diff --git a/launchers/qt/src/LauncherState.cpp b/launchers/qt/src/LauncherState.cpp index d1635c277c..12f9bfa360 100644 --- a/launchers/qt/src/LauncherState.cpp +++ b/launchers/qt/src/LauncherState.cpp @@ -223,6 +223,7 @@ Q_INVOKABLE void LauncherState::receivedLoginReply() { _loginResponse.tokenType = root["token_type"].toString(); qDebug() << "Got response for login: " << data; + _loginTokenResponse = data; downloadClient(); } @@ -421,6 +422,10 @@ void LauncherState::launchClient() { + " --displayName " + displayName + " --cache " + contentCachePath; + if (!_loginTokenResponse.isEmpty()) { + params += " --tokens \"" + _loginTokenResponse.replace("\"", "\\\"") + "\""; + } + #if defined(Q_OS_WIN) STARTUPINFO si; PROCESS_INFORMATION pi; diff --git a/launchers/qt/src/LauncherState.h b/launchers/qt/src/LauncherState.h index 353c5947e1..691ea23ebf 100644 --- a/launchers/qt/src/LauncherState.h +++ b/launchers/qt/src/LauncherState.h @@ -137,6 +137,7 @@ private: LastLoginError _lastLoginError { NONE }; QString _buildTag { QString::null }; QString _contentCacheURL{ "https://orgs.highfidelity.com/content-cache/content_cache_small-only_data8.zip" }; // QString::null }; // If null, there is no content cache to download + QString _loginTokenResponse; QFile _clientZipFile; QFile _contentZipFile; diff --git a/launchers/qt/src/Unzipper.cpp b/launchers/qt/src/Unzipper.cpp index 3d6672b340..c7cca0b5e3 100644 --- a/launchers/qt/src/Unzipper.cpp +++ b/launchers/qt/src/Unzipper.cpp @@ -9,10 +9,6 @@ Unzipper::Unzipper(const QString& zipFilePath, const QDir& outputDirectory) : _zipFilePath(zipFilePath), _outputDirectory(outputDirectory) { } -//uint64_t extractZip(const QString& zipFile, const std::string& path, - //std::vector& files) { - //std::function progressCallback) { - void Unzipper::run() { qDebug() << "Reading zip file" << _zipFilePath << ", extracting to" << _outputDirectory.absolutePath(); @@ -45,7 +41,6 @@ void Unzipper::run() { return; } - // Get root folder uint64_t totalSize = 0; uint64_t totalCompressedSize = 0; bool _shouldFail = false;