Improve Window's _validate_property()
This commit is contained in:
parent
1f787b63a5
commit
2ed4ed8cd0
1 changed files with 9 additions and 9 deletions
|
|
@ -236,15 +236,15 @@ void Window::_get_property_list(List<PropertyInfo> *p_list) const {
|
|||
}
|
||||
|
||||
void Window::_validate_property(PropertyInfo &p_property) const {
|
||||
if (p_property.name == "position" && initial_position != WINDOW_INITIAL_POSITION_ABSOLUTE) {
|
||||
p_property.usage = PROPERTY_USAGE_NONE;
|
||||
}
|
||||
|
||||
if (p_property.name == "current_screen" && initial_position != WINDOW_INITIAL_POSITION_CENTER_OTHER_SCREEN) {
|
||||
p_property.usage = PROPERTY_USAGE_NONE;
|
||||
}
|
||||
|
||||
if (p_property.name == "theme_type_variation") {
|
||||
if (p_property.name == "position") {
|
||||
if (initial_position != WINDOW_INITIAL_POSITION_ABSOLUTE) {
|
||||
p_property.usage = PROPERTY_USAGE_NONE;
|
||||
}
|
||||
} else if (p_property.name == "current_screen") {
|
||||
if (initial_position != WINDOW_INITIAL_POSITION_CENTER_OTHER_SCREEN) {
|
||||
p_property.usage = PROPERTY_USAGE_NONE;
|
||||
}
|
||||
} else if (p_property.name == "theme_type_variation") {
|
||||
List<StringName> names;
|
||||
|
||||
// Only the default theme and the project theme are used for the list of options.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue