|
|
@@ -1,7 +1,7 @@
|
|
|
"""
|
|
|
Generated by Statechart compiler by Glenn De Jonghe, Joeri Exelmans, Simon Van Mierlo, and Yentl Van Tendeloo (for the inspiration)
|
|
|
|
|
|
-Date: Mon Oct 9 15:39:54 2017
|
|
|
+Date: Mon Oct 9 16:07:22 2017
|
|
|
|
|
|
Model author: Yentl Van Tendeloo
|
|
|
Model name: Modelverse Visual Editor - Tkinter Version
|
|
|
@@ -7187,6 +7187,8 @@ class Canvas(RuntimeClassBase, tk.Canvas, SCCDWidget):
|
|
|
|
|
|
# state /ready/process_events/creating_line/drawing
|
|
|
self.states["/ready/process_events/creating_line/drawing"] = State(6, "/ready/process_events/creating_line/drawing", self)
|
|
|
+ self.states["/ready/process_events/creating_line/drawing"].setEnter(self._ready_process_events_creating_line_drawing_enter)
|
|
|
+ self.states["/ready/process_events/creating_line/drawing"].setExit(self._ready_process_events_creating_line_drawing_exit)
|
|
|
|
|
|
# state /ready/process_events/creating_line/create_in_mv
|
|
|
self.states["/ready/process_events/creating_line/create_in_mv"] = State(7, "/ready/process_events/creating_line/create_in_mv", self)
|
|
|
@@ -7338,6 +7340,12 @@ class Canvas(RuntimeClassBase, tk.Canvas, SCCDWidget):
|
|
|
def _ready_process_events_creating_line_exit(self):
|
|
|
self.delete(self.tmp_line)
|
|
|
|
|
|
+ def _ready_process_events_creating_line_drawing_enter(self):
|
|
|
+ print("Drawing")
|
|
|
+
|
|
|
+ def _ready_process_events_creating_line_drawing_exit(self):
|
|
|
+ print("NOT drawing")
|
|
|
+
|
|
|
def _ready_process_events_creating_element_enter(self):
|
|
|
self.big_step.outputEventOM(Event("broad_cast", None, [self, Event("mv_request", None, ['instantiate', [current_model, self.currently_selected, None, '']])]))
|
|
|
self.elems.append([0, self.create_image(self.last_x, self.last_y, image=self.loading[0])])
|
|
|
@@ -7413,6 +7421,8 @@ class Canvas(RuntimeClassBase, tk.Canvas, SCCDWidget):
|
|
|
|
|
|
def _ready_process_events_creating_line_drawing_0_exec(self, parameters):
|
|
|
x, y, _, _ = self.coords(self.tmp_line)
|
|
|
+
|
|
|
+ # NOTE: make sure that you can not click on the temporary line itself
|
|
|
if x > self.last_x:
|
|
|
self.last_x += 2
|
|
|
else:
|
|
|
@@ -7424,7 +7434,6 @@ class Canvas(RuntimeClassBase, tk.Canvas, SCCDWidget):
|
|
|
self.last_y -= 2
|
|
|
|
|
|
self.coords(self.tmp_line, x, y, self.last_x, self.last_y)
|
|
|
- pass
|
|
|
|
|
|
def _ready_process_events_creating_line_drawing_1_exec(self, parameters):
|
|
|
ID = parameters[0]
|