LayoutTests:
authoradele <adele@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 16 Nov 2006 01:42:28 +0000 (01:42 +0000)
committeradele <adele@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 16 Nov 2006 01:42:28 +0000 (01:42 +0000)
commitcdd523615599a35cf4fb97ab21935621605d99b8
treef15f3a33d6d262101257de927b0fec727368c769
parent7bdfb4e6fcba5439973800b744aec269a9097cb9
LayoutTests:

        Reviewed by Adam.

        Updating results for new slider implementation.

        * fast/forms/input-appearance-height-expected.checksum:
        * fast/forms/input-appearance-height-expected.png:
        * fast/forms/input-appearance-height-expected.txt:

WebCore:

        Reviewed by Adam.

        New implementation of slider control.

        * WebCore.xcodeproj/project.pbxproj: Removed DeprecatedSlider and Slider classes, added RenderSlider class.
        * rendering/DeprecatedSlider.cpp: Removed.
        * rendering/DeprecatedSlider.h: Removed.
        * platform/Slider.h: Removed.
        * platform/mac/SliderMac.mm: Removed.
        * platform/win/TemporaryLinkStubs.cpp:

        * css/CSSSelector.h: (WebCore::CSSSelector::): Added PseudoElement for thumb, PseudoSliderThumb.
        * css/CSSSelector.cpp: (WebCore::CSSSelector::extractPseudoType): Added code for "-webkit-slider-thumb".
        * css/cssstyleselector.cpp: (WebCore::CSSStyleSelector::checkOneSelector):
        * rendering/RenderStyle.cpp:
        (WebCore::):
        (WebCore::pseudoBit):
        * rendering/RenderStyle.h: (WebCore::RenderStyle::):

        * css/html4.css: Added style for input[type="range"] and input[type="range"]::-webkit-slider-thumb

        * html/HTMLInputElement.cpp:
        (WebCore::HTMLInputElement::createRenderer): Create RenderSlider for input type="range" elements.
        (WebCore::HTMLInputElement::defaultEventHandler): Allow the renderer to forward events, and set thumb position when click occurs on the track.

        * page/EventHandler.cpp:  Added concept of a node that will capture all mouse events.  This will be used by the slider thumb, so it can
          continue to capture mouse move events during the drag, even though those events aren't directly over the slider.
        (WebCore::EventHandler::EventHandler):
        (WebCore::EventHandler::setCapturingMouseEventsNode):
        (WebCore::EventHandler::dispatchMouseEvent): If the capturingMouseEventsNode is set, then dispatch all mouse events to that node.
        * page/EventHandler.h:

        * rendering/RenderSlider.cpp: Added.
        (WebCore::HTMLSliderThumbElement::isShadowNode):
        (WebCore::HTMLSliderThumbElement::shadowParentNode):
        (WebCore::HTMLSliderThumbElement::inDragMode): Keeps track of whether or not the thumb is in drag mode.
        (WebCore::HTMLSliderThumbElement::HTMLSliderThumbElement):
        (WebCore::HTMLSliderThumbElement::defaultEventHandler): Handles positioning of slider thumb during drag.
        (WebCore::RenderSlider::RenderSlider):
        (WebCore::RenderSlider::~RenderSlider):
        (WebCore::RenderSlider::baselinePosition):
        (WebCore::RenderSlider::calcMinMaxWidth):
        (WebCore::RenderSlider::setStyle):
        (WebCore::RenderSlider::createThumbStyle):
        (WebCore::RenderSlider::layout): Positions the thumb to be centered on the track.
        (WebCore::RenderSlider::updateFromElement):
        (WebCore::RenderSlider::mouseEventIsInThumb):
        (WebCore::RenderSlider::setValueForPosition):
        (WebCore::RenderSlider::setPositionFromValue):
        (WebCore::RenderSlider::positionForOffset):
        (WebCore::RenderSlider::valueChanged):
        (WebCore::RenderSlider::currentPosition):
        (WebCore::RenderSlider::setCurrentPosition):
        (WebCore::RenderSlider::trackSize):
        (WebCore::RenderSlider::forwardEvent):
        (WebCore::RenderSlider::inDragMode):
        * rendering/RenderSlider.h: Added.
        (WebCore::RenderSlider::renderName):

         * rendering/RenderTheme.cpp: Added drawing code for slider track and thumb.
        (WebCore::RenderTheme::adjustStyle):
        (WebCore::RenderTheme::paint):
        (WebCore::RenderTheme::paintBorderOnly):
        (WebCore::RenderTheme::paintDecorations):
        (WebCore::RenderTheme::adjustSliderTrackStyle):
        (WebCore::RenderTheme::adjustSliderThumbStyle):
        * rendering/RenderTheme.h:
        (WebCore::RenderTheme::paintSliderTrack):
        (WebCore::RenderTheme::paintSliderThumb):
        * rendering/RenderThemeMac.h:
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::RenderThemeMac):
        (WebCore::TrackGradientInterpolate):
        (WebCore::RenderThemeMac::paintSliderTrack):
        (WebCore::RenderThemeMac::paintSliderThumb):
        (WebCore::RenderThemeMac::adjustSliderTrackStyle):
        (WebCore::RenderThemeMac::adjustSliderThumbStyle):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17798 268f45cc-cd09-0410-ab3c-d52691b4dbfc
26 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/forms/input-appearance-height-expected.checksum
LayoutTests/fast/forms/input-appearance-height-expected.png
LayoutTests/fast/forms/input-appearance-height-expected.txt
WebCore/ChangeLog
WebCore/WebCore.xcodeproj/project.pbxproj
WebCore/css/CSSSelector.cpp
WebCore/css/CSSSelector.h
WebCore/css/cssstyleselector.cpp
WebCore/css/html4.css
WebCore/html/HTMLInputElement.cpp
WebCore/page/EventHandler.cpp
WebCore/page/EventHandler.h
WebCore/platform/Slider.h [deleted file]
WebCore/platform/mac/SliderMac.mm [deleted file]
WebCore/platform/win/TemporaryLinkStubs.cpp
WebCore/rendering/DeprecatedSlider.cpp [deleted file]
WebCore/rendering/DeprecatedSlider.h [deleted file]
WebCore/rendering/RenderSlider.cpp [new file with mode: 0644]
WebCore/rendering/RenderSlider.h [new file with mode: 0644]
WebCore/rendering/RenderStyle.cpp
WebCore/rendering/RenderStyle.h
WebCore/rendering/RenderTheme.cpp
WebCore/rendering/RenderTheme.h
WebCore/rendering/RenderThemeMac.h
WebCore/rendering/RenderThemeMac.mm