diff --git a/0001-fix-display-Fix-the-problem-that-all-monitors-doesn-.patch b/0001-fix-display-Fix-the-problem-that-all-monitors-doesn-.patch new file mode 100644 index 0000000000000000000000000000000000000000..b5508adfa9c052ea3d139a7a4b2d5e04bf96dd6a --- /dev/null +++ b/0001-fix-display-Fix-the-problem-that-all-monitors-doesn-.patch @@ -0,0 +1,37 @@ +From 77032b5c643437c286f13ecb4fcc4ff9c9419b9d Mon Sep 17 00:00:00 2001 +From: tangjie02 +Date: Wed, 17 Aug 2022 20:26:02 +0800 +Subject: [PATCH] fix(display): Fix the problem that all monitors doesn't + display because the saved enable field of all monitors is set off. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +- 修复由于保存的显示器状态全部为关闭导致显示器不显示的问题 + +Signed-off-by: tangjie02 +--- + plugins/display/display-manager.cpp | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/plugins/display/display-manager.cpp b/plugins/display/display-manager.cpp +index 5c7c5b3..bc18eb9 100644 +--- a/plugins/display/display-manager.cpp ++++ b/plugins/display/display-manager.cpp +@@ -499,6 +499,13 @@ bool DisplayManager::save_config(CCErrorCode &error_code) + this->display_config_ = std::unique_ptr(new DisplayConfigInfo()); + } + ++ // 禁止保存没有开启任何显示器的配置,这可能会导致下次进入会话屏幕无法显示 ++ if (this->get_enabled_monitors().size() == 0) ++ { ++ error_code = CCErrorCode::ERROR_DISPLAY_ONLY_ONE_ENABLED_MONITOR; ++ return false; ++ } ++ + auto monitors_uid = this->get_monitors_uid(); + auto &c_screens = this->display_config_->screen(); + bool matched = false; +-- +2.33.0 + diff --git a/kiran-cc-daemon.spec b/kiran-cc-daemon.spec index 96132f2d637499c13f874b29a98e5330d8732f85..14ef578260e542f95d20cb484e7f889df4562a61 100644 --- a/kiran-cc-daemon.spec +++ b/kiran-cc-daemon.spec @@ -1,6 +1,6 @@ Name: kiran-cc-daemon Version: 2.3.1 -Release: 4 +Release: 5 Summary: DBus daemon for Kiran Desktop License: MulanPSL-2.0 @@ -9,6 +9,7 @@ Source0: %{name}-%{version}.tar.gz Patch0001: 0001-fix-coredump-Fix-coredump-problem-caused-by-nullpoin.patch Patch0002: 0001-fix-hidpi-Fixed-QT-font-DPI-to-avoid-double-scaling.patch Patch0003: 0001-feature-display-The-scaling-rate-can-only-take-effec.patch +patch0004: 0001-fix-display-Fix-the-problem-that-all-monitors-doesn-.patch BuildRequires: cmake >= 3.2 @@ -148,6 +149,9 @@ glib-compile-schemas /usr/share/glib-2.0/schemas &> /dev/nulls || : %{_libdir}/pkgconfig/kiran-cc-daemon.pc %changelog +* Wed Aug 17 2022 tangjie02 - 2.3.1-5 +- KYOS-B: Fix the problem that all monitors doesn't display because the saved enable field of all monitors is set off. + * Tue Aug 16 2022 tangjie02 - 2.3.1-4 - KYOS-F: The scaling rate can only take effect after logging out and logging in again.