diff --git a/Userland/Libraries/LibGUI/TabWidget.h b/Userland/Libraries/LibGUI/TabWidget.h index 47a383a0a2d..835d29d04ba 100644 --- a/Userland/Libraries/LibGUI/TabWidget.h +++ b/Userland/Libraries/LibGUI/TabWidget.h @@ -73,6 +73,13 @@ public: return *t; } + ErrorOr add_tab(NonnullRefPtr const& tab, DeprecatedString title) + { + tab->set_title(move(title)); + TRY(try_add_widget(*tab)); + return {}; + } + void remove_tab(Widget& tab) { remove_widget(tab); } void remove_all_tabs_except(Widget& tab);