diff --git a/time-shutdown-4.0.0.0-fix-Selection-box-arrow-error.patch b/time-shutdown-4.0.0.0-fix-Selection-box-arrow-error.patch deleted file mode 100644 index 8840cb7994fff3b7670c2965dc3dac0e1957db2d..0000000000000000000000000000000000000000 --- a/time-shutdown-4.0.0.0-fix-Selection-box-arrow-error.patch +++ /dev/null @@ -1,75 +0,0 @@ -From 38bc681fe4187f5843498c12b2b93d10273872dc Mon Sep 17 00:00:00 2001 -From: huayadong -Date: Sat, 7 Dec 2024 07:29:19 +0800 -Subject: [PATCH] fix Selection box arrow error - ---- - time-shutdown/comboxwidget.cpp | 2 +- - time-shutdown/widget.cpp | 13 +++++++------ - time-shutdown/widget.h | 1 + - 3 files changed, 9 insertions(+), 7 deletions(-) - -diff --git a/time-shutdown/comboxwidget.cpp b/time-shutdown/comboxwidget.cpp -index d40f8a4..df5020a 100644 ---- a/time-shutdown/comboxwidget.cpp -+++ b/time-shutdown/comboxwidget.cpp -@@ -45,7 +45,7 @@ void comBoxWidget::initMemberVariable() - m_pLabel_3 = new QLabel(); - QIcon labelIcon = QIcon::fromTheme("ukui-down.symbolic"); - m_pLabel_3->setPixmap(labelIcon.pixmap(QSize(16, 16))); -- m_pLabel_3->setProperty("useIconHighlightEffect", 0x2); -+ m_pLabel_3->setProperty("useIconHighlightEffect", 0x1); - m_pHcomBoxWidgetLayout = new QHBoxLayout(); - m_pHcomBoxWidgetLayout->setSpacing(0); - m_pHcomBoxWidgetLayout->setContentsMargins(0, 0, 0, 0); -diff --git a/time-shutdown/widget.cpp b/time-shutdown/widget.cpp -index 0aea716..bc1b05f 100644 ---- a/time-shutdown/widget.cpp -+++ b/time-shutdown/widget.cpp -@@ -542,24 +542,25 @@ void Widget::updatedropDownBoxSelectSlots() - void Widget::confirmButtonSlots() - { - if (m_weekSelect[0] == NEVER_SHUTDON) { -- QMessageBox *msg = new QMessageBox(this); -- msg->setIcon(QMessageBox::Warning); -+ KMessageBox *msg = new KMessageBox(this); -+ msg->setIcon(KMessageBox::Warning); - msg->setText(tr("no set shutdown")); - QPushButton *button = new QPushButton(QObject::tr("OK")); - button->setProperty("useButtonPalette", true); -- msg->addButton(button, QMessageBox::RejectRole); -+ msg->addButton(button, KMessageBox::RejectRole); -+ msg->move(this->x() - (msg->width() - this->width()) / 8, this->y() + 60); - msg->show(); - // QMessageBox::warning(NULL, tr("warning"), tr("no set shutdown"), QMessageBox::Ok); - return; - } - - if (determineShutdownTime()) { -- QMessageBox *msg = new QMessageBox(this); -- msg->setIcon(QMessageBox::Warning); -+ KMessageBox *msg = new KMessageBox(this); - msg->setText(tr("The shutdown time is shorter than the current time")); - QPushButton *button = new QPushButton(QObject::tr("OK")); - button->setProperty("useButtonPalette", true); -- msg->addButton(button, QMessageBox::RejectRole); -+ msg->addButton(button, KMessageBox::RejectRole); -+ msg->move(this->x() - (msg->width() - this->width()) / 8, this->y() + 60); - msg->show(); - // QMessageBox::warning(NULL, tr("warning"), \ - // tr("The shutdown time is shorter than the current time"), \ -diff --git a/time-shutdown/widget.h b/time-shutdown/widget.h -index 02e4706..153c70e 100644 ---- a/time-shutdown/widget.h -+++ b/time-shutdown/widget.h -@@ -55,6 +55,7 @@ - #include "comboxwidget.h" - #include "dropdownmenu.h" - #include "kwidget.h" -+#include "kmessagebox.h" - #include "kaboutdialog.h" - #include "usermanual.h" - --- -2.46.0 - diff --git a/time-shutdown-4.0.0.0-resolve-the-issue-of-reversed-fonts-in-the-Qidian-theme.patch b/time-shutdown-4.0.0.0-resolve-the-issue-of-reversed-fonts-in-the-Qidian-theme.patch deleted file mode 100644 index 830e99bda49ae9b74eac4f274d58f7cc4d52632a..0000000000000000000000000000000000000000 --- a/time-shutdown-4.0.0.0-resolve-the-issue-of-reversed-fonts-in-the-Qidian-theme.patch +++ /dev/null @@ -1,66 +0,0 @@ -From 3beb942d97ad17ff4704ad4f0d4dc5c7cda0dd67 Mon Sep 17 00:00:00 2001 -From: huayadong -Date: Tue, 19 Nov 2024 21:02:10 +0800 -Subject: [PATCH] resolve the issue of reversed fonts in the Qidian theme - ---- - time-shutdown/dropdownmenu.cpp | 16 +++++++++++++++- - time-shutdown/dropdownmenu.h | 1 + - 2 files changed, 16 insertions(+), 1 deletion(-) - -diff --git a/time-shutdown/dropdownmenu.cpp b/time-shutdown/dropdownmenu.cpp -index 8cd8364..d4087d6 100644 ---- a/time-shutdown/dropdownmenu.cpp -+++ b/time-shutdown/dropdownmenu.cpp -@@ -62,7 +62,14 @@ MenuItem::MenuItem(QString week, int id, QWidget *parent) : QToolButton(parent), - m_darkTheme = false; - } - } -- connect(m_style, &QGSettings::changed, this, [=](const QString & key) { -+ -+ if (m_style->keys().contains("widgetThemeName")) { -+ if (m_style->get("widgetThemeName").toString() == "classical") { -+ m_classTheme = true; -+ } -+ } -+ -+ connect(m_style, &QGSettings::changed, this, [=](const QString &key) { - if (key == "styleName") { - setItemStyle(); - if (m_style->get("styleName").toString() == "ukui-dark") { -@@ -77,6 +84,10 @@ MenuItem::MenuItem(QString week, int id, QWidget *parent) : QToolButton(parent), - m_pweekLabel->setPalette(palette); - } - } -+ -+ if (key == "widgetThemeName") { -+ m_classTheme = m_style->get("widgetThemeName").toString() == "classical"; -+ } - }); - } - } -@@ -113,6 +124,9 @@ void MenuItem::mouseReleaseEvent(QMouseEvent *event) - void MenuItem::enterEvent(QEvent *e) - { - Q_UNUSED(e); -+ if (m_classTheme) { -+ return QToolButton::enterEvent(e); -+ } - QApplication::postEvent(m_pselectedLabelIcon, new QEvent(QEvent::Enter)); - - QPalette palette; -diff --git a/time-shutdown/dropdownmenu.h b/time-shutdown/dropdownmenu.h -index a9a75bc..79106de 100644 ---- a/time-shutdown/dropdownmenu.h -+++ b/time-shutdown/dropdownmenu.h -@@ -42,6 +42,7 @@ public: - QLabel *m_pselectedLabelIcon; - QHBoxLayout *m_pHWeekLayout; - bool m_darkTheme = false; -+ bool m_classTheme = false; - int m_id = 0; - - void setIconVisible(bool status); --- -2.46.0 - diff --git a/time-shutdown-4.0.0.0.tar.gz b/time-shutdown-4.0.0.0.tar.gz deleted file mode 100644 index f83b1ba2ceedfd5892b5c8bf84366438f2518ffe..0000000000000000000000000000000000000000 Binary files a/time-shutdown-4.0.0.0.tar.gz and /dev/null differ diff --git a/time-shutdown.spec b/time-shutdown.spec index 6e52732824c3a084a2ce0410d5baa9dde77bd63f..162bb4e2c3bd6a68c3f2656394e3d39283f0ffa0 100644 --- a/time-shutdown.spec +++ b/time-shutdown.spec @@ -1,14 +1,12 @@ Name: time-shutdown -Version: 4.0.0.0 -Release: 3 +Version: 4.10.0.0 +Release: 1 Summary: The time-shutdown is mainly used in the desktop operating system License: GPL-3+ URL: https://github.com/ukui/time-shutdown -Source0: %{name}-%{version}.tar.gz +Source0: time-shutdown_4.10.0.0.orig.tar.gz -Patch1: time-shutdown-4.0.0.0-resolve-the-issue-of-reversed-fonts-in-the-Qidian-theme.patch -Patch2: time-shutdown-4.0.0.0-fix-Selection-box-arrow-error.patch BuildRequires: glib2-devel BuildRequires: qt5-qtbase-devel @@ -43,8 +41,6 @@ pushd qmake-build popd %files -%doc debian/changelog -%license debian/copyright %{_sysconfdir}/xdg/autostart/time-shutdown-daemon.desktop %{_bindir}/time-shutdown %{_bindir}/time-shutdown-daemon @@ -53,6 +49,9 @@ popd %{_datadir}/ukui-time-shutdown/translations %changelog +* Tue Mar 25 2025 lvfei - 4.10.0.0-1 +- Update package to version 4.10.0.0 + * Mon Dec 9 2024 huayadong - 4.0.0.0-3 - add patch time-shutdown-4.0.0.0-fix-Selection-box-arrow-error.patch diff --git a/time-shutdown_4.10.0.0.orig.tar.gz b/time-shutdown_4.10.0.0.orig.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..3c897731683bde24eb3c32b831f8dac4d36edeb5 Binary files /dev/null and b/time-shutdown_4.10.0.0.orig.tar.gz differ