summaryrefslogtreecommitdiffstats
path: root/editor/scene_tree_editor.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2022-02-08 10:14:58 +0100
committerRémi Verschelde <rverschelde@gmail.com>2022-02-08 10:17:25 +0100
commitfc076ece3ddecd44a62dc0febed7baee47f2eede (patch)
tree6401f0a7ae1b39d516f86a0a44cd7c14aec569a6 /editor/scene_tree_editor.cpp
parent0154ce2c8d66528d617e10b139640fd4c4405c6b (diff)
downloadredot-engine-fc076ece3ddecd44a62dc0febed7baee47f2eede.tar.gz
Revert "Add missing SNAME macro optimization to all theme methods call"
This reverts commit a988fad9a092053434545c32afae91ccbdfbe792. As discussed in #57725 and clarified in #57788, `SNAME` is not meant to be used everywhere but only in critical code paths. For theme methods specifically, it was by design that only getters use `SNAME` and not setters.
Diffstat (limited to 'editor/scene_tree_editor.cpp')
-rw-r--r--editor/scene_tree_editor.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/scene_tree_editor.cpp b/editor/scene_tree_editor.cpp
index ddf7d8c465..e9aed53b4e 100644
--- a/editor/scene_tree_editor.cpp
+++ b/editor/scene_tree_editor.cpp
@@ -1219,7 +1219,7 @@ SceneTreeEditor::SceneTreeEditor(bool p_label, bool p_can_rename, bool p_can_ope
tree->set_begin(Point2(0, p_label ? 18 : 0));
tree->set_end(Point2(0, 0));
tree->set_allow_reselect(true);
- tree->add_theme_constant_override(SNAME("button_margin"), 0);
+ tree->add_theme_constant_override("button_margin", 0);
add_child(tree);
@@ -1324,7 +1324,7 @@ SceneTreeDialog::SceneTreeDialog() {
filter->set_h_size_flags(Control::SIZE_EXPAND_FILL);
filter->set_placeholder(TTR("Filter nodes"));
filter->set_clear_button_enabled(true);
- filter->add_theme_constant_override(SNAME("minimum_character_width"), 0);
+ filter->add_theme_constant_override("minimum_character_width", 0);
filter->connect("text_changed", callable_mp(this, &SceneTreeDialog::_filter_changed));
vbc->add_child(filter);