From 07c432faf992781868f4d24b417c9cabb52a33d5 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Fri, 30 Aug 2019 18:53:52 +0800 Subject: Managed to post login credentials to the RT server For now, it's just to get a response --- controller.cxx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'controller.cxx') diff --git a/controller.cxx b/controller.cxx index d1271b9..015d4ac 100644 --- a/controller.cxx +++ b/controller.cxx @@ -6,9 +6,15 @@ Controller::Controller() Worker* worker = new Worker{}; worker->moveToThread(&thread); connect(&thread, &QThread::finished, worker, &QObject::deleteLater); + connect(this, &Controller::credentialsObtained, worker, &Worker::logIn); thread.start(); } +void Controller::logIn(QString const& name, QString const& password) +{ + emit credentialsObtained(name, password); +} + Controller::~Controller() { thread.quit(); -- cgit v1.2.3