backgroundApps: Allow activating apps

Now that we track apps instead of instances, we can make the menu
items activatable, because the corresponding action is no longer
app specific (like activating a particular tab): We can simply
activate the app, which hopefully will bring it to the foreground
again.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2790>
This commit is contained in:
Florian Müllner 2023-05-19 19:02:08 +02:00 committed by Marge Bot
parent 6cf0df5fb9
commit dec26b7da2

View File

@ -34,8 +34,6 @@ var BackgroundAppMenuItem = GObject.registerClass({
delete params.message;
super._init(app.get_name(), app.get_icon(), {
activate: false,
reactive: false,
...params,
});
@ -93,6 +91,8 @@ var BackgroundAppMenuItem = GObject.registerClass({
closeButton.connect('clicked', () => this._quitApp().catch(logError));
this.connect('activate', () => this.app.activate());
this.connect('destroy', () => this._onDestroy());
}