summaryrefslogtreecommitdiff
path: root/src/gui/widgets/tabbedarea.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-05-24 02:54:01 +0300
committerAndrei Karas <akaras@inbox.ru>2011-05-24 02:54:01 +0300
commita0b5f5fee9809670c2c9cf9b1f63ab2be11fd9fd (patch)
treeb666fed3ff9bdea61159190035d697ea562c4faa /src/gui/widgets/tabbedarea.cpp
parentd2c42029b98c665725768b891aa877eb3267664f (diff)
downloadplus-a0b5f5fee9809670c2c9cf9b1f63ab2be11fd9fd.tar.gz
plus-a0b5f5fee9809670c2c9cf9b1f63ab2be11fd9fd.tar.bz2
plus-a0b5f5fee9809670c2c9cf9b1f63ab2be11fd9fd.tar.xz
plus-a0b5f5fee9809670c2c9cf9b1f63ab2be11fd9fd.zip
Fix leaks in client, skilldialog and playerinfo classes.
Diffstat (limited to 'src/gui/widgets/tabbedarea.cpp')
-rw-r--r--src/gui/widgets/tabbedarea.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/gui/widgets/tabbedarea.cpp b/src/gui/widgets/tabbedarea.cpp
index da6dfb64c..6c2ef5b25 100644
--- a/src/gui/widgets/tabbedarea.cpp
+++ b/src/gui/widgets/tabbedarea.cpp
@@ -428,6 +428,20 @@ void TabbedArea::updateArrowEnableState()
}
}
+Tab *TabbedArea::getTabByIndex(int index) const
+{
+ if (index < 0 || index >= static_cast<int>(mTabs.size()))
+ return 0;
+ return static_cast<Tab*>(mTabs[index].first);
+}
+
+gcn::Widget *TabbedArea::getWidgetByIndex(int index) const
+{
+ if (index < 0 || index >= static_cast<int>(mTabs.size()))
+ return 0;
+ return mTabs[index].second;
+}
+
/*
void TabbedArea::moveLeft(gcn::Tab *tab)
{