|
|
@@ -78,11 +78,14 @@ void ElementTabSet::RemoveTab(int tab_index)
|
|
|
return;
|
|
|
|
|
|
Element* panels = GetChildByTag("panels");
|
|
|
- Element* tabs = GetChildByTag("tabs");
|
|
|
-
|
|
|
- if (panels->GetNumChildren() > tab_index && tabs->GetNumChildren() > tab_index)
|
|
|
+ if (panels->GetNumChildren() > tab_index)
|
|
|
{
|
|
|
panels->RemoveChild(panels->GetChild(tab_index));
|
|
|
+ }
|
|
|
+
|
|
|
+ Element* tabs = GetChildByTag("tabs");
|
|
|
+ if (tabs->GetNumChildren() > tab_index)
|
|
|
+ {
|
|
|
tabs->RemoveChild(tabs->GetChild(tab_index));
|
|
|
}
|
|
|
}
|