diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-06-14 19:43:24 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-06-14 19:43:24 +0300 |
commit | cb7c18ed3dc3c53621dfe8debe14938a640e43db (patch) | |
tree | bf80b07a9f35dcbf92a9eb3e7f0470527fdc25b1 /src/gui | |
parent | 9f848c5c35103cff9597bf7349383c85ad3317cd (diff) | |
download | manaplus-cb7c18ed3dc3c53621dfe8debe14938a640e43db.tar.gz manaplus-cb7c18ed3dc3c53621dfe8debe14938a640e43db.tar.bz2 manaplus-cb7c18ed3dc3c53621dfe8debe14938a640e43db.tar.xz manaplus-cb7c18ed3dc3c53621dfe8debe14938a640e43db.zip |
Use CREATEWIDGET macro in unregisterdialog.
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/windows/unregisterdialog.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/windows/unregisterdialog.cpp b/src/gui/windows/unregisterdialog.cpp index 90c9bd404..c789de720 100644 --- a/src/gui/windows/unregisterdialog.cpp +++ b/src/gui/windows/unregisterdialog.cpp @@ -27,6 +27,7 @@ #include "gui/windows/okdialog.h" #include "gui/widgets/button.h" +#include "gui/widgets/createwidget.h" #include "gui/widgets/label.h" #include "gui/widgets/passwordfield.h" @@ -140,8 +141,9 @@ void UnRegisterDialog::action(const ActionEvent &event) { mWrongDataNoticeListener->setTarget(this->mPasswordField); - // TRANSLATORS: unregister dialog. error message. - OkDialog *const dlg = new OkDialog(_("Error"), + OkDialog *const dlg = CREATEWIDGETR(OkDialog, + // TRANSLATORS: unregister dialog. error message. + _("Error"), errorMsg.str(), // TRANSLATORS: ok dialog button _("OK"), @@ -150,7 +152,6 @@ void UnRegisterDialog::action(const ActionEvent &event) ShowCenter_true, nullptr, 260); - dlg->postInit(); dlg->addActionListener(mWrongDataNoticeListener); } else |