Commit e967385b authored by Martin Flöser's avatar Martin Flöser

[krunner] First set panel behavior than as panel

Summary:
If a PlasmaShellSurface for an already mapped window is created and set
to panel it affects other windows by adjusting the maximized area. This
happens when showing KRunner for the second time and later. To prevent
this and make KWin's life slightly easier we first set the panel behavior
to windows go below and then mark it as panel. Thus other windows are not
affected by opening KRunner.

Reviewers: #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D6657
parent be413f2c
......@@ -242,9 +242,9 @@ bool View::event(QEvent *event)
return retval;
}
m_plasmaShellSurface = m_plasmaShell->createSurface(s, this);
m_plasmaShellSurface->setRole(PlasmaShellSurface::Role::Panel);
m_plasmaShellSurface->setPanelBehavior(PlasmaShellSurface::PanelBehavior::WindowsGoBelow);
m_plasmaShellSurface->setPanelTakesFocus(true);
m_plasmaShellSurface->setRole(PlasmaShellSurface::Role::Panel);
//this should be on showEvent, but it was too soon so none of those had any effect
KWindowSystem::setOnAllDesktops(winId(), true);
positionOnScreen();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment