aboutsummaryrefslogtreecommitdiff
path: root/plugins/ProfileEditor/profileeditorplugin.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/ProfileEditor/profileeditorplugin.cpp')
-rw-r--r--plugins/ProfileEditor/profileeditorplugin.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/plugins/ProfileEditor/profileeditorplugin.cpp b/plugins/ProfileEditor/profileeditorplugin.cpp
index 5d5c18a..32b0b8d 100644
--- a/plugins/ProfileEditor/profileeditorplugin.cpp
+++ b/plugins/ProfileEditor/profileeditorplugin.cpp
@@ -28,5 +28,10 @@ QDialog *ProfileEditorPlugin::createWidget(QWidget *parent)
Q_CHECK_PTR(browser);
auto *widget = new ProfileManagerDialog(browser->profiles(), parent);
widget->setAttribute(Qt::WA_DeleteOnClose, true);
+
+ connect(widget, &ProfileManagerDialog::createProfile, this, [=](const QString &id) {
+ auto newProfile = browser->loadProfile(id);
+ widget->addProfile(newProfile.second);
+ });
return widget;
}