mirror of
https://github.com/hyprwm/aquamarine.git
synced 2024-11-17 03:46:00 +01:00
wayland: handle close events
This commit is contained in:
parent
aadc5dd5e6
commit
b8fc53e69d
1 changed files with 7 additions and 0 deletions
|
@ -469,6 +469,13 @@ Aquamarine::CWaylandOutput::CWaylandOutput(const std::string& name_, Hyprutils::
|
|||
sendFrameAndSetCallback();
|
||||
});
|
||||
|
||||
waylandState.xdgToplevel->setClose([this](CCXdgToplevel* r) {
|
||||
events.destroy.emit();
|
||||
waylandState.surface->sendAttach(nullptr, 0, 0);
|
||||
waylandState.surface->sendCommit();
|
||||
std::erase(backend->outputs, self.lock());
|
||||
});
|
||||
|
||||
auto inputRegion = makeShared<CCWlRegion>(backend->waylandState.compositor->sendCreateRegion());
|
||||
inputRegion->sendAdd(0, 0, INT32_MAX, INT32_MAX);
|
||||
|
||||
|
|
Loading…
Reference in a new issue