mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
docs(chatlog): Change comment style
This commit is contained in:
parent
29443040fb
commit
394c4bcc99
|
@ -24,6 +24,14 @@
|
||||||
#include <QPainter>
|
#include <QPainter>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
|
/**
|
||||||
|
@enum ChatLineContentProxy::ChatLineContentProxyType
|
||||||
|
@brief Type tag to avoid dynamic_cast of contained QWidget*
|
||||||
|
|
||||||
|
@value GenericType
|
||||||
|
@value FileTransferWidgetType = 0
|
||||||
|
*/
|
||||||
|
|
||||||
ChatLineContentProxy::ChatLineContentProxy(QWidget* widget, ChatLineContentProxyType type, int minWidth, float widthInPercent)
|
ChatLineContentProxy::ChatLineContentProxy(QWidget* widget, ChatLineContentProxyType type, int minWidth, float widthInPercent)
|
||||||
: widthPercent(widthInPercent)
|
: widthPercent(widthInPercent)
|
||||||
, widthMin(minWidth)
|
, widthMin(minWidth)
|
||||||
|
|
|
@ -28,7 +28,6 @@ class FileTransferWidget;
|
||||||
class ChatLineContentProxy : public ChatLineContent
|
class ChatLineContentProxy : public ChatLineContent
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
// Type tag to avoid dynamic_cast of contained QWidget*
|
|
||||||
enum ChatLineContentProxyType
|
enum ChatLineContentProxyType
|
||||||
{
|
{
|
||||||
GenericType,
|
GenericType,
|
||||||
|
|
|
@ -31,6 +31,11 @@
|
||||||
#include <QMouseEvent>
|
#include <QMouseEvent>
|
||||||
#include <QShortcut>
|
#include <QShortcut>
|
||||||
|
|
||||||
|
/**
|
||||||
|
@var ChatLog::repNameAfter
|
||||||
|
@brief repetition interval sender name (sec)
|
||||||
|
*/
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
T clamp(T x, T min, T max)
|
T clamp(T x, T min, T max)
|
||||||
{
|
{
|
||||||
|
|
|
@ -62,7 +62,6 @@ public:
|
||||||
ChatLine::Ptr getTypingNotification() const;
|
ChatLine::Ptr getTypingNotification() const;
|
||||||
QVector<ChatLine::Ptr> getLines();
|
QVector<ChatLine::Ptr> getLines();
|
||||||
ChatLine::Ptr getLatestLine() const;
|
ChatLine::Ptr getLatestLine() const;
|
||||||
// repetition interval sender name (sec)
|
|
||||||
const uint repNameAfter = 5*60;
|
const uint repNameAfter = 5*60;
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
|
|
|
@ -43,6 +43,9 @@ void DocumentCache::push(QTextDocument *doc)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
@brief Returns the singleton instance.
|
||||||
|
*/
|
||||||
DocumentCache &DocumentCache::getInstance()
|
DocumentCache &DocumentCache::getInstance()
|
||||||
{
|
{
|
||||||
static DocumentCache instance;
|
static DocumentCache instance;
|
||||||
|
|
|
@ -35,6 +35,9 @@ QPixmap PixmapCache::get(const QString &filename, QSize size)
|
||||||
return itr.value().pixmap(size);
|
return itr.value().pixmap(size);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
@brief Returns the singleton instance.
|
||||||
|
*/
|
||||||
PixmapCache &PixmapCache::getInstance()
|
PixmapCache &PixmapCache::getInstance()
|
||||||
{
|
{
|
||||||
static PixmapCache instance;
|
static PixmapCache instance;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user