link clicking and hovering in message body now works!

This commit is contained in:
Blue 2022-04-29 00:29:44 +03:00
parent eac87e713f
commit 7ba94e9deb
Signed by untrusted user: blue
GPG key ID: 9B203B252A63EE38
4 changed files with 105 additions and 120 deletions

View file

@ -20,6 +20,8 @@
#define FEEDVIEW_H
#include <QAbstractItemView>
#include <QDesktopServices>
#include <QUrl>
#include <deque>
#include <set>
@ -76,6 +78,7 @@ private:
bool tryToCalculateGeometriesWithNoScrollbars(const QStyleOptionViewItem& option, const QAbstractItemModel* model, uint32_t totalHeight);
void positionProgress();
void drawDateDevider(int top, const QDateTime& date, QPainter& painter);
void setAnchorHovered(bool hovered);
private:
struct Hint {
@ -96,6 +99,7 @@ private:
QFont dividerFont;
QFontMetrics dividerMetrics;
bool mousePressed;
bool anchorHovered;
static const std::set<int> geometryChangingRoles;