[GTK] close the volume slider when the media control panel is hidden
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 13 Aug 2013 13:14:39 +0000 (13:14 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 13 Aug 2013 13:14:39 +0000 (13:14 +0000)
https://bugs.webkit.org/show_bug.cgi?id=119062

Patch by Danilo Cesar Lemes de Paula <danilo.cesar@collabora.co.uk> on 2013-08-13
Reviewed by Gustavo Noronha Silva.

It's not obvious how to close the volume slider on webkitGtk.
The volume slider should close if the control panel is hidden.

* html/shadow/MediaControlsGtk.cpp:
(WebCore::MediaControlsGtk::makeTransparent):
* html/shadow/MediaControlsGtk.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@154000 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/html/shadow/MediaControlsGtk.cpp
Source/WebCore/html/shadow/MediaControlsGtk.h

index 996aa32..2d167a3 100644 (file)
@@ -1,3 +1,17 @@
+2013-08-13  Danilo Cesar Lemes de Paula  <danilo.cesar@collabora.co.uk>
+
+        [GTK] close the volume slider when the media control panel is hidden
+        https://bugs.webkit.org/show_bug.cgi?id=119062
+
+        Reviewed by Gustavo Noronha Silva.
+
+        It's not obvious how to close the volume slider on webkitGtk.
+        The volume slider should close if the control panel is hidden.
+
+        * html/shadow/MediaControlsGtk.cpp:
+        (WebCore::MediaControlsGtk::makeTransparent):
+        * html/shadow/MediaControlsGtk.h:
+
 2013-08-13  Commit Queue  <commit-queue@webkit.org>
 
         Unreviewed, rolling out r152563.
index 5eec087..7281824 100644 (file)
@@ -201,6 +201,15 @@ void MediaControlsGtk::changedMute()
         m_volumeSlider->setVolume(m_mediaController->volume());
 }
 
+
+void MediaControlsGtk::makeTransparent()
+{
+    MediaControls::makeTransparent();
+
+    if (m_volumeSliderContainer)
+        m_volumeSliderContainer->hide();
+}
+
 void MediaControlsGtk::showVolumeSlider()
 {
     if (!m_mediaController->hasAudio())
index f709964..2ea3259 100644 (file)
@@ -46,6 +46,7 @@ public:
     void changedMute() OVERRIDE;
     virtual void updateCurrentTimeDisplay() OVERRIDE;
     virtual void showVolumeSlider() OVERRIDE;
+    virtual void makeTransparent() OVERRIDE;
 
 #if ENABLE(VIDEO_TRACK)
     void createTextTrackDisplay() OVERRIDE;