fix(keybinding):Add support desktop extend key for GC

-添加GC支持的桌面扩展快捷键

  Related #67098
This commit is contained in:
meizhigang 2023-05-30 10:16:41 +08:00
parent 57b94bbbf9
commit 62a6c0ffca
2 changed files with 78 additions and 1 deletions

View File

@ -0,0 +1,67 @@
From aaaa7ec4ffcafbce965c0b234ba281bd8c003e1a Mon Sep 17 00:00:00 2001
From: meizhigang <meizhigang@kylinsec.com.cn>
Date: Sat, 27 May 2023 19:51:46 +0800
Subject: [PATCH] fix(keybinding):Add support desktop key for GC
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
-添加GC支持的桌面扩展快捷键
Related #67098
---
cmake/ksd_variables.cmake | 4 ++++
data/CMakeLists.txt | 6 ++++++
data/keybindings/01-desktop-extend-key.xml | 8 ++++++++
3 files changed, 18 insertions(+)
create mode 100644 data/keybindings/01-desktop-extend-key.xml
diff --git a/cmake/ksd_variables.cmake b/cmake/ksd_variables.cmake
index 3ea177b..46e3b7c 100644
--- a/cmake/ksd_variables.cmake
+++ b/cmake/ksd_variables.cmake
@@ -59,6 +59,10 @@ set(enable-plugin-clipboard
"false"
CACHE STRING "Enable plugin clipboard")
+set(filter-desktop-extend-key
+ "true"
+ CACHE STRING "Filter desktop extend key")
+
# Determine the platform.
if("${CMAKE_SYSTEM_NAME}" STREQUAL "Darwin")
set(OS_MACOSX 1)
diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt
index cf469fb..006d1b0 100644
--- a/data/CMakeLists.txt
+++ b/data/CMakeLists.txt
@@ -127,6 +127,12 @@ if(build-session-daemon)
# keybindings
file(GLOB KEYBINDINGS_XML_FILES ${PROJECT_SOURCE_DIR}/data/keybindings/*.xml)
+
+ if(filter-desktop-extend-key)
+ list(REMOVE_ITEM KEYBINDINGS_XML_FILES
+ ${PROJECT_SOURCE_DIR}/data/keybindings/01-desktop-extend-key.xml)
+ endif()
+
install(
FILES ${KEYBINDINGS_XML_FILES}
DESTINATION ${CMAKE_INSTALL_FULL_DATADIR}/${PROJECT_NAME}/keybindings/)
diff --git a/data/keybindings/01-desktop-extend-key.xml b/data/keybindings/01-desktop-extend-key.xml
new file mode 100644
index 0000000..e9b8d13
--- /dev/null
+++ b/data/keybindings/01-desktop-extend-key.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<KeyListEntries schema="org.mate.SettingsDaemon.plugins.media-keys" package="mate-settings-daemon" name="Desktop">
+
+ <KeyListEntry name="panel-kiran-menu" description="Show the panel's main menu of kiran"/>
+
+ <KeyListEntry name="show-desktop" description="Show the desktop"/>
+
+</KeyListEntries>
--
2.27.0

View File

@ -1,6 +1,6 @@
Name: kiran-cc-daemon
Version: 2.5.1
Release: 9
Release: 10
Summary: DBus daemon for Kiran Desktop
License: MulanPSL-2.0
@ -12,6 +12,7 @@ Patch0003: 0001-fix-audio-Fix-the-type-of-return-value-in-template.patch
Patch0004: 0001-feature-timedate-Prior-to-select-last-ntp-service-in.patch
Patch0005: 0001-feature-power-Delete-LockScreenWhenHibernate-and-Loc.patch
Patch0006: 0001-fix-identification-issues-in-control-centers.patch
Patch0007: 0001-fix-keybinding-Add-support-desktop-key-for-GC.patch
BuildRequires: cmake >= 3.2
@ -100,7 +101,13 @@ Development files for communicating with control center daemon
%autosetup -p1
%build
%if "%{ks_custom_name}" == "GC"
%cmake -Dfilter-desktop-extend-key=false
%else
%cmake
%endif
make %{?_smp_mflags}
%install
@ -176,6 +183,9 @@ glib-compile-schemas /usr/share/glib-2.0/schemas &> /dev/nulls || :
%{_libdir}/pkgconfig/kiran-cc-daemon.pc
%changelog
* Tue May 30 2023 meizhigang <meizhigang@kylinsec.com.cn> - 2.5.1-10
- KYOS-F: Add support desktop extend key for GC
* Thu May 11 2023 wangtaozhi <wangtaozhi@kylinsec.com.cn> - 2.5.1-9
- KYOS-F: Fix identification issues in the control center