Jellyfin Qt
QML Library for interacting with the Jellyfin multimedia server
Loading...
Searching...
No Matches
item.h
Go to the documentation of this file.
1/*
2 * Sailfin: a Jellyfin client written using Qt
3 * Copyright (C) 2021 Chris Josten and the Sailfin Contributors.
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 */
19#ifndef JELLYFIN_VIEWMODEL_ITEM_H
20#define JELLYFIN_VIEWMODEL_ITEM_H
21
22#include <QJsonArray>
23#include <QJsonDocument>
24#include <QJsonObject>
25#include <QJsonValue>
26
27#include <QDateTime>
28#include <QDebug>
29#include <QList>
30#include <QObject>
31#include <QQmlListProperty>
32#include <QSharedPointer>
33#include <QUuid>
34
35#include <optional>
36
37#include <cmath>
38
39/*#include "dto.h"
40#include "mediastream.h"
41#include "namedguidpair.h"
42#include "userdata.h"*/
43
45#include "../model/item.h"
46#include "mediastream.h"
47#include "loader.h"
48
49namespace Jellyfin {
50
51namespace DTO {
52class UserItemDataDto;
53} // NS DTO
54
55namespace ViewModel {
56
57class UserData;
58
59namespace {
60 template<typename T>
61 void qqmlistproperty_qlist_append(QQmlListProperty<T> *prop, T *data) {
62 static_cast<QList<T> *>(prop->data())->append(data);
63 }
64
65 template<typename T>
66 void qqmlistproperty_qlist_clear(QQmlListProperty<T> *prop) {
67 static_cast<QList<T> *>(prop->data())->clear();
68 }
69
70 template<typename T>
71 T *qqmlistproperty_qlist_at(QQmlListProperty<T> *prop, qint32 idx) {
72 return &static_cast<QList<T> *>(prop->data())->at(idx);
73 }
74
75 template<typename T>
76 void qqmlistproperty_qlist_count(QQmlListProperty<T> *prop) {
77 static_cast<QList<T> *>(prop->data())->count();
78 }
79}
80
81template <typename T>
82QQmlListProperty<T> qQmlListPropertyFromQList(QObject *object, QList<T> *list) {
83 return QQmlListProperty<T>(object, list, &qqmlistproperty_qlist_append<T>, &qqmlistproperty_qlist_count<T>, &qqmlistproperty_qlist_at<T>, &qqmlistproperty_qlist_clear<T>);
84}
85
86
87class NameGuidPair : public QObject {
88 Q_OBJECT
89 Q_PROPERTY(QString name READ name NOTIFY nameChanged)
90 Q_PROPERTY(QString jellyfinId READ jellyfinId NOTIFY jellyfinIdChanged)
91public:
92 explicit NameGuidPair(QSharedPointer<DTO::NameGuidPair> data = QSharedPointer<DTO::NameGuidPair>::create(QStringLiteral("00000000000000000000000000000000")), QObject *parent = nullptr);
93
94 QString name() const { return m_data->name(); }
95 QString jellyfinId() const { return m_data->jellyfinId(); }
96signals:
97 void nameChanged(const QString &newName);
98 void jellyfinIdChanged(const QString &newJellyfinId);
99
100private:
101 QSharedPointer<DTO::NameGuidPair> m_data;
102};
103
104class Item : public QObject {
105 Q_OBJECT
106public:
107 explicit Item(QObject *parent = nullptr, QSharedPointer<Model::Item> data = QSharedPointer<Model::Item>::create());
108
109 // Please keep the order of the properties the same as in the file linked above.
110 Q_PROPERTY(QString jellyfinId READ jellyfinId NOTIFY jellyfinIdChanged)
111 Q_PROPERTY(QString name READ name NOTIFY nameChanged)
112 Q_PROPERTY(QString originalTitle READ originalTitle NOTIFY originalTitleChanged)
113 Q_PROPERTY(QString serverId READ serverId NOTIFY serverIdChanged)
114 Q_PROPERTY(QString etag READ etag NOTIFY etagChanged)
115 Q_PROPERTY(QString sourceType READ sourceType NOTIFY sourceTypeChanged)
117 Q_PROPERTY(QDateTime dateCreated READ dateCreated NOTIFY dateCreatedChanged)
119 Q_PROPERTY(QString extraType READ extraType NOTIFY extraTypeChanged)
123 /*Q_PROPERTY(bool canDelete READ canDelete NOTIFY canDeleteChanged)
124 Q_PROPERTY(bool canDownload READ canDownload NOTIFY canDownloadChanged)
125 Q_PROPERTY(bool hasSubtitles READ hasSubtitles NOTIFY hasSubtitlesChanged)
126 Q_PROPERTY(QString preferredMetadataLanguage READ preferredMetadataLanguage NOTIFY preferredMetadataLanguageChanged)
127 Q_PROPERTY(QString preferredMetadataCountryCode READ preferredMetadataCountryCode NOTIFY preferredMetadataCountryCodeChanged)
128 Q_PROPERTY(bool supportsSync READ supportsSync NOTIFY supportsSyncChanged)
129 Q_PROPERTY(QString container READ container NOTIFY containerChanged)
130 Q_PROPERTY(QString sortName READ sortName NOTIFY sortNameChanged)
131 Q_PROPERTY(QString forcedSortName READ forcedSortName NOTIFY forcedSortNameChanged)
132 //SKIP: Video3DFormat
133 Q_PROPERTY(QDateTime premiereData READ premiereDate NOTIFY premiereDateChanged)
134 //SKIP: ExternalUrls
135 //SKIP: MediaSources
136 Q_PROPERTY(float criticRating READ criticRating NOTIFY criticRatingChanged)
137 Q_PROPERTY(QStringList productionLocations READ productionLocations NOTIFY productionLocationsChanged)*/
138
139 // Handpicked, important ones
140 Q_PROPERTY(qint64 runTimeTicks READ runTimeTicks NOTIFY runTimeTicksChanged)
141 Q_PROPERTY(QString overview READ overview NOTIFY overviewChanged)
143 Q_PROPERTY(int indexNumber READ indexNumber NOTIFY indexNumberChanged)
145 Q_PROPERTY(bool isFolder READ isFolder NOTIFY isFolderChanged)
146 Q_PROPERTY(QString type READ type NOTIFY typeChanged)
149 Q_PROPERTY(Jellyfin::ViewModel::UserData *userData READ userData NOTIFY userDataChanged)
151 Q_PROPERTY(int childCount READ childCount NOTIFY childCountChanged)
152 Q_PROPERTY(QString albumArtist READ albumArtist NOTIFY albumArtistChanged)
153 /*Q_PROPERTY(QVariantList albumArtists READ albumArtists NOTIFY albumArtistsChanged)*/
154 Q_PROPERTY(QString seriesName READ seriesName NOTIFY seriesNameChanged)
155 Q_PROPERTY(QString seriesId READ seriesId NOTIFY seriesIdChanged)
156 Q_PROPERTY(QString seasonId READ seasonId NOTIFY seasonIdChanged)
157 Q_PROPERTY(QString seasonName READ seasonName NOTIFY seasonNameChanged)
158 /*Q_PROPERTY(QList<MediaStream *> __list__mediaStreams MEMBER __list__m_mediaStreams NOTIFY mediaStreamsChanged)*/
159 Q_PROPERTY(QList<QObject *> mediaStreams READ mediaStreams NOTIFY mediaStreamsChanged)
160 Q_PROPERTY(QList<QObject *> audioStreams READ audioStreams NOTIFY audioStreamsChanged)
161 Q_PROPERTY(QList<QObject *> videoStreams READ videoStreams NOTIFY videoStreamsChanged)
164 Q_PROPERTY(QStringList artists READ artists NOTIFY artistsChanged)
165 Q_PROPERTY(QList<QObject *> artistItems READ artistItems NOTIFY artistItemsChanged);
167 // Why is this a QJsonObject? Well, because I couldn't be bothered to implement the deserialisations of
168 // a QHash at the moment.
169 Q_PROPERTY(QJsonObject imageTags READ imageTags NOTIFY imageTagsChanged)
171 Q_PROPERTY(QJsonObject imageBlurHashes READ imageBlurHashes NOTIFY imageBlurHashesChanged)
173 Q_PROPERTY(int movieCount READ movieCount NOTIFY movieCountChanged)
174 Q_PROPERTY(int seriesCount READ seriesCount NOTIFY seriesCountChanged)
177 Q_PROPERTY(int songCount READ songCount NOTIFY songCountChanged)
178 Q_PROPERTY(int albumCount READ albumCount NOTIFY albumCountChanged)
179 Q_PROPERTY(int artistCount READ artistCount NOTIFY artistCountChanged)
181 Q_PROPERTY(QString mediaType READ mediaType NOTIFY mediaTypeChanged)
182 Q_PROPERTY(QDateTime endDate READ endDate NOTIFY endDateChanged)
183 Q_PROPERTY(QDateTime startDate READ startDate NOTIFY startDateChanged)
184 Q_PROPERTY(int width READ width NOTIFY widthChanged)
185 Q_PROPERTY(int height READ height NOTIFY heightChanged)
187
188 QString jellyfinId() const { return m_data->jellyfinId(); }
189 QString name() const { return m_data->name(); }
190 QString originalTitle() const { return m_data->originalTitle(); }
191 QString serverId() const { return m_data->serverId(); }
192 QString etag() const { return m_data->etag(); }
193 QString sourceType() const { return m_data->sourceType(); }
194 QString playlistItemId() const { return m_data->playlistItemId(); }
195 QDateTime dateCreated() const { return m_data->dateCreated(); }
196 QDateTime dateLastMediaAdded() const { return m_data->dateLastMediaAdded(); }
197 QString extraType() const { return m_data->extraType(); }
198 int airsBeforeSeasonNumber() const { return m_data->airsBeforeSeasonNumber().value_or(0); }
199 int airsAfterSeasonNumber() const { return m_data->airsAfterSeasonNumber().value_or(999); }
200 int airsBeforeEpisodeNumber() const { return m_data->airsBeforeEpisodeNumber().value_or(0); }
201 qint64 runTimeTicks() const { return m_data->runTimeTicks().value_or(0); }
202 QString overview() const { return m_data->overview(); }
203 int productionYear() const { return m_data->productionYear().value_or(0); }
204 int indexNumber() const { return m_data->indexNumber().value_or(-1); }
205 int indexNumberEnd() const { return m_data->indexNumberEnd().value_or(-1); }
206 bool isFolder() const { return m_data->isFolder().value_or(false); }
207 QString type() const { return m_data->type(); }
208 QString parentBackdropItemId() const { return m_data->parentBackdropItemId(); }
209 QStringList parentBackdropImageTags() const { return m_data->parentBackdropImageTags(); }
210 UserData *userData() const { return m_userData; }
211 int recursiveItemCount() const { return m_data->recursiveItemCount().value_or(0); }
212 int childCount() const { return m_data->childCount().value_or(0); }
213 QString albumArtist() const { return m_data->albumArtist(); }
214 QString seriesName() const { return m_data->seriesName(); }
215 QString seriesId() const { return m_data->seriesId(); }
216 QString seasonId() const { return m_data->seasonId(); }
217 QString seasonName() const { return m_data->seasonName(); }
218
219 QObjectList mediaStreams() const { return m_allMediaStreams; }
220 QObjectList audioStreams() const { return m_audioStreams; }
221 QObjectList videoStreams() const { return m_videoStreams; }
222 QObjectList subtitleStreams() const { return m_subtitleStreams; }
223 double primaryImageAspectRatio() const { return m_data->primaryImageAspectRatio().value_or(1.0); }
224 QStringList artists() const { return m_data->artists(); }
226 QString collectionType() const { return this->m_data->collectionType(); }
227 QJsonObject imageTags() const { return m_data->imageTags(); }
228 QStringList backdropImageTags() const { return m_data->backdropImageTags(); }
229 QJsonObject imageBlurHashes() const { return m_data->imageBlurHashes(); }
230 QString mediaType() const { return m_data->mediaType(); }
231 QDateTime endDate() const { return m_data->endDate(); }
232 QDateTime startDate() const { return m_data->startDate(); }
234
235 int trailerCount() const { return m_data->trailerCount().value_or(0); }
236 int movieCount() const { return m_data->movieCount().value_or(0); }
237 int seriesCount() const { return m_data->seriesCount().value_or(0); }
238 int programCount() const { return m_data->programCount().value_or(0); }
239 int episodeCount() const { return m_data->episodeCount().value_or(0); }
240 int songCount() const { return m_data->songCount().value_or(0); }
241 int albumCount() const { return m_data->albumCount().value_or(0); }
242 int artistCount() const { return m_data->artistCount().value_or(0); }
243 int musicVideoCount() const { return m_data->musicVideoCount().value_or(0); }
244
245 int width() const { return m_data->width().value_or(0); }
246 int height() const { return m_data->height().value_or(0); }
247
248 QSharedPointer<Model::Item> data() const { return m_data; }
249 void setData(QSharedPointer<Model::Item> newData);
250signals:
251 void jellyfinIdChanged(const QString &newId);
252 void nameChanged(const QString &newName);
253 void originalTitleChanged(const QString &newOriginalTitle);
254 void serverIdChanged(const QString &newServerId);
255 void etagChanged(const QString &newEtag);
256 void sourceTypeChanged(const QString &sourceType);
258 void dateCreatedChanged(QDateTime newDateCreatedChanged);
259 void dateLastMediaAddedChanged(QDateTime newDateLastMediaAdded);
260 void extraTypeChanged(const QString &newExtraType);
261 void airsBeforeSeasonNumberChanged(int newAirsBeforeSeasonNumber);
262 void airsAfterSeasonNumberChanged(int newAirsAfterSeasonNumber);
263 void airsBeforeEpisodeNumberChanged(int newAirsAfterEpisodeNumber);
264 bool canDeleteChanged(bool newCanDelete);
265 void canDownloadChanged(bool newCanDownload);
266 void hasSubtitlesChanged(bool newHasSubtitles);
267 void preferredMetadataLanguageChanged(const QString &newPreferredMetadataLanguage);
268 void preferredMetadataCountryCodeChanged(const QString &newPreferredMetadataCountryCode);
269 void supportsSyncChanged(bool newSupportsSync);
270 void containerChanged(const QString &newContainer);
271 void sortNameChanged(const QString &newSortName);
272 void forcedSortNameChanged(const QString &newForcedSortName);
273 void premiereDateChanged(QDateTime newPremiereDate);
274 void criticRatingChanged(float newCriticRating);
275 void productionLocationsChanged(QStringList newProductionLocations);
276
277 // Handpicked, important ones
278 void runTimeTicksChanged(qint64 newRunTimeTicks);
279 void overviewChanged(const QString &newOverview);
280 void productionYearChanged(int newProductionYear);
281 void indexNumberChanged(int newIndexNumber);
282 void indexNumberEndChanged(int newIndexNumberEnd);
283 void isFolderChanged(bool newIsFolder);
284 void typeChanged(const QString &newType);
287 void userDataChanged(UserData *newUserData);
288 void recursiveItemCountChanged(int newRecursiveItemCount);
289 void childCountChanged(int newChildCount);
290 void albumArtistChanged(const QString &newAlbumArtist);
291 //void albumArtistsChanged(NameGuidPair *newAlbumArtists);
292 void seriesNameChanged(const QString &newSeriesName);
293 void seriesIdChanged(const QString &newSeriesId);
294 void seasonIdChanged(const QString &newSeasonId);
295 void seasonNameChanged(const QString &newSeasonName);
296 void mediaStreamsChanged(QVariantList &newMediaStreams);
297 void audioStreamsChanged(QVariantList &newAudioStreams);
298 void videoStreamsChanged(QVariantList &newVideoStreams);
299 void subtitleStreamsChanged(QVariantList &newSubtitleStreams);
300 void primaryImageAspectRatioChanged(double newPrimaryImageAspectRatio);
301 void artistsChanged(const QStringList &newArtists);
307 void trailerCountChanged(int newTrailerCount);
308 void movieCountChanged(int newMovieCount);
309 void seriesCountChanged(int newSeriesCount);
310 void programCountChanged(int newProgramCount);
311 void episodeCountChanged(int newEpisodeCount);
312 void songCountChanged(int newSongCount);
313 void albumCountChanged(int newAlbumCount);
314 void artistCountChanged(int newArtistCount);
315 void musicVideoCountChanged(int newMusicVideoCount);
316 void mediaTypeChanged(const QString &newMediaType);
319 void widthChanged(int newWidth);
320 void heightChanged(int newHeight);
322protected:
323 void setUserData(DTO::UserItemDataDto &newData);
324 void setUserData(QSharedPointer<DTO::UserItemDataDto> newData);
325 void updateMediaStreams();
326
327 QSharedPointer<Model::Item> m_data;
329 QObjectList m_allMediaStreams;
330 QObjectList m_audioStreams;
331 QObjectList m_videoStreams;
332 QObjectList m_subtitleStreams;
333 QObjectList m_artistItems;
335private slots:
336 void onUserDataChanged(const DTO::UserItemDataDto &userData);
337};
338
339class ItemLoader : public Loader<ViewModel::Item, DTO::BaseItemDto, Jellyfin::Loader::GetItemParams> {
340 Q_OBJECT
342public:
343 explicit ItemLoader(QObject *parent = nullptr);
344 Q_PROPERTY(QString itemId READ itemId WRITE setItemId NOTIFY itemIdChanged)
345
346 QString itemId() const { return m_parameters.itemId(); }
347 void setItemId(QString newItemId);
348 virtual bool canReload() const override;
349
350signals:
351 void itemIdChanged(const QString &newItemId) const;
352
353private slots:
354 void onApiClientChanged(ApiClient *newApiClient);
355private:
356 void setUserId(const QString &newUserId);
357};
358
359} // NS ViewModel
360} // NS Jellyfin
361
362#endif // JELLYFIN_VIEWMODEL_ITEM_H
An Api client for Jellyfin. Handles requests and authentication.
Definition apiclient.h:90
Definition useritemdatadto.h:49
const QString & itemId() const
Item id.
Definition requesttypes.cpp:11292
Definition item.h:339
virtual bool canReload() const override
Subclasses should implement this to determine if they can load data from the server.
Definition item.cpp:140
ItemLoader(QObject *parent=nullptr)
Definition item.cpp:118
QString itemId
Definition item.h:344
void itemIdChanged(const QString &newItemId) const
void setItemId(QString newItemId)
Definition item.cpp:147
Definition item.h:104
QString seriesId
Definition item.h:155
int indexNumber
Definition item.h:143
QDateTime dateCreated() const
Definition item.h:195
int movieCount() const
Definition item.h:236
QSharedPointer< Model::Item > m_data
Definition item.h:327
QString seasonId() const
Definition item.h:216
QString name() const
Definition item.h:189
void sourceTypeChanged(const QString &sourceType)
QString sourceType() const
Definition item.h:193
int childCount() const
Definition item.h:212
int width
Definition item.h:184
QObjectList subtitleStreams() const
Definition item.h:222
QObjectList audioStreams() const
Definition item.h:220
void videoStreamsChanged(QVariantList &newVideoStreams)
double primaryImageAspectRatio
Definition item.h:163
void premiereDateChanged(QDateTime newPremiereDate)
int episodeCount() const
Definition item.h:239
void preferredMetadataCountryCodeChanged(const QString &newPreferredMetadataCountryCode)
void widthChanged(int newWidth)
int songCount
Definition item.h:177
QString seriesId() const
Definition item.h:215
QString jellyfinId
Definition item.h:110
void userDataChanged(UserData *newUserData)
QString extraType
Definition item.h:119
QJsonObject imageBlurHashes() const
Definition item.h:229
int albumCount
Definition item.h:178
int seriesCount() const
Definition item.h:237
QString seasonId
Definition item.h:156
QDateTime startDate() const
Definition item.h:232
QList< QObject * > artistItems
Definition item.h:165
void albumArtistChanged(const QString &newAlbumArtist)
int artistCount() const
Definition item.h:242
QObjectList m_audioStreams
Definition item.h:330
int episodeCount
Definition item.h:176
QString seriesName() const
Definition item.h:214
bool isFolder
Definition item.h:145
void hasSubtitlesChanged(bool newHasSubtitles)
QString serverId
Definition item.h:113
QString originalTitle
Definition item.h:112
void trailerCountChanged(int newTrailerCount)
QJsonObject imageTags() const
Definition item.h:227
QString seriesName
Definition item.h:154
void indexNumberChanged(int newIndexNumber)
void movieCountChanged(int newMovieCount)
void setData(QSharedPointer< Model::Item > newData)
Definition item.cpp:40
int width() const
Definition item.h:245
QObjectList m_videoStreams
Definition item.h:331
bool isFolder() const
Definition item.h:206
void runTimeTicksChanged(qint64 newRunTimeTicks)
void artistsChanged(const QStringList &newArtists)
void airsBeforeEpisodeNumberChanged(int newAirsAfterEpisodeNumber)
int airsBeforeEpisodeNumber
Definition item.h:122
QList< QObject * > audioStreams
Definition item.h:160
void supportsSyncChanged(bool newSupportsSync)
QString collectionType() const
Definition item.h:226
QString sourceType
Definition item.h:115
int programCount
Definition item.h:175
void nameChanged(const QString &newName)
int programCount() const
Definition item.h:238
int airsBeforeEpisodeNumber() const
Definition item.h:200
QStringList parentBackdropImageTags() const
Definition item.h:209
QStringList backdropImageTags() const
Definition item.h:228
void subtitleStreamsChanged(QVariantList &newSubtitleStreams)
int indexNumberEnd
Definition item.h:144
void forcedSortNameChanged(const QString &newForcedSortName)
QSharedPointer< Model::Item > data() const
Definition item.h:248
void seriesCountChanged(int newSeriesCount)
QString playlistItemId() const
Definition item.h:194
Item * currentProgram() const
Definition item.h:233
QString overview() const
Definition item.h:202
QDateTime startDate
Definition item.h:183
int airsBeforeSeasonNumber
Definition item.h:120
void setUserData(DTO::UserItemDataDto &newData)
Definition item.cpp:98
QString mediaType() const
Definition item.h:230
void containerChanged(const QString &newContainer)
int indexNumberEnd() const
Definition item.h:205
QJsonObject imageTags
Definition item.h:169
void songCountChanged(int newSongCount)
void overviewChanged(const QString &newOverview)
int childCount
Definition item.h:151
int airsBeforeSeasonNumber() const
Definition item.h:198
Jellyfin::ViewModel::Item * currentProgram
Definition item.h:186
int airsAfterSeasonNumber() const
Definition item.h:199
QString parentBackdropItemId() const
Definition item.h:208
void programCountChanged(int newProgramCount)
void serverIdChanged(const QString &newServerId)
QString seasonName
Definition item.h:157
QString parentBackdropItemId
Definition item.h:147
void dateLastMediaAddedChanged(QDateTime newDateLastMediaAdded)
void playlistItemIdChanged(const QString &playlistItemIdChanged)
void criticRatingChanged(float newCriticRating)
void episodeCountChanged(int newEpisodeCount)
void isFolderChanged(bool newIsFolder)
QObjectList m_allMediaStreams
Definition item.h:329
QObjectList m_artistItems
Definition item.h:333
QString type
Definition item.h:146
int musicVideoCount() const
Definition item.h:243
QStringList artists
Definition item.h:164
void albumCountChanged(int newAlbumCount)
qint64 runTimeTicks
Definition item.h:140
void heightChanged(int newHeight)
QString overview
Definition item.h:141
int artistCount
Definition item.h:179
QStringList backdropImageTags
Definition item.h:170
bool canDeleteChanged(bool newCanDelete)
QString type() const
Definition item.h:207
QString seasonName() const
Definition item.h:217
void etagChanged(const QString &newEtag)
void seasonIdChanged(const QString &newSeasonId)
Item(QObject *parent=nullptr, QSharedPointer< Model::Item > data=QSharedPointer< Model::Item >::create())
Definition item.cpp:33
int seriesCount
Definition item.h:174
void seriesIdChanged(const QString &newSeriesId)
void jellyfinIdChanged(const QString &newId)
void airsAfterSeasonNumberChanged(int newAirsAfterSeasonNumber)
QString etag
Definition item.h:114
int movieCount
Definition item.h:173
void originalTitleChanged(const QString &newOriginalTitle)
QList< QObject * > artistItems() const
Definition item.h:225
void productionYearChanged(int newProductionYear)
QJsonObject imageBlurHashes
Definition item.h:171
void canDownloadChanged(bool newCanDownload)
void primaryImageAspectRatioChanged(double newPrimaryImageAspectRatio)
void extraTypeChanged(const QString &newExtraType)
QObjectList m_subtitleStreams
Definition item.h:332
void indexNumberEndChanged(int newIndexNumberEnd)
void sortNameChanged(const QString &newSortName)
void musicVideoCountChanged(int newMusicVideoCount)
QStringList parentBackdropImageTags
Definition item.h:148
QList< QObject * > subtitleStreams
Definition item.h:162
QList< QObject * > videoStreams
Definition item.h:161
int trailerCount
Definition item.h:172
QString mediaType
Definition item.h:181
UserData * m_userData
Definition item.h:328
void recursiveItemCountChanged(int newRecursiveItemCount)
UserData * userData() const
Definition item.h:210
int height
Definition item.h:185
QString etag() const
Definition item.h:192
int musicVideoCount
Definition item.h:180
qint64 runTimeTicks() const
Definition item.h:201
QString extraType() const
Definition item.h:197
void preferredMetadataLanguageChanged(const QString &newPreferredMetadataLanguage)
void mediaTypeChanged(const QString &newMediaType)
void dateCreatedChanged(QDateTime newDateCreatedChanged)
int airsAfterSeasonNumber
Definition item.h:121
int songCount() const
Definition item.h:240
void childCountChanged(int newChildCount)
QList< QObject * > mediaStreams
Definition item.h:159
void artistCountChanged(int newArtistCount)
int height() const
Definition item.h:246
QDateTime dateLastMediaAdded
Definition item.h:118
double primaryImageAspectRatio() const
Definition item.h:223
QDateTime dateLastMediaAdded() const
Definition item.h:196
QString collectionType
Definition item.h:166
QString playlistItemId
Definition item.h:116
void productionLocationsChanged(QStringList newProductionLocations)
int indexNumber() const
Definition item.h:204
QString name
Definition item.h:111
int recursiveItemCount() const
Definition item.h:211
void seriesNameChanged(const QString &newSeriesName)
void audioStreamsChanged(QVariantList &newAudioStreams)
Jellyfin::ViewModel::UserData * userData
Definition item.h:149
void updateMediaStreams()
Definition item.cpp:66
void mediaStreamsChanged(QVariantList &newMediaStreams)
QString originalTitle() const
Definition item.h:190
QObjectList videoStreams() const
Definition item.h:221
QObjectList mediaStreams() const
Definition item.h:219
int albumCount() const
Definition item.h:241
QDateTime endDate
Definition item.h:182
int productionYear() const
Definition item.h:203
int trailerCount() const
Definition item.h:235
int productionYear
Definition item.h:142
void airsBeforeSeasonNumberChanged(int newAirsBeforeSeasonNumber)
QString albumArtist() const
Definition item.h:213
QDateTime dateCreated
Definition item.h:117
Item * m_currentProgram
Definition item.h:334
int recursiveItemCount
Definition item.h:150
void typeChanged(const QString &newType)
QStringList artists() const
Definition item.h:224
void seasonNameChanged(const QString &newSeasonName)
QString serverId() const
Definition item.h:191
QString albumArtist
Definition item.h:152
QDateTime endDate() const
Definition item.h:231
Definition loader.h:148
void jellyfinIdChanged(const QString &newJellyfinId)
void nameChanged(const QString &newName)
QString jellyfinId
Definition item.h:90
QString jellyfinId() const
Definition item.h:95
QString name
Definition item.h:89
Definition userdata.h:31
Definition mediaplayer2.h:20
UserItemDataDto UserData
Definition apiclient.h:58
Jellyfin::DTO::UserItemDataDto UserItemDataDto
Definition useritemdatadto.h:207
QQmlListProperty< T > qQmlListPropertyFromQList(QObject *object, QList< T > *list)
Definition item.h:82