left/right clicking in assignment context returns postits to the panel

This commit is contained in:
Adrian Schmid 2023-08-22 20:06:55 +02:00
parent 72efb61d28
commit 12c51f842b
1 changed files with 8 additions and 0 deletions

View File

@ -272,11 +272,19 @@ func _input(event):
selected_card_for_assignment += 1
elif event.is_action_pressed("ui_left"): # left to switch context to the left
if active_context == ui_context.ASSIGN_POST_IT:
_return_postit_to_panels(currently_selected_node)
_leave_assignment_context()
active_context -= 1
if active_context <= -1:
active_context = ui_context.POST_IT_LIST
elif event.is_action_pressed("ui_right"): # right to switch context to the right
if active_context == ui_context.ASSIGN_POST_IT:
_return_postit_to_panels(currently_selected_node)
_leave_assignment_context()
active_context += 1
if active_context > 1:
active_context = ui_context.DROPZONE