Fix code completion popup colors not being updated properly

This commit is contained in:
Michael Alexsander 2026-01-23 18:34:42 -03:00
parent 3172d44799
commit 4eafa3c587
No known key found for this signature in database
GPG key ID: A9C91EE110F4EABA
4 changed files with 18 additions and 26 deletions

View file

@ -1843,6 +1843,15 @@ void ScriptEditor::_notification(int p_what) {
}
} break;
case EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED: {
if (EditorThemeManager::is_generated_theme_outdated() ||
EditorSettings::get_singleton()->check_changed_settings_in_group("interface/editor") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("text_editor") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("docks/filesystem")) {
_apply_editor_settings();
}
} break;
case NOTIFICATION_READY: {
// Can't set own styles in NOTIFICATION_THEME_CHANGED, so for now this will do.
add_theme_style_override(SceneStringName(panel), get_theme_stylebox(SNAME("ScriptEditorPanel"), EditorStringName(EditorStyles)));
@ -1863,7 +1872,6 @@ void ScriptEditor::_notification(int p_what) {
script_split->connect("dragged", callable_mp(this, &ScriptEditor::_split_dragged));
list_split->connect("dragged", callable_mp(this, &ScriptEditor::_split_dragged));
EditorSettings::get_singleton()->connect("settings_changed", callable_mp(this, &ScriptEditor::_editor_settings_changed));
EditorFileSystem::get_singleton()->connect("filesystem_changed", callable_mp(this, &ScriptEditor::_filesystem_changed));
#ifdef ANDROID_ENABLED
set_process(true);
@ -3051,17 +3059,6 @@ void ScriptEditor::_save_layout() {
EditorNode::get_singleton()->save_editor_layout_delayed();
}
void ScriptEditor::_editor_settings_changed() {
if (!EditorThemeManager::is_generated_theme_outdated() &&
!EditorSettings::get_singleton()->check_changed_settings_in_group("interface/editor") &&
!EditorSettings::get_singleton()->check_changed_settings_in_group("text_editor") &&
!EditorSettings::get_singleton()->check_changed_settings_in_group("docks/filesystem")) {
return;
}
_apply_editor_settings();
}
void ScriptEditor::_apply_editor_settings() {
textfile_extensions.clear();
const Vector<String> textfile_ext = ((String)(EDITOR_GET("docks/filesystem/textfile_extensions"))).split(",", false);