aboutsummaryrefslogtreecommitdiffstats
path: root/src/activitypub/apattachment.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/activitypub/apattachment.h')
-rw-r--r--src/activitypub/apattachment.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/activitypub/apattachment.h b/src/activitypub/apattachment.h
index 83e9339..4b5ba0e 100644
--- a/src/activitypub/apattachment.h
+++ b/src/activitypub/apattachment.h
@@ -4,7 +4,7 @@
#include "fields.h"
#include <QPixmap>
#include <array>
-#include <vector>
+#include <memory>
class APAttachment : APBase {
public:
@@ -12,7 +12,7 @@ public:
APAttachment(APAttachmentFields fields);
~APAttachment() {};
QString get_html_render(HtmlRenderDetails render_info);
- const QPixmap& get_pixmap(int width = 0, int height = 0);
+ std::shared_ptr<QPixmap> get_pixmap(int width = 0, int height = 0);
private:
QString blurhash;
@@ -22,7 +22,7 @@ private:
QString path_url; // attachment URL, might be file on filesystem (make sure that the attachment dir has been found and that the path is correct)
QString filename; // nicer descriptor of the attachment's path
- QPixmap* pixmap = nullptr;
+ std::shared_ptr<QPixmap> pixmap;
struct {
int width = 0;
int height = 0;