mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-08-24 13:59:29 -04:00
- Added blocking of embedded images (+ settings) to forums and messages
- Added image support for forum messages - Renamed LinkTextBrowser to RSTextBrowser - Updated english translation git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6752 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
8ffc0e05de
commit
6b1613d8bb
31 changed files with 907 additions and 454 deletions
36
retroshare-gui/src/gui/common/RSTextBrowser.h
Normal file
36
retroshare-gui/src/gui/common/RSTextBrowser.h
Normal file
|
@ -0,0 +1,36 @@
|
|||
#ifndef RSTEXTBROWSER_H
|
||||
#define RSTEXTBROWSER_H
|
||||
|
||||
#include <QTextBrowser>
|
||||
|
||||
class RSImageBlockWidget;
|
||||
|
||||
class RSTextBrowser : public QTextBrowser
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit RSTextBrowser(QWidget *parent = 0);
|
||||
|
||||
void setPlaceholderText(const QString &text);
|
||||
void setImageBlockWidget(RSImageBlockWidget *widget);
|
||||
void resetImagesStatus(bool load);
|
||||
|
||||
virtual QVariant loadResource(int type, const QUrl &name);
|
||||
|
||||
public slots:
|
||||
void showImages();
|
||||
|
||||
private slots:
|
||||
void linkClicked(const QUrl &url);
|
||||
void destroyImageBlockWidget();
|
||||
|
||||
protected:
|
||||
void paintEvent(QPaintEvent *event);
|
||||
|
||||
QString mPlaceholderText;
|
||||
bool mShowImages;
|
||||
RSImageBlockWidget *mImageBlockWidget;
|
||||
};
|
||||
|
||||
#endif // RSTEXTBROWSER_H
|
Loading…
Add table
Add a link
Reference in a new issue