[WTR] Do not dump information about empty subframes.
https://bugs.webkit.org/show_bug.cgi?id=110585

Reviewed by Simon Fraser.

Tools:

Follow DumpRenderTree more closely by skipping empty frames
(frames which have no document). We are not really interested in
showing anything about them.

* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::dumpDescendantFramesText): Do not print subframe names when they
have no associated Document.

LayoutTests:

Remove some platform-specific expectations now that the results match
the base expectations.

* platform/efl/TestExpectations: Unskip tests that are now passing.
* platform/mac-wk2/http/tests/security/cross-origin-xsl-BLOCKED-expected.txt: Removed.
* platform/mac-wk2/http/tests/security/cross-origin-xsl-redirect-BLOCKED-expected.txt: Removed.
* platform/qt-5.0-wk2/http/tests/security/cross-origin-xsl-BLOCKED-expected.txt: Removed.
* platform/qt-5.0-wk2/http/tests/security/cross-origin-xsl-redirect-BLOCKED-expected.txt: Removed.
* platform/win-wk2/http/tests/security/cross-origin-xsl-BLOCKED-expected.txt: Removed.
* platform/win-wk2/http/tests/security/cross-origin-xsl-redirect-BLOCKED-expected.txt: Removed.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143739 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Rename first/second to key/value in HashMap iterators
https://bugs.webkit.org/show_bug.cgi?id=110577

Patch by Carlos Garcia Campos <cargarcia@rim.com> on 2013-02-22
Reviewed by Rob Buis.

Iterators were renamed to key/value in r130612.

Source/WebCore:

* platform/blackberry/AuthenticationChallengeManager.cpp:
(WebCore::AuthenticationChallengeManager::pageVisibilityChanged):
* platform/network/blackberry/NetworkJob.cpp:
(WebCore::NetworkJob::handleNotifyMultipartHeaderReceived):

Source/WebKit/blackberry:

* WebKitSupport/NotificationManager.cpp:
(BlackBerry::WebKit::NotificationManager::show):
(BlackBerry::WebKit::NotificationManager::clearNotifications):
(BlackBerry::WebKit::NotificationManager::removeNotificationFromContextMap):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143740 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, rolling out r143734.
http://trac.webkit.org/changeset/143734
https://bugs.webkit.org/show_bug.cgi?id=110615

Causes linux build failures. (Requested by vollick on
#webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-02-22

* public/WebKit.h:
(WebKit):
* src/WebKit.cpp:
(WebKit::initialize):
(WebKit::initializeWithoutV8):
(WebKit::webKitPlatformSupport):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143741 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Roll ANGLE to r1833
https://bugs.webkit.org/show_bug.cgi?id=110513

Reviewed by Kenneth Russell.

Source/ThirdParty/ANGLE: 

Upstream ANGLE r1833 includes webkit side local fixes
1) r139758 build fix for -Wshorten-64-to-32
2) r139665 build fix for uninitialized variables

After this roll, WebKit side ANGLE is the same as upstream ANGLE r1833, except:
1) include/GLSLANG/ShaderLang.h, where "KHR" is removed from include path.

With this roll, we have EXT_draw_buffers support.
        
* ANGLE.xcodeproj/project.pbxproj:
* Target.pri:
* include/GLSLANG/ShaderLang.h:
* src/common/debug.cpp:
* src/common/system.h: Added.
* src/common/version.h:
* src/compiler/ArrayBoundsClamper.cpp: Removed.
* src/compiler/ArrayBoundsClamper.h: Removed.
* src/compiler/Compiler.cpp:
(TCompiler::TCompiler):
(TCompiler::Init):
(TCompiler::compile):
(TCompiler::getArrayBoundsClamper):
(TCompiler::getArrayIndexClampingStrategy):
(TCompiler::getBuiltInFunctionEmulator):
* src/compiler/DetectDiscontinuity.cpp:
(sh::DetectLoopDiscontinuity::traverse):
(sh::DetectLoopDiscontinuity::visitLoop):
(sh):
(sh::DetectLoopDiscontinuity::visitBranch):
* src/compiler/DetectDiscontinuity.h:
(DetectLoopDiscontinuity):
* src/compiler/Initialize.cpp:
(InitExtensionBehavior):
* src/compiler/Intermediate.cpp:
(TIntermConstantUnion::fold):
(TIntermTraverser::hash):
* src/compiler/MapLongVariableNames.cpp:
(LongNameMap::Size):
(MapLongVariableNames::mapGlobalLongName):
* src/compiler/MapLongVariableNames.h:
(LongNameMap):
* src/compiler/OutputESSL.cpp:
(TOutputESSL::TOutputESSL):
* src/compiler/OutputESSL.h:
(TOutputESSL):
* src/compiler/OutputGLSL.cpp:
(TOutputGLSL::TOutputGLSL):
* src/compiler/OutputGLSL.h:
(TOutputGLSL):
* src/compiler/OutputGLSLBase.cpp:
(TOutputGLSLBase::TOutputGLSLBase):
(TOutputGLSLBase::writeConstantUnion):
(TOutputGLSLBase::visitBinary):
* src/compiler/OutputGLSLBase.h:
(TOutputGLSLBase):
* src/compiler/OutputHLSL.cpp:
(sh::OutputHLSL::output):
(sh::OutputHLSL::visitLoop):
(sh::OutputHLSL::writeConstantUnion):
* src/compiler/ParseHelper.cpp:
(TParseContext::constructorErrorCheck):
(PaParseStrings):
* src/compiler/ParseHelper.h:
* src/compiler/ShHandle.h:
(TCompiler):
* src/compiler/ShaderLang.cpp:
(checkActiveUniformAndAttribMaxLengths):
(checkMappedNameMaxLength):
(getVariableInfo):
(ShInitBuiltInResources):
(ShCompile):
(ShGetInfo):
(ShGetActiveAttrib):
(ShGetActiveUniform):
(ShGetNameHashingEntry):
* src/compiler/SymbolTable.h:
(TFunction::getParamCount):
(TFunction::getParam):
(TSymbolTable::setDefaultPrecision):
* src/compiler/TranslatorESSL.cpp:
(TranslatorESSL::translate):
* src/compiler/TranslatorGLSL.cpp:
(TranslatorGLSL::translate):
* src/compiler/ValidateLimitations.cpp:
(ValidateLimitations::validateFunctionCall):
* src/compiler/VariablePacker.cpp:
(VariablePacker::GetNumRows):
* src/compiler/glslang.h:
* src/compiler/glslang.l:
* src/compiler/glslang.y:
* src/compiler/glslang_lex.cpp:
(string_input):
(glslang_scan):
* src/compiler/glslang_tab.cpp:
* src/compiler/preprocessor/ExpressionParser.cpp:
* src/compiler/preprocessor/ExpressionParser.y:
* src/compiler/preprocessor/Input.cpp:
(pp::Input::Input):
(pp::Input::read):
* src/compiler/preprocessor/Input.h:
(Input):
(pp::Input::count):
(pp::Input::string):
(pp::Input::length):
(Location):
* src/compiler/preprocessor/Preprocessor.cpp:
(pp::Preprocessor::init):
* src/compiler/preprocessor/Preprocessor.h:
(Preprocessor):
* src/compiler/preprocessor/Tokenizer.cpp:
(pp::Tokenizer::init):
* src/compiler/preprocessor/Tokenizer.h:
(Tokenizer):
* src/compiler/preprocessor/Tokenizer.l:
* src/third_party: Added.
* src/third_party/compiler: Added.
* src/third_party/compiler/ArrayBoundsClamper.cpp: Added.
(ArrayBoundsClamper::ArrayBoundsClamper):
(ArrayBoundsClamper::SetClampingStrategy):
(ArrayBoundsClamper::MarkIndirectArrayBoundsForClamping):
(ArrayBoundsClamper::OutputClampingFunctionDefinition):
* src/third_party/compiler/ArrayBoundsClamper.h: Added.
(ArrayBoundsClamper):
(ArrayBoundsClamper::Cleanup):
(ArrayBoundsClamper::GetArrayBoundsClampDefinitionNeeded):
(ArrayBoundsClamper::SetArrayBoundsClampDefinitionNeeded):
* src/third_party/compiler/LICENSE: Added.
* src/third_party/compiler/README.angle: Added.

Source/WebCore: 

* CMakeLists.txt:
* GNUmakefile.list.am:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143742 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Element: Make updateName/updateId/updateLabel private.
<http://webkit.org/b/110603>

Reviewed by Antti Koivisto.

These methods are only called from inside Element so make them private and
move them to the .cpp file.

* dom/Element.cpp:
(WebCore::Element::updateName):
(WebCore::Element::updateId):
* dom/Element.h:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143743 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Multiple Layout Test crashes (ASSERT) on chromium linux debug after r143727
https://bugs.webkit.org/show_bug.cgi?id=110609

Reviewed by Antonio Gomes.

Revert r128869. InnerNode may now again be from a child document,
and should be handled and not asserted against.

* dom/Document.cpp:
(WebCore::Document::updateHoverActiveState):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143744 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: [Canvas] throttle replayTraceLog messages to backend
https://bugs.webkit.org/show_bug.cgi?id=110591

Reviewed by Pavel Feldman.

The replayTraceLog message may be quite expensive. So, while such a request is processed by the
backend, user may well generate a dozen of new ones simply by walking through the DataGrid.
We should actually send to the backend only the last event from the queue.

* inspector/front-end/CanvasProfileView.js:
(WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
(WebInspector.CanvasProfileView.prototype._replayTraceLog):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143745 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed build-fix after r143744.

* dom/Document.cpp:
(WebCore::Document::updateHoverActiveState):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143747 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Use KURL::protocolIsInHTTPFamily instead of KURL::protocolInHTTPFamily
https://bugs.webkit.org/show_bug.cgi?id=110581

Patch by Carlos Garcia Campos <cargarcia@rim.com> on 2013-02-22
Reviewed by Rob Buis.

KURL::protocolInHTTPFamily() was removed in r109670.

* platform/network/blackberry/ResourceRequestBlackBerry.cpp:
(WebCore::ResourceRequest::clearHTTPContentLength):
(WebCore::ResourceRequest::clearHTTPContentType):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143748 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[TextAutosizing] Refactoring to eliminate boolean parameter.
https://bugs.webkit.org/show_bug.cgi?id=110490

Patch by Anton Vayvod <avayvod@chromium.org> on 2013-02-22
Reviewed by Julien Chaffraix.

A follow-up to the recent change that introduced a boolean parameter to
processClusterInternal method of TextAutosizer. Boolean parameters are discouraged by the
WebKit style guide. See http://trac.webkit.org/changeset/142866

Refactoring so no new tests.

* rendering/TextAutosizer.cpp:
(WebCore::TextAutosizer::clusterMultiplier):

        Calculates the font size multiplier for the specified cluster.

(WebCore::TextAutosizer::processClusterInternal):

        Accepts the font size multiplier instead of |shouldBeAutosized|.

(WebCore::TextAutosizer::processCluster):
(WebCore::TextAutosizer::processCompositeCluster):

        Both methods above now calculate the multiplier and then pass it to
        processClusterInternal.

* rendering/TextAutosizer.h:

        Updated method declarations.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143749 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Build fix after r143637.

* WebCore.exp.in: Unconditionally export ScriptController::javaScriptContext.
* bindings/js/ScriptController.h: Unconditionally define javaScriptContext for Mac builds.
* bindings/js/ScriptControllerMac.mm:
(WebCore::ScriptController::javaScriptContext): Move the #if inside the function, and return 0 when false.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143750 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION(r143664, r143681): http/tests/security/feed-urls-from-remote.html fails
https://bugs.webkit.org/show_bug.cgi?id=110554

Reviewed by Adam Barth.

Will fix http/tests/security/feed-urls-from-remote.html for Mac WK1.

* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::isLoading):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143753 268f45cc-cd09-0410-ab3c-d52691b4dbfc
text-overflow:ellipsis is not applied when the block contains nested blocks
https://bugs.webkit.org/show_bug.cgi?id=101879

Patch by Bem Jones-Bey <bjonesbe@adobe.com> on 2013-02-22
Reviewed by Eric Seidel.

Source/WebCore:

Since text-overflow is not an inherited property, the anonymous blocks
don't know they should ellipse. This causes the anonymous blocks
created in the nested block situation to check their parent to find
out if they should ellipse.

Test: fast/css/text-overflow-ellipsis-anonymous-blocks.html

* rendering/RenderBlockLineLayout.cpp:
(WebCore::RenderBlock::layoutInlineChildren):

LayoutTests:

Use the test from the specification that is supplied as part of the
bug.

* fast/css/text-overflow-ellipsis-anonymous-blocks-expected.html: Added.
* fast/css/text-overflow-ellipsis-anonymous-blocks.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143754 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[New Multicolumn] Correctly track whether or not a layer is paginated.
https://bugs.webkit.org/show_bug.cgi?id=110625.

Taking the first step towards implementing the correct spec-compliant painting
model for the new multi-column layout. Add code to make sure the paginated
bits in RenderLayer get propagated correctly for the new layout.
        
The main difference in bit propagation between the old multicolumn layout and
the new multicolumn layout is that the old layout only tracked pagination "roots",
since it has a broken layer painting model. It incorrectly treats a pagination
"root" inside a multi-column block as establishing a stacking context in each
column. This is incorrect.
        
The new multicolumn code is going to paint each paginated layer individually,
and this means the bits can't just be about roots. Instead they have to be set
on every layer that may be split across columns, without regard for whether parent
layers are also split or not. This is actually a simpler bit propagation model
than the old code.

Reviewed by Beth Dakin.

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::updateLayerPositions):
Add code to set the m_isPaginated bit for in-flow RenderFlowThreads. This includes
only RenderMultiColumnFlowThread for now, but eventually it will also include
RenderPageFlowThread.

(WebCore::RenderLayer::useRegionBasedColumns):
Add a helper method to check if region-based columns are turned on, since we're
not attempting to alter the old column pagination model.

(WebCore::RenderLayer::updatePagination):
Added the code to propagate bits under the new model. Whether or not you're paginated
just depends on whether or not your enclosing layer along the containing block chain
is paginated.

(WebCore::RenderLayer::paintList):
(WebCore::RenderLayer::hitTestList):
Add code that avoids the old multi-column pagination model when the new column model
is enabled. For now there is no code in the new model that does anything with the bits,
but we're avoiding calling the old code, since it is broken for the new columns.

* rendering/RenderLayer.h:
(RenderLayer):
Added the useRegionBasedColumns method to check the Setting.

* rendering/RenderMultiColumnFlowThread.h:
* rendering/RenderObject.h:
(WebCore::RenderObject::isInFlowRenderFlowThread):
(RenderObject):
Implement isInFlowRenderFlowThread, a virtual function for asking if a renderer is
an in-flow RenderFlowThread, which means that it is going to need paginated layers
because the flow thread has to split across "pages" that do not establish stacking
contexts.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143757 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Code cache size should adapt to workload
https://bugs.webkit.org/show_bug.cgi?id=110560

Reviewed by Antti Koivisto.

(*) 5% PLT arithmetic mean speedup
(*) 10% PLT geometric mean speedup
(*) 3.4X microbenchmark speedup
(*) Reduces initial cache capacity by 16X

* runtime/CodeCache.cpp:
(JSC::CodeCache::CodeCache): Updated for interface change.

* runtime/CodeCache.h:
(JSC::SourceCodeValue::SourceCodeValue):
(SourceCodeValue): Turned the cache value into a struct so it can track its age.

(CodeCacheMap):
(JSC::CodeCacheMap::CodeCacheMap):
(JSC::CodeCacheMap::find):
(JSC::CodeCacheMap::set):
(JSC::CodeCacheMap::clear):
(JSC::CodeCacheMap::pruneIfNeeded):
(CodeCache): Grow and shrink in response to usage.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143759 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add computeInstrinsicLogicalWidths functions to TableLayout subclasses
https://bugs.webkit.org/show_bug.cgi?id=110520

Reviewed by Tony Chang.

This is just a refactor in preparation for adding RenderTable::computeIntinsicLogicalWidths.
No change in behavior.

Split the computePreferredLogicalWidths functions into a computeIntinsicLogicalWidths
and a applyPreferredLogicalWidthQuirks. Also, move the addition of bordersPaddingAndSpacing
into RenderTable since both TableLayout subclasses need this.

This has the added readability benefit of better isolating the quirks that each table layout
mode requires.

* rendering/AutoTableLayout.cpp:
(WebCore::AutoTableLayout::computeIntrinsicLogicalWidths):
(WebCore::AutoTableLayout::applyPreferredLogicalWidthQuirks):
* rendering/AutoTableLayout.h:
(AutoTableLayout):
* rendering/FixedTableLayout.cpp:
(WebCore::FixedTableLayout::computeIntrinsicLogicalWidths):
(WebCore::FixedTableLayout::applyPreferredLogicalWidthQuirks):
* rendering/FixedTableLayout.h:
(FixedTableLayout):
* rendering/RenderTable.cpp:
(WebCore::RenderTable::computePreferredLogicalWidths):
* rendering/TableLayout.h:
(TableLayout):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143762 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Mac OS build broken by new ExpressionParser.cpp
https://bugs.webkit.org/show_bug.cgi?id=110629

Unreviewed build fix. Regenerated ExpressionParser with Bison 2.3.

* src/compiler/preprocessor/ExpressionParser.cpp:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143763 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Two video contollers appear after exiting the fullscreen video when using menubar to exit.
https://bugs.webkit.org/show_bug.cgi?id=110506

Reviewed by Eric Carlson.

When we are notified that the fullscreen window is about to exit fullscreen mode unrequested,
call requestExitFullScreen(), as that will result in Document::webkitExitFullScreen() correctly
tearing down the fullscreen state.

* UIProcess/mac/WKFullScreenWindowController.mm:
(-[WKFullScreenWindowController _startExitFullScreenAnimationWithDuration:]):

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

Fix the 32-bit build by using the right data type.

* runtime/CodeCache.h:
(JSC::CodeCacheMap::find):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@143765 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSS Regions] Region boxes should respect -shape-inside CSS property
https://bugs.webkit.org/show_bug.cgi?id=107880

Reviewed by David Hyatt.

The shape-inside CSS property modifies the shape of the inner inline flow content from rectangular content box
to an arbitrary geometry. The detailed documentation is located in the CSS-Exclusions specification:
http://dev.w3.org/csswg/css3-exclusions/#shape-inside-property. This change adds support for the shape-inside property
on CSS Regions.

Source/WebCore: 

Test: fast/regions/shape-inside-on-regions.html

* rendering/ExclusionShapeInfo.cpp:
(WebCore):
(WebCore::::logicalTopOffset): Shape dimension should be relative to the current region.
* rendering/ExclusionShapeInfo.h:
(ExclusionShapeInfo):
(WebCore::::logicalTopOffset): Move the implementation to ExclusionShapeInfo.cpp.
* rendering/RenderBlockLineLayout.cpp:
(WebCore::logicalHeightForLine): Move the function prior to layoutExclusionShapeInsideInfo, since we need to use it there.
(WebCore):
(WebCore::layoutExclusionShapeInsideInfo): Add support for cases when shape-inside is a region-block property.
(WebCore::RenderBlock::layoutRunsAndFloatsInRange): Update the exclusion shape information for every line, since the content
could flow through several region containers which can have different shape-inside properties.

LayoutTests: 

* fast/regions/shape-inside-on-regions-expected.html: Added.
* fast/regions/shape-inside-on-regions.html: Added.



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