Atomicize frequently identical ResourceResponse string members.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-02-16  Andreas Kling  <akling@apple.com>
2
3         Atomicize frequently identical ResourceResponse string members.
4         <https://webkit.org/b/128887>
5
6         Store the mime type, text encoding and HTTP response status text in
7         AtomicStrings instead of Strings to deduplicate frequently occurring
8         values (e.g "text/html", "utf-8" and "OK".)
9
10         Reviewed by Geoffrey Garen.
11
12         * platform/network/ResourceResponseBase.h:
13         * platform/network/cf/ResourceResponseCFNet.cpp:
14         (WebCore::ResourceResponse::cfURLResponse):
15         (WebCore::ResourceResponse::platformLazyInit):
16         * platform/network/mac/ResourceResponseMac.mm:
17         (WebCore::ResourceResponse::platformLazyInit):
18
19 2014-02-16  Dan Bernstein  <mitz@apple.com>
20
21         Speculative iOS build fix.
22
23         * dom/Document.cpp:
24         (WebCore::Document::Document):
25
26 2014-02-15  Antti Koivisto  <antti@apple.com>
27
28         Move document life time management from TreeScope to Document
29         https://bugs.webkit.org/show_bug.cgi?id=128877
30
31         Reviewed by Andreas Kling.
32
33         Document life time is managed in confusing manner by TreeScopes which are also inherited to ShadowRoots.
34         
35         This patches moves the life time management to Document. Nodes in shadow trees selfOnlyRef the Document instead
36         of the ShadowRoot. ShadowRoot is treated like any other node and selfOnlyRefs the Document as well (which it
37         also did earlier, indirectly).
38         
39         TreeScope is devirtualized.
40
41         * css/ElementRuleCollector.cpp:
42         (WebCore::ElementRuleCollector::collectMatchingRules):
43         
44             Author stylesheets never match in UA shadow trees.
45
46         * dom/ContainerNode.cpp:
47         (WebCore::ContainerNode::~ContainerNode):
48         * dom/Document.cpp:
49         (WebCore::Document::Document):
50         (WebCore::Document::~Document):
51         (WebCore::Document::removedLastRef):
52         * dom/Document.h:
53         (WebCore::Document::selfOnlyRef):
54         (WebCore::Document::selfOnlyDeref):
55
56             To avoid branches Document self-refs itself like all other Nodes. This is why deletion will now happen on ref count of 1.
57
58         (WebCore::Node::isDocumentNode):
59         (WebCore::Node::Node):
60         * dom/DocumentOrderedMap.cpp:
61         (WebCore::DocumentOrderedMap::add):
62         * dom/Element.cpp:
63         (WebCore::Element::insertedInto):
64         (WebCore::Element::removedFrom):
65         * dom/Node.cpp:
66         (WebCore::Node::~Node):
67         (WebCore::Node::removedLastRef):
68         * dom/Node.h:
69         (WebCore::Node::document):
70         (WebCore::Node::inDocument):
71         * dom/ShadowRoot.cpp:
72         (WebCore::ShadowRoot::ShadowRoot):
73         (WebCore::ShadowRoot::~ShadowRoot):
74         * dom/ShadowRoot.h:
75         * dom/TreeScope.cpp:
76         (WebCore::TreeScope::TreeScope):
77         (WebCore::TreeScope::~TreeScope):
78         (WebCore::TreeScope::setParentTreeScope):
79         * dom/TreeScope.h:
80         (WebCore::TreeScope::documentScope):
81         
82             Document can no longer ever be null.
83
84         (WebCore::TreeScope::rootNode):
85         (WebCore::TreeScope::setDocumentScope):
86         * dom/TreeScopeAdopter.cpp:
87         (WebCore::TreeScopeAdopter::moveTreeToNewScope):
88         (WebCore::TreeScopeAdopter::moveShadowTreeToNewDocument):
89         
90             Manage Document selfOnlyRefs for nodes in shadow trees too.
91
92         (WebCore::TreeScopeAdopter::updateTreeScope):
93         (WebCore::TreeScopeAdopter::moveNodeToNewDocument):
94         * dom/TreeScopeAdopter.h:
95
96 2014-02-16  Ryosuke Niwa  <rniwa@webkit.org>
97
98         setSelectionRange shouldn't directly instantiate VisibleSelection
99         https://bugs.webkit.org/show_bug.cgi?id=128881
100
101         Reviewed by Andreas Kling.
102
103         Added a new version of moveTo for setSelectionRange.
104
105         * editing/FrameSelection.cpp:
106         (WebCore::FrameSelection::moveTo): Added.
107         * editing/FrameSelection.h:
108         * html/HTMLTextFormControlElement.cpp:
109         (WebCore::HTMLTextFormControlElement::setSelectionRange): Use the newly added FrameSelection::moveTo
110         instead of manually instantiating VisibleSelection here.
111
112 2014-02-16  Dan Bernstein  <mitz@apple.com>
113
114         Stop using PLATFORM(MAC) in Source except where it means “OS X but not iOS”
115         https://bugs.webkit.org/show_bug.cgi?id=128885
116
117         Reviewed by Anders Carlsson.
118
119         * loader/FrameLoaderClient.h: Changed PLATFORM(MAC) to PLATFORM(COCOA).
120         * platform/Cursor.h: Changed PLATFORM(MAC) to USE(APPKIT) around uses of NSCursor.
121         * platform/LocalizedStrings.cpp: Changed PLATFORM(MAC) to PLATFORM(COCOA).
122         * platform/graphics/PlatformLayer.h: Ditto.
123         * platform/graphics/cg/PDFDocumentImage.cpp: Ditto.
124         * rendering/RenderLayerCompositor.cpp: Ditto.
125         (WebCore::RenderLayerCompositor::requiresContentShadowLayer):
126         (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
127
128 2014-02-16  Dan Bernstein  <mitz@apple.com>
129
130         Speculative iOS build fix after r164184.
131
132         * dom/Node.cpp:
133         (WebCore::Node::defaultEventHandler):
134
135 2014-02-15  Ryosuke Niwa  <rniwa@webkit.org>
136
137         DOMSelection shouldn't instantiate VisibleSelection everywhere
138         https://bugs.webkit.org/show_bug.cgi?id=128879
139
140         Reviewed by Antti Koivisto.
141
142         Removed explicit instantiation of VisibleSelection from various member functions of VisibleSelection.
143
144         * page/DOMSelection.cpp:
145         (WebCore::DOMSelection::collapse):
146         (WebCore::DOMSelection::collapseToEnd):
147         (WebCore::DOMSelection::collapseToStart):
148         (WebCore::DOMSelection::setBaseAndExtent):
149         (WebCore::DOMSelection::setPosition):
150         (WebCore::DOMSelection::extend):
151         (WebCore::DOMSelection::getRangeAt):
152         (WebCore::DOMSelection::addRange):
153
154 2014-02-15  Ryosuke Niwa  <rniwa@webkit.org>
155
156         Remove unused arguments from moveTo(Range*)
157         https://bugs.webkit.org/show_bug.cgi?id=128878
158
159         Reviewed by Antti Koivisto.
160
161         Cleanup.
162
163         * bindings/objc/DOMUIKitExtensions.mm:
164         (-[DOMRange move:inDirection:]):
165         (-[DOMRange extend:inDirection:]):
166         * editing/FrameSelection.cpp:
167         (WebCore::FrameSelection::moveTo):
168         * editing/FrameSelection.h:
169
170 2014-02-15  Filip Pizlo  <fpizlo@apple.com>
171
172         Vector with inline capacity should work with non-PODs
173         https://bugs.webkit.org/show_bug.cgi?id=128864
174
175         Reviewed by Michael Saboff.
176
177         No new tests because no change behavior.
178         
179         Deques no longer have inline capacity because it was broken, and we didn't need it
180         here anyway.
181
182         * page/WheelEventDeltaTracker.h:
183
184 2014-02-15  Andreas Kling  <akling@apple.com>
185
186         Add checked casts for Event.
187         <https://webkit.org/b/128875>
188
189         Generate casting helpers for casting from Event to various subclasses
190         and go on static_cast replacement spree.
191
192         Reviewed by Sam Weinig.
193
194 2014-02-15  Ryosuke Niwa  <rniwa@webkit.org>
195
196         HTMLTextFormControlElement::subtreeHasChanged should be called before updating selection
197         https://bugs.webkit.org/show_bug.cgi?id=128870
198
199         Reviewed by Darin Adler.
200
201         Extracted HTMLTextFormControlElement::didEditInnerTextValue out of HTMLTextFormControlElement::defaultEventHandler
202         and called it in appliedEditing, unappliedEditing, and reappliedEditing before updating selection.
203
204         * editing/Editor.cpp:
205         (WebCore::notifyTextFromControls): Added.
206         (WebCore::Editor::appliedEditing): Update text form control's internal states before updating selection.
207         (WebCore::Editor::unappliedEditing): Ditto.
208         (WebCore::Editor::reappliedEditing): Ditto.
209         * html/HTMLTextFormControlElement.cpp:
210         (WebCore::HTMLTextFormControlElement::didEditInnerTextValue):
211         * html/TextFieldInputType.cpp:
212         (WebCore::TextFieldInputType::subtreeHasChanged): Removed a stale assertion from the time we used to do
213         everything in the render tree.
214
215 2014-02-15  Andreas Kling  <akling@apple.com>
216
217         Add checked casts for ScriptExecutionContext.
218         <https://webkit.org/b/128874>
219
220         Generate casting helpers for casting from ScriptExecutionContext to
221         Document and WorkerGlobalScope. Apply heartily.
222
223         Reviewed by Antti Koivisto.
224
225 2014-02-15  Alexey Proskuryakov  <ap@apple.com>
226
227         [Mac] All WebKit clients should encrypt WebCrypto keys automatically
228         https://bugs.webkit.org/show_bug.cgi?id=128852
229
230         Reviewed by Oliver Hunt.
231
232         Install a persistent master key in Keychain on first use of WebCrypto key serialization.
233         The key is per application, protected with ACL.
234
235         * English.lproj/Localizable.strings:
236         * WebCore.exp.in:
237         * crypto/SerializedCryptoKeyWrap.h:
238         * crypto/mac/SerializedCryptoKeyWrapMac.mm:
239         (WebCore::masterKeyAccountNameForCurrentApplication):
240         (WebCore::getDefaultWebCryptoMasterKey):
241         (WebCore::createAndStoreMasterKey):
242         (WebCore::findMasterKey):
243         * platform/LocalizedStrings.cpp:
244         (WebCore::webCryptoMasterKeyKeychainLabel):
245         (WebCore::webCryptoMasterKeyKeychainComment):
246         * platform/LocalizedStrings.h:
247
248 2014-02-15  Ryosuke Niwa  <rniwa@webkit.org>
249
250         computeSelectionStart and computeSelectionEnd shouldn't trigger synchronous layout
251         https://bugs.webkit.org/show_bug.cgi?id=128806
252
253         Reviewed by Darin Adler.
254
255         Added indexForPosition to HTMLTextFormControlElement. Like r163825, this patch traverses the DOM tree
256         instead of the render tree to compute the index for a given position.
257
258         We traverse the DOM Tree backwards starting at the specified Position all the way back to the beginning
259         of the inner text element. The index is computed as the number of characters we encountered during
260         this backwards DOM traversal.
261
262         It's worth noting that passedPosition.computeNodeBeforePosition() returns and only returns 0 when the
263         position is before the first node of its parent or inside a text node. In such cases, we call
264         passedPosition.containerNode() to find the parent or the text node.
265
266         * html/HTMLTextFormControlElement.cpp:
267         (WebCore::HTMLTextFormControlElement::indexForVisiblePosition): Use indexForPosition.
268         (WebCore::HTMLTextFormControlElement::computeSelectionStart): Ditto.
269         (WebCore::HTMLTextFormControlElement::computeSelectionEnd): Dotto.
270         (WebCore::finishText): Cleanup. Use newlineCharacter instead of hard-coding '\n'.
271         (WebCore::HTMLTextFormControlElement::indexForPosition): Added. See above for the description.
272         * html/HTMLTextFormControlElement.h:
273
274 2014-02-15  Brent Fulgham  <bfulgham@apple.com>
275
276         [Win] Avoid unnecessary asserts if "prepareToPlay" is called multiple times.
277         https://bugs.webkit.org/show_bug.cgi?id=128859
278
279         Reviewed by Eric Carlson.
280
281         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
282         (WebCore::AVFWrapper::createPlayer): Don't assert if player exists; just return the
283         existing copy.
284         (WebCore::AVFWrapper::createPlayerItem): Ditto (but with Player Items).
285
286 2014-02-15  Darin Adler  <darin@apple.com>
287
288         Remove double hashing from DatasetDOMStringMap::deleteItem
289         https://bugs.webkit.org/show_bug.cgi?id=128865
290
291         Reviewed by Benjamin Poulain.
292
293         * dom/DatasetDOMStringMap.cpp:
294         (WebCore::DatasetDOMStringMap::deleteItem): Removed call to hasAttribute, using the
295         result from removeAttribute instead.
296
297         * dom/Element.cpp:
298         (WebCore::Element::removeAttribute): Add a return value, false if nothing is removed,
299         and true if something is removed.
300         (WebCore::Element::removeAttributeNS): Ditto.
301         * dom/Element.h: Ditto.
302
303 2014-02-15  Piotr Grad  <p.grad@samsung.com>
304
305         Setting currentTime on HTMLMediaElement with media controller should throw exception.
306         https://bugs.webkit.org/show_bug.cgi?id=128867.
307
308         Reviewed by Eric Carlson.
309
310         Added implementation for setting currentTime in HTMLMediaElement. Old implementation
311         was left to be used internally.
312
313         Test: media/video-controller-currentTime.html
314
315         * html/HTMLMediaElement.cpp:
316         (WebCore::HTMLMediaElement::parseAttribute):
317         * html/HTMLMediaElement.h:
318         * html/HTMLMediaElement.idl:
319
320 2014-02-15  Anders Carlsson  <andersca@apple.com>
321
322         Form controls are always painted in the active state
323         https://bugs.webkit.org/show_bug.cgi?id=128872
324         <rdar://problem/9422677>
325
326         Reviewed by Dan Bernstein.
327
328         AppKit will always paint form controls in the active state if the view doesn't have a
329         window. Fix this by adding a fake window whose key appearance we'll update based on the 
330         control state. Also, rename WebCoreFlippedView to WebCoreThemeView since it stopped being
331         just about the flippedness a long time ago.
332
333         * platform/mac/ThemeMac.h:
334         * platform/mac/ThemeMac.mm:
335         (-[WebCoreThemeWindow hasKeyAppearance]):
336         Return themeWindowHasKeyAppearance.
337
338         (-[WebCoreThemeView window]):
339         Create a WebCoreThemeWindow object lazily and return it.
340
341         (WebCore::paintCheckbox):
342         (WebCore::paintRadio):
343         (WebCore::paintButton):
344         Pass the control states to ThemeMac::ensuredView.
345
346         (WebCore::ThemeMac::ensuredView):
347         Set themeWindowHasKeyAppearance based on the control state.
348
349         * rendering/RenderThemeMac.mm:
350         (WebCore::RenderThemeMac::documentViewFor):
351         Pass the control states to ThemeMac::ensuredView.
352
353 2014-02-15  Renata Hodovan  <rhodovan.u-szeged@partner.samsung.com>
354
355         ASSERT_WITH_SECURITY_IMPLICATION in WebCore::toElement
356         https://bugs.webkit.org/show_bug.cgi?id=128810
357
358         Reviewed by Ryosuke Niwa.
359
360         Make CompositeEditCommand::cloneParagraphUnderNewElement() to work when |outerNode|
361         doesn't contain |start|.
362
363         Before this patch, CompositeEditCommand::cloneParagraphUnderNewElement() tried to copy
364         ancestry nodes from |start| to Document node when |start| position isn't in |outerNode|. This
365         patch changes CompositeEditCommand::cloneParagraphUnderNewElement() to copy |start| to
366         |outerNode| only if |outerNode| contains |start| position.
367
368         Merged from Blink https://src.chromium.org/viewvc/blink?revision=161762&view=revision by yosin@chromium.org.
369
370         Test: editing/execCommand/indent-with-uneditable-crash.html
371
372         * editing/CompositeEditCommand.cpp:
373         (WebCore::CompositeEditCommand::cloneParagraphUnderNewElement):
374
375 2014-02-15  Samuel White  <samuel_white@apple.com>
376
377         AX: Add ability to specify descendant type when using AXUIElementsForSearchPredicate.
378         https://bugs.webkit.org/show_bug.cgi?id=128747
379
380         Reviewed by Chris Fleizach.
381
382         Added support for 'immediate descendant only' to existing predicate based searching. This
383         addition allows VoiceOver to fetch each child element lazily (rather than all at once via AXChildren).
384
385         Test: platform/mac/accessibility/search-predicate-immediate-descendants-only.html
386
387         * accessibility/AccessibilityObject.cpp:
388         (WebCore::AccessibilityObject::findMatchingObjects):
389         * accessibility/AccessibilityObject.h:
390         (WebCore::AccessibilitySearchCriteria::AccessibilitySearchCriteria):
391         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
392         (accessibilitySearchCriteriaForSearchPredicateParameterizedAttribute):
393
394 2014-02-15  Jeremy Jones  <jeremyj@apple.com>
395
396         WK2 AVKit enter fullscreen doesn't work a second time.
397         https://bugs.webkit.org/show_bug.cgi?id=128558
398
399         Reviewed by Jer Noble.
400
401         Lazily create WebAVPlayerController when needed.
402
403         * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
404         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
405         (WebVideoFullscreenInterfaceAVKit::WebVideoFullscreenInterfaceAVKit):
406         (WebVideoFullscreenInterfaceAVKit::getPlayerController):
407         Add getPlayerController()
408
409         (WebVideoFullscreenInterfaceAVKit::setWebVideoFullscreenModel):
410         (WebVideoFullscreenInterfaceAVKit::setDuration):
411         (WebVideoFullscreenInterfaceAVKit::setCurrentTime):
412         (WebVideoFullscreenInterfaceAVKit::setRate):
413         (WebVideoFullscreenInterfaceAVKit::setVideoDimensions):
414         (WebVideoFullscreenInterfaceAVKit::setVideoLayer):
415         (WebVideoFullscreenInterfaceAVKit::enterFullscreenWithCompletionHandler):
416         use getPlayerController();
417
418 2014-02-15  Jer Noble  <jer.noble@apple.com>
419
420         [Mac] 10X slower than Chrome when drawing a video into a canvas
421         https://bugs.webkit.org/show_bug.cgi?id=124599
422
423         Reviewed by Darin Adler.
424
425         Follow up patch to r159518 to address Darin's post-commit review.
426
427         * html/HTMLVideoElement.cpp:
428         (WebCore::HTMLVideoElement::nativeImageForCurrentTime): Use nullptr.
429         * platform/graphics/MediaPlayerPrivate.h:
430         (WebCore::MediaPlayerPrivateInterface::nativeImageForCurrentTime): Ditto.
431         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
432         (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Ditto.
433         (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC): Clear the
434                 AVPlayerItemVideoOutput's delegate callback.
435         (WebCore::CVPixelBufferGetBytePointerCallback): Use static_cast.
436         (WebCore::CVPixelBufferReleaseBytePointerCallback): Ditto.
437         (WebCore::CVPixelBufferReleaseInfoCallback): Ditto.
438         (-[WebCoreAVFPullDelegate initWithCallback:]): Space changes.
439         (-[WebCoreAVFPullDelegate setCallback:]): Added.
440         (-[WebCoreAVFPullDelegate outputMediaDataWillChange:]): Check the value of m_callback.
441
442 2014-02-14  Andreas Kling  <akling@apple.com>
443
444         CTTE: WorkerGlobalScope is always owned by a WorkerThread.
445         <https://webkit.org/b/128834>
446
447         Codify this by storing the owner thread as a WorkerThread& and making
448         thread() return a reference.
449
450         This exposed a couple of unnecessary assertions.
451
452         Reviewed by Anders Carlsson.
453
454         * Modules/notifications/WorkerGlobalScopeNotifications.cpp:
455         (WebCore::WorkerGlobalScopeNotifications::webkitNotifications):
456         * Modules/websockets/ThreadableWebSocketChannel.cpp:
457         (WebCore::ThreadableWebSocketChannel::create):
458         * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
459         (WebCore::WorkerThreadableWebSocketChannel::Bridge::Bridge):
460         (WebCore::WorkerThreadableWebSocketChannel::Bridge::waitForMethodCompletion):
461         * bindings/js/ScheduledAction.cpp:
462         (WebCore::ScheduledAction::execute):
463         * bindings/js/WorkerScriptDebugServer.cpp:
464         (WebCore::WorkerScriptDebugServer::runEventLoopWhilePaused):
465         * dom/ScriptExecutionContext.cpp:
466         (WebCore::ScriptExecutionContext::createdMessagePort):
467         (WebCore::ScriptExecutionContext::destroyedMessagePort):
468         * inspector/WorkerDebuggerAgent.cpp:
469         (WebCore::WorkerDebuggerAgent::WorkerDebuggerAgent):
470         (WebCore::WorkerDebuggerAgent::~WorkerDebuggerAgent):
471         * inspector/WorkerInspectorController.cpp:
472         * inspector/WorkerRuntimeAgent.cpp:
473         (WebCore::WorkerRuntimeAgent::pauseWorkerGlobalScope):
474         * loader/WorkerThreadableLoader.cpp:
475         (WebCore::WorkerThreadableLoader::WorkerThreadableLoader):
476         (WebCore::WorkerThreadableLoader::loadResourceSynchronously):
477         * loader/cache/MemoryCache.cpp:
478         (WebCore::MemoryCache::removeRequestFromCache):
479         * workers/DedicatedWorkerGlobalScope.cpp:
480         (WebCore::DedicatedWorkerGlobalScope::create):
481         (WebCore::DedicatedWorkerGlobalScope::DedicatedWorkerGlobalScope):
482         (WebCore::DedicatedWorkerGlobalScope::postMessage):
483         (WebCore::DedicatedWorkerGlobalScope::importScripts):
484         (WebCore::DedicatedWorkerGlobalScope::thread):
485         * workers/DedicatedWorkerGlobalScope.h:
486         * workers/DedicatedWorkerThread.cpp:
487         (WebCore::DedicatedWorkerThread::createWorkerGlobalScope):
488         * workers/SharedWorkerGlobalScope.cpp:
489         (WebCore::SharedWorkerGlobalScope::create):
490         (WebCore::SharedWorkerGlobalScope::SharedWorkerGlobalScope):
491         (WebCore::SharedWorkerGlobalScope::thread):
492         * workers/SharedWorkerGlobalScope.h:
493         * workers/SharedWorkerThread.cpp:
494         (WebCore::SharedWorkerThread::createWorkerGlobalScope):
495         * workers/WorkerGlobalScope.cpp:
496         (WebCore::CloseWorkerGlobalScopeTask::performTask):
497         (WebCore::WorkerGlobalScope::WorkerGlobalScope):
498         (WebCore::WorkerGlobalScope::~WorkerGlobalScope):
499         (WebCore::WorkerGlobalScope::postTask):
500         (WebCore::WorkerGlobalScope::logExceptionToConsole):
501         (WebCore::WorkerGlobalScope::addConsoleMessage):
502         (WebCore::WorkerGlobalScope::addMessage):
503         (WebCore::WorkerGlobalScope::isContextThread):
504         * workers/WorkerGlobalScope.h:
505         (WebCore::WorkerGlobalScope::thread):
506         * workers/WorkerMessagingProxy.cpp:
507         (WebCore::MessageWorkerGlobalScopeTask::performTask):
508         (WebCore::WorkerMessagingProxy::WorkerMessagingProxy):
509         (WebCore::WorkerMessagingProxy::~WorkerMessagingProxy):
510         * workers/WorkerRunLoop.cpp:
511         (WebCore::WorkerRunLoop::runInMode):
512         (WebCore::WorkerRunLoop::runCleanupTasks):
513
514 2014-02-14  Ryosuke Niwa  <rniwa@webkit.org>
515
516         setSelectionRange shouldn't trigger a synchronous layout to check focusability when text field is already focused
517         https://bugs.webkit.org/show_bug.cgi?id=128804
518
519         Reviewed by Enrica Casucci.
520
521         Don't trigger a synchronous layout at the beginning of setSelectionRange if the element is already focused
522         since we don't have to check the size of render box in that case.
523
524         We should be able to get rid of this synchronous layout entirely once we fix https://webkit.org/b/128797
525         but that's somewhat risky behavioral change so we'll do that in a separate patch.
526
527         * editing/FrameSelection.cpp:
528         (WebCore::FrameSelection::selectAll): Fixed the bug where selectAll selects the entire document even if the text
529         form contol is focused if the selection is none (i.e. not anchored to any node).
530         * html/HTMLTextFormControlElement.cpp:
531         (WebCore::HTMLTextFormControlElement::setSelectionRange): Only update the layout if the element is not focused
532         already. Also pass in DoNotSetFocus option to setSelection since we already have the focus in that case.
533
534 2014-02-14  Dan Bernstein  <mitz@apple.com>
535
536         REGRESSION (r157443): Search fields with a non-white background don’t have a round bezel
537         https://bugs.webkit.org/show_bug.cgi?id=126295
538
539         Reviewed by Ryosuke Niwa.
540
541         Reverted r157443 and improved comment.
542
543         * rendering/RenderTheme.cpp:
544         (WebCore::RenderTheme::isControlStyled):
545
546 2014-02-14  Brian Burg  <bburg@apple.com>
547
548         Web Replay: AtomicString replay input names should be stored in a thread-local table
549         https://bugs.webkit.org/show_bug.cgi?id=128829
550
551         Reviewed by Andreas Kling.
552
553         Similar to how DOM event names are frequently-used AtomicStrings, replay input
554         names are also checked in many places as a "type tag". This patch puts all known
555         input names into a class held by ThreadGlobalData and adds the shortcut `inputTypes()`
556         so that replay input types can be referenced with `inputTypes.InputName()`.
557
558         * WebCore.xcodeproj/project.pbxproj:
559         * platform/ThreadGlobalData.cpp: Add inputTypes() shortcut.
560         (WebCore::ThreadGlobalData::ThreadGlobalData):
561         * platform/ThreadGlobalData.h: Add inputTypes() shortcut.
562         (WebCore::ThreadGlobalData::inputTypes):
563         * replay/ReplayInputTypes.cpp: Added.
564         (WebCore::ReplayInputTypes::ReplayInputTypes):
565         * replay/ReplayInputTypes.h: Added.
566         (WebCore::inputTypes): The input names are provided by per-framework macros that
567         are generated by the replay inputs code generator.
568
569 2014-02-14  Jer Noble  <jer.noble@apple.com>
570
571         Add support for specced event handlers to HTMLMediaElement
572         https://bugs.webkit.org/show_bug.cgi?id=128292
573
574         Reviewed by Andreas Kling.
575
576         Test: media/media-event-listeners.html
577
578         Add explicit event listener IDL attributes to HTMLMediaElement.
579
580         * html/HTMLMediaElement.h:
581         * html/HTMLMediaElement.idl:
582
583 2014-02-14  Oliver Hunt  <oliver@apple.com>
584
585         Implement a few more Array prototype functions in JS
586         https://bugs.webkit.org/show_bug.cgi?id=128788
587
588         Reviewed by Gavin Barraclough.
589
590         Minor change to ensure that the inspector is treating builtins
591         as host functions.
592
593         Tests: js/regress/array-prototype-filter.html
594                js/regress/array-prototype-forEach.html
595                js/regress/array-prototype-map.html
596                js/regress/array-prototype-some.html
597
598         * inspector/InspectorDOMAgent.cpp:
599         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
600           Make sure we treat builtins as regular host functions
601
602 2014-02-14  Beth Dakin  <bdakin@apple.com>
603
604         Margin tiles are not created for the top and left sides when there is a < 1.0 
605         scale factor
606         https://bugs.webkit.org/show_bug.cgi?id=128842
607
608         Reviewed by Simon Fraser.
609
610         floor the result of the computation whenever we have a negative origin, to ensure 
611         that we are rounding 'up' to a larger number of tiles. 
612         * platform/graphics/ca/mac/TileController.mm:
613         (WebCore::TileController::getTileIndexRangeForRect):
614
615 2014-02-13  Ryosuke Niwa  <rniwa@webkit.org>
616
617         setSelection should not synchronously trigger layout
618         https://bugs.webkit.org/show_bug.cgi?id=128797
619
620         Reviewed by Antti Koivisto.
621
622         Only update the appearance and reveal selection when the style and the layout is already up to date.
623         Otherwise, do so in performPostLayoutTasks.
624
625         * editing/FrameSelection.cpp:
626         (WebCore::FrameSelection::FrameSelection):
627         (WebCore::FrameSelection::setSelection): Set m_pendingSelectionUpdate and synchronously update caret rect
628         if we don't need to update style or layout.
629         (WebCore::updateSelectionByUpdatingLayoutOrStyle): Added. Used by FrameSelection member functions to
630         trigger layout or style recalc whichever is needed.
631         (WebCore::FrameSelection::updateAndRevealSelection): Extracted from setSelection.
632         (WebCore::FrameSelection::absoluteCaretBounds): Call updateSelectionByUpdatingLayoutOrStyle since caret rect
633         is no longer updated synchronously in setSelection.
634         (WebCore::FrameSelection::recomputeCaretRect): Don't assert that visibleStart().absoluteCaretBounds() is
635         equal to m_absCaretBounds since selection may no longer be caret at this point.
636         (WebCore::FrameSelection::setCaretVisibility): Call updateSelectionByUpdatingLayoutOrStyle since we're
637         synchronously calling into updateAppearance here. In the future, we should make this asynchronous as well.
638         (WebCore::FrameSelection::selectionBounds): Call updateSelectionByUpdatingLayoutOrStyle since selection bounds
639         could be outdated. This code only triggering style recalc was presumably a bug.
640         * editing/FrameSelection.h:
641
642         * page/FrameView.cpp:
643         (WebCore::FrameView::performPostLayoutTasks): Update selection's appearance and scroll to reveal selection
644         as needed.
645
646 2014-02-14  Andreas Kling  <akling@apple.com>
647
648         Purge remaining ENABLE(SHADOW_DOM) cruft.
649         <https://webkit.org/b/128827>
650
651         Remove the remaining 8.8 million lines of Shadow DOM code to align
652         with goals for intent to ship 60fps on mobile in 2014.
653
654         Reviewed by Antti Koivisto.
655
656 2014-02-13  Jer Noble  <jer.noble@apple.com>
657
658         [MediaControls][iOS] Embedded YouTube does not show a 'paused' button state after starting
659         https://bugs.webkit.org/show_bug.cgi?id=128755
660
661         Reviewed by Eric Carlson.
662
663         Don't rely on "canPlay()", instead, take the information directly from the event itself. I.e., when
664         handling the 'play' event, switch mode to playing, and vice versa for the 'pause' event.
665
666         * Modules/mediacontrols/mediaControlsApple.js:
667         (Controller.prototype.handlePlay):
668         (Controller.prototype.handlePause):
669         (Controller.prototype.updatePlaying):
670         (Controller.prototype.setPlaying):
671
672 2014-02-13  Jer Noble  <jer.noble@apple.com>
673
674         [MediaControls][iOS] Start playback button is visible when playing embedded YouTube
675         https://bugs.webkit.org/show_bug.cgi?id=128754
676
677         Reviewed by Eric Carlson.
678
679         Update shouldHaveStartPlaybackButton to match the behavior of the plugin proxy.
680
681         Add a accessor to determine whether playback has been requested:
682         * Modules/mediacontrols/MediaControlsHost.cpp:
683         (WebCore::MediaControlsHost::userGestureRequired):
684         * Modules/mediacontrols/MediaControlsHost.h:
685         * Modules/mediacontrols/MediaControlsHost.idl:
686
687         Update the logic of shouldHaveStartPlaybackButton.
688         * Modules/mediacontrols/mediaControlsiOS.js:
689         (ControllerIOS.prototype.shouldHaveStartPlaybackButton):
690
691 2014-02-13  Jer Noble  <jer.noble@apple.com>
692
693         [MediaControls] Add support for a loading progress meter
694         https://bugs.webkit.org/show_bug.cgi?id=128651
695
696         Reviewed by Eric Carlson.
697
698         Draw the loaded ranges underneath the timeline slider. Use a -webkit-canvas()
699         CSS function to allow the track of the slider to reflect the current state of
700         the video's loadedTimeRanges property.
701
702         Since -webkit-canvas() will share a backing store with all other CSS images using
703         the same identifier, use a monotonically increasing identifier to uniquely identify the timeline on a per-document basis.
704
705         * Modules/mediacontrols/mediaControlsApple.css:
706         (audio::-webkit-media-controls-timeline):
707         * Modules/mediacontrols/mediaControlsApple.js:
708         (Controller): Call updateProgress().
709         (Controller.prototype.createControls): Set up the canvas style and identifier.
710         (Controller.prototype.handleLoadStart): Call updateProgress().
711         (Controller.prototype.handleStalled): Ditto.
712         (Controller.prototype.handleReadyStateChange): Ditto.
713         (Controller.prototype.handleDurationChange): Ditto.
714         (Controller.prototype.handleProgress): Ditto.
715         (Controller.prototype.progressFillStyle): Added an easily overridable method
716             to determine the fill color of the progress bar.
717         (Controller.prototype.updateProgress): Draw the loadedTimeRanges into the timeline slider.
718         * Modules/mediacontrols/mediaControlsiOS.js:
719         (ControllerIOS.prototype.progressFillStyle): Override.
720
721 2014-02-14  Benjamin Poulain  <benjamin@webkit.org>
722
723         Clean up JSDOMStringMap::deleteProperty
724         https://bugs.webkit.org/show_bug.cgi?id=128801
725
726         Reviewed by Geoffrey Garen.
727
728         Follow up on my cleaning of JSDOMStringMapCustom, this time for deletion.
729
730         Previously, we would query for the name, then call deleteItem() if the name was
731         found. Instead, everything is moved to deleteItem which then return if the deletion
732         is successful or not.
733
734         By using convertPropertyNameToAttributeName, we can use Element::hasAttribute() directly
735         to find if the attribute exists or not. If it exists, we remove it.
736
737         Theoretically we could have a single pass over the attributes to find->delete but this
738         code is not hot enough to justify anything fancy at this point.
739
740         Finally, we no longer check for isValidPropertyName() on deletion. JSDOMStringMapCustom
741         was the last client of DatasetDOMStringMap::deleteItem() and it could not call deleteItem()
742         with invalid name since the name would have failed DatasetDOMStringMap::contains().
743         The spec does not specify any name checking either for deletion so we are safe just ignoring
744         invalid input.
745
746         * bindings/js/JSDOMStringMapCustom.cpp:
747         (WebCore::JSDOMStringMap::deleteProperty):
748         * dom/DatasetDOMStringMap.cpp:
749         (WebCore::DatasetDOMStringMap::deleteItem):
750         * dom/DatasetDOMStringMap.h:
751
752 2014-02-14  Benjamin Poulain  <bpoulain@apple.com>
753
754         Improve the performance on mobile of FTPDirectoryDocument
755         https://bugs.webkit.org/show_bug.cgi?id=128778
756
757         Reviewed by Antti Koivisto.
758
759         Little cleanup.
760
761         * html/FTPDirectoryDocument.cpp:
762         (WebCore::FTPDirectoryDocumentParser::appendEntry):
763         (WebCore::FTPDirectoryDocumentParser::createTDForFilename):
764         (WebCore::processFilesizeString):
765         (WebCore::wasLastDayOfMonth):
766         (WebCore::processFileDateString):
767         (WebCore::FTPDirectoryDocumentParser::parseAndAppendOneLine):
768         (WebCore::FTPDirectoryDocumentParser::loadDocumentTemplate):
769         (WebCore::FTPDirectoryDocumentParser::createBasicDocument):
770
771 2014-02-14  Benjamin Poulain  <benjamin@webkit.org>
772
773         Do not attempt to synchronize attributes when no Simple Selector could match an animatable attribute
774         https://bugs.webkit.org/show_bug.cgi?id=128728
775
776         Reviewed by Andreas Kling.
777
778         In most cases, we don't even need to test for the flag animatedSVGAttributesNotDirty.
779         If the selector filter could never match an animatable attribute, there is no point in testing for one.
780
781         * cssjit/SelectorCompiler.cpp:
782         (WebCore::SelectorCompiler::canMatchStyleAttribute):
783         Skip the second test when the local name is equal to canonicalLocalName. That is the common case.
784
785         (WebCore::SelectorCompiler::canMatchAnimatableSVGAttribute):
786         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributesMatching):
787
788         * svg/SVGElement.cpp:
789         (WebCore::addQualifiedName):
790         (WebCore::SVGElement::animatableAttributeForName):
791         (WebCore::SVGElement::isAnimatableAttribute):
792         (WebCore::SVGElement::filterOutAnimatableAttribute):
793         * svg/SVGElement.h:
794         * svg/SVGScriptElement.cpp:
795         (WebCore::SVGScriptElement::filterOutAnimatableAttribute):
796         * svg/SVGScriptElement.h:
797         Move the list of animatable attribute to a static function available in Release.
798         Selector matching is a lot more flexible than normal name matching. Since the local name must
799         always match, it is used as a key to get the full QualifiedName to compare to the selector.
800
801         Separating the list of animatable attributes between Selectors and SVGElement::isAnimatableAttribute
802         would be error prone. Instead, SVGElement::isAnimatableAttribute() is modified to use
803         SVGElement::animatableAttributeForName so that the two never get out of sync.
804
805         Since SVGScriptElement has one additional restriction to isAnimatableAttribute(), the function
806         filterOutAnimatableAttribute() is added to remove a qualified name from the complete list of animatable attributes.
807         This ensure SVGElement::animatableAttributeForName() always has the complete list, and subclasses of SVGElement
808         can only remove QualifiedNames, not add them.
809
810 2014-02-14  Benjamin Poulain  <benjamin@webkit.org>
811
812         Make code generation of the unoptimized pseudo classes separate
813         https://bugs.webkit.org/show_bug.cgi?id=128704
814
815         Reviewed by Andreas Kling.
816
817         Mapping the unoptimized selectors when generating the code was useful for debugging
818         but those cases are so common that looping over unoptimizedPseudoCheckers was more
819         costly than anticipated.
820
821         This patch moves the unoptimized pseudo selector in their own array to simplify code generation.
822
823         * cssjit/SelectorCompiler.cpp:
824         (WebCore::SelectorCompiler::addPseudoType):
825         (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
826         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
827
828 2014-02-14  Myles C. Maxfield  <mmaxfield@apple.com>
829
830         Implement text-decoration-skip: auto
831         https://bugs.webkit.org/show_bug.cgi?id=128786
832
833         Reviewed by Dean Jackson.
834
835         http://lists.w3.org/Archives/Public/www-style/2014Feb/0485.html
836         We are updating the initial value of text-decoration-skip to a new value, "auto".
837         On Mac + iOS, this will have the same behavior as "skip".
838
839         Test: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-default.html
840
841         * css/CSSComputedStyleDeclaration.cpp:
842         (WebCore::renderTextDecorationSkipFlagsToCSSValue):
843         * css/CSSParser.cpp:
844         (WebCore::CSSParser::parseTextDecorationSkip):
845         * css/DeprecatedStyleBuilder.cpp:
846         (WebCore::valueToDecorationSkip):
847         * rendering/InlineTextBox.cpp:
848         (WebCore::InlineTextBox::paintDecoration):
849         * rendering/style/RenderStyle.h:
850         * rendering/style/RenderStyleConstants.h:
851
852 2014-02-13  Simon Fraser  <simon.fraser@apple.com>
853
854         Give ScrollingTree(State)Nodes a reference to another layer, which is used for moving overflow:scroll contents around
855         https://bugs.webkit.org/show_bug.cgi?id=128790
856
857         Reviewed by Beth Dakin.
858
859         Have scrolling tree nodes and state nodes track another layer, the
860         "scrolled contents layer", for accelerated overflow:scroll.
861         
862         When making ScrollingTreeScrollingNodes for overflow:scroll, the node's
863         layer will point to the composited element's primary layer, and its
864         scrolledContentsLayer to the layer that gets moved around by scrolling.
865         
866         Do some other cleanup on AsyncScrollingCoordinator, removing
867         functions that just called through to nodes.
868
869         * WebCore.exp.in:
870         * page/scrolling/AsyncScrollingCoordinator.cpp:
871         (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
872         (WebCore::AsyncScrollingCoordinator::frameViewNonFastScrollableRegionChanged):
873         (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
874         (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
875         (WebCore::AsyncScrollingCoordinator::updateViewportConstrainedNode):
876         (WebCore::AsyncScrollingCoordinator::recomputeWheelEventHandlerCountForFrameView):
877         * page/scrolling/AsyncScrollingCoordinator.h:
878         * page/scrolling/ScrollingCoordinator.h:
879         (WebCore::ScrollingCoordinator::updateScrollingNode):
880         * page/scrolling/ScrollingStateScrollingNode.cpp:
881         (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
882         (WebCore::ScrollingStateScrollingNode::setScrolledContentsLayer):
883         (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayer):
884         (WebCore::ScrollingStateScrollingNode::setHeaderLayer):
885         (WebCore::ScrollingStateScrollingNode::setFooterLayer):
886         * page/scrolling/ScrollingStateScrollingNode.h:
887         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
888         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
889         (WebCore::ScrollingTreeScrollingNodeIOS::updateBeforeChildren):
890         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
891         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
892         (WebCore::ScrollingTreeScrollingNodeMac::updateBeforeChildren):
893         * rendering/RenderLayerCompositor.cpp:
894         (WebCore::RenderLayerCompositor::fixedRootBackgroundLayerChanged):
895
896 2014-02-14  Chris Fleizach  <cfleizach@apple.com>
897
898         AX: WebKit needs heuristics to differentiate lists used for layout from semantic data lists, similar to the heuristics for layout tables versus data tables.
899         https://bugs.webkit.org/show_bug.cgi?id=122320
900
901         Reviewed by Mario Sanchez Prada.
902
903         Many authors use lists for layout, rather than presenting data. Exposing these kinds of lists to accessibility users
904         makes the web harder to process and listen, while degrading the importance of real lists.
905
906         This introduces heuristics to filter out layout lists with the following:
907            1. If it's a named list, like ol or aria=list, then it's a list.
908              1a. Unless the list has no children, then it's not a list.
909            2. If it displays visible list markers, it's a list.
910            3. If it does not display list markers and has only one child, it's not a list.
911            4. If it does not have any listitem children, it's not a list.
912            5. Otherwise it's a list (for now).
913
914         Test: accessibility/list-detection.html
915
916         * accessibility/AccessibilityList.cpp:
917         (WebCore::AccessibilityList::determineAccessibilityRole):
918         (WebCore::AccessibilityList::roleValue):
919         * accessibility/AccessibilityList.h:
920
921 2014-02-14  Brendan Long  <b.long@cablelabs.com>
922
923         Use AtomicString arguments in TrackPrivateBaseClient callbacks
924         https://bugs.webkit.org/show_bug.cgi?id=128765
925
926         Reviewed by Eric Carlson.
927
928         No new tests because this doesn't change functionality.
929
930         * html/track/AudioTrack.cpp:
931         (WebCore::AudioTrack::idChanged):
932         (WebCore::AudioTrack::labelChanged):
933         (WebCore::AudioTrack::languageChanged):
934         * html/track/AudioTrack.h:
935         * html/track/InbandTextTrack.cpp:
936         (WebCore::InbandTextTrack::InbandTextTrack):
937         (WebCore::InbandTextTrack::idChanged):
938         (WebCore::InbandTextTrack::labelChanged):
939         (WebCore::InbandTextTrack::languageChanged):
940         * html/track/InbandTextTrack.h:
941         * html/track/VideoTrack.cpp:
942         (WebCore::VideoTrack::idChanged):
943         (WebCore::VideoTrack::labelChanged):
944         (WebCore::VideoTrack::languageChanged):
945         * html/track/VideoTrack.h:
946         * platform/graphics/TrackPrivateBase.h:
947
948 2014-02-14  Renata Hodovan  <rhodovan.u-szeged@partner.samsung.com>
949
950         ASSERTION FAILED: comparePositions(newEnd, newStart) >= 0 in WebCore::ApplyStyleCommand::updateStartEnd
951         https://bugs.webkit.org/show_bug.cgi?id=121791
952
953         Reviewed by Darin Adler.
954
955         If WebCore::ApplyStyleCommand::applyBlockStyle() creates a TextIterator for a range
956         that has an element with ReplacedElement rendering object, then a ',' is emitted in the
957         constructor of TextIterator. Due to this comma the end of the run range can be at the
958         wrong position, what makes the assertion fire. This situation can be handled the same
959         way in TextIterator::rangeFromLocationAndLength() as we do in case of the emitted '\n's.
960
961         Test: editing/execCommand/remove-formatting-from-iframe-in-button.html
962
963         * editing/TextIterator.cpp:
964         (WebCore::TextIterator::rangeFromLocationAndLength):
965
966 2014-02-14  Andrei Bucur  <abucur@adobe.com>
967
968         [CSS Regions] visibility: hidden on a region should hide its content
969         https://bugs.webkit.org/show_bug.cgi?id=128814
970
971         Reviewed by Mihnea Ovidenie.
972
973         The patch properly checks that the content of a region layer should be painted before actually
974         calling the paint function (for example, when visibility: hidden is specified on a region, its
975         content should be hidden).
976
977         Test: fast/regions/visibility-hidden.html
978
979         * rendering/RenderLayer.cpp:
980         (WebCore::RenderLayer::paintLayerContents):
981
982 2014-02-14  László Langó  <llango.u-szeged@partner.samsung.com>
983
984         Follow-up fix after r164036.
985
986         Reviewed by Csaba Osztrogonác.
987
988         * dom/Document.cpp:
989         (WebCore::Document::create):
990
991 2014-02-13  Byungseon Shin  <sun.shin@lge.com>
992
993         [MSE] Move PublicURLManager shutdown logic so ActiveDOMObjects associated with public URLs won't leak.
994         https://bugs.webkit.org/show_bug.cgi?id=128532
995
996         Reviewed by Jer Noble.
997
998         This fixes a leak of DOM objects by breaking the circular reference 
999         between Document, PublicURLManager, and MediaSource. 
1000         Instead of clearing PublicURLManager at destruction-time, 
1001         which is delayed indefinitely because of the circular reference, 
1002         clear the PublicURLManager during ActiveDOMObject::stop().
1003
1004         Frome Blink r151890 by <acolwell@chromium.org>
1005         <https://src.chromium.org/viewvc/blink?view=rev&revision=151890>
1006
1007         * dom/ScriptExecutionContext.cpp:
1008         (WebCore::ScriptExecutionContext::~ScriptExecutionContext):
1009         (WebCore::ScriptExecutionContext::publicURLManager):
1010         * html/DOMURL.h:
1011         * html/PublicURLManager.cpp:
1012         (WebCore::PublicURLManager::create):
1013         (WebCore::PublicURLManager::PublicURLManager):
1014         (WebCore::PublicURLManager::registerURL):
1015         (WebCore::PublicURLManager::stop):
1016         * html/PublicURLManager.h:
1017
1018 2014-02-13  Myles C. Maxfield  <mmaxfield@apple.com>
1019
1020         Remove position:sticky runtime flag
1021         https://bugs.webkit.org/show_bug.cgi?id=128774
1022
1023         Reviewed by Simon Fraser.
1024
1025         Rollout of r128663
1026
1027         No new tests are necessary because there is no behavior change.
1028
1029         * css/CSSParser.cpp:
1030         (WebCore::CSSParserContext::CSSParserContext):
1031         (WebCore::operator==):
1032         (WebCore::isValidKeywordPropertyAndValue):
1033         * css/CSSParserMode.h:
1034         * dom/Document.cpp:
1035         * dom/Document.h:
1036         * page/Settings.cpp:
1037         (WebCore::Settings::Settings):
1038         * page/Settings.h:
1039
1040 2014-02-04  Gustavo Noronha Silva  <gns@gnome.org>
1041
1042         [GTK][CMake] Generate GObject DOM bindings .symbols files
1043         https://bugs.webkit.org/show_bug.cgi?id=126210
1044
1045         Reviewed by Martin Robinson.
1046
1047         No new tests. Build change only.
1048
1049         * CMakeLists.txt: list Quota module files and IDLs even if the feature
1050         is disabled, for GTK, since we rely on that for our DOM bindings.
1051         * PlatformGTK.cmake: add a new target to check for DOM symbols API by
1052         running the new python script.
1053         * bindings/gobject/GNUmakefile.am: call the new python script instead
1054         of using a custom rule.
1055
1056 2014-02-13  Myles C. Maxfield  <mmaxfield@apple.com>
1057
1058         text-decoration-skip: ink skips randomly when using SVG fonts
1059         https://bugs.webkit.org/show_bug.cgi?id=128709
1060
1061         Reviewed by Simon Fraser.
1062
1063         This patch simply disables skipping underlines being used with SVG fonts.
1064         It's a stopgap until we can support skipping properly with SVG fonts.
1065
1066         Test: svg/custom/svg-fonts-skip-ink.html
1067
1068         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
1069         (WebCore::FontPlatformData::ctFont):
1070         * platform/graphics/mac/FontMac.mm:
1071         (WebCore::Font::dashesForIntersectionsWithRect):
1072
1073 2014-02-13  Daniel Bates  <dabates@apple.com>
1074
1075         Fix the ARM build when HAVE_ARM_NEON_INTRINSICS is enabled
1076
1077         Add !HAVE(ARM_NEON_INTRINSICS)-guard around file-level inline function arithmeticSoftware to
1078         avoid an unused function compiler warning when building with ARM Neon intrinsics.
1079
1080         * platform/graphics/filters/FEComposite.cpp:
1081
1082 2014-02-13  Brady Eidson  <beidson@apple.com>
1083
1084         IDB: Three tests crash the DatabaseProcess under ~KeyedDecoder
1085         https://bugs.webkit.org/show_bug.cgi?id=128763
1086
1087         Reviewed by Anders Carlsson.
1088
1089         No new tests (Covered by three existing tests)
1090
1091         * platform/KeyedCoding.h:
1092         (WebCore::KeyedEncoder::encodeObjects): If the array is empty we still have to begin() and end() it.
1093
1094 2014-02-13  Yuki Sekiguchi  <yuki.sekiguchi@access-company.com>
1095
1096         [css3-text] Support -webkit-text-decoration-skip: objects
1097         https://bugs.webkit.org/show_bug.cgi?id=128723
1098
1099         Reviewed by Dean Jackson.
1100
1101         Implemented 'objects' value of text-decoration-skip.
1102         http://www.w3.org/TR/2013/CR-css-text-decor-3-20130801/#text-decoration-skip
1103
1104         This is initial value and same behavior without
1105         ENABLE_CSS3_TEXT_DECORATION_SKIP_INK flag. Threfore, this patch only
1106         added parser code and constant for 'objects'.
1107
1108         Changed the initial value of text-decoration-skip.
1109
1110         The current implementation parses 'none', but the rendering code is
1111         not match the spec, so this patch added FIXME to the rendering code.
1112
1113         * css/CSSComputedStyleDeclaration.cpp:
1114         (WebCore::renderTextDecorationSkipFlagsToCSSValue):
1115         * css/CSSParser.cpp:
1116         (WebCore::CSSParser::parseTextDecorationSkip):
1117         * css/CSSValueKeywords.in:
1118         * css/DeprecatedStyleBuilder.cpp:
1119         (WebCore::valueToDecorationSkip):
1120         * rendering/InlineTextBox.cpp:
1121         (WebCore::InlineTextBox::paintDecoration):
1122         * rendering/style/RenderStyle.h:
1123         * rendering/style/RenderStyleConstants.h:
1124
1125 2014-02-13  Daniel Bates  <dabates@apple.com>
1126
1127         Fix ARM NEON build following <http://trac.webkit.org/changeset/164058>
1128         (https://bugs.webkit.org/show_bug.cgi?id=128767)
1129
1130         I inadvertently didn't include header NEONHelpers.h, which defines WebCore::loadRGBA8AsFloat().
1131
1132         * platform/graphics/cpu/arm/filters/FECompositeArithmeticNEON.h:
1133
1134 2014-02-13  Daniel Bates  <dabates@apple.com>
1135
1136         Write FEComposite::computeArithmeticPixelsNeon() in terms of loadRGBA8AsFloat()
1137         https://bugs.webkit.org/show_bug.cgi?id=128767
1138
1139         Reviewed by Dean Jackson.
1140
1141         This patch was inspired by Gabor Rapcsanyi's work in <https://bugs.webkit.org/show_bug.cgi?id=90669>.
1142
1143         Currently we duplicate code in FEComposite::computeArithmeticPixelsNeon() to read pixel data.
1144         Instead we should use the convenience function WebCore::loadRGBA8AsFloat. This also resolves
1145         an uninitialized variable compiler warning in the existing code.
1146
1147         * platform/graphics/cpu/arm/filters/FECompositeArithmeticNEON.h:
1148         (WebCore::FEComposite::computeArithmeticPixelsNeon):
1149
1150 2014-02-13  Myles C. Maxfield  <mmaxfield@apple.com>
1151
1152         During a copy, position:fixed gets converted to position:absolute even if only part of the document is selected
1153         https://bugs.webkit.org/show_bug.cgi?id=128688
1154
1155         Reviewed by Ryosuke Niwa.
1156
1157         Adds a field, m_needsPositionStyleConversion, to StyledMarkupAccumulator.
1158
1159         Also, renames the ConvertPositionStyleOnCopy setting to ShouldConvertPositionStyleOnCopy
1160
1161         Test: editing/pasteboard/copy-paste-doesnt-convert-sticky-and-fixed-during-partial-copy.html
1162
1163         * editing/markup.cpp:
1164         (WebCore::StyledMarkupAccumulator::StyledMarkupAccumulator):
1165         (WebCore::StyledMarkupAccumulator::appendElement):
1166         (WebCore::createMarkupInternal):
1167         * page/Settings.in:
1168         * testing/InternalSettings.cpp:
1169         (WebCore::InternalSettings::Backup::Backup):
1170         (WebCore::InternalSettings::Backup::restoreTo):
1171         (WebCore::InternalSettings::setShouldConvertPositionStyleOnCopy):
1172         * testing/InternalSettings.h:
1173         * testing/InternalSettings.idl:
1174
1175 2014-02-12  Timothy Hatcher  <timothy@apple.com>
1176
1177         Enable inspection of recently used IndexedDB databases.
1178
1179         https://bugs.webkit.org/show_bug.cgi?id=128687
1180
1181         Reviewed by Brady Eidson & Joseph Pecoraro.
1182
1183         * Modules/indexeddb/IDBFactory.cpp:
1184         (WebCore::IDBFactory::getDatabaseNames):
1185         * Modules/indexeddb/IDBFactoryBackendInterface.h:
1186         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
1187         (WebCore::IDBFactoryBackendLevelDB::getDatabaseNames):
1188         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.h:
1189         Fix up the arguments passed to getDatabaseNames.
1190
1191         * WebCore.xcodeproj/project.pbxproj:
1192         Make DOMStringList.h private so WebKit2 can use it.
1193
1194         * inspector/InspectorIndexedDBAgent.cpp:
1195         Modernize the loops and remove some PLATFORM(COCOA) ifdefs to
1196         compile the code. 
1197
1198         * inspector/protocol/IndexedDB.json: Use number for version to
1199         allow larger values instead of clamping to int.
1200
1201 2014-02-13  Chang Shu  <cshu@webkit.org>
1202
1203         Copying (createMarkup) wrapping text results in space between wrapped lines stripped.
1204         https://bugs.webkit.org/show_bug.cgi?id=63233
1205
1206         The problem is StyledMarkupAccumulator uses renderedText and the space at
1207         the end of the text has been stripped when the tag after the text was wrapped.
1208
1209         Reviewed by Ryosuke Niwa.
1210
1211         Test: editing/pasteboard/copy-text-with-wrapped-tag.html
1212
1213         * editing/TextIterator.cpp:
1214         (WebCore::TextIterator::TextIterator):
1215         (WebCore::TextIterator::handleTextBox):
1216         * editing/TextIterator.h:
1217         Check the special case when the iterator runs over a range that is followed by a non-text box.
1218         In this case, the possible last space has been collapsed and needs to be restored.
1219         * editing/markup.cpp:
1220         (WebCore::StyledMarkupAccumulator::renderedText):
1221         Check if the range is followed by more nodes and pass this information to the constructed TextIterator.
1222
1223 2014-02-13  Myles C. Maxfield  <mmaxfield@apple.com>
1224
1225         Gaps for text-decoration-skip: ink are calculated assuming the glyph orientation is the same as the run orientation
1226         https://bugs.webkit.org/show_bug.cgi?id=128718
1227
1228         Reviewed by Darin Adler.
1229
1230         This is a stop-gap patch to make underlines in CJK text not look terrible. A long-term fix is to refactor
1231         showGlyphsWithAdvances to move rotation logic into a common place that the text-decoration-skip: ink code
1232         can use.
1233
1234         Test: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-orientation-upright.html
1235
1236         * rendering/InlineTextBox.cpp:
1237         (WebCore::InlineTextBox::paintDecoration):
1238
1239 2014-02-13  Andreas Kling  <akling@apple.com>
1240
1241         InsertIntoTextNodeCommand should get Settings from the Frame.
1242         <https://webkit.org/b/128678>
1243
1244         EditCommands have a frame() accessor that returns a reference,
1245         so there's no need to go through Document.
1246
1247         Reviewed by Anders Carlsson.
1248
1249         * editing/InsertIntoTextNodeCommand.cpp:
1250         (WebCore::InsertIntoTextNodeCommand::doApply):
1251
1252 2014-02-13  László Langó  <llango.u-szeged@partner.samsung.com>
1253
1254         Document should be constructable
1255         https://bugs.webkit.org/show_bug.cgi?id=115643
1256
1257         Reviewed by Darin Adler.
1258
1259         http://www.w3.org/TR/2014/WD-dom-20140204/#interface-document
1260         Make Document constructable so that one can do "new Document"
1261         instead of "document.implementation.createHTMLDocument('')".
1262
1263         Test: fast/dom/Document/document-constructor.html
1264
1265         * dom/Document.cpp:
1266         (WebCore::Document::create):
1267         (WebCore::Document::origin):
1268         * dom/Document.h:
1269         * dom/Document.idl:
1270
1271 2014-02-13  Javier Fernandez  <jfernandez@igalia.com>
1272
1273         [CSS Grid Layout] Rename named areas property
1274         https://bugs.webkit.org/show_bug.cgi?id=127990
1275
1276         Reviewed by Sergio Villar Senin.
1277
1278         From Blink r165891 by <rego@igalia.com>
1279
1280         The property 'grid-template' has been renamed to 'grid-template-areas'
1281         in the last two versions of the spec.
1282
1283         * CMakeLists.txt:
1284         * GNUmakefile.list.am:
1285         * WebCore.vcxproj/WebCore.vcxproj:
1286         * WebCore.vcxproj/WebCore.vcxproj.filters:
1287         * WebCore.xcodeproj/project.pbxproj:
1288         * css/CSSComputedStyleDeclaration.cpp:
1289         (WebCore::ComputedStyleExtractor::propertyValue):
1290         * css/CSSGridTemplateAreasValue.cpp: Renamed from Source/WebCore/css/CSSGridTemplateValue.cpp.
1291         (WebCore::CSSGridTemplateAreasValue::CSSGridTemplateAreasValue):
1292         (WebCore::stringForPosition):
1293         (WebCore::CSSGridTemplateAreasValue::customCSSText):
1294         * css/CSSGridTemplateAreasValue.h: Renamed from Source/WebCore/css/CSSGridTemplateValue.h.
1295         (WebCore::CSSGridTemplateAreasValue::create):
1296         (WebCore::CSSGridTemplateAreasValue::~CSSGridTemplateAreasValue):
1297         (WebCore::CSSGridTemplateAreasValue::gridAreaMap):
1298         (WebCore::CSSGridTemplateAreasValue::rowCount):
1299         (WebCore::CSSGridTemplateAreasValue::columnCount):
1300         * css/CSSParser.cpp:
1301         (WebCore::CSSParser::parseValue):
1302         (WebCore::CSSParser::parseGridTemplateAreas):
1303         * css/CSSParser.h:
1304         * css/CSSPropertyNames.in:
1305         * css/CSSValue.cpp:
1306         (WebCore::CSSValue::equals):
1307         (WebCore::CSSValue::cssText):
1308         (WebCore::CSSValue::destroy):
1309         * css/CSSValue.h:
1310         (WebCore::CSSValue::isGridTemplateAreasValue):
1311         * css/StyleResolver.cpp:
1312         (WebCore::StyleResolver::applyProperty):
1313
1314 2014-02-13  Adrian Bunk  <bunk@stusta.de>
1315
1316         Remove the last remnants of Maemo support
1317         https://bugs.webkit.org/show_bug.cgi?id=85238
1318
1319         Reviewed by Ryosuke Niwa.
1320
1321         * plugins/npapi.h:
1322
1323 2014-02-13  ChangSeok Oh  <changseok.oh@collabora.com>
1324
1325         Support ANGLE_instanced_arrays for GLES backend.
1326         https://bugs.webkit.org/show_bug.cgi?id=128579
1327
1328         Reviewed by Dean Jackson.
1329
1330         Add some APIs to Extensions3D to support ANGLE_instanced_arrays for GLES backend.
1331         At the same time, drawArraysInstanced, drawElementsInstanced and vertexAttribDivisor
1332         are moved from GC3DOpenGL.cpp to GC3DOpenGLCommon.cpp since they could be shareable
1333         through Extensions3D.
1334
1335         Covered by fast/canvas/webgl/angle-instanced-arrays.html
1336
1337         * platform/graphics/Extensions3D.h:
1338         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
1339         (WebCore::Extensions3DOpenGL::drawArraysInstanced):
1340         (WebCore::Extensions3DOpenGL::drawElementsInstanced):
1341         (WebCore::Extensions3DOpenGL::vertexAttribDivisor):
1342         * platform/graphics/opengl/Extensions3DOpenGL.h:
1343         * platform/graphics/opengl/Extensions3DOpenGLES.cpp:
1344         (WebCore::Extensions3DOpenGLES::Extensions3DOpenGLES):
1345         (WebCore::Extensions3DOpenGLES::drawArraysInstanced):
1346         (WebCore::Extensions3DOpenGLES::drawElementsInstanced):
1347         (WebCore::Extensions3DOpenGLES::vertexAttribDivisor):
1348         (WebCore::Extensions3DOpenGLES::supportsExtension):
1349         * platform/graphics/opengl/Extensions3DOpenGLES.h:
1350         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
1351         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
1352         (WebCore::GraphicsContext3D::drawArraysInstanced):
1353         (WebCore::GraphicsContext3D::drawElementsInstanced):
1354         (WebCore::GraphicsContext3D::vertexAttribDivisor):
1355         * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
1356
1357 2014-02-13  Xabier Rodriguez Calvar  <calvaris@igalia.com>
1358
1359         [GTK] MEDIA_CONTROLS_SCRIPT support
1360         https://bugs.webkit.org/show_bug.cgi?id=123097
1361
1362         Reviewed by Jer Noble.
1363
1364         WebKitGTK+ multimedia controls are now managed from Javascript
1365         code. Apple controls are kept as common code and GTK+ ones are
1366         subclassed for the specific behavior.
1367
1368         Both CMake and Autotools build support is provided.
1369
1370         * CMakeLists.txt: Added support to build the media controls
1371         script and their associated files.
1372         * GNUmakefile.am: Added support to generate the C++ code from the
1373         Javascript.
1374         * GNUmakefile.list.am: Added the media controls script associated
1375         files.
1376         * Modules/mediacontrols/MediaControlsHost.cpp:
1377         * Modules/mediacontrols/MediaControlsHost.h:
1378         * Modules/mediacontrols/MediaControlsHost.idl:
1379         (WebCore::MediaControlsHost::supportsFullscreen): Added attribute
1380         to know if the element supports fullscreen.
1381         * Modules/mediacontrols/mediaControlsApple.js:
1382         (Controller.prototype.handleWrapperMouseMove):
1383         (Controller.prototype.handleWrapperMouseOut):
1384         (Controller.prototype.updatePlaying): Use clear and
1385         resetHideControlsTimer.
1386         (Controller.prototype.clearHideControlsTimer): Added.
1387         (Controller.prototype.resetHideControlsTimer): Added.
1388         * Modules/mediacontrols/mediaControlsGtk.js: Added.
1389         (createControls): Calls ControllerGtk.
1390         (ControllerGtk): Calls the superclass.
1391         (contains): Defines a function to know if an object is contained
1392         in an array.
1393         (ControllerGtk.prototype.inheritFrom): Copies the method of the
1394         superclass that are not reimplemented in the subclass.
1395         (ControllerGtk.prototype.createControls): Calls the superclass and
1396         create the remaining needed elements.
1397         (ControllerGtk.prototype.configureInlineControls): Configures the
1398         controls.
1399         (ControllerGtk.prototype.setStatusHidden): Redefined empty.
1400         (ControllerGtk.prototype.updateTime): Writes the duration and
1401         current position. As it was so far, current time also includes
1402         duration. If current time is bigger than 0 we show that.
1403         (ControllerGtk.prototype.showCurrentTime): Shows current time and
1404         hides duration label (that is included in current time).
1405         (ControllerGtk.prototype.handlePlay): Calls the superclass and
1406         force showing the current time.
1407         (ControllerGtk.prototype.handleTimeUpdate): Always update the
1408         time.
1409         (ControllerGtk.prototype.handleMuteButtonMouseOver): Shows the
1410         volume slider.
1411         (ControllerGtk.prototype.handleVolumeBoxMouseOut): Hides the
1412         volume slider.
1413         (ControllerGtk.prototype.addControls): Adds the enclosure instead
1414         of the panel directly. Panel is, of course, part of the enclosure.
1415         (ControllerGtk.prototype.updateReadyState): Shows the fullscreen
1416         button only if fullscreen is supported. Sets the volume in up or
1417         down mode depending on its position in the document. Updates the
1418         volume.
1419         (ControllerGtk.prototype.setControlsType): Creates the controls it
1420         they were not created before. Unlike Apple ones, WebKitGTK+
1421         fullscreen and inline controls are the same.
1422         (ControllerGtk.prototype.updatePlaying): Calls the superclass and
1423         shows the controls if not playing.
1424         (ControllerGtk.prototype.handleCaptionButtonClicked): Redefined
1425         empty. To be coherent with volume, that also shows a popup, this
1426         is handled with mouseover instead of click.
1427         (ControllerGtk.prototype.buildCaptionMenu): Calls the superclass
1428         to build the menu, sets some listeners, centers the popup with the
1429         captions button, keeps the current height and sets the style to 0,
1430         which is needed to animate it.
1431         (ControllerGtk.prototype.destroyCaptionMenu): Hides the caption menu.
1432         (ControllerGtk.prototype.showCaptionMenu): Resets the height to
1433         its original. We don't animate it with CSS because we would need
1434         to specify a height in the style and we don't know it in advance.
1435         (ControllerGtk.prototype.hideCaptionMenu): Sets height to 0.
1436         (ControllerGtk.prototype.captionMenuTransitionEnd): When the
1437         captions menu transtition ends, it is destroyed.
1438         (ControllerGtk.prototype.handleCaptionButtonMouseOver): Creates
1439         the caption menu and shows it.
1440         (ControllerGtk.prototype.handleCaptionButtonMouseOut): Hides the
1441         captions menu.
1442         (ControllerGtk.prototype.handleCaptionMouseOut): Hides the
1443         captions menu.
1444         * PlatformGTK.cmake: Added WebCore to the target link libraries
1445         and initialized the variables needed at CMakelists.txt
1446         * css/mediaControlsGtk.css:
1447         (audio::-webkit-media-controls-panel)
1448         (video::-webkit-media-controls-panel): Added transtion based on opacity.
1449         (video::-webkit-media-controls-panel): Set video opacity to 0.
1450         (video::-webkit-media-controls-panel.paused): Set video opacity to 1.
1451         (audio::-webkit-media-controls-panel div.mute-box): Set the same
1452         style as the mute button to preserve the layout.
1453         (audio::-webkit-media-controls-panel div.mute-box.hidden): Sets
1454         the display to none.
1455         (audio::-webkit-media-controls-mute-button)
1456         (video::-webkit-media-controls-mute-button): Removed the outline
1457         and the margin that is managed by the mute box now.
1458         (audio::-webkit-media-controls-play-button)
1459         (video::-webkit-media-controls-play-button): Removed the outline.
1460         (audio::-webkit-media-controls-time-remaining-display)
1461         (video::-webkit-media-controls-time-remaining-display): Removed
1462         the display.
1463         (audio::-webkit-media-controls-current-time-display)
1464         (video::-webkit-media-controls-current-time-display): Added the
1465         display block.
1466         (video::-webkit-media-controls-time-remaining-display): Set
1467         display none.
1468         (video::-webkit-media-controls-time-remaining-display.show): Set
1469         display block.
1470         (video::-webkit-media-controls-time-remaining-display.hidden): Set
1471         display none.
1472         (audio::-webkit-media-controls-timeline)
1473         (video::-webkit-media-controls-timeline): Removed outline.
1474         (audio::-webkit-media-controls-volume-slider-container)
1475         (video::-webkit-media-controls-volume-slider-container): Set
1476         overflow hidden and set a transition by height.
1477         (video::-webkit-media-controls-volume-slider-container.hidden):
1478         Set height 0.
1479         (video::-webkit-media-controls-volume-slider-container.down): Set
1480         bottom to be below the panel. Changed the border radius and
1481         transition accordingly.
1482         (video::-webkit-media-controls-panel .hidden.down): Sets default
1483         bottom as 0.
1484         (audio::-webkit-media-controls-volume-slider)
1485         (video::-webkit-media-controls-volume-slider): Removed the outline.
1486         (audio::-webkit-media-controls-toggle-closed-captions-button)
1487         (video::-webkit-media-controls-toggle-closed-captions-button):
1488         Removed the background that is painted from C++ and removed the
1489         outline.
1490         (video::-webkit-media-controls-closed-captions-container):
1491         (video::-webkit-media-controls-closed-captions-container h3):
1492         (video::-webkit-media-controls-closed-captions-container ul):
1493         (video::-webkit-media-controls-closed-captions-container li):
1494         (video::-webkit-media-controls-closed-captions-container li.selected): Changed
1495         the style to make it more coherent with the rest of the controls.
1496         (audio::-webkit-media-controls-fullscreen-button)
1497         (video::-webkit-media-controls-fullscreen-button): Removed the outline.
1498         (audio::-webkit-media-controls-panel button.hidden): Sets the
1499         display to none.
1500         * html/HTMLMediaElement.cpp: UserAgentScripts.h is not needed here
1501         and build cmake build would need for changes to get this compiled.
1502         * platform/gtk/RenderThemeGtk.cpp:
1503         (WebCore::nodeHasPseudo): Added. Checks if a node has a certain
1504         pseudo.
1505         (WebCore::nodeHasClass): Added. Checks if a node has a certain
1506         class.
1507         (WebCore::supportsFocus): Removed some element types as outline is
1508         now handled in CSS.
1509         (WebCore::RenderThemeGtk::paintMediaPlayButton): Checks if the
1510         play button has the class paused to show the play icon instead of
1511         the pause one.
1512         (WebCore::RenderThemeGtk::paintMediaToggleClosedCaptionsButton):
1513         Added. Paints the captions icon.
1514         (WebCore::RenderThemeGtk::mediaControlsScript): Added. Loads the
1515         bundled scripts.
1516         * platform/gtk/RenderThemeGtk.h: Added the mediaControlsScript
1517         method and declared the redefinition of the method to play the
1518         captions icon.
1519
1520 2014-02-11  Alexey Proskuryakov  <ap@apple.com>
1521
1522         Don't crash when SerializedScriptValue deserialization fails
1523         https://bugs.webkit.org/show_bug.cgi?id=128657
1524
1525         Reviewed by Oliver Hunt.
1526
1527         Test: crypto/subtle/postMessage-worker.html
1528
1529         * bindings/js/JSMessageEventCustom.cpp: (WebCore::JSMessageEvent::data): Added a FIXME.
1530
1531         * bindings/js/SerializedScriptValue.cpp:
1532         (WebCore::CloneBase::fail): Don't assert on failure.
1533         (WebCore::SerializedScriptValue::deserialize): Never return a null JSValue, these
1534         are not allowed.
1535
1536 2014-02-12  Bem Jones-Bey  <bjonesbe@adobe.com>
1537
1538         [CSS Shapes] Rename shapeSize and others to make ShapeInfo and friends easier to understand
1539         https://bugs.webkit.org/show_bug.cgi?id=128685
1540
1541         Reviewed by Alexandru Chiculita.
1542
1543         The ShapeInfo hierarchy has grown organically as the spec has changed,
1544         and the naming has become very stale and confusing. The spec is now in
1545         Last Call, so it seems like a good time to take a stab towards better
1546         naming that matches the spec terminology and is also more consistent
1547         in general.
1548
1549         No new tests, no behavior change.
1550
1551         * rendering/RenderBlock.cpp:
1552         (WebCore::RenderBlock::imageChanged): Use new names.
1553         (WebCore::RenderBlock::updateShapeInsideInfoAfterStyleChange): Ditto.
1554         (WebCore::shapeInfoRequiresRelayout): Ditto.
1555         (WebCore::RenderBlock::computeShapeSize): Ditto.
1556         (WebCore::RenderBlock::updateShapesAfterBlockLayout): Ditto.
1557         * rendering/RenderBlock.h:
1558         (WebCore::RenderBlock::logicalSizeForChild): This method makes it much
1559             cleaner to set the reference box size.
1560         * rendering/RenderBlockFlow.cpp:
1561         (WebCore::RenderBlockFlow::positionNewFloats): Use new names.
1562         * rendering/RenderBox.cpp:
1563         (WebCore::RenderBox::updateShapeOutsideInfoAfterStyleChange): Ditto.
1564         (WebCore::RenderBox::imageChanged): Ditto.
1565         * rendering/shapes/ShapeInfo.cpp:
1566         (WebCore::getShapeImageMarginRect): Rename variables.
1567         (WebCore::ShapeInfo<RenderType>::computedShape): More renames.
1568         * rendering/shapes/ShapeInfo.h:
1569         (WebCore::ShapeInfo::setReferenceBoxLogicalSize): Renamed from
1570             setShapeSize.
1571         (WebCore::ShapeInfo::logicalLineTop): Use new names.
1572         (WebCore::ShapeInfo::logicalLineBottom): Ditto.
1573         (WebCore::ShapeInfo::shapeContainingBlockLogicalHeight): Ditto.
1574         (WebCore::ShapeInfo::markShapeAsDirty): Renamed from dirtyShapeSize.
1575         (WebCore::ShapeInfo::isShapeDirty): Renamed from shapeSizeDirty.
1576         (WebCore::ShapeInfo::referenceBoxLogicalSize): Renamed from shapeSize.
1577         (WebCore::ShapeInfo::logicalTopOffset): Use new names.
1578         (WebCore::ShapeInfo::logicalLeftOffset): Ditto.
1579         * rendering/shapes/ShapeInsideInfo.cpp:
1580         (WebCore::ShapeInsideInfo::updateSegmentsForLine): Ditto.
1581         (WebCore::ShapeInsideInfo::adjustLogicalLineTop): Ditto.
1582         (WebCore::ShapeInsideInfo::computeFirstFitPositionForFloat): Ditto.
1583         * rendering/shapes/ShapeInsideInfo.h:
1584         * rendering/shapes/ShapeOutsideInfo.cpp:
1585         (WebCore::ShapeOutsideInfo::updateDeltasForContainingBlockLine): Ditto.
1586         * rendering/shapes/ShapeOutsideInfo.h:
1587
1588 2014-02-12  Brent Fulgham  <bfulgham@apple.com>
1589
1590         REGRESSION: Crashing/Broken Tests Due To Unexpected 8-bit Character Data
1591         https://bugs.webkit.org/show_bug.cgi?id=128698
1592
1593         Reviewed by Tim Horton.
1594
1595         * platform/graphics/win/UniscribeController.cpp:
1596         (WebCore::UniscribeController::advance): Make 16-bit copy when needed.
1597         (WebCore::UniscribeController::shapeAndPlaceItem): Handle 8-bit case when checking
1598         for word boundaries.
1599
1600 2014-02-12  Benjamin Poulain  <bpoulain@apple.com>
1601
1602         Document::childrenChanged does not necessarily have a page
1603
1604         Rubber stamped by Enrica Casucci.
1605
1606         * dom/Document.cpp:
1607         (WebCore::Document::childrenChanged):
1608
1609 2014-02-12  Timothy Hatcher  <timothy@apple.com>
1610
1611         Add a missing ": " between the URL and exception in STDOUT logs.
1612
1613         https://bugs.webkit.org/show_bug.cgi?id=128689
1614
1615         Reviewed by Joseph Pecoraro.
1616
1617         * page/PageConsole.cpp:
1618         (WebCore::PageConsole::addMessage): Print ": " after calling
1619         printSourceURLAndPosition now that it does not print it for us.
1620
1621 2014-02-12  Enrica Casucci  <enrica@apple.com>
1622
1623         WK2: coordinate mapping for frames does not work when the page is scrolled.
1624         https://bugs.webkit.org/show_bug.cgi?id=128690
1625         <rdar://problem/16042925>
1626
1627         Reviewed by Simon Fraser.
1628
1629         We should not apply the scroll offset when using delegate scrolling.
1630
1631         * platform/ScrollView.cpp:
1632         (WebCore::ScrollView::rootViewToContents):
1633         (WebCore::ScrollView::contentsToRootView):
1634         (WebCore::ScrollView::rootViewToTotalContents):
1635
1636 2014-02-12  Joseph Pecoraro  <pecoraro@apple.com>
1637
1638         Web Inspector: Rename PageInjectedScript* to WebInjectedScript*
1639         https://bugs.webkit.org/show_bug.cgi?id=128660
1640
1641         Reviewed by Timothy Hatcher.
1642
1643         Rename the files update build systems and users.
1644
1645         * CMakeLists.txt:
1646         * GNUmakefile.list.am:
1647         * WebCore.vcxproj/WebCore.vcxproj:
1648         * WebCore.vcxproj/WebCore.vcxproj.filters:
1649         * WebCore.xcodeproj/project.pbxproj:
1650         * inspector/CommandLineAPIModule.cpp:
1651         (WebCore::CommandLineAPIModule::host):
1652         * inspector/InspectorAllInOne.cpp:
1653         * inspector/InspectorController.cpp:
1654         (WebCore::InspectorController::InspectorController):
1655         * inspector/InspectorController.h:
1656         * inspector/InspectorHeapProfilerAgent.cpp:
1657         (WebCore::InspectorHeapProfilerAgent::InspectorHeapProfilerAgent):
1658         * inspector/InspectorHeapProfilerAgent.h:
1659         * inspector/InspectorProfilerAgent.cpp:
1660         (WebCore::PageProfilerAgent::PageProfilerAgent):
1661         (WebCore::InspectorProfilerAgent::create):
1662         (WebCore::WorkerProfilerAgent::WorkerProfilerAgent):
1663         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
1664         * inspector/InspectorProfilerAgent.h:
1665         * inspector/PageConsoleAgent.cpp:
1666         (WebCore::PageConsoleAgent::PageConsoleAgent):
1667         (WebCore::PageConsoleAgent::addInspectedNode):
1668         * inspector/PageConsoleAgent.h:
1669         * inspector/WebConsoleAgent.cpp:
1670         (WebCore::WebConsoleAgent::WebConsoleAgent):
1671         (WebCore::WebConsoleAgent::frameWindowDiscarded):
1672         (WebCore::WebConsoleAgent::addInspectedHeapObject):
1673         * inspector/WebConsoleAgent.h:
1674         * inspector/WebInjectedScriptHost.cpp: Renamed from Source/WebCore/inspector/PageInjectedScriptHost.cpp.
1675         (WebCore::WebInjectedScriptHost::type):
1676         (WebCore::WebInjectedScriptHost::isHTMLAllCollection):
1677         * inspector/WebInjectedScriptHost.h: Renamed from Source/WebCore/inspector/PageInjectedScriptHost.h.
1678         * inspector/WebInjectedScriptManager.cpp: Renamed from Source/WebCore/inspector/PageInjectedScriptManager.cpp.
1679         (WebCore::WebInjectedScriptManager::WebInjectedScriptManager):
1680         (WebCore::WebInjectedScriptManager::disconnect):
1681         (WebCore::WebInjectedScriptManager::didCreateInjectedScript):
1682         (WebCore::WebInjectedScriptManager::discardInjectedScriptsFor):
1683         * inspector/WebInjectedScriptManager.h: Renamed from Source/WebCore/inspector/PageInjectedScriptManager.h.
1684         * inspector/WorkerConsoleAgent.cpp:
1685         (WebCore::WorkerConsoleAgent::WorkerConsoleAgent):
1686         * inspector/WorkerConsoleAgent.h:
1687         * inspector/WorkerInspectorController.cpp:
1688         (WebCore::WorkerInspectorController::WorkerInspectorController):
1689         * inspector/WorkerInspectorController.h:
1690
1691 2014-02-12  Brent Fulgham  <bfulgham@apple.com>
1692
1693         Unreviewed iOS Build fix after r163975.
1694
1695         * page/EventHandler.cpp: Use wheel event stubs if !PLATFORM(MAC) || PLATFORM(IOS).
1696
1697 2014-02-12  Gavin Barraclough  <barraclough@apple.com>
1698
1699         Clean up PageThrottler interface
1700         https://bugs.webkit.org/show_bug.cgi?id=128677
1701
1702         Reviewed by Benjamin Poulain.
1703
1704         Currently, responsibility for throttling DOM timers & suspending animations is split
1705         between the Page & the PageThrottler. Clarify by making Page responsible for suspending
1706         animations (PageThrottler is now purely related to aspects of timer throttling), and
1707         move all timer throttling policy to the PageThrottler, with a single function on Page to
1708         enable (Page::setTimerThrottlingEnabled).
1709
1710         Also, transmit the full ViewState to the PageThrottler (not just the IsVisuallyIdle flag),
1711         and distinguish between media & page-load activity.
1712
1713         * WebCore.exp.in:
1714             - removed setDOMTimerAlignmentInterval.
1715         * html/HTMLMediaElement.cpp:
1716         (WebCore::HTMLMediaElement::parseAttribute):
1717             - createActivityToken -> mediaActivityToken
1718         * loader/FrameLoader.cpp:
1719         (WebCore::FrameLoader::started):
1720             - createActivityToken -> pageLoadActivityToken
1721         * page/Page.cpp:
1722         (WebCore::Page::Page):
1723             - added m_timerThrottlingEnabled, made PageThrottler a member
1724         (WebCore::Page::setIsVisuallyIdleInternal):
1725             - update animiation suspension.
1726         (WebCore::Page::setTimerThrottlingEnabled):
1727             - setTimerAlignmentInterval -> setTimerThrottlingEnabled
1728         (WebCore::Page::setViewState):
1729             - pass viewState to PageThrottler.
1730         (WebCore::Page::setIsVisibleInternal):
1731             - don't update timer throttling.
1732         * page/Page.h:
1733         (WebCore::Page::pageThrottler):
1734             - made PageThrottler a member.
1735         (WebCore::Page::timerAlignmentInterval):
1736             - inlined.
1737         * page/PageThrottler.cpp:
1738         (WebCore::PageThrottler::PageThrottler):
1739             - initialize ViewState.
1740         (WebCore::PageThrottler::~PageThrottler):
1741             - clean up by calling setTimerThrottlingEnabled directly.
1742         (WebCore::PageThrottler::hiddenPageDOMTimerThrottlingStateChanged):
1743             - moved from Page.
1744         (WebCore::PageThrottler::mediaActivityToken):
1745         (WebCore::PageThrottler::pageLoadActivityToken):
1746             - from Page::createActivityToken
1747         (WebCore::PageThrottler::throttlePage):
1748         (WebCore::PageThrottler::unthrottlePage):
1749             - don't throttle animations here.
1750         (WebCore::PageThrottler::setViewState):
1751         (WebCore::PageThrottler::setIsVisible):
1752             - added, throttle Dom timers.
1753         * page/PageThrottler.h:
1754         * page/Settings.cpp:
1755         (WebCore::Settings::setHiddenPageDOMTimerThrottlingEnabled):
1756             - removed setDOMTimerAlignmentInterval, hiddenPageDOMTimerThrottlingStateChanged moved to PageThrottler.
1757         * page/Settings.h:
1758             - removed setDOMTimerAlignmentInterval.
1759
1760 2014-02-12  Benjamin Poulain  <bpoulain@apple.com>
1761
1762         [WK2][iOS] Add back the special viewport for the old xhtml mobile doctype
1763         https://bugs.webkit.org/show_bug.cgi?id=128639
1764
1765         Reviewed by Andreas Kling.
1766
1767         * WebCore.exp.in:
1768         * dom/Document.cpp:
1769         (WebCore::Document::childrenChanged):
1770         Document::setDocType() has been removed and the doctype update code with it.
1771         Add a call to didReceiveDocType() to ensure the viewport is updated when the doctype is parsed.
1772
1773         * loader/EmptyClients.h:
1774         * page/Chrome.cpp:
1775         (WebCore::Chrome::didReceiveDocType):
1776         * page/ChromeClient.h:
1777         * page/ViewportConfiguration.cpp:
1778         (WebCore::ViewportConfiguration::xhtmlMobileParameters):
1779         * page/ViewportConfiguration.h:
1780
1781 2014-02-12  Alexey Proskuryakov  <ap@apple.com>
1782
1783         Mountain Lion build fix.
1784
1785         * WebCore.exp.in: Only export WebCrypto symbols on 10.9+, because SUBTLE_CRYPTO
1786         is not enabled on 10.8.
1787
1788 2014-02-12  Alexey Proskuryakov  <ap@apple.com>
1789
1790         Wrap WebCrypto keys in SerializedScriptValue
1791         https://bugs.webkit.org/show_bug.cgi?id=128680
1792
1793         Reviewed by Anders Carlsson.
1794
1795         Test: crypto/subtle/rsa-indexeddb.html
1796
1797         Added Mac code to wrap a key with AES-GCM. We then serialize it into a plist,
1798         because more custom formats would be crazy (even the custom format in SerializedScriptValue
1799         makes me nervous, we'll certainly need to change CryptoKey in the future).
1800
1801         * WebCore.exp.in:
1802         * WebCore.xcodeproj/project.pbxproj:
1803         * crypto/CommonCryptoUtilities.h:
1804         * crypto/SerializedCryptoKeyWrap.h: Added.
1805         * crypto/mac/SerializedCryptoKeyWrapMac.mm: Added.
1806         (WebCore::vectorFromNSData):
1807         (WebCore::wrapSerializedCryptoKey):
1808         (WebCore::unwrapSerializedCryptoKey):
1809
1810 2014-02-12  Brent Fulgham  <bfulgham@apple.com>
1811
1812         Wheel events don't latch to inner scrollable elements 
1813         https://bugs.webkit.org/show_bug.cgi?id=128225
1814         <rdar://problem/12183688>
1815
1816         Reviewed by Simon Fraser
1817
1818         * WebCore.exp.in: Add declarations for new scrolledToTop, scrolledToBottom, scrolledToLeft, and scrolledToRight.
1819         * page/EventHandler.cpp:
1820         (WebCore::EventHandler::EventHandler):
1821         (WebCore::EventHandler::clear):
1822         (WebCore::findScrollableContainer): New helper function to locate first node
1823         in enclosing region of document that is capable of handling mouse wheel events.
1824         (WebCore::isAtMaxDominantScrollPosition): Predicate to check if the scrollable
1825         area is at the limit we will hit based on scroll direction.
1826         (WebCore::EventHandler::handleWheelEvent): Identify the case where we have hit
1827         the end of a scroll, and treat that as a valid 'handled' case. If the scroll event
1828         is just starting, treat end-of-scroll as unhandled so the parent element can
1829         handle things.
1830         * page/EventHandler.h:
1831         * page/scrolling/ScrollingTree.cpp:
1832         (WebCore::ScrollingTree::shouldHandleWheelEventSynchronously): Use new methods
1833         on the PlatformWheelEvent class.
1834         (WebCore::ScrollingTree::setOrClearLatchedNode): Ditto
1835         * platform/PlatformWheelEvent.h:
1836         (WebCore::PlatformWheelEvent::shouldConsiderLatching): Moved implementation from ScrollingTree.
1837         (WebCore::PlatformWheelEvent::shouldClearLatchedNode): Ditto
1838         * platform/ScrollableArea.cpp:
1839         (WebCore::ScrollableArea::scrolledToTop): Added
1840         (WebCore::ScrollableArea::scrolledToBottom):Added
1841         (WebCore::ScrollableArea::scrolledToLeft): Added
1842         (WebCore::ScrollableArea::scrolledToRight): Added
1843         * platform/ScrollableArea.h:
1844         * rendering/RenderListBox.cpp:
1845         (WebCore::RenderListBox::scrolledToTop): Added
1846         (WebCore::RenderListBox::scrolledToBottom): Added
1847         (WebCore::RenderListBox::scrolledToLeft): Added
1848         (WebCore::RenderListBox::scrolledToRight): Added
1849         * rendering/RenderListBox.h: Changed to public inheritance of ScrollableArea to
1850         allow generic use of this type in scroll wheel logic.
1851
1852 2014-02-12  Brendan Long  <b.long@cablelabs.com>
1853
1854         Implement DataCue for metadata cues
1855         https://bugs.webkit.org/show_bug.cgi?id=128402
1856
1857         Reviewed by Eric Carlson.
1858
1859         Test: media/track/track-datacue.html
1860
1861         * CMakeLists.txt: Add DataCue.
1862         * DerivedSources.cpp: Add JSDataCue.
1863         * DerivedSources.make: Same.
1864         * GNUmakefile.list.am: Add DataCue and JSDataCue.
1865         * WebCore.vcxproj/WebCore.vcxproj: Add DataCue.
1866         * WebCore.vcxproj/WebCore.vcxproj.filters: Same.
1867         * WebCore.xcodeproj/project.pbxproj: Add DataCue and JSDataCue.
1868         * bindings/js/JSTextTrackCueCustom.cpp:
1869         (WebCore::toJS): Add DataCue wrapper.
1870         * html/track/DataCue.cpp: Copied from Source/WebCore/html/track/TextTrack.idl.
1871         * html/track/DataCue.h: Copied from Source/WebCore/html/track/TextTrack.idl.
1872         * html/track/DataCue.idl: Copied from Source/WebCore/html/track/TextTrack.idl.
1873         * html/track/InbandGenericTextTrack.cpp:
1874         (WebCore::InbandGenericTextTrack::addGenericCue): Pass ASSERT_NO_EXCEPTION to addCue().
1875         * html/track/InbandWebVTTTextTrack.cpp:
1876         (WebCore::InbandWebVTTTextTrack::newCuesParsed): Same.
1877         * html/track/TextTrack.cpp:
1878         (WebCore::TextTrack::addCue): Throw an exception if DataCue is added to a track that isn't kind="metadata".
1879         * html/track/TextTrack.h: Add exception code parameter to addCue().
1880         * html/track/TextTrack.idl: Add [RaisesException] to addCue().
1881         * html/track/TextTrackCue.h: Add Data CueType.
1882
1883 2014-02-12  Zalan Bujtas  <zalan@apple.com>
1884
1885         Subpixel layout: Clean up LayoutPoint class.
1886         https://bugs.webkit.org/show_bug.cgi?id=128515
1887
1888         Reviewed by Simon Fraser.
1889
1890         Remove redundant functions (keep the more explicit ones).
1891
1892         No change in functionality.
1893
1894         * page/FrameView.cpp:
1895         (WebCore::FrameView::viewportConstrainedVisibleContentRect):
1896         * platform/graphics/LayoutPoint.h:
1897         (WebCore::toLayoutPoint):
1898         (WebCore::toLayoutSize):
1899         (WebCore::roundedIntPoint):
1900         * platform/graphics/ca/GraphicsLayerCA.cpp:
1901         (WebCore::GraphicsLayerCA::updateContentsRects):
1902         * rendering/LayoutState.cpp:
1903         (WebCore::LayoutState::LayoutState):
1904         * rendering/RenderBlock.cpp:
1905         (WebCore::RenderBlock::addFocusRingRects):
1906         * rendering/RenderBox.cpp:
1907         (WebCore::RenderBox::offsetFromContainer):
1908         * rendering/RenderInline.cpp:
1909         (WebCore::RenderInline::addFocusRingRects):
1910         * rendering/RenderLayer.cpp:
1911         (WebCore::RenderLayer::updateLayerPosition):
1912         (WebCore::accumulateOffsetTowardsAncestor):
1913         (WebCore::RenderLayer::paintBackgroundForFragments):
1914         (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
1915         (WebCore::RenderLayer::paintOutlineForFragments):
1916         (WebCore::RenderLayer::paintMaskForFragments):
1917         (WebCore::RenderLayer::paintOverflowControlsForFragments):
1918         * rendering/RenderScrollbarPart.cpp:
1919         (WebCore::RenderScrollbarPart::paintIntoRect):
1920
1921 2014-02-12  Zan Dobersek  <zdobersek@igalia.com>
1922
1923         [CoordinatedGraphics] Move CoordinatedGraphicsScene, CoordinatedLayerTreeHostProxy to std::function
1924         https://bugs.webkit.org/show_bug.cgi?id=128473
1925
1926         Reviewed by Anders Carlsson.
1927
1928
1929         Move the CoordinatedGraphicsScene class to using std::function instead of WTF::Functional and std::bind
1930         instead of WTF::bind. The function wrapper is now moved through function calls and not passed by reference,
1931         and lambda functions are inlined into the dispatchOnMainThread() calls, with the CoordinatedGraphicsScene
1932         refcount-protected.
1933
1934         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
1935         (WebCore::CoordinatedGraphicsScene::dispatchOnMainThread):
1936         (WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext):
1937         (WebCore::CoordinatedGraphicsScene::commitSceneState):
1938         (WebCore::CoordinatedGraphicsScene::syncRemoteContent):
1939         (WebCore::CoordinatedGraphicsScene::purgeGLResources):
1940         (WebCore::CoordinatedGraphicsScene::commitScrollOffset):
1941         (WebCore::CoordinatedGraphicsScene::appendUpdate):
1942         (WebCore::CoordinatedGraphicsScene::setActive):
1943         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
1944
1945 2014-02-12  Eric Carlson  <eric.carlson@apple.com>
1946
1947         Cleanup the code added for https://bugs.webkit.org/show_bug.cgi?id=128125.
1948
1949         Not reviewed.
1950
1951         * html/HTMLMediaSession.cpp:
1952         (WebCore::restrictionName): Don't need a "break" after a "return" in a case statement.
1953         * platform/audio/MediaSession.cpp:
1954         (WebCore::stateName): Ditto.
1955         * platform/audio/ios/MediaSessionManagerIOS.mm:
1956
1957 2014-02-12  Andreas Kling  <akling@apple.com>
1958
1959         RenderNamedFlowThread should only support RenderElement children.
1960         <https://webkit.org/b/128675>
1961
1962         Tighten up flow-thread rendering so that it only supports element
1963         children directly. This means we don't have to worry about text
1964         renderers on this code path.
1965
1966         Reviewed by Antti Koivisto.
1967
1968         * rendering/RenderElement.cpp:
1969         (WebCore::RenderElement::insertedIntoTree):
1970         (WebCore::RenderElement::willBeRemovedFromTree):
1971         (WebCore::RenderElement::willBeDestroyed):
1972         * rendering/RenderNamedFlowThread.cpp:
1973         (WebCore::RenderNamedFlowThread::nextRendererForElement):
1974         (WebCore::RenderNamedFlowThread::addFlowChild):
1975         (WebCore::RenderNamedFlowThread::removeFlowChild):
1976         * rendering/RenderNamedFlowThread.h:
1977         * rendering/RenderObject.cpp:
1978         (WebCore::RenderObject::willBeDestroyed):
1979         (WebCore::RenderObject::insertedIntoTree):
1980         (WebCore::RenderObject::willBeRemovedFromTree):
1981         * style/StyleResolveTree.cpp:
1982         (WebCore::Style::createRendererIfNeeded):
1983
1984 2014-02-12  Joseph Pecoraro  <pecoraro@apple.com>
1985
1986         Web Inspector: Modernize missed inspector files
1987         https://bugs.webkit.org/show_bug.cgi?id=128661
1988
1989         Reviewed by Anders Carlsson.
1990
1991         Add final, override, and use nullptr where appropriate.
1992
1993         * inspector/InspectorCSSAgent.cpp:
1994         (WebCore::InspectorCSSAgent::asCSSStyleRule):
1995         (WebCore::InspectorCSSAgent::discardAgent):
1996         (WebCore::InspectorCSSAgent::disable):
1997         (WebCore::InspectorCSSAgent::getInlineStylesForNode):
1998         (WebCore::InspectorCSSAgent::getComputedStyleForNode):
1999         (WebCore::InspectorCSSAgent::asInspectorStyleSheet):
2000         (WebCore::InspectorCSSAgent::elementForId):
2001         (WebCore::InspectorCSSAgent::viaInspectorStyleSheet):
2002         (WebCore::InspectorCSSAgent::assertStyleSheetForId):
2003         (WebCore::InspectorCSSAgent::buildObjectForRule):
2004         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
2005         * inspector/InspectorFrontendClientLocal.h:
2006
2007 2014-02-11  Brent Fulgham  <bfulgham@apple.com>
2008
2009         Remove some unintended copies in ranged for loops
2010         https://bugs.webkit.org/show_bug.cgi?id=128644
2011
2012         Reviewed by Anders Carlsson.
2013
2014         * css/StyleResolver.cpp:
2015         (WebCore::StyleResolver::loadPendingSVGDocuments): Avoid creating/destroying
2016         RefPtrs in loop.
2017
2018 2014-02-12  Raphael Kubo da Costa  <raphael.kubo.da.costa@intel.com>
2019
2020         Update the HTML Media Capture implementation.
2021         https://bugs.webkit.org/show_bug.cgi?id=118465
2022
2023         Reviewed by Darin Adler.
2024
2025         Make the implementation in WebKit compatible with the 2013-05-09
2026         version of the spec, which makes the "capture" attribute a boolean
2027         instead of an enum.
2028
2029         Covered by fast/forms/file/file-input-capture.html.
2030
2031         * html/FileInputType.cpp:
2032         (WebCore::FileInputType::handleDOMActivateEvent):
2033         * html/HTMLInputElement.cpp:
2034         (WebCore::HTMLInputElement::capture): Renamed to shouldUseMediaCapture().
2035         (WebCore::HTMLInputElement::shouldUseMediaCapture): Return a bool.
2036         * html/HTMLInputElement.h:
2037         * html/HTMLInputElement.idl: Turn the `capture' attribute into a
2038         reflective boolean instead of a DOMString.
2039         * platform/FileChooser.h:
2040
2041 2014-02-12  Radu Stavila  <stavila@adobe.com>
2042
2043         [CSS Regions] Remove unused method in RenderFlowThread
2044         https://bugs.webkit.org/show_bug.cgi?id=128373
2045
2046         Reviewed by Mihnea Ovidenie.
2047
2048         After the landing of https://bugs.webkit.org/show_bug.cgi?id=118665, the 
2049         RenderFlowThread::computeRegionClippingRect method is obsolete.
2050
2051         No new tests needed, this patch only removes an unused method.
2052
2053         * rendering/RenderFlowThread.cpp:
2054         * rendering/RenderFlowThread.h:
2055
2056 2014-02-12  Mihai Tica  <mitica@adobe.com>
2057
2058         [CSS Element Blending] Implement the software path of -webkit-blend-mode with Core Graphics.
2059         https://bugs.webkit.org/show_bug.cgi?id=99119
2060
2061         Reviewed by Simon Fraser.
2062
2063         This patch adds support for -webkit-blend-mode with Core Graphics.
2064         The layer promotion code that forced compositing when blending was detected has been removed.
2065         Remaining work for the software path is to detect and implement isolation of the blending operation:
2066         as stated in the spec, blending should be limited to the parent stacking context.
2067
2068         Tests: css3/compositing/blend-mode-blended-element-overlapping-composited-sibling-should-have-compositing-layer.html
2069                css3/compositing/blend-mode-parent-of-composited-blended-has-layer.html
2070                css3/compositing/blend-mode-simple-composited.html
2071                css3/compositing/blend-mode-with-composited-descendant-should-have-layer.html
2072
2073         * inspector/InspectorLayerTreeAgent.cpp:
2074         (WebCore::InspectorLayerTreeAgent::reasonsForCompositingLayer): Remove CompositingReasonBlending.
2075         * rendering/RenderLayer.cpp:
2076         (WebCore::RenderLayer::beginTransparencyLayers): Set the blendMode on the GraphicsContext.
2077         * rendering/RenderLayer.h: paintsWithTransparency should return true when a blendMode is set.
2078         * rendering/RenderLayerCompositor.cpp: Remove promotion code when a blendMode is detected.
2079         (WebCore::RenderLayerCompositor::requiresCompositingLayer): Remove CompositingReasonBlending reason.
2080         (WebCore::RenderLayerCompositor::requiresOwnBackingStore): Remove CompositingReasonBlending reason.
2081         (WebCore::RenderLayerCompositor::reasonsForCompositing): Remove CompositingReasonBlending reason.
2082         (WebCore::RenderLayerCompositor::logReasonsForCompositing): Remove CompositingReasonBlending reason.
2083         * rendering/RenderLayerCompositor.h:
2084         - Remove the requiresCompositingForBlending method
2085         - Remove the CompositingReasonBlending from the CompositingReasons enum.
2086
2087 2014-02-11  Zalan Bujtas  <zalan@apple.com>
2088
2089         Subpixel rendering: Switch repaint rect from IntRect to LayoutRect to be able to
2090         repaint on device pixel boundaries.
2091         https://bugs.webkit.org/show_bug.cgi?id=128477
2092
2093         Reviewed by Simon Fraser.
2094
2095         RenderLayer needs to be able to repaint on device pixel boundaries. RenderView still
2096         repaints on integral position.
2097
2098         No change in functionality.
2099
2100         * rendering/RenderBlockLineLayout.cpp:
2101         (WebCore::RenderBlockFlow::layoutRunsAndFloats):
2102         * rendering/RenderElement.cpp:
2103         (WebCore::RenderElement::repaintAfterLayoutIfNeeded):
2104         * rendering/RenderLayer.cpp:
2105         (WebCore::RenderLayer::updateLayerPositions):
2106         (WebCore::RenderLayer::clearRepaintRects):
2107         (WebCore::RenderLayer::scrollTo):
2108         (WebCore::RenderLayer::calculateClipRects):
2109         * rendering/RenderLayerBacking.cpp:
2110         (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
2111         * rendering/RenderLayerBacking.h:
2112         * rendering/RenderObject.cpp:
2113         (WebCore::RenderObject::repaintUsingContainer):
2114         (WebCore::RenderObject::repaint):
2115         (WebCore::RenderObject::repaintRectangle):
2116         * rendering/RenderObject.h:
2117
2118 2014-02-11  Dan Bernstein  <mitz@apple.com>
2119
2120         iOS build fix fix.
2121
2122         * rendering/RenderElement.cpp:
2123         (WebCore::shouldRepaintForImageAnimation):
2124
2125 2014-02-11  Dan Bernstein  <mitz@apple.com>
2126
2127         iOS build fix.
2128
2129         * rendering/RenderElement.cpp:
2130         (WebCore::shouldRepaintForImageAnimation):
2131
2132 2014-02-11  David Kilzer  <ddkilzer@apple.com>
2133
2134         ContentData equals() methods are not inline-able
2135         <http://webkit.org/b/128538>
2136
2137         Reviewed by Darin Adler.
2138
2139         Get rid of pure virtual equals() method in favor of
2140         ContentData::Type enum for runtime type information.
2141         This also lets us devirtualize the isFoo() methods.
2142
2143         * rendering/style/ContentData.h:
2144         (WebCore::ContentData::type): Add.
2145         (WebCore::ContentData::isCounter): Devirtualize.
2146         (WebCore::ContentData::isImage): Devirtualize.
2147         (WebCore::ContentData::isQuote): Devirtualize.
2148         (WebCore::ContentData::isText): Devirtualize.
2149         (WebCore::ContentData::ContentData): Add.  Include
2150         ContentData::Type parameter.
2151         (WebCore::operator==): Add overloaded methods for each subclass.
2152         Stop using pure virtual equals() method, check type(), and use
2153         overloaded subclass operator==() methods.
2154         (WebCore::operator!=): Add overloaded methods for each subclass.
2155
2156 2014-02-11  Andreas Kling  <akling@apple.com>
2157
2158         Protect some RenderFlowThread functions.
2159         <https://webkit.org/b/128642>
2160
2161         Make the RenderFlowThread constructor protected and a handful of
2162         member functions private.
2163
2164         Reviewed by Anders Carlsson.
2165
2166         * rendering/RenderFlowThread.h:
2167
2168 2014-02-11  Andreas Kling  <akling@apple.com>
2169
2170         Don't allocate RenderNamedFlowThread's child list separately.
2171         <https://webkit.org/b/128640>
2172
2173         Since we always create the flow-thread child list, there's no reason
2174         to put it in a separate heap allocation. Also remove the typedef and
2175         use auto instead.
2176
2177         Reviewed by Anders Carlsson.
2178
2179         * rendering/RenderNamedFlowThread.cpp:
2180         (WebCore::RenderNamedFlowThread::RenderNamedFlowThread):
2181         (WebCore::RenderNamedFlowThread::nextRendererForNode):
2182         (WebCore::RenderNamedFlowThread::addFlowChild):
2183         (WebCore::RenderNamedFlowThread::removeFlowChild):
2184         * rendering/RenderNamedFlowThread.h:
2185
2186 2014-02-11  Zalan Bujtas  <zalan@apple.com>
2187
2188         Subpixel rendering: Make GraphicsLayerClient::paintContents's clip rect subpixel based.
2189         https://bugs.webkit.org/show_bug.cgi?id=128460
2190
2191         Reviewed by Simon Fraser.
2192
2193         GraphicsClient::paintContents takes clipRect as FloatRect now so that we can paint on
2194         subpixel position.
2195
2196         No change in functionality.
2197
2198         * platform/graphics/GraphicsLayerClient.h:
2199         * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
2200         (WebCore::CompositingCoordinator::paintContents):
2201         * platform/graphics/texmap/coordinated/CompositingCoordinator.h:
2202         * rendering/RenderLayer.cpp:
2203         (WebCore::cornerRect):
2204         (WebCore::RenderLayer::scrollCornerRect):
2205         (WebCore::resizerCornerRect):
2206         (WebCore::RenderLayer::scrollCornerAndResizerRect):
2207         (WebCore::RenderLayer::verticalScrollbarStart):
2208         (WebCore::RenderLayer::horizontalScrollbarStart):
2209         (WebCore::RenderLayer::paintResizer):
2210         (WebCore::RenderLayer::hitTestOverflowControls):
2211         * rendering/RenderLayer.h:
2212         * rendering/RenderLayerBacking.cpp:
2213         (WebCore::RenderLayerBacking::paintIntoLayer):
2214         (WebCore::RenderLayerBacking::paintContents):
2215         * rendering/RenderLayerBacking.h:
2216         * rendering/RenderLayerCompositor.cpp:
2217         (WebCore::RenderLayerCompositor::paintContents):
2218         * rendering/RenderLayerCompositor.h:
2219         * rendering/RenderWidget.cpp:
2220         (WebCore::RenderWidget::paint):
2221
2222 2014-02-11  Antti Koivisto  <antti@apple.com>
2223
2224         GIF animations should be suspended when outside of viewport
2225         https://bugs.webkit.org/show_bug.cgi?id=128632
2226
2227         Reviewed by Andreas Kling.
2228         
2229         Animations are driven by the paint cycle. Speculative tiles keep animations outside the actual viewport going.
2230         
2231         Pause animations when they are outside the viewport by not painting them.
2232
2233         Test: fast/repaint/no-animation-outside-viewport.html
2234
2235         * loader/cache/CachedImage.cpp:
2236         (WebCore::CachedImage::animationAdvanced):
2237         
2238             Call animation specific newImageAnimationFrameAvailable instead of the generic notifyObservers.
2239
2240         * loader/cache/CachedImage.h:
2241         
2242             Removed now unnecessary resumeAnimatingImagesForLoader mechanism.
2243             Remove unnecessary shouldPauseAnimation. Pausing is now always done when by avoiding repaint.
2244
2245         * loader/cache/CachedImageClient.h:
2246         (WebCore::CachedImageClient::newImageAnimationFrameAvailable):
2247         * page/FrameView.cpp:
2248         (WebCore::FrameView::scrollPositionChanged):
2249         
2250             Check if we have image animations to resume when scroll position changes.
2251
2252         * page/Page.cpp:
2253         (WebCore::Page::resumeAnimatingImages):
2254         
2255             Use the same mechanism when resuming background tabs etc.
2256
2257         * platform/graphics/BitmapImage.cpp:
2258         (WebCore::BitmapImage::internalAdvanceAnimation):
2259         
2260             Remove the shouldPauseAnimation test, always rely on pausing on invalidation.
2261
2262         * platform/graphics/ImageObserver.h:
2263         * rendering/RenderBoxModelObject.cpp:
2264         * rendering/RenderElement.cpp:
2265         (WebCore::RenderElement::RenderElement):
2266         (WebCore::RenderElement::~RenderElement):
2267         (WebCore::shouldRepaintForImageAnimation):
2268         
2269             Factor the pausing conditions to a function. Test that the animation is withing the
2270             visible rect.
2271
2272         (WebCore::RenderElement::newImageAnimationFrameAvailable):
2273         
2274             Add renderer to the paused animation set if we don't continue the animation.
2275
2276         (WebCore::RenderElement::repaintForPausedImageAnimationsIfNeeded):
2277         
2278             Resume the paused animations by triggering repaint.
2279
2280         * rendering/RenderElement.h:
2281         (WebCore::RenderElement::setHasPausedImageAnimations):
2282         (WebCore::RenderElement::hasPausedImageAnimations):
2283         * rendering/RenderObject.cpp:
2284         * rendering/RenderObject.h:
2285         * rendering/RenderView.cpp:
2286         (WebCore::RenderView::addRendererWithPausedImageAnimations):
2287         (WebCore::RenderView::removeRendererWithPausedImageAnimations):
2288         (WebCore::RenderView::resumePausedImageAnimationsIfNeeded):
2289         * rendering/RenderView.h:
2290
2291 2014-02-11  Andreas Kling  <akling@apple.com>
2292
2293         Remove unused RenderNamedFlowThread::previousRendererForNode().
2294         <https://webkit.org/b/128637>
2295
2296         Reviewed by Antti Koivisto.
2297
2298         * rendering/RenderNamedFlowThread.cpp:
2299         * rendering/RenderNamedFlowThread.h:
2300
2301 2014-02-11  Andreas Kling  <akling@apple.com>
2302
2303         Move renderNamedFlowThreadWrapper() to RenderElement.
2304         <https://webkit.org/b/128634>
2305
2306         This function is only ever called on RenderElements so move it there
2307         from RenderObject.
2308
2309         Reviewed by Antti Koivisto.
2310
2311         * rendering/RenderElement.cpp:
2312         (WebCore::RenderElement::renderNamedFlowThreadWrapper):
2313         * rendering/RenderElement.h:
2314         * rendering/RenderObject.cpp:
2315         * rendering/RenderObject.h:
2316
2317 2014-02-11  Myles C. Maxfield  <mmaxfield@apple.com>
2318
2319         Position and thickness of underline as text size changes
2320         https://bugs.webkit.org/show_bug.cgi?id=16768
2321
2322         Reviewed by Dean Jackson.
2323
2324         This patch adopts the iOS codepath for underlines. It also reorganizes
2325         drawLineForText to avoid a costly global state save & restore.
2326
2327         Test: fast/css3-text/css3-text-decoration/text-decoration-thickness.html
2328
2329         * platform/graphics/cg/GraphicsContextCG.cpp:
2330         (WebCore::computeLineBoundsAndAntialiasingModeForText):
2331         (WebCore::GraphicsContext::computeLineBoundsForText):
2332         (WebCore::GraphicsContext::drawLineForText):
2333         (WebCore::GraphicsContext::drawLinesForText):
2334         * rendering/InlineTextBox.cpp:
2335         (WebCore::InlineTextBox::paintDecoration):
2336
2337 2014-02-11  Ryosuke Niwa  <rniwa@webkit.org>
2338
2339         Frame::rectForSelection shouldn't instantiate FrameSelection
2340         https://bugs.webkit.org/show_bug.cgi?id=128587
2341
2342         Reviewed by Enrica Casucci.
2343
2344         Made VisiblePosition::absoluteCaretBounds more interoperable with the one in FrameSelection and made
2345         iOS's Frame::rectForScrollToVisible use that function instead.
2346
2347         The above change allows us to remove:
2348         - suppressCloseTyping(), restoreCloseTyping(), and m_closeTypingSuppressions in FrameSelection
2349         - suppressSelectionNotifications() and restoreSelectionNotifications() in EditorClient
2350
2351         See inline comments below for more details.
2352
2353         * Source/WebCore/WebCore.exp.in:
2354
2355         * editing/FrameSelection.cpp:
2356         (WebCore::FrameSelection::FrameSelection):
2357         (WebCore::FrameSelection::setSelectionWithoutUpdatingAppearance):
2358         (WebCore::CaretBase::updateCaretRect):
2359         (WebCore::FrameSelection::caretRendererWithoutUpdatingLayout):
2360         (WebCore::DragCaretController::caretRenderer):
2361         (WebCore::repaintCaretForLocalRect):
2362         (WebCore::FrameSelection::recomputeCaretRect): Merged FrameSelection::localCaretRect(). Modified
2363         the code to update caretNode when and only when caret rect is updated. Also added an assertion to
2364         ensure absoluteCaretBounds() on FrameSelection and VisiblePosition yield the same result.
2365
2366         (WebCore::CaretBase::paintCaret):
2367         * editing/FrameSelection.h:
2368
2369         * editing/VisiblePosition.cpp:
2370         (WebCore::VisiblePosition::absoluteCaretBounds): Fixed the bug where the old code wasn't respecting
2371         the convention to use containing block as the renderer to paint caret.
2372
2373         * editing/htmlediting.cpp:
2374         (WebCore::caretRendersInsideNode): Moved from FrameSelection.cpp.
2375         (WebCore::rendererForCaretPainting): Ditto and renamed from caretRenderer.
2376         (WebCore::localCaretRectInRendererForCaretPainting): Extracted from FrameSelection::updateCaretRect.
2377         (WebCore::absoluteBoundsForLocalCaretRect): Ditto from CaretBase::absoluteBoundsForLocalRect.
2378         * editing/htmlediting.h:
2379
2380         * loader/EmptyClients.h:
2381         * page/EditorClient.h:
2382         * page/Frame.h:
2383
2384         * page/ios/FrameIOS.mm:
2385         (WebCore::Frame::rectForScrollToVisible): Reimplemented in its simplest form using VisiblePosition's
2386         absoluteCaretBounds().
2387
2388 2014-02-11  Enrica Casucci  <enrica@apple.com>
2389
2390         Support WebSelections in WK2 on iOS.
2391         https://bugs.webkit.org/show_bug.cgi?id=127015
2392         <rdar://problem/15211964>
2393
2394         Reviewed by Benjamin Poulain.
2395
2396         Adding few exports.
2397
2398         * WebCore.exp.in:
2399
2400 2014-02-11  Andreas Kling  <akling@apple.com>
2401
2402         CTTE: RenderNamedFlowThread always has a WebKitNamedFlow.
2403         <https://webkit.org/b/128623>
2404
2405         Codify the fact that RenderNamedFlowThread always has a corresponding
2406         WebKitNamedFlow by storing it in a Ref, and adding an accessor that
2407         returns a reference to get rid of all the ->'s.
2408
2409         Also removed some unnecessary assertions exposed by this.
2410
2411         Reviewed by Antti Koivisto.
2412
2413         * dom/NamedFlowCollection.cpp:
2414         (WebCore::NamedFlowCollection::ensureFlowWithName):
2415         * dom/NamedFlowCollection.h:
2416         * rendering/RenderNamedFlowThread.cpp:
2417         (WebCore::RenderNamedFlowThread::RenderNamedFlowThread):
2418         (WebCore::RenderNamedFlowThread::registerNamedFlowContentElement):
2419         (WebCore::RenderNamedFlowThread::unregisterNamedFlowContentElement):
2420         (WebCore::RenderNamedFlowThread::flowThreadName):
2421         (WebCore::RenderNamedFlowThread::dispatchRegionLayoutUpdateEvent):
2422         (WebCore::RenderNamedFlowThread::dispatchRegionOversetChangeEvent):
2423         (WebCore::RenderNamedFlowThread::regionLayoutUpdateEventTimerFired):
2424         (WebCore::RenderNamedFlowThread::regionOversetChangeEventTimerFired):
2425         (WebCore::RenderNamedFlowThread::setMarkForDestruction):
2426         (WebCore::RenderNamedFlowThread::resetMarkForDestruction):
2427         (WebCore::RenderNamedFlowThread::isMarkedForDestruction):
2428         * rendering/RenderNamedFlowThread.h:
2429
2430 2014-02-10  Myles C. Maxfield  <mmaxfield@apple.com>
2431
2432         Convert position:fixed property to position:absolute upon copy
2433         https://bugs.webkit.org/show_bug.cgi?id=128194
2434
2435         Reviewed by Simon Fraser.
2436
2437         This adds a Setting and Preference that allows clients to opt-in to this behavior.
2438
2439         This new behavior is only activated if the entire body is copied. If there is a position:fixed
2440         element in the copied selection, it is replaced with position:absolute, and a containing
2441         block (position:relative) is wrapped around the copied text.
2442
2443         This patch originally converted position:-webkit-sticky to position:relative. However, we
2444         currently don't support copying and pasting of position:-webkit-sticky content (See below).
2445         Therefore, this patch only deals with position:fixed.
2446
2447         Right now we don't copy position:-webkit-sticky. This is because:
2448         1. When copying styled elements, we parse the style properties again
2449         2. CSSParserContext has a flag which can disable parsing -webkit-sticky
2450         3. There are two constructors to CSSParserContext: one that takes a document and sets up the
2451         aforementioned flag, and a simple one that doesn't take a document and sets all the enableFoo
2452         flags to false
2453         4. At the relevant place within copy code, we are far removed from the Document object, so we
2454         instead call the second constructor, thereby disabling parsing of -webkit-sticky
2455
2456         Test: editing/pasteboard/copy-paste-converts-sticky-and-fixed.html
2457
2458         * WebCore.exp.in: Export the Setting setter
2459         * editing/EditingStyle.cpp:
2460         (WebCore::EditingStyle::convertFixedAndStickyPosition): Converts a single style
2461         * editing/EditingStyle.h:
2462         * editing/markup.cpp:
2463         (WebCore::StyledMarkupAccumulator::StyledMarkupAccumulator): Remember if we found
2464         an element which needs the position:relative containing block
2465         (WebCore::StyledMarkupAccumulator::appendElement): Surround with the position:relative
2466         containing block if necessary
2467         (WebCore::createMarkupInternal):
2468         * page/Settings.cpp:
2469         (WebCore::Settings::Settings): New setting to opt-in to this new behavior
2470         (WebCore::Settings::setConvertPositionStyleOnCopy):
2471         * page/Settings.h:
2472         (WebCore::Settings::convertPositionStyleOnCopy):
2473         * testing/InternalSettings.cpp: Allow setting the setting from a Layout Test
2474         (WebCore::InternalSettings::Backup::Backup):
2475         (WebCore::InternalSettings::Backup::restoreTo):
2476         (WebCore::InternalSettings::setConvertPositionStyleOnCopy):
2477         * testing/InternalSettings.h:
2478         * testing/InternalSettings.idl:
2479
2480 2014-02-11  Youenn Fablet  <youennf@gmail.com>
2481
2482         XMLHttpRequest should not send DNT header
2483         https://bugs.webkit.org/show_bug.cgi?id=128533
2484
2485         Reviewed by Alexey Proskuryakov.
2486
2487         Added DNT (Do Not Track) header to the list of forbidden headers.
2488         Updated http/tests/xmlhttprequest/set-dangerous-headers.html to test that header.
2489
2490         * xml/XMLHttpRequest.cpp:
2491         (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData):
2492
2493 2014-02-10  Jeffrey Pfau  <jpfau@apple.com>
2494
2495         Bring third-party app cache blocking behavior in line with private browsing app cache blocking behavior
2496         https://bugs.webkit.org/show_bug.cgi?id=128557
2497
2498         Reviewed by Alexey Proskuryakov.
2499
2500         * loader/appcache/ApplicationCacheGroup.cpp:
2501         (WebCore::ApplicationCacheGroup::cacheForMainRequest):
2502         (WebCore::ApplicationCacheGroup::selectCache):
2503         (WebCore::ApplicationCacheGroup::selectCacheWithoutManifestURL):
2504         (WebCore::ApplicationCacheGroup::update):
2505         * loader/appcache/ApplicationCacheHost.cpp:
2506         (WebCore::ApplicationCacheHost::maybeLoadMainResource):
2507         (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainResponse):
2508         (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainError):
2509         (WebCore::ApplicationCacheHost::maybeLoadResource):
2510         (WebCore::ApplicationCacheHost::scheduleLoadFallbackResourceFromApplicationCache):
2511         (WebCore::ApplicationCacheHost::isApplicationCacheBlockedForRequest):
2512         * loader/appcache/ApplicationCacheHost.h:
2513
2514 2014-02-11  Brady Eidson  <beidson@apple.com>
2515
2516         IDB: The test after storage/indexeddb/mozilla/object-identity.html fails in cleanup code
2517         <rdar://problem/16040663> and https://bugs.webkit.org/show_bug.cgi?id=128621
2518
2519         Reviewed by Alexey Proskuryakov.
2520
2521         Covered by storage/indexeddb/mozilla/object-identity.html.
2522
2523         * Modules/indexeddb/IDBTransactionBackend.cpp:
2524         (WebCore::IDBTransactionBackend::abort): Clear the m_database pointer before calling the onAbort callback.
2525         (WebCore::IDBTransactionBackend::commit): Don't run the abort code if there's no m_database pointer.
2526
2527 2014-02-10  Jer Noble  <jer.noble@apple.com>
2528
2529         [EME][Mac] Move the implementation of CDMPrivateAVFoundation back into MediaPlayerPrivateAVFoundationObjC.
2530         https://bugs.webkit.org/show_bug.cgi?id=128559
2531
2532         Reviewed by Dean Jackson.
2533
2534         To prepare for multiple simultaneous CDMs with muliple MediaPlayer types, move the implementation for
2535         CDMPrivateAVFoundation back into its media engine.
2536
2537         * Modules/encryptedmedia/CDMPrivateAVFoundation.mm:
2538         (WebCore::MediaKeyExceptionToErrorCode): Added.
2539         (WebCore::CDMSessionAVFoundation::generateKeyRequest): Moved to MediaPlayerPrivateAVFoundationObjC.
2540         (WebCore::CDMSessionAVFoundation::releaseKeys): Ditto.
2541         (WebCore::CDMSessionAVFoundation::update): Ditto.
2542         * platform/graphics/MediaPlayer.cpp:
2543         (WebCore::MediaPlayer::generateKeyRequest): Added, pass through to MediaPlayerPrivate.
2544         (WebCore::MediaPlayer::releaseKeys): Ditto.
2545         (WebCore::MediaPlayer::update): Ditto.
2546         * platform/graphics/MediaPlayer.h:
2547         * platform/graphics/MediaPlayerPrivate.h:
2548         (WebCore::MediaPlayerPrivateInterface::generateKeyRequest): Added.
2549         (WebCore::MediaPlayerPrivateInterface::releaseKeys): Ditto.
2550         (WebCore::MediaPlayerPrivateInterface::update): Ditto.
2551         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2552         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2553         (WebCore::MediaPlayerPrivateAVFoundationObjC::generateKeyRequest): Moved from CDMSessionAVFoundation.
2554         (WebCore::MediaPlayerPrivateAVFoundationObjC::releaseKeys): Ditto.
2555         (WebCore::MediaPlayerPrivateAVFoundationObjC::update): Ditto.
2556
2557 2014-01-24  Jer Noble  <jer.noble@apple.com>
2558
2559         Run UserAgentScripts through jsmin rather than the css preprocessor
2560         https://bugs.webkit.org/show_bug.cgi?id=127559
2561
2562         Reviewed by Tim Horton.
2563
2564         User Agent JavaScript files were being run through the c++ preprocessor to strip out
2565         comments (and presumably to allow #if ENABLE macros, though that feature is entirely
2566         unused). This had the side effect of removing important whitespace, namely newlines where
2567         there would normally be an implicit semicolon.
2568
2569         Instead, .js files will now be run through the jsmin minifier, used by the inspector.
2570         Jsmin will also strip comments and whitespace, but in a syntactically aware way which will
2571         keep newlines when their presence adds an implied semicolon.
2572
2573         * DerivedSources.make:
2574         * Scripts/make-js-file-arrays.py: Added.
2575         (stringifyCodepoint):
2576         (chunk):
2577         (main):
2578
2579 2014-02-11  Andy Estes  <aestes@apple.com>
2580
2581         [Mac] connection:willStopBufferingData: no longer exists in NSURLConnectionDelegate
2582         https://bugs.webkit.org/show_bug.cgi?id=128583
2583
2584         Reviewed by Anders Carlsson.
2585
2586         The delegate method was removed in Snow Leopard.
2587
2588         * loader/ResourceLoader.cpp:
2589         * loader/ResourceLoader.h:
2590         * platform/network/ResourceHandleClient.h:
2591         * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
2592         * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
2593
2594 2014-02-10  Andy Estes  <aestes@apple.com>
2595
2596         [Content Filter] Check for NULL before calling dispatch_release()
2597         https://bugs.webkit.org/show_bug.cgi?id=128576
2598
2599         Reviewed by Darin Adler.
2600
2601         m_neFilterSourceQueue will be NULL if NEFilterSource isn't enabled, and
2602         passing NULL to dispatch_release() is undefined.
2603
2604         * platform/mac/ContentFilterMac.mm:
2605         (WebCore::ContentFilter::~ContentFilter):
2606
2607 2014-01-24  Jer Noble  <jer.noble@apple.com>
2608
2609         [MediaControls] Allow the media controls script to be debuggable by giving it a generated sourceURL
2610         https://bugs.webkit.org/show_bug.cgi?id=127560
2611
2612         Reviewed by Eric Carlson.
2613
2614         When evaluating a script through ScriptController, if that script does not have an
2615         explicit sourceURL, it will not appear in the resources section of the Web Inspector.
2616         For debug builds only, give the media controls script a generated (i.e. fake) sourceURL.
2617
2618         * html/HTMLMediaElement.cpp:
2619         (WebCore::HTMLMediaElement::parseAttribute):
2620
2621 2014-02-11  Samuel White  <samuel_white@apple.com>
2622
2623         AX: Add text replacement activity support to NSAccessibilitySelectTextWithCriteriaParameterizedAttribute.
2624         https://bugs.webkit.org/show_bug.cgi?id=128397
2625
2626         Reviewed by Chris Fleizach.
2627
2628         Added text replacement support for the AXSelectTextWithCriteria parameterized attribute.
2629
2630         No new test. Updated platform/mac/accessibility/select-text.html to test the added functionality.
2631
2632         * accessibility/AccessibilityObject.cpp:
2633         (WebCore::AccessibilityObject::selectText):
2634         * accessibility/AccessibilityObject.h:
2635         (WebCore::AccessibilitySelectTextCriteria::AccessibilitySelectTextCriteria):
2636         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2637         (accessibilitySelectTextCriteriaForCriteriaParameterizedAttribute):
2638
2639 2014-02-11  Roger Fong  <roger_fong@apple.com>
2640
2641         [Windows] Unreviewed. Speculative test fix.
2642
2643         * platform/graphics/GraphicsContext.h:
2644         (WebCore::GraphicsContext::pixelSnappingFactor):
2645         * platform/graphics/cg/GraphicsContextCG.cpp:
2646         (WebCore::GraphicsContext::platformInit):
2647
2648 2014-02-11  Dan Bernstein  <mitz@apple.com>
2649
2650         iOS build fix.
2651
2652         * platform/ios/TileGrid.mm:
2653         (WebCore::TileGrid::dropTilesBetweenRects):
2654         (WebCore::TileGrid::dropDistantTiles):
2655         (WebCore::TileGrid::dropInvalidTiles):
2656
2657 2014-02-11  James Craig  <jcraig@apple.com>
2658
2659         Web Inspector: AX: Accessibility Node Inspection
2660         https://bugs.webkit.org/show_bug.cgi?id=127447
2661
2662         Reviewed by Timothy Hatcher.
2663
2664         New methods supporting WebCore::AccessibilityObject::computedRoleString()
2665         used for Accessibility section in WebInspector Node Inspector. Other updates 
2666         support the JSON interface for the WebInspectorUI feature.
2667
2668         Test: accessibility/roles-computedRoleString.html
2669
2670         * accessibility/AccessibilityObject.cpp:
2671         (WebCore::initializeRoleMap):
2672         (WebCore::ariaRoleMap):
2673         (WebCore::reverseAriaRoleMap):
2674         (WebCore::AccessibilityObject::ariaRoleToWebCoreRole):
2675         (WebCore::AccessibilityObject::computedRoleString):
2676         * accessibility/AccessibilityObject.h:
2677         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2678         (-[WebAccessibilityObjectWrapper computedRoleString]):
2679         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
2680         * inspector/InspectorDOMAgent.cpp:
2681         (WebCore::InspectorDOMAgent::getAccessibilityPropertiesForNode):
2682         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
2683         * inspector/InspectorDOMAgent.h:
2684         * inspector/protocol/DOM.json:
2685
2686 2014-02-10  Oliver Hunt  <oliver@apple.com>
2687
2688         Stop throwing when attempting to read instance properties directly from the prototype
2689         https://bugs.webkit.org/show_bug.cgi?id=128568
2690
2691         Reviewed by Mark Lam.
2692
2693         A number of websites expect to be able to access instance properties
2694         directly through the prototype.  This is broken behavior but if we
2695         throw an exception the entire site breaks.  This patch simply makes us
2696         return undefined when reading, and logs the error to the console.
2697
2698         * bindings/scripts/CodeGeneratorJS.pm:
2699         (GenerateImplementation):
2700         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
2701         (WebCore::jsTestActiveDOMObjectExcitingAttr):
2702         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
2703         (WebCore::jsTestEventConstructorAttr1):
2704         (WebCore::jsTestEventConstructorAttr2):
2705         * bindings/scripts/test/JS/JSTestException.cpp:
2706         (WebCore::jsTestExceptionName):
2707         * bindings/scripts/test/JS/JSTestInterface.cpp:
2708         (WebCore::jsTestInterfaceImplementsStr1):
2709         (WebCore::jsTestInterfaceImplementsStr2):
2710         (WebCore::jsTestInterfaceImplementsStr3):
2711         (WebCore::jsTestInterfaceImplementsNode):
2712         (WebCore::jsTestInterfaceSupplementalStr1):
2713         (WebCore::jsTestInterfaceSupplementalStr2):
2714         (WebCore::jsTestInterfaceSupplementalStr3):
2715         (WebCore::jsTestInterfaceSupplementalNode):
2716         * bindings/scripts/test/JS/JSTestObj.cpp:
2717         (WebCore::jsTestObjReadOnlyLongAttr):
2718         (WebCore::jsTestObjReadOnlyStringAttr):
2719         (WebCore::jsTestObjReadOnlyTestObjAttr):
2720         (WebCore::jsTestObjConstructorTestSubObj):
2721         (WebCore::jsTestObjTestSubObjEnabledBySettingConstructor):
2722         (WebCore::jsTestObjEnumAttr):
2723         (WebCore::jsTestObjByteAttr):
2724         (WebCore::jsTestObjOctetAttr):
2725         (WebCore::jsTestObjShortAttr):
2726         (WebCore::jsTestObjUnsignedShortAttr):
2727         (WebCore::jsTestObjLongAttr):
2728         (WebCore::jsTestObjLongLongAttr):
2729         (WebCore::jsTestObjUnsignedLongLongAttr):
2730         (WebCore::jsTestObjStringAttr):
2731         (WebCore::jsTestObjTestObjAttr):
2732         (WebCore::jsTestObjXMLObjAttr):
2733         (WebCore::jsTestObjCreate):
2734         (WebCore::jsTestObjReflectedStringAttr):
2735         (WebCore::jsTestObjReflectedIntegralAttr):
2736         (WebCore::jsTestObjReflectedUnsignedIntegralAttr):
2737         (WebCore::jsTestObjReflectedBooleanAttr):
2738         (WebCore::jsTestObjReflectedURLAttr):
2739         (WebCore::jsTestObjReflectedCustomIntegralAttr):
2740         (WebCore::jsTestObjReflectedCustomBooleanAttr):
2741         (WebCore::jsTestObjReflectedCustomURLAttr):
2742         (WebCore::jsTestObjTypedArrayAttr):
2743         (WebCore::jsTestObjAttrWithGetterException):
2744         (WebCore::jsTestObjAttrWithSetterException):
2745         (WebCore::jsTestObjStringAttrWithGetterException):
2746         (WebCore::jsTestObjStringAttrWithSetterException):
2747         (WebCore::jsTestObjCustomAttr):
2748         (WebCore::jsTestObjWithScriptStateAttribute):
2749         (WebCore::jsTestObjWithScriptExecutionContextAttribute):
2750         (WebCore::jsTestObjWithScriptStateAttributeRaises):
2751         (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
2752         (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttribute):
2753         (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
2754         (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
2755         (WebCore::jsTestObjWithScriptArgumentsAndCallStackAttribute):
2756         (WebCore::jsTestObjConditionalAttr1):
2757         (WebCore::jsTestObjConditionalAttr2):
2758         (WebCore::jsTestObjConditionalAttr3):
2759         (WebCore::jsTestObjConditionalAttr4Constructor):
2760         (WebCore::jsTestObjConditionalAttr5Constructor):
2761         (WebCore::jsTestObjConditionalAttr6Constructor):
2762         (WebCore::jsTestObjCachedAttribute1):
2763         (WebCore::jsTestObjCachedAttribute2):
2764         (WebCore::jsTestObjAnyAttribute):
2765         (WebCore::jsTestObjContentDocument):
2766         (WebCore::jsTestObjMutablePoint):
2767         (WebCore::jsTestObjImmutablePoint):
2768         (WebCore::jsTestObjStrawberry):
2769         (WebCore::jsTestObjStrictFloat):
2770         (WebCore::jsTestObjDescription):
2771         (WebCore::jsTestObjId):
2772         (WebCore::jsTestObjHash):
2773         (WebCore::jsTestObjReplaceableAttribute):
2774         (WebCore::jsTestObjNullableDoubleAttribute):
2775         (WebCore::jsTestObjNullableLongAttribute):
2776         (WebCore::jsTestObjNullableBooleanAttribute):
2777         (WebCore::jsTestObjNullableStringAttribute):
2778         (WebCore::jsTestObjNullableLongSettableAttribute):
2779         (WebCore::jsTestObjNullableStringValue):
2780         (WebCore::jsTestObjAttribute):
2781         (WebCore::jsTestObjAttributeWithReservedEnumType):
2782         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
2783         (WebCore::jsTestSerializedScriptValueInterfaceValue):
2784         (WebCore::jsTestSerializedScriptValueInterfaceReadonlyValue):
2785         (WebCore::jsTestSerializedScriptValueInterfaceCachedValue):
2786         (WebCore::jsTestSerializedScriptValueInterfacePorts):
2787         (WebCore::jsTestSerializedScriptValueInterfaceCachedReadonlyValue):
2788         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
2789         (WebCore::jsTestTypedefsUnsignedLongLongAttr):
2790         (WebCore::jsTestTypedefsImmutableSerializedScriptValue):
2791         (WebCore::jsTestTypedefsConstructorTestSubObj):
2792         (WebCore::jsTestTypedefsAttrWithGetterException):
2793         (WebCore::jsTestTypedefsAttrWithSetterException):
2794         (WebCore::jsTestTypedefsStringAttrWithGetterException):
2795         (WebCore::jsTestTypedefsStringAttrWithSetterException):
2796         * bindings/scripts/test/JS/JSattribute.cpp:
2797         (WebCore::jsattributeReadonly):
2798
2799 2014-02-11  Sergio Villar Senin  <svillar@igalia.com>
2800
2801         [CSS Grid Layout] Support calc() breadth size type
2802         https://bugs.webkit.org/show_bug.cgi?id=103761
2803
2804         Reviewed by Dean Jackson.
2805
2806         We now support using calc() in
2807         -webkit-grid-template-{columns|rows}. This means that we now
2808         match the specification and support all the possible ways to
2809         specify the track breadths.
2810
2811         This includes a fix to CSSCalculationValue that was converting
2812         Length values to CalcExpressionNumber and thus removing all the
2813         info regarding length units (px, em, pt...). That's why things
2814         like calc(10px + 20%) were shown as calc(10 + 20%) in
2815         getComputedStyle() output.
2816
2817         * css/CSSCalculationValue.cpp:
2818         (WebCore::CSSCalcPrimitiveValue::toCalcValue):
2819         * css/CSSComputedStyleDeclaration.cpp:
2820         (WebCore::zoomAdjustedPixelValueForLength):
2821         (WebCore::specifiedValueForGridTrackBreadth):
2822         (WebCore::specifiedValueForGridTrackSize):
2823         * css/StyleResolver.cpp:
2824         (WebCore::createGridTrackBreadth):
2825         * rendering/RenderGrid.cpp:
2826         (WebCore::RenderGrid::computeUsedBreadthOfMinLength):
2827         (WebCore::RenderGrid::computeUsedBreadthOfMaxLength):
2828         (WebCore::RenderGrid::computeUsedBreadthOfSpecifiedLength):
2829
2830 2014-02-11  Brent Fulgham  <bfulgham@apple.com>
2831
2832         Correct some uses of 'auto'
2833         https://bugs.webkit.org/show_bug.cgi?id=128578
2834
2835         Reviewed by Anders Carlsson.
2836
2837         Correct the following instances of "for (auto ...)" to use reference or
2838         const references to avoid copies.
2839
2840         * accessibility/AccessibilityObject.cpp:
2841         (WebCore::AccessibilityObject::elementsFromAttribute):
2842         * css/CSSGridTemplateValue.cpp:
2843         (WebCore::stringForPosition):
2844         * dom/Node.cpp:
2845         (WebCore::NodeListsNodeData::invalidateCaches):
2846         * inspector/PageInjectedScriptManager.cpp:
2847         (WebCore::PageInjectedScriptManager::discardInjectedScriptsFor):
2848         * page/WheelEventDeltaTracker.cpp:
2849         (WebCore::WheelEventDeltaTracker::dominantScrollGestureDirection):
2850         * page/scrolling/ScrollingCoordinator.cpp:
2851         (WebCore::ScrollingCoordinator::computeNonFastScrollableRegion):
2852         * platform/graphics/mac/WebLayer.mm:
2853         (WebCore::drawLayerContents):
2854         * platform/ios/TileGrid.mm:
2855         (WebCore::TileGrid::dropTilesBetweenRects):
2856         (WebCore::TileGrid::dropDistantTiles):
2857         (WebCore::TileGrid::dropInvalidTiles):
2858         * rendering/InlineTextBox.cpp:
2859         (WebCore::translateIntersectionPointsToSkipInkBoundaries):
2860         * testing/InternalSettings.cpp:
2861         (WebCore::InternalSettings::Backup::restoreTo):
2862
2863 2014-02-10  David Hyatt  <hyatt@apple.com>
2864
2865         [New Multicolumn] Make columns work with line grids
2866         https://bugs.webkit.org/show_bug.cgi?id=128555
2867
2868         Reviewed by Antti Koivisto.
2869
2870         Added line-snap-into-columns.html and line-snap-inside-columns.html
2871
2872         * rendering/LayoutState.cpp:
2873         (WebCore::LayoutState::LayoutState):
2874         * rendering/LayoutState.h:
2875         (WebCore::LayoutState::pageOffset):
2876         (WebCore::LayoutState::setLineGridPaginationOrigin):
2877         Change the LayoutState to call into the renderer to compute the line
2878         grid pagination origin instead of doing it directly. Added the
2879         appropriate getters and setters to enable the renderer to do this.
2880
2881         * rendering/RenderBlock.cpp:
2882         (WebCore::RenderBlock::computeLineGridPaginationOrigin):
2883          * rendering/RenderBlock.h:
2884         An implementation for the old multi-column code. The logic is the
2885         same with tweaks made now that the method is on the renderer instead.
2886
2887         * rendering/RenderBlockFlow.cpp:
2888         (WebCore::RenderBlockFlow::pageLogicalTopForOffset):
2889         Fix a bug with flow threads and pageLogicalTopForOffset. Normal CSS region-based
2890         flow threads are never embedded in an enclosing pagination context, so they
2891         didn't add in the firstPageLogicalTop (or subtract it when computing the region
2892         hit). Multi-column flow threads do need to subtract out the firstPageLogicalTop,
2893         since it can occur somewhere on the page.
2894         
2895         Ultimately regions will need to get smarter here too if they want to work with
2896         line grids, but for now I just fixed multi-column.
2897
2898         * rendering/RenderBox.cpp:
2899         (WebCore::RenderBox::isUnsplittableForPagination):
2900         Undo this change, since it prevents the inheritance of line grids into the
2901         multi-column layout.
2902
2903         * rendering/RenderMultiColumnFlowThread.cpp:
2904         (WebCore::RenderMultiColumnFlowThread::computeLineGridPaginationOrigin):
2905         * rendering/RenderMultiColumnFlowThread.h:
2906         An implementation for the new multi-column code. The logic is the
2907         same as the old code. Code duplication is ok, since the old multi-column method
2908         in RenderBlock will just be deleted once the new code is turned on, and it's easier
2909         not to intertwine them.
2910
2911 2014-02-11  Radu Stavila  <stavila@adobe.com>
2912
2913         [CSS Regions] Overflow above the first region is not properly painted for regions with padding
2914         https://bugs.webkit.org/show_bug.cgi?id=128590
2915
2916         Reviewed by Andrei Bucur.
2917
2918         Painting is done using the layer of the region's container, so offsetting using the content box
2919         of the region itself is incorrect. 
2920
2921         Test: fast/regions/region-padding-overflow-hidden.html
2922
2923         * rendering/RenderLayer.cpp:
2924         (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
2925         * rendering/RenderRegion.cpp:
2926         (WebCore::RenderRegion::regionContainer):
2927         (WebCore::RenderRegion::regionContainerLayer):
2928         * rendering/RenderRegion.h:
2929
2930 2014-02-11  Benjamin Poulain  <benjamin@webkit.org>
2931
2932         querySelector() does not use the compiler correctly
2933         https://bugs.webkit.org/show_bug.cgi?id=128588
2934
2935         Reviewed by Andreas Kling.
2936
2937         * dom/SelectorQuery.cpp:
2938         (WebCore::SelectorDataList::execute):
2939         I messed up the refactoring when I landed SelectorQuery. The compiled
2940         code was not used the first time through SelectorDataList::execute.
2941
2942 2014-02-11  Piotr Grad  <p.grad@samsung.com>
2943
2944         [GStreamer] High playback rate causes crash
2945         https://bugs.webkit.org/show_bug.cgi?id=128453
2946
2947         Reviewed by Philippe Normand.
2948
2949         To high playback rate passed to GStreamer was causing crash.
2950         Added guard in setRate method.
2951
2952         Test: media/video-extreme-playbackrate-crash.html
2953
2954         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2955         (WebCore::MediaPlayerPrivateGStreamer::setRate):
2956
2957 2014-02-10  Brady Eidson  <beidson@apple.com>
2958
2959         IndexedDB assertion at IDBTransactionBackend::~IDBTransactionBackend()
2960         https://bugs.webkit.org/show_bug.cgi?id=128341
2961
2962         Reviewed by Maciej Stachowiak.
2963
2964         * Modules/indexeddb/IDBTransactionBackend.cpp:
2965         (WebCore::IDBTransactionBackend::~IDBTransactionBackend): "Finished" is not the only
2966           valid value here - In WK2, "Unused" is also valid. Update the ASSERT.
2967
2968 2014-02-10  Alexey Proskuryakov  <ap@apple.com>
2969
2970         Add hooks for wrapping CryptoKeys in SerializedScriptValue
2971         https://bugs.webkit.org/show_bug.cgi?id=128567
2972
2973         Reviewed by Anders Carlsson.
2974
2975         * bindings/js/SerializedScriptValue.cpp: Changed SerializedScriptValue to serialize
2976         wrapped keys. Added a version number to crypto key serialization.
2977
2978         * dom/Document.cpp:
2979         (WebCore::Document::wrapCryptoKey):
2980         (WebCore::Document::unwrapCryptoKey):
2981         * dom/Document.h:
2982         * dom/ScriptExecutionContext.h:
2983         * page/ChromeClient.h:
2984         (WebCore::ChromeClient::wrapCryptoKey):
2985         (WebCore::ChromeClient::unwrapCryptoKey):
2986         Hand wrapping/unwrapping over to client code.
2987
2988         * workers/WorkerGlobalScope.cpp:
2989         (WebCore::WorkerGlobalScope::wrapCryptoKey):
2990         (WebCore::WorkerGlobalScope::unwrapCryptoKey):
2991         * workers/WorkerGlobalScope.h:
2992         Not implemented in workers. SubtleCrypto is currently not exposed in workers. It used
2993         to be possible in WebKit implementation to post a CryptoKey to a worker anyway,
2994         but this doesn't work any more.
2995
2996 2014-02-10  ChangSeok Oh  <changseok.oh@collabora.com>
2997
2998         Support ANGLE_instanced_arrays for linux
2999         https://bugs.webkit.org/show_bug.cgi?id=127465
3000
3001         Reviewed by Martin Robinson.
3002
3003         Support the instanced drawing WebGL extension, ANGLE_instanced_arrays for linux platform.
3004         This is a following patch for r162565. Relevant opengl APIs are exposed
3005         for WebGLRenderingContext to access them.
3006
3007         Covered by fast/canvas/webgl/angle-instanced-arrays.html
3008
3009         * html/canvas/ANGLEInstancedArrays.cpp:
3010         (WebCore::ANGLEInstancedArrays::supported):
3011         * platform/graphics/OpenGLShims.cpp:
3012         (WebCore::initializeOpenGLShims):
3013         * platform/graphics/OpenGLShims.h:
3014         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
3015         (WebCore::Extensions3DOpenGL::supportsExtension):
3016         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
3017         (WebCore::GraphicsContext3D::drawArraysInstanced):
3018         (WebCore::GraphicsContext3D::drawElementsInstanced):
3019         (WebCore::GraphicsContext3D::vertexAttribDivisor):
3020
3021 2014-02-10  Mark Lam  <mark.lam@apple.com>
3022
3023         Removing limitation on JSLock’s lockDropDepth.
3024         <https://webkit.org/b/128570>
3025
3026         Reviewed by Geoffrey Garen.
3027
3028         No new tests.
3029
3030         * bindings/js/PageScriptDebugServer.cpp:
3031         (WebCore::PageScriptDebugServer::runEventLoopWhilePaused):
3032         * platform/ios/wak/WebCoreThread.mm:
3033         (SendDelegateMessage):
3034         (WebThreadRunOnMainThread):
3035         - No longer need to specify AlwaysDropLocks, because DropAllLocks is
3036           now always unconditional.
3037
3038 2014-02-10  Benjamin Poulain  <benjamin@webkit.org>
3039
3040         Clean up MarkupAccumulator::appendCharactersReplacingEntities
3041         https://bugs.webkit.org/show_bug.cgi?id=128440
3042
3043         Reviewed by Ryosuke Niwa.
3044
3045         Some cleanup:
3046         -Remove the copied code for the loops. Instead, use a template with the loop
3047          parametrized by the characters type.
3048         -Move EntityDescription from the header to the implementation.
3049         -Make the 5 substitution strings compile-time literals. Replacement is not hot enough
3050          to justify the static here.
3051
3052         * editing/MarkupAccumulator.cpp:
3053         (WebCore::appendCharactersReplacingEntitiesInternal):
3054         (WebCore::MarkupAccumulator::appendCharactersReplacingEntities):
3055         * editing/MarkupAccumulator.h:
3056
3057 2014-02-10  Benjamin Poulain  <benjamin@webkit.org>
3058
3059         Add a few pseudo type to the selector compiler through function calls
3060         https://bugs.webkit.org/show_bug.cgi?id=128514
3061
3062         Reviewed by Dean Jackson.
3063
3064         Certain pseudo type checkers rely on virtual function calls. Since those types
3065         are uncommon, and this code generator cannot currently make virtual function calls,
3066         the checker are added by generating a function call to a wrapper function.
3067
3068         To avoid code duplication between SelectorChecker and the compiler, all the relevant checking
3069         code has been moved to a common header, SelectorCheckerTestFunctions.h.
3070         SelectorChecker still inline the functions, while the SelectorCompiler generate local static functions
3071         and generate calls to them as needed.
3072
3073         * GNUmakefile.list.am:
3074         * WebCore.vcxproj/WebCore.vcxproj:
3075         * WebCore.vcxproj/WebCore.vcxproj.filters:
3076         * WebCore.xcodeproj/project.pbxproj:
3077         * css/SelectorChecker.cpp:
3078         (WebCore::SelectorChecker::checkOne):
3079         * css/SelectorCheckerTestFunctions.h: Added.
3080         (WebCore::isAutofilled):
3081         (WebCore::isDefaultButtonForForm):
3082         (WebCore::isDisabled):
3083         (WebCore::isEnabled):
3084         (WebCore::isChecked):
3085         (WebCore::isInvalid):
3086         (WebCore::isOptionalFormControl):
3087         (WebCore::isRequiredFormControl):
3088         (WebCore::isValid):
3089         (WebCore::matchesReadOnlyPseudoClass):
3090         (WebCore::matchesReadWritePseudoClass):
3091         (WebCore::shouldAppearIndeterminate):
3092         (WebCore::matchesFullScreenPseudoClass):
3093         (WebCore::matchesFutureCuePseudoClass):
3094         (WebCore::matchesPastCuePseudoClass):
3095         * cssjit/SelectorCompiler.cpp:
3096         (WebCore::SelectorCompiler::addPseudoType):
3097         (WebCore::SelectorCompiler::nonConstTestFunctionWrapper):
3098         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
3099         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementFunctionCallTest):
3100         * dom/Element.h:
3101         (WebCore::Element::isValidFormControlElement):
3102         * dom/Node.h:
3103         (WebCore::Node::toInputElement):
3104         * html/HTMLFormControlElement.cpp:
3105         (WebCore::HTMLFormControlElement::isValidFormControlElement):
3106         * html/HTMLFormControlElement.h:
3107
3108 2014-02-10  Benjamin Poulain  <benjamin@webkit.org>
3109
3110         Add the basic infrastructure to compile attributes matching in selectors
3111         https://bugs.webkit.org/show_bug.cgi?id=128484
3112
3113         Reviewed by Gavin Barraclough.
3114
3115         Tests: fast/selectors/querySelector-attribute-match-with-child-backtracking.html
3116                fast/selectors/querySelector-long-attribute-match-with-child-backtracking.html
3117                fast/selectors/querySelector-long-multiple-attribute-match-with-child-backtracking.html
3118                fast/selectors/querySelector-multiple-attribute-match-with-child-backtracking.html
3119
3120         Add the infrastructure to match attributes. This only add basic support for the 'Set' match
3121         type, the other match types will have to be built on top.
3122
3123         * cssjit/RegisterAllocator.h:
3124         (WebCore::RegisterAllocator::availableRegisterCount):
3125         (WebCore::RegisterAllocator::allocateRegister):
3126         (WebCore::RegisterAllocator::deallocateRegister):
3127         (WebCore::RegisterAllocator::reserveCalleeSavedRegisters):
3128         (WebCore::RegisterAllocator::restoreCalleeSavedRegisters):
3129         (WebCore::RegisterAllocator::allocatedRegisters):
3130         (WebCore::RegisterAllocator::RegisterAllocator):
3131         (WebCore::RegisterAllocator::~RegisterAllocator):
3132         In the worst case, matching attributes can take up to 10 registers. On x86_64, we have
3133         8 caller-saved registers. The extra 2 registers are simply added by taking callee-saved registers.
3134
3135         RegisterAllocator is modified to know support saving and restoring callee saved registers.
3136         The list of available registers is changed from a vector to a HashSet because the registers
3137         are removed from arbitrary locations in restoreCalleeSavedRegisters(). The m_allocatedRegisters
3138         remain a vector since the allocation/release pattern remain ordered.
3139
3140         * cssjit/SelectorCompiler.cpp:
3141         (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
3142
3143         (WebCore::SelectorCompiler::minimumRegisterRequirements):
3144         This new utility finds the minimum number of registers needed to compile the input. In most
3145         cases we have plenty enough. In rare cases we need to saved a few registers to the stack.
3146
3147         (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
3148         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementDataMatching):
3149         (WebCore::SelectorCompiler::testIsHTMLFlagOnNode):
3150         (WebCore::SelectorCompiler::canMatchStyleAttribute):
3151
3152         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSynchronizeStyleAttribute):
3153         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSynchronizeAllAnimatedSVGAttribute):
3154         The style attribute and certain SVG attributes can be modified lazily. In those cases,
3155         the element needs to be updated before querying the attributes.
3156
3157         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributesMatching):
3158         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeMatching):
3159         Generate the attribute matching. For each CSSSelector matching an attribute, we generate
3160         a loop over all the attributes of the element, maching the particular CSSSelector.
3161         This makes no attempt at grouping related queries since those do not seem to happen a lot
3162         in practice.
3163
3164         * dom/Attribute.h:
3165         (WebCore::Attribute::nameMemoryOffset):
3166         (WebCore::Attribute::nameMatchesFilter):
3167         (WebCore::Attribute::matches):
3168         * dom/ElementData.h:
3169         (WebCore::ElementData::isUniqueFlag):
3170         (WebCore::ElementData::arraySizeAndFlagsMemoryOffset):
3171         (WebCore::ElementData::styleAttributeIsDirtyFlag):
3172         (WebCore::ElementData::animatedSVGAttributesAreDirtyFlag):
3173         (WebCore::ElementData::arraySizeOffset):
3174         (WebCore::ShareableElementData::attributeArrayMemoryOffset):
3175         (WebCore::UniqueElementData::attributeVectorMemoryOffset):
3176         * dom/Node.h:
3177         (WebCore::Node::flagIsHTML):
3178         * dom/StyledElement.cpp:
3179         (WebCore::StyledElement::synchronizeStyleAttributeInternal):
3180         * dom/StyledElement.h:
3181         (WebCore::StyledElement::synchronizeStyleAttributeInternal):
3182         * svg/SVGElement.cpp:
3183         (WebCore::SVGElement::synchronizeAllAnimatedSVGAttribute):
3184         (WebCore::SVGElement::synchronizeAnimatedSVGAttribute):
3185         * svg/SVGElement.h:
3186
3187 2014-02-10  Brady Eidson  <beidson@apple.com>
3188
3189         IDB: storage/indexeddb/mozilla/indexes.html fails
3190         <rdar://problem/16031590> and https://bugs.webkit.org/show_bug.cgi?id=128563
3191
3192         Reviewed by Tim Horton.
3193
3194         Tested by storage/indexeddb/mozilla/indexes.html (and probably others)
3195
3196         * Modules/indexeddb/IDBGetResult.h:
3197         (WebCore::IDBGetResult::IDBGetResult): Add a constructor that takes an IDBKeyData argument.
3198
3199         * Modules/indexeddb/IDBRequest.cpp:
3200         (WebCore::IDBRequest::onSuccess): If there’s no keyPath then skip the injection step.
3201
3202 2014-02-10  Benjamin Poulain  <benjamin@webkit.org>
3203
3204         Speed up DatasetDOMStringMap::item() when the element has multiple attributes
3205         https://bugs.webkit.org/show_bug.cgi?id=128058
3206
3207         Reviewed by Darin Adler.
3208
3209         Accessing data attributes by name through DatasetDOMStringMap involes the conversion
3210         from JavaScript property name to attribute name (done with propertyNameMatchesAttributeName()).
3211
3212         When there is a single data attribute, that method is efficient. When there are several attributes,
3213         comparing names character by character becomes a bottleneck.
3214
3215         This patch add an efficent path for this case: instead of converting the attribute name on the fly,
3216         the JavaScript property name is converted to an attribute name so that it can compared by its
3217         AtomicStringImpl pointer.
3218
3219         This method puts a lot more pressure on convertPropertyNameToAttributeName()'s speed. The method was
3220         improved accordingly to compensate for its new caller.
3221
3222         When enumerating multiple attributes by name, this patch provides about 80% speedup.
3223         I could not measure any slow down on the simple cases.
3224
3225         * dom/DatasetDOMStringMap.cpp:
3226         (WebCore::convertPropertyNameToAttributeName):
3227         (WebCore::DatasetDOMStringMap::item):
3228         * dom/ElementData.h:
3229         (WebCore::AttributeIteratorAccessor::attributeCount):
3230
3231 2014-02-10  Ryosuke Niwa  <rniwa@webkit.org>
3232
3233         Address the review comments for r163825.
3234
3235         * html/HTMLTextFormControlElement.cpp:
3236         (WebCore::HTMLTextFormControlElement::indexForVisiblePosition):
3237         (WebCore::positionForIndex):
3238
3239 2014-02-10  Simon Fraser  <simon.fraser@apple.com>
3240
3241         Try to fix the 32-bit build.
3242
3243         * WebCore.exp.in:
3244
3245 2014-02-10  Filip Pizlo  <fpizlo@apple.com>
3246
3247         Rename Operations.h to JSCInlines.h
3248         https://bugs.webkit.org/show_bug.cgi?id=128543
3249
3250         Rubber stamped by Geoffrey Garen.
3251
3252         No new tests because no change in behavior.
3253
3254         * ForwardingHeaders/runtime/JSCInlines.h: Added.
3255         * bindings/js/JSCryptoAlgorithmBuilder.cpp:
3256         * bindings/js/JSCryptoKeySerializationJWK.cpp:
3257         * bindings/js/JSCustomXPathNSResolver.h:
3258         * bindings/js/JSDOMBinding.h:
3259         * bindings/js/JSDOMGlobalObject.h:
3260         * bindings/js/JSDictionary.h:
3261         * bindings/js/JSMessagePortCustom.cpp:
3262         * bindings/js/JSMessagePortCustom.h:
3263         * bindings/js/JSNodeFilterCondition.h:
3264         * bindings/js/SerializedScriptValue.cpp:
3265         * bindings/js/WebCoreTypedArrayController.cpp:
3266         * bridge/c/c_utility.h:
3267         * bridge/jsc/BridgeJSC.h:
3268         * dom/CustomEvent.cpp:
3269         * dom/Node.cpp:
3270         * html/HTMLCanvasElement.cpp:
3271         * html/HTMLImageLoader.cpp:
3272         * html/canvas/WebGLRenderingContext.cpp:
3273         * inspector/InspectorDOMAgent.cpp:
3274         * inspector/WebConsoleAgent.cpp:
3275         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3276         * platform/graphics/filters/FEGaussianBlur.cpp:
3277         * platform/graphics/filters/FilterEffect.cpp:
3278         * testing/MockCDM.cpp:
3279         * xml/XMLHttpRequest.cpp:
3280
3281 2014-02-09  Dean Jackson  <dino@apple.com>
3282
3283         Update aspect-ratio property to have constraining keywords
3284         https://bugs.webkit.org/show_bug.cgi?id=128262
3285
3286         Reviewed by Simon Fraser.
3287
3288         Add support for "from-dimensions" and "from-intrinsic"
3289         property values to "-webkit-aspect-ratio". I also changed
3290         the default value from "none" to "auto", because "none" doesn't
3291         make sense any more.
3292
3293         Covered by enhancing existing tests.
3294
3295         * css/CSSComputedStyleDeclaration.cpp:
3296         (WebCore::ComputedStyleExtractor::propertyValue): New keywords.
3297         * css/CSSParser.cpp:
3298         (WebCore::CSSParser::parseAspectRatio): Support new keywords.
3299         * css/CSSValueKeywords.in: Add from-dimensions and from-intrinsic.
3300         * css/DeprecatedStyleBuilder.cpp: This now has to handle the new
3301         values. I also changed "none" to "auto".
3302         (WebCore::ApplyPropertyAspectRatio::applyInheritValue):
3303         (WebCore::ApplyPropertyAspectRatio::applyInitialValue):
3304         (WebCore::ApplyPropertyAspectRatio::applyValue):
3305         * rendering/style/RenderStyle.h: hasAspectRatio is now aspectRatioType
3306         and indicates one of the three keywords, or a specified number.
3307         * rendering/style/RenderStyleConstants.h: New enum.
3308         * rendering/style/StyleRareNonInheritedData.cpp:
3309         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
3310         (WebCore::StyleRareNonInheritedData::operator==):
3311         * rendering/style/StyleRareNonInheritedData.h:
3312
3313 2014-02-10  Benjamin Poulain  <bpoulain@apple.com>
3314
3315         [WK2] Add support for image document viewport configuration
3316         https://bugs.webkit.org/show_bug.cgi?id=128565
3317
3318         Reviewed by Simon Fraser.
3319
3320         Add proper default settings for displaying images.
3321
3322         * WebCore.exp.in:
3323         * page/ViewportConfiguration.cpp:
3324         (WebCore::ViewportConfiguration::imageDocumentParameters):
3325         (WebCore::ViewportConfiguration::textDocumentParameters):
3326         * page/ViewportConfiguration.h:
3327
3328 2014-02-10  Brendan Long  <b.long@cablelabs.com>
3329
3330         Unreviewed GTK build fix after r163816.
3331
3332         * GNUmakefile.list.am: Remove HTMLMediaSource.h and HTMLMediaSource.cpp
3333
3334 2014-02-10  Jinwoo Song  <jinwoo7.song@samsung.com>
3335
3336         Unreviewed EFL WebKit2 build fix after r163816.
3337
3338         * CMakeLists.txt: Remove HTMLMediaSource.cpp
3339
3340 2014-02-10  Ryosuke Niwa  <rniwa@webkit.org>
3341
3342         HTMLTextFormControlElement::setSelectionRange shouldn't use VisiblePosition
3343         https://bugs.webkit.org/show_bug.cgi?id=128478
3344
3345         Reviewed by Darin Adler.
3346
3347         Added positionForIndex to compute Position given a selection index. This function doesn't
3348         synchronously trigger like visiblePositionForIndex.
3349
3350         Also added assertions in visiblePositionForIndex and visiblePositionForIndex to make sure
3351         they are inverse of one another.
3352
3353         * html/HTMLTextFormControlElement.cpp:
3354         (WebCore::HTMLTextFormControlElement::setSelectionRange): Use positionForIndex. Also removed
3355         the now tautological assertions since we would never create a position outside the inner text
3356         element.
3357
3358         (WebCore::HTMLTextFormControlElement::indexForVisiblePosition): Fixed the bug where this
3359         function could return a selection index beyond innerTextElement in some types of input
3360         elements such as search fields. fast/forms/search-disabled-readonly.html hits the newly
3361         added assertion without this change. Note we can't use visiblePositionForIndex here as that
3362         would result in a mutual recursion with the assertion in visiblePositionForIndex.
3363
3364         (WebCore::HTMLTextFormControlElement::visiblePositionForIndex): Added an assertion.
3365
3366         (WebCore::positionForIndex): Added. It's here with prototype at the beginning of the file
3367         so that it's right next to HTMLTextFormControlElement::innerText() where we do a similar
3368         DOM traversal to obtain the inner text value.
3369
3370 2014-02-07  Jeffrey Pfau  <jpfau@apple.com>
3371
3372         Disable access to application cache when in private browsing
3373         https://bugs.webkit.org/show_bug.cgi?id=128426
3374
3375         Reviewed by Alexey Proskuryakov.
3376
3377         Tests: http/tests/security/appcache-in-private-browsing.html
3378                http/tests/security/appcache-switching-private-browsing.html
3379
3380         * loader/appcache/ApplicationCacheGroup.cpp:
3381         (WebCore::ApplicationCacheGroup::cacheForMainRequest):
3382         (WebCore::ApplicationCacheGroup::selectCache):
3383         (WebCore::ApplicationCacheGroup::selectCacheWithoutManifestURL):
3384         (WebCore::ApplicationCacheGroup::update):
3385         * loader/appcache/ApplicationCacheHost.cpp:
3386         (WebCore::ApplicationCacheHost::isApplicationCacheEnabled):
3387
3388 2014-02-10  Jer Noble  <jer.noble@apple.com>
3389
3390         [MSE] Fix layering violations in MediaSource
3391         https://bugs.webkit.org/show_bug.cgi?id=128546
3392
3393         Reviewed by Eric Carlson.
3394
3395         Code in Modules should be considered part of html/ and should have the
3396         same layering properties. Get rid of HTMLMediaSource (which was intended
3397         to allow Modules/mediasource to be considered part of platform/) and add
3398         a new client interface allowing communication from platform/ -> 
3399         Modules/mediasource.
3400
3401         Replace HTMLMediaSource -> MediaSourcePrivateClient:
3402         * html/HTMLMediaSource.cpp: Removed.
3403         * html/HTMLMediaSource.h: Removed.
3404         * platform/graphics/MediaSourcePrivateClient.h: Added.
3405         (WebCore::MediaSourcePrivateClient::~MediaSourcePrivateClient):
3406
3407         Move registry support from HTMLMediaSource -> MediaSource.
3408         * Modules/mediasource/MediaSource.cpp:
3409         (WebCore::MediaSource::setRegistry): Moved from HTMLMediaSource.cpp.
3410         * Modules/mediasource/MediaSource.h:
3411         (WebCore::MediaSource::lookup): Ditto.
3412
3413         Update references to HTMLMediaSource -> MediaSource:
3414         * Modules/mediasource/MediaSourceRegistry.cpp:
3415         (WebCore::MediaSourceRegistry::MediaSourceRegistry): 
3416         * WebCore.xcodeproj/project.pbxproj:
3417         * html/HTMLMediaElement.cpp:
3418         (WebCore::HTMLMediaElement::loadResource):
3419         * html/HTMLMediaElement.h:
3420
3421         Update references to HTMLMediaSource -> MediaSourcePrivateClient:
3422         * platform/graphics/MediaPlayer.cpp:
3423         (WebCore::NullMediaPlayerPrivate::load):
3424         (WebCore::MediaPlayer::load): Ditto.
3425         (WebCore::MediaPlayer::loadWithNextMediaEngine):
3426         * platform/graphics/MediaPlayer.h:
3427         * platform/graphics/MediaPlayerPrivate.h:
3428         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
3429         (WebCore::MediaPlayerPrivateAVFoundation::load):
3430         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
3431         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
3432         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
3433         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::load):
3434         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3435         (WebCore::MediaPlayerPrivateGStreamer::load):
3436         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
3437         * platform/graphics/gstreamer/MediaSourceGStreamer.cpp:
3438         (WebCore::MediaSourceGStreamer::open):
3439         * platform/graphics/gstreamer/MediaSourceGStreamer.h:
3440         * platform/graphics/ios/MediaPlayerPrivateIOS.h:
3441         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3442         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3443         (WebCore::MediaPlayerPrivateQTKit::load):
3444         * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
3445         (WebCore::MockMediaPlayerMediaSource::load):
3446         * platform/mock/mediasource/MockMediaPlayerMediaSource.h:
3447
3448 2014-02-10  Alexey Proskuryakov  <ap@apple.com>
3449
3450         Remove some unused functions from SerializedScriptValue
3451         https://bugs.webkit.org/show_bug.cgi?id=128407
3452
3453         Reviewed by Oliver Hunt.
3454