Clean up BidiRun a little bit.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-11-07  Andreas Kling  <akling@apple.com>
2
3         Clean up BidiRun a little bit.
4         <https://webkit.org/b/123964>
5
6         Make BidiRun's member variables private and add accessors for them.
7         In doing so, codify the following:
8
9             - BidiRun always has a corresponding RenderObject.
10             - The inline box is never cleared after being set.
11
12         Reviewed by Antti Koivisto.
13
14 2013-11-07  Andreas Kling  <akling@apple.com>
15
16         More CSSPrimitiveValue constructors should return PassRef.
17         <https://webkit.org/b/123953>
18
19         Make some more CSSPrimitiveValue constructor helpers (that are
20         known to never return null) return PassRef instead of PassRefPtr.
21
22         Reviewed by Antti Koivisto.
23
24 2013-11-07  Andreas Kling  <akling@apple.com>
25
26         Generate type casting helpers for line boxes and use them.
27         <https://webkit.org/b/123976>
28
29         Semi-automatically generate the full set of toFooInlineBox()
30         helpers with macros instead of having them (partially) hand-coded.
31         Replaced static_casts with the new helpers across the codebase.
32
33         Also made the isFooInlineBox() overrides private since they should
34         never be called when the type is already known.
35
36         Reviewed by Antti Koivisto.
37
38 2013-11-07  Ryosuke Niwa  <rniwa@webkit.org>
39
40         Simplify Attr by removing m_specified member variable and setter
41         https://bugs.webkit.org/show_bug.cgi?id=123965
42
43         Reviewed by Andreas Kling.
44
45         Merge https://chromium.googlesource.com/chromium/blink/+/597f44ec928e08820574728889adabc6d8ecd746
46
47         m_specified is always true in WebKit so simply return true in Attr::specified().
48
49         * dom/Attr.cpp:
50         (WebCore::Attr::Attr):
51         * dom/Attr.h:
52         * dom/Document.cpp:
53         (WebCore::Document::adoptNode):
54
55 2013-10-25  Jer Noble  <jer.noble@apple.com>
56
57         [MSE] Add MediaSource extensions to AudioTrack, VideoTrack, and TextTrack.
58         https://bugs.webkit.org/show_bug.cgi?id=123374
59
60         Reviewed by Eric Carlson.
61
62         No tests added; tests will be added when Mock implementations are added in a future patch.
63
64         Add new partial interfaces for added methods on AudioTrack, TextTrack, and VideoTrack:
65         * Modules/mediasource/AudioTrackMediaSource.idl: Add read-only sourceBuffer attribute.
66         * Modules/mediasource/TextTrackMediaSource.idl: Ditto.
67         * Modules/mediasource/VideoTrackMediaSource.idl: Ditto.
68         * Modules/mediasource/AudioTrackMediaSource.h:
69         (WebCore::AudioTrackMediaSource::sourceBuffer): Added static wrapper around non-static sourceBuffer().
70         * Modules/mediasource/TextTrackMediaSource.h:
71         (WebCore::TextTrackMediaSource::sourceBuffer): Ditto.
72         * Modules/mediasource/VideoTrackMediaSource.h:
73         (WebCore::VideoTrackMediaSource::sourceBuffer): Ditto.
74
75         Add support for writable kind & language attributes through a custom setter:
76         * bindings/js/JSAudioTrackCustom.cpp:
77         (WebCore::JSAudioTrack::setKind):
78         (WebCore::JSAudioTrack::setLanguage):
79         * bindings/js/JSTextTrackCustom.cpp:
80         (WebCore::JSTextTrack::setKind):
81         (WebCore::JSTextTrack::setLanguage):
82         * bindings/js/JSVideoTrackCustom.cpp:
83         (WebCore::JSVideoTrack::setKind):
84         (WebCore::JSVideoTrack::setLanguage):
85         * html/track/AudioTrack.idl:
86         * html/track/TextTrack.idl:
87         * html/track/VideoTrack.idl:
88
89         Add setter methods to the implementation classes:
90         * html/track/TextTrack.cpp:
91         (WebCore::TextTrack::TextTrack):
92         (WebCore::TextTrack::setKind):
93         (WebCore::TextTrack::setLanguage):
94         * html/track/TextTrack.h:
95         * html/track/TrackBase.cpp:
96         (WebCore::TrackBase::TrackBase):
97         (WebCore::TrackBase::setKind):
98         (WebCore::TrackBase::setKindInternal):
99         * html/track/TrackBase.h:
100         (WebCore::TrackBase::setLanguage):
101         (WebCore::TrackBase::sourceBuffer):
102         (WebCore::TrackBase::setSourceBuffer):
103         * html/track/VideoTrack.cpp:
104         (WebCore::VideoTrack::VideoTrack):
105         (WebCore::VideoTrack::setKind):
106         (WebCore::VideoTrack::setLanguage):
107         * html/track/VideoTrack.h:
108
109         Implement the unimplemented portions of MediaSource and SourceBuffer:
110         * Modules/mediasource/MediaSource.cpp:
111         (WebCore::MediaSource::removeSourceBuffer):
112         * Modules/mediasource/MediaSourceBase.cpp:
113         (WebCore::MediaSourceBase::MediaSourceBase):
114         (WebCore::MediaSourceBase::setPrivateAndOpen):
115         (WebCore::MediaSourceBase::setReadyState):
116         (WebCore::MediaSourceBase::attachToElement):
117         * Modules/mediasource/MediaSourceBase.h:
118         (WebCore::MediaSourceBase::mediaElement):
119         * Modules/mediasource/SourceBuffer.cpp:
120         (WebCore::SourceBuffer::videoTracks):
121         (WebCore::SourceBuffer::audioTracks):
122         (WebCore::SourceBuffer::textTracks):
123         (WebCore::SourceBuffer::sourceBufferPrivateDidAddAudioTrack):
124         (WebCore::SourceBuffer::sourceBufferPrivateDidAddVideoTrack):
125         (WebCore::SourceBuffer::sourceBufferPrivateDidAddTextTrack):
126         (WebCore::SourceBuffer::sourceBufferPrivateDidChangeActiveState):
127         * Modules/mediasource/SourceBuffer.h:
128         * Modules/mediasource/SourceBuffer.idl:
129
130         Add new files to the project:
131         * DerivedSources.make:
132         * WebCore.xcodeproj/project.pbxproj:
133
134         And a smorgasbord of other utility changes:
135         * html/HTMLMediaElement.cpp:
136         (WebCore::HTMLMediaElement::loadResource): Pass this when attaching.
137         (WebCore::HTMLMediaElement::mediaPlayerDidAddTextTrack): Ditto.
138         * html/HTMLMediaSource.h:
139         * html/track/TextTrackList.cpp:
140         (TextTrackList::item): Make const.
141         * html/track/TextTrackList.h:
142         (WebCore::TextTrackList::lastItem): Added.
143         * platform/graphics/InbandTextTrackPrivate.h:
144         (WebCore::InbandTextTrackPrivate::create): Added.
145         (WebCore::MockSourceBufferPrivate::trackDidChangeEnabled):
146
147 2013-11-06  Vani Hegde  <vani.hegde@samsung.com>
148
149         Applied background color is not retained after typing a characters
150         https://bugs.webkit.org/show_bug.cgi?id=117337
151
152         Reviewed by Ryosuke Niwa.
153
154         While deleting a selection, only the inheritable style properties
155         applied on the selection were saved.
156         Since background color is considered as noninheritable style property,
157         on deleting the selection, background color set on it was being lost.
158         Hence on typing in new text, it would not have the applied
159         background color set.
160         Fixed by saving editing preoperties that are already in effect
161         on a selection before deleting it.
162
163         Test: editing/style/background-color-retained.html
164
165         * editing/DeleteSelectionCommand.cpp:
166         (WebCore::DeleteSelectionCommand::saveTypingStyleState):
167         Modified as to save EditingPropertiesInEffect on a selection before
168         deleting it.
169
170 2013-11-06  Andreas Kling  <akling@apple.com>
171
172         InlineBox: Make paint() and nodeAtPoint() pure virtuals.
173         <https://webkit.org/b/123937>
174
175         ...and move the current implementations to InlineElementBox.
176         All subclasses were already overriding these functions so the move
177         is completely natural.
178
179         Reviewed by Anders Carlsson.
180
181 2013-11-06  Andreas Kling  <akling@apple.com>
182
183         Nothing should return std::unique_ptr<InlineBox>.
184         <https://webkit.org/b/123936>
185
186         Made RenderBox, RenderLineBreak and RenderListMarker return tightly
187         typed InlineElementBoxes instead.
188
189         Reviewed by Anders Carlsson.
190
191 2013-11-06  Daniel Bates  <dabates@apple.com>
192
193         [iOS] Upstream Letterpress effect
194         https://bugs.webkit.org/show_bug.cgi?id=123932
195
196         Reviewed by Sam Weinig.
197
198         Test: platform/iphone-simulator/iphone/getComputedStyle-text-decoration-letterpress.html
199
200         * Configurations/FeatureDefines.xcconfig: Add feature define ENABLE_LETTERPRESS disabled
201         by default. We only enable letterpress on iOS.
202         * css/CSSComputedStyleDeclaration.cpp:
203         (WebCore::renderTextDecorationFlagsToCSSValue): Add support for CSS value -webkit-letterpress.
204         * css/CSSParser.cpp:
205         (WebCore::CSSParser::parseTextDecoration): Ditto.
206         * css/CSSPrimitiveValueMappings.h:
207         (WebCore::CSSPrimitiveValue::operator TextDecoration): Ditto.
208         * css/CSSValueKeywords.in: Added CSS value -webkit-letterpress.
209         * platform/graphics/GraphicsContext.h:
210         * platform/graphics/mac/FontMac.mm:
211         (WebCore::fillVectorWithHorizontalGlyphPositions): Added.
212         (WebCore::shouldUseLetterpressEffect): Added.
213         (WebCore::showLetterpressedGlyphsWithAdvances): Added.
214         (WebCore::showGlyphsWithAdvances): Modified to call showLetterpressedGlyphsWithAdvances()
215         to show a letterpressed glyph. I also included additional iOS-specific changes.
216         (WebCore::Font::drawGlyphs):
217         * rendering/TextPaintStyle.cpp:
218         (WebCore::TextPaintStyle::TextPaintStyle): 
219         (WebCore::computeTextPaintStyle): Modified to compute letterpress effect style.
220         (WebCore::updateGraphicsContext): Modified to apply/unapply letterpress effect drawing mode.
221         * rendering/TextPaintStyle.h:
222         * rendering/style/RenderStyleConstants.h:
223
224 2013-11-06  Ryosuke Niwa  <rniwa@webkit.org>
225
226         Crash in SliderThumbElement::dragFrom
227         https://bugs.webkit.org/show_bug.cgi?id=123873
228
229         Reviewed by Sam Weinig.
230
231         Moved Ref.
232
233         * html/RangeInputType.cpp:
234         (WebCore::RangeInputType::handleMouseDownEvent):
235         * html/shadow/SliderThumbElement.cpp:
236         (WebCore::SliderThumbElement::dragFrom):
237
238 2013-11-06  Daniel Bates  <dabates@apple.com>
239
240         Cleanup FontMac.mm
241         https://bugs.webkit.org/show_bug.cgi?id=123928
242
243         Reviewed by Andy Estes.
244
245         * platform/graphics/mac/FontMac.mm:
246         (WebCore::showGlyphsWithAdvances): Inline the value of variable isVertical as we
247         reference it exactly once and its value is sufficiently clear.
248         (WebCore::Font::drawGlyphs): Remove default case in switch block so that the compiler
249         checks that all cases are covered. Move definition of platformData to the top of the
250         function and use it whenever we want to access the platform font data
251
252 2013-11-06  Brent Fulgham  <bfulgham@apple.com>
253
254         [WebGL] We should not allow generateMipMap on compressed textures
255         https://bugs.webkit.org/show_bug.cgi?id=123915
256         <rdar://problem/15201274>
257
258         Reviewed by Dean Jackson.
259
260         Found by existing conformance/extensions/webgl-compressed-texture-s3tc.html
261
262         * html/canvas/WebGLRenderingContext.cpp:
263         (WebCore::WebGLRenderingContext::compressedTexImage2D): Set compressed flag.
264         (WebCore::WebGLRenderingContext::compressedTexSubImage2D): Ditto.
265         (WebCore::WebGLRenderingContext::generateMipmap): For Apple builds, check state
266         of compressed flag and generate appropriate WebGL error if necessary.
267         * html/canvas/WebGLTexture.cpp:
268         (WebCore::WebGLTexture::WebGLTexture): Set compressed flag to false by default
269         (WebCore::WebGLTexture::isCompressed): Added
270         (WebCore::WebGLTexture::setCompressed): Added
271         * html/canvas/WebGLTexture.h:
272         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
273         (WebCore::GraphicsContext3D::generateMipmap): Switch implementation to use proper
274         glGenerateMipmaps, rather than the glGenerateMipmapsEXT method.
275
276 2013-11-06  Joseph Pecoraro  <pecoraro@apple.com>
277
278         Web Inspector: Changes to CodeGeneratorInspectorStrings.py should rebuild inspector generated files
279         https://bugs.webkit.org/show_bug.cgi?id=123925
280
281         Reviewed by Timothy Hatcher.
282
283         * CMakeLists.txt:
284         * DerivedSources.make:
285         * GNUmakefile.am:
286
287 2013-11-06  Bem Jones-Bey  <bjonesbe@adobe.com>
288
289         Rename region line offset methods
290         https://bugs.webkit.org/show_bug.cgi?id=123897
291
292         Reviewed by Sam Weinig.
293
294         Because of the large number of overloads on the line offset methods,
295         it is very hard to read code using them, which also makes it harder to
296         move them out of RenderBlock. This patch renames the methods that take
297         a region as an argument to make it clearer when looking at the code
298         how the differ from the ones that don't.
299
300         No new tests, no behavior change.
301
302         * rendering/RenderBlock.cpp:
303         (WebCore::RenderBlock::computeStartPositionDeltaForChildAvoidingFloats):
304         * rendering/RenderBlock.h:
305         (WebCore::RenderBlock::availableLogicalWidthForLineInRegion):
306         (WebCore::RenderBlock::logicalRightOffsetForLineInRegion):
307         (WebCore::RenderBlock::logicalLeftOffsetForLineInRegion):
308         (WebCore::RenderBlock::startOffsetForLineInRegion):
309         (WebCore::RenderBlock::endOffsetForLineInRegion):
310         (WebCore::RenderBlock::availableLogicalWidthForLine):
311         * rendering/RenderBox.cpp:
312         (WebCore::RenderBox::shrinkLogicalWidthToAvoidFloats):
313         (WebCore::RenderBox::containingBlockAvailableLineWidthInRegion):
314
315 2013-11-06  Antti Koivisto  <antti@apple.com>
316
317         HTMLCollection should use CollectionIndexCache
318         https://bugs.webkit.org/show_bug.cgi?id=123906
319
320         Reviewed by Ryosuke Niwa.
321         
322         More code sharing.
323
324         * bindings/js/JSDOMWindowCustom.cpp:
325         (WebCore::namedItemGetter):
326         * bindings/js/JSHTMLDocumentCustom.cpp:
327         (WebCore::JSHTMLDocument::nameGetter):
328         * dom/ChildNodeList.h:
329         * dom/CollectionIndexCache.h:
330         (WebCore::::nodeBeforeCached):
331         (WebCore::::nodeAfterCached):
332         (WebCore::::nodeAt):
333             
334             Add a mechanism for disabling use of backward traversal.
335
336         * dom/LiveNodeList.h:
337         (WebCore::LiveNodeList::collectionCanTraverseBackward):
338         * html/HTMLCollection.cpp:
339         (WebCore::HTMLCollection::HTMLCollection):
340         (WebCore::isMatchingElement):
341         (WebCore::HTMLCollection::iterateForPreviousElement):
342         (WebCore::firstMatchingElement):
343         (WebCore::nextMatchingElement):
344         (WebCore::HTMLCollection::length):
345         (WebCore::HTMLCollection::item):
346         (WebCore::nameShouldBeVisibleInDocumentAll):
347         (WebCore::firstMatchingChildElement):
348         (WebCore::nextMatchingSiblingElement):
349         (WebCore::HTMLCollection::firstElement):
350         (WebCore::HTMLCollection::traverseForward):
351         (WebCore::HTMLCollection::collectionFirst):
352         (WebCore::HTMLCollection::collectionLast):
353         (WebCore::HTMLCollection::collectionTraverseForward):
354         (WebCore::HTMLCollection::collectionTraverseBackward):
355         (WebCore::HTMLCollection::invalidateCache):
356         (WebCore::HTMLCollection::namedItem):
357         (WebCore::HTMLCollection::updateNameCache):
358         * html/HTMLCollection.h:
359         (WebCore::HTMLCollection::collectionCanTraverseBackward):
360         
361             Disable use of backward traversal for collections that use custom traversal.
362
363 2013-11-06  Brendan Long  <b.long@cablelabs.com>
364
365         Add "id" attribute to TextTrack
366         https://bugs.webkit.org/show_bug.cgi?id=123825
367
368         Reviewed by Eric Carlson.
369
370         Test: media/track/track-id.html
371
372         * html/HTMLMediaElement.cpp:
373         (HTMLMediaElement::addTextTrack): Add emptyString() for track id.
374         * html/track/AudioTrack.cpp:
375         (WebCore::AudioTrack::AudioTrack): Pass trackPrivate->id() to TrackBase.
376         (WebCore::AudioTrack::idChanged): Added, set id.
377         * html/track/AudioTrack.h: Move m_id to TrackBase.
378         * html/track/InbandTextTrack.cpp:
379         (WebCore::InbandTextTrack::InbandTextTrack): Pass trackPrivate->id() to TrackBase.
380         (WebCore::InbandTextTrack::idChanged): Added, set id.
381         * html/track/InbandTextTrack.h: Add idChanged().
382         * html/track/LoadableTextTrack.cpp:
383         (WebCore::LoadableTextTrack::LoadableTextTrack): Add emptyString() for track id.
384         (WebCore::LoadableTextTrack::id): Override to return the track element's id.
385         * html/track/TextTrack.cpp:
386         (WebCore::TextTrack::captionMenuOffItem): Add empty string for track id.
387         (WebCore::TextTrack::captionMenuAutomaticItem): Add empty string for track id.
388         (WebCore::TextTrack::TextTrack): Pass id to TrackBase.
389         * html/track/TextTrack.h:
390         (WebCore::TextTrack::create): Add id parameter.
391         * html/track/TextTrack.idl: Add id attribute.
392         * html/track/TrackBase.cpp:
393         (WebCore::TrackBase::TrackBase): Add m_id.
394         * html/track/TrackBase.h: Add id attribute / m_id.
395         * html/track/VideoTrack.cpp:
396         (WebCore::VideoTrack::VideoTrack): Pass trackPrivate->id() to TrackBase.
397         (WebCore::VideoTrack::idChanged): Added, set id.
398         * html/track/VideoTrack.h: Move m_id to TrackBase.
399         * platform/graphics/TrackPrivateBase.h: Add idChanged() callback.
400
401 2013-11-06  Antti Koivisto  <antti@apple.com>
402
403         Move array position caching out from HTMLCollection
404         https://bugs.webkit.org/show_bug.cgi?id=123895
405
406         Reviewed by Darin Adler.
407
408         This caching complicates the logic but is used by a single subclass
409         (HTMLFormControlsCollection) only. The subclass can do the caching itself.
410
411         * html/HTMLAllCollection.cpp:
412         (WebCore::HTMLAllCollection::HTMLAllCollection):
413         * html/HTMLCollection.cpp:
414         (WebCore::HTMLCollection::HTMLCollection):
415         (WebCore::HTMLCollection::create):
416         (WebCore::HTMLCollection::item):
417         (WebCore::HTMLCollection::elementBeforeOrAfterCachedElement):
418         (WebCore::HTMLCollection::firstElement):
419         
420             Renamed from traverseFirstElement.
421
422         (WebCore::HTMLCollection::traverseForwardToOffset):
423         (WebCore::HTMLCollection::invalidateCache):
424         
425             Make cache invalidation virtual so we can clear HTMLTableRowsCollection index cache.
426
427         (WebCore::HTMLCollection::namedItem):
428         (WebCore::HTMLCollection::updateNameCache):
429         
430             Use traverseForwardToOffset instead traverseNextElement. This allows removal of traverseNextElement.
431
432         * html/HTMLCollection.h:
433         (WebCore::HTMLCollection::usesCustomForwardOnlyTraversal):
434         
435             Renamed the enum and the accessor to be more informative.
436
437         (WebCore::HTMLCollection::setCachedElement):
438         (WebCore::HTMLCollection::customElementAfter):
439         
440             Renamed from virtualItemAfter.
441
442         * html/HTMLFormControlsCollection.cpp:
443         (WebCore::HTMLFormControlsCollection::HTMLFormControlsCollection):
444         (WebCore::findFormAssociatedElement):
445         (WebCore::HTMLFormControlsCollection::customElementAfter):
446         
447             Move the array position caching logic here.
448
449         (WebCore::HTMLFormControlsCollection::invalidateCache):
450         * html/HTMLFormControlsCollection.h:
451         * html/HTMLNameCollection.cpp:
452         (WebCore::HTMLNameCollection::HTMLNameCollection):
453         * html/HTMLOptionsCollection.cpp:
454         (WebCore::HTMLOptionsCollection::HTMLOptionsCollection):
455         * html/HTMLTableRowsCollection.cpp:
456         (WebCore::HTMLTableRowsCollection::HTMLTableRowsCollection):
457         (WebCore::HTMLTableRowsCollection::customElementAfter):
458         * html/HTMLTableRowsCollection.h:
459
460 2013-11-06  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
461
462         [ATK] accessibility/title-ui-element-correctness.html fails
463         https://bugs.webkit.org/show_bug.cgi?id=99825
464
465         Reviewed by Mario Sanchez Prada.
466
467         When calling setAtkRelationSetFromCoreObject a new ATK_LABELLED_BY_RELATION
468         is added, adding proper label element as a relation. When the document structure
469         has been changed and a different label should be linked as a relation, current ATK
470         implementation adds it as a next target on relation's target list, while
471         WTR/DumpRenderTree implementation takes only first one into account.
472         This patch adds a new function removing current relations before adding new ones.
473
474         Covered by existing tests.
475
476         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
477         (removeAtkRelationFromRelationSetByType):
478         (setAtkRelationSetFromCoreObject):
479
480 2013-11-06  Daniel Bates  <dabates@apple.com>
481
482         Add ENABLE(TEXT_SELECTION)
483         https://bugs.webkit.org/show_bug.cgi?id=123827
484
485         Reviewed by Ryosuke Niwa.
486
487         Add compile-time guard, ENABLE(TEXT_SELECTION), to enable or
488         disable selection painting in WebCore (enabled by default).
489
490         On iOS we disable WebCore selection painting and have UIKit
491         paint the selection.
492
493         * rendering/InlineTextBox.cpp:
494         (WebCore::InlineTextBox::paintSelection): Only paint selection when
495         TEXT_SELECTION is enabled.
496         * rendering/LogicalSelectionOffsetCaches.h:
497         (WebCore::LogicalSelectionOffsetCaches::LogicalSelectionOffsetCaches):
498         For now, add a ENABLE(TEXT_SELECTION)-guard around an assertion. Added
499         a FIXME comment to investigate the callers and either move the assertion
500         to the appropriate callers or structure the code such that we can remove
501         the assertion.
502         * rendering/RenderBlock.cpp:
503         (WebCore::RenderBlock::paintSelection): Only paint selection when
504         TEXT_SELECTION is enabled.
505         * rendering/TextPaintStyle.cpp:
506         (WebCore::computeTextSelectionPaintStyle): Only compute the selection
507         paint style when TEXT_SELECTION is enabled. Otherwise, return a paint
508         style identical to the text paint style. Also, substitute nullptr for 0.
509
510 2013-11-06  Jer Noble  <jer.noble@apple.com>
511
512         Unrevewied Windows build fix after r158736; add InlineElementBox.cpp to the RenderingAllInOne.cpp file.
513
514         * rendering/RenderingAllInOne.cpp:
515
516 2013-11-06  Sergio Villar Senin  <svillar@igalia.com>
517
518         Unreviewed build fix, style() return type is now a reference.
519
520         * rendering/RenderGrid.cpp:
521         (WebCore::RenderGrid::resolveGridPositionFromStyle):
522
523 2013-11-06  Jer Noble  <jer.noble@apple.com>
524
525         Unreviewed 32-bit Mac build fix; use an explicit FloatSize -> IntSize conversion function.
526
527         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
528         (WebCore::MediaPlayerPrivateAVFoundationObjC::sizeChanged):
529
530 2013-11-04  Jer Noble  <jer.noble@apple.com>
531
532         Playing many sounds with HTML5 Audio makes WebKit unresponsive
533         https://bugs.webkit.org/show_bug.cgi?id=116145
534
535         Reviewed by Eric Carlson.
536
537         Cache as much information as possible from AVPlayerItem to eliminate unneccesary
538         calls into AVFoundation.
539
540         Add WillChange/DidChange functions to handle the results of KVO notifications
541         from AVPlayerItem and AVPlayer:
542         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
543         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformPlay):
544         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformPause):
545         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateRate):
546         (WebCore::MediaPlayerPrivateAVFoundationObjC::playerItemStatusDidChange):
547         (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackLikelyToKeepUpWillChange):
548         (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackLikelyToKeepUpDidChange):
549         (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackBufferEmptyWillChange):
550         (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackBufferEmptyDidChange):
551         (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackBufferFullWillChange):
552         (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackBufferFullDidChange):
553         (WebCore::MediaPlayerPrivateAVFoundationObjC::seekableTimeRangesDidChange):
554         (WebCore::MediaPlayerPrivateAVFoundationObjC::loadedTimeRangesDidChange):
555         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksDidChange):
556         (WebCore::MediaPlayerPrivateAVFoundationObjC::hasEnabledAudioDidChange):
557         (WebCore::MediaPlayerPrivateAVFoundationObjC::presentationSizeDidChange):
558         (WebCore::MediaPlayerPrivateAVFoundationObjC::durationDidChange):
559         (WebCore::MediaPlayerPrivateAVFoundationObjC::rateDidChange):
560         (WebCore::itemKVOProperties):
561         (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]):
562
563         Instruct the HTMLMediaElement to cache the currentTime value for 5 seconds:
564         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
565         (WebCore::MediaPlayerPrivateAVFoundationObjC::maximumDurationToCacheMediaTime):
566
567         Add and initialize member variables to hold these cached values:
568         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
569         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
570         (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
571         (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad):
572
573         Add a new Notification type which can take (and call) a Function object:
574         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
575         (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification):
576         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
577         (WebCore::MediaPlayerPrivateAVFoundation::Notification::Notification):
578         (WebCore::MediaPlayerPrivateAVFoundation::Notification::function):
579
580         Implement queries in terms of the cached values of AVPlayerItem and AVPlayer
581         properties:
582         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
583         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
584         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):
585         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem):
586         (WebCore::MediaPlayerPrivateAVFoundationObjC::playerItemStatus):
587         (WebCore::MediaPlayerPrivateAVFoundationObjC::rate):
588         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformBufferedTimeRanges):
589         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformMinTimeSeekable):
590         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformMaxTimeSeekable):
591         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformMaxTimeLoaded):
592         (WebCore::MediaPlayerPrivateAVFoundationObjC::totalBytes):
593         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged):
594         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateAudioTracks):
595         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoTracks):
596         (WebCore::MediaPlayerPrivateAVFoundationObjC::sizeChanged):
597         (WebCore::MediaPlayerPrivateAVFoundationObjC::processLegacyClosedCaptionsTracks):
598
599         Invalidate the cached currentTime before calling scheduleTimeUpdate so that the
600         correct movieTime is saved in m_clockTimeAtLastUpdateEvent:
601         * html/HTMLMediaElement.cpp:
602         (HTMLMediaElement::setReadyState):
603
604 2013-10-24  Sergio Villar Senin  <svillar@igalia.com>
605
606         [CSS Grid Layout] Add support for named grid areas
607         https://bugs.webkit.org/show_bug.cgi?id=120045
608
609         Reviewed by Andreas Kling.
610
611         From Blink r155555, r155850 and r155889 by <jchaffraix@chromium.org>
612
613         Added support for named grid areas. Basically a named grid area is
614         now a valid grid position. The shorthand parsing of grid-area was
615         split from the grid-{row|column} as the rules for expanding are
616         slightly different.
617
618         Unknown grid area names are treated as 'auto' as per the
619         specification. This means that for those cases we need to trigger
620         the auto-placement algorithm.
621
622         Tests: fast/css-grid-layout/grid-item-bad-named-area-auto-placement.html
623                fast/css-grid-layout/grid-item-named-grid-area-resolution.html
624
625         * css/CSSComputedStyleDeclaration.cpp:
626         (WebCore::valueForGridPosition):
627         * css/CSSParser.cpp:
628         (WebCore::CSSParser::parseValue):
629         (WebCore::CSSParser::parseGridPosition):
630         (WebCore::gridMissingGridPositionValue):
631         (WebCore::CSSParser::parseGridItemPositionShorthand):
632         (WebCore::CSSParser::parseGridAreaShorthand):
633         (WebCore::CSSParser::parseSingleGridAreaLonghand):
634         * css/CSSParser.h:
635         * css/StyleResolver.cpp:
636         (WebCore::StyleResolver::adjustRenderStyle):
637         (WebCore::StyleResolver::adjustGridItemPosition):
638         (WebCore::createGridPosition):
639         * css/StyleResolver.h:
640         * rendering/RenderGrid.cpp:
641         (WebCore::RenderGrid::resolveGridPositionFromStyle):
642         * rendering/style/GridPosition.h:
643         (WebCore::GridPosition::isNamedGridArea):
644         (WebCore::GridPosition::setNamedGridArea):
645         (WebCore::GridPosition::namedGridLine):
646
647 2013-11-06  Chris Fleizach  <cfleizach@apple.com>
648
649         AX: Audio and Video attachments are not output to VoiceOver
650         https://bugs.webkit.org/show_bug.cgi?id=123479
651
652         Reviewed by Mario Sanchez Prada.
653
654         Video and audio elements don't appear as distinct objects in the AX hierarchy,
655         nor are they treated as replaceable objects when emitting the text. We should
656         treat these characters like attachments, for one. On the Mac platform, we should
657         also identify them with special subroles.
658
659         Tests: platform/mac/accessibility/media-emits-object-replacement.html
660                platform/mac/accessibility/media-role-descriptions.html
661
662         * accessibility/AccessibilityNodeObject.cpp:
663         (WebCore::AccessibilityNodeObject::isGenericFocusableElement):
664         * accessibility/AccessibilityObject.h:
665         * accessibility/AccessibilityRenderObject.cpp:
666         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
667         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
668         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
669         (createAccessibilityRoleMap):
670         (-[WebAccessibilityObjectWrapper subrole]):
671         (-[WebAccessibilityObjectWrapper roleDescription]):
672         * editing/TextIterator.cpp:
673         (WebCore::isRendererReplacedElement):
674
675
676 2013-11-06  Ryosuke Niwa  <rniwa@webkit.org>
677
678         Notify nodes removal to Range/Selection after dispatching blur and mutation event
679         https://bugs.webkit.org/show_bug.cgi?id=123880
680
681         Reviewed by Andreas Kling.
682
683         Merge https://chromium.googlesource.com/chromium/blink/+/b60576a0560d14f8757e58d55d37b7cefa48a6ac
684
685         In willRemoveChildren in ContainerNode.cpp, call Document::nodeChildrenWillBeRemoved after instead of
686         before dispatching mutation events because we need to update ranges created by those mutation event
687         listeners. willRemoveChild was fixed in r115686.
688
689         Tests: editing/selection/selection-change-in-blur-event-by-remove-children.html
690                editing/selection/selection-change-in-mutation-event-by-remove-children.html
691                fast/dom/Range/range-created-during-remove-children.html
692
693         * dom/ContainerNode.cpp:
694         (WebCore::willRemoveChildren):
695
696 2013-11-06  Ryosuke Niwa  <rniwa@webkit.org>
697
698         Fix out-of-date offset in selection range code in range.surroundContents
699         https://bugs.webkit.org/show_bug.cgi?id=123871
700
701         Reviewed by Andreas Kling.
702         
703         Merge https://chromium.googlesource.com/chromium/blink/+/c89b413ff0fc4aafa0c71d180b0b1e131bb37707
704
705         The code in Range::insertNode assumeed that the start offset of the selection range within its container
706         doesn't change across a call to insertBefore on the container but this is wrong. This patch recomputes
707         the start offset when it is used after the insertBefore call.
708
709         Test: editing/selection/range-surroundContents-with-preceding-node.html
710
711         * dom/Range.cpp:
712         (WebCore::Range::insertNode):
713
714 2013-11-06  Andreas Kling  <akling@apple.com>
715
716         Add InlineElementBox and stop instantiating InlineBox directly.
717         <https://webkit.org/b/123882>
718
719         Make the InlineBox constructors protected and add a new class
720         called InlineElementBox on top. This is somewhat analogous to the
721         split between RenderText and RenderElement, and allows us to make
722         renderer() return a far tighter RenderBoxModelObject& instead
723         of a RenderObject&.
724
725         Moved over attachLine(), deleteLine() and extractLine() to start
726         things off. More things will follow.
727
728         Reviewed by Antti Koivisto.
729
730 2013-11-06  Piotr Grad  <p.grad@samsung.com>
731
732         Seek for video doesn't work when playback rate is negative
733         https://bugs.webkit.org/show_bug.cgi?id=123791
734
735         In MediaPlayerPrivateGStreamer::seek negative playback rate was not taken to account.
736
737         Reviewed by Philippe Normand.
738
739         Test: media/video-seek-with-negative-playback.html
740
741         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
742         (WebCore::MediaPlayerPrivateGStreamer::seek):
743
744 2013-11-06  Andreas Kling  <akling@apple.com>
745
746         Reinstate an annoying assertion that I accidentally commented out.
747
748         * loader/icon/IconDatabase.cpp:
749         (WebCore::IconDatabase::synchronousIconForPageURL):
750
751 2013-11-06  Brendan Long  <b.long@cablelabs.com>
752
753         [GStreamer] Override label() and language() in Audio and VideoTrackPrivateGStreamer
754         https://bugs.webkit.org/show_bug.cgi?id=123836
755
756         The tests are currently flakey because we only get the label and language if we get
757         tags after the track client is set.
758
759         Reviewed by Philippe Normand.
760
761         No new tests because the tests already exist (this fixes flakeyness).
762
763         * platform/graphics/gstreamer/AudioTrackPrivateGStreamer.h: Override label() and language() to use m_label and m_language.
764         * platform/graphics/gstreamer/VideoTrackPrivateGStreamer.h: Same.
765         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h: Make m_label and m_language protected so they can be used in the functions above.
766
767 2013-11-05  Andreas Kling  <akling@apple.com>
768
769         RenderBlockFlow should only expose its line boxes as RootInlineBox.
770         <https://webkit.org/b/123878>
771
772         The line boxes attached directly to a RenderBlockFlow are always
773         RootInlineBox objects, so call sites should always use the tightly
774         typed firstRootBox() and lastRootBox().
775
776         This allows the compiler to devirtualize calls to member functions
777         of RootInlineBox that are marked FINAL.
778
779         Reviewed by Antti Koivisto.
780
781 2013-11-06  Ryosuke Niwa  <rniwa@webkit.org>
782
783         Assertion failure end < m_runCount in WebCore::BidiRunList<WebCore::BidiRun>::reverseRuns
784         https://bugs.webkit.org/show_bug.cgi?id=123863
785
786         Reviewed by Andreas Kling.
787
788         Merge https://chromium.googlesource.com/chromium/blink/+/cbaa92c763a37d89eeabd01658e522219299290c
789
790         Test: fast/text/bidi-reverse-runs-crash.html
791
792         * platform/text/BidiResolver.h:
793         (WebCore::BidiResolver<Iterator, Run>::createBidiRunsForLine): Don't reverse the runs if there's
794         nothing to be reversed.
795
796 2013-11-05  Ryosuke Niwa  <rniwa@webkit.org>
797
798         Address the review comment after r158724.
799
800         * html/RangeInputType.cpp:
801         (WebCore::RangeInputType::handleMouseDownEvent):
802
803 2013-11-05  Zalan Bujtas  <zalan@apple.com>
804
805         Widget's position change should not initiate layout, only when its size changes.
806         https://bugs.webkit.org/show_bug.cgi?id=123860
807
808         Reviewed by Andreas Kling.
809
810         RenderWidgets initiate unnecessary layouts while scrolling when they are embedded to
811         overflow:scroll containers. Scroll position change doesn't dirty the render tree
812         so it should not trigger layout either.
813
814         Manual test added. Unfortunately we can't test against the number of layouts yet.
815
816         * rendering/RenderWidget.cpp:
817         (WebCore::RenderWidget::setWidgetGeometry):
818         (WebCore::RenderWidget::updateWidgetGeometry):
819         (WebCore::RenderWidget::updateWidgetPosition):
820
821 2013-11-05  Ryosuke Niwa  <rniwa@webkit.org>
822
823         Use-after-free in SliderThumbElement::dragFrom
824         https://bugs.webkit.org/show_bug.cgi?id=123873
825
826         Reviewed by Andreas Kling.
827
828         Ref the SliderThumbElement since it could go away inside dragFrom.
829
830         Test: fast/forms/range/range-type-change-onchange-2.html
831
832         * html/RangeInputType.cpp:
833         (WebCore::RangeInputType::handleMouseDownEvent):
834
835 2013-11-05  Ryosuke Niwa  <rniwa@webkit.org>
836
837         Change the order of conditions to avoid computing rendererIsEditable()
838         https://bugs.webkit.org/show_bug.cgi?id=123868
839
840         Reviewed by Andreas Kling.
841
842         Merge https://chromium.googlesource.com/chromium/blink/+/c89b413ff0fc4aafa0c71d180b0b1e131bb37707
843
844         When we need both Node::renderer() and Node::rendererIsEditable() conditions to be true to perform
845         some operation, it is more effective to check for renderer() first, so that if this condition fails
846         we can avoid unnecessary computation of rendererIsEditable().
847
848         * dom/Position.cpp:
849         (WebCore::nextRenderedEditable):
850         (WebCore::previousRenderedEditable):
851         * page/EventHandler.cpp:
852         (WebCore::EventHandler::handleMouseReleaseEvent):
853
854 2013-11-05  Ryosuke Niwa  <rniwa@webkit.org>
855
856         simpleUserAgentStyleSheet doesn't have focus ring on anchor element
857         https://bugs.webkit.org/show_bug.cgi?id=123867
858
859         Reviewed by Andreas Kling.
860
861         Merge https://chromium.googlesource.com/chromium/blink/+/08ecc23c4d80be9969918c4baf0ac83dc6cb6cbd
862
863         * css/CSSDefaultStyleSheets.cpp:
864
865 2013-11-05  Ryosuke Niwa  <rniwa@webkit.org>
866
867         valueForBorderRadiusShorthand returns wrong values in some case
868         https://bugs.webkit.org/show_bug.cgi?id=123866
869
870         Reviewed by Andreas Kling.
871
872         Merge https://chromium.googlesource.com/chromium/blink/+/0933728126f2db06ab8e945efc98bffa2d42af1c
873
874         Because valueForBorderRadiusShorthand misses the followings:
875         - showHorizontalBottomRight depends on showHorizontalBottomLeft.
876         - showHorizontalTopRight depends on showHorizontalBottomRight (including showHorizontalBottomLeft).
877
878         See also http://dev.w3.org/csswg/css-backgrounds/#the-border-radius
879
880         Test: fast/css/getComputedStyle/getComputedStyle-borderRadius-2.html
881
882         * css/CSSComputedStyleDeclaration.cpp:
883         (WebCore::getBorderRadiusShorthandValue):
884
885 2013-11-05  Ryosuke Niwa  <rniwa@webkit.org>
886
887         Protect DOM nodes in IndentOutdentCommand::tryIndentingAsListItem()
888         https://bugs.webkit.org/show_bug.cgi?id=123861
889
890         Reviewed by Benjamin Poulain.
891
892         Merge https://chromium.googlesource.com/chromium/blink/+/297442eb539a2b764fdad323de79099a70179186 partially.
893
894         * editing/IndentOutdentCommand.cpp:
895         (WebCore::IndentOutdentCommand::tryIndentingAsListItem): Make selectedListItem, previousList, and nextList
896         RefPtr since they're are used after calling insertNodeBefore.
897
898 2013-11-05  Andreas Kling  <akling@apple.com>
899
900         Apply more unique_ptr to line box management.
901         <https://webkit.org/b/123857>
902
903         Make all of the functions that return newly-created line boxes
904         return them packed up in std::unique_ptrs.
905
906         There is one exception in RenderBlockLineLayout where the function
907         createInlineBoxForRenderer() is inconsistent about the ownership of
908         the returned object. This will be addressed by a subsequent patch.
909
910         We now "release" the line boxes into their various home structures,
911         so the pointer smartness doesn't go end-to-end just yet.
912
913         Reviewed by Anders Carlsson.
914
915 2013-11-05  Ryosuke Niwa  <rniwa@webkit.org>
916
917         getComputedStyle(x).lineHeight is affected by zooming
918         https://bugs.webkit.org/show_bug.cgi?id=123847
919
920         Reviewed by Benjamin Poulain.
921
922         Merge https://chromium.googlesource.com/chromium/blink/+/7957097afbab2899ababd0d9c8acbf6e3eddb870
923
924         Test: fast/css/line-height-zoom-get-computed-style.html
925
926         * css/CSSComputedStyleDeclaration.cpp:
927         (WebCore::lineHeightFromStyle): Don't round line-height values.
928         * css/DeprecatedStyleBuilder.cpp:
929         (WebCore::ApplyPropertyLineHeight::applyValue): Use the computed value instead of the used value.
930
931 2013-11-05  James Craig  <jcraig@apple.com>
932
933         AX: media controls accessibility needs more work
934         https://bugs.webkit.org/show_bug.cgi?id=123749
935
936         Reviewed by Jer Noble.
937
938         Updated some of the control labels/roles to improve accessibility.
939           - Volume slider is now keyboard/screenreader accessible.
940           - muteButton was a checkbox toggling checked state, now a button that toggles label "mute/unmute"
941           - fullscreenButton was a checkbox toggling checked state, now a button that toggles label "display/exit full screen"
942           - captionButton was a checkbox, now a popup button that launches the newly accessible menu.
943         Subtitles menu is now keyboard/screenreader accessible (uses roaming tabindex).
944         Render dump expectations changed because volume slider is now hidden via... 
945         ...opacity/size (to make accessible without hover) instead of display:none.
946
947         Updated existing test coverage.
948
949         * Modules/mediacontrols/mediaControlsApple.css:
950         (audio::-webkit-media-controls-panel .volume-box):
951         (audio::-webkit-media-controls-panel .volume-box:active):
952         (audio::-webkit-media-controls-toggle-closed-captions-button):
953         (audio::-webkit-media-controls-closed-captions-container .list):
954         (audio::-webkit-media-controls-closed-captions-container li:focus):
955         * Modules/mediacontrols/mediaControlsApple.js:
956         (Controller.prototype.createControls):
957         (Controller.prototype.handleFullscreenChange):
958         (Controller.prototype.handleMuteButtonClicked):
959         (Controller.prototype.handleMinButtonClicked):
960         (Controller.prototype.handleMaxButtonClicked):
961         (Controller.prototype.handleVolumeSliderChange):
962         (Controller.prototype.buildCaptionMenu):
963         (Controller.prototype.focusSiblingCaptionItem):
964         (Controller.prototype.handleCaptionItemKeyUp):
965
966 2013-11-05  Andreas Kling  <akling@apple.com>
967
968         Move some plugin-specific code from RenderWidget to RenderEmbeddedObject.
969         <https://webkit.org/b/123845>
970
971         All RenderWidgets representing plugins will be RenderEmbeddedObjects.
972         Move some of the plugin-specific logic to RenderEmbeddedObject since it
973         doesn't make sense for all RenderWidgets (frames, embedded documents)
974         to care about this.
975
976         Reviewed by Anders Carlsson.
977
978 2013-11-05  Tim Horton  <timothy_horton@apple.com>
979
980         Fix the 32-bit build.
981
982         * WebCore.exp.in:
983
984 2013-11-05  Alexandru Chiculita  <achicu@adobe.com>
985
986         Web Inspector: Moving an element while in the DOMNodeRemoved handler will hide it in the inspector
987         https://bugs.webkit.org/show_bug.cgi?id=123516
988
989         Reviewed by Timothy Hatcher.
990
991         InspectorInstrumentation::willRemoveDOMNode was actually calling both willRemoveDOMNodeImpl and
992         didRemoveDOMNodeImpl, making the DOMAgent unbind the element even if it was still part of the DOM.
993
994         Because of that the DOMAgent was sending two events:
995         1. When the element was about to be removed, just before JS "DOMNodeRemoved" was triggered.
996         2. When the element was actually removed.
997
998         Note that inspector's event #2 will not know about the node, as it just removed it from the
999         internal hashmap, so it will just use a nodeID == 0 for it.
1000
1001         This patch adds a separate call to InspectorInstrumentation::didRemoveDOMNode, just before the
1002         element is about to be removed. The InspectorInstrumentation::willRemoveDOMNode call is now only used
1003         by the DOMDebugger to trigger the DOM breakpoints in the Web Inspector. That feature is not exposed
1004         in the new Inspector UI, but can be used/tested using the protocol directly.
1005
1006         Tests: inspector-protocol/dom-debugger/node-removed.html
1007                inspector-protocol/dom/dom-remove-events.html
1008                inspector-protocol/dom/remove-multiple-nodes.html
1009
1010         * dom/ContainerNode.cpp:
1011         (WebCore::ContainerNode::removeBetween):
1012         * inspector/InspectorInstrumentation.h:
1013         (WebCore::InspectorInstrumentation::willRemoveDOMNode):
1014         (WebCore::InspectorInstrumentation::didRemoveDOMNode):
1015
1016 2013-11-05  Ryuan Choi  <ryuan.choi@samsung.com>
1017
1018         Unreviewed build fix on CMake based ports with GLES.
1019
1020         * CMakeLists.txt:
1021         Added OPENGLES2_LIBRARIES and OPENGLES2_INCLUDE_DIR into the includes and
1022         libraries list.
1023
1024 2013-11-05  Tim Horton  <timothy_horton@apple.com>
1025
1026         platformCALayerDeviceScaleFactor should be const
1027         https://bugs.webkit.org/show_bug.cgi?id=123842
1028
1029         Reviewed by Simon Fraser.
1030
1031         * WebCore.exp.in:
1032         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
1033         (WebCore::LayerClient::platformCALayerDeviceScaleFactor):
1034         * platform/graphics/ca/GraphicsLayerCA.cpp:
1035         (WebCore::GraphicsLayerCA::platformCALayerDeviceScaleFactor):
1036         * platform/graphics/ca/GraphicsLayerCA.h:
1037         * platform/graphics/ca/PlatformCALayerClient.h:
1038         * platform/graphics/ca/mac/TileController.h:
1039         * platform/graphics/ca/mac/TileController.mm:
1040         (WebCore::TileController::platformCALayerDeviceScaleFactor):
1041         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
1042         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerDeviceScaleFactor):
1043         Constify PlatformCALayerClient::platformCALayerDeviceScaleFactor.
1044
1045 2013-11-05  Gavin Barraclough  <barraclough@apple.com>
1046
1047         Subresource loads should not prevent page throttling
1048         https://bugs.webkit.org/show_bug.cgi?id=123757
1049
1050         Reviewed by Alexey Proskuryakov.
1051
1052         The page-is-loading test for inhibiting process supression is currently
1053         too conservative, preventing supression of pages with infinitely loading
1054         resources (commonly XHRs). Instead, just rely on the FrameLoader being
1055         active (with hysteresis).
1056
1057         * loader/SubresourceLoader.cpp:
1058         (WebCore::SubresourceLoader::init):
1059         (WebCore::SubresourceLoader::checkForHTTPStatusCodeError):
1060         (WebCore::SubresourceLoader::didFinishLoading):
1061         (WebCore::SubresourceLoader::didFail):
1062         (WebCore::SubresourceLoader::willCancel):
1063         * loader/SubresourceLoader.h:
1064             - remove m_activityAssertion from SubresourceLoader.
1065
1066 2013-11-05  Tim Horton  <timothy_horton@apple.com>
1067
1068         [mac] PDFDocumentImage is too big if PDF has a crop box smaller than the media box
1069         https://bugs.webkit.org/show_bug.cgi?id=123840
1070         <rdar://problem/15308765>
1071
1072         Reviewed by Alexey Proskuryakov.
1073
1074         Test: fast/images/pdf-as-image-crop-box.html
1075
1076         * platform/graphics/cg/PDFDocumentImage.cpp:
1077         (WebCore::PDFDocumentImage::size):
1078         Use the crop box when determining the size of the image.
1079
1080         (WebCore::PDFDocumentImage::computeBoundsForCurrentPage):
1081         * platform/graphics/cg/PDFDocumentImage.h:
1082         * platform/graphics/mac/PDFDocumentImageMac.mm:
1083         (WebCore::PDFDocumentImage::computeBoundsForCurrentPage):
1084         Get rid of m_mediaBox, since we don't need it anymore.
1085
1086         (WebCore::PDFDocumentImage::drawPDFPage):
1087         PDFKit does the translation by the crop box origin for us;
1088         if we do it additionally, we'll be painting the wrong part of the image.
1089         So, don't do the translation here.
1090
1091 2013-11-05  Antti Koivisto  <antti@apple.com>
1092
1093         Factor index cache for NodeLists and HTMLCollections to a class
1094         https://bugs.webkit.org/show_bug.cgi?id=123823
1095
1096         Reviewed by Ryosuke Niwa.
1097
1098         Implement index cache class that can used by NodeLists and HTMLCollections that currently
1099         each have implementations of their own.
1100         
1101         This patch also implements ChildNodeList and LiveNodeList using CollectionIndexCache.
1102         HTMLCollection is will be transitioned later.
1103
1104         * GNUmakefile.list.am:
1105         * WebCore.vcxproj/WebCore.vcxproj:
1106         * WebCore.xcodeproj/project.pbxproj:
1107         * dom/ChildNodeList.cpp:
1108         (WebCore::ChildNodeList::ChildNodeList):
1109         (WebCore::ChildNodeList::length):
1110         (WebCore::ChildNodeList::item):
1111         
1112             The client calls to cache to for indexed and size access.
1113
1114         (WebCore::ChildNodeList::collectionFirst):
1115         (WebCore::ChildNodeList::collectionLast):
1116         (WebCore::ChildNodeList::collectionTraverseForward):
1117         (WebCore::ChildNodeList::collectionTraverseBackward):
1118         
1119             Cache calls back to these as needed to do the actual traversal.
1120
1121         (WebCore::ChildNodeList::invalidateCache):
1122         * dom/ChildNodeList.h:
1123         * dom/CollectionIndexCache.h: Added.
1124         
1125             Templated cache class itself.
1126
1127         (WebCore::::CollectionIndexCache):
1128         (WebCore::::nodeCount):
1129         (WebCore::::nodeBeforeCached):
1130         (WebCore::::nodeAfterCached):
1131         (WebCore::::nodeAt):
1132         (WebCore::::invalidate):
1133         * dom/LiveNodeList.cpp:
1134         (WebCore::firstMatchingElement):
1135         (WebCore::nextMatchingElement):
1136         (WebCore::traverseMatchingElementsForward):
1137         (WebCore::LiveNodeList::collectionFirst):
1138         (WebCore::LiveNodeList::collectionLast):
1139         (WebCore::LiveNodeList::collectionTraverseForward):
1140         (WebCore::LiveNodeList::collectionTraverseBackward):
1141         (WebCore::LiveNodeList::length):
1142         (WebCore::LiveNodeList::item):
1143         (WebCore::LiveNodeList::invalidateCache):
1144         * dom/LiveNodeList.h:
1145         (WebCore::LiveNodeList::LiveNodeList):
1146
1147 2013-11-05  Enrica Casucci  <enrica@apple.com>
1148
1149         Full width semicolon is wrong in vertical text.
1150         https://bugs.webkit.org/show_bug.cgi?id=123814
1151         <rdar://problem/15312541>
1152
1153         Reviewed by Benjamin Poulain.
1154
1155         The full width semicolon should always be upright.
1156         Adding it to the list of characters that should
1157         ignore rotation.
1158
1159         * platform/graphics/FontGlyphs.cpp:
1160         (WebCore::shouldIgnoreRotation):
1161
1162 2013-11-05  Andreas Kling  <akling@apple.com>
1163
1164         Remove unused RenderWidget::notifyWidget().
1165
1166         Rubber-stamped by Anders Carlsson.
1167
1168 2013-11-05  Commit Queue  <commit-queue@webkit.org>
1169
1170         Unreviewed, rolling out r158678.
1171         http://trac.webkit.org/changeset/158678
1172         https://bugs.webkit.org/show_bug.cgi?id=123820
1173
1174         Causes a new debug assertion failure on the Mavericks test
1175         system. (Requested by bfulgham on #webkit).
1176
1177         * rendering/mathml/RenderMathMLOperator.cpp:
1178
1179 2013-11-05  Renata Hodovan  <reni@webkit.org>
1180
1181         ASSERTION FAILED: isHTMLTitleElement(m_titleElement.get()) in WebCore::Document::setTitle
1182         https://bugs.webkit.org/show_bug.cgi?id=122092
1183
1184         Reviewed by Darin Adler.
1185
1186         Remove a bogus assert in Document::setTitle().
1187         m_titleElement can be either of HTMLTitleElement or SVGTitleElement. The assertion was wrong.
1188         
1189         Backported from Blink:
1190         https://src.chromium.org/viewvc/blink?revision=158620&view=revision
1191
1192         Test: svg/custom/title-assertion.html
1193
1194         * dom/Document.cpp:
1195         (WebCore::Document::setTitle):
1196         * svg/SVGTitleElement.cpp:
1197         (WebCore::SVGTitleElement::insertedInto):
1198
1199 2013-11-05  Martin Robinson  <mrobinson@igalia.com>
1200
1201         [MathML] Poor spacing around delimiters in MathML Torture Test 14
1202         https://bugs.webkit.org/show_bug.cgi?id=122837
1203
1204         Reviewed by Brent Fulgham.
1205
1206         Instead of stretching the vertical bar with the stretchable version, just repeat
1207         the normal vertical bar. This follows what Gecko does when rendering tall vertical
1208         bars and also works around an issue with STIX fonts leading to poor spacing in
1209         formulas.
1210
1211         * rendering/mathml/RenderMathMLOperator.cpp: Stretch the vertical bar with the
1212         normal variant.
1213
1214 2013-11-05  Daniel Bates  <dabates@apple.com>
1215
1216         XSSAuditor should catch reflected srcdoc properties even without a <frame> tag injection
1217
1218         From Blink r160615 by <tsepez@chromium.org>
1219         https://src.chromium.org/viewvc/blink?view=rev&revision=160615
1220
1221         Test: http/tests/security/xssAuditor/iframe-srcdoc-property-blocked.html
1222
1223         * html/parser/XSSAuditor.cpp:
1224         (WebCore::XSSAuditor::filterIframeToken):
1225
1226 2013-11-05  Éva Balázsfalvi  <balazsfalvi.eva@stud.u-szeged.hu>
1227
1228         Delete maketokenizer.
1229         https://bugs.webkit.org/show_bug.cgi?id=115155
1230
1231         Reviewed by Zoltan Herczeg.
1232
1233         This script was used to generate the old flex based CSS tokenizer. It
1234         was replaced by a custom tokenizer in r106217 but the script wasn't
1235         removed. Since there is no mention of it in the original bug nor any
1236         reference to maketokenizer in our build files, it's probably an
1237         oversight.
1238
1239         Merge from blink:
1240         https://chromium.googlesource.com/chromium/blink/+/2a1c8aaf867f707ccdcd8893446e907e2aa2e1c2
1241
1242         * css/maketokenizer: Removed.
1243
1244 2013-11-05  Zan Dobersek  <zdobersek@igalia.com>
1245
1246         Unreviewed. Unbreaking GCC builds.
1247
1248         * html/HTMLCollection.cpp:
1249         (WebCore::isMatchingElement): This inline function is not a template anymore.
1250
1251 2013-11-05  Antti Koivisto  <antti@apple.com>
1252
1253         Make it compile.
1254
1255         * dom/LiveNodeList.h:
1256         (WebCore::LiveNodeList::LiveNodeList):
1257         (WebCore::LiveNodeList::~LiveNodeList):
1258         * dom/NodeRareData.h:
1259         (WebCore::NodeListsNodeData::adoptDocument):
1260         * html/HTMLCollection.cpp:
1261         (WebCore::HTMLCollection::HTMLCollection):
1262         (WebCore::HTMLCollection::~HTMLCollection):
1263
1264 2013-11-05  Antti Koivisto  <antti@apple.com>
1265
1266         HTMLCollection should not be NodeList
1267         https://bugs.webkit.org/show_bug.cgi?id=123794
1268
1269         Reviewed by Andreas Kling.
1270
1271         HTMLCollection and NodeList are unrelated types in DOM yet our HTMLCollection inherits NodeList
1272         for code sharing reasons. While some code does get shared the types are sufficiently different 
1273         that this results in lots of unnecessary branches, complexity and general awkwardness. Code sharing 
1274         can be better achieved by means other than inheritance.
1275         
1276         This patch splits HTMLCollection from NodeList by copy-pasting and eliminating resulting redundancies. 
1277         Sharing comes later.
1278
1279         * dom/Attr.cpp:
1280         (WebCore::Attr::setValue):
1281         (WebCore::Attr::childrenChanged):
1282         * dom/ClassNodeList.cpp:
1283         (WebCore::ClassNodeList::~ClassNodeList):
1284         * dom/ContainerNode.cpp:
1285         (WebCore::ContainerNode::childrenChanged):
1286         (WebCore::ContainerNode::getElementsByTagName):
1287         (WebCore::ContainerNode::getElementsByName):
1288         (WebCore::ContainerNode::getElementsByClassName):
1289         (WebCore::ContainerNode::radioNodeList):
1290         * dom/Document.cpp:
1291         (WebCore::Document::Document):
1292         (WebCore::Document::~Document):
1293         (WebCore::Document::registerNodeList):
1294         (WebCore::Document::unregisterNodeList):
1295         (WebCore::Document::registerCollection):
1296         (WebCore::Document::unregisterCollection):
1297         (WebCore::Document::ensureCachedCollection):
1298         
1299             Add separate functions and map for registering HTMLCollections.
1300
1301         (WebCore::Document::all):
1302         (WebCore::Document::windowNamedItems):
1303         (WebCore::Document::documentNamedItems):
1304         * dom/Document.h:
1305         * dom/Element.cpp:
1306         (WebCore::Element::attributeChanged):
1307         (WebCore::Element::ensureCachedHTMLCollection):
1308         (WebCore::Element::cachedHTMLCollection):
1309         * dom/LiveNodeList.cpp:
1310         (WebCore::LiveNodeList::rootNode):
1311         (WebCore::isMatchingElement):
1312         (WebCore::LiveNodeList::iterateForPreviousElement):
1313         (WebCore::LiveNodeList::itemBefore):
1314         (WebCore::firstMatchingElement):
1315         (WebCore::nextMatchingElement):
1316         (WebCore::traverseMatchingElementsForwardToOffset):
1317         (WebCore::LiveNodeList::traverseLiveNodeListFirstElement):
1318         (WebCore::LiveNodeList::traverseLiveNodeListForwardToOffset):
1319         (WebCore::LiveNodeList::isLastItemCloserThanLastOrCachedItem):
1320         (WebCore::LiveNodeList::isFirstItemCloserThanCachedItem):
1321         (WebCore::LiveNodeList::length):
1322         (WebCore::LiveNodeList::item):
1323         (WebCore::LiveNodeList::elementBeforeOrAfterCachedElement):
1324         
1325             This code used to live in HTMLCollection.cpp. Copy-paste here and remove all branches not needed for NodeLists.
1326
1327         (WebCore::LiveNodeList::invalidateCache):
1328         
1329             NodeLists have no name caches.
1330
1331         * dom/LiveNodeList.h:
1332         (WebCore::LiveNodeList::LiveNodeList):
1333         (WebCore::LiveNodeList::~LiveNodeList):
1334         (WebCore::LiveNodeList::isRootedAtDocument):
1335         (WebCore::LiveNodeList::type):
1336         (WebCore::LiveNodeList::invalidateCache):
1337         (WebCore::LiveNodeList::setCachedElement):
1338         
1339             Merge LiveNodeListBase and LiveNodeList.
1340             Remove fields and code supporting HTMLCollection.
1341
1342         (WebCore::shouldInvalidateTypeOnAttributeChange):
1343         
1344             Move to global scope. This function is used both HTMLCollections and LiveNodeLists.
1345
1346         * dom/NameNodeList.cpp:
1347         (WebCore::NameNodeList::~NameNodeList):
1348         * dom/NameNodeList.h:
1349         (WebCore::NameNodeList::create):
1350         * dom/Node.cpp:
1351         (WebCore::shouldInvalidateNodeListCachesForAttr):
1352         (WebCore::Document::shouldInvalidateNodeListAndCollectionCaches):
1353         (WebCore::Document::invalidateNodeListAndCollectionCaches):
1354         (WebCore::Node::invalidateNodeListAndCollectionCachesInAncestors):
1355         (WebCore::NodeListsNodeData::invalidateCaches):
1356         * dom/Node.h:
1357         * dom/NodeRareData.h:
1358         (WebCore::NodeListsNodeData::addCacheWithAtomicName):
1359         (WebCore::NodeListsNodeData::addCacheWithName):
1360         (WebCore::NodeListsNodeData::addCacheWithQualifiedName):
1361         (WebCore::NodeListsNodeData::addCachedCollection):
1362         (WebCore::NodeListsNodeData::cachedCollection):
1363         (WebCore::NodeListsNodeData::removeCacheWithAtomicName):
1364         (WebCore::NodeListsNodeData::removeCacheWithName):
1365         (WebCore::NodeListsNodeData::removeCachedCollection):
1366         (WebCore::NodeListsNodeData::isEmpty):
1367         (WebCore::NodeListsNodeData::adoptDocument):
1368         (WebCore::NodeListsNodeData::namedCollectionKey):
1369         (WebCore::NodeListsNodeData::namedNodeListKey):
1370         (WebCore::NodeListsNodeData::deleteThisAndUpdateNodeRareDataIfAboutToRemoveLastList):
1371         
1372             Add separate cache for HTMLCollections.
1373
1374         * dom/TagNodeList.cpp:
1375         (WebCore::TagNodeList::TagNodeList):
1376         (WebCore::TagNodeList::~TagNodeList):
1377         * dom/TagNodeList.h:
1378         (WebCore::TagNodeList::create):
1379         (WebCore::HTMLTagNodeList::create):
1380         * html/CollectionType.h:
1381         
1382             Remove NodeList types.
1383
1384         * html/HTMLCollection.cpp:
1385         (WebCore::shouldOnlyIncludeDirectChildren):
1386         (WebCore::rootTypeFromCollectionType):
1387         (WebCore::invalidationTypeExcludingIdAndNameAttributes):
1388         (WebCore::HTMLCollection::HTMLCollection):
1389         (WebCore::HTMLCollection::~HTMLCollection):
1390         (WebCore::HTMLCollection::rootNode):
1391         (WebCore::isMatchingElement):
1392         (WebCore::HTMLCollection::iterateForPreviousElement):
1393         (WebCore::HTMLCollection::itemBefore):
1394         (WebCore::firstMatchingElement):
1395         (WebCore::nextMatchingElement):
1396         (WebCore::traverseMatchingElementsForwardToOffset):
1397         (WebCore::HTMLCollection::isLastItemCloserThanLastOrCachedItem):
1398         (WebCore::HTMLCollection::isFirstItemCloserThanCachedItem):
1399         (WebCore::HTMLCollection::setCachedElement):
1400         (WebCore::HTMLCollection::length):
1401         (WebCore::HTMLCollection::item):
1402         (WebCore::HTMLCollection::elementBeforeOrAfterCachedElement):
1403         (WebCore::HTMLCollection::traverseFirstElement):
1404         (WebCore::HTMLCollection::traverseNextElement):
1405         (WebCore::HTMLCollection::traverseForwardToOffset):
1406         (WebCore::HTMLCollection::invalidateCache):
1407         (WebCore::HTMLCollection::invalidateIdNameCacheMaps):
1408         (WebCore::HTMLCollection::namedItem):
1409         
1410             Remove NodeList specific branches and functions.
1411             LiveNodeListBase functions are now HTMLCollection functions.
1412
1413         * html/HTMLCollection.h:
1414         (WebCore::HTMLCollection::isRootedAtDocument):
1415         (WebCore::HTMLCollection::invalidationType):
1416         (WebCore::HTMLCollection::type):
1417         (WebCore::HTMLCollection::ownerNode):
1418         (WebCore::HTMLCollection::invalidateCache):
1419         (WebCore::HTMLCollection::document):
1420         (WebCore::HTMLCollection::overridesItemAfter):
1421         (WebCore::HTMLCollection::isElementCacheValid):
1422         (WebCore::HTMLCollection::cachedElement):
1423         (WebCore::HTMLCollection::cachedElementOffset):
1424         (WebCore::HTMLCollection::isLengthCacheValid):
1425         (WebCore::HTMLCollection::cachedLength):
1426         (WebCore::HTMLCollection::setLengthCache):
1427         (WebCore::HTMLCollection::setCachedElement):
1428         (WebCore::HTMLCollection::isItemRefElementsCacheValid):
1429         (WebCore::HTMLCollection::setItemRefElementsCacheValid):
1430         (WebCore::HTMLCollection::rootType):
1431         (WebCore::HTMLCollection::hasNameCache):
1432         (WebCore::HTMLCollection::setHasNameCache):
1433         
1434             Copy-paste functions and fields from former LiveNodeListBase.
1435
1436         * html/HTMLNameCollection.cpp:
1437         (WebCore::HTMLNameCollection::~HTMLNameCollection):
1438         * html/LabelableElement.cpp:
1439         (WebCore::LabelableElement::labels):
1440         * html/LabelsNodeList.cpp:
1441         (WebCore::LabelsNodeList::~LabelsNodeList):
1442         * html/LabelsNodeList.h:
1443         * html/RadioNodeList.cpp:
1444         (WebCore::RadioNodeList::~RadioNodeList):
1445         * html/RadioNodeList.h:
1446         (WebCore::RadioNodeList::create):
1447
1448 2013-11-05  Emilio Pozuelo Monfort  <pochu27@gmail.com>
1449
1450         [GTK] Add stubs for missing symbols in dom bindings
1451         https://bugs.webkit.org/show_bug.cgi?id=123663
1452
1453         Reviewed by Carlos Garcia Campos.
1454
1455         * bindings/gobject/WebKitDOMCustom.cpp:
1456         (webkit_dom_html_head_element_get_profile):
1457         (webkit_dom_html_head_element_set_profile):
1458         (webkit_dom_processing_instruction_get_data):
1459         (webkit_dom_processing_instruction_set_data):
1460         * bindings/gobject/WebKitDOMCustom.h:
1461         * bindings/gobject/WebKitDOMCustom.symbols:
1462
1463 2013-11-05  Zan Dobersek  <zdobersek@igalia.com>
1464
1465         Main thread tasks in ThreadableBlobRegistry should use std::unique_ptr
1466         https://bugs.webkit.org/show_bug.cgi?id=122946
1467
1468         Reviewed by Darin Adler.
1469
1470         The new BlobRegistryContext objects don't have to be adopted into OwnPtr and then have OwnPtr's leaked pointer
1471         passed into the WTF::callOnMainThread call - the pointer to the new heap-allocated object is passed in directly,
1472         with the object ending up being managed by std::unique_ptr in the designated main thread task.
1473
1474         * fileapi/ThreadableBlobRegistry.cpp:
1475         (WebCore::registerBlobURLTask):
1476         (WebCore::ThreadableBlobRegistry::registerBlobURL):
1477         (WebCore::registerBlobURLFromTask):
1478         (WebCore::unregisterBlobURLTask):
1479         (WebCore::ThreadableBlobRegistry::unregisterBlobURL):
1480
1481 2013-11-05  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1482
1483         [CSS] Enable css-image-orientation on EFL and GTK ports.
1484         https://bugs.webkit.org/show_bug.cgi?id=123698
1485
1486         Reviewed by Beth Dakin.
1487
1488         r157909 added wrong early return for css-image-orientation. It causes about 20 regressions in layout test
1489         when enabling css-image-orientation. This fixes those wrong implementation as well as enables it on EFL
1490         and GTK ports by default.
1491
1492         Test: fast/css/image-orientation/image-orientation.html
1493
1494         * loader/cache/CachedImage.cpp:
1495         (WebCore::CachedImage::imageSizeForRenderer):
1496         * platform/graphics/BitmapImage.cpp:
1497         (WebCore::BitmapImage::updateSize):
1498
1499 2013-11-05  Andreas Kling  <akling@apple.com>
1500
1501         RenderEmbeddedObject shouldn't know about fallback content.
1502         <https://webkit.org/b/123781>
1503
1504         Stop caching the presence of fallback (DOM) content in a flag on
1505         RenderEmbeddedObject and have SubframeLoader fetch it directly from
1506         HTMLObjectElement instead.
1507
1508         Also made SubframeLoader::requestObject() take the owner element
1509         by reference since we don't support owner-less embedded objects.
1510
1511         Reviewed by Antti Koivisto.
1512
1513 2013-11-05  Xabier Rodriguez Calvar  <calvaris@igalia.com>
1514
1515         [GStreamer] Remove NATIVE_FULLSCREEN_VIDEO support
1516         https://bugs.webkit.org/show_bug.cgi?id=123437
1517
1518         Reviewed by Philippe Normand.
1519
1520         Removed some dead code as no GStreamer port is using the native
1521         fullscreen video support.
1522
1523         * GNUmakefile.list.am:
1524         * PlatformEfl.cmake:
1525         * PlatformGTK.cmake: Removed compilation of deleted files.
1526         * platform/graphics/MediaPlayer.h: Removed structures related to
1527         GStreamer and NATIVE_FULLSCREEN_VIDEO.
1528         * platform/graphics/gstreamer/FullscreenVideoControllerGStreamer.cpp: Removed.
1529         * platform/graphics/gstreamer/FullscreenVideoControllerGStreamer.h: Removed.
1530         * platform/graphics/gstreamer/GStreamerGWorld.cpp: Removed.
1531         * platform/graphics/gstreamer/GStreamerGWorld.h: Removed.
1532         * platform/graphics/gstreamer/ImageGStreamerCairo.cpp: Removed
1533         gst/video/video.h include.
1534         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
1535         (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
1536         (WebCore::MediaPlayerPrivateGStreamerBase::platformMedia):
1537         (WebCore::MediaPlayerPrivateGStreamerBase::createVideoSink):
1538         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
1539         Removed code related to GStreamer and NATIVE_FULLSCREEN_VIDEO.
1540         * platform/graphics/gstreamer/PlatformVideoWindow.h: Removed.
1541         * platform/graphics/gstreamer/PlatformVideoWindowEfl.cpp: Removed.
1542         * platform/graphics/gstreamer/PlatformVideoWindowGtk.cpp: Removed.
1543         * platform/graphics/gstreamer/PlatformVideoWindowMac.mm: Removed.
1544         * platform/graphics/gstreamer/PlatformVideoWindowNix.cpp: Removed.
1545         * platform/graphics/gstreamer/PlatformVideoWindowPrivate.h: Removed.
1546         * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
1547         (webkitVideoSinkRender):
1548         (webkitVideoSinkNew):
1549         * platform/graphics/gstreamer/VideoSinkGStreamer.h: Removed code
1550         related to GStreamer and NATIVE_FULLSCREEN_VIDEO.
1551         * platform/graphics/gtk/FullscreenVideoControllerGtk.cpp: Removed.
1552         * platform/graphics/gtk/FullscreenVideoControllerGtk.h: Removed.
1553
1554 2013-11-05  Andreas Kling  <akling@apple.com>
1555
1556         Remove RenderWidget::viewCleared().
1557         <https://webkit.org/b/123777>
1558
1559         This was some ancient hand-waving code from the KHTML era.
1560
1561         It was obviously confused (e.g RenderEmbeddedObject trying to handle
1562         iframe owners, even though that setup is impossible.)
1563
1564         Reviewed by Anders Carlsson.
1565
1566 2013-11-04  Brady Eidson  <beidson@apple.com>
1567
1568         IDB: Split backend Cursors and Transactions into their own files
1569         https://bugs.webkit.org/show_bug.cgi?id=123789
1570
1571         Reviewed by Alexey Proskuryakov.
1572
1573         No new tests (Rename, no change in behavior).
1574
1575         * CMakeLists.txt:
1576         * GNUmakefile.list.am:
1577         * WebCore.xcodeproj/project.pbxproj:
1578
1579         * Modules/indexeddb/IDBBackingStoreCursorInterface.h:
1580         (WebCore::IDBBackingStoreCursorInterface::~IDBBackingStoreCursorInterface):
1581
1582         * Modules/indexeddb/IDBBackingStoreInterface.h:
1583
1584         * Modules/indexeddb/IDBBackingStoreTransactionInterface.h: Added.
1585         (WebCore::IDBBackingStoreTransactionInterface::~IDBBackingStoreTransactionInterface):
1586
1587         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
1588         (WebCore::IDBCursorBackendImpl::IDBCursorBackendImpl):
1589         * Modules/indexeddb/IDBCursorBackendImpl.h:
1590         (WebCore::IDBCursorBackendImpl::create):
1591
1592         * Modules/indexeddb/IDBFactoryBackendInterface.h:
1593
1594         * Modules/indexeddb/IDBIndexWriter.cpp:
1595         (WebCore::IDBIndexWriter::writeIndexKeys):
1596         (WebCore::IDBIndexWriter::verifyIndexKeys):
1597         (WebCore::IDBIndexWriter::addingKeyAllowed):
1598         * Modules/indexeddb/IDBIndexWriter.h:
1599
1600         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
1601         (WebCore::IDBTransactionBackendImpl::createCursorBackend):
1602         * Modules/indexeddb/IDBTransactionBackendImpl.h:
1603         * Modules/indexeddb/IDBTransactionBackendInterface.h:
1604
1605         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
1606         (WebCore::GetOperation::perform):
1607         (WebCore::OpenCursorOperation::perform):
1608         (WebCore::CountOperation::perform):
1609         (WebCore::DeleteRangeOperation::perform):
1610
1611         * Modules/indexeddb/leveldb/IDBBackingStoreCursorLevelDB.cpp: Added.
1612         (WebCore::IDBBackingStoreCursorLevelDB::IDBBackingStoreCursorLevelDB):
1613         (WebCore::IDBBackingStoreCursorLevelDB::firstSeek):
1614         (WebCore::IDBBackingStoreCursorLevelDB::advance):
1615         (WebCore::IDBBackingStoreCursorLevelDB::continueFunction):
1616         (WebCore::IDBBackingStoreCursorLevelDB::haveEnteredRange):
1617         (WebCore::IDBBackingStoreCursorLevelDB::isPastBounds):
1618         * Modules/indexeddb/leveldb/IDBBackingStoreCursorLevelDB.h: Added.
1619         (WebCore::IDBBackingStoreCursorLevelDB::~IDBBackingStoreCursorLevelDB):
1620         (WebCore::IDBBackingStoreCursorLevelDB::IDBBackingStoreCursorLevelDB):
1621
1622         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
1623         (WebCore::IDBBackingStoreLevelDB::compareIndexKeys):
1624         (WebCore::IDBBackingStoreLevelDB::updateIDBDatabaseVersion):
1625         (WebCore::IDBBackingStoreLevelDB::createObjectStore):
1626         (WebCore::IDBBackingStoreLevelDB::deleteObjectStore):
1627         (WebCore::IDBBackingStoreLevelDB::getRecord):
1628         (WebCore::IDBBackingStoreLevelDB::putRecord):
1629         (WebCore::IDBBackingStoreLevelDB::clearObjectStore):
1630         (WebCore::IDBBackingStoreLevelDB::deleteRecord):
1631         (WebCore::IDBBackingStoreLevelDB::getKeyGeneratorCurrentNumber):
1632         (WebCore::IDBBackingStoreLevelDB::maybeUpdateKeyGeneratorCurrentNumber):
1633         (WebCore::IDBBackingStoreLevelDB::keyExistsInObjectStore):
1634         (WebCore::IDBBackingStoreLevelDB::createIndex):
1635         (WebCore::IDBBackingStoreLevelDB::deleteIndex):
1636         (WebCore::IDBBackingStoreLevelDB::putIndexDataForRecord):
1637         (WebCore::findGreatestKeyLessThanOrEqual):
1638         (WebCore::IDBBackingStoreLevelDB::findKeyInIndex):
1639         (WebCore::IDBBackingStoreLevelDB::getPrimaryKeyViaIndex):
1640         (WebCore::IDBBackingStoreLevelDB::keyExistsInIndex):
1641         (WebCore::ObjectStoreKeyCursorImpl::create):
1642         (WebCore::ObjectStoreKeyCursorImpl::clone):
1643         (WebCore::ObjectStoreKeyCursorImpl::ObjectStoreKeyCursorImpl):
1644         (WebCore::ObjectStoreCursorImpl::create):
1645         (WebCore::ObjectStoreCursorImpl::clone):
1646         (WebCore::ObjectStoreCursorImpl::ObjectStoreCursorImpl):
1647         (WebCore::objectStoreCursorOptions):
1648         (WebCore::indexCursorOptions):
1649         (WebCore::IDBBackingStoreLevelDB::openObjectStoreCursor):
1650         (WebCore::IDBBackingStoreLevelDB::openObjectStoreKeyCursor):
1651         (WebCore::IDBBackingStoreLevelDB::openIndexKeyCursor):
1652         (WebCore::IDBBackingStoreLevelDB::openIndexCursor):
1653         (WebCore::IDBBackingStoreLevelDB::createBackingStoreTransaction):
1654         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
1655  
1656        * Modules/indexeddb/leveldb/IDBBackingStoreTransactionLevelDB.cpp: Added.
1657         (WebCore::IDBBackingStoreTransactionLevelDB::IDBBackingStoreTransactionLevelDB):
1658         (WebCore::IDBBackingStoreTransactionLevelDB::begin):
1659         (WebCore::IDBBackingStoreTransactionLevelDB::commit):
1660         (WebCore::IDBBackingStoreTransactionLevelDB::rollback):
1661         * Modules/indexeddb/leveldb/IDBBackingStoreTransactionLevelDB.h:
1662
1663         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
1664         (WebCore::IDBFactoryBackendLevelDB::createCursorBackend):
1665         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.h:
1666
1667 2013-11-04  Zalan Bujtas  <zalan@apple.com>
1668
1669         Do not call setFrameRect on Widget unless its boundaries changed.
1670         https://bugs.webkit.org/show_bug.cgi?id=123781
1671
1672         Reviewed by Andreas Kling.
1673
1674         Call Widget:setFrameRect only when the frame's rect actually changes. It also
1675         cleans up the related weak reference code a bit.
1676         
1677         Covered by existing tests.
1678
1679         * rendering/RenderWidget.cpp:
1680         (WebCore::RenderWidget::setWidgetGeometry): 
1681
1682 2013-11-04  Santosh Mahto  <santosh.ma@samsung.com>
1683
1684         [webcore/html] remove extra header includes from cpp files.
1685         https://bugs.webkit.org/show_bug.cgi?id=123740
1686
1687         Reviewed by Darin Adler.
1688
1689         Removing redundant headers.
1690
1691         * html/BaseDateAndTimeInputType.cpp:
1692         * html/ColorInputType.cpp:
1693         * html/DOMFormData.cpp:
1694         * html/DOMURL.cpp:
1695         * html/DateInputType.cpp:
1696         * html/DateTimeInputType.cpp:
1697         * html/DateTimeLocalInputType.cpp:
1698         * html/FTPDirectoryDocument.cpp:
1699         * html/FileInputType.cpp:
1700         * html/FormController.cpp:
1701         * html/HTMLAnchorElement.cpp:
1702         * html/HTMLAreaElement.cpp:
1703         * html/HTMLCanvasElement.cpp:
1704         * html/HTMLCollection.cpp:
1705         * html/HTMLDetailsElement.cpp:
1706         * html/HTMLDocument.cpp:
1707         * html/HTMLElement.cpp:
1708         * html/HTMLFormControlsCollection.cpp:
1709         * html/HTMLFormElement.cpp:
1710         * html/HTMLImageElement.cpp:
1711         * html/HTMLInputElement.cpp:
1712         * html/HTMLLegendElement.cpp:
1713         * html/HTMLMapElement.cpp:
1714         * html/HTMLMediaElement.cpp:
1715         * html/HTMLOptionElement.cpp:
1716         * html/HTMLOptionsCollection.cpp:
1717         * html/HTMLPlugInImageElement.cpp:
1718         * html/HTMLProgressElement.cpp:
1719         * html/HTMLSummaryElement.cpp:
1720         * html/HTMLTemplateElement.cpp:
1721         * html/HTMLVideoElement.cpp:
1722         * html/HTMLViewSourceDocument.cpp:
1723         * html/MediaController.cpp:
1724         * html/MediaKeyEvent.cpp:
1725         * html/MonthInputType.cpp:
1726         * html/RangeInputType.cpp:
1727         * html/StepRange.cpp:
1728         * html/TextFieldInputType.cpp:
1729         * html/TimeInputType.cpp:
1730         * html/WeekInputType.cpp:
1731         * html/canvas/CanvasRenderingContext.cpp:
1732         * html/canvas/CanvasRenderingContext2D.cpp:
1733         * html/canvas/CanvasStyle.cpp:
1734         * html/canvas/OESVertexArrayObject.cpp:
1735         * html/parser/BackgroundHTMLParser.cpp:
1736         * html/parser/CSSPreloadScanner.cpp:
1737         * html/parser/CompactHTMLToken.cpp:
1738         * html/parser/HTMLConstructionSite.cpp:
1739         * html/parser/HTMLDocumentParser.cpp:
1740         * html/parser/HTMLElementStack.cpp:
1741         * html/parser/HTMLFormattingElementList.cpp:
1742         * html/parser/HTMLMetaCharsetParser.cpp:
1743         * html/parser/HTMLParserIdioms.cpp:
1744         * html/parser/HTMLPreloadScanner.cpp:
1745         * html/parser/HTMLTokenizer.cpp:
1746         * html/parser/HTMLTreeBuilder.cpp:
1747         * html/parser/HTMLTreeBuilderSimulator.cpp:
1748         * html/parser/HTMLViewSourceParser.cpp:
1749         * html/parser/TextDocumentParser.cpp:
1750         * html/parser/XSSAuditor.cpp:
1751         * html/shadow/ContentDistributor.cpp:
1752         * html/shadow/InsertionPoint.cpp:
1753         * html/shadow/MediaControlElements.cpp:
1754         * html/shadow/MediaControlsApple.cpp:
1755         * html/shadow/MediaControlsBlackBerry.cpp:
1756         * html/shadow/MediaControlsGtk.cpp:
1757         * html/shadow/SliderThumbElement.cpp:
1758         * html/track/AudioTrack.cpp:
1759         * html/track/InbandGenericTextTrack.cpp:
1760         * html/track/InbandTextTrack.cpp:
1761         * html/track/InbandWebVTTTextTrack.cpp:
1762         * html/track/TextTrack.cpp:
1763         * html/track/TextTrackCueGeneric.cpp:
1764         * html/track/TextTrackList.cpp:
1765         * html/track/TextTrackRegion.cpp:
1766         * html/track/TrackListBase.cpp:
1767         * html/track/VideoTrack.cpp:
1768         * html/track/WebVTTParser.cpp:
1769
1770 2013-11-04  Brady Eidson  <beidson@apple.com>
1771
1772         IDB: deleteDatabase() interface should be asynchronous
1773         https://bugs.webkit.org/show_bug.cgi?id=123787
1774
1775         Reviewed by Tim Horton.
1776
1777         No new tests (No behavior change for a tested port).
1778
1779         deleteDatabase now has no return value, but calls back to a bool function:
1780         * Modules/indexeddb/IDBBackingStoreInterface.h:
1781         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
1782         (WebCore::IDBBackingStoreLevelDB::deleteDatabase):
1783         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
1784
1785         Refactor to account for the new async deleteDatabase:
1786         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
1787         (WebCore::IDBDatabaseBackendImpl::processPendingCalls):
1788         (WebCore::IDBDatabaseBackendImpl::deleteDatabase):
1789         (WebCore::IDBDatabaseBackendImpl::deleteDatabaseAsync):
1790         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
1791
1792 2013-11-04  Brady Eidson  <beidson@apple.com>
1793
1794         Add Modules/indexeddb/leveldb to the WebCore.xcodeproj
1795
1796         Rubberstamped by Andreas Kling.
1797
1798         This will make hacking on IDB much easier for Mac developers as they won’t have
1799         to constantly add and then subtract the leveldb subdirectory.
1800
1801         The USE(LEVELDB) flag is still disabled so these files won’t actually build by default.
1802
1803         * WebCore.xcodeproj/project.pbxproj:
1804
1805 2013-11-04  Brady Eidson  <beidson@apple.com>
1806
1807         Address review feedback I forgot to commit in r158641
1808
1809         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
1810         (WebCore::IDBDatabaseBackendImpl::processPendingOpenCalls):
1811
1812 2013-11-04  Brady Eidson  <beidson@apple.com>
1813
1814         IDB: Make opening/establishing a database asynchronous.
1815         https://bugs.webkit.org/show_bug.cgi?id=123775
1816
1817         Reviewed by Andreas Kling.
1818
1819         No new tests (No behavior change for a tested port).
1820
1821         * Modules/indexeddb/IDBBackingStoreInterface.h: Add getOrEstablishIDBDatabaseMetadata with a callback,
1822           removing getIDBDatabaseMetaData, getObjectStores, and createIDBDatabaseMetaData in the process.
1823
1824         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
1825         (WebCore::IDBBackingStoreLevelDB::getOrEstablishIDBDatabaseMetadata): Adapted from getIDBDatabaseMetaData,
1826           implement the asynchronous interface in terms of other LevelDB methods, always calling back synchronously.
1827         (WebCore::IDBBackingStoreLevelDB::createIDBDatabaseMetaData):
1828         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
1829
1830         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
1831         (WebCore::IDBDatabaseBackendImpl::create):
1832         (WebCore::IDBDatabaseBackendImpl::openInternalAsync): Broken off from openInternal.
1833         (WebCore::IDBDatabaseBackendImpl::didOpenInternalAsync): Broken off from openInternal.
1834         (WebCore::IDBDatabaseBackendImpl::processPendingCalls):
1835         (WebCore::IDBDatabaseBackendImpl::processPendingOpenCalls): Broken off to allow didOpenInternalAsync
1836           to perform open callbacks in the failure case.
1837         (WebCore::IDBDatabaseBackendImpl::openConnection): Always queue open connection calls, then immediately processPendingCalls.
1838         (WebCore::IDBDatabaseBackendImpl::openConnectionInternal): Actually perform open connection calls.
1839         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
1840
1841
1842 2013-11-04  Andreas Kling  <akling@apple.com>
1843
1844         CTTE: RenderFrameBase's widget is always a FrameView.
1845         <https://webkit.org/b/123771>
1846
1847         Delete widget() from RenderFrameBase and supplant a childView()
1848         that returns FrameView*. Strip away unnecessary casts and asserts.
1849
1850         Reviewed by Antti Koivisto.
1851
1852 2013-11-04  Zoltan Horvath  <zoltan@webkit.org>
1853
1854         [CSS Regions][CSS Shapes] Content in region doesn't respect shape-outside after initial layout pass
1855         <https://webkit.org/b/114829>
1856
1857         Although we set the size of a shape for shape-outside in RenderBlockFlow::insertFloatingObject based on the
1858         float's size, the actual height of the float is not always resolved at that point. (Look at cases when the shape
1859         has percentage based height or percentage based radius.) ShapeInfo::setShapeSize triggers a layout for 0 height
1860         value, which will be overriden later, when RenderBlockFlow::positionNewFloats sets the actual size of the float (shape).
1861         Thus it doesn't make sense to set the shape's size in insertFloatingObject and run those extra unnecessary layout passes,
1862         since it'll be overriden anyways. I moved the shape size setting logic into RenderBlockFlow::positionNewFloats.
1863
1864         The problem showed up when we had a shape-outside ellipse with percentage based radius, and we inserted the content
1865         with JavaScript into a region flow. The content has been layed out based on the 0 border radius, and relayout hasn't been
1866         triggered when it flew into the flow. This change sets the shape size only when we already have the height of the float,
1867         so the radius(es) can be resolved correctly, thus no unnecessary layout passes will happen and the layout will be correct as well.
1868
1869         Reviewed by David Hyatt.
1870
1871         Test: fast/shapes/shape-outside-floats/shape-outside-floats-layout-after-initial-layout-pass.html
1872
1873         * rendering/RenderBlockFlow.cpp:
1874         (WebCore::RenderBlockFlow::insertFloatingObject): Remove setting the size of the shape.
1875         (WebCore::RenderBlockFlow::positionNewFloats): Set the size of the shape here.
1876
1877 2013-11-04  Samuel White  <samuel_white@apple.com>
1878
1879         AX: AXShowMenu doesn't always work.
1880         https://bugs.webkit.org/show_bug.cgi?id=123649
1881
1882         Reviewed by Chris Fleizach.
1883
1884         No new tests, the change occurs in a code path that forces the context menu to show which
1885         locks up DRT if we try to test it (platform menu is shown). The change itself gives the mouse
1886         event handler a chance to handle our platform mouse event BEFORE the event ends up in the show
1887         context menu machinery. This is necessary because without it, the element will not become
1888         focused. Without focus, accessibility shows different/less menu items than a mouse click. The
1889         end result is that context menus shown via accessibility are consistent with menus shown via click.
1890
1891         * page/ContextMenuController.cpp:
1892         (WebCore::ContextMenuController::showContextMenuAt):
1893
1894 2013-11-04  Jeffrey Pfau  <jpfau@apple.com>
1895
1896         SMIL timers can still fire after the containing document has been torn down
1897         <https://webkit.org/b/123291>
1898
1899         Reviewed by Darin Adler.
1900
1901         Ensure that the timers get paused when the document is preparing to be torn down.
1902
1903         Test: svg/animations/smil-timers-not-disabled-crash.html
1904
1905         * dom/Document.cpp:
1906         (WebCore::Document::dropChildren):
1907         (WebCore::Document::commonTeardown):
1908         (WebCore::Document::prepareForDestruction):
1909         * dom/Document.h:
1910
1911 2013-11-04  Brendan Long  <b.long@cablelabs.com>
1912
1913         Move duplicate code in TrackPrivate classes to a common base class
1914         https://bugs.webkit.org/show_bug.cgi?id=123619
1915
1916         Reviewed by Darin Adler.
1917
1918         No new tests because this is just refactoring.
1919
1920         * GNUmakefile.list.am: Add TrackPrivateBase.
1921         * WebCore.vcxproj/WebCore.vcxproj: Same.
1922         * WebCore.vcxproj/WebCore.vcxproj.filters: Same.
1923         * WebCore.xcodeproj/project.pbxproj: Same.
1924         * html/track/AudioTrack.cpp:
1925         (WebCore::AudioTrack::inbandTrackIndex): Renamed audioTrackIndex() to trackIndex().
1926         (WebCore::AudioTrack::labelChanged): First argument is now a TrackPrivateBase*.
1927         (WebCore::AudioTrack::languageChanged): Same.
1928         (WebCore::AudioTrack::willRemove): Same.
1929         * html/track/AudioTrack.h: Update TrackPrivateBaseClient function signatures.
1930         * html/track/InbandTextTrack.cpp:
1931         (WebCore::InbandTextTrack::inbandTrackIndex): Renamed textTrackIndex() to trackIndex().
1932         (WebCore::InbandTextTrack::labelChanged): First argument is now a TrackPrivateBase*.
1933         (WebCore::InbandTextTrack::languageChanged): Same.
1934         (WebCore::InbandTextTrack::willRemove): Same.
1935         * html/track/InbandTextTrack.h: Update TrackPrivateBaseClient function signatures.
1936         * html/track/VideoTrack.cpp:
1937         (WebCore::VideoTrack::inbandTrackIndex): Renamed videoTrackIndex() to trackIndex().
1938         (WebCore::VideoTrack::labelChanged): First argument is now a TrackPrivateBase*.
1939         (WebCore::VideoTrack::languageChanged): Same.
1940         (WebCore::VideoTrack::willRemove): Same.
1941         * html/track/VideoTrack.h: Update TrackPrivateBaseClient function signatures.
1942         * platform/graphics/AudioTrackPrivate.h: Remove code that was moved to TrackPrivateBase.
1943         * platform/graphics/InbandTextTrackPrivate.h: Same.
1944         * platform/graphics/InbandTextTrackPrivateClient.h: Same.
1945         * platform/graphics/VideoTrackPrivate.h: Same.
1946         * platform/graphics/TrackPrivateBase.h: Refactored out duplicate code in AudioTrackPrivate, InbandTextTrackPrivate and VideoTrackPrivate.
1947         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h: Renamed textTrackIndex() to trackIndex().
1948         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h: Same.
1949         * platform/graphics/gstreamer/AudioTrackPrivateGStreamer.h: Renamed audioTrackIndex() to trackIndex().
1950         * platform/graphics/gstreamer/VideoTrackPrivateGStreamer.h: Renamed videoTrackIndex() to trackIndex90.
1951
1952 2013-11-04  Andreas Kling  <akling@apple.com>
1953
1954         FrameView destructor is worried about being retained by a renderer.
1955         <https://webkit.org/b/123763>
1956
1957         There's no way we can be in ~FrameView() while also being owned by
1958         a RenderWidget. Remove some overly paranoid code that was making sure
1959         the renderer didn't have a reference on us.
1960
1961         Reviewed by Anders Carlsson.
1962
1963 2013-11-04  Eric Carlson  <eric.carlson@apple.com>
1964
1965         REGRESSION(r158311): media/media-fragments/TC0054.html and TC0061.html hit assertions
1966         https://bugs.webkit.org/show_bug.cgi?id=123555
1967
1968         Reviewed by Darin Adler.
1969
1970         No new tests, covered by existing tests.
1971
1972         * html/MediaFragmentURIParser.cpp:
1973         (WebCore::MediaFragmentURIParser::parseFragments): Don't add a fragment with empty key or value as
1974             they will not processed.
1975         (WebCore::MediaFragmentURIParser::parseNPTFragment): Remove excess whitespace.
1976
1977 2013-11-04  Patrick Gansterer  <paroga@webkit.org>
1978
1979         Remove code duplications in createFontCustomPlatformData()
1980         https://bugs.webkit.org/show_bug.cgi?id=123706
1981
1982         Reviewed by Darin Adler.
1983
1984         Move OpenTypeSanitizer and WOFF handling from the port specific
1985         implementations in createFontCustomPlatformData() into the only
1986         caller of this function CachedFont::ensureCustomFontData().
1987         Also change the parameter passing the SharedBuffer from a
1988         pointer to a reference since it is never null.
1989
1990         * loader/cache/CachedFont.cpp:
1991         (WebCore::CachedFont::ensureCustomFontData):
1992         * platform/graphics/blackberry/FontCustomPlatformData.h:
1993         * platform/graphics/blackberry/FontCustomPlatformDataBlackBerry.cpp:
1994         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
1995         (WebCore::createFontCustomPlatformData):
1996         * platform/graphics/cairo/FontCustomPlatformData.h:
1997         * platform/graphics/freetype/FontCustomPlatformDataFreeType.cpp:
1998         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
1999         (WebCore::createFontCustomPlatformData):
2000         * platform/graphics/mac/FontCustomPlatformData.cpp:
2001         (WebCore::createFontCustomPlatformData):
2002         * platform/graphics/mac/FontCustomPlatformData.h:
2003         * platform/graphics/win/FontCustomPlatformData.cpp:
2004         (WebCore::createFontCustomPlatformData):
2005         * platform/graphics/win/FontCustomPlatformData.h:
2006         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
2007         (WebCore::createFontCustomPlatformData):
2008         * platform/graphics/wince/FontCustomPlatformData.cpp:
2009         (WebCore::createFontCustomPlatformData):
2010         * platform/graphics/wince/FontCustomPlatformData.h:
2011
2012 2013-11-04  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
2013
2014         Fixing MediaStreamDescriptor addSource and addTrack methods
2015         https://bugs.webkit.org/show_bug.cgi?id=123755
2016
2017         Reviewed by Eric Carlson.
2018
2019         We must store the track and source that is passed as parameter in a RefPtr,
2020         otherwise we will refer to a null pointer.
2021
2022         No new tests needed.
2023
2024         * platform/mediastream/MediaStreamDescriptor.cpp:
2025         (WebCore::MediaStreamDescriptor::addSource):
2026         (WebCore::MediaStreamDescriptor::addTrack):
2027
2028 2013-11-04  Tim Horton  <timothy_horton@apple.com>
2029
2030         Remove PlatformCALayer::playerLayer
2031         https://bugs.webkit.org/show_bug.cgi?id=123764
2032
2033         Reviewed by Sam Weinig.
2034
2035         * platform/graphics/ca/PlatformCALayer.h:
2036         * platform/graphics/ca/mac/PlatformCALayerMac.h:
2037         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2038         (PlatformCALayerMac::clone):
2039         Remove playerLayer(), fold it into clone().
2040
2041 2013-11-04  Chris Fleizach  <cfleizach@apple.com>
2042
2043         AX: Mail attachments at the start of an email are not output by VoiceOver
2044         https://bugs.webkit.org/show_bug.cgi?id=123697
2045
2046         Reviewed by Ryosuke Niwa.
2047
2048         VoiceOver is expecting that "replaced elements" (attachments in a Mail message in this case) to be
2049         represented by the replacement character when asking for a stringForRange.
2050
2051         However, when that replaced element is at the beginning of the document, the logic does not work because
2052         there is a few code places that will take that first Position and advance it forward, not accounting for replaced elements.
2053         When using the TextIterator normally, it does account for these, so that's why it's only affecting as at the beginning of the document.
2054
2055         Also a "replaced element" can be more than just renderer->isReplaced(), hence the externing of the isRendererReplacedElement method
2056         and using that it in pertinent places.
2057
2058         Tests: platform/mac/accessibility/object-replacement-with-no-rendered-children-at-node-start.html
2059                platform/mac/accessibility/object-replacement-with-rendered-children-at-node-start.html
2060
2061         * accessibility/AccessibilityObject.cpp:
2062         (WebCore::replacedNodeNeedsCharacter):
2063         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2064         (nsStringForReplacedNode):
2065         * dom/Position.cpp:
2066         (WebCore::Position::isCandidate):
2067         * dom/PositionIterator.cpp:
2068         * dom/Range.cpp:
2069         (WebCore::Range::firstNode):
2070         * editing/TextIterator.cpp:
2071         (WebCore::isRendererReplacedElement):
2072         * editing/TextIterator.h:
2073
2074 2013-11-04  Andreas Kling  <akling@apple.com>
2075
2076         Use RenderAncestorIterator in a couple of places.
2077         <https://webkit.org/b/123725>
2078
2079         Take the ancestorsOfType<RenderMoo>() thingy out for a spin.
2080
2081         Found a bunch of parent chain walking loops that were really just
2082         looking for the first ancestor renderer of a certain type.
2083         They were a perfect fit for this pattern:
2084
2085             if (auto svgRoot = ancestorsOfType<RenderSVGRoot>(renderer).first())
2086                 svgRoot->shakeMoneyMaker();
2087
2088         Quite a bit clearer than the previous:
2089
2090             for (auto ancestor = renderer.parent(); ancestor; ancestor = ancestor->parent()) {
2091                 if (ancestor->isSVGRoot())
2092                     toRenderSVGRoot(ancestor)->makeMoneyShaker();
2093             }
2094
2095         Reviewed by Antti Koivisto.
2096
2097 2013-10-25  Jer Noble  <jer.noble@apple.com>
2098
2099         [MSE] Add a SourceBufferPrivateClient interface for platform -> html communication.
2100         https://bugs.webkit.org/show_bug.cgi?id=123373
2101
2102         Reviewed by Eric Carlson.
2103
2104         To enable communication between SourceBuffer and SourceBufferPrivate without introducing
2105         layering violations, add a new interface class SourceBufferPrivateInterface from which
2106         SourceBuffer will inherit.
2107
2108         * Modules/mediasource/SourceBuffer.cpp:
2109         (WebCore::SourceBuffer::SourceBuffer): Set the private's client.
2110         (WebCore::SourceBuffer::~SourceBuffer): Clear the private's client.
2111         (WebCore::SourceBuffer::sourceBufferPrivateDidEndStream): Added stub.
2112         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment): Hinno.
2113         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto.
2114         (WebCore::SourceBuffer::sourceBufferPrivateHasAudio): Ditto.
2115         (WebCore::SourceBuffer::sourceBufferPrivateHasVideo): Ditto.
2116         * Modules/mediasource/SourceBuffer.h:
2117         * WebCore.xcodeproj/project.pbxproj: Add new files to project.
2118         * platform/graphics/SourceBufferPrivate.h:
2119         * platform/graphics/SourceBufferPrivateClient.h: Added.
2120         (WebCore::SourceBufferPrivateClient::~SourceBufferPrivateClient): Empty destructor.
2121
2122 2013-11-01  Jer Noble  <jer.noble@apple.com>
2123
2124         [PluginProxy] Add a setting to disable video plugin proxy support in HTMLMediaElement.
2125         https://bugs.webkit.org/show_bug.cgi?id=123621
2126
2127         Reviewed by Eric Carlson.
2128
2129         Add a new Setting which will disable the video plugin proxy. Enable support for AVFoundation
2130         in iOS (which requries fixing a few compile errors resulting from classes and methods which
2131         are not available on iOS.
2132
2133         * WebCore.exp.in: Export wkAVAssetResolvedURL.
2134         * css/StyleResolver.cpp:
2135         (WebCore::StyleResolver::canShareStyleWithElement): Make conditional upon
2136             new isVideoPluginProxyEnabled() setting.
2137         * html/HTMLMediaElement.cpp:
2138         (WebCore::HTMLMediaElement::parseAttribute): Ditto.
2139         * html/HTMLMediaElement.h:
2140         * html/HTMLVideoElement.cpp:
2141         (WebCore::HTMLVideoElement::createRenderer): Ditto.
2142         (WebCore::HTMLVideoElement::attach): Ditto.
2143         (WebCore::HTMLVideoElement::parseAttribute): Ditto.
2144         (HTMLVideoElement::setDisplayMode): Ditto.
2145         * html/HTMLVideoElement.h:
2146         * page/Settings.cpp:
2147         (WebCore::Settings::setVideoPluginProxyEnabled): Simple setter.
2148         * page/Settings.h:
2149         (WebCore::Settings::isVideoPluginProxyEnabled): Simple getter.
2150         * platform/graphics/MediaPlayer.cpp:
2151         (WebCore::installedMediaEngines): Conditionally add MediaPlayerPrivateIOS and always add
2152             MediaPlayerPriateAVFoundationObjC.
2153         * platform/graphics/MediaPlayerPrivate.h:
2154         (WebCore::MediaPlayerPrivateInterface::deliverNotification): Add default implementation.
2155         (WebCore::MediaPlayerPrivateInterface::setMediaPlayerProxy): Ditto.
2156         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2157         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2158         (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Use new
2159             HAS_ and USE_ macros instead of __MAC_OS_MIN_VERNSION_REQUIRED.
2160         (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC): Ditto.
2161         (WebCore::MediaPlayerPrivateAVFoundationObjC::hasContextRenderer): Ditto.
2162         (WebCore::MediaPlayerPrivateAVFoundationObjC::createContextVideoRenderer): Ditto.
2163         (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyContextVideoRenderer): Ditto.
2164         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Ditto.
2165         (WebCore::MediaPlayerPrivateAVFoundationObjC::paint): Ditto.
2166         (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Use cachedCGColor instead
2167             of CGColorGetConstantColor.
2168         (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoOutput): Use CVPixelBuffer pixel
2169             format constant instead of QuickDraw constant.
2170         (WebCore::MediaPlayerPrivateAVFoundationObjC::createPixelBuffer): Ditto.
2171         (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput): Draw to intermediary
2172             CGImage on iOS.
2173         * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.h:
2174         * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.mm:
2175         * platform/ios/WebCoreSystemInterfaceIOS.mm:
2176         * platform/mac/WebCoreSystemInterface.h:
2177
2178 2013-11-04  Andreas Kling  <akling@apple.com>
2179
2180         REGRESSION(r158561): fast/block/float/float-append-child-crash.html asserting.
2181
2182         The non-const ancestor iterator was walking siblings, not ancestors.
2183
2184         Rubber-stamped by Antti Koivisto.
2185
2186 2013-10-31  Jer Noble  <jer.noble@apple.com>
2187
2188         [MSE] [Mac] Disclaim support for MSE in AVFoundation and QTKit engines
2189         https://bugs.webkit.org/show_bug.cgi?id=123593
2190
2191         Reviewed by Eric Carlson.
2192
2193         Immediately fail if asked to load a Media Source in engines which do not support
2194         them.
2195
2196         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2197         (WebCore::MediaPlayerPrivateAVFoundation::load):
2198         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
2199         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2200         (WebCore::MediaPlayerPrivateAVFoundationObjC::supportsType):
2201         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
2202         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2203         (WebCore::MediaPlayerPrivateQTKit::load):
2204         (WebCore::MediaPlayerPrivateQTKit::supportsType):
2205
2206 2013-11-04  Hans Muller  <hmuller@adobe.com>
2207
2208         [CSS Shapes] image valued shape element margin can cause an ASSERT fail
2209         https://bugs.webkit.org/show_bug.cgi?id=123743
2210
2211         Reviewed by Andreas Kling.
2212
2213         When margin-top is specified for a shape's element, the Y coordinates passed
2214         to RasterShapeIntervals::getExcludedIntervals() may be negative. This is
2215         because the incoming logical coordinates are relative to the content or
2216         padding box, depending on the box-sizing property. The RasterShape::getExcludedIntervals()
2217         method now clips the incoming Y coordinates to the shape's bounds before
2218         accessing the shape's intervals.
2219
2220         Test: fast/shapes/shape-outside-floats/shape-outside-floats-margin-crash.html
2221
2222         * rendering/shapes/RasterShape.cpp:
2223         (WebCore::RasterShapeIntervals::getExcludedIntervals):
2224
2225 2013-11-04  Antti Koivisto  <antti@apple.com>
2226
2227         Make LiveNodeListBase use Elements instead of Nodes
2228         https://bugs.webkit.org/show_bug.cgi?id=123745
2229
2230         Reviewed by Anders Carlsson.
2231
2232         * WebCore.exp.in:
2233         * dom/Element.cpp:
2234         (WebCore::Element::firstElementChild):
2235         (WebCore::Element::lastElementChild):
2236         
2237             Switch to correct calls. ElementTraversal::previous and previousChild are no longer equivalent.
2238
2239         * dom/ElementTraversal.h:
2240         (WebCore::::lastWithinTemplate):
2241         (WebCore::::previousTemplate):
2242         
2243             Fix ElementTraversal::lastWithin and previous. They had no real clients and didn't work correctly.
2244             With LiveNodeListBase starting to use these they get excellent test coverage.
2245
2246         * dom/LiveNodeList.cpp:
2247         (WebCore::LiveNodeListBase::invalidateCache):
2248         * dom/LiveNodeList.h:
2249         (WebCore::LiveNodeListBase::LiveNodeListBase):
2250         (WebCore::LiveNodeListBase::isElementCacheValid):
2251         (WebCore::LiveNodeListBase::cachedElement):
2252         (WebCore::LiveNodeListBase::cachedElementOffset):
2253         (WebCore::LiveNodeListBase::setCachedElement):
2254         
2255             Make the cache Element based.
2256             Switch to Elements in all helpers.
2257             Rename item -> element for clarity.
2258
2259         * dom/NodeIterator.cpp:
2260         (WebCore::NodeIterator::NodePointer::moveToPrevious):
2261         (WebCore::NodeIterator::updateForNodeRemoval):
2262         
2263             This code expected the old inconsistent NodeTraversal::previous behavior where the traversal includes
2264             the root as the last item. Drop the stayWithin parameter and handle the one case where it is needed here.
2265
2266         * dom/NodeTraversal.cpp:
2267         (WebCore::NodeTraversal::last):
2268         (WebCore::NodeTraversal::deepLastChild):
2269         * dom/NodeTraversal.h:
2270         
2271             Support ElementTraversal::previous/lastWithin.
2272
2273         (WebCore::NodeTraversal::previous):
2274         
2275             This was slightly wrong too.
2276
2277         * html/HTMLCollection.cpp:
2278         (WebCore::previousElement):
2279         (WebCore::lastElement):
2280         (WebCore::LiveNodeListBase::iterateForPreviousElement):
2281         (WebCore::LiveNodeListBase::itemBefore):
2282         (WebCore::LiveNodeListBase::isLastItemCloserThanLastOrCachedItem):
2283         (WebCore::LiveNodeListBase::isFirstItemCloserThanCachedItem):
2284         (WebCore::LiveNodeListBase::setCachedElement):
2285         (WebCore::LiveNodeListBase::item):
2286         (WebCore::LiveNodeListBase::elementBeforeOrAfterCachedElement):
2287         * html/HTMLCollection.h:
2288         (WebCore::HTMLCollection::isEmpty):
2289         (WebCore::HTMLCollection::hasExactlyOneItem):
2290
2291 2013-11-04  Michael Saboff  <msaboff@apple.com>
2292
2293         Eliminate HostCall bit from JSC Stack CallerFrame
2294         https://bugs.webkit.org/show_bug.cgi?id=123642
2295
2296         Reviewed by Geoffrey Garen.
2297
2298         Updated JavaScript stack walking as a result of the corresponding changes made in
2299         JavaScriptCore.
2300
2301         * bindings/js/ScriptController.cpp:
2302         (WebCore::ScriptController::shouldBypassMainWorldContentSecurityPolicy):
2303         * bindings/js/ScriptDebugServer.cpp:
2304         (WebCore::ScriptDebugServer::stepOutOfFunction):
2305         (WebCore::ScriptDebugServer::returnEvent):
2306         (WebCore::ScriptDebugServer::didExecuteProgram):
2307
2308 2013-11-04  Bem Jones-Bey  <bjonesbe@adobe.com>
2309
2310         [css shapes] Fix support for shape-outside on a float with padding
2311         https://bugs.webkit.org/show_bug.cgi?id=123590
2312
2313         Reviewed by Alexandru Chiculita.
2314
2315         The line top was being improperly converted to the coordinates of the
2316         shape, causing the shape to be positioned incorrectly when the float
2317         had padding. This fixes that problem.
2318
2319         No new tests, covered by updates to existing ones.
2320
2321         * rendering/shapes/ShapeOutsideInfo.cpp:
2322         (WebCore::ShapeOutsideInfo::updateDeltasForContainingBlockLine):
2323
2324 2013-11-04  Alexey Proskuryakov  <ap@apple.com>
2325
2326         Implement generateKey for HMAC and AES-CBC
2327         https://bugs.webkit.org/show_bug.cgi?id=123669
2328
2329         Reviewed by Dan Bernstein.
2330
2331         Tests: crypto/subtle/aes-cbc-generate-key.html
2332                crypto/subtle/hmac-generate-key.html
2333
2334         * WebCore.xcodeproj/project.pbxproj: Added new files.
2335
2336         * bindings/js/JSCryptoAlgorithmDictionary.cpp:
2337         (WebCore::createAesKeyGenParams): Added bindings for AesKeyGenParams.
2338         (WebCore::JSCryptoAlgorithmDictionary::createParametersForGenerateKey): Handle
2339         algorithms that generate AES and HMAC keys.
2340
2341         * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::JSSubtleCrypto::generateKey): Added.
2342
2343         * crypto/CryptoAlgorithmAesKeyGenParams.h: Added.
2344
2345         * crypto/CryptoKey.cpp: (WebCore::CryptoKey::randomData):
2346         * crypto/CryptoKey.h:
2347         * crypto/CryptoKeyMac.cpp: Added
2348         Expose a function that produces random data for symmetric crypto keys. Cross-platform
2349         implementation uses ARC4 code from WTF, while Mac uses a system function that
2350         provides a FIPS validated random number generator.
2351
2352         * crypto/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::generate):
2353         * crypto/CryptoKeyAES.h:
2354         Added a function that creates AES keys.
2355
2356         * crypto/SubtleCrypto.idl: Added generateKey.
2357
2358         * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp:
2359         (WebCore::CryptoAlgorithmAES_CBC::generateKey): Added.
2360
2361         * crypto/algorithms/CryptoAlgorithmHMAC.cpp:
2362         (WebCore::CryptoAlgorithmHMAC::generateKey): Added.
2363
2364         * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::generate):
2365         * crypto/keys/CryptoKeyHMAC.h:
2366         Added a function that creates HMAC keys.
2367
2368         * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp: Removed generateKey stub, the implementation
2369         ended up in cross-platform file.
2370
2371         * crypto/mac/CryptoAlgorithmHMACMac.cpp: Ditto.
2372
2373 2013-11-04  Daniel Bates  <dabates@apple.com>
2374
2375         Revert SetCGFontRenderingMode() build fix for Chromium Mac
2376         https://bugs.webkit.org/show_bug.cgi?id=123633
2377
2378         Reviewed by Darin Adler.
2379
2380         Reverts <http://trac.webkit.org/changeset/134380>, which
2381         was a Chromium Mac build fix for <http://trac.webkit.org/changeset/134348>
2382         (https://bugs.webkit.org/show_bug.cgi?id=101787). Chromium doesn't
2383         build against top-of-tree WebKit.
2384
2385         * platform/graphics/mac/FontMac.mm:
2386         (WebCore::Font::drawGlyphs):
2387         * platform/mac/WebCoreSystemInterface.h:
2388         * platform/mac/WebCoreSystemInterface.mm:
2389
2390 2013-11-04  Commit Queue  <commit-queue@webkit.org>
2391
2392         Unreviewed, rolling out r158526.
2393         http://trac.webkit.org/changeset/158526
2394         https://bugs.webkit.org/show_bug.cgi?id=123744
2395
2396         it broke the build (Requested by jessieberlin on #webkit).
2397
2398         * WebCore.xcodeproj/project.pbxproj:
2399         * bindings/js/JSCryptoAlgorithmDictionary.cpp:
2400         (WebCore::createAesCbcParams):
2401         (WebCore::createHmacParams):
2402         (WebCore::createHmacKeyParams):
2403         (WebCore::JSCryptoAlgorithmDictionary::createParametersForGenerateKey):
2404         * bindings/js/JSSubtleCryptoCustom.cpp:
2405         * crypto/CryptoAlgorithmAesKeyGenParams.h: Removed.
2406         * crypto/CryptoKey.cpp:
2407         * crypto/CryptoKey.h:
2408         * crypto/CryptoKeyAES.cpp:
2409         * crypto/CryptoKeyAES.h:
2410         * crypto/CryptoKeyMac.cpp: Removed.
2411         * crypto/SubtleCrypto.idl:
2412         * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp:
2413         * crypto/algorithms/CryptoAlgorithmHMAC.cpp:
2414         * crypto/keys/CryptoKeyHMAC.cpp:
2415         * crypto/keys/CryptoKeyHMAC.h:
2416         * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp:
2417         (WebCore::CryptoAlgorithmAES_CBC::generateKey):
2418         * crypto/mac/CryptoAlgorithmHMACMac.cpp:
2419         (WebCore::CryptoAlgorithmHMAC::generateKey):
2420
2421 2013-11-04  Przemyslaw Szymanski  <p.szymanski3@samsung.com>
2422
2423         [Texmap] Remove redundant calls in CoordinatedGraphicsScene
2424         https://bugs.webkit.org/show_bug.cgi?id=123737
2425
2426         Reviewed by Noam Rosenthal.
2427
2428         Removing unused code left after few refactoring patches.
2429
2430         No new tests. Covered by existing ones.
2431
2432         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
2433         (WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext):
2434
2435 2013-11-04  Andreas Kling  <akling@apple.com>
2436
2437         CSSPrimitiveValue color constructors should return PassRef.
2438         <https://webkit.org/b/123728>
2439
2440         Make CSSPrimitiveValue::createColor() and the corresponding
2441         CSSValuePool helper functions return PassRef<CSSPrimitiveValue>.
2442
2443         Also made CSSValuePool slightly less stupid when hitting the upper
2444         size limit on the color value cache: instead of throwing out cache
2445         and rebuilding it from scratch, just remove one value at random.
2446
2447         Reviewed by Antti Koivisto.
2448
2449 2013-11-04  Andreas Kling  <akling@apple.com>
2450
2451         Some more RenderChildIterator deployment.
2452         <https://webkit.org/b/123735>
2453
2454         Convert another handful of loops to use childrenOfType<RenderFoo>
2455         iterators, mostly for skipping over uninteresting text renderers.
2456
2457         Reviewed by Antti Koivisto.
2458
2459 2013-11-04  Andreas Kling  <akling@apple.com>
2460
2461         LabelsNodeList always is always rooted at a LabelableElement.
2462         <https://webkit.org/b/123730>
2463
2464         Tighten up LabelsNodeList by enforcing that it's only rooted to
2465         a LabelableElement. Also marked the class FINAL and made its
2466         create() helper return PassRef.
2467
2468         Reviewed by Antti Koivisto.
2469
2470 2013-11-04  Andreas Kling  <akling@apple.com>
2471
2472         REGRESSION: RenderStyle is leaked when not creating renderer for display:none
2473         <https://webkit.org/b/123726>
2474
2475         Explicitly drop the RenderStyle reference in RenderElement::createFor
2476         if we decide to not create any renderer.
2477
2478         Reviewed by Antti Koivisto.
2479
2480         Test: fast/css/renderstyle-leak-with-display-none.html
2481
2482         * rendering/RenderElement.cpp:
2483         (WebCore::RenderElement::createFor):
2484
2485 2013-11-04  Santosh Mahto  <santosh.ma@samsung.com>
2486
2487         [webcore/dom] Remove extra header includes from cpp files.
2488         https://bugs.webkit.org/show_bug.cgi?id=123720
2489
2490         Reviewed by Andreas Kling.
2491
2492         Removing redundant headers from dom related cpp files.
2493
2494         * dom/Attr.cpp:
2495         * dom/CharacterData.cpp:
2496         * dom/ChildListMutationScope.cpp:
2497         * dom/ChildNodeList.cpp:
2498         * dom/ContainerNode.cpp:
2499         * dom/ContainerNodeAlgorithms.cpp:
2500         * dom/DOMNamedFlowCollection.cpp:
2501         * dom/DatasetDOMStringMap.cpp:
2502         * dom/Document.cpp:
2503         * dom/DocumentEventQueue.cpp:
2504         * dom/DocumentMarkerController.cpp:
2505         * dom/DocumentOrderedMap.cpp:
2506         * dom/DocumentStyleSheetCollection.cpp:
2507         * dom/Element.cpp:
2508         * dom/ElementRareData.cpp:
2509         * dom/Event.cpp:
2510         * dom/EventContext.cpp:
2511         * dom/EventDispatcher.cpp:
2512         * dom/EventTarget.cpp:
2513         * dom/ExceptionBase.cpp:
2514         * dom/FocusEvent.cpp:
2515         * dom/InlineStyleSheetOwner.cpp:
2516         * dom/KeyboardEvent.cpp:
2517         * dom/LiveNodeList.cpp:
2518         * dom/MessageEvent.cpp:
2519         * dom/MessagePort.cpp:
2520         * dom/MouseRelatedEvent.cpp:
2521         * dom/MutationEvent.cpp:
2522         * dom/MutationObserver.cpp:
2523         * dom/MutationObserverInterestGroup.cpp:
2524         * dom/MutationObserverRegistration.cpp:
2525         * dom/MutationRecord.cpp:
2526         * dom/NameNodeList.cpp:
2527         * dom/NamedFlowCollection.cpp:
2528         * dom/NamedNodeMap.cpp:
2529         * dom/Node.cpp:
2530         * dom/NodeIterator.cpp:
2531         * dom/NodeTraversal.cpp:
2532         * dom/PositionIterator.cpp:
2533         * dom/ProcessingInstruction.cpp:
2534         * dom/Range.cpp:
2535         * dom/RegisteredEventListener.cpp:
2536         * dom/ScopedEventQueue.cpp:
2537         * dom/ScriptElement.cpp:
2538         * dom/ScriptRunner.cpp:
2539         * dom/SelectorQuery.cpp:
2540         * dom/ShadowRoot.cpp:
2541         * dom/StyledElement.cpp:
2542         * dom/TagNodeList.cpp:
2543         * dom/Text.cpp:
2544         * dom/TextEvent.cpp:
2545         * dom/TouchEvent.cpp:
2546         * dom/TreeScope.cpp:
2547         * dom/TreeScopeAdopter.cpp:
2548         * dom/TreeWalker.cpp:
2549         * dom/UIEvent.cpp:
2550         * dom/UserActionElementSet.cpp:
2551         * dom/UserTypingGestureIndicator.cpp:
2552         * dom/VisitedLinkState.cpp:
2553         * dom/WebKitNamedFlow.cpp:
2554
2555 2013-11-04  Andreas Kling  <akling@apple.com>
2556
2557         HTMLAllCollection is always rooted at a Document.
2558         <https://webkit.org/b/123724>
2559
2560         Tighten up HTMLAllCollection by making the constructor take a
2561         Document& instead of a ContainerNode&. Drive-by application of
2562         FINAL and PassRef also happened.
2563
2564         Reviewed by Antti Koivisto.
2565
2566 2013-11-04  Andreas Kling  <akling@apple.com>
2567
2568         Make more CSSValue subclass constructors return PassRef.
2569         <https://webkit.org/b/123731>
2570
2571         Make the constructor helpers for the following classes return
2572         PassRef instead of PassRefPtr:
2573
2574             - CSSFontValue
2575             - CSSImageSetValue
2576             - CSSUnicodeRangeValue
2577             - WebKitCSSArrayFunctionValue
2578             - WebKitCSSFilterValue
2579             - WebKitCSSMatFunctionValue
2580             - WebKitCSSMixFunctionValue
2581             - WebKitCSSShaderValue
2582             - WebKitCSSTransformValue
2583
2584         Reviewed by Antti Koivisto.
2585
2586 2013-11-04  Jozsef Berta  <jberta@inf.u-szeged.hu>
2587
2588         Buildfix after r158182 for GCC 4.6
2589         https://bugs.webkit.org/show_bug.cgi?id=123442
2590
2591         Reviewed by Csaba Osztrogonác.
2592
2593         Added explicit "friend class", because  GCC 4.6 doesn't support extended friend declaration (c++11)
2594
2595         * dom/ScopedEventQueue.h:
2596
2597 2013-11-04  Andreas Kling  <akling@apple.com>
2598
2599         HTMLTableRowsCollection is always rooted at a HTMLTableElement.
2600         <https://webkit.org/b/123721>
2601
2602         Tighten up HTMLTableRowsCollection by making the create() helper
2603         take a HTMLTableElement& and adding a HTMLSelectElement& getter.
2604
2605         Reviewed by Antti Koivisto.
2606
2607 2013-11-04  Andreas Kling  <akling@apple.com>
2608
2609         HTMLNameCollection and friends are always rooted at a Document.
2610         <https://webkit.org/b/123722>
2611
2612         Tighten WindowNameCollection and DocumentNameCollection by making
2613         their constructors take a Document&, and add a slightly better
2614         document() than the one we inherit from LiveNodeListBase.
2615
2616         Also marked the classes FINAL and made create() helpers return
2617         PassRef instead of PassRefPtr.
2618
2619         Reviewed by Antti Koivisto.
2620
2621 2013-11-04  Andreas Kling  <akling@apple.com>
2622
2623         Add an ancestor renderer iterator.
2624         <https://webkit.org/b/123718>
2625
2626         Add ancestor iterators for renderers, analogous to element ancestor
2627         iterators. They walk the chain of parent renderers, stopping at each
2628         ancestor of a certain type.
2629
2630         Just like child renderer iterators, this requires isRendererOfType()
2631         to be implemented for the targeted renderer class.
2632
2633         You use them like this:
2634
2635         auto frameSets = ancestorsOfType<RenderFrameSet>(*this);
2636         for (auto frameSet = frameSets.begin(), end = frameSets.end(); frameSet != end; ++frameSet)
2637             frameSet->thisOrThat();
2638
2639         To complete the patch, I put them to use in a couple of random places.
2640
2641         Reviewed by Antti Koivisto.
2642
2643 2013-11-04  Mihnea Ovidenie  <mihnea@adobe.com>
2644
2645         [CSSRegions] Use auto keyword to clean-up for loops
2646         https://bugs.webkit.org/show_bug.cgi?id=123699
2647
2648         Reviewed by Anders Carlsson.
2649
2650         Start using auto keyword for loops.
2651         Also, since region breaks (forced breaks) can be added only on boxes,
2652         i changed RenderFlowThread::addForcedRegionBreak to use a RenderBox* instead of RenderObject*.
2653
2654         No change in functionality, no new tests.
2655
2656         * dom/WebKitNamedFlow.cpp:
2657         (WebCore::WebKitNamedFlow::firstEmptyRegionIndex):
2658         * rendering/FlowThreadController.cpp:
2659         (WebCore::FlowThreadController::ensureRenderFlowThreadWithName):
2660         (WebCore::FlowThreadController::styleDidChange):
2661         (WebCore::FlowThreadController::layoutRenderNamedFlowThreads):
2662         (WebCore::FlowThreadController::updateFlowThreadsChainIfNecessary):
2663         (WebCore::FlowThreadController::updateFlowThreadsNeedingLayout):
2664         (WebCore::FlowThreadController::updateFlowThreadsNeedingTwoStepLayout):
2665         (WebCore::FlowThreadController::resetFlowThreadsWithAutoHeightRegions):
2666         (WebCore::FlowThreadController::updateFlowThreadsIntoConstrainedPhase):
2667         (WebCore::FlowThreadController::updateFlowThreadsIntoOverflowPhase):
2668         (WebCore::FlowThreadController::updateFlowThreadsIntoMeasureContentPhase):
2669         (WebCore::FlowThreadController::updateFlowThreadsIntoFinalPhase):
2670         (WebCore::FlowThreadController::updateRenderFlowThreadLayersIfNeeded):
2671         (WebCore::FlowThreadController::collectFixedPositionedLayers):
2672         (WebCore::FlowThreadController::isAutoLogicalHeightRegionsCountConsistent):
2673         * rendering/RenderFlowThread.cpp:
2674         (WebCore::RenderFlowThread::validateRegions):
2675         (WebCore::RenderFlowThread::hasCompositingRegionDescendant):
2676         (WebCore::RenderFlowThread::getLayerListForRegion):
2677         (WebCore::RenderFlowThread::updateLayerToRegionMappings):
2678         (WebCore::RenderFlowThread::updateLogicalWidth):
2679         (WebCore::RenderFlowThread::computeLogicalHeight):
2680         (WebCore::RenderFlowThread::repaintRectangleInRegions):
2681         (WebCore::RenderFlowThread::removeRenderBoxRegionInfo):
2682         (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
2683         (WebCore::RenderFlowThread::clearRenderObjectCustomStyle):
2684         (WebCore::RenderFlowThread::clearRenderBoxRegionInfoAndCustomStyle):
2685         (WebCore::RenderFlowThread::setRegionRangeForBox):
2686         (WebCore::RenderFlowThread::getRegionRangeForBox):
2687         (WebCore::RenderFlowThread::regionInRange):
2688         (WebCore::RenderFlowThread::checkRegionsWithStyling):
2689         (WebCore::RenderFlowThread::objectInFlowRegion):
2690         (WebCore::RenderFlowThread::isAutoLogicalHeightRegionsCountConsistent):
2691         (WebCore::RenderFlowThread::initializeRegionsComputedAutoHeight):
2692         (WebCore::RenderFlowThread::markAutoLogicalHeightRegionsForLayout):
2693         (WebCore::RenderFlowThread::markRegionsForOverflowLayoutIfNeeded):
2694         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
2695         (WebCore::RenderFlowThread::addForcedRegionBreak):
2696         (WebCore::RenderFlowThread::collectLayerFragments):
2697         (WebCore::RenderFlowThread::fragmentsBoundingBox):
2698         (WebCore::RenderFlowThread::addRegionsVisualEffectOverflow):
2699         (WebCore::RenderFlowThread::addRegionsVisualOverflowFromTheme):
2700         (WebCore::RenderFlowThread::addRegionsOverflowFromChild):
2701         (WebCore::RenderFlowThread::addRegionsLayoutOverflow):
2702         (WebCore::RenderFlowThread::clearRegionsOverflow):
2703         * rendering/RenderFlowThread.h:
2704         * rendering/RenderNamedFlowThread.cpp:
2705         (WebCore::RenderNamedFlowThread::nextRendererForNode):
2706         (WebCore::RenderNamedFlowThread::previousRendererForNode):
2707         (WebCore::RenderNamedFlowThread::dependsOn):
2708         (WebCore::addRegionToList):
2709         (WebCore::RenderNamedFlowThread::computeOversetStateForRegions):
2710         (WebCore::RenderNamedFlowThread::checkInvalidRegions):
2711         (WebCore::RenderNamedFlowThread::pushDependencies):
2712         * rendering/RenderRegion.cpp:
2713         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
2714         (WebCore::RenderRegion::restoreRegionObjectsOriginalStyle):
2715         (WebCore::RenderRegion::computeChildrenStyleInRegion):
2716
2717 2013-11-03  Zan Dobersek  <zdobersek@igalia.com>
2718
2719         PingLoader objects unnecessarily pass through OwnPtr
2720         https://bugs.webkit.org/show_bug.cgi?id=122942
2721
2722         Reviewed by Darin Adler.
2723
2724         There's no need to store new PingLoader objects into an OwnPtr just to leak them out a few lines later
2725         into an unused variable. New objects are created through a new helper method and then left unmanaged as
2726         they're guaranteed to destroy themselves when they receive a response of any kind.
2727
2728         * loader/PingLoader.cpp:
2729         (WebCore::PingLoader::loadImage): Call the new createPingLoader method to spawn the PingLoader.
2730         (WebCore::PingLoader::sendPing): Ditto.
2731         (WebCore::PingLoader::sendViolationReport): Ditto.
2732         (WebCore::PingLoader::createPingLoader): A helper method that creates a new PingLoader object
2733         * loader/PingLoader.h: Declare the new PingLoader::createPingLoader method.
2734
2735 2013-11-03  Andreas Kling  <akling@apple.com>
2736
2737         HTMLOptionsCollection is always rooted at a HTMLSelectElement.
2738         <https://webkit.org/b/123719>
2739
2740         Tighten up HTMLOptionsCollection by making the constructor take
2741         a HTMLSelectElement& and adding a HTMLSelectElement& getter instead
2742         of casting all over the place. Removed now-pointless assertions.
2743
2744         Reviewed by Sam Weinig.
2745
2746 2013-11-03  Andreas Kling  <akling@apple.com>
2747
2748         RenderTextFragment: Tighten first-letter logic.
2749         <https://webkit.org/b/123714>
2750
2751         Reviewed by Antti Koivisto.
2752
2753         * editing/TextIterator.cpp:
2754         (WebCore::firstRenderTextInFirstLetter):
2755
2756             Use iterator helper to find first RenderText child.
2757
2758         (WebCore::TextIterator::handleTextNodeFirstLetter):
2759
2760             Tightening through type inference.
2761
2762         * rendering/RenderBlock.cpp:
2763         (WebCore::RenderBlock::updateFirstLetterStyle):
2764         (WebCore::RenderBlock::createFirstLetterRenderer):
2765         * rendering/RenderTextFragment.h:
2766
2767             The first letter renderer is always a RenderBoxModelObject,
2768             so make the code deal in that instead of RenderObject.
2769
2770         * rendering/RenderChildIterator.h:
2771         (WebCore::RenderChildIteratorAdapter::first):
2772         (WebCore::RenderChildIteratorAdapter::last):
2773
2774             Remove excess ampersands that were keeping this from building.
2775
2776 2013-11-03  Andreas Kling  <akling@apple.com>
2777
2778         CSSPrimitiveValue identifier constructors should return PassRef.
2779         <https://webkit.org/b/123712>
2780
2781         Make CSSPrimitiveValue::createIdentifier() and the corresponding
2782         CSSValuePool helper return PassRef<CSSPrimitiveValue>.
2783
2784         Reviewed by Antti Koivisto.
2785
2786 2013-11-03  Andreas Kling  <akling@apple.com>
2787
2788         Use RenderChildIterator in two more loops.
2789         <https://webkit.org/b/123713>
2790
2791         Switch two more renderer child traversal loops to childrenOfType.
2792
2793         Reviewed by Antti Koivisto.
2794
2795 2013-11-03  Andreas Kling  <akling@apple.com>
2796
2797         CSSShadowValue constructor should return PassRef.
2798         <https://webkit.org/b/123711>
2799
2800         Make CSSShadowValue::create() return a PassRef since it will never
2801         return null.
2802
2803         Reviewed by Sam Weinig.
2804
2805 2013-11-03  Andreas Kling  <akling@apple.com>
2806
2807         CSSLineBoxContainValue constructor should return PassRef.
2808         <https://webkit.org/b/123710>
2809
2810         Make CSSLineBoxContainValue::create() return a PassRef since it
2811         will never return null.
2812
2813         Reviewed by Sam Weinig.
2814
2815 2013-11-03  Antti Koivisto  <antti@apple.com>
2816
2817         LiveNodeLists should have non-null ContainerNode as root
2818         https://bugs.webkit.org/show_bug.cgi?id=123709
2819
2820         Reviewed by Andreas Kling.
2821
2822         After moving ChildNodeList off from LiveNodeList the root is now always at least a ContainerNode.
2823
2824         * dom/ContainerNode.cpp:
2825         (WebCore::ContainerNode::getElementsByTagName):
2826         (WebCore::ContainerNode::getElementsByTagNameNS):
2827         (WebCore::ContainerNode::getElementsByName):
2828         (WebCore::ContainerNode::getElementsByClassName):
2829         (WebCore::ContainerNode::radioNodeList):
2830         
2831             Also these move from Node to ContainerNode to make tighter typing work.
2832
2833 2013-11-03  Antti Koivisto  <antti@apple.com>
2834
2835         Switch createContextualFragment to element iterator
2836         https://bugs.webkit.org/show_bug.cgi?id=123704
2837
2838         Reviewed by Andreas Kling.
2839
2840         * editing/FrameSelection.cpp:
2841         (WebCore::scanForForm):
2842         
2843             Use type helpers instead of hasTagName
2844
2845         * editing/markup.cpp:
2846         (WebCore::collectElementsToRemoveFromFragment):
2847         (WebCore::removeElementFromFragmentPreservingChildren):
2848         (WebCore::createContextualFragment):
2849         * html/HTMLFormElement.cpp:
2850         (WebCore::HTMLFormElement::formElementIndex):
2851         
2852             Use type helpers instead of hasTagName
2853
2854         * html/HTMLTagNames.in:
2855         
2856             Generate type helpers for <html>.
2857
2858 2013-11-03  Antti Koivisto  <antti@apple.com>
2859
2860         ChildNodeList should not be LiveNodeList
2861         https://bugs.webkit.org/show_bug.cgi?id=123708
2862
2863         Reviewed by Sam Weinig.
2864
2865         ChildNodeList is a poor fit to be a LiveNodeList. It is heavily special-cased. It is also
2866         the only subtype that returns non-Elements thus preventing tightening.
2867
2868         * bindings/js/JSNodeListCustom.cpp:
2869         (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
2870         
2871             Support new types.
2872
2873         * dom/ChildNodeList.cpp:
2874         (WebCore::EmptyNodeList::~EmptyNodeList):
2875         (WebCore::ChildNodeList::ChildNodeList):
2876         (WebCore::ChildNodeList::~ChildNodeList):
2877         (WebCore::ChildNodeList::length):
2878         (WebCore::childFromFirst):
2879         (WebCore::childFromLast):
2880         (WebCore::ChildNodeList::nodeBeforeCached):
2881         (WebCore::ChildNodeList::nodeAfterCached):
2882         (WebCore::ChildNodeList::item):
2883         (WebCore::ChildNodeList::namedItem):
2884         (WebCore::ChildNodeList::invalidateCache):
2885         
2886             Implement the same caching optimizations as LiveNodeList with tighter, less generic code.
2887
2888         * dom/ChildNodeList.h:
2889         
2890             Inherit ChildNodeList directly from NodeList.
2891
2892             Add new EmptyNodeList type. This is only ever used if NodeList is requested for a non-container node.
2893             It allows tighter typing in ChildNodeList.
2894
2895         * dom/LiveNodeList.cpp:
2896         (WebCore::LiveNodeList::namedItem):
2897         * dom/LiveNodeList.h:
2898         (WebCore::LiveNodeListBase::LiveNodeListBase):
2899         (WebCore::LiveNodeListBase::~LiveNodeListBase):
2900         (WebCore::LiveNodeList::LiveNodeList):
2901         
2902             Remove ChildNodeList specific code and branches.
2903
2904         * dom/Node.cpp:
2905         (WebCore::Node::childNodes):
2906         
2907             Return EmptyNodeList for non-containers.
2908
2909         * dom/NodeList.h:
2910         (WebCore::NodeList::~NodeList):
2911         (WebCore::NodeList::isLiveNodeList):
2912         (WebCore::NodeList::isChildNodeList):
2913         (WebCore::NodeList::isEmptyNodeList):
2914         
2915             For isReachableFromOpaqueRoots.
2916
2917         * dom/NodeRareData.h:
2918         (WebCore::NodeListsNodeData::ensureChildNodeList):
2919         (WebCore::NodeListsNodeData::removeChildNodeList):
2920         (WebCore::NodeListsNodeData::ensureEmptyChildNodeList):
2921         (WebCore::NodeListsNodeData::removeEmptyChildNodeList):
2922         (WebCore::NodeListsNodeData::NodeListsNodeData):
2923         (WebCore::NodeListsNodeData::deleteThisAndUpdateNodeRareDataIfAboutToRemoveLastList):
2924         
2925             EmptyNodeList support.
2926
2927         * html/CollectionType.h:
2928         * html/HTMLCollection.cpp:
2929         (WebCore::shouldOnlyIncludeDirectChildren):
2930         (WebCore::rootTypeFromCollectionType):
2931         (WebCore::invalidationTypeExcludingIdAndNameAttributes):
2932         (WebCore::isMatchingElement):
2933         (WebCore::LiveNodeListBase::itemBefore):
2934         (WebCore::LiveNodeListBase::traverseLiveNodeListFirstElement):
2935         (WebCore::LiveNodeListBase::traverseLiveNodeListForwardToOffset):
2936         (WebCore::LiveNodeListBase::item):
2937         (WebCore::LiveNodeListBase::itemBeforeOrAfterCachedItem):
2938         
2939             Remove ChildNodeList specific code and branches.
2940
2941 2013-11-03  Patrick Gansterer  <paroga@webkit.org>
2942
2943         [WINCE] Replace OwnPtr with GDIObject
2944         https://bugs.webkit.org/show_bug.cgi?id=123670
2945
2946         Reviewed by Anders Carlsson.
2947
2948         * page/win/FrameGdiWin.cpp:
2949         (WebCore::imageFromRect):
2950         * platform/graphics/wince/FontPlatformData.cpp:
2951         (WebCore::FixedSizeFontData::create):
2952         (WebCore::FontPlatformData::hfont):
2953         (WebCore::FontPlatformData::getScaledFontHandle):
2954         * platform/graphics/wince/GraphicsContextWinCE.cpp:
2955         (WebCore::createPen):
2956         (WebCore::createBrush):
2957         (WebCore::GraphicsContext::drawRect):
2958         (WebCore::GraphicsContext::drawLine):
2959         (WebCore::GraphicsContext::drawEllipse):
2960         (WebCore::GraphicsContext::drawConvexPolygon):
2961         (WebCore::GraphicsContext::fillRect):
2962         (WebCore::GraphicsContext::clip):
2963         (WebCore::GraphicsContext::strokeRect):
2964         (WebCore::GraphicsContext::fillRoundedRect):
2965         (WebCore::GraphicsContext::drawRoundCorner):
2966         (WebCore::GraphicsContext::fillPath):
2967         (WebCore::GraphicsContext::strokePath):
2968         (WebCore::GraphicsContext::drawText):
2969         * platform/graphics/wince/ImageWinCE.cpp:
2970         (WebCore::BitmapImage::getHBITMAPOfSize):
2971         * platform/graphics/wince/SharedBitmap.cpp:
2972         (WebCore::SharedBitmap::createHandle):
2973         (WebCore::SharedBitmap::draw):
2974         (WebCore::SharedBitmap::clipBitmap):
2975         (WebCore::drawPatternSimple):
2976         (WebCore::SharedBitmap::drawPattern):
2977         (WebCore::SharedBitmap::DCProvider::getDC):
2978         * platform/graphics/wince/SharedBitmap.h:
2979
2980 2013-11-03  Antti Koivisto  <antti@apple.com>
2981
2982         Add helpers for partial descendant traversal to element iterators
2983         https://bugs.webkit.org/show_bug.cgi?id=123703
2984
2985         Reviewed by Andreas Kling.
2986
2987         * dom/ElementAncestorIterator.h:
2988         (WebCore::lineageOfType):
2989         
2990             lineageOfType definition didn't match the declaration.
2991
2992         * dom/ElementDescendantIterator.h:
2993         (WebCore::::find):
2994         (WebCore::::from):
2995         
2996             Add find and from for getting begin iterator for partial traversals.
2997
2998         * editing/FrameSelection.cpp:
2999         (WebCore::scanForForm):
3000         (WebCore::FrameSelection::currentForm):
3001         * html/HTMLFormElement.cpp:
3002         (WebCore::HTMLFormElement::formElementIndex):
3003         (WebCore::HTMLFormElement::findClosestFormAncestor):
3004         
3005             Use them in a few places.
3006
3007 2013-11-03  Andreas Kling  <akling@apple.com>
3008
3009         Inline RenderStyle functions for getting/setting pseudo style bits.
3010         <https://webkit.org/b/123702>
3011
3012         hasPseudoStyle() actually shows up on html5-full-render.html,
3013         and it's pretty crazy to eat the cost of a function call just
3014         to do some basic bit twiddling.
3015
3016         Reviewed by Antti Koivisto.
3017
3018 2013-11-03  Xabier Rodriguez Calvar  <calvaris@igalia.com>
3019
3020         Remove HTMLMediaElement.initialTime
3021         https://bugs.webkit.org/show_bug.cgi?id=123572
3022
3023         Reviewed by Eric Carlson.
3024
3025         Patch based on one by: philipj@opera.com
3026         Blink review URL: https://codereview.chromium.org/35033002
3027
3028         initialTime has been removed from the HTMLMediaElement.
3029
3030         * bindings/gobject/WebKitDOMCustom.cpp:
3031         (webkit_dom_html_media_element_get_initial_time):
3032         * bindings/gobject/WebKitDOMCustom.h:
3033         * bindings/gobject/WebKitDOMCustom.symbols: Added phony function.
3034         * html/HTMLMediaElement.cpp:
3035         * html/HTMLMediaElement.h:
3036         * html/HTMLMediaElement.idl: Removed HTMLMediaElement::initialTime.
3037
3038 2013-11-02  Alexey Proskuryakov  <ap@apple.com>
3039
3040         Implement generateKey for HMAC and AES-CBC
3041         https://bugs.webkit.org/show_bug.cgi?id=123669
3042
3043         Reviewed by Dan Bernstein.
3044
3045         Tests: crypto/subtle/aes-cbc-generate-key.html
3046                crypto/subtle/hmac-generate-key.html
3047
3048         * WebCore.xcodeproj/project.pbxproj: Added new files.
3049
3050         * bindings/js/JSCryptoAlgorithmDictionary.cpp:
3051         (WebCore::createAesKeyGenParams): Added bindings for AesKeyGenParams.
3052         (WebCore::JSCryptoAlgorithmDictionary::createParametersForGenerateKey): Handle
3053         algorithms that generate AES and HMAC keys.
3054
3055         * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::JSSubtleCrypto::generateKey): Added.
3056
3057         * crypto/CryptoAlgorithmAesKeyGenParams.h: Added.
3058
3059         * crypto/CryptoKey.cpp: (WebCore::CryptoKey::randomData):
3060         * crypto/CryptoKey.h:
3061         * crypto/CryptoKeyMac.cpp: Added
3062         Expose a function that produces random data for symmetric crypto keys. Cross-platform
3063         implementation uses ARC4 code from WTF, while Mac uses a system function that
3064         provides a FIPS validated random number generator.
3065
3066         * crypto/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::generate):
3067         * crypto/CryptoKeyAES.h:
3068         Added a function that creates AES keys.
3069
3070         * crypto/SubtleCrypto.idl: Added generateKey.
3071
3072         * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp:
3073         (WebCore::CryptoAlgorithmAES_CBC::generateKey): Added.
3074
3075         * crypto/algorithms/CryptoAlgorithmHMAC.cpp:
3076         (WebCore::CryptoAlgorithmHMAC::generateKey): Added.
3077
3078         * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::generate):
3079         * crypto/keys/CryptoKeyHMAC.h:
3080         Added a function that creates HMAC keys.
3081
3082         * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp: Removed generateKey stub, the implementation
3083         ended up in cross-platform file.
3084
3085         * crypto/mac/CryptoAlgorithmHMACMac.cpp: Ditto.
3086
3087 2013-11-02  Christophe Dumez  <ch.dumez@samsung.com>
3088
3089         EnforceRange doesn't enforce range of a short
3090         https://bugs.webkit.org/show_bug.cgi?id=123661
3091
3092         Reviewed by Alexey Proskuryakov.
3093
3094         Handle Web IDL short / unsigned short types as per the
3095         specification:
3096         - http://www.w3.org/TR/WebIDL/#es-short
3097         - http://www.w3.org/TR/WebIDL/#es-unsigned-short
3098
3099         Specifically, we used to treat short / unsigned short as 32bit
3100         integers, which was wrong. We now properly handle them as 16bit
3101         integers.
3102
3103         No new tests, added test cases to js/dom/webidl-type-mapping.html.
3104
3105         * WebCore.exp.in:
3106         * bindings/js/JSDOMBinding.cpp:
3107         (WebCore::toSmallerInt):
3108         (WebCore::toSmallerUInt):
3109         (WebCore::toInt8):
3110         (WebCore::toUInt8):
3111         (WebCore::toInt16):
3112         (WebCore::toUInt16):
3113         * bindings/js/JSDOMBinding.h:
3114         * bindings/scripts/CodeGeneratorJS.pm:
3115         (JSValueToNative):
3116         * bindings/scripts/test/JS/JSTestObj.cpp:
3117         (WebCore::setJSTestObjShortAttr):
3118         (WebCore::setJSTestObjUnsignedShortAttr):
3119         * testing/TypeConversions.h:
3120         (WebCore::TypeConversions::testShort):
3121         (WebCore::TypeConversions::setTestShort):
3122         (WebCore::TypeConversions::testEnforceRangeShort):
3123         (WebCore::TypeConversions::setTestEnforceRangeShort):
3124         (WebCore::TypeConversions::testUnsignedShort):
3125         (WebCore::TypeConversions::setTestUnsignedShort):
3126         (WebCore::TypeConversions::testEnforceRangeUnsignedShort):
3127         (WebCore::TypeConversions::setTestEnforceRangeUnsignedShort):
3128         * testing/TypeConversions.idl:
3129
3130 2013-11-02  Patrick Gansterer  <paroga@webkit.org>
3131
3132         Cleanup OpenTypeUtilities
3133         https://bugs.webkit.org/show_bug.cgi?id=123686
3134
3135         Reviewed by Darin Adler.
3136
3137         Merge the WinCE specific code into the general Windows code to
3138         make the compilation of WinCE port on WinNT easier.
3139
3140         * platform/graphics/opentype/OpenTypeUtilities.cpp:
3141         (WebCore::renameFont):
3142         (WebCore::renameAndActivateFont):
3143         * platform/graphics/opentype/OpenTypeUtilities.h:
3144         * platform/graphics/win/FontCustomPlatformData.cpp:
3145         (WebCore::createFontCustomPlatformData):
3146         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
3147         (WebCore::createFontCustomPlatformData):
3148         * platform/graphics/wince/FontCustomPlatformData.cpp:
3149         (WebCore::createFontCustomPlatformData):
3150
3151 2013-11-02  Andreas Kling  <akling@apple.com>
3152
3153         CSSFontFaceSrcValue constructors should return PassRef.
3154         <https://webkit.org/b/123692>
3155
3156         Make functions that return non-null CSSFontFaceSrcValues return
3157         PassRef instead of PassRefPtr. Tweak some call sites to be
3158         slightly more efficient.
3159
3160         Reviewed by Anders Carlsson.
3161
3162 2013-11-02  Andreas Kling  <akling@apple.com>
3163
3164         CSSStyleSheet::contents() should return a reference.
3165         <https://webkit.org/b/123689>
3166
3167         Make CSSStyleSheet::contents() return a StyleSheetContents& instead
3168         of a pointer. The object was already stored in a Ref.
3169
3170         Reviewed by Anders Carlsson.
3171
3172 2013-11-02  Andreas Kling  <akling@apple.com>
3173
3174         CSSReflectValue constructor should return PassRef.
3175         <https://webkit.org/b/123963>
3176
3177         Make CSSReflectValue::create() return a PassRef. Tweak one call
3178         site to be slightly more efficient.
3179
3180         Reviewed by Anders Carlsson.
3181
3182 2013-11-02  Andreas Kling  <akling@apple.com>
3183
3184         CSSFontFeatureValue constructor should return PassRef.
3185         <https://webkit.org/b/123691>
3186
3187         Make CSSFontFeatureValue::create() return PassRef, since it never
3188         returns null. Tweak one call site to be slightly more efficient.
3189
3190         Reviewed by Anders Carlsson.
3191
3192 2013-11-02  Andreas Kling  <akling@apple.com>
3193
3194         Tighten typing in SVGResources::buildCachedResources().
3195         <https://webkit.org/b/123690>
3196
3197         Make this function take a RenderElement&/SVGRenderStyle& pair instead
3198         of a RenderObject*/SVGRenderStyle* pair. Also tweaked the code a bit,
3199         removing ampersands and asserts as appropriate.
3200
3201         Reviewed by Anders Carlsson.
3202
3203 2013-11-02  Andreas Kling  <akling@apple.com>
3204
3205         CSSImageValue constructors should return PassRef.
3206         <https://webkit.org/b/123688>
3207
3208         Make the CSSImageValue::create() helpers return PassRef.
3209         Tightened call sites to avoid null checks and destructor calls.
3210
3211         Reviewed by Anders Carlsson.
3212
3213 2013-11-02  Patrick Gansterer  <paroga@webkit.org>
3214
3215         Fix compilation of SynchronousLoaderClient
3216         https://bugs.webkit.org/show_bug.cgi?id=123676
3217
3218         Reviewed by Darin Adler.
3219
3220         Assign a ResourceRequest varibale an empty ResourceRequest instead of 0.
3221         The current solution only works for ports which can create a
3222         ResourceRequest from a pointer, which might not be true for all ports.
3223
3224         * platform/network/SynchronousLoaderClient.cpp:
3225         (WebCore::SynchronousLoaderClient::willSendRequest):
3226
3227 2013-11-02  Patrick Gansterer  <paroga@webkit.org>
3228
3229         Port LoggingWin.cpp to WinCE
3230         https://bugs.webkit.org/show_bug.cgi?id=123678
3231
3232         Reviewed by Darin Adler.
3233
3234         This makes it easier to use a common list of files
3235         for the different Windows ports later.
3236
3237         * PlatformWin.cmake:
3238         * platform/win/LoggingWin.cpp:
3239         (WebCore::logLevelString):
3240
3241 2013-11-02  Patrick Gansterer  <paroga@webkit.org>
3242
3243         Fix UnicodeWchar after r157330.
3244         https://bugs.webkit.org/show_bug.cgi?id=123668
3245
3246         Reviewed by Darin Adler.
3247
3248         * editing/TextIterator.cpp:
3249         (WebCore::SearchBuffer::append):
3250         * platform/graphics/wince/FontWinCE.cpp:
3251         (WebCore::generateComponents):
3252         * platform/graphics/wince/GraphicsContextWinCE.cpp:
3253         (WebCore::GraphicsContext::drawText):
3254         * platform/text/wchar/TextBreakIteratorWchar.cpp:
3255         (WebCore::isCharStop):
3256         (WebCore::isLineStop):
3257         (WebCore::isSentenceStop):
3258         (WebCore::WordBreakIterator::next):
3259         (WebCore::WordBreakIterator::previous):
3260
3261 2013-11-02  Andreas Kling  <akling@apple.com>
3262
3263         Use RenderChildIterator in a couple of places.
3264         <https://webkit.org/b/123684>
3265
3266         Added isRendererOfType() for RenderBox and RenderBlock and switch
3267         some loops over to using childrenOfType<>. Also sprinkled const
3268         and references on touched code.
3269
3270         Reviewed by Antti Koivisto.
3271
3272 2013-11-02  Zan Dobersek  <zdobersek@igalia.com>
3273
3274         Manage FileReaderLoader through std::unique_ptr
3275         https://bugs.webkit.org/show_bug.cgi?id=123666
3276
3277         Reviewed by Anders Carlsson.
3278
3279         Construct FileReaderLoader objects through std::make_unique and store them in std::unique_ptr.
3280
3281         * fileapi/FileReader.cpp:
3282         (WebCore::FileReader::readInternal):
3283         * fileapi/FileReader.h:
3284
3285 2013-11-02  Andreas Kling  <akling@apple.com>
3286
3287         Add a child renderer iterator.
3288         <https://webkit.org/b/123662>
3289
3290         Introduce an ElementIterator-style iterator for renderers and put
3291         it to use in a childrenOfType() implementation.
3292
3293         It's used just like the Element iterators:
3294
3295         auto sections = childrenOfType<RenderTableSection>(*this);
3296         for (auto section = sections.begin(), section = sections.end(); section != sections.end(); ++section)
3297             section->thisOrThat();
3298
3299         Just like the DOM counterpart, it relies on a templatized helper:
3300
3301             bool isRendererOfType<T>(const RenderObject&)
3302
3303         This patch puts the iterator to use in a couple of random places.
3304
3305         Reviewed by Antti Koivisto.
3306
3307 2013-11-02  Alexey Proskuryakov  <ap@apple.com>
3308
3309         Implement remaining SHA variations for WebCrypto
3310         https://bugs.webkit.org/show_bug.cgi?id=123659
3311
3312         Reviewed by Anders Carlsson.
3313
3314         Tests: crypto/subtle/sha-224.html
3315                crypto/subtle/sha-256.html
3316                crypto/subtle/sha-384.html
3317                crypto/subtle/sha-512.html
3318
3319         * WebCore.xcodeproj/project.pbxproj:
3320         * crypto/algorithms/CryptoAlgorithmSHA224.cpp: Added.
3321         (WebCore::CryptoAlgorithmSHA224::CryptoAlgorithmSHA224):
3322         (WebCore::CryptoAlgorithmSHA224::~CryptoAlgorithmSHA224):
3323         (WebCore::CryptoAlgorithmSHA224::create):
3324         (WebCore::CryptoAlgorithmSHA224::identifier):
3325         * crypto/algorithms/CryptoAlgorithmSHA224.h: Added.
3326         * crypto/algorithms/CryptoAlgorithmSHA256.cpp: Added.
3327         (WebCore::CryptoAlgorithmSHA256::CryptoAlgorithmSHA256):
3328         (WebCore::CryptoAlgorithmSHA256::~CryptoAlgorithmSHA256):
3329         (WebCore::CryptoAlgorithmSHA256::create):
3330         (WebCore::CryptoAlgorithmSHA256::identifier):
3331         * crypto/algorithms/CryptoAlgorithmSHA256.h: Added.
3332         * crypto/algorithms/CryptoAlgorithmSHA384.cpp: Added.
3333         (WebCore::CryptoAlgorithmSHA384::CryptoAlgorithmSHA384):
3334         (WebCore::CryptoAlgorithmSHA384::~CryptoAlgorithmSHA384):
3335         (WebCore::CryptoAlgorithmSHA384::create):
3336         (WebCore::CryptoAlgorithmSHA384::identifier):
3337         * crypto/algorithms/CryptoAlgorithmSHA384.h: Added.
3338         * crypto/algorithms/CryptoAlgorithmSHA512.cpp: Added.
3339         (WebCore::CryptoAlgorithmSHA512::CryptoAlgorithmSHA512):
3340         (WebCore::CryptoAlgorithmSHA512::~CryptoAlgorithmSHA512):
3341         (WebCore::CryptoAlgorithmSHA512::create):
3342         (WebCore::CryptoAlgorithmSHA512::identifier):
3343         * crypto/algorithms/CryptoAlgorithmSHA512.h: Added.
3344         * crypto/mac/CryptoAlgorithmRegistryMac.cpp:
3345         (WebCore::CryptoAlgorithmRegistry::platformRegisterAlgorithms):
3346         * crypto/mac/CryptoAlgorithmSHA224Mac.cpp: Added.
3347         (WebCore::CryptoAlgorithmSHA224::digest):
3348         * crypto/mac/CryptoAlgorithmSHA256Mac.cpp: Added.
3349         (WebCore::CryptoAlgorithmSHA256::digest):
3350         * crypto/mac/CryptoAlgorithmSHA384Mac.cpp: Added.
3351         (WebCore::CryptoAlgorithmSHA384::digest):
3352         * crypto/mac/CryptoAlgorithmSHA512Mac.cpp: Added.
3353         (WebCore::CryptoAlgorithmSHA512::digest):
3354
3355 2013-11-02  Patrick Gansterer  <paroga@webkit.org>
3356
3357         Various small WinCE build fixes
3358
3359         * editing/TextIterator.cpp:
3360         (WebCore::SearchBuffer::append):
3361         * platform/graphics/BitmapImage.h:
3362         * platform/graphics/wince/ImageWinCE.cpp:
3363         (WebCore::BitmapImage::getHBITMAPOfSize):
3364         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
3365         * platform/graphics/wince/PlatformPathWinCE.h:
3366         * platform/win/PopupMenuWin.h:
3367         * rendering/RenderThemeWinCE.cpp:
3368         (WebCore::RenderThemeWinCE::adjustMenuListButtonStyle):
3369
3370 2013-11-01  Alexey Proskuryakov  <ap@apple.com>
3371
3372         Add WebCrypto AES-CBC
3373         https://bugs.webkit.org/show_bug.cgi?id=123647
3374
3375         Reviewed by Anders Carlsson.
3376
3377         Tests: crypto/subtle/aes-cbc-192-encrypt-decrypt.html
3378                crypto/subtle/aes-cbc-256-encrypt-decrypt.html
3379                crypto/subtle/aes-cbc-encrypt-decrypt-with-padding.html
3380                crypto/subtle/aes-cbc-encrypt-decrypt.html
3381                crypto/subtle/aes-cbc-invalid-length.html
3382                crypto/subtle/aes-cbc-wrong-key-class.html
3383
3384         * WebCore.xcodeproj/project.pbxproj: Added new files.
3385         * bindings/js/JSCryptoAlgorithmDictionary.cpp:
3386         (WebCore::getProperty): Factored out a function to get a property as JSValue.
3387         (WebCore::getHashAlgorithm): Use it.
3388         (WebCore::createAesCbcParams): Added converter for AesCbcParams.
3389         (WebCore::JSCryptoAlgorithmDictionary::createParametersForEncrypt): Support AES_CBC.
3390         (WebCore::JSCryptoAlgorithmDictionary::createParametersForDecrypt): Ditto.
3391         (WebCore::JSCryptoAlgorithmDictionary::createParametersForImportKey): Support all
3392         algorithms, all the new ones just have trivial dictionaries.
3393         (WebCore::JSCryptoAlgorithmDictionary::createParametersForExportKey): Ditto.
3394
3395         * bindings/js/JSCryptoOperationData.cpp: Added.
3396         (WebCore::sequenceOfCryptoOperationDataFromJSValue):
3397         (WebCore::cryptoOperationDataFromJSValue):
3398         * bindings/js/JSCryptoOperationData.h: Added.
3399         Moved CryptoOperationData bindings out of JSSubtleCryptoCustom.cpp, so that we
3400         could use them in JSCryptoAlgorithmDictionary.cpp.
3401
3402         * bindings/js/JSDOMPromise.h: (WebCore::PromiseWrapper::reject): Added a specialization
3403         to reject with null result. The spec doesn't actually say how algorithms fail.
3404
3405         * bindings/js/JSSubtleCryptoCustom.cpp:
3406         (WebCore::JSSubtleCrypto::encrypt): Added.
3407         (WebCore::JSSubtleCrypto::decrypt): Ditto.
3408         (WebCore::JSSubtleCrypto::sign): Style fix.
3409
3410         * crypto/CryptoAlgorithmAesCbcParams.h: Added.
3411
3412         * crypto/CryptoKey.h:
3413         (WebCore::CryptoKeyClass):
3414         * crypto/keys/CryptoKeyHMAC.h:
3415         (WebCore::asCryptoKeyHMAC):
3416         Added poor man's RTTI, so that we can safely upcast Keys passed fro JavaScript code.
3417
3418         * crypto/CryptoKeyAES.cpp: Added.
3419         (WebCore::CryptoKeyAES::CryptoKeyAES):
3420         (WebCore::CryptoKeyAES::~CryptoKeyAES):
3421         (WebCore::CryptoKeyAES::buildAlgorithmDescription):
3422         * crypto/CryptoKeyAES.h: Added.
3423         (WebCore::asCryptoKeyAES):
3424         AES keys are the same for all algorithms, but they still need to remember the algorithm.
3425
3426         * crypto/SubtleCrypto.idl: Added encrypt/decrypt.
3427
3428         * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: Added.
3429         (WebCore::CryptoAlgorithmAES_CBC::CryptoAlgorithmAES_CBC):
3430         (WebCore::CryptoAlgorithmAES_CBC::~CryptoAlgorithmAES_CBC):
3431         (WebCore::CryptoAlgorithmAES_CBC::create):
3432         (WebCore::CryptoAlgorithmAES_CBC::identifier):
3433         (WebCore::CryptoAlgorithmAES_CBC::importKey):
3434         (WebCore::CryptoAlgorithmAES_CBC::exportKey):
3435         * crypto/algorithms/CryptoAlgorithmAES_CBC.h: Added.
3436         * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp: Added.
3437         (WebCore::transformAES_CBC):
3438         (WebCore::CryptoAlgorithmAES_CBC::encrypt):
3439         (WebCore::CryptoAlgorithmAES_CBC::decrypt):
3440         (WebCore::CryptoAlgorithmAES_CBC::generateKey):
3441         Added.
3442
3443         * crypto/mac/CryptoAlgorithmHMACMac.cpp:
3444         (WebCore::CryptoAlgorithmHMAC::sign):
3445         (WebCore::CryptoAlgorithmHMAC::verify):
3446         Check key class before casting it to CryptoKeyHMAC.
3447
3448         * crypto/mac/CryptoAlgorithmRegistryMac.cpp:
3449         (WebCore::CryptoAlgorithmRegistry::platformRegisterAlgorithms): Register AES-CBC
3450         on Mac, so that it can be used.
3451
3452 2013-11-01  Andreas Kling  <akling@apple.com>
3453
3454         SVGRenderStyle accessors should return references.
3455         <https://webkit.org/b/123656>
3456
3457         RenderStyle::svgStyle() and accessSVGStyle() never return null,
3458         so make them return references instead.
3459         
3460         This flushed out a myriad of pointless null checks and assertions.
3461
3462         Reviewed by Anders Carlsson.
3463
3464 2013-11-01  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3465
3466         Removing MediaStreamTrackVector and MediaStreamSourceVector typedefs
3467         https://bugs.webkit.org/show_bug.cgi?id=123648
3468
3469         Reviewed by Eric Carlson.
3470
3471         No new tests needed.
3472
3473         * Modules/mediastream/MediaStream.cpp:
3474         (WebCore::MediaStream::create):
3475         (WebCore::MediaStream::clone):
3476         (WebCore::MediaStream::cloneMediaStreamTrackVector):
3477         (WebCore::MediaStream::addTrack):
3478         (WebCore::MediaStream::removeTrack):
3479         (WebCore::MediaStream::haveTrackWithSource):
3480         (WebCore::MediaStream::getTrackById):
3481         (WebCore::MediaStream::trackVectorForType):
3482         * Modules/mediastream/MediaStream.h:
3483         * Modules/mediastream/MediaStreamTrack.h:
3484         * Modules/mediastream/UserMediaRequest.cpp:
3485         (WebCore::UserMediaRequest::callSuccessHandler):
3486         * Modules/webaudio/AudioContext.cpp:
3487         (WebCore::AudioContext::createMediaStreamSource):
3488         * Modules/webaudio/MediaStreamAudioDestinationNode.cpp:
3489         (WebCore::MediaStreamAudioDestinationNode::MediaStreamAudioDestinationNode):
3490         * platform/mediastream/MediaStreamDescriptor.cpp:
3491         (WebCore::MediaStreamDescriptor::create):
3492         (WebCore::MediaStreamDescriptor::MediaStreamDescriptor):
3493         * platform/mediastream/MediaStreamDescriptor.h:
3494         * platform/mediastream/MediaStreamSource.h:
3495
3496 2013-11-01  Andreas Kling  <akling@apple.com>
3497
3498         createFontFaceValue() should be smarter about overgrown cache.
3499         <https://webkit.org/b/123643>
3500
3501         Instead of clearing the whole font-face value cache when it passes
3502         128 entries, just delete one entry at random.
3503
3504         Reviewed by Geoffrey Garen.
3505
3506 2013-11-01  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3507
3508         Fixing mac code to use new MediaStreamDescriptor create method
3509         https://bugs.webkit.org/show_bug.cgi?id=123653
3510
3511         Reviewed by Eric Carlson.
3512
3513         No new tests needed.
3514
3515         * platform/mediastream/mac/MediaStreamCenterMac.cpp:
3516         (WebCore::MediaStreamCenterMac::createMediaStream):
3517
3518 2013-11-01  Andreas Kling  <akling@apple.com>
3519
3520         Re-use existing RenderStyle local in textWidth().
3521         <https://webkit.org/b/123392>
3522
3523         We already have the RenderStyle cached in a local here, so avoid
3524         getting it from RenderText since that has to go via the parent.
3525
3526         Reviewed by Antti Koivisto.
3527
3528 2013-11-01  Andreas Kling  <akling@apple.com>
3529
3530         Neuter WTF_MAKE_FAST_ALLOCATED in GLOBAL_FASTMALLOC_NEW builds.
3531         <https://webkit.org/b/123639>
3532
3533         WebCore::TimerBase really needed to have the new/delete operators
3534         overridden, in order for WebCore::SuspendableTimer to be able to
3535         choose that "operator new" out of the two it inherits.
3536
3537         Reviewed by Anders Carlsson.
3538
3539 2013-11-01  Andreas Kling  <akling@apple.com>
3540
3541         CSSCanvasValue construction helper should return PassRef.
3542         <https://webkit.org/b/123650>
3543
3544         Return PassRef instead of PassRefPtr from functions that return
3545         ownership-passing pointers that are known to be non-null.
3546
3547         Reviewed by Anders Carlsson.
3548
3549 2013-11-01  Joseph Pecoraro  <pecoraro@apple.com>
3550
3551         Move CF/Mac WTF String implementations down into WTF
3552         https://bugs.webkit.org/show_bug.cgi?id=123635
3553
3554         Reviewed by Sam Weinig.
3555
3556         * WebCore.vcxproj/WebCore.vcxproj:
3557         * WebCore.vcxproj/WebCore.vcxproj.filters:
3558         * WebCore.xcodeproj/project.pbxproj:
3559
3560 2013-11-01  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3561
3562         Removing unnecessary early returns in addTrack, removeTrack and removeRemoteSource methods
3563         https://bugs.webkit.org/show_bug.cgi?id=123644
3564
3565         Reviewed by Eric Carlson.
3566
3567         No new tests needed.
3568
3569         * Modules/mediastream/MediaStream.cpp:
3570         (WebCore::MediaStream::addTrack):
3571         (WebCore::MediaStream::removeTrack):
3572         (WebCore::MediaStream::removeRemoteSource):
3573         (WebCore::MediaStream::trackVectorForType):
3574         * Modules/mediastream/MediaStream.h:
3575
3576 2013-11-01  Andreas Kling  <akling@apple.com>
3577
3578         CSSAspectRatioValue construction helper should return PassRef.
3579         <https://webkit.org/b/123645>
3580
3581         Return PassRef instead of PassRefPtr from functions that return
3582         ownership-passing pointers that are known to be non-null.
3583
3584         Reviewed by Darin Adler.
3585
3586 2013-11-01  Myles C. Maxfield  <mmaxfield@apple.com>
3587
3588         Initial implementation of text-decoration-skip ink
3589         https://bugs.webkit.org/show_bug.cgi?id=121806
3590
3591         Reviewed by Darin Adler.
3592
3593         text-decoration-skip: ink is implemented by the following steps:
3594         1. Before drawing any decorations, figure out the bounding box for the decorations that will be drawn
3595         2. Create an ImageBuffer with these dimensions
3596         3. Draw text into this ImageBuffer with a thicker stroke
3597         4. Apply the ImageBuffer as a mask to the context
3598         5. Draw decorations like normal
3599         6. Clean up
3600
3601         Test: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-ink.html
3602
3603         * platform/graphics/cg/GraphicsContextCG.cpp:
3604         (WebCore::computeLineBoundsAndAntialiasingModeForText): Don't call GraphicsContext::roundToDevicePixels
3605         when painting is disabled
3606         * rendering/InlineTextBox.cpp:
3607         (WebCore::InlineTextBox::paint): Pass the TextPainter to paintDecoration
3608         (WebCore::computeUnderlineOffset): Small cleanup
3609         (WebCore::getWavyStrokeControlPointDistance): Pulling out of strokeWavyTextDecoration()
3610         (WebCore::getWavyStrokeStep): Ditto
3611         (WebCore::strokeWavyTextDecoration): Use the previous 2 functions
3612         (WebCore::getSingleDecorationBoundingBox): Pulling out repeated code into a function
3613         (WebCore::getDecorationBoundingBox): Compute the bounding box for an underline which
3614         hasn't been drawn yet
3615         (WebCore::InlineTextBox::paintDecoration): Construct a mask and apply it to the GraphicsContext
3616         * rendering/InlineTextBox.h: paintDecoration needs the TextPainter
3617         * rendering/style/RenderStyle.cpp:
3618         (WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline): Redraw the underline when
3619         text-decoration-skip changes
3620
3621 2013-11-01  Andreas Kling  <akling@apple.com>
3622
3623         CSS 'initial' and 'inherit' value constructors should return PassRef.
3624         <https://webkit.org/b/123641>
3625
3626         Make the helpers involved in constructing CSS{Initial,Inherited}Value
3627         all return PassRef instead of PassRefPtr. This avoids generating
3628         pointless null checks at the call sites.
3629
3630         Reviewed by Darin Adler.
3631
3632 2013-11-01  Andreas Kling  <akling@apple.com>
3633
3634         Kill RenderArena.
3635         <https://webkit.org/b/123634>
3636
3637         There are no remaining users of the RenderArena allocator.
3638
3639         Reviewed by Geoffrey Garen.
3640
3641 2013-11-01  James Craig  <jcraig@apple.com>
3642
3643         AX: Regression: media controls are no longer accessible
3644         https://bugs.webkit.org/show_bug.cgi?id=121990
3645
3646         Reviewed by Jer Noble.
3647
3648         Updated existing test coverage.
3649         Added ARIA roles, attrs, and labels to the new media controls shadow DOM.
3650         Localization will be handled in http://webkit.org/b/120956
3651
3652         * Modules/mediacontrols/mediaControlsApple.js:
3653         (Controller.prototype.UIString):
3654         (Controller.prototype.createControls):
3655         (Controller.prototype.handleLoadStart):
3656         (Controller.prototype.handleError):
3657         (Controller.prototype.handleAbort):
3658         (Controller.prototype.handleSuspend):
3659         (Controller.prototype.handleStalled):
3660         (Controller.prototype.handleWaiting):
3661         (Controller.prototype.handleFullscreenChange):
3662         (Controller.prototype.handleMuteButtonClicked):
3663         (Controller.prototype.handleMinButtonClicked):
3664         (Controller.prototype.handleMaxButtonClicked):
3665         (Controller.prototype.handleVolumeSliderChange):
3666         (Controller.prototype.updatePlaying):
3667
3668 2013-11-01  Andreas Kling  <akling@apple.com>
3669
3670         Take BidiRuns out of the arena.
3671         <https://webkit.org/b/123630>
3672
3673         Stop arena-allocating BidiRun objects and use regular new/delete.
3674
3675         With this, there are no remaining clients of RenderArena.
3676         It will be removed in a subsequent patch.
3677
3678         Reviewed by Anders Carlsson.
3679
3680 2013-11-01  Afonso R. Costa Jr.  <afonso.costa@samsung.com>
3681
3682         Expose setApplicationCacheOriginQuota via window.internals
3683         https://bugs.webkit.org/show_bug.cgi?id=87838
3684
3685         Reviewed by Joseph Pecoraro.
3686
3687         Also reset the default origin quota in resetToConsistentState().
3688
3689         * testing/Internals.cpp: Add setApplicationCacheOriginQuota.
3690         (WebCore::Internals::resetToConsistentState): Reset the default origin
3691         quota.
3692         (WebCore::Internals::setApplicationCacheOriginQuota): Added.
3693         * testing/Internals.h: Add setApplicationCacheOriginQuota.
3694         * testing/Internals.idl: Ditto.
3695
3696 2013-11-01  Nick Diego Yamane  <nick.yamane@openbossa.org>
3697
3698         Explicitly initialize RefCounted base class in MediaStreamTrack's constructors
3699         https://bugs.webkit.org/show_bug.cgi?id=123620
3700
3701         Reviewed by Andreas Kling.
3702
3703         No new tests needed.
3704
3705         * Modules/mediastream/MediaStreamTrack.cpp:
3706         (WebCore::MediaStreamTrack::MediaStreamTrack):
3707
3708 2013-11-01  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3709
3710         Adding addRemoteTrack and removeRemoteTrack functions to MediaStreamDescriptor and MediaStream
3711         https://bugs.webkit.org/show_bug.cgi?id=123477
3712
3713         Reviewed by Eric Carlson.
3714
3715         When the backend report that a remote track has been added or removed by a remote peer, we must be able to add
3716         it to its MediaStream
3717
3718         No new tests needed.
3719
3720         * Modules/mediastream/MediaStream.cpp:
3721         (WebCore::MediaStream::addTrack): Splitted in two parts that can be used by old addTrack and new addRemoteTrack.
3722         (WebCore::MediaStream::removeTrack): Splitted in two parts that can be used by old removeTrack and new
3723         removeRemoteTrack.
3724         (WebCore::MediaStream::addRemoteSource): Reusing code in new addTrack method.
3725         (WebCore::MediaStream::removeRemoteSource): Refactored.
3726         (WebCore::MediaStream::addRemoteTrack): Added.
3727         (WebCore::MediaStream::removeRemoteTrack): Added.
3728         (WebCore::MediaStream::getTrackVectorForType): Helper method that returns a vector of tracks according to
3729         track's type (Audio or Video).
3730
3731         * Modules/mediastream/MediaStream.h:
3732         * Modules/mediastream/MediaStreamTrack.cpp:
3733         (WebCore::MediaStreamTrack::MediaStreamTrack):
3734         * platform/mediastream/MediaStreamDescriptor.cpp:
3735         (WebCore::MediaStreamDescriptor::addRemoteTrack): Added.
3736         (WebCore::MediaStreamDescriptor::removeRemoteTrack): Added.
3737         * platform/mediastream/MediaStreamDescriptor.h:
3738
3739 2013-11-01  Brendan Long  <b.long@cablelabs.com>
3740
3741         [GStreamer] Support audio and video tracks
3742         https://bugs.webkit.org/show_bug.cgi?id=117039
3743
3744         Reviewed by Philippe Normand.
3745
3746         Tests: media/track/audio/audio-track-mkv-vorbis-addtrack.html
3747                media/track/audio/audio-track-mkv-vorbis-enabled.html
3748                media/track/audio/audio-track-mkv-vorbis-language.html
3749                media/track/in-band/track-in-band-kate-ogg-addtrack.html
3750                media/track/in-band/track-in-band-srt-mkv-addtrack.html
3751                media/track/video/video-track-mkv-theora-addtrack.html
3752                media/track/video/video-track-mkv-theora-language.html
3753                media/track/video/video-track-mkv-theora-selected.html
3754
3755         * GNUmakefile.list.am: Add audio and video track files.
3756         * PlatformEfl.cmake: Same.
3757         * html/HTMLMediaElement.cpp:
3758         (WebCore::HTMLMediaElement::audioTrackEnabledChanged): Schedule "change" event.
3759         (WebCore::HTMLMediaElement::videoTrackSelectedChanged): Same.
3760         * html/track/AudioTrack.cpp:
3761         (WebCore::AudioTrack::setEnabled): Call m_private->setEnabled
3762         (WebCore::AudioTrack::enabledChanged): Added callback.
3763         (WebCore::AudioTrack::labelChanged): Same.
3764         (WebCore::AudioTrack::languageChanged): Same.
3765         (WebCore::AudioTrack::willRemoveAudioTrackPrivate): Use ASSERT_UNUSED for consistence.
3766         * html/track/AudioTrack.h: Add new enabled, label and language callbacks.
3767         * html/track/VideoTrack.cpp:
3768         (WebCore::VideoTrack::setSelected): Call m_private->setEnabled
3769         (WebCore::VideoTrack::selectedChanged): Added callback.
3770         (WebCore::VideoTrack::labelChanged): Same.
3771         (WebCore::VideoTrack::languageChanged): Same.
3772         (WebCore::VideoTrack::willRemoveVideoTrackPrivate): Use ASSERT_UNUSED for consistence.
3773         * html/track/VideoTrack.h: Add new selected, label and language callbacks.
3774         * platform/graphics/AudioTrackPrivate.h:
3775         (WebCore::AudioTrackPrivate::setEnabled): Call m_client->enabledChanged
3776         * platform/graphics/VideoTrackPrivate.h:
3777         (WebCore::VideoTrackPrivate::setSelected): Call m_client->selectedChanged
3778         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
3779         (WebCore::InbandTextTrackPrivateGStreamer::InbandTextTrackPrivateGStreamer): Add ASSERT(m_pad)
3780         (WebCore::InbandTextTrackPrivateGStreamer::notifyTrackOfTagsChanged): Look at all tag events instead of just the first one.
3781         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3782         (WebCore::mediaPlayerPrivateVideoSinkCapsChangedCallback): Separated callback when caps change from callback when number of videos change.
3783         (WebCore::mediaPlayerPrivateVideoCapsChangeTimeoutCallback): Same.
3784         (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer): Initialize m_videoCapsTimerHandler.
3785         (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer): Disconnect audio and video tracks and remove callbacks.
3786         (WebCore::MediaPlayerPrivateGStreamer::videoCapsChanged): Separated callback when caps change from callback when number of videos change.
3787         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo): Create video tracks for each stream.
3788         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideoCaps): Separated callback when caps change from callback when number of videos change.
3789         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio): Create audio tracks for each stream.
3790         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h: Add audio and video tracks, and a pointer to keep track of the default audio stream.
3791         * platform/graphics/gstreamer/AudioTrackPrivateGStreamer.cpp: Added.
3792         * platform/graphics/gstreamer/AudioTrackPrivateGStreamer.h: Added.
3793         * platform/graphics/gstreamer/GRefPtrGStreamer.cpp: Add GRefPtr<GstTagList>
3794         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp: Added, handles tags and "active" property of audio and video tracks.
3795         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h: Added.
3796         * platform/graphics/gstreamer/VideoTrackPrivateGStreamer.cpp: Added.
3797         * platform/graphics/gstreamer/VideoTrackPrivateGStreamer.h: Added.
3798
3799 2013-11-01  Patrick Gansterer  <paroga@webkit.org>
3800
3801         Buildfix for !ENABLE(INSPECTOR) after 157288.
3802
3803         * inspector/InspectorInstrumentation.h:
3804         (WebCore::InspectorInstrumentation::willDispatchEvent):
3805
3806 2013-11-01  Mario Sanchez Prada  <mario.prada@samsung.com>
3807
3808         [ATK] Avoid explicit traversal of text controls and the render tree in AtkText implementation
3809         https://bugs.webkit.org/show_bug.cgi?id=123153
3810
3811         Reviewed by Chris Fleizach.
3812
3813         Remove functions from the AtkText implementation that manually
3814         walk the render tree to compose the text for a exposed objects in
3815         certain cases (e.g. anonymous blocks, text controls).
3816
3817         The reason for this change is that the current implementation
3818         follows an error-prone approach, since by doing things like
3819         manually walking the render tree from here we are not properly
3820         considering all the possible scenarios that might happen when
3821         traversing text. This, however, is a task that is better suited
3822         for the TextIterator, which is already written to consider all
3823         those cases and to emit the proper character in every single
3824         situation: text nodes, replaced objects and so on.
3825
3826         So, by removing all that too specific code (textForObject() and
3827         textForRenderer() mainly) from WebKitAccessibleInterfaceText.cpp
3828         and relying in AccessibilityObject::textUnderElement(), which it
3829         ends up using the TextIterator for certain cases, we have a much
3830         better and robust method of retrieving the text associated with an
3831         instance of AtkObject implementing the AtkText interface.
3832
3833         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
3834         (webkitAccessibleTextGetText): Removed call to textForObject(), now that
3835         we have just removed that function, together with textForRenderer().
3836
3837         Make AccessibilityRenderObject::textUnderElement() able to deal with
3838         anonymous blocks directly, by creating a range based in the boundaries
3839         defined by the first and last child renderers for that block. This will
3840         make possible to treat an anonymous block as a whole instead of having
3841         to rely in the concatenation of each of its children, as it does now.
3842
3843         * accessibility/AccessibilityRenderObject.cpp:
3844         (WebCore::AccessibilityRenderObject::textUnderElement): Added a new code
3845         path to deal with anonymous blocks for text renderers, or when including
3846         all the children is explicitly requested.
3847
3848         Modified TextIterator so text for children of replaced objects are
3849         ignored if we are emmiting the special character for those objects.
3850
3851         * editing/TextIterator.cpp:
3852         (WebCore::TextIterator::handleReplacedElement): Make sure no children are
3853         handled a replaced object if m_emitsObjectReplacementCharacters is set.
3854         * editing/TextIterator.h: Updated m_emitsObjectReplacementCharacters
3855         description to reflect the new behavior.
3856
3857 2013-11-01  Alexey Proskuryakov  <ap@apple.com>
3858
3859         Add a Mac WebCrypto implementation of HMAC importKey/sign/verify
3860         https://bugs.webkit.org/show_bug.cgi?id=123598
3861
3862         Reviewed by Anders Carlsson.
3863
3864         Test: crypto/subtle/hmac-sign-verify.html
3865
3866         * WebCore.xcodeproj/project.pbxproj:
3867         * bindings/js/JSSubtleCryptoCustom.cpp: Added property svn:eol-style.
3868         (WebCore::createAlgorithmFromJSValue):
3869         (WebCore::cryptoOperationDataFromJSValue):
3870         (WebCore::cryptoKeyFormatFromJSValue):
3871         (WebCore::cryptoKeyUsagesFromJSValue):
3872         (WebCore::JSSubtleCrypto::sign):
3873         (WebCore::JSSubtleCrypto::verify):
3874         (WebCore::JSSubtleCrypto::digest):
3875         (WebCore::JSSubtleCrypto::importKey):
3876         * crypto/SubtleCrypto.idl:
3877         * crypto/algorithms/CryptoAlgorithmHMAC.cpp: Added.
3878         (WebCore::CryptoAlgorithmHMAC::CryptoAlgorithmHMAC):
3879         (WebCore::CryptoAlgorithmHMAC::~CryptoAlgorithmHMAC):
3880         (WebCore::CryptoAlgorithmHMAC::create):
3881         (WebCore::CryptoAlgorithmHMAC::identifier):
3882         (WebCore::CryptoAlgorithmHMAC::importKey):
3883         (WebCore::CryptoAlgorithmHMAC::exportKey):
3884         * crypto/algorithms/CryptoAlgorithmHMAC.h: Added.
3885         * crypto/keys: Added.
3886         * crypto/keys/CryptoKeyHMAC.cpp: Added.
3887         (WebCore::CryptoKeyHMAC::CryptoKeyHMAC):
3888         (WebCore::CryptoKeyHMAC::~CryptoKeyHMAC):
3889         (WebCore::CryptoKeyHMAC::buildAlgorithmDescription):
3890         * crypto/keys/CryptoKeyHMAC.h: Added.
3891         * crypto/mac/CryptoAlgorithmHMACMac.cpp: Added.
3892         (WebCore::getCommonCryptoAlgorithm):
3893         (WebCore::calculateSignature):
3894         (WebCore::CryptoAlgorithmHMAC::sign):
3895         (WebCore::CryptoAlgorithmHMAC::verify):
3896         (WebCore::CryptoAlgorithmHMAC::generateKey):
3897         * crypto/mac/CryptoAlgorithmRegistryMac.cpp:
3898         (WebCore::CryptoAlgorithmRegistry::platformRegisterAlgorithms):
3899
3900 2013-10-31  Joseph Pecoraro  <pecoraro@apple.com>
3901
3902         Web Inspector: Clean up a few Inspector interfaces
3903         https://bugs.webkit.org/show_bug.cgi?id=123594
3904
3905         Reviewed by Timothy Hatcher.
3906
3907         * WebCore.exp.in:
3908         * inspector/InjectedScriptHost.cpp:
3909         * inspector/InspectorBaseAgent.h:
3910         (WebCore::InspectorBaseAgentInterface::name):
3911         * inspector/InspectorConsoleAgent.cpp:
3912         * inspector/InspectorConsoleAgent.h:
3913         (WebCore::InspectorConsoleAgent::enabled):
3914         * inspector/InspectorController.cpp:
3915         (WebCore::InspectorController::profilerEnabled):
3916         * inspector/InspectorController.h:
3917         * inspector/InspectorDebuggerAgent.cpp:
3918         * inspector/InspectorDebuggerAgent.h:
3919         (WebCore::InspectorDebuggerAgent::enabled):
3920         * inspector/InspectorRuntimeAgent.h:
3921         (WebCore::InspectorRuntimeAgent::enabled):
3922
3923 2013-10-31  Tim Horton  <timothy_horton@apple.com>
3924
3925         Remote Layer Tree: Vend layer contents via IOSurfaces
3926         https://bugs.webkit.org/show_bug.cgi?id=123600
3927
3928         Reviewed by Anders Carlsson.
3929
3930         * WebCore.exp.in:
3931         Export sRGBColorSpaceRef.
3932
3933         * WebCore.xcodeproj/project.pbxproj:
3934         Expose GraphicsContextCG.h.
3935
3936 2013-10-31  Joseph Pecoraro  <pecoraro@apple.com>
3937
3938         Remove unused Page::setDebuggerForAllPages
3939         https://bugs.webkit.org/show_bug.cgi?id=123602
3940
3941         Reviewed by Timothy Hatcher.
3942
3943         * page/Page.cpp:
3944         * page/Page.h:
3945
3946 2013-10-31  Joseph Pecoraro  <pecoraro@apple.com>
3947
3948         Web Inspector: Remove InspectorState
3949         https://bugs.webkit.org/show_bug.cgi?id=123547
3950
3951         Reviewed by Timothy Hatcher.
3952
3953         * CMakeLists.txt:
3954         * GNUmakefile.list.am:
3955         * WebCore.vcxproj/WebCore.vcxproj:
3956         * WebCore.vcxproj/WebCore.vcxproj.filters:
3957         * WebCore.xcodeproj/project.pbxproj:
3958         * inspector/InspectorAgent.cpp:
3959         (WebCore::InspectorAgent::InspectorAgent):
3960         * inspector/InspectorAgent.h:
3961         (WebCore::InspectorAgent::create):
3962         * inspector/InspectorAllInOne.cpp:
3963         * inspector/InspectorApplicationCacheAgent.cpp:
3964         (WebCore::InspectorApplicationCacheAgent::InspectorApplicationCacheAgent):
3965         * inspector/InspectorApplicationCacheAgent.h:
3966         (WebCore::InspectorApplicationCacheAgent::create):
3967         * inspector/InspectorBaseAgent.cpp:
3968         (WebCore::InspectorBaseAgentInterface::InspectorBaseAgentInterface):
3969         * inspector/InspectorBaseAgent.h:
3970         (WebCore::InspectorBaseAgent::InspectorBaseAgent):
3971         * inspector/InspectorCSSAgent.cpp:
3972         (WebCore::InspectorCSSAgent::InspectorCSSAgent):
3973         * inspector/InspectorCSSAgent.h:
3974         (WebCore::InspectorCSSAgent::create):
3975         * inspector/InspectorCanvasAgent.cpp:
3976         (WebCore::InspectorCanvasAgent::InspectorCanvasAgent):
3977         * inspector/InspectorCanvasAgent.h:
3978         (WebCore::InspectorCanvasAgent::create):
3979         * inspector/InspectorClient.h:
3980         * inspector/InspectorConsoleAgent.cpp:
3981         (WebCore::InspectorConsoleAgent::InspectorConsoleAgent):
3982         * inspector/InspectorConsoleAgent.h:
3983         * inspector/InspectorController.cpp:
3984         (WebCore::InspectorController::InspectorController):
3985         (WebCore::InspectorController::connectFrontend):
3986         (WebCore::InspectorController::disconnectFrontend):
3987         * inspector/InspectorController.h:
3988         * inspector/InspectorDOMAgent.cpp:
3989         (WebCore::InspectorDOMAgent::InspectorDOMAgent):
3990         * inspector/InspectorDOMAgent.h:
3991         (WebCore::InspectorDOMAgent::create):
3992         * inspector/InspectorDOMDebuggerAgent.cpp:
3993         (WebCore::InspectorDOMDebuggerAgent::create):
3994         (WebCore::InspectorDOMDebuggerAgent::InspectorDOMDebuggerAgent):
3995         * inspector/InspectorDOMDebuggerAgent.h:
3996         * inspector/InspectorDOMStorageAgent.cpp:
3997         (WebCore::InspectorDOMStorageAgent::InspectorDOMStorageAgent):
3998         * inspector/InspectorDOMStorageAgent.h:
3999         (WebCore::InspectorDOMStorageAgent::create):
4000         * inspector/InspectorDatabaseAgent.cpp:
4001         (WebCore::InspectorDatabaseAgent::InspectorDatabaseAgent):
4002         * inspector/InspectorDatabaseAgent.h:
4003         (WebCore::InspectorDatabaseAgent::create):
4004         * inspector/InspectorDebuggerAgent.cpp:
4005         (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent):
4006         * inspector/InspectorDebuggerAgent.h:
4007         * inspector/InspectorHeapProfilerAgent.cpp:
4008         (WebCore::InspectorHeapProfilerAgent::create):
4009         (WebCore::InspectorHeapProfilerAgent::InspectorHeapProfilerAgent):
4010         * inspector/InspectorHeapProfilerAgent.h:
4011         * inspector/InspectorIndexedDBAgent.cpp:
4012         (WebCore::InspectorIndexedDBAgent::InspectorIndexedDBAgent):
4013         * inspector/InspectorIndexedDBAgent.h:
4014         (WebCore::InspectorIndexedDBAgent::create):
4015         * inspector/InspectorInputAgent.cpp:
4016         (WebCore::InspectorInputAgent::InspectorInputAgent):
4017         * inspector/InspectorInputAgent.h:
4018         (WebCore::InspectorInputAgent::create):
4019         * inspector/InspectorLayerTreeAgent.cpp:
4020         (WebCore::InspectorLayerTreeAgent::InspectorLayerTreeAgent):
4021         * inspector/InspectorLayerTreeAgent.h:
4022         (WebCore::InspectorLayerTreeAgent::create):
4023         * inspector/InspectorMemoryAgent.cpp:
4024         (WebCore::InspectorMemoryAgent::InspectorMemoryAgent):
4025         (WebCore::InspectorMemoryAgent::create):
4026         * inspector/InspectorMemoryAgent.h:
4027         * inspector/InspectorPageAgent.cpp:
4028         (WebCore::InspectorPageAgent::create):
4029         (WebCore::InspectorPageAgent::InspectorPageAgent):
4030         * inspector/InspectorPageAgent.h:
4031         * inspector/InspectorProfilerAgent.cpp:
4032         (WebCore::PageProfilerAgent::PageProfilerAgent):
4033         (WebCore::InspectorProfilerAgent::create):
4034         (WebCore::WorkerProfilerAgent::WorkerProfilerAgent):
4035         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
4036         * inspector/InspectorProfilerAgent.h:
4037         * inspector/InspectorResourceAgent.cpp:
4038         (WebCore::InspectorResourceAgent::InspectorResourceAgent):
4039         * inspector/InspectorResourceAgent.h:
4040         (WebCore::InspectorResourceAgent::create):
4041         * inspector/InspectorRuntimeAgent.cpp:
4042         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
4043         * inspector/InspectorRuntimeAgent.h:
4044         * inspector/InspectorState.cpp: Removed.
4045         * inspector/InspectorState.h: Removed.
4046         * inspector/InspectorStateClient.h: Removed.
4047         * inspector/InspectorTimelineAgent.cpp:
4048         (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
4049         * inspector/InspectorTimelineAgent.h:
4050         (WebCore::InspectorTimelineAgent::create):
4051         * inspector/InspectorWorkerAgent.cpp:
4052         (WebCore::InspectorWorkerAgent::create):
4053         (WebCore::InspectorWorkerAgent::InspectorWorkerAgent):
4054         * inspector/InspectorWorkerAgent.h:
4055         * inspector/PageConsoleAgent.cpp:
4056         (WebCore::PageConsoleAgent::PageConsoleAgent):
4057         * inspector/PageConsoleAgent.h:
4058         (WebCore::PageConsoleAgent::create):
4059         * inspector/PageDebuggerAgent.cpp:
4060         (WebCore::PageDebuggerAgent::create):
4061         (WebCore::PageDebuggerAgent::PageDebuggerAgent):
4062         * inspector/PageDebuggerAgent.h:
4063         * inspector/PageRuntimeAgent.cpp:
4064         (WebCore::PageRuntimeAgent::PageRuntimeAgent):
4065         * inspector/PageRuntimeAgent.h:
4066         (WebCore::PageRuntimeAgent::create):
4067         * inspector/WorkerConsoleAgent.cpp:
4068         (WebCore::WorkerConsoleAgent::WorkerConsoleAgent):
4069         * inspector/WorkerConsoleAgent.h:
4070         (WebCore::WorkerConsoleAgent::create):