seat: keep track of serials that are allowed to steal keyboard focus
This commit is contained in:
parent
324540c41e
commit
18bddbc987
4 changed files with 21 additions and 1 deletions
|
|
@ -211,6 +211,7 @@ impl TabletTool {
|
|||
tool.send_frame(time);
|
||||
});
|
||||
if state == ToolButtonState::Pressed {
|
||||
n.client.focus_stealing_serial.set(Some(serial.get()));
|
||||
if let Some(node) = n.get_focus_node(self.tablet.seat.id) {
|
||||
self.tablet.seat.focus_node_with_serial(node, serial.get());
|
||||
}
|
||||
|
|
@ -259,6 +260,7 @@ impl TabletTool {
|
|||
});
|
||||
if let Some(changes) = changes {
|
||||
if changes.down == Some(true) {
|
||||
n.client.focus_stealing_serial.set(Some(serial.get()));
|
||||
if let Some(node) = n.get_focus_node(self.tablet.seat.id) {
|
||||
self.tablet.seat.focus_node_with_serial(node, serial.get());
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue