diff --git a/source/rafcon/gui/controllers/state_machines_editor.py b/source/rafcon/gui/controllers/state_machines_editor.py
index <HASH>..<HASH> 100644
--- a/source/rafcon/gui/controllers/state_machines_editor.py
+++ b/source/rafcon/gui/controllers/state_machines_editor.py
@@ -309,7 +309,8 @@ class StateMachinesEditorController(ExtendedController):
         :param state_machine_m: The selected state machine model.
         """
         from rafcon.core.singleton import state_machine_execution_engine, state_machine_manager
-        force = True if event is not None and event.state & SHIFT_MASK and event.state & CONTROL_MASK else force
+        force = True if event is not None and hasattr(event, 'state') and \
+                        event.state & SHIFT_MASK and event.state & CONTROL_MASK else force
 
         def push_sm_running_dialog():
force close state machine editor tabs: fix condition to be more robust
- before it was causing problems if used in the right-click menu