mirror of
https://github.com/linuxdeepin/dde-dock.git
synced 2025-06-04 17:33:05 +00:00
add accessibility name to tips
Change-Id: I9db8447ab3e8be46bd78ab4e8b9c9620802eb2a5
This commit is contained in:
parent
53e8f61ab5
commit
de444b01bc
@ -30,6 +30,7 @@ AppItem::AppItem(const QDBusObjectPath &entry, QWidget *parent)
|
|||||||
m_id = m_itemEntry->id();
|
m_id = m_itemEntry->id();
|
||||||
m_active = m_itemEntry->active();
|
m_active = m_itemEntry->active();
|
||||||
|
|
||||||
|
m_appNameTips->setObjectName(m_itemEntry->name());
|
||||||
m_appNameTips->setVisible(false);
|
m_appNameTips->setVisible(false);
|
||||||
m_appNameTips->setStyleSheet("color:white;"
|
m_appNameTips->setStyleSheet("color:white;"
|
||||||
"padding:5px 10px;");
|
"padding:5px 10px;");
|
||||||
|
@ -13,6 +13,7 @@ LauncherItem::LauncherItem(QWidget *parent)
|
|||||||
{
|
{
|
||||||
setAccessibleName("Launcher");
|
setAccessibleName("Launcher");
|
||||||
m_tips->setVisible(false);
|
m_tips->setVisible(false);
|
||||||
|
m_tips->setObjectName("launcher");
|
||||||
m_tips->setText(tr("Launcher"));
|
m_tips->setText(tr("Launcher"));
|
||||||
m_tips->setStyleSheet("color:white;"
|
m_tips->setStyleSheet("color:white;"
|
||||||
"padding:5px 10px;");
|
"padding:5px 10px;");
|
||||||
|
@ -22,8 +22,6 @@ PluginsItem::PluginsItem(PluginsItemInterface* const pluginInter, const QString
|
|||||||
{
|
{
|
||||||
Q_ASSERT(m_centeralWidget);
|
Q_ASSERT(m_centeralWidget);
|
||||||
|
|
||||||
setAccessibleName(m_pluginInter->pluginName());
|
|
||||||
|
|
||||||
QBoxLayout *hLayout = new QHBoxLayout;
|
QBoxLayout *hLayout = new QHBoxLayout;
|
||||||
hLayout->addWidget(m_centeralWidget);
|
hLayout->addWidget(m_centeralWidget);
|
||||||
hLayout->setSpacing(0);
|
hLayout->setSpacing(0);
|
||||||
@ -33,6 +31,7 @@ PluginsItem::PluginsItem(PluginsItemInterface* const pluginInter, const QString
|
|||||||
m_centeralWidget->setVisible(true);
|
m_centeralWidget->setVisible(true);
|
||||||
|
|
||||||
setLayout(hLayout);
|
setLayout(hLayout);
|
||||||
|
setAccessibleName(pluginInter->pluginName() + "-" + m_itemKey);
|
||||||
setAttribute(Qt::WA_TranslucentBackground);
|
setAttribute(Qt::WA_TranslucentBackground);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -33,6 +33,8 @@ void DockPopupWindow::setContent(QWidget *content)
|
|||||||
lastWidget->removeEventFilter(this);
|
lastWidget->removeEventFilter(this);
|
||||||
content->installEventFilter(this);
|
content->installEventFilter(this);
|
||||||
|
|
||||||
|
setAccessibleName(content->objectName() + "-popup");
|
||||||
|
|
||||||
DArrowRectangle::setContent(content);
|
DArrowRectangle::setContent(content);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -9,6 +9,7 @@ DatetimePlugin::DatetimePlugin(QObject *parent)
|
|||||||
|
|
||||||
m_refershTimer(new QTimer(this))
|
m_refershTimer(new QTimer(this))
|
||||||
{
|
{
|
||||||
|
m_dateTipsLabel->setObjectName("datetime");
|
||||||
m_dateTipsLabel->setStyleSheet("color:white;"
|
m_dateTipsLabel->setStyleSheet("color:white;"
|
||||||
"padding:6px 10px;");
|
"padding:6px 10px;");
|
||||||
|
|
||||||
|
@ -41,6 +41,7 @@ QWidget *DiskMountPlugin::itemPopupApplet(const QString &itemKey)
|
|||||||
void DiskMountPlugin::initCompoments()
|
void DiskMountPlugin::initCompoments()
|
||||||
{
|
{
|
||||||
m_diskControlApplet = new DiskControlWidget;
|
m_diskControlApplet = new DiskControlWidget;
|
||||||
|
m_diskControlApplet->setObjectName("dist-mount");
|
||||||
m_diskControlApplet->setVisible(false);
|
m_diskControlApplet->setVisible(false);
|
||||||
|
|
||||||
connect(m_diskControlApplet, &DiskControlWidget::diskCountChanged, this, &DiskMountPlugin::diskCountChanged);
|
connect(m_diskControlApplet, &DiskControlWidget::diskCountChanged, this, &DiskMountPlugin::diskCountChanged);
|
||||||
|
@ -11,6 +11,7 @@ WiredItem::WiredItem(const QUuid &deviceUuid)
|
|||||||
m_itemTips(new QLabel(this))
|
m_itemTips(new QLabel(this))
|
||||||
{
|
{
|
||||||
|
|
||||||
|
m_itemTips->setObjectName("wired-" + deviceUuid.toString());
|
||||||
m_itemTips->setVisible(false);
|
m_itemTips->setVisible(false);
|
||||||
m_itemTips->setStyleSheet("color:white;"
|
m_itemTips->setStyleSheet("color:white;"
|
||||||
"padding:5px 10px;");
|
"padding:5px 10px;");
|
||||||
|
@ -80,6 +80,7 @@ void WirelessItem::init()
|
|||||||
const auto devInfo = m_networkManager->device(m_deviceUuid);
|
const auto devInfo = m_networkManager->device(m_deviceUuid);
|
||||||
|
|
||||||
m_applet = new WirelessApplet(devInfo, this);
|
m_applet = new WirelessApplet(devInfo, this);
|
||||||
|
m_applet->setObjectName("wireless-" + m_deviceUuid.toString());
|
||||||
m_applet->setVisible(false);
|
m_applet->setVisible(false);
|
||||||
|
|
||||||
connect(m_applet, &WirelessApplet::activeAPChanged, this, static_cast<void (WirelessItem::*)()>(&WirelessItem::update));
|
connect(m_applet, &WirelessApplet::activeAPChanged, this, static_cast<void (WirelessItem::*)()>(&WirelessItem::update));
|
||||||
|
@ -15,6 +15,7 @@ ShutdownPlugin::ShutdownPlugin(QObject *parent)
|
|||||||
m_powerInter(new DBusPower(this))
|
m_powerInter(new DBusPower(this))
|
||||||
{
|
{
|
||||||
m_tipsLabel->setVisible(false);
|
m_tipsLabel->setVisible(false);
|
||||||
|
m_tipsLabel->setObjectName("power");
|
||||||
m_tipsLabel->setAlignment(Qt::AlignCenter);
|
m_tipsLabel->setAlignment(Qt::AlignCenter);
|
||||||
m_tipsLabel->setStyleSheet("color:white;"
|
m_tipsLabel->setStyleSheet("color:white;"
|
||||||
"padding:5px 10px;");
|
"padding:5px 10px;");
|
||||||
|
@ -11,6 +11,7 @@ SystemTrayPlugin::SystemTrayPlugin(QObject *parent)
|
|||||||
m_trayInter(new DBusTrayManager(this)),
|
m_trayInter(new DBusTrayManager(this)),
|
||||||
m_tipsWidget(new TipsWidget)
|
m_tipsWidget(new TipsWidget)
|
||||||
{
|
{
|
||||||
|
m_tipsWidget->setObjectName("sys-tray");
|
||||||
m_fashionItem = new FashionTrayItem;
|
m_fashionItem = new FashionTrayItem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user