Fixed desktopAbove/Below/ToLeft/ToRight() coordinate detection.

Prevents crashing when usign spatial desktop switching.

svn path=/trunk/KDE/kdebase/workspace/; revision=926754
This commit is contained in:
Lucas Murray 2009-02-16 04:12:14 +00:00
parent c7092239e5
commit d0825f0515

View file

@ -73,7 +73,7 @@ QPoint Workspace::desktopGridCoords( int id ) const
{
for( int y = 0; y < desktopGridSize_.height(); y++ )
for( int x = 0; x < desktopGridSize_.width(); x++ )
if( desktopGrid_[y * desktopGridSize_.height() + x] == id )
if( desktopGrid_[y * desktopGridSize_.width() + x] == id )
return QPoint( x, y );
return QPoint( -1, -1 );
}