diff options
author | Rindbee <idleman@yeah.net> | 2022-06-25 15:39:39 +0800 |
---|---|---|
committer | Rindbee <idleman@yeah.net> | 2022-06-25 15:39:39 +0800 |
commit | c10304415fbdaa079c817a37c242055e79ef4cc8 (patch) | |
tree | 92806cf1546657f766281ce5efd87cbaf3104772 /scene | |
parent | c87f9fe4cec15dcfa8ddb68e2de55d2bfab40d32 (diff) |
Fix ProgressBar's minimum size not updating when toggling its percent_visible
Diffstat (limited to 'scene')
-rw-r--r-- | scene/gui/progress_bar.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/scene/gui/progress_bar.cpp b/scene/gui/progress_bar.cpp index f36682942f..80859e8eb9 100644 --- a/scene/gui/progress_bar.cpp +++ b/scene/gui/progress_bar.cpp @@ -126,7 +126,11 @@ int ProgressBar::get_fill_mode() { } void ProgressBar::set_percent_visible(bool p_visible) { + if (percent_visible == p_visible) { + return; + } percent_visible = p_visible; + update_minimum_size(); update(); } |