Fix: snap on resize snapped by 1px wrong on the right and bottom.
Now it works perfectly with all client windows including the desktop. CCMAIL: 45805@bugs.kde.org svn path=/trunk/kdebase/kwin/; revision=323630
This commit is contained in:
parent
a475ba494b
commit
aa98f268bc
1 changed files with 6 additions and 6 deletions
12
geometry.cpp
12
geometry.cpp
|
@ -384,9 +384,9 @@ QRect Workspace::adjustClientSize( Client* c, QRect moveResizeGeom, int mode )
|
|||
|
||||
const QRect maxRect = clientArea(MovementArea, c->rect().center(), c->desktop());
|
||||
const int xmin = maxRect.left();
|
||||
const int xmax = maxRect.right()+1; //desk size
|
||||
const int xmax = maxRect.right(); //desk size
|
||||
const int ymin = maxRect.top();
|
||||
const int ymax = maxRect.bottom()+1;
|
||||
const int ymax = maxRect.bottom();
|
||||
|
||||
const int cx(moveResizeGeom.left());
|
||||
const int cy(moveResizeGeom.top());
|
||||
|
@ -485,10 +485,10 @@ QRect Workspace::adjustClientSize( Client* c, QRect moveResizeGeom, int mode )
|
|||
!(*l)->isMinimized()
|
||||
&& (*l) != c )
|
||||
{
|
||||
lx = (*l)->x();
|
||||
ly = (*l)->y();
|
||||
lrx = lx + (*l)->width();
|
||||
lry = ly + (*l)->height();
|
||||
lx = (*l)->x()-1;
|
||||
ly = (*l)->y()-1;
|
||||
lrx =(*l)->x() + (*l)->width();
|
||||
lry =(*l)->y() + (*l)->height();
|
||||
|
||||
#define WITHIN_HEIGHT ((( newcy <= lry ) && ( newcy >= ly )) || \
|
||||
(( newry >= ly ) && ( newry <= lry )) || \
|
||||
|
|
Loading…
Reference in a new issue