diff --git a/effects/desktopgrid/desktopgrid.cpp b/effects/desktopgrid/desktopgrid.cpp index 8d94852de6..711ab4cab2 100644 --- a/effects/desktopgrid/desktopgrid.cpp +++ b/effects/desktopgrid/desktopgrid.cpp @@ -809,7 +809,7 @@ EffectWindow* DesktopGridEffect::windowAt( QPoint pos ) const int desktop; pos = unscalePos( pos, &desktop ); - if( desktop >= effects->numberOfDesktops() ) + if( desktop > effects->numberOfDesktops() ) return NULL; if( isUsingPresentWindows() ) {