diff --git a/src/libdanbooru/danbooruservice.cpp b/src/libdanbooru/danbooruservice.cpp index f623d5b..f24e9c9 100644 --- a/src/libdanbooru/danbooruservice.cpp +++ b/src/libdanbooru/danbooruservice.cpp @@ -60,7 +60,7 @@ DanbooruService::DanbooruService(QUrl& boardUrl, QString username, m_url(boardUrl), m_username(username), m_password(password), - m_maxRating(Safe), + m_maxRating(Danbooru::DanbooruPost::Safe), m_currentPosts(0), m_cache(cache) { @@ -175,24 +175,24 @@ void DanbooruService::getPoolList(int page) } void DanbooruService::getRelatedTags(const QStringList& tags, - Danbooru::TagType tagType) + DanbooruTag::TagType tagType) { QString type; switch (tagType) { - case Danbooru::General: + case DanbooruTag::General: type = "general"; break; - case Danbooru::Artist: + case DanbooruTag::Artist: type = "artist"; break; - case Danbooru::Copyright: + case DanbooruTag::Copyright: type = "copyright"; break; - case Danbooru::Character: + case DanbooruTag::Character: type = "character"; break; - case Danbooru::Unknown: + case DanbooruTag::Unknown: type = "unknown"; break; } diff --git a/src/libdanbooru/danbooruservice.h b/src/libdanbooru/danbooruservice.h index 2928494..eec7dd3 100644 --- a/src/libdanbooru/danbooruservice.h +++ b/src/libdanbooru/danbooruservice.h @@ -41,23 +41,24 @@ // KDE #include -#include +#include // Own #include "danbooru.h" +#include "danboorupost.h" +#include "danboorutag.h" class QPixmap; class QUrl; class KJob; class KImageCache; +using Danbooru::DanbooruTag; namespace Danbooru { - class DanbooruPost; class DanbooruPool; - class DanbooruTag; using KIO::StoredTransferJob; @@ -93,7 +94,7 @@ namespace Danbooru { QString m_username; QString m_password; QSet m_blacklist; - Ratings m_maxRating; + Danbooru::DanbooruPost::Rating m_maxRating; unsigned int m_currentPosts; // To tell when to quit @@ -171,7 +172,7 @@ namespace Danbooru { * @param tags The tags to query for related terms * @param tagType The type of tag to query for **/ - void getRelatedTags(const QStringList& tags, Danbooru::TagType tagType = General); + void getRelatedTags(const QStringList& tags, DanbooruTag::TagType tagType = DanbooruTag::General); /** * @return The currently allowed ratings when downloading posts.