Add touch support to the calendar picker
https://bugs.webkit.org/show_bug.cgi?id=112256

Reviewed by Kent Tamura.

Source/WebCore:

This patch increases the hit target sizes for touch and adds touch event
support to the scroll view, scroll bar and navigation button.

Tests: platform/chromium/fast/forms/calendar-picker/calendar-picker-touch-operations.html
       platform/chromium/fast/forms/calendar-picker/month-picker-touch-operations.html
       platform/chromium/fast/forms/calendar-picker/week-picker-touch-operations.html

* Resources/pagepopups/calendarPicker.js:
(hasInaccuratePointingDevice):
(Animator): Super class for TransitionAnimator and FlingGestureAnimator.
(Animator.prototype.start):
(Animator.prototype.stop):
(Animator.prototype.onAnimationFrame):
(TransitionAnimator): Same as the old Animator. Transition from one value to another.
(TransitionAnimator.prototype.setFrom):
(TransitionAnimator.prototype.start):
(TransitionAnimator.prototype.stop):
(TransitionAnimator.prototype.setTo):
(TransitionAnimator.prototype.onAnimationFrame):
(FlingGestureAnimator):Animates the fling scroll.
(FlingGestureAnimator.prototype._valueAtTime): Returns the value at the given time.
(FlingGestureAnimator.prototype._velocityAtTime): Returns the value change velocity at the given time.
(FlingGestureAnimator.prototype._timeAtVelocity): Returns the time when the value is changing at the given velocity.
(FlingGestureAnimator.prototype.start):
(FlingGestureAnimator.prototype.onAnimationFrame):
(ScrollView): Added support for touch gesture scrolling.
(ScrollView.prototype.onTouchStart):
(ScrollView.prototype.onWindowTouchMove):
(ScrollView.prototype.onWindowTouchEnd):
(ScrollView.prototype.onFlingGestureAnimatorStep):
(ScrollView.prototype.scrollTo):
(ScrubbyScrollBar): Added support for touch.
(ScrubbyScrollBar.prototype.onTouchStart):
(ScrubbyScrollBar.prototype.onWindowTouchMove):
(ScrubbyScrollBar.prototype.onWindowTouchEnd):
(ScrubbyScrollBar.prototype._setThumbPositionFromEventPosition): Accept MouseEvent or Touch.
(ScrubbyScrollBar.prototype.onMouseDown):
(ScrubbyScrollBar.prototype.onWindowMouseMove):
(ScrubbyScrollBar.prototype.onWindowMouseUp):
(YearListCell):
(YearListView):
(YearListView.prototype.onTouchStart):
(YearListView.prototype._animateRow):
(CalendarNavigationButton): Add touch support for long press.
(CalendarNavigationButton.prototype.onTouchStart):
(CalendarNavigationButton.prototype.onWindowTouchEnd):
(CalendarNavigationButton.prototype.onMouseDown):
(CalendarNavigationButton.prototype.onWindowMouseUp):
(CalendarTableView): Disable touch gesture scrolling in the calendar table.

LayoutTests:

* platform/chromium/fast/forms/calendar-picker/calendar-picker-touch-operations-expected.txt: Added.
* platform/chromium/fast/forms/calendar-picker/calendar-picker-touch-operations.html: Added.
* platform/chromium/fast/forms/calendar-picker/month-picker-touch-operations-expected.txt: Added.
* platform/chromium/fast/forms/calendar-picker/month-picker-touch-operations.html: Added.
* platform/chromium/fast/forms/calendar-picker/resources/calendar-picker-common.js:
(hoverOverMonthPopupButton):
(clickMonthPopupButton): Use hoverOverMonthPopupButton.
* platform/chromium/fast/forms/calendar-picker/week-picker-touch-operations-expected.txt: Added.
* platform/chromium/fast/forms/calendar-picker/week-picker-touch-operations.html: Added.


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