Move the tag types where they belong
This commit is contained in:
parent
fce61f8c9b
commit
1de6786a9e
2 changed files with 23 additions and 17 deletions
|
@ -79,24 +79,7 @@ namespace Danbooru {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief Types of tags
|
|
||||||
*
|
|
||||||
* A Danbooru tag is not simply a string, but carries some (limited)
|
|
||||||
* semantic information. In particular, tags are organized in what they
|
|
||||||
* refer to, either something related to the image itself, or to the
|
|
||||||
* artist that drew it, or the copyrights associated to the image, or even
|
|
||||||
* the characters that are represented in it.
|
|
||||||
*
|
|
||||||
**/
|
|
||||||
|
|
||||||
enum TagType {
|
|
||||||
General = 1, /**< Generic tags **/
|
|
||||||
Artist = 2, /**< Tags related to artists **/
|
|
||||||
Copyright = 4, /**<Tags related to copyrights **/
|
|
||||||
Character= 8, /**<Tags related to characters **/
|
|
||||||
Unknown = 16 /**< Unknown tags **/
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Ratings for a Danbooru item
|
* @brief Ratings for a Danbooru item
|
||||||
|
|
|
@ -35,6 +35,26 @@ namespace Danbooru {
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
/**
|
||||||
|
* @brief Types of tags
|
||||||
|
*
|
||||||
|
* A Danbooru tag is not simply a string, but carries some (limited)
|
||||||
|
* semantic information. In particular, tags are organized in what they
|
||||||
|
* refer to, either something related to the image itself, or to the
|
||||||
|
* artist that drew it, or the copyrights associated to the image, or even
|
||||||
|
* the characters that are represented in it.
|
||||||
|
*
|
||||||
|
**/
|
||||||
|
|
||||||
|
enum TagType {
|
||||||
|
General = 1, /**< Generic tags **/
|
||||||
|
Artist = 2, /**< Tags related to artists **/
|
||||||
|
Copyright = 4, /**<Tags related to copyrights **/
|
||||||
|
Character= 8, /**<Tags related to characters **/
|
||||||
|
Unknown = 16 /**< Unknown tags **/
|
||||||
|
};
|
||||||
|
|
||||||
private:
|
private:
|
||||||
int m_id;
|
int m_id;
|
||||||
int m_count;
|
int m_count;
|
||||||
|
@ -52,6 +72,9 @@ namespace Danbooru {
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Q_DECLARE_FLAGS(TagTypes, DanbooruTag::TagType)
|
||||||
|
Q_DECLARE_OPERATORS_FOR_FLAGS(TagTypes)
|
||||||
|
|
||||||
}; // namespace Danbooru
|
}; // namespace Danbooru
|
||||||
|
|
||||||
Q_DECLARE_METATYPE(Danbooru::DanbooruTag*)
|
Q_DECLARE_METATYPE(Danbooru::DanbooruTag*)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue