summaryrefslogtreecommitdiff
path: root/main.cxx
diff options
context:
space:
mode:
authorErik Prabowo Kamal <erik@darapsa.co.id>2019-08-30 18:53:52 +0800
committerErik Prabowo Kamal <erik@darapsa.co.id>2019-08-30 18:53:52 +0800
commit07c432faf992781868f4d24b417c9cabb52a33d5 (patch)
treeb1b8c262509ce932e1169d9aa59c516de1bb31a5 /main.cxx
parent2235e4736994ae902e6cff167c5550168c0a37bb (diff)
Managed to post login credentials to the RT server
For now, it's just to get a response
Diffstat (limited to 'main.cxx')
-rw-r--r--main.cxx11
1 files changed, 6 insertions, 5 deletions
diff --git a/main.cxx b/main.cxx
index 0b52736..a29e917 100644
--- a/main.cxx
+++ b/main.cxx
@@ -12,13 +12,14 @@ int main(int argc, char* argv[])
qmlRegisterSingletonType<User>("id.co.darapsa.kelakon.user", 0, 1, "User", [](QQmlEngine *engine, QJSEngine *scriptEngine) -> QObject* {
Q_UNUSED(engine)
Q_UNUSED(scriptEngine)
-
- User* user = new User{};
- return user;
+ return new User{};
+ });
+ qmlRegisterSingletonType<User>("id.co.darapsa.kelakon.rtclient", 0, 1, "RTClient", [](QQmlEngine *engine, QJSEngine *scriptEngine) -> QObject* {
+ Q_UNUSED(engine)
+ Q_UNUSED(scriptEngine)
+ return new Controller{};
});
engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
- Controller controller{};
-
return app.exec();
}