Create new contructor for UrlHandler

This commit is contained in:
Jonas Kvinge 2020-08-23 18:52:30 +02:00
parent e8a073651f
commit 2f4f29517e
2 changed files with 12 additions and 0 deletions

View File

@ -39,4 +39,14 @@ UrlHandler::LoadResult::LoadResult(const QUrl &original_url, const Type type, co
error_(error)
{}
UrlHandler::LoadResult::LoadResult(const QUrl &original_url, const Type type, const QString error) :
original_url_(original_url),
type_(type),
filetype_(Song::FileType_Stream),
samplerate_(-1),
bit_depth_(-1),
length_nanosec_(-1),
error_(error)
{}
UrlHandler::UrlHandler(QObject *parent) : QObject(parent) {}

View File

@ -59,6 +59,8 @@ class UrlHandler : public QObject {
explicit LoadResult(const QUrl &original_url = QUrl(), const Type type = NoMoreTracks, const QUrl &stream_url = QUrl(), const Song::FileType filetype = Song::FileType_Stream, const int samplerate = -1, const int bit_depth = -1, const qint64 length_nanosec = -1, const QString error = QString());
explicit LoadResult(const QUrl &original_url, const Type type, const QString error);
// The url that the playlist item has in Url().
// Might be something unplayable like lastfm://...
QUrl original_url_;