summary refs log tree commit diff
path: root/src/popups
diff options
context:
space:
mode:
Diffstat (limited to 'src/popups')
-rw-r--r--src/popups/SuggestionsPopup.cpp6
-rw-r--r--src/popups/SuggestionsPopup.h3
-rw-r--r--src/popups/UserMentions.h2
3 files changed, 9 insertions, 2 deletions
diff --git a/src/popups/SuggestionsPopup.cpp b/src/popups/SuggestionsPopup.cpp

index 8f355b38..e84435b7 100644 --- a/src/popups/SuggestionsPopup.cpp +++ b/src/popups/SuggestionsPopup.cpp
@@ -19,6 +19,12 @@ SuggestionsPopup::SuggestionsPopup(QWidget *parent) layout_->setSpacing(0); } +QString +SuggestionsPopup::displayName(QString room, QString user) +{ + return cache::displayName(room, user); +} + void SuggestionsPopup::addRooms(const std::vector<RoomSearchResult> &rooms) { diff --git a/src/popups/SuggestionsPopup.h b/src/popups/SuggestionsPopup.h
index 73bfe6f7..c66f2903 100644 --- a/src/popups/SuggestionsPopup.h +++ b/src/popups/SuggestionsPopup.h
@@ -22,7 +22,7 @@ public: const auto &widget = qobject_cast<Item *>(item->widget()); emit itemSelected( - cache::displayName(ChatPage::instance()->currentRoom(), widget->selectedText())); + displayName(ChatPage::instance()->currentRoom(), widget->selectedText())); resetSelection(); } @@ -47,6 +47,7 @@ signals: void itemSelected(const QString &user); private: + QString displayName(QString roomid, QString userid); void hoverSelection(); void resetSelection() { selectedItem_ = -1; } void selectFirstItem() { selectedItem_ = 0; } diff --git a/src/popups/UserMentions.h b/src/popups/UserMentions.h
index b7c4e51d..885fe67d 100644 --- a/src/popups/UserMentions.h +++ b/src/popups/UserMentions.h
@@ -1,6 +1,6 @@ #pragma once -#include <mtx/responses.hpp> +#include <mtx/responses/notifications.hpp> #include <QMap> #include <QString>