diff --git a/src/manjaro-hello.glade b/src/manjaro-hello.glade index f62a5ac..647466f 100644 --- a/src/manjaro-hello.glade +++ b/src/manjaro-hello.glade @@ -41,6 +41,11 @@ + + True + False + go-home + True False @@ -59,7 +64,6 @@ False - True False True stack @@ -674,6 +678,16 @@ We, the Manjaro Developers, hope that you will enjoy using Manjaro as much as we False Manjaro Hello True + + + home + True + True + True + homeicon + + + True @@ -684,7 +698,7 @@ We, the Manjaro Developers, hope that you will enjoy using Manjaro as much as we - 1 + 2 diff --git a/src/manjaro-hello.py b/src/manjaro-hello.py index 24cb7e8..5f77957 100644 --- a/src/manjaro-hello.py +++ b/src/manjaro-hello.py @@ -14,6 +14,8 @@ from gi.repository import Gtk class ManjaroHello(): def __init__(self): # App vars + args = str(sys.argv) + self.menu = True if "--menu" in args else False self.app = "manjaro-hello" self.urls = { "wiki": "https://wiki.manjaro.org", @@ -77,6 +79,11 @@ class ManjaroHello(): # Save locale used in config file self.save_preferences() + # Set menu + if self.menu: + self.builder.get_object("sidebar").set_visible(True) + self.builder.get_object("home").set_visible(False) + # Set window subtitle if self.infos["codename"] and self.infos["release"]: self.builder.get_object("headerbar").props.subtitle = self.infos["codename"] + " " + self.infos["release"] + " " @@ -201,7 +208,9 @@ class ManjaroHello(): def on_action_btn_clicked(self, btn): name = btn.get_name() - if name == "readme": + if name == "home": + self.builder.get_object("stack").set_visible_child(self.builder.get_object("welcome")) + elif name == "readme": self.builder.get_object("stack").set_visible_child(self.builder.get_object("documentation")) self.builder.get_object("documentation").set_current_page(0) elif name == "release":