From f27a6c39ea796f946893ced1d9f80441ad9aa18c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Sun, 1 Dec 2013 02:00:42 +0100 Subject: Fix login and startup logging issues Auth uses the refresh endpoint instead of validate. This means less password entering. Console will now only autoscroll when already scrolled all the way down. Better conformance with the Yggdrasil auth protocol (not complete yet, but Mojang launcher isn't complete either). Fix bug that prevented saving the account data (uninitialized variable). Accounts can now trigger account list saving, this is used for the refresh endpoint. --- logic/MinecraftProcess.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'logic/MinecraftProcess.h') diff --git a/logic/MinecraftProcess.h b/logic/MinecraftProcess.h index e38d2f83..bd0151cc 100644 --- a/logic/MinecraftProcess.h +++ b/logic/MinecraftProcess.h @@ -69,10 +69,9 @@ public: void killMinecraft(); - inline void setLogin(QString user, QString sid) + inline void setLogin(MojangAccountPtr account) { - username = user; - sessionID = sid; + m_account = account; } signals: @@ -104,11 +103,13 @@ signals: void log(QString text, MessageLevel::Enum level = MessageLevel::MultiMC); protected: - BaseInstance *m_instance; + BaseInstance *m_instance = nullptr; QStringList m_args; QString m_err_leftover; QString m_out_leftover; QProcess m_prepostlaunchprocess; + bool killed = false; + MojangAccountPtr m_account; protected slots: @@ -117,8 +118,7 @@ slots: void on_stdOut(); private: - bool killed; + QString censorPrivateInfo(QString in); MessageLevel::Enum getLevel(const QString &message, MessageLevel::Enum defaultLevel); - QString sessionID; - QString username; + }; -- cgit v1.2.3