WebKit-https.git
7 years agoTurn PageLoad tests into simple performancetests, commit #7 (last)
zoltan@webkit.org [Mon, 29 Oct 2012 17:30:56 +0000 (17:30 +0000)]
Turn PageLoad tests into simple performancetests, commit #7 (last)
https://bugs.webkit.org/show_bug.cgi?id=99899

Reviewed by Ryosuke Niwa.

We cannot provide an elegant way to measure the memory consumption of the PageLoad tests, but we can turn them into simple
performance tests and measure their memory footprint and performance that way. This change moves and renames the related files
to their new location and adds html/js wrappers for them.

This is the #7 (last) commit of the whole patch.

* PageLoad: Removed.
* PageLoad/svg: Removed.
* PageLoad/svg/LICENSES: Removed.
* PageLoad/svg/files: Removed.
* PageLoad/svg/files/33041-Samurai.svg: Removed.
* PageLoad/svg/files/42450-under the see.svg: Removed.
* PageLoad/svg/files/world-iso.svg: Removed.
* PageLoad/svg/svg.pltsuite: Removed.
* SVG/Samurai.html: Added.
* SVG/UnderTheSee.html: Added.
* SVG/WorldIso.html: Added.
* SVG/resources/LICENSES: Copied from PerformanceTests/PageLoad/svg/LICENSES.
* SVG/resources/Samurai.svg: Copied from PerformanceTests/PageLoad/svg/files/33041-Samurai.svg.
* SVG/resources/UnderTheSee.svg: Copied from PerformanceTests/PageLoad/svg/files/42450-under%20the%20see.svg.
* SVG/resources/WorldIso.svg: Copied from PerformanceTests/PageLoad/svg/files/world-iso.svg.
* SVG/resources/svg.pltsuite: Copied from PerformanceTests/PageLoad/svg/svg.pltsuite.
* Skipped: Rename the files on the skipped list also.

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

7 years agoWeb Inspector: bind redo to Ctrl+Y on non-mac platforms
pfeldman@chromium.org [Mon, 29 Oct 2012 17:26:59 +0000 (17:26 +0000)]
Web Inspector: bind redo to Ctrl+Y on non-mac platforms
https://bugs.webkit.org/show_bug.cgi?id=100685

Reviewed by Vsevolod Vlasov.

* inspector/front-end/DefaultTextEditor.js:
(WebInspector.DefaultTextEditor.prototype._registerShortcuts):

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

7 years agoAdd ENABLE_USERSELECT_ALL feature flag.
enrica@apple.com [Mon, 29 Oct 2012 17:10:19 +0000 (17:10 +0000)]
Add ENABLE_USERSELECT_ALL feature flag.
https://bugs.webkit.org/show_bug.cgi?id=100559

Reviewed by Eric Seidel.

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig:

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

7 years ago[CSS Shaders] Extract the CustomFilterParameterList to its own file
achicu@adobe.com [Mon, 29 Oct 2012 16:50:06 +0000 (16:50 +0000)]
[CSS Shaders] Extract the CustomFilterParameterList to its own file
https://bugs.webkit.org/show_bug.cgi?id=100548

Reviewed by Dean Jackson.

Moved all the CustomFilterParameterList related methods to their own file.
Also made CustomFilterParameterList inherit from Vector instead of typedefing it,
so that we can add a different operator== and a blend method to it.

No new tests, just refactoring existing code.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.gypi:
* WebCore.xcodeproj/project.pbxproj:
* css/StyleResolver.h:
* platform/graphics/filters/CustomFilterOperation.cpp:
(WebCore::CustomFilterOperation::CustomFilterOperation):
(WebCore::CustomFilterOperation::blend):
* platform/graphics/filters/CustomFilterOperation.h:
(WebCore):
(WebCore::CustomFilterOperation::operator==):
* platform/graphics/filters/CustomFilterParameterList.cpp: Added.
(WebCore):
(WebCore::CustomFilterParameterList::operator==):
(WebCore::CustomFilterParameterList::checkAlphabeticalOrder):
(WebCore::CustomFilterParameterList::blend):
* platform/graphics/filters/CustomFilterParameterList.h: Added.
(WebCore):
(CustomFilterParameterList):

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

7 years agoTry to fix 32-bit builds after my incompletely tested m_identifier change.
beidson@apple.com [Mon, 29 Oct 2012 16:42:48 +0000 (16:42 +0000)]
Try to fix 32-bit builds after my incompletely tested m_identifier change.

Not reviewed.

* loader/ResourceLoader.h:
(WebCore::ResourceLoader::identifier): Revert my "unsigned long" -> "uint64_t" change in two places.

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

7 years ago[BlackBerry] Typo in WebPagePrivate::postponeDocumentRecalcStyle()
commit-queue@webkit.org [Mon, 29 Oct 2012 15:51:50 +0000 (15:51 +0000)]
[BlackBerry] Typo in WebPagePrivate::postponeDocumentRecalcStyle()
https://bugs.webkit.org/show_bug.cgi?id=100377

Patch by Mike Lattanzio <mlattanzio@rim.com> on 2012-10-29
Reviewed by Adam Treat.

Should be void, not bool.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::postponeDocumentStyleRecalc):
* Api/WebPage_p.h:
(WebPagePrivate):

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

7 years ago[WK2][WKTR] Enable Shadow DOM at runtime if compiled with SHADOW_DOM support
commit-queue@webkit.org [Mon, 29 Oct 2012 14:52:18 +0000 (14:52 +0000)]
[WK2][WKTR] Enable Shadow DOM at runtime if compiled with SHADOW_DOM support
https://bugs.webkit.org/show_bug.cgi?id=100668

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-10-29
Reviewed by Kenneth Rohde Christiansen.

Source/WebKit2:

Add Bundle API to enable Shadow DOM functionality. This is
now needed by WebKitTestRunner.

* WebProcess/InjectedBundle/API/c/WKBundle.cpp:
(WKBundleSetShadowDOMEnabled):
* WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
* WebProcess/InjectedBundle/InjectedBundle.cpp:
(WebKit::InjectedBundle::setShadowDOMEnabled):
(WebKit):
* WebProcess/InjectedBundle/InjectedBundle.h:
(InjectedBundle):

Tools:

Enable Shadow DOM functionality at run time in WebKitTestRunner
if compiled with SHADOW_DOM flag set. This is needed to run
the Shadow DOM layout tests.

* WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
(WTR::InjectedBundle::beginTesting):

LayoutTests:

Remove Shadow DOM layout tests from the global wk2 TestExpectations
and add it to the mac-wk2 one. EFL and GTK ports have Shadow DOM
enabled so they don't need to be skipped for those ports. The Qt port
is already skipping those tests in its global TestExpectations file.

* platform/efl-wk2/TestExpectations:
* platform/mac-wk2/TestExpectations:
* platform/wk2/TestExpectations:

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

7 years ago[EFL][WK2] Fix cursor change detection in EwkViewImpl::setCursor()
commit-queue@webkit.org [Mon, 29 Oct 2012 14:50:24 +0000 (14:50 +0000)]
[EFL][WK2] Fix cursor change detection in EwkViewImpl::setCursor()
https://bugs.webkit.org/show_bug.cgi?id=100662

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-10-29
Reviewed by Kenneth Rohde Christiansen.

Cursor change detection in EwkViewImpl::setCursor() relies on
addresses returned by Cursor::platformCursor(). However, the
value returned is currently assigned to a WKEinaSharedString
instead of a raw pointer. Therefore, the address is always
different and we keep recreating Evas Objects for the same
cursor.

* UIProcess/API/efl/EwkViewImpl.cpp:
(EwkViewImpl::EwkViewImpl):
(EwkViewImpl::setCursor): Call smartData() after same cursor
detection since it is not needed if the cursor has not changed
and it may affect performance.
* UIProcess/API/efl/EwkViewImpl.h:
(EwkViewImpl):

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

7 years ago[Qt] Text with zero font size renders as X px sometimes, causing fast/text/zero-font...
ossy@webkit.org [Mon, 29 Oct 2012 14:47:34 +0000 (14:47 +0000)]
[Qt] Text with zero font size renders as X px sometimes, causing fast/text/zero-font-size-2.html to fail
https://bugs.webkit.org/show_bug.cgi?id=100115

Reviewed by Noam Rosenthal.

Source/WebCore:

* platform/graphics/qt/FontQt.cpp:
(WebCore::Font::drawGlyphs):

LayoutTests:

* platform/qt/TestExpectations: Unskip fast/text/zero-font-size-2.html.

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

7 years agoCoordinated Graphics: Make sure that we release images immediately when purging resources
jocelyn.turcotte@digia.com [Mon, 29 Oct 2012 14:46:35 +0000 (14:46 +0000)]
Coordinated Graphics: Make sure that we release images immediately when purging resources
https://bugs.webkit.org/show_bug.cgi?id=100661

Reviewed by Noam Rosenthal.

When we purge, we do both on the UI and web process at the same time,
both are expected to release references of the other process.
This creates problem when delaying the release of directly composited
images.

Release them immediately in that case.

Fixes the tst_QQuickWebView::removeFromCanvas API test.

* WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
(WebKit::LayerTreeCoordinator::flushPendingLayerChanges):
(WebKit::LayerTreeCoordinator::purgeReleasedImages):
(WebKit):
(WebKit::LayerTreeCoordinator::purgeBackingStores):
* WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.h:
(LayerTreeCoordinator):

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

7 years ago[EFL][WK2] Avoid useless assignment in EwkViewImpl::setCustomTextEncodingName()
commit-queue@webkit.org [Mon, 29 Oct 2012 14:37:22 +0000 (14:37 +0000)]
[EFL][WK2] Avoid useless assignment in EwkViewImpl::setCustomTextEncodingName()
https://bugs.webkit.org/show_bug.cgi?id=100667

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-10-29
Reviewed by Kenneth Rohde Christiansen.

Remove useless m_customEncoding assignment in EwkViewImpl::setCustomTextEncodingName()
since the member is anyway assigned in EwkViewImpl::customTextEncodingName().

Have EwkViewImpl::setCustomTextEncodingName() take a String in argument instead
of a const char* to make the API more C++ and since we don't need a const char*
to assign to m_customEncoding anymore.

* UIProcess/API/efl/EwkViewImpl.cpp:
(EwkViewImpl::setCustomTextEncodingName):
* UIProcess/API/efl/EwkViewImpl.h:
(EwkViewImpl):
* UIProcess/API/efl/ewk_view.cpp:
(ewk_view_setting_encoding_custom_set):

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

7 years ago[EFL][AC] Fix bugs preventing us from running layout tests with AC turned on
commit-queue@webkit.org [Mon, 29 Oct 2012 14:29:52 +0000 (14:29 +0000)]
[EFL][AC] Fix bugs preventing us from running layout tests with AC turned on
https://bugs.webkit.org/show_bug.cgi?id=100598

Patch by Yael Aharon <yael.aharon@intel.com> on 2012-10-29
Reviewed by Kenneth Rohde Christiansen.

Make sure to use opengl_x11 engine when AC is turned on and X11 is in use.
We cannot create a gl context otherwise.

* MiniBrowser/efl/main.c:
(elm_main):
* WebKitTestRunner/efl/PlatformWebViewEfl.cpp:
(WTR::initEcoreEvas):
* DumpRenderTree/efl/DumpRenderTree.cpp:
(initEcoreEvas):
* EWebLauncher/efl/main.c:
(windowCreate):

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

7 years ago[TexMap] Make GraphicsLayerAnimation choose a proper timing function.
commit-queue@webkit.org [Mon, 29 Oct 2012 14:26:46 +0000 (14:26 +0000)]
[TexMap] Make GraphicsLayerAnimation choose a proper timing function.
https://bugs.webkit.org/show_bug.cgi?id=100623

Patch by Huang Dongsung <luxtella@company100.net> on 2012-10-29
Reviewed by Noam Rosenthal.

Currently, GraphicsLayerAnimation chooses a timing function in the wrong
way. Other GraphicsLayers choose a timing function in the similar way to
GraphicsLayerCA::timingFunctionForAnimationValue(). The way consists of
the following steps.
1. Try to query the timing function of the current keyframe animation value.
2. If the timing function of #1 is null, try to query the timing function of Animation.
3. If the timing function of #2 is null, return CubicBezierTimingFunction::defaultTimingFunction().

This patch makes GraphicsLayerAnimation choose a timing function in the same way
to other implementations.

Covered by existing animations tests.

* platform/graphics/GraphicsLayerAnimation.cpp:
(WebCore::timingFunctionForAnimationValue):
(WebCore::GraphicsLayerAnimation::apply):

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

7 years agoWeb Inspector: Toolbar overflow appears outside window
commit-queue@webkit.org [Mon, 29 Oct 2012 14:23:44 +0000 (14:23 +0000)]
Web Inspector: Toolbar overflow appears outside window
https://bugs.webkit.org/show_bug.cgi?id=100663

Patch by Patrick Dubroy <dubroy@chromium.org> on 2012-10-29
Reviewed by Pavel Feldman.

Since the search bar was removed from the toolbar, the overflow menu appears too far
to the right, and is unreadable. Fixed this by aligning it relative to the right side
of the window, rather than the left.

* inspector/front-end/Toolbar.js:
(WebInspector.ToolbarDropdown.prototype.show):
* inspector/front-end/inspector.css:
(#toolbar-dropdown .toolbar-label):

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

7 years ago[EFL][WK2] REGRESSION(r132342): fast/events/frame-tab-focus.html fails
rakuco@webkit.org [Mon, 29 Oct 2012 14:23:07 +0000 (14:23 +0000)]
[EFL][WK2] REGRESSION(r132342): fast/events/frame-tab-focus.html fails
https://bugs.webkit.org/show_bug.cgi?id=100646

Reviewed by Kenneth Rohde Christiansen.

Tools:

* WebKitTestRunner/efl/PlatformWebViewEfl.cpp:
(WTR::PlatformWebView::focus): Improve the check we perform to
decide whether the focus should be taken out of the view before
focusing it again so that we do not unnecessarily unfocus it and
cause blur/focus events to be triggered. Instead of just verifying
if the Evas_Object representing the view has focus, use the WK C
API to check that the currently focused frame is not the main
frame.

LayoutTests:

* platform/efl-wk2/TestExpectations: Unskip
fast/events/frame-tab-focus.html.

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

7 years ago[CSS Shaders] Implement CustomFilterArrayParameter::blend
michelangelo@webkit.org [Mon, 29 Oct 2012 14:10:05 +0000 (14:10 +0000)]
[CSS Shaders] Implement CustomFilterArrayParameter::blend
https://bugs.webkit.org/show_bug.cgi?id=96437

Reviewed by Dean Jackson.

Source/WebCore:

This patch adds the missing code to blend values within
an array() when using Custom Filters.

Test: css3/filters/custom/custom-filter-array-blending.html

* platform/graphics/filters/CustomFilterArrayParameter.h:
(WebCore::CustomFilterArrayParameter::blend):

LayoutTests:

New tests to asses the correctness of CustomFilterArrayParameter::blend.

* animations/resources/animation-test-helpers.js:
(customFilterParameterMatch): A check for functions' parameters length has been added.
* css3/filters/custom/custom-filter-array-blending-expected.txt: Added.
* css3/filters/custom/custom-filter-array-blending.html: Added.

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

7 years agoWeb Inspector: Drag and drop a URL in inspector is not working as expected
apavlov@chromium.org [Mon, 29 Oct 2012 13:52:23 +0000 (13:52 +0000)]
Web Inspector: Drag and drop a URL in inspector is not working as expected
https://bugs.webkit.org/show_bug.cgi?id=100527

Reviewed by Yury Semikhatsky.

Inhibit custom dragstart handling when the active element is A.

* inspector/front-end/ElementsTreeOutline.js:
(WebInspector.ElementsTreeOutline.prototype._ondragstart):

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

7 years agoWeb Inspector: Error/warning count is one pixel off.
mkwst@chromium.org [Mon, 29 Oct 2012 13:29:33 +0000 (13:29 +0000)]
Web Inspector: Error/warning count is one pixel off.
https://bugs.webkit.org/show_bug.cgi?id=100660

Reviewed by Pavel Feldman.

The error/warning count div had a top padding of 6. That was one pixel
too many.

* inspector/front-end/inspector.css:
(#error-warning-count):

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

7 years ago[BlackBerry] Fix a build error
commit-queue@webkit.org [Mon, 29 Oct 2012 13:07:47 +0000 (13:07 +0000)]
[BlackBerry] Fix a build error
https://bugs.webkit.org/show_bug.cgi?id=100649

Patch by Robin Cao <robin.cao@torchmobile.com.cn> on 2012-10-29
Reviewed by Kentaro Hara.

r127876 changed the signature of WebCore::EventHandler::hitTestResultAtPoint()
and this commit was later reverted. We need to update a call site in the
BlackBerry port to make it build.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::hitTestResult):

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

7 years ago[Refactoring] Use isActiveInsertionPoint() instead of isInsertionPoint()
shinyak@chromium.org [Mon, 29 Oct 2012 12:51:31 +0000 (12:51 +0000)]
[Refactoring] Use isActiveInsertionPoint() instead of isInsertionPoint()
https://bugs.webkit.org/show_bug.cgi?id=100459

Reviewed by Hajime Morita.

Checking InsertionPoint and its activeness with two if-statement is error-prone. We would like to
use a utility function which checks both at once.

We rewrite some lines with such function.

No new tests, simple refactoring.

* dom/ComposedShadowTreeWalker.cpp:
(WebCore::ComposedShadowTreeWalker::traverseNode):
* html/shadow/ContentDistributor.cpp:
(WebCore::ContentDistributor::populate):
(WebCore::ContentDistributor::distribute):
(WebCore::ContentDistributor::distributeNodeChildrenTo):
* html/shadow/InsertionPoint.h:
(WebCore::isInsertionPoint): Since our convention is the argument of this kind of function should not be null,
we would like to make it similar to the other functions.
(WebCore::toInsertionPoint):
(WebCore::isLowerEncapsulationBoundary):

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

7 years agoWeb Inspector: Fix vertical alignment in toolbar backgrounds and overflow button.
commit-queue@webkit.org [Mon, 29 Oct 2012 12:48:06 +0000 (12:48 +0000)]
Web Inspector: Fix vertical alignment in toolbar backgrounds and overflow button.
https://bugs.webkit.org/show_bug.cgi?id=100373

Patch by Patrick Dubroy <dubroy@chromium.org> on 2012-10-29
Reviewed by Pavel Feldman.

Fix the background image for the selected toolbar item to be vertically centered.
Make close button and toolbar overflow button vertically centered for any toolbar
height.

* inspector/front-end/Toolbar.js: Remove unused variable.
* inspector/front-end/inspector.css:
(.toolbar-item.toggleable):
(body.compact .toolbar-item.toggleable):
(.toolbar-item.toggleable.toggled-on):
(body.compact .toolbar-label):
(#toolbar-dropdown-arrow):
(#close-button-left, #close-button-right):
(.toolbar-item.close-left):
* inspector/front-end/inspector.html:

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

7 years agoWeb Inspector: Timeline: Overview bars do not correspond to timeline bars
commit-queue@webkit.org [Mon, 29 Oct 2012 12:43:02 +0000 (12:43 +0000)]
Web Inspector: Timeline: Overview bars do not correspond to timeline bars
https://bugs.webkit.org/show_bug.cgi?id=100500

Patch by Eugene Klyuchnikov <eustas.bug@gmail.com> on 2012-10-29
Reviewed by Yury Semikhatsky.

Fix: do not shorten bars by nested records of the same category.

* inspector/front-end/TimelineOverviewPane.js: Check added.

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

7 years agoWeb Inspector: Timeline: make cpu-monitoring feature available only on capable browsers
commit-queue@webkit.org [Mon, 29 Oct 2012 12:40:05 +0000 (12:40 +0000)]
Web Inspector: Timeline: make cpu-monitoring feature available only on capable browsers
https://bugs.webkit.org/show_bug.cgi?id=100530

Patch by Eugene Klyuchnikov <eustas.bug@gmail.com> on 2012-10-29
Reviewed by Yury Semikhatsky.

Motivation: cpu-monitoring feature looks like a glitch,
when it is not supported by browser.

Source/WebCore:

* inspector/Inspector.json: Added capability getter to protocol.
* inspector/InspectorClient.h: Added capability getter.
* inspector/InspectorTimelineAgent.cpp: Proxy to request to client.
* inspector/InspectorTimelineAgent.h: Added capability getter.
* inspector/front-end/Settings.js: Added capability field.
* inspector/front-end/TimelinePanel.js: Check capability.
* inspector/front-end/inspector.js: Forward capability value.

Source/WebKit/chromium:

* src/InspectorClientImpl.cpp: Implemented capability getter.
* src/InspectorClientImpl.h:

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

7 years agoMove seamless stylesheet collecting to DocumentStyleSheetCollection
antti@apple.com [Mon, 29 Oct 2012 12:37:57 +0000 (12:37 +0000)]
Move seamless stylesheet collecting to DocumentStyleSheetCollection
https://bugs.webkit.org/show_bug.cgi?id=100655

Reviewed by Andreas Kling.

Move the code from StyleResolver to DocumentStyleSheetCollection. StyleResolver should focus on resolving style.

* css/StyleResolver.cpp:
(WebCore::StyleResolver::StyleResolver):

    Use standard create() pattern.

(WebCore):
* css/StyleResolver.h:
(StyleResolver):
* dom/Document.cpp:
(WebCore::Document::Document):
* dom/DocumentStyleSheetCollection.cpp:
(WebCore::collectActiveCSSStyleSheetsFromSeamlessParents):

    Since parent activeAuthorStyleSheets() contains all seamlessly inherited sheets too, this does not need to
    iterate to ancestors anymore.

(WebCore):
(WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
* dom/DocumentStyleSheetCollection.h:
(WebCore::DocumentStyleSheetCollection::create):
(DocumentStyleSheetCollection):
(WebCore::DocumentStyleSheetCollection::styleSheetsForStyleSheetList):
(WebCore::DocumentStyleSheetCollection::activeAuthorStyleSheets):

    activeAuthorStyleSheets() now includes the stylesheets inherited from the seamless parent too.

(WebCore::DocumentStyleSheetCollection::needsUpdateActiveStylesheetsOnStyleRecalc):

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

7 years agoDon't expose implementation details of StylePropertySet storage.
kling@webkit.org [Mon, 29 Oct 2012 11:44:31 +0000 (11:44 +0000)]
Don't expose implementation details of StylePropertySet storage.
<http://webkit.org/b/100644>

Reviewed by Antti Koivisto.

Add a StylePropertySet::PropertyReference class, now returned by propertyAt(index).
This will allow us to refactor the internal storage of StylePropertySet without
breaking its API.

A PropertyReference is a simple inlinable wrapper around a StylePropertySet&/index pair.

* css/CSSComputedStyleDeclaration.cpp:
* css/CSSParser.cpp:
* css/CSSParser.h:
* css/SVGCSSParser.cpp:
* css/StylePropertySet.cpp:
(WebCore::StylePropertySet::asText):
(WebCore::StylePropertySet::mergeAndOverrideOnConflict):
(WebCore::StylePropertySet::findPropertyWithId):
(WebCore::StylePropertySet::reportMemoryUsage):
* css/StylePropertySet.h:
(StylePropertySet):
(PropertyReference):
(WebCore::StylePropertySet::PropertyReference::PropertyReference):
(WebCore::StylePropertySet::PropertyReference::id):
(WebCore::StylePropertySet::PropertyReference::isImportant):
(WebCore::StylePropertySet::PropertyReference::isInherited):
(WebCore::StylePropertySet::PropertyReference::cssName):
(WebCore::StylePropertySet::PropertyReference::cssText):
(WebCore::StylePropertySet::PropertyReference::value):
(WebCore::StylePropertySet::PropertyReference::propertyInternal):
(WebCore::StylePropertySet::propertyAt):
(WebCore::StylePropertySet::propertyAtInternal):
(WebCore):
* css/StyleResolver.cpp:
(WebCore::attributeStylesEqual):
(WebCore::StyleResolver::applyProperties):
(WebCore::StyleResolver::resolveVariables):
* editing/ApplyStyleCommand.cpp:
* editing/EditingStyle.cpp:
(WebCore::EditingStyle::mergeStyle):
(WebCore::EditingStyle::mergeStyleFromRulesForSerialization):
* editing/Editor.cpp:
* editing/markup.cpp:
* page/Frame.cpp:
* svg/SVGFontFaceElement.cpp:

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

7 years agoUnreviewed, rolling out r132782.
ossy@webkit.org [Mon, 29 Oct 2012 11:29:28 +0000 (11:29 +0000)]
Unreviewed, rolling out r132782.
http://trac.webkit.org/changeset/132782
https://bugs.webkit.org/show_bug.cgi?id=100653

It made 400+ tests fail and 180 tests flakey on Qt (Requested
by Ossy on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-10-29

Tools:

* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore::DumpRenderTree::resetToConsistentStateBeforeTesting):

LayoutTests:

* platform/qt/TestExpectations:

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

7 years agoUnreviewed, rolling out r132736.
ossy@webkit.org [Mon, 29 Oct 2012 11:21:07 +0000 (11:21 +0000)]
Unreviewed, rolling out r132736.
http://trac.webkit.org/changeset/132736
https://bugs.webkit.org/show_bug.cgi?id=100652

It broke all plugin related tests on GTK and on Qt (Requested
by Ossy on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-10-29

* wtf/text/WTFString.cpp:
(WTF::String::fromUTF8):

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

7 years ago[Chromium] Merge LocalizedNumberICUTest into LocaleICUTest
tkent@chromium.org [Mon, 29 Oct 2012 10:53:06 +0000 (10:53 +0000)]
[Chromium] Merge LocalizedNumberICUTest into LocaleICUTest
https://bugs.webkit.org/show_bug.cgi?id=100648

Reviewed by Kentaro Hara.

LocalizedNumberICU was removed some months ago, and its features were
merged to LocaleICU. We merge the test too.

* WebKit.gypi: Remove LocalizedNumberICUTest.cpp
* tests/LocaleICUTest.cpp:
Move a #if because some headers are used unconditionally.
(testDecimalSeparator): Moved from LocalizedNumberICUTest.cpp.
(TEST_F): Ditto.
(testNumberIsReversible): Ditto.
(testNumbers): Ditto.
* tests/LocalizedNumberICUTest.cpp: Removed.

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

7 years ago[Qt] Flaky security tests
allan.jensen@digia.com [Mon, 29 Oct 2012 10:52:29 +0000 (10:52 +0000)]
[Qt] Flaky security tests
https://bugs.webkit.org/show_bug.cgi?id=100388

Reviewed by Jocelyn Turcotte.

Tools:

Disable text output and load a blank URL to ensure the documentLoader is cleared
before we start dumping text for the new page. Otherwise messages from the old page
may end up in the text output of the new test.

* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore::DumpRenderTree::resetToConsistentStateBeforeTesting):

LayoutTests:

Unskip no longer flaky tests.

* platform/qt/TestExpectations:

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

7 years ago[chromium] remove remaining usages of webkit_support from the TestRunner library
jochen@chromium.org [Mon, 29 Oct 2012 10:50:29 +0000 (10:50 +0000)]
[chromium] remove remaining usages of webkit_support from the TestRunner library
https://bugs.webkit.org/show_bug.cgi?id=100344

Reviewed by Adam Barth.

The most important part is to not rely on calling out to gdk/X11 to
translate keycodes to hardware keycodes, as this is not possible inside
the sandbox.

* DumpRenderTree/DumpRenderTree.gypi:
* DumpRenderTree/chromium/DRTTestRunner.h:
(WebKit):
(webkit_support):
* DumpRenderTree/chromium/TestRunner/public/WebTestDelegate.h:
(WebTestDelegate):
* DumpRenderTree/chromium/TestRunner/src/CppVariant.h:
* DumpRenderTree/chromium/TestRunner/src/EventSender.cpp:
(WebTestRunner):
(WebTestRunner::EventSender::doDragDrop):
(WebTestRunner::EventSender::updateClickCountForButton):
(WebTestRunner::EventSender::mouseDown):
(WebTestRunner::EventSender::mouseUp):
(WebTestRunner::EventSender::mouseMoveTo):
(WebTestRunner::EventSender::keyDown):
(WebTestRunner::EventSender::replaySavedEvents):
(WebTestRunner::EventSender::contextClick):
(WebTestRunner::EventSender::beginDragWithFiles):
(WebTestRunner::EventSender::sendCurrentTouchEvent):
(WebTestRunner::EventSender::handleMouseWheel):
(WebTestRunner::EventSender::gestureEvent):
(WebTestRunner::EventSender::gestureFlingCancel):
(WebTestRunner::EventSender::gestureFlingStart):
* DumpRenderTree/chromium/TestRunner/src/KeyCodeMapping.cpp: Added.
(WebTestRunner):
(WebTestRunner::NativeKeyCodeForWindowsKeyCode):
* DumpRenderTree/chromium/TestRunner/src/KeyCodeMapping.h: Copied from Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.h.
(WebTestRunner):
* DumpRenderTree/chromium/TestRunner/src/TestDelegate.h:
(TestDelegate):
* DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp:
* DumpRenderTree/chromium/TestRunner/src/TestRunner.h:
* DumpRenderTree/chromium/TestRunner/src/WebTestInterfaces.cpp:
(WebTestInterfaces::Internal):
(WebTestRunner::WebTestInterfaces::Internal::getCurrentTimeInMillisecond):
(WebTestRunner):
(WebTestRunner::WebTestInterfaces::Internal::getAbsoluteWebStringFromUTF8Path):
* DumpRenderTree/chromium/WebViewHost.cpp:
(WebViewHost::getCurrentTimeInMillisecond):
(WebViewHost::getAbsoluteWebStringFromUTF8Path):
* DumpRenderTree/chromium/WebViewHost.h:
(WebViewHost):

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

7 years ago[WK2] Enable delegated scrolling as soon as the FrameView is created when using fixed...
jocelyn.turcotte@digia.com [Mon, 29 Oct 2012 10:28:01 +0000 (10:28 +0000)]
[WK2] Enable delegated scrolling as soon as the FrameView is created when using fixed layout
https://bugs.webkit.org/show_bug.cgi?id=100383

Reviewed by Kenneth Rohde Christiansen.

Scroll requests and PageTransitionViewportReady messages depend on
delegated scrolling being set properly on the FrameView to behave
properly. Since we were waiting for the viewport information to be
ready before setting the flag this could cause those messages to be avoided.

This patch takes most of the flag set by setResizesToContentsUsingLayoutSize
and apply them as soon as possible in WebPage::setUseFixedLayout and
WebFrameLoaderClient::transitionToCommittedForNewPage.

The behavior should be the same except for the following settings which are
now set outside of USE(TILED_BACKING_STORE) if we're using fixed layout:
- setAcceleratedCompositingForFixedPositionEnabled
- setFixedElementsLayoutRelativeToFrame
- setFixedPositionCreatesStackingContext

This fixes the tst_QQuickWebView::scrollRequest auto test and improves the
reliability of the loadVisuallyCommitted signal with pages loaded from disk.

* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::sendViewportAttributesChanged):
(WebKit::WebPage::setUseFixedLayout):
(WebKit::WebPage::setFixedLayoutSize):
* WebProcess/WebPage/WebPage.h:
(WebPage):

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

7 years ago2012-10-29 Pavel Podivilov <podivilov@google.com>
podivilov@chromium.org [Mon, 29 Oct 2012 10:07:16 +0000 (10:07 +0000)]
2012-10-29  Pavel Podivilov  <podivilov@google.com>

        [Chromium] Test expectation update.

        Unreviewed, mark recently added audiobuffersource-loop-points.html test as failing on windows.

        * platform/chromium/TestExpectations:

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

7 years ago[Chromium] Rename LocalizedDateICUTest.cpp to LocaleICUTest.cpp
tkent@chromium.org [Mon, 29 Oct 2012 09:44:33 +0000 (09:44 +0000)]
[Chromium] Rename LocalizedDateICUTest.cpp to LocaleICUTest.cpp
https://bugs.webkit.org/show_bug.cgi?id=100643

Reviewed by Kentaro Hara.

LocalizedDateICU was removed some months ago, and LocalizedDateICUTest
actually had tests for LocaleICU.

* WebKit.gypi:
* tests/LocaleICUTest.cpp:
- Renamed from Source/WebKit/chromium/tests/LocalizedDateICUTest.cpp.
- Rename LocalizedDateICUTest class to LocaleICUTest.

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

7 years agoMove LocaleWin.{cpp,h} to platform/text/win/
tkent@chromium.org [Mon, 29 Oct 2012 09:18:51 +0000 (09:18 +0000)]
Move LocaleWin.{cpp,h} to platform/text/win/
https://bugs.webkit.org/show_bug.cgi?id=100641

Reviewed by Kentaro Hara.

We have platform/text/win/ directory. Windows-specific files should be
in it.
Note that these files are used only in Chromium-win for now.

No new tests. This doesn't change any behavior.

* WebCore.gyp/WebCore.gyp: Fix path names.
* WebCore.gypi: Ditto.
* platform/text/win/LocaleWin.cpp: Renamed from Source/WebCore/platform/text/LocaleWin.cpp.
* platform/text/win/LocaleWin.h: Renamed from Source/WebCore/platform/text/LocaleWin.h.

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

7 years agoUnreviewed build fix after r132709.
rakuco@webkit.org [Mon, 29 Oct 2012 09:17:34 +0000 (09:17 +0000)]
Unreviewed build fix after r132709.

* Shared/WebMemorySampler.cpp: Include unistd.h for getpid(3).

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

7 years ago[Chromium-linux] Fix build.
tkent@chromium.org [Mon, 29 Oct 2012 09:11:08 +0000 (09:11 +0000)]
[Chromium-linux] Fix build.

* tests/LocalizedNumberICUTest.cpp:
(testNumberIsReversible): Rename an argument.
(testDecimalSeparator): Ditto.

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

7 years agoRename Localizer to Locale
tkent@chromium.org [Mon, 29 Oct 2012 08:51:17 +0000 (08:51 +0000)]
Rename Localizer to Locale
https://bugs.webkit.org/show_bug.cgi?id=100634

Reviewed by Kentaro Hara.

Source/WebCore:

- Rename Localizer class to Locale
- Rename localizer with locale in variable names
- Rename localizer with locale in function names

No new tests. This doesn't make any behavior changes.

* dom/Document.h:
(WebCore): Declare Locale instead of Localizer.
(Document):
- Rename getCachedLocalizer to getCachedLocale.
- Rename LocaleToLocalizerMap to LocaleIdentifierToLocaleMap.
- Rename m_localizerCache to m_localeCache.
* dom/Document.cpp:
(WebCore::Document::getCachedLocale): Follow renamings.
* dom/Element.h:
(WebCore): Declare Locale instead of Localizer.
(Element): Rename localizer() to locale().
* dom/Element.cpp:
(WebCore::Element::locale): Follow renamings.

* html/BaseDateAndTimeInputType.cpp:
(WebCore::BaseDateAndTimeInputType::localizeValue): Ditto.
(WebCore::BaseDateAndTimeInputType::convertFromVisibleValue): Ditto.
* html/BaseMultipleFieldsDateAndTimeInputType.cpp:
(WebCore::BaseMultipleFieldsDateAndTimeInputType::updateInnerTextValue): Ditto.
* html/DateInputType.cpp:
(WebCore::DateInputType::fixedPlaceholder): Ditto.
(WebCore::DateInputType::setupLayoutParameters): Ditto.
* html/DateTimeInputType.cpp:
(WebCore::DateTimeInputType::setupLayoutParameters): Ditto.
* html/DateTimeLocalInputType.cpp:
(WebCore::DateTimeLocalInputType::setupLayoutParameters): Ditto.
* html/MonthInputType.cpp:
(WebCore::MonthInputType::setupLayoutParameters): Ditto.
* html/NumberInputType.cpp:
(WebCore::NumberInputType::localizeValue): Ditto.
(WebCore::NumberInputType::convertFromVisibleValue): Ditto.
* html/TimeInputType.cpp:
(WebCore::TimeInputType::localizeValue): Ditto.
(WebCore::TimeInputType::setupLayoutParameters): Ditto.

* html/shadow/DateTimeEditElement.h:
(WebCore): Declare Locale instead of Localizer.
(LayoutParameters): Rename localizer data member to locale.
(WebCore::DateTimeEditElement::LayoutParameters::LayoutParameters): Follow renamings.
* html/shadow/DateTimeEditElement.cpp:
(WebCore::DateTimeEditBuilder::visitField): Ditto.
* html/shadow/DateTimeNumericFieldElement.h:
(DateTimeNumericFieldElement): Rename localizerForOwner to localeForOwner.
* html/shadow/DateTimeNumericFieldElement.cpp:
(WebCore::DateTimeNumericFieldElement::formatValue): Follow renamings.
(WebCore::DateTimeNumericFieldElement::handleKeyboardEvent): Ditto.
(WebCore::DateTimeNumericFieldElement::localeForOwner): Ditto.
* page/PagePopupClient.h:
(WebCore): Declare Locale instead of Localizer.
(PagePopupClient): Rename localizer member function to locale.
* page/PagePopupController.cpp:
(WebCore::PagePopupController::localizeNumberString): Follow renamings.

* platform/text/PlatformLocale.cpp: Rename the Localizer class to Locale.
(DateTimeStringBuilder):
(WebCore::DateTimeStringBuilder::DateTimeStringBuilder):
(WebCore::Locale::~Locale):
(WebCore::Locale::setLocaleData): Renamed from setLocalizerData.
(WebCore::Locale::convertToLocalizedNumber):
(WebCore::Locale::detectSignAndGetDigitRange):
(WebCore::Locale::matchedDecimalSymbolIndex):
(WebCore::Locale::convertFromLocalizedNumber):
(WebCore::Locale::localizedDecimalSeparator):
(WebCore::Locale::dateTimeFormatWithSeconds):
(WebCore::Locale::dateTimeFormatWithoutSeconds):
(WebCore::Locale::formatDateTime):
* platform/text/PlatformLocale.h: Update the ifndef macro.
(Locale): Renamed from Localizer. Also, renamed the followings:
 - initializeLocalizerData -> initializeLocaleData
 - setLocalizerData -> setLocaleData
 - m_hasLocalizerData -> m_hasLocaleData
(WebCore::Locale::Locale):
(WebCore::Locale::createDefault):
* platform/text/LocaleICU.cpp: Follow renamings.
* platform/text/LocaleICU.h: Ditto.
* platform/text/LocaleNone.cpp: Ditto.
* platform/text/LocaleWin.cpp: Ditto.
* platform/text/LocaleWin.h: Ditto.
* platform/text/mac/LocaleMac.h: Ditto.
* platform/text/mac/LocaleMac.mm: Ditto.

Source/WebKit/chromium:

* src/ColorChooserUIController.h:
(ColorChooserUIController):
Rename m_localizer to m_locale, and follow other renamings.
* src/ColorChooserUIController.cpp:
(WebKit::ColorChooserUIController::ColorChooserUIController): Follow renamings.
(WebKit::ColorChooserUIController::locale): Ditto.
* src/DateTimeChooserImpl.h:
(DateTimeChooserImpl):
Rename m_localizer to m_locale, and follow other renamings.
* src/DateTimeChooserImpl.cpp:
(WebKit::DateTimeChooserImpl::DateTimeChooserImpl): Follow renamings.
(WebKit::DateTimeChooserImpl::writeDocument): Ditto.
(WebKit::DateTimeChooserImpl::locale): Ditto.
* tests/LocaleMacTest.cpp:
(LocaleMacTest::formatTime): Ditto.
(testNumberIsReversible): Ditto.
* tests/LocalizedNumberICUTest.cpp:
(testNumberIsReversible): Ditto.
(testDecimalSeparator): Ditto.

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

7 years agoWeb Inspector: Error messages lines in console are 1px taller than regular messages
mkwst@chromium.org [Mon, 29 Oct 2012 08:49:49 +0000 (08:49 +0000)]
Web Inspector: Error messages lines in console are 1px taller than regular messages
https://bugs.webkit.org/show_bug.cgi?id=100521

Reviewed by Pavel Feldman.

The inspector is adding a 1px bottom border to list elements inside
a disclosure list. This is unnecessary in the current layout; it's
causing console messages with stack traces to be one pixel taller than
other console messages, which this patch fixes.

As a drive-by, this patch also adjusts the disclosure triangle's
position to match.

* inspector/front-end/inspector.css:
(.outline-disclosure li):
(.outline-disclosure li.parent::before):

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

7 years agoWeb Inspector: The bubble for repeated errors is misplaced.
mkwst@chromium.org [Mon, 29 Oct 2012 08:48:16 +0000 (08:48 +0000)]
Web Inspector: The bubble for repeated errors is misplaced.
https://bugs.webkit.org/show_bug.cgi?id=100525

Reviewed by Pavel Feldman.

The repeated-message bubble is displayed as an inline-block element,
which works well as long as no stack trace is present. If present, the
message is wrapped in an 'ol' element displayed as a block, which pushes
itself down to the next line.

To avoid that issue, this patch switches the wrapper element to flexbox,
glorious flexbox.

* inspector/front-end/inspector.css:
(.console-message .bubble):
(.repeated-message .outline-disclosure):
(.filter-all .console-log-level.repeated-message, .filter-logs .console-log-level.repeated-message):

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

7 years ago[Chromium] Test expectation update.
tkent@chromium.org [Mon, 29 Oct 2012 08:45:58 +0000 (08:45 +0000)]
[Chromium] Test expectation update.
https://bugs.webkit.org/show_bug.cgi?id=99818

The failure of month-multiple-fields-keyboard-events.html on SnowLeopard
and XP is expected.

- OS X SnowLeopard
  The month forma is "yyyy MMMM" on SnowLoepard though it's "MMMM yyyy"
  on other platforms.

- Windows XP
  It doesn't support the lang-attribute-aware-form-control-UI testing
feature.

* platform/chromium-mac-snowleopard/fast/forms/month-multiple-fields/month-multiple-fields-keyboard-events-expected.txt: Copied from LayoutTests/platform/chromium-win-xp/fast/forms/month-multiple-fields/month-multiple-fields-keyboard-events-expected.txt.
* platform/chromium-win-xp/fast/forms/month-multiple-fields/month-multiple-fields-keyboard-events-expected.txt:
* platform/chromium/TestExpectations:

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

7 years ago[EFL] Skip 2 tests failing due to missing drag'n drop support
commit-queue@webkit.org [Mon, 29 Oct 2012 08:36:21 +0000 (08:36 +0000)]
[EFL] Skip 2 tests failing due to missing drag'n drop support
https://bugs.webkit.org/show_bug.cgi?id=100638

Unreviewed EFL gardening.

Skip 2 test cases failing due to missing drag'n drop support
in EFL port.

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-10-29

* platform/efl/TestExpectations:

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

7 years ago[EFL] Skip 2 jquery tests crashing after r132757
commit-queue@webkit.org [Mon, 29 Oct 2012 08:34:00 +0000 (08:34 +0000)]
[EFL] Skip 2 jquery tests crashing after r132757
https://bugs.webkit.org/show_bug.cgi?id=100637

Unreviewed EFL gardening.

Skip 2 jquery test cases that started crashing after
r132757.

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-10-29

* platform/efl/TestExpectations:

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

7 years agoWeb Inspector: [Styles] Handle non-parsedOk properties as inactive ones
apavlov@chromium.org [Mon, 29 Oct 2012 08:30:38 +0000 (08:30 +0000)]
Web Inspector: [Styles] Handle non-parsedOk properties as inactive ones
https://bugs.webkit.org/show_bug.cgi?id=100119

Reviewed by Vsevolod Vlasov.

Source/WebCore:

Test: inspector/styles/inactive-properties.html

* inspector/front-end/StylesSidebarPane.js:
(WebInspector.StylesSidebarPane.createExclamationMark):
(WebInspector.ComputedStylePropertiesSection.prototype.rebuildComputedTrace):
* inspector/front-end/elementsPanel.css:
(.styles-section.computed-style .properties li.not-parsed-ok):
(.styles-section.computed-style .properties li.not-parsed-ok img.exclamation-mark):
(.styles-section .properties .not-parsed-ok):

LayoutTests:

* http/tests/inspector/elements-test.js:
(initialize_ElementTest.InspectorTest.dumpStyleTreeItem):
* inspector/styles/inactive-properties-expected.txt: Added.
* inspector/styles/inactive-properties.html: Added.

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

7 years agoTechnical Articles should link to an old talk I gave
eric@webkit.org [Mon, 29 Oct 2012 08:17:28 +0000 (08:17 +0000)]
Technical Articles should link to an old talk I gave
https://bugs.webkit.org/show_bug.cgi?id=100624

Reviewed by Adam Barth.

* coding/technical-articles.html:

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

7 years agoUnreviewed. Add jonathan.dong@torchmobile.com.cn as a committer.
jonathan.dong@torchmobile.com.cn [Mon, 29 Oct 2012 08:14:24 +0000 (08:14 +0000)]
Unreviewed. Add jonathan.dong@torchmobile.com.cn as a committer.
https://bugs.webkit.org/show_bug.cgi?id=100629

* Scripts/webkitpy/common/config/committers.py:

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

7 years ago[Qt] Unreviewed gardening.
kkristof@inf.u-szeged.hu [Mon, 29 Oct 2012 07:51:26 +0000 (07:51 +0000)]
[Qt] Unreviewed gardening.

Skip some tests because SHADOW_DOM is disabled on Qt.
Unskip another one that doesn't exist already.

Patch by Nandor Huszka <hnandor@inf.u-szeged.hu> on 2012-10-29

* platform/qt/TestExpectations:

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

7 years agoMake rendering tables with <colgroups> twice as fast by avoiding walking the DOM...
eric@webkit.org [Mon, 29 Oct 2012 07:38:01 +0000 (07:38 +0000)]
Make rendering tables with <colgroups> twice as fast by avoiding walking the DOM for colgroups 4 times for each cell
https://bugs.webkit.org/show_bug.cgi?id=100630

Reviewed by Ojan Vafai.

This is not a complete fix.  Our rendering of this large tables still takes 7.8 seconds
on my retina MBP (down from 14.3s before this change).
It's very expensive to walk the DOM each time we call RenderTable::colElement
so this caches the RenderTableCol* in a vector for easier walking.
We invalidate the cache any time a RenderTableCol is added or removed from the
rendering sub-tree to avoid holding a bad pointer.

* rendering/RenderTable.cpp:
(WebCore::RenderTable::RenderTable):
(WebCore::RenderTable::invalidateCachedColumns):
(WebCore):
(WebCore::RenderTable::addColumn):
(WebCore::RenderTable::removeColumn):
(WebCore::RenderTable::updateColumnCache):
(WebCore::RenderTable::slowColElement):
* rendering/RenderTable.h:
(RenderTable):
* rendering/RenderTableCol.cpp:
(WebCore::RenderTableCol::insertedIntoTree):
(WebCore):
(WebCore::RenderTableCol::willBeRemovedFromTree):
* rendering/RenderTableCol.h:

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

7 years agoUnreviewed. Rolled DEPS.
tkent@chromium.org [Mon, 29 Oct 2012 07:29:43 +0000 (07:29 +0000)]
Unreviewed.  Rolled DEPS.

* DEPS:

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

7 years agoRename Localizer.{cpp,h} to PlatformLocale.{cpp,h}
tkent@chromium.org [Mon, 29 Oct 2012 07:02:39 +0000 (07:02 +0000)]
Rename Localizer.{cpp,h} to PlatformLocale.{cpp,h}
https://bugs.webkit.org/show_bug.cgi?id=100627

Reviewed by Yuta Kitamura.

Source/WebCore:

We'd like to rename Localizer class to Locale class. However we use
PlatformLocale.cpp and PlatformLocale.h as their file names because
<locale.h> exists in the C standard.  In this patch, we rename only file
names. We're going to rename the class name later.

No new tests. This doesn't make any behavior change.

* platform/text/PlatformLocale.h: Renamed from Source/WebCore/platform/text/Localizer.h.
* platform/text/PlatformLocale.cpp: Renamed from Source/WebCore/platform/text/Localizer.cpp.
Follow the Localizer.h -> PlatformLocale.cpp renaming.

* CMakeLists.txt: Follow the file name renaming.
* GNUmakefile.list.am: Ditto.
* Target.pri: Ditto.
* WebCore.gypi: Ditto.
* WebCore.vcproj/WebCore.vcproj: Ditto.
* WebCore.xcodeproj/project.pbxproj: Ditto.
* dom/Document.cpp: Ditto.
* html/BaseDateAndTimeInputType.cpp: Ditto.
* html/BaseMultipleFieldsDateAndTimeInputType.cpp: Ditto.
* html/DateInputType.cpp: Ditto.
* html/DateTimeInputType.cpp: Ditto.
* html/DateTimeLocalInputType.cpp: Ditto.
* html/MonthInputType.cpp: Ditto.
* html/NumberInputType.cpp: Ditto.
* html/TimeInputType.cpp: Ditto.
* html/shadow/DateTimeEditElement.cpp: Ditto.
* html/shadow/DateTimeNumericFieldElement.cpp: Ditto.
* page/PagePopupController.cpp: Ditto.
* platform/text/LocaleICU.h: Ditto.
* platform/text/LocaleNone.cpp: Ditto.
* platform/text/LocaleWin.h: Ditto.
* platform/text/mac/LocaleMac.h: Ditto.

Source/WebKit/chromium:

* src/ColorChooserUIController.h: Follow the file name renaming.
* src/DateTimeChooserImpl.cpp: Ditto.

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

7 years ago[WK2] Fix the incorrect use of preprocessor statement in API header.
commit-queue@webkit.org [Mon, 29 Oct 2012 05:13:51 +0000 (05:13 +0000)]
[WK2] Fix the incorrect use of preprocessor statement in API header.
https://bugs.webkit.org/show_bug.cgi?id=100610

Patch by Byungwoo Lee <bw80.lee@samsung.com> on 2012-10-28
Reviewed by Timothy Hatcher.

Remove the preprocessor statement to check 'ENABLE_INSPECTOR' feature
from the WKPage.h.

* UIProcess/API/C/WKPage.cpp:
(WKPageGetInspector):
* UIProcess/API/C/WKPage.h:

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

7 years agoThe shadow element is not reprojected to a nested ShadowRoot.
shinyak@chromium.org [Mon, 29 Oct 2012 04:08:03 +0000 (04:08 +0000)]
The shadow element is not reprojected to a nested ShadowRoot.
https://bugs.webkit.org/show_bug.cgi?id=99228

Reviewed by Dimitri Glazkov.

Source/WebCore:

We support shadow reprojection; elements distributed to <shadow> element can be reprojected to <content> now.

First, we have a distribution vector for each InsertionPoint, even if InsertionPoint is a shadow insertion point.
And we update a node-distribution map. Basically We're creating a map from node to InsertionPoint in ElementShadow.
If a node can be distributed to several InsertionPoint (e.g. in case reprojection happens),
the InsertionPoint in older ShadowDOM is chosen.

We also fix ComposedShadowTreeWalker to consider shadow reprojection.

Tests: fast/dom/shadow/composed-shadow-tree-walker-shadow-reprojection.html
       fast/dom/shadow/shadow-reprojection-click.html
       fast/dom/shadow/shadow-reprojection-dynamic.html
       fast/dom/shadow/shadow-reprojection-fallback.html
       fast/dom/shadow/shadow-reprojection.html
       fast/dom/shadow/shadow-reprojection2.html

* css/StyleResolver.cpp:
(WebCore::shouldResetStyleInheritance): Now context.insertionPoint() returns the final insertion point where
a node is distributed. So we don't have to trace shadow insertion point anymore here.
(WebCore::StyleResolver::styleForElement): Since a direct child of ShadowRoot can be distributed now. In that case,
we don't have any parentElement. The parent node is a ShadowRoot in that case.
* dom/ComposedShadowTreeWalker.cpp:
(WebCore::nodeCanBeDistributed): If a node can be distributed, returns true.
(WebCore):
(WebCore::resolveReprojection): Resolves content-reprojection and shadow-reprojection both.
(WebCore::ComposedShadowTreeWalker::traverseSiblingOrBackToInsertionPoint):
(WebCore::ComposedShadowTreeWalker::traverseParent):
(WebCore::ComposedShadowTreeWalker::traverseParentBackToYoungerShadowRootOrHost): A case ShadowRoot is assigned
to some InsertionPoint should be handled with in traverseSiblingOrBackToInsertionPoint. So we remove it.
(WebCore::AncestorChainWalker::parent): Now we have a case that a direct child of ShadowRoot can be distributed.
In that case, we should not update m_distributedNode.
* dom/ElementShadow.cpp:
(WebCore::ElementShadow::insertionPointFor): Since we have a distribution vector for each InsertionPoint,
we don't have a special case that a ShadowRoot is assigned to some InsertionPoint. Actually the existing code
is not correct now due to shadow reprojection.
* html/shadow/ContentDistributor.cpp:
(WebCore::ContentDistributor::populate): Populate a POOL. If a node is InsertionPoint, we fill it with the
distributed nodes.
(WebCore):
(WebCore::ContentDistributor::distribute): Since we want to make a distribution vector for each InsertionPoint,
we have to resolve a shadow InsertionPoint
(WebCore::ContentDistributor::distributeNodeChildrenTo):
* html/shadow/ContentDistributor.h:
(ContentDistributor):
* html/shadow/HTMLShadowElement.h:
(WebCore::toHTMLShadowElement):
(WebCore):
* html/shadow/InsertionPoint.h:
(WebCore::parentNodeForDistribution):
(WebCore::parentElementForDistribution):
(WebCore):

LayoutTests:

* fast/dom/shadow/composed-shadow-tree-walker-shadow-reprojection-expected.txt: Added.
* fast/dom/shadow/composed-shadow-tree-walker-shadow-reprojection.html: Added. A walker test case for elements distributed
to shadow element are reprojected.
* fast/dom/shadow/composed-shadow-tree-walker.html:
* fast/dom/shadow/content-reprojection-complex.html:
* fast/dom/shadow/content-reprojection-fallback-expected.html:
* fast/dom/shadow/content-reprojection-fallback-reprojection-expected.html:
* fast/dom/shadow/shadow-reprojection-click-expected.txt: Added.
* fast/dom/shadow/shadow-reprojection-click.html: Added. Does some interactive with a shadow-reprojected node.
* fast/dom/shadow/shadow-reprojection-dynamic-expected.html: Added.
* fast/dom/shadow/shadow-reprojection-dynamic.html: Added. Adds dynamically elements shadow-reprojected.
* fast/dom/shadow/shadow-reprojection-expected.html: Added.
* fast/dom/shadow/shadow-reprojection-fallback-expected.html: Added.
* fast/dom/shadow/shadow-reprojection-fallback.html: Added. A test case for fallback elements of a shadow element
are reprojected.
* fast/dom/shadow/shadow-reprojection-prohibited-expected.html: Removed.
* fast/dom/shadow/shadow-reprojection-prohibited.html: Removed.
* fast/dom/shadow/shadow-reprojection.html: Added. A basic test case.
* fast/dom/shadow/shadow-reprojection2-expected.html: Added.
* fast/dom/shadow/shadow-reprojection2.html: Added. Another basic test case.

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

7 years agoDFG should be able to emit effectful structure checks
fpizlo@apple.com [Mon, 29 Oct 2012 04:02:08 +0000 (04:02 +0000)]
DFG should be able to emit effectful structure checks
https://bugs.webkit.org/show_bug.cgi?id=99260

Reviewed by Oliver Hunt.

This change allows us to find out if an array access that has gone polymorphic
is operating over known structures - i.e. the primordial array structures of the
global object that the code block containing the array access belongs to. We
term this state "OriginalArray" for short. The fact that the access has gone
polymorphic means that the array profile will not be able to report the set of
structures it had seen - but if it can tell us that all of the structures were
primordial then it just so happens that we can deduce what the structure set
would have been by just querying the code block's global object. This allows us
to emit an ArrayifyToStructure instead of an Arrayify if we find that we need to
do conversions. The fast path of an ArrayifyToStructure is exactly like the fast
path of a CheckStructure and is mostly subject to the same optimizations. It
also burns one fewer registers.

Essentially the notion of OriginalArray is a super cheap way of getting the
array profile to tell us a structure set instead of a singleton structure.
Currently, the array profile can only tell us the structure seen at an array
access if there was exactly one structure. If there were multiple structures, it
won't tell us anything other than the array modes and other auxiliary profiling
data (whether there were stores to holes, for example). With OriginalArray, we
cheaply get a structure set if all of the structures were primordial for the
code block's global object, since in that case the array mode set (ArrayModes)
can directly tell us the structure set. In the future, we might consider adding
complete structure sets to the array profiles, but I suspect that we would hit
diminishing returns if we did so - it would only help if we have array accesses
that are both polymorphic and are cross-global-object accesses (rare) or if the
arrays had named properties or other structure transitions that are unrelated to
indexing type (also rare).

This also does away with Arrayify (and the new ArrayifyToStructure) returning
the butterfly pointer. This turns out to be faster and easier to CSE.

And, this also changes constant folding to be able to eliminate CheckStructure,
ForwardCheckStructure, and ArrayifyToStructure in addition to being able to
transform them into structure transition watchpoints. This is great for
ArrayifyToStructure because then CSE and CFA know that there is no side effect.
Converting CheckStructure and ForwardCheckStructure to also behave this way is
just a matter of elegance.

This has no performance impact right now. It's intended to alleviate some of the
regressions seen in the early implementation of
https://bugs.webkit.org/show_bug.cgi?id=98606.

* bytecode/ArrayProfile.cpp:
(JSC::ArrayProfile::computeUpdatedPrediction):
* bytecode/ArrayProfile.h:
(JSC):
(JSC::ArrayProfile::ArrayProfile):
(ArrayProfile):
(JSC::ArrayProfile::usesOriginalArrayStructures):
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::updateAllPredictionsAndCountLiveness):
* dfg/DFGAbstractState.cpp:
(JSC::DFG::AbstractState::execute):
* dfg/DFGArrayMode.cpp:
(JSC::DFG::ArrayMode::fromObserved):
(JSC::DFG::ArrayMode::alreadyChecked):
(JSC::DFG::arrayClassToString):
* dfg/DFGArrayMode.h:
(JSC::DFG::ArrayMode::withProfile):
(JSC::DFG::ArrayMode::isJSArray):
(ArrayMode):
(JSC::DFG::ArrayMode::isJSArrayWithOriginalStructure):
(JSC::DFG::ArrayMode::supportsLength):
(JSC::DFG::ArrayMode::arrayModesWithIndexingShape):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::getArrayMode):
(JSC::DFG::ByteCodeParser::getArrayModeAndEmitChecks):
(JSC::DFG::ByteCodeParser::handleGetByOffset):
* dfg/DFGCSEPhase.cpp:
(JSC::DFG::CSEPhase::checkStructureElimination):
(JSC::DFG::CSEPhase::structureTransitionWatchpointElimination):
(JSC::DFG::CSEPhase::getPropertyStorageLoadElimination):
(JSC::DFG::CSEPhase::checkArrayElimination):
(JSC::DFG::CSEPhase::getScopeRegistersLoadElimination):
* dfg/DFGConstantFoldingPhase.cpp:
(JSC::DFG::ConstantFoldingPhase::foldConstants):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
(JSC::DFG::FixupPhase::checkArray):
* dfg/DFGNode.h:
(JSC::DFG::Node::hasStructure):
(JSC::DFG::Node::hasArrayMode):
(JSC::DFG::Node::arrayMode):
* dfg/DFGNodeType.h:
(DFG):
* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::propagate):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::jumpSlowForUnwantedArrayMode):
(JSC::DFG::SpeculativeJIT::arrayify):
* dfg/DFGSpeculativeJIT.h:
(SpeculativeJIT):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::isOriginalArrayStructure):
* runtime/Structure.cpp:
(JSC::Structure::nonPropertyTransition):

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

7 years agoWebkit adds a boundary to the Content-Type: text/plain POST header
commit-queue@webkit.org [Mon, 29 Oct 2012 02:50:52 +0000 (02:50 +0000)]
Webkit adds a boundary to the Content-Type: text/plain POST header
https://bugs.webkit.org/show_bug.cgi?id=100445

Patch by Kunihiko Sakamoto <ksakamoto@chromium.org> on 2012-10-28
Reviewed by Kent Tamura.

Source/WebCore:

Fixed a bug where an empty boundary parameter was added to Content-Type
header when POSTing forms with enctype=text/plain.

Test: http/tests/misc/form-post-textplain.html

* loader/FormSubmission.cpp:
(WebCore::FormSubmission::populateFrameLoadRequest): Add boundary parameter to
Content-Type only when a boundary string is generated.

LayoutTests:

Fixed test failure and added a test case for Content-Type header.

* http/tests/misc/form-post-textplain-expected.txt:
* http/tests/misc/form-post-textplain.html:
* http/tests/misc/resources/form-post-textplain.php:
Added a test case for testing Content-Type POST header.
Also fixed existing test case that attempted to test newline in the input value.
LF in the input value is replaced with CRLF durling the construction of the form data set.

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

7 years agoThere should not be blind spots in array length array profiling
fpizlo@apple.com [Mon, 29 Oct 2012 02:16:27 +0000 (02:16 +0000)]
There should not be blind spots in array length array profiling
https://bugs.webkit.org/show_bug.cgi?id=100620

Reviewed by Oliver Hunt.

I don't think this has any performance impact. But it's good to not have random
programs occasionally emit a GetById for array length accesses.

* jit/JITPropertyAccess.cpp:
(JSC::JIT::compileGetByIdHotPath):
(JSC::JIT::privateCompilePatchGetArrayLength):
* jit/JITPropertyAccess32_64.cpp:
(JSC::JIT::compileGetByIdHotPath):
(JSC::JIT::privateCompilePatchGetArrayLength):

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

7 years ago[Chromium] Test expectation update
tkent@chromium.org [Sun, 28 Oct 2012 23:39:16 +0000 (23:39 +0000)]
[Chromium] Test expectation update

Rebaseline for http://trac.webkit.org/changeset/132753

* platform/chromium-linux/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png:
* platform/chromium-mac-lion/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png:
* platform/chromium-mac-snowleopard/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png:
* platform/chromium-mac/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png:
* platform/chromium-win/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png:

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

7 years agoCache calcMode() value for SVG animations.
pdr@google.com [Sun, 28 Oct 2012 23:32:24 +0000 (23:32 +0000)]
Cache calcMode() value for SVG animations.
https://bugs.webkit.org/show_bug.cgi?id=99694

Reviewed by Eric Seidel.

This patch refactors SVGAnimationElement::calcMode() to return a cached value instead
of recalculating its value on every call. On a simple test of 100 rectangles with 100
animations each, calls to calcMode() account for 3% of the total animation. After this
patch, calcMode() no longer appears in animation profiles at all.

No new tests as this functionality is covered by existing tests.

* svg/SVGAnimateMotionElement.cpp:
(WebCore::SVGAnimateMotionElement::SVGAnimateMotionElement):

    The default calcMode for all animation types is linear except AnimateMotion,
    which defaults to CalcModePaced.
    See: http://www.w3.org/TR/SVG/single-page.html#animate-CalcModeAttribute

* svg/SVGAnimationElement.cpp:
(WebCore::SVGAnimationElement::SVGAnimationElement):
(WebCore::SVGAnimationElement::isSupportedAttribute):
(WebCore::SVGAnimationElement::parseAttribute):
(WebCore::SVGAnimationElement::setCalcMode):
* svg/SVGAnimationElement.h:
(WebCore::SVGAnimationElement::calcMode):
(WebCore::SVGAnimationElement::setCalcMode):
(SVGAnimationElement):

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

7 years agoGet rid of StyleResolver state related to unknown pseudo-elements.
dglazkov@chromium.org [Sun, 28 Oct 2012 22:35:33 +0000 (22:35 +0000)]
Get rid of StyleResolver state related to unknown pseudo-elements.
https://bugs.webkit.org/show_bug.cgi?id=100582

Reviewed by Eric Seidel.

All of the state, related to unknown pseudo-elements is already understood at the time of collecting rules.
We can just get rid of most of this code in StyleResolver.

At the time of matching rules, we know for certain that only rules that contain unknown pseudo-elements,
or are UA rules, or are explicitly invited by a TreeScope will match. So we can just return early in many cases.

No change in behavior, covered by existing tests.

* css/SelectorChecker.cpp:
(WebCore::SelectorChecker::checkSelector): Removed now-unnecessary param.
(WebCore::SelectorChecker::checkOneSelector): Ditto.
* css/SelectorChecker.h:
(SelectorChecker): Ditto.
* css/StyleResolver.cpp:
(WebCore::StyleResolver::StyleResolver): Ditto.
(MatchingUARulesScope): Moved class definition here, since we now use it in a different place.
(WebCore::StyleResolver::collectMatchingRules): Changed the logic to stop matching rules that definitely won't match in a different scope.
(WebCore::StyleResolver::collectMatchingRulesForList): Removed code that's now unnecesssary.
(WebCore::StyleResolver::checkSelector): Removed now-unnecessary param.
(WebCore::StyleResolver::checkRegionSelector): Removed weird dead code.
* css/StyleResolver.h:
(StyleResolver): Removed now-unnecessary member.

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

7 years agoUnreviewed, rolling out r132696.
commit-queue@webkit.org [Sun, 28 Oct 2012 21:42:58 +0000 (21:42 +0000)]
Unreviewed, rolling out r132696.
http://trac.webkit.org/changeset/132696
https://bugs.webkit.org/show_bug.cgi?id=100609

Needs a bit more clean-up on Chrome Web UI side. (Requested by
dglazkov on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-10-28

Source/WebCore:

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::updateFirstLetter):
* rendering/RenderListBox.h:
* rendering/RenderObjectChildList.cpp:
(WebCore::RenderObjectChildList::updateBeforeAfterContent):

LayoutTests:

* fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements-expected.html: Removed.
* fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements-expected.txt: Added.
* fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements.html:
* fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements-expected.html: Removed.
* fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements-expected.txt: Added.
* fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements.html:
* fast/forms/pseudo-elements-expected.html: Removed.
* fast/forms/pseudo-elements.html: Removed.
* fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements-expected.html: Removed.
* fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements-expected.txt: Added.
* fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements.html:
* fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.html: Removed.
* fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.txt: Added.
* fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements.html:
* platform/chromium-linux/fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-linux/fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-linux/fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-linux/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac-lion/fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements-expected.png:
* platform/chromium-mac-lion/fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac-lion/fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements-expected.png:
* platform/chromium-mac-lion/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png:
* platform/chromium-mac-snowleopard/fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac-snowleopard/fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac-snowleopard/fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac-snowleopard/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac/fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac/fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac/fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-mac/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-win/fast/forms/date-multiple-fields/date-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-win/fast/forms/month-multiple-fields/month-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-win/fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements-expected.png: Added.
* platform/chromium-win/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements-expected.png: Added.

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

7 years agoUnreviewed, make always-true enum-to-int comparisons use casts.
fpizlo@apple.com [Sun, 28 Oct 2012 21:36:50 +0000 (21:36 +0000)]
Unreviewed, make always-true enum-to-int comparisons use casts.

* dfg/DFGFPRInfo.h:
(JSC::DFG::FPRInfo::debugName):
* dfg/DFGGPRInfo.h:
(JSC::DFG::JSValueSource::tagGPR):
(JSC::DFG::GPRInfo::toIndex):
(JSC::DFG::GPRInfo::debugName):
* runtime/JSTypeInfo.h:
(JSC::TypeInfo::TypeInfo):

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

7 years ago[EFL][WK2][AC] Viewport size does not change when the window size changes
commit-queue@webkit.org [Sun, 28 Oct 2012 12:31:04 +0000 (12:31 +0000)]
[EFL][WK2][AC] Viewport size does not change when the window size changes
https://bugs.webkit.org/show_bug.cgi?id=100573

Patch by Yael Aharon <yael.aharon@intel.com> on 2012-10-28
Reviewed by Kenneth Rohde Christiansen.

The viewport size is set when we create the window the first time
and does not change automatically afterwards. When we change the window size,
we need to explicitly change the viewport size as well.

* UIProcess/API/efl/EwkViewImpl.cpp:
(EwkViewImpl::createGLSurface):

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

7 years ago[Chromium] Test expectation update
tkent@chromium.org [Sun, 28 Oct 2012 12:17:45 +0000 (12:17 +0000)]
[Chromium] Test expectation update
https://bugs.webkit.org/show_bug.cgi?id=100128

Rebaseline for http://trac.webkit.org/changeset/132718 and crrev.com/164515.

* platform/chromium-linux/fast/forms/week-multiple-fields/week-multiple-fields-appearance-basic-expected.png:
* platform/chromium-linux/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-classes-expected.png:
* platform/chromium-linux/fast/forms/week-multiple-fields/week-multiple-fields-appearance-style-expected.png:
* platform/chromium-mac-lion/fast/forms/week-multiple-fields/week-multiple-fields-appearance-basic-expected.png:
* platform/chromium-mac-lion/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-classes-expected.png:
* platform/chromium-mac-lion/fast/forms/week-multiple-fields/week-multiple-fields-appearance-style-expected.png:
* platform/chromium-mac-snowleopard/fast/forms/week-multiple-fields/week-multiple-fields-appearance-basic-expected.png:
* platform/chromium-mac-snowleopard/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-classes-expected.png:
* platform/chromium-mac-snowleopard/fast/forms/week-multiple-fields/week-multiple-fields-appearance-style-expected.png:
* platform/chromium-mac/fast/forms/week-multiple-fields/week-multiple-fields-appearance-basic-expected.png:
* platform/chromium-mac/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-classes-expected.png:
* platform/chromium-mac/fast/forms/week-multiple-fields/week-multiple-fields-appearance-style-expected.png:
* platform/chromium-win/fast/forms/week-multiple-fields/week-multiple-fields-appearance-basic-expected.png:
* platform/chromium-win/fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-classes-expected.png:
* platform/chromium-win/fast/forms/week-multiple-fields/week-multiple-fields-appearance-style-expected.png:
* platform/chromium/TestExpectations:

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

7 years agoOSR exit compilation should defend against argument recoveries from code blocks that...
fpizlo@apple.com [Sun, 28 Oct 2012 08:20:03 +0000 (08:20 +0000)]
OSR exit compilation should defend against argument recoveries from code blocks that are no longer on the inline stack
https://bugs.webkit.org/show_bug.cgi?id=100601

Reviewed by Oliver Hunt.

This happened to me while I was fixing bugs for https://bugs.webkit.org/show_bug.cgi?id=100599.
I'm not sure how to reproduce this.

* dfg/DFGAssemblyHelpers.h:
(JSC::DFG::AssemblyHelpers::baselineCodeBlockFor):
(AssemblyHelpers):
* dfg/DFGOSRExitCompiler32_64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):

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

7 years ago[Qt] Unreviewed weekend gardening, skip a failing test, update expected files.
ossy@webkit.org [Sun, 28 Oct 2012 07:06:59 +0000 (07:06 +0000)]
[Qt] Unreviewed weekend gardening, skip a failing test, update expected files.

* platform/qt-5.0-wk2/TestExpectations:
* platform/qt-5.0-wk2/compositing/tiling/crash-reparent-tiled-layer-expected.txt: Added.
* platform/qt-5.0-wk2/compositing/tiling/huge-layer-add-remove-child-expected.txt: Added.
* platform/qt-5.0-wk2/compositing/tiling/huge-layer-with-layer-children-expected.txt: Added.
* platform/qt-5.0-wk2/compositing/tiling/huge-layer-with-layer-children-resize-expected.txt: Added.
* platform/qt-5.0-wk2/http/tests/navigation/postredirect-basic-expected.txt: Added.
* platform/qt-5.0-wk2/http/tests/navigation/postredirect-goback1-expected.txt: Added.

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

7 years agoUnreviewed build fix for breakage to minimal bot caused by r132742.
ossy@webkit.org [Sun, 28 Oct 2012 06:47:02 +0000 (06:47 +0000)]
Unreviewed build fix for breakage to minimal bot caused by r132742.

Patch by Noam Rosenthal <noam.rosenthal@nokia.com> on 2012-10-27

* WebProcess/WebPage/LayerTreeHost.h:
(LayerTreeHost):
    Added appropriate ENABLE(REQUEST_ANIMATION_FRAME) flag.

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

7 years ago[Chromium] Find-in-page reports matches in hidden iframes
abarth@webkit.org [Sun, 28 Oct 2012 06:27:51 +0000 (06:27 +0000)]
[Chromium] Find-in-page reports matches in hidden iframes
https://bugs.webkit.org/show_bug.cgi?id=100604

Reviewed by Eric Seidel.

This is actually a regression caused by
http://trac.webkit.org/changeset/128784. This patch adds back some code
removed in WebFrameImpl::shouldScopeMatches in r128784.

This patch also introduces a test so that we don't make this mistake
again.

* src/WebFrameImpl.cpp:
(WebKit::WebFrameImpl::shouldScopeMatches):
* tests/WebFrameTest.cpp:
* tests/data/find_in_hidden_frame.html: Added.

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

7 years agoDFG::Array::Mode needs to be cleaned up
fpizlo@apple.com [Sun, 28 Oct 2012 06:13:23 +0000 (06:13 +0000)]
DFG::Array::Mode needs to be cleaned up
https://bugs.webkit.org/show_bug.cgi?id=100599

Reviewed by Oliver Hunt.

Turn the previous massive Array::Mode enum into a class that contains four
fields, the type, whether it's a JSArray, the level of speculation, and the
kind of conversion to perform.

No performance or behavioral change.

* dfg/DFGAbstractState.cpp:
(JSC::DFG::AbstractState::execute):
* dfg/DFGArgumentsSimplificationPhase.cpp:
(JSC::DFG::ArgumentsSimplificationPhase::run):
* dfg/DFGArrayMode.cpp:
(JSC::DFG::ArrayMode::fromObserved):
(JSC::DFG::ArrayMode::refine):
(JSC::DFG::ArrayMode::alreadyChecked):
(JSC::DFG::arrayTypeToString):
(JSC::DFG::arrayClassToString):
(DFG):
(JSC::DFG::arraySpeculationToString):
(JSC::DFG::arrayConversionToString):
(JSC::DFG::ArrayMode::toString):
* dfg/DFGArrayMode.h:
(DFG):
(ArrayMode):
(JSC::DFG::ArrayMode::ArrayMode):
(JSC::DFG::ArrayMode::type):
(JSC::DFG::ArrayMode::arrayClass):
(JSC::DFG::ArrayMode::speculation):
(JSC::DFG::ArrayMode::conversion):
(JSC::DFG::ArrayMode::asWord):
(JSC::DFG::ArrayMode::fromWord):
(JSC::DFG::ArrayMode::withSpeculation):
(JSC::DFG::ArrayMode::usesButterfly):
(JSC::DFG::ArrayMode::isJSArray):
(JSC::DFG::ArrayMode::isInBounds):
(JSC::DFG::ArrayMode::mayStoreToHole):
(JSC::DFG::ArrayMode::isOutOfBounds):
(JSC::DFG::ArrayMode::isSlowPut):
(JSC::DFG::ArrayMode::canCSEStorage):
(JSC::DFG::ArrayMode::lengthNeedsStorage):
(JSC::DFG::ArrayMode::modeForPut):
(JSC::DFG::ArrayMode::isSpecific):
(JSC::DFG::ArrayMode::supportsLength):
(JSC::DFG::ArrayMode::benefitsFromStructureCheck):
(JSC::DFG::ArrayMode::doesConversion):
(JSC::DFG::ArrayMode::arrayModesThatPassFiltering):
(JSC::DFG::ArrayMode::operator==):
(JSC::DFG::ArrayMode::operator!=):
(JSC::DFG::ArrayMode::arrayModesWithIndexingShape):
(JSC::DFG::canCSEStorage):
(JSC::DFG::lengthNeedsStorage):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::getArrayMode):
(JSC::DFG::ByteCodeParser::getArrayModeAndEmitChecks):
(JSC::DFG::ByteCodeParser::handleIntrinsic):
(JSC::DFG::ByteCodeParser::parseBlock):
* dfg/DFGCSEPhase.cpp:
(JSC::DFG::CSEPhase::getArrayLengthElimination):
(JSC::DFG::CSEPhase::checkArrayElimination):
(JSC::DFG::CSEPhase::getIndexedPropertyStorageLoadElimination):
(JSC::DFG::CSEPhase::performNodeCSE):
* dfg/DFGConstantFoldingPhase.cpp:
(JSC::DFG::ConstantFoldingPhase::foldConstants):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
(JSC::DFG::FixupPhase::checkArray):
(JSC::DFG::FixupPhase::blessArrayOperation):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dump):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::byValIsPure):
* dfg/DFGNode.h:
(JSC::DFG::Node::arrayMode):
(JSC::DFG::Node::setArrayMode):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::typedArrayDescriptor):
(JSC::DFG::SpeculativeJIT::jumpSlowForUnwantedArrayMode):
(JSC::DFG::SpeculativeJIT::checkArray):
(JSC::DFG::SpeculativeJIT::arrayify):
(JSC::DFG::SpeculativeJIT::compileGetByValOnString):
(JSC::DFG::SpeculativeJIT::compileGetByValOnIntTypedArray):
(JSC::DFG::SpeculativeJIT::compileGetByValOnFloatTypedArray):
(JSC::DFG::SpeculativeJIT::compilePutByValForFloatTypedArray):
(JSC::DFG::SpeculativeJIT::compileGetIndexedPropertyStorage):
(JSC::DFG::SpeculativeJIT::compileGetByValOnArguments):
(JSC::DFG::SpeculativeJIT::compileGetArgumentsLength):
(JSC::DFG::SpeculativeJIT::compileGetArrayLength):
(JSC::DFG::SpeculativeJIT::temporaryRegisterForPutByVal):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::putByValWillNeedExtraRegister):
(SpeculativeJIT):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):

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

7 years ago All tests crash in WebKit1 mode
ap@apple.com [Sun, 28 Oct 2012 06:10:56 +0000 (06:10 +0000)]
    All tests crash in WebKit1 mode
        https://bugs.webkit.org/show_bug.cgi?id=100602

        Reviewed by Sam Weinig.

        * WebView/WebView.mm: (+[WebView _setLoadResourcesSerially:]): Resource load
        scheduler is created via a strategy, so strategies need to be initialized before
        using it.

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

7 years agoUnreviewed, rolling out r132740.
weinig@apple.com [Sun, 28 Oct 2012 05:49:45 +0000 (05:49 +0000)]
Unreviewed, rolling out r132740.
http://trac.webkit.org/changeset/132740
https://bugs.webkit.org/show_bug.cgi?id=100603

"Causing many crashes" (Requested by weinig on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-10-27

* UIProcess/Downloads/DownloadProxy.cpp:
(WebKit::DownloadProxy::DownloadProxy):
(WebKit::DownloadProxy::invalidate):
(WebKit):
* UIProcess/Downloads/DownloadProxy.h:
(DownloadProxy):
* UIProcess/WebContext.cpp:
(WebKit::WebContext::createDownloadProxy):
(WebKit::WebContext::downloadFinished):
(WebKit::WebContext::didReceiveMessage):
(WebKit::WebContext::didReceiveSyncMessage):
* UIProcess/WebContext.h:
(WebKit):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy):
(WebKit::WebPageProxy::~WebPageProxy):
(WebKit::WebPageProxy::didReceiveMessage):
(WebKit::WebPageProxy::didReceiveSyncMessage):
* UIProcess/WebPageProxy.h:
(CoreIPC):
(WebPageProxy):
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::didReceiveMessage):
(WebKit::WebProcessProxy::didReceiveSyncMessage):
* UIProcess/WebProcessProxy.h:
(WebProcessProxy):
* WebProcess/WebPage/WebPageGroupProxy.cpp:
(WebKit::WebPageGroupProxy::~WebPageGroupProxy):
(WebKit):
(WebKit::WebPageGroupProxy::didReceiveMessage):
(WebKit::WebPageGroupProxy::WebPageGroupProxy):
* WebProcess/WebPage/WebPageGroupProxy.h:
(CoreIPC):
(WebPageGroupProxy):
* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::didReceiveSyncMessage):
(WebKit::WebProcess::didReceiveMessage):

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

7 years agoCoordinated Graphics: Animation jerkiness when rAF is enabled
noam.rosenthal@nokia.com [Sun, 28 Oct 2012 01:32:58 +0000 (01:32 +0000)]
Coordinated Graphics: Animation jerkiness when rAF is enabled
https://bugs.webkit.org/show_bug.cgi?id=100536

Reviewed by Kenneth Rohde Christiansen.

Source/WebKit2:

The jerkiness comes from the fact that we schedule animations excessively; That's because
the previous patch broke requestAnimationFrame behavior during CSS animations, since the
frame returns right away instead of waiting till the previous frame is actually rendered.

This patch makes sure that when animations are scheduled, they're only serviced after the
UI process has actually painted the previous frame. We do so by sending a
RequestAnimationFrame message to the UI process, which responds with AnimationFrameReady
after the UI process paints.

New test: fast/animations/request-animation-frame-too-rapid.html
Tests that we don't receive an unreasonably high number of callbacks from
requestAnimationFrame (> 1000FPS).

* UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.cpp:
(WebKit):
(WebKit::LayerTreeCoordinatorProxy::requestAnimationFrame):
(WebKit::LayerTreeCoordinatorProxy::animationFrameReady):
* UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.h:
(LayerTreeCoordinatorProxy):
* UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.messages.in:
* UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
(WebKit::LayerTreeRenderer::LayerTreeRenderer):
(WebKit::LayerTreeRenderer::paintToCurrentGLContext):
(WebKit):
(WebKit::LayerTreeRenderer::animationFrameReady):
(WebKit::LayerTreeRenderer::requestAnimationFrame):
* UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
(LayerTreeRenderer):
* WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
(WebKit):
(WebKit::LayerTreeCoordinator::scheduleAnimation):
(WebKit::LayerTreeCoordinator::animationFrameReady):
* WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.h:
(LayerTreeCoordinator):
* WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.messages.in:

LayoutTests:

Added a test to make sure we don't respond too eagerly to requestAnimationFrame.

* fast/animation/request-animation-frame-too-rapid-expected.txt: Added.
* fast/animation/request-animation-frame-too-rapid.html: Added.
* fast/animation/script-tests/request-animation-frame-too-rapid.js: Added.

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

7 years agoFix AVFoundation build.
andersca@apple.com [Sun, 28 Oct 2012 01:31:06 +0000 (01:31 +0000)]
Fix AVFoundation build.

* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::addKey):

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

7 years agoYet more MessageReceivering
weinig@apple.com [Sat, 27 Oct 2012 20:48:52 +0000 (20:48 +0000)]
Yet more MessageReceivering
https://bugs.webkit.org/show_bug.cgi?id=100325

Reviewed by Anders Carlsson.

Make DownloadProxy, WebPageProxy, and WebPageGroupProxy MessageReceivers.

* UIProcess/Downloads/DownloadProxy.cpp:
(WebKit::DownloadProxy::DownloadProxy):
(WebKit::DownloadProxy::invalidate):
(WebKit::DownloadProxy::didReceiveMessage):
(WebKit::DownloadProxy::didReceiveSyncMessage):
* UIProcess/Downloads/DownloadProxy.h:
(DownloadProxy):
Make a MessageReceiver.

* UIProcess/WebContext.cpp:
(WebKit::WebContext::WebContext):
(WebKit::WebContext::addMessageReceiver):
(WebKit::WebContext::removeMessageReceiver):
(WebKit::WebContext::didReceiveMessage):
(WebKit::WebContext::didReceiveSyncMessage):
* UIProcess/WebContext.h:
Add additional MessageReceiverMap forwards, and stop dealing with DownloadProxy explicitly.

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy):
(WebKit::WebPageProxy::~WebPageProxy):
(WebKit::WebPageProxy::didReceiveMessage):
(WebKit::WebPageProxy::didReceiveSyncMessage):
* UIProcess/WebPageProxy.h:
Make a MessageReceiver, but keep sub objects using didReceiveMessage for now (like WebPage).

* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::addMessageReceiver):
(WebKit::WebProcessProxy::removeMessageReceiver):
(WebKit::WebProcessProxy::didReceiveMessage):
(WebKit::WebProcessProxy::didReceiveSyncMessage):
* UIProcess/WebProcessProxy.h:
Give WebProcessProxy a MessageReceiverMap and all the appropriate forwarding methods.

* WebProcess/WebPage/WebPageGroupProxy.cpp:
(WebKit::WebPageGroupProxy::WebPageGroupProxy):
(WebKit::WebPageGroupProxy::~WebPageGroupProxy):
(WebKit::WebPageGroupProxy::didReceiveMessage):
* WebProcess/WebPage/WebPageGroupProxy.h:
(WebKit::WebPageGroupProxy::isVisibleToHistoryClient):
(WebPageGroupProxy):
Make a MessageReceiver and register/unregister with the WebProcess.

* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::didReceiveSyncMessage):
Remove extraneous return statement.
(WebKit::WebProcess::didReceiveMessage):
Stop handling WebPageGroupProxy special.

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

7 years agoTry to create AtomicString as 8 bit where possible
msaboff@apple.com [Sat, 27 Oct 2012 20:33:17 +0000 (20:33 +0000)]
Try to create AtomicString as 8 bit where possible
https://bugs.webkit.org/show_bug.cgi?id=100575

Reviewed by Oliver Hunt.

Added StringImpl::create8BitIfPossible() that first tries to create an 8 bit string.  If it finds a 16 bit character
during processing, it calls the standard create() method.  The assumption is that this will be used on mostly 8 bit
strings and ones that are shorter (in the tens of characters).  Changed AtomicString to use the new creation method
for UChar based construction.

* wtf/text/AtomicString.cpp:
(WTF::UCharBufferTranslator::translate):
* wtf/text/StringImpl.cpp:
(WTF::StringImpl::create8BitIfPossible):
* wtf/text/StringImpl.h:
(WTF::StringImpl::create8BitIfPossible):

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

7 years agoCompletely roll out https://bugs.webkit.org/show_bug.cgi?id=99251 (r131686)
weinig@apple.com [Sat, 27 Oct 2012 20:31:04 +0000 (20:31 +0000)]
Completely roll out https://bugs.webkit.org/show_bug.cgi?id=99251 (r131686)

It has caused too many crashes.

* UIProcess/API/mac/PageClientImpl.mm:
* UIProcess/API/mac/WKView.mm:
* UIProcess/API/mac/WKViewInternal.h:
* UIProcess/API/mac/WKViewPrivate.h:
* UIProcess/mac/CorrectionPanel.mm:
* UIProcess/mac/WKFullScreenWindowController.mm:
* UIProcess/mac/WebFullScreenManagerProxyMac.mm:

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

7 years agoASSERTION FAILED: m_next in LayoutState.cpp
dbarton@mathscribe.com [Sat, 27 Oct 2012 18:27:58 +0000 (18:27 +0000)]
ASSERTION FAILED: m_next in LayoutState.cpp
https://bugs.webkit.org/show_bug.cgi?id=99796

Reviewed by Eric Seidel.

Before RenderMathMLBlock::computeChildrenPreferredLogicalHeights calls child->layoutIfNeeded(),
it must ensure a layoutState exists. We disable it in any case, since we are just calculating
metrics here, and the final layout may well happen again.

No new tests. I don't know how to create an automated test for this. The crashes users are
seeing are flaky.

* rendering/mathml/RenderMathMLBlock.cpp:
(WebCore::RenderMathMLBlock::computeChildrenPreferredLogicalHeights):

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

7 years agoString::fromUTF8() should take advantage of the ASCII check in convertUTF8ToUTF16()
msaboff@apple.com [Sat, 27 Oct 2012 18:25:56 +0000 (18:25 +0000)]
String::fromUTF8() should take advantage of the ASCII check in convertUTF8ToUTF16()
https://bugs.webkit.org/show_bug.cgi?id=100577

Reviewed by Oliver Hunt.

Passed is ASCII flag to convertUTF8ToUTF16() and if try, create an 8 bit string from the original arguments.

* wtf/text/WTFString.cpp:
(WTF::String::fromUTF8):

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

7 years ago[MathML] Improve some addChild methods
dbarton@mathscribe.com [Sat, 27 Oct 2012 18:18:34 +0000 (18:18 +0000)]
[MathML] Improve some addChild methods
https://bugs.webkit.org/show_bug.cgi?id=98791

Reviewed by Eric Seidel.

Source/WebCore:

MathML addChild methods need to handle any anonymous renderers correctly. Actually, most MathML elements have a fixed
number of children, so conformant javascript won't be doing arbitrary addChild and removeChild calls. However, we don't
want any assertions to fail, and we do want addChild to work correctly when beforeChild == 0, to build up the original
renderer, and then replaceChild at least should work correctly after that. We therefore clean up these routines before
giving them to the chromium fuzzers.

It's best to build the anonymous wrappers just once initially if possible, so empty wrappers aren't left in the render
tree after later removeChild calls.

Test: mathml/presentation/dynamic.html added for mfrac and msqrt. There are already tests for dynamically changing
msub/sup elements, in mathml/presentation/m*-changed.xhtml.

* rendering/mathml/RenderMathMLFraction.cpp:
(WebCore::RenderMathMLFraction::addChild):
    - The two wrappers are built initially. Also, the old RenderMathMLBlock::addChild(row, beforeChild); doesn't really
      work because beforeChild is buried inside a wrapper. This new routine allows the numerator and denominator to be
      added initially, and then later replaced with replaceChild. It's not clear whether e.g. a plain removeChild of a
      numerator should move the remaining child from the denominator to the numerator or not, so we ignore that for now.
* rendering/mathml/RenderMathMLRoot.cpp:
(WebCore::RenderMathMLRoot::addChild):
    - A bit of bullet-proofing for the fuzzers.
* rendering/mathml/RenderMathMLSubSup.cpp:
(WebCore::RenderMathMLSubSup::addChild):
    - Like RenderMathMLFraction::addChild, we create the wrappers once initially, and then fill them dynamically.

LayoutTests:

* mathml/presentation/dynamic-expected.html: Added.
* mathml/presentation/dynamic.html: Added.

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

7 years agobuildHTTPHeaders() should use a StringBuilder instead of a Vector<UChar>
msaboff@apple.com [Sat, 27 Oct 2012 18:17:30 +0000 (18:17 +0000)]
buildHTTPHeaders() should use a StringBuilder instead of a Vector<UChar>
https://bugs.webkit.org/show_bug.cgi?id=100580

Reviewed by Oliver Hunt.

Replaced Vector<UChar> with StringBuilder in the HTTP header construction function buildHTTPHeaders.
This eliminates 8 -> 16 bit up conversion of the strings involved.

* WebProcess/Plugins/PluginView.cpp:
(WebKit::buildHTTPHeaders):

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

7 years agoUnreviewed gardening.
kbalazs@webkit.org [Sat, 27 Oct 2012 18:16:01 +0000 (18:16 +0000)]
Unreviewed gardening.

Removing my garbage, now from svn.

* platform/qt-5.0-wk2/fast/images/png-suite/test-expected.png: Removed.

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

7 years agoUnreviewed gardening.
kbalazs@webkit.org [Sat, 27 Oct 2012 17:22:06 +0000 (17:22 +0000)]
Unreviewed gardening.

Added one more png to a wrong path in my previous commit, removing it and hoping that
the directory will not stay in svn.

* platform/qt-5.0-wk2/fast/images/png-suite/test-expected.png/test-expected.png: Removed.

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

7 years agoBackground images can incorrectly repeat with sub-pixel layout
leviw@chromium.org [Sat, 27 Oct 2012 17:18:12 +0000 (17:18 +0000)]
Background images can incorrectly repeat with sub-pixel layout
https://bugs.webkit.org/show_bug.cgi?id=94622

Reviewed by Emil A Eklund.

Source/WebCore:

Attempting to better match author expectations when painting tiled background images. When under
the effects of zoom with sub-pixel layout enabled, the drawn size of a rendered element can
differ depending on its location. This change looks at the size of the scaled tiled background
image size, and either ceils or floors that value depending on if tiling that value will
result in us being one pixel or less short of covering the background size. This is a heuristic,
as sub-pixel/zooming isn't specced.

Test: fast/sub-pixel/scaled-background-image.html

* rendering/RenderBoxModelObject.cpp:
(WebCore::applySubPixelHeuristicForTileSize):
(WebCore):
(WebCore::RenderBoxModelObject::calculateFillTileSize):

LayoutTests:

* fast/sub-pixel/scaled-background-image-expected.html: Added.
* fast/sub-pixel/scaled-background-image.html: Added.

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

7 years agoUnreviewed, rolling out r132725.
loislo@chromium.org [Sat, 27 Oct 2012 17:15:47 +0000 (17:15 +0000)]
Unreviewed, rolling out r132725.
http://trac.webkit.org/changeset/132725
https://bugs.webkit.org/show_bug.cgi?id=100596

it broke linking on chromium debug bots (Requested by loislo
on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-10-27

* inspector/InspectorMemoryAgent.cpp:
(WebCore::addPlatformComponentsInfo):
(WebCore):
(WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
* platform/MemoryUsageSupport.cpp:
(WebCore::MemoryUsageSupport::memoryUsageByComponents):
* platform/MemoryUsageSupport.h:
(ComponentInfo):
(WebCore::MemoryUsageSupport::ComponentInfo::ComponentInfo):
(MemoryUsageSupport):
* platform/PlatformMemoryInstrumentation.cpp:
(WebCore):
* platform/PlatformMemoryInstrumentation.h:
(PlatformMemoryTypes):
* platform/chromium/MemoryUsageSupportChromium.cpp:
(WebCore::MemoryUsageSupport::memoryUsageByComponents):
* platform/qt/MemoryUsageSupportQt.cpp:
(WebCore::MemoryUsageSupport::memoryUsageByComponents):

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

7 years agoREAL_PLATFORM_NAME build setting is no longer needed
mitz@apple.com [Sat, 27 Oct 2012 16:14:53 +0000 (16:14 +0000)]
REAL_PLATFORM_NAME build setting is no longer needed
https://bugs.webkit.org/show_bug.cgi?id=100587

Reviewed by Mark Rowe.

Removed the definition of REAL_PLATFORM_NAME and replaced references to it with references
to PLATFORM_NAME.

Source/JavaScriptCore:

* Configurations/Base.xcconfig:
* Configurations/CompilerVersion.xcconfig:
* Configurations/DebugRelease.xcconfig:
* Configurations/FeatureDefines.xcconfig:
* Configurations/JSC.xcconfig:
* Configurations/JavaScriptCore.xcconfig:
* Configurations/ToolExecutable.xcconfig:

Source/ThirdParty:

* gtest/xcode/Config/CompilerVersion.xcconfig:
* gtest/xcode/Config/General.xcconfig:

Source/ThirdParty/ANGLE:

* Configurations/Base.xcconfig:
* Configurations/CompilerVersion.xcconfig:

Source/WebCore:

* Configurations/Base.xcconfig:
* Configurations/CompilerVersion.xcconfig:
* Configurations/DebugRelease.xcconfig:
* Configurations/FeatureDefines.xcconfig:
* Configurations/Version.xcconfig:
* Configurations/WebCore.xcconfig:

Source/WebKit/mac:

* Configurations/Base.xcconfig:
* Configurations/CompilerVersion.xcconfig:
* Configurations/DebugRelease.xcconfig:
* Configurations/FeatureDefines.xcconfig:
* Configurations/Version.xcconfig:
* Configurations/WebKit.xcconfig:

Source/WebKit2:

* Configurations/Base.xcconfig:
* Configurations/BaseTarget.xcconfig:
* Configurations/CompilerVersion.xcconfig:
* Configurations/FeatureDefines.xcconfig:
* Configurations/WebKit2.xcconfig:

Source/WTF:

* Configurations/Base.xcconfig:
* Configurations/CompilerVersion.xcconfig:
* Configurations/DebugRelease.xcconfig:

Tools:

* DumpRenderTree/mac/Configurations/Base.xcconfig:
* DumpRenderTree/mac/Configurations/CompilerVersion.xcconfig:
* DumpRenderTree/mac/Configurations/DebugRelease.xcconfig:
* MiniBrowser/Configurations/Base.xcconfig:
* MiniBrowser/Configurations/CompilerVersion.xcconfig:
* TestWebKitAPI/Configurations/Base.xcconfig:
* TestWebKitAPI/Configurations/CompilerVersion.xcconfig:
* WebKitTestRunner/Configurations/Base.xcconfig:
* WebKitTestRunner/Configurations/CompilerVersion.xcconfig:
* WebKitTestRunner/Configurations/DebugRelease.xcconfig:

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

7 years agoPixel tests need rebaseline https://bugs.webkit.org/show_bug.cgi?id=99323
kbalazs@webkit.org [Sat, 27 Oct 2012 16:07:03 +0000 (16:07 +0000)]
Pixel tests need rebaseline https://bugs.webkit.org/show_bug.cgi?id=99323

Unreviewed gardening.

Reland Qt-WebKit2 new expectations part 2 with fixed paths.

* platform/qt-5.0-wk2/fullscreen/full-screen-iframe-zIndex-expected.png: Added.
* platform/qt-5.0-wk2/fullscreen/full-screen-remove-ancestor-after-expected.png: Added.
* platform/qt-5.0-wk2/fullscreen/full-screen-stacking-context-expected.png: Added.
* platform/qt-5.0-wk2/fullscreen/full-screen-zIndex-after-expected.png: Added.
* platform/qt-5.0-wk2/fullscreen/full-screen-zIndex-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-appendItem-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-basics-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-getItem-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-initialize-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-insertItemBefore-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-removeItem-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-replaceItem-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLengthList-xml-dom-modifications-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGLocatable-getCTM-svg-root-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGNumberList-basics-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGPathSegList-appendItem-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGPathSegList-clear-and-initialize-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGPathSegList-insertItemBefore-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGPathSegList-removeItem-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGPathSegList-replaceItem-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGPathSegList-xml-dom-synchronization-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGPointList-basics-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGStringList-basics-expected.png: Added.
* platform/qt-5.0-wk2/svg/dom/SVGTransformList-basics-expected.png: Added.
* platform/qt-5.0-wk2/svg/filters/feImage-animated-transform-on-target-rect-expected.png: Added.
* platform/qt-5.0-wk2/svg/repaint/image-href-change-expected.png: Added.
* platform/qt-5.0-wk2/svg/repaint/image-with-clip-path-expected.png: Added.

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

7 years agoPixel tests need rebaseline https://bugs.webkit.org/show_bug.cgi?id=99323
kbalazs@webkit.org [Sat, 27 Oct 2012 16:05:47 +0000 (16:05 +0000)]
Pixel tests need rebaseline https://bugs.webkit.org/show_bug.cgi?id=99323

Unreviewed gardening.

Reland Qt-WebKit2 new expectations part 1 with fixed paths.

* platform/qt-5.0-wk2/css3/filters/filter-empty-element-crash-expected.png: Added.
* platform/qt-5.0-wk2/css3/filters/multiple-filters-invalidation-expected.png: Added.
* platform/qt-5.0-wk2/css3/flexbox/repaint-expected.png: Added.
* platform/qt-5.0-wk2/css3/flexbox/repaint-rtl-column-expected.png: Added.
* platform/qt-5.0-wk2/fast/borders/border-shadow-large-radius-expected.png: Added.
* platform/qt-5.0-wk2/fast/borders/outline-alpha-block-expected.png: Added.
* platform/qt-5.0-wk2/fast/borders/outline-alpha-inline-expected.png: Added.
* platform/qt-5.0-wk2/fast/box-shadow/box-shadow-clipped-slices-expected.png: Added.
* platform/qt-5.0-wk2/fast/box-shadow/no-blur-multiple-offsets-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/canvas-composite-fill-repaint-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/canvas-composite-transformclip-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/canvas-empty-image-pattern-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/canvas-imageSmoothingEnabled-patterns-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/canvas-resize-after-paint-without-layout-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/canvas-resize-reset-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/canvas-transforms-during-path-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/gradient-add-second-start-end-stop-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/image-pattern-rotate-expected.png: Added.
* platform/qt-5.0-wk2/fast/canvas/toDataURL-alpha-expected.png: Added.
* platform/qt-5.0-wk2/fast/css/border-radius-non-negative-expected.png: Added.
* platform/qt-5.0-wk2/fast/css/linear-gradient-currentcolor-expected.png: Added.
* platform/qt-5.0-wk2/fast/forms/datalist/input-appearance-range-with-datalist-expected.png: Added.
* platform/qt-5.0-wk2/fast/forms/datalist/input-appearance-range-with-datalist-zoomed-expected.png: Added.
* platform/qt-5.0-wk2/fast/forms/datalist/input-appearance-range-with-padding-with-datalist-expected.png: Added.
* platform/qt-5.0-wk2/fast/forms/datalist/input-appearance-range-with-transform-expected.png: Added.
* platform/qt-5.0-wk2/fast/forms/file/file-input-pressed-state-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-color-stop-units-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-color-stops-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-linear-angle-gradients-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-linear-right-angle-gradients-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-radial-gradients-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-radial-gradients2-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-radial-gradients3-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-repeating-linear-gradients-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-repeating-linear-gradients2-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/css3-repeating-radial-gradients-expected.png: Added.
* platform/qt-5.0-wk2/fast/gradients/gradient-after-transparent-border-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/jpeg-with-color-profile-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/paint-subrect-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/paint-subrect-grid-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/png-suite/test-expected.png/test-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/png-with-color-profile-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/rgb-jpeg-with-adobe-marker-only-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/rgb-png-with-cmyk-color-profile-expected.png: Added.
* platform/qt-5.0-wk2/fast/images/ycbcr-with-cmyk-color-profile-expected.png: Added.
* platform/qt-5.0-wk2/fast/layers/scroll-with-transform-composited-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/layers/scroll-with-transform-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/absolute-position-changed-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/fixed-and-absolute-position-scrolled-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/fixed-position-transparency-with-overflow-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/nested-iframe-scroll-inner-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/nested-iframe-scroll-outer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/overflow-auto-in-overflow-auto-scrolled-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/overflow-hide-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/overflow-scroll-in-overflow-scroll-scrolled-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/overflow-show-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-absolute-layer-with-reflection-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-fixed-layer-with-no-visible-content-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-fixed-layer-with-reflection-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-fixed-layer-with-transformed-parent-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-fixed-reflected-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-in-clipped-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-in-fixed-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-in-transformed-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-inside-table-cell-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-relative-table-inside-table-cell-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/scroll-with-transformed-parent-layer-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/table-overflow-auto-in-overflow-auto-scrolled-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/table-overflow-hidden-in-overflow-hidden-scrolled-expected.png: Added.
* platform/qt-5.0-wk2/fast/repaint/table-overflow-scroll-in-overflow-scroll-scrolled-expected.png: Added.
* platform/qt-5.0-wk2/fast/replaced/outline-replaced-elements-expected.png: Added.
* platform/qt-5.0-wk2/fast/scrolling/scrollbar-tickmarks-styled-expected.png: Added.
* platform/qt-5.0-wk2/fast/table/border-collapsing/collapsed-border-with-col-colgroup-span-expected.png: Added.
* platform/qt-5.0-wk2/fast/table/table-row-focus-ring-paint-expected.png: Added.

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

7 years agoRemove internals shouldDisplayTrackKind methods; these are also on internals.settings
tony@chromium.org [Sat, 27 Oct 2012 15:13:49 +0000 (15:13 +0000)]
Remove internals shouldDisplayTrackKind methods; these are also on internals.settings
https://bugs.webkit.org/show_bug.cgi?id=100564

Reviewed by Adam Barth.

Source/WebCore:

Remove duplicate methods from internals that was just forwarding on the call to internals.settings.
Also fix a bug where we didn't reset these settings properly.

No new tests, this is covered by existing media/track tests.

* testing/InternalSettings.cpp:
(WebCore::InternalSettings::Backup::Backup): Properly save display track settings.
(WebCore::InternalSettings::Backup::restoreTo): Restore display track settings.
* testing/InternalSettings.h:
* testing/InternalSettings.idl: Use [Conditional=VIDEO_TRACK].
* testing/Internals.cpp: Remove code.
* testing/Internals.h: Remove code.
* testing/Internals.idl: Remove code.

LayoutTests:

Update tests to use the internals.settings method.

* media/track/track-language-preference-expected.txt:
* media/track/track-language-preference.html:
* media/track/track-prefer-captions-expected.txt:
* media/track/track-prefer-captions.html:

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

7 years agoWeb Inspector: instrument chromium GlyphCache. It keeps ~2mb.
loislo@chromium.org [Sat, 27 Oct 2012 15:11:30 +0000 (15:11 +0000)]
Web Inspector: instrument chromium GlyphCache. It keeps ~2mb.
https://bugs.webkit.org/show_bug.cgi?id=100515

Reviewed by Yury Semikhatsky.

I replaced old version with an abstract number with new one which precisely reports allocated SkGlyphCache objects and their sizes.

* inspector/InspectorMemoryAgent.cpp:
(WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
* platform/MemoryUsageSupport.cpp:
(WebCore::MemoryUsageSupport::reportMemoryUsage):
* platform/MemoryUsageSupport.h:
(MemoryUsageSupport):
* platform/PlatformMemoryInstrumentation.cpp:
(WebCore):
* platform/PlatformMemoryInstrumentation.h:
(PlatformMemoryTypes):
* platform/chromium/MemoryUsageSupportChromium.cpp:
(reportMemoryUsage):
(WebCore::reportGlyphCache):
(WebCore):
(WebCore::MemoryUsageSupport::reportMemoryUsage):
* platform/qt/MemoryUsageSupportQt.cpp:
(WebCore::MemoryUsageSupport::reportMemoryUsage):

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

7 years agoPrevent NaN offset values in ElementTimeControl.
pdr@google.com [Sat, 27 Oct 2012 07:01:34 +0000 (07:01 +0000)]
Prevent NaN offset values in ElementTimeControl.
https://bugs.webkit.org/show_bug.cgi?id=100322

Reviewed by Abhishek Arya.

Source/WebCore:

NaN values can cause ElementTimeControl to go back in time!
If a value of NaN is passed to ElementTimeControl::beginElementAt(offset),
subsequent sorting will cause an assert in SVGSMILElement::findInstanceTime
because NaN values are not properly sorted. NaN SMILTime values
should not be allowed at all, so this patch adds a check for them in
ElementTimeControl's setters.

This patch also adds preventative asserts to catch if SMILTime is ever
initialized with NaN, or if addEndTime/addBeginTime are ever called
with NaN values.

Test: svg/custom/elementTimeControl-nan-crash.html

* svg/SVGAnimationElement.cpp:
(WebCore::SVGAnimationElement::beginElementAt):
(WebCore::SVGAnimationElement::endElementAt):
* svg/animation/SMILTime.h:
(WebCore::SMILTime::SMILTime):
* svg/animation/SVGSMILElement.cpp:
(WebCore::SVGSMILElement::addBeginTime):
(WebCore::SVGSMILElement::addEndTime):

LayoutTests:

* svg/custom/elementTimeControl-nan-crash-expected.txt: Added.
* svg/custom/elementTimeControl-nan-crash.html: Added.

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

7 years ago[Qt] Unreviewed weekend gardening, skip new failing tests.
ossy@webkit.org [Sat, 27 Oct 2012 06:55:17 +0000 (06:55 +0000)]
[Qt] Unreviewed weekend gardening, skip new failing tests.

* platform/qt/TestExpectations:

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

7 years ago[BlackBerry] Browser prematurely sends wrong credentials
charles.wei@torchmobile.com.cn [Sat, 27 Oct 2012 06:00:43 +0000 (06:00 +0000)]
[BlackBerry] Browser prematurely sends wrong credentials
https://bugs.webkit.org/show_bug.cgi?id=100585

Reviewed by Yong Li.

Manually revert the patch for bug 96362, which causes regressions and the right patch has been
submitted with patch for bug 100448. Since the auto-revert fails, we use this patch to manually
revert.

No new tests. The test is coverted by patch for 100448.

* platform/network/blackberry/CredentialBackingStore.cpp:
* platform/network/blackberry/CredentialBackingStore.h:
(CredentialBackingStore):
* platform/network/blackberry/NetworkManager.cpp:
(WebCore::NetworkManager::startJob):

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

7 years agoHave NetworkProcess manage resource load scheduling.
beidson@apple.com [Sat, 27 Oct 2012 05:59:24 +0000 (05:59 +0000)]
Have NetworkProcess manage resource load scheduling.
https://bugs.webkit.org/show_bug.cgi?id=100479

Reviewed by Alexey Proskuryakov.

Source/WebCore:

Down in WebCore we need to virtualize a handful of ResourceLoadScheduler methods
to be overridden by WebKit's implementation.

No new tests (No change in Core behavior).

* WebCore.exp.in:
* WebCore.xcodeproj/project.pbxproj:

* loader/ResourceLoadScheduler.cpp:
(WebCore::resourceLoadScheduler): Gracefully handle LoaderStrategies wanting to return the default scheduler.
(WebCore::ResourceLoadScheduler::scheduleLoad): Call notifyDidScheduleResourceRequest.
(WebCore::ResourceLoadScheduler::notifyDidScheduleResourceRequest): Moved InspectorInstrumentation call
  here so derived classes can do it indirectly.
(WebCore::ResourceLoadScheduler::startResourceLoader): To allow derived classes the ability to call
  ResourceLoader::start() which only ResourceLoadScheduler can do.

* loader/ResourceLoadScheduler.h:
(ResourceLoadScheduler): Virtualize some core public methods so they can be overridden.
(WebCore::ResourceLoadScheduler::setSerialLoadingEnabled): Make virtual.
(WebCore::ResourceLoadScheduler::isSuspendingPendingRequests): Make private as it's internal only.

* loader/ResourceLoader.cpp:
(WebCore::ResourceLoader::setIdentifier): Add this setter so outside clients can manually change the identifier.

* loader/ResourceLoader.h:
(WebCore::ResourceLoader::identifier): Change identifier to explicitly be uint64_t.
(WebCore::ResourceLoader::request): Make public.
(ResourceLoader):

Source/WebKit2:

Implement a ResourceLoadScheduler that models the same behavior as WebCore::ResourceLoadScheduler.

The WebProcess scheduler acts as a marshall to the NetworkProcess scheduler via CoreIPC messaging.

Besides MainResourceLoads which are started directly in the WebProcess, all other loads are now
started only when the NetworkProcess tells them to start.

Build-system and messaging related stuff:
* DerivedSources.make:
* Platform/CoreIPC/MessageID.h:
* WebKit2.xcodeproj/project.pbxproj:

Add a new Network logging channel.
* Platform/Logging.cpp:
(WebKit::getChannelFromName):
* Platform/Logging.h:

Modeled after ResourceLoadScheduler::HostInformation but more specifically geared towards what NetworkProcess needs to track:
* NetworkProcess/HostRecord.cpp: Added.
(WebKit::HostRecord::HostRecord):
(WebKit::HostRecord::~HostRecord):
(WebKit::HostRecord::schedule):
(WebKit::HostRecord::addLoadInProgress):
(WebKit::HostRecord::remove):
(WebKit::HostRecord::hasRequests):
(WebKit::HostRecord::limitRequests):
* NetworkProcess/HostRecord.h:
(WebKit::HostRecord::name):
(WebKit::HostRecord::requestsPending):

Gateway messaging from the WebResourceLoadScheduler to the NetworkResourceLoadScheduler:
* NetworkProcess/NetworkConnectionToWebProcess.cpp:
(WebKit::NetworkConnectionToWebProcess::NetworkConnectionToWebProcess):
(WebKit::NetworkConnectionToWebProcess::~NetworkConnectionToWebProcess):
(WebKit::NetworkConnectionToWebProcess::registerObserver):
(WebKit::NetworkConnectionToWebProcess::unregisterObserver):
(WebKit::NetworkConnectionToWebProcess::didReceiveMessage):
(WebKit::NetworkConnectionToWebProcess::didReceiveSyncMessage):
(WebKit::NetworkConnectionToWebProcess::didClose):
(WebKit::NetworkConnectionToWebProcess::scheduleNetworkRequest):
(WebKit::NetworkConnectionToWebProcess::addLoadInProgress):
(WebKit::NetworkConnectionToWebProcess::removeLoadIdentifier):
(WebKit::NetworkConnectionToWebProcess::crossOriginRedirectReceived):
(WebKit::NetworkConnectionToWebProcess::servePendingRequests):
(WebKit::NetworkConnectionToWebProcess::suspendPendingRequests):
(WebKit::NetworkConnectionToWebProcess::resumePendingRequests):
(WebKit::NetworkConnectionToWebProcess::setSerialLoadingEnabled):
* NetworkProcess/NetworkConnectionToWebProcess.h:
(NetworkConnectionToWebProcessObserver): Add an observer interface so arbitrary objects can be notified if
  a Network->WebProcess connection closes.
(WebKit::NetworkConnectionToWebProcessObserver::~NetworkConnectionToWebProcessObserver):
(WebKit::NetworkConnectionToWebProcess::isSerialLoadingEnabled):
* NetworkProcess/NetworkConnectionToWebProcess.messages.in:

Represents a request,  ResourceLoadIdentifier, and connection that all correspond to the same pending NetworkLoad:
* NetworkProcess/NetworkRequest.cpp:
(WebKit::NetworkRequest::NetworkRequest):
(WebKit::NetworkRequest::~NetworkRequest):
(WebKit::NetworkRequest::connectionToWebProcessDidClose): Using the NetworkConnectionToWebProcessObserver interface,
  if the connection closes then clear out the connection pointer for this request that is now irrelevant.
* NetworkProcess/NetworkRequest.h:
(WebKit::NetworkRequest::create):
(WebKit::NetworkRequest::identifier):
(WebKit::NetworkRequest::connectionToWebProcess):

Manages connection-per-host scheduling with the same structure as WebCore::ResourceLoadScheduling but also with IPC:
* NetworkProcess/NetworkResourceLoadScheduler.cpp: Added.
(WebKit::NetworkResourceLoadScheduler::NetworkResourceLoadScheduler):
(WebKit::NetworkResourceLoadScheduler::scheduleServePendingRequests):
(WebKit::NetworkResourceLoadScheduler::requestTimerFired):
(WebKit::NetworkResourceLoadScheduler::scheduleNetworkRequest):
(WebKit::NetworkResourceLoadScheduler::addLoadInProgress):
(WebKit::NetworkResourceLoadScheduler::hostForURL):
(WebKit::NetworkResourceLoadScheduler::removeLoadIdentifier):
(WebKit::NetworkResourceLoadScheduler::crossOriginRedirectReceived):
(WebKit::NetworkResourceLoadScheduler::servePendingRequests):
(WebKit::NetworkResourceLoadScheduler::servePendingRequestsForHost): Serve as many requests for the host as we should,
  skipping the NetworkRequests who have lost their connection to their WebProcess.
(WebKit::NetworkResourceLoadScheduler::suspendPendingRequests):
(WebKit::NetworkResourceLoadScheduler::resumePendingRequests):
* NetworkProcess/NetworkResourceLoadScheduler.h: Added.
* NetworkProcess/mac/NetworkResourceLoadSchedulerMac.mm: Added.
(WebKit::NetworkResourceLoadScheduler::platformInitializeMaximumHTTPConnectionCountPerHost):

* NetworkProcess/NetworkProcess.h:
(WebKit::NetworkProcess::networkResourceLoadScheduler): Add a scheduler global to the NetworkProcess.

A thin derivation of WebCore::ResourceLoadScheduler, most of what WebResourceLoadScheduler does is handle IPC to the NetworkProcess:
* WebProcess/Network/WebResourceLoadScheduler.cpp:
(WebKit::WebResourceLoadScheduler::WebResourceLoadScheduler):
(WebKit::WebResourceLoadScheduler::scheduleSubresourceLoad):
(WebKit::WebResourceLoadScheduler::schedulePluginStreamLoad):
(WebKit::WebResourceLoadScheduler::scheduleLoad):
(WebKit::WebResourceLoadScheduler::addMainResourceLoad):
(WebKit::WebResourceLoadScheduler::remove):
(WebKit::WebResourceLoadScheduler::crossOriginRedirectReceived):
(WebKit::WebResourceLoadScheduler::servePendingRequests):
(WebKit::WebResourceLoadScheduler::suspendPendingRequests):
(WebKit::WebResourceLoadScheduler::resumePendingRequests):
(WebKit::WebResourceLoadScheduler::setSerialLoadingEnabled):
(WebKit::WebResourceLoadScheduler::startResourceLoad):
* WebProcess/Network/WebResourceLoadScheduler.h:

Add the ability for the NetworkProcess to message back to the WebProcess telling it to start a resource load:
* WebProcess/Network/NetworkProcessConnection.cpp:
(WebKit::NetworkProcessConnection::didReceiveMessage):
(WebKit::NetworkProcessConnection::didReceiveSyncMessage):
(WebKit::NetworkProcessConnection::startResourceLoad):
* WebProcess/Network/NetworkProcessConnection.h:
* WebProcess/Network/NetworkProcessConnection.messages.in:

* WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
(WebKit::WebPlatformStrategies::resourceLoadScheduler): Only return the WebResourceLoadScheduler if NetworkProcess is enabled.

* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::ensureNetworkProcessConnection): Actually keep the NetworkProcessConnection around in a member variable.
(WebKit::WebProcess::networkConnection):
* WebProcess/WebProcess.h:
(WebKit::WebProcess::usesNetworkProcess): Expose this for platform strategies sake.

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

7 years agoImplement AudioBufferSourceNode .loopStart and .loopEnd attributes
crogers@google.com [Sat, 27 Oct 2012 02:10:33 +0000 (02:10 +0000)]
Implement AudioBufferSourceNode .loopStart and .loopEnd attributes
https://bugs.webkit.org/show_bug.cgi?id=100170

Reviewed by Kenneth Russell.

Source/WebCore:

AudioBufferSourceNode currently only supports looping of an entire AudioBuffer.
Sample-based synthesis is a very common technique which requires "internal" loop-points.
For example, the first part of the sample data might represent the attack portion of
a synthesized instrument, which then enters a loop portion.

Tests: webaudio/audiobuffersource-loop-comprehensive.html
       webaudio/audiobuffersource-loop-points.html

* Modules/webaudio/AudioBufferSourceNode.cpp:
(WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
(WebCore::AudioBufferSourceNode::process):
(WebCore::AudioBufferSourceNode::renderFromBuffer):
* Modules/webaudio/AudioBufferSourceNode.h:
(AudioBufferSourceNode):
(WebCore::AudioBufferSourceNode::loopStart):
(WebCore::AudioBufferSourceNode::loopEnd):
(WebCore::AudioBufferSourceNode::setLoopStart):
(WebCore::AudioBufferSourceNode::setLoopEnd):
* Modules/webaudio/AudioBufferSourceNode.idl:

LayoutTests:

* webaudio/audiobuffersource-loop-comprehensive-expected.txt: Added.
* webaudio/audiobuffersource-loop-comprehensive.html: Added.
* webaudio/audiobuffersource-loop-points-expected.wav: Added.
* webaudio/audiobuffersource-loop-points.html: Added.

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

7 years ago[Chromium] Test expectation update.
tkent@chromium.org [Sat, 27 Oct 2012 02:07:19 +0000 (02:07 +0000)]
[Chromium] Test expectation update.

Rebaseline for recent forms changes.

* platform/chromium-linux/platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-step-expected.png:
* platform/chromium-mac-lion/platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-step-expected.png:
* platform/chromium-mac-snowleopard/platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-step-expected.png:
* platform/chromium-win/platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-step-expected.png:
* platform/chromium-win/platform/chromium/fast/forms/suggestion-picker/time-suggestion-picker-appearance-rtl-expected.png:
* platform/chromium-win/platform/chromium/fast/forms/suggestion-picker/time-suggestion-picker-appearance-with-scroll-bar-expected.png:
* platform/chromium/TestExpectations:

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

7 years ago[Chromium] Convert Chromium template string to an LDML date format
tkent@chromium.org [Sat, 27 Oct 2012 01:53:38 +0000 (01:53 +0000)]
[Chromium] Convert Chromium template string to an LDML date format
https://bugs.webkit.org/show_bug.cgi?id=100128

Reviewed by Tony Chang.

* src/LocalizedStrings.cpp:
(WebCore): Include WebCore/platform/text/DateTimeFormat.h.
(WebCore::weekFormatInLDML):
Replace $1 with yyyy, $2 with ww, and quote other parts.

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

7 years agoAdd a microbenchmark for Hindi (complex-text) line-layout
eric@webkit.org [Sat, 27 Oct 2012 01:37:12 +0000 (01:37 +0000)]
Add a microbenchmark for Hindi (complex-text) line-layout
https://bugs.webkit.org/show_bug.cgi?id=100024

Reviewed by Ryosuke Niwa.

I wrote this to make sure that we don't regress line-breaking performance
for the complex-text codepath. This test has shown me that TOT is
already 5% slower than Safari 6.0.1 here. :(

* Layout/hindi-line-layout.html: Added.

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

7 years agodragover's default action should prevent drop for file drags
dcheng@chromium.org [Sat, 27 Oct 2012 01:31:08 +0000 (01:31 +0000)]
dragover's default action should prevent drop for file drags
https://bugs.webkit.org/show_bug.cgi?id=79173

Reviewed by Tony Chang.

Source/WebCore:

During a file drag, we need to keep track of whether or not the document has cancelled the
dragover action. We should only send a drop event if the dragover event was cancelled; this
matches the behavior of the spec, as well as IE, Gecko, and Opera. The relevant sections
from the spec are the sections pertaining to dragover and drop events at:
http://www.whatwg.org/specs/web-apps/current-work/#drag-and-drop-processing-model

Test: fast/events/only-valid-drop-targets-receive-file-drop.html

* page/DragController.cpp:
(WebCore::DragController::performDrag):
(WebCore::DragController::dragEnteredOrUpdated):
(WebCore::DragController::tryDocumentDrag):
* page/DragController.h:
(DragController): Cleanup to repurpose a variable that doesn't need to be a member anymore
                  and remove the corresponding getter/setter.

LayoutTests:

* fast/dom/shadow/drop-event-in-shadow.html:
    Added dragover handler as required by the HTML specification.
* fast/events/input-element-display-none-in-dragleave-crash.html:
    Added dragover handler as required by the HTML specification.
* fast/events/only-valid-drop-targets-receive-file-drop-expected.txt: Added.
* fast/events/only-valid-drop-targets-receive-file-drop.html: Added.
* http/tests/security/clipboard/clipboard-file-access.html:
    Added dragover handler as required by the HTML specification.

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

7 years agoFix a operator ordering bug in SVGSMILElement::calculateAnimationPercentAndRepeat
thakis@chromium.org [Sat, 27 Oct 2012 01:20:29 +0000 (01:20 +0000)]
Fix a operator ordering bug in SVGSMILElement::calculateAnimationPercentAndRepeat
https://bugs.webkit.org/show_bug.cgi?id=94756

Reviewed by Dirk Schulze.

The function has an early exit for !simpleDuration.value(), so
!simpleDuration.value() always is 0 when passed as second parameter to
fmod(), which means fmod() always returns NaN, which always evaluates
to true. Simplify the code by removing that explicit check.

No observable behavior change.

Covered by existing svg tests.

* svg/animation/SVGSMILElement.cpp:
(WebCore::SVGSMILElement::calculateAnimationPercentAndRepeat):

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

7 years agoCrash in WebProces at WebCore::ResourceLoadScheduler::crossOriginRedirectReceived...
beidson@apple.com [Sat, 27 Oct 2012 01:01:16 +0000 (01:01 +0000)]
Crash in WebProces at WebCore::ResourceLoadScheduler::crossOriginRedirectReceived + 78
https://bugs.webkit.org/show_bug.cgi?id=100554

Reviewed by Alexey Proskuryakov.

For now, just have WebPlatformStrategies return the same default resourceLoadScheduler that
WebCore knows about.

* WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
(WebKit::WebPlatformStrategies::resourceLoadScheduler):

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

7 years agoSource/WebKit2: Crash when making NPRuntime calls with a null NPP pointer
andersca@apple.com [Sat, 27 Oct 2012 00:17:09 +0000 (00:17 +0000)]
Source/WebKit2: Crash when making NPRuntime calls with a null NPP pointer
https://bugs.webkit.org/show_bug.cgi?id=100569
<rdar://problem/11726426>
<rdar://problem/12352836>

Reviewed by Darin Adler.

Finally bite the bullet and remove the assertion from NetscapePlugin::fromNPP. The WebKit1 equivalent of this
function used to return the plug-in currently being initialized in NPP_New, but we've never done that in WebKit2
and it has never been necessary. The crashes fixed here are not from calls underneath NPP_New so fixing it wouldn't
do us any good anyway.

Also, make the PluginDestructionProtector handle a null plug-in gracefully.

* WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
(WebKit::PluginDestructionProtector::PluginDestructionProtector):
(PluginDestructionProtector):
* WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
(WebKit::NetscapePlugin::fromNPP):

Tools: Crash when making NPRuntime calls with a null NPP pointer
https://bugs.webkit.org/show_bug.cgi?id=100569

Reviewed by Darin Adler.

Add new NPRuntimeCallsWithNullNPP plug-in test.

* DumpRenderTree/DumpRenderTree.gypi:
* DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
* DumpRenderTree/TestNetscapePlugIn/PluginTest.cpp:
(PluginTest::NPN_ReleaseVariantValue):
(PluginTest::netscapeFuncs):
* DumpRenderTree/TestNetscapePlugIn/PluginTest.h:
(PluginTest):
* DumpRenderTree/TestNetscapePlugIn/Tests/NPRuntimeCallsWithNullNPP.cpp: Added.
(NPRuntimeCallsWithNullNPP):
(NPRuntimeCallsWithNullNPP::NPRuntimeCallsWithNullNPP):
(NPRuntimeCallsWithNullNPP::NPP_New):
* DumpRenderTree/TestNetscapePlugIn/win/TestNetscapePlugin.vcproj:
* DumpRenderTree/qt/TestNetscapePlugin/TestNetscapePlugin.pro:
* GNUmakefile.am:

LayoutTests: Crash when making NPRuntime calls with a null NPP pointer
https://bugs.webkit.org/show_bug.cgi?id=100569

Reviewed by Darin Adler.

Add new tests.

* plugins/npruntime/npruntime-calls-with-null-npp-expected.txt: Added.
* plugins/npruntime/npruntime-calls-with-null-npp.html: Added.

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

7 years agoUnreviewed, rolling out r132695.
commit-queue@webkit.org [Fri, 26 Oct 2012 23:55:46 +0000 (23:55 +0000)]
Unreviewed, rolling out r132695.
http://trac.webkit.org/changeset/132695
https://bugs.webkit.org/show_bug.cgi?id=100581

caused 20+ test crashes on bots (Requested by estes on
#webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-10-26

* dom/ContainerNode.cpp:
(WebCore::ContainerNode::suspendPostAttachCallbacks):
(WebCore::ContainerNode::resumePostAttachCallbacks):
* loader/MainResourceLoader.cpp:
(WebCore::MainResourceLoader::loadNow):
* loader/ResourceLoadScheduler.cpp:
(WebCore::resourceLoadScheduler):
* loader/ResourceLoadScheduler.h:
* loader/ResourceLoader.cpp:
(WebCore::ResourceLoader::releaseResources):
(WebCore::ResourceLoader::willSendRequest):
* loader/cache/CachedResource.cpp:
(WebCore::CachedResource::load):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::performPostLoadActions):

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

7 years agoUnreviewed, rolling out r132689.
commit-queue@webkit.org [Fri, 26 Oct 2012 23:36:28 +0000 (23:36 +0000)]
Unreviewed, rolling out r132689.
http://trac.webkit.org/changeset/132689
https://bugs.webkit.org/show_bug.cgi?id=100574

Broke HashMaps containing RetainPtrs (Requested by andersca on
#webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-10-26

* wtf/RetainPtr.h:

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