diff options
Diffstat (limited to 'editor/editor_feature_profile.cpp')
-rw-r--r-- | editor/editor_feature_profile.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/editor/editor_feature_profile.cpp b/editor/editor_feature_profile.cpp index 959507535b..e2b79efb43 100644 --- a/editor/editor_feature_profile.cpp +++ b/editor/editor_feature_profile.cpp @@ -153,7 +153,7 @@ Error EditorFeatureProfile::save_to_file(const String &p_path) { Array dis_props; - for (Map<StringName, Set<StringName> >::Element *E = disabled_properties.front(); E; E = E->next()) { + for (Map<StringName, Set<StringName>>::Element *E = disabled_properties.front(); E; E = E->next()) { for (Set<StringName>::Element *F = E->get().front(); F; F = F->next()) { dis_props.push_back(String(E->key()) + ":" + String(F->get())); } @@ -420,7 +420,7 @@ void EditorFeatureProfileManager::_profile_action(int p_action) { } break; case PROFILE_NEW: { - new_profile_dialog->popup_centered_minsize(); + new_profile_dialog->popup_centered(); new_profile_name->clear(); new_profile_name->grab_focus(); } break; @@ -430,7 +430,7 @@ void EditorFeatureProfileManager::_profile_action(int p_action) { ERR_FAIL_COND(selected == String()); erase_profile_dialog->set_text(vformat(TTR("Erase profile '%s'? (no undo)"), selected)); - erase_profile_dialog->popup_centered_minsize(); + erase_profile_dialog->popup_centered(); } break; } } @@ -485,7 +485,7 @@ void EditorFeatureProfileManager::_fill_classes_from(TreeItem *p_parent, const S bool disabled_editor = edited->is_class_editor_disabled(p_class); bool disabled_properties = edited->has_class_properties_disabled(p_class); if (disabled) { - class_item->set_custom_color(0, get_color("disabled_font_color", "Editor")); + class_item->set_custom_color(0, class_list->get_theme_color("disabled_font_color", "Editor")); } else if (disabled_editor && disabled_properties) { text += " " + TTR("(Editor Disabled, Properties Disabled)"); } else if (disabled_properties) { @@ -787,7 +787,7 @@ Ref<EditorFeatureProfile> EditorFeatureProfileManager::get_current_profile() { return current; } -EditorFeatureProfileManager *EditorFeatureProfileManager::singleton = NULL; +EditorFeatureProfileManager *EditorFeatureProfileManager::singleton = nullptr; void EditorFeatureProfileManager::_bind_methods() { @@ -805,7 +805,7 @@ EditorFeatureProfileManager::EditorFeatureProfileManager() { current_profile_name = memnew(LineEdit); name_hbc->add_child(current_profile_name); current_profile_name->set_editable(false); - current_profile_name->set_h_size_flags(SIZE_EXPAND_FILL); + current_profile_name->set_h_size_flags(Control::SIZE_EXPAND_FILL); profile_actions[PROFILE_CLEAR] = memnew(Button(TTR("Unset"))); name_hbc->add_child(profile_actions[PROFILE_CLEAR]); profile_actions[PROFILE_CLEAR]->set_disabled(true); @@ -815,7 +815,7 @@ EditorFeatureProfileManager::EditorFeatureProfileManager() { HBoxContainer *profiles_hbc = memnew(HBoxContainer); profile_list = memnew(OptionButton); - profile_list->set_h_size_flags(SIZE_EXPAND_FILL); + profile_list->set_h_size_flags(Control::SIZE_EXPAND_FILL); profiles_hbc->add_child(profile_list); profile_list->connect("item_selected", callable_mp(this, &EditorFeatureProfileManager::_profile_selected)); @@ -849,12 +849,12 @@ EditorFeatureProfileManager::EditorFeatureProfileManager() { main_vbc->add_margin_child(TTR("Available Profiles:"), profiles_hbc); h_split = memnew(HSplitContainer); - h_split->set_v_size_flags(SIZE_EXPAND_FILL); + h_split->set_v_size_flags(Control::SIZE_EXPAND_FILL); main_vbc->add_child(h_split); VBoxContainer *class_list_vbc = memnew(VBoxContainer); h_split->add_child(class_list_vbc); - class_list_vbc->set_h_size_flags(SIZE_EXPAND_FILL); + class_list_vbc->set_h_size_flags(Control::SIZE_EXPAND_FILL); class_list = memnew(Tree); class_list_vbc->add_margin_child(TTR("Enabled Classes:"), class_list, true); @@ -865,7 +865,7 @@ EditorFeatureProfileManager::EditorFeatureProfileManager() { VBoxContainer *property_list_vbc = memnew(VBoxContainer); h_split->add_child(property_list_vbc); - property_list_vbc->set_h_size_flags(SIZE_EXPAND_FILL); + property_list_vbc->set_h_size_flags(Control::SIZE_EXPAND_FILL); property_list = memnew(Tree); property_list_vbc->add_margin_child(TTR("Class Options"), property_list, true); @@ -891,7 +891,7 @@ EditorFeatureProfileManager::EditorFeatureProfileManager() { import_profiles = memnew(EditorFileDialog); add_child(import_profiles); - import_profiles->set_mode(EditorFileDialog::MODE_OPEN_FILES); + import_profiles->set_file_mode(EditorFileDialog::FILE_MODE_OPEN_FILES); import_profiles->add_filter("*.profile; " + TTR("Godot Feature Profile")); import_profiles->connect("files_selected", callable_mp(this, &EditorFeatureProfileManager::_import_profiles)); import_profiles->set_title(TTR("Import Profile(s)")); @@ -899,7 +899,7 @@ EditorFeatureProfileManager::EditorFeatureProfileManager() { export_profile = memnew(EditorFileDialog); add_child(export_profile); - export_profile->set_mode(EditorFileDialog::MODE_SAVE_FILE); + export_profile->set_file_mode(EditorFileDialog::FILE_MODE_SAVE_FILE); export_profile->add_filter("*.profile; " + TTR("Godot Feature Profile")); export_profile->connect("file_selected", callable_mp(this, &EditorFeatureProfileManager::_export_profile)); export_profile->set_title(TTR("Export Profile")); |