You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
514 B
28 lines
514 B
#pragma once |
|
|
|
#include <QWidget> |
|
|
|
class QTextEdit; |
|
class QPushButton; |
|
class EmojiPanel; |
|
|
|
class InputBar : public QWidget { |
|
Q_OBJECT |
|
public: |
|
explicit InputBar(EmojiPanel *emojiPanel, QWidget *parent = nullptr); |
|
|
|
signals: |
|
void sendMessage(const QString &text); |
|
|
|
protected: |
|
bool eventFilter(QObject *obj, QEvent *event) override; |
|
|
|
private slots: |
|
void onSendClicked(); |
|
void adjustInputHeight(); |
|
|
|
private: |
|
QTextEdit *m_input; |
|
QPushButton *m_emojiBtn; |
|
EmojiPanel *m_emojiPanel; |
|
};
|
|
|