summaryrefslogtreecommitdiff
path: root/src/previewimage.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/previewimage.h')
-rw-r--r--src/previewimage.h21
1 files changed, 15 insertions, 6 deletions
diff --git a/src/previewimage.h b/src/previewimage.h
index 5568dd29..d7f4d2aa 100644
--- a/src/previewimage.h
+++ b/src/previewimage.h
@@ -35,16 +35,19 @@
// Qt Includes
#include <QLabel>
+#include <QFrame>
#include <QImage>
#include <QUrl>
#include <QToolButton>
+#include <QSize>
-class PreviewImage : public QLabel
+
+class PreviewImage : public QWidget
{
Q_OBJECT
public:
- PreviewImage(const QUrl &url, int index, bool isFavorite);
+ PreviewImage(const QUrl &url, const QString &title, int index, bool isFavorite);
~PreviewImage();
QString guessNameFromUrl(QUrl url);
@@ -54,7 +57,7 @@ public slots:
void removeMe();
void setUrlFromAction();
void refreshPreview();
-
+
protected:
void contextMenuEvent(QContextMenuEvent *event);
void mouseDoubleClickEvent(QMouseEvent *event);
@@ -67,17 +70,23 @@ protected:
void showEmptyPreview();
private:
+ void checkTitle();
+
QPixmap m_pixmap;
WebSnap *ws;
- QUrl m_url;
- QString m_savePath;
-
+ QString m_savePath;
bool loadingSnapshot;
+
+ QUrl m_url;
+ QString m_title;
bool m_isFavorite;
int m_index;
QToolButton *m_button;
+
+ QLabel *m_imageLabel;
+ QLabel *m_textLabel;
};
#endif // PREVIEW_IMAGE_H