Mercurial > minori
annotate include/gui/widgets/poster.h @ 93:d5efb81540b3
statistics: add graph!
also now we have a VERY VERY simple graph widget that probably
sucks and doesn't work half the time :)
author | Paper <mrpapersonic@gmail.com> |
---|---|
date | Wed, 01 Nov 2023 13:52:34 -0400 |
parents | d02fdf1d6708 |
children | 8043152ef9d4 |
rev | line source |
---|---|
66 | 1 #ifndef __gui__widgets__poster_h |
2 #define __gui__widgets__poster_h | |
3 #include <QFrame> | |
4 #include <QImage> | |
5 | |
6 class QWidget; | |
67
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
66
diff
changeset
|
7 class ClickableLabel; |
83 | 8 namespace Anime { |
9 class Anime; | |
10 } | |
66 | 11 |
12 class Poster : public QFrame { | |
13 Q_OBJECT | |
14 | |
15 public: | |
83 | 16 Poster(QWidget* parent = nullptr); |
17 Poster(const Anime::Anime& anime, QWidget* parent = nullptr); | |
18 void SetAnime(const Anime::Anime& anime); | |
66 | 19 |
20 protected: | |
67
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
66
diff
changeset
|
21 void resizeEvent(QResizeEvent*) override; |
83 | 22 void ImageDownloadFinished(const QByteArray& arr); |
75 | 23 void RenderToLabel(); |
66 | 24 |
25 private: | |
26 QImage img; | |
67
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
66
diff
changeset
|
27 ClickableLabel* label; |
66 | 28 }; |
29 | |
30 #endif // __gui__widgets__poster_h |