diff options
author | Ira Rice <irarice@gmail.com> | 2009-03-10 11:50:27 -0600 |
---|---|---|
committer | Ira Rice <irarice@gmail.com> | 2009-03-10 11:50:27 -0600 |
commit | 58ee835c3763e7bf088fa6c7e31dda1d687589cc (patch) | |
tree | 2eb06f7ee3fa05af68fb536284497a9967222ad9 /src/gui/npcintegerdialog.cpp | |
parent | 5bbf8219bffbb587cf9a23561734c917bb23f42f (diff) | |
download | mana-58ee835c3763e7bf088fa6c7e31dda1d687589cc.tar.gz mana-58ee835c3763e7bf088fa6c7e31dda1d687589cc.tar.bz2 mana-58ee835c3763e7bf088fa6c7e31dda1d687589cc.tar.xz mana-58ee835c3763e7bf088fa6c7e31dda1d687589cc.zip |
Extended window layout to take relative positions, as well as offsets to
that position. This makes it so that when resolutions are changed, the
default locations stay relative to the window's position, and not the
800x600 screen resolution.
Signed-off-by: Ira Rice <irarice@gmail.com>
Diffstat (limited to 'src/gui/npcintegerdialog.cpp')
-rw-r--r-- | src/gui/npcintegerdialog.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/gui/npcintegerdialog.cpp b/src/gui/npcintegerdialog.cpp index 132a7608..5b3e05aa 100644 --- a/src/gui/npcintegerdialog.cpp +++ b/src/gui/npcintegerdialog.cpp @@ -37,6 +37,9 @@ NpcIntegerDialog::NpcIntegerDialog(Network *network): Window(_("NPC Number Request")), mNetwork(network) { mValueField = new IntTextField(); + setWindowName("NPCInput"); + + setDefaultSize(175, 75, ImageRect::CENTER); mDecButton = new Button("-", "decvalue", this); mIncButton = new Button("+", "incvalue", this); @@ -58,9 +61,9 @@ NpcIntegerDialog::NpcIntegerDialog(Network *network): place(0, 0, resetButton); place(2, 0, cancelButton); place(3, 0, okButton); - reflowLayout(175, 0); + //reflowLayout(175, 0); - setLocationRelativeTo(getParent()); + loadWindowState(); } void NpcIntegerDialog::setRange(const int min, const int max) |