diff options
Diffstat (limited to 'indra/newview/llchiclet.cpp')
-rw-r--r-- | indra/newview/llchiclet.cpp | 38 |
1 files changed, 26 insertions, 12 deletions
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp index b9e8c5394d..bad61101c1 100644 --- a/indra/newview/llchiclet.cpp +++ b/indra/newview/llchiclet.cpp @@ -51,7 +51,7 @@ #include "lltransientfloatermgr.h" static LLDefaultChildRegistry::Register<LLChicletPanel> t1("chiclet_panel"); -static LLDefaultChildRegistry::Register<LLTalkButton> t2("talk_button"); +static LLDefaultChildRegistry::Register<LLTalkButton> t2("chiclet_talk"); static LLDefaultChildRegistry::Register<LLNotificationChiclet> t3("chiclet_notification"); static LLDefaultChildRegistry::Register<LLIMP2PChiclet> t4("chiclet_im_p2p"); static LLDefaultChildRegistry::Register<LLIMGroupChiclet> t5("chiclet_im_group"); @@ -830,21 +830,13 @@ LLChicletPanel::~LLChicletPanel() void im_chiclet_callback(LLChicletPanel* panel, const LLSD& data){ LLUUID session_id = data["session_id"].asUUID(); - S32 unread = data["num_unread"].asInteger(); - - LLIMFloater* im_floater = LLIMFloater::findInstance(session_id); - if (im_floater && im_floater->getVisible()) - { - unread = 0; - } - std::list<LLChiclet*> chiclets = LLIMChiclet::sFindChicletsSignal(session_id); std::list<LLChiclet *>::iterator iter; for (iter = chiclets.begin(); iter != chiclets.end(); iter++) { LLChiclet* chiclet = *iter; if (chiclet != NULL) { - chiclet->setCounter(unread); + chiclet->setCounter(data["num_unread"].asInteger()); } else { @@ -1265,7 +1257,30 @@ LLTalkButton::Params::Params() , show_button("show_button") , monitor("monitor") { - // See widgets/talk_button.xml + // *TODO Vadim: move hardcoded labels (!) and other params to XUI. + speak_button.name("left"); + speak_button.label("Speak"); + speak_button.label_selected("Speak"); + speak_button.font(LLFontGL::getFontSansSerifSmall()); + speak_button.tab_stop(false); + speak_button.is_toggle(true); + speak_button.picture_style(true); + // Use default button art. JC + //speak_button.image_selected(LLUI::getUIImage("SegmentedBtn_Left_Selected")); + //speak_button.image_unselected(LLUI::getUIImage("SegmentedBtn_Left_Off")); + + show_button.name("right"); + show_button.label(LLStringUtil::null); + show_button.rect(LLRect(0, 0, 20, 0)); + show_button.tab_stop(false); + show_button.is_toggle(true); + show_button.picture_style(true); + show_button.image_selected(LLUI::getUIImage("ComboButton_Selected")); + show_button.image_unselected(LLUI::getUIImage("ComboButton_Off")); + + monitor.name("monitor"); + // *TODO: Make this data driven. + monitor.rect(LLRect(0, 18, 18, 0)); } LLTalkButton::LLTalkButton(const Params& p) @@ -1321,7 +1336,6 @@ LLTalkButton::LLTalkButton(const Params& p) // never show "muted" because you can't mute yourself mOutputMonitor->setIsMuted(false); - mOutputMonitor->setIsAgentControl(true); } LLTalkButton::~LLTalkButton() |