Jellyfin Qt
QML Library for interacting with the Jellyfin multimedia server
|
Model of a playlist, a list of items that can be played. More...
#include <playlist.h>
Signals | |
void | beforeListCleared () |
void | listCleared () |
void | beforeItemsAddedToQueue (int index, int count) |
void | beforeItemsAddedToList (int index, int count) |
void | itemsAddedToQueue () |
void | itemsAddedToList () |
void | beforeItemsRemovedFromQueue (int index, int count) |
void | beforeItemsRemovedFromList (int index, int count) |
void | itemsRemovedFromQueue () |
void | itemsRemovedFromList () |
void | listReshuffled () |
void | currentItemChanged () |
Public Member Functions | |
Playlist (QObject *parent=nullptr) | |
QSharedPointer< Item > | currentItem () |
Returns the current item in the queue. | |
QSharedPointer< Item > | nextItem () |
int | currentItemIndexInList () const |
bool | hasPrevious () |
void | previous () |
Determine the previous item to be played. | |
bool | hasNext () |
void | next () |
Determine the next item to be played. | |
QList< QSharedPointer< Item > > | queueAndList () const |
Returns all items in the queue. | |
int | queueSize () |
int | listSize () const |
int | totalSize () const |
QSharedPointer< const Item > | listAt (int index) const |
Returns the item at the given index of the currently selected playlist, excluding the queue. | |
QSharedPointer< const Item > | queueAt (int index) const |
Returns the item at the given index of the currently queue, excluding the playlist. | |
void | clearList () |
Removes all the items from the playlist, but not from the queue. | |
void | appendToList (const QList< QSharedPointer< Item > > &model) |
Appends all items from the given item list to this list. | |
void | appendToList (QSharedPointer< Model::Item > item) |
appendToList Appends a single item to the current list | |
void | play (int index=0) |
Start playing this playlist. | |
bool | playingFromQueue () const |
playingFromQueue | |
Model of a playlist, a list of items that can be played.
This tries to take the managing what items to play away from the PlaybackManager, which now only will be informed about the current and next item to play.
The playlist has actually two list, one named list and the other named queue. When playing, the queue has priority over the list and will not be affected by the shuffle mode. After all items of the queue are played, the items in the list are played. Items in the list may be shuffled.
|
explicit |
Appends all items from the given item list to this list.
void Jellyfin::Model::Playlist::appendToList | ( | QSharedPointer< Model::Item > | item | ) |
appendToList Appends a single item to the current list
item | The item to append |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
void Jellyfin::Model::Playlist::clearList | ( | ) |
Removes all the items from the playlist, but not from the queue.
QSharedPointer< Item > Jellyfin::Model::Playlist::currentItem | ( | ) |
Returns the current item in the queue.
|
signal |
int Jellyfin::Model::Playlist::currentItemIndexInList | ( | ) | const |
bool Jellyfin::Model::Playlist::hasNext | ( | ) |
bool Jellyfin::Model::Playlist::hasPrevious | ( | ) |
|
signal |
|
signal |
|
signal |
|
signal |
QSharedPointer< const Item > Jellyfin::Model::Playlist::listAt | ( | int | index | ) | const |
Returns the item at the given index of the currently selected playlist, excluding the queue.
index |
|
signal |
|
signal |
|
inline |
void Jellyfin::Model::Playlist::next | ( | ) |
Determine the next item to be played.
QSharedPointer< Item > Jellyfin::Model::Playlist::nextItem | ( | ) |
void Jellyfin::Model::Playlist::play | ( | int | index = 0 | ) |
Start playing this playlist.
index | The index to start from. |
bool Jellyfin::Model::Playlist::playingFromQueue | ( | ) | const |
playingFromQueue
void Jellyfin::Model::Playlist::previous | ( | ) |
Determine the previous item to be played.
Returns all items in the queue.
QSharedPointer< const Item > Jellyfin::Model::Playlist::queueAt | ( | int | index | ) | const |
Returns the item at the given index of the currently queue, excluding the playlist.
index |
|
inline |
|
inline |