Mercurial > minori
comparison src/gui/widgets/poster.cc @ 255:fe702c8f161f
*: whatever
author | Paper <paper@paper.us.eu.org> |
---|---|
date | Wed, 07 Feb 2024 17:04:06 -0500 |
parents | d14f8e0e40c3 |
children | 862d0d8619f6 |
comparison
equal
deleted
inserted
replaced
254:d14f8e0e40c3 | 255:fe702c8f161f |
---|---|
33 Poster::Poster(const Anime::Anime& anime, QWidget* parent) : Poster(parent) { | 33 Poster::Poster(const Anime::Anime& anime, QWidget* parent) : Poster(parent) { |
34 SetAnime(anime); | 34 SetAnime(anime); |
35 } | 35 } |
36 | 36 |
37 void Poster::SetAnime(const Anime::Anime& anime) { | 37 void Poster::SetAnime(const Anime::Anime& anime) { |
38 /* todo: only download on showEvent() */ | |
38 { | 39 { |
39 HTTP::GetThread* thread = new HTTP::GetThread(anime.GetPosterUrl(), {}, this); | 40 HTTP::GetThread* thread = new HTTP::GetThread(anime.GetPosterUrl(), {}, this); |
40 | 41 |
41 connect(thread, &HTTP::GetThread::ReceivedData, this, &Poster::ImageDownloadFinished); | 42 connect(thread, &HTTP::GetThread::ReceivedData, this, &Poster::ImageDownloadFinished); |
42 connect(thread, &HTTP::GetThread::finished, thread, &HTTP::GetThread::deleteLater); | 43 connect(thread, &HTTP::GetThread::finished, thread, &HTTP::GetThread::deleteLater); |