From e18e3bdf005824b5875bda74053c116b6c4c059f Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 29 Jan 2012 15:41:25 +0300 Subject: Fix possible hiding methods issues. --- src/gui/widgets/setupitem.cpp | 10 +++++----- src/gui/widgets/vertcontainer.cpp | 6 +++--- src/gui/widgets/vertcontainer.h | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) (limited to 'src/gui/widgets') diff --git a/src/gui/widgets/setupitem.cpp b/src/gui/widgets/setupitem.cpp index 92ff625c2..059b05ba2 100644 --- a/src/gui/widgets/setupitem.cpp +++ b/src/gui/widgets/setupitem.cpp @@ -192,7 +192,7 @@ void SetupItemCheckBox::createControls() load(); mCheckBox = new CheckBox(mText, mValue != "0", mParent, mEventName); mWidget = mCheckBox; - mParent->getContainer()->add(mWidget); + mParent->getContainer()->add1(mWidget); mParent->addControl(this); mParent->addActionListener(this); mWidget->addActionListener(this); @@ -275,7 +275,7 @@ void SetupItemTextField::createControls() mHorizont->add(mTextField); mHorizont->add(mButton); - mParent->getContainer()->add(mHorizont, true, 4); + mParent->getContainer()->add2(mHorizont, true, 4); mParent->addControl(this); mParent->addControl(this, mEventName + "_EDIT"); mParent->addControl(this, mEventName + "_EDIT_OK"); @@ -398,7 +398,7 @@ void SetupItemIntTextField::createControls() mHorizont->add(mTextField); mHorizont->add(mButton); - mParent->getContainer()->add(mHorizont, true, 4); + mParent->getContainer()->add2(mHorizont, true, 4); mParent->addControl(this); mParent->addControl(this, mEventName + "_EDIT"); mParent->addControl(this, mEventName + "_EDIT_OK"); @@ -486,7 +486,7 @@ void SetupItemLabel::createControls() } mWidget = mLabel; - mParent->getContainer()->add(mWidget); + mParent->getContainer()->add1(mWidget); mParent->addControl(this); mParent->addActionListener(this); mWidget->addActionListener(this); @@ -568,7 +568,7 @@ void SetupItemDropDown::createControls() mHorizont->add(mLabel); mHorizont->add(mDropDown); - mParent->getContainer()->add(mHorizont, true, 4); + mParent->getContainer()->add2(mHorizont, true, 4); mParent->addControl(this); mParent->addActionListener(this); mWidget->addActionListener(this); diff --git a/src/gui/widgets/vertcontainer.cpp b/src/gui/widgets/vertcontainer.cpp index 42ae97802..0eb59c8f9 100644 --- a/src/gui/widgets/vertcontainer.cpp +++ b/src/gui/widgets/vertcontainer.cpp @@ -35,12 +35,12 @@ VertContainer::VertContainer(int verticalItemSize, bool resizable, addWidgetListener(this); } -void VertContainer::add(gcn::Widget *widget, int spacing) +void VertContainer::add1(gcn::Widget *widget, int spacing) { - add(widget, mResizable, spacing); + add2(widget, mResizable, spacing); } -void VertContainer::add(gcn::Widget *widget, bool resizable, int spacing) +void VertContainer::add2(gcn::Widget *widget, bool resizable, int spacing) { if (!widget) return; diff --git a/src/gui/widgets/vertcontainer.h b/src/gui/widgets/vertcontainer.h index 6e1305a06..9460c837e 100644 --- a/src/gui/widgets/vertcontainer.h +++ b/src/gui/widgets/vertcontainer.h @@ -39,10 +39,10 @@ class VertContainer : public Container, public gcn::WidgetListener VertContainer(int verticalItemSize, bool resizable = true, int leftSpacing = 0); - virtual void add(gcn::Widget *widget, bool resizable, + virtual void add2(gcn::Widget *widget, bool resizable, int spacing = -1); - virtual void add(gcn::Widget *widget, int spacing = -1); + virtual void add1(gcn::Widget *widget, int spacing = -1); virtual void clear(); -- cgit v1.2.3-70-g09d2 From 9ae83b4bb267c032f9499e80bc6b3bcd9fb37e71 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 29 Jan 2012 18:17:21 +0300 Subject: Fix code style. --- src/gui/widgets/vertcontainer.h | 2 +- src/mumblemanager.cpp | 1 - src/net/inventoryhandler.h | 2 +- src/net/manaserv/specialhandler.cpp | 4 ++-- src/net/messagein.cpp | 4 ++-- 5 files changed, 6 insertions(+), 7 deletions(-) (limited to 'src/gui/widgets') diff --git a/src/gui/widgets/vertcontainer.h b/src/gui/widgets/vertcontainer.h index 9460c837e..b4e43d31d 100644 --- a/src/gui/widgets/vertcontainer.h +++ b/src/gui/widgets/vertcontainer.h @@ -40,7 +40,7 @@ class VertContainer : public Container, public gcn::WidgetListener int leftSpacing = 0); virtual void add2(gcn::Widget *widget, bool resizable, - int spacing = -1); + int spacing = -1); virtual void add1(gcn::Widget *widget, int spacing = -1); diff --git a/src/mumblemanager.cpp b/src/mumblemanager.cpp index 766f4085e..14ca7d527 100644 --- a/src/mumblemanager.cpp +++ b/src/mumblemanager.cpp @@ -78,7 +78,6 @@ void MumbleManager::init() #if defined BSD4_4 return; #endif - if (mLinkedMem || !config.getBoolValue("enableMumble")) return; diff --git a/src/net/inventoryhandler.h b/src/net/inventoryhandler.h index 45f7c3028..642d6f1c1 100644 --- a/src/net/inventoryhandler.h +++ b/src/net/inventoryhandler.h @@ -58,7 +58,7 @@ class InventoryHandler //void changeCart() = 0; virtual void moveItem2(int source, int slot, int amount, - int destination) = 0; + int destination) = 0; // TODO: fix/remove me virtual size_t getSize(int type) const = 0; diff --git a/src/net/manaserv/specialhandler.cpp b/src/net/manaserv/specialhandler.cpp index 73fa864a3..c168afd7c 100644 --- a/src/net/manaserv/specialhandler.cpp +++ b/src/net/manaserv/specialhandler.cpp @@ -59,8 +59,8 @@ void SpecialHandler::useBeing(int id A_UNUSED, int level A_UNUSED, // TODO } -void SpecialHandler::usePos(int id A_UNUSED, int level A_UNUSED, int x A_UNUSED, - int y A_UNUSED) +void SpecialHandler::usePos(int id A_UNUSED, int level A_UNUSED, + int x A_UNUSED, int y A_UNUSED) { // TODO } diff --git a/src/net/messagein.cpp b/src/net/messagein.cpp index 6efc3ddfe..0547ed337 100644 --- a/src/net/messagein.cpp +++ b/src/net/messagein.cpp @@ -264,10 +264,10 @@ unsigned char *MessageIn::readBytes(int length) #ifdef ENABLEDEBUGLOG std::string str; - for (int f = 0;f < length; f ++) + for (int f = 0; f < length; f ++) str += strprintf ("%02x", (unsigned)buf[f]); str += " "; - for (int f = 0;f < length; f ++) + for (int f = 0; f < length; f ++) { if (buf[f]) str += strprintf ("%c", buf[f]); -- cgit v1.2.3-70-g09d2