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

在图标排序时,对于系统图标,会自动全部排在其他图标后面,而声音图标正好是属于系统图标,在切换Dock显示模式时,会将声音图标显示在网络图标后面 Log: 修复调整声音插件顺序,切换任务栏模式之后,声音插件顺序改变问题(bug:38862) Bug: https://pms.uniontech.com/zentao/bug-view-38862.html Change-Id: Ib080d6eed3a361974142911ff81e9fa0003ae01f Reviewed-on: http://gerrit.uniontech.com/c/dde-dock/+/343 Reviewed-by: lizhongming <lizhongming@uniontech.com> Tested-by: lizhongming <lizhongming@uniontech.com>
51 lines
1.6 KiB
C++
51 lines
1.6 KiB
C++
/*
|
|
* Copyright (C) 2017 ~ 2018 Deepin Technology Co., Ltd.
|
|
*
|
|
* Author: rekols <rekols@foxmail.com>
|
|
*
|
|
* This program is free software: you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
* any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
#ifndef KEYBOARDPLUGIN_H
|
|
#define KEYBOARDPLUGIN_H
|
|
|
|
#include "pluginsiteminterface.h"
|
|
#include "dbusadaptors.h"
|
|
|
|
class KeyboardPlugin : public QObject, PluginsItemInterface
|
|
{
|
|
Q_OBJECT
|
|
Q_INTERFACES(PluginsItemInterface)
|
|
Q_PLUGIN_METADATA(IID "com.deepin.dock.PluginsItemInterface" FILE "keyboard.json")
|
|
|
|
public:
|
|
explicit KeyboardPlugin(QObject *parent = nullptr);
|
|
~KeyboardPlugin() override;
|
|
|
|
const QString pluginName() const override;
|
|
const QString pluginDisplayName() const override;
|
|
void init(PluginProxyInterface *proxyInter) override;
|
|
|
|
QWidget *itemWidget(const QString &itemKey) override;
|
|
QWidget *itemTipsWidget(const QString &itemKey) override;
|
|
|
|
int itemSortKey(const QString &itemKey) override;
|
|
void setSortKey(const QString &itemKey, const int order) override;
|
|
|
|
private:
|
|
DBusAdaptors *m_dbusAdaptors = nullptr;
|
|
};
|
|
|
|
#endif
|