File tree Expand file tree Collapse file tree 2 files changed +14
-1
lines changed Expand file tree Collapse file tree 2 files changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -154,6 +154,14 @@ void SurfaceWrapper::setParent(QQuickItem *item)
154
154
void SurfaceWrapper::setActivate (bool activate)
155
155
{
156
156
m_shellSurface->setActivate (activate);
157
+ if (type () == SurfaceWrapper::Type::XWayland) {
158
+ auto xwaylandSurface = qobject_cast<WXWaylandSurface *>(m_shellSurface);
159
+ if (activate)
160
+ xwaylandSurface->restack (nullptr , WXWaylandSurface::XCB_STACK_MODE_ABOVE);
161
+
162
+ return ;
163
+ }
164
+
157
165
auto parent = parentSurface ();
158
166
while (parent) {
159
167
parent->setActivate (activate);
Original file line number Diff line number Diff line change @@ -565,7 +565,12 @@ void WXWaylandSurface::close()
565
565
566
566
void WXWaylandSurface::restack (WXWaylandSurface *sibling, StackMode mode)
567
567
{
568
- handle ()->restack (*sibling->handle (), static_cast <xcb_stack_mode_t >(mode));
568
+ if (sibling) {
569
+ handle ()->restack (*sibling->handle (), static_cast <xcb_stack_mode_t >(mode));
570
+ return ;
571
+ }
572
+
573
+ handle ()->restack (nullptr , static_cast <xcb_stack_mode_t >(mode));
569
574
}
570
575
571
576
WAYLIB_SERVER_END_NAMESPACE
You can’t perform that action at this time.
0 commit comments