Generic JSObject::put should handle static properties in the classinfo hierarchy
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-01-24  Oliver Hunt  <oliver@apple.com>
2
3         Generic JSObject::put should handle static properties in the classinfo hierarchy
4         https://bugs.webkit.org/show_bug.cgi?id=127523
5
6         Reviewed by Geoffrey Garen.
7
8         Update the bindings generator to emit the flag indicating the presence
9         of setters, and remove the many (now unnecessary) put overrides.
10         Tested with run-jsc-benchmarks and shows neutral performance. A few of the
11         micro benchmarks actually get a significant performance increase which
12         is nice.
13
14         * bindings/js/JSDOMWindowCustom.cpp:
15         (WebCore::JSDOMWindow::put):
16             We still need a custom call to lookupPut here in order
17             to get the magic security semantics of the window object.
18         * bindings/scripts/CodeGeneratorJS.pm:
19         (hashTableAccessor):
20         (prototypeHashTableAccessor):
21         (constructorHashTableAccessor):
22         (GenerateImplementation):
23         (GenerateHashTable):
24         (GenerateConstructorHelperMethods):
25
26         * bindings/js/JSDOMWindowCustom.cpp:
27         (WebCore::JSDOMWindow::put):
28         * bindings/scripts/CodeGeneratorJS.pm:
29         (hashTableAccessor):
30         (prototypeHashTableAccessor):
31         (constructorHashTableAccessor):
32         (InstanceOverridesPutImplementation):
33         (InstanceOverridesPutDeclaration):
34         (GenerateHeader):
35         (GenerateImplementation):
36         (GenerateHashTable):
37         (GenerateConstructorHelperMethods):
38         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
39         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
40         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
41         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
42         * bindings/scripts/test/JS/JSTestException.cpp:
43         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
44         * bindings/scripts/test/JS/JSTestInterface.cpp:
45         (WebCore::JSTestInterface::put):
46         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
47         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
48         * bindings/scripts/test/JS/JSTestNode.cpp:
49         * bindings/scripts/test/JS/JSTestObj.cpp:
50         * bindings/scripts/test/JS/JSTestObj.h:
51         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
52         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
53         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
54         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
55         * bindings/scripts/test/JS/JSTestTypedefs.h:
56         * bindings/scripts/test/JS/JSattribute.cpp:
57         * bindings/scripts/test/JS/JSreadonly.cpp:
58         * html/canvas/WebGLRenderingContext.idl:
59           Remove bogus attribute, as it has never been in the spec and should not
60           have been added.
61
62 2014-01-24  David Hyatt  <hyatt@apple.com>
63
64         [New Multicolumn] Eliminate RenderMultiColumnBlock
65         https://bugs.webkit.org/show_bug.cgi?id=127565
66
67         Reviewed by Antti Koivisto.
68
69         This patch eliminates RenderMultiColumnBlock and folds all of its remaining code
70         back into RenderBlockFlow. This allows all block flows to support multi-column
71         layout, including table cells, list items, and the RenderView itself.
72
73         * CMakeLists.txt:
74         * WebCore.order:
75         * WebCore.vcxproj/WebCore.vcxproj:
76         * WebCore.vcxproj/WebCore.vcxproj.filters:
77         * WebCore.xcodeproj/project.pbxproj:
78         Remove RenderMultiColumnBlock from the makefiles.
79
80         * rendering/RenderBlock.cpp:
81         (WebCore::RenderBlock::adjustIntrinsicLogicalWidthsForColumns):
82         Tweak the comment, since it was no longer accurate.
83
84         * rendering/RenderBlock.h:
85         Move some functions down into RenderBlockFlow.
86
87         * rendering/RenderBlockFlow.cpp:
88         (WebCore::RenderBlockFlow::RenderBlockFlow):
89         (WebCore::RenderBlockFlow::createMultiColumnFlowThreadIfNeeded):
90         (WebCore::RenderBlockFlow::styleDidChange):
91         (WebCore::RenderBlockFlow::relayoutForPagination):
92         (WebCore::RenderBlockFlow::layoutSpecialExcludedChild):
93         (WebCore::RenderBlockFlow::updateLogicalWidthAndColumnWidth):
94         (WebCore::RenderBlockFlow::addChild):
95         (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
96          * rendering/RenderBlockFlow.h:
97          Move a bunch of functions from RenderMultiColumnBlock up into RenderBlockFlow.
98
99         * rendering/RenderBox.cpp:
100         (WebCore::RenderBox::isUnsplittableForPagination):
101         Calls isMultiColumnBlockFlow() now instead of testing for a specific renderer type.
102
103         * rendering/RenderElement.cpp:
104         (WebCore::RenderElement::createFor):
105         Remove the multicolumn block creation code, since we always make a block flow now.
106
107         * rendering/RenderMultiColumnBlock.cpp: Removed.
108         * rendering/RenderMultiColumnBlock.h: Removed.
109         Nuke the files.
110
111         * rendering/RenderMultiColumnFlowThread.cpp:
112         (WebCore::RenderMultiColumnFlowThread::initialLogicalWidth):
113         (WebCore::RenderMultiColumnFlowThread::autoGenerateRegionsToBlockOffset):
114         * rendering/RenderMultiColumnSet.cpp:
115         (WebCore::RenderMultiColumnSet::heightAdjustedForSetOffset):
116         (WebCore::RenderMultiColumnSet::addForcedBreak):
117         (WebCore::RenderMultiColumnSet::recalculateBalancedHeight):
118         (WebCore::RenderMultiColumnSet::updateLogicalWidth):
119         (WebCore::RenderMultiColumnSet::prepareForLayout):
120         (WebCore::RenderMultiColumnSet::columnGap):
121         (WebCore::RenderMultiColumnSet::paintColumnRules):
122         Change all of the functions in the multicolumnset and multicolumnflowthread classes
123         to cast the parent to a RenderBlockFlow now instead of a RenderMultiColumnBlock.
124         Change the code to call through to multiColumnFlowThread() for column-specific information
125         for that parent block.
126
127         * rendering/RenderObject.h:
128         (WebCore::RenderObject::isMultiColumnBlockFlow):
129         Remove isRenderMultiColumnBlock() and replace with isMultiColumnBlockFlow().
130
131         * rendering/RenderingAllInOne.cpp:
132         Remove RenderMultiColumnBlock include.
133         
134 2014-01-24  Brady Eidson  <beidson@apple.com>
135
136         IDB: support createIndex/deleteIndex messaging
137         https://bugs.webkit.org/show_bug.cgi?id=127546
138
139         Reviewed by Tim Horton.
140
141         * WebCore.exp.in: Export a needed CrossThreadCopier
142
143 2014-01-24  Daniel Bates  <dabates@apple.com>
144
145         Fix the Windows build after <http://trac.webkit.org/changeset/162704>
146         (https://bugs.webkit.org/show_bug.cgi?id=127293)
147
148         Only include TargetConditionals.h when building on a Darwin-based OS.
149         Also, check that TARGET_OS_IPHONE is defined before referencing its value
150         since it will be undefined when building on Windows.
151
152         * bindings/objc/PublicDOMInterfaces.h:
153
154 2014-01-24  Daniel Bates  <dabates@apple.com>
155
156         Bindings generation tests hit an error trying to include wtf/Platform.h after r161638
157         https://bugs.webkit.org/show_bug.cgi?id=127293
158
159         Reviewed by Alexey Proskuryakov.
160
161         Include TargetConditionals.h instead of wtf/Platform.h as the latter isn't available
162         in the public SDK.
163
164         As a side effect of this change, replace usage of PLATFORM(IOS) with TARGET_OS_IPHONE.
165
166         * bindings/objc/PublicDOMInterfaces.h:
167
168 2014-01-21  David Hyatt  <hyatt@apple.com>
169
170         [New Multicolumn] Table cells and list items need to work as multicolumn blocks.
171         https://bugs.webkit.org/show_bug.cgi?id=127365
172         
173         This patch is a first step towards eliminating RenderMultiColumnBlock and moving
174         all its functionality into RenderBlockFlow. Doing so will allow table cells, list
175         items and the RenderView to use the new multi-column layout.
176         
177         Reviewed by Simon Fraser.
178
179         * rendering/RenderBlockFlow.cpp:
180         (WebCore::RenderBlockFlow::setMultiColumnFlowThread):
181         * rendering/RenderBlockFlow.h:
182         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::RenderBlockFlowRareData):
183         (WebCore::RenderBlockFlow::multiColumnFlowThread):
184         Add the flow thread pointer to the multi-column flow thread to RenderBlockFlow's
185         rare data. This lets us use only one pointer in the rare data to point to an object
186         that can hold all of the rest of the multi-column info.
187
188         * rendering/RenderMultiColumnBlock.cpp:
189         (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
190         Move the construction of the flow thread to the constructor. This ensures we
191         never have a null flow thread and lets us avoid having to null check it for
192         empty multi-column blocks.
193
194         (WebCore::RenderMultiColumnBlock::columnHeightAvailable):
195         (WebCore::RenderMultiColumnBlock::columnWidth):
196         (WebCore::RenderMultiColumnBlock::columnCount):
197         (WebCore::RenderMultiColumnBlock::updateLogicalWidthAndColumnWidth):
198         The above functions now call through to the multi-column flow thread for results.
199
200         (WebCore::RenderMultiColumnBlock::checkForPaginationLogicalHeightChange):
201          Set the column height available on the flow thread.
202
203         (WebCore::RenderMultiColumnBlock::relayoutForPagination):
204         The balancing pass and guard is in the multi-column flow thread now.
205
206         (WebCore::RenderMultiColumnBlock::addChild):
207         Don't have to create the flow thread here any longer, since we do it up front
208         in the constructor of RenderMultiColumnBlock.
209
210         (WebCore::RenderMultiColumnBlock::layoutSpecialExcludedChild):
211         Don't need the null check of the flow thread any more.
212
213         * rendering/RenderMultiColumnBlock.h:
214         Change the inlined functions to not be inlined, since they need to call
215         RenderMultiColumnFlowThread functions now.
216
217         * rendering/RenderMultiColumnFlowThread.cpp:
218         (WebCore::RenderMultiColumnFlowThread::RenderMultiColumnFlowThread):
219         Init the new member variables we moved here from RenderMultiColumnBlock.
220
221         (WebCore::RenderMultiColumnFlowThread::computeColumnCountAndWidth):
222         Moved from RenderMultiColumnBlock.
223
224         * rendering/RenderMultiColumnFlowThread.h:
225         Add public getters/setters to the member variables so that RenderMultiColumnBlock can
226         still see them. Move the member variables here from RenderMultiColumnBlock.
227
228         * rendering/RenderMultiColumnSet.cpp:
229         (WebCore::RenderMultiColumnSet::calculateBalancedHeight):
230         (WebCore::RenderMultiColumnSet::prepareForLayout):
231         (WebCore::RenderMultiColumnSet::columnCount):
232         Call through to the flow thread instead.
233
234 2014-01-24  Zan Dobersek  <zdobersek@igalia.com>
235
236         Unreviewed GTK build fix after r162663.
237
238         * platform/gtk/ScrollViewGtk.cpp:
239         (WebCore::ScrollView::visibleContentRectInternal): Renamed from visibleContentRect.
240
241 2014-01-24  Zan Dobersek  <zdobersek@igalia.com>
242
243         Move HistoryItem to std::unique_ptr
244         https://bugs.webkit.org/show_bug.cgi?id=127275
245
246         Reviewed by Darin Adler.
247
248         Replace the uses of OwnPtr and PassOwnPtr in the HistoryItem class with std::unique_ptr.
249
250         * history/HistoryItem.cpp:
251         (WebCore::HistoryItem::HistoryItem):
252         (WebCore::HistoryItem::reset):
253         (WebCore::HistoryItem::addRedirectURL):
254         (WebCore::HistoryItem::setRedirectURLs):
255         * history/HistoryItem.h:
256         * history/mac/HistoryItemMac.mm:
257         (WebCore::HistoryItem::setTransientProperty):
258         WebCore.exp.in: Update the symbol.
259
260 2014-01-23  Morten Stenshorne  <mstensho@opera.com>
261
262         Region based multicol: unresolvable percent height results in 1px tall multicol
263         https://bugs.webkit.org/show_bug.cgi?id=122826
264
265         Reviewed by David Hyatt.
266
267         If a box has a percentage height, but the computed height of its
268         containing block is auto, the computed height of the box also becomes
269         auto. computeContentLogicalHeight() returns -1 if the height isn't
270         resolvable, and we need to make sure that such a value doesn't
271         constrain the height of the multicol container.
272
273         Tests: fast/multicol/newmulticol/unresolvable-percent-height-2.html
274                fast/multicol/newmulticol/unresolvable-percent-height.html
275                fast/multicol/newmulticol/unresolvable-percent-max-height-2.html
276                fast/multicol/newmulticol/unresolvable-percent-max-height.html
277
278         * rendering/RenderMultiColumnSet.cpp:
279         (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
280         (WebCore::RenderMultiColumnSet::calculateBalancedHeight):
281         (WebCore::RenderMultiColumnSet::recalculateBalancedHeight):
282         (WebCore::RenderMultiColumnSet::prepareForLayout):
283
284 2014-01-23  Joseph Pecoraro  <pecoraro@apple.com>
285
286         Move ContentSearchUtils, ScriptBreakpoint, and ScriptDebugListener into JavaScriptCore for inspector
287         https://bugs.webkit.org/show_bug.cgi?id=127537
288
289         Reviewed by Timothy Hatcher.
290
291           - Rename ContentSearchUtils => ContentSearchUtilities and move to JavaScriptCore.
292           - Move ScriptBreakpoint and ScriptDebugListener to JavaScriptCore.
293           - Move them all to namespace Inspector.
294           - Update build files and users to the new names.
295
296         No change in functionality, just moving code.
297
298         * CMakeLists.txt:
299         * ForwardingHeaders/inspector/ContentSearchUtilities.h: Added.
300         * ForwardingHeaders/inspector/ScriptBreakpoint.h: Added.
301         * ForwardingHeaders/inspector/ScriptDebugListener.h: Added.
302         * GNUmakefile.list.am:
303         * WebCore.vcxproj/WebCore.vcxproj:
304         * WebCore.vcxproj/WebCore.vcxproj.filters:
305         * WebCore.xcodeproj/project.pbxproj:
306         * bindings/js/PageScriptDebugServer.cpp:
307         * bindings/js/PageScriptDebugServer.h:
308         * bindings/js/ScriptDebugServer.cpp:
309         * bindings/js/ScriptDebugServer.h:
310         * bindings/js/WorkerScriptDebugServer.cpp:
311         * bindings/js/WorkerScriptDebugServer.h:
312         * inspector/InspectorAllInOne.cpp:
313         * inspector/InspectorDebuggerAgent.cpp:
314         (WebCore::InspectorDebuggerAgent::searchInContent):
315         (WebCore::InspectorDebuggerAgent::sourceMapURLForScript):
316         (WebCore::InspectorDebuggerAgent::didParseSource):
317         * inspector/InspectorDebuggerAgent.h:
318         * inspector/InspectorPageAgent.cpp:
319         (WebCore::InspectorPageAgent::sourceMapURLForResource):
320         (WebCore::InspectorPageAgent::searchInResource):
321         (WebCore::InspectorPageAgent::searchInResources):
322         * inspector/InspectorStyleSheet.cpp:
323         (WebCore::buildSourceRangeObject):
324         (WebCore::InspectorStyleSheet::lineEndings):
325         (WebCore::InspectorStyleSheetForInlineStyle::lineEndings):
326
327 2014-01-23  Joseph Pecoraro  <pecoraro@apple.com>
328
329         Move RegularExpression into JavaScriptCore for inspector
330         https://bugs.webkit.org/show_bug.cgi?id=127526
331
332         Reviewed by Geoffrey Garen.
333
334         Update as appropriate for the moved file and namespace
335         change for class RegularExpression.
336
337         * CMakeLists.txt:
338         * ForwardingHeaders/yarr/RegularExpression.h: Added.
339         * GNUmakefile.list.am:
340         * WebCore.exp.in:
341         * WebCore.vcxproj/WebCore.vcxproj:
342         * WebCore.vcxproj/WebCore.vcxproj.filters:
343         * WebCore.xcodeproj/project.pbxproj:
344         * dom/DOMImplementation.h:
345         * html/BaseCheckableInputType.cpp:
346         * html/BaseTextInputType.cpp:
347         (WebCore::BaseTextInputType::patternMismatch):
348         * html/EmailInputType.cpp:
349         (WebCore::isValidEmailAddress):
350         * html/InputType.cpp:
351         * inspector/ContentSearchUtils.cpp:
352         (WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
353         (WebCore::ContentSearchUtils::createSearchRegex):
354         (WebCore::ContentSearchUtils::countRegularExpressionMatches):
355         (WebCore::ContentSearchUtils::searchInTextByLines):
356         * inspector/ContentSearchUtils.h:
357         * inspector/InspectorDebuggerAgent.cpp:
358         (WebCore::matches):
359         (WebCore::InspectorDebuggerAgent::breakpointActionLog):
360         (WebCore::InspectorDebuggerAgent::breakpointActionSound):
361         * inspector/InspectorDebuggerAgent.h:
362         * inspector/InspectorPageAgent.cpp:
363         (WebCore::InspectorPageAgent::searchInResources):
364         * inspector/InspectorPageAgent.h:
365         * inspector/InspectorRuntimeAgent.cpp:
366         * inspector/InspectorRuntimeAgent.h:
367         * inspector/InspectorStyleSheet.cpp:
368         (WebCore::selectorsFromSource):
369         * inspector/WorkerDebuggerAgent.cpp:
370         * page/Frame.cpp:
371         (WebCore::createRegExpForLabels):
372         (WebCore::Frame::searchForLabelsAboveCell):
373         (WebCore::Frame::searchForLabelsBeforeElement):
374         (WebCore::matchLabelsAgainstString):
375         * page/Frame.h:
376         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
377         (WebCore::GraphicsContext3D::getUnmangledInfoLog):
378
379 2014-01-23  Brady Eidson  <beidson@apple.com>
380
381         IDB: Support IDBObjectStore.clear()
382         https://bugs.webkit.org/show_bug.cgi?id=127541
383         
384         Reviewed by Anders Carlsson.
385
386         The backing store should never be performing callbacks directly:
387         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp:
388         (WebCore::IDBServerConnectionLevelDB::clearObjectStore):
389
390         Instead, the transaction operations should do that themselves:
391         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
392         (WebCore::ClearObjectStoreOperation::perform):
393         * Modules/indexeddb/IDBTransactionBackendOperations.h:
394         (WebCore::ClearObjectStoreOperation::transaction):
395
396 2014-01-23  Dan Bernstein  <mitz@apple.com>
397
398         <rdar://problem/15875326> REGRESSION (r162257): Assertion failure (should not be reached) in CSSPreloadScanner::tokenize()
399         https://bugs.webkit.org/show_bug.cgi?id=127540
400
401         Reviewed by Anders Carlsson.
402
403         No new tests, because I could not reproduce the bug reliably and I don’t know how to trigger
404         it.
405
406         * html/parser/CSSPreloadScanner.cpp:
407         (WebCore::CSSPreloadScanner::scan): Check for the DoneParsingImportRules before tokenizing
408         a character, not after. This restores the logic from before r162257.
409
410 2014-01-23  Jer Noble  <jer.noble@apple.com>
411
412         [iOS] Protect against possbile deadlock by delaying video layer creation
413         https://bugs.webkit.org/show_bug.cgi?id=127505
414
415         Reviewed by Eric Carlson.
416
417         Work around a possible deadlock on iOS when creating a media element
418         backed by AVFoundation by delaying creation of the AVPlayerLayer.
419         The deadlock can occur when the web thread is doing CALayer layout
420         while taking the web thread lock, while CoreMedia is doing property
421         access on an async thread while taking the CM lock, and each is waiting
422         for the other's lock to be released.
423
424         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
425         (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer):
426
427 2014-01-23  Jer Noble  <jer.noble@apple.com>
428
429         [MSE][Mac] Crash when reloading a page during playback
430         https://bugs.webkit.org/show_bug.cgi?id=126903
431
432         Reviewed by Eric Carlson.
433
434         Periodic time observers added to AVSampleBufferRenderSynchronizer will execute their
435         callback block even after being removed with -removeTimeObserver:, which is tracked by
436         <rdar://problem/15798050>. Work around this problem by passing a WeakPtr into the block
437         and bail early if the owning media player has been destroyed.
438
439         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
440         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::createWeakPtr):
441         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
442         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC):
443
444 2014-01-23  ChangSeok Oh  <changseok.oh@collabora.com>
445
446         Dragging from inner side of video to outside causes a crash
447         https://bugs.webkit.org/show_bug.cgi?id=126338
448
449         Reviewed by Jer Noble.
450
451         The crash happens while dragging mouse cursor through timeline control to outside
452         of video region. This is beacause media controls are selected with the drag.
453         The media controls disappear when mouse cursor goes outside of video though
454         the dragging/selection proceeds. If once media controls are hidden, related element
455         lose their renderers. However the drag is still under going. it requires shadowPseudoId
456         of the selected controls. Untorntunately, SliderThumbElement/SliderContainerElement
457         don't return a static value for the shadowPseudoId unlike other media controls,
458         but they need a renderer to determine it. This is the reason of crash.
459
460         Test: media/media-controller-drag-crash.html
461
462         * html/shadow/SliderThumbElement.cpp:
463         (WebCore::SliderThumbElement::shadowPseudoId):
464         (WebCore::SliderContainerElement::shadowPseudoId):
465
466 2014-01-23  Brady Eidson  <beidson@apple.com>
467
468         IDB: Implement SQLite backing store 'get' support
469         https://bugs.webkit.org/show_bug.cgi?id=127502
470
471         Reviewed by Tim Horton.
472
473         Get a KeyRange from a KeyRangeData:
474         * Modules/indexeddb/IDBKeyRangeData.cpp:
475         (WebCore::IDBKeyRangeData::maybeCreateIDBKeyRange):
476         * Modules/indexeddb/IDBKeyRangeData.h:
477
478         Add collation function support to SQLiteDatabase:
479         * platform/sql/SQLiteDatabase.cpp:
480         (WebCore::destroyCollationFunction):
481         (WebCore::callCollationFunction):
482         (WebCore::SQLiteDatabase::setCollationFunction):
483         (WebCore::SQLiteDatabase::removeCollationFunction):
484         * platform/sql/SQLiteDatabase.h:
485
486         * WebCore.exp.in:
487
488 2014-01-23  Jon Honeycutt  <jhoneycutt@apple.com>
489
490         Assertion failure in WebCore::PseudoElement::didRecalcStyle()
491         <https://bugs.webkit.org/show_bug.cgi?id=126761>
492         <rdar://problem/15793540>
493
494         Reviewed by Andy Estes.
495
496         Test: fast/images/animate-list-item-image-assertion.html
497
498         * dom/PseudoElement.cpp:
499         (WebCore::PseudoElement::didRecalcStyle):
500         Check isRenderImage() rather than isImage() before casting to
501         RenderImage.
502
503         * editing/ios/EditorIOS.mm:
504         (WebCore::getImage):
505         Ditto.
506
507         * editing/mac/EditorMac.mm:
508         (WebCore::getImage):
509         Ditto.
510
511         * html/HTMLImageElement.cpp:
512         (WebCore::HTMLImageElement::parseAttribute):
513         (WebCore::HTMLImageElement::didAttachRenderers):
514         Ditto.
515
516         * loader/ImageLoader.cpp:
517         (WebCore::ImageLoader::renderImageResource):
518         Ditto.
519
520         * page/DragController.cpp:
521         (WebCore::getCachedImage):
522         Ditto.
523
524         * rendering/RenderLayerBacking.cpp:
525         (WebCore::RenderLayerBacking::isDirectlyCompositedImage):
526         (WebCore::RenderLayerBacking::updateImageContents):
527         Ditto.
528
529 2014-01-23  Joseph Pecoraro  <pecoraro@apple.com>
530
531         Web Inspector: Remove recompileAllJSFunctions timer in ScriptDebugServer
532         https://bugs.webkit.org/show_bug.cgi?id=127409
533
534         Reviewed by Geoffrey Garen.
535
536         Covered by existing tests.
537
538         * bindings/js/ScriptDebugServer.h:
539         * bindings/js/ScriptDebugServer.cpp:
540         (WebCore::ScriptDebugServer::ScriptDebugServer):
541         Remove m_recompileTimer and the recompile soon function.
542         We can just recompile immediately in all existing cases.
543
544         * bindings/js/PageScriptDebugServer.h:
545         * bindings/js/PageScriptDebugServer.cpp:
546         (WebCore::PageScriptDebugServer::addListener):
547         (WebCore::PageScriptDebugServer::removeListener):
548         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
549         (WebCore::PageScriptDebugServer::didAddFirstListener):
550         (WebCore::PageScriptDebugServer::didRemoveLastListener):
551         Add a "didAddFirstListener" to match "didRemoveLastListener".
552         Only recompile functions when we attach the debugger and when
553         we detach the last listener.
554
555         * bindings/js/WorkerScriptDebugServer.cpp:
556         (WebCore::WorkerScriptDebugServer::addListener):
557         (WebCore::WorkerScriptDebugServer::removeListener):
558         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
559         Same thing. Also rearrange the functions to read better.
560
561         * inspector/InspectorProfilerAgent.cpp:
562         Use the direct recompile function instead of the removed "soon" version.
563
564         * WebCore.exp.in:
565         Update disconnectFrontend symbol.
566
567         * page/PageDebuggable.cpp:
568         (WebCore::PageDebuggable::disconnect):
569         * testing/Internals.cpp:
570         (WebCore::Internals::closeDummyInspectorFrontend):
571         * workers/WorkerMessagingProxy.cpp:
572         (WebCore::disconnectFromWorkerGlobalScopeInspectorTask):
573         Include an InspectorDisconnectReason when calling disconnectFrontend.
574
575         * inspector/InspectorDatabaseAgent.h:
576         * inspector/InspectorDebuggerAgent.cpp:
577         (WebCore::InspectorDebuggerAgent::disable):
578         (WebCore::InspectorDebuggerAgent::willDestroyFrontendAndBackend):
579         If the disconnect reason is the page will be destroyed, don't recompile when disconnecting.
580
581         * inspector/InspectorProfilerAgent.h:
582         * inspector/InspectorProfilerAgent.cpp:
583         (WebCore::InspectorProfilerAgent::enable):
584         (WebCore::InspectorProfilerAgent::disable):
585         (WebCore::InspectorProfilerAgent::willDestroyFrontendAndBackend):
586         If the disconnect reason is the page will be destroyed, don't recompile when disconnecting.
587
588         * inspector/InspectorController.h:
589         * inspector/InspectorController.cpp:
590         (WebCore::InspectorController::inspectedPageDestroyed):
591         (WebCore::InspectorController::disconnectFrontend):
592         (WebCore::InspectorController::close):
593         Pass different reasons for the different disconnect reasons.
594
595         * inspector/WorkerInspectorController.h:
596         * inspector/WorkerInspectorController.cpp:
597         (WebCore::WorkerInspectorController::~WorkerInspectorController):
598         (WebCore::WorkerInspectorController::disconnectFrontend):
599         Pass different reasons for the different disconnect reasons.
600
601         * inspector/InspectorApplicationCacheAgent.cpp:
602         (WebCore::InspectorApplicationCacheAgent::willDestroyFrontendAndBackend):
603         * inspector/InspectorApplicationCacheAgent.h:
604         * inspector/InspectorCSSAgent.cpp:
605         (WebCore::InspectorCSSAgent::willDestroyFrontendAndBackend):
606         * inspector/InspectorCSSAgent.h:
607         * inspector/InspectorCanvasAgent.cpp:
608         (WebCore::InspectorCanvasAgent::willDestroyFrontendAndBackend):
609         * inspector/InspectorCanvasAgent.h:
610         * inspector/InspectorConsoleAgent.cpp:
611         (WebCore::InspectorConsoleAgent::willDestroyFrontendAndBackend):
612         * inspector/InspectorConsoleAgent.h:
613         * inspector/InspectorDOMAgent.cpp:
614         (WebCore::InspectorDOMAgent::willDestroyFrontendAndBackend):
615         * inspector/InspectorDOMAgent.h:
616         * inspector/InspectorDOMDebuggerAgent.cpp:
617         (WebCore::InspectorDOMDebuggerAgent::willDestroyFrontendAndBackend):
618         * inspector/InspectorDOMDebuggerAgent.h:
619         * inspector/InspectorDOMStorageAgent.cpp:
620         (WebCore::InspectorDOMStorageAgent::willDestroyFrontendAndBackend):
621         * inspector/InspectorDOMStorageAgent.h:
622         * inspector/InspectorDatabaseAgent.cpp:
623         (WebCore::InspectorDatabaseAgent::willDestroyFrontendAndBackend):
624         * inspector/InspectorDebuggerAgent.h:
625         * inspector/InspectorHeapProfilerAgent.cpp:
626         (WebCore::InspectorHeapProfilerAgent::willDestroyFrontendAndBackend):
627         * inspector/InspectorHeapProfilerAgent.h:
628         * inspector/InspectorIndexedDBAgent.cpp:
629         (WebCore::InspectorIndexedDBAgent::willDestroyFrontendAndBackend):
630         * inspector/InspectorIndexedDBAgent.h:
631         * inspector/InspectorInputAgent.cpp:
632         (WebCore::InspectorInputAgent::willDestroyFrontendAndBackend):
633         * inspector/InspectorInputAgent.h:
634         * inspector/InspectorLayerTreeAgent.cpp:
635         (WebCore::InspectorLayerTreeAgent::willDestroyFrontendAndBackend):
636         * inspector/InspectorLayerTreeAgent.h:
637         * inspector/InspectorMemoryAgent.cpp:
638         (WebCore::InspectorMemoryAgent::willDestroyFrontendAndBackend):
639         * inspector/InspectorMemoryAgent.h:
640         * inspector/InspectorPageAgent.cpp:
641         (WebCore::InspectorPageAgent::willDestroyFrontendAndBackend):
642         * inspector/InspectorPageAgent.h:
643         * inspector/InspectorResourceAgent.cpp:
644         (WebCore::InspectorResourceAgent::willDestroyFrontendAndBackend):
645         * inspector/InspectorResourceAgent.h:
646         * inspector/InspectorTimelineAgent.cpp:
647         (WebCore::InspectorTimelineAgent::willDestroyFrontendAndBackend):
648         * inspector/InspectorTimelineAgent.h:
649         * inspector/InspectorWorkerAgent.cpp:
650         (WebCore::InspectorWorkerAgent::willDestroyFrontendAndBackend):
651         * inspector/InspectorWorkerAgent.h:
652         * inspector/PageDebuggerAgent.cpp:
653         (WebCore::PageDebuggerAgent::disable):
654         (WebCore::PageDebuggerAgent::stopListeningScriptDebugServer):
655         * inspector/PageDebuggerAgent.h:
656         * inspector/PageRuntimeAgent.cpp:
657         (WebCore::PageRuntimeAgent::willDestroyFrontendAndBackend):
658         * inspector/PageRuntimeAgent.h:
659         * inspector/WorkerDebuggerAgent.cpp:
660         (WebCore::WorkerDebuggerAgent::stopListeningScriptDebugServer):
661         * inspector/WorkerDebuggerAgent.h:
662         * inspector/WorkerRuntimeAgent.cpp:
663         (WebCore::WorkerRuntimeAgent::willDestroyFrontendAndBackend):
664         * inspector/WorkerRuntimeAgent.h:
665         Include InspectorDisconnectReason param.
666
667 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
668
669         Another Windows fix: include <algorithm> for std::min and std::max.
670         
671         * platform/graphics/IntSize.h:
672
673 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
674
675         Try to fix Windows build.
676
677         * platform/win/PopupMenuWin.cpp:
678         (WebCore::PopupMenuWin::visibleSize):
679         * platform/win/PopupMenuWin.h:
680
681 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
682
683         Make visibleContentRect() return actualVisibleContentRect() on iOS most of the time
684         https://bugs.webkit.org/show_bug.cgi?id=127456
685         
686         Reviewed by Antti Koivisto.
687         
688         On iOS, visibleContentRect() returns the entire document rect for historical
689         reasons, and actualVisibleContentRect() returns what visibleContentRect()
690         returns on other platforms.
691         
692         In addition, actualVisibleContentRect() was returning an empty rect in WK2.
693         
694         Reduce the confusion of #ifdefs by making visibleContentRect() behave like
695         actualVisibleContentRect() by default on iOS. Where it needs the old behavior,
696         an optional parameter, LegacyIOSDocumentVisibleRect, provides this.
697         
698         Achieve this by having the virtual ScrollableArea::visibleContentRectInternal(),
699         which is called by non-virtual visibleContentRect() and visibleContentRectIncludingScrollbars().
700         
701         Similarly clean up visibleHeight/visibleWidth functions by having visibleSize() be virtual,
702         with non-virtual visibleHeight() and visibleWidth().
703         
704         ScrollableArea subclasses override visibleContentRectInternal() and visibleSize() where necessary.
705         
706         Mechanically change all the call sites of actualVisibleContentRect() to
707         use visibleContentRect(), and the call sites of visibleContentRect()
708         to visibleContentRect(..., LegacyIOSDocumentVisibleRect), adding comments
709         where this may not be appropriate.
710         
711         Change callers of visibleContentRect(IncludeScrollbars...) to visibleContentRectIncludingScrollbars().
712         
713         Also add actualScrollPosition(), and clean up some actualScroll* call sites.
714         
715         No behavior change.
716
717         * WebCore.exp.in:
718         * accessibility/AccessibilityObject.cpp:
719         (WebCore::AccessibilityObject::isOnscreen):
720         (WebCore::AccessibilityObject::scrollToMakeVisibleWithSubFocus):
721         * accessibility/AccessibilityRenderObject.cpp:
722         (WebCore::AccessibilityRenderObject::isOffScreen):
723         * dom/Document.cpp:
724         (WebCore::Document::adjustFloatQuadsForScrollAndAbsoluteZoomAndFrameScale):
725         (WebCore::Document::adjustFloatRectForScrollAndAbsoluteZoomAndFrameScale):
726         * dom/MouseRelatedEvent.cpp:
727         (WebCore::MouseRelatedEvent::MouseRelatedEvent):
728         * editing/Editor.cpp:
729         (WebCore::Editor::countMatchesForText):
730         * editing/FrameSelection.cpp:
731         (WebCore::FrameSelection::bounds):
732         (WebCore::FrameSelection::getClippedVisibleTextRectangles):
733         * html/HTMLBodyElement.cpp:
734         (WebCore::HTMLBodyElement::scrollLeft):
735         (WebCore::HTMLBodyElement::scrollTop):
736         * html/ImageDocument.cpp:
737         (WebCore::ImageDocument::imageFitsInWindow):
738         (WebCore::ImageDocument::windowSizeChanged):
739         * inspector/InspectorOverlay.cpp:
740         (WebCore::InspectorOverlay::update):
741         * page/DOMWindow.cpp:
742         (WebCore::DOMWindow::innerHeight):
743         (WebCore::DOMWindow::innerWidth):
744         (WebCore::DOMWindow::scrollX):
745         (WebCore::DOMWindow::scrollY):
746         (WebCore::DOMWindow::scrollBy):
747         * page/FrameView.cpp:
748         (WebCore::FrameView::calculateScrollbarModesForLayout):
749         (WebCore::FrameView::layout):
750         (WebCore::FrameView::scrollContentsSlowPath):
751         (WebCore::FrameView::repaintContentRectangle):
752         (WebCore::FrameView::sendResizeEventIfNeeded):
753         (WebCore::FrameView::windowClipRect):
754         (WebCore::FrameView::isScrollable):
755         (WebCore::FrameView::paintControlTints):
756         * page/SpatialNavigation.cpp:
757         (WebCore::canScrollInDirection):
758         * platform/ScrollView.cpp:
759         (WebCore::ScrollView::unscaledVisibleContentSize):
760         (WebCore::ScrollView::visibleContentRectInternal):
761         (WebCore::ScrollView::updateScrollbars):
762         (WebCore::ScrollView::paint):
763         * platform/ScrollView.h:
764         (WebCore::ScrollView::scrollOffset):
765         (WebCore::ScrollView::actualScrollX):
766         (WebCore::ScrollView::actualScrollY):
767         (WebCore::ScrollView::actualScrollPosition):
768         * platform/ScrollableArea.cpp:
769         (WebCore::ScrollableArea::visibleContentRect):
770         (WebCore::ScrollableArea::visibleContentRectIncludingScrollbars):
771         (WebCore::ScrollableArea::visibleContentRectInternal):
772         * platform/ScrollableArea.h:
773         (WebCore::ScrollableArea::visibleWidth):
774         (WebCore::ScrollableArea::visibleHeight):
775         * platform/graphics/IntSize.h:
776         (WebCore::IntSize::expandedTo): Drive-by cleanup.
777         (WebCore::IntSize::shrunkTo):
778         * platform/gtk/ScrollViewGtk.cpp:
779         (WebCore::ScrollView::visibleContentRect):
780         * rendering/RenderLayer.cpp:
781         (WebCore::RenderLayer::scrollRectToVisible):
782         (WebCore::RenderLayer::maximumScrollPosition):
783         (WebCore::RenderLayer::visibleContentRectInternal):
784         (WebCore::RenderLayer::hitTest):
785         * rendering/RenderLayer.h:
786         * rendering/RenderLayerBacking.cpp:
787         (WebCore::RenderLayerBacking::updateCompositedBounds):
788         * rendering/RenderListBox.cpp:
789         * rendering/RenderListBox.h:
790         * rendering/RenderView.cpp:
791         (WebCore::RenderView::viewRect):
792         (WebCore::RenderView::viewportSize):
793
794 2014-01-20  Myles C. Maxfield  <mmaxfield@apple.com>
795
796        Turn text-decoration-skip: ink on for all underlines
797        https://bugs.webkit.org/show_bug.cgi?id=127331
798
799        Reviewed by Antti Koivisto.
800
801        No new tests are necessary because tests already exist
802
803        * rendering/style/RenderStyle.h:
804
805 2014-01-23  Hans Muller  <hmuller@adobe.com>
806
807         [CSS Shapes] Image valued shape size and position should conform to the spec
808         https://bugs.webkit.org/show_bug.cgi?id=123295
809
810         Reviewed by Andreas Kling.
811
812         Implement image valued shape-outside scaling and translation per the spec,
813         http://dev.w3.org/csswg/css-shapes/#shapes-from-image:
814
815         "The image is sized and positioned as if it were a replaced element whose
816         specified width and height are the same as the element’s used content box size."
817
818         This change doesn't completely fulfill the spec, it's limited to image elements
819         and shape-outside.
820
821         Tests: fast/shapes/shape-outside-floats/shape-outside-image-fit-001.html
822                fast/shapes/shape-outside-floats/shape-outside-image-fit-002.html
823                fast/shapes/shape-outside-floats/shape-outside-image-fit-003.html
824                fast/shapes/shape-outside-floats/shape-outside-image-fit-004.html
825
826         * rendering/shapes/Shape.h:
827         * rendering/shapes/Shape.cpp:
828         (WebCore::Shape::createRasterShape):
829         Added an imageRect parameter which specifies where the shape image is to
830         appear relative to the content box. The imageRect implies both scaling and
831         translation of the shape image.
832
833         * rendering/shapes/ShapeInfo.cpp:
834         (WebCore::ShapeInfo<RenderType>::computedShape):
835         (WebCore::getShapeImageRect):
836         For replaced elements, compute the shape's imageRect with
837         RenderReplaced::replacedContentRect().
838
839
840 2014-01-23  Max Vujovic  <mvujovic@adobe.com>
841
842         Remove CSS Custom Filters code and tests
843         https://bugs.webkit.org/show_bug.cgi?id=127382
844
845         Reviewed by Simon Fraser.
846
847         No new tests. Removing functionality.
848
849         * CMakeLists.txt:
850         * Configurations/FeatureDefines.xcconfig:
851         * DerivedSources.cpp:
852         * DerivedSources.make:
853         * GNUmakefile.list.am:
854         * WebCore.order:
855         * WebCore.vcxproj/WebCore.vcxproj:
856         * WebCore.vcxproj/WebCore.vcxproj.filters:
857         * WebCore.xcodeproj/project.pbxproj:
858         * bindings/js/JSCSSRuleCustom.cpp:
859         (WebCore::toJS):
860         * bindings/js/JSCSSValueCustom.cpp:
861         (WebCore::toJS):
862         * bindings/objc/DOMCSS.mm:
863         (kitClass):
864         * css/CSSComputedStyleDeclaration.cpp:
865         (WebCore::ComputedStyleExtractor::valueForFilter):
866         (WebCore::ComputedStyleExtractor::propertyValue):
867         * css/CSSComputedStyleDeclaration.h:
868         * css/CSSGrammar.y.in:
869         * css/CSSParser.cpp:
870         (WebCore::CSSParserContext::CSSParserContext):
871         (WebCore::operator==):
872         (WebCore::CSSParser::CSSParser):
873         (WebCore::CSSParser::parseValue):
874         (WebCore::filterInfoForName):
875         (WebCore::CSSParser::parseFilter):
876         (WebCore::CSSParser::detectAtToken):
877         * css/CSSParser.h:
878         * css/CSSParserMode.h:
879         * css/CSSPropertyNames.in:
880         * css/CSSPropertySourceData.h:
881         * css/CSSRule.h:
882         * css/CSSRule.idl:
883         * css/CSSValue.cpp:
884         (WebCore::CSSValue::equals):
885         (WebCore::CSSValue::cssText):
886         (WebCore::CSSValue::destroy):
887         (WebCore::CSSValue::cloneForCSSOM):
888         * css/CSSValue.h:
889         * css/CSSValueKeywords.in:
890         * css/StyleResolver.cpp:
891         (WebCore::StyleResolver::State::clear):
892         (WebCore::StyleResolver::applyProperty):
893         (WebCore::filterOperationForType):
894         (WebCore::StyleResolver::createFilterOperations):
895         (WebCore::StyleResolver::loadPendingResources):
896         * css/StyleResolver.h:
897         (WebCore::StyleResolver::State::State):
898         * css/StyleRule.cpp:
899         (WebCore::StyleRuleBase::destroy):
900         (WebCore::StyleRuleBase::copy):
901         (WebCore::StyleRuleBase::createCSSOMWrapper):
902         * css/StyleRule.h:
903         * css/StyleSheetContents.cpp:
904         (WebCore::childRulesHaveFailedOrCanceledSubresources):
905         * css/WebKitCSSArrayFunctionValue.cpp: Removed.
906         * css/WebKitCSSArrayFunctionValue.h: Removed.
907         * css/WebKitCSSFilterRule.cpp: Removed.
908         * css/WebKitCSSFilterRule.h: Removed.
909         * css/WebKitCSSFilterRule.idl: Removed.
910         * css/WebKitCSSFilterValue.cpp:
911         (WebCore::WebKitCSSFilterValue::WebKitCSSFilterValue):
912         (WebCore::WebKitCSSFilterValue::customCSSText):
913         * css/WebKitCSSFilterValue.h:
914         * css/WebKitCSSFilterValue.idl:
915         * css/WebKitCSSMatFunctionValue.cpp: Removed.
916         * css/WebKitCSSMatFunctionValue.h: Removed.
917         * css/WebKitCSSMixFunctionValue.cpp: Removed.
918         * css/WebKitCSSMixFunctionValue.h: Removed.
919         * css/WebKitCSSMixFunctionValue.idl: Removed.
920         * css/WebKitCSSShaderValue.cpp: Removed.
921         * css/WebKitCSSShaderValue.h: Removed.
922         * loader/cache/CachedResource.cpp:
923         (WebCore::defaultPriorityForResourceType):
924         * loader/cache/CachedResource.h:
925         * loader/cache/CachedResourceLoader.cpp:
926         (WebCore::createResource):
927         (WebCore::CachedResourceLoader::checkInsecureContent):
928         (WebCore::CachedResourceLoader::canRequest):
929         * loader/cache/CachedResourceLoader.h:
930         * loader/cache/CachedShader.cpp: Removed.
931         * loader/cache/CachedShader.h: Removed.
932         * page/Settings.cpp:
933         (WebCore::Settings::Settings):
934         * page/Settings.h:
935         * page/animation/CSSPropertyAnimation.cpp:
936         (WebCore::blendFilter):
937         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
938         (PlatformCALayerMac::filtersCanBeComposited):
939         * platform/graphics/filters/CustomFilterArrayParameter.h: Removed.
940         * platform/graphics/filters/CustomFilterColorParameter.h: Removed.
941         * platform/graphics/filters/CustomFilterCompiledProgram.cpp: Removed.
942         * platform/graphics/filters/CustomFilterCompiledProgram.h: Removed.
943         * platform/graphics/filters/CustomFilterConstants.h: Removed.
944         * platform/graphics/filters/CustomFilterGlobalContext.cpp: Removed.
945         * platform/graphics/filters/CustomFilterGlobalContext.h: Removed.
946         * platform/graphics/filters/CustomFilterMesh.cpp: Removed.
947         * platform/graphics/filters/CustomFilterMesh.h: Removed.
948         * platform/graphics/filters/CustomFilterMeshGenerator.cpp: Removed.
949         * platform/graphics/filters/CustomFilterMeshGenerator.h: Removed.
950         * platform/graphics/filters/CustomFilterNumberParameter.h: Removed.
951         * platform/graphics/filters/CustomFilterOperation.cpp: Removed.
952         * platform/graphics/filters/CustomFilterOperation.h: Removed.
953         * platform/graphics/filters/CustomFilterParameter.h: Removed.
954         * platform/graphics/filters/CustomFilterParameterList.cpp: Removed.
955         * platform/graphics/filters/CustomFilterParameterList.h: Removed.
956         * platform/graphics/filters/CustomFilterProgram.cpp: Removed.
957         * platform/graphics/filters/CustomFilterProgram.h: Removed.
958         * platform/graphics/filters/CustomFilterProgramClient.h: Removed.
959         * platform/graphics/filters/CustomFilterProgramInfo.cpp: Removed.
960         * platform/graphics/filters/CustomFilterProgramInfo.h: Removed.
961         * platform/graphics/filters/CustomFilterRenderer.cpp: Removed.
962         * platform/graphics/filters/CustomFilterRenderer.h: Removed.
963         * platform/graphics/filters/CustomFilterTransformParameter.h: Removed.
964         * platform/graphics/filters/CustomFilterValidatedProgram.cpp: Removed.
965         * platform/graphics/filters/CustomFilterValidatedProgram.h: Removed.
966         * platform/graphics/filters/FECustomFilter.cpp: Removed.
967         * platform/graphics/filters/FECustomFilter.h: Removed.
968         * platform/graphics/filters/FilterOperation.h:
969         * platform/graphics/filters/FilterOperations.cpp:
970         (WebCore::FilterOperations::outsets):
971         * platform/graphics/filters/FilterOperations.h:
972         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp: Removed.
973         * platform/graphics/filters/ValidatedCustomFilterOperation.h: Removed.
974         * platform/graphics/filters/texmap/CustomFilterValidatedProgramTextureMapper.cpp: Removed.
975         * platform/graphics/filters/texmap/TextureMapperPlatformCompiledProgram.h: Removed.
976         * platform/graphics/gpu/Texture.cpp:
977         * platform/graphics/texmap/TextureMapper.h:
978         * platform/graphics/texmap/TextureMapperGL.cpp:
979         (WebCore::getPassesRequiredForFilter):
980         (WebCore::BitmapTextureGL::applyFilters):
981         * platform/graphics/texmap/TextureMapperGL.h:
982         * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
983         (WebCore::CompositingCoordinator::clearPendingStateChanges):
984         (WebCore::CompositingCoordinator::syncLayerState):
985         * platform/graphics/texmap/coordinated/CompositingCoordinator.h:
986         * platform/graphics/texmap/coordinated/CoordinatedCustomFilterOperation.h: Removed.
987         * platform/graphics/texmap/coordinated/CoordinatedCustomFilterProgram.h: Removed.
988         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
989         (WebCore::CoordinatedGraphicsScene::setLayerFiltersIfNeeded):
990         (WebCore::CoordinatedGraphicsScene::commitSceneState):
991         (WebCore::CoordinatedGraphicsScene::setLayerAnimationsIfNeeded):
992         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
993         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
994         * rendering/FilterEffectRenderer.cpp:
995         (WebCore::FilterEffectRenderer::FilterEffectRenderer):
996         (WebCore::FilterEffectRenderer::build):
997         (WebCore::FilterEffectRenderer::computeSourceImageRectForDirtyRect):
998         * rendering/FilterEffectRenderer.h:
999         * rendering/RenderLayer.cpp:
1000         (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
1001         (WebCore::RenderLayer::calculateClipRects):
1002         * rendering/RenderLayer.h:
1003         * rendering/RenderLayerBacking.cpp:
1004         (WebCore::RenderLayerBacking::updateFilters):
1005         * rendering/RenderLayerFilterInfo.cpp:
1006         (WebCore::RenderLayer::FilterInfo::~FilterInfo):
1007         * rendering/RenderLayerFilterInfo.h:
1008         * rendering/RenderView.cpp:
1009         * rendering/RenderView.h:
1010         * rendering/style/StyleCachedShader.cpp: Removed.
1011         * rendering/style/StyleCachedShader.h: Removed.
1012         * rendering/style/StyleCustomFilterProgram.cpp: Removed.
1013         * rendering/style/StyleCustomFilterProgram.h: Removed.
1014         * rendering/style/StyleCustomFilterProgramCache.cpp: Removed.
1015         * rendering/style/StyleCustomFilterProgramCache.h: Removed.
1016         * rendering/style/StylePendingShader.h: Removed.
1017         * rendering/style/StyleShader.h: Removed.
1018
1019 2014-01-22  Jon Honeycutt  <jhoneycutt@apple.com>
1020
1021         REGRESSION(r161967): Crash in WebCore::CachedSVGDocumentReference::load
1022         <https://webkit.org/b/127151>
1023         <rdar://problem/15840760>
1024
1025         There were two issues introduced here; the first is a use-after-free of
1026         CachedSVGDocumentReference objects.
1027
1028         The previous code kept a map from FilterOperation ->
1029         RefPtr<WebKitCSSSVGDocumentValue>, which retained the
1030         CachedSVGDocument. In r161967, this was changed to use a weak HashSet,
1031         which allows stale CachedSVGDocumentReferences in the pending document
1032         set if the owning FilterOperation is deleted. To fix this, we'll keep a
1033         vector of RefPtr<FilterOperation> with pending SVG documents.
1034
1035         The second issue is a null deref in CachedSVGDocumentReference::load();
1036         CachedResourceLoader::requestSVGDocument() can return 0 if (for
1037         example) an invalid URL is passed. r161967 removed a null check as part
1038         of the refactoring.
1039
1040         Reviewed by Dirk Schulze.
1041
1042         Tests: css3/filters/crash-filter-animation-invalid-url.html
1043                css3/filters/crash-invalid-url.html
1044
1045         * css/StyleResolver.cpp:
1046         (WebCore::StyleResolver::State::clear):
1047         Use new member var name.
1048         (WebCore::StyleResolver::loadPendingSVGDocuments):
1049         For each FilterOperation with a pending SVG document, get or create a
1050         CachedSVGDocumentReference, and tell it to load. Changed to use new
1051         function names.
1052         (WebCore::StyleResolver::createFilterOperations):
1053         Append the FilterOperation to the list of FilterOperations with
1054         unloaded SVG documents.
1055
1056         * css/StyleResolver.h:
1057         Changed from using PendingSVGDocumentSet, a weak set, to
1058         a Vector<RefPtr<ReferenceFilterOperation>>.
1059         (WebCore::StyleResolver::State::filtersWithPendingSVGDocuments):
1060         Return the vector.
1061
1062         * loader/cache/CachedSVGDocumentReference.cpp:
1063         (WebCore::CachedSVGDocumentReference::~CachedSVGDocumentReference):
1064         Null check m_document rather than checking m_loadRequested.
1065         m_loadRequested may be true when m_document is 0.
1066         (WebCore::CachedSVGDocumentReference::load):
1067         Null check the result of CachedResourceLoader::requestSVGDocument().
1068
1069         * platform/graphics/filters/FilterOperation.cpp:
1070         (WebCore::ReferenceFilterOperation::getOrCreateCachedSVGDocumentReference):
1071         Create, if necessary, and return the CachedSVGDocumentReference.
1072
1073         * platform/graphics/filters/FilterOperation.h:
1074         Replaced createCachedSVGDocumentReference() with
1075         getOrCreateCachedSVGDocumentReference(), which makes for slightly
1076         cleaner code.
1077
1078 2014-01-23  Antti Koivisto  <antti@apple.com>
1079
1080         Don't enable speculative tiles immediately after main load stops progressing
1081         https://bugs.webkit.org/show_bug.cgi?id=127507
1082
1083         Reviewed by Andreas Kling.
1084
1085         It is common for timers and events to trigger more loading after the initial main frame loading
1086         has completed. We should delay a bit before enabling speculative tiles and keep them disabled 
1087         if loading still continues.
1088
1089         * page/FrameView.cpp:
1090         (WebCore::FrameView::FrameView):
1091         (WebCore::FrameView::adjustTiledBackingCoverage):
1092         (WebCore::shouldEnableSpeculativeTilingDuringLoading):
1093         (WebCore::FrameView::enableSpeculativeTilingIfNeeded):
1094         
1095             When load progression stops wait 0.5s before enabling speculative tiles.
1096
1097         (WebCore::FrameView::speculativeTilingEnableTimerFired):
1098         
1099             Don't enable speculative tiles if the progression has started again. Instead restart the timer.
1100
1101         * page/FrameView.h:
1102         * rendering/RenderLayerBacking.cpp:
1103         (WebCore::RenderLayerBacking::RenderLayerBacking):
1104         (WebCore::computeTileCoverage):
1105         
1106             Move the FrameView level code to FrameView (so we don't need to add a timer to every RenderLayerBacking).
1107
1108         * rendering/RenderLayerBacking.h:
1109
1110 2014-01-23  Antti Koivisto  <antti@apple.com>
1111
1112         Loads started soon after main frame completion should be considered part of the main load
1113         https://bugs.webkit.org/show_bug.cgi?id=127504
1114
1115         Reviewed by Andreas Kling.
1116
1117         ProgressTracker currently decides that main load is complete when the main frame stops loading. 
1118         However it is common that timers and onload events trigger more loads immediately (for example 
1119         by inserting iframes) and loading continues visually. These should be considered as part of the
1120         main load for paint throttling and speculative tiling coverage purposes.
1121
1122         * loader/ProgressTracker.cpp:
1123         (WebCore::ProgressTracker::ProgressTracker):
1124         (WebCore::ProgressTracker::progressStarted):
1125         
1126             Track whether this is considered part of the main load or not with a boolean. 
1127             It is set for subframe loads too if they start loading soon (within 1s) after the main frame load completes.
1128
1129         (WebCore::ProgressTracker::finalProgressComplete):
1130         
1131             Get a timestamp.
1132
1133         (WebCore::ProgressTracker::isMainLoadProgressing):
1134
1135             New definition of "main load".
1136
1137         * loader/ProgressTracker.h:
1138
1139 2014-01-23  peavo@outlook.com  <peavo@outlook.com>
1140
1141         [WinCairo] Compile error.
1142         https://bugs.webkit.org/show_bug.cgi?id=127499
1143
1144         Reviewed by Brent Fulgham.
1145
1146         * platform/network/curl/ResourceError.h: Include <winsock2.h> before <curl/curl.h>.
1147
1148 2014-01-23  Brady Eidson  <beidson@apple.com>
1149
1150         IDB: Implement cross-thread and IPC plumbing for 'get' support
1151         https://bugs.webkit.org/show_bug.cgi?id=127501
1152
1153         Reviewed by Anders Carlsson.
1154
1155         Add isolatedCopy to the IDBGetResult object:
1156         * Modules/indexeddb/IDBGetResult.h:
1157         (WebCore::IDBGetResult::isolatedCopy):
1158
1159         Add a cross-thread and cross-IPC appropriate object for IDBKeyRanges:
1160         * Modules/indexeddb/IDBKeyRangeData.cpp: Copied from Source/WebCore/Modules/indexeddb/IDBGetResult.h.
1161         (WebCore::IDBKeyRangeData::isolatedCopy):
1162         * Modules/indexeddb/IDBKeyRangeData.h: Copied from Source/WebCore/Modules/indexeddb/IDBGetResult.h.
1163         (WebCore::IDBKeyRangeData::IDBKeyRangeData):
1164
1165         Add a few more cross-thread copiers:
1166         * platform/CrossThreadCopier.cpp:
1167         (WebCore::IDBGetResult>::copy):
1168         (WebCore::IDBKeyRangeData>::copy):
1169         * platform/CrossThreadCopier.h:
1170
1171         Project file gunk:
1172         * CMakeLists.txt:
1173         * GNUmakefile.list.am:
1174         * WebCore.exp.in:
1175         * WebCore.xcodeproj/project.pbxproj:
1176
1177 2014-01-23  Jer Noble  <jer.noble@apple.com>
1178
1179         [MSE][Mac] Adopt new AVStreamDataParser delegate API
1180         https://bugs.webkit.org/show_bug.cgi?id=127498
1181
1182         Reviewed by Eric Carlson.
1183
1184         Adopt a new delegate API which passes in whether or not the new AVAsset
1185         is discontinuous, implying the AVAsset is entirely new rather than
1186         just updated with new information.
1187
1188         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
1189         (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:withDiscontinuity:]):
1190
1191 2014-01-23  Tim Horton  <timothy_horton@apple.com>
1192
1193         PDFPlugin: Use PDFPlugin even if there's an external plugin installed, if it's blocked
1194         https://bugs.webkit.org/show_bug.cgi?id=127415
1195         <rdar://problem/12482452>
1196
1197         Reviewed by Sam Weinig.
1198
1199         * English.lproj/Localizable.strings:
1200         * WebCore.exp.in:
1201         * platform/LocalizedStrings.cpp:
1202         (WebCore::useBlockedPlugInContextMenuTitle):
1203         * platform/LocalizedStrings.h:
1204         Add a localizable string for the generic case, where the client
1205         didn't provide a more specific string for the context menu item.
1206
1207 2014-01-23  peavo@outlook.com  <peavo@outlook.com>
1208
1209         [Curl] There is no way to specify cache folder.
1210         https://bugs.webkit.org/show_bug.cgi?id=125028
1211
1212         Reviewed by Brent Fulgham.
1213
1214         Fixed logical test, disc cache should be disabled if creating cache folder fails.
1215
1216         * platform/network/curl/CurlCacheManager.cpp:
1217         (WebCore::CurlCacheManager::setCacheDirectory):
1218
1219 2014-01-23  Brady Eidson  <beidson@apple.com>
1220
1221         Unreviewed build fix.
1222
1223         * WebCore.xcodeproj/project.pbxproj: Export the new header so WebKit can see it
1224
1225 2014-01-22  Brent Fulgham  <bfulgham@apple.com>
1226
1227         [Win] Update project and solution files for 64-bit builds
1228         https://bugs.webkit.org/show_bug.cgi?id=127457
1229
1230         Reviewed by Eric Carlson.
1231
1232         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj: Update for VS2013
1233         * WebCore.vcxproj/WebCore.submit.sln: Add x64 targets
1234         * WebCore.vcxproj/WebCore.vcxproj: Update for VS2013. Also exclude 32-bit specific
1235         assembly when building 64-bit target.
1236         * WebCore.vcxproj/WebCore.vcxproj.filters: Update for VS2013
1237         * config.h: Handle 64-bit type definitions.
1238         * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
1239         (PlatformCAAnimation::setFromValue): Use CGFloat to support 64-bit builds
1240         (PlatformCAAnimation::setToValue): Ditto
1241         (PlatformCAAnimation::setValues): Ditto
1242         * platform/graphics/win/FontCustomPlatformData.cpp:
1243         (WebCore::FontCustomPlatformData::fontPlatformData): Add cast to
1244         support 32- and 64-bit targets.
1245         * platform/graphics/win/GraphicsContextCGWin.cpp:
1246         (WebCore::GraphicsContext::drawLineForDocumentMarker): Use CGFloat to
1247         support 64-bit builds.
1248         * platform/win/PasteboardWin.cpp:
1249         (WebCore::Pasteboard::writeURLToDataObject): Specialize std::min to
1250         work on 32- and 64-bit code.
1251         (WebCore::createGlobalImageFileDescriptor): Ditto
1252         * platform/win/StructuredExceptionHandlerSuppressor.cpp:
1253         (WebCore::StructuredExceptionHandlerSuppressor::StructuredExceptionHandlerSuppressor):
1254         Comment out 32-bit inline assembly.
1255         (WebCore::StructuredExceptionHandlerSuppressor::~StructuredExceptionHandlerSuppressor):
1256         Ditto
1257
1258 2014-01-23  Brady Eidson  <beidson@apple.com>
1259
1260         Make IDBGetResult work with IDBKeyData instead of IDBKey.
1261         https://bugs.webkit.org/show_bug.cgi?id=127493
1262
1263         Reviewed by Eric Carlson.
1264
1265         Also break it into its own header to work better with IPC messages.
1266
1267         * Modules/indexeddb/IDBGetResult.h: Added.
1268         (WebCore::IDBGetResult::IDBGetResult):
1269
1270         * Modules/indexeddb/IDBServerConnection.h:
1271
1272         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
1273         (WebCore::GetOperation::perform):
1274
1275         * WebCore.xcodeproj/project.pbxproj:
1276
1277 2014-01-23  Mátyás Mustoha  <mmatyas@inf.u-szeged.hu>
1278
1279         [curl] Add storage limit to cache manager
1280         https://bugs.webkit.org/show_bug.cgi?id=125779
1281
1282         Reviewed by Brent Fulgham.
1283
1284         Sets a local disc storage size limit for the cache manager
1285         used by the curl network backend.
1286
1287         * platform/network/curl/CurlCacheEntry.cpp:
1288         (WebCore::CurlCacheEntry::CurlCacheEntry):
1289         (WebCore::CurlCacheEntry::isCached):
1290         (WebCore::CurlCacheEntry::saveCachedData):
1291         (WebCore::CurlCacheEntry::readCachedData):
1292         (WebCore::CurlCacheEntry::didFail):
1293         (WebCore::CurlCacheEntry::didFinishLoading):
1294         (WebCore::CurlCacheEntry::loadFileToBuffer):
1295         (WebCore::CurlCacheEntry::parseResponseHeaders):
1296         (WebCore::CurlCacheEntry::entrySize):
1297         * platform/network/curl/CurlCacheEntry.h:
1298         (WebCore::CurlCacheEntry::requestHeaders):
1299         * platform/network/curl/CurlCacheManager.cpp:
1300         (WebCore::CurlCacheManager::CurlCacheManager):
1301         (WebCore::CurlCacheManager::setStorageSizeLimit):
1302         (WebCore::CurlCacheManager::loadIndex):
1303         (WebCore::CurlCacheManager::saveIndex):
1304         (WebCore::CurlCacheManager::makeRoomForNewEntry):
1305         (WebCore::CurlCacheManager::didReceiveResponse):
1306         (WebCore::CurlCacheManager::didReceiveData):
1307         (WebCore::CurlCacheManager::invalidateCacheEntry):
1308         (WebCore::CurlCacheManager::readCachedData):
1309         * platform/network/curl/CurlCacheManager.h:
1310         (WebCore::CurlCacheManager::cacheDirectory):
1311
1312 2014-01-23  Carlos Garcia Campos  <cgarcia@igalia.com>
1313
1314         Unreviewed. Fix automake warning.
1315
1316         * GNUmakefile.list.am: Remove trailing whitespaces.
1317
1318 2014-01-23  Mihai Maerean  <mmaerean@adobe.com>
1319
1320         [CSS Regions] Fix positioning composited layers when the region has overflow:hidden
1321         https://bugs.webkit.org/show_bug.cgi?id=124042
1322
1323         Reviewed by Mihnea Ovidenie.
1324
1325         If there's a clipping GraphicsLayer on the hierarchy, substract its offset, since it's its
1326         parent that positions us.
1327
1328         Tests: compositing/regions/position-layer-inside-region-overflow-hidden.html
1329                compositing/regions/position-layer-inside-overflow-hidden.html
1330                compositing/regions/position-layers-inside-region-overflow-hidden.html
1331                compositing/regions/position-layers-inside-regions-overflow-hidden.html
1332
1333         * rendering/RenderLayerBacking.cpp:
1334         (WebCore::RenderLayerBacking::adjustAncestorCompositingBoundsForFlowThread): The position
1335         must also be correct when the region has box-shadow that inflates the region's layer. The
1336         composited layers from the flow thread should be rendered in the same position whether the
1337         associated region has clipping or not.
1338         Using the position of the clipping layer instead of the location of the clipbox makes it
1339         also work with box-shadow that inflates the region's graphics layer.
1340
1341 2014-01-23  Andrei Bucur  <abucur@adobe.com>
1342
1343         [CSS Regions] Convert regions iterator loops to range-based loops
1344         https://bugs.webkit.org/show_bug.cgi?id=127464
1345
1346         Reviewed by Antti Koivisto.
1347
1348         Replace most of the iterator loops in the region implementation with
1349         range based for loops. The for loops that iterate only over subsets
1350         of collections have not been changed.
1351
1352         Tests: no new tests, this is a refactoring patch.
1353
1354         * dom/WebKitNamedFlow.cpp:
1355         (WebCore::WebKitNamedFlow::firstEmptyRegionIndex):
1356         (WebCore::WebKitNamedFlow::getRegionsByContent):
1357         (WebCore::WebKitNamedFlow::getRegions):
1358         (WebCore::WebKitNamedFlow::getContent):
1359         * inspector/InspectorOverlay.cpp:
1360         (WebCore::buildObjectForCSSRegionsHighlight):
1361         * rendering/RenderFlowThread.cpp:
1362         (WebCore::RenderFlowThread::validateRegions):
1363         (WebCore::RenderFlowThread::updateLogicalWidth):
1364         (WebCore::RenderFlowThread::computeLogicalHeight):
1365         (WebCore::RenderFlowThread::repaintRectangleInRegions):
1366         (WebCore::RenderFlowThread::removeRenderBoxRegionInfo):
1367         (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
1368         (WebCore::RenderFlowThread::clearRenderBoxRegionInfoAndCustomStyle):
1369         (WebCore::RenderFlowThread::isAutoLogicalHeightRegionsCountConsistent):
1370         (WebCore::RenderFlowThread::markAutoLogicalHeightRegionsForLayout):
1371         (WebCore::RenderFlowThread::markRegionsForOverflowLayoutIfNeeded):
1372         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
1373         (WebCore::RenderFlowThread::collectLayerFragments):
1374         (WebCore::RenderFlowThread::fragmentsBoundingBox):
1375         * rendering/RenderNamedFlowFragment.cpp:
1376         (WebCore::RenderNamedFlowFragment::setRegionObjectsRegionStyle):
1377         (WebCore::RenderNamedFlowFragment::restoreRegionObjectsOriginalStyle):
1378         * rendering/RenderNamedFlowThread.cpp:
1379         (WebCore::RenderNamedFlowThread::clearContentElements):
1380         (WebCore::RenderNamedFlowThread::nextRendererForNode):
1381         (WebCore::RenderNamedFlowThread::dependsOn):
1382         (WebCore::RenderNamedFlowThread::computeOversetStateForRegions):
1383         (WebCore::RenderNamedFlowThread::checkInvalidRegions):
1384         (WebCore::RenderNamedFlowThread::pushDependencies):
1385         (WebCore::RenderNamedFlowThread::registerNamedFlowContentElement):
1386         (WebCore::isContainedInElements):
1387         (WebCore::RenderNamedFlowThread::getRanges):
1388         (WebCore::RenderNamedFlowThread::checkRegionsWithStyling):
1389         (WebCore::RenderNamedFlowThread::clearRenderObjectCustomStyle):
1390         * rendering/RenderTreeAsText.cpp:
1391         (WebCore::writeRenderRegionList):
1392
1393 2014-01-23  László Langó  <llango.u-szeged@partner.samsung.com>
1394
1395         Range should be constructable.
1396         https://bugs.webkit.org/show_bug.cgi?id=115639
1397
1398         Reviewed by Ryosuke Niwa.
1399
1400         http://www.w3.org/TR/2013/WD-dom-20131107/#interface-range
1401         Now we can do `new Range()` instead of `document.createRange()`.
1402
1403         Backported from Blink: https://chromium.googlesource.com/chromium/blink/+/47ca40efdf58a4787aa33aa75a35778899b1c002%5E%21
1404
1405         Test: fast/dom/Range/range-constructor.html
1406
1407         * dom/Range.cpp:
1408         (WebCore::Range::create):
1409         * dom/Range.h:
1410         * dom/Range.idl:
1411
1412 2014-01-23  ChangSeok Oh  <changseok.oh@collabora.com>
1413
1414         Unreviewed build fix for gles after r162565. Add missing definitions.
1415
1416         * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
1417         (WebCore::GraphicsContext3D::drawArraysInstanced):
1418         (WebCore::GraphicsContext3D::drawElementsInstanced):
1419         (WebCore::GraphicsContext3D::vertexAttribDivisor):
1420
1421 2014-01-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1422
1423         [GLIB] Use GUniquePtr instead of GOwnPtr
1424         https://bugs.webkit.org/show_bug.cgi?id=127431
1425
1426         Reviewed by Martin Robinson.
1427
1428         GUniquePtr is a template alias of std::unique_ptr with a custom
1429         deleter that replaces GOwnPtr. GOwnPtr is still used for the cases
1430         where the output pointer is needed, but it will also be replaced soon.
1431
1432         * GNUmakefile.list.am:
1433         * PlatformGTK.cmake:
1434         * accessibility/atk/AXObjectCacheAtk.cpp:
1435         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
1436         (getAttributeSetForAccessibilityObject):
1437         (accessibilityObjectLength):
1438         (textExtents):
1439         (webkitAccessibleTextGetChar):
1440         (numberOfReplacedElementsBeforeOffset):
1441         * page/ContextMenuController.cpp:
1442         * platform/SharedBuffer.h:
1443         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
1444         (webKitWebAudioSrcConstructed):
1445         (webKitWebAudioSrcLoop):
1446         * platform/audio/gtk/AudioBusGtk.cpp:
1447         (WebCore::AudioBus::loadPlatformResource):
1448         * platform/geoclue/GeolocationProviderGeoclue.cpp:
1449         * platform/graphics/gstreamer/ImageGStreamerCairo.cpp:
1450         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1451         (WebCore::MediaPlayerPrivateGStreamer::setAudioStreamProperties):
1452         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
1453         * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
1454         (webKitMediaSrcAddSrc):
1455         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
1456         (webKitWebSrcStart):
1457         (ResourceHandleStreamingClient::wasBlocked):
1458         (ResourceHandleStreamingClient::cannotShowURL):
1459         * platform/graphics/gtk/ImageBufferGtk.cpp:
1460         (WebCore::encodeImage):
1461         (WebCore::ImageBuffer::toDataURL):
1462         * platform/graphics/gtk/ImageGtk.cpp:
1463         (WebCore::getThemeIconFileName):
1464         (WebCore::Image::loadPlatformResource):
1465         * platform/gtk/ContextMenuGtk.cpp:
1466         (WebCore::ContextMenu::itemCount):
1467         (WebCore::contextMenuItemVector):
1468         * platform/gtk/ContextMenuItemGtk.cpp:
1469         (WebCore::createPlatformMenuItemDescription):
1470         * platform/gtk/DataObjectGtk.cpp:
1471         (WebCore::DataObjectGtk::setURIList):
1472         (WebCore::DataObjectGtk::setURL):
1473         * platform/gtk/FileSystemGtk.cpp:
1474         (WebCore::filenameToString):
1475         (WebCore::fileSystemRepresentation):
1476         (WebCore::filenameForDisplay):
1477         (WebCore::pathGetFileName):
1478         (WebCore::applicationDirectoryPath):
1479         (WebCore::sharedResourcesPath):
1480         (WebCore::directoryName):
1481         (WebCore::listDirectory):
1482         (WebCore::openTemporaryFile):
1483         * platform/gtk/GOwnPtrGtk.cpp: Removed.
1484         * platform/gtk/GOwnPtrGtk.h: Removed.
1485         * platform/gtk/GUniquePtrGtk.h: Added.
1486         * platform/gtk/GamepadsGtk.cpp:
1487         (WebCore::GamepadsGtk::GamepadsGtk):
1488         * platform/gtk/GtkClickCounter.cpp:
1489         (WebCore::GtkClickCounter::shouldProcessButtonEvent):
1490         * platform/gtk/GtkInputMethodFilter.cpp:
1491         (WebCore::GtkInputMethodFilter::sendCompositionAndPreeditWithFakeKeyEvents):
1492         * platform/gtk/GtkPopupMenu.cpp:
1493         (WebCore::GtkPopupMenu::popUp):
1494         (WebCore::GtkPopupMenu::typeAheadFind):
1495         * platform/gtk/LanguageGtk.cpp:
1496         (WebCore::platformLanguage):
1497         * platform/gtk/LocalizedStringsGtk.cpp:
1498         (WebCore::imageTitle):
1499         (WebCore::localizedMediaTimeDescription):
1500         * platform/gtk/PasteboardHelper.cpp:
1501         (WebCore::selectionDataToUTF8String):
1502         (WebCore::PasteboardHelper::getClipboardContents):
1503         (WebCore::PasteboardHelper::fillSelectionData):
1504         * platform/gtk/PopupMenuGtk.cpp:
1505         (WebCore::PopupMenuGtk::createGtkActionForMenuItem):
1506         (WebCore::PopupMenuGtk::show):
1507         * platform/gtk/WebKitAuthenticationWidget.cpp:
1508         (webkitAuthenticationWidgetInitialize):
1509         * platform/network/ResourceHandleInternal.h:
1510         * platform/network/gtk/CredentialBackingStore.cpp:
1511         (WebCore::credentialForChallengeAsyncReadyCallback):
1512         * platform/network/soup/CookieJarSoup.cpp:
1513         (WebCore::setCookiesFromDOM):
1514         (WebCore::cookiesForSession):
1515         (WebCore::getRawCookies):
1516         (WebCore::deleteCookie):
1517         (WebCore::getHostnamesWithCookies):
1518         (WebCore::deleteCookiesForHostname):
1519         (WebCore::deleteAllCookies):
1520         * platform/network/soup/DNSSoup.cpp:
1521         * platform/network/soup/GUniquePtrSoup.h: Added.
1522         * platform/network/soup/ResourceErrorSoup.cpp:
1523         (WebCore::failingURI):
1524         * platform/network/soup/ResourceHandleSoup.cpp:
1525         (WebCore::ResourceHandle::ensureReadBuffer):
1526         (WebCore::cleanupSoupRequestOperation):
1527         (WebCore::createSoupRequestAndMessageForHandle):
1528         * platform/network/soup/ResourceRequestSoup.cpp:
1529         (WebCore::ResourceRequest::updateSoupMessageMembers):
1530         (WebCore::ResourceRequest::updateSoupMessage):
1531         * platform/network/soup/ResourceResponseSoup.cpp:
1532         * platform/network/soup/SoupURIUtils.cpp:
1533         (WebCore::soupURIToKURL):
1534         * platform/soup/SharedBufferSoup.cpp:
1535         (WebCore::SharedBuffer::SharedBuffer):
1536         (WebCore::SharedBuffer::clearPlatformData):
1537         (WebCore::SharedBuffer::maybeTransferPlatformData):
1538         (WebCore::SharedBuffer::hasPlatformData):
1539         * plugins/gtk/PluginPackageGtk.cpp:
1540         (WebCore::PluginPackage::fetchInfo):
1541         (WebCore::PluginPackage::load):
1542
1543 2014-01-22  Simon Fraser  <simon.fraser@apple.com>
1544
1545         Surround fixedVisibleContentRect code with USE(TILED_BACKING_STORE)
1546         https://bugs.webkit.org/show_bug.cgi?id=127461
1547
1548         Reviewed by Andreas Kling.
1549
1550         The "fixedVisibleContentRect" code path is only used by platforms
1551         which enabled TILED_BACKING_STORE, so to reduce confusion, surround
1552         this code with #if USE(TILED_BACKING_STORE).
1553
1554         * page/Frame.cpp:
1555         (WebCore::Frame::createView):
1556         * page/FrameView.cpp:
1557         * page/FrameView.h:
1558         * platform/ScrollView.cpp:
1559         (WebCore::ScrollView::unscaledVisibleContentSize):
1560         (WebCore::ScrollView::visibleContentRect):
1561         * platform/ScrollView.h:
1562         (WebCore::ScrollView::visibleSize):
1563
1564 2014-01-22  Myles C. Maxfield  <mmaxfield@apple.com>
1565
1566         ASSERTION FAILED: v.isFixed() in WebCore::RenderStyle::setWordSpacing
1567         https://bugs.webkit.org/show_bug.cgi?id=126987
1568
1569         Reviewed by Simon Fraser.
1570
1571         When "inherit" is specified and there is no parent, Length values have an "Auto" type
1572
1573         Test: fast/css3-text/css3-word-spacing-percentage/word-spacing-crash.html
1574
1575         * rendering/style/RenderStyle.cpp:
1576         (WebCore::RenderStyle::setWordSpacing):
1577
1578 2014-01-22  Samuel White  <samuel_white@apple.com>
1579
1580         AX: Can't always increment web sliders.
1581         https://bugs.webkit.org/show_bug.cgi?id=127451
1582
1583         Reviewed by Chris Fleizach.
1584
1585         Clamping the decrement/increment amount to one when necessary (if a percent change would result in a change of less than one).
1586
1587         Test: accessibility/range-alter-by-percent.html
1588
1589         * accessibility/AccessibilityNodeObject.cpp:
1590         (WebCore::AccessibilityNodeObject::changeValueByPercent):
1591
1592 2014-01-22  Myles C. Maxfield  <mmaxfield@apple.com>
1593
1594         Remove CSS3_TEXT_DECORATION define
1595         https://bugs.webkit.org/show_bug.cgi?id=127333
1596
1597         Reviewed by Simon Fraser.
1598
1599         This is required for unprefixing the text-decoration-* CSS properties.
1600
1601         No new tests are necessary becase the flag was already on by default.
1602
1603         * Configurations/FeatureDefines.xcconfig:
1604         * css/CSSComputedStyleDeclaration.cpp:
1605         (WebCore::renderTextDecorationSkipFlagsToCSSValue):
1606         (WebCore::ComputedStyleExtractor::propertyValue):
1607         * css/CSSParser.cpp:
1608         (WebCore::isColorPropertyID):
1609         (WebCore::CSSParser::parseValue):
1610         (WebCore::CSSParser::addTextDecorationProperty):
1611         (WebCore::CSSParser::parseTextUnderlinePosition):
1612         * css/CSSParser.h:
1613         * css/CSSPrimitiveValueMappings.h:
1614         (WebCore::CSSPrimitiveValue::operator TextUnderlinePosition):
1615         * css/CSSPropertyNames.in:
1616         * css/CSSValueKeywords.in:
1617         * css/DeprecatedStyleBuilder.cpp:
1618         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
1619         * css/StylePropertyShorthand.cpp:
1620         (WebCore::webkitTextDecorationShorthand):
1621         (WebCore::shorthandForProperty):
1622         (WebCore::matchingShorthandsForLonghand):
1623         * css/StylePropertyShorthand.h:
1624         * css/StyleResolver.cpp:
1625         (WebCore::shouldApplyPropertyInParseOrder):
1626         (WebCore::isValidVisitedLinkProperty):
1627         (WebCore::StyleResolver::applyProperty):
1628         * platform/graphics/GraphicsContext.h:
1629         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1630         (WebCore::GraphicsContext::setPlatformStrokeStyle):
1631         * platform/graphics/cg/GraphicsContextCG.cpp:
1632         (WebCore::GraphicsContext::platformInit):
1633         * platform/graphics/wince/GraphicsContextWinCE.cpp:
1634         (WebCore::createPen):
1635         * rendering/InlineFlowBox.cpp:
1636         (WebCore::InlineFlowBox::computeMaxLogicalTop):
1637         * rendering/InlineFlowBox.h:
1638         * rendering/InlineTextBox.cpp:
1639         (WebCore::textDecorationStyleToStrokeStyle):
1640         (WebCore::boundingBoxForAllActiveDecorations):
1641         (WebCore::InlineTextBox::paintDecoration):
1642         * rendering/RenderObject.cpp:
1643         (WebCore::decorationColor):
1644         * rendering/RootInlineBox.cpp:
1645         (WebCore::RootInlineBox::maxLogicalTop):
1646         * rendering/RootInlineBox.h:
1647         * rendering/style/RenderStyle.cpp:
1648         (WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline):
1649         (WebCore::RenderStyle::colorIncludingFallback):
1650         (WebCore::RenderStyle::visitedDependentColor):
1651         * rendering/style/RenderStyle.h:
1652         * rendering/style/RenderStyleConstants.h:
1653         * rendering/style/StyleRareInheritedData.cpp:
1654         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
1655         (WebCore::StyleRareInheritedData::operator==):
1656         * rendering/style/StyleRareInheritedData.h:
1657         * rendering/style/StyleRareNonInheritedData.cpp:
1658         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1659         (WebCore::StyleRareNonInheritedData::operator==):
1660         * rendering/style/StyleRareNonInheritedData.h:
1661
1662 2014-01-22  Chris Fleizach  <cfleizach@apple.com>
1663
1664         AX: Do not return an accessible name for an object just because it has tabindex=0
1665         https://bugs.webkit.org/show_bug.cgi?id=126914
1666
1667         Reviewed by Mario Sanchez Prada.
1668
1669         WebKit has code to return an accessible name for any object that is "generically" focusable (ie. tabindex=0).
1670         This behavior, which is not supported in ARIA, has caused many problems for VoiceOver. Often VoiceOver will
1671         speak all the text underneath any type of group.
1672
1673         I think we need to revert this behavior and follow the ARIA spec more closely.
1674
1675         Test: accessibility/aria-describedby-ensures-visibility.html
1676
1677         * accessibility/AccessibilityNodeObject.cpp:
1678         (WebCore::AccessibilityNodeObject::visibleText):
1679         (WebCore::AccessibilityNodeObject::title):
1680
1681 2014-01-22  Brady Eidson  <beidson@apple.com>
1682
1683         The IDB backing store get() method shouldn't call IDB callbacks directly
1684         https://bugs.webkit.org/show_bug.cgi?id=127453
1685
1686         Reviewed by Beth Dakin.
1687
1688         * Modules/indexeddb/IDBServerConnection.h:
1689         (WebCore::IDBGetResult::IDBGetResult): Add a new structure to hold all of the
1690           possible results of a get() call.
1691
1692         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp:
1693         (WebCore::IDBServerConnectionLevelDB::get): Don't call IDBCallbacks directly.
1694           Instead, return the GetResult to the GetOperation which will make IDBCallbacks.
1695         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.h:
1696
1697         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
1698         (WebCore::GetOperation::perform): Get all of the IDBGetResults in the completion callback
1699           make the appropriate IDBCallback.
1700         * Modules/indexeddb/IDBTransactionBackendOperations.h:
1701
1702 2014-01-22  Dean Jackson  <dino@apple.com>
1703
1704         Unreviewed attempt to fix 32-bit builds.
1705
1706         Use long long rather than GC3Dintptr.
1707
1708         * html/canvas/ANGLEInstancedArrays.cpp:
1709         (WebCore::ANGLEInstancedArrays::drawElementsInstancedANGLE):
1710         * html/canvas/ANGLEInstancedArrays.h:
1711         * html/canvas/WebGLRenderingContext.cpp:
1712         (WebCore::WebGLRenderingContext::drawElementsInstanced):
1713         * html/canvas/WebGLRenderingContext.h:
1714
1715 2014-01-21  Brady Eidson  <beidson@apple.com>
1716
1717         IDB: "Put" support
1718         <rdar://problem/15779643> and https://bugs.webkit.org/show_bug.cgi?id=127401
1719
1720         Reviewed by Alexey Proskuryakov.
1721
1722         Add persistent encode/decode for storage to the database:
1723         * Modules/indexeddb/IDBKey.cpp:
1724         (WebCore::IDBKey::encode):
1725         (WebCore::IDBKey::decode):
1726         * Modules/indexeddb/IDBKey.h:
1727
1728         Add a data class to represent IDBKey suitable for crossing IPC:
1729         * Modules/indexeddb/IDBKeyData.cpp: Added.
1730         (WebCore::IDBKeyData::IDBKeyData):
1731         (WebCore::IDBKeyData::maybeCreateIDBKey):
1732         (WebCore::IDBKeyData::isolatedCopy):
1733         * Modules/indexeddb/IDBKeyData.h: Added.
1734         (WebCore::IDBKeyData::IDBKeyData):
1735
1736         * platform/CrossThreadCopier.cpp:
1737         (WebCore::IDBKeyData>::copy):
1738         * platform/CrossThreadCopier.h:
1739
1740         * WebCore.exp.in:
1741         * WebCore.xcodeproj/project.pbxproj:
1742
1743 2014-01-22  Dean Jackson  <dino@apple.com>
1744
1745         [WebGL] Implement ANGLE_instanced_arrays
1746         https://bugs.webkit.org/show_bug.cgi?id=127257
1747
1748         Reviewed by Brent Fulgham.
1749
1750         Implement the instanced drawing WebGL extension,
1751         ANGLE_instanced_arrays. This is currently Mac-only,
1752         but should be portable to other platforms if their
1753         OpenGL exposes the functions. It's also done in a way
1754         that will make exposing it to WebGL2 simple.
1755
1756         Test: fast/canvas/webgl/angle-instanced-arrays.html
1757
1758         * CMakeLists.txt:
1759         * DerivedSources.cpp:
1760         * DerivedSources.make:
1761         * GNUmakefile.list.am:
1762         * WebCore.vcxproj/WebCore.vcxproj:
1763         * WebCore.vcxproj/WebCore.vcxproj.filters:
1764         * WebCore.xcodeproj/project.pbxproj:
1765         Add the new files to all the build systems.
1766
1767         * bindings/js/JSWebGLRenderingContextCustom.cpp:
1768         (WebCore::toJS): Link JS side to C++ side.
1769
1770         * html/canvas/ANGLEInstancedArrays.cpp: Added.
1771         (WebCore::ANGLEInstancedArrays::ANGLEInstancedArrays):
1772         * html/canvas/ANGLEInstancedArrays.h: Added.
1773         * html/canvas/ANGLEInstancedArrays.idl: Added.
1774         New boilerplate files that expose the extension methods.
1775
1776         * html/canvas/WebGLExtension.h: New extension enum.
1777
1778         * html/canvas/WebGLRenderingContext.cpp:
1779         (WebCore::WebGLRenderingContext::validateVertexAttributes): Add an optional
1780         parameter representing the number of instance primitives we are asked
1781         to draw. Use that for the draw count if looking at an instanced attribute.
1782         Also make sure we see at least one non-instanced attribute.
1783         (WebCore::WebGLRenderingContext::validateDrawArrays): Update this so it could
1784         be used from either drawArrays or drawArraysInstanced.
1785         (WebCore::WebGLRenderingContext::drawArrays):
1786         (WebCore::WebGLRenderingContext::validateDrawElements): Same here, now can be
1787         used by the instanced and non-instanced versions.
1788         (WebCore::WebGLRenderingContext::drawElements):
1789         (WebCore::WebGLRenderingContext::getExtension): Create and return the new extension.
1790         (WebCore::WebGLRenderingContext::getSupportedExtensions): Add new extension to the list.
1791         (WebCore::WebGLRenderingContext::getVertexAttrib): Intercept a query to the divisor
1792         attribute and return the value we kept in the state.
1793         (WebCore::WebGLRenderingContext::drawArraysInstanced): Call the GC3D method.
1794         (WebCore::WebGLRenderingContext::drawElementsInstanced): Ditto.
1795         (WebCore::WebGLRenderingContext::vertexAttribDivisor): Ditto.
1796
1797         * html/canvas/WebGLRenderingContext.h: Define the new methods and parameters.
1798
1799         * html/canvas/WebGLVertexArrayObjectOES.cpp:
1800         (WebCore::WebGLVertexArrayObjectOES::setVertexAttribDivisor): Keep a record of the
1801         divisor if we set it.
1802         * html/canvas/WebGLVertexArrayObjectOES.h:
1803         (WebCore::WebGLVertexArrayObjectOES::VertexAttribState::VertexAttribState):
1804
1805         * platform/graphics/GraphicsContext3D.h: New enum.
1806         * platform/graphics/mac/GraphicsContext3DMac.mm:
1807         (WebCore::GraphicsContext3D::drawArraysInstanced): The actual calls into OpenGL.
1808         (WebCore::GraphicsContext3D::drawElementsInstanced): Ditto.
1809         (WebCore::GraphicsContext3D::vertexAttribDivisor): Ditto.
1810
1811         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp: Empty implementations
1812         for non-mac platforms.
1813
1814         * platform/graphics/ios/GraphicsContext3DIOS.h: Define the iOS names for the
1815         functions.
1816
1817 2014-01-22  Zalan Bujtas  <zalan@apple.com>
1818
1819         [CSS Shapes] shape-inside rectangle layout can fail
1820         https://bugs.webkit.org/show_bug.cgi?id=124784
1821
1822         Reviewed by Darin Adler.
1823
1824         Early subpixel rounding/flooring/ceiling can have unwanted
1825         side effect on the final pixel value. Delay pixel
1826         conversions as much as possible.
1827
1828         Existing test is changed to reflect subpixel functionality.
1829
1830         * rendering/shapes/RectangleShape.cpp:
1831         (WebCore::RectangleShape::firstIncludedIntervalLogicalTop):
1832
1833 2014-01-22  Jochen Eisinger  <jochen@chromium.org>
1834
1835         Add protocolIsInHTTPFamily for strings and use it where appropriate
1836         https://bugs.webkit.org/show_bug.cgi?id=127336
1837
1838         Reviewed by Alexey Proskuryakov.
1839
1840         * html/HTMLAnchorElement.cpp:
1841         (WebCore::HTMLAnchorElement::parseAttribute):
1842         * page/ContentSecurityPolicy.cpp:
1843         (WebCore::CSPSource::schemeMatches):
1844         * page/SecurityPolicy.cpp:
1845         (WebCore::SecurityPolicy::generateReferrerHeader):
1846         * platform/URL.cpp:
1847         (WebCore::protocolIsInHTTPFamily):
1848         * platform/URL.h:
1849
1850 2014-01-22  Zalan Bujtas  <zalan@apple.com>
1851
1852         Subpixel Layout: SimpleLineLayout needs more position rounding to match InlineFlowBox layout.
1853         https://bugs.webkit.org/show_bug.cgi?id=127404
1854
1855         Reviewed by Antti Koivisto.
1856
1857         In order to produce a CSS pixel perfect layout, SimpleLineLayout needs to
1858         round line positions to CSS (integral) position similarly to InlineFlowBox.
1859
1860         Existing tests cover it.
1861
1862         * rendering/SimpleLineLayoutResolver.h:
1863         (WebCore::SimpleLineLayout::RunResolver::Run::rect):
1864         (WebCore::SimpleLineLayout::RunResolver::Run::baseline):
1865
1866 2014-01-22  Joseph Pecoraro  <pecoraro@apple.com>
1867
1868         Unreviewed rollout of r162534, this caused inspector test failures.
1869
1870         * bindings/js/PageScriptDebugServer.cpp:
1871         (WebCore::PageScriptDebugServer::addListener):
1872         (WebCore::PageScriptDebugServer::removeListener):
1873         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
1874         (WebCore::PageScriptDebugServer::didRemoveLastListener):
1875         * bindings/js/PageScriptDebugServer.h:
1876         * bindings/js/ScriptDebugServer.cpp:
1877         (WebCore::ScriptDebugServer::ScriptDebugServer):
1878         (WebCore::ScriptDebugServer::recompileAllJSFunctionsSoon):
1879         (WebCore::ScriptDebugServer::recompileAllJSFunctionsTimerFired):
1880         * bindings/js/ScriptDebugServer.h:
1881         * bindings/js/WorkerScriptDebugServer.cpp:
1882         (WebCore::WorkerScriptDebugServer::addListener):
1883         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
1884         (WebCore::WorkerScriptDebugServer::removeListener):
1885         * inspector/InspectorProfilerAgent.cpp:
1886
1887 2014-01-22  peavo@outlook.com  <peavo@outlook.com>
1888
1889         Crashes in setTextForIterator
1890         https://bugs.webkit.org/show_bug.cgi?id=127424
1891
1892         Reviewed by Brent Fulgham.
1893
1894         * platform/text/icu/UTextProviderLatin1.cpp:
1895         (WebCore::uTextLatin1Clone): Provide correct buffer size in utext_setup function call.
1896         (WebCore::uTextLatin1Access): Give correct buffer size to memset call.
1897         (WebCore::openLatin1UTextProvider): Ditto.
1898
1899 2014-01-22  Jer Noble  <jer.noble@apple.com>
1900
1901         [Mac] MediaPlayerPrivateMediaSourceAVFObjC::load ASSERTs on lots of tests
1902         https://bugs.webkit.org/show_bug.cgi?id=127430
1903
1904         Reviewed by Eric Carlson.
1905
1906         When other registered media engines cannot load a URL, the engine selection
1907         will eventually pick MediaPlayerPrivateMediaSourceAVFObjC and ask it to load
1908         the URL. Instead of ASSERTing here, simply reject the URL by setting the
1909         network state to FormatError.
1910
1911         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1912         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::load):
1913
1914 2014-01-22  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1915
1916         [EFL][GTK] Get EFL and GTK compiling with ACCESSIBILITY disabled
1917         https://bugs.webkit.org/show_bug.cgi?id=127119
1918
1919         Reviewed by Mario Sanchez Prada.
1920
1921         At build time, the compiler was not able to determine which Timer's constructor to call in AXObjectCache when
1922         ACCESSIBILITY is not enabled, fixing that.
1923         Also guarding some members in AccessibilityObject that are only being used by EFL and GTK with ACCESSIBILITY.
1924
1925         * accessibility/AXObjectCache.h:
1926         (WebCore::AXObjectCache::AXObjectCache):
1927         * accessibility/AccessibilityObject.h:
1928
1929 2014-01-22  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
1930
1931         Refactor calculation of hasRx and hasRy values in SVGPathData
1932         https://bugs.webkit.org/show_bug.cgi?id=127423
1933
1934         Reviewed by Darin Adler.
1935
1936         This is a follow-up on https://bugs.webkit.org/show_bug.cgi?id=127337
1937
1938         * rendering/svg/SVGPathData.cpp:
1939         (WebCore::updatePathFromRectElement):
1940
1941 2014-01-21  Joseph Pecoraro  <pecoraro@apple.com>
1942
1943         Web Inspector: Remove recompileAllJSFunctions timer in ScriptDebugServer
1944         https://bugs.webkit.org/show_bug.cgi?id=127409
1945
1946         Reviewed by Timothy Hatcher.
1947
1948         * bindings/js/ScriptDebugServer.h:
1949         * bindings/js/ScriptDebugServer.cpp:
1950         (WebCore::ScriptDebugServer::ScriptDebugServer):
1951         Remove m_recompileTimer and the recompile soon function.
1952         We can just recompile immediately in all existing cases.
1953
1954         * bindings/js/PageScriptDebugServer.h:
1955         * bindings/js/PageScriptDebugServer.cpp:
1956         (WebCore::PageScriptDebugServer::addListener):
1957         (WebCore::PageScriptDebugServer::removeListener):
1958         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
1959         (WebCore::PageScriptDebugServer::didAddFirstListener):
1960         (WebCore::PageScriptDebugServer::didRemoveLastListener):
1961         Add a "didAddFirstListener" to match "didRemoveLastListener".
1962         Only recompile functions when we attach the debugger and when
1963         we detach the last listener.
1964
1965         * bindings/js/WorkerScriptDebugServer.cpp:
1966         (WebCore::WorkerScriptDebugServer::addListener):
1967         (WebCore::WorkerScriptDebugServer::removeListener):
1968         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
1969         Same thing. Also rearrange the functions to read better.
1970
1971         * inspector/InspectorProfilerAgent.cpp:
1972         Use the direct recompile function instead of the removed "soon" version.
1973
1974 2014-01-22  Robert Sipka  <sipka@inf.u-szeged.hu>
1975
1976         [curl] Improve detecting and handling of SSL client certificate
1977         https://bugs.webkit.org/show_bug.cgi?id=125006
1978
1979         Reviewed by Brent Fulgham.
1980
1981         Add client certificate handling.
1982
1983         * platform/network/ResourceHandle.h:
1984         * platform/network/curl/ResourceError.h:
1985         (WebCore::ResourceError::hasSSLConnectError):
1986         * platform/network/curl/ResourceHandleCurl.cpp:
1987         (WebCore::ResourceHandle::setClientCertificateInfo):
1988         * platform/network/curl/ResourceHandleManager.cpp:
1989         (WebCore::ResourceHandleManager::initializeHandle):
1990         * platform/network/curl/SSLHandle.cpp:
1991         (WebCore::addAllowedClientCertificate):
1992         (WebCore::setSSLClientCertificate):
1993         * platform/network/curl/SSLHandle.h:
1994
1995 2014-01-22  Mihai Maerean  <mmaerean@adobe.com>
1996
1997         [CSS Regions] layerOwner in RenderNamedFlowFragment cannot return null
1998         https://bugs.webkit.org/show_bug.cgi?id=127343
1999
2000         Reviewed by Sam Weinig.
2001
2002         RenderNamedFlowFragment::layerOwner cannot return null because regions create stacking
2003         contexts which create layers.
2004
2005         No new tests, no functional change.
2006
2007         * rendering/RenderFlowThread.cpp:
2008         (WebCore::RenderFlowThread::hasCompositingRegionDescendant):
2009         * rendering/RenderLayer.cpp:
2010         (WebCore::RenderLayer::calculateClipRects):
2011         * rendering/RenderLayerBacking.cpp:
2012         (WebCore::RenderLayerBacking::adjustAncestorCompositingBoundsForFlowThread):
2013         * rendering/RenderLayerCompositor.cpp:
2014         (WebCore::RenderLayerCompositor::computeRegionCompositingRequirements):
2015         * rendering/RenderNamedFlowFragment.h:
2016
2017 2014-01-22  Antti Koivisto  <antti@apple.com>
2018
2019         Avoid unthrottled layer flushes triggered by RenderLayerCompositor::ensureRootLayer
2020         https://bugs.webkit.org/show_bug.cgi?id=127426
2021
2022         Reviewed by Anders Carlsson.
2023         
2024         * rendering/RenderLayerCompositor.cpp:
2025         (WebCore::RenderLayerCompositor::updateScrollLayerPosition):
2026         (WebCore::RenderLayerCompositor::frameViewDidScroll):
2027
2028             Factor scroll layer position update to a function.
2029
2030         (WebCore::RenderLayerCompositor::ensureRootLayer):
2031         
2032             Stop calling frameViewDidChangeSize/frameViewDidScroll. Instead call the relevent functions
2033             directly. This avoid unthrottled layer flush that is done when the view actually scrolls.
2034
2035         * rendering/RenderLayerCompositor.h:
2036
2037 2014-01-22  Mihai Tica  <mitica@adobe.com>
2038
2039         [CSS Background Blending] -webkit-background-blend-mode fails for certain SVG files
2040         https://bugs.webkit.org/show_bug.cgi?id=127350
2041
2042         Reviewed by Dirk Schulze.
2043
2044         The graphics context of the SVG inherits the blend mode set
2045         on the background layer. Fix consists in drawing the SVG
2046         in a transparency layer.
2047
2048         Test: css3/compositing/background-blend-mode-svg.html
2049
2050         * svg/graphics/SVGImage.cpp:
2051         (WebCore::SVGImage::draw): Begin a transparency layer if a blend mode is set.
2052
2053 2014-01-22  Antti Koivisto  <antti@apple.com>
2054
2055         Update overlay scrollbars in single pass
2056         https://bugs.webkit.org/show_bug.cgi?id=127289
2057
2058         Reviewed by Anders Carlsson.
2059
2060         * platform/ScrollView.cpp:
2061         (WebCore::ScrollView::updateScrollbars):
2062         
2063             Multi-pass scrollbar resolution is only needed for traditional scrollbars. Overlay scrollbars don't affect layout.
2064
2065 2014-01-22  Mihnea Ovidenie  <mihnea@adobe.com>
2066
2067         [CSSRegions] Incorrect layout of a region pseudo children
2068         https://bugs.webkit.org/show_bug.cgi?id=126146
2069
2070         Reviewed by David Hyatt.
2071
2072         Test: fast/regions/collapse-anonymous-region.html
2073
2074         A region behaviour, styled using -webkit-flow-from, is modeled using an anonymous
2075         block created to fragment the named flow content inside the region. We have to prevent
2076         the behaviour of anonymous children collapsing for this block to make sure that the
2077         region element children are still laid out properly when the region element becomes an ordinary
2078         element.
2079
2080         * rendering/RenderBlockFlow.h:
2081
2082 2014-01-21  Ryuan Choi  <ryuan.choi@samsung.com>
2083
2084         Remove unused "acceleratedCompositingForScrollableFramesEnabled" setting
2085         https://bugs.webkit.org/show_bug.cgi?id=127402
2086
2087         Reviewed by Anders Carlsson.
2088
2089         compositing/iframes/iframe-composited-scrolling.html is updated because
2090         there are no usages in WebCore.
2091
2092         * page/Settings.in:
2093
2094 2014-01-21  Alex Christensen  <achristensen@webkit.org>
2095
2096         Compile fix for using libsoup on Windows.
2097         https://bugs.webkit.org/show_bug.cgi?id=127377
2098
2099         Reviewed by Daniel Bates.
2100
2101         * platform/network/soup/ProxyResolverSoup.cpp:
2102         (soupProxyResolverWkSetProperty):
2103         (soupProxyResolverWkGetProperty):
2104         (soupProxyResolverWkGetProxyURISync):
2105         Replaced uint with unsigned.
2106
2107 2014-01-21  Daniel Bates  <dabates@apple.com>
2108
2109         Break up single assertion into two assertions in HTMLMediaElement::returnPlatformLayer()
2110
2111         Following up after <http://trac.webkit.org/changeset/162473>, we should break up
2112         the assertion into two assertions as suggested by Darin Adler. Separating the single
2113         assertion into two assertions makes it straightforward to determine the conjunct that
2114         failed among other benefits.
2115
2116         * html/HTMLMediaElement.cpp:
2117         (WebCore::HTMLMediaElement::parseAttribute):
2118
2119 2014-01-21  Brady Eidson  <beidson@apple.com>
2120
2121         The IDB backing store put() method shouldn't call IDB callbacks directly
2122         https://bugs.webkit.org/show_bug.cgi?id=127399
2123
2124         Reviewed by Beth Dakin.
2125
2126         Refactor the put() callback to take a resulting key or an error.
2127         * Modules/indexeddb/IDBServerConnection.h:
2128
2129         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
2130         (WebCore::PutOperation::perform): Call to the backing store, then perform the
2131           appropriate IDB callback whether a key or an error was returned.
2132         * Modules/indexeddb/IDBTransactionBackendOperations.h:
2133
2134         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp:
2135         (WebCore::IDBServerConnectionLevelDB::put): Don’t call IDB callbacks directly.
2136           Instead, pass the resulting key/error back to the PutOperation.
2137         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.h:
2138
2139 2014-01-21  Jae Hyun Park  <jae.park@company100.net>
2140
2141         Use nullptr in HTMLCanvasElement
2142         https://bugs.webkit.org/show_bug.cgi?id=127388
2143
2144         Reviewed by Gyuyoung Kim.
2145
2146         * html/HTMLCanvasElement.cpp:
2147         (WebCore::HTMLCanvasElement::getContext):
2148         (WebCore::HTMLCanvasElement::drawingContext):
2149         (WebCore::HTMLCanvasElement::existingDrawingContext):
2150
2151 2014-01-21  László Langó  <llango.u-szeged@partner.samsung.com>
2152
2153         Assertion failure in Range::nodeWillBeRemoved
2154         https://bugs.webkit.org/show_bug.cgi?id=121694
2155
2156         Reviewed by Ryosuke Niwa.
2157
2158         Based on Blink a change: https://chromium.googlesource.com/chromium/blink/+/407c1d7b2c45974aa614b3f847ffe9e8fce205fa
2159
2160         This patch fix an assertion failure. Range::nodeWillBeRemoved() might
2161         be called with removed node in ContainerNode, when DOMNodeRemovedFromDocument
2162         event handler calls removeChild(), for node being removed.
2163
2164         Test: fast/dom/Range/remove-twice-crash.html
2165
2166         * dom/ContainerNode.cpp:
2167         (WebCore::ContainerNode::willRemoveChild):
2168         * dom/ContainerNode.h:
2169
2170 2014-01-21  Tim Horton  <timothy_horton@apple.com>
2171
2172         REGRESSION (r161580): Some PDFs render outside their <img>
2173         https://bugs.webkit.org/show_bug.cgi?id=127381
2174         <rdar://problem/15872168>
2175
2176         Reviewed by Simon Fraser.
2177
2178         * platform/graphics/cg/PDFDocumentImage.cpp:
2179         (WebCore::transformContextForPainting):
2180         Only try to make the scale uniform if it isn't already, and use the minimum
2181         of the two original scales when doing so, so that it is absolutely certain
2182         to fit inside space allocated for the image during layout.
2183
2184 2014-01-21  Simon Fraser  <simon.fraser@apple.com>
2185
2186         Remove #if PLATFORM(IOS) in various places around customFixedPositionLayoutRect() code
2187         https://bugs.webkit.org/show_bug.cgi?id=127373
2188
2189         Reviewed by Beth Dakin.
2190
2191         Instead of PLATFORM(IOS) #idefs at every call site for viewportConstrainedVisibleContentRect(),
2192         move the #ifdef inside viewportConstrainedVisibleContentRect().
2193         
2194         The one call site that needs special handling is RenderLayerBacking::updateCompositedBounds(),
2195         which needs to avoid clipping fixed layers to the custom fixed position rect, but instead to
2196         visibleContentRect() (which is really the document bounds on iOS). This ensures that the
2197         fixed layers aren't clipped when zooming out.
2198
2199         * page/FrameView.cpp:
2200         (WebCore::FrameView::viewportConstrainedVisibleContentRect):
2201         * rendering/RenderBoxModelObject.cpp:
2202         (WebCore::RenderBoxModelObject::stickyPositionOffset):
2203         * rendering/RenderLayerBacking.cpp:
2204         (WebCore::RenderLayerBacking::updateCompositedBounds):
2205         * rendering/RenderLayerCompositor.cpp:
2206         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
2207         (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
2208         (WebCore::RenderLayerCompositor::computeStickyViewportConstraints):
2209
2210 2014-01-21  Andy Estes  <aestes@apple.com>
2211
2212         [iOS] Allow all clients to link against WebCore
2213         https://bugs.webkit.org/show_bug.cgi?id=127372
2214         
2215         Reviewed by Dan Bernstein.
2216
2217         * Configurations/WebCore.xcconfig:
2218
2219 2014-01-21  Bear Travis  <betravis@adobe.com>
2220
2221         [CSS Shapes] Preserve box-shape order when serializing shape values
2222         https://bugs.webkit.org/show_bug.cgi?id=127200
2223
2224         Reviewed by Dirk Schulze.
2225
2226         Convert the parsed shape-box pair to a CSSValueList rather than directly
2227         adding the box value to BasicShape. The CSSValueList preserves the
2228         shape-box ordering, and cleans up a little bit of the code shared between
2229         clip and shape values.
2230
2231         Modifying existing parsing tests.
2232
2233         * css/CSSComputedStyleDeclaration.cpp:
2234         (WebCore::shapePropertyValue): Factor out code common to generating shape
2235         values.
2236         (WebCore::ComputedStyleExtractor::propertyValue): Generate a CSSValueList when
2237         you have both a shape and a box.
2238         * css/CSSParser.cpp:
2239         (WebCore::CSSParser::parseBasicShapeAndOrBox): Factor out code common to clip
2240         paths and shape properties that parses the [basic-shape || box] syntax from
2241         the CSS Shapes spec.
2242         (WebCore::CSSParser::parseShapeProperty): Parse shape-box pairs as a CSSValueList.
2243         * css/DeprecatedStyleBuilder.cpp:
2244         (WebCore::ApplyPropertyShape::applyValue): Use the CSSValueList for shape-box pairs.
2245         * css/CSSValueList.h:
2246         (WebCore::CSSValueList::itemWithoutBoundsCheck): Add a const version.
2247         * page/animation/CSSPropertyAnimation.cpp:
2248         (WebCore::blendFunc): Specify a box when blending.
2249         * rendering/style/ShapeValue.h:
2250         (WebCore::ShapeValue::createShapeValue): Add a box parameter.
2251         (WebCore::ShapeValue::ShapeValue): Ditto.
2252
2253 2014-01-21  Daniel Bates  <dabates@apple.com>
2254
2255         Fix the iOS Simulator release build
2256
2257         Substitute ASSERT_UNUSED() for ASSERT() to resolve a compiler warning
2258         that the argument platformLayer is unused. The argument platformLayer
2259         is only used in the asserted condition, which isn't compiled in a
2260         release build; => the argument is unused in a release build.
2261
2262         * html/HTMLMediaElement.cpp:
2263         (WebCore::HTMLMediaElement::parseAttribute):
2264
2265 2014-01-21  Zoltan Horvath  <zoltan@webkit.org>
2266
2267         Since MidpointState is a class, it should behave like a class
2268         https://bugs.webkit.org/show_bug.cgi?id=127154
2269
2270         Reviewed by David Hyatt.
2271
2272         I modified MidpointState to behave like a class, updated the call sites also.
2273
2274         No new tests, no behavior change.
2275
2276         * platform/text/BidiResolver.h:
2277         (WebCore::MidpointState::reset):
2278         (WebCore::MidpointState::startIgnoringSpaces):
2279         (WebCore::MidpointState::stopIgnoringSpaces):
2280         (WebCore::MidpointState::midpoints):
2281         (WebCore::MidpointState::numMidpoints):
2282         (WebCore::MidpointState::currentMidpoint):
2283         (WebCore::MidpointState::incrementCurrentMidpoint):
2284         (WebCore::MidpointState::decreaseNumMidpoints):
2285         (WebCore::MidpointState::betweenMidpoints):
2286         (WebCore::MidpointState::setBetweenMidpoints):
2287         (WebCore::MidpointState::addMidpoint): Renamed from deprecatedAddMidpoint, since now
2288         its private, we no longer need to discourage callers from using it.
2289         * rendering/InlineIterator.h:
2290         (WebCore::IsolateTracker::addFakeRunIfNecessary):
2291         * rendering/RenderBlockLineLayout.cpp:
2292         (WebCore::RenderBlockFlow::appendRunsForObject):
2293         (WebCore::constructBidiRunsForLine):
2294         * rendering/line/BreakingContextInlineHeaders.h:
2295         (WebCore::checkMidpoints):
2296         * rendering/line/TrailingObjects.cpp:
2297         (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes):
2298
2299 2014-01-21  Commit Queue  <commit-queue@webkit.org>
2300
2301         Unreviewed, rolling out r162452.
2302         http://trac.webkit.org/changeset/162452
2303         https://bugs.webkit.org/show_bug.cgi?id=127366
2304
2305         broke a few tests on all Mac WebKit1 bots (Requested by
2306         thorton on #webkit).
2307
2308         * WebCore.exp.in:
2309         * page/FocusController.cpp:
2310         (WebCore::FocusController::FocusController):
2311         (WebCore::FocusController::setFocused):
2312         (WebCore::FocusController::setActive):
2313         (WebCore::FocusController::setContentIsVisible):
2314         * page/FocusController.h:
2315         (WebCore::FocusController::isActive):
2316         (WebCore::FocusController::isFocused):
2317         * page/Page.cpp:
2318         (WebCore::Page::Page):
2319         (WebCore::Page::setIsInWindow):
2320         (WebCore::Page::setIsVisuallyIdle):
2321         (WebCore::Page::setIsVisible):
2322         (WebCore::Page::visibilityState):
2323         (WebCore::Page::hiddenPageCSSAnimationSuspensionStateChanged):
2324         * page/Page.h:
2325         (WebCore::Page::isVisible):
2326         (WebCore::Page::isInWindow):
2327
2328 2014-01-21  Chris Fleizach  <cfleizach@apple.com>
2329
2330         AX: Mac: Expose the visible text of a password field to AX
2331         https://bugs.webkit.org/show_bug.cgi?id=127353
2332
2333         Reviewed by Brent Fulgham.
2334
2335         The Mac platform should now expose the rendered value of password fields through AX.
2336
2337         Test: accessibility/password-field-value.html
2338
2339         * accessibility/AccessibilityRenderObject.cpp:
2340         (WebCore::AccessibilityRenderObject::textLength):
2341         (WebCore::AccessibilityRenderObject::passwordFieldValue):
2342
2343 2014-01-21  Robert Sipka  <sipka@inf.u-szeged.hu>
2344
2345         Support SSL error handling in case of synchronous job.
2346         https://bugs.webkit.org/show_bug.cgi?id=125301
2347
2348         Reviewed by Brent Fulgham.
2349
2350         Set ssl error informations for the users.
2351
2352         * platform/network/curl/ResourceHandleManager.cpp:
2353         (WebCore::ResourceHandleManager::dispatchSynchronousJob):
2354
2355 2014-01-21  Simon Fraser  <simon.fraser@apple.com>
2356
2357         Export systemTotalMemory() and systemMemoryLevel() for MobileSafari
2358         https://bugs.webkit.org/show_bug.cgi?id=127360
2359
2360         Reviewed by Andy Estes.
2361         
2362         MobileSafari inappropriately calls these WebCore functions directly,
2363         so export them.
2364
2365         * WebCore.exp.in:
2366
2367 2014-01-21  Simon Fraser  <simon.fraser@apple.com>
2368
2369         Clean up PLATFORM(IOS) code related to the custom fixed position layout rect
2370         https://bugs.webkit.org/show_bug.cgi?id=127362
2371
2372         Reviewed by Dave Hyatt.
2373
2374         Various platforms customize the rect used to layout position:fixed elements,
2375         and each modified RenderBox::availableLogicalHeight/WidthUsing() in different
2376         ways.
2377         
2378         Clean this up by adding RenderView::clientLogicalWidth/HeightForFixedPosition(),
2379         and moving the platform hacks into it.
2380
2381         * rendering/RenderBox.cpp:
2382         (WebCore::RenderBox::availableLogicalHeightUsing):
2383         (WebCore::RenderBox::containingBlockLogicalWidthForPositioned):
2384         (WebCore::RenderBox::containingBlockLogicalHeightForPositioned):
2385         * rendering/RenderView.cpp:
2386         (WebCore::RenderView::clientLogicalWidthForFixedPosition):
2387         (WebCore::RenderView::clientLogicalHeightForFixedPosition):
2388         * rendering/RenderView.h:
2389
2390 2014-01-21  Tamas Gergely  <tgergely.u-szeged@partner.samsung.com>
2391
2392         ASSERT(time.isFinite()) in SVGSMILElement::createInstanceTimesFromSyncbase
2393         <https://webkit.org/b/108184>
2394
2395         Reviewed by Philip Rogers.
2396
2397         In the case a SMILElement timing had a syncbase dependency on an indefinite value
2398         the assert were raised. The assert has been removed and a check has been added
2399         instead that prevents the addition of indefinite times to the time list.
2400
2401         Test: svg/animations/smil-syncbase-self-dependency.svg
2402
2403         * svg/animation/SVGSMILElement.cpp:
2404         (WebCore::SVGSMILElement::createInstanceTimesFromSyncbase):
2405           ASSERT removed.
2406
2407 2014-01-21  Tim Horton  <timothy_horton@apple.com>
2408
2409         Address late review naming comments after r162453.
2410
2411         * WebCore.xcodeproj/project.pbxproj:
2412         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2413         * platform/graphics/mac/CALayerWebAdditions.h: Removed.
2414         * platform/graphics/mac/CALayerWebAdditions.mm: Removed.
2415         * platform/graphics/mac/WebCoreCALayerExtras.h: Added.
2416         * platform/graphics/mac/WebCoreCALayerExtras.mm: Added.
2417         (-[CALayer web_disableAllActions]):
2418
2419 2014-01-21  Tim Horton  <timothy_horton@apple.com>
2420
2421         Keep CALayer implicit animation disabling code in a single place
2422         https://bugs.webkit.org/show_bug.cgi?id=127355
2423
2424         Reviewed by Simon Fraser.
2425
2426         * WebCore.xcodeproj/project.pbxproj:
2427         Add CALayerWebAdditions.{h,mm}.
2428
2429         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2430         (PlatformCALayerMac::commonInit):
2431         Remove nullActionsDictionary() and use [CALayer(WebAdditions) web_disableAllActions] instead.
2432
2433         * platform/graphics/mac/CALayerWebAdditions.h: Added.
2434         * platform/graphics/mac/CALayerWebAdditions.mm: Added.
2435         (-[CALayer web_disableAllActions]):
2436         Added. Disable all implicit actions on the layer.
2437
2438 2014-01-21  Gavin Barraclough  <barraclough@apple.com>
2439
2440         Change Page, FocusController to use ViewState
2441         https://bugs.webkit.org/show_bug.cgi?id=126533
2442
2443         Reviewed by Tim Horton.
2444
2445         These classes currently maintain a set of separate fields to represent the view state;
2446         combine these into a single field, and allow WebPage to send the combined update rather
2447         than individual changes.
2448
2449         Maintain existing interface for WebKit1 clients.
2450
2451         * WebCore.exp.in:
2452             - Added WebCore::setViewState, removed WebCore::setIsVisuallyIdle.
2453         * page/FocusController.cpp:
2454         (WebCore::FocusController::FocusController):
2455             - Initialize combined m_viewState.
2456         (WebCore::FocusController::setFocused):
2457             - Calls setViewState.
2458         (WebCore::FocusController::setFocusedInternal):
2459             - setFocused -> setFocusedInternal.
2460         (WebCore::FocusController::setViewState):
2461             - Added, update all ViewState flags.
2462         (WebCore::FocusController::setActive):
2463             - Calls setViewState.
2464         (WebCore::FocusController::setActiveInternal):
2465             - setActive -> setActiveInternal.
2466         (WebCore::FocusController::setContentIsVisible):
2467             - Calls setViewState.
2468         (WebCore::FocusController::setContentIsVisibleInternal):
2469             - setContentIsVisible -> setContentIsVisibleInternal.
2470         * page/FocusController.h:
2471         (WebCore::FocusController::isActive):
2472         (WebCore::FocusController::isFocused):
2473         (WebCore::FocusController::contentIsVisible):
2474             - Implemented in terms of ViewState.
2475         * page/Page.cpp:
2476         (WebCore::Page::Page):
2477             - Initialize using PageInitialViewState.
2478         (WebCore::Page::setIsInWindow):
2479             - Calls setViewState.
2480         (WebCore::Page::setIsInWindowInternal):
2481             - setIsInWindow -> setIsInWindowInternal.
2482         (WebCore::Page::setIsVisuallyIdleInternal):
2483             - setIsVisuallyIdle -> setIsVisuallyIdleInternal.
2484         (WebCore::Page::setViewState):
2485             - Added, update all ViewState flags, including FocusController.
2486         (WebCore::Page::setIsVisible):
2487             - Calls setViewState.
2488         (WebCore::Page::setIsVisibleInternal):
2489             - setIsVisible -> setIsVisibleInternal.
2490         (WebCore::Page::visibilityState):
2491             - m_isVisible -> isVisible()
2492         (WebCore::Page::hiddenPageCSSAnimationSuspensionStateChanged):
2493             - m_isVisible -> isVisible()
2494         * page/Page.h:
2495         (WebCore::Page::isVisible):
2496         (WebCore::Page::isInWindow):
2497             - Implemented in terms of ViewState.
2498         (WebCore::Page::scriptedAnimationsSuspended):
2499             - Combined member fields into ViewState::Flags.
2500
2501 2014-01-21  Lauro Neto  <lauro.neto@openbossa.org>
2502
2503         Remove PLATFORM(NIX) from WebCore
2504         https://bugs.webkit.org/show_bug.cgi?id=127299
2505
2506         Reviewed by Anders Carlsson.
2507
2508         * editing/Editor.cpp:
2509         (WebCore::Editor::cut):
2510         (WebCore::Editor::copy):
2511         (WebCore::Editor::copyImage):
2512         * editing/Editor.h:
2513         * html/HTMLCanvasElement.h:
2514         * loader/EmptyClients.h:
2515         * loader/FrameLoader.cpp:
2516         (WebCore::FrameLoader::defaultObjectContentType):
2517         * page/ChromeClient.h:
2518         * page/DragController.cpp:
2519         (WebCore::DragController::startDrag):
2520         * platform/Cursor.h:
2521         * platform/DragData.h:
2522         * platform/DragImage.h:
2523         * platform/FileSystem.h:
2524         * platform/LocalizedStrings.h:
2525         * platform/Widget.h:
2526         * platform/audio/FFTFrame.h:
2527         * platform/audio/HRTFElevation.cpp:
2528         * platform/cairo/WidgetBackingStore.h:
2529         * platform/graphics/ANGLEWebKitBridge.h:
2530         * platform/graphics/FontPlatformData.h:
2531         * platform/graphics/GLContext.cpp:
2532         (WebCore::GLContext::createContextForWindow):
2533         * platform/graphics/GLContext.h:
2534         * platform/graphics/GraphicsContext3D.h:
2535         * platform/graphics/GraphicsContext3DPrivate.cpp:
2536         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
2537         * platform/graphics/OpenGLESShims.h:
2538         * platform/graphics/OpenGLShims.cpp:
2539         (WebCore::getProcAddress):
2540         * platform/graphics/OpenGLShims.h:
2541         * platform/graphics/PlatformLayer.h:
2542         * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
2543         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
2544         (WebCore::Extensions3DOpenGL::createVertexArrayOES):
2545         (WebCore::Extensions3DOpenGL::deleteVertexArrayOES):
2546         (WebCore::Extensions3DOpenGL::isVertexArrayOES):
2547         (WebCore::Extensions3DOpenGL::bindVertexArrayOES):
2548         (WebCore::Extensions3DOpenGL::supportsExtension):
2549         * platform/graphics/opengl/Extensions3DOpenGL.h:
2550         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
2551         * platform/graphics/opengl/Extensions3DOpenGLES.h:
2552         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
2553         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
2554         (WebCore::GraphicsContext3D::reshape):
2555         * platform/graphics/opengl/TemporaryOpenGLSetting.cpp:
2556         * platform/graphics/texmap/TextureMapper.h:
2557         * platform/network/ResourceHandle.h:
2558         * plugins/PluginPackage.cpp:
2559         * plugins/PluginView.cpp:
2560         (WebCore::PluginView::PluginView):
2561         * plugins/PluginView.h:
2562         * plugins/PluginViewNone.cpp:
2563         * rendering/SimpleLineLayout.cpp:
2564         (WebCore::SimpleLineLayout::canUseFor):
2565
2566 2014-01-21  Eric Carlson  <eric.carlson@apple.com>
2567
2568         Add &lrm; &rlm; and &nbsp; to WebVTT parser
2569         https://bugs.webkit.org/show_bug.cgi?id=85112
2570
2571         Reviewed by Jer Noble.
2572
2573         No new tests, track-webvtt-tc022-entities.html was updated to test this.
2574
2575         * html/track/WebVTTTokenizer.cpp:
2576         (WebCore::WebVTTTokenizer::nextToken): Support RLM, LRM, and NBSP entities.
2577
2578 2014-01-21  Commit Queue  <commit-queue@webkit.org>
2579
2580         Unreviewed, rolling out r162354.
2581         http://trac.webkit.org/changeset/162354
2582         https://bugs.webkit.org/show_bug.cgi?id=127354
2583
2584         Appears to have broken accessibility in a non-trivial way
2585         (Requested by ap on #webkit).
2586
2587         * platform/ScrollView.cpp:
2588         (WebCore::ScrollView::updateScrollbars):
2589
2590 2014-01-21  Commit Queue  <commit-queue@webkit.org>
2591
2592         Unreviewed, rolling out r162445.
2593         http://trac.webkit.org/changeset/162445
2594         https://bugs.webkit.org/show_bug.cgi?id=127351
2595
2596         It broke the 32 bit GTK build (Requested by Ossy on #webkit).
2597
2598         * rendering/style/StyleRareInheritedData.cpp:
2599
2600 2014-01-21  László Langó  <llango.u-szeged@partner.samsung.com>
2601
2602         Wrong struct size when CSS_IMAGE_ORIENTATION and CSS3_TEXT_DECORATION are enabled.
2603         https://bugs.webkit.org/show_bug.cgi?id=127346
2604
2605         Efl build fix.
2606
2607         Reviewed by Csaba Osztrogonác.
2608
2609         * rendering/style/StyleRareInheritedData.cpp:
2610
2611 2014-01-21  Antti Koivisto  <antti@apple.com>
2612
2613         Delay initial layer flush during loading on all platforms
2614         https://bugs.webkit.org/show_bug.cgi?id=127347
2615
2616         Reviewed by Andreas Kling.
2617
2618         To reduce unnecessary repaints enable the same behaviour as iOS already has.
2619
2620         * rendering/RenderLayerCompositor.cpp:
2621         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
2622         
2623             Set the initial state of m_layerFlushThrottlingEnabled correctly.
2624
2625         (WebCore::RenderLayerCompositor::scheduleLayerFlush):
2626         (WebCore::RenderLayerCompositor::startInitialLayerFlushTimerIfNeeded):
2627         * rendering/RenderLayerCompositor.h:
2628         
2629             Enable initial layer flush delay on all platforms.
2630
2631 2014-01-21  Mihai Tica  <mitica@adobe.com>
2632
2633         If you set a tiled cross-faded-image or a tiled gradient as
2634         a background layer, -webkit-background-blend-mode doesn't work.
2635         The problem consists in the blendMode parameter not being set
2636         for these specific drawing paths.
2637
2638         https://bugs.webkit.org/show_bug.cgi?id=126888
2639         Reviewed by Dirk Schulze.
2640
2641         Test: css3/compositing/background-blend-mode-tiled-layers.html
2642
2643         * platform/graphics/CrossfadeGeneratedImage.cpp:
2644         (WebCore::CrossfadeGeneratedImage::drawPattern): Add the blendMode parameter and pass it to ImageBuffer::drawPattern.
2645         * platform/graphics/GradientImage.cpp:
2646         (WebCore::GradientImage::drawPattern): Add the blendMode parameter and pass it to ImageBuffer::drawPattern.
2647         * platform/graphics/ImageBuffer.h: Add a BlendMode parameter to the drawPattern method.
2648         * platform/graphics/cairo/ImageBufferCairo.cpp:
2649         (WebCore::ImageBuffer::drawPattern): Add the default BlendMode parameter to the method declaration.
2650         * platform/graphics/cg/ImageBufferCG.cpp:
2651         (WebCore::ImageBuffer::drawPattern): Add and use the blendMode parameter for all the code paths.
2652         * platform/graphics/wince/ImageBufferWinCE.cpp:
2653         (WebCore::BufferedImage::drawPattern): Add the default BlendMode parameter to the method declaration.
2654
2655 2014-01-21  Gurpreet Kaur  <k.gurpreet@samsung.com>
2656
2657         The WebCore.vcxproj.filters doesnot apply
2658         https://bugs.webkit.org/show_bug.cgi?id=127338
2659
2660         Reviewed by Csaba Osztrogonác.
2661
2662         * WebCore.vcxproj/WebCore.vcxproj.filters:
2663         Modified the WebCore.vcxproj.filters so that it is applied when loading
2664         WebCore.vcxproj file.
2665
2666 2014-01-21  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
2667
2668         Fix SVG animations which set rx or ry attributes
2669         https://bugs.webkit.org/show_bug.cgi?id=127337
2670
2671         Reviewed by Dirk Schulze.
2672
2673         Test: svg/stroke/animated-non-scaling-rxry.html
2674
2675         Merged from Blink: https://src.chromium.org/viewvc/blink?revision=152376&view=revision
2676
2677         * rendering/svg/RenderSVGRect.cpp:
2678         (WebCore::RenderSVGRect::updateShapeFromElement):
2679         * rendering/svg/SVGPathData.cpp:
2680         (WebCore::updatePathFromRectElement):
2681
2682 2014-01-21  Krzysztof Czech  <k.czech@samsung.com>
2683
2684         [ATK] Expose aria-flowto through ATK_RELATION_FLOWS_TO
2685         https://bugs.webkit.org/show_bug.cgi?id=127291
2686
2687         Reviewed by Mario Sanchez Prada.
2688
2689         Test: accessibility/aria-flowto.html
2690
2691         Expose aria-flowto through ATK_RELATION_FLOWS_TO according to
2692         http://www.w3.org/TR/wai-aria-implementation/#mapping_state-property
2693
2694         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2695         (setAtkRelationSetFromCoreObject):
2696
2697 2014-01-20  Ryuan Choi  <ryuan.choi@samsung.com>
2698
2699         [CMAKE] Remove Nix from CMake scripts
2700         https://bugs.webkit.org/show_bug.cgi?id=127264
2701
2702         Reviewed by Anders Carlsson.
2703
2704         * CMakeLists.txt:
2705
2706 2014-01-20  Anders Carlsson  <andersca@apple.com>
2707
2708         Remove an unused PageGroup function
2709         https://bugs.webkit.org/show_bug.cgi?id=127327
2710
2711         Reviewed by Andreas Kling.
2712
2713         * WebCore.exp.in:
2714         * page/PageGroup.cpp:
2715         * page/PageGroup.h:
2716
2717 2014-01-20  Anders Carlsson  <andersca@apple.com>
2718
2719         Move user style sheet handling to UserContentController
2720         https://bugs.webkit.org/show_bug.cgi?id=127322
2721         <rdar://problem/15861296>
2722
2723         Reviewed by Andreas Kling.
2724
2725         * dom/DocumentStyleSheetCollection.cpp:
2726         (WebCore::DocumentStyleSheetCollection::updateInjectedStyleSheetCache):
2727         * page/PageGroup.cpp:
2728         (WebCore::PageGroup::addUserStyleSheetToWorld):
2729         (WebCore::PageGroup::removeUserStyleSheetFromWorld):
2730         (WebCore::PageGroup::removeUserStyleSheetsFromWorld):
2731         (WebCore::PageGroup::removeAllUserContent):
2732         * page/PageGroup.h:
2733         * page/UserContentController.cpp:
2734         (WebCore::UserContentController::addUserStyleSheet):
2735         (WebCore::UserContentController::removeUserStyleSheet):
2736         (WebCore::UserContentController::removeUserStyleSheets):
2737         (WebCore::UserContentController::removeAllUserContent):
2738         (WebCore::UserContentController::invalidateInjectedStyleSheetCacheInAllFrames):
2739         * page/UserContentController.h:
2740         (WebCore::UserContentController::userStyleSheets):
2741
2742 2014-01-20  Benjamin Poulain  <benjamin@webkit.org>
2743
2744         Add a nicer way to iterate over all the attributes of an element
2745         https://bugs.webkit.org/show_bug.cgi?id=127266
2746
2747         Reviewed by Geoffrey Garen.
2748
2749         When using Element::attributeAt() in a loop, the compiler had to generate two kinds of
2750         accessor:
2751         -If the element data is unique, the length and data comes from the attribute Vector.
2752         -If the element data is shared, the data comes from the tail of elementData itself.
2753
2754         The choice was done for every access, which caused the assembly to be a little
2755         hard to follow.
2756         This patch unify the data access by doing everything as a array pointer with offset (getting
2757         that data from Vector when necessary).
2758
2759         To make it easier to do the right thing, a new iterator was added so that range-based loops
2760         can replace all the faulty cases.
2761
2762         * css/SelectorChecker.cpp:
2763         (WebCore::anyAttributeMatches):
2764         * css/SelectorChecker.h:
2765         (WebCore::SelectorChecker::checkExactAttribute):
2766         * dom/DatasetDOMStringMap.cpp:
2767         (WebCore::DatasetDOMStringMap::getNames):
2768         (WebCore::DatasetDOMStringMap::item):
2769         (WebCore::DatasetDOMStringMap::contains):
2770         * dom/Element.cpp:
2771         (WebCore::Element::normalizeAttributes):
2772         (WebCore::Element::detachAllAttrNodesFromElement):
2773         (WebCore::Element::cloneAttributesFromElement):
2774         * dom/Element.h:
2775         (WebCore::Element::attributesIterator):
2776         * dom/ElementData.cpp:
2777         (WebCore::ElementData::isEquivalent):
2778         (WebCore::ElementData::findAttributeIndexByNameSlowCase):
2779         * dom/ElementData.h:
2780         (WebCore::AttributeConstIterator::AttributeConstIterator):
2781         (WebCore::AttributeConstIterator::operator*):
2782         (WebCore::AttributeConstIterator::operator->):
2783         (WebCore::AttributeConstIterator::operator++):
2784         (WebCore::AttributeConstIterator::operator==):
2785         (WebCore::AttributeConstIterator::operator!=):
2786         (WebCore::AttributeIteratorAccessor::AttributeIteratorAccessor):
2787         (WebCore::AttributeIteratorAccessor::begin):
2788         (WebCore::AttributeIteratorAccessor::end):
2789         (WebCore::ElementData::attributesIterator):
2790         * dom/Node.cpp:
2791         (WebCore::Node::isDefaultNamespace):
2792         (WebCore::Node::lookupNamespaceURI):
2793         (WebCore::Node::lookupNamespacePrefix):
2794         (WebCore::Node::compareDocumentPosition):
2795         * dom/StyledElement.cpp:
2796         (WebCore::StyledElement::makePresentationAttributeCacheKey):
2797         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
2798         * editing/MarkupAccumulator.cpp:
2799         (WebCore::MarkupAccumulator::appendElement):
2800         * editing/markup.cpp:
2801         (WebCore::completeURLs):
2802         (WebCore::StyledMarkupAccumulator::appendElement):
2803         * html/HTMLEmbedElement.cpp:
2804         (WebCore::HTMLEmbedElement::parametersForPlugin):
2805         * html/HTMLObjectElement.cpp:
2806         (WebCore::HTMLObjectElement::parametersForPlugin):
2807         * inspector/DOMPatchSupport.cpp:
2808         (WebCore::DOMPatchSupport::innerPatchNode):
2809         (WebCore::DOMPatchSupport::createDigest):
2810         * inspector/InspectorDOMAgent.cpp:
2811         (WebCore::InspectorDOMAgent::setAttributesAsText):
2812         (WebCore::InspectorDOMAgent::buildArrayForElementAttributes):
2813         * inspector/InspectorNodeFinder.cpp:
2814         (WebCore::InspectorNodeFinder::matchesElement):
2815         * page/PageSerializer.cpp:
2816         (WebCore::isCharsetSpecifyingNode):
2817         * xml/XPathNodeSet.cpp:
2818         (WebCore::XPath::NodeSet::traversalSort):
2819         * xml/XPathStep.cpp:
2820         (WebCore::XPath::Step::nodesInAxis):
2821         * xml/parser/XMLDocumentParserLibxml2.cpp:
2822         (WebCore::XMLDocumentParser::XMLDocumentParser):
2823
2824 2014-01-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2825
2826         Do refactor in collectGradientAttributes() and renderStyleForLengthResolve()
2827         https://bugs.webkit.org/show_bug.cgi?id=126869
2828
2829         Reviewed by Dirk Schulze.
2830
2831         Some SVG functions have done a first iteration by using a boolean flag. This is
2832         one of poor implementations. This patch fix it by extracting a logic into a new method.
2833         Additionally it would be good to use do-while() loop instead of using while() in
2834         renderStyleForLengthResolving() because a first condition is always true.
2835
2836         Merge r165358 from blink.
2837
2838         * svg/SVGLengthContext.cpp:
2839         (WebCore::renderStyleForLengthResolving):
2840         * svg/SVGLinearGradientElement.cpp:
2841         (WebCore::setGradientAttributes):
2842         (WebCore::SVGLinearGradientElement::collectGradientAttributes):
2843         * svg/SVGRadialGradientElement.cpp:
2844         (WebCore::setGradientAttributes):
2845         (WebCore::SVGRadialGradientElement::collectGradientAttributes):
2846
2847 2014-01-20  Anders Carlsson  <andersca@apple.com>
2848
2849         UserContentController should keep track of user scripts
2850         https://bugs.webkit.org/show_bug.cgi?id=127317
2851         <rdar://problem/15861296>
2852
2853         Reviewed by Andreas Kling.
2854
2855         Move handling of user scripts from PageGroup to UserContentController.
2856
2857         * page/Frame.cpp:
2858         (WebCore::Frame::injectUserScripts):
2859         * page/PageGroup.cpp:
2860         (WebCore::PageGroup::addUserScriptToWorld):
2861         (WebCore::PageGroup::removeUserScriptFromWorld):
2862         (WebCore::PageGroup::removeUserScriptsFromWorld):
2863         (WebCore::PageGroup::removeAllUserContent):
2864         * page/PageGroup.h:
2865         * page/UserContentController.cpp:
2866         (WebCore::UserContentController::addUserScript):
2867         (WebCore::UserContentController::removeUserScript):
2868         (WebCore::UserContentController::removeUserScripts):
2869         (WebCore::UserContentController::removeAllUserContent):
2870         * page/UserContentController.h:
2871         (WebCore::UserContentController::userScripts):
2872
2873 2014-01-20  Anders Carlsson  <andersca@apple.com>
2874
2875         Give each page a UserContentController
2876         https://bugs.webkit.org/show_bug.cgi?id=127315
2877         <rdar://problem/15861296>
2878
2879         Reviewed by Andreas Kling.
2880
2881         Add a UserContentController object to PageGroup and have the page group set it on any
2882         pages that are added to the page group.
2883
2884         This is another step towards moving handling of user content away from PageGroup and make it
2885         possible for each page to have different user content.
2886
2887         * page/Page.cpp:
2888         (WebCore::Page::~Page):
2889         (WebCore::Page::setUserContentController):
2890         * page/Page.h:
2891         (WebCore::Page::userContentController):
2892         * page/PageGroup.cpp:
2893         (WebCore::PageGroup::PageGroup):
2894         (WebCore::PageGroup::addPage):
2895         (WebCore::PageGroup::removePage):
2896         * page/PageGroup.h:
2897         * page/UserContentController.cpp:
2898         (WebCore::UserContentController::addPage):
2899         (WebCore::UserContentController::removePage):
2900         * page/UserContentController.h:
2901
2902 2014-01-20  Jeremy Jones  <jeremyj@apple.com>
2903
2904         Add AVKit fullscreen video interface.
2905         https://bugs.webkit.org/show_bug.cgi?id=126818
2906
2907         Reviewed by Eric Carlson.
2908
2909         No new tests, no observable change in functionality.
2910
2911         * WebCore.exp.in:
2912         * WebCore.xcodeproj/project.pbxproj:
2913         * html/HTMLMediaElement.cpp:
2914         (WebCore::HTMLMediaElement::parseAttribute):
2915         * html/HTMLMediaElement.h:
2916         Add ability for fullscreen to borrow the AVPlayerLayer.
2917         * page/Settings.cpp:
2918         * page/Settings.h:
2919         (WebCore::Settings::setMediaPlaybackFullscreenAVKit):
2920         (WebCore::Settings::mediaPlaybackFullscreenAVKit):
2921         Add a disabled setting.
2922         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2923         (WebCore::MediaPlayerPrivateAVFoundation::supportsFullscreen):
2924         Enabled fullscreen for iOS.
2925         * platform/ios/WebVideoFullscreenControllerAVKit.h: Added.
2926         * platform/ios/WebVideoFullscreenControllerAVKit.mm: Added.
2927         (-[WebAVPlayerController init]):
2928         (-[WebAVPlayerController dealloc]):
2929         (-[WebAVPlayerController forwardingTargetForSelector:]):
2930         (-[WebAVPlayerController shouldDismissForDone]):
2931         (-[WebAVPlayerController play:]):
2932         (-[WebAVPlayerController pause:]):
2933         (-[WebAVPlayerController togglePlayback:]):
2934         (-[WebAVPlayerController isPlaying]):
2935         (-[WebAVPlayerController setPlaying:]):
2936         (+[WebAVPlayerController keyPathsForValuesAffectingPlaying]):
2937         (-[WebAVPlayerController seekToTime:]):
2938         (-[WebAVPlayerController updateTimingWithCurrentTime:]):
2939         (-[WebAVPlayerController effectiveRate]):
2940         (-[WebAVPlayerController setMediaElement:]):
2941         (-[WebAVPlayerController handleEvent:]):
2942         (-[WebVideoFullscreenController init]):
2943         (-[WebVideoFullscreenController dealloc]):
2944         (-[WebVideoFullscreenController setMediaElement:]):
2945         (-[WebVideoFullscreenController mediaElement]):
2946         (-[WebVideoFullscreenController enterFullscreen:]):
2947         (-[WebVideoFullscreenController exitFullscreen]):
2948         Add WebAVPlayerController for HTMLMediaElememt to interface with AVPlayerViewController.
2949
2950 2014-01-20  Zan Dobersek  <zdobersek@igalia.com>
2951
2952         Replace uses of std::forward<T>(), std::unique_ptr<T>::clear() that landed in r162368
2953         https://bugs.webkit.org/show_bug.cgi?id=127306
2954
2955         Reviewed by Darin Adler.
2956
2957         Address the post-landing reviews of the r162368 commit that moved WebAudio source code to using std::unique_ptr.
2958         std::move() should be used instead of std::forward<T>() in HRTFKernel::create().
2959         Instead of calling std::unique_ptr<T>::reset(), nullptr should be assigned to that smart pointer to reset it.
2960
2961         * Modules/webaudio/ConvolverNode.cpp:
2962         (WebCore::ConvolverNode::uninitialize):
2963         * Modules/webaudio/DynamicsCompressorNode.cpp:
2964         (WebCore::DynamicsCompressorNode::uninitialize):
2965         * Modules/webaudio/MediaElementAudioSourceNode.cpp:
2966         (WebCore::MediaElementAudioSourceNode::setFormat):
2967         * Modules/webaudio/PannerNode.cpp:
2968         (WebCore::PannerNode::uninitialize):
2969         * platform/audio/AudioChannel.h:
2970         (WebCore::AudioChannel::set):
2971         * platform/audio/HRTFDatabaseLoader.cpp:
2972         (WebCore::HRTFDatabaseLoader::~HRTFDatabaseLoader):
2973         * platform/audio/HRTFKernel.h:
2974         (WebCore::HRTFKernel::create):
2975
2976 2014-01-20  Joseph Pecoraro  <pecoraro@apple.com>
2977
2978         Modernize WebCore/inspector with nullptr
2979         https://bugs.webkit.org/show_bug.cgi?id=127303
2980
2981         Reviewed by Anders Carlsson.
2982
2983         Ran clang-modernize -use-nullptr over WebCore/inspector.
2984
2985         * inspector/ConsoleMessage.cpp:
2986         (WebCore::ConsoleMessage::ConsoleMessage):
2987         * inspector/ConsoleMessage.h:
2988         * inspector/ContentSearchUtils.cpp:
2989         (WebCore::ContentSearchUtils::findMagicComment):
2990         * inspector/DOMEditor.cpp:
2991         (WebCore::DOMEditor::SetOuterHTMLAction::SetOuterHTMLAction):
2992         * inspector/DOMPatchSupport.cpp:
2993         (WebCore::DOMPatchSupport::patchDocument):
2994         (WebCore::DOMPatchSupport::patchNode):
2995         (WebCore::DOMPatchSupport::diff):
2996         (WebCore::DOMPatchSupport::innerPatchChildren):
2997         * inspector/InspectorApplicationCacheAgent.cpp:
2998         (WebCore::InspectorApplicationCacheAgent::willDestroyFrontendAndBackend):
2999         (WebCore::InspectorApplicationCacheAgent::assertFrameWithDocumentLoader):
3000         * inspector/InspectorCanvasAgent.cpp:
3001         (WebCore::InspectorCanvasAgent::disable):
3002         (WebCore::InspectorCanvasAgent::notifyRenderingContextWasWrapped):
3003         (WebCore::InspectorCanvasAgent::frameNavigated):
3004         * inspector/InspectorConsoleAgent.cpp:
3005         (WebCore::InspectorConsoleAgent::InspectorConsoleAgent):
3006         (WebCore::InspectorConsoleAgent::~InspectorConsoleAgent):
3007         (WebCore::InspectorConsoleAgent::clearMessages):
3008         (WebCore::InspectorConsoleAgent::didFinishXHRLoading):
3009         (WebCore::InspectorConsoleAgent::didReceiveResponse):
3010         (WebCore::InspectorConsoleAgent::didFailLoading):
3011         * inspector/InspectorConsoleAgent.h:
3012         * inspector/InspectorController.cpp:
3013         (WebCore::InspectorController::inspectedPageDestroyed):
3014         * inspector/InspectorDOMDebuggerAgent.cpp:
3015         (WebCore::InspectorDOMDebuggerAgent::disable):
3016         (WebCore::InspectorDOMDebuggerAgent::discardAgent):
3017         * inspector/InspectorDOMStorageAgent.cpp:
3018         (WebCore::InspectorDOMStorageAgent::~InspectorDOMStorageAgent):
3019         (WebCore::InspectorDOMStorageAgent::setDOMStorageItem):
3020         (WebCore::InspectorDOMStorageAgent::removeDOMStorageItem):
3021         (WebCore::InspectorDOMStorageAgent::findStorageArea):
3022         * inspector/InspectorDatabaseAgent.cpp:
3023         (WebCore::InspectorDatabaseAgent::~InspectorDatabaseAgent):
3024         (WebCore::InspectorDatabaseAgent::findByFileName):
3025         (WebCore::InspectorDatabaseAgent::databaseForId):
3026         * inspector/InspectorDebuggerAgent.cpp:
3027         (WebCore::InspectorDebuggerAgent::addMessageToConsole):
3028         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
3029         (WebCore::InspectorDebuggerAgent::didParseSource):
3030         (WebCore::InspectorDebuggerAgent::didContinue):
3031         (WebCore::InspectorDebuggerAgent::clearBreakDetails):
3032         * inspector/InspectorFrontendHost.cpp:
3033         (WebCore::FrontendMenuProvider::disconnect):
3034         (WebCore::InspectorFrontendHost::InspectorFrontendHost):
3035         (WebCore::InspectorFrontendHost::disconnectClient):
3036         * inspector/InspectorHeapProfilerAgent.cpp:
3037         (WebCore::InspectorHeapProfilerAgent::~InspectorHeapProfilerAgent):
3038         * inspector/InspectorIndexedDBAgent.cpp:
3039         (WebCore::assertDocument):
3040         (WebCore::assertIDBFactory):
3041         (WebCore::InspectorIndexedDBAgent::requestData):
3042         * inspector/InspectorInstrumentation.cpp:
3043         (WebCore::frameForScriptExecutionContext):
3044         (WebCore::InspectorInstrumentation::willDispatchEventOnWindowImpl):
3045         (WebCore::InspectorInstrumentation::didReceiveResourceResponseButCanceledImpl):
3046         (WebCore::InspectorInstrumentation::consoleAgentEnabled):
3047         (WebCore::InspectorInstrumentation::unregisterInstrumentingAgents):
3048         (WebCore::InspectorInstrumentation::retrieveTimelineAgent):
3049         (WebCore::InspectorInstrumentation::instrumentingAgentsForPage):
3050         (WebCore::InspectorInstrumentation::instrumentingAgentsForWorkerGlobalScope):
3051         (WebCore::InspectorInstrumentation::instrumentingAgentsForNonDocumentContext):
3052         * inspector/InspectorInstrumentation.h:
3053         (WebCore::InspectorInstrumentation::instrumentingAgentsForContext):
3054         (WebCore::InspectorInstrumentation::instrumentingAgentsForFrame):
3055         (WebCore::InspectorInstrumentation::instrumentingAgentsForDocument):
3056         * inspector/InspectorLayerTreeAgent.cpp:
3057         (WebCore::InspectorLayerTreeAgent::disable):
3058         * inspector/InspectorNodeFinder.cpp:
3059         (WebCore::InspectorNodeFinder::searchUsingXPath):
3060         * inspector/InspectorOverlay.cpp:
3061         (WebCore::buildObjectForElementInfo):
3062         * inspector/InspectorPageAgent.cpp:
3063         (WebCore::InspectorPageAgent::cachedResourceContent):
3064         (WebCore::InspectorPageAgent::sharedBufferContent):
3065         (WebCore::InspectorPageAgent::disable):
3066         (WebCore::InspectorPageAgent::frameForId):
3067         (WebCore::InspectorPageAgent::findFrameWithSecurityOrigin):
3068         * inspector/InspectorProfilerAgent.cpp:
3069         (WebCore::InspectorProfilerAgent::~InspectorProfilerAgent):
3070         * inspector/InspectorProfilerAgent.h:
3071         * inspector/InspectorResourceAgent.cpp:
3072         (WebCore::buildObjectForResourceResponse):
3073         (WebCore::InspectorResourceAgent::willSendRequest):
3074         (WebCore::InspectorResourceAgent::didReceiveResponse):
3075         (WebCore::InspectorResourceAgent::didFinishLoading):
3076         (WebCore::InspectorResourceAgent::didFailLoading):
3077         (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache):
3078         (WebCore::InspectorResourceAgent::disable):
3079         * inspector/InspectorRuntimeAgent.cpp:
3080         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
3081         * inspector/InspectorStyleSheet.cpp:
3082         (ParsedStyleSheet::ruleSourceDataAt):
3083         (WebCore::buildSourceRangeObject):
3084         (WebCore::asCSSRuleList):
3085         (WebCore::fillMediaListChain):
3086         (WebCore::InspectorStyle::setPropertyText):
3087         (WebCore::InspectorStyle::populateAllProperties):
3088         (WebCore::InspectorStyle::extractSourceData):
3089         (WebCore::InspectorStyle::newLineAndWhitespaceDelimiters):
3090         (WebCore::InspectorStyleSheet::addRule):
3091         (WebCore::InspectorStyleSheet::ruleForId):
3092         (WebCore::InspectorStyleSheet::buildObjectForStyleSheet):
3093         (WebCore::InspectorStyleSheet::buildObjectForStyleSheetInfo):
3094         (WebCore::InspectorStyleSheet::buildObjectForRule):
3095         (WebCore::InspectorStyleSheet::styleForId):
3096         (WebCore::InspectorStyleSheet::inspectorStyleForId):
3097         (WebCore::InspectorStyleSheetForInlineStyle::InspectorStyleSheetForInlineStyle):
3098         * inspector/InspectorStyleSheet.h:
3099         (WebCore::InspectorCSSId::asProtocolValue):
3100         * inspector/InspectorTimelineAgent.cpp:
3101         (WebCore::InspectorTimelineAgent::stop):
3102         (WebCore::InspectorTimelineAgent::willComposite):
3103         (WebCore::InspectorTimelineAgent::page):
3104         * inspector/InspectorWorkerAgent.cpp:
3105         (WebCore::InspectorWorkerAgent::~InspectorWorkerAgent):
3106         * inspector/InstrumentingAgents.cpp:
3107         (WebCore::InstrumentingAgents::InstrumentingAgents):
3108         (WebCore::InstrumentingAgents::reset):
3109         * inspector/NetworkResourcesData.cpp:
3110         (WebCore::NetworkResourcesData::ResourceData::ResourceData):
3111         (WebCore::NetworkResourcesData::xhrReplayData):
3112         (WebCore::NetworkResourcesData::removeCachedResource):
3113         (WebCore::NetworkResourcesData::resourceDataForRequestId):
3114         * inspector/PageConsoleAgent.cpp:
3115         (WebCore::PageConsoleAgent::~PageConsoleAgent):
3116         * inspector/PageDebuggerAgent.cpp:
3117         (WebCore::PageDebuggerAgent::disable):
3118         * inspector/PageRuntimeAgent.cpp:
3119         (WebCore::PageRuntimeAgent::~PageRuntimeAgent):
3120         (WebCore::PageRuntimeAgent::didCreateMainWorldContext):
3121         (WebCore::PageRuntimeAgent::reportExecutionContextCreation):
3122         * inspector/ScriptArguments.cpp:
3123         (WebCore::ScriptArguments::globalState):
3124         * inspector/WorkerRuntimeAgent.cpp:
3125         (WebCore::WorkerRuntimeAgent::~WorkerRuntimeAgent):
3126
3127 2014-01-20  Anders Carlsson  <andersca@apple.com>
3128
3129         Add empty UserContentController class
3130         https://bugs.webkit.org/show_bug.cgi?id=127300
3131         <rdar://problem/15861296>
3132
3133         Reviewed by Dan Bernstein.
3134
3135         This is the first step towards moving handling of user scripts and style sheets from
3136         the page group to a separate objects and ultimately make them be settable per page instead of per page group.
3137
3138         * CMakeLists.txt:
3139         * GNUmakefile.list.am:
3140         * WebCore.vcxproj/WebCore.vcxproj:
3141         * WebCore.vcxproj/WebCore.vcxproj.filters:
3142         * WebCore.xcodeproj/project.pbxproj:
3143         * page/UserContentController.cpp: Added.
3144         (WebCore::UserContentController::create):
3145         (WebCore::UserContentController::UserContentController):
3146         (WebCore::UserContentController::~UserContentController):
3147         * page/UserContentController.h: Added.
3148
3149 2014-01-20  Joseph Pecoraro  <pecoraro@apple.com>
3150
3151         Run clang-modernize and let it add a bunch of missing overrides in WebCore/inspector
3152         https://bugs.webkit.org/show_bug.cgi?id=127206
3153
3154         Reviewed by Anders Carlsson.
3155
3156         Let clang-modernize add overrides.
3157
3158         * inspector/DOMEditor.cpp:
3159         * inspector/InspectorApplicationCacheAgent.h:
3160         * inspector/InspectorCSSAgent.h:
3161         * inspector/InspectorCanvasAgent.h:
3162         * inspector/InspectorConsoleAgent.h:
3163         * inspector/InspectorDOMAgent.h:
3164         * inspector/InspectorDOMDebuggerAgent.h:
3165         * inspector/InspectorDOMStorageAgent.h:
3166         * inspector/InspectorDatabaseAgent.cpp:
3167         * inspector/InspectorDatabaseAgent.h:
3168         * inspector/InspectorDebuggerAgent.h:
3169         * inspector/InspectorFrontendHost.cpp:
3170         * inspector/InspectorHeapProfilerAgent.cpp:
3171         (WebCore::InspectorHeapProfilerAgent::getHeapSnapshot):
3172         (WebCore::InspectorHeapProfilerAgent::takeHeapSnapshot):
3173         * inspector/InspectorHeapProfilerAgent.h:
3174         * inspector/InspectorHistory.cpp:
3175         * inspector/InspectorIndexedDBAgent.cpp:
3176         * inspector/InspectorIndexedDBAgent.h:
3177         * inspector/InspectorInputAgent.h:
3178         * inspector/InspectorLayerTreeAgent.h:
3179         * inspector/InspectorMemoryAgent.h:
3180         * inspector/InspectorPageAgent.h:
3181         * inspector/InspectorProfilerAgent.cpp:
3182         * inspector/InspectorProfilerAgent.h:
3183         * inspector/InspectorResourceAgent.h:
3184         * inspector/InspectorRuntimeAgent.h:
3185         * inspector/InspectorStyleSheet.h:
3186         * inspector/InspectorTimelineAgent.h:
3187         * inspector/InspectorWorkerAgent.cpp:
3188         * inspector/InspectorWorkerAgent.h:
3189         * inspector/PageConsoleAgent.h:
3190         * inspector/PageDebuggerAgent.h:
3191         * inspector/PageRuntimeAgent.h:
3192         * inspector/WorkerConsoleAgent.h:
3193         * inspector/WorkerDebuggerAgent.cpp:
3194         * inspector/WorkerInspectorController.cpp:
3195         * inspector/WorkerRuntimeAgent.h:
3196
3197 2014-01-20  Zan Dobersek  <zdobersek@igalia.com>
3198
3199         Move WebAudio source code to std::unique_ptr
3200         https://bugs.webkit.org/show_bug.cgi?id=127274
3201
3202         Reviewed by Eric Carlson.
3203
3204         Move from using OwnPtr and PassOwnPtr to using std::unique_ptr and move semantics
3205         in the WebAudio module and the WebAudio code in the platform layer.
3206
3207         * Modules/webaudio/AsyncAudioDecoder.cpp:
3208         * Modules/webaudio/AsyncAudioDecoder.h:
3209         * Modules/webaudio/AudioBasicInspectorNode.cpp:
3210         (WebCore::AudioBasicInspectorNode::AudioBasicInspectorNode):
3211         * Modules/webaudio/AudioBasicProcessorNode.cpp:
3212         (WebCore::AudioBasicProcessorNode::AudioBasicProcessorNode):
3213         * Modules/webaudio/AudioBasicProcessorNode.h:
3214         * Modules/webaudio/AudioBufferSourceNode.cpp:
3215         (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
3216         * Modules/webaudio/AudioContext.cpp:
3217         * Modules/webaudio/AudioContext.h:
3218         * Modules/webaudio/AudioDestinationNode.cpp:
3219         (WebCore::AudioDestinationNode::AudioDestinationNode):
3220         * Modules/webaudio/AudioNode.cpp:
3221         (WebCore::AudioNode::addInput):
3222         (WebCore::AudioNode::addOutput):
3223         (WebCore::AudioNode::checkNumberOfChannelsForInput):
3224         * Modules/webaudio/AudioNode.h:
3225         * Modules/webaudio/BiquadFilterNode.cpp:
3226         (WebCore::BiquadFilterNode::BiquadFilterNode):
3227         * Modules/webaudio/BiquadProcessor.cpp:
3228         (WebCore::BiquadProcessor::createKernel):
3229         (WebCore::BiquadProcessor::getFrequencyResponse):
3230         * Modules/webaudio/BiquadProcessor.h:
3231         * Modules/webaudio/ChannelMergerNode.cpp:
3232         (WebCore::ChannelMergerNode::ChannelMergerNode):
3233         * Modules/webaudio/ChannelSplitterNode.cpp:
3234         (WebCore::ChannelSplitterNode::ChannelSplitterNode):
3235         * Modules/webaudio/ConvolverNode.cpp:
3236         (WebCore::ConvolverNode::ConvolverNode):
3237         (WebCore::ConvolverNode::uninitialize):
3238         (WebCore::ConvolverNode::setBuffer):
3239         * Modules/webaudio/ConvolverNode.h:
3240         * Modules/webaudio/DefaultAudioDestinationNode.h:
3241         * Modules/webaudio/DelayNode.cpp:
3242         (WebCore::DelayNode::DelayNode):
3243         * Modules/webaudio/DelayProcessor.cpp:
3244         (WebCore::DelayProcessor::createKernel):
3245         * Modules/webaudio/DelayProcessor.h:
3246         * Modules/webaudio/DynamicsCompressorNode.cpp:
3247         (WebCore::DynamicsCompressorNode::DynamicsCompressorNode):
3248         (WebCore::DynamicsCompressorNode::initialize):
3249         (WebCore::DynamicsCompressorNode::uninitialize):
3250         * Modules/webaudio/DynamicsCompressorNode.h:
3251         * Modules/webaudio/GainNode.cpp:
3252         (WebCore::GainNode::GainNode):
3253         * Modules/webaudio/MediaElementAudioSourceNode.cpp:
3254         (WebCore::MediaElementAudioSourceNode::MediaElementAudioSourceNode):
3255         (WebCore::MediaElementAudioSourceNode::setFormat):
3256         * Modules/webaudio/MediaElementAudioSourceNode.h:
3257         * Modules/webaudio/MediaStreamAudioDestinationNode.h:
3258         * Modules/webaudio/MediaStreamAudioSource.cpp:
3259         * Modules/webaudio/MediaStreamAudioSourceNode.cpp:
3260         (WebCore::MediaStreamAudioSourceNode::MediaStreamAudioSourceNode):
3261         * Modules/webaudio/MediaStreamAudioSourceNode.h:
3262         * Modules/webaudio/OscillatorNode.cpp:
3263         (WebCore::OscillatorNode::OscillatorNode):
3264         * Modules/webaudio/PannerNode.cpp:
3265         (WebCore::PannerNode::PannerNode):
3266         (WebCore::PannerNode::uninitialize):
3267         (WebCore::PannerNode::setPanningModel):
3268         * Modules/webaudio/PannerNode.h:
3269         * Modules/webaudio/PeriodicWave.cpp:
3270         (WebCore::PeriodicWave::createBandLimitedTables):
3271         * Modules/webaudio/PeriodicWave.h:
3272         * Modules/webaudio/RealtimeAnalyser.cpp:
3273         (WebCore::RealtimeAnalyser::RealtimeAnalyser):
3274         (WebCore::RealtimeAnalyser::setFftSize):
3275         * Modules/webaudio/RealtimeAnalyser.h:
3276         * Modules/webaudio/ScriptProcessorNode.cpp:
3277         (WebCore::ScriptProcessorNode::ScriptProcessorNode):
3278         * Modules/webaudio/WaveShaperDSPKernel.cpp:
3279         (WebCore::WaveShaperDSPKernel::lazyInitializeOversampling):
3280         * Modules/webaudio/WaveShaperDSPKernel.h:
3281         * Modules/webaudio/WaveShaperNode.cpp:
3282         (WebCore::WaveShaperNode::WaveShaperNode):
3283         * Modules/webaudio/WaveShaperProcessor.cpp:
3284         (WebCore::WaveShaperProcessor::createKernel):
3285         * Modules/webaudio/WaveShaperProcessor.h:
3286         * platform/audio/AudioBus.cpp:
3287         (WebCore::AudioBus::AudioBus):
3288         (WebCore::AudioBus::copyWithGainFrom):
3289         * platform/audio/AudioBus.h:
3290         * platform/audio/AudioChannel.cpp:
3291         * platform/audio/AudioChannel.h:
3292         (WebCore::AudioChannel::AudioChannel):
3293         (WebCore::AudioChannel::set):
3294         * platform/audio/AudioDSPKernelProcessor.h:
3295         * platform/audio/AudioDestination.h:
3296         * platform/audio/AudioResampler.cpp:
3297         (WebCore::AudioResampler::AudioResampler):
3298         (WebCore::AudioResampler::configureChannels):
3299         * platform/audio/AudioResampler.h:
3300         * platform/audio/AudioSession.h:
3301         * platform/audio/DynamicsCompressor.cpp:
3302         (WebCore::DynamicsCompressor::setNumberOfChannels):
3303         * platform/audio/DynamicsCompressor.h:
3304         * platform/audio/DynamicsCompressorKernel.cpp:
3305         (WebCore::DynamicsCompressorKernel::setNumberOfChannels):
3306         * platform/audio/DynamicsCompressorKernel.h:
3307         * platform/audio/FFTFrame.cpp:
3308         (WebCore::FFTFrame::createInterpolatedFrame):
3309         * platform/audio/FFTFrame.h:
3310         * platform/audio/HRTFDatabase.cpp:
3311         (WebCore::HRTFDatabase::HRTFDatabase):
3312         * platform/audio/HRTFDatabase.h:
3313         * platform/audio/HRTFDatabaseLoader.cpp:
3314         (WebCore::HRTFDatabaseLoader::~HRTFDatabaseLoader):
3315         (WebCore::HRTFDatabaseLoader::load):
3316         * platform/audio/HRTFDatabaseLoader.h:
3317         * platform/audio/HRTFElevation.cpp:
3318         (WebCore::HRTFElevation::createForSubject):
3319         (WebCore::HRTFElevation::createByInterpolatingSlices):
3320         * platform/audio/HRTFElevation.h:
3321         (WebCore::HRTFElevation::HRTFElevation):
3322         * platform/audio/HRTFKernel.cpp:
3323         (WebCore::HRTFKernel::HRTFKernel):
3324         (WebCore::HRTFKernel::createImpulseResponse):
3325         (WebCore::HRTFKernel::createInterpolatedKernel):
3326         * platform/audio/HRTFKernel.h:
3327         (WebCore::HRTFKernel::create):
3328         (WebCore::HRTFKernel::HRTFKernel):
3329         * platform/audio/MultiChannelResampler.cpp:
3330         (WebCore::MultiChannelResampler::MultiChannelResampler):
3331         * platform/audio/MultiChannelResampler.h:
3332         * platform/audio/Panner.cpp:
3333         (WebCore::Panner::create):
3334         * platform/audio/Panner.h:
3335         * platform/audio/Reverb.cpp:
3336         (WebCore::Reverb::initialize):
3337         * platform/audio/Reverb.h:
3338         * platform/audio/ReverbConvolver.h:
3339         * platform/audio/ReverbConvolverStage.cpp:
3340         (WebCore::ReverbConvolverStage::ReverbConvolverStage):
3341         * platform/audio/ReverbConvolverStage.h:
3342         * platform/audio/gstreamer/AudioDestinationGStreamer.cpp:
3343         (WebCore::AudioDestination::create):
3344         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
3345         * platform/audio/ios/AudioDestinationIOS.cpp:
3346         (WebCore::AudioDestination::create):
3347         * platform/audio/ios/AudioSessionIOS.mm:
3348         (WebCore::AudioSession::AudioSession):
3349         * platform/audio/mac/AudioDestinationMac.cpp:
3350         (WebCore::AudioDestination::create):
3351         * platform/audio/mac/AudioDestinationMac.h:
3352         * platform/audio/mac/AudioSessionMac.cpp:
3353         (WebCore::AudioSession::AudioSession):
3354
3355 2014-01-20  Morten Stenshorne  <mstensho@opera.com>
3356
3357         Region based multicol: support explicit column breaks
3358         https://bugs.webkit.org/show_bug.cgi?id=123993
3359
3360         Reviewed by David Hyatt.
3361
3362         Merely supporting insertion of explicit (forced) column breaks in
3363         the region based multicol implementation is really simple: just
3364         hook up with what the CSS regions code is already doing.
3365
3366         However, there is one complication: column balancing. In order to
3367         balance columns as nicely as possible when there are explicit
3368         breaks, we need to figure out between which explicit breaks the
3369         implicit breaks will occur (if there's room for any at all).
3370
3371         Tests: fast/multicol/newmulticol/break-after.html
3372                fast/multicol/newmulticol/break-before.html
3373                fast/multicol/newmulticol/breaks-2-columns-3-no-balancing.html
3374                fast/multicol/newmulticol/breaks-2-columns-3.html
3375                fast/multicol/newmulticol/breaks-3-columns-3.html
3376                fast/multicol/newmulticol/fixed-height-fill-balance-2.html
3377
3378         * rendering/RenderBlockFlow.cpp:
3379         (WebCore::RenderBlockFlow::applyBeforeBreak):
3380         (WebCore::RenderBlockFlow::applyAfterBreak): Use the already
3381         existing region breaking code when inserting breaks in region
3382         based multicol.
3383         * rendering/RenderFlowThread.h:
3384         * rendering/RenderMultiColumnBlock.cpp:
3385         (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
3386         (WebCore::RenderMultiColumnBlock::relayoutForPagination): Avoid
3387         re-balancing if the multicol's contents were not laid out. Apart
3388         from being good for performance, this is now necessary because of
3389         how explicit breaks are implemented.
3390         (WebCore::RenderMultiColumnBlock::layoutSpecialExcludedChild):
3391         Detect if the contents are going to be laid out, or skipped, so
3392         that we can tell if we need to (re-)balance the columns
3393         afterwards.
3394         * rendering/RenderMultiColumnBlock.h:
3395         * rendering/RenderMultiColumnFlowThread.cpp:
3396         (WebCore::RenderMultiColumnFlowThread::addForcedRegionBreak):
3397         Locate the appropriate multi-column set and call its
3398         addForcedBreak().
3399         * rendering/RenderMultiColumnFlowThread.h:
3400         * rendering/RenderMultiColumnSet.cpp:
3401         (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
3402         (WebCore::RenderMultiColumnSet::findRunWithTallestColumns):
3403         (WebCore::RenderMultiColumnSet::distributeImplicitBreaks): Figure
3404         out how many implicit breaks each single "content run" should
3405         contain. The taller the content run, the more implicit breaks.
3406         (WebCore::RenderMultiColumnSet::calculateBalancedHeight): This is
3407         now a const method that only does half of what the old
3408         calculateBalancedHeight() did. The rest (such as actually storing
3409         the new column height) is done by recalculateBalancedHeight().
3410         (WebCore::RenderMultiColumnSet::clearForcedBreaks): Needs to be
3411         called between each layout pass, to clear the list of "content
3412         runs".
3413         (WebCore::RenderMultiColumnSet::addForcedBreak): Only useful when
3414         columns are to be balanced. It receives explicit (forced) breaks
3415         and stores them as "content runs". When layout is done, we'll go
3416         through the list of content runs, and see where implicit breaks
3417         should be inserted (if there's room for any). The goal is to
3418         insert implicit breaks in such a way that the final columns become
3419         as short as possible.
3420         (WebCore::RenderMultiColumnSet::recalculateBalancedHeight):
3421         Calculates and sets a new balanced column height. This used to be
3422         done directly in calculateBalancedHeight(), but that method is now
3423         const and it now only calculates the new height and returns it.
3424         (WebCore::RenderMultiColumnSet::prepareForLayout):
3425         * rendering/RenderMultiColumnSet.h: Remove old data members
3426         intended for forced breaks (they were unused), and introduce a
3427         "content run" vector instead. A new content run is triggered by an
3428         explicit break. This is only used when column balancing is
3429         enabled. When not balanced, RenderMultiColumnSet doesn't need to
3430         do anything when explicit breaks are inserted.
3431
3432 2014-01-20  Eric Carlson  <eric.carlson@apple.com>
3433
3434         Allow MediaSessionManager to restrict 'preload' behavior
3435         https://bugs.webkit.org/show_bug.cgi?id=127297
3436
3437         Reviewed by Jer Noble.
3438
3439         Tests: media/video-restricted-no-preload-auto.html
3440                media/video-restricted-no-preload-metadata.html
3441
3442         * html/HTMLMediaElement.cpp:
3443         (WebCore::HTMLMediaElement::parseAttribute): Apply restrictions to preload attribute before
3444             passing to media engine.
3445         (WebCore::HTMLMediaElement::loadResource): Ditto.
3446
3447         * html/HTMLMediaSession.cpp:
3448         (WebCore::HTMLMediaSession::effectivePreloadForElement): New, limit preload according to restrictions.
3449         * html/HTMLMediaSession.h:
3450
3451         * platform/audio/MediaSessionManager.h:
3452         * platform/audio/ios/MediaSessionManagerIOS.mm:
3453         (WebCore::MediaSessionManageriOS::resetRestrictions): Limit preload to metadata only. Drive-by
3454             static deviceClass initialization cleanup.
3455
3456         * testing/Internals.cpp:
3457         (WebCore::Internals::setMediaSessionRestrictions): Support MetadataPreloadingNotPermitted and
3458             AutoPreloadingNotPermitted.
3459
3460 2014-01-20  Andreas Kling  <akling@apple.com>
3461
3462         Let RenderImage construct its RenderImageResource.
3463         <https://webkit.org/b/127290>
3464
3465         Everyone who creates a RenderImage immediately follows up with
3466         creating a RenderImageResource and assigning it to the image.
3467
3468         Let the RenderImage constructor do this instead, and make the
3469         imageResource() accessors return references. This exposed a
3470         number of unnecessary null checks.
3471
3472         Also modernized the touched code with std::unique_ptr.
3473
3474         Reviewed by Antti Koivisto.
3475
3476         * html/HTMLImageElement.cpp:
3477         (WebCore::HTMLImageElement::createElementRenderer):
3478         (WebCore::HTMLImageElement::didAttachRenderers):
3479         * html/HTMLPlugInImageElement.cpp:
3480         (WebCore::HTMLPlugInImageElement::createElementRenderer):
3481         * html/HTMLVideoElement.cpp:
3482         (WebCore::HTMLVideoElement::didAttachRenderers):
3483         (WebCore::HTMLVideoElement::parseAttribute):
3484         * html/ImageInputType.cpp:
3485         (WebCore::ImageInputType::createInputRenderer):
3486         (WebCore::ImageInputType::attach):
3487         * loader/ImageLoader.cpp:
3488         (WebCore::ImageLoader::renderImageResource):
3489         * rendering/RenderElement.cpp:
3490         (WebCore::RenderElement::createFor):
3491         * rendering/RenderImage.cpp:
3492         (WebCore::RenderImage::RenderImage):
3493         (WebCore::RenderImage::~RenderImage):
3494         (WebCore::RenderImage::styleDidChange):
3495         (WebCore::RenderImage::imageChanged):
3496         (WebCore::RenderImage::updateIntrinsicSizeIfNeeded):
3497         (WebCore::RenderImage::updateInnerContentRect):
3498         (WebCore::RenderImage::imageDimensionsChanged):
3499         (WebCore::RenderImage::notifyFinished):
3500         (WebCore::RenderImage::paintReplaced):
3501         (WebCore::RenderImage::paintIntoRect):
3502         (WebCore::RenderImage::foregroundIsKnownToBeOpaqueInRect):
3503         (WebCore::RenderImage::minimumReplacedHeight):
3504         (WebCore::RenderImage::computeIntrinsicRatioInformation):
3505         (WebCore::RenderImage::embeddedContentBox):
3506         * rendering/RenderImage.h:
3507         (WebCore::RenderImage::imageResource):
3508         (WebCore::RenderImage::cachedImage):
3509         * rendering/RenderImageResource.h:
3510         * rendering/RenderImageResourceStyleImage.h:
3511         * rendering/RenderMedia.cpp:
3512         (WebCore::RenderMedia::RenderMedia):
3513         * rendering/RenderSnapshottedPlugIn.cpp:
3514         (WebCore::RenderSnapshottedPlugIn::RenderSnapshottedPlugIn):
3515         * rendering/RenderSnapshottedPlugIn.h:
3516         * rendering/RenderVideo.cpp:
3517         (WebCore::RenderVideo::calculateIntrinsicSize):
3518         * rendering/style/ContentData.cpp:
3519         (WebCore::ImageContentData::createContentRenderer):
3520         * rendering/svg/RenderSVGImage.cpp:
3521         (WebCore::RenderSVGImage::RenderSVGImage):
3522         (WebCore::RenderSVGImage::~RenderSVGImage):
3523         (WebCore::RenderSVGImage::updateImageViewport):
3524         (WebCore::RenderSVGImage::paint):
3525         (WebCore::RenderSVGImage::paintForeground):
3526         * rendering/svg/RenderSVGImage.h:
3527         * svg/SVGImageElement.cpp:
3528         (WebCore::SVGImageElement::didAttachRenderers):
3529
3530 2014-01-20  Antti Koivisto  <antti@apple.com>
3531
3532         Update overlay scrollbars in single pass
3533         https://bugs.webkit.org/show_bug.cgi?id=127289
3534
3535         Reviewed by Anders Carlsson.
3536
3537         * platform/ScrollView.cpp:
3538         (WebCore::ScrollView::updateScrollbars):
3539         
3540             Multi-pass scrollbar resolution is only needed for traditional scrollbars. Overlay scrollbars don't affect layout.
3541
3542 2014-01-20  Jochen Eisinger  <jochen@chromium.org>
3543
3544         Never send a non-http(s) referrer header even with a referrer policy
3545         https://bugs.webkit.org/show_bug.cgi?id=127172
3546
3547         Reviewed by Alexey Proskuryakov.
3548
3549         This mirrors the code SecurityPolicy::shouldHideReferrer which is used
3550         for ReferrerPolicyDefault.
3551
3552         No new tests, only affects an embedder that registers other schemes,
3553         e.g. chrome://
3554
3555         * page/SecurityPolicy.cpp:
3556         (WebCore::SecurityPolicy::generateReferrerHeader):
3557
3558 2014-01-20  Mihai Tica  <mitica@adobe.com>
3559
3560         [CSS Background Blending] Background layer with -webkit-cross-fade doesn't blend
3561         when having -webkit-background-blending applied. Turns out the problem was
3562         the blending parameter not being passed to WebCore::CrossfadeGeneratedImage::draw
3563
3564         https://bugs.webkit.org/show_bug.cgi?id=126887
3565
3566         Reviewed by Dirk Schulze.
3567
3568         Test: css3/compositing/background-blend-mode-crossfade-image.html
3569
3570         * platform/graphics/CrossfadeGeneratedImage.cpp:
3571         (WebCore::CrossfadeGeneratedImage::draw): set blendMode on context.
3572
3573 2013-11-22  Sergio Villar Senin  <svillar@igalia.com>
3574
3575         Null-pointer dereference in WebCore::CSSValue::isPrimitiveValue
3576         https://bugs.webkit.org/show_bug.cgi?id=124769
3577
3578         Reviewed by Andreas Kling.
3579
3580         Test: fast/gradients/crash-on-no-position-separator.html
3581
3582         The function parseFillPosition() may not return valid values for
3583         centerX and centerY if the input data is malformed. We need to
3584         check that we get a valid pair of positions before checking that
3585         they're actually valid primitive values in the assertions.
3586
3587         * css/CSSParser.cpp:
3588         (WebCore::CSSParser::parseRadialGradient):
3589
3590 2014-01-20  Mihai Tica  <mitica@adobe.com>
3591
3592         Background-blend-mode doesn't work for an element with an
3593         SVG image as background and border-style or padding set.
3594         The problem consisted in the drawing path using the default
3595         blending parameter at all times.
3596         https://bugs.webkit.org/show_bug.cgi?id=118894
3597
3598         Reviewed by Dirk Schulze.
3599
3600         Test: css3/compositing/background-blend-mode-data-uri-svg-image.html
3601
3602         * svg/graphics/SVGImage.cpp:
3603         (WebCore::SVGImage::drawPatternForContainer): Pass blendMode to Image::drawPattern.
3604         * svg/graphics/SVGImage.h: Add a blendMode parameter to drawPatternForContainer.
3605         * svg/graphics/SVGImageForContainer.cpp:
3606         (WebCore::SVGImageForContainer::drawPattern): Pass blendMode to drawPatternForContainer call.
3607
3608 2014-01-20  Zalan Bujtas  <zalan@apple.com>
3609
3610         Subpixel layout: setSimpleLineLayoutEnabled() produces different layout when line position has CSS px fractions.
3611         https://bugs.webkit.org/show_bug.cgi?id=126892
3612
3613         Reviewed by Antti Koivisto.
3614
3615         SimpleLineLayout needs to copy normal linebox layout's subpixel rounding strategy to produce
3616         the same layout.
3617
3618         Covered by existing tests.
3619
3620         * rendering/SimpleLineLayoutFunctions.cpp:
3621         (WebCore::SimpleLineLayout::paintFlow):
3622
3623 2014-01-20  Gurpreet Kaur  <k.gurpreet@samsung.com>
3624
3625         Col width is not honored when dynamically updated and it would make table narrower
3626         https://bugs.webkit.org/show_bug.cgi?id=104711
3627
3628         Reviewed by Antti Koivisto.
3629
3630         Increasing the table width by increasing the colgroup width
3631         was working but decreasing the table width by decreasing the
3632         colgroup width is not working.
3633
3634         Test: fast/dom/HTMLTableColElement/resize-table-width-using-col-width.html
3635
3636         * rendering/RenderTableCol.cpp:
3637         (WebCore::RenderTableCol::styleDidChange):
3638         When colgroup width is defined table cell should adjust according to
3639         that. On decreasing colgroup width the cells maxPreferredLogicalWidth
3640         was still set to the earlier value. Setting the
3641         setPreferredLogicalWidthsDirty to true so that cells pref width is
3642         calculated again.
3643
3644 2014-01-20  Edit Balint  <edbalint@inf.u-szeged.hu>
3645
3646         [CoordinatedGraphics] Segmentation fault at  CoordinatedGraphicsScene::clearImageBackingContents
3647
3648         https://bugs.webkit.org/show_bug.cgi?id=125776
3649
3650         Reviewed by Csaba Osztrogonác.
3651
3652         Unexpected behavior occurs in some test cases which leads to segmentation fault.
3653
3654         * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
3655         (WebCore::CompositingCoordinator::removeImageBacking):
3656
3657 2014-01-20  Morten Stenshorne  <mstensho@opera.com>
3658
3659         Region based multicol: tall line causes taller multicol container than necessary
3660         https://bugs.webkit.org/show_bug.cgi?id=122550
3661
3662         Detect and report all column breaks, also when there's no pagination strut involved.
3663
3664         This may end up becoming the overall smallest space shortage in some cases,
3665         so we need to report it, to avoid column height over-stretching.
3666
3667         Reviewed by David Hyatt.
3668
3669         Test: fast/multicol/newmulticol/balance10.html
3670
3671         * rendering/RenderBlockFlow.cpp:
3672         (WebCore::RenderBlockFlow::adjustLinePositionForPagination):
3673
3674 2014-01-19  Carlos Garcia Campos  <cgarcia@igalia.com>
3675
3676         [GLIB] GVariant floating references are not correctly handled by GRefPtr
3677         https://bugs.webkit.org/show_bug.cgi?id=127246
3678
3679         Reviewed by Martin Robinson.
3680
3681         Do not adopt GVariant floating references, they will be converted
3682         to a full reference by GRefPtr.
3683
3684         * platform/gtk/PasteboardHelper.cpp:
3685         (WebCore::PasteboardHelper::fillSelectionData):
3686         (WebCore::PasteboardHelper::fillDataObjectFromDropData):
3687
3688 2014-01-19  Jinwoo Song  <jinwoo7.song@samsung.com>
3689
3690         Use unsigned type for the size of CSSParserValueList
3691         https://bugs.webkit.org/show_bug.cgi?id=127211
3692
3693         Reviewed by Andreas Kling.
3694
3695         * css/CSSParser.cpp: Changed variable type from int to unsigned.
3696         (WebCore::CSSParser::parseValue):
3697
3698 2014-01-19  Jaehun Lim  <ljaehun.lim@samsung.com>
3699
3700         Unreviewed build fix after r162293
3701
3702         Fix debug build.
3703
3704         [ 13%] Building CXX object Source/WebCore/CMakeFiles/WebCore.dir/html/parser/HTMLTreeBuilder.cpp.o
3705         /source/WebKit/Source/WebCore/html/parser/HTMLTreeBuilder.cpp: In member function ‘void WebCore::HTMLTreeBuilder::processStartTagForInTable(WebCore::AtomicHTMLToken*)’:
3706         /source/WebKit/Source/WebCore/html/parser/HTMLTreeBuilder.cpp:1037:40: error: no match for ‘operator!’ in ‘!(WebCore::HTMLTreeBuilder::InsertionMode)12’
3707         /source/WebKit/Source/WebCore/html/parser/HTMLTreeBuilder.cpp:1037:40: note: candidate is:
3708         /source/WebKit/Source/WebCore/html/parser/HTMLTreeBuilder.cpp:1037:40: note: operator!(bool) <built-in>
3709         /source/WebKit/Source/WebCore/html/parser/HTMLTreeBuilder.cpp:1037:40: note:   no known conversion for argument 1 from ‘WebCore::HTMLTreeBuilder::InsertionMode’ to ‘bool’
3710         make[2]: *** [Source/WebCore/CMakeFiles/WebCore.dir/html/parser/HTMLTreeBuilder.cpp.o] Error 1
3711         make[1]: *** [Source/WebCore/CMakeFiles/WebCore.dir/all] Error 2
3712         make: *** [all] Error 2
3713
3714         * html/parser/HTMLTreeBuilder.cpp:
3715         (WebCore::HTMLTreeBuilder::processStartTagForInTable): Fix ASSERT.
3716
3717 2014-01-19  Anders Carlsson  <andersca@apple.com>
3718
3719         Stop using MutexTryLocker in WebCore
3720         https://bugs.webkit.org/show_bug.cgi?id=127254
3721
3722         Reviewed by Andreas Kling.
3723
3724         Instead use std::mutex and std::unique_lock with the std::try_to_lock constructor.
3725
3726         * Modules/webaudio/AudioBufferSourceNode.cpp:
3727         (WebCore::AudioBufferSourceNode::process):
3728         (WebCore::AudioBufferSourceNode::setBuffer):
3729         * Modules/webaudio/AudioBufferSourceNode.h:
3730         * Modules/webaudio/AudioParamTimeline.cpp:
3731         (WebCore::AudioParamTimeline::insertEvent):
3732         (WebCore::AudioParamTimeline::cancelScheduledValues):
3733         (WebCore::AudioParamTimeline::valueForContextTime):
3734         (WebCore::AudioParamTimeline::valuesForTimeRange):
3735         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
3736         * Modules/webaudio/AudioParamTimeline.h:
3737         * Modules/webaudio/ConvolverNode.cpp:
3738         (WebCore::ConvolverNode::process):
3739         (WebCore::ConvolverNode::reset):
3740         (WebCore::ConvolverNode::setBuffer):
3741         * Modules/webaudio/ConvolverNode.h:
3742         * Modules/webaudio/MediaElementAudioSourceNode.cpp:
3743         (WebCore::MediaElementAudioSourceNode::setFormat):
3744         (WebCore::MediaElementAudioSourceNode::process):
3745         (WebCore::MediaElementAudioSourceNode::lock):
3746         (WebCore::MediaElementAudioSourceNode::unlock):
3747         * Modules/webaudio/MediaElementAudioSourceNode.h:
3748         * Modules/webaudio/MediaStreamAudioSourceNode.cpp:
3749         (WebCore::MediaStreamAudioSourceNode::setFormat):
3750         (WebCore::MediaStreamAudioSourceNode::process):
3751         * Modules/webaudio/MediaStreamAudioSourceNode.h:
3752         * Modules/webaudio/OscillatorNode.cpp:
3753         (WebCore::OscillatorNode::process):
3754         (WebCore::OscillatorNode::setPeriodicWave):
3755         * Modules/webaudio/OscillatorNode.h:
3756         * Modules/webaudio/PannerNode.cpp:
3757         (WebCore::PannerNode::process):
3758         (WebCore::PannerNode::setPanningModel):
3759         * Modules/webaudio/PannerNode.h:
3760         * Modules/webaudio/WaveShaperProcessor.cpp:
3761         (WebCore::WaveShaperProcessor::setCurve):
3762         (WebCore::WaveShaperProcessor::setOversample):
3763         (WebCore::WaveShaperProcessor::process):
3764         * Modules/webaudio/WaveShaperProcessor.h:
3765
3766 2014-01-19  Alberto Garcia  <berto@igalia.com>
3767
3768         Does not build with SVG disabled
3769         https://bugs.webkit.org/show_bug.cgi?id=127248
3770
3771         Reviewed by Sam Weinig.
3772
3773         Add missing #if ENABLE(SVG) guard.
3774
3775         * dom/ElementData.h:
3776
3777 2014-01-19  Anders Carlsson  <andersca@apple.com>
3778
3779         Use a strong enum for HTMLTreeBuilder::InsertionMode
3780         https://bugs.webkit.org/show_bug.cgi?id=127252
3781
3782         Reviewed by Antti Koivisto.
3783
3784         * html/parser/HTMLTreeBuilder.cpp:
3785         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
3786         (WebCore::HTMLTreeBuilder::constructTree):
3787         (WebCore::HTMLTreeBuilder::processDoctypeToken):
3788         (WebCore::HTMLTreeBuilder::processStartTagForInBody):
3789         (WebCore::HTMLTreeBuilder::processTemplateStartTag):
3790         (WebCore::HTMLTreeBuilder::processColgroupEndTagForInColumnGroup):
3791         (WebCore::HTMLTreeBuilder::closeTheCell):
3792         (WebCore::HTMLTreeBuilder::processStartTagForInTable):
3793         (WebCore::HTMLTreeBuilder::processStartTag):
3794         (WebCore::HTMLTreeBuilder::processBodyEndTagForInBody):
3795         (WebCore::HTMLTreeBuilder::resetInsertionModeAppropriately):
3796         (WebCore::HTMLTreeBuilder::processEndTagForInTableBody):
3797         (WebCore::HTMLTreeBuilder::processEndTagForInRow):
3798         (WebCore::HTMLTreeBuilder::processEndTagForInCell):
3799         (WebCore::HTMLTreeBuilder::processCaptionEndTagForInCaption):
3800         (WebCore::HTMLTreeBuilder::processTrEndTagForInRow):
3801         (WebCore::HTMLTreeBuilder::processEndTag):
3802         (WebCore::HTMLTreeBuilder::processComment):
3803         (WebCore::HTMLTreeBuilder::processCharacterBuffer):
3804         (WebCore::HTMLTreeBuilder::processEndOfFile):
3805         (WebCore::HTMLTreeBuilder::defaultForInitial):
3806         (WebCore::HTMLTreeBuilder::defaultForBeforeHTML):
3807         (WebCore::HTMLTreeBuilder::processStartTagForInHead):
3808         (WebCore::HTMLTreeBuilder::processGenericRCDATAStartTag):
3809         (WebCore::HTMLTreeBuilder::processGenericRawTextStartTag):
3810         (WebCore::HTMLTreeBuilder::processScriptStartTag):
3811         * html/parser/HTMLTreeBuilder.h:
3812
3813 2014-01-19  Anders Carlsson  <andersca@apple.com>
3814
3815         Convert LoaderRunLoopCF.cpp and WebCoreThreadRun.cpp over to modern threading primitives
3816         https://bugs.webkit.org/show_bug.cgi?id=127251
3817
3818         Reviewed by Antti Koivisto.
3819
3820         Also add a condition to the loaderRunLoop() function to protect against spurious wake-ups.
3821
3822         * platform/ios/wak/WebCoreThreadRun.cpp:
3823         * platform/network/cf/LoaderRunLoopCF.cpp:
3824         (WebCore::loaderRunLoopMutex):
3825         (WebCore::loaderRunLoopConditionVariable):
3826         (WebCore::runLoaderThread):
3827         (WebCore::loaderRunLoop):
3828
3829 2014-01-19  Anders Carlsson  <andersca@apple.com>
3830
3831         Modernize ReverbConvolver
3832         https://bugs.webkit.org/show_bug.cgi?id=127250
3833
3834         Reviewed by Andreas Kling.
3835
3836         Use std::unique_ptr instead of OwnPtr and the STL threading primitives instead of the WTF ones.
3837
3838         * platform/audio/ReverbConvolver.cpp:
3839         (WebCore::ReverbConvolver::ReverbConvolver):
3840         (WebCore::ReverbConvolver::~ReverbConvolver):
3841         (WebCore::ReverbConvolver::backgroundThreadEntry):
3842         (WebCore::ReverbConvolver::process):
3843         * platform/audio/ReverbConvolver.h:
3844
3845 2014-01-18  Andy Estes  <aestes@apple.com>
3846
3847         [iOS] Rename GestureEventIOS.{cpp,h} to GestureEvent.{cpp,h} to fix the build
3848
3849         InFilesCompiler.pm assumes that <interface name>.h exists for each
3850         interface it processes. We renamed GestureEvent.h to GestureEventIOS.h
3851         but kept the interface named GestureEvent, so a non-existant file was
3852         being referenced by InFilesCompiler.pm (this was hard to detect since
3853         GestureEvent.h still existed in the SDK due to not having submitted
3854         WebKitAdditions recently).
3855
3856         Since we cannot rename the GestureEvent interface, and since there is
3857         no conflicting GestureEvent in open source, we can just rename
3858         GestureEventIOS.{cpp,h} back to GestureEvent.{cpp,h}.
3859
3860         * dom/ios/TouchEvents.cpp: Updated to include GestureEvent.cpp.
3861
3862 2014-01-18  Alexey Proskuryakov  <ap@apple.com>
3863
3864         Memory leak in JSSubtleCrypto::wrapKey
3865         https://bugs.webkit.org/show_bug.cgi?id=127241
3866
3867         Reviewed by Sam Weinig.
3868
3869         * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::JSSubtleCrypto::wrapKey):
3870         Delete algorithmPtr and parametersPtr that aren't smart pointers because of lambdas.
3871
3872 2014-01-18  Andy Estes  <aestes@apple.com>
3873
3874         Fix the iOS Production build.
3875
3876         * Configurations/WebCore.xcconfig:
3877
3878 2014-01-18  Alberto Garcia  <berto@igalia.com>
3879
3880         [CodeGeneratorJS] Sort output of StructureFlags and function parameters
3881
3882         https://bugs.webkit.org/show_bug.cgi?id=127226
3883
3884         Reviewed by Alexey Proskuryakov.
3885
3886         The order of the keys in a hash is undefined and subject to change
3887         between different Perl versions, so we have to sort them to make
3888         sure that the output is always the same.
3889
3890         * bindings/scripts/CodeGeneratorJS.pm:
3891         (GenerateHeader):
3892         (GenerateParametersCheckExpression):
3893         * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
3894         * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
3895         * bindings/scripts/test/JS/JSTestEventConstructor.h:
3896         * bindings/scripts/test/JS/JSTestEventTarget.h:
3897         * bindings/scripts/test/JS/JSTestException.h:
3898         * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
3899         * bindings/scripts/test/JS/JSTestInterface.h:
3900         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
3901         * bindings/scripts/test/JS/JSTestNamedConstructor.h:
3902         * bindings/scripts/test/JS/JSTestNode.h:
3903         * bindings/scripts/test/JS/JSTestObj.cpp:
3904         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
3905         * bindings/scripts/test/JS/JSTestObj.h:
3906         * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
3907         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
3908         * bindings/scripts/test/JS/JSTestTypedefs.h:
3909         * bindings/scripts/test/JS/JSattribute.h:
3910         * bindings/scripts/test/JS/JSreadonly.h:
3911
3912 2014-01-18  Anders Carlsson  <andersca@apple.com>
3913
3914         Replace a couple of uses of WTF::Function with std::function
3915         https://bugs.webkit.org/show_bug.cgi?id=127218
3916
3917         Reviewed by Andreas Kling.
3918
3919         * WebCore.exp.in:
3920         * page/scrolling/ScrollingThread.cpp:
3921         (WebCore::ScrollingThread::dispatch):
3922         (WebCore::ScrollingThread::dispatchBarrier):
3923         (WebCore::ScrollingThread::shared):
3924         (WebCore::ScrollingThread::createThreadIfNeeded):
3925         (WebCore::ScrollingThread::dispatchFunctionsFromScrollingThread):
3926         * page/scrolling/ScrollingThread.h:
3927         * page/scrolling/mac/ScrollingThreadMac.mm:
3928         (WebCore::ScrollingThread::initializeRunLoop):
3929
3930 2014-01-18  Anders Carlsson  <andersca@apple.com>
3931
3932         Modernize HTML parser code
3933         https://bugs.webkit.org/show_bug.cgi?id=127236
3934
3935         Reviewed by Andreas Kling.
3936
3937         * html/parser/AtomicHTMLToken.h:
3938         * html/parser/CSSPreloadScanner.cpp:
3939         (WebCore::CSSPreloadScanner::emitRule):
3940         * html/parser/HTMLDocumentParser.cpp:
3941         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
3942         (WebCore::HTMLDocumentParser::detach):
3943         (WebCore::HTMLDocumentParser::stopParsing):
3944         (WebCore::HTMLDocumentParser::pumpTokenizer):
3945         (WebCore::HTMLDocumentParser::insert):
3946         (WebCore::HTMLDocumentParser::append):
3947         (WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution):
3948         * html/parser/HTMLDocumentParser.h:
3949         * html/parser/HTMLElementStack.cpp:
3950         (WebCore::HTMLElementStack::ElementRecord::ElementRecord):
3951         (WebCore::HTMLElementStack::insertAbove):
3952         (WebCore::HTMLElementStack::pushCommon):
3953         * html/parser/HTMLElementStack.h:
3954         (WebCore::HTMLElementStack::ElementRecord::releaseNext):
3955         (WebCore::HTMLElementStack::ElementRecord::setNext):
3956         * html/parser/HTMLMetaCharsetParser.cpp:
3957         (WebCore::HTMLMetaCharsetParser::HTMLMetaCharsetParser):
3958         * html/parser/HTMLMetaCharsetParser.h:
3959         * html/parser/HTMLParserScheduler.h:
3960         * html/parser/HTMLPreloadScanner.cpp:
3961         (WebCore::TokenPreloadScanner::StartTagScanner::createPreloadRequest):
3962         (WebCore::TokenPreloadScanner::scan):
3963         (WebCore::HTMLPreloadScanner::HTMLPreloadScanner):
3964         * html/parser/HTMLPreloadScanner.h:
3965         * html/parser/HTMLResourcePreloader.cpp:
3966         (WebCore::HTMLResourcePreloader::takeAndPreload):
3967         (WebCore::HTMLResourcePreloader::preload):
3968         * html/parser/HTMLResourcePreloader.h:
3969         (WebCore::PreloadRequest::PreloadRequest):
3970         * html/parser/HTMLScriptRunner.h:
3971         * html/parser/HTMLToken.h:
3972         (WebCore::HTMLToken::beginDOCTYPE):
3973         (WebCore::HTMLToken::releaseDoctypeData):
3974         * html/parser/HTMLTokenizer.h:
3975         * html/parser/HTMLTreeBuilder.h:
3976         * html/parser/HTMLViewSourceParser.cpp:
3977         (WebCore::HTMLViewSourceParser::HTMLViewSourceParser):
3978         * html/parser/HTMLViewSourceParser.h:
3979         * html/parser/XSSAuditor.cpp:
3980         (WebCore::XSSAuditor::init):
3981         (WebCore::XSSAuditor::filterToken):
3982         * html/parser/XSSAuditor.h:
3983         * html/parser/XSSAuditorDelegate.h:
3984         (WebCore::XSSInfo::XSSInfo):
3985         * loader/TextResourceDecoder.cpp:
3986         (WebCore::TextResourceDecoder::checkForHeadCharset):
3987         (WebCore::TextResourceDecoder::checkForMetaCharset):
3988         * loader/TextResourceDecoder.h:
3989
3990 2014-01-18  Benjamin Poulain  <benjamin@webkit.org>
3991
3992         Make ElementData JIT friendly
3993         https://bugs.webkit.org/show_bug.cgi?id=127209
3994
3995         Reviewed by Geoffrey Garen.
3996
3997         The offsets of ElementData's flags were not accessible by the JIT. This patch
3998         refactor ElementData to use explicit flags so that they can be used from
3999         the code generators.
4000
4001         * dom/Element.cpp:
4002         (WebCore::Element::synchronizeAllAttributes):
4003         (WebCore::Element::synchronizeAttribute):
4004         (WebCore::Element::attributeChanged):
4005         (WebCore::Element::removeAttribute):
4006         * dom/ElementData.cpp:
4007         (WebCore::ElementData::destroy):
4008         (WebCore::ElementData::ElementData):
4009         (WebCore::ShareableElementData::ShareableElementData):
4010         (WebCore::ShareableElementData::~ShareableElementData):
4011         (WebCore::ElementData::arraySizeAndFlagsFromOther):
4012         * dom/ElementData.h:
4013         (WebCore::ElementData::hasName):
4014         (WebCore::ElementData::isUnique):
4015         (WebCore::ElementData::updateFlag):
4016         (WebCore::ElementData::arraySize):
4017         (WebCore::ElementData::setHasNameAttribute):
4018         (WebCore::ElementData::styleAttributeIsDirty):
4019         (WebCore::ElementData::setStyleAttributeIsDirty):
4020         (WebCore::ElementData::presentationAttributeStyleIsDirty):
4021         (WebCore::ElementData::setPresentationAttributeStyleIsDirty):
4022         (WebCore::ElementData::animatedSVGAttributesAreDirty):
4023         (WebCore::ElementData::setAnimatedSVGAttributesAreDirty):
4024         (WebCore::ElementData::length):
4025         (WebCore::ElementData::attributeBase):
4026         (WebCore::ElementData::presentationAttributeStyle):
4027         * dom/StyledElement.cpp:
4028         (WebCore::StyledElement::synchronizeStyleAttributeInternal):
4029         (WebCore::StyledElement::attributeChanged):
4030         (WebCore::StyledElement::styleAttributeChanged):
4031         (WebCore::StyledElement::inlineStyleChanged):
4032         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
4033         * dom/StyledElement.h:
4034         (WebCore::StyledElement::invalidateStyleAttribute):
4035         (WebCore::StyledElement::presentationAttributeStyle):
4036         * svg/SVGElement.cpp:
4037         (WebCore::SVGElement::synchronizeAnimatedSVGAttribute):
4038         * svg/SVGElement.h:
4039         (WebCore::SVGElement::invalidateSVGAttributes):
4040
4041 2014-01-18  Zalan Bujtas  <zalan@apple.com>
4042
4043         Subpixel layout: IntRect::infiniteRect() overflows when subpixel layout is enabled.
4044         https://bugs.webkit.org/show_bug.cgi?id=126899
4045
4046         Reviewed by Tim Horton.
4047
4048         Use LayoutUnits when setting the infinite values on IntRect::infiniteRect() to ensure