mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-01 19:13:55 -07:00
fixed direct chat, fixed in-game attachment bugs
This commit is contained in:
parent
c39539b73a
commit
92e842bb74
18 changed files with 127 additions and 96 deletions
|
|
@ -4,7 +4,7 @@
|
|||
#include "tab.h"
|
||||
|
||||
class AbstractClient;
|
||||
class QTextEdit;
|
||||
class ChatView;
|
||||
class QLineEdit;
|
||||
class Event_Message;
|
||||
|
||||
|
|
@ -13,26 +13,27 @@ class TabMessage : public Tab {
|
|||
private:
|
||||
AbstractClient *client;
|
||||
QString userName;
|
||||
bool userOnline;
|
||||
|
||||
QTextEdit *textEdit;
|
||||
ChatView *chatView;
|
||||
QLineEdit *sayEdit;
|
||||
|
||||
QAction *aLeave;
|
||||
QString sanitizeHtml(QString dirty) const;
|
||||
signals:
|
||||
void talkClosing(TabMessage *tab);
|
||||
private slots:
|
||||
void sendMessage();
|
||||
void actLeave();
|
||||
public slots:
|
||||
void processMessageEvent(Event_Message *event);
|
||||
void processUserLeft(const QString &userName);
|
||||
public:
|
||||
TabMessage(AbstractClient *_client, const QString &_userName);
|
||||
TabMessage(AbstractClient *_client, const QString &_ownName, const QString &_userName);
|
||||
~TabMessage();
|
||||
void retranslateUi();
|
||||
QString getUserName() const { return userName; }
|
||||
QString getTabText() const { return tr("Talking to %1").arg(userName); }
|
||||
|
||||
void processMessageEvent(Event_Message *event);
|
||||
void processUserLeft();
|
||||
void processUserJoined();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue