fix: missing lockscreen option during printing
This commit is contained in:
1 parent
66192b6936
commit
35c26ba4d4
2 files changed
+8
No files matched your search
@@ -91,3 +91,8 @@ name: {{ gettext('Pins') }}
|
||||
icon: hashtag
|
||||
panel: pins
|
||||
enable: {{ printer.output_pins.count > 0 or printer.pwm_tools.count > 0 }}
|
||||
|
||||
[menu __print lock]
|
||||
name: {{ gettext('Lock') }}
|
||||
icon: lock
|
||||
panel: lock_screen
|
||||
@@ -333,6 +333,9 @@ class KlipperScreen(Gtk.Window):
|
||||
def show_panel(self, panel, title=None, remove_all=False, panel_name=None, **kwargs):
|
||||
if panel_name is None:
|
||||
panel_name = panel
|
||||
if panel == "lock_screen":
|
||||
self.lock_screen.lock(None)
|
||||
return
|
||||
if self._cur_panels and panel_name == self._cur_panels[-1]:
|
||||
logging.error("Panel is already is in view")
|
||||
return
|
||||
|
||||
Reference in new issue
Block a user