mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-23 03:18:49 +03:00
Additional code cleanup
This commit is contained in:
parent
12c46e86b4
commit
b9626f0c69
4 changed files with 0 additions and 34 deletions
|
@ -606,12 +606,6 @@ ChatPage::resetUI()
|
||||||
showUnreadMessageNotification(0);
|
showUnreadMessageNotification(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
ChatPage::reactMessage(const QString &id)
|
|
||||||
{
|
|
||||||
view_manager_->queueReactionMessage(current_room_, id, "👀");
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
ChatPage::focusMessageInput()
|
ChatPage::focusMessageInput()
|
||||||
{
|
{
|
||||||
|
|
|
@ -87,7 +87,6 @@ public:
|
||||||
//! Show the room/group list (if it was visible).
|
//! Show the room/group list (if it was visible).
|
||||||
void showSideBars();
|
void showSideBars();
|
||||||
void initiateLogout();
|
void initiateLogout();
|
||||||
void reactMessage(const QString &eventId);
|
|
||||||
void focusMessageInput();
|
void focusMessageInput();
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
|
|
|
@ -961,13 +961,6 @@ TimelineModel::decryptEvent(const mtx::events::EncryptedEvent<mtx::events::msg::
|
||||||
return {dummy, false};
|
return {dummy, false};
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
TimelineModel::reactAction(QString id)
|
|
||||||
{
|
|
||||||
setReaction(id);
|
|
||||||
ChatPage::instance()->reactMessage(id);
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
TimelineModel::replyAction(QString id)
|
TimelineModel::replyAction(QString id)
|
||||||
{
|
{
|
||||||
|
|
|
@ -126,8 +126,6 @@ class TimelineModel : public QAbstractListModel
|
||||||
int currentIndex READ currentIndex WRITE setCurrentIndex NOTIFY currentIndexChanged)
|
int currentIndex READ currentIndex WRITE setCurrentIndex NOTIFY currentIndexChanged)
|
||||||
Q_PROPERTY(std::vector<QString> typingUsers READ typingUsers WRITE updateTypingUsers NOTIFY
|
Q_PROPERTY(std::vector<QString> typingUsers READ typingUsers WRITE updateTypingUsers NOTIFY
|
||||||
typingUsersChanged)
|
typingUsersChanged)
|
||||||
Q_PROPERTY(QString reaction READ reaction WRITE setReaction NOTIFY reactionChanged RESET
|
|
||||||
resetReaction)
|
|
||||||
Q_PROPERTY(QString reply READ reply WRITE setReply NOTIFY replyChanged RESET resetReply)
|
Q_PROPERTY(QString reply READ reply WRITE setReply NOTIFY replyChanged RESET resetReply)
|
||||||
Q_PROPERTY(
|
Q_PROPERTY(
|
||||||
bool paginationInProgress READ paginationInProgress NOTIFY paginationInProgressChanged)
|
bool paginationInProgress READ paginationInProgress NOTIFY paginationInProgressChanged)
|
||||||
|
@ -191,7 +189,6 @@ public:
|
||||||
Q_INVOKABLE void viewRawMessage(QString id) const;
|
Q_INVOKABLE void viewRawMessage(QString id) const;
|
||||||
Q_INVOKABLE void viewDecryptedRawMessage(QString id) const;
|
Q_INVOKABLE void viewDecryptedRawMessage(QString id) const;
|
||||||
Q_INVOKABLE void openUserProfile(QString userid) const;
|
Q_INVOKABLE void openUserProfile(QString userid) const;
|
||||||
Q_INVOKABLE void reactAction(QString id);
|
|
||||||
Q_INVOKABLE void replyAction(QString id);
|
Q_INVOKABLE void replyAction(QString id);
|
||||||
Q_INVOKABLE void readReceiptsAction(QString id) const;
|
Q_INVOKABLE void readReceiptsAction(QString id) const;
|
||||||
Q_INVOKABLE void redactEvent(QString id);
|
Q_INVOKABLE void redactEvent(QString id);
|
||||||
|
@ -220,21 +217,6 @@ public slots:
|
||||||
}
|
}
|
||||||
std::vector<QString> typingUsers() const { return typingUsers_; }
|
std::vector<QString> typingUsers() const { return typingUsers_; }
|
||||||
bool paginationInProgress() const { return m_paginationInProgress; }
|
bool paginationInProgress() const { return m_paginationInProgress; }
|
||||||
QString reaction() const { return reaction_; }
|
|
||||||
void setReaction(QString reaction)
|
|
||||||
{
|
|
||||||
if (reaction_ != reaction) {
|
|
||||||
reaction_ = reaction;
|
|
||||||
emit reactionChanged(reaction_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
void resetReaction()
|
|
||||||
{
|
|
||||||
if (!reaction_.isEmpty()) {
|
|
||||||
reaction_ = "";
|
|
||||||
emit reactionChanged(reaction_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
QString reply() const { return reply_; }
|
QString reply() const { return reply_; }
|
||||||
void setReply(QString newReply)
|
void setReply(QString newReply)
|
||||||
{
|
{
|
||||||
|
@ -271,7 +253,6 @@ signals:
|
||||||
void newEncryptedImage(mtx::crypto::EncryptedFile encryptionInfo);
|
void newEncryptedImage(mtx::crypto::EncryptedFile encryptionInfo);
|
||||||
void eventFetched(QString requestingEvent, mtx::events::collections::TimelineEvents event);
|
void eventFetched(QString requestingEvent, mtx::events::collections::TimelineEvents event);
|
||||||
void typingUsersChanged(std::vector<QString> users);
|
void typingUsersChanged(std::vector<QString> users);
|
||||||
void reactionChanged(QString reaction);
|
|
||||||
void replyChanged(QString reply);
|
void replyChanged(QString reply);
|
||||||
void paginationInProgressChanged(const bool);
|
void paginationInProgressChanged(const bool);
|
||||||
|
|
||||||
|
@ -305,7 +286,6 @@ private:
|
||||||
bool m_paginationInProgress = false;
|
bool m_paginationInProgress = false;
|
||||||
|
|
||||||
QString currentId;
|
QString currentId;
|
||||||
QString reaction_;
|
|
||||||
QString reply_;
|
QString reply_;
|
||||||
std::vector<QString> typingUsers_;
|
std::vector<QString> typingUsers_;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue