diff options
author | Eugenio Favalli <elvenprogrammer@gmail.com> | 2006-01-04 20:28:57 +0000 |
---|---|---|
committer | Eugenio Favalli <elvenprogrammer@gmail.com> | 2006-01-04 20:28:57 +0000 |
commit | 34b19f52d2f4a0b8e7eecf0900d1760460390b9d (patch) | |
tree | 0e1ddf0575ec5780d988623daf4fc25d813fc1fd /src/gui/confirm_dialog.cpp | |
parent | 180f39cb9da6e3169f95e9da5c8782c50f826af4 (diff) | |
download | mana-34b19f52d2f4a0b8e7eecf0900d1760460390b9d.tar.gz mana-34b19f52d2f4a0b8e7eecf0900d1760460390b9d.tar.bz2 mana-34b19f52d2f4a0b8e7eecf0900d1760460390b9d.tar.xz mana-34b19f52d2f4a0b8e7eecf0900d1760460390b9d.zip |
Reverted r0nny changes, enabled 3 slots to create players, smoothed player deletion.
Diffstat (limited to 'src/gui/confirm_dialog.cpp')
-rw-r--r-- | src/gui/confirm_dialog.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gui/confirm_dialog.cpp b/src/gui/confirm_dialog.cpp index dc710961..59d48318 100644 --- a/src/gui/confirm_dialog.cpp +++ b/src/gui/confirm_dialog.cpp @@ -45,20 +45,20 @@ ConfirmDialog::ConfirmDialog(Window *parent, const std::string &title, void ConfirmDialog::init(const std::string &msg, gcn::ActionListener *listener) { - gcn::Label *userLabel = new gcn::Label(msg); - Button *yesButton = new Button("Yes"); - Button *noButton = new Button("No"); + textLabel = new gcn::Label(msg); + yesButton = new Button("Yes"); + noButton = new Button("No"); - int w = userLabel->getWidth() + 20; + int w = textLabel->getWidth() + 20; int inWidth = yesButton->getWidth() + noButton->getWidth() + 5; - int h = userLabel->getHeight() + 25 + yesButton->getHeight(); + int h = textLabel->getHeight() + 25 + yesButton->getHeight(); if (w < inWidth + 10) { w = inWidth + 10; } setContentSize(w, h); - userLabel->setPosition(10, 10); + textLabel->setPosition(10, 10); yesButton->setPosition( (w - inWidth) / 2, h - 5 - noButton->getHeight()); @@ -75,7 +75,7 @@ void ConfirmDialog::init(const std::string &msg, gcn::ActionListener *listener) noButton->addActionListener(listener); } - add(userLabel); + add(textLabel); add(yesButton); add(noButton); |