summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gui/windows/logindialog.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/gui/windows/logindialog.cpp b/src/gui/windows/logindialog.cpp
index 5203bc228..c783abed8 100644
--- a/src/gui/windows/logindialog.cpp
+++ b/src/gui/windows/logindialog.cpp
@@ -34,6 +34,7 @@
#include "gui/widgets/button.h"
#include "gui/widgets/checkbox.h"
+#include "gui/widgets/createwidget.h"
#include "gui/widgets/dropdown.h"
#include "gui/widgets/label.h"
#include "gui/widgets/passwordfield.h"
@@ -224,10 +225,13 @@ void LoginDialog::action(const ActionEvent &event)
{
const std::string &url = mLoginData->registerUrl;
urlListener.url = url;
- // TRANSLATORS: question dialog
- ConfirmDialog *const confirmDlg = new ConfirmDialog(
- _("Open register url"), url, SOUND_REQUEST, false, Modal_true);
- confirmDlg->postInit();
+ ConfirmDialog *const confirmDlg = CREATEWIDGETR(ConfirmDialog,
+ // TRANSLATORS: question dialog
+ _("Open register url"),
+ url,
+ SOUND_REQUEST,
+ false,
+ Modal_true);
confirmDlg->addActionListener(&urlListener);
}
}