diff options
Diffstat (limited to 'scene/gui/dialogs.cpp')
-rw-r--r-- | scene/gui/dialogs.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/scene/gui/dialogs.cpp b/scene/gui/dialogs.cpp index b911a18312..140d002387 100644 --- a/scene/gui/dialogs.cpp +++ b/scene/gui/dialogs.cpp @@ -3,7 +3,7 @@ /*************************************************************************/ /* This file is part of: */ /* GODOT ENGINE */ -/* http://www.godotengine.org */ +/* https://godotengine.org */ /*************************************************************************/ /* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ /* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ @@ -60,13 +60,13 @@ void WindowDialog::_fix_size() { float right = 0; // Check validity, because the theme could contain a different type of StyleBox if (panel->get_class() == "StyleBoxTexture") { - Ref<StyleBoxTexture> panel_texture = panel->cast_to<StyleBoxTexture>(); + Ref<StyleBoxTexture> panel_texture = Object::cast_to<StyleBoxTexture>(*panel); top = panel_texture->get_expand_margin_size(MARGIN_TOP); left = panel_texture->get_expand_margin_size(MARGIN_LEFT); bottom = panel_texture->get_expand_margin_size(MARGIN_BOTTOM); right = panel_texture->get_expand_margin_size(MARGIN_RIGHT); } else if (panel->get_class() == "StyleBoxFlat") { - Ref<StyleBoxFlat> panel_flat = panel->cast_to<StyleBoxFlat>(); + Ref<StyleBoxFlat> panel_flat = Object::cast_to<StyleBoxFlat>(*panel); top = panel_flat->get_expand_margin_size(MARGIN_TOP); left = panel_flat->get_expand_margin_size(MARGIN_LEFT); bottom = panel_flat->get_expand_margin_size(MARGIN_BOTTOM); @@ -424,7 +424,7 @@ void AcceptDialog::_update_child_rects() { Vector2 csize(size.x - margin * 2, size.y - margin * 3 - hminsize.y - label_size.height); for (int i = 0; i < get_child_count(); i++) { - Control *c = get_child(i)->cast_to<Control>(); + Control *c = Object::cast_to<Control>(get_child(i)); if (!c) continue; @@ -448,7 +448,7 @@ Size2 AcceptDialog::get_minimum_size() const { Size2 minsize = label->get_combined_minimum_size(); for (int i = 0; i < get_child_count(); i++) { - Control *c = get_child(i)->cast_to<Control>(); + Control *c = Object::cast_to<Control>(get_child(i)); if (!c) continue; |