mirror of
https://github.com/linuxdeepin/dde-dock.git
synced 2025-06-04 09:23:03 +00:00

清除编译警告和cppcheck检查出的警告信息 Log: Influence: 无 Task: https://pms.uniontech.com/zentao/task-view-96546.html Change-Id: I8b32b02c9d3a284029a39826516ab7b41132f236
41 lines
843 B
C++
41 lines
843 B
C++
#include "attentioncontainer.h"
|
|
|
|
AttentionContainer::AttentionContainer(TrayPlugin *trayPlugin, QWidget *parent)
|
|
: AbstractContainer(trayPlugin, parent)
|
|
{
|
|
|
|
}
|
|
|
|
FashionTrayWidgetWrapper *AttentionContainer::takeAttentionWrapper()
|
|
{
|
|
if (isEmpty()) {
|
|
return nullptr;
|
|
}
|
|
|
|
return takeWrapper(wrapperList().first());
|
|
}
|
|
|
|
bool AttentionContainer::acceptWrapper(FashionTrayWidgetWrapper *wrapper)
|
|
{
|
|
Q_UNUSED(wrapper);
|
|
|
|
return true;
|
|
}
|
|
|
|
void AttentionContainer::refreshVisible()
|
|
{
|
|
// AbstractContainer::refreshVisible();
|
|
setContentsMargins(0, 0, 0 ,0);
|
|
setVisible(!isEmpty());
|
|
}
|
|
|
|
void AttentionContainer::addWrapper(FashionTrayWidgetWrapper *wrapper)
|
|
{
|
|
if (!isEmpty()) {
|
|
qDebug() << "Reject! Already contains a attention wrapper!";
|
|
return;
|
|
}
|
|
|
|
AbstractContainer::addWrapper(wrapper);
|
|
}
|