summaryrefslogtreecommitdiff
path: root/src/gui/widgets/tabbedarea.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/tabbedarea.cpp')
-rw-r--r--src/gui/widgets/tabbedarea.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gui/widgets/tabbedarea.cpp b/src/gui/widgets/tabbedarea.cpp
index 2de812ed..681f99ec 100644
--- a/src/gui/widgets/tabbedarea.cpp
+++ b/src/gui/widgets/tabbedarea.cpp
@@ -80,6 +80,14 @@ gcn::Widget *TabbedArea::getCurrentWidget()
return NULL;
}
+void TabbedArea::addTab(gcn::Tab* tab, gcn::Widget* widget)
+{
+ int width = getWidth() - 2 * getFrameSize();
+ int height = getHeight() - 2 * getFrameSize() - mTabContainer->getHeight();
+ widget->setSize(width, height);
+ gcn::TabbedArea::addTab(tab, widget);
+}
+
void TabbedArea::addTab(const std::string &caption, gcn::Widget *widget)
{
Tab *tab = new Tab;