Skip to content
Snippets Groups Projects
Commit d34746b5 authored by Seth ProductEngine's avatar Seth ProductEngine
Browse files

CHUI-144 FIXED Residents picker added to Conversations panel + button.

parent 569146f2
No related branches found
No related tags found
No related merge requests found
...@@ -34,8 +34,10 @@ ...@@ -34,8 +34,10 @@
#include "llnearbychat.h" #include "llnearbychat.h"
#include "llagent.h" #include "llagent.h"
#include "llavataractions.h"
#include "llavatariconctrl.h" #include "llavatariconctrl.h"
#include "llgroupiconctrl.h" #include "llgroupiconctrl.h"
#include "llfloateravatarpicker.h"
#include "llimview.h" #include "llimview.h"
#include "lltransientfloatermgr.h" #include "lltransientfloatermgr.h"
#include "llviewercontrol.h" #include "llviewercontrol.h"
...@@ -75,6 +77,8 @@ BOOL LLIMFloaterContainer::postBuild() ...@@ -75,6 +77,8 @@ BOOL LLIMFloaterContainer::postBuild()
mExpandCollapseBtn = getChild<LLButton>("expand_collapse_btn"); mExpandCollapseBtn = getChild<LLButton>("expand_collapse_btn");
mExpandCollapseBtn->setClickedCallback(boost::bind(&LLIMFloaterContainer::onExpandCollapseButtonClicked, this)); mExpandCollapseBtn->setClickedCallback(boost::bind(&LLIMFloaterContainer::onExpandCollapseButtonClicked, this));
childSetAction("add_btn", boost::bind(&LLIMFloaterContainer::onAddButtonClicked, this));
collapseMessagesPane(gSavedPerAccountSettings.getBOOL("ConversationsMessagePaneCollapsed")); collapseMessagesPane(gSavedPerAccountSettings.getBOOL("ConversationsMessagePaneCollapsed"));
collapseConversationsPane(gSavedPerAccountSettings.getBOOL("ConversationsListPaneCollapsed")); collapseConversationsPane(gSavedPerAccountSettings.getBOOL("ConversationsListPaneCollapsed"));
...@@ -313,4 +317,26 @@ void LLIMFloaterContainer::updateState(bool collapse, S32 delta_width) ...@@ -313,4 +317,26 @@ void LLIMFloaterContainer::updateState(bool collapse, S32 delta_width)
setCanMinimize(is_left_pane_expanded || is_right_pane_expanded); setCanMinimize(is_left_pane_expanded || is_right_pane_expanded);
} }
void LLIMFloaterContainer::onAddButtonClicked()
{
LLFloaterAvatarPicker* picker = LLFloaterAvatarPicker::show(boost::bind(&LLIMFloaterContainer::onAvatarPicked, this, _1), TRUE, TRUE);
LLFloater* root_floater = gFloaterView->getParentFloater(this);
if (picker && root_floater)
{
root_floater->addDependentFloater(picker);
}
}
void LLIMFloaterContainer::onAvatarPicked(const uuid_vec_t& ids)
{
if (ids.size() == 1)
{
LLAvatarActions::startIM(ids.back());
}
else
{
LLAvatarActions::startConference(ids);
}
}
// EOF // EOF
...@@ -80,6 +80,9 @@ class LLIMFloaterContainer : public LLMultiFloater ...@@ -80,6 +80,9 @@ class LLIMFloaterContainer : public LLMultiFloater
void updateState(bool collapse, S32 delta_width); void updateState(bool collapse, S32 delta_width);
void onAddButtonClicked();
void onAvatarPicked(const uuid_vec_t& ids);
LLButton* mExpandCollapseBtn; LLButton* mExpandCollapseBtn;
LLLayoutPanel* mMessagesPane; LLLayoutPanel* mMessagesPane;
LLLayoutPanel* mConversationsPane; LLLayoutPanel* mConversationsPane;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment