Fix #74063 - if there's a restacking operation, cancel pending autoraise

for the window.

svn path=/trunk/kdebase/kwin/; revision=286801
This commit is contained in:
Luboš Luňák 2004-02-10 14:46:03 +00:00
parent d465d96819
commit 0c051481e9
5 changed files with 18 additions and 7 deletions

View file

@ -704,11 +704,8 @@ void Client::setActive( bool act)
if ( active )
Notify::raise( Notify::Activate );
if ( !active && autoRaiseTimer )
{
delete autoRaiseTimer;
autoRaiseTimer = 0;
}
if( !active )
cancelAutoRaise();
if( !active && shade_mode == ShadeActivated )
setShade( ShadeNormal );

View file

@ -1632,6 +1632,12 @@ void Client::autoRaise()
autoRaiseTimer = 0;
}
void Client::cancelAutoRaise()
{
delete autoRaiseTimer;
autoRaiseTimer = 0;
}
#ifdef NDEBUG
kndbgstream& operator<<( kndbgstream& stream, const Client* ) { return stream; }
kndbgstream& operator<<( kndbgstream& stream, const ClientList& ) { return stream; }

View file

@ -276,6 +276,7 @@ class Client : public QObject, public KDecorationDefines
void toggleShade();
void showContextHelp();
void autoRaise();
void cancelAutoRaise();
void shadeHover();
void destroyClient();

View file

@ -893,8 +893,7 @@ void Client::leaveNotifyEvent( XCrossingEvent* e )
}
if ( lostMouse )
{
delete autoRaiseTimer;
autoRaiseTimer = 0;
cancelAutoRaise();
delete shadeHoverTimer;
shadeHoverTimer = 0;
if ( shade_mode == ShadeHover && !moveResizeMode && !buttonDown )

View file

@ -269,6 +269,8 @@ void Workspace::lowerClient( Client* c )
if ( !c )
return;
c->cancelAutoRaise();
StackingUpdatesBlocker blocker( this );
unconstrained_stacking_order.remove( c );
@ -292,6 +294,8 @@ void Workspace::lowerClientWithinApplication( Client* c )
if ( !c )
return;
c->cancelAutoRaise();
StackingUpdatesBlocker blocker( this );
unconstrained_stacking_order.remove( c );
@ -316,6 +320,8 @@ void Workspace::raiseClient( Client* c )
if ( !c )
return;
c->cancelAutoRaise();
StackingUpdatesBlocker blocker( this );
if( c->isTransient())
@ -339,6 +345,8 @@ void Workspace::raiseClientWithinApplication( Client* c )
if ( !c )
return;
c->cancelAutoRaise();
StackingUpdatesBlocker blocker( this );
// ignore mainwindows