From 7c1c085a0a0ec38a258bb90cd2903765040a5448 Mon Sep 17 00:00:00 2001 From: liuxinhao Date: Mon, 14 Nov 2022 19:04:00 +0800 Subject: [PATCH] =?UTF-8?q?=E9=9B=86=E6=88=90=E6=BF=80=E6=B4=BB,=E9=87=8D?= =?UTF-8?q?=E6=9E=84=E4=BB=A3=E7=A0=81,=E6=96=B0=E5=A2=9E=E5=BF=AB?= =?UTF-8?q?=E6=8D=B7=E9=94=AE=E4=BF=AE=E5=A4=8D,=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E5=86=85=E5=AD=98=E6=B3=84=E6=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 简要展示激活信息,提供激活信息入口 - 修复部分代码问题 - 调整控制中心弹窗按钮问题 - 修复快捷键 提取desktop entry Exec过滤%u,%f问题 - 修复检查出内存泄漏的问题 --- ...efly-displays-the-license-informatio.patch | 429 ++++++++++++ ...ck-Fix-problems-in-valgrind-memcheck.patch | 100 +++ ...ter-the-Exec-Key-when-reading-the-ex.patch | 34 + ...djust-the-pop-up-button-of-account-m.patch | 62 ++ ...actor-Reconstruct-the-code-structure.patch | 630 ++++++++++++++++++ kiran-control-panel.spec | 17 +- 6 files changed, 1270 insertions(+), 2 deletions(-) create mode 100644 0001-feat-license-briefly-displays-the-license-informatio.patch create mode 100644 0002-fix-memcheck-Fix-problems-in-valgrind-memcheck.patch create mode 100644 0003-fix-shortcut-Filter-the-Exec-Key-when-reading-the-ex.patch create mode 100644 0004-fix-messagebox-Adjust-the-pop-up-button-of-account-m.patch create mode 100644 0005-refactor-Reconstruct-the-code-structure.patch diff --git a/0001-feat-license-briefly-displays-the-license-informatio.patch b/0001-feat-license-briefly-displays-the-license-informatio.patch new file mode 100644 index 0000000..62ec02d --- /dev/null +++ b/0001-feat-license-briefly-displays-the-license-informatio.patch @@ -0,0 +1,429 @@ +From 19ed0f093a304c99f7b54dc66ef0c05ceb3162bd Mon Sep 17 00:00:00 2001 +From: liuxinhao +Date: Mon, 7 Nov 2022 15:44:34 +0800 +Subject: [PATCH 1/5] feat(license): briefly displays the license + information,provide access to the activation interface +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +- 简要展示激活信息,提供激活信息入口 +--- + plugins/system/CMakeLists.txt | 6 + + .../data/com.kylinsec.Kiran.LicenseObject.xml | 45 +++++++ + .../system-information/system-information.cpp | 124 +++++++++++++++--- + .../system-information/system-information.h | 8 +- + .../system-information/system-information.ui | 85 ++++++++++++ + 5 files changed, 249 insertions(+), 19 deletions(-) + create mode 100644 plugins/system/data/com.kylinsec.Kiran.LicenseObject.xml + +diff --git a/plugins/system/CMakeLists.txt b/plugins/system/CMakeLists.txt +index fb49f4b..619f469 100644 +--- a/plugins/system/CMakeLists.txt ++++ b/plugins/system/CMakeLists.txt +@@ -18,9 +18,15 @@ file(GLOB_RECURSE SYSTEM_SRC ${CMAKE_CURRENT_SOURCE_DIR}/*.cpp + + qt5_create_translation(SYSTEM_QM ${CMAKE_CURRENT_SOURCE_DIR} .//translations/kiran-cpanel-system.zh_CN.ts) + ++kiran_qt5_add_dbus_interface_ex(LICENSE_DBUS_SRC ++ data/com.kylinsec.Kiran.LicenseObject.xml ++ dbus_license_dbus ++ DBusLicenseObject) ++ + add_library(${TARGET_NAME} SHARED + ${SYSTEM_SRC} + ${SYSTEM_QM} ++ ${LICENSE_DBUS_SRC} + ${CMAKE_CURRENT_SOURCE_DIR}/data/res.qrc) + + target_include_directories(${TARGET_NAME} PRIVATE +diff --git a/plugins/system/data/com.kylinsec.Kiran.LicenseObject.xml b/plugins/system/data/com.kylinsec.Kiran.LicenseObject.xml +new file mode 100644 +index 0000000..cf3760f +--- /dev/null ++++ b/plugins/system/data/com.kylinsec.Kiran.LicenseObject.xml +@@ -0,0 +1,45 @@ ++ ++ ++ ++ ++ ++ ++ ++ The license info contain activation status, service status, activation code, machine code and activation type etc.. ++ ++ Get the license info. ++ ++ ++ ++ ++ The activation code. ++ ++ Activate by activation code. ++ ++ ++ ++ ++ The usb key info contain authorized points and remaining points. ++ ++ Activate by usb key. ++ ++ ++ ++ ++ The host used to request activation code. ++ ++ ++ The service uid to request activation code. ++ ++ Activate on-line. ++ ++ ++ ++ ++ The placeholder. ++ ++ The license info is changed, you need call function GetLicense to get the newest license info. ++ ++ ++ ++ +diff --git a/plugins/system/src/pages/system-information/system-information.cpp b/plugins/system/src/pages/system-information/system-information.cpp +index 4409040..bf36086 100644 +--- a/plugins/system/src/pages/system-information/system-information.cpp ++++ b/plugins/system/src/pages/system-information/system-information.cpp +@@ -14,11 +14,14 @@ + + #include "system-information.h" + #include "dbus-wrapper/system-info-dbus.h" ++#include "dbus_license_dbus.h" + #include "license-agreement.h" + #include "ui_system-information.h" + +- + #include ++#include ++#include ++#include + #include + #include + #include +@@ -26,7 +29,10 @@ + #include + #include + #include +-#include ++#include ++#include ++#include ++ + #define HOST_NAME "host_name" + #define ARCH "arch" + #define KERNEL_VERSION "kernel_version" +@@ -34,7 +40,7 @@ + #define KERNEL_RELEASE "kernel_release" + #define PRODUCT_RELEASE "product_release" + +-SystemInformation::SystemInformation(QWidget *parent) ++SystemInformation::SystemInformation(QWidget* parent) + : QWidget(parent), ui(new Ui::SystemInformation), hostNameWidget(nullptr), licenseAgreement(nullptr) + { + ui->setupUi(this); +@@ -78,9 +84,10 @@ void SystemInformation::init() + }); + // clang-format on + connect(ui->btn_change_name, &QPushButton::clicked, this, &SystemInformation::handleChangeHostName); +- Kiran::StylePropertyHelper::setButtonType(ui->btn_change_name,Kiran::BUTTON_Default); +- Kiran::StylePropertyHelper::setButtonType(ui->btn_EULA,Kiran::BUTTON_Default); +- Kiran::StylePropertyHelper::setButtonType(ui->btn_version_license,Kiran::BUTTON_Default); ++ Kiran::StylePropertyHelper::setButtonType(ui->btn_change_name, Kiran::BUTTON_Default); ++ Kiran::StylePropertyHelper::setButtonType(ui->btn_EULA, Kiran::BUTTON_Default); ++ Kiran::StylePropertyHelper::setButtonType(ui->btn_version_license, Kiran::BUTTON_Default); ++ Kiran::StylePropertyHelper::setButtonType(ui->btn_license_show, Kiran::BUTTON_Default); + } + + bool SystemInformation::initUI() +@@ -97,7 +104,7 @@ bool SystemInformation::initUI() + } + else + { +- QString hostname,arch,systemVersion,kernelVersion; ++ QString hostname, arch, systemVersion, kernelVersion; + parseSoftwareInfoJson(systemInfoJson, + hostname, + arch, +@@ -108,16 +115,26 @@ bool SystemInformation::initUI() + ui->lab_system_arch_info->setText(arch); + ui->lab_system_version_info->setText(systemVersion); + ui->lab_core_version_info->setText(kernelVersion); ++ } + ++ QString licenseDesc; ++ if (!checkLicensEnable() || !getLicenseDesc(licenseDesc)) ++ { ++ ui->widget_license->setVisible(false); ++ } ++ else ++ { ++ ui->lab_license_status->setText(licenseDesc); ++ connect(ui->btn_license_show, &QPushButton::clicked, this, &SystemInformation::handleShowLicenseDialog); + } + +- QList labels = {ui->lab_name_info,ui->lab_core_version_info, ui->lab_system_arch_info,ui->lab_system_version_info}; +- for (auto label : labels) ++ QList labels = {ui->lab_name_info, ui->lab_core_version_info, ui->lab_system_arch_info, ui->lab_system_version_info, ui->lab_license_status}; ++ for (QLabel* label : labels) + { + label->setStyleSheet("color:#919191;font-family: \"Noto Sans CJK SC regular\";"); + } + +- auto kiranFrames = findChildren(); ++ auto kiranFrames = findChildren(); + for (auto frame : kiranFrames) + { + frame->setRadius(6); +@@ -151,25 +168,90 @@ void SystemInformation::parseSoftwareInfoJson(QString jsonString, + return; + } + QJsonObject rootObject = jsonDocument.object(); +- if( rootObject.contains("host_name") && rootObject["host_name"].isString() ) ++ if (rootObject.contains("host_name") && rootObject["host_name"].isString()) + { + hostName = rootObject["host_name"].toString(); + } +- if( rootObject.contains("arch") && rootObject["arch"].isString() ) ++ if (rootObject.contains("arch") && rootObject["arch"].isString()) + { + arch = rootObject["arch"].toString(); + } +- if( rootObject.contains("product_release") && rootObject["product_release"].isString() ) ++ if (rootObject.contains("product_release") && rootObject["product_release"].isString()) + { + systemVersion = rootObject["product_release"].toString(); + } +- if( rootObject.contains("kernal_name") && rootObject["kernal_name"].isString() && +- rootObject.contains("kernel_release") && rootObject["kernel_release"].isString() ) ++ if (rootObject.contains("kernal_name") && rootObject["kernal_name"].isString() && ++ rootObject.contains("kernel_release") && rootObject["kernel_release"].isString()) + { + kernelVersion = rootObject["kernal_name"].toString() + " " + rootObject["kernel_release"].toString(); + } + } + ++bool SystemInformation::checkLicensEnable() ++{ ++ QDBusConnection dbusConn = QDBusConnection::systemBus(); ++ return dbusConn.interface()->isServiceRegistered("com.kylinsec.Kiran.LicenseManager"); ++} ++ ++bool SystemInformation::getLicenseDesc(QString& licenseStatus) ++{ ++ DBusLicenseObject dBusLicenseObject("com.kylinsec.Kiran.LicenseManager", ++ "/com/kylinsec/Kiran/LicenseObject/KylinSecOS", ++ QDBusConnection::systemBus()); ++ auto reply = dBusLicenseObject.GetLicense(); ++ reply.waitForFinished(); ++ if (reply.isError()) ++ { ++ KLOG_ERROR() << "KylinSecOS GetLicense failed:" << reply.error(); ++ return false; ++ } ++ ++ QString licenseJson = reply.value(); ++ QJsonDocument jsonDocument = QJsonDocument::fromJson(licenseJson.toUtf8()); ++ QJsonObject rootObj = jsonDocument.object(); ++ QStringList keys = rootObj.keys(); ++ ++ QSet keySet = {"expired_time","activation_status"}; ++ for( auto key:keySet ) ++ { ++ if( !keys.contains(key) ) ++ { ++ KLOG_ERROR() << "KylinSecOS GetLicense missing key:" << key; ++ return false; ++ } ++ } ++ ++ QVariant expiredTimeVar = rootObj["expired_time"].toVariant(); ++ qlonglong expiredTimeSinceEpoch = expiredTimeVar.toULongLong(); ++ ++ QVariant activationStatusVar = rootObj["activation_status"].toVariant(); ++ qulonglong activationStatus = activationStatusVar.toULongLong(); ++ ++ QDateTime expiredTime = QDateTime::fromSecsSinceEpoch(expiredTimeSinceEpoch); ++ if (activationStatus == 0) //未激活 ++ { ++ licenseStatus = tr("UnActivated"); ++ } ++ else ++ { ++ QDateTime currentDateTime = QDateTime::currentDateTime(); ++ ++ if( currentDateTime > expiredTime ) //激活码已过期 ++ { ++ licenseStatus = tr("Activation code has expired"); ++ } ++ else if( expiredTime.date().year() >= 2100 ) //永久激活 ++ { ++ licenseStatus = tr("Permanently activated"); ++ } ++ else //已激活 ++ { ++ licenseStatus = tr("Activated"); ++ } ++ } ++ return true; ++} ++ + /** + * @brief SystemInformation::onBtnchangeHostName: 当点击更改用户名后的槽函数 + */ +@@ -200,13 +282,21 @@ void SystemInformation::updateHostName(bool isChanged, QString name) + } + } + ++void SystemInformation::handleShowLicenseDialog() ++{ ++ if( !QProcess::startDetached("/usr/bin/ksl-os-gui") ) ++ { ++ KiranMessageBox::message(this, tr("Error"), tr("Failed to open the license activator"),KiranMessageBox::Ok); ++ } ++} ++ + /** + * @brief 事件监听,当收到激活向导窗口或者授权信息窗口的关闭事件时,释放窗口内存 + * @param obj 事件对象 + * @param obj 事件 + * @return 是否过滤 + */ +-bool SystemInformation::eventFilter(QObject *obj, QEvent *event) ++bool SystemInformation::eventFilter(QObject* obj, QEvent* event) + { + if (obj == hostNameWidget && event->type() == QEvent::Close) + { +@@ -218,5 +308,5 @@ bool SystemInformation::eventFilter(QObject *obj, QEvent *event) + + QSize SystemInformation::sizeHint() const + { +- return {500,657}; ++ return {500, 657}; + } +diff --git a/plugins/system/src/pages/system-information/system-information.h b/plugins/system/src/pages/system-information/system-information.h +index c15561c..d46ad74 100644 +--- a/plugins/system/src/pages/system-information/system-information.h ++++ b/plugins/system/src/pages/system-information/system-information.h +@@ -43,9 +43,13 @@ private: + QString &systemVersion, + QString &kernelVersion); + +-private slots : +- void handleChangeHostName(void); ++ bool checkLicensEnable(); ++ bool getLicenseDesc(QString& licenseStatus); ++ ++private slots: ++ void handleChangeHostName(void); + void updateHostName(bool isChanged, QString name); ++ void handleShowLicenseDialog(); + + protected: + bool eventFilter(QObject *obj, QEvent *event); +diff --git a/plugins/system/src/pages/system-information/system-information.ui b/plugins/system/src/pages/system-information/system-information.ui +index b036ab6..7dd5cdd 100644 +--- a/plugins/system/src/pages/system-information/system-information.ui ++++ b/plugins/system/src/pages/system-information/system-information.ui +@@ -423,6 +423,91 @@ + + + ++ ++ ++ ++ ++ 0 ++ 40 ++ ++ ++ ++ ++ 16777215 ++ 40 ++ ++ ++ ++ ++ 0 ++ ++ ++ 10 ++ ++ ++ 0 ++ ++ ++ 10 ++ ++ ++ 0 ++ ++ ++ ++ ++ Activation status: ++ ++ ++ ++ ++ ++ ++ Qt::Horizontal ++ ++ ++ ++ 40 ++ 20 ++ ++ ++ ++ ++ ++ ++ ++ TextLabel ++ ++ ++ ++ ++ ++ ++ ++ 0 ++ 0 ++ ++ ++ ++ ++ 56 ++ 28 ++ ++ ++ ++ ++ 56 ++ 28 ++ ++ ++ ++ Show ++ ++ ++ ++ ++ ++ + + + +-- +2.33.0 + diff --git a/0002-fix-memcheck-Fix-problems-in-valgrind-memcheck.patch b/0002-fix-memcheck-Fix-problems-in-valgrind-memcheck.patch new file mode 100644 index 0000000..20be214 --- /dev/null +++ b/0002-fix-memcheck-Fix-problems-in-valgrind-memcheck.patch @@ -0,0 +1,100 @@ +From 896bb4517b2a8a413265ffb6795ce2b5acb885d4 Mon Sep 17 00:00:00 2001 +From: liuxinhao +Date: Wed, 9 Nov 2022 15:02:41 +0800 +Subject: [PATCH 2/5] fix(memcheck): Fix problems in valgrind memcheck +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +- 修复valgrind memcheck中出现的问题 +--- + lib/common-widgets/kiran-frame/kiran-frame.h | 1 + + plugins/appearance/src/pages/theme/theme-widget.h | 14 +++++++------- + .../appearance/src/pages/wallpaper/wallpaper.cpp | 1 + + plugins/system/src/kylinsec-logo.cpp | 1 + + .../system-information/system-information.cpp | 5 +++-- + 5 files changed, 13 insertions(+), 9 deletions(-) + +diff --git a/lib/common-widgets/kiran-frame/kiran-frame.h b/lib/common-widgets/kiran-frame/kiran-frame.h +index 1b1f290..4a3dc9f 100644 +--- a/lib/common-widgets/kiran-frame/kiran-frame.h ++++ b/lib/common-widgets/kiran-frame/kiran-frame.h +@@ -22,6 +22,7 @@ + //给控制中心组件提供色块的控件,用于突出显示 + class KiranFrame : public QWidget + { ++ Q_OBJECT + public: + explicit KiranFrame(QWidget* parent = nullptr, Qt::WindowFlags f = Qt::WindowFlags()); + +diff --git a/plugins/appearance/src/pages/theme/theme-widget.h b/plugins/appearance/src/pages/theme/theme-widget.h +index df419ad..672876f 100644 +--- a/plugins/appearance/src/pages/theme/theme-widget.h ++++ b/plugins/appearance/src/pages/theme/theme-widget.h +@@ -44,15 +44,15 @@ protected: + virtual bool eventFilter(QObject* watched, QEvent* event); + + private: +- QLabel* m_iconSelectLabel; +- KiranFrame* m_iconImgWidget; +- QWidget* m_currIconTheme; ++ QLabel* m_iconSelectLabel = nullptr; ++ KiranFrame* m_iconImgWidget = nullptr; ++ QWidget* m_currIconTheme = nullptr; + +- QLabel* m_selectLabel; +- KiranFrame* m_themeImgWidget; ++ QLabel* m_selectLabel = nullptr; ++ KiranFrame* m_themeImgWidget = nullptr; + +- QLabel* m_cursorSelectLabel; +- KiranFrame* m_cursorWidget; ++ QLabel* m_cursorSelectLabel = nullptr; ++ KiranFrame* m_cursorWidget = nullptr; + + QString m_theme; + }; +diff --git a/plugins/appearance/src/pages/wallpaper/wallpaper.cpp b/plugins/appearance/src/pages/wallpaper/wallpaper.cpp +index 139ab0f..9abd0b8 100644 +--- a/plugins/appearance/src/pages/wallpaper/wallpaper.cpp ++++ b/plugins/appearance/src/pages/wallpaper/wallpaper.cpp +@@ -69,6 +69,7 @@ Wallpaper::~Wallpaper() + delete ui; + m_thread->quit(); + m_thread->wait(); ++ delete m_thread; + } + + void Wallpaper::initUI() +diff --git a/plugins/system/src/kylinsec-logo.cpp b/plugins/system/src/kylinsec-logo.cpp +index 31df8c4..5c1e24b 100644 +--- a/plugins/system/src/kylinsec-logo.cpp ++++ b/plugins/system/src/kylinsec-logo.cpp +@@ -19,6 +19,7 @@ + #define SYSTEM_LOGO "KylinSec OS" + + KylinsecLogo::KylinsecLogo(QWidget *parent) ++ :QWidget(parent) + { + setAccessibleName("KylinsecLogo"); + } +diff --git a/plugins/system/src/pages/system-information/system-information.cpp b/plugins/system/src/pages/system-information/system-information.cpp +index bf36086..0fb839f 100644 +--- a/plugins/system/src/pages/system-information/system-information.cpp ++++ b/plugins/system/src/pages/system-information/system-information.cpp +@@ -134,9 +134,10 @@ bool SystemInformation::initUI() + label->setStyleSheet("color:#919191;font-family: \"Noto Sans CJK SC regular\";"); + } + +- auto kiranFrames = findChildren(); +- for (auto frame : kiranFrames) ++ QList kiranFrames = findChildren(); ++ for (int i = 0; i < kiranFrames.count();i++) + { ++ KiranFrame* frame = kiranFrames.at(i); + frame->setRadius(6); + frame->setDrawBroder(false); + } +-- +2.33.0 + diff --git a/0003-fix-shortcut-Filter-the-Exec-Key-when-reading-the-ex.patch b/0003-fix-shortcut-Filter-the-Exec-Key-when-reading-the-ex.patch new file mode 100644 index 0000000..8ef9e7e --- /dev/null +++ b/0003-fix-shortcut-Filter-the-Exec-Key-when-reading-the-ex.patch @@ -0,0 +1,34 @@ +From 4813ea776b59abbe2beacea74b310249402e48e7 Mon Sep 17 00:00:00 2001 +From: liuxinhao +Date: Mon, 14 Nov 2022 16:20:50 +0800 +Subject: [PATCH 3/5] fix(shortcut): Filter the Exec Key when reading the exec + from the desktop entry +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +新增快捷键时从desktop entry读取exec时过滤掉Exec Key +--- + plugins/keybinding/src/shortcut.cpp | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/plugins/keybinding/src/shortcut.cpp b/plugins/keybinding/src/shortcut.cpp +index f15d794..b3d4e1a 100644 +--- a/plugins/keybinding/src/shortcut.cpp ++++ b/plugins/keybinding/src/shortcut.cpp +@@ -364,6 +364,12 @@ bool Shortcut::getExecFromDesktop(QString fileName, QString &exec) + if (str.isNull()) + return false; + ++ //移除掉无用的%f,%u,%F,%U ++ //https://specifications.freedesktop.org/desktop-entry-spec/1.1/ar01s06.html ++ ++ str = str.replace("%f","",Qt::CaseInsensitive); ++ str = str.replace("%u","",Qt::CaseInsensitive); ++ + exec = str; + return true; + } +-- +2.33.0 + diff --git a/0004-fix-messagebox-Adjust-the-pop-up-button-of-account-m.patch b/0004-fix-messagebox-Adjust-the-pop-up-button-of-account-m.patch new file mode 100644 index 0000000..a6f450d --- /dev/null +++ b/0004-fix-messagebox-Adjust-the-pop-up-button-of-account-m.patch @@ -0,0 +1,62 @@ +From 458eeaf6b93ace479e96dd464b9c13a1309aa67d Mon Sep 17 00:00:00 2001 +From: liuxinhao +Date: Mon, 14 Nov 2022 17:28:45 +0800 +Subject: [PATCH 4/5] fix(messagebox): Adjust the pop-up button of account + management +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +- 调整帐户管理下弹框的按钮 +--- + .../account/src/pages/create-user-page/create-user-page.cpp | 2 +- + plugins/account/src/pages/user-info-page/user-info-page.cpp | 6 +++--- + 2 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/plugins/account/src/pages/create-user-page/create-user-page.cpp b/plugins/account/src/pages/create-user-page/create-user-page.cpp +index 65a4b74..cb8695f 100644 +--- a/plugins/account/src/pages/create-user-page/create-user-page.cpp ++++ b/plugins/account/src/pages/create-user-page/create-user-page.cpp +@@ -232,7 +232,7 @@ void CreateUserPage::handlerCreateNewUserIsDone(QString userPath, + if (!errMsg.isEmpty()) + { + KiranMessageBox::message(nullptr, tr("Error"), +- errMsg, KiranMessageBox::Yes | KiranMessageBox::No); ++ errMsg, KiranMessageBox::Ok); + } + if (!userPath.isEmpty()) + { +diff --git a/plugins/account/src/pages/user-info-page/user-info-page.cpp b/plugins/account/src/pages/user-info-page/user-info-page.cpp +index 68b2e17..4e76c51 100644 +--- a/plugins/account/src/pages/user-info-page/user-info-page.cpp ++++ b/plugins/account/src/pages/user-info-page/user-info-page.cpp +@@ -311,7 +311,7 @@ void UserInfoPage::handlerUpdateUserPropertyDone(QString errMsg) + { + KiranMessageBox::message(nullptr, + tr("Error"), errMsg, +- KiranMessageBox::Yes | KiranMessageBox::No); ++ KiranMessageBox::Ok); + } + else + { +@@ -330,7 +330,7 @@ void UserInfoPage::handlerUpdatePasswdDone(QString errMsg) + { + KiranMessageBox::message(nullptr, + tr("Error"), errMsg, +- KiranMessageBox::Yes | KiranMessageBox::No); ++ KiranMessageBox::Ok); + } + else + { +@@ -363,7 +363,7 @@ void UserInfoPage::handlerDeleteUserDone(QString errMsg) + emit sigIsBusyChanged(false); + if (!errMsg.isEmpty()) + { +- KiranMessageBox::message(this, tr("Error"), errMsg, KiranMessageBox::Yes | KiranMessageBox::No); ++ KiranMessageBox::message(this, tr("Error"), errMsg, KiranMessageBox::Ok); + } + } + +-- +2.33.0 + diff --git a/0005-refactor-Reconstruct-the-code-structure.patch b/0005-refactor-Reconstruct-the-code-structure.patch new file mode 100644 index 0000000..70d5d1d --- /dev/null +++ b/0005-refactor-Reconstruct-the-code-structure.patch @@ -0,0 +1,630 @@ +From d1f1a182b540ae4b9c1c6fb35aa4ac0b5caebc9e Mon Sep 17 00:00:00 2001 +From: liuxinhao +Date: Mon, 14 Nov 2022 17:55:08 +0800 +Subject: [PATCH 5/5] refactor(*): Reconstruct the code structure +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +- 重构代码结构,简化解析IconTheme json字符串的代码 +--- + include/panel-interface.h | 2 + + include/plugin-interface-v2.h | 4 +- + include/plugin-subitem-interface.h | 2 +- + launcher/src/main.cpp | 1 - + lib/common-widgets/hover-tips/hover-tips.cpp | 7 +- + .../kiran-module-widget.cpp | 23 ++-- + .../src/kiran-cpanel-appearance.cpp | 67 --------- + .../appearance/src/kiran-cpanel-appearance.h | 60 -------- + .../appearance/src/kiran-cpanel-appearance.ui | 130 ------------------ + .../pages/theme/icon-themes/icon-themes.cpp | 79 ++++++----- + .../src/pages/theme/icon-themes/icon-themes.h | 2 +- + 11 files changed, 69 insertions(+), 308 deletions(-) + delete mode 100644 plugins/appearance/src/kiran-cpanel-appearance.cpp + delete mode 100644 plugins/appearance/src/kiran-cpanel-appearance.h + delete mode 100644 plugins/appearance/src/kiran-cpanel-appearance.ui + +diff --git a/include/panel-interface.h b/include/panel-interface.h +index 6276649..d352ed4 100644 +--- a/include/panel-interface.h ++++ b/include/panel-interface.h +@@ -22,7 +22,9 @@ namespace KiranControlPanel + class PanelInterface + { + public: ++ //通知控制中心主面板功能项信息变化 + virtual void handlePluginSubItemInfoChanged(const QString& subItemID) = 0; ++ //通知控制中心主面板 功能项 发生改变,调用该接口,控制中心将重新加载该插件下的功能项信息 + virtual void handlePluginSubItemChanged() = 0; + }; + } // namespace KiranControlPanel +diff --git a/include/plugin-interface-v2.h b/include/plugin-interface-v2.h +index 19b0824..2643ffc 100644 +--- a/include/plugin-interface-v2.h ++++ b/include/plugin-interface-v2.h +@@ -38,8 +38,8 @@ public: + //主面板调用该接口取消掉该插件初始化做的操作并卸载该插件 + virtual void uninit() = 0; + +- // 功能项数组,生存周期由插件维护 +- // 功能项发生变更时,应调用init时传入KcpInterface接口,通知主面板相关信息变更,及时加载新的功能项信息 ++ // 功能项数组 ++ // 功能项发生变更时,应调用init时传入KcpInterface接口,通知主面板功能项发生变更,及时同步功能项 + virtual QVector getSubItems() = 0; + }; + } // namespace KiranControlPanel +diff --git a/include/plugin-subitem-interface.h b/include/plugin-subitem-interface.h +index b28be7e..01fc608 100644 +--- a/include/plugin-subitem-interface.h ++++ b/include/plugin-subitem-interface.h +@@ -46,7 +46,7 @@ public: + // QVector< 显示文本(已翻译),搜索跳转标识ID > + virtual QVector> getSearchKeys() = 0; + +- //创建显示控件 ++ //创建该功能项显示控件,释放由控制中心主面板决定 + virtual QWidget* createWidget() = 0; + + //跳转至自定义搜索项 +diff --git a/launcher/src/main.cpp b/launcher/src/main.cpp +index 7bb78f2..eaeee99 100644 +--- a/launcher/src/main.cpp ++++ b/launcher/src/main.cpp +@@ -119,7 +119,6 @@ int main(int argc, char *argv[]) + w.setIcon(titleIcon); + w.setSubItems(plugin.getSubItems()); + w.resize(w.sizeHint()); +- KLOG_DEBUG() << "sizeHint:" << w.sizeHint(); + + QScreen* screen = QApplication::screenAt(QCursor::pos()); + QRect screenGeometry = screen->geometry(); +diff --git a/lib/common-widgets/hover-tips/hover-tips.cpp b/lib/common-widgets/hover-tips/hover-tips.cpp +index 61821dc..569290a 100644 +--- a/lib/common-widgets/hover-tips/hover-tips.cpp ++++ b/lib/common-widgets/hover-tips/hover-tips.cpp +@@ -39,7 +39,7 @@ void HoverTips::show(HoverTipsTypeEnum typeEnum, const QString &msg) + auto iter = m_tipsTypeIconMap.find(typeEnum); + if (iter == m_tipsTypeIconMap.end()) + { +- KLOG_WARNING() << "invalid type enum"; ++ KLOG_WARNING() << "HoverTips: invalid type enum" << typeEnum; + return; + } + +@@ -66,9 +66,10 @@ void HoverTips::updatePostion() + { + if (parentWidget() == nullptr) + { +- KLOG_WARNING() << "hover tips parnetwidget is null"; ++ KLOG_WARNING() << "HoverTips: parnetwidget is null,don't update position"; + return; + } ++ + this->move((parentWidget()->width() - width()) / 2, + (parentWidget()->height() - height()) / 2); + } +@@ -97,7 +98,7 @@ void HoverTips::setIcon(HoverTips::HoverTipsTypeEnum typeEnum, const QString &ic + QPixmap pixmap; + if (!pixmap.load(icon) || pixmap.isNull()) + { +- KLOG_WARNING() << "load icon failed."; ++ KLOG_WARNING() << "HoverTips: load icon" << icon << "failed."; + return; + } + m_tipsTypeIconMap[typeEnum] = icon; +diff --git a/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp b/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp +index 629bf83..6ddb2bd 100644 +--- a/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp ++++ b/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp +@@ -42,9 +42,12 @@ KiranModuleWidget::~KiranModuleWidget() + + void KiranModuleWidget::clear() + { +- disconnect(m_category, &Category::subItemAdded, this, &KiranModuleWidget::handleCategorySubItemAdded); +- disconnect(m_category, &Category::subItemDeleted, this, &KiranModuleWidget::handleCategorySubItemDeleted); +- disconnect(m_category, &Category::subItemInfoChanged, this, &KiranModuleWidget::handleCategorySubItemInfoChanged); ++ if (m_category != nullptr) ++ { ++ disconnect(m_category, &Category::subItemAdded, this, &KiranModuleWidget::handleCategorySubItemAdded); ++ disconnect(m_category, &Category::subItemDeleted, this, &KiranModuleWidget::handleCategorySubItemDeleted); ++ disconnect(m_category, &Category::subItemInfoChanged, this, &KiranModuleWidget::handleCategorySubItemInfoChanged); ++ } + + ui->list_subItems->clear(); + ui->widget_siderbar->hide(); +@@ -96,7 +99,7 @@ void KiranModuleWidget::appendListWidgetItem(KiranControlPanel::SubItemPtr subit + item->setWeight(subitem->getWeight()); + if (icon.isNull()) + { +- KLOG_WARNING() << "can't find subitem icon:" << name << icon; ++ KLOG_WARNING() << "KiranModuleWidget: can't find subitem icon:" << name << icon; + } + else + { +@@ -154,7 +157,7 @@ void KiranModuleWidget::handleCurrentItemChanged() + auto selectedItems = ui->list_subItems->selectedItems(); + if (selectedItems.size() != 1) + { +- KLOG_ERROR() << "sider bar size != 1"; ++ KLOG_ERROR() << "KiranModuleWidget: sider bar size != 1"; + return; + } + +@@ -162,21 +165,21 @@ void KiranModuleWidget::handleCurrentItemChanged() + + if (m_currentSubItem.first == selectedItem) + { +- KLOG_DEBUG() << "subitem not changed,ignore 'itemSelectionChanged' signal!"; ++ KLOG_DEBUG() << "KiranModuleWidget: subitem not changed,ignore 'itemSelectionChanged' signal!"; + return; + } + + auto mapIter = m_subItemsMap.find(selectedItem); + if (mapIter == m_subItemsMap.end()) + { +- KLOG_WARNING() << "can't find KiranControlPanel::SubItemPtr by QListWidgetItem," << selectedItem->text(); ++ KLOG_WARNING() << "KiranModuleWidget: can't find KiranControlPanel::SubItemPtr by QListWidgetItem," << selectedItem->text(); + return; + } + + KiranControlPanel::SubItemPtr pluginSubitem = *mapIter; + if (checkHasUnSaved()) + { +- KLOG_DEBUG() << "switch subitem to:" << pluginSubitem->getName() << "reject"; ++ KLOG_DEBUG() << "KiranModuleWidget: switch subitem to:" << pluginSubitem->getName() << "reject"; + m_currentSubItem.first->setSelected(true); + return; + } +@@ -194,12 +197,12 @@ void KiranModuleWidget::handleCurrentItemChanged() + QWidget *widget = pluginSubitem->createWidget(); + if (widget) + { +- KLOG_DEBUG() << "sub item widget sizeHint:" << widget->sizeHint(); ++ KLOG_DEBUG() << "KiranModuleWidget: sub item widget sizeHint:" << widget->sizeHint(); + ui->centerLayout->addWidget(widget); + } + else + { +- KLOG_ERROR() << "can't get subitem widget:" << pluginSubitem->getName() << pluginSubitem->getID(); ++ KLOG_ERROR() << "KiranModuleWidget: can't get subitem widget:" << pluginSubitem->getName() << pluginSubitem->getID(); + } + + m_subItemWidget = widget; +diff --git a/plugins/appearance/src/kiran-cpanel-appearance.cpp b/plugins/appearance/src/kiran-cpanel-appearance.cpp +deleted file mode 100644 +index 3dee3c6..0000000 +--- a/plugins/appearance/src/kiran-cpanel-appearance.cpp ++++ /dev/null +@@ -1,67 +0,0 @@ +-/** +- * Copyright (c) 2020 ~ 2021 KylinSec Co., Ltd. +- * kiran-control-panel is licensed under Mulan PSL v2. +- * You can use this software according to the terms and conditions of the Mulan PSL v2. +- * You may obtain a copy of Mulan PSL v2 at: +- * http://license.coscl.org.cn/MulanPSL2 +- * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, +- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, +- * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE. +- * See the Mulan PSL v2 for more details. +- * +- * Author: yuanxing +- */ +- +-#include "kiran-cpanel-appearance.h" +-#include +-#include "ui_kiran-cpanel-appearance.h" +- +-KiranCpanelAppearance::KiranCpanelAppearance(QWidget *parent) : KiranTitlebarWindow(parent), +- ui(new Ui::KiranCpanelAppearance) +-{ +- ui->setupUi(getWindowContentWidget()); +- initUI(); +- +- connect(ui->listWidget, &KiranSidebarWidget::itemClicked, +- [=](QListWidgetItem *item) { +- int row = ui->listWidget->row(item); +- ui->stackedWidget->setCurrentIndex(row); +- //TODO:后续根据需求确定是否切换列表项时需要指定第一页 +- if (row == ITEM_BACKGROUND) +- ; +- else if (row == ITEM_THEME) +- { +- ui->page_theme->setPage(0); +- } +- else +- { +- }; +- }); +-} +- +-KiranCpanelAppearance::~KiranCpanelAppearance() +-{ +- delete ui; +-} +- +-bool KiranCpanelAppearance::initUI() +-{ +- //TODO:connect dbus if faile return false; +- setIcon(QIcon::fromTheme("kcp-appearance")); +- +- ui->listWidget->setIconSize(QSize(16, 16)); +- addSidebarItem(tr("Wallpaper Setting"), ":/images/wallpaper.svg"); +- addSidebarItem(tr("Theme Setting"), ":/images/themes.svg"); +- addSidebarItem(tr("Font Setting"), ":/images/themes.svg"); +- +- ui->listWidget->setCurrentRow(0); +- return true; +-} +- +-void KiranCpanelAppearance::addSidebarItem(QString text, QString icon) +-{ +- QListWidgetItem *item = new QListWidgetItem(ui->listWidget); +- item->setIcon(QIcon(icon)); +- item->setText(text); +- ui->listWidget->addItem(item); +-} +diff --git a/plugins/appearance/src/kiran-cpanel-appearance.h b/plugins/appearance/src/kiran-cpanel-appearance.h +deleted file mode 100644 +index a5edb7c..0000000 +--- a/plugins/appearance/src/kiran-cpanel-appearance.h ++++ /dev/null +@@ -1,60 +0,0 @@ +-/** +- * Copyright (c) 2020 ~ 2021 KylinSec Co., Ltd. +- * kiran-control-panel is licensed under Mulan PSL v2. +- * You can use this software according to the terms and conditions of the Mulan PSL v2. +- * You may obtain a copy of Mulan PSL v2 at: +- * http://license.coscl.org.cn/MulanPSL2 +- * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, +- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, +- * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE. +- * See the Mulan PSL v2 for more details. +- * +- * Author: yuanxing +- */ +- +-#ifndef KIRANCPANELAPPEARANCE_H +-#define KIRANCPANELAPPEARANCE_H +-#include +- +-#include +- +-namespace Ui +-{ +-class KiranCpanelAppearance; +-} +- +-enum pages +-{ +- PAGE_BACKGROUND = 0, +- PAGE_THEME, +- PAGE_FONT, +- PAGE_BACKGROND_SELECT, +- PAGE_ICON_THEME, +- PAGE_CURSOR_THEME +-}; +- +-enum items +-{ +- ITEM_BACKGROUND = 0, +- ITEM_THEME, +- ITEM_FONT +-}; +- +-class QListWidgetItem; +-class KiranCpanelAppearance : public KiranTitlebarWindow +-{ +- Q_OBJECT +- +-public: +- explicit KiranCpanelAppearance(QWidget *parent = 0); +- ~KiranCpanelAppearance(); +- +-private: +- bool initUI(); +- void addSidebarItem(QString, QString); +- +-private: +- Ui::KiranCpanelAppearance *ui; +-}; +- +-#endif // KIRANCPANELAPPEARANCE_H +diff --git a/plugins/appearance/src/kiran-cpanel-appearance.ui b/plugins/appearance/src/kiran-cpanel-appearance.ui +deleted file mode 100644 +index d2cdea5..0000000 +--- a/plugins/appearance/src/kiran-cpanel-appearance.ui ++++ /dev/null +@@ -1,130 +0,0 @@ +- +- +- KiranCpanelAppearance +- +- +- +- 0 +- 0 +- 712 +- 591 +- +- +- +- KiranCpanelAppearance +- +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- +- +- +- 0 +- 0 +- +- +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- +- +- +- 0 +- 0 +- +- +- +- +- 282 +- 16777215 +- +- +- +- +- +- +- +- +- +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- 0 +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- KiranSidebarWidget +- QListWidget +-
/usr/include/kiranwidgets-qt5/kiran-sidebar-widget.h
+-
+- +- Fonts +- QWidget +-
pages/font/fonts.h
+- 1 +-
+- +- Themes +- QWidget +-
pages/theme/themes.h
+- 1 +-
+- +- Wallpaper +- QWidget +-
pages/wallpaper/wallpaper.h
+- 1 +-
+-
+- +- +-
+diff --git a/plugins/appearance/src/pages/theme/icon-themes/icon-themes.cpp b/plugins/appearance/src/pages/theme/icon-themes/icon-themes.cpp +index 184ae66..6e6f614 100644 +--- a/plugins/appearance/src/pages/theme/icon-themes/icon-themes.cpp ++++ b/plugins/appearance/src/pages/theme/icon-themes/icon-themes.cpp +@@ -13,9 +13,11 @@ + */ + + #include "icon-themes.h" ++ + #include + #include + #include ++ + #include + #include + #include +@@ -23,6 +25,7 @@ + #include + #include + #include ++ + #include "../theme-widget-group.h" + #include "../theme-widget.h" + #include "dbus-interface/appearance-global-info.h" +@@ -49,7 +52,7 @@ IconThemes::~IconThemes() + + bool IconThemes::initUI() + { +- if (!getIconThemes(APPEARANCE_THEME_TYPE_ICON)) ++ if (!getIconThemes()) + { + return false; + } +@@ -84,10 +87,10 @@ void IconThemes::updateIconTheme(QString newIconTheme) + * @return true 成功 + * false 失败 + */ +-bool IconThemes::getIconThemes(int themeType) ++bool IconThemes::getIconThemes() + { + QString iconThemesJson = nullptr; +- if (!AppearanceGlobalInfo::instance()->getAllThemes(themeType, iconThemesJson)) ++ if (!AppearanceGlobalInfo::instance()->getAllThemes(APPEARANCE_THEME_TYPE_ICON, iconThemesJson)) + { + return false; + } +@@ -103,44 +106,51 @@ int IconThemes::getJsonValueFromString(QString jsonString) + { + QJsonParseError jsonError; + QJsonDocument jsonDocument = QJsonDocument::fromJson(jsonString.toLocal8Bit().data(), &jsonError); ++ + if (jsonDocument.isNull() || jsonError.error != QJsonParseError::NoError) + { +- KLOG_ERROR() << " please check the string " << jsonString.toLocal8Bit().data(); ++ KLOG_ERROR() << "parse icon theme json failed," << jsonString << jsonError.errorString() << jsonError.error; ++ return -1; ++ } ++ ++ if( !jsonDocument.isArray() ) ++ { ++ return 0; ++ } ++ ++ QJsonArray array = jsonDocument.array(); ++ if( array.size() < 1 ) ++ { + return -1; + } +- if (jsonDocument.isArray()) ++ ++ for (int i = 0; i < array.size();i++) + { +- QJsonArray array = jsonDocument.array(); +- int iconThemesNum = array.size(); +- if (iconThemesNum < 1) +- return -1; +- for (int i = 0; i < iconThemesNum; i++) ++ QJsonValue value = array.at(i); ++ if( value.type() != QJsonValue::Object ) + { +- QJsonValue value = array.at(i); +- if (value.type() == QJsonValue::Object) +- { +- QJsonObject themeInfoObj = value.toObject(); +- if (themeInfoObj.contains("name")) +- { +- QJsonValue themeValue = themeInfoObj.value("name"); +- if (themeValue.isString()) +- { +- QString name = themeValue.toVariant().toString(); +- m_iconThemes.insert(i, name); +- } +- } +- if (themeInfoObj.contains("path")) +- { +- QJsonValue themeValue = themeInfoObj.value("path"); +- if (themeValue.isString()) +- { +- QString path = themeValue.toVariant().toString(); +- m_iconThemesPath.insert(i, path); +- } +- } +- } ++ continue; + } ++ ++ QJsonObject themeInfoObj = value.toObject(); ++ if( !themeInfoObj.contains("name") || !themeInfoObj.contains("path") ) ++ { ++ KLOG_WARNING() << "parse getAllThemes json failed,Missing specific key(name/path)"; ++ continue; ++ } ++ if( !themeInfoObj["name"].isString() || !themeInfoObj["path"].isString() ) ++ { ++ KLOG_WARNING() << "parse getAllThemes json failed,Wrong key format(name/path)"; ++ continue; ++ } ++ ++ QString name = themeInfoObj["name"].toString(); ++ m_iconThemes.append(name); ++ ++ QString path = themeInfoObj["path"].toString(); ++ m_iconThemesPath.append(path); + } ++ + return m_iconThemes.size(); + } + +@@ -153,8 +163,10 @@ void IconThemes::createIconWidgets() + QVBoxLayout *vLayout = new QVBoxLayout(ui->widget_icon); + vLayout->setMargin(0); + vLayout->setSpacing(4); ++ + for (int i = 0; i < m_iconThemes.size(); i++) + { ++ + if (m_iconThemes.at(i).startsWith("Kiran", Qt::CaseInsensitive)) + { + QString path = m_iconThemesPath.at(i) + "/apps/scalable/"; +@@ -238,6 +250,7 @@ void IconThemes::createIconWidgets() + continue; + } + } ++ + connect(m_iconThemeWidgetGroup, &ThemeWidgetGroup::themeWidgetChange, + [=](ThemeWidget *preWidget, ThemeWidget *currWidget) { + if (currWidget->getTheme() == m_currentIconTheme) +diff --git a/plugins/appearance/src/pages/theme/icon-themes/icon-themes.h b/plugins/appearance/src/pages/theme/icon-themes/icon-themes.h +index 1e57ee0..3a86516 100644 +--- a/plugins/appearance/src/pages/theme/icon-themes/icon-themes.h ++++ b/plugins/appearance/src/pages/theme/icon-themes/icon-themes.h +@@ -34,7 +34,7 @@ public: + void updateIconTheme(QString newIconTheme); + + private: +- bool getIconThemes(int themeType); ++ bool getIconThemes(); + int getJsonValueFromString(QString jsonString); + void createIconWidgets(); + +-- +2.33.0 + diff --git a/kiran-control-panel.spec b/kiran-control-panel.spec index d12c6c9..9961dc2 100644 --- a/kiran-control-panel.spec +++ b/kiran-control-panel.spec @@ -1,13 +1,19 @@ Name: kiran-control-panel Version: 2.4.0 -Release: 2 +Release: 3 Summary: Kiran Control Panel Summary(zh_CN): Kiran桌面控制面板 License: MulanPSL-2.0 Source0: %{name}-%{version}.tar.gz -Patch0001: 0001-fix-network-tray-Fix-the-problem-that-the-tray-has-a.patch +Patch0001: 0001-fix-network-tray-Fix-the-problem-that-the-tray-has-a.patch +Patch0002: 0001-feat-license-briefly-displays-the-license-informatio.patch +Patch0003: 0002-fix-memcheck-Fix-problems-in-valgrind-memcheck.patch +Patch0004: 0003-fix-shortcut-Filter-the-Exec-Key-when-reading-the-ex.patch +Patch0005: 0004-fix-messagebox-Adjust-the-pop-up-button-of-account-m.patch +Patch0006: 0005-refactor-Reconstruct-the-code-structure.patch + BuildRequires: gcc-c++ BuildRequires: cmake >= 3.2 @@ -143,6 +149,13 @@ make %{?_smp_mflags} rm -rf %{buildroot} %changelog +* Mon Nov 14 2022 liuxinhao - 2.4.0-3 +- KYOS-F: Reconstruct the code structure +- KYOS-F: Adjust the pop-up button of account management +- KYOS-F: Filter the Exec Key when reading the exec from the desktop entry +- KYOS-F: Fix problems in valgrind memcheck +- KYOS-F: briefly displays the license information,provide access to the activation interface + * Fri Nov 04 2022 luoqing - 2.4.0-2 - KYOS-F: Fix the problem that the tray has an unavailable widget when the device is available -- Gitee