From 2fbe6d5efc01acf09c3a0561ffa9e355e277e43e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rocky=20K=C3=BCppers?= Date: Tue, 15 Jan 2019 11:20:44 +0100 Subject: [PATCH 1/2] Fix for File Explorer --- src/app/files/file-explorer.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/app/files/file-explorer.js b/src/app/files/file-explorer.js index d0c23595e6..096b5a59c1 100644 --- a/src/app/files/file-explorer.js +++ b/src/app/files/file-explorer.js @@ -132,6 +132,7 @@ function fileExplorer (localRegistry, files) { }) self.treeView.event.register('nodeRightClick', function (key, data, label, event) { + if (key == self.files.type) return MENU_HANDLE && MENU_HANDLE.hide(null, true) MENU_HANDLE = contextMenu(event, { 'Rename': () => { @@ -147,6 +148,7 @@ function fileExplorer (localRegistry, files) { }) self.treeView.event.register('leafRightClick', function (key, data, label, event) { + if (key == self.files.type) return MENU_HANDLE && MENU_HANDLE.hide(null, true) MENU_HANDLE = contextMenu(event, { 'Rename': () => { From f1d2369dfabcf38e665a21e61d0d9d29b464887a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rocky=20K=C3=BCppers?= Date: Tue, 15 Jan 2019 11:25:07 +0100 Subject: [PATCH 2/2] Fix Equality Test --- src/app/files/file-explorer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app/files/file-explorer.js b/src/app/files/file-explorer.js index 096b5a59c1..b1d90ea71a 100644 --- a/src/app/files/file-explorer.js +++ b/src/app/files/file-explorer.js @@ -132,7 +132,7 @@ function fileExplorer (localRegistry, files) { }) self.treeView.event.register('nodeRightClick', function (key, data, label, event) { - if (key == self.files.type) return + if (key === self.files.type) return MENU_HANDLE && MENU_HANDLE.hide(null, true) MENU_HANDLE = contextMenu(event, { 'Rename': () => { @@ -148,7 +148,7 @@ function fileExplorer (localRegistry, files) { }) self.treeView.event.register('leafRightClick', function (key, data, label, event) { - if (key == self.files.type) return + if (key === self.files.type) return MENU_HANDLE && MENU_HANDLE.hide(null, true) MENU_HANDLE = contextMenu(event, { 'Rename': () => {