LMB activates, others cancel.

svn path=/branches/work/kwin_composite/; revision=654154
This commit is contained in:
Luboš Luňák 2007-04-15 09:14:37 +00:00
parent 672c95e435
commit e18e701f7f

View file

@ -44,7 +44,7 @@ PresentWindowsEffect::PresentWindowsEffect()
b->setGlobalShortcut(KShortcut(Qt::CTRL + Qt::Key_F11));
connect(b, SIGNAL(triggered(bool)), this, SLOT(toggleActiveAllDesktops()));
borderActivate = ElectricTopRight;
borderActivate = ElectricTopRight; // TODO config options
borderActivateAll = ElectricNone;
effects->reserveElectricBorder( borderActivate );
@ -164,6 +164,11 @@ void PresentWindowsEffect::windowInputMouseEvent( Window w, QEvent* e )
}
if( e->type() != QEvent::MouseButtonPress )
return;
if( static_cast< QMouseEvent* >( e )->button() != Qt::LeftButton )
{
setActive( false );
return;
}
// Find out which window (if any) was clicked and activate it
QPoint pos = static_cast< QMouseEvent* >( e )->pos();