diff options
Diffstat (limited to 'scene/2d/line_2d.cpp')
-rw-r--r-- | scene/2d/line_2d.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/scene/2d/line_2d.cpp b/scene/2d/line_2d.cpp index 58dad40403..3a9473d76c 100644 --- a/scene/2d/line_2d.cpp +++ b/scene/2d/line_2d.cpp @@ -30,7 +30,6 @@ #include "line_2d.h" -#include "core/core_string_names.h" #include "core/math/geometry_2d.h" #include "line_builder.h" @@ -89,14 +88,14 @@ float Line2D::get_width() const { void Line2D::set_curve(const Ref<Curve> &p_curve) { // Cleanup previous connection if any if (_curve.is_valid()) { - _curve->disconnect(CoreStringNames::get_singleton()->changed, callable_mp(this, &Line2D::_curve_changed)); + _curve->disconnect_changed(callable_mp(this, &Line2D::_curve_changed)); } _curve = p_curve; // Connect to the curve so the line will update when it is changed if (_curve.is_valid()) { - _curve->connect(CoreStringNames::get_singleton()->changed, callable_mp(this, &Line2D::_curve_changed)); + _curve->connect_changed(callable_mp(this, &Line2D::_curve_changed)); } queue_redraw(); @@ -159,14 +158,14 @@ Color Line2D::get_default_color() const { void Line2D::set_gradient(const Ref<Gradient> &p_gradient) { // Cleanup previous connection if any if (_gradient.is_valid()) { - _gradient->disconnect(CoreStringNames::get_singleton()->changed, callable_mp(this, &Line2D::_gradient_changed)); + _gradient->disconnect_changed(callable_mp(this, &Line2D::_gradient_changed)); } _gradient = p_gradient; // Connect to the gradient so the line will update when the Gradient is changed if (_gradient.is_valid()) { - _gradient->connect(CoreStringNames::get_singleton()->changed, callable_mp(this, &Line2D::_gradient_changed)); + _gradient->connect_changed(callable_mp(this, &Line2D::_gradient_changed)); } queue_redraw(); |