diff options
author | reduz <reduzio@gmail.com> | 2022-03-23 21:08:54 +0100 |
---|---|---|
committer | reduz <reduzio@gmail.com> | 2022-03-24 14:21:52 +0100 |
commit | 09b951b99b1a8e799b00adaa896c788949c18017 (patch) | |
tree | 4a81fb9584b90063c651758ba53b16462083fe66 /scene/gui | |
parent | d7d528c15f0e858b52bb0f510ff47e65c2341de1 (diff) | |
download | redot-engine-09b951b99b1a8e799b00adaa896c788949c18017.tar.gz |
Refactor Object metadata
* API kept the same (Although functions could be renamed to set_metadata/get_metadata in a later PR), so not much should change.
* Metadata now exposed as individual properties.
* Properties are editable in inspector (unless metadata name begins with _) under the metadata/ namespace.
* Added the ability to Add/Remove metadata properties to the inspector.
This is a functionality that was requested very often, that makes metadata work a bit more similar to custom properties in Blender.
Diffstat (limited to 'scene/gui')
-rw-r--r-- | scene/gui/dialogs.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/scene/gui/dialogs.cpp b/scene/gui/dialogs.cpp index e3744eedca..be57ca9084 100644 --- a/scene/gui/dialogs.cpp +++ b/scene/gui/dialogs.cpp @@ -93,6 +93,9 @@ void AcceptDialog::_notification(int p_what) { } void AcceptDialog::_text_submitted(const String &p_text) { + if (get_ok_button() && get_ok_button()->is_disabled()) { + return; // Do not allow submission if OK button is disabled. + } _ok_pressed(); } |