mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 13:28:09 +02:00
Merge pull request #1 from danteruiz/interstitalMerged
handle unable to connect to domain case
This commit is contained in:
commit
60a5b0eeaf
2 changed files with 5 additions and 1 deletions
|
@ -346,6 +346,7 @@ public slots:
|
||||||
bool importEntities(const QString& url);
|
bool importEntities(const QString& url);
|
||||||
void updateThreadPoolCount() const;
|
void updateThreadPoolCount() const;
|
||||||
void updateSystemTabletMode();
|
void updateSystemTabletMode();
|
||||||
|
void goToErrorDomainURL(QUrl errorDomainURL);
|
||||||
|
|
||||||
Q_INVOKABLE void loadDialog();
|
Q_INVOKABLE void loadDialog();
|
||||||
Q_INVOKABLE void loadScriptURLDialog() const;
|
Q_INVOKABLE void loadScriptURLDialog() const;
|
||||||
|
@ -474,7 +475,6 @@ private slots:
|
||||||
void setSessionUUID(const QUuid& sessionUUID) const;
|
void setSessionUUID(const QUuid& sessionUUID) const;
|
||||||
|
|
||||||
void domainURLChanged(QUrl domainURL);
|
void domainURLChanged(QUrl domainURL);
|
||||||
void goToErrorDomainURL(QUrl errorDomainURL);
|
|
||||||
void updateWindowTitle() const;
|
void updateWindowTitle() const;
|
||||||
void nodeAdded(SharedNodePointer node) const;
|
void nodeAdded(SharedNodePointer node) const;
|
||||||
void nodeActivated(SharedNodePointer node);
|
void nodeActivated(SharedNodePointer node);
|
||||||
|
|
|
@ -11,16 +11,19 @@
|
||||||
|
|
||||||
#include "ConnectionMonitor.h"
|
#include "ConnectionMonitor.h"
|
||||||
|
|
||||||
|
#include "Application.h"
|
||||||
#include "ui/DialogsManager.h"
|
#include "ui/DialogsManager.h"
|
||||||
|
|
||||||
#include <DependencyManager.h>
|
#include <DependencyManager.h>
|
||||||
#include <DomainHandler.h>
|
#include <DomainHandler.h>
|
||||||
|
#include <AddressManager.h>
|
||||||
#include <NodeList.h>
|
#include <NodeList.h>
|
||||||
|
|
||||||
// Because the connection monitor is created at startup, the time we wait on initial load
|
// Because the connection monitor is created at startup, the time we wait on initial load
|
||||||
// should be longer to allow the application to initialize.
|
// should be longer to allow the application to initialize.
|
||||||
static const int ON_INITIAL_LOAD_DISPLAY_AFTER_DISCONNECTED_FOR_X_MS = 10000;
|
static const int ON_INITIAL_LOAD_DISPLAY_AFTER_DISCONNECTED_FOR_X_MS = 10000;
|
||||||
static const int DISPLAY_AFTER_DISCONNECTED_FOR_X_MS = 5000;
|
static const int DISPLAY_AFTER_DISCONNECTED_FOR_X_MS = 5000;
|
||||||
|
static const QString ERROR_DOMAIN_URL = "file:///~/serverless/redirect.json";
|
||||||
|
|
||||||
void ConnectionMonitor::init() {
|
void ConnectionMonitor::init() {
|
||||||
// Connect to domain disconnected message
|
// Connect to domain disconnected message
|
||||||
|
@ -38,6 +41,7 @@ void ConnectionMonitor::init() {
|
||||||
|
|
||||||
connect(&_timer, &QTimer::timeout, this, []() {
|
connect(&_timer, &QTimer::timeout, this, []() {
|
||||||
qDebug() << "ConnectionMonitor: Showing connection failure window";
|
qDebug() << "ConnectionMonitor: Showing connection failure window";
|
||||||
|
qApp->goToErrorDomainURL(REDIRECT_HIFI_ADDRESS);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue