From 1a247af0a982863d87b7c5503dbda54ea3e1538f Mon Sep 17 00:00:00 2001 From: ansuz Date: Mon, 21 Mar 2022 17:48:41 +0530 Subject: [PATCH] block access to the properties menu in iframes --- www/common/common-ui-elements.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 5661ade7f..422820361 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -888,6 +888,14 @@ define([ .text(Messages.propertiesButton)) .click(common.prepareFeedback(type)) .click(function () { + var isTop; + try { + isTop = common.getMetadataMgr().getPrivateData().isTop; + } catch (err) { console.error(err); } + if (!isTop) { + return void UIElements.openDirectlyConfirmation(common); + } + sframeChan.event('EV_PROPERTIES_OPEN'); }); break;