From f9eaac46ab50d6fff2b765882ad2ae0979e2468f Mon Sep 17 00:00:00 2001 From: yann300 Date: Thu, 17 Nov 2022 16:45:51 +0100 Subject: [PATCH] fix listenning event in debugger --- libs/remix-ui/debugger-ui/src/lib/debugger-ui.tsx | 4 ++-- .../debugger-ui/src/lib/vm-debugger/vm-debugger-head.tsx | 4 ++-- libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger.tsx | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/libs/remix-ui/debugger-ui/src/lib/debugger-ui.tsx b/libs/remix-ui/debugger-ui/src/lib/debugger-ui.tsx index 81f2ea218c..3233461935 100644 --- a/libs/remix-ui/debugger-ui/src/lib/debugger-ui.tsx +++ b/libs/remix-ui/debugger-ui/src/lib/debugger-ui.tsx @@ -396,8 +396,8 @@ export const DebuggerUI = (props: DebuggerUIProps) => { { state.debugging && }
- { state.debugging && } - { state.debugging && } + { state.debugging && } + { state.debugging && }
) diff --git a/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger-head.tsx b/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger-head.tsx index 0ffc505833..aa195f0038 100644 --- a/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger-head.tsx +++ b/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger-head.tsx @@ -5,7 +5,7 @@ import StepDetail from './step-detail' // eslint-disable-line import SolidityState from './solidity-state' // eslint-disable-line import SolidityLocals from './solidity-locals' // eslint-disable-line -export const VmDebuggerHead = ({ vmDebugger: { registerEvent, triggerEvent } }) => { +export const VmDebuggerHead = ({ vmDebugger: { registerEvent, triggerEvent }, debugging }) => { const [functionPanel, setFunctionPanel] = useState(null) const [stepDetail, setStepDetail] = useState({ 'vm trace step': '-', @@ -95,7 +95,7 @@ export const VmDebuggerHead = ({ vmDebugger: { registerEvent, triggerEvent } }) return { ...solidityLocals, message } }) }) - }, [registerEvent]) + }, [debugging]) return (
diff --git a/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger.tsx b/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger.tsx index 8bf8307f2a..508097d5df 100644 --- a/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger.tsx +++ b/libs/remix-ui/debugger-ui/src/lib/vm-debugger/vm-debugger.tsx @@ -8,7 +8,7 @@ import ReturnValuesPanel from './dropdown-panel' // eslint-disable-line import FullStoragesChangesPanel from './full-storages-changes' // eslint-disable-line import GlobalVariables from './global-variables' // eslint-disable-line -export const VmDebugger = ({ vmDebugger: { registerEvent }, currentBlock, currentReceipt, currentTransaction }) => { +export const VmDebugger = ({ vmDebugger: { registerEvent }, currentBlock, currentReceipt, currentTransaction, debugging }) => { const [calldataPanel, setCalldataPanel] = useState(null) const [memoryPanel, setMemoryPanel] = useState(null) const [callStackPanel, setCallStackPanel] = useState(null) @@ -49,7 +49,7 @@ export const VmDebugger = ({ vmDebugger: { registerEvent }, currentBlock, curren registerEvent && registerEvent('traceStorageUpdate', (calldata) => { setFullStoragesChangesPanel(() => calldata) }) - }, [registerEvent]) + }, [debugging]) return (