summaryrefslogtreecommitdiffstats
path: root/logic/auth/YggdrasilTask.h
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2013-12-01 02:00:42 +0100
committerPetr Mrázek <peterix@gmail.com>2013-12-01 02:00:42 +0100
commitf27a6c39ea796f946893ced1d9f80441ad9aa18c (patch)
treefed31b28bc7752f4fea85aefddfeff62701e13b7 /logic/auth/YggdrasilTask.h
parent2eaf33816b0c4f6fd61ea2b086fa1c4f9fcba4c5 (diff)
downloadMultiMC-f27a6c39ea796f946893ced1d9f80441ad9aa18c.tar
MultiMC-f27a6c39ea796f946893ced1d9f80441ad9aa18c.tar.gz
MultiMC-f27a6c39ea796f946893ced1d9f80441ad9aa18c.tar.lz
MultiMC-f27a6c39ea796f946893ced1d9f80441ad9aa18c.tar.xz
MultiMC-f27a6c39ea796f946893ced1d9f80441ad9aa18c.zip
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.
Diffstat (limited to 'logic/auth/YggdrasilTask.h')
-rw-r--r--logic/auth/YggdrasilTask.h22
1 files changed, 12 insertions, 10 deletions
diff --git a/logic/auth/YggdrasilTask.h b/logic/auth/YggdrasilTask.h
index 5a433aeb..62638c9d 100644
--- a/logic/auth/YggdrasilTask.h
+++ b/logic/auth/YggdrasilTask.h
@@ -24,15 +24,14 @@
class QNetworkReply;
-
/**
* A Yggdrasil task is a task that performs an operation on a given mojang account.
*/
class YggdrasilTask : public Task
{
-Q_OBJECT
+ Q_OBJECT
public:
- explicit YggdrasilTask(MojangAccountPtr account, QObject* parent=0);
+ explicit YggdrasilTask(MojangAccountPtr account, QObject *parent = 0);
~YggdrasilTask();
/**
@@ -49,7 +48,10 @@ public:
QString getCause() const { return m_cause; }
/// Gets the string to display in the GUI for describing this error.
- QString getDisplayMessage() { return getErrorMessage(); }
+ QString getDisplayMessage()
+ {
+ return getErrorMessage();
+ }
protected:
QString m_shortError;
@@ -66,7 +68,7 @@ public:
* Returns a pointer to a YggdrasilTask::Error object if an error has occurred.
* If no error has occurred, returns a null pointer.
*/
- virtual Error* getError() const;
+ virtual Error *getError() const;
protected:
/**
@@ -120,11 +122,11 @@ protected:
MojangAccountPtr m_account;
- QNetworkReply* m_netReply;
+ QNetworkReply *m_netReply;
- Error* m_error;
+ Error *m_error;
-protected slots:
- void processReply(QNetworkReply* reply);
+protected
+slots:
+ void processReply(QNetworkReply *reply);
};
-