Ability to change default behavior of Chats being torn off so that all chats appear minimized upon opening, as well, regardless of conditions.
Adds debug setting OtherChatsTornOffAndMinimized Not added to ui xml because the default behavior is likely fine.
This commit is contained in:
@@ -760,6 +760,17 @@ Found in Advanced->Rendering->Info Displays</string>
|
||||
<key>Value</key>
|
||||
<integer>0</integer>
|
||||
</map>
|
||||
<key>OtherChatsTornOffAndMinimized</key>
|
||||
<map>
|
||||
<key>Comment</key>
|
||||
<string>When this and OtherChatsTornOff are true, new chats open torn off and minimized.</string>
|
||||
<key>Persist</key>
|
||||
<integer>1</integer>
|
||||
<key>Type</key>
|
||||
<string>Boolean</string>
|
||||
<key>Value</key>
|
||||
<integer>0</integer>
|
||||
</map>
|
||||
<key>MarketImporterUpdateFreq</key>
|
||||
<map>
|
||||
<key>Comment</key>
|
||||
|
||||
@@ -1176,11 +1176,16 @@ LLFloaterIMPanel* LLIMMgr::createFloater(
|
||||
gFloaterView->addChild(floater); // reparent to floater view
|
||||
LLFloater* focused_floater = gFloaterView->getFocusedFloater(); // obtain the focused floater
|
||||
floater->open(); // make the new chat floater appear
|
||||
static LLCachedControl<bool> minimize("OtherChatsTornOffAndMinimized");
|
||||
if (focused_floater != NULL) // there was a focused floater
|
||||
{
|
||||
floater->setMinimized(true); // so minimize this one, for now
|
||||
focused_floater->setFocus(true); // and work around focus being removed by focusing on the last
|
||||
}
|
||||
else if (minimize)
|
||||
{
|
||||
floater->setMinimized(true);
|
||||
}
|
||||
}
|
||||
mFloaters.insert(floater->getHandle());
|
||||
return floater;
|
||||
|
||||
Reference in New Issue
Block a user