fix(launcher): not clearing focused state when closing window
Fixes #213. Fixes partially #225.
This commit is contained in:
@@ -381,8 +381,12 @@ impl Module<gtk::Box> for LauncherModule {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
LauncherUpdate::RemoveWindow(app_id, _) => {
|
LauncherUpdate::RemoveWindow(app_id, win_id) => {
|
||||||
|
debug!("Removing window {win_id} with id {app_id}");
|
||||||
|
|
||||||
if let Some(button) = buttons.get(&app_id) {
|
if let Some(button) = buttons.get(&app_id) {
|
||||||
|
button.set_focused(false);
|
||||||
|
|
||||||
let mut menu_state = write_lock!(button.menu_state);
|
let mut menu_state = write_lock!(button.menu_state);
|
||||||
menu_state.num_windows -= 1;
|
menu_state.num_windows -= 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user