diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-03-01 19:13:11 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-03-01 19:13:11 +0300 |
commit | a260aeab234704ace8ba672b1d1ce57e18425e07 (patch) | |
tree | e215c6eeeae7e6c2ca4f4453718cef6ca9a8af6a /src/gui/windows/setupwindow.cpp | |
parent | 382067b05c4fe97bcf0da0143405375ec295f7c6 (diff) | |
parent | 2c62286a7ecf246e8a445dd7d00f618efae2a96a (diff) | |
download | plus-a260aeab234704ace8ba672b1d1ce57e18425e07.tar.gz plus-a260aeab234704ace8ba672b1d1ce57e18425e07.tar.bz2 plus-a260aeab234704ace8ba672b1d1ce57e18425e07.tar.xz plus-a260aeab234704ace8ba672b1d1ce57e18425e07.zip |
Merge branch 'master' into stable
Diffstat (limited to 'src/gui/windows/setupwindow.cpp')
-rw-r--r-- | src/gui/windows/setupwindow.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/gui/windows/setupwindow.cpp b/src/gui/windows/setupwindow.cpp index 0780865aa..2bcac85a5 100644 --- a/src/gui/windows/setupwindow.cpp +++ b/src/gui/windows/setupwindow.cpp @@ -44,6 +44,7 @@ #include "gui/widgets/tabs/setup_video.h" #include "gui/widgets/tabs/setup_visual.h" +#include "gui/widgets/button.h" #include "gui/widgets/label.h" #include "gui/widgets/tabbedarea.h" @@ -58,7 +59,7 @@ SetupWindow *setupWindow = nullptr; SetupWindow::SetupWindow() : // TRANSLATORS: setup window name Window(_("Setup"), false, nullptr, "setup.xml"), - gcn::ActionListener(), + ActionListener(), mTabs(), mModsTab(nullptr), mWindowsToReset(), @@ -112,7 +113,7 @@ void SetupWindow::postInit() mResetWindows = btn; } - mPanel->setDimension(gcn::Rectangle(5, 5, width - 10, height - 40)); + mPanel->setDimension(Rect(5, 5, width - 10, height - 40)); mPanel->enableScrollButtons(true); mTabs.push_back(new Setup_Video(this)); @@ -149,7 +150,7 @@ void SetupWindow::postInit() center(); - widgetResized(gcn::Event(nullptr)); + widgetResized(Event(nullptr)); setInGame(false); enableVisibleSound(true); } @@ -160,7 +161,7 @@ SetupWindow::~SetupWindow() mButtons.clear(); } -void SetupWindow::action(const gcn::ActionEvent &event) +void SetupWindow::action(const ActionEvent &event) { if (Game::instance()) Game::instance()->resetAdjustLevel(); @@ -260,16 +261,16 @@ void SetupWindow::setVisible(bool visible) Window::setVisible(visible); } -void SetupWindow::widgetResized(const gcn::Event &event) +void SetupWindow::widgetResized(const Event &event) { Window::widgetResized(event); - const gcn::Rectangle area = getChildrenArea(); + const Rect area = getChildrenArea(); int x = area.width; const int height = area.height; const int width = area.width; const int buttonPadding = getOption("buttonPadding", 5); - mPanel->setDimension(gcn::Rectangle(5, 5, width - 10, height - 40)); + mPanel->setDimension(Rect(5, 5, width - 10, height - 40)); FOR_EACH (std::vector<Button*>::iterator, it, mButtons) { Button *const btn = *it; |