diff --git a/0005-fix-osd-sound-level.patch b/0005-fix-osd-sound-level.patch new file mode 100644 index 0000000000000000000000000000000000000000..0de3bfd24bcd3e1e5925165f58878bdcdf522c39 --- /dev/null +++ b/0005-fix-osd-sound-level.patch @@ -0,0 +1,45 @@ +From b4f22c6f73858e0e30af0b4a1f82c45b1e22cc6d Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?=E5=BC=A0=E6=B6=9B?= +Date: Thu, 19 Oct 2023 10:15:23 +0800 +Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BC=98=E5=8C=96=E7=AC=94=E8=AE=B0?= + =?UTF-8?q?=E6=9C=AC=E5=8A=9F=E8=83=BD=E9=94=AE=E6=9C=80=E5=A4=A7=E9=9F=B3?= + =?UTF-8?q?=E9=87=8F=E6=98=BE=E7=A4=BA=E4=B8=8D=E6=BB=A1=E6=A0=BC=E9=97=AE?= + =?UTF-8?q?=E9=A2=98?= +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +--- + plugins/media-keys/csd-media-keys-manager.c | 2 +- + plugins/media-keys/csd-osd-window.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/plugins/media-keys/csd-media-keys-manager.c b/plugins/media-keys/csd-media-keys-manager.c +index f1cd986..987ff51 100644 +--- a/plugins/media-keys/csd-media-keys-manager.c ++++ b/plugins/media-keys/csd-media-keys-manager.c +@@ -1569,7 +1569,7 @@ do_sound_action (CsdMediaKeysManager *manager, + else if (type == VOLUME_UP_KEY && old_vol == MAX_VOLUME && !old_muted) + osd_vol = 101; + else if (!new_muted) +- osd_vol = (int) (100 * (double) new_vol / MAX_VOLUME); ++ osd_vol = (int)round (100 * (double) new_vol / MAX_VOLUME); + else + osd_vol = 0; + update_dialog (manager, stream, osd_vol, new_muted, sound_changed, quiet, type); +diff --git a/plugins/media-keys/csd-osd-window.c b/plugins/media-keys/csd-osd-window.c +index a1aefb1..ee02712 100644 +--- a/plugins/media-keys/csd-osd-window.c ++++ b/plugins/media-keys/csd-osd-window.c +@@ -495,7 +495,7 @@ draw_volume_boxes (CsdOsdDrawContext *ctx, + + height = round (height) - 1; + width = round (width) - 1; +- x1 = round ((width - 1) * percentage); ++ x1 = round (width * percentage); + + /* bar background */ + gtk_style_context_save (ctx->style); +-- +2.30.2 + diff --git a/found-settings-daemon.spec b/found-settings-daemon.spec index 8b1b87b28370582bf93711cc9e035627c356e82d..ad96903dc597bdb6c6f9e6e147a23cd7e09f22cd 100644 --- a/found-settings-daemon.spec +++ b/found-settings-daemon.spec @@ -8,7 +8,7 @@ Name: found-settings-daemon Version: 4.0.1 -Release: 5%{?dist} +Release: 6%{?dist} Summary: The daemon sharing settings from GNOME to GTK+/KDE applications License: GPLv2+ @@ -19,6 +19,7 @@ Patch0: 0001-auto-empty-recycle-bin.patch Patch1: 0002-fix-modify-default-value.patch Patch2: 0003-fix-brightness-on-all-in-one.patch Patch3: 0004-fix-touchpad-while-typing.patch +Patch4: 0005-fix-osd-sound-level.patch BuildRequires: meson >= 0.44.0 BuildRequires: gcc @@ -191,6 +192,10 @@ ln -s /usr/libexec/found-settings-daemon/cdos-settings-daemon /usr/bin/cdos-sett %{_libdir}/pkgconfig/found-settings-daemon.pc %changelog +* Thu Oct 19 2023 张涛 - 4.0.1-6 +- fix: 优化笔记本功能键最大音量显示不满格问题 +- add patch: 0005-fix-osd-sound-level.patch + * Thu Oct 19 2023 张涛 - 4.0.1-5 - fix: 触摸板开启防误触功能不生效 - add patch: 0004-fix-touchpad-while-typing.patch