Make use of a theme cache in EditorHelp and ensure it's updated

- Migrates the existing cache to the standard theme cache struct
- Moves some parts of the codebase to use cache instead of ad-hoc fetching
- Adds hooks to editor settings previously missing from theme regeneration
This commit is contained in:
Yuri Sizov
2023-02-11 16:29:44 +01:00
parent 44b41ded82
commit bbbcd77217
3 changed files with 217 additions and 203 deletions

View File

@@ -691,10 +691,11 @@ void EditorNode::_notification(int p_what) {
bool theme_changed =
EditorSettings::get_singleton()->check_changed_settings_in_group("interface/theme") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("text_editor/theme") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("interface/editor/font") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("interface/editor/main_font") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("interface/editor/code_font") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("text_editor/theme") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("text_editor/help/help") ||
EditorSettings::get_singleton()->check_changed_settings_in_group("filesystem/file_dialog/thumbnail_size");
if (theme_changed) {