2010-07-08 Eric Carlson <eric.carlson@apple.com>
authoreric.carlson@apple.com <eric.carlson@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 8 Jul 2010 20:00:49 +0000 (20:00 +0000)
committereric.carlson@apple.com <eric.carlson@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 8 Jul 2010 20:00:49 +0000 (20:00 +0000)
commitf168579d3c2e0fd956c85d01bcd294eb70801aa6
treea75fb5ed9176f65540bc1ab621d850a1f80ec0fe
parent40abd89a1d3531692289685620c605338f1a70bd
2010-07-08  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by NOBODY (OOPS!).

        Mac OS X media controls should have a way to adjust volume incrementally
        https://bugs.webkit.org/show_bug.cgi?id=41718
        <rdar://problem/5679472>

        * css/CSSPrimitiveValueMappings.h:
        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Handle MediaVolumeSliderMuteButtonPart.

        * css/CSSSelector.cpp:
        (WebCore::CSSSelector::pseudoId): Handle PseudoMediaControlsVolumeSliderMuteButton.
        (WebCore::nameToPseudoTypeMap): Define mediaControlsVolumeSliderMuteButton.
        (WebCore::CSSSelector::extractPseudoType): Handle PseudoMediaControlsVolumeSliderMuteButton.

        * css/CSSSelector.h:
        (WebCore::CSSSelector::): Define PseudoMediaControlsVolumeSliderMuteButton.

        * css/CSSValueKeywords.in: Define media-volume-slider-mute-button.

        * css/mediaControls.css:
        (audio::-webkit-media-controls-volume-slider-mute-button, video::-webkit-media-controls-volume-slider-mute-button): New.

        * css/mediaControlsQuickTime.css:
        (audio::-webkit-media-controls-panel, video::-webkit-media-controls-panel): Add "overflow: visible"
        so volume slider pop-up will be visible.

        (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button): Make
        mute button 14x12 instead of 15x14 so it matches the size in the volume slider.

        (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
        (audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider):
        (audio::-webkit-media-controls-volume-slider-mute-button, video::-webkit-media-controls-volume-slider-mute-button):
        New.

        * platform/ThemeTypes.h: Define MediaVolumeSliderMuteButtonPart.

        * rendering/MediaControlElements.cpp:
        (WebCore::MediaControlInputElement::MediaControlInputElement): Handle MEDIA_CONTROLS_VOLUME_SLIDER_MUTE_BUTTON.
        (WebCore::MediaControlMuteButtonElement::MediaControlMuteButtonElement): Add ButtonLocation
        parameter both mute buttons can be created.
        (WebCore::MediaControlMuteButtonElement::create): Ditto.

        * rendering/MediaControlElements.h: Define MediaVolumeSliderMuteButton and ButtonLocation.

        * rendering/RenderMedia.cpp:
        (WebCore::RenderMedia::styleDidChange): Update volume slider mute button.
        (WebCore::RenderMedia::createMuteButton): Pass ButtonLocation parameter to MediaControlMuteButtonElement::create.
        (WebCore::RenderMedia::createVolumeSliderMuteButton): New.
        (WebCore::RenderMedia::updateControls): Deal with volume slider mute button.
        (WebCore::RenderMedia::updateVolumeSliderContainer): Don't assume all ports want to position
        the volume slider in the same place, call new volumeSliderOffsetFromMuteButton theme function.
        (WebCore::RenderMedia::forwardEvent): Handle volume slider mute button.
        * rendering/RenderMedia.h:

        * rendering/RenderTheme.cpp:
        (WebCore::RenderTheme::paint): Handle MediaVolumeSliderMuteButtonPart.
        (WebCore::RenderTheme::volumeSliderOffsetFromMuteButton): New, return location previously hard
        coded in RenderMedia::updateVolumeSliderContainer.
        * rendering/RenderTheme.h:

        * rendering/RenderThemeMac.h:
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::adjustMediaSliderThumbSize): Deal with the volume slider thumb.
        (WebCore::RenderThemeMac::paintMediaVolumeSliderContainer): New, call the WKSI paint function
        for this button.
        (WebCore::RenderThemeMac::paintMediaVolumeSliderTrack): Ditto.
        (WebCore::RenderThemeMac::paintMediaVolumeSliderThumb): Ditto.
        (WebCore::RenderThemeMac::shouldRenderMediaControlPart): Draw the volume slider parts when
        using the new controller UI for a movie that has audio.
        (WebCore::RenderThemeMac::volumeSliderOffsetFromMuteButton): New, position the volume slider
        directly above the mute button.

        * rendering/style/RenderStyleConstants.h: Define MEDIA_CONTROLS_VOLUME_SLIDER_MUTE_BUTTON.

2010-07-08  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Dan Bernstein.

        Update WebKitSystemInterface.

        * libWebKitSystemInterfaceLeopard.a:
        * libWebKitSystemInterfaceSnowLeopard.a:
        * libWebKitSystemInterfaceTiger.a:

2010-07-08  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Dan Bernstein.

        Mac OS X media controls should have a way to adjust volume incrementally
        https://bugs.webkit.org/show_bug.cgi?id=41718
        <rdar://problem/5679472>

        Updated results for the mute button size change. Remove some Leopard test results
        where the SnowLeopard results are identical.

        * platform/mac-leopard/media/audio-controls-rendering-expected.checksum: Removed.
        * platform/mac-leopard/media/audio-controls-rendering-expected.png: Removed.
        * platform/mac-leopard/media/audio-controls-rendering-expected.txt: Removed.
        * platform/mac-leopard/media/controls-after-reload-expected.checksum: Removed.
        * platform/mac-leopard/media/controls-after-reload-expected.png: Removed.
        * platform/mac-leopard/media/controls-after-reload-expected.txt: Removed.
        * platform/mac-leopard/media/controls-styling-expected.checksum: Removed.
        * platform/mac-leopard/media/controls-styling-expected.png: Removed.
        * platform/mac-leopard/media/controls-styling-expected.txt: Removed.
        * platform/mac-leopard/media/video-zoom-controls-expected.checksum: Removed.
        * platform/mac-leopard/media/video-zoom-controls-expected.png: Removed.
        * platform/mac-leopard/media/video-zoom-controls-expected.txt: Removed.
        * platform/mac/media/audio-controls-rendering-expected.txt:
        * platform/mac/media/controls-after-reload-expected.txt:
        * platform/mac/media/controls-styling-expected.txt:
        * platform/mac/media/video-zoom-controls-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@62821 268f45cc-cd09-0410-ab3c-d52691b4dbfc
35 files changed:
LayoutTests/ChangeLog
LayoutTests/platform/mac-leopard/media/audio-controls-rendering-expected.checksum [deleted file]
LayoutTests/platform/mac-leopard/media/audio-controls-rendering-expected.png [deleted file]
LayoutTests/platform/mac-leopard/media/audio-controls-rendering-expected.txt [deleted file]
LayoutTests/platform/mac-leopard/media/controls-after-reload-expected.txt
LayoutTests/platform/mac-leopard/media/controls-strict-expected.txt
LayoutTests/platform/mac-leopard/media/controls-styling-expected.txt
LayoutTests/platform/mac-leopard/media/video-controls-rendering-expected.txt
LayoutTests/platform/mac-leopard/media/video-display-toggle-expected.txt
LayoutTests/platform/mac-leopard/media/video-zoom-controls-expected.txt
LayoutTests/platform/mac/media/audio-controls-rendering-expected.txt
LayoutTests/platform/mac/media/controls-after-reload-expected.txt
LayoutTests/platform/mac/media/controls-styling-expected.txt
LayoutTests/platform/mac/media/video-zoom-controls-expected.txt
WebCore/ChangeLog
WebCore/css/CSSPrimitiveValueMappings.h
WebCore/css/CSSSelector.cpp
WebCore/css/CSSSelector.h
WebCore/css/CSSValueKeywords.in
WebCore/css/mediaControls.css
WebCore/css/mediaControlsQuickTime.css
WebCore/platform/ThemeTypes.h
WebCore/rendering/MediaControlElements.cpp
WebCore/rendering/MediaControlElements.h
WebCore/rendering/RenderMedia.cpp
WebCore/rendering/RenderMedia.h
WebCore/rendering/RenderTheme.cpp
WebCore/rendering/RenderTheme.h
WebCore/rendering/RenderThemeMac.h
WebCore/rendering/RenderThemeMac.mm
WebCore/rendering/style/RenderStyleConstants.h
WebKitLibraries/ChangeLog
WebKitLibraries/libWebKitSystemInterfaceLeopard.a
WebKitLibraries/libWebKitSystemInterfaceSnowLeopard.a
WebKitLibraries/libWebKitSystemInterfaceTiger.a