do not switch desktop on resizing windows

REVIEW: 123599
icc-effect-5.14.5
Thomas Lübking 2015-05-03 14:26:18 +02:00
parent 7a7d79a168
commit 5d09eaae1f
3 changed files with 9 additions and 2 deletions

View File

@ -85,6 +85,11 @@ void Client::setHiddenInternal(bool set)
m_hiddenInternal = set; m_hiddenInternal = set;
} }
bool Client::isResize() const
{
return false;
}
void Client::setGeometry(const QRect &rect) void Client::setGeometry(const QRect &rect)
{ {
m_geometry = rect; m_geometry = rect;

View File

@ -38,6 +38,7 @@ public:
bool isActive() const; bool isActive() const;
bool isFullScreen() const; bool isFullScreen() const;
bool isHiddenInternal() const; bool isHiddenInternal() const;
bool isResize() const;
QRect geometry() const; QRect geometry() const;
void setActive(bool active); void setActive(bool active);

View File

@ -188,7 +188,8 @@ void Edge::handle(const QPoint &cursorPos)
unreserve(); unreserve();
return; return;
} }
if ((edges()->isDesktopSwitchingMovingClients() && Workspace::self()->getMovingClient()) || Client *movingClient = Workspace::self()->getMovingClient();
if ((edges()->isDesktopSwitchingMovingClients() && movingClient && !movingClient->isResize()) ||
(edges()->isDesktopSwitching() && isScreenEdge())) { (edges()->isDesktopSwitching() && isScreenEdge())) {
// always switch desktops in case: // always switch desktops in case:
// moving a Client and option for switch on client move is enabled // moving a Client and option for switch on client move is enabled
@ -196,7 +197,7 @@ void Edge::handle(const QPoint &cursorPos)
switchDesktop(cursorPos); switchDesktop(cursorPos);
return; return;
} }
if (Workspace::self()->getMovingClient()) { if (movingClient) {
// if we are moving a window we don't want to trigger the actions. This just results in // if we are moving a window we don't want to trigger the actions. This just results in
// problems, e.g. Desktop Grid activated or screen locker activated which just cannot // problems, e.g. Desktop Grid activated or screen locker activated which just cannot
// work as we hold a grab. // work as we hold a grab.