Add missing SNAME macro optimization in some function calls
This commit is contained in:
parent
fd0d2dcabf
commit
1ce81dc5f2
27 changed files with 217 additions and 217 deletions
|
|
@ -1723,15 +1723,15 @@ void AnimationTimelineEdit::update_values() {
|
|||
|
||||
switch (animation->get_loop_mode()) {
|
||||
case Animation::LoopMode::LOOP_NONE: {
|
||||
loop->set_icon(get_theme_icon("Loop", "EditorIcons"));
|
||||
loop->set_icon(get_theme_icon(SNAME("Loop"), SNAME("EditorIcons")));
|
||||
loop->set_pressed(false);
|
||||
} break;
|
||||
case Animation::LoopMode::LOOP_LINEAR: {
|
||||
loop->set_icon(get_theme_icon("Loop", "EditorIcons"));
|
||||
loop->set_icon(get_theme_icon(SNAME("Loop"), SNAME("EditorIcons")));
|
||||
loop->set_pressed(true);
|
||||
} break;
|
||||
case Animation::LoopMode::LOOP_PINGPONG: {
|
||||
loop->set_icon(get_theme_icon("PingPongLoop", "EditorIcons"));
|
||||
loop->set_icon(get_theme_icon(SNAME("PingPongLoop"), SNAME("EditorIcons")));
|
||||
loop->set_pressed(true);
|
||||
} break;
|
||||
default:
|
||||
|
|
@ -4516,7 +4516,7 @@ void AnimationTrackEditor::_notification(int p_what) {
|
|||
if (p_what == NOTIFICATION_THEME_CHANGED || p_what == NOTIFICATION_ENTER_TREE) {
|
||||
zoom_icon->set_texture(get_theme_icon(SNAME("Zoom"), SNAME("EditorIcons")));
|
||||
snap->set_icon(get_theme_icon(SNAME("Snap"), SNAME("EditorIcons")));
|
||||
view_group->set_icon(get_theme_icon(view_group->is_pressed() ? "AnimationTrackList" : "AnimationTrackGroup", "EditorIcons"));
|
||||
view_group->set_icon(get_theme_icon(view_group->is_pressed() ? SNAME("AnimationTrackList") : SNAME("AnimationTrackGroup"), SNAME("EditorIcons")));
|
||||
selected_filter->set_icon(get_theme_icon(SNAME("AnimationFilter"), SNAME("EditorIcons")));
|
||||
imported_anim_warning->set_icon(get_theme_icon(SNAME("NodeWarning"), SNAME("EditorIcons")));
|
||||
main_panel->add_theme_style_override("panel", get_theme_stylebox(SNAME("bg"), SNAME("Tree")));
|
||||
|
|
@ -5493,8 +5493,8 @@ void AnimationTrackEditor::_edit_menu_pressed(int p_option) {
|
|||
String text;
|
||||
Ref<Texture2D> icon = get_theme_icon(SNAME("Node"), SNAME("EditorIcons"));
|
||||
if (node) {
|
||||
if (has_theme_icon(node->get_class(), "EditorIcons")) {
|
||||
icon = get_theme_icon(node->get_class(), "EditorIcons");
|
||||
if (has_theme_icon(node->get_class(), SNAME("EditorIcons"))) {
|
||||
icon = get_theme_icon(node->get_class(), SNAME("EditorIcons"));
|
||||
}
|
||||
|
||||
text = node->get_name();
|
||||
|
|
@ -5907,7 +5907,7 @@ void AnimationTrackEditor::_cleanup_animation(Ref<Animation> p_animation) {
|
|||
|
||||
void AnimationTrackEditor::_view_group_toggle() {
|
||||
_update_tracks();
|
||||
view_group->set_icon(get_theme_icon(view_group->is_pressed() ? "AnimationTrackList" : "AnimationTrackGroup", "EditorIcons"));
|
||||
view_group->set_icon(get_theme_icon(view_group->is_pressed() ? SNAME("AnimationTrackList") : SNAME("AnimationTrackGroup"), SNAME("EditorIcons")));
|
||||
}
|
||||
|
||||
bool AnimationTrackEditor::is_grouping_tracks() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue