fixme: setting on stage property of board children when stage is set
This commit is contained in:
parent
7fb7be47a8
commit
aa34c2e93a
|
|
@ -5,13 +5,18 @@ enum ui_context {DROPZONE, POST_IT_LIST, ASSIGN_POST_IT}
|
|||
|
||||
var has_stage = false:
|
||||
set(focus):
|
||||
if focus != has_stage:
|
||||
if focus:
|
||||
has_stage = true
|
||||
self.mouse_filter = Control.MOUSE_FILTER_PASS
|
||||
else:
|
||||
has_stage = false
|
||||
self.mouse_filter = Control.MOUSE_FILTER_IGNORE
|
||||
if is_node_ready():
|
||||
#fixme: thie should be replaced by a reference that holds all children ...
|
||||
for child in dropzone.get_children():
|
||||
child.on_stage = has_stage
|
||||
for child in postit_container.get_children():
|
||||
child.get_child(1).on_stage = has_stage
|
||||
|
||||
@onready var dropzone = $HBoxContainer/dropzone
|
||||
@onready var postit_container = $HBoxContainer/ScrollContainer/VBoxContainer
|
||||
|
|
@ -36,6 +41,7 @@ func _ready():
|
|||
reorder_areas("dropzone_content")
|
||||
active_context = ui_context.DROPZONE
|
||||
|
||||
has_stage = has_stage
|
||||
|
||||
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
func _process(delta):
|
||||
|
|
|
|||
Loading…
Reference in New Issue