* Forbid editor from applying changes when hidden
* Allow skip interaction when editor is hidden
This commit is contained in:
LoafyLemon 2022-05-27 16:23:37 +01:00
parent 1554cdd5d5
commit a4e953ecf3
2 changed files with 6 additions and 2 deletions

View File

@ -1,5 +1,5 @@
init -100 python:
init 1 python:
# Custom hotkeys
config.keymap = dict(
@ -153,7 +153,7 @@ init -100 python:
#director = director.Start(),
performance = ToggleScreen("_performance"),
accessibility = ShowMenu("preferences", page="accessibility"),
editor = ToggleScreen("editor"),
editor = [ToggleField(e, "active", True, False), ToggleScreen("editor")],
)
config.underlay = [ _default_keymap ]

View File

@ -13,8 +13,12 @@ init python:
self.active_expressions = _dict()
self.persistent_expressions = _dict()
self.last_expressions = _dict()
self.active = False
def catch(self, *args, **kwargs):
if not self.active:
return
global n # DEBUG
self.node = None
self.live_code = None