CtrlClickMessage class, will use later.

This commit is contained in:
Ozbolt Menegatti 2020-01-02 10:38:06 +01:00
parent 3c8f12243c
commit 1e612fb2a0

View File

@ -49,3 +49,23 @@ class ModalNotOkClose(Reset):
return False return False
# Special message to handle ctrl+click and click
# overwrite update_model_noctrl and/or update_model_ctrl
class CtrlClickMessage(ClickMessage):
def on_event(self, event):
super().on_event(event)
self.ctrl = event.ctrlKey
def update_model(self, model):
if self.ctrl:
self.update_model_ctrl(model)
else:
self.update_model_noctrl(model)
def update_model_ctrl(self, model):
pass
def update_model_noctrl(self, model):
pass