Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Traktor S3: fixes and updates #12409

Merged
merged 3 commits into from Dec 11, 2023
Merged

Traktor S3: fixes and updates #12409

merged 3 commits into from Dec 11, 2023

Conversation

ywwg
Copy link
Member

@ywwg ywwg commented Dec 8, 2023

Trying to get rid of warnings for this deck

Fixes main vu meter output connections
Update to use non-deprecated makeConnection function
Update hotcue status CO name

Fixes main vu meter output connections
Update to use non-deprecated makeConnection function
@ywwg
Copy link
Member Author

ywwg commented Dec 8, 2023

this controller also needs #12406 to work

@@ -2077,9 +2077,9 @@ class HIDController {
continue;
}
const bitControlGroup = this.resolveGroup(bit.mapped_group);
engine.connectControl(
engine.makeConnection(
bitControlGroup, bit.mapped_name, bit.mapped_callback, true);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

makeConnection has not 4th parameter as connectControl. See

* Connects a specified Mixxx Control with a callback function, which is executed if the value of the control changes
*
* This connection has a FIFO buffer - all value change events are processed in serial order.
*
* @param group Group of the control e.g. "[Channel1]"
* @param name Name of the control e.g. "play_indicator"
* @param callback JS function, which will be called every time, the value of the connected control changes.
* @returns Returns script connection object on success, otherwise 'undefined''
*/
function makeConnection(group: string, name: string, callback: CoCallback): ScriptConnection |undefined;

vs.
/**
* This function is a legacy version of makeConnection with several alternate
* ways of invoking it. The callback function can be passed either as a string of
* JavaScript code that evaluates to a function or an actual JavaScript function.
*
* @param group Group of the control e.g. "[Channel1]"
* @param name Name of the control e.g. "vu_meter"
* @param callback JS function, which will be called every time, the value of the connected control changes.
* @param disconnect If "true", all connections to the ControlObject are removed. [default = false]
* @returns Returns script connection object on success, otherwise 'undefined' or 'false' depending on the error cause.
* @deprecated Use {@link makeConnection} instead
*/
function connectControl(group: string, name: string, callback: CoCallback, disconnect?: boolean): ScriptConnection | boolean | undefined;

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh that's the difference! I was wondering

@@ -2169,7 +2169,7 @@ class HIDController {
return;
}
const controlgroup = this.resolveGroup(field.mapped_group);
engine.connectControl(controlgroup, field.mapped_name, callback, true);
engine.makeConnection(controlgroup, field.mapped_name, callback, true);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here

@JoergAtGithub
Copy link
Member

LGTM! Thank you!

@JoergAtGithub JoergAtGithub merged commit 86208d6 into mixxxdj:2.4 Dec 11, 2023
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants