loleaflet: When the 'premission' is 'edit', request a session immediately.
This commit is contained in:
parent
5848cff634
commit
41378e9945
1 changed files with 5 additions and 0 deletions
|
@ -72,6 +72,11 @@ L.Map = L.Evented.extend({
|
|||
this._addLayers(this.options.layers);
|
||||
this._socket = L.socket(this);
|
||||
|
||||
// when editing, we need the LOK session right away
|
||||
if (options.permission === 'edit') {
|
||||
this._socket.sendMessage('requestloksession');
|
||||
}
|
||||
|
||||
// Inhibit the context menu - the browser thinks that the document
|
||||
// is just a bunch of images, hence the context menu is useless (tdf#94599)
|
||||
this.on('contextmenu', function() {});
|
||||
|
|
Loading…
Reference in a new issue