diff options
Diffstat (limited to 'scene')
-rw-r--r-- | scene/2d/animated_sprite.cpp | 2 | ||||
-rw-r--r-- | scene/2d/sprite.cpp | 2 | ||||
-rw-r--r-- | scene/gui/control.cpp | 2 | ||||
-rw-r--r-- | scene/main/viewport.cpp | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/scene/2d/animated_sprite.cpp b/scene/2d/animated_sprite.cpp index 4300c25e9f..ac24e4ee97 100644 --- a/scene/2d/animated_sprite.cpp +++ b/scene/2d/animated_sprite.cpp @@ -417,7 +417,7 @@ void AnimatedSprite::_notification(int p_what) { if (centered) ofs-=s/2; - if (OS::get_singleton()->get_use_pixel_snap()) { + if (Engine::get_singleton()->get_use_pixel_snap()) { ofs=ofs.floor(); } Rect2 dst_rect(ofs,s); diff --git a/scene/2d/sprite.cpp b/scene/2d/sprite.cpp index 8bad8fcb38..01aa99c6a4 100644 --- a/scene/2d/sprite.cpp +++ b/scene/2d/sprite.cpp @@ -86,7 +86,7 @@ void Sprite::_notification(int p_what) { Point2 ofs=offset; if (centered) ofs-=s/2; - if (OS::get_singleton()->get_use_pixel_snap()) { + if (Engine::get_singleton()->get_use_pixel_snap()) { ofs=ofs.floor(); } diff --git a/scene/gui/control.cpp b/scene/gui/control.cpp index 3322469397..2e6dd48442 100644 --- a/scene/gui/control.cpp +++ b/scene/gui/control.cpp @@ -1883,7 +1883,7 @@ void Control::show_modal(bool p_exclusive) { raise(); data.modal_exclusive=p_exclusive; data.MI=get_viewport()->_gui_show_modal(this); - data.modal_frame=OS::get_singleton()->get_frames_drawn(); + data.modal_frame=Engine::get_singleton()->get_frames_drawn(); } diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp index 30476b2f76..a7d259ef06 100644 --- a/scene/main/viewport.cpp +++ b/scene/main/viewport.cpp @@ -1830,7 +1830,7 @@ void Viewport::_gui_input_event(InputEvent p_event) { Vector2 pos = top->get_global_transform_with_canvas().affine_inverse().xform(mpos); if (!top->has_point(pos)) { - if (top->data.modal_exclusive || top->data.modal_frame==OS::get_singleton()->get_frames_drawn()) { + if (top->data.modal_exclusive || top->data.modal_frame==Engine::get_singleton()->get_frames_drawn()) { //cancel event, sorry, modal exclusive EATS UP ALL //alternative, you can't pop out a window the same frame it was made modal (fixes many issues) get_tree()->set_input_as_handled(); |