idle-inhibit: implement protocol

This commit is contained in:
dfangx
2022-05-11 08:14:01 -04:00
committed by GitHub
parent 90b37645cf
commit d5c915e3cb
5 changed files with 111 additions and 0 deletions

View File

@ -436,6 +436,13 @@ pub fn fromWlrSurface(surface: *wlr.Surface) ?*Self {
return @intToPtr(*Self, xwayland_surface.data);
}
}
if (surface.isSubsurface()) {
if (wlr.Subsurface.fromWlrSurface(surface)) |ss| {
if (ss.parent) |s| {
return fromWlrSurface(s);
}
}
}
return null;
}