Skip to content

Commit

Permalink
extension: don't trust D-Bus activation
Browse files Browse the repository at this point in the history
Manually ensure the app is running before calling its actions.

Both dbus-daemon and dbus-broker are somewhat broken:

- https://gitlab.freedesktop.org/dbus/dbus/-/issues/458
- bus1/dbus-broker#314

Fixes #433
  • Loading branch information
amezin committed Jun 4, 2023
1 parent 9595c6c commit 590ec21
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions ddterm/shell/extension.js
Original file line number Diff line number Diff line change
Expand Up @@ -416,10 +416,14 @@ function activate() {
if (!window_manager.current_window)
window_manager.update_monitor_index();

if (window_manager.current_window)
if (window_manager.current_window) {
Main.activateWindow(window_manager.current_window);
else
} else {
if (!app_dbus.available)
spawn_app();

app_dbus.action_group.activate_action('show', null);
}
}

function set_skip_taskbar() {
Expand Down

0 comments on commit 590ec21

Please sign in to comment.