Browse Source

CollisionShape2D: Fix warning icon not updating.

`CollisionPolygon2D` also had this problem.

(cherry picked from commit 16eee2f59b6d2567d7d15d9a2ff66c52e9705137)
Andreas Haas 8 năm trước cách đây
mục cha
commit
1eb9925f58
2 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 1 0
      scene/2d/collision_polygon_2d.cpp
  2. 1 0
      scene/2d/collision_shape_2d.cpp

+ 1 - 0
scene/2d/collision_polygon_2d.cpp

@@ -243,6 +243,7 @@ void CollisionPolygon2D::set_polygon(const Vector<Point2>& p_polygon) {
 		_update_parent();
 	}
 	update();
+	update_configuration_warning();
 }
 
 Vector<Point2> CollisionPolygon2D::get_polygon() const {

+ 1 - 0
scene/2d/collision_shape_2d.cpp

@@ -159,6 +159,7 @@ void CollisionShape2D::set_shape(const Ref<Shape2D>& p_shape) {
 	if (shape.is_valid())
 		shape->connect("changed",this,"_shape_changed");
 
+	update_configuration_warning();
 }
 
 Ref<Shape2D> CollisionShape2D::get_shape() const {