diff --git a/src/desktops.py b/src/desktops.py new file mode 100644 index 0000000..6c2a70a --- /dev/null +++ b/src/desktops.py @@ -0,0 +1,14 @@ +desktops = [ + "Onyx", + "Gnome", + "Kde", + "Budgie", + "Mate", + "Cinnamon", + "Lxqt", + "Sway", + "i3-gaps", + "Herbstluftwm", + "Awesome", + "bspwm" +] diff --git a/src/meson.build b/src/meson.build index f925093..2d9d062 100644 --- a/src/meson.build +++ b/src/meson.build @@ -69,6 +69,7 @@ jade_gui_sources = [ 'main.py', 'window.py', 'keymaps.py', + 'desktops.py', ] install_data(jade_gui_sources, install_dir: moduledir) diff --git a/src/window.py b/src/window.py index 39e557e..0c624fc 100644 --- a/src/window.py +++ b/src/window.py @@ -35,6 +35,7 @@ from .functions.install_screen import InstallScreen from .functions.finished_screen import FinishedScreen from .locales.locales_list import locations from .keymaps import keymaps +from .desktops import desktops @Gtk.Template(resource_path='/al/getcryst/jadegui/window.ui') class JadeGuiWindow(Gtk.ApplicationWindow): @@ -96,13 +97,12 @@ class JadeGuiWindow(Gtk.ApplicationWindow): ### --------- ### Test desktops - desktop_test = DesktopEntry(window=self, desktop="GNOME", button_group=None, **kwargs) - desktop_test_two = DesktopEntry(window=self, desktop="Onyx", button_group=desktop_test.select_button, **kwargs) - desktop_test_three = DesktopEntry(window=self, desktop="KDE", button_group=desktop_test.select_button, **kwargs) - desktop_test.select_button.set_active(True) - self.desktop_screen.list_desktops.append(desktop_test) - self.desktop_screen.list_desktops.append(desktop_test_two) - self.desktop_screen.list_desktops.append(desktop_test_three) + onyx = DesktopEntry(window=self, desktop="Onyx", button_group=None, **kwargs) # Manually specifying onyx since the other entries need a button group to attach to + self.desktop_screen.list_desktops.append(onyx) + for desktop in desktops: + if desktop is not "Onyx": + print(desktop) + self.desktop_screen.list_desktops.append(DesktopEntry(window=self, desktop=desktop, button_group=onyx.select_button, **kwargs)) ### --------- ### Test partitions