Commit d7aa9b5a authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

MAke it compile with new KUrlLabel

parent f06bb332
......@@ -37,7 +37,7 @@
#include <KontactInterface/Plugin>
#include <KMime/Message>
#include <kwidgetsaddons_version.h>
#include <KCheckableProxyModel>
#include <KIconEffect>
#include <KIconLoader>
......@@ -189,12 +189,21 @@ void KNotesSummaryWidget::createNote(const Akonadi::Item &item, int counter)
urlLabel->installEventFilter(this);
urlLabel->setAlignment(Qt::AlignLeft);
urlLabel->setWordWrap(true);
#if KWIDGETSADDONS_VERSION < QT_VERSION_CHECK(5, 65, 0)
connect(urlLabel, qOverload<const QString &>(&KUrlLabel::leftClickedUrl),
this, &KNotesSummaryWidget::slotSelectNote);
connect(urlLabel, qOverload<const QString &>(&KUrlLabel::rightClickedUrl),
this, &KNotesSummaryWidget::slotPopupMenu);
#else
connect(urlLabel, &KUrlLabel::leftClickedUrl, this, [this, urlLabel]() {
slotSelectNote(urlLabel->url()); }
);
connect(urlLabel, &KUrlLabel::rightClickedUrl, this, [this, urlLabel]() {
slotPopupMenu(urlLabel->url()); }
);
#endif
mLayout->addWidget(urlLabel, counter, 1);
QColor color;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment