summary refs log tree commit diff
path: root/src/timeline
diff options
context:
space:
mode:
authorJedi18 <targetakhil@gmail.com>2021-02-05 22:42:08 +0530
committerJedi18 <targetakhil@gmail.com>2021-02-05 22:42:08 +0530
commit4aefac08a4b57e6fb344cd8cffb0b6e32698e0ba (patch)
tree05c1d631bea6709b99a76d7e76aee098fe889d64 /src/timeline
parentclose emoji autocompleter if space typed after : issue #433 and adds default ... (diff)
downloadnheko-4aefac08a4b57e6fb344cd8cffb0b6e32698e0ba.tar.xz
focus message input on adding emoji/reacting to a message
Diffstat (limited to 'src/timeline')
-rw-r--r--src/timeline/TimelineViewManager.cpp6
-rw-r--r--src/timeline/TimelineViewManager.h2
2 files changed, 8 insertions, 0 deletions
diff --git a/src/timeline/TimelineViewManager.cpp b/src/timeline/TimelineViewManager.cpp
index 93451976..9ca08e06 100644
--- a/src/timeline/TimelineViewManager.cpp
+++ b/src/timeline/TimelineViewManager.cpp
@@ -545,3 +545,9 @@ TimelineViewManager::queueCallMessage(const QString &roomid,
 {
         models.value(roomid)->sendMessageEvent(callHangUp, mtx::events::EventType::CallHangUp);
 }
+
+void
+TimelineViewManager::focusMessageInput()
+{
+        emit focusInput();
+}
\ No newline at end of file
diff --git a/src/timeline/TimelineViewManager.h b/src/timeline/TimelineViewManager.h
index 74128865..7c994a14 100644
--- a/src/timeline/TimelineViewManager.h
+++ b/src/timeline/TimelineViewManager.h
@@ -66,6 +66,7 @@ public:
 
         Q_INVOKABLE void openLink(QString link) const;
 
+        Q_INVOKABLE void focusMessageInput();
         Q_INVOKABLE void openInviteUsersDialog();
         Q_INVOKABLE void openMemberListDialog() const;
         Q_INVOKABLE void openLeaveRoomDialog() const;
@@ -87,6 +88,7 @@ signals:
         void showRoomList();
         void narrowViewChanged();
         void focusChanged();
+        void focusInput();
 
 public slots:
         void updateReadReceipts(const QString &room_id, const std::vector<QString> &event_ids);