Allow javascript to safely open the correct login window (or answer that

it is unneded).
This commit is contained in:
howard-stearns 2016-08-18 14:19:36 -07:00
parent 5e8722ccf5
commit 4492c4e64e
2 changed files with 6 additions and 0 deletions

View file

@ -26,6 +26,11 @@ bool AccountScriptingInterface::isLoggedIn() {
return accountManager->isLoggedIn();
}
bool AccountScriptingInterface::checkAndSignalForAccessToken() {
auto accountManager = DependencyManager::get<AccountManager>();
return accountManager->checkAndSignalForAccessToken();
}
QString AccountScriptingInterface::getUsername() {
auto accountManager = DependencyManager::get<AccountManager>();
if (accountManager->isLoggedIn()) {

View file

@ -26,6 +26,7 @@ public slots:
static AccountScriptingInterface* getInstance();
QString getUsername();
bool isLoggedIn();
bool checkAndSignalForAccessToken();
};
#endif // hifi_AccountScriptingInterface_h