Commit e1b6faa2 authored by Camilo Higuita's avatar Camilo Higuita

fix db issue were db folder wasn't created and use linked taglib instead of search for local one

parent 1d358161
......@@ -5,50 +5,44 @@
#include <QByteArray>
#include <QObject>
#if (defined (Q_OS_LINUX) && !defined (Q_OS_ANDROID))
#include <taglib/tag.h>
#include <taglib/fileref.h>
#endif
#if defined(Q_OS_ANDROID)
#include <./3rdparty/taglib/tag.h>
#include <./3rdparty/taglib/fileref.h>
#endif
namespace TagLib {
class FileRef;
namespace TagLib
{
class FileRef;
}
class TagInfo : public QObject
{
Q_OBJECT
public:
TagInfo(QObject *parent = nullptr);
~TagInfo();
bool feed(const QString &url);
QString getAlbum() const;
QString getTitle() const;
QString getArtist() const;
int getTrack() const;
QString getGenre() const;
QString fileName() const;
QString getComment() const;
QByteArray getCover() const;
int getDuration() const;
uint getYear() const;
void setAlbum(const QString &album) ;
void setTitle(const QString &title);
void setTrack(const int &track);
void setArtist(const QString &artist);
void setGenre(const QString &genre);
void setComment(const QString &comment);
void setCover(const QByteArray &array);
private:
TagLib::FileRef file;
QString path;
Q_OBJECT
public:
TagInfo(QObject *parent = nullptr);
~TagInfo();
bool feed(const QString &url);
QString getAlbum() const;
QString getTitle() const;
QString getArtist() const;
int getTrack() const;
QString getGenre() const;
QString fileName() const;
QString getComment() const;
QByteArray getCover() const;
int getDuration() const;
uint getYear() const;
void setAlbum(const QString &album) ;
void setTitle(const QString &title);
void setTrack(const int &track);
void setArtist(const QString &artist);
void setGenre(const QString &genre);
void setComment(const QString &comment);
void setCover(const QByteArray &array);
private:
TagLib::FileRef file;
QString path;
};
#endif // TAGINFO_H
......@@ -48,12 +48,9 @@ BabeSettings::BabeSettings(QObject *parent) : QObject(parent)
}
#endif
QDir collectionDBPath_dir(BAE::CollectionDBPath);
QDir cachePath_dir(BAE::CachePath);
QDir youtubeCache_dir(BAE::YoutubeCachePath);
if (!collectionDBPath_dir.exists())
collectionDBPath_dir.mkpath(".");
if (!cachePath_dir.exists())
cachePath_dir.mkpath(".");
if (!youtubeCache_dir.exists())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment