summaryrefslogtreecommitdiffstats
path: root/scene/2d/touch_screen_button.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2024-05-14 18:10:05 +0200
committerRémi Verschelde <rverschelde@gmail.com>2024-05-14 18:10:05 +0200
commitc0d2464d6b176c8e22a592167748c92d0c42dd01 (patch)
treef40440e8760c7bafd95c2cb2346a976c6396db06 /scene/2d/touch_screen_button.cpp
parent882449f496cab29098e663c1ca57e9b525ed9987 (diff)
parentee79386f7b5620c3d1ed18d24de7b9a4731602d4 (diff)
downloadredot-engine-c0d2464d6b176c8e22a592167748c92d0c42dd01.tar.gz
Merge pull request #91939 from AThousandShips/pressed_sname
[Scene] Add `SceneStringNames::pressed`
Diffstat (limited to 'scene/2d/touch_screen_button.cpp')
-rw-r--r--scene/2d/touch_screen_button.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/scene/2d/touch_screen_button.cpp b/scene/2d/touch_screen_button.cpp
index f682471a48..ff409272c5 100644
--- a/scene/2d/touch_screen_button.cpp
+++ b/scene/2d/touch_screen_button.cpp
@@ -305,7 +305,7 @@ void TouchScreenButton::_press(int p_finger_pressed) {
get_viewport()->push_input(iea, true);
}
- emit_signal(SNAME("pressed"));
+ emit_signal(SceneStringName(pressed));
queue_redraw();
}
@@ -373,7 +373,7 @@ bool TouchScreenButton::_set(const StringName &p_name, const Variant &p_value) {
if (p_name == CoreStringName(normal)) { // Compatibility with Godot 3.x.
set_texture_normal(p_value);
return true;
- } else if (p_name == SNAME("pressed")) { // Compatibility with Godot 3.x.
+ } else if (p_name == SceneStringName(pressed)) { // Compatibility with Godot 3.x.
set_texture_pressed(p_value);
return true;
}