From 84c28985fb0d01331cd4e9af0510ba616e081992 Mon Sep 17 00:00:00 2001 From: Lucas Murray Date: Tue, 16 Dec 2008 04:24:20 +0000 Subject: [PATCH] Prevent selecting of hidden windows when using the present windows filter feature. svn path=/trunk/KDE/kdebase/workspace/; revision=897444 --- effects/presentwindows.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/effects/presentwindows.cpp b/effects/presentwindows.cpp index e54279f99d..114c3b2159 100644 --- a/effects/presentwindows.cpp +++ b/effects/presentwindows.cpp @@ -1286,6 +1286,8 @@ EffectWindow* PresentWindowsEffect::relativeWindow( EffectWindow *w, int xdiff, next = NULL; foreach( EffectWindow* e, m_motionManager.managedWindows() ) { + if( !m_windowData[e].visible ) + continue; QRectF eArea = m_motionManager.transformedGeometry( e ); if( eArea.intersects( detectRect ) && eArea.x() > wArea.x() ) @@ -1319,6 +1321,8 @@ EffectWindow* PresentWindowsEffect::relativeWindow( EffectWindow *w, int xdiff, next = NULL; foreach( EffectWindow* e, m_motionManager.managedWindows() ) { + if( !m_windowData[e].visible ) + continue; QRectF eArea = m_motionManager.transformedGeometry( e ); if( eArea.intersects( detectRect ) && eArea.x() + eArea.width() < wArea.x() + wArea.width() ) @@ -1357,6 +1361,8 @@ EffectWindow* PresentWindowsEffect::relativeWindow( EffectWindow *w, int xdiff, next = NULL; foreach( EffectWindow* e, m_motionManager.managedWindows() ) { + if( !m_windowData[e].visible ) + continue; QRectF eArea = m_motionManager.transformedGeometry( e ); if( eArea.intersects( detectRect ) && eArea.y() > wArea.y() ) @@ -1390,6 +1396,8 @@ EffectWindow* PresentWindowsEffect::relativeWindow( EffectWindow *w, int xdiff, next = NULL; foreach( EffectWindow* e, m_motionManager.managedWindows() ) { + if( !m_windowData[e].visible ) + continue; QRectF eArea = m_motionManager.transformedGeometry( e ); if( eArea.intersects( detectRect ) && eArea.y() + eArea.height() < wArea.y() + wArea.height() )