# HG changeset patch # User Goffi # Date 1546604429 -3600 # Node ID 15e47bbb192cc880d5baa5b8e0abfe8a7be13253 # Parent d535446fdf4520b851de4163c02917352a2dbeee about: show full version of SàT diff -r d535446fdf45 -r 15e47bbb192c cagou/core/cagou_main.py --- a/cagou/core/cagou_main.py Thu Jan 03 20:44:07 2019 +0100 +++ b/cagou/core/cagou_main.py Fri Jan 04 13:20:29 2019 +0100 @@ -389,6 +389,7 @@ self._plg_wids_transfer = [] # transfer widgets plugins self._import_plugins() self._visible_widgets = {} # visible widgets by classes + self.version = C.APP_VERSION # will be replaced by getVersion() @property def visible_widgets(self): @@ -428,8 +429,12 @@ else: sat_instance.stopService() + def _getVersionCb(self, version): + self.version = version + def onBackendReady(self): self.app.showWidget() + self.bridge.getVersion(callback=self._getVersionCb) self.postInit() def postInit(self, dummy=None): diff -r d535446fdf45 -r 15e47bbb192c cagou/core/menu.py --- a/cagou/core/menu.py Thu Jan 03 20:44:07 2019 +0100 +++ b/cagou/core/menu.py Fri Jan 04 13:20:29 2019 +0100 @@ -45,7 +45,7 @@ Cagou is part of the "Salut à Toi" project more informations at [color=5500ff][ref=website]salut-a-toi.org[/ref][/color] -""").format(version=C.APP_VERSION) +""") class AboutContent(Label): @@ -164,7 +164,8 @@ def onAbout(self): about = AboutPopup() about.title = ABOUT_TITLE - about.content = AboutContent(text=ABOUT_CONTENT, markup=True) + about.content = AboutContent(text=ABOUT_CONTENT.format(version=G.host.version), + markup=True) about.open()