From 334a40a7056909045d472c994f6cc4940e729917 Mon Sep 17 00:00:00 2001 From: yann300 Date: Thu, 8 Feb 2018 16:55:49 +0100 Subject: [PATCH] add leafRightClick --- remix-debugger/src/ui/TreeView.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/remix-debugger/src/ui/TreeView.js b/remix-debugger/src/ui/TreeView.js index c1541f4ff0..2c7e189546 100644 --- a/remix-debugger/src/ui/TreeView.js +++ b/remix-debugger/src/ui/TreeView.js @@ -95,8 +95,11 @@ class TreeView { li.appendChild(list) } else { caret.style.visibility = 'hidden' - label.onclick = function () { - self.event.trigger('leafClick', [key, data, label]) + label.oncontextmenu = function (event) { + self.event.trigger('leafRightClick', [key, data, label, event]) + } + label.onclick = function (event) { + self.event.trigger('leafClick', [key, data, label, event]) } } return li