Skip to content

Commit

Permalink
fix on selecting nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeremi360 committed Jan 15, 2022
1 parent 905a4ec commit 544c65d
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions addons/advanced-text/MarkupTextEditor/MarkupTextEditor.gd
Original file line number Diff line number Diff line change
Expand Up @@ -338,15 +338,11 @@ func _process(delta: float) -> void:
preview_tabs.visible = true
file_name_label.text = selected_node.name
toggle_nodes_mode()
_on_node_selected(selected_node)

# print("type", last_selected_node.get_class())

func _on_node_selected(node: Node):
if last_selected_node == node:
return

last_selected_node = node

if node is AdvancedTextLabel:
var _markup_str_id = node.markup

Expand Down Expand Up @@ -566,7 +562,7 @@ func _on_file_button_pressed(file_box: Node):
func _on_file_close_button_pressed(file_box: Node):
var f_data = files_ram[file_box]
var f_button = f_data["f_button"]
# todo add ask for save if text is changed
# todo add ask for save if text was changed
files_box.remove_child(file_box)
files_boxes.erase(file_box.name)
files_ram.erase(file_box)
Expand Down

0 comments on commit 544c65d

Please sign in to comment.