/usr/share/mixxx/controllers/MixVibes-U-Mix-Control-Pro-2-scripts.js is in mixxx-data 2.0.0~dfsg-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | function ControlPro2() {}
ControlPro2.scratching = [];
// The button that enables/disables scratching
ControlPro2.wheelTouch = function (channel, control, value, status, group) {
var deck = script.deckFromGroup(group);
if (value == 0x7F) {
var alpha = 1.0/8;
var beta = alpha/32;
engine.scratchEnable(deck, 340, 33+1/3, alpha, beta);
}
else { // If button up
engine.scratchDisable(deck);
}
}
// The wheel that actually controls the scratching
ControlPro2.wheelTurn = function (channel, control, value, status, group) {
// See if we're scratching. If not, do wheel jog.
var deck = script.deckFromGroup(group);
var newValue=(value-64);
if (!engine.isScratching(deck)) {
engine.setValue(group, "jog", newValue/4);
return;
}
engine.scratchTick(deck,newValue);
}
|