feat(PageReload): make the reload interval random, between 10-30 sec
This commit is contained in:
parent
c95c46edac
commit
3c6d464b32
|
@ -21,6 +21,7 @@ import SettingsMenu from "./side_pannels/settings/SettingsMenu";
|
||||||
import Profile from "./side_pannels/profile/Profile";
|
import Profile from "./side_pannels/profile/Profile";
|
||||||
import Settings from "./../settings/Settings";
|
import Settings from "./../settings/Settings";
|
||||||
import RingOverlay from "./ring_overlay/RingOverlay";
|
import RingOverlay from "./ring_overlay/RingOverlay";
|
||||||
|
import RandomUtil from "../util/RandomUtil";
|
||||||
import UIErrors from './UIErrors';
|
import UIErrors from './UIErrors';
|
||||||
|
|
||||||
var EventEmitter = require("events");
|
var EventEmitter = require("events");
|
||||||
|
@ -1103,7 +1104,8 @@ UI.notifyFocusDisconnected = function (focus, retrySec) {
|
||||||
* the page should be reloaded.
|
* the page should be reloaded.
|
||||||
*/
|
*/
|
||||||
UI.showPageReloadOverlay = function () {
|
UI.showPageReloadOverlay = function () {
|
||||||
PageReloadOverlay.show(15 /* will reload in 15 seconds */);
|
// Reload the page after 10 - 30 seconds
|
||||||
|
PageReloadOverlay.show(10 + RandomUtil.randomInt(0, 20));
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue