From 862181606916a4fde71061af5f98eb1a53b6b4ce Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Tue, 22 Oct 2024 17:44:19 +0200 Subject: [PATCH 1/7] Fixed allow NVDA to control the volume of other apps --- 2 | 0 source/audio/appsVolume.py | 10 +++++++++- source/globalCommands.py | 3 +-- 3 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 2 diff --git a/2 b/2 new file mode 100644 index 00000000000..e69de29bb2d diff --git a/source/audio/appsVolume.py b/source/audio/appsVolume.py index 0b9a1a924ec..96f9597f7c6 100644 --- a/source/audio/appsVolume.py +++ b/source/audio/appsVolume.py @@ -163,7 +163,15 @@ def _toggleAppsVolumeState(): state = _APPS_VOLUME_STATES_ORDER[index] config.conf["audio"]["applicationsVolumeMode"] = state.name _updateAppsVolumeImpl(volume / 100.0, muted, state) - ui.message(state.displayString) + if state == AppsVolumeAdjusterFlag.ENABLED: + # Translators: Reported as a result of the command to allow or disallow to control the volume of other + # applications + msg = _("Allowed to control the volume of other applications") + else: + # Translators: Reported as a result of the command to allow or disallow to control the volume of other + # applications + msg = _("Disallowed to control the volume of other applications") + ui.message(msg) def _toggleAppsVolumeMute(): diff --git a/source/globalCommands.py b/source/globalCommands.py index e7ee405dc50..89f91725ae2 100755 --- a/source/globalCommands.py +++ b/source/globalCommands.py @@ -4775,10 +4775,9 @@ def script_decreaseApplicationsVolume(self, gesture: "inputCore.InputGesture") - @script( description=_( # Translators: Describes a command. - "Toggles other applications volume adjuster status", + "Allow or disallow to control the volume of other applications", ), category=SCRCAT_AUDIO, - gesture=None, ) def script_toggleApplicationsVolumeAdjuster(self, gesture: "inputCore.InputGesture") -> None: appsVolume._toggleAppsVolumeState() From 28c6cc7c6e269fe1fdbcb6a5f25befc6e4960c97 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Tue, 22 Oct 2024 22:50:23 +0200 Subject: [PATCH 2/7] Update options in the User Guide --- user_docs/en/userGuide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/user_docs/en/userGuide.md b/user_docs/en/userGuide.md index 5d063711ba7..f5e79292f8a 100644 --- a/user_docs/en/userGuide.md +++ b/user_docs/en/userGuide.md @@ -2469,7 +2469,7 @@ This option is not available if you have started NVDA with [WASAPI disabled for | . {.hideHeaderRow} |.| |---|---| -|Options |No, Yes| +|Options |Default (No), No, Yes| |Default |No| This combo box determines whether NVDA commands can be used to adjust the volume of other applications running on the system. From 643e9bb532df77e9be7fd5ed75e2d244b907619d Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Tue, 22 Oct 2024 22:53:27 +0200 Subject: [PATCH 3/7] Remove a file created by error --- 2 | 0 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 2 diff --git a/2 b/2 deleted file mode 100644 index e69de29bb2d..00000000000 From fb08988f1e619bad58d2c32d0306cb166f93b706 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Wed, 23 Oct 2024 09:29:15 +0200 Subject: [PATCH 4/7] Update source/audio/appsVolume.py Co-authored-by: Luke Davis <8139760+XLTechie@users.noreply.github.com> --- source/audio/appsVolume.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/audio/appsVolume.py b/source/audio/appsVolume.py index 96f9597f7c6..da75ae770aa 100644 --- a/source/audio/appsVolume.py +++ b/source/audio/appsVolume.py @@ -166,7 +166,7 @@ def _toggleAppsVolumeState(): if state == AppsVolumeAdjusterFlag.ENABLED: # Translators: Reported as a result of the command to allow or disallow to control the volume of other # applications - msg = _("Allowed to control the volume of other applications") + msg = _("Enabled control of other applications' volume") else: # Translators: Reported as a result of the command to allow or disallow to control the volume of other # applications From 6ee679957918a8efad5a3b5c6be7e0fff0026d18 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Wed, 23 Oct 2024 09:36:40 +0200 Subject: [PATCH 5/7] Update source/globalCommands.py Co-authored-by: Luke Davis <8139760+XLTechie@users.noreply.github.com> --- source/globalCommands.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/globalCommands.py b/source/globalCommands.py index 89f91725ae2..4a7f8cee0c7 100755 --- a/source/globalCommands.py +++ b/source/globalCommands.py @@ -4775,7 +4775,7 @@ def script_decreaseApplicationsVolume(self, gesture: "inputCore.InputGesture") - @script( description=_( # Translators: Describes a command. - "Allow or disallow to control the volume of other applications", + "Toggle whether control of other applications' volume is enabled.", ), category=SCRCAT_AUDIO, ) From 4c36b633500ec53354291be5db7b88c1a2464a04 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Wed, 23 Oct 2024 09:43:45 +0200 Subject: [PATCH 6/7] Reword translators comment --- source/audio/appsVolume.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/source/audio/appsVolume.py b/source/audio/appsVolume.py index da75ae770aa..63c36055dfa 100644 --- a/source/audio/appsVolume.py +++ b/source/audio/appsVolume.py @@ -164,13 +164,13 @@ def _toggleAppsVolumeState(): config.conf["audio"]["applicationsVolumeMode"] = state.name _updateAppsVolumeImpl(volume / 100.0, muted, state) if state == AppsVolumeAdjusterFlag.ENABLED: - # Translators: Reported as a result of the command to allow or disallow to control the volume of other - # applications + # Translators: Reported as a result of the command to toggle whether control of other applications' volume + # is enabled. msg = _("Enabled control of other applications' volume") else: - # Translators: Reported as a result of the command to allow or disallow to control the volume of other - # applications - msg = _("Disallowed to control the volume of other applications") + # Translators: Reported as a result of the command to toggle whether control of other applications' volume + # is enabled. + msg = _("Enabled control of other applications' volume") ui.message(msg) From f4178f0de379a3851cfd44e8637344bb601ce1e8 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Wed, 23 Oct 2024 10:31:28 +0200 Subject: [PATCH 7/7] Update source/audio/appsVolume.py Co-authored-by: Luke Davis <8139760+XLTechie@users.noreply.github.com> --- source/audio/appsVolume.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/audio/appsVolume.py b/source/audio/appsVolume.py index 63c36055dfa..3db401b12bb 100644 --- a/source/audio/appsVolume.py +++ b/source/audio/appsVolume.py @@ -170,7 +170,7 @@ def _toggleAppsVolumeState(): else: # Translators: Reported as a result of the command to toggle whether control of other applications' volume # is enabled. - msg = _("Enabled control of other applications' volume") + msg = _("Disabled control of other applications' volume") ui.message(msg)