diff options
author | Xabier Rodriguez Calvar <calvaris@igalia.com> | 2015-01-05 16:01:59 +0100 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-01-06 16:07:33 +0100 |
commit | c92fe03ac19f09eb5db25cb0f02809fab80fbecc (patch) | |
tree | 6ca9e09bf7bf4f0bf987797aff8829219771bfe3 /Source/JavaScriptCore/API/JSCallbackFunction.cpp | |
parent | c7412da7727fc51a1f89cbe529c5d4a99adcfd10 (diff) | |
download | qtwebkit-c92fe03ac19f09eb5db25cb0f02809fab80fbecc.tar.gz |
[GStreamer] Video player sets system volume to 100%
https://bugs.webkit.org/show_bug.cgi?id=118974
Reviewed by Philippe Normand.
In order to preserve the system volume we need to keep track of
the volume being initialized in the HTMLMediaElement and then just
setting the volume to the sink when initializing the pipeline if
that volume was changed before.
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::HTMLMediaElement): Initialized
attribute to false.
(WebCore::HTMLMediaElement::setVolume): Set the attribute to true
when volume is changed.
(WebCore::HTMLMediaElement::updateVolume): Set the volume only if
volume was initialized.
(WebCore::HTMLMediaElement::mediaPlayerPlatformVolumeConfigurationRequired):
Platform volume configuration is required only if volume was not
initialized before.
* html/HTMLMediaElement.h: Added attribute and interface method.
* platform/graphics/MediaPlayer.h:
(WebCore::MediaPlayerClient::mediaPlayerPlatformVolumeConfigurationRequired):
Declared and added default implementation for the interface method.
(WebCore::MediaPlayer::platformVolumeConfigurationRequired):
Asked the client, meaning the HTMLMediaElement if the platform
volume configuration is required.
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::mediaPlayerPrivateVolumeChangedCallback): Added log.
(WebCore::MediaPlayerPrivateGStreamerBase::setVolume): Added log.
(WebCore::MediaPlayerPrivateGStreamerBase::setStreamVolumeElement):
Set the volume only if not platform volume is required and added log.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154970 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Task-number: QTBUG-43479
Task-number: QTBUG-34896
Change-Id: I4031b33e52e2299b03a5844770dc17c69822059c
Reviewed-by: Michael BrĂ¼ning <michael.bruning@theqtcompany.com>
Diffstat (limited to 'Source/JavaScriptCore/API/JSCallbackFunction.cpp')
0 files changed, 0 insertions, 0 deletions