Closed Bug 1250087 Opened 9 years ago Closed 9 years ago

The value of mute/volume in the nsPIDOMWindow should be as same as AudioChannelConfig's.

Categories

(Firefox OS Graveyard :: AudioChannel, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: alwu, Assigned: alwu)

Details

When we change the value of the audioMuted and audioVolume, it should also be applied to the AudioChannelService::AudioChannelConfig. Both them are related to the same window, so we should make them consistent.
Hi, Baku, Should the |winData->mChannels.mVolume| always equal to |window->GetAudioVolume()|? Thanks!
Flags: needinfo?(amarchesini)
No it's not. the window volume is managed by the window itself or by nsIDOMWindowUtils. AudioChannelService exposes the volume via BrowserElement API in b2g. These 2 values are multiplied in AudioChannelService::GetState.
Flags: needinfo?(amarchesini)
Why we don't treat them as the same value? Is there any use cases we need two different volume values for that window?
Because most of time the volume of the AudioChannelConfig is 1.0, that means the multiplied result is equal to the window volume. Therefore, I am thinking about whether we can make them consistent and regard them as the same value.
Flags: needinfo?(amarchesini)
> Therefore, I am thinking about whether we can make them consistent and > regard them as the same value. That would mean that nsIDOMWindowUtils and BrowserElement API touch the same value. I don't see good reasons to do that. Same for muted value. But if you want to propose something, I'll review it.
Flags: needinfo?(amarchesini)
After rethinking my proposal, it seems no significant benefit to merge these two value together. Reopen it if we need to do that someday.
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.