From 18cba14c0f80f6ae7db883ce4d6abbf24728f07d Mon Sep 17 00:00:00 2001 From: Bjørn Lindeijer Date: Thu, 16 Apr 2009 22:32:39 +0200 Subject: Some more cleanups Nothing in particular worth mentioning. --- src/gui/widgets/tabbedarea.h | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) (limited to 'src/gui/widgets/tabbedarea.h') diff --git a/src/gui/widgets/tabbedarea.h b/src/gui/widgets/tabbedarea.h index b4fc1ded..6aaafe16 100644 --- a/src/gui/widgets/tabbedarea.h +++ b/src/gui/widgets/tabbedarea.h @@ -47,45 +47,45 @@ class TabbedArea : public gcn::TabbedArea void draw(gcn::Graphics *graphics); /** - * Return how many tabs have been created + * Return how many tabs have been created. + * + * @todo Remove this method when upgrading to Guichan 0.9.0 */ - int getNumberOfTabs(); + int getNumberOfTabs() const; /** - * Return tab with specified name as caption + * Return tab with specified name as caption. */ - Tab* getTab(const std::string &name); + Tab *getTab(const std::string &name) const; /** * Returns the widget with the tab that has specified caption */ - gcn::Widget* getWidget(const std::string &name); + gcn::Widget *getWidget(const std::string &name) const; + + using gcn::TabbedArea::addTab; /** - * Add a tab + * Add a tab. Overridden since it needs to create an instance of Tab + * instead of gcn::Tab. + * * @param caption The Caption to display * @param widget The widget to show when tab is selected */ void addTab(const std::string &caption, gcn::Widget *widget); /** - * Add a tab - * @param tab The tab - * @param widget The widget to display - */ - void addTab(Tab *tab, gcn::Widget *widget); - - /** - * Overload the remove tab function as its broken in guichan 0.8 + * Overload the remove tab function as it's broken in guichan 0.8. */ void removeTab(Tab *tab); /** - * Overload the logic function since it's broken in guichan 0.8 + * Overload the logic function since it's broken in guichan 0.8. */ void logic(); - int getContainerHeight() { return mWidgetContainer->getHeight(); } + int getContainerHeight() const + { return mWidgetContainer->getHeight(); } void setSelectedTab(unsigned int index) { gcn::TabbedArea::setSelectedTab(index); } -- cgit v1.2.3-70-g09d2