diff options
author | Yuri Sizov <yuris@humnom.net> | 2022-08-08 19:29:36 +0300 |
---|---|---|
committer | Yuri Sizov <yuris@humnom.net> | 2022-08-26 19:23:05 +0300 |
commit | 6320a0fc18fa84363494df9013b65011a3018a62 (patch) | |
tree | 1e93dc743f3f5454918229ba0b6ec2d73ca86feb /editor/plugins/theme_editor_preview.cpp | |
parent | c8ef12a03a81c931480be41739ba5789415c4675 (diff) |
Add ThemeDB, expose previously static Theme methods
Diffstat (limited to 'editor/plugins/theme_editor_preview.cpp')
-rw-r--r-- | editor/plugins/theme_editor_preview.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/editor/plugins/theme_editor_preview.cpp b/editor/plugins/theme_editor_preview.cpp index b5c6c6d651..9a32e9317c 100644 --- a/editor/plugins/theme_editor_preview.cpp +++ b/editor/plugins/theme_editor_preview.cpp @@ -40,6 +40,7 @@ #include "scene/gui/color_picker.h" #include "scene/gui/progress_bar.h" #include "scene/resources/packed_scene.h" +#include "scene/theme/theme_db.h" constexpr double REFRESH_TIMER = 1.5; @@ -240,7 +241,7 @@ ThemeEditorPreview::ThemeEditorPreview() { MarginContainer *preview_root = memnew(MarginContainer); preview_container->add_child(preview_root); - preview_root->set_theme(Theme::get_default()); + preview_root->set_theme(ThemeDB::get_singleton()->get_default_theme()); preview_root->set_clip_contents(true); preview_root->set_custom_minimum_size(Size2(450, 0) * EDSCALE); preview_root->set_v_size_flags(SIZE_EXPAND_FILL); |