Enter Book::Illustration

`Book::m_favicon` and its 2 friends are replaced with a single
`Book::m_illustration` data member.
This commit is contained in:
Veloman Yunkan
2021-10-31 16:38:21 +04:00
parent 811b73a4f1
commit ec5a423924
2 changed files with 24 additions and 19 deletions

View File

@ -41,7 +41,15 @@ class Reader;
*/
class Book
{
public:
public: // types
struct Illustration
{
std::string mimeType;
std::string url;
mutable std::string data;
};
public: // functions
Book();
~Book();
@ -76,6 +84,7 @@ class Book
const std::string& getFavicon() const;
const std::string& getFaviconUrl() const;
const std::string& getFaviconMimeType() const;
const std::string& getDownloadId() const { return m_downloadId; }
void setReadOnly(bool readOnly) { m_readOnly = readOnly; }
@ -122,9 +131,7 @@ class Book
uint64_t m_mediaCount = 0;
bool m_readOnly = false;
uint64_t m_size = 0;
mutable std::string m_favicon;
std::string m_faviconUrl;
std::string m_faviconMimeType;
Illustration m_illustration;
};
}