Offline mode can be used even when online.
Allow the user to pick a player name for offline mode. Big auth refactor. Now using session objects instead of the accounts themselves. Sessions only last for one instance start and hold all the auth and player data.
This commit is contained in:
@ -25,8 +25,7 @@
|
||||
|
||||
#include "logger/QsLog.h"
|
||||
|
||||
RefreshTask::RefreshTask(MojangAccount *account, QObject *parent)
|
||||
: YggdrasilTask(account, parent)
|
||||
RefreshTask::RefreshTask(MojangAccount *account) : YggdrasilTask(account)
|
||||
{
|
||||
}
|
||||
|
||||
@ -126,7 +125,6 @@ bool RefreshTask::processResponse(QJsonObject responseData)
|
||||
m_account->m_user = u;
|
||||
}
|
||||
|
||||
|
||||
// We've made it through the minefield of possible errors. Return true to indicate that
|
||||
// we've succeeded.
|
||||
QLOG_DEBUG() << "Finished reading refresh response.";
|
||||
|
@ -30,7 +30,7 @@ class RefreshTask : public YggdrasilTask
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
RefreshTask(MojangAccount * account, QObject *parent = 0);
|
||||
RefreshTask(MojangAccount * account);
|
||||
|
||||
protected:
|
||||
virtual QJsonObject getRequestContent() const;
|
||||
@ -41,3 +41,4 @@ protected:
|
||||
|
||||
QString getStateMessage(const YggdrasilTask::State state) const;
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user