Skip to content

Commit

Permalink
Merge pull request #3453 from Be-ing/coreservices_regressions
Browse files Browse the repository at this point in the history
fix regressions from CoreServices refactoring
  • Loading branch information
uklotzde authored Dec 15, 2020
2 parents 1baea63 + 215e95d commit 648bc1d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
4 changes: 4 additions & 0 deletions src/coreservices.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -367,6 +367,8 @@ void CoreServices::initialize(QApplication* pApp) {
// https://bugs.launchpad.net/mixxx/+bug/1758189
m_pPlayerManager->loadSamplers();

m_pTouchShift = std::make_unique<ControlPushButton>(ConfigKey("[Controls]", "touch_shift"));

// Load tracks in args.qlMusicFiles (command line arguments) into player
// 1 and 2:
const QList<QString>& musicFiles = m_cmdlineArgs.getMusicFiles();
Expand Down Expand Up @@ -542,6 +544,8 @@ void CoreServices::shutdown() {
// at exit.
m_pSettingsManager->save();

m_pTouchShift.reset();

// Check for leaked ControlObjects and give warnings.
{
const QList<QSharedPointer<ControlDoublePrivate>> leakedControls =
Expand Down
3 changes: 3 additions & 0 deletions src/coreservices.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#pragma once

#include "control/controlpushbutton.h"
#include "preferences/configobject.h"
#include "preferences/constants.h"
#include "preferences/settingsmanager.h"
Expand Down Expand Up @@ -127,6 +128,8 @@ class CoreServices : public QObject {
std::shared_ptr<ConfigObject<ConfigValueKbd>> m_pKbdConfig;
std::shared_ptr<ConfigObject<ConfigValueKbd>> m_pKbdConfigEmpty;

std::unique_ptr<ControlPushButton> m_pTouchShift;

TooltipsPreference m_toolTipsCfg;

Timer m_runtime_timer;
Expand Down
5 changes: 3 additions & 2 deletions src/mixxx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,9 @@ MixxxMainWindow::MixxxMainWindow(
show();
pApp->processEvents();

m_pGuiTick = new GuiTick();
m_pVisualsManager = new VisualsManager();

connect(
m_pCoreServices.get(),
&mixxx::CoreServices::initializationProgressUpdate,
Expand All @@ -120,8 +123,6 @@ MixxxMainWindow::MixxxMainWindow(

installEventFilter(m_pCoreServices->getKeyboardEventFilter().get());

m_pGuiTick = new GuiTick();
m_pVisualsManager = new VisualsManager();
DEBUG_ASSERT(m_pCoreServices->getPlayerManager());
const QStringList visualGroups = m_pCoreServices->getPlayerManager()->getVisualPlayerGroups();
for (const QString& group : visualGroups) {
Expand Down

0 comments on commit 648bc1d

Please sign in to comment.