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 Aug 30, 2023
2 parents dace66c + 6f65df2 commit ffc617f
Show file tree
Hide file tree
Showing 22 changed files with 60 additions and 51 deletions.
7 changes: 7 additions & 0 deletions .codespellignorelines
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,10 @@ void EngineEffectsDelay::process(CSAMPLE* pInOut,
effectsDelay.process(pInOut.data(), bufferSizeInSamples);
} else if (!strcmp(pavInputFormat->name, "caf")) {
list.append("caf");
// Adopted from Csound code at http://www.kunstmusik.com/udo/cache/moogladder.udo
<< "-alac.caf"
// Test fails for file type "caf" supported by SoundSourceSndfile
//QStringLiteral("caf"),
// Source: FIPS 180-4 Secure Hash Standard (SHS)
// ALAC/CAF has been added in version 1.0.26
QStringLiteral("caf"),
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
# because it won't prevent catching other, unrelated issues.

# _anlz.h/_pdb.h: Header files generated by Kaitai Struct
exclude: ^(lib/|src/test/.*data/).*|res/translations/.*\.ts|src/.*_(anlz|pdb)\.h$
exclude: ^(lib/|src/test/.*data/).*|res/controllers/lodash\.mixxx\.js|res/translations/.*\.ts|src/.*_(anlz|pdb)\.h$
minimum_pre_commit_version: 2.21.0
default_language_version:
python: python3
Expand Down
2 changes: 1 addition & 1 deletion CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ they are doing - politely bringing their behavior to their attention is
encouraged.

If you are uncomfortable speaking up, or feel that your concerns are not being
duly considered, you can email community@mixxx.org to request involvement
duly considered, you can email <community@mixxx.org> to request involvement
from a community manager. You may also email any of the community managers
directly. All concerns shared with community managers will be kept
confidential. In cases where a public response is deemed necessary, the
Expand Down
3 changes: 3 additions & 0 deletions packaging/debian/control.in
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ Build-Depends: debhelper (>= 11),
libdjinterop-dev,
libmsgsl-dev,
# for running mixxx-test
libgtest-dev,
libgmock-dev,
libbenchmark-dev,
xvfb
Rules-Requires-Root: no
Standards-Version: 4.1.4
Expand Down
2 changes: 1 addition & 1 deletion res/controllers/Roland_DJ-505-scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,7 @@ DJ505.Sampler = function() {
*
* 1. Standalone mode
*
* When the controller is in standlone mode, the controller's TR-S works
* When the controller is in standalone mode, the controller's TR-S works
* with the SERATO SAMPLER and SYNC functionality disabled. Also, it's not
* possible to apply FX to the TR-S output signal. The TR/SAMPLER LEVEL
* knob can be used to adjust the volume of the output.
Expand Down
2 changes: 1 addition & 1 deletion src/engine/sync/synccontrol.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ class SyncControl : public EngineControl, public Syncable {
mixxx::Bpm getLocalBpm() const;

QString m_sGroup;
// The only reason we have this pointer is an optimzation so that the
// The only reason we have this pointer is an optimization so that the
// EngineSync can ask us what our EngineChannel is. EngineMaster in turn
// asks EngineSync what EngineChannel is the "leader" channel.
EngineChannel* m_pChannel;
Expand Down
28 changes: 14 additions & 14 deletions src/library/coverartcache.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,15 @@ CoverArtCache::CoverArtCache() {

//static
void CoverArtCache::requestCover(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const TrackPointer& pTrack) {
CoverArtCache* pCache = CoverArtCache::instance();
VERIFY_OR_DEBUG_ASSERT(pCache) {
return;
}
pCache->tryLoadCover(
pRequestor,
pRequester,
pTrack,
coverInfo,
0, // original size
Expand All @@ -62,27 +62,27 @@ void CoverArtCache::requestCover(

//static
void CoverArtCache::requestTrackCover(
const QObject* pRequestor,
const QObject* pRequester,
const TrackPointer& pTrack) {
VERIFY_OR_DEBUG_ASSERT(pTrack) {
return;
}
requestCover(
pRequestor,
pRequester,
pTrack->getCoverInfoWithLocation(),
pTrack);
}

QPixmap CoverArtCache::tryLoadCover(
const QObject* pRequestor,
const QObject* pRequester,
const TrackPointer& pTrack,
const CoverInfo& coverInfo,
int desiredWidth,
Loading loading) {
if (kLogger.traceEnabled()) {
kLogger.trace()
<< "requestCover"
<< pRequestor
<< pRequester
<< coverInfo
<< desiredWidth
<< loading;
Expand All @@ -94,14 +94,14 @@ QPixmap CoverArtCache::tryLoadCover(

if (coverInfo.type == CoverInfo::NONE) {
if (loading == Loading::Default) {
emit coverFound(pRequestor, coverInfo, QPixmap(), requestedCacheKey, false);
emit coverFound(pRequester, coverInfo, QPixmap(), requestedCacheKey, false);
}
return QPixmap();
}

// keep a list of trackIds for which a future is currently running
// to avoid loading the same picture again while we are loading it
QPair<const QObject*, mixxx::cache_key_t> requestId = qMakePair(pRequestor, requestedCacheKey);
QPair<const QObject*, mixxx::cache_key_t> requestId = qMakePair(pRequester, requestedCacheKey);
if (m_runningRequests.contains(requestId)) {
return QPixmap();
}
Expand All @@ -122,7 +122,7 @@ QPixmap CoverArtCache::tryLoadCover(
<< loading;
}
if (loading == Loading::Default) {
emit coverFound(pRequestor, coverInfo, pixmap, requestedCacheKey, false);
emit coverFound(pRequester, coverInfo, pixmap, requestedCacheKey, false);
}
return pixmap;
}
Expand All @@ -144,7 +144,7 @@ QPixmap CoverArtCache::tryLoadCover(
QFutureWatcher<FutureResult>* watcher = new QFutureWatcher<FutureResult>(this);
QFuture<FutureResult> future = QtConcurrent::run(
&CoverArtCache::loadCover,
pRequestor,
pRequester,
pTrack,
coverInfo,
desiredWidth,
Expand All @@ -159,7 +159,7 @@ QPixmap CoverArtCache::tryLoadCover(

//static
CoverArtCache::FutureResult CoverArtCache::loadCover(
const QObject* pRequestor,
const QObject* pRequester,
TrackPointer pTrack,
CoverInfo coverInfo,
int desiredWidth,
Expand All @@ -175,7 +175,7 @@ CoverArtCache::FutureResult CoverArtCache::loadCover(
pTrack->getLocation() == coverInfo.trackLocation);

auto res = FutureResult(
pRequestor,
pRequester,
coverInfo.cacheKey(),
signalWhenDone);
DEBUG_ASSERT(!res.coverInfoUpdated);
Expand Down Expand Up @@ -265,11 +265,11 @@ void CoverArtCache::coverLoaded() {
}
}

m_runningRequests.remove(qMakePair(res.pRequestor, res.requestedCacheKey));
m_runningRequests.remove(qMakePair(res.pRequester, res.requestedCacheKey));

if (res.signalWhenDone) {
emit coverFound(
res.pRequestor,
res.pRequester,
std::move(res.coverArt),
pixmap,
res.requestedCacheKey,
Expand Down
26 changes: 13 additions & 13 deletions src/library/coverartcache.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,17 @@ class CoverArtCache : public QObject, public Singleton<CoverArtCache> {
Q_OBJECT
public:
static void requestCover(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo) {
requestCover(pRequestor, coverInfo, TrackPointer());
requestCover(pRequester, coverInfo, TrackPointer());
}
static void requestTrackCover(
const QObject* pRequestor,
const QObject* pRequester,
const TrackPointer& pTrack);

/* This method is used to request a cover art pixmap.
*
* @param pRequestor : an arbitrary pointer (can be any number you'd like,
* @param pRequester : an arbitrary pointer (can be any number you'd like,
* really) that will be provided in the coverFound signal for this
* request. This allows you to match requests with their responses.
*
Expand All @@ -40,12 +40,12 @@ class CoverArtCache : public QObject, public Singleton<CoverArtCache> {
Default, // signal when done
};
QPixmap tryLoadCover(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& info,
int desiredWidth = 0, // <= 0: original size
Loading loading = Loading::Default) {
return tryLoadCover(
pRequestor,
pRequester,
TrackPointer(),
info,
desiredWidth,
Expand All @@ -55,7 +55,7 @@ class CoverArtCache : public QObject, public Singleton<CoverArtCache> {
// Only public for testing
struct FutureResult {
FutureResult()
: pRequestor(nullptr),
: pRequester(nullptr),
requestedCacheKey(CoverImageUtils::defaultCacheKey()),
signalWhenDone(false),
coverInfoUpdated(false) {
Expand All @@ -64,13 +64,13 @@ class CoverArtCache : public QObject, public Singleton<CoverArtCache> {
const QObject* pRequestorArg,
mixxx::cache_key_t requestedCacheKeyArg,
bool signalWhenDoneArg)
: pRequestor(pRequestorArg),
: pRequester(pRequestorArg),
requestedCacheKey(requestedCacheKeyArg),
signalWhenDone(signalWhenDoneArg),
coverInfoUpdated(false) {
}

const QObject* pRequestor;
const QObject* pRequester;
mixxx::cache_key_t requestedCacheKey;
bool signalWhenDone;

Expand All @@ -80,7 +80,7 @@ class CoverArtCache : public QObject, public Singleton<CoverArtCache> {
// Load cover from path indicated in coverInfo. WARNING: This is run in a
// worker thread.
static FutureResult loadCover(
const QObject* pRequestor,
const QObject* pRequester,
TrackPointer pTrack,
CoverInfo coverInfo,
int desiredWidth,
Expand All @@ -92,7 +92,7 @@ class CoverArtCache : public QObject, public Singleton<CoverArtCache> {

signals:
void coverFound(
const QObject* requestor,
const QObject* requester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
Expand All @@ -105,12 +105,12 @@ class CoverArtCache : public QObject, public Singleton<CoverArtCache> {

private:
static void requestCover(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const TrackPointer& /*optional*/ pTrack);

QPixmap tryLoadCover(
const QObject* pRequestor,
const QObject* pRequester,
const TrackPointer& pTrack,
const CoverInfo& info,
int desiredWidth,
Expand Down
4 changes: 2 additions & 2 deletions src/library/coverartdelegate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,13 @@ void CoverArtDelegate::slotInhibitLazyLoading(
}

void CoverArtDelegate::slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedImageHash,
bool coverInfoUpdated) {
Q_UNUSED(pixmap);
if (pRequestor != this) {
if (pRequester != this) {
return;
}
if (coverInfoUpdated) {
Expand Down
2 changes: 1 addition & 1 deletion src/library/coverartdelegate.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class CoverArtDelegate : public TableItemDelegate {

private slots:
void slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedImageHash,
Expand Down
2 changes: 1 addition & 1 deletion src/library/dao/playlistdao.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class PlaylistDAO : public QObject, public virtual DAO {
bool deleteUnlockedPlaylists(QStringList&& idStringList);
/// Delete Playlists with fewer entries then "minNumberOfTracks"
/// Needs to be called inside a transaction.
/// @return true on success, flase on error
/// @return true on success, false on error
bool deleteAllUnlockedPlaylistsWithFewerTracks(const PlaylistDAO::HiddenType type,
int minNumberOfTracks);
// Rename a playlist
Expand Down
4 changes: 2 additions & 2 deletions src/library/dlgcoverartfullsize.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -158,14 +158,14 @@ void DlgCoverArtFullSize::slotTrackCoverArtUpdated() {
}

void DlgCoverArtFullSize::slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
bool coverInfoUpdated) {
Q_UNUSED(requestedCacheKey);
Q_UNUSED(coverInfoUpdated);
if (pRequestor != this || !m_pLoadedTrack ||
if (pRequester != this || !m_pLoadedTrack ||
m_pLoadedTrack->getLocation() != coverInfo.trackLocation) {
return;
}
Expand Down
2 changes: 1 addition & 1 deletion src/library/dlgcoverartfullsize.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class DlgCoverArtFullSize
public slots:
void slotLoadTrack(TrackPointer);
void slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
Expand Down
4 changes: 2 additions & 2 deletions src/library/dlgtagfetcher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -527,14 +527,14 @@ void DlgTagFetcher::tagSelected() {
}

void DlgTagFetcher::slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
bool coverInfoUpdated) {
Q_UNUSED(requestedCacheKey);
Q_UNUSED(coverInfoUpdated);
if (pRequestor == this &&
if (pRequester == this &&
m_pTrack &&
m_pTrack->getLocation() == coverInfo.trackLocation) {
m_trackRecord.setCoverInfo(coverInfo);
Expand Down
2 changes: 1 addition & 1 deletion src/library/dlgtagfetcher.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class DlgTagFetcher : public QDialog, public Ui::DlgTagFetcher {
void slotNext();
void slotPrev();
void slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
Expand Down
4 changes: 2 additions & 2 deletions src/library/dlgtrackinfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -512,14 +512,14 @@ void DlgTrackInfo::focusField(const QString& property) {
}

void DlgTrackInfo::slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
bool coverInfoUpdated) {
Q_UNUSED(requestedCacheKey);
Q_UNUSED(coverInfoUpdated);
if (pRequestor == this &&
if (pRequester == this &&
m_pLoadedTrack &&
m_pLoadedTrack->getLocation() == coverInfo.trackLocation) {
m_trackRecord.setCoverInfo(coverInfo);
Expand Down
2 changes: 1 addition & 1 deletion src/library/dlgtrackinfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class DlgTrackInfo : public QDialog, public Ui::DlgTrackInfo {
void slotColorButtonClicked();

void slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& info,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
Expand Down
4 changes: 2 additions & 2 deletions src/widget/wcoverart.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ void WCoverArt::slotTrackCoverArtUpdated() {
}

void WCoverArt::slotCoverFound(
const QObject* pRequestor,
const QObject* pRequester,
const CoverInfo& coverInfo,
const QPixmap& pixmap,
mixxx::cache_key_t requestedCacheKey,
Expand All @@ -160,7 +160,7 @@ void WCoverArt::slotCoverFound(
return;
}

if (pRequestor == this &&
if (pRequester == this &&
m_loadedTrack &&
m_loadedTrack->getLocation() == coverInfo.trackLocation) {
m_lastRequestedCover = coverInfo;
Expand Down
Loading

0 comments on commit ffc617f

Please sign in to comment.