summaryrefslogtreecommitdiffstats
path: root/res/controllers/midi-components-0.0.js
diff options
context:
space:
mode:
authorJan Holthuis <jan.holthuis@ruhr-uni-bochum.de>2020-03-10 11:09:27 +0100
committerJan Holthuis <jan.holthuis@ruhr-uni-bochum.de>2020-03-10 11:09:27 +0100
commit702050f0b8c52622849d0db1fa5146589c52d11f (patch)
treeeea060db744a3744f73952c8e6f5019e185f7a8c /res/controllers/midi-components-0.0.js
parenta538a0958356874d1994654d11fec1105937c6fa (diff)
res/controllers: Add color conv. functions to common-controller-scripts
Diffstat (limited to 'res/controllers/midi-components-0.0.js')
-rw-r--r--res/controllers/midi-components-0.0.js17
1 files changed, 1 insertions, 16 deletions
diff --git a/res/controllers/midi-components-0.0.js b/res/controllers/midi-components-0.0.js
index 9936e0841e..3c61cbf383 100644
--- a/res/controllers/midi-components-0.0.js
+++ b/res/controllers/midi-components-0.0.js
@@ -308,21 +308,6 @@
shift: function() {
this.inKey = "hotcue_" + this.number + "_clear";
},
- getColor: function(colorCode) {
- if (colorCode === undefined && this.colorKey !== undefined) {
- colorCode = engine.getValue(this.group, this.colorKey);
- }
-
- if (colorCode !== undefined) {
- return {
- "red": (colorCode >> 16) & 0xFF,
- "green": (colorCode >> 8) & 0xFF,
- "blue": colorCode & 0xFF,
- };
- }
-
- return null;
- },
output: function(value) {
var outval = this.outValueScale(value);
// WARNING: outputColor only handles hotcueColors
@@ -344,7 +329,7 @@
print("ERROR: no function defined for sending RGB colors");
return;
}
- this.sendRGB(this.getColor(colorCode));
+ this.sendRGB(colorCodeToColor(colorCode));
}
},
connect: function() {