diff options
Diffstat (limited to 'editor/property_editor.cpp')
-rw-r--r-- | editor/property_editor.cpp | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/editor/property_editor.cpp b/editor/property_editor.cpp index 666bfa20b5..5ff5e680f6 100644 --- a/editor/property_editor.cpp +++ b/editor/property_editor.cpp @@ -116,7 +116,6 @@ void CustomPropertyEditor::_menu_option(int p_which) { Set<String> valid_extensions; for (List<String>::Element *E = extensions.front(); E; E = E->next()) { - print_line("found: " + E->get()); valid_extensions.insert(E->get()); } @@ -2770,10 +2769,7 @@ TreeItem *PropertyEditor::get_parent_node(String p_path, HashMap<String, TreeIte item = tree->create_item(parent); String name = (p_path.find("/") != -1) ? p_path.right(p_path.find_last("/") + 1) : p_path; - if (capitalize_paths) - item->set_text(0, name.capitalize()); - else - item->set_text(0, name); + item->set_text(0, capitalize_paths ? name.capitalize() : name); item->set_tooltip(0, p_path); if (item->get_parent() != root) { item->set_icon(0, get_icon("Folder", "EditorIcons")); @@ -3406,6 +3402,13 @@ void PropertyEditor::update_tree() { item->set_icon(0, get_icon("ArrayData", "EditorIcons")); } break; + case Variant::DICTIONARY: { + + item->set_cell_mode(1, TreeItem::CELL_MODE_STRING); + item->set_editable(1, false); + item->set_text(1, obj->get(p.name).operator String()); + + } break; case Variant::POOL_INT_ARRAY: { @@ -4299,9 +4302,15 @@ String PropertyEditor::get_selected_path() const { return ""; } -void PropertyEditor::set_capitalize_paths(bool p_capitalize) { +bool PropertyEditor::is_capitalize_paths_enabled() const { + + return capitalize_paths; +} + +void PropertyEditor::set_enable_capitalize_paths(bool p_capitalize) { capitalize_paths = p_capitalize; + update_tree_pending = true; } void PropertyEditor::set_autoclear(bool p_enable) { |