Compare commits
10 Commits
d4ec55545e
...
8329627ebf
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8329627ebf | ||
|
|
98aa26b101 | ||
|
|
bc7b2a0a5b | ||
|
|
86172bf3d3 | ||
|
|
125abe975a | ||
|
|
a55e04f587 | ||
|
|
c64020572b | ||
|
|
532a724114 | ||
|
|
5219930bc3 | ||
|
|
6d7e1a5292 |
105
0001-fix-the-problem-that-the-app-version-not-set.patch
Normal file
105
0001-fix-the-problem-that-the-app-version-not-set.patch
Normal file
@ -0,0 +1,105 @@
|
|||||||
|
From cca34e2f88f6a2c2af752a39f665ce9fdc776464 Mon Sep 17 00:00:00 2001
|
||||||
|
From: =?UTF-8?q?=E4=BE=AF=E7=BA=A2=E5=8B=8B?= <houhongxun@kylinos.cn>
|
||||||
|
Date: Tue, 28 May 2024 14:47:33 +0800
|
||||||
|
Subject: [PATCH] fix the problem that the app version not set
|
||||||
|
MIME-Version: 1.0
|
||||||
|
Content-Type: text/plain; charset=UTF-8
|
||||||
|
Content-Transfer-Encoding: 8bit
|
||||||
|
|
||||||
|
Signed-off-by: 侯红勋 <houhongxun@kylinos.cn>
|
||||||
|
---
|
||||||
|
src/ukui-screensaver-command.cpp | 22 ++++++++++++++++++++++
|
||||||
|
src/ukui-screensaver-dialog.cpp | 21 +++++++++++++++++++++
|
||||||
|
2 files changed, 43 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/src/ukui-screensaver-command.cpp b/src/ukui-screensaver-command.cpp
|
||||||
|
index 1ce2d54..97f1eb7 100644
|
||||||
|
--- a/src/ukui-screensaver-command.cpp
|
||||||
|
+++ b/src/ukui-screensaver-command.cpp
|
||||||
|
@@ -22,15 +22,37 @@
|
||||||
|
#include <QTranslator>
|
||||||
|
#include <QCommandLineParser>
|
||||||
|
#include <QDebug>
|
||||||
|
+#include <QProcess>
|
||||||
|
+#include <QRegularExpression>
|
||||||
|
#include "types.h"
|
||||||
|
#include <ukui-log4qt.h>
|
||||||
|
|
||||||
|
#define WORKING_DIRECTORY "/usr/share/ukui-screensaver"
|
||||||
|
|
||||||
|
+static QString getVersion()
|
||||||
|
+{
|
||||||
|
+ QProcess v_p;
|
||||||
|
+ v_p.start("rpm", QStringList() << "-q" << "ukui-screensaver");
|
||||||
|
+
|
||||||
|
+ if (!v_p.waitForFinished())
|
||||||
|
+ return "none";
|
||||||
|
+
|
||||||
|
+ QByteArray ba = v_p.readAllStandardOutput();
|
||||||
|
+
|
||||||
|
+ QRegularExpression qe("-([^-]+)-[^-]+\n$");
|
||||||
|
+
|
||||||
|
+ QRegularExpressionMatch qem = qe.match(ba);
|
||||||
|
+ if (qem.hasMatch()) {
|
||||||
|
+ return qem.captured(1);
|
||||||
|
+ }
|
||||||
|
+ return "none";
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
int main(int argc, char **argv)
|
||||||
|
{
|
||||||
|
initUkuiLog4qt("ukui-screensaver-command");
|
||||||
|
QCoreApplication a(argc, argv);
|
||||||
|
+ a.setApplicationVersion(getVersion());
|
||||||
|
|
||||||
|
QString locale = QLocale::system().name();
|
||||||
|
QTranslator translator;
|
||||||
|
diff --git a/src/ukui-screensaver-dialog.cpp b/src/ukui-screensaver-dialog.cpp
|
||||||
|
index e05cd00..3ea7bad 100644
|
||||||
|
--- a/src/ukui-screensaver-dialog.cpp
|
||||||
|
+++ b/src/ukui-screensaver-dialog.cpp
|
||||||
|
@@ -28,6 +28,7 @@
|
||||||
|
#include <QDebug>
|
||||||
|
#include <QDesktopWidget>
|
||||||
|
#include <QDBusInterface>
|
||||||
|
+#include <QRegularExpression>
|
||||||
|
#include <signal.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <fcntl.h>
|
||||||
|
@@ -125,6 +126,25 @@ void handler(int signum)
|
||||||
|
window->closeScreensaver();
|
||||||
|
}
|
||||||
|
|
||||||
|
+static QString getVersion()
|
||||||
|
+{
|
||||||
|
+ QProcess v_p;
|
||||||
|
+ v_p.start("rpm", QStringList() << "-q" << "ukui-screensaver");
|
||||||
|
+
|
||||||
|
+ if (!v_p.waitForFinished())
|
||||||
|
+ return "none";
|
||||||
|
+
|
||||||
|
+ QByteArray ba = v_p.readAllStandardOutput();
|
||||||
|
+
|
||||||
|
+ QRegularExpression qe("-([^-]+)-[^-]+\n$");
|
||||||
|
+
|
||||||
|
+ QRegularExpressionMatch qem = qe.match(ba);
|
||||||
|
+ if (qem.hasMatch()) {
|
||||||
|
+ return qem.captured(1);
|
||||||
|
+ }
|
||||||
|
+ return "none";
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
#define WORKING_DIRECTORY "/usr/share/ukui-screensaver"
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
@@ -169,6 +189,7 @@ int main(int argc, char *argv[])
|
||||||
|
//signal(SIGTERM,handler);
|
||||||
|
QApplication a(argc, argv);
|
||||||
|
QApplication::setSetuidAllowed(true);
|
||||||
|
+ a.setApplicationVersion(getVersion());
|
||||||
|
|
||||||
|
QDesktopWidget *desktop = QApplication::desktop();
|
||||||
|
if(desktop->geometry().width()<=0 || desktop->geometry().height()<=0)
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
24
0002-fix-build-compile-error.patch
Normal file
24
0002-fix-build-compile-error.patch
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
From 6f41615756a3793420918265fba01148eab4b42b Mon Sep 17 00:00:00 2001
|
||||||
|
From: tanyulong2021 <tanyulong@kylinos.cn>
|
||||||
|
Date: Fri, 10 Feb 2023 09:56:04 +0800
|
||||||
|
Subject: [PATCH] fix build compile error
|
||||||
|
|
||||||
|
---
|
||||||
|
BiometricAuth/giodbus.cpp | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/BiometricAuth/giodbus.cpp b/BiometricAuth/giodbus.cpp
|
||||||
|
index 9e0490e..4ad8d27 100644
|
||||||
|
--- a/BiometricAuth/giodbus.cpp
|
||||||
|
+++ b/BiometricAuth/giodbus.cpp
|
||||||
|
@@ -1,6 +1,6 @@
|
||||||
|
#include "giodbus.h"
|
||||||
|
#include <gio/gio.h>
|
||||||
|
-#include <gio-unix-2.0/gio/gunixfdlist.h>
|
||||||
|
+#include <glib-2.0/gio/gunixfdlist.h>
|
||||||
|
#include <glib.h>
|
||||||
|
|
||||||
|
int get_server_gvariant_stdout (int drvid)
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
26
add-switchuser-no-limits-in-ukui-screensaver.patch
Normal file
26
add-switchuser-no-limits-in-ukui-screensaver.patch
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
From ad431e316a1905b17509cc8f69040380e3fde9cb Mon Sep 17 00:00:00 2001
|
||||||
|
From: peijiankang <peijiankang@kylinos.cn>
|
||||||
|
Date: Mon, 4 Sep 2023 20:45:12 +0800
|
||||||
|
Subject: [PATCH] add switchuser no limits in ukui-screensaver
|
||||||
|
|
||||||
|
---
|
||||||
|
src/lockwidget.cpp | 3 ---
|
||||||
|
1 file changed, 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/lockwidget.cpp b/src/lockwidget.cpp
|
||||||
|
index ac11367..2e9a415 100644
|
||||||
|
--- a/src/lockwidget.cpp
|
||||||
|
+++ b/src/lockwidget.cpp
|
||||||
|
@@ -81,9 +81,6 @@ LockWidget::LockWidget(QWidget *parent)
|
||||||
|
this->installEventFilter(this);
|
||||||
|
initUI();
|
||||||
|
|
||||||
|
- if(users->getUsers().count() < 2){
|
||||||
|
- ui->btnSwitchUser->hide();
|
||||||
|
- }
|
||||||
|
}
|
||||||
|
|
||||||
|
LockWidget::~LockWidget()
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
36
disable-Suspend-and-Sleep-of-ukui-screensaver.patch
Normal file
36
disable-Suspend-and-Sleep-of-ukui-screensaver.patch
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
From b38417c0327894a8165a9ea7eda7db4cbf01531a Mon Sep 17 00:00:00 2001
|
||||||
|
From: peijiankang <peijiankang@kylinos.cn>
|
||||||
|
Date: Wed, 14 Jun 2023 15:55:43 +0800
|
||||||
|
Subject: [PATCH] disable Suspend and Sleep of ukui-screensaver
|
||||||
|
|
||||||
|
---
|
||||||
|
src/powermanager.cpp | 6 ++++--
|
||||||
|
1 file changed, 4 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/powermanager.cpp b/src/powermanager.cpp
|
||||||
|
index 5b3a23f..e854112 100644
|
||||||
|
--- a/src/powermanager.cpp
|
||||||
|
+++ b/src/powermanager.cpp
|
||||||
|
@@ -59,7 +59,7 @@ PowerManager::PowerManager(QWidget *parent)
|
||||||
|
"org.gnome.SessionManager",
|
||||||
|
QDBusConnection::sessionBus(),
|
||||||
|
this);
|
||||||
|
-
|
||||||
|
+/*
|
||||||
|
loginInterface = new QDBusInterface(login1Service,
|
||||||
|
login1Path,
|
||||||
|
login1ManagerInterface,
|
||||||
|
@@ -79,7 +79,9 @@ PowerManager::PowerManager(QWidget *parent)
|
||||||
|
}else{
|
||||||
|
canHibernate = false;
|
||||||
|
}
|
||||||
|
-
|
||||||
|
+*/
|
||||||
|
+ canSuspend = false;
|
||||||
|
+ canHibernate = false;
|
||||||
|
initUI();
|
||||||
|
resize((ITEM_WIDTH+ITEM_SPACING*2)*this->count()-ITEM_SPACING*2, ITEM_HEIGHT+ITEM_SPACING*2);
|
||||||
|
//setCurrentRow(0);
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
Binary file not shown.
BIN
ukui-screensaver-3.1.1.tar.gz
Normal file
BIN
ukui-screensaver-3.1.1.tar.gz
Normal file
Binary file not shown.
@ -1,47 +1,59 @@
|
|||||||
Name: ukui-screensaver
|
Name: ukui-screensaver
|
||||||
Version: 3.0.3
|
Version: 3.1.1
|
||||||
Release: 2
|
Release: 7
|
||||||
Summary: parallels toolbox for UKUI
|
Summary: Screensaver for UKUI desktop environment
|
||||||
License: GPL-3+ GPL-2+
|
License: GPL-3+ and GPL-2+
|
||||||
URL: http://www.ukui.org
|
URL: http://www.ukui.org
|
||||||
Source0: %{name}-%{version}.tar.gz
|
Source0: %{name}-%{version}.tar.gz
|
||||||
Patch01: 0001-fix-root-can-not-input-passwd-bug.patch
|
Patch01: 0001-fix-root-can-not-input-passwd-bug.patch
|
||||||
BuildRequires: glib2-devel
|
Patch02: 0002-fix-build-compile-error.patch
|
||||||
BuildRequires: qt5-qtbase-devel
|
%if 0%{?kylin}
|
||||||
BuildRequires: qt5-qtsvg-devel
|
Patch03: disable-Suspend-and-Sleep-of-ukui-screensaver.patch
|
||||||
BuildRequires: qt5-qtmultimedia-devel
|
Patch04: add-switchuser-no-limits-in-ukui-screensaver.patch
|
||||||
BuildRequires: qt5-qttools-devel
|
%endif
|
||||||
BuildRequires: gsettings-qt-devel
|
Patch05: 0001-fix-the-problem-that-the-app-version-not-set.patch
|
||||||
BuildRequires: dconf-devel
|
|
||||||
BuildRequires: libXtst-devel
|
|
||||||
BuildRequires: cmake
|
BuildRequires: cmake
|
||||||
|
BuildRequires: qt5-qtbase-devel
|
||||||
BuildRequires: qt5-qtx11extras-devel
|
BuildRequires: qt5-qtx11extras-devel
|
||||||
BuildRequires: pam-devel
|
BuildRequires: pam-devel
|
||||||
|
BuildRequires: qt5-qttools-devel
|
||||||
|
BuildRequires: glib2-devel
|
||||||
BuildRequires: opencv
|
BuildRequires: opencv
|
||||||
|
BuildRequires: libX11-devel
|
||||||
|
BuildRequires: libXtst-devel
|
||||||
|
BuildRequires: qt5-qtsvg-devel
|
||||||
|
BuildRequires: gsettings-qt-devel
|
||||||
BuildRequires: kf5-kwindowsystem-devel
|
BuildRequires: kf5-kwindowsystem-devel
|
||||||
BuildRequires: libmatemixer-devel
|
BuildRequires: libmatemixer-devel
|
||||||
|
BuildRequires: ukui-interface
|
||||||
|
|
||||||
|
|
||||||
|
Requires: ukui-session-manager
|
||||||
Requires: glib2-devel
|
Requires: glib2-devel
|
||||||
Requires: qt5-qtbase-devel
|
Requires: ethtool
|
||||||
Requires: qt5-qtsvg-devel
|
Requires: mate-common
|
||||||
Requires: qt5-qtmultimedia-devel
|
|
||||||
Requires: qt5-qttools-devel
|
|
||||||
Requires: gsettings-qt-devel
|
|
||||||
Requires: dconf-devel
|
|
||||||
|
|
||||||
%description
|
%description
|
||||||
The ukui-sidebar is mainly used in the desktop operating system.
|
A simple and lightweight screensaver written by Qt5.
|
||||||
It pops up from the right side of the desktop in the form of a tray,
|
The screensaver supports biometric auhentication which is
|
||||||
displaying some application notification messages and some cutting
|
provided by biometric-auth service.
|
||||||
storage information.
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch1 -p1
|
%patch01 -p1
|
||||||
|
if [ -e "/usr/include/glib-2.0/gio/gunixfdlist.h" ]; then
|
||||||
|
%patch02 -p1
|
||||||
|
fi
|
||||||
|
%if 0%{?kylin}
|
||||||
|
%patch03 -p1
|
||||||
|
%patch04 -p1
|
||||||
|
%endif
|
||||||
|
%patch05 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
cmake .
|
cmake .
|
||||||
make
|
%{make_build}
|
||||||
|
|
||||||
%install
|
%install
|
||||||
rm -rf $RPM_BUILD_ROOT
|
rm -rf $RPM_BUILD_ROOT
|
||||||
@ -50,6 +62,11 @@ make install DESTDIR=%{buildroot}
|
|||||||
%clean
|
%clean
|
||||||
rm -rf $RPM_BUILD_ROOT
|
rm -rf $RPM_BUILD_ROOT
|
||||||
|
|
||||||
|
%post
|
||||||
|
set -e
|
||||||
|
glib-compile-schemas /usr/share/glib-2.0/schemas/ &> /dev/null ||:
|
||||||
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%doc debian/copyright debian/changelog
|
%doc debian/copyright debian/changelog
|
||||||
%{_bindir}/ukui-screensaver-dialog
|
%{_bindir}/ukui-screensaver-dialog
|
||||||
@ -65,15 +82,52 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
%{_sysconfdir}/pam.d/ukui-screensaver-qt
|
%{_sysconfdir}/pam.d/ukui-screensaver-qt
|
||||||
%{_prefix}/lib/ukui-screensaver/ukui-screensaver-default
|
%{_prefix}/lib/ukui-screensaver/ukui-screensaver-default
|
||||||
%{_prefix}/lib/ukui-screensaver/screensaver-focus-helper
|
%{_prefix}/lib/ukui-screensaver/screensaver-focus-helper
|
||||||
#%%{_datadir}/ukui-screensaver/screensaver.ini
|
|
||||||
#%%{_datadir}/ukui-screensaver/screensaver-en.ini
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Wed Mar 2 2022 pei-jiankang <peijiankang@kylinos.cn> - 3.0.3-2
|
* Tue May 28 2024 houhongxun <houhongxun@kylinos.cn> - 3.1.1-7
|
||||||
|
- Type:bugfix
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:add patch5:0001-fix-the-problem-that-the-app-version-not-set.patch
|
||||||
|
|
||||||
|
* Mon Sep 04 2023 peijiankang <peijiankang@kylinos.cn> - 3.1.1-6
|
||||||
|
- Type:bugfix
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:add patch3:add-switchuser-no-limits-in-ukui-screensaver.patch
|
||||||
|
|
||||||
|
* Wed Jun 14 2023 peijiankang <peijiankang@kylinos.cn> - 3.1.1-5
|
||||||
|
- Type:bugfix
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC: disable Suspend and Sleep of ukui-screensaver
|
||||||
|
|
||||||
|
* Thu May 25 2023 peijiankang <peijiankang@kylinos.cn> - 3.1.1-4
|
||||||
|
- update glib2 error
|
||||||
|
|
||||||
|
* Fri Feb 10 2023 tanyulong <tanyulong@kylinos.cn> - 3.1.1-3
|
||||||
|
- fix build compile error
|
||||||
|
|
||||||
|
* Fri Dec 9 2022 peijiankang <peijiankang@kylinos.cn> - 3.1.1-2
|
||||||
- fix root can not input passwd bug
|
- fix root can not input passwd bug
|
||||||
|
|
||||||
* Wed Feb 23 2022 douyan <douyan@kylinos.cn> - 3.0.3-1
|
* Tue Dec 6 2022 peijiankang <peijiankang@kylinos.cn> - 3.1.1-1
|
||||||
- update to upstream version 3.0.3-1
|
- update version to 3.1.1
|
||||||
|
|
||||||
|
* Mon Aug 08 2022 tanyulong<tanyulong@kylinos.cn> - 3.0.1-22
|
||||||
|
- modify username size
|
||||||
|
|
||||||
|
* Thu Aug 04 2022 tanyulong<tanyulong@kylinos.cn> - 3.0.1-21
|
||||||
|
- add and use attribute of UseHighDpiPixmaps
|
||||||
|
|
||||||
|
* Fri May 20 2022 tanyulong<tanyulong@kylinos.cn> - 3.0.1-20
|
||||||
|
- Improve the project according to the requirements of compliance improvement
|
||||||
|
|
||||||
|
* Sat Apr 02 2022 tanyulong <tanyulong@kylinos.cn> - 3.0.1-19
|
||||||
|
- add yaml file
|
||||||
|
|
||||||
|
* Mon Mar 28 2022 huayadong <huayadong@kylinos.cn> - 3.0.1-18
|
||||||
|
- Before adding the lock screen, determine whether the lock screen has been activated, and prevent the login password box from being input when multiple lock screens are activated.
|
||||||
|
|
||||||
* Fri Dec 10 2021 huayadong <huayadong@kylinos.cn> - 3.0.1-17
|
* Fri Dec 10 2021 huayadong <huayadong@kylinos.cn> - 3.0.1-17
|
||||||
- add patch15: 0001-insert-the-monitor-after-placement-and-the-screensav.patch
|
- add patch15: 0001-insert-the-monitor-after-placement-and-the-screensav.patch
|
||||||
|
|||||||
4
ukui-screensaver.yaml
Normal file
4
ukui-screensaver.yaml
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
version_control: github
|
||||||
|
src_repo: UKUI/ukui-screensaver
|
||||||
|
tag_prefix: "^v"
|
||||||
|
separator: "."
|
||||||
Loading…
x
Reference in New Issue
Block a user