window-list: Expose workspace preview option

Now that we have the option, the window-list should expose it
in its preference window like the workspace-indicator.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/316>
This commit is contained in:
Florian Müllner
2024-03-21 17:27:09 +01:00
parent 69d8d1a335
commit 24ba03fe96

View File

@@ -81,6 +81,19 @@ class WindowListPrefsWidget extends Adw.PreferencesPage {
});
row.add_suffix(toggle);
miscGroup.add(row);
toggle = new Gtk.Switch({
action_name: 'window-list.embed-previews',
valign: Gtk.Align.CENTER,
});
this._settings.bind('embed-previews',
toggle, 'active', Gio.SettingsBindFlags.DEFAULT);
row = new Adw.ActionRow({
title: _('Show workspace previews'),
activatable_widget: toggle,
});
row.add_suffix(toggle);
miscGroup.add(row);
}
}