diff options
author | kobewi <kobewi4e@gmail.com> | 2023-01-03 17:06:36 +0100 |
---|---|---|
committer | kobewi <kobewi4e@gmail.com> | 2023-01-03 17:06:36 +0100 |
commit | bf74ff94c8451de071a6a85f39ab37edc6ef431b (patch) | |
tree | cb59bca363d0440655cc3dc036632a8e4eaf2f86 | |
parent | 26bed8aa85fc2f98e38552a82929e1deb5b29d8a (diff) |
Improve remote tree node tooltips
-rw-r--r-- | editor/debugger/editor_debugger_tree.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/editor/debugger/editor_debugger_tree.cpp b/editor/debugger/editor_debugger_tree.cpp index 351af4508f..05f7dc9725 100644 --- a/editor/debugger/editor_debugger_tree.cpp +++ b/editor/debugger/editor_debugger_tree.cpp @@ -158,7 +158,11 @@ void EditorDebuggerTree::update_scene_tree(const SceneDebuggerTree *p_tree, int const SceneDebuggerTree::RemoteNode &node = p_tree->nodes[i]; TreeItem *item = create_item(parent); item->set_text(0, node.name); - item->set_tooltip_text(0, TTR("Type:") + " " + node.type_name); + if (node.scene_file_path.is_empty()) { + item->set_tooltip_text(0, node.name + "\n" + TTR("Type:") + " " + node.type_name); + } else { + item->set_tooltip_text(0, node.name + "\n" + TTR("Instance:") + " " + node.scene_file_path + "\n" + TTR("Type:") + " " + node.type_name); + } Ref<Texture2D> icon = EditorNode::get_singleton()->get_class_icon(node.type_name, ""); if (icon.is_valid()) { item->set_icon(0, icon); |