Add option to make the statistics bar ignore focus requests from closing other floaters with ctrl-w.

Sat, 14 Apr 2018 01:24:15 -0700

author
Liny <liny@pinkfox.xyz>
date
Sat, 14 Apr 2018 01:24:15 -0700
changeset 55101
92f05af11f97
parent 55100
089bc7e7644d
child 55102
5b79e95827ec

Add option to make the statistics bar ignore focus requests from closing other floaters with ctrl-w.
Prevents it from being able to steal keyboard focus from movement.

indra/newview/app_settings/settings.xml file | annotate | diff | revisions
indra/newview/llappviewer.cpp file | annotate | diff | revisions
     1.1 --- a/indra/newview/app_settings/settings.xml	Fri Apr 13 18:59:52 2018 -0700
     1.2 +++ b/indra/newview/app_settings/settings.xml	Sat Apr 14 01:24:15 2018 -0700
     1.3 @@ -24624,6 +24624,17 @@
     1.4        <key>Value</key>
     1.5        <integer>1</integer>
     1.6      </map>
     1.7 +    <key>FSStatisticsNoFocus</key>
     1.8 +    <map>
     1.9 +      <key>Comment</key>
    1.10 +      <string>If enabled, the statistics bar will never gain focus (i.e. from closing another floater). Requires restart.</string>
    1.11 +      <key>Persist</key>
    1.12 +      <integer>1</integer>
    1.13 +      <key>Type</key>
    1.14 +      <string>Boolean</string>
    1.15 +      <key>Value</key>
    1.16 +      <integer>0</integer>
    1.17 +    </map>
    1.18    </map>
    1.19  </llsd>
    1.20  
     2.1 --- a/indra/newview/llappviewer.cpp	Fri Apr 13 18:59:52 2018 -0700
     2.2 +++ b/indra/newview/llappviewer.cpp	Sat Apr 14 01:24:15 2018 -0700
     2.3 @@ -1162,6 +1162,23 @@
     2.4  	initWindow();
     2.5  	LL_INFOS("InitInfo") << "Window is initialized." << LL_ENDL ;
     2.6  
     2.7 +
     2.8 +
     2.9 +	// <FS:LO> Add ability for the statistics window to not be able to receive focus
    2.10 +	if (gSavedSettings.getBOOL("FSStatisticsNoFocus"))
    2.11 +	{
    2.12 +		LLFloater* stats = LLFloaterReg::getInstance("stats");
    2.13 +		if (stats)
    2.14 +		{
    2.15 +			stats->setIsChrome(TRUE);
    2.16 +		}
    2.17 +		else
    2.18 +		{
    2.19 +			LL_ERRS("") << "Cant find floater" << LL_ENDL;
    2.20 +		}
    2.21 +	}
    2.22 +	// </FS:LO>
    2.23 +
    2.24  	// initWindow also initializes the Feature List, so now we can initialize this global.
    2.25  	LLCubeMap::sUseCubeMaps = LLFeatureManager::getInstance()->isFeatureAvailable("RenderCubeMap");
    2.26  

mercurial