#48786 (comments #7 and later) - focus stealing prevention doesn't work

well with unreasonable focus policies -> disabled.

svn path=/trunk/kdebase/kwin/; revision=284526
This commit is contained in:
Luboš Luňák 2004-02-02 17:02:11 +00:00
parent e5d090ff4d
commit 39e48b3b8d
3 changed files with 5 additions and 6 deletions

View file

@ -276,11 +276,6 @@ void Workspace::activateClient( Client* c, bool force )
if( options->focusPolicyIsReasonable())
requestFocus( c, force );
else
{
if( mostRecentlyActivatedClient() != c )
c->demandAttention();
}
c->updateUserTime();
}

View file

@ -525,7 +525,9 @@ KAdvancedConfig::KAdvancedConfig (bool _standAlone, KConfig *_config, QWidget *p
focusStealingLayout->addWidget( focusStealingLabel );
focusStealingLayout->addWidget( focusStealing, AlignLeft );
wtstr = i18n( "This option specifies how much KWin will try to prevent unwanted focus stealing "
"caused by unexpected activation of new windows.<ul>"
"caused by unexpected activation of new windows. (Note: This feature doesn't "
"work with the Focus Under Mouse or Focus Strictly Under Mouse focus policies.)"
"<ul>"
"<li><em>None:</em> The standard old behavior - prevention is turned off "
"and new windows always become activated.</li>"
"<li><em>Low:</em> Prevention is enabled; when some window doesn't have support "

View file

@ -68,6 +68,8 @@ unsigned long Options::updateSettings()
// TODO use low level for now
focusStealingPreventionLevel = config->readNumEntry( "FocusStealingPreventionLevel", 1 );
focusStealingPreventionLevel = KMAX( 0, KMIN( 4, focusStealingPreventionLevel ));
if( !focusPolicyIsReasonable()) // #48786, comments #7 and later
focusStealingPreventionLevel = 0;
KConfig *gc = new KConfig("kdeglobals", false, false);
bool isVirtual = KApplication::desktop()->isVirtualDesktop();