mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
Merge branch 'pr1524' into back_in_the_game
Conflicts: src/widget/form/groupchatform.cpp
This commit is contained in:
commit
8b6ef7ab9d
|
@ -244,17 +244,17 @@ void ChatLine::moveBy(qreal deltaY)
|
|||
bbox.moveTop(bbox.top() + deltaY);
|
||||
}
|
||||
|
||||
bool ChatLine::lessThanBSRectTop(const ChatLine::Ptr lhs, const qreal rhs)
|
||||
bool ChatLine::lessThanBSRectTop(const ChatLine::Ptr& lhs, const qreal& rhs)
|
||||
{
|
||||
return lhs->sceneBoundingRect().top() < rhs;
|
||||
}
|
||||
|
||||
bool ChatLine::lessThanBSRectBottom(const ChatLine::Ptr lhs, const qreal rhs)
|
||||
bool ChatLine::lessThanBSRectBottom(const ChatLine::Ptr& lhs, const qreal& rhs)
|
||||
{
|
||||
return lhs->sceneBoundingRect().bottom() < rhs;
|
||||
}
|
||||
|
||||
bool ChatLine::lessThanRowIndex(const ChatLine::Ptr lhs, const ChatLine::Ptr rhs)
|
||||
bool ChatLine::lessThanRowIndex(const ChatLine::Ptr& lhs, const ChatLine::Ptr& rhs)
|
||||
{
|
||||
return lhs->getRow() < rhs->getRow();
|
||||
}
|
||||
|
|
|
@ -82,9 +82,9 @@ public:
|
|||
bool isOverSelection(QPointF scenePos);
|
||||
|
||||
//comparators
|
||||
static bool lessThanBSRectTop(const ChatLine::Ptr lhs, const qreal rhs);
|
||||
static bool lessThanBSRectBottom(const ChatLine::Ptr lhs, const qreal rhs);
|
||||
static bool lessThanRowIndex(const ChatLine::Ptr lhs, const ChatLine::Ptr rhs);
|
||||
static bool lessThanBSRectTop(const ChatLine::Ptr& lhs, const qreal& rhs);
|
||||
static bool lessThanBSRectBottom(const ChatLine::Ptr& lhs, const qreal& rhs);
|
||||
static bool lessThanRowIndex(const ChatLine::Ptr& lhs, const ChatLine::Ptr& rhs);
|
||||
|
||||
protected:
|
||||
friend class ChatLog;
|
||||
|
|
|
@ -36,13 +36,15 @@ CameraWorker::~CameraWorker()
|
|||
}
|
||||
|
||||
void CameraWorker::onStart()
|
||||
{
|
||||
if (!clock)
|
||||
{
|
||||
clock = new QTimer(this);
|
||||
clock->setSingleShot(false);
|
||||
clock->setInterval(1000/60);
|
||||
|
||||
connect(clock, &QTimer::timeout, this, &CameraWorker::doWork);
|
||||
|
||||
}
|
||||
emit started();
|
||||
}
|
||||
|
||||
|
|
|
@ -64,11 +64,10 @@ GroupChatForm::GroupChatForm(Group* chatGroup)
|
|||
|
||||
namesListLayout = new FlowLayout(0,5,0);
|
||||
QStringList names(group->getPeerList());
|
||||
QLabel *l;
|
||||
|
||||
for (const QString& name : names)
|
||||
{
|
||||
l = new QLabel(name);
|
||||
QLabel *l = new QLabel(name);
|
||||
l->setTextFormat(Qt::PlainText);
|
||||
namesListLayout->addWidget(l);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user