summaryrefslogtreecommitdiff
path: root/src/net/ea
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-06-14 21:19:00 +0300
committerAndrei Karas <akaras@inbox.ru>2015-06-14 21:19:00 +0300
commitfd229a024de7244181e184d736a610645f32db0d (patch)
tree0616cf5318893250519015658fd2d8d88963302c /src/net/ea
parent0e13e22e4902eca435812ae002c56ad13233efc6 (diff)
downloadmanaverse-fd229a024de7244181e184d736a610645f32db0d.tar.gz
manaverse-fd229a024de7244181e184d736a610645f32db0d.tar.bz2
manaverse-fd229a024de7244181e184d736a610645f32db0d.tar.xz
manaverse-fd229a024de7244181e184d736a610645f32db0d.zip
Use CREATEWIDGET macro in tradehandler.
Diffstat (limited to 'src/net/ea')
-rw-r--r--src/net/ea/tradehandler.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/net/ea/tradehandler.cpp b/src/net/ea/tradehandler.cpp
index a0c84c24e..848e0a024 100644
--- a/src/net/ea/tradehandler.cpp
+++ b/src/net/ea/tradehandler.cpp
@@ -28,6 +28,8 @@
#include "gui/windows/tradewindow.h"
+#include "gui/widgets/createwidget.h"
+
#include "net/messagein.h"
#include "utils/gettext.h"
@@ -168,13 +170,14 @@ void TradeHandler::processTradeRequestContinue(const std::string &partner)
!= tradePartnerName)
{
tradeWindow->clear();
- // TRANSLATORS: trade message
- confirmDlg = new ConfirmDialog(_("Request for Trade"),
+ CREATEWIDGETV(confirmDlg, ConfirmDialog,
+ // TRANSLATORS: trade message
+ _("Request for Trade"),
// TRANSLATORS: trade message
strprintf(_("%s wants to trade with you, do"
" you accept?"), tradePartnerName.c_str()),
- SOUND_REQUEST, true);
- confirmDlg->postInit();
+ SOUND_REQUEST,
+ true);
confirmDlg->addActionListener(&listener);
}
else