Fix stacking disconnection alerts

This commit is contained in:
yflory
2020-02-05 16:18:09 +01:00
parent 768dc71803
commit 1c013d8a4f
7 changed files with 34 additions and 17 deletions

View File

@@ -5,6 +5,7 @@ define([
'/common/common-util.js',
'/common/common-hash.js',
'/common/common-interface.js',
'/common/common-ui-elements.js',
'/common/common-feedback.js',
'/bower_components/nthen/index.js',
'/common/sframe-common.js',
@@ -22,6 +23,7 @@ define([
Util,
Hash,
UI,
UIElements,
Feedback,
nThen,
SFCommon,
@@ -272,13 +274,13 @@ define([
setEditable(false);
if (drive.refresh) { drive.refresh(); }
APP.toolbar.failed();
if (!noAlert) { UI.alert(Messages.common_connectionLost, undefined, true); }
if (!noAlert) { UIElements.disconnectAlert(); }
};
var onReconnect = function () {
setEditable(true);
if (drive.refresh) { drive.refresh(); }
APP.toolbar.reconnecting();
UI.findOKButton().click();
UIElements.reconnectAlert();
};
sframeChan.on('EV_DRIVE_LOG', function (msg) {