|
@@ -206,6 +206,12 @@ void Control::set_custom_minimum_size(const Size2 &p_custom) {
|
|
if (p_custom == data.custom_minimum_size) {
|
|
if (p_custom == data.custom_minimum_size) {
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ if (isnan(p_custom.x) || isnan(p_custom.y)) {
|
|
|
|
+ // Prevent infinite loop.
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+
|
|
data.custom_minimum_size = p_custom;
|
|
data.custom_minimum_size = p_custom;
|
|
update_minimum_size();
|
|
update_minimum_size();
|
|
}
|
|
}
|