aboutsummaryrefslogtreecommitdiff
path: root/src/mainwindow/mainwindow.cpp
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2018-08-24 19:49:21 +0200
committerAqua-sama <aqua@iserlohn-fortress.net>2018-08-24 20:03:38 +0200
commitb8ea8aa986ff88e82658523ac8d40756ab871984 (patch)
tree5cf1b6dcbd86ffe6e26814c8225b7f05c7407c05 /src/mainwindow/mainwindow.cpp
parentDownloads: prevent download widget width from exceeding download list width (diff)
downloadsmolbote-b8ea8aa986ff88e82658523ac8d40756ab871984.tar.xz
MainWindow: fix load session action
Diffstat (limited to 'src/mainwindow/mainwindow.cpp')
-rw-r--r--src/mainwindow/mainwindow.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mainwindow/mainwindow.cpp b/src/mainwindow/mainwindow.cpp
index 7f9cdcc..ccc5f1e 100644
--- a/src/mainwindow/mainwindow.cpp
+++ b/src/mainwindow/mainwindow.cpp
@@ -129,7 +129,8 @@ MainWindow::MainWindow(const std::unique_ptr<Configuration> &config, QWidget *pa
QFile json(filename);
if(json.open(QIODevice::ReadOnly | QIODevice::Text)) {
auto *browser = qobject_cast<Browser *>(qApp);
- browser->sendMessage(json.readAll());
+ auto doc = QJsonDocument::fromJson(json.readAll());
+ browser->createSession(doc.object());
json.close();
}
});