summaryrefslogtreecommitdiff
path: root/scene/gui
diff options
context:
space:
mode:
authorbesh81 <besh81@virgilio.it>2021-05-07 13:01:27 +0200
committerGitHub <noreply@github.com>2021-05-07 13:01:27 +0200
commite7e7aa7d1205038770ffe677422978d183a6a19f (patch)
treefc1f80f04a5c63a21b226738ad1a696f7fc2165e /scene/gui
parentbcbd480c32f7c9a6fdaad297ef1fbb8fa5fa12ee (diff)
Fixed bug in tab_container with hidden tabs
Fix a bug that occour when there are hidden tabs in tab_container. The visualization isn't correct due to missing values in tab_widths array.
Diffstat (limited to 'scene/gui')
-rw-r--r--scene/gui/tab_container.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/scene/gui/tab_container.cpp b/scene/gui/tab_container.cpp
index ff9dafa0f9..acf0641005 100644
--- a/scene/gui/tab_container.cpp
+++ b/scene/gui/tab_container.cpp
@@ -394,6 +394,7 @@ void TabContainer::_notification(int p_what) {
Vector<int> tab_widths;
for (int i = first_tab_cache; i < tabs.size(); i++) {
if (get_tab_hidden(i)) {
+ tab_widths.push_back(0);
continue;
}
int tab_width = _get_tab_width(i);