Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Plasma
KWayland Integration
Commits
c70458bc
Commit
c70458bc
authored
Oct 01, 2015
by
Marco Martin
Browse files
werap skipTaskbar in setState
parent
e989409e
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/windowsystem/waylandintegration.cpp
View file @
c70458bc
...
...
@@ -31,6 +31,7 @@
#include
<KWayland/Client/contrast.h>
#include
<KWayland/Client/region.h>
#include
<KWayland/Client/slide.h>
#include
<KWayland/Client/shell.h>
#include
<KWindowSystem/KWindowSystem>
...
...
src/windowsystem/windowsystem.cpp
View file @
c70458bc
...
...
@@ -289,16 +289,124 @@ void WindowSystem::setShowingDesktop(bool showing)
void
WindowSystem
::
clearState
(
WId
win
,
NET
::
States
state
)
{
Q_UNUSED
(
win
)
Q_UNUSED
(
state
)
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing window states"
;
Surface
*
s
=
Surface
::
fromQtWinId
(
win
);
if
(
!
s
)
{
return
;
}
KWayland
::
Client
::
PlasmaShellSurface
*
plasmaShellSurface
=
0
;
if
(
state
&
NET
::
SkipTaskbar
)
{
if
(
!
WaylandIntegration
::
self
()
->
waylandPlasmaShell
())
{
return
;
}
plasmaShellSurface
=
PlasmaShellSurface
::
get
(
s
);
if
(
!
plasmaShellSurface
)
{
plasmaShellSurface
=
WaylandIntegration
::
self
()
->
waylandPlasmaShell
()
->
createSurface
(
s
,
this
);
}
if
(
!
plasmaShellSurface
)
{
return
;
}
}
if
(
state
&
NET
::
SkipTaskbar
)
{
plasmaShellSurface
->
setSkipTaskbar
(
false
);
}
if
(
state
&
NET
::
Max
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Max window state"
;
}
if
(
state
&
NET
::
FullScreen
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing FullScreen window state"
;
}
if
(
state
&
NET
::
Modal
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Modal window state"
;
}
if
(
state
&
NET
::
Sticky
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Sticky window state"
;
}
if
(
state
&
NET
::
Shaded
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Shaded window state"
;
}
if
(
state
&
NET
::
KeepAbove
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing KeepAbove window state"
;
}
if
(
state
&
NET
::
StaysOnTop
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing StaysOnTop window state"
;
}
if
(
state
&
NET
::
SkipPager
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing SkipPager window state"
;
}
if
(
state
&
NET
::
Hidden
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Hidden window state"
;
}
if
(
state
&
NET
::
KeepBelow
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing KeepBelow window state"
;
}
if
(
state
&
NET
::
DemandsAttention
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing DemandsAttention window state"
;
}
}
void
WindowSystem
::
setState
(
WId
win
,
NET
::
States
state
)
{
Q_UNUSED
(
win
)
Q_UNUSED
(
state
)
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing window states"
;
Surface
*
s
=
Surface
::
fromQtWinId
(
win
);
if
(
!
s
)
{
return
;
}
KWayland
::
Client
::
PlasmaShellSurface
*
plasmaShellSurface
=
0
;
if
(
state
&
NET
::
SkipTaskbar
)
{
if
(
!
WaylandIntegration
::
self
()
->
waylandPlasmaShell
())
{
return
;
}
plasmaShellSurface
=
PlasmaShellSurface
::
get
(
s
);
if
(
!
plasmaShellSurface
)
{
plasmaShellSurface
=
WaylandIntegration
::
self
()
->
waylandPlasmaShell
()
->
createSurface
(
s
,
this
);
}
if
(
!
plasmaShellSurface
)
{
return
;
}
}
if
(
state
&
NET
::
SkipTaskbar
)
{
plasmaShellSurface
->
setSkipTaskbar
(
true
);
}
if
(
state
&
NET
::
Max
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Max window state"
;
}
if
(
state
&
NET
::
FullScreen
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing FullScreen window state"
;
}
if
(
state
&
NET
::
Modal
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Modal window state"
;
}
if
(
state
&
NET
::
Sticky
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Sticky window state"
;
}
if
(
state
&
NET
::
Shaded
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Shaded window state"
;
}
if
(
state
&
NET
::
KeepAbove
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing KeepAbove window state"
;
}
if
(
state
&
NET
::
StaysOnTop
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing StaysOnTop window state"
;
}
if
(
state
&
NET
::
SkipPager
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing SkipPager window state"
;
}
if
(
state
&
NET
::
Hidden
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing Hidden window state"
;
}
if
(
state
&
NET
::
KeepBelow
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing KeepBelow window state"
;
}
if
(
state
&
NET
::
DemandsAttention
)
{
qCDebug
(
KWAYLAND_KWS
)
<<
"This plugin does not support changing DemandsAttention window state"
;
}
}
void
WindowSystem
::
setType
(
WId
win
,
NET
::
WindowType
windowType
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment