Disable some toolbar features not available if the pad is not stored

This commit is contained in:
yflory
2018-08-28 12:12:47 +02:00
parent 9ebb598467
commit d201e9a0cd
6 changed files with 54 additions and 23 deletions

View File

@@ -766,7 +766,8 @@ define([
// Add the pad if it does not exist in our drive
if (!contains) {
var autoStore = Util.find(store.proxy, ['settings', 'general', 'autostore']);
if (autoStore !== 1 && !data.forceSave && !data.path) {
var ownedByMe = Array.isArray(owners) && owners.indexOf(store.proxy.edPublic) !== -1;
if (autoStore !== 1 && !data.forceSave && !data.path && !ownedByMe) {
// send event to inner to display the corner popup
postMessage(clientId, "AUTOSTORE_DISPLAY_POPUP", {
autoStore: autoStore