summaryrefslogtreecommitdiff
path: root/scene
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2021-12-07 22:38:26 +0100
committerGitHub <noreply@github.com>2021-12-07 22:38:26 +0100
commitff118d7a88f56bce1f35a0c700521b0c63cec32c (patch)
tree556b37363063b85ef98159636a9740101e890e78 /scene
parent46d384060ef20672e23b3c1ffe947ff7898ecf75 (diff)
parent083ff9a1331132df54f689c15f533b21007c99d7 (diff)
Merge pull request #55706 from jmb462/fix-bad-control-wrap_mouse-offset
Fix bad mouse offset with Control::wrap_mouse()
Diffstat (limited to 'scene')
-rw-r--r--scene/gui/control.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/gui/control.cpp b/scene/gui/control.cpp
index fd6fb48412..3a926b3fb5 100644
--- a/scene/gui/control.cpp
+++ b/scene/gui/control.cpp
@@ -2590,7 +2590,7 @@ Control *Control::get_focus_owner() const {
void Control::warp_mouse(const Point2 &p_to_pos) {
ERR_FAIL_COND(!is_inside_tree());
- get_viewport()->warp_mouse(get_screen_transform().xform(p_to_pos));
+ get_viewport()->warp_mouse(get_global_transform().xform(p_to_pos));
}
bool Control::is_text_field() const {