mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-07 00:25:16 -04:00
Fixes two problems in the current group chat:
- the parser fails to embed two links in the same sentence - the parser can potentially put smileys in the middle of <a> tags Solution: Since the message is in HTML, it is parsed into a DOM tree, then that DOM tree is traversed and only the text nodes are parsed (see HandleRichText.cpp for details). Bonus fixes: - missing std:: for endl (which was falling back to its Qt counterpart) - commenting useless code in PeersDialog::smileyWidgetgroupchat() - replacing int by size_t - RetroShare.pro now queries gpgme-config for its include path git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2888 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
6b3f51c626
commit
988c6c31f5
5 changed files with 281 additions and 40 deletions
|
@ -25,6 +25,7 @@
|
|||
#include <QFileDialog>
|
||||
|
||||
#include "chat/PopupChatDialog.h"
|
||||
#include "chat/HandleRichText.h"
|
||||
#include "RsAutoUpdatePage.h"
|
||||
|
||||
#include "mainpage.h"
|
||||
|
@ -159,8 +160,12 @@ private:
|
|||
|
||||
///play the sound when recv a message
|
||||
void playsound();
|
||||
|
||||
QString fileName;
|
||||
|
||||
QString fileName;
|
||||
|
||||
/** store default information for embedding HTML */
|
||||
RsChat::EmbedInHtmlAhref defEmbedAhref;
|
||||
RsChat::EmbedInHtmlImg defEmbedImg;
|
||||
|
||||
/* Worker Functions */
|
||||
/* (1) Update Display */
|
||||
|
@ -187,7 +192,7 @@ private:
|
|||
QColor _currentColor;
|
||||
bool _underline;
|
||||
time_t last_status_send_time ;
|
||||
|
||||
|
||||
QHash<QString, QString> smileys;
|
||||
|
||||
std::map<std::string, PopupChatDialog *> chatDialogs;
|
||||
|
@ -198,5 +203,5 @@ private:
|
|||
Ui::PeersDialog ui;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue