Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/2.4' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
daschuer committed Feb 22, 2024
2 parents d21cb08 + 7c6324e commit 99bc5c2
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 19 deletions.
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2425,7 +2425,7 @@ string(REPLACE ";" "|" CMAKE_PREFIX_PATH_ALT_SEP "${CMAKE_PREFIX_PATH}")
option(KEYFINDER "KeyFinder support" ON)
if(KEYFINDER)
set(MIN_LIBKEYFINDER_VERSION 2.2.4)
set(FETCH_LIBKEYFINDER_VERSION 2.2.6)
set(FETCH_LIBKEYFINDER_VERSION 2.2.8)
find_package(KeyFinder ${MIN_LIBKEYFINDER_VERSION})
if (KeyFinder_FOUND)
target_link_libraries(mixxx-lib PRIVATE KeyFinder::KeyFinder)
Expand All @@ -2443,8 +2443,8 @@ if(KEYFINDER)
# copy it into DOWNLOAD_DIR under DOWNLOAD_NAME prior to starting
# the configuration.
ExternalProject_Add(libkeyfinder
URL "https://github.com/mixxxdj/libkeyfinder/archive/refs/tags/v${FETCH_LIBKEYFINDER_VERSION}.zip"
URL_HASH SHA256=f15deb56c2dcaa6b10dc3717a7d2f42a8407c04ad550f694de42118be998d256
URL "https://github.com/mixxxdj/libkeyfinder/archive/refs/tags/${FETCH_LIBKEYFINDER_VERSION}.zip"
URL_HASH SHA256=4f10e9e5673d948776e47e78273fa4d61408155cb0e210af1538c83222f285d4
DOWNLOAD_DIR "${CMAKE_CURRENT_BINARY_DIR}/downloads"
DOWNLOAD_NAME "libkeyfinder-${FETCH_LIBKEYFINDER_VERSION}.zip"
INSTALL_DIR "${KeyFinder_INSTALL_DIR}"
Expand Down
23 changes: 9 additions & 14 deletions res/controllers/Traktor-Kontrol-S3-hid-scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -286,21 +286,16 @@ TraktorS3.Controller = class {
engine.makeConnection(ch, "end_of_track",
TraktorS3.Channel.prototype.endOfTrackHandler.bind(chanob));
}
// Set each InputReport to the bitwise inverted state first,
// and than apply the non-inverted initial state.
// This is done, because the common-hid-packet-parser only triggers
// the callback functions in case of a delta to the previous data.
for (let inputReportIdx = 0x01; inputReportIdx <= 0x02; ++inputReportIdx) {
const reportData = new Uint8Array(controller.getInputReport(inputReportIdx));

// Query the current values from the controller and set them. The packet
// parser ignores the first time a value is set, so we'll need to set it
// with different values once. Report 2 contains the state of the mixer
// controls.
const report2Values = new Uint8Array(controller.getInputReport(2));
TraktorS3.incomingData(new Uint8Array([2, ...Uint8Array.from(report2Values.map(x => ~x))]));
TraktorS3.incomingData(new Uint8Array([2, ...Uint8Array.from(report2Values)]));

// Report 1 is the state of the deck controls. These shouldn't have any
// initial effect, and most of these values will be 0 anyways. We'll
// just tell the packet parser the current values so it won't ignore the
// next input.
const report1Values = new Uint8Array(controller.getInputReport(1));
TraktorS3.incomingData(new Uint8Array([1, ...Uint8Array.from(report1Values)]));
TraktorS3.incomingData([inputReportIdx, ...reportData.map(x => ~x)]);
TraktorS3.incomingData([inputReportIdx, ...reportData]);
}

// NOTE: Soft takeovers must only be enabled after setting the initial
// value, or the above line won't have any effect
Expand Down
6 changes: 5 additions & 1 deletion src/sources/soundsourcemp3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,11 @@ inline bool isUnrecoverableError(mad_error error) {
return (MAD_ERROR_NONE != error) && !MAD_RECOVERABLE(error);
}

inline bool hasUnrecoverableError(const mad_stream* pMadStream) {
#ifndef MIXXX_DEBUG_ASSERTIONS_ENABLED
[[maybe_unused]]
#endif
inline bool
hasUnrecoverableError(const mad_stream* pMadStream) {
if (pMadStream) {
return isUnrecoverableError(pMadStream->error);
}
Expand Down
2 changes: 1 addition & 1 deletion tools/json2github.py
Original file line number Diff line number Diff line change
Expand Up @@ -630,7 +630,7 @@ def run_import(self, lp_issues, lp_milestones):
lp_issues[issuedata["id"]]["gh_status_comment_imported"] = True
self.logger.info(
f"Imported {i}/{num_issues} "
f"({'{:.2f}'.format((i/num_issues)*100)}%)"
f"({'{:.2f}'.format((i / num_issues) * 100)}%)"
)

for issuedata in sorted(
Expand Down

0 comments on commit 99bc5c2

Please sign in to comment.