StyleResolver: Garbage collect the matched properties cache on a timer.
<http://webkit.org/b/98625>

Reviewed by Eric Seidel.

Sweeping the matched properties cache once every 100 additions ended up choking RoboHornet's
svgresize.html benchmark. Move it to a single-shot timer that's refreshed every 100 additions
and defers the actual sweep for 60 seconds.

* css/StyleResolver.cpp:
(WebCore::StyleResolver::StyleResolver):
(WebCore::StyleResolver::sweepMatchedPropertiesCache):
(WebCore::StyleResolver::addToMatchedPropertiesCache):
* css/StyleResolver.h:
(StyleResolver):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@131388 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Input elements with multiple fields UI should set appropriate direction for browser locale automatically
https://bugs.webkit.org/show_bug.cgi?id=99291

Reviewed by Hajime Morita.

Source/WebCore:

Input elemnts with multiple fields UI ignores HTML dir attribute or CSS
direction property, and their direction should be decided by the browser
locale. If the browser locale is a RTL language, date/time input fields
show formats/digits for the RTL language. The layout should be always
RTL regardless of the direction in such case.

Test: fast/forms/date-multiple-fields/date-multiple-fields-appearance-l10n.html

* html/BaseMultipleFieldsDateAndTimeInputType.cpp:
(WebCore::BaseMultipleFieldsDateAndTimeInputType::updateInnerTextValue):
Set approriate dir attribute value to the child element of the UA shadow root.

LayoutTests:

* fast/forms/date-multiple-fields/date-multiple-fields-appearance-l10n.html:
Added. We can confirm ar-eg and he-il have RTL layout.
* fast/forms/date-multiple-fields/date-multiple-fields-appearance-l10n-expected.txt: Added.
* platform/chromium-mac/fast/forms/date-multiple-fields/date-multiple-fields-appearance-l10n-expected.png: Added.

* fast/forms/date-multiple-fields/date-multiple-fields-keyboard-events-expected.txt:
* fast/forms/date-multiple-fields/date-multiple-fields-keyboard-events.html:
- Enable the lang-attribute-aware-form-control-UI feature.
- Set lang=he-il instead of dir=rtl because dir=rtl is ignored.
* fast/forms/month-multiple-fields/month-multiple-fields-keyboard-events.html: Ditto.
* fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html: Ditto.

* platform/chromium-mac/fast/forms/date-multiple-fields/date-multiple-fields-appearance-basic-expected.png:
Updated becaues dir=RTL doesn't affect.
* platform/chromium-mac/fast/forms/month-multiple-fields/month-multiple-fields-appearance-basic-expected.png:
Ditto.
* platform/chromium-mac/fast/forms/time-multiple-fields/time-multiple-fields-appearance-basic-expected.png:
Ditto.
* platform/chromium-mac/fast/forms/week-multiple-fields/week-multiple-fields-appearance-basic-expected.png:
Ditto.

* platform/chromium/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@131389 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION: Build break after r131373 when ACCELERATED_COMPOSITING disabled
https://bugs.webkit.org/show_bug.cgi?id=99397

Unreviewed, build fix.

* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@131390 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove page visibility hidden histograms
https://bugs.webkit.org/show_bug.cgi?id=99360

Reviewed by Ojan Vafai.

The 2 page visibility hidden histograms were added in http://webkit.org/b/85537 to
investigate a potential optimization where we would destroy the render tree when
a tab was hidden. The optimization was abandoned but the histograms were never
removed. They are too narrow to be reused so this change removes them.

* page/Page.cpp:
(WebCore::Page::setVisibilityState):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@131391 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LocaleMacTest.formatDate is failing on Mac 10.8
https://bugs.webkit.org/show_bug.cgi?id=99330

It seems OS X 10.8 and 10.7 return different date formats for ja_JP
locale. We should not test such locales.

* tests/LocaleMacTest.cpp:
(TEST_F): Remove a test for ja_JP locale.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@131392 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix GraphicsLayer visible rect computation when scrolling in WebKit1
https://bugs.webkit.org/show_bug.cgi?id=99385

Reviewed by Dean Jackson, Tim Horton.

Source/WebCore:

RenderLayerCompositor always used frameView->frameRect() as the visible
rect on the root used for GraphicsLayer visibleRect computation. This
was wrong for subframes, which require a rect with an origin of (0,0)
and size of the contentsSize().

It was also wrong when the scrolling is not represented in the GraphicsLayer
tree. When scrolling is done elsewhere, we need to use the ScrollView's
visibleContentRect().

Tests: compositing/visible-rect/scrolled.html
       compositing/visible-rect/iframe-and-layers.html
       compositing/visible-rect/iframe-no-layers.html

* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::flushPendingLayerChanges):

LayoutTests:

scrolled.html tests the visible rect after scrolling. The other tests
are for visibleRect in iframes, with and without compositing layers
in the parent document (which exercises different code paths in WebKit1).

* compositing/visible-rect/iframe-and-layers-expected.txt: Added.
* compositing/visible-rect/iframe-and-layers.html: Added.
* compositing/visible-rect/iframe-no-layers-expected.txt: Added.
* compositing/visible-rect/iframe-no-layers.html: Added.
* compositing/visible-rect/resources/subframe-with-layers.html: Added.
* compositing/visible-rect/scrolled-expected.txt: Added.
* compositing/visible-rect/scrolled.html: Added.
* platform/mac-wk2/compositing/visible-rect/iframe-no-layers-expected.txt: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@131393 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium] The default target for Android builds should be "all" instead of "All"
https://bugs.webkit.org/show_bug.cgi?id=98879

Reviewed by Adam Barth.

The default gyp target for Android builds is being overridden in Chromium's
envsetup_functions.sh to "All" (whereas the rest of Chromium and WebKit use "all"),
because Android wants to use a different list of main targets. There is
no need to do this for the WebKit project, and it's breaking ninja.

* gyp_webkit:


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