diff options
author | Jared Adams <jaxad0127@gmail.com> | 2009-03-10 09:35:26 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-03-10 09:35:26 -0600 |
commit | 3aa9e681e466b1596a99b0361277975476790c3f (patch) | |
tree | a3b2af3981cdd0b92b32f12875c7733805c1accb /src/gui | |
parent | 171198999b4290f3e2adadd019c8d914212ecf47 (diff) | |
download | mana-client-3aa9e681e466b1596a99b0361277975476790c3f.tar.gz mana-client-3aa9e681e466b1596a99b0361277975476790c3f.tar.bz2 mana-client-3aa9e681e466b1596a99b0361277975476790c3f.tar.xz mana-client-3aa9e681e466b1596a99b0361277975476790c3f.zip |
Allow NPCList dialog to use it's old location
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/npclistdialog.cpp | 2 | ||||
-rw-r--r-- | src/gui/window.cpp | 4 | ||||
-rw-r--r-- | src/gui/window.h | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/npclistdialog.cpp b/src/gui/npclistdialog.cpp index 94dfabeb..95fe5983 100644 --- a/src/gui/npclistdialog.cpp +++ b/src/gui/npclistdialog.cpp @@ -69,7 +69,7 @@ NpcListDialog::NpcListDialog(Network *network): layout.setRowHeight(0, Layout::AUTO_SET); loadWindowState(); - resetToDefaultSize(); + resetToDefaultSize(false); } int NpcListDialog::getNumberOfElements() diff --git a/src/gui/window.cpp b/src/gui/window.cpp index 48229ec8..8eaaf31d 100644 --- a/src/gui/window.cpp +++ b/src/gui/window.cpp @@ -490,9 +490,9 @@ void Window::setDefaultSize(int defaultX, int defaultY, mDefaultHeight = defaultHeight; } -void Window::resetToDefaultSize() +void Window::resetToDefaultSize(bool changePosition) { - setPosition(mDefaultX, mDefaultY); + if (changePosition) setPosition(mDefaultX, mDefaultY); setSize(mDefaultWidth, mDefaultHeight); } diff --git a/src/gui/window.h b/src/gui/window.h index 518de6e9..9977aff4 100644 --- a/src/gui/window.h +++ b/src/gui/window.h @@ -243,7 +243,7 @@ class Window : public gcn::Window, gcn::WidgetListener * Reset the win pos and size to default. Don't forget to set defaults * first. */ - void resetToDefaultSize(); + void resetToDefaultSize(bool changePosition = true); /** * Gets the layout handler for this window. |