diff options
author | Arno <arno@disconnect.de> | 2017-09-21 19:53:05 +0200 |
---|---|---|
committer | Arno <arno@disconnect.de> | 2017-09-21 19:53:05 +0200 |
commit | ff7e948a9494b82ac3daae00e2c35675a2bb7233 (patch) | |
tree | 9907de7221ad33c99f34c3f24108b31d6ac25f3a /playerwidget.h | |
parent | e2d0533a7cb1ac3dcc80df20d2710c12d67f15e0 (diff) | |
download | BeetPlayer-ff7e948a9494b82ac3daae00e2c35675a2bb7233.tar.gz BeetPlayer-ff7e948a9494b82ac3daae00e2c35675a2bb7233.tar.bz2 BeetPlayer-ff7e948a9494b82ac3daae00e2c35675a2bb7233.zip |
Implement Favorites view
And make it possible to remove songs from favorites!
Diffstat (limited to 'playerwidget.h')
-rw-r--r-- | playerwidget.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/playerwidget.h b/playerwidget.h index 44896db..e5764e5 100644 --- a/playerwidget.h +++ b/playerwidget.h @@ -31,6 +31,7 @@ class PlayerWidget : public QWidget { enum ItemType { Artist, Album, Song, Genre, WebRadio }; enum PopulateType { FilterType, IdType, EmptyType }; enum CustomRoles { TypeRole = Qt::UserRole + 1, IdRole = Qt::UserRole + 2, FullPathRole = Qt::UserRole + 3, GenreRole = Qt::UserRole + 4, ArtistRole = Qt::UserRole + 5, TitleRole = Qt::UserRole + 6, AlbumRole = Qt::UserRole + 7, LengthRole = Qt::UserRole + 8, UrlRole = Qt::UserRole + 9, RemoteRole = Qt::UserRole + 10 }; + enum ModelType { Webradio, Favorites, Folders, DoNotCare }; explicit PlayerWidget(QWidget *parent = 0); ~PlayerWidget(); const QMediaPlayer* player() const { return mPlayer; } @@ -65,6 +66,7 @@ class PlayerWidget : public QWidget { void addToPlayList(); void addToPlayListAndClear(); void removeFromPlayList(); + void removeFromFavorites(); void addToFavorites(); void clearPlayList(); void shufflePlayList(); @@ -149,6 +151,7 @@ class PlayerWidget : public QWidget { QAction *mDeselectAllA; QAction *mDeleteFilesA; QAction *mRefreshA; + QAction *mRemoveFromFavoritesA; qint64 mDurSecs; quint64 mPlayListLength; QString mCurDir; @@ -161,6 +164,7 @@ class PlayerWidget : public QWidget { WebDownloader *mWebDownloader; QMap<QString, QVariant> mOtherMeta; bool mIsStream; + int mModelType; }; #endif // PLAYERWIDGET_H |