Skip to content

Commit

Permalink
xwm: use attention request when activating invisible windows
Browse files Browse the repository at this point in the history
  • Loading branch information
mahkoh committed Mar 3, 2024
1 parent 3582b8f commit d2f818b
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/xwayland/xwm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2290,9 +2290,13 @@ impl Wm {
Some(w) => w,
_ => return Ok(()),
};
let seats = self.state.globals.seats.lock();
for (_, seat) in seats.deref() {
seat.focus_toplevel(win.clone());
if win.toplevel_data.visible.get() {
let seats = self.state.globals.seats.lock();
for (_, seat) in seats.deref() {
seat.focus_toplevel(win.clone());
}
} else {
win.x.surface.request_activation();
}
Ok(())
}
Expand Down

0 comments on commit d2f818b

Please sign in to comment.