// // LLFloaterChatterBox // LLFloaterChatterBox::LLFloaterChatterBox(const LLSD& seed) : mActiveVoiceFloater(NULL) { mAutoResize = FALSE; LLUICtrlFactory::getInstance()->buildFloater(this, "floater_chatterbox.xml", NULL, FALSE); if (gSavedSettings.getBOOL("ContactsTornOff")) { LLFloaterMyFriends* floater_contacts = LLFloaterMyFriends::getInstance(0); // add then remove to set up relationship for re-attach addFloater(floater_contacts, FALSE); removeFloater(floater_contacts); // reparent to floater view gFloaterView->addChild(floater_contacts); } else { addFloater(LLFloaterMyFriends::getInstance(0), TRUE); } if (gSavedSettings.getBOOL("ChatHistoryTornOff")) { LLFloaterChat* floater_chat = LLFloaterChat::getInstance(); // add then remove to set up relationship for re-attach addFloater(floater_chat, FALSE); removeFloater(floater_chat); // reparent to floater view gFloaterView->addChild(floater_chat); } else { addFloater(LLFloaterChat::getInstance(LLSD()), FALSE); } mTabContainer->lockTabs(); }
// // LLFloaterChatterBox // LLFloaterChatterBox::LLFloaterChatterBox(const LLSD& seed) : mActiveVoiceFloater(NULL) { mAutoResize = FALSE; if(!gSavedSettings.getBOOL("WoLfVerticalIMTabs")) { LLUICtrlFactory::getInstance()->buildFloater(this, "floater_chatterbox.xml", NULL, FALSE); } else { LLUICtrlFactory::getInstance()->buildFloater(this, "floater_chatterbox_wolf.xml", NULL, FALSE); } if (gSavedSettings.getBOOL("ContactsTornOff")) { LLFloaterMyFriends* floater_contacts = LLFloaterMyFriends::getInstance(0); // add then remove to set up relationship for re-attach addFloater(floater_contacts, FALSE); removeFloater(floater_contacts); // reparent to floater view gFloaterView->addChild(floater_contacts); if (gSavedSettings.getBOOL("ShowContacts")) floater_contacts->open(); } else { addFloater(LLFloaterMyFriends::getInstance(0), TRUE); } LLFloaterChat* floater_chat = LLFloaterChat::getInstance(); if (gSavedSettings.getBOOL("ChatHistoryTornOff")) { // add then remove to set up relationship for re-attach addFloater(floater_chat, FALSE); removeFloater(floater_chat); // reparent to floater view gFloaterView->addChild(floater_chat); if (gSavedSettings.getBOOL("ShowChatHistory")) floater_chat->open(); } else { addFloater(floater_chat, FALSE); } if (gSavedSettings.getBOOL("ShowCommunicate")) open(); // After all floaters have been added, so we may not be hidden anyhow. gSavedSettings.getControl("ShowLocalChatFloaterBar")->getSignal()->connect(boost::bind(handleLocalChatBar, floater_chat, _2)); mTabContainer->lockTabs(); }
void LLMultiFloater::showFloater(LLFloater* floaterp, LLTabContainer::eInsertionPoint insertion_point) { if(!floaterp) return; // we won't select a panel that already is selected // it is hard to do this internally to tab container // as tab selection is handled via index and the tab at a given // index might have changed if (floaterp != mTabContainer->getCurrentPanel() && !mTabContainer->selectTabPanel(floaterp)) { addFloater(floaterp, TRUE, insertion_point); } }
BOOL FSFloaterIMContainer::postBuild() { if (!gSavedSettings.getBOOL("ContactsTornOff")) { addFloater(FSFloaterContacts::getInstance(), TRUE); } mNewMessageConnection = LLIMModel::instance().mNewMsgSignal.connect(boost::bind(&FSFloaterIMContainer::onNewMessageReceived, this, _1)); // Do not call base postBuild to not connect to mCloseSignal to not close all floaters via Close button // mTabContainer will be initialized in LLMultiFloater::addChild() return TRUE; }
BOOL LLFloaterChatterBox::postBuild() { setVisibleCallback(boost::bind(&LLFloaterChatterBox::onVisibilityChange, this, _2)); if (gSavedSettings.getBOOL("ContactsTornOff")) { LLFloaterMyFriends* floater_contacts = LLFloaterMyFriends::getInstance(); if(floater_contacts) { // add then remove to set up relationship for re-attach addFloater(floater_contacts, FALSE); removeFloater(floater_contacts); // reparent to floater view gFloaterView->addChild(floater_contacts); } } else { addFloater(LLFloaterMyFriends::getInstance(), TRUE); } mTabContainer->lockTabs(); return TRUE; }