linuxmint / cinnamon-spices-applets

Applets for the Cinnamon desktop
http://cinnamon-spices.linuxmint.com
GNU General Public License v2.0
606 stars 509 forks source link

Volume increment percentage in Sound150 not working properly #5353

Closed mildly-useful closed 9 months ago

mildly-useful commented 9 months ago

Applet version/Build date

Version 4.6.0 (2023-12-25 12:27:12)

Cinnamon version

5.8.4, theme Mint-Y-Dark-Aqua

Distribution

Mint 21.2 kernel 6.2.0-39-generic

Graphics hardware and driver used

Nvidia GTX 1050 (2GB), Driver version 535.129.03 (Proprietary)

Applet name and maintainer

sound150@claudiux @claudiux

What happened?

The feature that lets you change the volume increment percentage only works if I hover my mouse over sound150 in the panel tray, and use the scroll wheel to alter the volume. OSD information is also displayed correctly. However, the Volume Up and Volume Down shortcuts from the Keyboard > Shortcuts menu in Mint, in the Sound and Media section, do not alter the volume by the percentage I set. It's always the default 5%. For reference, I bound those volume shortcut keys to CTRL + PGUP and CTRL + PGDN, not that I think it would matter.

Other information

My enabled applets (on two panels): Applauncher, Color Picker, Pomodoro Timer, Simple Memory Monitor, Sound 150, Weather, Calendar, Corner Bar, Keyboard, Menu, Network Manager, Notifications, Panel Launchers, Power Manager, Separator, System Tray, Window List, Windows Quick List, Workspace Switcher, Xapp Status applet. I also disabled the system Sound in order to use Sound150 exclusively.

Another random note: after disabling "Sound" from the panel, and putting "Sound150" in its place, I have to clear and rebind the Volume Up and Volume Down shortcuts in order for those specific shortcuts to work at all. I only have to do this once, after enabling Sound150 and disabling Sound. But, the fact that the increment percentage isn't working correctly is still the main problem.

A screenshort of my Sound150 settings: Screenshot from 2024-01-02 22-40-20

claudiux commented 9 months ago

@mildly-useful I don't understand what's causing this problem. I'll make a PR, please test it when it's ready.

claudiux commented 9 months ago

@mildly-useful Please test these changes: #5354 particularly the lines 1223-1226:

        Main.keybindingManager.removeHotKey("raise-volume");
        Main.keybindingManager.removeHotKey("lower-volume");
        Main.keybindingManager.removeHotKey("volume-up");
        Main.keybindingManager.removeHotKey("volume-down");
mildly-useful commented 9 months ago

Thanks for the response! I am still a Linux newbie, so I don't know 100% what I'm doing, but I did this. I disabled Sound and Sound150, then I removed the original applet.js from "/home/username/.local/share/cinnamon/applets/sound150@claudiux/5.4" and replaced it with the one from this location, which I assume it's the file with your new changes:

https://github.com/linuxmint/cinnamon-spices-applets/blob/35b611d0aac24ef9c485ac72db2f1261f3bcf248/sound150%40claudiux/files/sound150%40claudiux/5.4/applet.js

Then I enabled Sound150 again. It still makes no difference though. And I still have to rebind the Volume Up and Volume down keys in order for them to work at all (even if the binds are still there). I wonder, what could make this not work properly on my system?

I also just tested it on a live USB (Mint 21.2 Edge Cinnamon). Same thing, it also doesn't work there. So, apparently, it's not related to something I have installed on my system. Is it my hardware? I will post my System Info bellow, as well as an image showing my keyboard shortcuts related to the volume.

Screenshot from 2024-01-03 13-37-05

System: Kernel: 6.2.0-39-generic x86_64 bits: 64 compiler: N/A Desktop: Cinnamon 5.8.4 tk: GTK 3.24.33 wm: muffin dm: LightDM Distro: Linux Mint 21.2 Victoria base: Ubuntu 22.04 jammy Machine: Type: Desktop System: bluechip AG product: N/A v: N/A serial: Mobo: ASUSTeK model: P8B75-M v: Rev X.0x serial: UEFI: American Megatrends v: 1701 date: 08/06/2014 CPU: Info: quad core model: Intel Core i5-3570 bits: 64 type: MCP arch: Ivy Bridge rev: 9 cache: L1: 256 KiB L2: 1024 KiB L3: 6 MiB Speed (MHz): avg: 3715 high: 3798 min/max: 1600/3800 cores: 1: 3729 2: 3798 3: 3611 4: 3723 bogomips: 27200 Flags: avx ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx Graphics: Device-1: NVIDIA GP107 [GeForce GTX 1050] vendor: Hewlett-Packard driver: nvidia v: 535.129.03 pcie: speed: 2.5 GT/s lanes: 16 ports: active: none off: DVI-D-1 empty: DP-1,HDMI-A-1 bus-ID: 01:00.0 chip-ID: 10de:1c81 Display: x11 server: X.Org v: 1.21.1.4 driver: X: loaded: nvidia unloaded: fbdev,modesetting,nouveau,vesa gpu: nvidia display-ID: :0 screens: 1 Screen-1: 0 s-res: 1920x1080 s-dpi: 92 Monitor-1: DVI-D-0 res: 1920x1080 dpi: 92 diag: 609mm (24") OpenGL: renderer: NVIDIA GeForce GTX 1050/PCIe/SSE2 v: 4.6.0 NVIDIA 535.129.03 direct render: Yes Audio: Device-1: Intel 7 Series/C216 Family High Definition Audio vendor: ASUSTeK P8H77-I driver: snd_hda_intel v: kernel bus-ID: 00:1b.0 chip-ID: 8086:1e20 Device-2: NVIDIA GP107GL High Definition Audio vendor: Hewlett-Packard driver: snd_hda_intel v: kernel pcie: speed: 8 GT/s lanes: 16 bus-ID: 01:00.1 chip-ID: 10de:0fb9 Sound Server-1: ALSA v: k6.2.0-39-generic running: yes Sound Server-2: PulseAudio v: 15.99.1 running: yes Sound Server-3: PipeWire v: 0.3.48 running: yes Network: Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet vendor: ASUSTeK P8 series driver: r8169 v: kernel pcie: speed: 2.5 GT/s lanes: 1 port: d000 bus-ID: 03:00.0 chip-ID: 10ec:8168 IF: enp3s0 state: up speed: 1000 Mbps duplex: full mac: Drives: Local Storage: total: 10.12 TiB used: 9.65 TiB (95.4%) ID-1: /dev/sda vendor: Kingston model: SV300S37A120G size: 111.79 GiB speed: 6.0 Gb/s serial: ID-2: /dev/sdb vendor: Western Digital model: WD10EZEX-08M2NA0 size: 931.51 GiB speed: 3.0 Gb/s serial: ID-3: /dev/sdc vendor: Western Digital model: WD60EZRZ-00RWYB1 size: 5.46 TiB speed: 3.0 Gb/s serial: ID-4: /dev/sdd vendor: Western Digital model: WD10EZEX-00ZF5A0 size: 931.51 GiB speed: 3.0 Gb/s serial: ID-5: /dev/sde type: USB vendor: Western Digital model: WD30EZRX-11SPEB0 size: 2.73 TiB serial: Partition: ID-1: / size: 108.98 GiB used: 76.09 GiB (69.8%) fs: ext4 dev: /dev/sda3 ID-2: /boot/efi size: 512 MiB used: 6.1 MiB (1.2%) fs: vfat dev: /dev/sda2 Swap: ID-1: swap-1 type: file size: 6 GiB used: 0 KiB (0.0%) priority: -2 file: /swapfile USB: Hub-1: 1-0:1 info: Full speed or root hub ports: 2 rev: 2.0 speed: 480 Mb/s chip-ID: 1d6b:0002 Hub-2: 1-1:2 info: Intel Integrated Rate Matching Hub ports: 6 rev: 2.0 speed: 480 Mb/s chip-ID: 8087:0024 Device-1: 1-1.1:3 info: SINOWEALTH Game Mouse type: Mouse,Keyboard driver: hid-generic,usbhid rev: 1.1 speed: 12 Mb/s chip-ID: 258a:1007 Device-2: 1-1.2:4 info: China Resource Semico Keyboard type: Keyboard,HID driver: hid-generic,usbhid rev: 1.1 speed: 1.5 Mb/s chip-ID: 1a2c:2d23 Device-3: 1-1.3:5 info: Logitech F710 Wireless Gamepad [XInput Mode] type: driver: xpad rev: 2.0 speed: 12 Mb/s chip-ID: 046d:c21f Hub-3: 2-0:1 info: Full speed or root hub ports: 2 rev: 2.0 speed: 480 Mb/s chip-ID: 1d6b:0002 Hub-4: 2-1:2 info: Intel Integrated Rate Matching Hub ports: 6 rev: 2.0 speed: 480 Mb/s chip-ID: 8087:0024 Hub-5: 3-0:1 info: Hi-speed hub with single TT ports: 4 rev: 2.0 speed: 480 Mb/s chip-ID: 1d6b:0002 Hub-6: 4-0:1 info: Super-speed hub ports: 4 rev: 3.0 speed: 5 Gb/s chip-ID: 1d6b:0003 Device-1: 4-2:2 info: Western Digital My Book (WDBFJK) type: Mass Storage driver: usb-storage rev: 3.0 speed: 5 Gb/s chip-ID: 1058:1230 Sensors: System Temperatures: cpu: 36.5 C mobo: 36.0 C gpu: nvidia temp: 40 C Fan Speeds (RPM): cpu: 831 fan-1: 1260 fan-3: 1327 gpu: nvidia fan: 28% Power: 12v: N/A 5v: N/A 3.3v: 3.36 vbat: 3.38

claudiux commented 9 months ago

@mildly-useful #5354 Please try new version of applet.js and settings-schema.json files, in 5.4 folder. Restart Cinnamon then modify keybindings at the bottom of this applet settings. Maybe remove your shortcuts defined in Cinnamon settings. Please tell me if that solves your problem.

claudiux commented 9 months ago

@mildly-useful Any news?

mildly-useful commented 9 months ago

Yes, with the two new files, it now works properly. It increments by how much I set it and the OSD information is also displayed. I had to remove the bindings from the Cinnamon shortcuts though. Only with the shortcuts set from the applet it works properly. Thanks so much for the new update! Should I close this issue?

claudiux commented 9 months ago

Great! This issue will be automatically closed when I merge this PR #5354. Maybe you can increment the score of this applet? https://cinnamon-spices.linuxmint.com/applets/view/306

mildly-useful commented 9 months ago

Done! Thanks again.