From fb6467841904c709d9d718ae949439ed7bbd9059 Mon Sep 17 00:00:00 2001 From: John A Knight Jr Date: Fri, 18 Oct 2024 09:52:47 -0700 Subject: [PATCH] Add feedback subscriptions to proc toggles --- buildStripDefs.js | 14 ++++++++++++++ package.json | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/buildStripDefs.js b/buildStripDefs.js index a9b2d3b..0e29a34 100644 --- a/buildStripDefs.js +++ b/buildStripDefs.js @@ -790,6 +790,20 @@ export function buildStripDefs(self) { color: combineRgb(192, 192, 192), bgcolor: combineRgb(0, 92, 128), }, + subscribe: async (feedback, context) => { + const theChannel = feedback.options.theChannel + const fbWhich = feedback.feedbackId + if (theChannel) { + self.xStat[self.fbToStat[fbWhich + theChannel]].fbSubs.add(feedback.id) + } + }, + unsubscribe: async (feedback, context) => { + const theChannel = feedback.options.theChannel + const fbWhich = feedback.feedbackId + if (theChannel) { + self.xStat[self.fbToStat[fbWhich + theChannel]].fbSubs.delete(feedback.id) + } + }, callback: async (feedback, context) => { const theChannel = feedback.options.theChannel const fbWhich = feedback.feedbackId diff --git a/package.json b/package.json index e2e181b..141cab5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "behringer-xair", - "version": "2.4.0", + "version": "2.4.1", "type": "module", "main": "index.js", "scripts": {