aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/lltoolbar.cpp
diff options
context:
space:
mode:
authorJacek Antonelli2008-08-15 23:45:04 -0500
committerJacek Antonelli2008-08-15 23:45:04 -0500
commit117e22047c5752352342d64e3fb7ce00a4eb8113 (patch)
treee32de2cfba0dda8705ae528fcd1fbe23ba075685 /linden/indra/newview/lltoolbar.cpp
parentSecond Life viewer sources 1.18.0.6 (diff)
downloadmeta-impy-117e22047c5752352342d64e3fb7ce00a4eb8113.zip
meta-impy-117e22047c5752352342d64e3fb7ce00a4eb8113.tar.gz
meta-impy-117e22047c5752352342d64e3fb7ce00a4eb8113.tar.bz2
meta-impy-117e22047c5752352342d64e3fb7ce00a4eb8113.tar.xz
Second Life viewer sources 1.18.1.2
Diffstat (limited to 'linden/indra/newview/lltoolbar.cpp')
-rw-r--r--linden/indra/newview/lltoolbar.cpp35
1 files changed, 5 insertions, 30 deletions
diff --git a/linden/indra/newview/lltoolbar.cpp b/linden/indra/newview/lltoolbar.cpp
index 3d065e1..d58cca0 100644
--- a/linden/indra/newview/lltoolbar.cpp
+++ b/linden/indra/newview/lltoolbar.cpp
@@ -46,6 +46,7 @@
46#include "llvoavatar.h" 46#include "llvoavatar.h"
47#include "lltooldraganddrop.h" 47#include "lltooldraganddrop.h"
48#include "llinventoryview.h" 48#include "llinventoryview.h"
49#include "llfloaterchatterbox.h"
49#include "llfloaterfriends.h" 50#include "llfloaterfriends.h"
50#include "llfloatersnapshot.h" 51#include "llfloatersnapshot.h"
51#include "lltoolmgr.h" 52#include "lltoolmgr.h"
@@ -114,15 +115,12 @@ LLToolBar::LLToolBar(const std::string& name, const LLRect& r)
114 115
115BOOL LLToolBar::postBuild() 116BOOL LLToolBar::postBuild()
116{ 117{
117 childSetAction("im_btn", onClickIM, this); 118 childSetAction("communicate_btn", onClickCommunicate, this);
118 childSetControlName("im_btn", "ShowIM"); 119 childSetControlName("communicate_btn", "ShowCommunicate");
119 120
120 childSetAction("chat_btn", onClickChat, this); 121 childSetAction("chat_btn", onClickChat, this);
121 childSetControlName("chat_btn", "ChatVisible"); 122 childSetControlName("chat_btn", "ChatVisible");
122 123
123 childSetAction("friends_btn", onClickFriends, this);
124 childSetControlName("friends_btn", "ShowFriends");
125
126 childSetAction("appearance_btn", onClickAppearance, this); 124 childSetAction("appearance_btn", onClickAppearance, this);
127 childSetControlName("appearance_btn", ""); 125 childSetControlName("appearance_btn", "");
128 126
@@ -333,24 +331,9 @@ void LLToolBar::refresh()
333 331
334 332
335// static 333// static
336void LLToolBar::onClickIM(void* user_data) 334void LLToolBar::onClickCommunicate(void* user_data)
337{ 335{
338 if(gIMView->getFloaterOpen()) 336 LLFloaterChatterBox::toggleInstance(LLSD());
339 {
340 // this is if we want Ctrl-T to be simply a toggle
341 // gIMView->setFloaterOpen( FALSE );
342 // three-state behavior follows
343 if(gFocusMgr.childHasKeyboardFocus(gIMView->getFloater()))
344 {
345 gIMView->setFloaterOpen( FALSE );
346 } else {
347 gIMView->getFloater()->setFocus( TRUE );
348 }
349 }
350 else
351 {
352 gIMView->setFloaterOpen( TRUE );
353 }
354} 337}
355 338
356 339
@@ -360,14 +343,6 @@ void LLToolBar::onClickChat(void* user_data)
360 handle_chat(NULL); 343 handle_chat(NULL);
361} 344}
362 345
363
364// static
365void LLToolBar::onClickFriends(void*)
366{
367 LLFloaterFriends::toggle();
368}
369
370
371// static 346// static
372void LLToolBar::onClickAppearance(void*) 347void LLToolBar::onClickAppearance(void*)
373{ 348{