From 900d0302cd01fd31094380a016b142b0eab3c55d Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Thu, 18 Jul 2019 17:20:23 +1000 Subject: [PATCH] gui: remove duplicate active stack assignment --- tuhigui/window.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tuhigui/window.py b/tuhigui/window.py index ace7593..c07ca07 100644 --- a/tuhigui/window.py +++ b/tuhigui/window.py @@ -155,9 +155,8 @@ class MainWindow(Gtk.ApplicationWindow): dp = DrawingPerspective() self._add_perspective(dp) - active = dp self.headerbar.set_title(f'Tuhi') - self.stack_perspectives.set_visible_child_name(active.name) + self.stack_perspectives.set_visible_child_name(dp.name) if not self._tuhi.devices: dialog = SetupDialog(self._tuhi) @@ -166,7 +165,6 @@ class MainWindow(Gtk.ApplicationWindow): dialog.show() else: dp.device = self._tuhi.devices[0] - active = dp self.headerbar.set_title(f'Tuhi - {dp.device.name}') def _on_setup_dialog_closed(self, dialog, response):