Remove unneeded slots
This commit is contained in:
@@ -62,7 +62,7 @@ void MoodbarController::CurrentSongChanged(const Song &song) {
|
|||||||
const MoodbarLoader::LoadResult load_result = moodbar_loader_->Load(song.url(), song.has_cue());
|
const MoodbarLoader::LoadResult load_result = moodbar_loader_->Load(song.url(), song.has_cue());
|
||||||
switch (load_result.status) {
|
switch (load_result.status) {
|
||||||
case MoodbarLoader::LoadStatus::CannotLoad:
|
case MoodbarLoader::LoadStatus::CannotLoad:
|
||||||
Q_EMIT CurrentMoodbarDataChanged(QByteArray());
|
Q_EMIT CurrentMoodbarDataChanged();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case MoodbarLoader::LoadStatus::Loaded:
|
case MoodbarLoader::LoadStatus::Loaded:
|
||||||
@@ -71,7 +71,7 @@ void MoodbarController::CurrentSongChanged(const Song &song) {
|
|||||||
|
|
||||||
case MoodbarLoader::LoadStatus::WillLoadAsync:
|
case MoodbarLoader::LoadStatus::WillLoadAsync:
|
||||||
// Emit an empty array for now so the GUI reverts to a normal progressbar. Our slot will be called when the data is actually loaded.
|
// Emit an empty array for now so the GUI reverts to a normal progressbar. Our slot will be called when the data is actually loaded.
|
||||||
Q_EMIT CurrentMoodbarDataChanged(QByteArray());
|
Q_EMIT CurrentMoodbarDataChanged();
|
||||||
|
|
||||||
MoodbarPipelinePtr pipeline = load_result.pipeline;
|
MoodbarPipelinePtr pipeline = load_result.pipeline;
|
||||||
Q_ASSERT(pipeline);
|
Q_ASSERT(pipeline);
|
||||||
@@ -88,7 +88,7 @@ void MoodbarController::CurrentSongChanged(const Song &song) {
|
|||||||
void MoodbarController::PlaybackStopped() {
|
void MoodbarController::PlaybackStopped() {
|
||||||
|
|
||||||
if (enabled_) {
|
if (enabled_) {
|
||||||
Q_EMIT CurrentMoodbarDataChanged(QByteArray());
|
Q_EMIT CurrentMoodbarDataChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -43,14 +43,14 @@ class MoodbarController : public QObject {
|
|||||||
void ReloadSettings();
|
void ReloadSettings();
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
void CurrentMoodbarDataChanged(const QByteArray &data);
|
void CurrentMoodbarDataChanged(const QByteArray &data = QByteArray());
|
||||||
void StyleChanged();
|
void StyleChanged();
|
||||||
|
|
||||||
public Q_SLOTS:
|
public Q_SLOTS:
|
||||||
void CurrentSongChanged(const Song &song);
|
void CurrentSongChanged(const Song &song);
|
||||||
void PlaybackStopped();
|
void PlaybackStopped();
|
||||||
|
|
||||||
private Q_SLOTS:
|
private:
|
||||||
void AsyncLoadComplete(MoodbarPipelinePtr pipeline, const QUrl &url);
|
void AsyncLoadComplete(MoodbarPipelinePtr pipeline, const QUrl &url);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|||||||
@@ -55,13 +55,14 @@ class MoodbarItemDelegate : public QItemDelegate {
|
|||||||
private Q_SLOTS:
|
private Q_SLOTS:
|
||||||
void ReloadSettings();
|
void ReloadSettings();
|
||||||
|
|
||||||
|
Q_SIGNALS:
|
||||||
|
void StyleChanged();
|
||||||
|
|
||||||
|
private:
|
||||||
void DataLoaded(const QUrl &url, MoodbarPipelinePtr pipeline);
|
void DataLoaded(const QUrl &url, MoodbarPipelinePtr pipeline);
|
||||||
void ColorsLoaded(const QUrl &url, const ColorVector &colors);
|
void ColorsLoaded(const QUrl &url, const ColorVector &colors);
|
||||||
void ImageLoaded(const QUrl &url, const QImage &image);
|
void ImageLoaded(const QUrl &url, const QImage &image);
|
||||||
|
|
||||||
Q_SIGNALS:
|
|
||||||
void StyleChanged();
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
struct Data {
|
struct Data {
|
||||||
Data();
|
Data();
|
||||||
|
|||||||
@@ -70,13 +70,11 @@ class MoodbarLoader : public QObject {
|
|||||||
|
|
||||||
LoadResult Load(const QUrl &url, const bool has_cue);
|
LoadResult Load(const QUrl &url, const bool has_cue);
|
||||||
|
|
||||||
private Q_SLOTS:
|
|
||||||
void RequestFinished(MoodbarPipelinePtr pipeline, const QUrl &url);
|
|
||||||
void MaybeTakeNextRequest();
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
static QStringList MoodFilenames(const QString &song_filename);
|
static QStringList MoodFilenames(const QString &song_filename);
|
||||||
static QUrl CacheUrlEntry(const QString &filename);
|
static QUrl CacheUrlEntry(const QString &filename);
|
||||||
|
void RequestFinished(MoodbarPipelinePtr pipeline, const QUrl &url);
|
||||||
|
void MaybeTakeNextRequest();
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
void MoodbarEnabled(const bool enabled);
|
void MoodbarEnabled(const bool enabled);
|
||||||
|
|||||||
Reference in New Issue
Block a user