Includes in alphabetical order, moved Player ReloadSettings() to Player init
This commit is contained in:
parent
1120f97844
commit
e4df00050d
|
@ -29,10 +29,10 @@
|
|||
|
||||
#include <memory>
|
||||
|
||||
#include <QSettings>
|
||||
#include <QSortFilterProxyModel>
|
||||
#include <QtDebug>
|
||||
#include <QtConcurrentRun>
|
||||
#include <QSettings>
|
||||
|
||||
#include "config.h"
|
||||
#include "core/application.h"
|
||||
|
@ -62,7 +62,8 @@ Player::Player(Application* app, QObject* parent)
|
|||
last_state_(Engine::Empty),
|
||||
nb_errors_received_(0),
|
||||
volume_before_mute_(50),
|
||||
last_pressed_previous_(QDateTime::currentDateTime()) {
|
||||
last_pressed_previous_(QDateTime::currentDateTime()),
|
||||
menu_previousmode_(PreviousBehaviour_DontRestart) {
|
||||
settings_.beginGroup("Player");
|
||||
|
||||
SetVolume(settings_.value("volume", 50).toInt());
|
||||
|
@ -89,6 +90,8 @@ void Player::Init() {
|
|||
|
||||
engine_->SetVolume(settings_.value("volume", 50).toInt());
|
||||
|
||||
ReloadSettings();
|
||||
|
||||
#ifdef HAVE_LIBLASTFM
|
||||
lastfm_ = app_->scrobbler();
|
||||
#endif
|
||||
|
|
|
@ -29,9 +29,9 @@
|
|||
|
||||
#include <memory>
|
||||
|
||||
#include <QDateTime>
|
||||
#include <QObject>
|
||||
#include <QSettings>
|
||||
#include <QDateTime>
|
||||
|
||||
#include "config.h"
|
||||
#include "core/song.h"
|
||||
|
|
|
@ -216,7 +216,6 @@ MainWindow::MainWindow(Application* app, SystemTrayIcon* tray_icon, OSD* osd,
|
|||
int volume = app_->player()->GetVolume();
|
||||
ui_->volume->setValue(volume);
|
||||
VolumeChanged(volume);
|
||||
app_->player()->ReloadSettings();
|
||||
|
||||
// Initialise the global search widget
|
||||
StyleHelper::setBaseColor(palette().color(QPalette::Highlight).darker());
|
||||
|
|
Loading…
Reference in New Issue