WebKit-https.git
6 years agoASSERT(!m_hasBadParent) in InlineBox::parent() should be ASSERT_WITH_SECURITY_IMPLICATION
commit-queue@webkit.org [Mon, 30 Sep 2013 21:56:02 +0000 (21:56 +0000)]
ASSERT(!m_hasBadParent) in InlineBox::parent() should be ASSERT_WITH_SECURITY_IMPLICATION
https://bugs.webkit.org/show_bug.cgi?id=122032

Patch by Drew Yao <ayao@apple.com> on 2013-09-30
Reviewed by Andreas Kling.

Convert assertion to ASSERT_WITH_SECURITY_IMPLICATION to help catch use after free bugs.

No new tests needed.

* rendering/InlineBox.h:
(WebCore::InlineBox::parent):

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

6 years agoDon't attempt to destroy decoded frame if a BitmapImage doesn't have encoded raw...
commit-queue@webkit.org [Mon, 30 Sep 2013 21:54:17 +0000 (21:54 +0000)]
Don't attempt to destroy decoded frame if a BitmapImage doesn't have encoded raw data.
https://bugs.webkit.org/show_bug.cgi?id=122115

Patch by Yongjun Zhang <yongjun_zhang@apple.com> on 2013-09-30
Reviewed by Daniel Bates.

With BitmapImage::create(PassNativeImagePtr, ImageObserver*), a BitmapImage could be created by
passing a native image.  If this image is added to memory cache, we shouldn't attempt to destroy
its decoded frames since there is no encoded raw data and we won't be able to reconstruct the image again.

No new tests for now. Currently there isn't a code path to add to the memory cache a BitmapImage
that was created by adopting a native image. We'll add such a code path in a subsequent patch.

* platform/graphics/BitmapImage.cpp:
(WebCore::BitmapImage::destroyDecodedDataIfNecessary):

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

6 years agoPass VM instead of ExecState to ObjectPrototype constructor.
akling@apple.com [Mon, 30 Sep 2013 21:42:05 +0000 (21:42 +0000)]
Pass VM instead of ExecState to ObjectPrototype constructor.
<https://webkit.org/b/122116>

Reviewed by Geoffrey Garen.

The ObjectPrototype constructor was only using the ExecState to get
to the VM.

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

6 years agoPass VM instead of JSGlobalObject to MathObject constructor.
akling@apple.com [Mon, 30 Sep 2013 21:41:04 +0000 (21:41 +0000)]
Pass VM instead of JSGlobalObject to MathObject constructor.
<https://webkit.org/b/122119>

Reviewed by Geoffrey Garen.

The MathObject constructor was only using the global object to get
to the VM. finishCreation() still uses it to set up functions.

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

6 years agoRemove timeout from shouldBecome* functions in js-test-pre
ap@apple.com [Mon, 30 Sep 2013 20:47:43 +0000 (20:47 +0000)]
Remove timeout from shouldBecome* functions in js-test-pre
https://bugs.webkit.org/show_bug.cgi?id=122121

Reviewed by Ryosuke Niwa.

Removed timeout. A 0.5 sec timeout never makes sense, and if something is stuck,
a test should just time out normally.

* resources/js-test-pre.js:
(_waitForCondition):
(shouldBecomeEqual):
(shouldBecomeEqualToString):
(shouldBecomeDifferent):

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

6 years agoGet rid of the AlreadyInJSStack recoveries since they are totally redundant with...
fpizlo@apple.com [Mon, 30 Sep 2013 20:38:46 +0000 (20:38 +0000)]
Get rid of the AlreadyInJSStack recoveries since they are totally redundant with the DisplacedInJSStack recoveries
https://bugs.webkit.org/show_bug.cgi?id=122065

Reviewed by Mark Hahnenberg.

This mostly just kills a bunch of code.

But incidentaly while killing that code, I uncovered a bug in our FTL OSR entrypoint
creation phase. The phase inserts a sequence of SetLocal(ExtractOSREntryLocal) nodes.
If we hoist some type check into the local, then we might inject a conversion node
between the ExtractOSREntryLocal and the SetLocal - for example we might put in a
Int32ToDouble node. But currently the FixupPhase will make all conversion nodes placed
on an edge of a SetLocal use forward exit. This then confuses the OSR exit machinery.
When OSR exit sees a forward exit, it tries to "roll forward" execution from the exiting
node to the first node that has a different CodeOrigin. This only works if the nodes
after the forward exit are MovHints or other tnings that the OSR exit compiler can
forward-execute. But here, it will see a bunch of SetLocal and ExtractOSREntryLocal
nodes for the same bytecode index. Two possible solutions exist. We could teach the
forward-execution logic how to deal with multiple SetLocals and ExtractOSREntryLocals.
This would be a lot of complexity; right now it just needs to deal with exactly one
SetLocal-like operation. The alternative is to make sure that the conversion node that
we inject ends up exiting *backward* rather than forward.

But making the conversion nodes exit backward is somewhat tricky. Before this patch,
conversion nodes always exit forward for SetLocals and backwards otherwise. It turns out
that the solution is to rationalize how we choose the speculation direciton for a
conversion node. The conversion node's speculation direction should be the same as the
speculation direction of the node for which it is doing a conversion. Since SetLocal's
already exit forward by default, this policy preserves our previous behavior. But it
also allows the OSR entrypoint creation phase to make its SetLocals exit backward
instead.

Of course, if the SetLocal(ExtractOSREntryLocal) sequences exit backward, then we need
to make sure that the OSR exit machine knows that the local variables are indeed live.
Consider that if we have:

    a: ExtractOSREntryLocal(loc1)
    b: SetLocal(@a, loc1)
    c: ExtractOSRentryLocal(loc2)
    d: SetLocal(@c, loc2)

Without additional magic, the exit at @b will think that loc2 is dead and the OSR exit
compiler will clobber loc2 with Undefined. So we need to make sure that we actually
emit code like:

    a: ExtractOSREntryLocal(loc1)
    b: ExtractOSREntryLocal(loc2)
    c: SetLocal(@a, loc1)
    d: SetLocal(@b, loc2)
    e: SetLocal(@a, loc1)
    f: SetLocal(@b, loc2)

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* bytecode/CodeOrigin.h:
* bytecode/ValueRecovery.cpp: Added.
(JSC::ValueRecovery::recover):
(JSC::ValueRecovery::dumpInContext):
(JSC::ValueRecovery::dump):
* bytecode/ValueRecovery.h:
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupSetLocalsInBlock):
(JSC::DFG::FixupPhase::fixEdge):
* dfg/DFGJITCode.cpp:
(JSC::DFG::JITCode::reconstruct):
* dfg/DFGNode.h:
(JSC::DFG::Node::speculationDirection):
(JSC::DFG::Node::setSpeculationDirection):
* dfg/DFGOSREntrypointCreationPhase.cpp:
(JSC::DFG::OSREntrypointCreationPhase::run):
* dfg/DFGOSRExitCompiler32_64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileInlineStart):
(JSC::DFG::SpeculativeJIT::computeValueRecoveryFor):
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::computeValueRecoveryFor):
* dfg/DFGValueSource.h:
(JSC::DFG::ValueSource::valueRecovery):
* dfg/DFGVariableEventStream.cpp:
(JSC::DFG::VariableEventStream::reconstruct):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::speculate):
(JSC::FTL::LowerDFGToLLVM::speculateMachineInt):
* interpreter/Register.h:
(JSC::Register::unboxedStrictInt52):
* runtime/Arguments.cpp:
(JSC::Arguments::tearOff):
* runtime/Arguments.h:

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

6 years agoRemove IDBTracing.h.
beidson@apple.com [Mon, 30 Sep 2013 20:32:21 +0000 (20:32 +0000)]
Remove IDBTracing.h.
https://bugs.webkit.org/show_bug.cgi?id=122118

Reviewed by Alexey Proskuryakov.

Global replace of "IDB_TRACE" with "LOG(StorageAPI)", and remove all notions of this header.

* GNUmakefile.list.am:

* Modules/indexeddb/IDBCursor.cpp:
* Modules/indexeddb/IDBDatabase.cpp:
* Modules/indexeddb/IDBDatabaseBackendInterface.h:
* Modules/indexeddb/IDBFactory.cpp:
* Modules/indexeddb/IDBIndex.cpp:
* Modules/indexeddb/IDBObjectStore.cpp:
* Modules/indexeddb/IDBOpenDBRequest.cpp:
* Modules/indexeddb/IDBRequest.cpp:
* Modules/indexeddb/IDBTracing.h: Removed.
* Modules/indexeddb/IDBTransaction.cpp:
* Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
* Modules/indexeddb/leveldb/IDBCursorBackendLevelDB.cpp:
* Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.cpp:
* Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
* Modules/indexeddb/leveldb/IDBObjectStoreBackendLevelDB.cpp:
* Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.cpp:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/IDBBindingUtilities.cpp:

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

6 years agoWeb Inspector: rows in the Layer sidebar panel may have the incorrect background...
graouts@apple.com [Mon, 30 Sep 2013 20:10:14 +0000 (20:10 +0000)]
Web Inspector: rows in the Layer sidebar panel may have the incorrect background color
https://bugs.webkit.org/show_bug.cgi?id=122108

Reviewed by Darin Adler.

The LayerTreeDataGrid is a custom DataGrid subclass which exposes a .setChildren() method
used to sort chidren without DOM order manipulation, for performance reason. However, since
the way the alternating background color is usually implemented is based on the built-in
CSS pseudo-classes working with DOM order, the background colors of nodes in the LayerTreeDataGrid
can be incorrect depending on the sort order and the number of nodes. To fix this, we now manually
set "even" and "odd" CSS classes on those nodes when they're sorted such that we have a chance
to style them as intended.

* UserInterface/LayerTreeDataGrid.js:
(WebInspector.LayerTreeDataGrid.prototype._updateChildren):
Check if the data grid node index is even or odd and reflect this via an exclusive "even"
or "odd" CSS class name.

* UserInterface/LayerTreeSidebarPanel.css:
(.layer-tree.panel .data-container tbody > tr.even):
(.layer-tree.panel .data-container tbody > tr.odd):
Apply alternating colors based on the exclusive "even" and "odd" CSS class names as applied in
WebInspector.LayerTreeDataGrid.prototype._updateChildren().

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

6 years ago[Windows] Unreviewed build fix for Win64.
alex.christensen@flexsim.com [Mon, 30 Sep 2013 20:07:35 +0000 (20:07 +0000)]
[Windows] Unreviewed build fix for Win64.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in:
Added correct 64-bit BitmapImage::create symbol.

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

6 years agoWeb Inspector: Popover displaying "reasons for compositing" may remain on screen...
graouts@apple.com [Mon, 30 Sep 2013 20:07:10 +0000 (20:07 +0000)]
Web Inspector: Popover displaying "reasons for compositing" may remain on screen after selected layer is removed
https://bugs.webkit.org/show_bug.cgi?id=117575

Ensure the popover attached to the selected data grid node is updated when the
content or sort order of the Layer sidebar panel is updated.

Reviewed by Darin Adler.

* UserInterface/LayerTreeSidebarPanel.js:
(WebInspector.LayerTreeSidebarPanel.prototype._sortDataGrid):

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

6 years agoWeb Inspector: nodes can be dragged from the console log
graouts@apple.com [Mon, 30 Sep 2013 20:06:06 +0000 (20:06 +0000)]
Web Inspector: nodes can be dragged from the console log
https://bugs.webkit.org/show_bug.cgi?id=122105

Reviewed by Darin Adler.

Catch "dragstart" events targeting nodes hosted in a DOMTreeOutline within the console
log view and prevent the default logic to trigger so that these nodes can't be dragged
off the console as it wouldn't make sense to.

* UserInterface/DOMTreeOutline.js:
(WebInspector.DOMTreeOutline):
Create a class property to allow the CSS class name to be used in WebInspector.LogContentView.

* UserInterface/LogContentView.js:
(WebInspector.LogContentView):
(WebInspector.LogContentView.prototype._ondragstart):
Track the "dragstart" events in their capture phase such that, if the event target is
a DOM node hosted in a DOMTreeOutline, we can prevent the event from propagating and
cancel its default behavior such that no dragging at all is performed.

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

6 years agoWin64 compile fix after r1256490.
alex.christensen@flexsim.com [Mon, 30 Sep 2013 19:51:43 +0000 (19:51 +0000)]
Win64 compile fix after r1256490.
https://bugs.webkit.org/show_bug.cgi?id=122117

Patch by Alex Christensen <alex.christensen@flexsim.com> on 2013-09-30
Reviewed by Michael Saboff.

* jit/JITStubsMSVC64.asm:
Implemented getHostCallReturnValue for Windows x86_64 processors.

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

6 years agoNetworkResourceLoader.messages.in should be ENABLE(NETWORK_PROCESS) guarded
ossy@webkit.org [Mon, 30 Sep 2013 19:44:51 +0000 (19:44 +0000)]
NetworkResourceLoader.messages.in should be ENABLE(NETWORK_PROCESS) guarded
https://bugs.webkit.org/show_bug.cgi?id=122110

Reviewed by Darin Adler.

* NetworkProcess/NetworkResourceLoader.messages.in:

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

6 years ago[Windows] Build fix after r156622. Build RenderLayerModelObject.cpp in a separate...
bfulgham@apple.com [Mon, 30 Sep 2013 19:35:54 +0000 (19:35 +0000)]
[Windows] Build fix after r156622. Build RenderLayerModelObject.cpp in a separate compilation unit
from the RenderLayerAllnOne file so that the scalar and vector destructors are visible to other
elements of WebCore during the build.

* WebCore.vcxproj/WebCore.vcxproj: Compile RenderLayerModelObject outside of the all-in-one file.
* WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
* rendering/RenderingAllInOne.cpp: Remove RenderLayerModelObject.cpp.

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

6 years agoPass VM instead of JSGlobalObject to RegExp constructor.
akling@apple.com [Mon, 30 Sep 2013 18:58:51 +0000 (18:58 +0000)]
Pass VM instead of JSGlobalObject to RegExp constructor.
<https://webkit.org/b/122113>

Reviewed by Darin Adler.

RegExps don't need anything from the global object during their
construction and only use it to get to the VM. Reduce loads by
simply passing the VM around instead.

JSC release binary size -= 120 bytes(!)

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

6 years ago[Win] Compile errors in WebKit (via peavo@outlook.com).
bfulgham@apple.com [Mon, 30 Sep 2013 18:13:27 +0000 (18:13 +0000)]
[Win] Compile errors in WebKit (via peavo@outlook.com).
https://bugs.webkit.org/show_bug.cgi?id=122106

Reviewed by Darin Adler.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in: Add link
declarations missed in r156655.

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

6 years agoFix the build when building against an SDK.
mrowe@apple.com [Mon, 30 Sep 2013 18:09:55 +0000 (18:09 +0000)]
Fix the build when building against an SDK.

Xcode helpfully prepends $(SDKROOT) to the paths in FRAMEWORK_SEARCH_PATHS when generating
the compiler command lines. It can't know to do this for the system framework search paths
we add manually via OTHER_CFLAGS though, so we need to prefix them with $(SDKROOT) ourself.

Source/WebCore:

* Configurations/WebCore.xcconfig:

Source/WebKit/mac:

* Configurations/WebKit.xcconfig:

Source/WebKit2:

* Configurations/BaseTarget.xcconfig:

Tools:

* DumpRenderTree/mac/Configurations/BaseTarget.xcconfig:
* WebKitTestRunner/Configurations/BaseTarget.xcconfig:

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

6 years ago[Windows] Unreviewed build fix.
bfulgham@apple.com [Mon, 30 Sep 2013 17:58:27 +0000 (17:58 +0000)]
[Windows] Unreviewed build fix.

* WebCore.vcxproj/WebCore.vcxproj.filters: Correct malformed XML in project files.

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

6 years agoUnreviewed, roll back in r156546 with rebaselined tests.
jer.noble@apple.com [Mon, 30 Sep 2013 17:56:35 +0000 (17:56 +0000)]
Unreviewed, roll back in r156546 with rebaselined tests.
https://bugs.webkit.org/show_bug.cgi?id=122111

Source/WebCore:

* Modules/mediacontrols/mediaControlsApple.js:
(Controller):
(Controller.prototype.addVideoListeners):
(Controller.prototype.removeVideoListeners):
(Controller.prototype.updateHasAudio):

LayoutTests:

* platform/mac/TestExpectations:
* platform/mac/fast/hidpi/video-controls-in-hidpi-expected.png:
* platform/mac/fast/hidpi/video-controls-in-hidpi-expected.txt:
* platform/mac/fast/layers/video-layer-expected.png:
* platform/mac/fast/layers/video-layer-expected.txt:
* platform/mac/media/media-controls-clone-expected.png:
* platform/mac/media/media-controls-clone-expected.txt:
* platform/mac/media/video-no-audio-expected.txt:

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

6 years agoediting/execCommand/findString-diacriticals.html expects to fail
commit-queue@webkit.org [Mon, 30 Sep 2013 17:38:02 +0000 (17:38 +0000)]
editing/execCommand/findString-diacriticals.html expects to fail
https://bugs.webkit.org/show_bug.cgi?id=122100

Patch by Robert Plociennik <r.plociennik@samsung.com> on 2013-09-30
Reviewed by Alexey Proskuryakov.

Since all major platforms pass editing/execCommand/findString-diacriticals.html,
the test now globally expects "PASS" instead of "FAIL" rendering the individual
platform expectation files obsolete.

* editing/execCommand/findString-diacriticals-expected.txt: "PASS" -> "FAIL"
* platform/efl/TestExpectations: EFL passes editing/execCommand/findString-diacriticals.
* platform/gtk/editing/execCommand/findString-diacriticals-expected.txt: Removed.
* platform/mac/editing/execCommand/findString-diacriticals-expected.txt: Removed.
* platform/qt/editing/execCommand/findString-diacriticals-expected.txt: Removed.

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

6 years ago[Windows] Unreviewed test fix. Prevent crash when changing URL paths during testing.
bfulgham@apple.com [Mon, 30 Sep 2013 17:36:54 +0000 (17:36 +0000)]
[Windows] Unreviewed test fix. Prevent crash when changing URL paths during testing.

A shared BSTR value (_bstr_t) was being reallocated outside the smart pointer, causing
it to be double-freed.

* WinLauncher/WinLauncher.cpp:
(EditProc): Be explicit about type passed to loadURL.
(loadURL): Create a shallow copy of the BSTR so we only allocate memory if needed. Use _bstr_t so
that reallocating the BSTR is done with the knowledge of the smart pointer.

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

6 years agoUnreviewed, rolling out r156656.
commit-queue@webkit.org [Mon, 30 Sep 2013 16:59:35 +0000 (16:59 +0000)]
Unreviewed, rolling out r156656.
http://trac.webkit.org/changeset/156656
https://bugs.webkit.org/show_bug.cgi?id=122111

Broke several media tests (Requested by ap on #webkit).

Source/WebCore:

* Modules/mediacontrols/mediaControlsApple.js:
(Controller):
(Controller.prototype.addVideoListeners):
(Controller.prototype.removeVideoListeners):

LayoutTests:

* platform/mac/TestExpectations:
* platform/mac/media/video-no-audio-expected.txt:

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

6 years agoConvert a bunch of OwnPtrs on Page to std::unique_ptrs
weinig@apple.com [Mon, 30 Sep 2013 16:50:34 +0000 (16:50 +0000)]
Convert a bunch of OwnPtrs on Page to std::unique_ptrs
https://bugs.webkit.org/show_bug.cgi?id=122086

Reviewed by Darin Adler.

* loader/ProgressTracker.cpp:
* loader/ProgressTracker.h:
* page/Page.cpp:
(WebCore::Page::Page):
(WebCore::Page::setGroupName):
(WebCore::Page::initGroup):
* page/Page.h:
* page/PageGroup.cpp:
(WebCore::PageGroup::PageGroup):
* page/PageGroup.h:

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

6 years ago[EFL] Changed expectation for accessibility/file-upload-button-stringvalue.html after...
commit-queue@webkit.org [Mon, 30 Sep 2013 16:32:07 +0000 (16:32 +0000)]
[EFL] Changed expectation for accessibility/file-upload-button-stringvalue.html after r156532
https://bugs.webkit.org/show_bug.cgi?id=122103

Unreviewed EFL gardening.

Patch by Krzysztof Czech <k.czech@samsung.com> on 2013-09-30

* platform/efl-wk1/TestExpectations: file-upload-button-stringvalue.html fails on efl-wk1.
Unskipped accessibility/heading-level.html. It passes after r156551.
* platform/efl-wk2/accessibility/file-upload-button-stringvalue-expected.txt:

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

6 years ago[Qt] Fix force_static_libs_as_shared in WebKit2
allan.jensen@digia.com [Mon, 30 Sep 2013 16:30:46 +0000 (16:30 +0000)]
[Qt] Fix force_static_libs_as_shared in WebKit2
https://bugs.webkit.org/show_bug.cgi?id=121961

Reviewed by Csaba Osztrogon√°c.

Get rid of the unused WebKit2QML library

.:

* Source/api.pri:

Source/WebKit2:

* Target.pri:
* WebKit2.pro:
* WebKit2QML.pri: Removed.

Tools:

* qmake/mkspecs/features/webkit_modules.prf:
* qmake/mkspecs/modules/webkit2qml.prf: Removed.

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

6 years agoRemove FontTranscoder
antti@apple.com [Mon, 30 Sep 2013 16:21:54 +0000 (16:21 +0000)]
Remove FontTranscoder
https://bugs.webkit.org/show_bug.cgi?id=122088

Reviewed by Andreas Kling.

This overly generic class just implements mapping of backslash to yen symbol for some legacy Japanese fonts.

* CMakeLists.txt:
* GNUmakefile.am:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.pri:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.xcodeproj/project.pbxproj:
* platform/graphics/Font.cpp:
(WebCore::useBackslashAsYenSignForFamily):

    Move the family set to Font.cpp.

(WebCore::Font::Font):
(WebCore::Font::operator=):
(WebCore::Font::update):

    Keep the cached boolean up to date.

* platform/graphics/Font.h:
(WebCore::Font::useBackslashAsYenSymbol):

    Use descriptive name instead of talking about "transcoding".

* platform/text/transcoder: Removed.
* platform/text/transcoder/FontTranscoder.cpp: Removed.
* platform/text/transcoder/FontTranscoder.h: Removed.
* rendering/RenderText.cpp:
(WebCore::RenderText::RenderText):
(WebCore::RenderText::computeUseBackslashAsYenSymbol):

    Rename for clarity.
    Avoid unnecessary hash lookup, just check the cached bit in Font.

(WebCore::RenderText::styleDidChange):
(WebCore::RenderText::setTextInternal):

    "Transcoding" here was just a simple character replacement.

(WebCore::RenderText::textWithoutConvertingBackslashToYenSymbol):

    Renamed.

* rendering/RenderText.h:

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

6 years agoREGRESSION(r156546): media/video-no-audio.html broken
jer.noble@apple.com [Mon, 30 Sep 2013 16:09:37 +0000 (16:09 +0000)]
REGRESSION(r156546): media/video-no-audio.html broken
https://bugs.webkit.org/show_bug.cgi?id=122049

Reviewed by Eric Carlson.

Source/WebCore:

Now that our video elements have audio tracks, use their presence or
absense to show or hide the volume controls.

* Modules/mediacontrols/mediaControlsApple.js:
(Controller):
(Controller.prototype.addVideoListeners): Listen for audioTrack changes.
(Controller.prototype.removeVideoListeners): Stop listening to same.
(Controller.prototype.handleAudioTrackChange): Call this.updateHasAudio()
(Controller.prototype.handleAudioTrackAdd): Ditto.
(Controller.prototype.handleAudioTrackRemove): Ditto.
(Controller.prototype.updateHasAudio): Hide the volume controls if no
    audioTracks are present, and vice versa.

LayoutTests:

* platform/mac/TestExpectations:
* platform/mac/media/video-no-audio-expected.txt:

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

6 years agoTry to fix the Windows build.
akling@apple.com [Mon, 30 Sep 2013 15:43:34 +0000 (15:43 +0000)]
Try to fix the Windows build.

* WebFrame.cpp:
(WebFrame::pauseAnimation):
(WebFrame::pauseTransition):

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

6 years agoFix compilation for COMPILER(MSVC) && !CPU(X86) after r156490.
paroga@webkit.org [Mon, 30 Sep 2013 15:42:49 +0000 (15:42 +0000)]
Fix compilation for COMPILER(MSVC) && !CPU(X86) after r156490.
https://bugs.webkit.org/show_bug.cgi?id=122102

Reviewed by Geoffrey Garen.

_AddressOfReturnAddress() is supported for all platforms of
ths Microsoft compiler, so we can use it for !CPU(X86) too.

* jit/JITOperationWrappers.h:

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

6 years agoUnreviewed Mac-Lion build fix.
jer.noble@apple.com [Mon, 30 Sep 2013 15:39:10 +0000 (15:39 +0000)]
Unreviewed Mac-Lion build fix.

Use metadataItemsFromArray:withLocale: instead of
metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:
on Lion and earlier.

* platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm:
(WebCore::AudioTrackPrivateAVFObjC::resetPropertiesFromTrack):

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

6 years ago[Mac] Add AudioTrack support to MediaPlayerPrivateAVFObC.
jer.noble@apple.com [Mon, 30 Sep 2013 15:17:28 +0000 (15:17 +0000)]
[Mac] Add AudioTrack support to MediaPlayerPrivateAVFObC.
https://bugs.webkit.org/show_bug.cgi?id=122043

Reviewed by Eric Carlson.

Source/WebCore:

Test: media/track/audio-track.html

Add a new class AudioTrackPrivateAVF and subclass AudioTrackPrivateAVFObjC
which are backed by a AVPlayerItemTrack. Create one of these tracks when
we are notified that the list of available tracks has changed.

* WebCore.xcodeproj/project.pbxproj:
* html/track/AudioTrack.cpp:
(WebCore::AudioTrack::setEnabled): Pass through to the AudioTrackPrivate
    so that the underlying media track can be (dis|en)abled.
* platform/graphics/avfoundation/AudioTrackPrivateAVF.h: Added.
(WebCore::AudioTrackPrivateAVF::kind): Simple getter.
(WebCore::AudioTrackPrivateAVF::id): Ditto.
(WebCore::AudioTrackPrivateAVF::label): Ditto.
(WebCore::AudioTrackPrivateAVF::language): Ditto.
(WebCore::AudioTrackPrivateAVF::setKind): Simple Setter.
(WebCore::AudioTrackPrivateAVF::setId): Ditto.
(WebCore::AudioTrackPrivateAVF::setLabel): Ditto.
(WebCore::AudioTrackPrivateAVF::setLanguage): Ditto.
(WebCore::AudioTrackPrivateAVF::AudioTrackPrivateAVF): Simple constructor.
* platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.h: Added.
(WebCore::AudioTrackPrivateAVFObjC::create): Simple factory.
(WebCore::AudioTrackPrivateAVFObjC::playerItemTrack): Simple getter.
* platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm: Added.
(WebCore::AudioTrackPrivateAVFObjC::AudioTrackPrivateAVFObjC): Call resetPropertiesFromTrack.
(WebCore::AudioTrackPrivateAVFObjC::resetPropertiesFromTrack): Fill out the values from
    the associated AVPlayerItemTrack and its AVAssetTrack.
(WebCore::AudioTrackPrivateAVFObjC::setPlayerItemTrack): Call resetPropertiesFromTrack.
(WebCore::AudioTrackPrivateAVFObjC::setEnabled): (En|Dis)able the AVPlayerItemTrack.
(WebCore::AudioTrackPrivateAVFObjC::languageForAVAssetTrack): Refactored from
    MediaPlayerPrivateAVFoundationObjC::languageOfPrimaryAudioTrack.
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Determine which tracks
    have been added or removed and notify the clients accordingly.
(WebCore::MediaPlayerPrivateAVFoundationObjC::languageOfPrimaryAudioTrack): Refactor into
    AudioTrackPrivateAVFObjC::languageForAVAssetTrack.

LayoutTests:

* media/track/audio-track-expected.txt: Added.
* media/track/audio-track.html: Added.

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

6 years ago[EFL] Added passing expectation for fast/forms/textarea-metrics.html
commit-queue@webkit.org [Mon, 30 Sep 2013 14:57:23 +0000 (14:57 +0000)]
[EFL] Added passing expectation for fast/forms/textarea-metrics.html
https://bugs.webkit.org/show_bug.cgi?id=122107

Unreviewed EFL gardening.

fast/forms/textarea-metrics.html fails in WebKitTestRunner but returns expected
results in MiniBrowser. Since GTK uses platform dependent expectation file to
migitate this identical discrepancy, the same solution has been applied to EFL.

Patch by Robert Plociennik <r.plociennik@samsung.com> on 2013-09-30

* platform/efl/TestExpectations:
* platform/efl/fast/forms/textarea-metrics-expected.txt: Added.

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

6 years agoUnreviewed WinCE build fix after r153927.
paroga@webkit.org [Mon, 30 Sep 2013 14:05:46 +0000 (14:05 +0000)]
Unreviewed WinCE build fix after r153927.

* WebView.cpp:
(WebView::WebView):

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

6 years agoUnreviewed WinCE build fix after r155289.
paroga@webkit.org [Mon, 30 Sep 2013 13:58:00 +0000 (13:58 +0000)]
Unreviewed WinCE build fix after r155289.

* WebCoreSupport/FrameLoaderClientWinCE.cpp:
(WebKit::FrameLoaderClientWinCE::dispatchDecidePolicyForResponse):
(WebKit::FrameLoaderClientWinCE::dispatchDecidePolicyForNewWindowAction):
(WebKit::FrameLoaderClientWinCE::dispatchDecidePolicyForNavigationAction):
(WebKit::FrameLoaderClientWinCE::dispatchWillSubmitForm):

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

6 years agoUnreviewed WinCE build fix after r154178.
paroga@webkit.org [Mon, 30 Sep 2013 13:57:41 +0000 (13:57 +0000)]
Unreviewed WinCE build fix after r154178.

* WebView.cpp:
(WebView::wndProc):

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

6 years ago[EFL] Fix incorrect click counting in EventSenderProxy
commit-queue@webkit.org [Mon, 30 Sep 2013 13:15:31 +0000 (13:15 +0000)]
[EFL] Fix incorrect click counting in EventSenderProxy
https://bugs.webkit.org/show_bug.cgi?id=122098

Patch by Krzysztof Wolanski <k.wolanski@samsung.com> on 2013-09-30
Reviewed by Gyuyoung Kim.

Tools:

Previously used two types of recording time, which conflicted with each other.

* WebKitTestRunner/efl/EventSenderProxyEfl.cpp:
(WTR::EventSenderProxy::mouseUp):

LayoutTests:

After fixing EventSenderProxy extend-selection-after-double-click.html runs correctly.

* platform/efl/TestExpectations:

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

6 years ago[EFL] Gardening after the resolution of bug 84835
commit-queue@webkit.org [Mon, 30 Sep 2013 11:49:19 +0000 (11:49 +0000)]
[EFL] Gardening after the resolution of bug 84835
https://bugs.webkit.org/show_bug.cgi?id=122096

Unreviewed EFL gardening.

Removed expected failures for bug 84835.
editing/pasteboard/copy-inside-h1-preserves-h1 and
editing/pasteboard/copy-without-selection are still failing due to bug 86623
and have been marked accordingly.

Patch by Robert Plociennik <r.plociennik@samsung.com> on 2013-09-30

* platform/efl-wk1/TestExpectations:
* platform/efl/TestExpectations:

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

6 years agoUnreviewed GTK gardening. Two tests are passing in WK2 after r156541.
mario@webkit.org [Mon, 30 Sep 2013 10:56:08 +0000 (10:56 +0000)]
Unreviewed GTK gardening. Two tests are passing in WK2 after r156541.

* platform/gtk-wk2/TestExpectations: Removed passing tests.

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

6 years ago[EFL] Accessibility tests pass after r156532 and r156551
commit-queue@webkit.org [Mon, 30 Sep 2013 10:46:52 +0000 (10:46 +0000)]
[EFL] Accessibility tests pass after r156532 and r156551
https://bugs.webkit.org/show_bug.cgi?id=122090

Unreviewed EFL gardening.

Patch by Krzysztof Czech <k.czech@samsung.com> on 2013-09-30

* platform/efl-wk2/TestExpectations:

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

6 years ago[EFL] New test accessibility/table-with-hidden-head-section.html failing on EFL port
commit-queue@webkit.org [Mon, 30 Sep 2013 10:44:57 +0000 (10:44 +0000)]
[EFL] New test accessibility/table-with-hidden-head-section.html failing on EFL port
https://bugs.webkit.org/show_bug.cgi?id=111850

Patch by Krzysztof Czech <k.czech@samsung.com> on 2013-09-30
Reviewed by Mario Sanchez Prada.

Test passes after r156532.

* platform/efl/TestExpectations:

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

6 years agoGenerate toCSSCalcValue instead of using manual cast function
gyuyoung.kim@samsung.com [Mon, 30 Sep 2013 10:39:08 +0000 (10:39 +0000)]
Generate toCSSCalcValue instead of using manual cast function
https://bugs.webkit.org/show_bug.cgi?id=122055

Reviewed by Antti Koivisto.

Generated type cast function supports more plenty functions rather than manual functions.
To use CSS_VALUE_TYPE_CAST, isCalculationValue() needs to be changed with isCalcValue().

No new tests, no behavior changes.

* css/CSSCalculationValue.h:
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/CSSValue.h:
(WebCore::CSSValue::isCalcValue):
* css/StyleResolver.cpp:
(WebCore::hasVariableReference):

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

6 years agoUnreviewed. Build fix for DEBUG_VERBOSE mode after r156511.
rgabor@webkit.org [Mon, 30 Sep 2013 09:33:34 +0000 (09:33 +0000)]
Unreviewed. Build fix for DEBUG_VERBOSE mode after r156511.

* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileCurrentBlock):

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

6 years ago[webkitpy] Make the Xvfb screen depth overridable
zandobersek@gmail.com [Mon, 30 Sep 2013 08:26:47 +0000 (08:26 +0000)]
[webkitpy] Make the Xvfb screen depth overridable
https://bugs.webkit.org/show_bug.cgi?id=122089

Reviewed by Gyuyoung Kim.

Make the Xvfb screen depth overridable by checking if the XVFB_SCREEN_DEPTH environment variable
was set. The default value that's used if the variable wasn't set is 24.

* Scripts/webkitpy/port/xvfbdriver.py:
(XvfbDriver._xvfb_screen_depth):
(XvfbDriver._start):
* Scripts/webkitpy/port/xvfbdriver_unittest.py:
(XvfbDriverTest.make_driver):
(XvfbDriverTest.test_start_no_pixel_tests):
(XvfbDriverTest.test_start_pixel_tests):
(XvfbDriverTest.test_start_arbitrary_worker_number):
(XvfbDriverTest.test_next_free_display):
(XvfbDriverTest.test_start_next_worker):

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

6 years agoGet rid of static map for marking ancestor line boxes dirty
antti@apple.com [Mon, 30 Sep 2013 08:21:34 +0000 (08:21 +0000)]
Get rid of static map for marking ancestor line boxes dirty
https://bugs.webkit.org/show_bug.cgi?id=122080

Reviewed by Andreas Kling.

This is ugly and shows up in profiles too. Use a bit in RenderElement instead.

* rendering/RenderBlock.h:
* rendering/RenderBlockFlow.h:

    Move dirtyLinesFromChangedChild down to RenderBlockFlow. It wouldn't do anything on other RenderBlocks.

* rendering/RenderElement.cpp:
(WebCore::RenderElement::RenderElement):
* rendering/RenderElement.h:

    Add m_ancestorLineBoxDirty bit. We have 32 unused bits here on 64bit systems.

(WebCore::RenderElement::dirtyLinesFromChangedChild):
(WebCore::RenderElement::ancestorLineBoxDirty):
(WebCore::RenderElement::setAncestorLineBoxDirty):
(WebCore::RenderObject::setNeedsLayout):
* rendering/RenderInline.h:
* rendering/RenderLineBoxList.cpp:
(WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):

    Tighten the interface.

* rendering/RenderLineBoxList.h:
* rendering/RenderObject.cpp:
(WebCore::RenderObject::willBeDestroyed):
* rendering/RenderObject.h:

    Remove the static map.

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

6 years ago[CSS Grid Layout] Implement the grid-area shorthand
svillar@igalia.com [Mon, 30 Sep 2013 08:14:41 +0000 (08:14 +0000)]
[CSS Grid Layout] Implement the grid-area shorthand
https://bugs.webkit.org/show_bug.cgi?id=103334

Reviewed by Andreas Kling.

Source/WebCore:

Based on Blink r151684 by <jchaffraix@chromium.org>

Test: fast/css-grid-layout/grid-item-area-get-set.html

Added support to specify grid positions using the
'-webkit-grid-area' shorthand. Named grid areas are still not
allowed, to be done in a follow up patch as it likely requires
'-webkit-grid-template' support.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::ComputedStyleExtractor::propertyValue):
* css/CSSParser.cpp:
(WebCore::CSSParser::parseValue):
(WebCore::CSSParser::parseGridItemPositionShorthand):
* css/CSSPropertyNames.in:
* css/StylePropertySet.cpp:
(WebCore::StylePropertySet::getPropertyValue):
* css/StylePropertyShorthand.cpp:
(WebCore::webkitGridAreaShorthand):
(WebCore::shorthandForProperty):
* css/StylePropertyShorthand.h:
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):

LayoutTests:

From Blink r151684 by <jchaffraix@chromium.org>

* fast/css-grid-layout/grid-item-area-get-set-expected.txt: Added.
* fast/css-grid-layout/grid-item-area-get-set.html: Added.

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

6 years agoUnreviewed. Speculative build fix on ARMv7 Thumb2 after r156490.
rgabor@webkit.org [Mon, 30 Sep 2013 08:10:12 +0000 (08:10 +0000)]
Unreviewed. Speculative build fix on ARMv7 Thumb2 after r156490.

* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::fmodAsDFGOperation):

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

6 years agoGenerate toCSSFooValue for CSSGradientValue, CSSLinearGradientValue and CSSRadialGradient
gyuyoung.kim@samsung.com [Mon, 30 Sep 2013 07:35:29 +0000 (07:35 +0000)]
Generate toCSSFooValue for CSSGradientValue, CSSLinearGradientValue and CSSRadialGradient
https://bugs.webkit.org/show_bug.cgi?id=122060

Reviewed by Antti Koivisto.

As a step to generate toCSSFooValue, toCSSGradientValuem toCSSLinearGradientValue and
toCSSRadialGradient are generated. isLinearGradient() and isRadialGradient() are moved
from each class to CSSValue in order to generate toCSSFooValue.

No new tests, no behavior change.

* css/CSSGradientValue.cpp:
(WebCore::CSSGradientValue::image):
(WebCore::CSSGradientValue::gradientWithStylesResolved):
* css/CSSGradientValue.h:
* css/CSSImageGeneratorValue.cpp:
(WebCore::CSSImageGeneratorValue::image):
(WebCore::CSSImageGeneratorValue::fixedSize):
(WebCore::CSSImageGeneratorValue::loadSubimages):
* css/CSSParser.cpp:
(WebCore::CSSParser::parseDeprecatedGradient):
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/CSSValue.h:
(WebCore::CSSValue::isLinearGradient):
(WebCore::CSSValue::isRadialGradient):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):
(WebCore::StyleResolver::styleImage):

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

6 years agouser-select: none cursor turns to I-beam on mouse dragging
commit-queue@webkit.org [Mon, 30 Sep 2013 07:12:44 +0000 (07:12 +0000)]
user-select: none cursor turns to I-beam on mouse dragging
https://bugs.webkit.org/show_bug.cgi?id=90159

Patch by Vani Hegde <vani.hegde@samsung.com> on 2013-09-30
Reviewed by Ryosuke Niwa.

Source/WebCore:

When tried to select some text in an area that has style
cursor:default set, cursor type changes to text cursor ignoring
the cursor style that is explicitly set.

When the cursor style is explicitly set as default (or something else),
we should not change it to text cursor no matter what we are over
or what operation we are performing (be it hovering over the text
or selecting the text).

During text selection, changing the cursor type to text only when
there is no explicit cursor type set fixes the issue.

Test: editing/caret/selection-with-caret-type-progress.html

* page/EventHandler.cpp:
(WebCore::EventHandler::selectCursor):
During selection, set the cursor style to text only if there is no
explicit cursor style set.

LayoutTests:

Test case added to verify that explicitly set cursor style
is retained on performing text selection.

* editing/caret/selection-with-caret-type-progress-expected.txt: Added.
* editing/caret/selection-with-caret-type-progress.html: Added.

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

6 years agoFTL: refactor compileAdd and compileArithSub into one function.
commit-queue@webkit.org [Mon, 30 Sep 2013 06:32:59 +0000 (06:32 +0000)]
FTL: refactor compileAdd and compileArithSub into one function.
https://bugs.webkit.org/show_bug.cgi?id=122081

Patch by Nadav Rotem <nrotem@apple.com> on 2013-09-29
Reviewed by Geoffrey Garen.

* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileNode):
(JSC::FTL::LowerDFGToLLVM::compileAddSub):

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

6 years agoGenerate toCSSFooValue() for CSSCanvasValue
gyuyoung.kim@samsung.com [Mon, 30 Sep 2013 05:40:57 +0000 (05:40 +0000)]
Generate toCSSFooValue() for CSSCanvasValue
https://bugs.webkit.org/show_bug.cgi?id=122058

Reviewed by Antti Koivisto.

Generate toCSSFooValue() for CSSCanvasValue, and use it.
This type cast function will help to detect bad-casts.
isCanvasValue() is added in order to generate toCSSCanvasValue.

No new tests, no behavior change.

* css/CSSCanvasValue.h:
* css/CSSImageGeneratorValue.cpp:
(WebCore::CSSImageGeneratorValue::image):
(WebCore::CSSImageGeneratorValue::fixedSize):
(WebCore::CSSImageGeneratorValue::loadSubimages):
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/CSSValue.h:
(WebCore::CSSValue::isCanvasValue):

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

6 years agoTake some Xcode advice about turning on additional warnings in ANGLE and gtest
darin@apple.com [Mon, 30 Sep 2013 05:38:32 +0000 (05:38 +0000)]
Take some Xcode advice about turning on additional warnings in ANGLE and gtest
https://bugs.webkit.org/show_bug.cgi?id=122087

Reviewed by Mark Rowe.

Source/ThirdParty:

* gtest/xcode/Config/General.xcconfig: Added some warnings that Xcode 5 suggested.

Source/ThirdParty/ANGLE:

* Configurations/Base.xcconfig: Add some of the warnings that Xcode 5 suggested.
* src/compiler/preprocessor/Tokenizer.l: Defined YY_NO_INPUT so we don't compile
an unused function and get a warning.

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

6 years agoFix the Lion build.
mrowe@apple.com [Mon, 30 Sep 2013 05:30:50 +0000 (05:30 +0000)]
Fix the Lion build.

Ensure that C++ and Objective-C++ files build with the right compiler flags.

Source/WebCore:

* Configurations/WebCore.xcconfig:

Source/WebKit/mac:

* Configurations/WebKit.xcconfig:

Source/WebKit2:

* Configurations/BaseTarget.xcconfig:

Tools:

* DumpRenderTree/mac/Configurations/BaseTarget.xcconfig:
* WebKitTestRunner/Configurations/BaseTarget.xcconfig:

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

6 years agoGenerate toCSSFooValue() for CSSLineBoxContainValue
gyuyoung.kim@samsung.com [Mon, 30 Sep 2013 05:28:58 +0000 (05:28 +0000)]
Generate toCSSFooValue() for CSSLineBoxContainValue
https://bugs.webkit.org/show_bug.cgi?id=122054

Reviewed by Darin Adler.

As a step to use toCSSFooValue, toCSSLineBoxContainValue is generated by using
CSS_VALUE_TYPE_CASTS. To use it, isCSSLineBoxContainValue() is changed to
isLineBoxContatinValue(). Unnecessary local variable is removed by this patch.

No new tests, no behavior changes.

* css/CSSLineBoxContainValue.h:
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/CSSValue.h:
(WebCore::CSSValue::isLineBoxContainValue):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):

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

6 years agoGenerate toCSSCrossfadeValue() instead of using manual function
gyuyoung.kim@samsung.com [Mon, 30 Sep 2013 05:26:17 +0000 (05:26 +0000)]
Generate toCSSCrossfadeValue() instead of using manual function
https://bugs.webkit.org/show_bug.cgi?id=122057

Reviewed by Antti Koivisto.

Generated toCSSFooValue() supports more plenty functions rather than
to use manual cast function.

No new tests, no behavior changes.

* css/CSSCrossfadeValue.h:
* css/CSSImageGeneratorValue.cpp:
(WebCore::CSSImageGeneratorValue::image):
(WebCore::CSSImageGeneratorValue::fixedSize):
(WebCore::CSSImageGeneratorValue::loadSubimages):
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):

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

6 years agoGenerate toCSSFooValue() for CSSFilterImageValue and CSSInitialValue
gyuyoung.kim@samsung.com [Mon, 30 Sep 2013 05:22:22 +0000 (05:22 +0000)]
Generate toCSSFooValue() for CSSFilterImageValue and CSSInitialValue
https://bugs.webkit.org/show_bug.cgi?id=122056

Reviewed by Antti Koivisto.

Generate toCSSFooValue() for CSSFilterImageValue and CSSInitialValue, and use it.
This type cast function will help to detect bad-casts.

No new tests, no behavior changes.

* css/CSSFilterImageValue.h:
* css/CSSImageGeneratorValue.cpp:
(WebCore::CSSImageGeneratorValue::image):
(WebCore::CSSImageGeneratorValue::fixedSize):
(WebCore::CSSImageGeneratorValue::loadSubimages):
* css/CSSInitialValue.h:
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::generatedOrPendingFromValue):

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

6 years ago Fix crashes caused by my recent attempt at a Windows build fix.
darin@apple.com [Mon, 30 Sep 2013 04:57:41 +0000 (04:57 +0000)]
    Fix crashes caused by my recent attempt at a Windows build fix.

        * bindings/js/WebCoreTypedArrayController.cpp:
        (WebCore::WebCoreTypedArrayController::toJS): Added back the prefix for the call to
        WebCore::toJS, otherwise this function just calls itself infinitely recursively.

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

6 years agoFix the build.
weinig@apple.com [Mon, 30 Sep 2013 04:56:01 +0000 (04:56 +0000)]
Fix the build.

* WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
(WebKit::NPRuntimeObjectMap::evaluate):

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

6 years agoCleanup PageThrottler and PageConsole a bit
weinig@apple.com [Mon, 30 Sep 2013 04:36:35 +0000 (04:36 +0000)]
Cleanup PageThrottler and PageConsole a bit
https://bugs.webkit.org/show_bug.cgi?id=122085

Reviewed by Anders Carlsson.

* html/HTMLMediaElement.h:
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::completed):
* loader/FrameLoader.h:
* loader/SubresourceLoader.cpp:
(WebCore::SubresourceLoader::checkForHTTPStatusCodeError):
(WebCore::SubresourceLoader::didFinishLoading):
(WebCore::SubresourceLoader::didFail):
(WebCore::SubresourceLoader::willCancel):
* loader/SubresourceLoader.h:
Store the PageActivityAssertionToken as a std::unique_ptr.

* page/Page.cpp:
(WebCore::Page::Page):
Use createOwned and pass this by reference for the PageThrottler and PageConsole.
(WebCore::Page::~Page):
Remove unnecessary clearing of an OwnPtr that is about to be destroyed.
* page/Page.h:
Make m_pageThrottler const and return it as a reference.

* page/PageActivityAssertionToken.cpp:
(WebCore::PageActivityAssertionToken::PageActivityAssertionToken):
(WebCore::PageActivityAssertionToken::~PageActivityAssertionToken):
* page/PageActivityAssertionToken.h:
Take the PageThrottler by reference in the constructor. It is never null.

* page/PageConsole.cpp:
(WebCore::PageConsole::PageConsole):
(WebCore::PageConsole::~PageConsole):
(WebCore::PageConsole::addMessage):
* page/PageConsole.h:
Pass and store the Page as a reference and remove an extraneous null check. Remove
the create function.

* page/PageThrottler.cpp:
(WebCore::PageThrottler::PageThrottler):
(WebCore::PageThrottler::~PageThrottler):
(WebCore::PageThrottler::createActivityToken):
(WebCore::PageThrottler::throttlePage):
(WebCore::PageThrottler::unthrottlePage):
(WebCore::PageThrottler::addActivityToken):
(WebCore::PageThrottler::removeActivityToken):
* page/PageThrottler.h:
Pass and store the Page as a reference. Move the creation of PageActivityAssertionToken here
to aid encapsulation.

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

6 years agoPass VM instead of JSGlobalObject to function constructors.
akling@apple.com [Mon, 30 Sep 2013 03:45:30 +0000 (03:45 +0000)]
Pass VM instead of JSGlobalObject to function constructors.
<https://webkit.org/b/122082>

Reviewed by Darin Adler.

Functions don't need anything from the global object during their
construction and only use it to get to the VM. Reduce loads by
simply passing the VM around instead.

This patch is mostly mechanical, I just changed the signature of
InternalFunction and worked my way from there until it built.

JSC release binary size -= 4840 bytes.

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

6 years ago Try to fix Windows build.
darin@apple.com [Mon, 30 Sep 2013 02:54:57 +0000 (02:54 +0000)]
    Try to fix Windows build.

        * bindings/js/WebCoreTypedArrayController.cpp: Windows has a symbol named Handle, so we need
        to call JSC::Handle out by name. To fix that, I removed "using namespace JSC" entirely. And
        just for fun, sort of "rewrote" this file.
        (WebCore::WebCoreTypedArrayController::WebCoreTypedArrayController): Removed unneeded explicit
        initialization of m_owner.
        (WebCore::WebCoreTypedArrayController::~WebCoreTypedArrayController): Fixed formatting.
        (WebCore::WebCoreTypedArrayController::toJS): Added lots of explicit JSC and got rid of local.
        (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots): Cut
        down on locals, used auto& for type, and called it "wrapper" since that's what JSArrayBuffer is.
        (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::finalize): More of the same.

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

6 years agoUse RenderElement instead of RenderObject in many places
darin@apple.com [Mon, 30 Sep 2013 02:40:50 +0000 (02:40 +0000)]
Use RenderElement instead of RenderObject in many places
https://bugs.webkit.org/show_bug.cgi?id=122078

Reviewed by Andreas Kling.

Source/ThirdParty/ANGLE:

* ANGLE.xcodeproj/project.pbxproj: Let Xcode do its thing to this file.

Source/WebCore:

* WebCore.exp.in: Updated for name changes.

* dom/ContainerNode.h: Moved renderer() here from Element.
* dom/Element.h: Moved renderer() from here to ContainerNode.
* render/RenderElement.h: Moved renderer() from Element to ContainerNode.

* accessibility/AccessibilityImageMapLink.cpp:
(WebCore::AccessibilityImageMapLink::imageMapLinkRenderer):
(WebCore::AccessibilityImageMapLink::detachFromParent):
(WebCore::AccessibilityImageMapLink::elementPath):
(WebCore::AccessibilityImageMapLink::elementRect):
* accessibility/AccessibilityImageMapLink.h:
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
* bindings/objc/DOM.mm:
(-[DOMElement image]):
(-[DOMElement _font]):
(-[DOMElement _imageTIFFRepresentation]):
* css/CSSCanvasValue.cpp:
(WebCore::CSSCanvasValue::canvasChanged):
(WebCore::CSSCanvasValue::canvasResized):
(WebCore::CSSCanvasValue::canvasDestroyed):
(WebCore::CSSCanvasValue::fixedSize):
(WebCore::CSSCanvasValue::image):
* css/CSSCanvasValue.h:
* css/CSSComputedStyleDeclaration.cpp:
(WebCore::computeRenderStyleForProperty):
* css/CSSCrossfadeValue.cpp:
(WebCore::subimageKnownToBeOpaque):
(WebCore::CSSCrossfadeValue::fixedSize):
(WebCore::CSSCrossfadeValue::knownToBeOpaque):
(WebCore::CSSCrossfadeValue::image):
(WebCore::CSSCrossfadeValue::crossfadeChanged):
* css/CSSCrossfadeValue.h:
* css/CSSFilterImageValue.cpp:
(WebCore::CSSFilterImageValue::fixedSize):
(WebCore::CSSFilterImageValue::knownToBeOpaque):
(WebCore::CSSFilterImageValue::image):
(WebCore::CSSFilterImageValue::filterImageChanged):
* css/CSSFilterImageValue.h:
* css/CSSFontSelector.cpp:
* css/CSSGradientValue.cpp:
(WebCore::CSSGradientValue::image):
(WebCore::CSSGradientValue::addStops):
(WebCore::CSSGradientValue::knownToBeOpaque):
(WebCore::CSSLinearGradientValue::createGradient):
(WebCore::CSSRadialGradientValue::createGradient):
* css/CSSGradientValue.h:
(WebCore::CSSGradientValue::fixedSize):
* css/CSSImageGeneratorValue.cpp:
(WebCore::CSSImageGeneratorValue::addClient):
(WebCore::CSSImageGeneratorValue::removeClient):
(WebCore::CSSImageGeneratorValue::image):
(WebCore::CSSImageGeneratorValue::fixedSize):
(WebCore::CSSImageGeneratorValue::knownToBeOpaque):
* css/CSSImageGeneratorValue.h:
(WebCore::CSSImageGeneratorValue::clients):
* css/CSSImageValue.cpp:
(WebCore::CSSImageValue::knownToBeOpaque):
* css/CSSImageValue.h:
* css/DeprecatedStyleBuilder.cpp:
* dom/DocumentMarkerController.cpp:
(WebCore::DocumentMarkerController::removeMarkersFromList):
(WebCore::DocumentMarkerController::repaintMarkers):
* dom/Element.cpp:
(WebCore::localZoomForRenderer):
(WebCore::adjustForLocalZoom):
(WebCore::Element::offsetParent):
(WebCore::Element::updateExistingPseudoElement):
* dom/ElementRareData.h:
(WebCore::ElementRareData::create):
(WebCore::ElementRareData::ElementRareData):
* dom/Node.cpp:
(WebCore::Node::ensureRareData):
* editing/DeleteButtonController.cpp:
(WebCore::isDeletableElement):
* editing/Editor.cpp:
(WebCore::Editor::hasBidiSelection):
(WebCore::Editor::baseWritingDirectionForSelectionStart):
* editing/EditorCommand.cpp:
(WebCore::verticalScrollDistance):
* editing/htmlediting.cpp:
(WebCore::directionOfEnclosingBlock):
* editing/ios/EditorIOS.mm:
(WebCore::Editor::fontForSelection):
(WebCore::getImage):
* editing/mac/EditorMac.mm:
(WebCore::Editor::fontForSelection):
(WebCore::getImage):
* editing/markup.cpp:
* html/HTMLAreaElement.cpp:
(WebCore::HTMLAreaElement::computePath):
(WebCore::HTMLAreaElement::computeRect):
(WebCore::HTMLAreaElement::setFocus):
* html/HTMLAreaElement.h:
* html/HTMLCanvasElement.cpp:
(WebCore::HTMLCanvasElement::reset):
* html/HTMLElement.cpp:
(WebCore::HTMLElement::setInnerText):
* html/HTMLFormControlElement.cpp:
(WebCore::updateFromElementCallback):
* html/HTMLFormElement.cpp:
(WebCore::HTMLFormElement::rendererIsNeeded):
* html/HTMLFrameOwnerElement.h:
* html/HTMLImageElement.cpp:
(WebCore::HTMLImageElement::x):
(WebCore::HTMLImageElement::y):
(WebCore::HTMLImageElement::willRespondToMouseClickEvents):
* html/HTMLMapElement.cpp:
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::defaultEventHandler):
* html/HTMLMeterElement.cpp:
(WebCore::HTMLMeterElement::renderMeter):
* html/HTMLOptionElement.cpp:
(WebCore::HTMLOptionElement::didRecalcStyle):
* html/HTMLPlugInElement.cpp:
(WebCore::HTMLPlugInElement::willRespondToMouseClickEvents):
(WebCore::HTMLPlugInElement::defaultEventHandler):
(WebCore::HTMLPlugInElement::isKeyboardFocusable):
* html/HTMLPlugInImageElement.cpp:
(WebCore::HTMLPlugInImageElement::defaultEventHandler):
* html/HTMLProgressElement.cpp:
(WebCore::HTMLProgressElement::renderProgress):
* html/HTMLSelectElement.cpp:
(WebCore::HTMLSelectElement::scrollToSelection):
(WebCore::HTMLSelectElement::setOptionsChangedOnRenderer):
(WebCore::HTMLSelectElement::selectOption):
* html/HTMLTableCellElement.cpp:
(WebCore::HTMLTableCellElement::cellAbove):
* html/HTMLTextFormControlElement.cpp:
(WebCore::hasVisibleTextArea):
(WebCore::HTMLTextFormControlElement::setSelectionRange):
* html/InputType.h:
* html/parser/HTMLResourcePreloader.cpp:
* html/shadow/MediaControlElementTypes.cpp:
(WebCore::MediaControlElement::setDisplayType):
* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlPanelElement::startDrag):
(WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
* html/shadow/MeterShadowElement.cpp:
(WebCore::MeterShadowElement::rendererIsNeeded):
(WebCore::MeterInnerElement::rendererIsNeeded):
* inspector/InspectorOverlay.cpp:
* inspector/InspectorTimelineAgent.cpp:
* inspector/InspectorTimelineAgent.h:
* loader/ImageLoader.cpp:
(WebCore::ImageLoader::renderImageResource):
* loader/cache/CachedImage.cpp:
(WebCore::CachedImage::currentFrameKnownToBeOpaque):
* loader/cache/CachedImage.h:
* mathml/MathMLElement.cpp:
* page/ContextMenuController.cpp:
* page/DragController.cpp:
(WebCore::DragController::draggableElement):
* page/EventHandler.cpp:
(WebCore::EventHandler::EventHandler):
(WebCore::EventHandler::clear):
(WebCore::EventHandler::startPanScrolling):
(WebCore::EventHandler::autoscrollRenderer):
(WebCore::EventHandler::scrollOverflow):
(WebCore::EventHandler::logicalScrollOverflow):
(WebCore::EventHandler::subframeForTargetNode):
(WebCore::EventHandler::selectCursor):
(WebCore::layerForNode):
(WebCore::EventHandler::handleWheelEvent):
(WebCore::EventHandler::clearGestureScrollNodes):
* page/EventHandler.h:
* page/FocusController.cpp:
* page/Frame.cpp:
(WebCore::Frame::ownerRenderer):
(WebCore::Frame::visiblePositionForPoint):
(WebCore::Frame::nodeImage):
* page/FrameView.cpp:
(WebCore::FrameView::applyOverflowToViewport):
(WebCore::FrameView::applyPaginationToViewport):
(WebCore::FrameView::calculateScrollbarModesForLayout):
(WebCore::FrameView::isEnclosedInCompositingLayer):
(WebCore::FrameView::embeddedContentBox):
(WebCore::FrameView::addSlowRepaintObject):
(WebCore::FrameView::removeSlowRepaintObject):
(WebCore::FrameView::addViewportConstrainedObject):
(WebCore::FrameView::removeViewportConstrainedObject):
(WebCore::FrameView::scrollContentsFastPath):
(WebCore::FrameView::repaintSlowRepaintObjects):
(WebCore::FrameView::setViewportConstrainedObjectsNeedLayout):
(WebCore::FrameView::updateOverflowStatus):
(WebCore::FrameView::updateScrollCorner):
(WebCore::FrameView::paintContents):
(WebCore::FrameView::convertFromRenderer):
(WebCore::FrameView::convertToRenderer):
* page/FrameView.h:
* page/PageSerializer.cpp:
(WebCore::PageSerializer::addImageToResources):
* page/PageSerializer.h:
* page/animation/AnimationBase.cpp:
(WebCore::AnimationBase::AnimationBase):
(WebCore::AnimationBase::updateStateMachine):
* page/animation/AnimationBase.h:
(WebCore::AnimationBase::renderer):
* page/animation/AnimationController.cpp:
(WebCore::AnimationControllerPrivate::ensureCompositeAnimation):
(WebCore::AnimationControllerPrivate::clear):
(WebCore::AnimationControllerPrivate::updateAnimations):
(WebCore::AnimationControllerPrivate::updateAnimationTimerForRenderer):
(WebCore::AnimationControllerPrivate::isRunningAnimationOnRenderer):
(WebCore::AnimationControllerPrivate::isRunningAcceleratedAnimationOnRenderer):
(WebCore::AnimationControllerPrivate::suspendAnimationsForDocument):
(WebCore::AnimationControllerPrivate::resumeAnimationsForDocument):
(WebCore::AnimationControllerPrivate::pauseAnimationAtTime):
(WebCore::AnimationControllerPrivate::pauseTransitionAtTime):
(WebCore::AnimationControllerPrivate::getAnimatedStyleForRenderer):
(WebCore::AnimationControllerPrivate::numberOfActiveAnimations):
(WebCore::AnimationController::cancelAnimations):
(WebCore::AnimationController::updateAnimations):
(WebCore::AnimationController::getAnimatedStyleForRenderer):
(WebCore::AnimationController::notifyAnimationStarted):
(WebCore::AnimationController::pauseAnimationAtTime):
(WebCore::AnimationController::pauseTransitionAtTime):
(WebCore::AnimationController::isRunningAnimationOnRenderer):
(WebCore::AnimationController::isRunningAcceleratedAnimationOnRenderer):
* page/animation/AnimationController.h:
* page/animation/AnimationControllerPrivate.h:
* page/animation/CSSPropertyAnimation.cpp:
(WebCore::crossfadeBlend):
* page/animation/CompositeAnimation.cpp:
(WebCore::CompositeAnimation::updateTransitions):
(WebCore::CompositeAnimation::updateKeyframeAnimations):
(WebCore::CompositeAnimation::animate):
* page/animation/CompositeAnimation.h:
* page/animation/ImplicitAnimation.cpp:
(WebCore::ImplicitAnimation::ImplicitAnimation):
(WebCore::ImplicitAnimation::animate):
(WebCore::ImplicitAnimation::pauseAnimation):
(WebCore::ImplicitAnimation::sendTransitionEvent):
* page/animation/ImplicitAnimation.h:
(WebCore::ImplicitAnimation::create):
* page/animation/KeyframeAnimation.cpp:
(WebCore::KeyframeAnimation::KeyframeAnimation):
(WebCore::KeyframeAnimation::animate):
(WebCore::KeyframeAnimation::pauseAnimation):
(WebCore::KeyframeAnimation::endAnimation):
(WebCore::KeyframeAnimation::sendAnimationEvent):
* page/animation/KeyframeAnimation.h:
* page/mac/EventHandlerMac.mm:
(WebCore::EventHandler::passWidgetMouseDownEventToWidget):
(WebCore::EventHandler::passSubframeEventToSubframe):
* page/mac/FrameSnapshottingMac.mm:
(WebCore::snapshotDragImage):
* platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
(WebCore::MediaPlayerPrivateQTKit::paint):
* rendering/CounterNode.cpp:
(WebCore::CounterNode::CounterNode):
(WebCore::CounterNode::create):
* rendering/CounterNode.h:
(WebCore::CounterNode::owner):
* rendering/FilterEffectRenderer.cpp:
(WebCore::FilterEffectRenderer::buildReferenceFilter):
(WebCore::FilterEffectRenderer::build):
* rendering/FilterEffectRenderer.h:
* rendering/HitTestResult.cpp:
(WebCore::HitTestResult::spellingToolTip):
(WebCore::HitTestResult::title):
(WebCore::HitTestResult::innerTextIfTruncated):
(WebCore::HitTestResult::image):
* rendering/LayoutRepainter.cpp:
(WebCore::LayoutRepainter::LayoutRepainter):
* rendering/LayoutRepainter.h:
* rendering/LayoutState.h:
(WebCore::LayoutState::LayoutState):
* rendering/LineWidth.h:
* rendering/LogicalSelectionOffsetCaches.h:
(WebCore::isContainingBlockCandidateForAbsolutelyPositionedObject):
(WebCore::isNonRenderBlockInline):
(WebCore::containingBlockForFixedPosition):
(WebCore::containingBlockForAbsolutePosition):
(WebCore::containingBlockForObjectInFlow):
(WebCore::LogicalSelectionOffsetCaches::LogicalSelectionOffsetCaches):
* rendering/PaintInfo.h:
(WebCore::PaintInfo::PaintInfo):
(WebCore::PaintInfo::updateSubtreePaintRootForChildren):
* rendering/RenderBox.cpp:
(WebCore::RenderBox::paintFillLayers):
(WebCore::RenderBox::paintFillLayer):
* rendering/RenderBox.h:
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::paintFillLayerExtended):
(WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
* rendering/RenderBoxModelObject.h:
* rendering/RenderCounter.cpp:
(WebCore::nextInPreOrder):
(WebCore::planCounter):
(WebCore::makeCounterNode):
(WebCore::RenderCounter::originalText):
* rendering/RenderElement.cpp:
(WebCore::RenderElement::~RenderElement):
(WebCore::RenderElement::insertChildInternal):
(WebCore::RenderElement::removeChildInternal):
(WebCore::RenderElement::willBeDestroyed):
(WebCore::RenderElement::rendererForRootBackground):
* rendering/RenderImageResource.cpp:
(WebCore::RenderImageResource::initialize):
* rendering/RenderImageResource.h:
* rendering/RenderImageResourceStyleImage.cpp:
(WebCore::RenderImageResourceStyleImage::initialize):
* rendering/RenderImageResourceStyleImage.h:
(WebCore::RenderImageResourceStyleImage::create):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::shouldPropagateCompositingToEnclosingFrame):
(WebCore::RenderLayerCompositor::requiresCompositingLayer):
(WebCore::RenderLayerCompositor::canBeComposited):
(WebCore::RenderLayerCompositor::requiresOwnBackingStore):
(WebCore::RenderLayerCompositor::reasonsForCompositing):
(WebCore::RenderLayerCompositor::requiresCompositingForTransform):
(WebCore::RenderLayerCompositor::requiresCompositingForVideo):
(WebCore::RenderLayerCompositor::requiresCompositingForCanvas):
(WebCore::RenderLayerCompositor::requiresCompositingForPlugin):
(WebCore::RenderLayerCompositor::requiresCompositingForFrame):
(WebCore::RenderLayerCompositor::requiresCompositingForAnimation):
(WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason):
(WebCore::RenderLayerCompositor::requiresCompositingForFilters):
(WebCore::RenderLayerCompositor::requiresCompositingForBlending):
(WebCore::RenderLayerCompositor::requiresCompositingForPosition):
(WebCore::RenderLayerCompositor::isRunningAcceleratedTransformAnimation):
* rendering/RenderLayerCompositor.h:
* rendering/RenderObject.cpp:
(WebCore::RenderObject::containingBlock):
(WebCore::mustRepaintFillLayers):
(WebCore::RenderObject::borderImageIsLoadedAndCanBeRendered):
(WebCore::RenderObject::willBeDestroyed):
* rendering/RenderScrollbarPart.cpp:
(WebCore::RenderScrollbarPart::rendererOwningScrollbar):
* rendering/RenderScrollbarPart.h:
* rendering/RenderTableCell.cpp:
(WebCore::RenderTableCell::paintBackgroundsBehindCell):
* rendering/RenderTableCell.h:
* rendering/RenderView.cpp:
(WebCore::RenderView::RenderView):
* rendering/style/FillLayer.cpp:
(WebCore::FillLayer::hasOpaqueImage):
* rendering/style/FillLayer.h:
* rendering/style/KeyframeList.h:
(WebCore::KeyframeList::KeyframeList):
* rendering/style/StyleCachedImage.cpp:
(WebCore::StyleCachedImage::imageSize):
(WebCore::StyleCachedImage::computeIntrinsicDimensions):
(WebCore::StyleCachedImage::setContainerSizeForRenderer):
(WebCore::StyleCachedImage::addClient):
(WebCore::StyleCachedImage::removeClient):
(WebCore::StyleCachedImage::image):
(WebCore::StyleCachedImage::knownToBeOpaque):
* rendering/style/StyleCachedImage.h:
* rendering/style/StyleCachedImageSet.cpp:
(WebCore::StyleCachedImageSet::imageSize):
(WebCore::StyleCachedImageSet::computeIntrinsicDimensions):
(WebCore::StyleCachedImageSet::setContainerSizeForRenderer):
(WebCore::StyleCachedImageSet::addClient):
(WebCore::StyleCachedImageSet::removeClient):
(WebCore::StyleCachedImageSet::image):
(WebCore::StyleCachedImageSet::knownToBeOpaque):
* rendering/style/StyleCachedImageSet.h:
* rendering/style/StyleGeneratedImage.cpp:
(WebCore::StyleGeneratedImage::imageSize):
(WebCore::StyleGeneratedImage::computeIntrinsicDimensions):
(WebCore::StyleGeneratedImage::addClient):
(WebCore::StyleGeneratedImage::removeClient):
(WebCore::StyleGeneratedImage::image):
(WebCore::StyleGeneratedImage::knownToBeOpaque):
* rendering/style/StyleGeneratedImage.h:
* rendering/style/StyleImage.h:
(WebCore::StyleImage::imagesEquivalent):
* rendering/style/StylePendingImage.h:
(WebCore::StylePendingImage::cssImageValue):
(WebCore::StylePendingImage::cssImageGeneratorValue):
(WebCore::StylePendingImage::cssCursorImageValue):
(WebCore::StylePendingImage::cssImageSetValue):
(WebCore::StylePendingImage::computeIntrinsicDimensions):
* testing/Internals.cpp:
(WebCore::Internals::boundingBox):
(WebCore::Internals::isSelectPopupVisible):
(WebCore::Internals::isPluginUnavailabilityIndicatorObscured):
Use RenderElement instead of RenderObject where it was easy to do so.
For local variables holding the return value of renderer() functions,
use auto instead, so the most-specific possible type will be used,
without having to figure out what that is in each case. Also use some
more OVERRIDE and FINAL and use nullptr instead of 0. And replace some
cryptic short local variable names with words.

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

6 years agoPass VM instead of JSGlobalObject to ArrayPrototype constructor.
akling@apple.com [Mon, 30 Sep 2013 00:57:07 +0000 (00:57 +0000)]
Pass VM instead of JSGlobalObject to ArrayPrototype constructor.
<https://webkit.org/b/122079>

Reviewed by Geoffrey Garen.

ArrayPrototype doesn't need the global object for anything during
construction, so reduce the amount of loads by just passing the VM.

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

6 years agoPass VM instead of ExecState to simple builtin constructors.
akling@apple.com [Sun, 29 Sep 2013 22:20:26 +0000 (22:20 +0000)]
Pass VM instead of ExecState to simple builtin constructors.
<https://webkit.org/b/122077>

Reviewed by Sam Weinig.

None of the simple builtins need the ExecState for anything during
their construction, so reduce the amount of loads by just passing
the VM around instead.

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

6 years agoRepaint borders and outlines on pseudo content changes
pdr@google.com [Sun, 29 Sep 2013 22:16:06 +0000 (22:16 +0000)]
Repaint borders and outlines on pseudo content changes
https://bugs.webkit.org/show_bug.cgi?id=122070

Reviewed by Andreas Kling.

Source/WebCore:

This patch fixes a regression from wkrev.com/150259 where pseudo content with
borders or outlines would fail to repaint if the color property changed.
The root bug is that border-color and outline-color properties use 'color' if
no explicit border-color or outline-color are given, and changing color should
repaint borders and outlines even if the text content is empty.

Relevant spec sections:
border: http://www.w3.org/TR/CSS1/#border-color
outline: http://www.w3.org/TR/CSS2/ui.html#propdef-outline-color

This patch also renames StyleDifferenceRepaintIfText to
StyleDifferenceRepaintIfTextOrBorderOrOutline and updates the relevant functions.

Test: fast/repaint/hover-pseudo-borders.html

* rendering/RenderElement.cpp:
(WebCore::RenderElement::hasImmediateNonWhitespaceTextChildOrBorderOrOutline):

    This function has been renamed to reflect that it returns true for borders
    or outlines as well.

(WebCore::RenderElement::shouldRepaintForStyleDifference):
* rendering/RenderElement.h:
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline):
(WebCore::RenderStyle::diff):
* rendering/style/RenderStyle.h:
* rendering/style/RenderStyleConstants.h:
* rendering/svg/SVGResourcesCache.cpp:
(WebCore::SVGResourcesCache::clientStyleChanged):
    These have also been renamed to reflect the new borders and outlines check.

LayoutTests:

* fast/repaint/hover-pseudo-borders.html: Added.
* platform/mac/fast/repaint/hover-pseudo-borders-expected.png: Added.
* platform/mac/fast/repaint/hover-pseudo-borders-expected.txt: Added.

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

6 years agoTighten typing in inline rendering
antti@apple.com [Sun, 29 Sep 2013 20:50:01 +0000 (20:50 +0000)]
Tighten typing in inline rendering
https://bugs.webkit.org/show_bug.cgi?id=122076

Reviewed by Andreas Kling.

More RenderElement, const, &, etc.

* dom/Position.cpp:
(WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
* rendering/InlineFlowBox.cpp:
(WebCore::isLastChildForRenderer):
(WebCore::isAncestorAndWithinBlock):
(WebCore::InlineFlowBox::determineSpacingForFlowBoxes):
(WebCore::InlineFlowBox::nodeAtPoint):
* rendering/InlineIterator.h:
(WebCore::InlineIterator::InlineIterator):
(WebCore::InlineIterator::root):
(WebCore::isEmptyInline):
(WebCore::bidiNextShared):
(WebCore::bidiNextSkippingEmptyInlines):
(WebCore::bidiNextIncludingEmptyInlines):
(WebCore::bidiFirstSkippingEmptyInlines):
* rendering/RenderBlockLineLayout.cpp:
(WebCore::inlineLogicalWidth):
(WebCore::alwaysRequiresLineBox):
(WebCore::requiresLineBox):
(WebCore::canBreakAtThisPosition):
(WebCore::LineBreaker::nextSegmentBreak):
* rendering/shapes/ShapeInsideInfo.h:
(WebCore::LineSegmentIterator::LineSegmentIterator):

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

6 years agoRefactor code for finding x86 scratch register.
commit-queue@webkit.org [Sun, 29 Sep 2013 19:31:33 +0000 (19:31 +0000)]
Refactor code for finding x86 scratch register.
https://bugs.webkit.org/show_bug.cgi?id=122072

Patch by Nadav Rotem <nrotem@apple.com> on 2013-09-29
Reviewed by Geoffrey Garen.

* assembler/MacroAssemblerX86Common.h:
(JSC::MacroAssemblerX86Common::getUnusedRegister):
(JSC::MacroAssemblerX86Common::store8):
(JSC::MacroAssemblerX86Common::store16):

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

6 years agoUnreviewed GTK gardening. Skip the IndexedDB tests for now as the feature is going
zandobersek@gmail.com [Sun, 29 Sep 2013 18:04:15 +0000 (18:04 +0000)]
Unreviewed GTK gardening. Skip the IndexedDB tests for now as the feature is going
through substantial changes that don't ensure constant proper functionality.

* platform/gtk-wk2/TestExpectations:
* platform/gtk/TestExpectations:

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

6 years agoMerge ScriptControllerBase into ScriptController
weinig@apple.com [Sun, 29 Sep 2013 06:02:13 +0000 (06:02 +0000)]
Merge ScriptControllerBase into ScriptController
https://bugs.webkit.org/show_bug.cgi?id=122071

Reviewed by Antti Koivisto.

There is no need for ScriptControllerBase. Remove it.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* bindings/ScriptControllerBase.cpp: Removed.
* bindings/ScriptControllerBase.h: Removed.
* bindings/js/ScriptController.cpp:
(WebCore::ScriptController::canExecuteScripts):
(WebCore::ScriptController::executeScript):
(WebCore::ScriptController::executeIfJavaScriptURL):
* bindings/js/ScriptController.h:

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

6 years agoUnreviewed build fix after r156613 for ports enabling CSS3_TEXT.
zandobersek@gmail.com [Sun, 29 Sep 2013 05:42:35 +0000 (05:42 +0000)]
Unreviewed build fix after r156613 for ports enabling CSS3_TEXT.

* rendering/RenderBlockLineLayout.cpp:
(WebCore::requiresIndent): Use the RenderStyle reference.

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

6 years agoSwitch inline boxes to use const RenderStyle&
antti@apple.com [Sun, 29 Sep 2013 04:34:37 +0000 (04:34 +0000)]
Switch inline boxes to use const RenderStyle&
https://bugs.webkit.org/show_bug.cgi?id=122068

Reviewed by Sam Weinig.

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

6 years agoAdd first()/last() to ElementIteratorAdapters
antti@apple.com [Sat, 28 Sep 2013 20:20:56 +0000 (20:20 +0000)]
Add first()/last() to ElementIteratorAdapters
https://bugs.webkit.org/show_bug.cgi?id=122067

Reviewed by Darin Adler.

Add a convenient way for getting the first and last element if it exists.

Use it in some places.

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::canvasHasFallbackContent):
* css/CSSFontFaceSource.cpp:
(WebCore::CSSFontFaceSource::getFontData):
* dom/Document.cpp:
(WebCore::Document::childrenChanged):
(WebCore::Document::removeTitle):
* dom/ElementChildIterator.h:
(WebCore::::first):
(WebCore::::last):
* dom/ElementDescendantIterator.h:
(WebCore::::first):
(WebCore::::last):
* html/HTMLFieldSetElement.cpp:
(WebCore::HTMLFieldSetElement::legend):
* html/HTMLLegendElement.cpp:
(WebCore::HTMLLegendElement::associatedControl):
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::finishParsingChildren):
(WebCore::HTMLMediaElement::selectMediaResource):
* svg/SVGElement.cpp:
(WebCore::SVGElement::title):
* svg/SVGFontFaceElement.cpp:
(WebCore::SVGFontFaceElement::rebuildFontFace):
* svg/graphics/SVGImage.cpp:
(WebCore::SVGImage::hasSingleSecurityOrigin):

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

6 years agoFix some failures with newer versions of clang.
mrowe@apple.com [Sat, 28 Sep 2013 20:01:30 +0000 (20:01 +0000)]
Fix some failures with newer versions of clang.

Some CoreGraphics headers generate warnings under newer versions of clang. Since they're system headers the warnings would
usually be suppressed, but we're adding the frameworks to the non-system framework search path so they're no longer treated
as system headers. We address this by removing the system paths from FRAMEWORK_SEARCH_PATHS and using the -iframework compiler
flag in OTHER_CFLAGS to add the paths to the system framework search path. We have to set OTHER_CFLAGS at the target level
in order for it to coexist with the ASAN-related OTHER_CFLAGS that's set in DebugRelease.xcconfig.

Reviewed by Dan Bernstein.

Source/WebCore:

* Configurations/WebCore.xcconfig:

Source/WebKit/mac:

* Configurations/DebugRelease.xcconfig:
* Configurations/WebKit.xcconfig:

Source/WebKit2:

* Configurations/BaseTarget.xcconfig:
* Configurations/DebugRelease.xcconfig:

Tools:

* DumpRenderTree/mac/Configurations/Base.xcconfig:
* DumpRenderTree/mac/Configurations/BaseTarget.xcconfig: A new .xcconfig file that's included by all target-specific .xcconfig files.
* DumpRenderTree/mac/Configurations/DebugRelease.xcconfig:
* DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig:
* DumpRenderTree/mac/Configurations/ImageDiff.xcconfig:
* DumpRenderTree/mac/Configurations/TestNetscapePlugIn.xcconfig:
* WebKitTestRunner/Configurations/Base.xcconfig:
* WebKitTestRunner/Configurations/BaseTarget.xcconfig: A new .xcconfig file that's included by all target-specific .xcconfig files.
* WebKitTestRunner/Configurations/DebugRelease.xcconfig:
* WebKitTestRunner/Configurations/InjectedBundle.xcconfig:
* WebKitTestRunner/Configurations/WebKitTestRunner.xcconfig:

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

6 years agoTake Xcode's advice and enable some extra warnings.
mrowe@apple.com [Sat, 28 Sep 2013 19:15:48 +0000 (19:15 +0000)]
Take Xcode's advice and enable some extra warnings.

Reviewed by Sam Weinig.

Source/JavaScriptCore:

* Configurations/Base.xcconfig:
* JavaScriptCore.xcodeproj/project.pbxproj:

Source/WebCore:

* Configurations/Base.xcconfig:
* WebCore.xcodeproj/project.pbxproj:
* dom/NamedNodeMap.cpp:
(WebCore::NamedNodeMap::removeNamedItemNS): Use the correct constant.

Source/WebKit:

* WebKit.xcodeproj/project.pbxproj:

Source/WebKit/mac:

* Configurations/Base.xcconfig:

Source/WebKit2:

* Configurations/Base.xcconfig:
* WebKit2.xcodeproj/project.pbxproj:

Source/WTF:

* Configurations/Base.xcconfig:
* WTF.xcodeproj/project.pbxproj:

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

6 years agoCTTE: VisitedLinkState should hold a Document&
weinig@apple.com [Sat, 28 Sep 2013 19:10:00 +0000 (19:10 +0000)]
CTTE: VisitedLinkState should hold a Document&
https://bugs.webkit.org/show_bug.cgi?id=122066

Reviewed by Antti Koivisto.

The Document can never be null, so use a reference.

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

6 years agoClean up code for getting first line style
antti@apple.com [Sat, 28 Sep 2013 18:30:16 +0000 (18:30 +0000)]
Clean up code for getting first line style
https://bugs.webkit.org/show_bug.cgi?id=122037

Reviewed by Andreas Kling.

We have confusing RenderObject::style(bool firstLine). Get rid of it in favour of
just using RenderObject::firstLineStyle() where appropriate.

Also switch to RenderStyle references in many places and move first line style caching
code down to RenderElement.

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

6 years agoAdd Frame::mainFrame and Frame::isMainFrame
darin@apple.com [Sat, 28 Sep 2013 17:19:04 +0000 (17:19 +0000)]
Add Frame::mainFrame and Frame::isMainFrame
https://bugs.webkit.org/show_bug.cgi?id=122064

Reviewed by Andreas Kling.

Source/WebCore:

* WebCore.exp.in: Removed exports of FrameView::isMainFrameView and
Page::frameIsMainFrame. Since the new isMainFrame function is inline, it
does not need to be exported.

* history/PageCache.cpp:
(WebCore::PageCache::markPagesForFullStyleRecalc):
(WebCore::PageCache::markPagesForDeviceScaleChanged):
These two were the only functions I found that really wanted the equivalent
of Page::frameIsMainFrame, so wrote it out here instead of using a function
call.

* inspector/InspectorAgent.cpp: Removed the unused isMainResourceLoader function.
* inspector/InspectorAgent.h: Removed declarations of a few nonexistent or
unused private member functions. Also removed the InjectedScriptForOriginMap
typedef: It's mor readable to use the type directly

* loader/FrameLoader.h: Removed isLoadingMainFrame. It's not better than
calling frame().isMainFrame() directly.

* page/Frame.cpp:
(WebCore::Frame::Frame): Initialize m_mainFrame and call selfOnlyRef, keeping
the MainFrame alive as long as any of its subframes is alive.
(WebCore::Frame::~Frame): Call selfOnlyDeref.
(WebCore::Frame::createView): Use isMainFrame.
(WebCore::Frame::setPageAndTextZoomFactors): Ditto.

* page/Frame.h: Added Frame::mainFrame, Frame::isMainFrame, and Frame::m_mainFrame.

* page/FrameView.h: Removed the isMainFrameView function. It's not better than
calling frame().isMainFrame() directly.

* page/MainFrame.cpp:
(WebCore::MainFrame::MainFrame): Initialize m_selfOnlyRefCount to 0.
(WebCore::MainFrame::selfOnlyRef): Added.
(WebCore::MainFrame::selfOnlyDeref): Added.
(WebCore::MainFrame::dropChildren): Added. Called when the self-only reference
count reaches 0 to avoid a reference cycle with subframes.

* page/MainFrame.h: Added new data members as mentioned above. Also, the
definition of the Frame::isMainFrame inline function goes here, since it can't
compile without the MainFrame class definition. This means that callers of
isMainFrame need to include MainFrame.h, which seems reasonable and is easy
to do.

* page/Page.cpp:
* page/Page.h: Added assertion to Page::mainFrame since it returns a reference.
Removed Page::frameIsMainFrame since it's not better than calling isMainFrame
on the frame.

* dom/Document.cpp:
(WebCore::Document::setVisualUpdatesAllowed):
(WebCore::Document::didBecomeCurrentDocumentInFrame):
(WebCore::Document::updateViewportArguments):
(WebCore::Document::setInPageCache):
(WebCore::Document::ensurePlugInsInjectedScript):
* history/CachedFrame.cpp:
(WebCore::CachedFrame::CachedFrame):
* history/CachedPage.cpp:
(WebCore::CachedPage::restore):
* html/HTMLPlugInImageElement.cpp:
(WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn):
* html/ImageDocument.cpp:
(WebCore::ImageDocument::shouldShrinkToFit):
* inspector/InspectorController.cpp:
(WebCore::InspectorController::didClearWindowObjectInWorld):
* inspector/InspectorInstrumentation.cpp:
(WebCore::InspectorInstrumentation::didCommitLoadImpl):
* inspector/InspectorPageAgent.cpp:
(WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
(WebCore::InspectorPageAgent::frameNavigated):
* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::willSendRequest):
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::transitionToCommitted):
(WebCore::FrameLoader::prepareForCachedPageRestore):
(WebCore::FrameLoader::checkLoadCompleteForThisFrame):
(WebCore::FrameLoader::didLayout):
(WebCore::FrameLoader::checkLoadComplete):
(WebCore::FrameLoader::addExtraFieldsToRequest):
(WebCore::FrameLoader::loadResourceSynchronously):
(WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
(WebCore::FrameLoader::dispatchDidCommitLoad):
(WebCore::FrameLoader::loadProgressingStatusChanged):
* loader/HistoryController.cpp:
(WebCore::HistoryController::saveScrollPositionAndViewStateToItem):
(WebCore::HistoryController::restoreScrollPositionAndViewState):
(WebCore::HistoryController::updateForCommit):
(WebCore::HistoryController::updateForSameDocumentNavigation):
(WebCore::HistoryController::updateBackForwardListClippedAtTarget):
(WebCore::HistoryController::pushState):
* loader/icon/IconController.cpp:
(WebCore::IconController::startLoader):
* page/AutoscrollController.cpp:
(WebCore::AutoscrollController::stopAutoscrollTimer):
* page/ContextMenuController.cpp:
(WebCore::ContextMenuController::populate):
* page/DOMWindow.cpp:
(WebCore::allowsBeforeUnloadListeners):
(WebCore::DOMWindow::focus):
(WebCore::DOMWindow::blur):
(WebCore::DOMWindow::close):
(WebCore::DOMWindow::allowedToChangeWindowGeometry):
* page/EventHandler.cpp:
(WebCore::EventHandler::hitTestResultAtPoint):
(WebCore::EventHandler::selectCursor):
(WebCore::EventHandler::handleMousePressEvent):
(WebCore::EventHandler::keyEvent):
* page/FrameTree.cpp:
(WebCore::FrameTree::find):
(WebCore::FrameTree::traverseNextWithWrap):
* page/FrameView.cpp:
(WebCore::FrameView::FrameView):
(WebCore::FrameView::setFrameRect):
(WebCore::FrameView::createScrollbar):
(WebCore::FrameView::applyOverflowToViewport):
(WebCore::FrameView::setHeaderHeight):
(WebCore::FrameView::setFooterHeight):
(WebCore::FrameView::minimumScrollPosition):
(WebCore::FrameView::maximumScrollPosition):
(WebCore::FrameView::shouldUpdateFixedElementsAfterScrolling):
(WebCore::FrameView::beginDeferredRepaints):
(WebCore::FrameView::endDeferredRepaints):
(WebCore::FrameView::performPostLayoutTasks):
(WebCore::FrameView::sendResizeEventIfNeeded):
(WebCore::FrameView::pagination):
(WebCore::FrameView::visibleContentScaleFactor):
(WebCore::FrameView::setVisibleScrollerThumbRect):
(WebCore::FrameView::scrollbarStyleChanged):
(WebCore::FrameView::paintScrollCorner):
(WebCore::FrameView::paintScrollbar):
(WebCore::FrameView::paintOverhangAreas):
* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::ScrollingCoordinator::coordinatesScrollingForFrameView):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::RenderLayerBacking):
Use the new functions where possible instead of Page::frameIsMainFrame,
Page::mainFrame, FrameLoader::isLoadingMainFrame, and FrameView::isMainFrameView.

Source/WebKit/blackberry:

* WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
(WebCore::FrameLoaderClientBlackBerry::dispatchWillSendRequest):
Call isMainFrame.

Source/WebKit/efl:

* WebCoreSupport/FrameLoaderClientEfl.cpp:
(WebCore::FrameLoaderClientEfl::dispatchWillSendRequest):
(WebCore::FrameLoaderClientEfl::assignIdentifierToInitialRequest):
(WebCore::FrameLoaderClientEfl::updateGlobalHistory):
Call isMainFrame.

Source/WebKit/gtk:

* WebCoreSupport/FrameLoaderClientGtk.cpp:
(WebKit::FrameLoaderClient::assignIdentifierToInitialRequest):
Call isMainFrame.

Source/WebKit/mac:

* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::canHandleRequest):
(WebFrameLoaderClient::transitionToCommittedForNewPage):
* WebView/WebFrameView.mm:
(-[WebFrameView _install]):
Call isMainFrame.

Source/WebKit2:

* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
(WebKit::TiledCoreAnimationDrawingArea::shouldUseTiledBackingForFrameView):
Call isMainFrame.

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

6 years agofilter: drop-shadow doesnot support viewport units
commit-queue@webkit.org [Sat, 28 Sep 2013 16:14:00 +0000 (16:14 +0000)]
filter: drop-shadow doesnot support viewport units
https://bugs.webkit.org/show_bug.cgi?id=122053

Patch by Gurpreet Kaur <k.gurpreet@samsung.com> on 2013-09-28
Reviewed by Darin Adler.

Source/WebCore:

drop-shadow properties were not applied incase its values
were given in vh, vw, vmax, vmin units.

Tests: fast/css/drop-shadow-viewport-height.html
       fast/css/drop-shadow-viewport-vmax.html
       fast/css/drop-shadow-viewport-vmin.html
       fast/css/drop-shadow-viewport-width.html

* css/StyleResolver.cpp:
(WebCore::StyleResolver::createFilterOperations):
Calculating the drop-shadow values which has been specified in viewport
units.The vh/vw units are calcultated as percent of viewport height and
viewport width respectively. 1vmax: 1vw or 1vh, whatever is largest.
1vmin: 1vw or 1vh, whatever is smallest.

LayoutTests:

* fast/css/drop-shadow-viewport-height-expected-mismatch.html: Added.
* fast/css/drop-shadow-viewport-height.html: Added.
* fast/css/drop-shadow-viewport-vmax-expected-mismatch.html: Added.
* fast/css/drop-shadow-viewport-vmax.html: Added.
* fast/css/drop-shadow-viewport-vmin-expected-mismatch.html: Added.
* fast/css/drop-shadow-viewport-vmin.html: Added.
* fast/css/drop-shadow-viewport-width-expected-mismatch.html: Added.
* fast/css/drop-shadow-viewport-width.html: Added.
Added new tests for verifying that drop-shadow properties are applied
when its values are viewport units.

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

6 years agoREGRESSION (r154614): Setting the document scroll position isn't symmetric; can succe...
commit-queue@webkit.org [Sat, 28 Sep 2013 16:10:34 +0000 (16:10 +0000)]
REGRESSION (r154614): Setting the document scroll position isn't symmetric; can successfully set document.body.scrollTop, but can only read from document.documentElement.scrollTop
https://bugs.webkit.org/show_bug.cgi?id=121876

Patch by Gurpreet Kaur <k.gurpreet@samsung.com> on 2013-09-28
Reviewed by Darin Adler.

Source/WebCore:

Non-Quirks mode should set/get scrolltop/scrollleft through
document.documentElement.scrollTop/document.documentElement.scrollLeft
Quirks mode should set/get scrolltop/scrollleft through
document.body.scrollTop/document.body.scrollLeft.

Tests: fast/dom/Element/body-scrollLeft-Quirks.html
       fast/dom/Element/body-scrollLeft.html
       fast/dom/Element/body-scrollTop-Quirks.html
       fast/dom/Element/body-scrollTop.html
       fast/dom/Element/documentElement-scrollLeft-Quirks.html
       fast/dom/Element/documentElement-scrollLeft.html
       fast/dom/Element/documentElement-scrollTop-Quirks.html
       fast/dom/Element/documentElement-scrollTop.html

* dom/Element.cpp:
(WebCore::Element::setScrollLeft):
(WebCore::Element::setScrollTop):
* html/HTMLBodyElement.cpp:
(WebCore::HTMLBodyElement::setScrollLeft):
(WebCore::HTMLBodyElement::setScrollTop):
Need to set the scrollTop and scrollLeft after checking if document
is in quirks or non-quirks mode. Incase it is body.scrollLeft/
body.scrollTop set only if document is in quirks mode. If document is
non-quirks mode set documentElement.scrollLeft/documentElement.scrollTop.

LayoutTests:

* fast/dom/Element/body-scrollLeft-Quirks-expected.txt: Added.
* fast/dom/Element/body-scrollLeft-Quirks.html: Added.
* fast/dom/Element/body-scrollLeft-expected.txt: Added.
* fast/dom/Element/body-scrollLeft.html: Added.
* fast/dom/Element/body-scrollTop-Quirks-expected.txt: Added.
* fast/dom/Element/body-scrollTop-Quirks.html: Added.
* fast/dom/Element/body-scrollTop-expected.txt: Added.
* fast/dom/Element/body-scrollTop.html: Added.
* fast/dom/Element/documentElement-scrollLeft-Quirks-expected.txt: Added.
* fast/dom/Element/documentElement-scrollLeft-Quirks.html: Added.
* fast/dom/Element/documentElement-scrollLeft-expected.txt: Added.
* fast/dom/Element/documentElement-scrollLeft.html: Added.
* fast/dom/Element/documentElement-scrollTop-Quirks-expected.txt: Added.
* fast/dom/Element/documentElement-scrollTop-Quirks.html: Added.
* fast/dom/Element/documentElement-scrollTop-expected.txt: Added.
* fast/dom/Element/documentElement-scrollTop.html: Added.
Added test cases for verifying that Non-Quirks mode should set
scrolltop/scrollleft through document.documentElement.scrollTop/
document.documentElement.scrollLeft and Quirks mode should set/get
scrolltop/scrollleft through document.body.scrollTop/document.body.scrollLeft.

* fast/multicol/scrolling-overflow.html:
Rebaselining existing tests as per the new behavior. To set
document.body.scrollLeft document to be in Quirks mode.

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

6 years agoMessage sending functions should only accept rvalues
andersca@apple.com [Sat, 28 Sep 2013 15:05:54 +0000 (15:05 +0000)]
Message sending functions should only accept rvalues
https://bugs.webkit.org/show_bug.cgi?id=122041

Reviewed by Andreas Kling.

In order to safely encode move-only types, make all send variants accept rvalues only, except
for the "send to all processes" ones. For them, copy the message before sending. This ensures that trying
to send a move-only type in a message will fail to compile.

* NetworkProcess/NetworkResourceLoader.h:
(WebKit::NetworkResourceLoader::sendAbortingOnFailure):
* Platform/CoreIPC/Connection.h:
(CoreIPC::Connection::send):
(CoreIPC::Connection::sendSync):
* Platform/CoreIPC/MessageSender.h:
(CoreIPC::MessageSender::sendSync):
* Shared/ChildProcessProxy.h:
(WebKit::ChildProcessProxy::send):
(WebKit::ChildProcessProxy::sendSync):
* UIProcess/WebContext.h:
(WebKit::WebContext::sendToNetworkingProcess):
(WebKit::WebContext::sendToNetworkingProcessRelaunchingIfNecessary):
(WebKit::WebContext::sendToAllProcesses):
(WebKit::WebContext::sendToAllProcessesRelaunchingThemIfNecessary):
(WebKit::WebContext::sendToOneProcess):
* UIProcess/WebPageGroup.h:
(WebKit::WebPageGroup::sendToAllProcessesInGroup):

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

6 years agoUnreviewed GTK build fix after r156560.
philn@webkit.org [Sat, 28 Sep 2013 15:02:53 +0000 (15:02 +0000)]
Unreviewed GTK build fix after r156560.

Source/WebKit/gtk:

* WebCoreSupport/AcceleratedCompositingContext.h:

Source/WebKit2:

* WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
(WebKit::LayerTreeHostGtk::paintContents):
(WebKit::LayerTreeHostGtk::createPageOverlayLayer):
(WebKit::LayerTreeHostGtk::destroyPageOverlayLayer):
* WebProcess/WebPage/gtk/LayerTreeHostGtk.h:

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

6 years agoPass VM instead of ExecState to JSFunction constructors.
akling@apple.com [Sat, 28 Sep 2013 14:15:24 +0000 (14:15 +0000)]
Pass VM instead of ExecState to JSFunction constructors.
<https://webkit.org/b/122014>

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

JSFunction doesn't need the ExecState for anything during its
construction, so reduce the amount of loads by just passing the
VM around instead.

Factored out putDirectNonIndexAccessor() from the existing
putDirectAccessor() to avoid snowballing the patch (and because
it's kinda neat to avoid the extra branch.)

JSC release binary size -= 9680 bytes.

Source/WebCore:

Updated for new JSFunction::create() signature.

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

6 years agoGenerate toCSSFooValue() for CSSImageValue
gyuyoung.kim@samsung.com [Sat, 28 Sep 2013 13:27:12 +0000 (13:27 +0000)]
Generate toCSSFooValue() for CSSImageValue
https://bugs.webkit.org/show_bug.cgi?id=122051

Reviewed by Andreas Kling.

Clean up static_cast<CSSImageValue*> type casts. It will help to
detect bad cast as well as improve code readability.

Removed unnecessary local variables as well.

No new tests, no behavior changes.

* css/CSSCrossfadeValue.cpp:
(WebCore::subimageKnownToBeOpaque):
* css/CSSCursorImageValue.cpp:
(WebCore::CSSCursorImageValue::~CSSCursorImageValue):
(WebCore::CSSCursorImageValue::updateIfSVGCursorIsUsed):
(WebCore::CSSCursorImageValue::cachedImage):
(WebCore::CSSCursorImageValue::isSVGCursor):
* css/CSSImageGeneratorValue.cpp:
(WebCore::CSSImageGeneratorValue::subimageIsPending):
(WebCore::CSSImageGeneratorValue::cachedImageForCSSValue):
* css/CSSImageSetValue.cpp:
(WebCore::CSSImageSetValue::fillImageSet):
* css/CSSImageValue.h:
* css/CSSValue.cpp:
(WebCore::CSSValue::destroy):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty):
(WebCore::StyleResolver::styleImage):
* page/PageSerializer.cpp:
(WebCore::PageSerializer::retrieveResourcesForProperties):
* rendering/style/StylePendingImage.h:
(WebCore::StylePendingImage::data):
(WebCore::StylePendingImage::cssImageValue):

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

6 years agoWebCore fails to build with newer versions of clang.
mrowe@apple.com [Sat, 28 Sep 2013 10:26:17 +0000 (10:26 +0000)]
WebCore fails to build with newer versions of clang.

Reviewed by Sam Weinig.

* Modules/indexeddb/IDBIndex.cpp: Remove an unused constant.
* Modules/indexeddb/IDBObjectStore.cpp: Ditto.
* Modules/webaudio/AudioContext.cpp: Ditto.
* Modules/webaudio/ScriptProcessorNode.cpp: Ditto.
* Modules/webdatabase/SQLResultSet.cpp: Ditto.
* Modules/webdatabase/SQLTransactionBackend.cpp: Ditto.
* Modules/websockets/WebSocketHandshake.cpp: Ditto.
* bindings/objc/DOM.mm: Disable a warning about overriding a protocol method in a cateogry around the one
place we do it. I don't understand why this generates a warning, nor can I see a different approach that
would not result in the warning being emitted.
* css/CSSGrammar.y.in: #if a function that's only used inside an #if.
* html/track/TextTrackCue.cpp: Remove an unused constant.
* loader/TextResourceDecoder.cpp: Remove two unused functions.
* page/ContentSecurityPolicy.cpp: Add #if's around constants and functions that are only used when CSP_NEXT is enabled.
(WebCore::CSPDirectiveList::checkSourceAndReportViolation): Reorder the ifs slightly to make the #if'ing easier.
* page/ContentSecurityPolicy.h: Add #if's around functions that are only used when CSP_NEXT is enabled.
* page/DOMSecurityPolicy.cpp: Ditto.
* page/DOMSecurityPolicy.h: Ditto.
* page/animation/CSSPropertyAnimation.cpp: Remove an unused function.
* platform/mac/DisplaySleepDisabler.cpp: Add an #if around a constant that's only used on iOS.
* platform/mac/WebCoreFullScreenWarningView.mm: Remove three unused constants.
* rendering/RenderLayer.cpp: Remove two unused constants.
* rendering/RenderLayerCompositor.cpp:
(WebCore::compositingLogEnabled): Move the #if around the function definition.
* svg/SVGAnimatedAngle.cpp: Remove an unused function.
* svg/SVGUseElement.cpp: #if a function that's only used inside an ASSERT.
* xml/XPathStep.cpp: Ditto.

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

6 years agoWebKit fails to build with newer versions of clang.
mrowe@apple.com [Sat, 28 Sep 2013 10:25:30 +0000 (10:25 +0000)]
WebKit fails to build with newer versions of clang.

Reviewed by Sam Weinig.

* Carbon/HIWebView.mm: Remove an unused function.
* History/BinaryPropertyList.cpp: #if a constant that's only used in 64-bit.
* Misc/WebIconDatabase.mm: Remove two unused constants.
* Plugins/WebBaseNetscapePluginView.mm: Remove an unused constant.
* WebCoreSupport/WebEditorClient.mm: Ditto.

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

6 years agoWebKit2 fails to build with newer versions of clang.
mrowe@apple.com [Sat, 28 Sep 2013 10:23:32 +0000 (10:23 +0000)]
WebKit2 fails to build with newer versions of clang.

Reviewed by Anders Carlsson.

* Shared/VisitedLinkTable.cpp: #if a function that's only used inside an ASSERT.
* UIProcess/Plugins/mac/PluginInfoStoreMac.mm: Remove an unused constant.
* UIProcess/mac/WKFullScreenWindowController.mm: Ditto.
* WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm: Ditto.
* WebProcess/WebPage/FindController.cpp: Ditto.
* WebProcess/WebPage/WebBackForwardListProxy.cpp: Remove two unused constants.

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

6 years agoJavaScriptCore fails to build with newer versions of clang.
mrowe@apple.com [Sat, 28 Sep 2013 10:22:06 +0000 (10:22 +0000)]
JavaScriptCore fails to build with newer versions of clang.

Reviewed by Sam Weinig.

* interpreter/Interpreter.cpp: Remove an unused function.
* parser/SourceProvider.cpp: Ditto.
* runtime/GCActivityCallback.cpp: #if a constant that's only used on non-CF platforms.
* runtime/JSCJSValue.cpp: Remove an unused constant.
* runtime/JSString.cpp: Ditto.

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

6 years ago<rdar://problem/15079224> WTF fails to build with newer versions of clang.
mrowe@apple.com [Sat, 28 Sep 2013 10:19:40 +0000 (10:19 +0000)]
<rdar://problem/15079224> WTF fails to build with newer versions of clang.

Reviewed by Sam Weinig.

* wtf/DateMath.cpp: Remove some unused constants.
* wtf/FastMalloc.cpp: #if some constants and functions that are unused in some configurations.
Remove a function that's unused on all platforms.
* wtf/TCSystemAlloc.cpp: Remove some unused constants.
(TCMalloc_SystemRelease): Remove an if whose body is never executed.
* wtf/dtoa.cpp: #if things such that storeInc is only defined when USE_LONG_LONG is undefined.
Remove an unused constant.

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

6 years agoRestore accidentally removed ChangeLog lines.
ap@apple.com [Sat, 28 Sep 2013 05:35:03 +0000 (05:35 +0000)]
Restore accidentally removed ChangeLog lines.

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

6 years agoGet rid of SetMyScope/SetCallee; use normal variables for the scope and callee of...
fpizlo@apple.com [Sat, 28 Sep 2013 04:08:59 +0000 (04:08 +0000)]
Get rid of SetMyScope/SetCallee; use normal variables for the scope and callee of inlined call frames of closures
https://bugs.webkit.org/show_bug.cgi?id=122047

Reviewed by Oliver Hunt.

Currently we have the DFG reserve space for inline call frames at exactly the same stack
offsets that you would have gotten if the baseline interpreter/JIT had made the calls.
We need to get rid of that. One of the weirder parts of this is that we have special DFG
operations for accessing these inlined call frame headers. It's really hard for any
analysis of DFG IR to see what the liveness of any of those frame header "variables" is;
the liveness behaves like flushed arguments (it's all live until end of the inlinee) but
we don't have anything like a Flush node for those special variables.

This patch gets rid of the special operations for accessing inline call frame headers.
GetMyScope and GetCallee still remain, and are only for accessing the machine call
frame's scope/callee entries. The inline call frame's scope/callee now behave like
normal variables, and have Flush behavior just like inline arguments.

* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::::executeEffects):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::getDirect):
(JSC::DFG::ByteCodeParser::get):
(JSC::DFG::ByteCodeParser::setDirect):
(JSC::DFG::ByteCodeParser::set):
(JSC::DFG::ByteCodeParser::setLocal):
(JSC::DFG::ByteCodeParser::setArgument):
(JSC::DFG::ByteCodeParser::flush):
(JSC::DFG::ByteCodeParser::InlineStackEntry::remapOperand):
(JSC::DFG::ByteCodeParser::handleInlining):
(JSC::DFG::ByteCodeParser::getScope):
* dfg/DFGCSEPhase.cpp:
(JSC::DFG::CSEPhase::getCalleeLoadElimination):
(JSC::DFG::CSEPhase::getMyScopeLoadElimination):
(JSC::DFG::CSEPhase::performNodeCSE):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
* dfg/DFGNodeType.h:
* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::propagate):
* dfg/DFGSafeToExecute.h:
(JSC::DFG::safeToExecute):
* 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@156594 268f45cc-cd09-0410-ab3c-d52691b4dbfc

6 years ago[CSS Shapes] New positioning model: Positive margins
bjonesbe@adobe.com [Sat, 28 Sep 2013 00:32:21 +0000 (00:32 +0000)]
[CSS Shapes] New positioning model: Positive margins
https://bugs.webkit.org/show_bug.cgi?id=118089

Reviewed by Alexandru Chiculita.

The remaining tests for shape-outside with positive margins. These
have all been imported from the CSSWG's repo.

* csswg/contributors/adobe/submitted/shapes/shape-outside/resources/w3c-import.log:
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-005-expected.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-005.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-006-expected.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-006.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-007-expected.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-007.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-008-expected.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-008.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-009-expected.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-009.html: Added.
* csswg/contributors/adobe/submitted/shapes/shape-outside/w3c-import.log:

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

6 years agoLayout Test media/media-controller-playback.html is flaky
ap@apple.com [Sat, 28 Sep 2013 00:11:17 +0000 (00:11 +0000)]
Layout Test media/media-controller-playback.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=122042

* platform/mac/TestExpectations: Marked as such.

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

6 years agoVersioning.
lforschler@apple.com [Sat, 28 Sep 2013 00:03:37 +0000 (00:03 +0000)]
Versioning.

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

6 years agoIndexedDB IDL Refactoring.
beidson@apple.com [Fri, 27 Sep 2013 23:45:27 +0000 (23:45 +0000)]
IndexedDB IDL Refactoring.
https://bugs.webkit.org/show_bug.cgi?id=121996

Reviewed by Alexey Proskuryakov.

This includes:
1 - Leveraging EventTarget.idl inheritance
2 - Removing comments
3 - Reordering to match the spec's IDLs
4 - Removing nonstandard, WebKit-specific methods
5 - Updating interfaces to match the spec (versions are only uint64_t's now...)
6 - Updating implementation code as needed (versions are only uint64_t's now...)

IDL changes:
* Modules/indexeddb/IDBCursor.idl:
* Modules/indexeddb/IDBDatabase.idl:
* Modules/indexeddb/IDBFactory.idl:
* Modules/indexeddb/IDBIndex.idl:
* Modules/indexeddb/IDBKeyRange.idl:
* Modules/indexeddb/IDBObjectStore.idl:
* Modules/indexeddb/IDBRequest.idl:
* Modules/indexeddb/IDBTransaction.idl:
* Modules/indexeddb/IDBVersionChangeEvent.idl:

* Modules/indexeddb/IndexedDB.h: Add new enum to represent version nullness.

Adapt to new IDLs, and also refactor representation of initial, null versioning:
* Modules/indexeddb/IDBCallbacks.h:
(WebCore::IDBCallbacks::onBlocked):
(WebCore::IDBCallbacks::onUpgradeNeeded):

* Modules/indexeddb/IDBDatabase.cpp:
(WebCore::IDBDatabase::version):
(WebCore::IDBDatabase::onVersionChange):
* Modules/indexeddb/IDBDatabase.h:

* Modules/indexeddb/IDBDatabaseCallbacks.h:
* Modules/indexeddb/IDBDatabaseCallbacksImpl.cpp:
(WebCore::IDBDatabaseCallbacksImpl::onVersionChange):
* Modules/indexeddb/IDBDatabaseCallbacksImpl.h:

* Modules/indexeddb/IDBFactory.cpp:
(WebCore::IDBFactory::open):
(WebCore::IDBFactory::openInternal):
(WebCore::IDBFactory::deleteDatabase):
* Modules/indexeddb/IDBFactory.h:

* Modules/indexeddb/IDBMetadata.h:
(WebCore::IDBDatabaseMetadata::IDBDatabaseMetadata):

* Modules/indexeddb/IDBOpenDBRequest.cpp:
(WebCore::IDBOpenDBRequest::create):
(WebCore::IDBOpenDBRequest::IDBOpenDBRequest):
(WebCore::IDBOpenDBRequest::onBlocked):
(WebCore::IDBOpenDBRequest::onUpgradeNeeded):
* Modules/indexeddb/IDBOpenDBRequest.h:

* Modules/indexeddb/IDBRequest.cpp:
* Modules/indexeddb/IDBRequest.h:

* Modules/indexeddb/IDBTransaction.cpp:
* Modules/indexeddb/IDBTransaction.h:

* Modules/indexeddb/IDBVersionChangeEvent.cpp:
(WebCore::IDBVersionChangeEvent::IDBVersionChangeEvent):
* Modules/indexeddb/IDBVersionChangeEvent.h:
(WebCore::IDBVersionChangeEvent::create):
(WebCore::IDBVersionChangeEvent::oldVersion):
(WebCore::IDBVersionChangeEvent::newVersion):

Keep leveldb building with minimal adaptations to the new IDLs,
but note that the LevelDB implementation is now incompatible with the spec:
* Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
(WebCore::IDBBackingStore::getIDBDatabaseMetaData):
(WebCore::objectStoreCursorOptions):
(WebCore::indexCursorOptions):

* Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.cpp:
(WebCore::IDBDatabaseBackendLevelDB::IDBDatabaseBackendLevelDB):
(WebCore::IDBDatabaseBackendLevelDB::openInternal):
(WebCore::IDBDatabaseBackendLevelDB::VersionChangeOperation::perform):
(WebCore::IDBDatabaseBackendLevelDB::processPendingCalls):
(WebCore::IDBDatabaseBackendLevelDB::openConnection):
(WebCore::IDBDatabaseBackendLevelDB::runIntVersionChangeTransaction):
(WebCore::IDBDatabaseBackendLevelDB::deleteDatabase):
(WebCore::IDBDatabaseBackendLevelDB::deleteDatabaseFinal):
(WebCore::IDBDatabaseBackendLevelDB::VersionChangeAbortOperation::perform):

* Modules/indexeddb/leveldb/IDBLevelDBCoding.cpp:
(WebCore::IDBLevelDBCoding::compareEncodedIDBKeys):

* inspector/InspectorIndexedDBAgent.cpp: Update for metadata change.

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

6 years agoCookieStorageShim should be PLATFORM(MAC) guarded
ossy@webkit.org [Fri, 27 Sep 2013 23:40:33 +0000 (23:40 +0000)]
CookieStorageShim should be PLATFORM(MAC) guarded
https://bugs.webkit.org/show_bug.cgi?id=121423

Reviewed by Darin Adler.

Original patch by Kwang Yul Seo <skyul@company100.com>.

* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::initializeWebProcess):

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

6 years agoUpstream changes to Pasteboard implementation for iOS.
enrica@apple.com [Fri, 27 Sep 2013 23:29:34 +0000 (23:29 +0000)]
Upstream changes to Pasteboard implementation for iOS.
https://bugs.webkit.org/show_bug.cgi?id=121818

Reviewed by Benjamin Poulain.

Source/WebCore:

* WebCore.exp.in:
* editing/Editor.cpp:
(WebCore::Editor::dispatchCPPEvent):
* editing/ios/EditorIOS.mm:
(WebCore::Editor::WebContentReader::addFragment):
(WebCore::Editor::WebContentReader::readWebArchive):
(WebCore::Editor::WebContentReader::readFilenames):
(WebCore::Editor::WebContentReader::readHTML):
(WebCore::Editor::WebContentReader::readRTFD):
(WebCore::Editor::WebContentReader::readRTF):
(WebCore::uniqueURLWithRelativePart):
(WebCore::Editor::WebContentReader::readImage):
(WebCore::Editor::WebContentReader::readURL):
(WebCore::Editor::WebContentReader::readPlainText):
(WebCore::Editor::webContentFromPasteboard):
(WebCore::Editor::pasteWithPasteboard):
(WebCore::Editor::createFragmentAndAddResources):
(WebCore::Editor::createFragmentForImageResourceAndAddResource):
* platform/Pasteboard.h:
* platform/PasteboardStrategy.h:
* platform/PlatformPasteboard.h:
* platform/ios/PasteboardIOS.mm:
(WebCore::PasteboardWebContent::PasteboardWebContent):
(WebCore::PasteboardWebContent::~PasteboardWebContent):
(WebCore::PasteboardImage::PasteboardImage):
(WebCore::PasteboardImage::~PasteboardImage):
(WebCore::Pasteboard::Pasteboard):
(WebCore::Pasteboard::clear):
(WebCore::Pasteboard::readString):
(WebCore::Pasteboard::writeString):
(WebCore::Pasteboard::types):
* platform/ios/PlatformPasteboardIOS.mm:
(WebCore::PlatformPasteboard::changeCount):
(WebCore::PlatformPasteboard::write):
(WebCore::PlatformPasteboard::count):
(WebCore::PlatformPasteboard::readBuffer):
(WebCore::PlatformPasteboard::readString):
(WebCore::PlatformPasteboard::readURL):
* platform/mac/PasteboardMac.mm:
(WebCore::PasteboardWebContent::PasteboardWebContent):
(WebCore::PasteboardWebContent::~PasteboardWebContent):
(WebCore::PasteboardImage::PasteboardImage):
(WebCore::PasteboardImage::~PasteboardImage):
* platform/mac/PlatformPasteboardMac.mm:

Source/WebKit/mac:

* WebCoreSupport/WebPlatformStrategies.h:
* WebCoreSupport/WebPlatformStrategies.mm:
(WebPlatformStrategies::writeToPasteboard):
(WebPlatformStrategies::getPasteboardItemsCount):
(WebPlatformStrategies::readBufferFromPasteboard):
(WebPlatformStrategies::readURLFromPasteboard):
(WebPlatformStrategies::readStringFromPasteboard):
(WebPlatformStrategies::changeCount):

Source/WebKit2:

* Shared/WebCoreArgumentCoders.cpp:
(CoreIPC::decodeSharedBuffer):
* Shared/WebCoreArgumentCoders.h:
* UIProcess/WebContext.h:
* UIProcess/WebContext.messages.in:
* UIProcess/mac/WebContextMac.mm:
(WebKit::WebContext::writeWebContentToPasteboard):
(WebKit::WebContext::writeImageToPasteboard):
(WebKit::WebContext::writeStringToPasteboard):
(WebKit::WebContext::readStringFromPasteboard):
(WebKit::WebContext::readURLFromPasteboard):
(WebKit::WebContext::readBufferFromPasteboard):
(WebKit::WebContext::getPasteboardItemsCount):
* WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
(WebKit::WebPlatformStrategies::writeToPasteboard):
(WebKit::WebPlatformStrategies::getPasteboardItemsCount):
(WebKit::WebPlatformStrategies::readBufferFromPasteboard):
(WebKit::WebPlatformStrategies::readURLFromPasteboard):
(WebKit::WebPlatformStrategies::readStringFromPasteboard):
(WebKit::WebPlatformStrategies::changeCount):
* WebProcess/WebCoreSupport/WebPlatformStrategies.h:

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

6 years ago[Windows] Unreviewed build fix following r156560.
roger_fong@apple.com [Fri, 27 Sep 2013 23:19:17 +0000 (23:19 +0000)]
[Windows] Unreviewed build fix following r156560.

* WebView.h:

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

6 years agoCrash on shape-outside when using calc()
hmuller@adobe.com [Fri, 27 Sep 2013 23:17:34 +0000 (23:17 +0000)]
Crash on shape-outside when using calc()
https://bugs.webkit.org/show_bug.cgi?id=121020

Reviewed by Dirk Schulze.

Source/WebCore:

This change prevents a crash caused by specifying a CSS Shape geometry
Length attribute with a calc() expression. It adds support for converting
Lengths to CSSPrimitive Values, in large part by migrating Blink changes
made to the calc classes since the split. Doing so required a few supporting
changes in some related classes, notably CSSPrimitiveValue.

Tests: fast/shapes/shape-inside/shape-inside-calc-crash.html
       css3/calc/simplification.html

* css/BasicShapeFunctions.cpp:
(WebCore::convertToCSSPrimitiveValue): Effectively use the new CSSPrimtiveValue(length,style) constructor to convert Lengths to CSSValues.
(WebCore::valueForBasicShape): Use the convertToCSSPrimitiveValue() function.
(WebCore::convertToLength): Added the CalculatedConversion convertToLength() flag to enable support for calc() valued Length Shape attributes.
* css/BasicShapeFunctions.h:
* css/CSSCalculationValue.cpp:
(WebCore::hasDoubleValue):
(WebCore::buildCssText):
(WebCore::CSSCalcValue::clampToPermittedRange):
(WebCore::CSSCalcValue::doubleValue):
(WebCore::CSSCalcExpressionNode::~CSSCalcExpressionNode):
(WebCore::CSSCalcPrimitiveValue::create):
(WebCore::CSSCalcPrimitiveValue::toCalcValue):
(WebCore::CSSCalcPrimitiveValue::doubleValue):
(WebCore::CSSCalcPrimitiveValue::computeLengthPx):
(WebCore::CSSCalcPrimitiveValue::primitiveType):
(WebCore::CSSCalcPrimitiveValue::CSSCalcPrimitiveValue):
(WebCore::determineCategory):
(WebCore::isIntegerResult):
(WebCore::CSSCalcBinaryOperation::create):
(WebCore::CSSCalcBinaryOperation::createSimplified):
(WebCore::CSSCalcBinaryOperation::doubleValue):
(WebCore::CSSCalcBinaryOperation::buildCssText):
(WebCore::CSSCalcBinaryOperation::primitiveType):
(WebCore::CSSCalcBinaryOperation::CSSCalcBinaryOperation):
(WebCore::CSSCalcBinaryOperation::getNumberSide):
(WebCore::CSSCalcBinaryOperation::evaluate):
(WebCore::CSSCalcBinaryOperation::evaluateOperator):
(WebCore::CSSCalcExpressionNodeParser::parseValue):
(WebCore::CSSCalcExpressionNodeParser::parseValueTerm):
(WebCore::CSSCalcExpressionNodeParser::parseValueMultiplicativeExpression):
(WebCore::CSSCalcExpressionNodeParser::parseAdditiveValueExpression):
(WebCore::CSSCalcValue::createExpressionNode):
(WebCore::CSSCalcValue::create):
* css/CSSCalculationValue.h:
(WebCore::CSSCalcExpressionNode::category):
(WebCore::CSSCalcValue::create):
(WebCore::CSSCalcValue::isInt):
(WebCore::CSSCalcValue::permittedValueRange):
(WebCore::CSSCalcValue::expressionNode):
(WebCore::CSSCalcValue::CSSCalcValue):
(WebCore::toCSSCalcValue):
* css/CSSComputedStyleDeclaration.cpp:
(WebCore::ComputedStyleExtractor::propertyValue): Pass the style along to the new valueForBasicShape() function.
* css/CSSPrimitiveValue.cpp:
(WebCore::CSSPrimitiveValue::unitCategory): Made this function public so that CSSCalculationValue could use it.
(WebCore::CSSPrimitiveValue::conversionToCanonicalUnitsScaleFactor): Ditto.
(WebCore::CSSPrimitiveValue::primitiveType): Cleared trailing whitespace.
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Construct a CSSPrimitiveValue from a Length and a RenderStyle*.
(WebCore::CSSPrimitiveValue::init): The common part of the two Length CSSPrimitiveValue constructors.
(WebCore::CSSPrimitiveValue::computeLengthDouble): Moved the case labels to the left per check-webkit-style.
(WebCore::CSSPrimitiveValue::getStringValue): Ditto.
(WebCore::CSSPrimitiveValue::getDoubleValue): Removed trailing whitespace.
* css/CSSPrimitiveValue.h:
(WebCore::CSSPrimitiveValue::create): Construct a CSSPrimitiveValue from a Length and a RenderStyle*.
(WebCore::toCSSPrimitiveValue): Check the CSSValue*'s validity with ASSERT_WITH_SECURITY_IMPLICATION before casting to CSSPrimitiveValue*.
* css/CSSValuePool.h:
(WebCore::CSSValuePool::createValue): A new overload that delegates to the new CSSPrimitiveValue(length,style) constructor.
* platform/CalculationValue.h:
(WebCore::CalculationValue::operator==):
(WebCore::CalculationValue::isNonNegative):
(WebCore::CalculationValue::expression):
(WebCore::CalcExpressionNumber::value):
(WebCore::toCalcExpressionNumber):
(WebCore::CalcExpressionLength::CalcExpressionLength):
(WebCore::CalcExpressionLength::length):
(WebCore::toCalcExpressionLength):
(WebCore::CalcExpressionBinaryOperation::leftSide):
(WebCore::CalcExpressionBinaryOperation::rightSide):
(WebCore::CalcExpressionBinaryOperation::getOperator):
(WebCore::toCalcExpressionBinaryOperation):
(WebCore::CalcExpressionBlendLength::CalcExpressionBlendLength):
(WebCore::CalcExpressionBlendLength::from):
(WebCore::CalcExpressionBlendLength::to):
(WebCore::CalcExpressionBlendLength::progress):
(WebCore::toCalcExpressionBlendLength):

LayoutTests:

Specifying a CSS Shape geometry Length attribute with a calc() expression
or looking up the value with getComputedStyle(), caused crashes.

* fast/shapes/shape-inside/shape-inside-calc-crash-expected.txt: Added.
* fast/shapes/shape-inside/shape-inside-calc-crash.html: Added.
* css3/calc/simplification-expected.txt: Added
* css3/calc/simplification.html: Added
* LayoutTests/css3/calc/cssom-expected.txt:

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

6 years agoLayout Test animations/combo-transform-translate+scale.html is flaky
ap@apple.com [Fri, 27 Sep 2013 23:09:03 +0000 (23:09 +0000)]
Layout Test animations/combo-transform-translate+scale.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=122040

* platform/mac/TestExpectations: Marking as such.

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

6 years agoLayout Test media/track/track-cue-overlap-snap-to-lines-not-set.html is flaky
ap@apple.com [Fri, 27 Sep 2013 23:05:27 +0000 (23:05 +0000)]
Layout Test media/track/track-cue-overlap-snap-to-lines-not-set.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=122039

* platform/mac/TestExpectations: Marking as such.

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

6 years agoanimations/transform-non-accelerated.html is flaky
ap@apple.com [Fri, 27 Sep 2013 23:01:53 +0000 (23:01 +0000)]
animations/transform-non-accelerated.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=122038

* platform/mac/TestExpectations: Marking as such.

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