From e12ea9cd2f4ebe551474ca1e988e54b934dc8b89 Mon Sep 17 00:00:00 2001 From: Jesse Mazzella Date: Mon, 6 May 2024 21:58:27 -0700 Subject: [PATCH] Revert "fix: pass context to eventHelpers" This reverts commit 7df3d66669d082b96942606bcacee453e25aa79c. --- src/plugins/imagery/lib/eventHelpers.js | 4 ++-- src/plugins/plot/lib/eventHelpers.js | 2 +- src/plugins/summaryWidget/src/eventHelpers.js | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/plugins/imagery/lib/eventHelpers.js b/src/plugins/imagery/lib/eventHelpers.js index 9d46dca54dd5..c4de691650ea 100644 --- a/src/plugins/imagery/lib/eventHelpers.js +++ b/src/plugins/imagery/lib/eventHelpers.js @@ -41,7 +41,7 @@ const helperFunctions = { } else if (object.addEventListener) { object.addEventListener(event, listener._cb); } else { - object.on(event, listener._cb, listener.context); + object.on(event, listener._cb); } this._listeningTo.push(listener); @@ -78,7 +78,7 @@ const helperFunctions = { } else if (listener.object.removeEventListener) { listener.object.removeEventListener(listener.event, listener._cb); } else { - listener.object.off(listener.event, listener._cb, listener.context); + listener.object.off(listener.event, listener._cb); } return listener; diff --git a/src/plugins/plot/lib/eventHelpers.js b/src/plugins/plot/lib/eventHelpers.js index 20bb3838ea96..e05d20518263 100644 --- a/src/plugins/plot/lib/eventHelpers.js +++ b/src/plugins/plot/lib/eventHelpers.js @@ -74,7 +74,7 @@ const helperFunctions = { } else if (listener.object.removeEventListener) { listener.object.removeEventListener(listener.event, listener._cb); } else { - listener.object.off(listener.event, listener._cb, listener.context); + listener.object.off(listener.event, listener._cb); } return listener; diff --git a/src/plugins/summaryWidget/src/eventHelpers.js b/src/plugins/summaryWidget/src/eventHelpers.js index fbc74c148df9..88945438a9de 100644 --- a/src/plugins/summaryWidget/src/eventHelpers.js +++ b/src/plugins/summaryWidget/src/eventHelpers.js @@ -41,7 +41,7 @@ const helperFunctions = { } else if (object.addEventListener) { object.addEventListener(event, listener._cb); } else { - object.on(event, listener._cb, listener.context); + object.on(event, listener._cb); } this._listeningTo.push(listener); @@ -78,7 +78,7 @@ const helperFunctions = { } else if (listener.object.removeEventListener) { listener.object.removeEventListener(listener.event, listener._cb); } else { - listener.object.off(listener.event, listener._cb, listener.context); + listener.object.off(listener.event, listener._cb); } return listener;