Fixes an issue with calculating the hover stack which resulted in #324
Fixes #324 Co-authored-by: Dennis Ploeger <develop@dieploegers.de> Co-authored-by: dploeger <dploeger@users.noreply.github.com>
This commit is contained in:
@@ -315,7 +315,7 @@ func _ev_left_click_on_item(obj, event, default_action = false):
|
||||
"arrived"
|
||||
)
|
||||
|
||||
self.logger.info("Context arrived: ", [context])
|
||||
self.logger.info("Context arrived: %s" % var2str(context))
|
||||
|
||||
if context.target_object and \
|
||||
context.target_object.global_id != walk_context.\
|
||||
|
||||
@@ -120,9 +120,9 @@ func _on_mouse_entered_item(item: ESCItem) -> void:
|
||||
escoria.logger.info("Item focused: ", [item.global_id])
|
||||
_clean_hover_stack()
|
||||
|
||||
if !hover_stack.empty():
|
||||
if item.z_index > hover_stack.back().z_index:
|
||||
hover_stack.insert(hover_stack.size()-1, item)
|
||||
if not hover_stack.empty():
|
||||
if item.z_index < hover_stack.back().z_index:
|
||||
hover_stack.insert(hover_stack.size() - 1, item)
|
||||
else:
|
||||
hover_stack.push_back(item)
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user