summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenry Castro <hcastro@collabora.com>2021-08-09 08:20:01 -0400
committerHenry Castro <hcastro@collabora.com>2021-09-17 08:58:00 -0400
commit321ab8c749daad20be0b6e63529e08459922279a (patch)
tree22b204fb4ef7f2c992325cb2b3bbc2fb6d9d8368
parentAction_Paste postMessage to work around the pasting mechanism. (diff)
downloadonline-pr/distro/collabora/co-6-4/05.tar.gz
online-pr/distro/collabora/co-6-4/05.zip
loleaflet: auto reload page if it is integrated with WOPI pr/distro/collabora/co-6-4/05
Reload page if the loolwsd server is upgraded. Change-Id: I3c6ba97c04c001affbc62b039290d2a7a8c8f91a Signed-off-by: Henry Castro <hcastro@collabora.com>
-rw-r--r--loleaflet/src/core/Socket.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/loleaflet/src/core/Socket.js b/loleaflet/src/core/Socket.js
index 48d9be5724..c11faef012 100644
--- a/loleaflet/src/core/Socket.js
+++ b/loleaflet/src/core/Socket.js
@@ -497,7 +497,9 @@ app.definitions.Socket = L.Class.extend({
this._map.uiManager.showSnackbar(reloadMessage, _('RELOAD'), function() {window.location.reload();});
setTimeout(window.location.reload, 5000);
} else {
- alert(reloadMessage);
+ if (!this._map.options.wopi)
+ alert(reloadMessage);
+
window.location.reload();
}
}