diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-10-18 20:23:35 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-10-19 15:12:21 +0300 |
commit | 0d5c5aa4e8f66c36d5f78d0da449ee6becdb8298 (patch) | |
tree | 8b11537e1fd9c1c37f90d0d52ce94f3221dc9851 /src | |
parent | a0097fcc8d5b2ca32b6b346d6b06156f4d0c459c (diff) | |
download | plus-0d5c5aa4e8f66c36d5f78d0da449ee6becdb8298.tar.gz plus-0d5c5aa4e8f66c36d5f78d0da449ee6becdb8298.tar.bz2 plus-0d5c5aa4e8f66c36d5f78d0da449ee6becdb8298.tar.xz plus-0d5c5aa4e8f66c36d5f78d0da449ee6becdb8298.zip |
move virtual member calls from quitdialog constuctor into postInit.
Diffstat (limited to 'src')
-rw-r--r-- | src/actionmanager.cpp | 1 | ||||
-rw-r--r-- | src/gui/windows/quitdialog.cpp | 5 | ||||
-rw-r--r-- | src/gui/windows/quitdialog.h | 2 |
3 files changed, 7 insertions, 1 deletions
diff --git a/src/actionmanager.cpp b/src/actionmanager.cpp index 01137c2f6..d415f93ab 100644 --- a/src/actionmanager.cpp +++ b/src/actionmanager.cpp @@ -332,6 +332,7 @@ impHandler0(quit) else if (!quitDialog) { quitDialog = new QuitDialog(&quitDialog); + quitDialog->postInit(); quitDialog->requestMoveToTop(); return true; } diff --git a/src/gui/windows/quitdialog.cpp b/src/gui/windows/quitdialog.cpp index 0eeece318..03a7697db 100644 --- a/src/gui/windows/quitdialog.cpp +++ b/src/gui/windows/quitdialog.cpp @@ -114,8 +114,11 @@ QuitDialog::QuitDialog(QuitDialog **const pointerToMe): placer = getPlacer(0, 1); placer(1, 0, mOkButton, 1); placer(2, 0, mCancelButton, 1); - reflowLayout(200, 0); +} + +void QuitDialog::postInit() +{ setLocationRelativeTo(getParent()); setVisible(true); soundManager.playGuiSound(SOUND_SHOW_WINDOW); diff --git a/src/gui/windows/quitdialog.h b/src/gui/windows/quitdialog.h index efbdc586d..db08fa815 100644 --- a/src/gui/windows/quitdialog.h +++ b/src/gui/windows/quitdialog.h @@ -56,6 +56,8 @@ class QuitDialog final : public Window, public gcn::ActionListener, */ ~QuitDialog(); + void postInit(); + /** * Called when receiving actions from the widgets. */ |