[Libreoffice-commits] online.git: loleaflet/src

Henry Castro (via logerrit) logerrit at kemper.freedesktop.org
Mon Feb 10 21:30:02 UTC 2020


 loleaflet/src/control/Control.Menubar.js |    8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

New commits:
commit 070395257a49cc699cdd7e21280ba2a197ec2f52
Author:     Henry Castro <hcastro at collabora.com>
AuthorDate: Mon Feb 10 16:53:57 2020 -0400
Commit:     Henry Castro <hcastro at collabora.com>
CommitDate: Mon Feb 10 22:29:43 2020 +0100

    loleaflet: mobile: don't show 'Save' menu item when it is read only
    
    Change-Id: I1b2c56c4c05c40b2e6e0cc6b4d0c420236c03fed
    Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88414
    Tested-by: Henry Castro <hcastro at collabora.com>
    Reviewed-by: Henry Castro <hcastro at collabora.com>

diff --git a/loleaflet/src/control/Control.Menubar.js b/loleaflet/src/control/Control.Menubar.js
index d9c5cfbfa..1a5cdc19d 100644
--- a/loleaflet/src/control/Control.Menubar.js
+++ b/loleaflet/src/control/Control.Menubar.js
@@ -1316,8 +1316,12 @@ L.Control.Menubar = L.Control.extend({
 			if (!found)
 				return false;
 		}
-		if (this._map._permission === 'readonly' && menuItem.id === 'last-mod') {
-			return false;
+		if (this._map._permission === 'readonly') {
+			switch (menuItem.id) {
+			case 'last-mod':
+			case 'save':
+				return false;
+			}
 		}
 
 		if (menuItem.type === 'action') {


More information about the Libreoffice-commits mailing list