mirror of
https://github.com/nextcloud/server.git
synced 2026-05-22 01:55:56 -04:00
prevent right-click when hideDownload is enabled
Signed-off-by: szaimen <szaimen@e.mail.de>
This commit is contained in:
parent
4fc2a276b4
commit
d1ae6ee0e5
1 changed files with 8 additions and 0 deletions
|
|
@ -50,6 +50,14 @@ OCA.Sharing.PublicApp = {
|
|||
var token = $('#sharingToken').val();
|
||||
var hideDownload = $('#hideDownload').val();
|
||||
|
||||
// Prevent all right-click options if hideDownload is enabled
|
||||
if (hideDownload === 'true') {
|
||||
window.oncontextmenu = function(event) {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
return false;
|
||||
};
|
||||
}
|
||||
|
||||
// file list mode ?
|
||||
if ($el.find('#filestable').length) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue