REGRESSION (r149928): CanvasStyle::operator= leaks everything
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-09-19  Alexey Proskuryakov  <ap@apple.com>
2
3         REGRESSION (r149928): CanvasStyle::operator= leaks everything
4         https://bugs.webkit.org/show_bug.cgi?id=121591
5
6         Reviewed by Andreas Kling.
7
8         * html/canvas/CanvasStyle.cpp: (WebCore::CanvasStyle::operator=): Don't leak.
9
10 2013-09-19  Andrei Parvu  <parvu@adobe.com>
11
12         [CSS Masking/Background] Position property should be ignored when using repeat: space
13         https://bugs.webkit.org/show_bug.cgi?id=120623
14
15         The background/mask-position should be ignored when using repeat: space,
16         unless there is not enough space for two copies of the image. In that case,
17         only one image is placed and background/mask-position determines its position.
18
19         Reviewed by Dirk Schulze.
20
21         Test: css3/masking/mask-repeat-one-copy.html
22
23         * rendering/RenderBoxModelObject.cpp: Ignored position property if space value is positive, set no-repeat otherwise.
24         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
25
26 2013-09-19  Andreas Kling  <akling@apple.com>
27
28         CTTE: EllipsisBox::renderer() should return RenderBlock&.
29         <https://webkit.org/b/121604>
30
31         Reviewed by Antti Koivisto.
32
33         I missed adding a renderer() overload when fixing up EllipsisBox.
34         Flushed out one unnecessary type check.
35
36 2013-09-19  Andreas Kling  <akling@apple.com>
37
38         CTTE: Tighten renderer types for InlineTextBox and SVGInlineTextBox.
39         <https://webkit.org/b/121605>
40
41         Reviewed by Antti Koivisto.
42
43         Codify the following:
44
45         - InlineTextBox always has a RenderText.
46         - SVGInlineTextBox always has a RenderSVGInlineText.
47
48         Removed InlineTextBox::textRenderer() and make renderer() simply
49         return a RenderText&/RenderSVGInlineText& instead.
50
51         This turns some node() accessors into textNode() and removes a host
52         of casts and assertions.
53
54 2013-09-19  Antti Koivisto  <antti@apple.com>
55
56         [CTTE] Hide nonPseudoNode and generatingNode, replace with Element versions
57         https://bugs.webkit.org/show_bug.cgi?id=121606
58
59         Reviewed by Andreas Kling.
60
61 2013-09-19  Andreas Kling  <akling@apple.com>
62
63         CTTE: Tighten renderer types for InlineFlowBox and SVGInlineFlowBox.
64         <https://webkit.org/b/121603>
65
66         Reviewed by Antti Koivisto.
67
68         Codify the following:
69
70         - InlineFlowBox always has a RenderBoxModelObject.
71         - SVGInlineFlowBox always has a RenderSVGInline.
72
73         This turns some node() accessors into element(). Neato!
74
75 2013-09-19  Gurpreet Kaur  <k.gurpreet@samsung.com>
76
77         CSS Unit vmax and vmin in border-width not handled.
78         https://bugs.webkit.org/show_bug.cgi?id=121421
79
80         Reviewed by Darin Adler.
81
82         Border properties were not applied incase its values 
83         were given in vmax/vmin units.
84
85         Tests: fast/css/viewport-vmax-border.html
86                fast/css/viewport-vmin-border.html
87
88         * css/CSSPrimitiveValue.cpp:
89         (WebCore::CSSPrimitiveValue::computeLengthDouble):
90         * css/CSSPrimitiveValue.h:
91         (WebCore::CSSPrimitiveValue::isViewportPercentageMax):
92         (WebCore::CSSPrimitiveValue::isViewportPercentageMin):
93         * css/DeprecatedStyleBuilder.cpp:
94         (WebCore::ApplyPropertyComputeLength::applyValue):
95         Calculating the border values which has been specified in
96         vmax/vmin units. 1vmax: 1vw or 1vh, whatever is largest.
97         1vmin: 1vw or 1vh, whatever is smallest. The vh/vw units are 
98         calcultated as percent of viewport height and viewport width respectively.
99
100 2013-09-19  Antti Koivisto  <antti@apple.com>
101
102         [CTTE] RenderText is always anonymous or associated with Text node
103         https://bugs.webkit.org/show_bug.cgi?id=121596
104
105         Reviewed by Andreas Kling.
106
107         Tighten the node type of RenderText and its subclasses to Text.
108         Switch to createAnonymous pattern.
109         Switch a bunch of unnecessary StringImpl* use to Strings.
110
111 2013-09-18  Mihnea Ovidenie  <mihnea@adobe.com>
112
113         Unreviewed build fix after 156082. Guard SVG code with defines.
114
115         * rendering/RenderNamedFlowThread.cpp:
116         (WebCore::nextNodeInsideContentNode):
117
118 2013-09-18  Mihnea Ovidenie  <mihnea@adobe.com>
119
120         [CSSRegions] Failed to retrieve named flow ranges for content with inline svg
121         https://bugs.webkit.org/show_bug.cgi?id=121489
122
123         Reviewed by David Hyatt.
124
125         The inline SVG element behaves like a replaced element in HTML context. When computing the ranges
126         that are displayed inside a region for a named flow that contains an inline SVG element, we have
127         to treat the SVG as a replaced and run the checks only for the SVG root element, skipping the
128         other SVG elements inside.
129
130         Test: fast/regions/get-region-flow-ranges-inline-svg.html
131
132         * rendering/RenderNamedFlowThread.cpp:
133         (WebCore::nextNodeInsideContentNode): Add function to retrieve the next node in traversal
134         under the contentNode subtree that should be used for getRanges inspection.
135         (WebCore::RenderNamedFlowThread::getRanges): Replace NodeTravesal::next with nextNodeInsideContentNode.
136
137 2013-09-18  Bem Jones-Bey  <bjonesbe@adobe.com>
138
139         REGRESSION (r155854 - r155967) block with margin-left adjacent to floated block causes text of subsequent blocks to overlap the floated block.
140         https://bugs.webkit.org/show_bug.cgi?id=121532
141
142         Reviewed by Andreas Kling.
143
144         When refactoring the code, I ended up adding the margin in instead of
145         subtracting it in the case of an intruding float. This patch fixes
146         that so that the margin is properly handled.
147
148         Test: fast/block/float/intruding-float-sibling-with-margin.html
149
150         * rendering/RenderBlock.cpp:
151         (WebCore::RenderBlock::addIntrudingFloats):
152
153 2013-09-18  Ryosuke Niwa  <rniwa@webkit.org>
154
155         Merge HTMLBodyElement::didNotifySubtreeInsertions into HTMLBodyElement::insertedInto
156         https://bugs.webkit.org/show_bug.cgi?id=121576
157
158         Reviewed by Andreas Kling.
159
160         Merge https://chromium.googlesource.com/chromium/blink/+/2a9cac908f4eceadfcf9d21bdf5b3e598075aa1f
161
162         The logic in didNotifySubtreeInsertions to set the marginwidth and marginheight attributes
163         on the <body> of elements inside <iframe> and <frame> doesn't need to run after inserting
164         all the children of the frame. In fact this means that when you have those attributes
165         and then the script in the iframe touches offsetLeft or any layout dependent property
166         we'll layout with the wrong values and then have to do another layout after these margin
167         attributes are set.
168
169         I also remove the scheduleRelayout() call that was inside didNotifySubtreeInsertions. This
170         call doesn't make any sense, inserting a <body> will always trigger a style recalc and
171         a subsequent layout. The code is 9 years old: https://trac.webkit.org/changeset/8122
172         and all tests run fine without it.
173
174         * html/HTMLBodyElement.cpp:
175         (WebCore::HTMLBodyElement::insertedInto):
176         * html/HTMLBodyElement.h:
177         * html/HTMLFrameElementBase.h:
178         (WebCore::isHTMLFrameElementBase):
179         (WebCore::toHTMLFrameElementBase):
180
181 2013-09-18  Jer Noble  <jer.noble@apple.com>
182
183         [MSE] Throw exception when setting timestampOffset while 'updating' state is set.
184         https://bugs.webkit.org/show_bug.cgi?id=121561
185
186         Reviewed by Eric Carlson.
187
188         Tests: Updated http/tests/media/media-source/mediasource-append-buffer.html.
189
190         Merge https://chromium.googlesource.com/chromium/blink/+/25285998be3d0edcd951d12d445a7375e50e512c
191         by Changbin Shao.
192
193         The Media Source Extensions spec requires that an exception be thrown if the 'updating' attribute
194         equals true while setting the timestampOffset of a SourceBuffer. 
195
196         * Modules/mediasource/SourceBuffer.cpp:
197         (WebCore::SourceBuffer::setTimestampOffset):
198
199 2013-09-18  Anders Carlsson  <andersca@apple.com>
200
201         RefPtrHashMap should work with move only types
202         https://bugs.webkit.org/show_bug.cgi?id=121564
203
204         Reviewed by Andreas Kling.
205
206         * bridge/IdentifierRep.cpp:
207         (WebCore::IdentifierRep::get):
208         * page/PageGroup.cpp:
209         (WebCore::PageGroup::transientLocalStorage):
210
211 2013-09-18  Enrica Casucci  <enrica@apple.com>
212
213         Upstream changes to WebHTMLConverter to support HTML
214         to NSAttributedString conversion on both iOS and OS X.
215
216         Reviewed by Benjamin Poulain.
217
218         This is a new submission of r156001 with the fix for the
219         failing TestWebKitAPI test. The additional change has been
220         reviewed by Tim Horton.
221         
222         * platform/mac/HTMLConverter.h:
223         * platform/mac/HTMLConverter.mm:
224         (WebDefaultFont):
225         (_fontForNameAndSize):
226         (+[WebHTMLConverter defaultParagraphStyle]):
227         (-[WebHTMLConverter _computedStyleForElement:]):
228         (-[WebHTMLConverter _specifiedStyleForElement:]):
229         (-[WebHTMLConverter _computedStringForNode:property:]):
230         (-[WebHTMLConverter _stringForNode:property:]):
231         (-[WebHTMLConverter _getComputedFloat:forNode:property:]):
232         (-[WebHTMLConverter _getFloat:forNode:property:]):
233         (_NSFirstPathForDirectoriesInDomains):
234         (_NSSystemLibraryPath):
235         (-[WebHTMLConverter _webKitBundle]):
236         (_colorForRGBColor):
237         (_shadowForShadowStyle):
238         (-[WebHTMLConverter _elementIsBlockLevel:]):
239         (-[WebHTMLConverter _elementHasOwnBackgroundColor:]):
240         (-[WebHTMLConverter _computedColorForNode:property:]):
241         (-[WebHTMLConverter _colorForNode:property:]):
242         (-[WebHTMLConverter _computedAttributesForElement:]):
243         (-[WebHTMLConverter _attributesForElement:]):
244         (-[WebHTMLConverter _newParagraphForElement:tag:allowEmpty:suppressTrailingSpace:]):
245         (-[WebHTMLConverter _newLineForElement:]):
246         (-[WebHTMLConverter _newTabForElement:]):
247         (-[WebHTMLConverter _WebMessageDocumentClass]):
248         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
249         (-[WebHTMLConverter _addQuoteForElement:opening:level:]):
250         (-[WebHTMLConverter _addValue:forElement:]):
251         (-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
252         (_dateForString):
253         (_colCompare):
254         (-[WebHTMLConverter _processMetaElementWithName:content:]):
255         (-[WebHTMLConverter _processHeadElement:]):
256         (-[WebHTMLConverter _enterElement:tag:display:embedded:]):
257         (-[WebHTMLConverter _addTableForElement:]):
258         (-[WebHTMLConverter _addTableCellForElement:]):
259         (-[WebHTMLConverter _processElement:tag:display:depth:]):
260         (-[WebHTMLConverter _addMarkersToList:range:]):
261         (-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
262         (-[WebHTMLConverter _processText:]):
263         (-[WebHTMLConverter _traverseNode:depth:embedded:]):
264         (-[WebHTMLConverter _traverseFooterNode:depth:]):
265         (-[WebHTMLConverter _loadFromDOMRange]):
266         (-[WebHTMLConverter dealloc]):
267         (-[WebHTMLConverter init]):
268         (-[WebHTMLConverter initWithDOMRange:]):
269         (-[WebHTMLConverter attributedString]):
270         (+[WebHTMLConverter editingAttributedStringFromRange:]):
271
272 2013-09-18  Antti Koivisto  <antti@apple.com>
273
274         Rename RenderBR to RenderLineBreak
275         https://bugs.webkit.org/show_bug.cgi?id=121560
276
277         Reviewed by Sam Weinig.
278
279         It now represents both hard (br) and soft (wbr) line breaks.
280
281 2013-09-18  Robert Hogan  <robert@webkit.org>
282
283         Quirksmode: Break Tag Extra Space Bug
284         https://bugs.webkit.org/show_bug.cgi?id=11943
285
286         Reviewed by David Hyatt.
287
288         Collapse away all space between text and a hard line-break when in a right-aligned
289         container so that the trailing space doesn't push the text away from the container edge.
290
291         Test: fast/text/whitespace/trailing-space-before-br-in-right-aligned-text.html
292
293         * rendering/RenderBlockLineLayout.cpp:
294         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
295
296 2013-09-18  Jer Noble  <jer.noble@apple.com>
297
298         Unreviewed build fix for Qt (and other) ports after 156049.
299
300         Wrap implementation of PublicURLManager in ENABLE(BLOB) check.
301
302         * html/PublicURLManager.cpp:
303
304 2013-09-18  Jer Noble  <jer.noble@apple.com>
305
306         Merge blink MediaSource changes since fork.
307         https://bugs.webkit.org/show_bug.cgi?id=118752
308
309         Rubber-stamped by Eric Carlson.
310
311         Tests: http/tests/media/media-source/mediasource-addsourcebuffer.html
312                http/tests/media/media-source/mediasource-append-buffer.html
313                http/tests/media/media-source/mediasource-buffered.html
314                http/tests/media/media-source/mediasource-closed.html
315                http/tests/media/media-source/mediasource-config-change-mp4-a-bitrate.html
316                http/tests/media/media-source/mediasource-config-change-mp4-av-audio-bitrate.html
317                http/tests/media/media-source/mediasource-config-change-mp4-av-framesize.html
318                http/tests/media/media-source/mediasource-config-change-mp4-av-video-bitrate.html
319                http/tests/media/media-source/mediasource-config-change-mp4-v-bitrate.html
320                http/tests/media/media-source/mediasource-config-change-mp4-v-framerate.html
321                http/tests/media/media-source/mediasource-config-change-mp4-v-framesize.html
322                http/tests/media/media-source/mediasource-config-change-webm-a-bitrate.html
323                http/tests/media/media-source/mediasource-config-change-webm-av-audio-bitrate.html
324                http/tests/media/media-source/mediasource-config-change-webm-av-framesize.html
325                http/tests/media/media-source/mediasource-config-change-webm-av-video-bitrate.html
326                http/tests/media/media-source/mediasource-config-change-webm-v-bitrate.html
327                http/tests/media/media-source/mediasource-config-change-webm-v-framerate.html
328                http/tests/media/media-source/mediasource-config-change-webm-v-framesize.html
329                http/tests/media/media-source/mediasource-is-type-supported.html
330                http/tests/media/media-source/mediasource-multiple-attach.html
331                http/tests/media/media-source/mediasource-play.html
332                http/tests/media/media-source/mediasource-sourcebufferlist.html
333
334         Add files to project. Fix compile errors exposed by enabling.
335
336         * WebCore.xcodeproj/project.pbxproj:
337         * Modules/mediasource/MediaSourceRegistry.cpp:
338         (WebCore::MediaSourceRegistry::lookupMediaSource):
339         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
340         (WebCore::MediaPlayerPrivateAVFoundation::load):
341         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
342         (WebCore::MediaPlayerPrivateQTKit::load):
343         * platform/mac/MIMETypeRegistryMac.mm:
344         (WebCore::MIMETypeRegistry::isSupportedMediaSourceMIMEType):
345         * CMakeLists.txt:
346         * DerivedSources.make:
347         * DerivedSources.pri:
348         * GNUmakefile.list.am:
349
350         Merge
351         https://chromium.googlesource.com/chromium/blink/+/c38e2955db98a300a535b692869fea0e41501497
352         https://chromium.googlesource.com/chromium/blink/+/8568015e9bee1de7fccee28163f9e4a4b51f9baf
353         https://chromium.googlesource.com/chromium/blink/+/14417e8fa6294f4e7dbc1e0fac549398522b2f97
354         https://chromium.googlesource.com/chromium/blink/+/f43a5496f233102f8861a067a9cf8053c010d401
355         https://chromium.googlesource.com/chromium/blink/+/57771439806f7c6e6a272efb1ea72900f5f6a015
356         https://chromium.googlesource.com/chromium/blink/+/8c77a790a9d225194db0a8832399d0f9e1fa54ec
357         https://chromium.googlesource.com/chromium/blink/+/d33ae3fa7a8592e946503ed17f862a27c6d9dde1
358         https://chromium.googlesource.com/chromium/blink/+/1caaa9c51f06e1b9341d58c994f77fd59fcd236d
359         https://chromium.googlesource.com/chromium/blink/+/e95720393b0ebe67f19de39bb77cdf2926165512
360         https://chromium.googlesource.com/chromium/blink/+/bad2c1b4b70faec731b2ad3cc8a4ccf28de6cc38
361         https://chromium.googlesource.com/chromium/blink/+/a7873430c3d5c9373336c6f3993db3cb4228e9cd
362         https://chromium.googlesource.com/chromium/blink/+/508966d5e32360b3cec058f9fbae0014542fbc52
363         https://chromium.googlesource.com/chromium/blink/+/371dfe72f61ce6f73e6c242324da73c415d38be3
364
365 2013-09-18  Andreas Kling  <akling@apple.com>
366
367         CTTE: RenderBR always has an HTMLElement.
368         <https://webkit.org/b/121557>
369
370         Reviewed by Antti Koivisto.
371
372         This renderer is never anonymous and always has a corresponding HTMLElement.
373         Tighten this up by making the constructor take a HTMLElement& and remove
374         RenderBR::createAnonymous().
375
376 2013-09-18  Andreas Kling  <akling@apple.com>
377
378         Avoid using RenderBR internally in RenderMenuList.
379         <https://webkit.org/b/121550>
380
381         Reviewed by Antti Koivisto.
382
383         RenderMenuLists with an empty caption text were previously using a
384         RenderBR as placeholder.
385
386         Switch to using a \n RenderText instead so we can tighten RenderBR.
387
388         This will change DRT dumps but actual metrics should not change.
389
390 2013-09-18  Antti Koivisto  <antti@apple.com>
391
392         Change one accidental "object->isText() || object->isLineBreak()" from previous patch back to "object->isTextOrLineBreak()"
393         
394         Not reviewed.
395
396         * rendering/InlineIterator.h:
397         (WebCore::isIteratorTarget):
398
399 2013-09-18  Antti Koivisto  <antti@apple.com>
400
401         Remove RenderWordBreak
402         https://bugs.webkit.org/show_bug.cgi?id=121549
403
404         Reviewed by Andreas Kling.
405
406         Remove RenderWordBreak and make it a bit in RenderBR instead.
407         
408         * CMakeLists.txt:
409         * GNUmakefile.list.am:
410         * Target.pri:
411         * WebCore.vcxproj/WebCore.vcxproj:
412         * WebCore.xcodeproj/project.pbxproj:
413         * dom/Document.cpp:
414         (WebCore::Document::updateHoverActiveState):
415         * dom/Position.cpp:
416         (WebCore::hasInlineBoxWrapper):
417         (WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
418         * editing/Editor.cpp:
419         (WebCore::findFirstMarkable):
420         * editing/TextIterator.cpp:
421         (WebCore::ignoresContainerClip):
422         * html/HTMLElement.cpp:
423         (WebCore::HTMLElement::createRenderer):
424         * rendering/InlineBox.cpp:
425         (WebCore::InlineBox::logicalHeight):
426         (WebCore::InlineBox::baselinePosition):
427         (WebCore::InlineBox::lineHeight):
428         (WebCore::InlineBox::deleteLine):
429         (WebCore::InlineBox::extractLine):
430         (WebCore::InlineBox::attachLine):
431         (WebCore::InlineBox::nodeAtPoint):
432         * rendering/InlineBox.h:
433         (WebCore::InlineBox::isLineBreak):
434         * rendering/InlineFlowBox.cpp:
435         (WebCore::InlineFlowBox::addToLine):
436         (WebCore::InlineFlowBox::computeOverflow):
437         * rendering/InlineIterator.h:
438         (WebCore::InlineIterator::atTextParagraphSeparator):
439         (WebCore::isIteratorTarget):
440         * rendering/RenderBR.cpp:
441         (WebCore::RenderBR::RenderBR):
442         * rendering/RenderBR.h:
443         (WebCore::toRenderBR):
444     
445             RenderBR now represents both hard and soft line breaks. It will be renamed to RenderLineBreak later.
446
447         * rendering/RenderBlock.cpp:
448         (WebCore::InlineMinMaxIterator::next):
449         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
450         * rendering/RenderBlockLineLayout.cpp:
451         (WebCore::createInlineBoxForRenderer):
452         (WebCore::dirtyLineBoxesForRenderer):
453         (WebCore::RenderBlock::computeBlockDirectionPositionsForLine):
454         (WebCore::RenderBlockFlow::layoutInlineChildren):
455         (WebCore::textBeginsWithBreakablePosition):
456         (WebCore::canBreakAtThisPosition):
457         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
458         * rendering/RenderInline.cpp:
459         (WebCore::RenderInline::generateCulledLineBoxRects):
460         (WebCore::RenderInline::culledInlineFirstLineBox):
461         (WebCore::RenderInline::culledInlineLastLineBox):
462         (WebCore::RenderInline::dirtyLineBoxes):
463         * rendering/RenderLineBoxList.cpp:
464         (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
465         * rendering/RenderObject.h:
466         (WebCore::RenderObject::isLineBreak):
467         
468             This bit covers both BR and WBR.
469
470         (WebCore::RenderObject::isBR):
471         (WebCore::RenderObject::isLineBreakOpportunity):
472         
473             Rename isWordBreak to isLineBreakOpportunity. This matches HTML5 spec terminology.
474
475         (WebCore::RenderObject::isTextOrLineBreak):
476         
477             Since WBR used to be Text we want this check to still cover it too. Renamed from isTextOrBR.
478
479         (WebCore::RenderObject::setIsLineBreak):
480         (WebCore::RenderObject::isWBR):
481         (WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
482         * rendering/RenderObjectChildList.cpp:
483         (WebCore::RenderObjectChildList::removeChildNode):
484         * rendering/RenderText.cpp:
485         * rendering/RenderText.h:
486         * rendering/RenderTreeAsText.cpp:
487         (WebCore::RenderTreeAsText::writeRenderObject):
488         * rendering/RenderWordBreak.cpp: Removed.
489         * rendering/RenderWordBreak.h: Removed.
490         * rendering/RenderingAllInOne.cpp:
491         * rendering/RootInlineBox.cpp:
492         (WebCore::RootInlineBox::ascentAndDescentForBox):
493         (WebCore::RootInlineBox::verticalPositionForBox):
494         (WebCore::RootInlineBox::includeLeadingForBox):
495         (WebCore::RootInlineBox::includeFontForBox):
496         (WebCore::RootInlineBox::includeGlyphsForBox):
497         (WebCore::RootInlineBox::includeMarginForBox):
498
499 2013-09-18  Csaba Osztrogonác  <ossy@webkit.org>
500
501         ASSERT_NOT_REACHED is touched in WebCore::CSSPrimitiveValue::computeLengthDouble
502         https://bugs.webkit.org/show_bug.cgi?id=120469
503
504         Tests: fast/css/outline-offset-parsing-assert.html
505                fast/css/outline-offset-parsing.html
506
507         Reviewed by Dirk Schulze.
508
509         * css/CSSParser.cpp:
510         (WebCore::CSSParser::parseValue): Fixed a typo after r66615, outline-offset can't be percentage.
511
512 2013-09-18  Gurpreet Kaur  <k.gurpreet@samsung.com>
513
514         [MathML] Implement the subscriptshift and superscriptshift attributes
515         https://bugs.webkit.org/show_bug.cgi?id=120069
516
517         Reviewed by Darin Adler.
518
519         Added support for subscriptshift and superscriptshift attributes. The
520         subscriptshift attribute is for msup element and superscriptshift for
521         msup. msubsup can have both subscriptshift and superscriptshift. The
522         subscriptshift attribute specifies the minimum amount to shift the
523         baseline of subscript down. The superscriptshift attribute specifies
524         the minimum amount to shift the baseline of superscript up.
525
526         Tests: mathml/presentation/msub-subscriptshift.html
527                mathml/presentation/msubsup-subscriptshift.html
528                mathml/presentation/msubsup-superscriptshift.html
529                mathml/presentation/msup-superscriptshift.html
530                mathml/presentation/multiscript-subscriptshift.html
531                mathml/presentation/multiscript-superscriptshift.html
532
533         * mathml/mathattrs.in:
534         * rendering/mathml/RenderMathMLScripts.cpp:
535         (WebCore::RenderMathMLScripts::layout):
536         For aligning the subscript and superscript padding is added to the base.
537         So subscriptshift and superscriptshift attributes is set as padding bottom
538         and padding top of base respectively.
539
540 2013-09-18  Mario Sanchez Prada  <mario.prada@samsung.com>
541
542         [ATK] Expose aria-haspopup and aria-sort without the 'aria-' prefix
543         https://bugs.webkit.org/show_bug.cgi?id=121495
544
545         Reviewed by Chris Fleizach.
546
547         Removed the 'aria-' prefix from the exposed ATK object attributes
548         for WAI-ARIA attributes 'aria-haspopup' and 'aria-sort'.
549
550         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
551         (webkitAccessibleGetAttributes): Removed the prefix.
552
553 2013-09-17  Antti Koivisto  <antti@apple.com>
554
555         Rename InlineBox::isText()
556         <https://webkit.org/b/121525>
557
558         Reviewed by Andreas Kling.
559
560         The flag sounds like RenderObject::isText() yet it can be set for some inline boxes generated
561         for non-text renderers too (br, list markers). This is pretty confusing.
562         
563         Rename to InlineBox::behavesLikeText().
564
565         * rendering/InlineBox.cpp:
566         (WebCore::InlineBox::logicalHeight):
567         (WebCore::InlineBox::baselinePosition):
568         (WebCore::InlineBox::lineHeight):
569         * rendering/InlineBox.h:
570         (WebCore::InlineBox::behavesLikeText):
571         (WebCore::InlineBox::setBehavesLikeText):
572         (WebCore::InlineBox::InlineBoxBitfields::InlineBoxBitfields):
573         * rendering/InlineFlowBox.cpp:
574         (WebCore::InlineFlowBox::addToLine):
575         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
576         * rendering/InlineTextBox.cpp:
577         (WebCore::InlineTextBox::baselinePosition):
578         (WebCore::InlineTextBox::lineHeight):
579         * rendering/RenderBlockLineLayout.cpp:
580         (WebCore::createInlineBoxForRenderer):
581         (WebCore::setLogicalWidthForTextRun):
582         * rendering/RenderListMarker.cpp:
583         (WebCore::RenderListMarker::createInlineBox):
584         * rendering/RenderText.cpp:
585         (WebCore::RenderText::createInlineTextBox):
586         * rendering/RootInlineBox.cpp:
587         (WebCore::RootInlineBox::includeLeadingForBox):
588         (WebCore::RootInlineBox::includeFontForBox):
589         (WebCore::RootInlineBox::includeGlyphsForBox):
590         (WebCore::RootInlineBox::includeMarginForBox):
591         
592             Switch tests from isText() to isTextOrBR(). This matches the behavior before r155957.
593             I don't know if there is a case where this actually makes any difference in behavior.
594
595 2013-09-17  Sam Weinig  <sam@webkit.org>
596
597         Shrink SVGPathStringBuilder
598         https://bugs.webkit.org/show_bug.cgi?id=121536
599
600         Reviewed by Anders Carlsson.
601
602         - Use StringBuilder everywhere to avoid unnecessary temporary
603           String objects and code size bloat.
604         - Also did a drive by FINAL / OVERRIDE pass.
605
606         As an example of the win, the function SVGPathStringBuilder::arcTo
607         went from being 6120 bytes down to just 378 bytes.
608
609         * svg/SVGPathStringBuilder.cpp:
610         (WebCore::SVGPathStringBuilder::SVGPathStringBuilder):
611         (WebCore::SVGPathStringBuilder::~SVGPathStringBuilder):
612         (WebCore::SVGPathStringBuilder::cleanup):
613         (WebCore::SVGPathStringBuilder::incrementPathSegmentCount):
614         (WebCore::SVGPathStringBuilder::continueConsuming):
615         It wasn't helpful for these to be inlined, so move them to
616         the implementation file.
617
618         (WebCore::appendFlag):
619         (WebCore::appendNumber):
620         (WebCore::appendPoint):
621         Added helpers.
622
623         (WebCore::SVGPathStringBuilder::moveTo):
624         (WebCore::SVGPathStringBuilder::lineTo):
625         (WebCore::SVGPathStringBuilder::lineToHorizontal):
626         (WebCore::SVGPathStringBuilder::lineToVertical):
627         (WebCore::SVGPathStringBuilder::curveToCubic):
628         (WebCore::SVGPathStringBuilder::curveToCubicSmooth):
629         (WebCore::SVGPathStringBuilder::curveToQuadratic):
630         (WebCore::SVGPathStringBuilder::curveToQuadraticSmooth):
631         (WebCore::SVGPathStringBuilder::arcTo):
632         (WebCore::SVGPathStringBuilder::closePath):
633         * svg/SVGPathStringBuilder.h:
634         Stopped using operator+ and removed duplicate string building logic in each build
635         type (e.g. both sides of the PathCoordinateMode condition were doing almost identical
636         work).
637
638 2013-09-17  Sam Weinig  <sam@webkit.org>
639
640         CTTE: Convert some straggling Element subclasses constructors to take a Document&
641         https://bugs.webkit.org/show_bug.cgi?id=121533
642
643         Reviewed by Anders Carlsson.
644
645         * html/HTMLMeterElement.cpp:
646         (WebCore::HTMLMeterElement::didAddUserAgentShadowRoot):
647         * html/HTMLProgressElement.cpp:
648         (WebCore::HTMLProgressElement::didAddUserAgentShadowRoot):
649         * html/HTMLTextAreaElement.cpp:
650         (WebCore::HTMLTextAreaElement::didAddUserAgentShadowRoot):
651         * html/SearchInputType.cpp:
652         (WebCore::SearchInputType::createShadowSubtree):
653         * html/TextFieldInputType.cpp:
654         (WebCore::TextFieldInputType::createShadowSubtree):
655         * html/shadow/MeterShadowElement.cpp:
656         (WebCore::MeterShadowElement::MeterShadowElement):
657         (WebCore::MeterInnerElement::MeterInnerElement):
658         * html/shadow/MeterShadowElement.h:
659         (WebCore::MeterInnerElement::create):
660         (WebCore::MeterBarElement::create):
661         (WebCore::MeterValueElement::create):
662         * html/shadow/ProgressShadowElement.cpp:
663         (WebCore::ProgressShadowElement::ProgressShadowElement):
664         (WebCore::ProgressInnerElement::ProgressInnerElement):
665         (WebCore::ProgressBarElement::ProgressBarElement):
666         (WebCore::ProgressValueElement::ProgressValueElement):
667         * html/shadow/ProgressShadowElement.h:
668         (WebCore::ProgressInnerElement::create):
669         (WebCore::ProgressBarElement::create):
670         (WebCore::ProgressValueElement::create):
671         * html/shadow/SpinButtonElement.cpp:
672         (WebCore::SpinButtonElement::SpinButtonElement):
673         (WebCore::SpinButtonElement::create):
674         * html/shadow/SpinButtonElement.h:
675         * html/shadow/TextControlInnerElements.cpp:
676         (WebCore::TextControlInnerContainer::TextControlInnerContainer):
677         (WebCore::TextControlInnerContainer::create):
678         (WebCore::TextControlInnerElement::TextControlInnerElement):
679         (WebCore::TextControlInnerElement::create):
680         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
681         (WebCore::TextControlInnerTextElement::create):
682         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
683         (WebCore::SearchFieldResultsButtonElement::create):
684         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
685         (WebCore::SearchFieldCancelButtonElement::create):
686         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
687         (WebCore::InputFieldSpeechButtonElement::create):
688         * html/shadow/TextControlInnerElements.h:
689
690 2013-09-17  Zoltan Horvath  <zoltan@webkit.org>
691
692         [CSS Shapes] Use the float height to determine position in shape-inside
693         https://bugs.webkit.org/show_bug.cgi?id=102846
694
695         Reviewed by Darin Adler.
696
697         Float positioning inside shape-inside has been working only for simple cases when the float boundaries didn't overlap with the shape.
698         This patch fixes the behavior for left floats and shapes with inline content. I want to add this work step by step, therefore the next
699         step would be to add support for block content with inline content (e.g. paragraphs) then cover cases with right floats.
700
701         Tests: fast/shapes/shape-inside/shape-inside-left-float-in-lower-left-triangle-inline-content.html
702                fast/shapes/shape-inside/shape-inside-left-float-in-lower-right-triangle-inline-content.html
703                fast/shapes/shape-inside/shape-inside-left-float-in-upper-left-triangle-inline-content.html
704                fast/shapes/shape-inside/shape-inside-left-float-in-upper-right-triangle-inline-content.html
705
706         * rendering/LineWidth.cpp:
707         (WebCore::LineWidth::LineWidth): Use the new updateCurrentShapeSegment member function.
708         (WebCore::LineWidth::updateCurrentShapeSegment): We need a function to update the current line segment's reference, since we use it multiple places.
709         * rendering/LineWidth.h: Add new member function.
710         * rendering/RenderBlock.cpp:
711         (WebCore::RenderBlock::computeLogicalLocationForFloat): Fix positioning of a floating element.
712         * rendering/RenderBlockLineLayout.cpp:
713         (WebCore::RenderBlock::updateShapeAndSegmentsForCurrentLine): Use updateSegmentsForLine instead of computeSegmentsForLine.
714         (WebCore::RenderBlock::updateShapeAndSegmentsForCurrentLineInFlowThread): Use updateSegmentsForLine instead of computeSegmentsForLine.
715         (WebCore::RenderBlock::adjustLogicalLineTopAndLogicalHeightIfNeeded):
716         (WebCore::updateSegmentsForShapes): After our float is positioned, we need to adjust the current lineTop and update the logical height to be able to wrap around the float.
717         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak): If we have a float in our line we might need to adjust our lineTop and logicalHeight.
718         * rendering/shapes/ShapeInfo.cpp:
719         (WebCore::::computeSegmentsForLine): Add new const function to compute the segments. I'd like make this function static later if possible.
720         (WebCore::::updateSegmentsForLine): Old computeSegmentsForLine, change name to indicate that it is actually changing things.
721         * rendering/shapes/ShapeInfo.h: Update function names, add declaration.
722         (WebCore::ShapeInfo::clearSegments):
723         (WebCore::ShapeInfo::logicalLineBottom):
724         (WebCore::ShapeInfo::lineOverlapsShapeBounds):
725         * rendering/shapes/ShapeInsideInfo.cpp:
726         (WebCore::ShapeInsideInfo::computeFirstFitPositionForFloat): Compute the first fit position below the current line position inside shapes. I called this function
727         this way, because currently we use it only for shapes.
728         * rendering/shapes/ShapeInsideInfo.h: Update function names.
729         * rendering/shapes/ShapeOutsideInfo.cpp: Update function names.
730         (WebCore::ShapeOutsideInfo::computeSegmentsForContainingBlockLine):
731         (WebCore::ShapeOutsideInfo::updateSegmentsForLine):
732         * rendering/shapes/ShapeOutsideInfo.h: Update function names.
733
734 2013-09-17  Sam Weinig  <sam@webkit.org>
735
736         Replace use of OwnArrayPtr<Foo> with std::unique_ptr<Foo[]> in WebCore
737         https://bugs.webkit.org/show_bug.cgi?id=121527
738
739         Reviewed by Anders Carlsson.
740
741         * Modules/webaudio/AudioBufferSourceNode.cpp:
742         (WebCore::AudioBufferSourceNode::setBuffer):
743         * Modules/webaudio/AudioBufferSourceNode.h:
744         * Modules/webaudio/OscillatorNode.h:
745         * css/CSSParser.cpp:
746         (WebCore::CSSParser::setupParser):
747         (WebCore::CSSParser::currentCharacter16):
748         * css/CSSParser.h:
749         * html/HTMLAreaElement.h:
750         * html/HTMLFrameSetElement.h:
751         * html/canvas/WebGLRenderingContext.cpp:
752         (WebCore::WebGLRenderingContext::copyTexSubImage2D):
753         (WebCore::WebGLRenderingContext::simulateVertexAttrib0):
754         (WebCore::WebGLRenderingContext::LRUImageBufferCache::LRUImageBufferCache):
755         * html/canvas/WebGLRenderingContext.h:
756         * platform/ScrollAnimatorNone.cpp:
757         * platform/audio/DynamicsCompressor.cpp:
758         (WebCore::DynamicsCompressor::setNumberOfChannels):
759         * platform/audio/DynamicsCompressor.h:
760         * platform/audio/FFTFrame.h:
761         * platform/audio/gstreamer/FFTFrameGStreamer.cpp:
762         (WebCore::FFTFrame::FFTFrame):
763         * platform/efl/ScrollbarEfl.cpp:
764         (ScrollbarEfl::updateThumbPositionAndProportion):
765         * platform/graphics/ANGLEWebKitBridge.cpp:
766         (WebCore::ANGLEWebKitBridge::compileShaderSource):
767         * platform/graphics/GraphicsContext3D.cpp:
768         (WebCore::GraphicsContext3D::texImage2DResourceSafe):
769         * platform/graphics/GraphicsContext3D.h:
770         * platform/graphics/GraphicsContext3DPrivate.cpp:
771         (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
772         * platform/graphics/blackberry/LayerTexture.cpp:
773         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
774         (WebCore::getDirtyRects):
775         * platform/graphics/cg/GraphicsContext3DCG.cpp:
776         (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
777         * platform/graphics/cg/GraphicsContextCG.cpp:
778         * platform/graphics/cg/ImageBufferCG.cpp:
779         * platform/graphics/gpu/Texture.cpp:
780         (WebCore::Texture::updateSubRect):
781         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
782         (WebCore::HarfBuzzShaper::HarfBuzzShaper):
783         (WebCore::HarfBuzzShaper::setNormalizedBuffer):
784         * platform/graphics/harfbuzz/HarfBuzzShaper.h:
785         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
786         (WebCore::GraphicsContext3D::paintRenderingResultsToCanvas):
787         (WebCore::GraphicsContext3D::compileShader):
788         (WebCore::GraphicsContext3D::getActiveAttrib):
789         (WebCore::GraphicsContext3D::getActiveUniform):
790         (WebCore::GraphicsContext3D::getProgramInfoLog):
791         (WebCore::GraphicsContext3D::getShaderInfoLog):
792         * platform/graphics/opentype/OpenTypeSanitizer.cpp:
793         * platform/graphics/texmap/TextureMapperGL.cpp:
794         * platform/graphics/wince/SharedBitmap.cpp:
795         (WebCore::SharedBitmap::SharedBitmap):
796         (WebCore::SharedBitmap::to16bit):
797         * platform/graphics/wince/SharedBitmap.h:
798         * platform/image-decoders/blackberry/JPEGImageDecoder.cpp:
799         (WebCore::ImageReader::decode):
800         * platform/image-decoders/png/PNGImageDecoder.cpp:
801         (WebCore::PNGImageReader::createRowBuffer):
802         * platform/win/ContextMenuWin.cpp:
803         (WebCore::ContextMenu::getContextMenuItems):
804         * platform/win/LoggingWin.cpp:
805         (WebCore::logLevelString):
806         * plugins/PluginPackage.cpp:
807         * plugins/blackberry/PluginViewBlackBerry.cpp:
808         (WebCore::PluginView::handleTouchEvent):
809         * plugins/win/PluginPackageWin.cpp:
810         (WebCore::PluginPackage::fetchInfo):
811
812 2013-09-17  Commit Queue  <commit-queue@webkit.org>
813
814         Unreviewed, rolling out r156001.
815         http://trac.webkit.org/changeset/156001
816         https://bugs.webkit.org/show_bug.cgi?id=121529
817
818         Broke API tests (Requested by ap on #webkit).
819
820         * platform/mac/HTMLConverter.h:
821         * platform/mac/HTMLConverter.mm:
822         (WebDefaultFont):
823         (_fontForNameAndSize):
824         (+[WebHTMLConverter defaultParagraphStyle]):
825         (-[WebHTMLConverter _computedStyleForElement:]):
826         (-[WebHTMLConverter _specifiedStyleForElement:]):
827         (-[WebHTMLConverter _computedStringForNode:property:]):
828         (-[WebHTMLConverter _stringForNode:property:]):
829         (-[WebHTMLConverter _getComputedFloat:forNode:property:]):
830         (-[WebHTMLConverter _getFloat:forNode:property:]):
831         (_colorForRGBColor):
832         (_shadowForShadowStyle):
833         (-[WebHTMLConverter _elementIsBlockLevel:]):
834         (-[WebHTMLConverter _elementHasOwnBackgroundColor:]):
835         (-[WebHTMLConverter _computedColorForNode:property:]):
836         (-[WebHTMLConverter _colorForNode:property:]):
837         (-[WebHTMLConverter _computedAttributesForElement:]):
838         (-[WebHTMLConverter _attributesForElement:]):
839         (-[WebHTMLConverter _newParagraphForElement:tag:allowEmpty:suppressTrailingSpace:]):
840         (-[WebHTMLConverter _newLineForElement:]):
841         (-[WebHTMLConverter _newTabForElement:]):
842         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
843         (-[WebHTMLConverter _addQuoteForElement:opening:level:]):
844         (-[WebHTMLConverter _addValue:forElement:]):
845         (-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
846         (_dateForString):
847         (_colCompare):
848         (-[WebHTMLConverter _enterElement:tag:display:]):
849         (-[WebHTMLConverter _addTableForElement:]):
850         (-[WebHTMLConverter _addTableCellForElement:]):
851         (-[WebHTMLConverter _processElement:tag:display:depth:]):
852         (-[WebHTMLConverter _addMarkersToList:range:]):
853         (-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
854         (-[WebHTMLConverter _processText:]):
855         (-[WebHTMLConverter _traverseNode:depth:embedded:]):
856         (-[WebHTMLConverter _traverseFooterNode:depth:]):
857         (-[WebHTMLConverter _loadFromDOMRange]):
858         (-[WebHTMLConverter dealloc]):
859         (-[WebHTMLConverter init]):
860         (-[WebHTMLConverter initWithDOMRange:]):
861         (-[WebHTMLConverter attributedString]):
862         (+[WebHTMLConverter editingAttributedStringFromRange:]):
863         (fileWrapperForElement):
864
865 2013-09-17  Samuel White  <samuel_white@apple.com>
866
867         AX: Mac AXARIABusy should be AXElementBusy (not ARIA specific)
868         https://bugs.webkit.org/show_bug.cgi?id=121442
869
870         Reviewed by Chris Fleizach.
871
872         No new tests, changed AXARIABusy attribute to AXElementBusy to uncouple the concept of busy with
873         the aria-busy attribute. This will allow us to expand on the definition of busy moving forward.
874
875         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
876         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
877         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
878
879 2013-09-17  Andreas Kling  <akling@apple.com>
880
881         Pack create_hash_table tables better.
882         <https://webkit.org/b/121517>
883
884         Reviewed by Sam Weinig.
885
886         Reduces WebCore binary size by 72744 bytes.
887
888         * bindings/scripts/CodeGeneratorJS.pm:
889         (GenerateHashTable):
890
891             Updated for new HashTableValue member order.
892
893         * bindings/scripts/test/JS/*:
894
895             Rebaselined bindings tests.
896
897 2013-09-17  Zoltan Horvath  <zoltan@webkit.org>
898
899         [Qt] Add FlowThreadController.h to Target.pri
900         https://bugs.webkit.org/show_bug.cgi?id=121516
901
902         Reviewed by Dirk Schulze.
903
904         No new tests, no behavior change.
905
906         * Target.pri:
907
908 2013-09-17  Anders Carlsson  <andersca@apple.com>
909
910         Stop explicitly using PassOwnPtr in WebCore/html
911         https://bugs.webkit.org/show_bug.cgi?id=121511
912
913         Reviewed by Andreas Kling.
914
915         * dom/ElementRareData.h:
916         (WebCore::ElementRareData::setClassList):
917         * html/ButtonInputType.cpp:
918         (WebCore::ButtonInputType::create):
919         * html/ButtonInputType.h:
920         * html/CheckboxInputType.cpp:
921         (WebCore::CheckboxInputType::create):
922         (WebCore::CheckboxInputType::willDispatchClick):
923         * html/CheckboxInputType.h:
924         * html/ClassList.cpp:
925         (WebCore::ClassList::create):
926         * html/ClassList.h:
927         * html/ColorInputType.cpp:
928         (WebCore::ColorInputType::create):
929         * html/ColorInputType.h:
930         * html/DateInputType.cpp:
931         (WebCore::DateInputType::create):
932         * html/DateInputType.h:
933         * html/DateTimeInputType.cpp:
934         (WebCore::DateTimeInputType::create):
935         * html/DateTimeInputType.h:
936         * html/DateTimeLocalInputType.cpp:
937         (WebCore::DateTimeLocalInputType::create):
938         * html/DateTimeLocalInputType.h:
939         * html/EmailInputType.cpp:
940         (WebCore::EmailInputType::create):
941         * html/EmailInputType.h:
942         * html/FileInputType.cpp:
943         (WebCore::FileInputType::create):
944         * html/FileInputType.h:
945         * html/FormAssociatedElement.cpp:
946         (WebCore::FormAttributeTargetObserver::create):
947         * html/FormController.cpp:
948         (WebCore::SavedFormState::create):
949         (WebCore::SavedFormState::deserialize):
950         (WebCore::FormKeyGenerator::create):
951         (WebCore::FormController::createSavedFormStateMap):
952         * html/FormController.h:
953         (WebCore::FormController::create):
954         * html/HTMLInputElement.cpp:
955         (WebCore::ListAttributeTargetObserver::create):
956         * html/HiddenInputType.cpp:
957         (WebCore::HiddenInputType::create):
958         * html/HiddenInputType.h:
959         * html/ImageInputType.cpp:
960         (WebCore::ImageInputType::create):
961         * html/ImageInputType.h:
962         * html/InputType.cpp:
963         (WebCore::InputType::create):
964         (WebCore::InputType::createText):
965         (WebCore::InputType::willDispatchClick):
966         * html/InputType.h:
967         * html/MonthInputType.cpp:
968         (WebCore::MonthInputType::create):
969         * html/MonthInputType.h:
970         * html/NumberInputType.cpp:
971         (WebCore::NumberInputType::create):
972         * html/NumberInputType.h:
973         * html/PasswordInputType.cpp:
974         (WebCore::PasswordInputType::create):
975         * html/PasswordInputType.h:
976         * html/PublicURLManager.h:
977         (WebCore::PublicURLManager::create):
978         * html/RadioInputType.cpp:
979         (WebCore::RadioInputType::create):
980         (WebCore::RadioInputType::willDispatchClick):
981         * html/RadioInputType.h:
982         * html/RangeInputType.cpp:
983         (WebCore::RangeInputType::create):
984         * html/RangeInputType.h:
985         * html/ResetInputType.cpp:
986         (WebCore::ResetInputType::create):
987         * html/ResetInputType.h:
988         * html/SearchInputType.cpp:
989         (WebCore::SearchInputType::create):
990         * html/SearchInputType.h:
991         * html/SubmitInputType.cpp:
992         (WebCore::SubmitInputType::create):
993         * html/SubmitInputType.h:
994         * html/TelephoneInputType.cpp:
995         (WebCore::TelephoneInputType::create):
996         * html/TelephoneInputType.h:
997         * html/TextInputType.cpp:
998         (WebCore::TextInputType::create):
999         * html/TextInputType.h:
1000         * html/TimeInputType.cpp:
1001         (WebCore::TimeInputType::create):
1002         * html/TimeInputType.h:
1003         * html/URLInputType.cpp:
1004         (WebCore::URLInputType::create):
1005         * html/URLInputType.h:
1006         * html/ValidationMessage.cpp:
1007         (WebCore::ValidationMessage::create):
1008         * html/ValidationMessage.h:
1009         * html/ValidityState.h:
1010         (WebCore::ValidityState::create):
1011         * html/WeekInputType.cpp:
1012         (WebCore::WeekInputType::create):
1013         * html/WeekInputType.h:
1014         * html/canvas/CanvasRenderingContext2D.cpp:
1015         (WebCore::CanvasRenderingContext2D::createCompositingBuffer):
1016         * html/canvas/CanvasRenderingContext2D.h:
1017         (WebCore::CanvasRenderingContext2D::create):
1018         * html/canvas/EXTDrawBuffers.cpp:
1019         (WebCore::EXTDrawBuffers::create):
1020         * html/canvas/EXTDrawBuffers.h:
1021         * html/canvas/EXTTextureFilterAnisotropic.cpp:
1022         (WebCore::EXTTextureFilterAnisotropic::create):
1023         * html/canvas/EXTTextureFilterAnisotropic.h:
1024         * html/canvas/OESElementIndexUint.cpp:
1025         (WebCore::OESElementIndexUint::create):
1026         * html/canvas/OESElementIndexUint.h:
1027         * html/canvas/OESStandardDerivatives.cpp:
1028         (WebCore::OESStandardDerivatives::create):
1029         * html/canvas/OESStandardDerivatives.h:
1030         * html/canvas/OESTextureFloat.cpp:
1031         (WebCore::OESTextureFloat::create):
1032         * html/canvas/OESTextureFloat.h:
1033         * html/canvas/OESTextureHalfFloat.cpp:
1034         (WebCore::OESTextureHalfFloat::create):
1035         * html/canvas/OESTextureHalfFloat.h:
1036         * html/canvas/OESVertexArrayObject.cpp:
1037         (WebCore::OESVertexArrayObject::create):
1038         * html/canvas/OESVertexArrayObject.h:
1039         * html/canvas/WebGLCompressedTextureATC.cpp:
1040         (WebCore::WebGLCompressedTextureATC::create):
1041         * html/canvas/WebGLCompressedTextureATC.h:
1042         * html/canvas/WebGLCompressedTexturePVRTC.cpp:
1043         (WebCore::WebGLCompressedTexturePVRTC::create):
1044         * html/canvas/WebGLCompressedTexturePVRTC.h:
1045         * html/canvas/WebGLCompressedTextureS3TC.cpp:
1046         (WebCore::WebGLCompressedTextureS3TC::create):
1047         * html/canvas/WebGLCompressedTextureS3TC.h:
1048         * html/canvas/WebGLDebugRendererInfo.cpp:
1049         (WebCore::WebGLDebugRendererInfo::create):
1050         * html/canvas/WebGLDebugRendererInfo.h:
1051         * html/canvas/WebGLDebugShaders.cpp:
1052         (WebCore::WebGLDebugShaders::create):
1053         * html/canvas/WebGLDebugShaders.h:
1054         * html/canvas/WebGLDepthTexture.cpp:
1055         (WebCore::WebGLDepthTexture::create):
1056         * html/canvas/WebGLDepthTexture.h:
1057         * html/canvas/WebGLLoseContext.cpp:
1058         (WebCore::WebGLLoseContext::create):
1059         * html/canvas/WebGLLoseContext.h:
1060         * html/canvas/WebGLRenderingContext.cpp:
1061         (WebCore::WebGLRenderingContext::create):
1062         * html/canvas/WebGLRenderingContext.h:
1063         * html/parser/BackgroundHTMLParser.cpp:
1064         (WebCore::BackgroundHTMLParser::BackgroundHTMLParser):
1065         (WebCore::BackgroundHTMLParser::resumeFrom):
1066         * html/parser/BackgroundHTMLParser.h:
1067         (WebCore::BackgroundHTMLParser::create):
1068         * html/parser/HTMLDocumentParser.cpp:
1069         (WebCore::HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser):
1070         (WebCore::HTMLDocumentParser::validateSpeculations):
1071         (WebCore::HTMLDocumentParser::discardSpeculationsAndResumeFrom):
1072         (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser):
1073         * html/parser/HTMLDocumentParser.h:
1074         * html/parser/HTMLElementStack.cpp:
1075         (WebCore::HTMLElementStack::ElementRecord::ElementRecord):
1076         * html/parser/HTMLElementStack.h:
1077         (WebCore::HTMLElementStack::ElementRecord::releaseNext):
1078         (WebCore::HTMLElementStack::ElementRecord::setNext):
1079         * html/parser/HTMLMetaCharsetParser.h:
1080         (WebCore::HTMLMetaCharsetParser::create):
1081         * html/parser/HTMLParserScheduler.h:
1082         (WebCore::HTMLParserScheduler::create):
1083         * html/parser/HTMLParserThread.h:
1084         (WebCore::HTMLParserThread::create):
1085         * html/parser/HTMLPreloadScanner.cpp:
1086         (WebCore::TokenPreloadScanner::StartTagScanner::createPreloadRequest):
1087         * html/parser/HTMLResourcePreloader.cpp:
1088         (WebCore::HTMLResourcePreloader::preload):
1089         * html/parser/HTMLResourcePreloader.h:
1090         (WebCore::PreloadRequest::create):
1091         * html/parser/HTMLScriptRunner.h:
1092         (WebCore::HTMLScriptRunner::create):
1093         * html/parser/HTMLToken.h:
1094         (WebCore::HTMLToken::releaseDoctypeData):
1095         * html/parser/HTMLTokenizer.h:
1096         (WebCore::HTMLTokenizer::create):
1097         * html/parser/HTMLTreeBuilder.h:
1098         (WebCore::HTMLTreeBuilder::create):
1099         * html/parser/XSSAuditor.cpp:
1100         (WebCore::XSSAuditor::filterToken):
1101         * html/parser/XSSAuditor.h:
1102         * html/parser/XSSAuditorDelegate.h:
1103         (WebCore::XSSInfo::create):
1104         * html/track/WebVTTParser.h:
1105         (WebCore::WebVTTParser::create):
1106         * html/track/WebVTTTokenizer.h:
1107         (WebCore::WebVTTTokenizer::create):
1108
1109 2013-09-17  Enrica Casucci  <enrica@apple.com>
1110
1111         Upstream changes to WebHTMLConverter to support HTML
1112         to NSAttributedString conversion on both iOS and OS X.
1113
1114         Reviewed by Benjamin Poulain.
1115
1116         * platform/mac/HTMLConverter.h:
1117         * platform/mac/HTMLConverter.mm:
1118         (WebDefaultFont):
1119         (_fontForNameAndSize):
1120         (+[WebHTMLConverter defaultParagraphStyle]):
1121         (-[WebHTMLConverter _computedStyleForElement:]):
1122         (-[WebHTMLConverter _specifiedStyleForElement:]):
1123         (-[WebHTMLConverter _computedStringForNode:property:]):
1124         (-[WebHTMLConverter _stringForNode:property:]):
1125         (-[WebHTMLConverter _getComputedFloat:forNode:property:]):
1126         (-[WebHTMLConverter _getFloat:forNode:property:]):
1127         (_NSFirstPathForDirectoriesInDomains):
1128         (_NSSystemLibraryPath):
1129         (-[WebHTMLConverter _webKitBundle]):
1130         (_colorForRGBColor):
1131         (_shadowForShadowStyle):
1132         (-[WebHTMLConverter _elementIsBlockLevel:]):
1133         (-[WebHTMLConverter _elementHasOwnBackgroundColor:]):
1134         (-[WebHTMLConverter _computedColorForNode:property:]):
1135         (-[WebHTMLConverter _colorForNode:property:]):
1136         (-[WebHTMLConverter _computedAttributesForElement:]):
1137         (-[WebHTMLConverter _attributesForElement:]):
1138         (-[WebHTMLConverter _newParagraphForElement:tag:allowEmpty:suppressTrailingSpace:]):
1139         (-[WebHTMLConverter _newLineForElement:]):
1140         (-[WebHTMLConverter _newTabForElement:]):
1141         (-[WebHTMLConverter _WebMessageDocumentClass]):
1142         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
1143         (-[WebHTMLConverter _addQuoteForElement:opening:level:]):
1144         (-[WebHTMLConverter _addValue:forElement:]):
1145         (-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
1146         (_dateForString):
1147         (_colCompare):
1148         (-[WebHTMLConverter _processMetaElementWithName:content:]):
1149         (-[WebHTMLConverter _processHeadElement:]):
1150         (-[WebHTMLConverter _enterElement:tag:display:embedded:]):
1151         (-[WebHTMLConverter _addTableForElement:]):
1152         (-[WebHTMLConverter _addTableCellForElement:]):
1153         (-[WebHTMLConverter _processElement:tag:display:depth:]):
1154         (-[WebHTMLConverter _addMarkersToList:range:]):
1155         (-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
1156         (-[WebHTMLConverter _processText:]):
1157         (-[WebHTMLConverter _traverseNode:depth:embedded:]):
1158         (-[WebHTMLConverter _traverseFooterNode:depth:]):
1159         (-[WebHTMLConverter _loadFromDOMRange]):
1160         (-[WebHTMLConverter dealloc]):
1161         (-[WebHTMLConverter init]):
1162         (-[WebHTMLConverter initWithDOMRange:]):
1163         (-[WebHTMLConverter attributedString]):
1164         (+[WebHTMLConverter editingAttributedStringFromRange:]):
1165
1166 2013-09-17  Sam Weinig  <sam@webkit.org>
1167
1168         Add make_unique and start using it
1169         https://bugs.webkit.org/show_bug.cgi?id=121523
1170
1171         Reviewed by Anders Carlsson.
1172
1173         * html/HTMLAreaElement.h:
1174         * html/HTMLFrameSetElement.h:
1175         * platform/Length.cpp:
1176         (WebCore::newCoordsArray):
1177         (WebCore::newLengthArray):
1178         * platform/Length.h:
1179         Switch off OwnArrayPtr to std::unique_ptr<T[]> and make use of make_unique.
1180
1181 2013-09-17  Simon Fraser  <simon.fraser@apple.com>
1182
1183         Hardware accelerated CSS transitions appear pixelated when scaled up using transform
1184         https://bugs.webkit.org/show_bug.cgi?id=27684
1185         <rdar://problem/6134606>
1186
1187         Reviewed by Dean Jackson.
1188         
1189         Take transforms and animations into account when computing the contentsScale
1190         for a layer, so that scaled-up layers remain sharp most of the time.
1191         
1192         In its recursiveCommitChanges() tree walk, GraphicsLayerCA now tracks
1193         a root-relative transform, and extracts from that transform the X and Y
1194         scales which it uses to scale the backing store.
1195         
1196         If the layer has transform animations on it, we keep around
1197         a transformation matrix for the animation endpoints (or keyframes),
1198         pick up the state that has the larger impact on the root-relative scale,
1199         and use that as the layer's transform, and the transform when recursing
1200         over descendants.
1201
1202         Tests: compositing/contents-scale/animating.html
1203                compositing/contents-scale/scaled-ancestor.html
1204                compositing/contents-scale/simple-scale.html
1205                compositing/contents-scale/z-translate.html
1206
1207         * platform/graphics/ca/GraphicsLayerCA.cpp:
1208         (WebCore::maxScaleFromTransform): Decompose the transform if necesssary
1209         to extract the X and Y scale components.
1210         (WebCore::GraphicsLayerCA::GraphicsLayerCA): Initialize m_rootRelativeScaleFactor.
1211         (WebCore::GraphicsLayerCA::flushCompositingState): Supply a TransformationMatrix
1212         for the root of the recursion.
1213         (WebCore::GraphicsLayerCA::layerTransform): This code was factored out of
1214         computeVisibleRect(), and optionally takes a custom transform.
1215         (WebCore::GraphicsLayerCA::computeVisibleRect): Use the layerTransform() function.
1216         (WebCore::GraphicsLayerCA::updateRootRelativeScale): Given a transform from the root,
1217         find the max scale factor by multiplying the various animation endpoint matrices and picking
1218         the one with the biggest impact on scale. Use this to set m_rootRelativeScaleFactor, and
1219         set the flag to say that we need to update contentsScale.
1220         (WebCore::GraphicsLayerCA::recursiveCommitChanges):
1221         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): After updating
1222         animations, call updateRootRelativeScale() to update m_rootRelativeScaleFactor.
1223         (WebCore::GraphicsLayerCA::updateAnimations): We have a side table of animation name to
1224         TransformationMatrix, so figure out which entries can be removed from that side table,
1225         and remove them.
1226         (WebCore::GraphicsLayerCA::setAnimationOnLayer):
1227         (WebCore::GraphicsLayerCA::appendToUncommittedAnimations): Store the matrices for
1228         animation endpoints/keyframes in the m_animationTransforms side table. We don't store
1229         them directly in LayerPropertyAnimation because we just want the final matrix for
1230         a transform list, and using a side table makes ownership easier to manage.
1231         (WebCore::GraphicsLayerCA::getTransformFromAnimationsWithMaxScaleImpact):
1232         goes through the matrices for the running animation endpoints/keyframes, and
1233         multiplies each with the transform up to this layer to find the matrix with the
1234         larger impact on scale.
1235         (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints): Returns a vector
1236         of TransformationMatrix for the from and to states.
1237         (WebCore::GraphicsLayerCA::setTransformAnimationKeyframes): Returns a vector
1238         of TransformationMatrix for the keyframes.
1239         (WebCore::GraphicsLayerCA::updateContentsScale): Include m_rootRelativeScaleFactor in the
1240         scale factor computation.
1241         (WebCore::GraphicsLayerCA::dumpAdditionalProperties): If we're dumping visible rects,
1242         also dump the contentsScale. Convenient at these are useful to look at together, and I didn't
1243         want to pollute Internals with yet more flags.
1244         * platform/graphics/ca/GraphicsLayerCA.h:
1245         (WebCore::GraphicsLayerCA::LayerPropertyAnimation::LayerPropertyAnimation): Formatting.
1246
1247 2013-09-17  Commit Queue  <commit-queue@webkit.org>
1248
1249         Unreviewed, rolling out r155977.
1250         http://trac.webkit.org/changeset/155977
1251         https://bugs.webkit.org/show_bug.cgi?id=121515
1252
1253         Broke over a dozen tests on Mac WK2 (Requested by ap on
1254         #webkit).
1255
1256         * platform/graphics/ca/GraphicsLayerCA.cpp:
1257         (WebCore::GraphicsLayerCA::GraphicsLayerCA):
1258         (WebCore::GraphicsLayerCA::flushCompositingState):
1259         (WebCore::GraphicsLayerCA::computeVisibleRect):
1260         (WebCore::GraphicsLayerCA::recursiveCommitChanges):
1261         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
1262         (WebCore::GraphicsLayerCA::updateAnimations):
1263         (WebCore::GraphicsLayerCA::setAnimationOnLayer):
1264         (WebCore::GraphicsLayerCA::appendToUncommittedAnimations):
1265         (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints):
1266         (WebCore::GraphicsLayerCA::setTransformAnimationKeyframes):
1267         (WebCore::GraphicsLayerCA::updateContentsScale):
1268         (WebCore::GraphicsLayerCA::dumpAdditionalProperties):
1269         * platform/graphics/ca/GraphicsLayerCA.h:
1270         (WebCore::GraphicsLayerCA::LayerPropertyAnimation::LayerPropertyAnimation):
1271
1272 2013-09-17  Eric Carlson  <eric.carlson@apple.com>
1273
1274         MediaStream API: Changing the device enumeration to be async
1275         https://bugs.webkit.org/show_bug.cgi?id=120883
1276
1277         Reviewed by Darin Adler.
1278
1279         Parts merged from https://chromium.googlesource.com/chromium/blink/+/40a96080a1531e50de4eb84571c7dc9fb321ece5
1280         and https://chromium.googlesource.com/chromium/blink/+/ff783a23bb1add588971a8187048a305cf485121
1281         by Tommy Widenflycht.
1282
1283         Test: fast/mediastream/MediaStreamTrack-getSources.html
1284
1285         * CMakeLists.txt: Added new files.
1286         * DerivedSources.make: Ditto.
1287         * GNUmakefile.list.am: Ditto.
1288
1289         * Modules/mediastream/MediaStreamTrack.cpp:
1290         (WebCore::MediaStreamTrack::kind): ASCIILiteral -> NeverDestroyed<AtomicString>.
1291         (WebCore::MediaStreamTrack::readyState): Ditto.
1292         (WebCore::MediaStreamTrack::getSources): New.
1293         * Modules/mediastream/MediaStreamTrack.h:
1294         * Modules/mediastream/MediaStreamTrack.idl:
1295
1296         * Modules/mediastream/MediaStreamTrackSourcesCallback.h: Added.
1297         * Modules/mediastream/MediaStreamTrackSourcesCallback.idl: Added.
1298         * Modules/mediastream/MediaStreamTrackSourcesRequest.cpp: Added.
1299         * Modules/mediastream/MediaStreamTrackSourcesRequest.h: Added.
1300
1301         * Modules/mediastream/SourceInfo.cpp: Added.
1302         * Modules/mediastream/SourceInfo.h: Added.
1303         * Modules/mediastream/SourceInfo.idl: Added.
1304
1305         * WebCore.xcodeproj/project.pbxproj: Add new files.
1306
1307         * bindings/js/JSDOMBinding.h: Add toJS templates for Vector<T> and Vector<RefPtr<T>>.
1308
1309         * platform/mediastream/MediaStreamCenter.h: Add prototype for getMediaStreamTrackSources.
1310
1311         * platform/mediastream/MediaStreamTrackSourcesRequestClient.h: Added.
1312
1313         * platform/mediastream/blackberry/MediaStreamCenterBlackBerry.cpp:
1314         (WebCore::MediaStreamCenterMac::getMediaStreamTrackSources): Added.
1315         * platform/mediastream/blackberry/MediaStreamCenterBlackBerry.h:
1316
1317         * platform/mediastream/gstreamer/MediaStreamCenterGStreamer.cpp:
1318         (WebCore::MediaStreamCenterMac::getMediaStreamTrackSources): Added
1319         * platform/mediastream/gstreamer/MediaStreamCenterGStreamer.h:
1320
1321         * platform/mediastream/mac/MediaStreamCenterMac.cpp:
1322         (WebCore::MediaStreamCenterMac::getMediaStreamTrackSources): Added.
1323         * platform/mediastream/mac/MediaStreamCenterMac.h:
1324
1325 2013-09-17  Commit Queue  <commit-queue@webkit.org>
1326
1327         Unreviewed, rolling out r155976.
1328         http://trac.webkit.org/changeset/155976
1329         https://bugs.webkit.org/show_bug.cgi?id=121512
1330
1331         Broke a test, needs cleanup (Requested by ap_ on #webkit).
1332
1333         * accessibility/AXObjectCache.cpp:
1334         (WebCore::AXObjectCache::handleAttributeChanged):
1335         * accessibility/AXObjectCache.h:
1336         * accessibility/mac/AXObjectCacheMac.mm:
1337         (WebCore::AXObjectCache::postPlatformNotification):
1338
1339 2013-09-17  Romain Perier  <romain.perier@gmail.com>
1340
1341         Improve srcset parser
1342         https://bugs.webkit.org/show_bug.cgi?id=119423
1343
1344         Reviewed by Benjamin Poulain.
1345
1346         Added new tests and covered by existing ones.
1347
1348         * html/parser/HTMLParserIdioms.cpp:
1349         (WebCore::isHTMLSpaceOrComma): Add a new predicate function used by String::find()
1350         to get the first space or comma character from the input string.
1351         (WebCore::parseImagesWithScaleFromSrcSetAttribute): Add a new static function to parse
1352         and extract images with scale from the srcset attribute. All valid candidates are
1353         returned to the caller through a list. This parsing function also adds support
1354         for data URI schemes as described by the specification.
1355         (WebCore::bestFitSourceForImageAttributes): Remove intermediate arrays of string
1356         when parsing. That is more efficient and avoids trashing the data cache
1357         (varying between 20 and 65% faster depending of the amount of data)
1358         The parser now walks along the attribute value and extracts the candidates directly.
1359
1360 2013-09-17  Gustavo Noronha Silva  <gns@gnome.org>
1361
1362         Unreviewed build fix after 155963.
1363
1364         * platform/gtk/RenderThemeGtk3.cpp:
1365         (WebCore::getStyleContext): use nullptr instead of 0.
1366
1367 2013-09-17  Alexey Proskuryakov  <ap@apple.com>
1368
1369         Make SVGTransform::valueAsString use StringBuilder
1370         https://bugs.webkit.org/show_bug.cgi?id=121498
1371
1372         Unreviewed typo fix, should address a regression on svg/dom/SVGViewSpec.html.
1373
1374         * svg/SVGTransform.cpp: (WebCore::SVGTransform::valueAsString): "e" is totally
1375         not the same as "f".
1376
1377 2013-09-16  Simon Fraser  <simon.fraser@apple.com>
1378
1379         Hardware accelerated CSS transitions appear pixelated when scaled up using transform
1380         https://bugs.webkit.org/show_bug.cgi?id=27684
1381         <rdar://problem/6134606>
1382
1383         Reviewed by Dean Jackson.
1384         
1385         Take transforms and animations into account when computing the contentsScale
1386         for a layer, so that scaled-up layers remain sharp most of the time.
1387         
1388         In its recursiveCommitChanges() tree walk, GraphicsLayerCA now tracks
1389         a root-relative transform, and extracts from that transform the X and Y
1390         scales which it uses to scale the backing store.
1391         
1392         If the layer has transform animations on it, we keep around
1393         a transformation matrix for the animation endpoints (or keyframes),
1394         pick up the state that has the larger impact on the root-relative scale,
1395         and use that as the layer's transform, and the transform when recursing
1396         over descendants.
1397
1398         Tests: compositing/contents-scale/animating.html
1399                compositing/contents-scale/scaled-ancestor.html
1400                compositing/contents-scale/simple-scale.html
1401                compositing/contents-scale/z-translate.html
1402
1403         * platform/graphics/ca/GraphicsLayerCA.cpp:
1404         (WebCore::maxScaleFromTransform): Decompose the transform if necesssary
1405         to extract the X and Y scale components.
1406         (WebCore::GraphicsLayerCA::GraphicsLayerCA): Initialize m_rootRelativeScaleFactor.
1407         (WebCore::GraphicsLayerCA::flushCompositingState): Supply a TransformationMatrix
1408         for the root of the recursion.
1409         (WebCore::GraphicsLayerCA::layerTransform): This code was factored out of
1410         computeVisibleRect(), and optionally takes a custom transform.
1411         (WebCore::GraphicsLayerCA::computeVisibleRect): Use the layerTransform() function.
1412         (WebCore::GraphicsLayerCA::updateRootRelativeScale): Given a transform from the root,
1413         find the max scale factor by multiplying the various animation endpoint matrices and picking
1414         the one with the biggest impact on scale. Use this to set m_rootRelativeScaleFactor, and
1415         set the flag to say that we need to update contentsScale.
1416         (WebCore::GraphicsLayerCA::recursiveCommitChanges):
1417         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): After updating
1418         animations, call updateRootRelativeScale() to update m_rootRelativeScaleFactor.
1419         (WebCore::GraphicsLayerCA::updateAnimations): We have a side table of animation name to
1420         TransformationMatrix, so figure out which entries can be removed from that side table,
1421         and remove them.
1422         (WebCore::GraphicsLayerCA::setAnimationOnLayer):
1423         (WebCore::GraphicsLayerCA::appendToUncommittedAnimations): Store the matrices for
1424         animation endpoints/keyframes in the m_animationTransforms side table. We don't store
1425         them directly in LayerPropertyAnimation because we just want the final matrix for
1426         a transform list, and using a side table makes ownership easier to manage.
1427         (WebCore::GraphicsLayerCA::getTransformFromAnimationsWithMaxScaleImpact):
1428         goes through the matrices for the running animation endpoints/keyframes, and
1429         multiplies each with the transform up to this layer to find the matrix with the
1430         larger impact on scale.
1431         (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints): Returns a vector
1432         of TransformationMatrix for the from and to states.
1433         (WebCore::GraphicsLayerCA::setTransformAnimationKeyframes): Returns a vector
1434         of TransformationMatrix for the keyframes.
1435         (WebCore::GraphicsLayerCA::updateContentsScale): Include m_rootRelativeScaleFactor in the
1436         scale factor computation.
1437         (WebCore::GraphicsLayerCA::dumpAdditionalProperties): If we're dumping visible rects,
1438         also dump the contentsScale. Convenient at these are useful to look at together, and I didn't
1439         want to pollute Internals with yet more flags.
1440         * platform/graphics/ca/GraphicsLayerCA.h:
1441         (WebCore::GraphicsLayerCA::LayerPropertyAnimation::LayerPropertyAnimation): Formatting.
1442
1443 2013-09-17  Samuel White  <samuel_white@apple.com>
1444
1445         AX: Expose ARIA Busy Notifications
1446         https://bugs.webkit.org/show_bug.cgi?id=121451
1447
1448         Reviewed by Darin Adler.
1449
1450         Added AXElementBusyChanged notification that posts when aria-busy is toggled. This
1451         enables screen readers to detect busy states without polling the focused element.
1452
1453         Test: platform/mac/accessibility/element-busy-changed.html
1454
1455         * accessibility/AXObjectCache.cpp:
1456         (WebCore::AXObjectCache::handleAttributeChanged):
1457         * accessibility/AXObjectCache.h:
1458         * accessibility/mac/AXObjectCacheMac.mm:
1459         (WebCore::AXObjectCache::postPlatformNotification):
1460
1461 2013-09-17  Antti Koivisto  <antti@apple.com>
1462
1463         Add isTextOrBR() and use it
1464         https://bugs.webkit.org/show_bug.cgi?id=121506
1465
1466         Reviewed by Darin Adler.
1467
1468         It is a popular test.
1469
1470         * dom/Document.cpp:
1471         (WebCore::Document::updateHoverActiveState):
1472         * editing/Editor.cpp:
1473         (WebCore::findFirstMarkable):
1474         * editing/TextIterator.cpp:
1475         (WebCore::ignoresContainerClip):
1476         * rendering/InlineBox.cpp:
1477         (WebCore::InlineBox::logicalHeight):
1478         * rendering/InlineIterator.h:
1479         (WebCore::isIteratorTarget):
1480         * rendering/RenderBlock.cpp:
1481         (WebCore::InlineMinMaxIterator::next):
1482         * rendering/RenderBlockLineLayout.cpp:
1483         (WebCore::RenderBlockFlow::layoutInlineChildren):
1484         * rendering/RenderCounter.cpp:
1485         (WebCore::planCounter):
1486         * rendering/RenderObject.h:
1487         (WebCore::RenderObject::isTextOrBR):
1488         * rendering/RenderTreeAsText.cpp:
1489         (WebCore::write):
1490         * rendering/RootInlineBox.cpp:
1491         (WebCore::RootInlineBox::ascentAndDescentForBox):
1492         (WebCore::RootInlineBox::verticalPositionForBox):
1493
1494 2013-09-17  Antti Koivisto  <antti@apple.com>
1495
1496         RenderBR should not be RenderText
1497         https://bugs.webkit.org/show_bug.cgi?id=121221
1498
1499         Rubber-stamped by Andreas Kling.
1500         
1501         Fix assertion in these tests:
1502
1503         fast/repaint/selection-rl.html
1504         fast/writing-mode/horizontal-bt-replaced-selection.html
1505         fast/writing-mode/vertical-rl-replaced-selection.html
1506
1507         * rendering/InlineBox.cpp:
1508         (WebCore::InlineBox::nodeAtPoint):
1509
1510 2013-09-16  Enrica Casucci  <enrica@apple.com>
1511
1512         Remove unused function didSetSelectionTypesForPasteboard from EditorClient.
1513         https://bugs.webkit.org/show_bug.cgi?id=121464
1514
1515         Reviewed by Darin Adler.
1516
1517         This method was only implemented in WebEditorClient.mm for Mac where it was
1518         calling a private delegate that is no longer in use.
1519         This patch removes it for all the platforms.
1520         I've also removed setTypes and writeAfterSettingTypes from the implementation
1521         of the Pasteboard class for Mac.
1522
1523         * editing/mac/EditorMac.mm:
1524         (WebCore::Editor::writeSelectionToPasteboard): Now calls write instead of
1525         setTypes and writeAfterSettingTypes.
1526         * loader/EmptyClients.h: Removed didSetSelectionTypesForPasteboard.
1527         * page/EditorClient.h: Ditto.
1528         * platform/Pasteboard.h: Removed setTypes and writeAfterSettingTypes.
1529         * platform/ios/PasteboardIOS.mm:
1530         (WebCore::Pasteboard::writeSelection): Removed call to didSetSelectionTypesForPasteboard.
1531         * platform/mac/PasteboardMac.mm:
1532         (WebCore::Pasteboard::write): Added to replace setTypes and writeAfterSettingTypes.
1533
1534 2013-09-17  Darin Adler  <darin@apple.com>
1535
1536         Further shrink table-populating code by making the tables read-only data and preventing inlining
1537         https://bugs.webkit.org/show_bug.cgi?id=121468
1538
1539         Reviewed by Sam Weinig.
1540
1541         * bindings/scripts/StaticString.pm:
1542         (GenerateStrings): Eliminated the xxxImpl globals. We definitely did not need
1543         globals for these, much less read-write data. Instead, write the expression at
1544         each site where we need them.
1545         (GenerateStringAsserts): This is one such site (see above).
1546         * css/CSSSelector.cpp:
1547         (WebCore::populatePseudoTypeByNameMap): Mark this function NEVER_INLINE and
1548         add static to make sure the table ends up in read-only data.
1549         * dom/make_names.pl:
1550         (printDefinitions): Write the xxxImpl expression (see above).
1551         (printFactoryCppFile): Ditto. Also mark the populate function NEVER_INLINE and
1552         add static to make sure the table ends up in read-only data.
1553         (printWrapperFactoryCppFile): Ditto.
1554         * html/HTMLElement.cpp:
1555         (WebCore::populateEventNameForAttributeLocalNameMap): Mark this function
1556         NEVER_INLINE and add static to makes sure the table ends up in read-only data.
1557
1558         * platform/text/UnicodeRange.cpp: Added a const to make this read-only data.
1559
1560 2013-09-17  Darin Adler  <darin@apple.com>
1561
1562         Shrink SVGElement::cssPropertyIdForSVGAttributeName and cssPropertyToTypeMap
1563         https://bugs.webkit.org/show_bug.cgi?id=121499
1564
1565         Reviewed by Andreas Kling.
1566
1567         * svg/SVGElement.cpp:
1568         (WebCore::populateAttributeNameToCSSPropertyIDMap): Added. Code that used to
1569         be in SVGElement::cssPropertyIdForSVGAttributeName to build a map that maps
1570         attribute names to CSS property IDs, but without the multiple unrolled calls
1571         to HashMap functions.
1572         (WebCore::populateAttributeNameToAnimatedPropertyTypeMap): Added. Code that
1573         used to be in cssPropertyToTypeMap, but without the multiple unrolled calls
1574         to HashMap functions.
1575         (WebCore::attributeNameToAnimatedPropertyTypeMap): Renamed from
1576         cssPropertyToTypeMap, a confusingly inaccurate and imprecise name, and
1577         reimplemented using the populate function.
1578         (WebCore::SVGElement::animatedPropertyTypeForAttribute): Updated to call
1579         attributeNameToAnimatedPropertyTypeMap, and also removed the double hashing
1580         that was done by calling contains followed by get.
1581         (WebCore::SVGElement::cssPropertyIdForSVGAttributeName): Rewrote to use
1582         populateAttributeNameToCSSPropertyIDMap.
1583         (WebCore::SVGElement::isAnimatableCSSProperty): Updated to call the new
1584         attributeNameToAnimatedPropertyTypeMap.
1585
1586 2013-09-17  Darin Adler  <darin@apple.com>
1587
1588         Make SVGTransform::valueAsString use StringBuilder
1589         https://bugs.webkit.org/show_bug.cgi?id=121498
1590
1591         Reviewed by Andreas Kling.
1592
1593         * svg/SVGTransform.cpp:
1594         (WebCore::SVGTransform::valueAsString): Use StringBuilder constently to
1595         avoid creating temporary String objects that cause additional, slow
1596         memory allocation.
1597
1598 2013-09-17  Darin Adler  <darin@apple.com>
1599
1600         Get rid of a couple unneeded NeverDestroyed::get() calls
1601         https://bugs.webkit.org/show_bug.cgi?id=121500
1602
1603         Reviewed by Andreas Kling.
1604
1605         * css/CSSSelector.cpp:
1606         (WebCore::CSSSelector::parsePseudoType): No need to call get() here.
1607         * dom/make_names.pl:
1608         (printFactoryCppFile): Ditto.
1609         (printWrapperFactoryCppFile): Ditto.
1610
1611 2013-09-17  Hans Muller  <hmuller@adobe.com>
1612
1613         Bad ASSERT() in RasterShapeIntervals::firstIncludedIntervalY()
1614         https://bugs.webkit.org/show_bug.cgi?id=121455
1615
1616         Reviewed by Darin Adler.
1617
1618         Corrected a bad ASSERT() introduced in https://bugs.webkit.org/show_bug.cgi?id=120211.
1619
1620         Test: fast/shapes/shape-inside/shape-inside-first-fit-crash.html
1621
1622         * rendering/shapes/RasterShape.cpp:
1623         (WebCore::RasterShapeIntervals::firstIncludedIntervalY):
1624
1625 2013-09-16  David Hyatt  <hyatt@apple.com>
1626
1627         Move the line widow functions out of RenderBlock and into RenderBlockFlow.
1628         https://bugs.webkit.org/show_bug.cgi?id=121456
1629
1630         Reviewed by Dean Jackson.
1631
1632         * rendering/RenderBlock.cpp:
1633         * rendering/RenderBlock.h:
1634         (WebCore::RenderBlock::RenderBlockRareData::RenderBlockRareData):
1635         * rendering/RenderBlockFlow.cpp:
1636         (WebCore::RenderBlockFlow::layoutBlockChild):
1637         (WebCore::calculateMinimumPageHeight):
1638         (WebCore::RenderBlockFlow::adjustLinePositionForPagination):
1639         (WebCore::RenderBlockFlow::setBreakAtLineToAvoidWidow):
1640         (WebCore::RenderBlockFlow::clearShouldBreakAtLineToAvoidWidow):
1641         (WebCore::RenderBlockFlow::relayoutToAvoidWidows):
1642         * rendering/RenderBlockFlow.h:
1643         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::RenderBlockFlowRareData):
1644         (WebCore::RenderBlockFlow::shouldBreakAtLineToAvoidWidow):
1645         (WebCore::RenderBlockFlow::lineBreakToAvoidWidow):
1646         * rendering/RenderBlockLineLayout.cpp:
1647         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
1648         (WebCore::RenderBlock::linkToEndLineIfNeeded):
1649         (WebCore::RenderBlock::determineStartPosition):
1650         (WebCore::RenderBlock::checkPaginationAndFloatsAtEndLine):
1651         * rendering/RenderObject.h:
1652
1653 2013-09-16  Anders Carlsson  <andersca@apple.com>
1654
1655         HashMap should work with move-only keys
1656         https://bugs.webkit.org/show_bug.cgi?id=121310
1657
1658         Reviewed by Darin Adler.
1659
1660         Update the call sites now that HashMap::take doesn't return a PassOwnPtr.
1661
1662         * rendering/RenderRegion.cpp:
1663         (WebCore::RenderRegion::takeRenderBoxRegionInfo):
1664         * rendering/RenderRegion.h:
1665         * rendering/svg/RenderSVGResourceContainer.cpp:
1666         (WebCore::RenderSVGResourceContainer::registerResource):
1667         * svg/SVGDocumentExtensions.cpp:
1668         (WebCore::SVGDocumentExtensions::removePendingResource):
1669         (WebCore::SVGDocumentExtensions::removePendingResourceForRemoval):
1670         * svg/SVGDocumentExtensions.h:
1671
1672 2013-09-17  Antti Koivisto  <antti@apple.com>
1673
1674         Add RenderObject bit for isBR().
1675         https://bugs.webkit.org/show_bug.cgi?id=121494
1676
1677         Reviewed by Andreas Kling.
1678
1679         It is no longer piggybacking on isText() flag and is now hot in inline layout.
1680
1681         * rendering/RenderBR.cpp:
1682         (WebCore::RenderBR::RenderBR):
1683         * rendering/RenderBR.h:
1684         * rendering/RenderObject.h:
1685         (WebCore::RenderObject::isBR):
1686         (WebCore::RenderObject::setIsBR):
1687         (WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
1688
1689 2013-09-17  Andreas Kling  <akling@apple.com>
1690
1691         Export some missing symbols for Internals after RenderArena& change.
1692
1693         * WebCore.exp.in:
1694
1695 2013-09-17  Christophe Dumez  <ch.dumez@sisa.samsung.com>
1696
1697         Set MessageEvent.source to the newly created port for shared workers' connect events
1698         https://bugs.webkit.org/show_bug.cgi?id=121390
1699
1700         Reviewed by Darin Adler.
1701
1702         Set MessageEvent.source to the newly created port for shared workers' connect events
1703         instead of previously null, as per the latest specification:
1704         http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#dom-messageevent-source
1705         http://www.whatwg.org/specs/web-apps/current-work/multipage/workers.html#dom-sharedworker
1706
1707         This behavior is consisent with Blink.
1708
1709         Test: fast/workers/shared-worker-messageevent-source.html
1710
1711         * dom/EventTarget.cpp:
1712         (WebCore::EventTarget::isMessagePort):
1713         * dom/EventTarget.h:
1714         * dom/MessageEvent.cpp:
1715         (WebCore::isValidSource):
1716         (WebCore::MessageEvent::MessageEvent):
1717         * dom/MessageEvent.h:
1718         Use null String instead of an empty String as default value for origin and lastEventId.
1719         This is more efficient and has no impact on the behavior on the JavaScript since a
1720         null String is exposed as an empty one on JS side.
1721         This change is covered by fast/events/constructors/message-event-constructor.html
1722         * dom/MessageEvent.idl:
1723         * dom/MessagePort.h:
1724         * page/DOMWindow.cpp:
1725         (WebCore::PostMessageTimer::event):
1726         * workers/SharedWorkerGlobalScope.cpp:
1727         (WebCore::createConnectEvent):
1728
1729 2013-09-17  Antti Koivisto  <antti@apple.com>
1730
1731         RenderBR should not be RenderText
1732         https://bugs.webkit.org/show_bug.cgi?id=121221
1733
1734         Reviewed by Darin Adler.
1735
1736         Stop inheriting RenderBR from RenderText and make it be a RenderBoxModelObject instead. RenderBR was one
1737         of the few cases where Element renderer was a RenderText. This will enable future cleanups.
1738         
1739         RenderBR used little of RenderText mechanisms and was already heavily specialized everywhere. Layout code
1740         didn't care about its text content at all. The new RenderText is also significatly more lightweight
1741         than the old. As a line box it uses plain InlineBox instead of InlineTextBox.
1742         
1743         The patch tries to avoid changing test results though there are a few changed render tree dumps without
1744         visual effect. There are also two rendering progressions.
1745
1746         * accessibility/AccessibilityRenderObject.cpp:
1747         (WebCore::AccessibilityRenderObject::textUnderElement):
1748         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
1749         * dom/ContainerNode.cpp:
1750         (WebCore::ContainerNode::getUpperLeftCorner):
1751         * dom/Document.cpp:
1752         (WebCore::Document::updateHoverActiveState):
1753         * dom/Position.cpp:
1754         (WebCore::hasInlineBoxWrapper):
1755         (WebCore::nextRenderedEditable):
1756         (WebCore::previousRenderedEditable):
1757         (WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
1758         (WebCore::Position::getInlineBoxAndOffset):
1759         * dom/Range.cpp:
1760         (WebCore::Range::textRects):
1761         (WebCore::Range::textQuads):
1762         * editing/ApplyStyleCommand.cpp:
1763         (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown):
1764         * editing/Editor.cpp:
1765         (WebCore::findFirstMarkable):
1766         * editing/TextIterator.cpp:
1767         (WebCore::ignoresContainerClip):
1768         * editing/VisibleUnits.cpp:
1769         (WebCore::CachedLogicallyOrderedLeafBoxes::previousTextOrLineBreakBox):
1770         (WebCore::CachedLogicallyOrderedLeafBoxes::nextTextOrLineBreakBox):
1771         (WebCore::logicallyPreviousBox):
1772         (WebCore::logicallyNextBox):
1773         (WebCore::wordBreakIteratorForMinOffsetBoundary):
1774         (WebCore::wordBreakIteratorForMaxOffsetBoundary):
1775         * rendering/InlineBox.cpp:
1776         (WebCore::InlineBox::logicalHeight):
1777         (WebCore::InlineBox::baselinePosition):
1778         (WebCore::InlineBox::lineHeight):
1779         (WebCore::InlineBox::deleteLine):
1780         (WebCore::InlineBox::extractLine):
1781         (WebCore::InlineBox::attachLine):
1782         (WebCore::InlineBox::paint):
1783         * rendering/InlineBox.h:
1784         (WebCore::InlineBox::isLineBreak):
1785         * rendering/InlineFlowBox.cpp:
1786         (WebCore::InlineFlowBox::computeOverflow):
1787         * rendering/InlineIterator.h:
1788         (WebCore::isIteratorTarget):
1789         * rendering/InlineTextBox.cpp:
1790         (WebCore::InlineTextBox::lineHeight):
1791         (WebCore::InlineTextBox::isLineBreak):
1792         * rendering/RenderBR.cpp:
1793         (WebCore::RenderBR::RenderBR):
1794         (WebCore::RenderBR::~RenderBR):
1795         (WebCore::RenderBR::createAnonymous):
1796         (WebCore::RenderBR::lineHeight):
1797         (WebCore::RenderBR::baselinePosition):
1798         (WebCore::RenderBR::createInlineBox):
1799         (WebCore::RenderBR::setInlineBoxWrapper):
1800         (WebCore::RenderBR::replaceInlineBoxWrapper):
1801         (WebCore::RenderBR::deleteInlineBoxWrapper):
1802         (WebCore::RenderBR::dirtyLineBoxes):
1803         (WebCore::RenderBR::caretMinOffset):
1804         (WebCore::RenderBR::caretMaxOffset):
1805         (WebCore::RenderBR::canBeSelectionLeaf):
1806         (WebCore::RenderBR::setSelectionState):
1807         (WebCore::RenderBR::localCaretRect):
1808         (WebCore::RenderBR::linesBoundingBox):
1809         (WebCore::RenderBR::absoluteRects):
1810         (WebCore::RenderBR::absoluteQuads):
1811         (WebCore::RenderBR::updateFromStyle):
1812         (WebCore::RenderBR::borderBoundingBox):
1813         * rendering/RenderBR.h:
1814         (WebCore::toRenderBR):
1815         * rendering/RenderBlock.cpp:
1816         (WebCore::InlineMinMaxIterator::next):
1817         (WebCore::RenderBlock::updateFirstLetter):
1818         * rendering/RenderBlockLineLayout.cpp:
1819         (WebCore::createInlineBoxForRenderer):
1820         (WebCore::dirtyLineBoxesForRenderer):
1821         (WebCore::reachedEndOfTextRenderer):
1822         (WebCore::RenderBlock::computeBlockDirectionPositionsForLine):
1823         (WebCore::RenderBlockFlow::layoutInlineChildren):
1824         (WebCore::requiresLineBox):
1825         (WebCore::shouldSkipWhitespaceAfterStartObject):
1826         (WebCore::canBreakAtThisPosition):
1827         * rendering/RenderInline.cpp:
1828         (WebCore::RenderInline::generateCulledLineBoxRects):
1829         (WebCore::RenderInline::culledInlineFirstLineBox):
1830         (WebCore::RenderInline::culledInlineLastLineBox):
1831         (WebCore::RenderInline::dirtyLineBoxes):
1832         * rendering/RenderLineBoxList.cpp:
1833         (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
1834         * rendering/RenderMenuList.cpp:
1835         (WebCore::RenderMenuList::RenderMenuList):
1836         (WebCore::RenderMenuList::styleDidChange):
1837         (WebCore::RenderMenuList::setText):
1838         (WebCore::RenderMenuList::text):
1839         * rendering/RenderMenuList.h:
1840         * rendering/RenderObject.h:
1841         (WebCore::RenderObject::isBeforeContent):
1842         (WebCore::RenderObject::isAfterContent):
1843         * rendering/RenderObjectChildList.cpp:
1844         (WebCore::RenderObjectChildList::removeChildNode):
1845         * rendering/RenderText.cpp:
1846         (WebCore::RenderText::removeAndDestroyTextBoxes):
1847         (WebCore::RenderText::computePreferredLogicalWidths):
1848         (WebCore::RenderText::setTextInternal):
1849         * rendering/RenderTreeAsText.cpp:
1850         (WebCore::RenderTreeAsText::writeRenderObject):
1851         * rendering/RootInlineBox.cpp:
1852         (WebCore::RootInlineBox::ascentAndDescentForBox):
1853         (WebCore::RootInlineBox::verticalPositionForBox):
1854
1855 2013-09-17  Andreas Kling  <akling@apple.com>
1856
1857         Dodge more work during render tree teardown.
1858         <https://webkit.org/b/121487>
1859
1860         Reviewed by Antti Koivisto.
1861
1862         Add a Document::hasLivingRenderTree() method that returns true if
1863         there's a render tree attached to the document and it's not in the
1864         process of being torn down.
1865
1866         Deploy this check in a number of places that were only checking
1867         for the presence of a RenderView.
1868
1869 2013-09-17  Eric Carlson  <eric.carlson@apple.com>
1870
1871         MediaStream API: Adding an async RTCPeerConnection::addIceCandidate
1872         https://bugs.webkit.org/show_bug.cgi?id=121403
1873
1874         Merged from https://chromium.googlesource.com/chromium/blink/+/5bd81fda88d48dd2780832246e7d1ab973ee7a1d
1875
1876         Reviewed by Darin Adler.
1877
1878         No new tests, updated RTCPeerConnection-ice.html.
1879
1880         * Modules/mediastream/RTCPeerConnection.cpp:
1881         (WebCore::RTCPeerConnection::addIceCandidate): Add success and error callbacks.
1882         * Modules/mediastream/RTCPeerConnection.h:
1883         * Modules/mediastream/RTCPeerConnection.idl:
1884
1885         * platform/mediastream/RTCPeerConnectionHandler.h: Changed addIceCandidate signature.
1886
1887         * platform/mediastream/RTCVoidRequest.h: Removed ExtraData, it is unnecessary.
1888
1889 2013-09-17  Carlos Garcia Campos  <cgarcia@igalia.com>
1890
1891         [GTK] Do not include Returns tag in api doc for methods returning void
1892         https://bugs.webkit.org/show_bug.cgi?id=121488
1893
1894         Reviewed by Philippe Normand.
1895
1896         * bindings/gobject/WebKitDOMCustom.h:
1897         * bindings/scripts/CodeGeneratorGObject.pm:
1898         (GenerateFunction): Only add Returns tag for methods not returning
1899         void.
1900         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
1901         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
1902         * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
1903         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
1904         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:
1905
1906 2013-09-17  Michael Brüning  <michael.bruning@digia.com>
1907
1908         Correct range used for Emoji checks.
1909         https://bugs.webkit.org/show_bug.cgi?id=121486
1910
1911         Reviewed by Allan Sandfeld Jensen.
1912
1913         Found and reported by David Binderman via Qt bug tracker.
1914
1915         The check if a character was in the Emoji range always evaluated to
1916         false due to the upper range limit being lower than the lower limit.
1917
1918         Changed the upper limit to the highest assigned character from the
1919         "Transport and Map Symbols" (0x1F6C5) as that seems to have been the
1920         intended upper range limit of this check.
1921
1922         * platform/graphics/Font.cpp:
1923         (WebCore::Font::isCJKIdeographOrSymbol):
1924
1925 2013-09-17  Antti Koivisto  <antti@apple.com>
1926
1927         Move text caret rect computation to root inline box
1928         https://bugs.webkit.org/show_bug.cgi?id=121479
1929
1930         Reviewed by Andreas Kling.
1931
1932         For future code sharing.
1933
1934         * rendering/RenderText.cpp:
1935         (WebCore::RenderText::localCaretRect):
1936         * rendering/RootInlineBox.cpp:
1937         (WebCore::RootInlineBox::computeCaretRect):
1938         * rendering/RootInlineBox.h:
1939
1940 2013-09-17  Alberto Garcia  <berto@igalia.com>
1941
1942         [GTK] Don't make the GObject DOM bindings API break test fatal
1943         https://bugs.webkit.org/show_bug.cgi?id=121484
1944
1945         Reviewed by Carlos Garcia Campos.
1946
1947         The API varies depending on the compilation options, so this can
1948         easily produce false positives.
1949
1950         Until we figure out a way to handle this situation we shouldn't
1951         make this test fatal.
1952
1953         * bindings/scripts/gobject-run-api-break-test:
1954         (check_api):
1955
1956 2013-09-17  Mihnea Ovidenie  <mihnea@adobe.com>
1957
1958         [CSSRegions] Replace generatingNode() with generatingElement() for RenderRegion
1959         https://bugs.webkit.org/show_bug.cgi?id=121469
1960
1961         Reviewed by Antti Koivisto.
1962
1963         The fix for https://bugs.webkit.org/show_bug.cgi?id=120397 replaced node() with generatingElement() for regions, but i forgot about replacing generatingNode() with generatingElement() in RenderNamedFlowThread::compareRenderRegions. This is needed in preparation for regions as anonymous blocks refactoring in https://bugs.webkit.org/show_bug.cgi?id=119135.
1964
1965         No new functionality introduced, therefore no new tests.
1966
1967         * rendering/RenderNamedFlowThread.cpp:
1968         (WebCore::compareRenderRegions):
1969
1970 2013-09-17  Andreas Kling  <akling@apple.com>
1971
1972         CTTE: Pass RenderArena around by reference.
1973         <https://webkit.org/b/121470>
1974
1975         Reviewed by Antti Koivisto.
1976
1977         Pass the RenderArena around by reference in all render tree code.
1978         This code will never be running without an arena.
1979
1980 2013-09-17  Carlos Garcia Campos  <cgarcia@igalia.com>
1981
1982         [GTK] GObject DOM symbols file is not generated for video related classes
1983         https://bugs.webkit.org/show_bug.cgi?id=121476
1984
1985         Reviewed by Philippe Normand.
1986
1987         The problem is that we are using a different path for video
1988         related header files in the Makefile, it's the same path in
1989         practice, because we are just prepending ./ to the path, but the
1990         rules that parse those paths don't expect the ./ at the beginning.
1991
1992         * bindings/gobject/GNUmakefile.am: Use the same path for video
1993         related header files as the other paths in
1994         webkitgtk_gdom_built_h_api.
1995         * bindings/gobject/webkitdom.symbols: Updated to include the
1996         symbols of the video related clases.
1997
1998 2013-09-17  Andreas Kling  <akling@apple.com>
1999
2000         Remove ContextFeatures.
2001         <https://webkit.org/b/121473>
2002
2003         Reviewed by Antti Koivisto.
2004
2005         This was only used by the chromium port, nobody implements ContextFeaturesClient.
2006
2007 2013-09-17  Andreas Kling  <akling@apple.com>
2008
2009         Un-dork the build. :|
2010
2011 2013-09-17  Andreas Kling  <akling@apple.com>
2012
2013         Unreviewed, fix clang warning when building without ENABLE(STYLE_SCOPED).
2014
2015 2013-09-08  Andreas Kling  <akling@apple.com>
2016
2017         Move <style scoped> code behind ENABLE(STYLE_SCOPED)
2018         <https://webkit.org/b/121018>
2019
2020         Reviewed by Darin Adler.
2021
2022         Move all the code for <style scoped> behind ENABLE(STYLE_SCOPED) guards.
2023         It's not nice to clutter common codepaths with code that always executes
2024         even though the feature is disabled at compile-time.
2025
2026 2013-09-16  Sam Weinig  <sam@webkit.org>
2027
2028         CTTE: InputType should store its HTMLInputElement back pointer as a reference
2029         https://bugs.webkit.org/show_bug.cgi?id=121466
2030
2031         Reviewed by Anders Carlsson.
2032
2033         - Converts InputType::create() and InputType::createText() to take a HTMLInputElement&
2034           (as well as all the subclasses).
2035         - Change InputType::element() to return an HTMLInputElement& and update all the callers.
2036
2037 2013-09-16  Timothy Hatcher  <timothy@apple.com>
2038
2039         Make InspectorTimelineAgent use an enum for the record type instead of a string.
2040
2041         https://bugs.webkit.org/show_bug.cgi?id=121461
2042
2043         Reviewed by Joseph Pecoraro.
2044
2045         * inspector/Inspector.json:
2046         * inspector/InspectorTimelineAgent.cpp:
2047         (WebCore::InspectorTimelineAgent::addRecordToTimeline):
2048         (WebCore::toProtocol):
2049         (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline):
2050         (WebCore::InspectorTimelineAgent::didCompleteCurrentRecord):
2051         (WebCore::InspectorTimelineAgent::appendRecord):
2052         (WebCore::InspectorTimelineAgent::pushCurrentRecord):
2053         * inspector/InspectorTimelineAgent.h:
2054         (WebCore::InspectorTimelineAgent::TimelineRecordEntry::TimelineRecordEntry):
2055
2056 2013-09-16  Joseph Pecoraro  <pecoraro@apple.com>
2057
2058         Add RunLoop::isMain and use it in WebKit2
2059         https://bugs.webkit.org/show_bug.cgi?id=121459
2060
2061         Reviewed by Anders Carlsson.
2062
2063         * WebCore.exp.in:
2064         * platform/RunLoop.cpp:
2065         (WebCore::RunLoop::isMain):
2066         * platform/RunLoop.h:
2067
2068 2013-09-16  Chris Fleizach  <cfleizach@apple.com>
2069
2070         AX: ARIA tablist is disabled, but VoiceOver does not speak the tabs as dimmed
2071         https://bugs.webkit.org/show_bug.cgi?id=121408
2072
2073         Reviewed by Darin Adler.
2074
2075         ARIA says that aria-disabled should propagate to children nodes.
2076
2077         Test: accessibility/aria-disabled-propagated-to-children.html
2078
2079         * accessibility/AccessibilityNodeObject.cpp:
2080         (WebCore::AccessibilityNodeObject::isEnabled):
2081
2082 2013-09-16  Sam Weinig  <sam@webkit.org>
2083
2084         CTTE: Element::createRenderer() should take references
2085         https://bugs.webkit.org/show_bug.cgi?id=121449
2086
2087         Reviewed by Anders Carlsson.
2088
2089         *Many file elided*
2090
2091 2013-09-16  Enrica Casucci  <enrica@apple.com>
2092
2093         iOS build fix after r155638.
2094
2095         Unreviewed.
2096
2097         * editing/Editor.cpp:
2098
2099 2013-09-16  Bem Jones-Bey  <bjonesbe@adobe.com>
2100
2101         Make FloatingObjects own it's FloatingObject instances
2102         https://bugs.webkit.org/show_bug.cgi?id=121323
2103
2104         Reviewed by Alexandru Chiculita.
2105
2106         As part of decoupling FloatingObjects from RenderBlock, change
2107         FloatingObjects to properly manage the FloatingObject instances it
2108         contains.
2109
2110         No new tests, no behavior change.
2111
2112         * rendering/FloatingObjects.cpp:
2113         (WebCore::FloatingObject::FloatingObject): Make the constructors
2114         private so that FloatingObjects can only be created with an OwnPtr.
2115         Also make a RenderBox required to create a FloatingObject.
2116         (WebCore::FloatingObject::create): Factory method to create a vanilla
2117         FloatingObject.
2118         (WebCore::FloatingObject::copyToNewContainer): Factory method to copy
2119         an existing FloatingObject in the case it is overhanging or intruding
2120         and needs to be copied to the block that it overhangs or intrudes
2121         into.
2122         (WebCore::FloatingObject::unsafeClone): Rename this method so it is
2123         more obvious that it really shouldn't be used, and to make it more
2124         obvious that one should use the copyToNewContainer method for all
2125         normal FloatingObject copies.
2126         (WebCore::FloatingObjects::clear): Delete all the FloatingObjects in
2127         the set before clearing it.
2128         (WebCore::FloatingObjects::moveAllToFloatInfoMap): Move all of the
2129         FloatingObjects in the set to a RendererToFloatInfoMap. This is used
2130         in RenderBlockFlow::clearFloats to when it is readding floats after
2131         clearing the set.
2132         (WebCore::FloatingObjects::add): Take an OwnPtr.
2133         (WebCore::FloatingObjects::remove): Delete the removed FloatingObject.
2134         * rendering/FloatingObjects.h: Remove FloatingObject::setRenderer(),
2135         since the RenderBox must be set in the constructor.
2136         * rendering/RenderBlock.cpp:
2137         (WebCore::RenderBlock::moveAllChildrenIncludingFloatsTo): Rename clone
2138         to unsafeClone.
2139         (WebCore::RenderBlock::removeFloatingObjects): Don't delete anymore,
2140         since clear does it.
2141         (WebCore::RenderBlock::insertFloatingObject): Handle OwnPtr properly.
2142         (WebCore::RenderBlock::removeFloatingObject): Don't delete anymore,
2143         since remove does it.
2144         (WebCore::RenderBlock::removeFloatingObjectsBelow): Ditto.
2145         (WebCore::RenderBlock::addOverhangingFloats): Use copyToNewContainer
2146         and OwnPtr.
2147         (WebCore::RenderBlock::addIntrudingFloats): Ditto.
2148         * rendering/RenderBlockFlow.cpp:
2149         (WebCore::RenderBlockFlow::clearFloats): Use exportToFloatInfoMap.
2150
2151 2013-09-16  Hugo Parente Lima  <hugo.lima@openbossa.org>
2152
2153         Fix creation of embedded JS and CSS files on cmake based ports.
2154         https://bugs.webkit.org/show_bug.cgi?id=121448
2155
2156         Reviewed by Joseph Pecoraro.
2157
2158         Just a build fix, layout tests already test this issue.
2159
2160         * CMakeLists.txt:
2161
2162 2013-09-16  Anders Carlsson  <andersca@apple.com>
2163
2164         MessageQueue should use a Deque of OwnPtrs
2165         https://bugs.webkit.org/show_bug.cgi?id=121450
2166
2167         Reviewed by Andreas Kling.
2168
2169         * Modules/webdatabase/DatabaseThread.cpp:
2170         (WebCore::SameDatabasePredicate::operator()):
2171         * dom/default/PlatformMessagePortChannel.h:
2172         (WebCore::PlatformMessagePortChannel::MessagePortQueue::tryGetMessage):
2173         * fileapi/FileThread.cpp:
2174         (WebCore::SameInstancePredicate::operator()):
2175         * workers/WorkerRunLoop.cpp:
2176         (WebCore::ModePredicate::operator()):
2177
2178 2013-09-16  Andreas Kling  <akling@apple.com>
2179
2180         CTTE: FrameTree::top() should return a reference.
2181         <https://webkit.org/b/121445>
2182
2183         Reviewed by Anders Carlsson.
2184
2185         There's always a top frame in the tree.
2186
2187 2013-09-16  Zan Dobersek  <zdobersek@igalia.com>
2188
2189         Unreviewed, fixing GObject bindings tests after r155850 by adding the *.symbols files that are now also generated.
2190
2191         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.symbols: Added.
2192         * bindings/scripts/test/GObject/WebKitDOMTestCallback.symbols: Added.
2193         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.symbols: Added.
2194         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.symbols: Added.
2195         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.symbols: Added.
2196         * bindings/scripts/test/GObject/WebKitDOMTestException.symbols: Added.
2197         * bindings/scripts/test/GObject/WebKitDOMTestInterface.symbols: Added.
2198         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.symbols: Added.
2199         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.symbols: Added.
2200         * bindings/scripts/test/GObject/WebKitDOMTestNode.symbols: Added.
2201         * bindings/scripts/test/GObject/WebKitDOMTestObj.symbols: Added.
2202         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.symbols: Added.
2203         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.symbols: Added.
2204         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.symbols: Added.
2205
2206 2013-09-16  Daniel Bates  <dabates@apple.com>
2207
2208         Fix the build following <http://trac.webkit.org/changeset/155591>
2209         (https://bugs.webkit.org/show_bug.cgi?id=121200)
2210
2211         Fix the build for ports that enable PLUGIN_PROXY_FOR_VIDEO, such as iOS WebKit.
2212
2213         * html/shadow/MediaControlElements.cpp:
2214         (WebCore::MediaControlTextTrackContainerElement::updateSizes): Substitute isWidget() for isRenderWidget()
2215         as the latter is undefined.
2216         * rendering/RenderLayerCompositor.cpp:
2217         (WebCore::RenderLayerCompositor::requiresCompositingForVideo): Ditto.
2218
2219 2013-09-16  Daniel Bates  <dabates@apple.com>
2220
2221         Build fix following <https://trac.webkit.org/r154358>
2222         (https://bugs.webkit.org/show_bug.cgi?id=120078)
2223
2224         Fix the build for ports that enable PLUGIN_PROXY_FOR_VIDEO, such as iOS WebKit.
2225
2226         * html/HTMLMediaElement.cpp:
2227         (WebCore::HTMLMediaElement::rendererIsNeeded): Substitute "style" for "context".
2228
2229 2013-09-16  Timothy Hatcher  <timothy@apple.com>
2230
2231         Make InspectorTypeBuilder generate better enums in C++.
2232
2233         https://bugs.webkit.org/show_bug.cgi?id=121440
2234
2235         Reviewed by Joseph Pecoraro.
2236
2237         * inspector/CodeGeneratorInspector.py:
2238         (fix_camel_case): Add more abbrivations.
2239         (TypeBindings.create_type_declaration_.EnumBinding.get_code_generator.CodeGenerator.generate_type_builder): Use fix_camel_case
2240         * inspector/ConsoleMessage.cpp:
2241         (WebCore::messageSourceValue):
2242         (WebCore::messageTypeValue):
2243         * inspector/InspectorCSSAgent.cpp:
2244         (WebCore::InspectorCSSAgent::detectOrigin):
2245         * inspector/InspectorRuntimeAgent.cpp:
2246         (WebCore::InspectorRuntimeAgent::parse):
2247         * inspector/InspectorStyleSheet.cpp:
2248         (WebCore::InspectorStyleSheet::resourceStyleSheetText):
2249         * inspector/InspectorStyleSheet.h:
2250         (WebCore::InspectorStyleSheet::canBind):
2251
2252 2013-09-16  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
2253
2254         MediaStream API: Storing the constraints in MediaStreamSource
2255         https://bugs.webkit.org/show_bug.cgi?id=120882
2256
2257         based on: https://chromium.googlesource.com/chromium/blink/+/04ac7655b54ae98f55774afde3f8e92b6c6302e6
2258
2259         Reviewed by Eric Carlson.
2260
2261         No new tests needed.
2262
2263         * Modules/mediastream/UserMediaRequest.cpp:
2264         (WebCore::UserMediaRequest::succeed):
2265         * platform/mediastream/MediaStreamSource.h:
2266         (WebCore::MediaStreamSource::setConstraints):
2267         (WebCore::MediaStreamSource::constraints):
2268
2269 2013-09-16  Andreas Kling  <akling@apple.com>
2270
2271         Rebaseline bindings tests after Sam's Document& changes.
2272
2273 2013-09-16  Andreas Kling  <akling@apple.com>
2274
2275         Destroying a Document's render tree shouldn't make it impossible to recreate.
2276         <https://webkit.org/b/121437>
2277
2278         Reviewed by Antti Koivisto.
2279
2280         Rename Document::detach() to destroyRenderTree() and stop automatically
2281         disconnecting Document from its Frame after the deforestation.
2282
2283         Added Document::disconnectFromFrame() and do that after every call to
2284         destroyRenderTree() that we currently have.
2285
2286         This change doesn't alter any behavior on its own, but is a step towards
2287         being able to destroy and rebuild the render tree.
2288
2289 2013-09-16  Brent Fulgham  <bfulgham@apple.com>
2290
2291         Unreviewed warning correction. Avoid uninitialized renderer.
2292
2293         * css/CSSComputedStyleDeclaration.cpp:
2294         (WebCore::ComputedStyleExtractor::propertyValue): Renderer can be uninitialized.
2295
2296 2013-09-16  Brent Fulgham  <bfulgham@apple.com>
2297
2298         Unreviewed warning correction.
2299
2300         * css/CSSParser.cpp:
2301         (WebCore::CSSParser::parseFilter): Don't use 'value' as the input argument
2302         to the method, and the internal loop variable for the parser.
2303
2304 2013-09-16  peavo@outlook.com  <peavo@outlook.com>
2305
2306         [Win] Compile errors in WebCore derived sources.
2307         https://bugs.webkit.org/show_bug.cgi?id=121420
2308
2309         Reviewed by Brent Fulgham.
2310
2311         * dom/make_names.pl:
2312         (printNamesCppFile): Added const modifier.
2313         (printDefinitions): Use C style cast.
2314
2315 2013-09-16  Hans Muller  <hmuller@adobe.com>
2316
2317         [CSS Shapes] Winding rule polygon issues
2318         https://bugs.webkit.org/show_bug.cgi?id=120236
2319
2320         Reviewed by Dirk Schulze.
2321
2322         This patch corrects some of the problems with shape-inside and
2323         self-intersecting polygons and eliminates the layout flashing behavior
2324         that prompted the original bug report. The FloatPolygon::contains()
2325         method now respoects the polygon's fillRule and the PolygonShape code
2326         used to find shape-inside intervals for the top and bottom of a line
2327         now also handles fillRule correctly.
2328
2329         Tests: fast/shapes/shape-inside/shape-inside-complex-polygon-001.html
2330                fast/shapes/shape-inside/shape-inside-complex-polygon-002.html
2331                fast/shapes/shape-inside/shape-inside-complex-polygon-003.html
2332                fast/shapes/shape-inside/shape-inside-complex-polygon-004.html
2333
2334         * platform/graphics/FloatPolygon.cpp:
2335         (WebCore::FloatPolygon::containsEvenOdd):
2336         (WebCore::FloatPolygon::containsNonZero):
2337         (WebCore::FloatPolygon::contains):
2338         * platform/graphics/FloatPolygon.h:
2339         * rendering/shapes/PolygonShape.cpp:
2340         (WebCore::computeXIntersections):
2341
2342 2013-09-16  Andreas Kling  <akling@apple.com>
2343
2344         AXObjectCache::m_document should be a reference.
2345         <https://webkit.org/b/121425>
2346
2347         Reviewed by Antti Koivisto.
2348
2349         AXObjectCache is always owned by a Document so remove the uncertainty
2350         by turning its m_document into a Document&.
2351
2352 2013-09-16  Commit Queue  <commit-queue@webkit.org>
2353
2354         Unreviewed, rolling out r155851.
2355         http://trac.webkit.org/changeset/155851
2356         https://bugs.webkit.org/show_bug.cgi?id=121429
2357
2358         checkbox states should be exposed through AtkState, not
2359         AtkValue (Requested by msanchez on #webkit).
2360
2361         * accessibility/atk/WebKitAccessibleInterfaceValue.cpp:
2362         (webkitAccessibleValueGetCurrentValue):
2363         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2364         (getInterfaceMaskFromObject):
2365
2366 2013-09-16  Krzysztof Czech  <k.czech@samsung.com>
2367
2368         [ATK] Extends atk value interface to return proper checkbox states
2369         https://bugs.webkit.org/show_bug.cgi?id=121413
2370
2371         Reviewed by Mario Sanchez Prada.
2372
2373         Tests: accessibility/mixed-checkbox.html
2374                accessibility/native-vs-nonnative-checkboxes.html
2375
2376         * accessibility/atk/WebKitAccessibleInterfaceValue.cpp:
2377         (webkitAccessibleValueValueForAccessibilityObject):
2378         (webkitAccessibleValueGetCurrentValue):
2379         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2380         (getInterfaceMaskFromObject):
2381
2382 2013-09-16  Carlos Garcia Campos  <cgarcia@igalia.com>
2383
2384         [GTK] Check DOM bindings API compatibility while building
2385         https://bugs.webkit.org/show_bug.cgi?id=101224
2386
2387         Reviewed by Gustavo Noronha Silva.
2388
2389         A .symbols file is now generated for every DOM binding public API
2390         object. It contains the signature of all public methods. We keep a
2391         single file with the signature of all public methods in the source
2392         tree. When DOM bindings are generated, a new symbols file is
2393         created concatenating all .symbols files generated and it's
2394         compared with the symbols file in the source tree using a script
2395         that checks if the changes are API compatible or not. In case of
2396         API break the build finishes showing the differences found in the
2397         symbol files. If API compatible changes are found, the diff is
2398         shown in stdout, suggesting to run the gobject-run-api-break-test
2399         with the --reset-results option to update the symbols file, and
2400         the build continues. If there aren't API changes the build
2401         continues silently.
2402
2403         * GNUmakefile.am:
2404         * bindings/gobject/GNUmakefile.am:
2405         * bindings/gobject/WebKitDOMCustom.symbols: Added.
2406         * bindings/gobject/WebKitDOMEventTarget.symbols: Added.
2407         * bindings/gobject/WebKitDOMObject.symbols: Added.
2408         * bindings/gobject/webkitdom.symbols: Added.
2409         * bindings/scripts/CodeGeneratorGObject.pm:
2410         (GenerateFunction):
2411         (WriteData):
2412         * bindings/scripts/gobject-run-api-break-test: Added.
2413         (check_api):
2414
2415 2013-09-16  Andreas Kling  <akling@apple.com>
2416
2417         Devirtualize Document::detach().
2418         <https://webkit.org/b/121418>
2419
2420         Reviewed by Antti Koivisto.
2421
2422         The only override was in PluginDocument which needs to decouple itself
2423         from the plugin element at the start of detach.
2424
2425         Added PluginDocument::detachFromPluginElement() and call it from detach().
2426
2427 2013-09-15  Andreas Kling  <akling@apple.com>
2428
2429         CTTE: RenderCombineText always has a Text node.
2430         <https://webkit.org/b/121411>
2431
2432         Reviewed by Antti Koivisto.
2433
2434         This renderer is never anonymous and always has a corresponding Text node.
2435         Replaced node() with a textNode() reference getter.
2436
2437 2013-09-15  Andreas Kling  <akling@apple.com>
2438
2439         CTTE: RenderSVGInlineText always has a Text node.
2440         <https://webkit.org/b/121409>
2441
2442         Reviewed by Antti Koivisto.
2443
2444         This renderer is never anonymous and always has a corresponding Text node.
2445         Replaced node() with a textNode() reference getter.
2446
2447         Only one null check was harmed in the making of this patch.
2448
2449 2013-09-15  Darin Adler  <darin@apple.com>
2450
2451         Try to fix the Windows build.
2452
2453         * dom/make_names.pl: The static_cast here was running into const-correctness
2454         issues, so for now change it back to a C-style cast.
2455
2456 2013-09-15  Santosh Mahto  <santosh.ma@samsung.com>
2457
2458         Adding "explicit" keyword in rendering related constructors
2459         https://bugs.webkit.org/show_bug.cgi?id=121398
2460
2461         Reviewed by Andreas Kling.
2462
2463         Adding explicit in below constructor.
2464         All files belong to Source/WebCore/rendering/ path.
2465
2466         * rendering/AutoTableLayout.h:
2467         * rendering/ClipPathOperation.h:
2468         (WebCore::ClipPathOperation::ClipPathOperation):
2469         (WebCore::ShapeClipPathOperation::ShapeClipPathOperation):
2470         * rendering/FixedTableLayout.h:
2471         * rendering/FloatingObjects.h:
2472         (WebCore::FloatingObject::FloatingObject):
2473         * rendering/FlowThreadController.h:
2474         * rendering/HitTestResult.h:
2475         * rendering/ImageQualityController.h:
2476         * rendering/InlineBox.h:
2477         (WebCore::InlineBox::InlineBox):
2478         (WebCore::InlineBox::InlineBoxBitfields::InlineBoxBitfields):
2479         * rendering/InlineFlowBox.h:
2480         (WebCore::InlineFlowBox::InlineFlowBox):
2481         * rendering/InlineTextBox.h:
2482         (WebCore::InlineTextBox::InlineTextBox):
2483         * rendering/LayoutState.h:
2484         * rendering/LogicalSelectionOffsetCaches.h:
2485         (WebCore::LogicalSelectionOffsetCaches::LogicalSelectionOffsetCaches):
2486         * rendering/RenderBoxModelObject.h:
2487         * rendering/RenderFlexibleBox.h:
2488         * rendering/RenderFrameSet.h:
2489         (WebCore::FrameEdgeInfo::FrameEdgeInfo):
2490         * rendering/RenderGeometryMap.h:
2491         * rendering/RenderImage.h:
2492         * rendering/RenderImageResourceStyleImage.h:
2493         * rendering/RenderLayerFilterInfo.h:
2494         * rendering/RenderMultiColumnSet.h:
2495         * rendering/RenderNamedFlowThread.h:
2496         * rendering/RenderReplaced.h:
2497         * rendering/RenderSearchField.h:
2498         * rendering/RenderSelectionInfo.h:
2499         (WebCore::RenderSelectionInfoBase::RenderSelectionInfoBase):
2500         (WebCore::RenderBlockSelectionInfo::RenderBlockSelectionInfo):
2501         * rendering/RenderTableSection.h:
2502         * rendering/RenderTextControl.h:
2503         * rendering/RenderTextControlSingleLine.h:
2504         * rendering/TrailingFloatsRootInlineBox.h:
2505
2506 2013-09-15  Gustavo Noronha Silva  <gns@gnome.org>
2507
2508         Unreviewed make distcheck fix.
2509
2510         * GNUmakefile.am:
2511         * GNUmakefile.list.am:
2512
2513 2013-09-15  Patrick Gansterer  <paroga@webkit.org>
2514
2515         [WIN] Fix build without precompiled header after r154146.
2516
2517         * platform/win/WebCoreBundleWin.h:
2518
2519 2013-09-15  Andreas Kling  <akling@apple.com>
2520
2521         CTTE: EllipsisBox owner renderer is always a RenderBlock.
2522         <https://webkit.org/b/121402>
2523
2524         Reviewed by Antti Koivisto.
2525
2526         Let the constructor reflect this. Also out-of-line it because reasons.
2527
2528 2013-09-15  Sam Weinig  <sam@webkit.org>
2529
2530         CTTE: RenderObject's createAnonymous() and setDocumentForAnonymous() should take Document references
2531         https://bugs.webkit.org/show_bug.cgi?id=121400
2532
2533         Reviewed by Andreas Kling.
2534
2535         The Document used for anonymous renderers is never null.
2536
2537         * dom/Document.cpp:
2538         * page/FrameView.cpp:
2539         * rendering/FlowThreadController.cpp:
2540         * rendering/RenderBlock.cpp:
2541         * rendering/RenderBlock.h:
2542         * rendering/RenderFlexibleBox.cpp:
2543         * rendering/RenderFlexibleBox.h:
2544         * rendering/RenderFullScreen.cpp:
2545         * rendering/RenderFullScreen.h:
2546         * rendering/RenderImage.cpp:
2547         * rendering/RenderInline.cpp:
2548         * rendering/RenderInline.h:
2549         * rendering/RenderLayer.cpp:
2550         * rendering/RenderListMarker.cpp:
2551         * rendering/RenderMultiColumnBlock.cpp:
2552         * rendering/RenderMultiColumnFlowThread.cpp:
2553         * rendering/RenderMultiColumnFlowThread.h:
2554         * rendering/RenderMultiColumnSet.cpp:
2555         * rendering/RenderMultiColumnSet.h:
2556         * rendering/RenderNamedFlowThread.cpp:
2557         * rendering/RenderNamedFlowThread.h:
2558         * rendering/RenderObject.h:
2559         * rendering/RenderReplica.cpp:
2560         * rendering/RenderReplica.h:
2561         * rendering/RenderRuby.cpp:
2562         * rendering/RenderRubyBase.cpp:
2563         * rendering/RenderRubyBase.h:
2564         * rendering/RenderRubyRun.cpp:
2565         * rendering/RenderScrollbar.cpp:
2566         * rendering/RenderScrollbarPart.cpp:
2567         * rendering/RenderScrollbarPart.h:
2568         * rendering/RenderTable.cpp:
2569         * rendering/RenderTableCell.cpp:
2570         * rendering/RenderTableCell.h:
2571         * rendering/RenderTableRow.cpp:
2572         * rendering/RenderTableRow.h:
2573         * rendering/RenderTableSection.cpp:
2574         * rendering/RenderText.cpp:
2575         * rendering/RenderView.cpp:
2576         * rendering/RenderView.h:
2577         * rendering/mathml/RenderMathMLBlock.cpp:
2578         * rendering/mathml/RenderMathMLRow.cpp:
2579         * rendering/mathml/RenderMathMLScripts.cpp:
2580
2581 2013-09-15  Sam Weinig  <sam@webkit.org>
2582
2583         CTTE: ContentData::createRenderer() should take references
2584         https://bugs.webkit.org/show_bug.cgi?id=121399
2585
2586         Reviewed by Andreas Kling.
2587
2588         - Convert createRenderer(Document*, RenderStyle*) to createRenderer(Document&, RenderStyle&)
2589         - Do a drive by final-ing of ContentData derived classes.
2590
2591         * dom/PseudoElement.cpp:
2592         (WebCore::PseudoElement::didAttachRenderers):
2593         * rendering/RenderImage.cpp:
2594         (WebCore::RenderImage::createAnonymous):
2595         * rendering/RenderImage.h:
2596         * rendering/style/ContentData.cpp:
2597         (WebCore::ImageContentData::createRenderer):
2598         (WebCore::TextContentData::createRenderer):
2599         (WebCore::CounterContentData::createRenderer):
2600         (WebCore::QuoteContentData::createRenderer):
2601         * rendering/style/ContentData.h:
2602
2603 2013-09-15  Andreas Kling  <akling@apple.com>
2604
2605         CTTE: RenderFrameSet is never anonymous.
2606         <https://webkit.org/b/121396>
2607
2608         Reviewed by Antti Koivisto.
2609
2610         This renderer is never anonymous, and always has a corresponding HTMLFrameSetElement.
2611         Replaced element() with a frameSetElement().
2612
2613 2013-09-15  Sam Weinig  <sam@webkit.org>
2614
2615         CTTE: Node subclasses should take a Document by reference in their constructor (Part 10)
2616         https://bugs.webkit.org/show_bug.cgi?id=121397
2617
2618         Reviewed by Andreas Kling.
2619
2620         Convert the bindings code to pass a Document reference for named constructors.
2621
2622         * bindings/js/JSImageConstructor.cpp:
2623         (WebCore::constructImage):
2624         * bindings/scripts/CodeGeneratorJS.pm:
2625         (GenerateConstructorDefinition):
2626         * html/HTMLAudioElement.cpp:
2627         (WebCore::HTMLAudioElement::createForJSConstructor):
2628         * html/HTMLAudioElement.h:
2629         * html/HTMLImageElement.cpp:
2630         (WebCore::HTMLImageElement::createForJSConstructor):
2631         * html/HTMLImageElement.h:
2632         * html/HTMLOptionElement.cpp:
2633         (WebCore::HTMLOptionElement::createForJSConstructor):
2634         * html/HTMLOptionElement.h:
2635
2636 2013-09-15  Sam Weinig  <sam@webkit.org>
2637
2638         CTTE: Node subclasses should take a Document by reference in their constructor (Part 9)
2639         https://bugs.webkit.org/show_bug.cgi?id=121394
2640
2641         Reviewed by Andreas Kling.
2642
2643         Remove the 'constructorTakesDocumentReference' property. It is the default now.
2644
2645         * dom/make_names.pl:
2646         Always use a Document reference.
2647
2648         * html/HTMLTagNames.in:
2649         * mathml/mathtags.in:
2650         * svg/svgtags.in:
2651         Remove the 'constructorTakesDocumentReference' property.
2652
2653 2013-09-15  Andreas Kling  <akling@apple.com>
2654
2655         RenderWidget doesn't need to cache a FrameView pointer.
2656         <https://webkit.org/b/121158>
2657
2658         Reviewed by Antti Koivisto.
2659
2660         The FrameView can be found through RenderObject::view().frameView().
2661         This way also gets you a reference, so no need for null-checking.
2662
2663 2013-09-15  Sam Weinig  <sam@webkit.org>
2664
2665         CTTE: Node subclasses should take a Document by reference in their constructor (Part 8)
2666         https://bugs.webkit.org/show_bug.cgi?id=121393
2667
2668         Reviewed by Andreas Kling.
2669
2670         Converts the following to take a Document reference:
2671             - All of SVG
2672
2673 2013-09-15  Sam Weinig  <sam@webkit.org>
2674
2675         [CTTE] Node subclasses should take a Document by reference in their constructor (Part 7)
2676         https://bugs.webkit.org/show_bug.cgi?id=121389
2677
2678         Reviewed by Andreas Kling.
2679
2680         Converts the following to take a Document reference:
2681             - Element
2682             - MathMLElement
2683             - MathMLInlineContainerElement
2684             - MathMLMathElement
2685             - MathMLTextElement
2686
2687 2013-09-15  Andreas Kling  <akling@apple.com>
2688
2689         CTTE: RenderMedia and RenderVideo are never anonymous.
2690         <https://webkit.org/b/121388>
2691
2692         Reviewed by Sam Weinig.
2693
2694         Codify the following:
2695
2696         - RenderMedia always has an HTMLMediaElement.
2697         - RenderVideo always has an HTMLVideoElement.
2698
2699         None of these renderers are ever anonymous, so delete element() and provide
2700         strongly typed reference getters instead.
2701
2702 2013-09-15  Andreas Kling  <akling@apple.com>
2703
2704         Unreviewed, rolling out r155809.
2705         http://trac.webkit.org/changeset/155809
2706         https://bugs.webkit.org/show_bug.cgi?id=121388
2707
2708         Accidentally removed files, let's redo this.
2709
2710 2013-09-15  Andreas Kling  <akling@apple.com>
2711
2712         CTTE: RenderMedia and RenderVideo are never anonymous.
2713         <https://webkit.org/b/121388>
2714
2715         Reviewed by Sam Weinig.
2716
2717         Codify the following:
2718
2719         - RenderMedia always has an HTMLMediaElement.
2720         - RenderVideo always has an HTMLVideoElement.
2721
2722         None of these renderers are ever anonymous, so delete element() and provide
2723         strongly typed reference getters instead.
2724
2725 2013-09-15  Sam Weinig  <sam@webkit.org>
2726
2727         [CTTE] Node subclasses should take a Document by reference in their constructor (Part 6)
2728         https://bugs.webkit.org/show_bug.cgi?id=121387
2729
2730         Reviewed by Andreas Kling.
2731
2732         Converts the following to take a Document reference:
2733             - Attr
2734             - CDATASection
2735             - CharacterData
2736             - Comment
2737             - DOMImplementation
2738             - DocumentFragment
2739             - DocumentType
2740             - EntityReference
2741             - Notation
2742             - ProcessingInstruction
2743             - ShadowRoot
2744             - TemplateContentDocumentFragment
2745             - Text
2746
2747 2013-09-15  Andreas Kling  <akling@apple.com>
2748
2749         Remove RenderObject::clearNode().
2750         <https://webkit.org/b/121386>
2751
2752         Reviewed by Anders Carlsson.
2753
2754         This was used by ref-counted RenderWidgets after getting removed from their
2755         parent renderer but kept alive by an external ref. We have no need for this
2756         awkward state anymore, so remove clearNode().
2757
2758 2013-09-15  Andreas Kling  <akling@apple.com>
2759
2760         CTTE: RenderWidgets are never anonymous.
2761         <https://webkit.org/b/121385>
2762
2763         Reviewed by Anders Carlsson.
2764
2765         Codify the following:
2766
2767         - RenderWidget always has an HTMLFrameOwnerElement.
2768         - RenderEmbeddedObject always has an HTMLFrameOwnerElement.
2769         - RenderSnapshottedPlugIn always has an HTMLPlugInImageElement.
2770         - RenderFrame always has an HTMLFrameElement.
2771         - RenderIFrame always has an HTMLIFrameElement.
2772
2773         None of these renderers are ever anonymous, so delete element() and provide
2774         strongly typed reference getters instead.
2775
2776 2013-09-14  Darin Adler  <darin@apple.com>
2777
2778         Use FINAL instead of virtualChildren trick in render tree classes
2779         https://bugs.webkit.org/show_bug.cgi?id=121373
2780
2781         Reviewed by Andreas Kling.
2782
2783         * rendering/RenderBlock.cpp:
2784         (WebCore::RenderBlock::updateFirstLetterStyle): Use children instead of
2785         virtualChildren.
2786         * rendering/RenderBox.cpp:
2787         (WebCore::RenderBox::splitAnonymousBoxesAroundChild): Ditto.
2788         * rendering/RenderBoxModelObject.cpp:
2789         (WebCore::RenderBoxModelObject::moveChildTo): Ditto.
2790         * rendering/RenderObject.cpp:
2791         (WebCore::RenderObject::addChild): Ditto.
2792         (WebCore::RenderObject::removeChild): Ditto.
2793         (WebCore::RenderObject::handleDynamicFloatPositionChange): Ditto.
2794         (WebCore::RenderObject::willBeDestroyed): Ditto.
2795         (WebCore::RenderObject::removeFromRenderFlowThreadRecursive): Ditto.
2796
2797         * rendering/RenderBlock.h: Changed firstChild and lastChild to use
2798         m_children directly instead of a function. Made the children function
2799         a final virtual override. Deleted the virtualChildren override. Added
2800         override keywords to other virtual functions.
2801         * rendering/RenderEmbeddedObject.h: Ditto.
2802         * rendering/RenderFrameSet.h: Ditto.
2803         * rendering/RenderInline.h: Ditto.
2804         * rendering/RenderMedia.h: Ditto.
2805         * rendering/RenderTableCol.h: Ditto.
2806         * rendering/RenderTableRow.h: Ditto.
2807         * rendering/RenderTableSection.h: Ditto.
2808         * rendering/svg/RenderSVGContainer.h: Ditto.
2809         * rendering/svg/RenderSVGRoot.h: Ditto.
2810
2811         * rendering/RenderObject.h:
2812         (WebCore::RenderObject::firstChild): Use children instead of virtualChildren.
2813         (WebCore::RenderObject::lastChild): Ditto.
2814         (WebCore::RenderObject::children): Renamed from virtualChildren.
2815         (WebCore::RenderObject::canHaveChildren): Use children instead of virtualChildren.
2816
2817 2013-09-15  Darin Adler  <darin@apple.com>
2818
2819         Shrink factory functions
2820         https://bugs.webkit.org/show_bug.cgi?id=121378
2821
2822         Reviewed by Andreas Kling.
2823
2824         This makes the functions that builds four different types of per-element tables
2825         all have smaller code size.
2826
2827         * DerivedSources.make: Tweaked how HTML and SVG wrapper factories are made a bit.
2828         It was OK, but a little sloppy.
2829
2830         * dom/Document.cpp:
2831         (WebCore::Document::createElement): Changed to call the createElement functions
2832         in the factories. Also did some style improvement.
2833
2834         * dom/make_names.pl:
2835         (printConstructorSignature): Make constructors take a Document& instead of
2836         a Document*.
2837         (printConstructorInterior): Updated for Document& instead of Document*.
2838         (printFunctionTable): Renamed from printFunctionInits, because this now
2839         creates table entries. The actual code to add each function is now done
2840         in a loop instead.
2841         (printNamesHeaderFile): Made the table const.
2842         (printNamesCppFile): Made the table const.
2843         (printDefinitions): Generate a table, table entries, and a loop that calls
2844         createQualifiedName, rather than an "unrolled loop".
2845         (printFactoryCppFile): Tweaked indentation. Updated to take Document& instead
2846         of Document*. Generate a table, table entries, and a loop that builds a map,
2847         rather than an "unrolled" loop.
2848         (printFactoryHeaderFile): Eliminated the unused createElement member function
2849         that was part of a dream of factory objects in a namespace registry, giving
2850         the name createElement to the static member function so it would be less
2851         redundant. Also made the function takes a Document& instead of Document*.
2852         Also made the default "not created by parser", since the parser is the simpler
2853         use case, outnumbered by the non-parser uses, at least at the moment. Also,
2854         use nullptr instead of 0.
2855         (printWrapperFactoryCppFile): Generate a table, table entries, and a loop
2856         that builds a map rather than an "unrolled" loop.
2857
2858         * editing/htmlediting.cpp:
2859         (WebCore::createHTMLElement): Put the null check here that used to be in
2860         HTMLElementFactory::createElement, and call with a reference instead of a
2861         pointer. Also don't need to pass "0, false" since "not created by the parser"
2862         is now the default.
2863         * html/HTMLDocument.cpp:
2864         (WebCore::HTMLDocument::createElement): Ditto.
2865
2866         * html/HTMLElement.cpp:
2867         (WebCore::populateEventNameForAttributeLocalNameMap): Changed to use an
2868         AtomicStringImpl* as the key instead of AtomicString, since all the strings
2869         come from the local names of tags, and so don't need to be ref'd. This saves
2870         a bit of reference count churn when building the map and is the same pattern
2871         used in some maps in the make_names.pl script above.
2872         (WebCore::HTMLElement::parseAttribute): Updated for change above.
2873
2874         * html/HTMLObjectElement.cpp:
2875         (WebCore::isRecognizedTagName): More const.
2876
2877         * html/parser/HTMLConstructionSite.cpp:
2878         (WebCore::HTMLConstructionSite::createHTMLElement): Changed to call the
2879         HTMLElementFactory::createElement function under its new name with a reference
2880         rather than a pointer.
2881
2882         * html/parser/HTMLIdentifier.cpp:
2883         (WebCore::nameForIndex): More const.
2884         (WebCore::HTMLIdentifier::addNames): More const.
2885
2886         * html/parser/HTMLTreeBuilder.cpp:
2887         (WebCore::mapLoweredLocalNameToName): More const.
2888         (WebCore::adjustSVGTagNameCase): Eliminated local variable so we would not have
2889         to utter type with more const.
2890         (WebCore::adjustAttributes): Ditto.
2891         (WebCore::addNamesWithPrefix): More const. Also tweaked to use a bit more reference,
2892         and a bit less pointer. Also used array instead of pointer for argument since they
2893         are synonyms and this use is more array-like and const array is slightly easier to
2894         understand than the double const pointer.
2895         (WebCore::adjustForeignAttributes): Eliminated local variable so we would not have
2896         to utter type with more const.
2897
2898         * html/track/TextTrackCue.cpp:
2899         (WebCore::TextTrackCue::copyWebVTTNodeToDOMTree): Pass a reference to
2900         WebVTTElement::createEquivalentHTMLElement.
2901
2902         * html/track/WebVTTElement.cpp:
2903         (WebCore::WebVTTElement::WebVTTElement): Take a reference instead of a pointer.
2904         (WebCore::WebVTTElement::create): Ditto.
2905         (WebCore::WebVTTElement::cloneElementWithoutAttributesAndChildren): Pass a
2906         reference instead of a pointer to create.
2907         (WebCore::WebVTTElement::createEquivalentHTMLElement): Take a reference instead
2908         of a pointer, and update uses of HTMLElementFactory::createElement. Also made
2909         this return null when a bad node type is passed in, which should never happen.
2910
2911         * html/track/WebVTTElement.h: Use Document& instead of Document*. Removed unused
2912         and undefined create/constructor overloads.
2913
2914         * html/track/WebVTTParser.cpp:
2915         (WebCore::WebVTTParser::constructTreeFromToken): Pass document reference rather than
2916         pointer to WebVTTElement::create.
2917
2918 2013-09-15  Andreas Kling  <akling@apple.com>
2919
2920         Get rid of ref-counting on RenderArena.
2921         <https://webkit.org/b/121379>
2922
2923         Reviewed by Darin Adler.
2924
2925         This was used to guard the arena during ref-counted RenderWidget teardown.
2926
2927 2013-09-15  Darin Adler  <darin@apple.com>
2928
2929         Fix Qt build.
2930
2931         * css/CSSSelector.cpp:
2932         (WebCore::populatePseudoTypeByNameMap): Removed stray line that was breaking
2933         the build for any platform with !ENABLE(VIDEO_TRACK).
2934
2935 2013-09-15  Andreas Kling  <akling@apple.com>
2936
2937         Restore two-pass mechanism for FrameView::updateEmbeddedObjects().
2938         <https://webkit.org/b/121380>
2939
2940         Reviewed by Darin Adler.
2941
2942         Restore the code to make a second pass over the embedded objects needing
2943         an update in case more objects were added to the set during the first pass.
2944
2945 2013-09-15  Frédéric Wang  <fred.wang@free.fr>
2946
2947         Implement the mmultiscripts tag
2948         https://bugs.webkit.org/show_bug.cgi?id=99618
2949
2950         Reviewed by Chris Fleizach.
2951
2952         Tests: mathml/invalid-scripts-crash.html
2953                mathml/presentation/multiscripts-equivalence.html
2954                mathml/presentation/multiscripts-noscripts.html
2955                mathml/presentation/multiscripts-positions.html
2956                mathml/presentation/scripts-base-alignment.html
2957                mathml/presentation/scripts-horizontal-alignment.html
2958                mathml/presentation/scripts-vertical-alignment.html
2959                mathml/scripts-addChild.html
2960                mathml/scripts-removeChild.html
2961
2962         This relies on the existing msub/msup/msubsup code to implement the mmultiscripts tag. This also improves dynamic addition/removal of children for these MathML elements and adds a specific style for invalid children, so that they render like an merror tag. Finally, this fixes a bad memory access in the Accessibility render object of msubsup.
2963
2964         * CMakeLists.txt:
2965         * GNUmakefile.list.am:
2966         * Target.pri:
2967         * WebCore.vcxproj/WebCore.vcxproj:
2968         * WebCore.vcxproj/WebCore.vcxproj.filters:
2969         * WebCore.xcodeproj/project.pbxproj:
2970         * accessibility/AccessibilityRenderObject.cpp:
2971         (WebCore::AccessibilityRenderObject::isMathSubscriptSuperscript):
2972         (WebCore::AccessibilityRenderObject::mathSuperscriptObject):
2973         * css/mathml.css:
2974         (mo, mrow, mfenced, mfrac, msub, msup, msubsup, mmultiscripts, mprescripts, none, munder, mover, munderover, msqrt, mroot):
2975         (mover > :last-child, munderover > :last-child):
2976         (msub > * + *, msup > * + *, msubsup > * + *, mmultiscripts > * + *, munder > * + *, mover > * + *, munderover > * + *):
2977         (merror, msub > * + * + *, msup > * + * + *, msubsup > * + * + * + *, msub > mprescripts, msup > mprescripts, msubsup > mprescripts, msub > none, msup > none, msubsup > none, mmultiscripts > mprescripts ~ mprescripts, mmultiscripts > mprescripts ~ mprescripts ~ *):
2978         * mathml/MathMLInlineContainerElement.cpp:
2979         (WebCore::MathMLInlineContainerElement::createRenderer):
2980         * mathml/mathtags.in:
2981         * rendering/mathml/RenderMathMLBlock.h:
2982         (WebCore::RenderMathMLBlock::isRenderMathMLScripts):
2983         (WebCore::RenderMathMLBlock::isRenderMathMLScriptsWrapper):
2984         * rendering/mathml/RenderMathMLScripts.cpp: Added.
2985         (WebCore::isMPrescripts):
2986         (WebCore::RenderMathMLScripts::RenderMathMLScripts):
2987         (WebCore::RenderMathMLScripts::base):
2988         (WebCore::RenderMathMLScripts::fixAnonymousStyleForSubSupPair):
2989         (WebCore::RenderMathMLScripts::fixAnonymousStyles):
2990         (WebCore::RenderMathMLScripts::addChildInternal):
2991         (WebCore::RenderMathMLScripts::removeChildInternal):
2992         (WebCore::RenderMathMLScripts::addChild):
2993         (WebCore::RenderMathMLScripts::removeChild):
2994         (WebCore::RenderMathMLScripts::styleDidChange):
2995         (WebCore::RenderMathMLScripts::unembellishedOperator):
2996         (WebCore::RenderMathMLScripts::layout):
2997         (WebCore::RenderMathMLScripts::firstLineBoxBaseline):
2998         (WebCore::RenderMathMLScriptsWrapper::createAnonymousWrapper):
2999         (WebCore::RenderMathMLScriptsWrapper::addChildInternal):
3000         (WebCore::RenderMathMLScriptsWrapper::addChild):
3001         (WebCore::RenderMathMLScriptsWrapper::removeChildInternal):
3002         (WebCore::RenderMathMLScriptsWrapper::removeChild):
3003         * rendering/mathml/RenderMathMLScripts.h: Added.
3004         (WebCore::RenderMathMLScriptsWrapper::RenderMathMLScriptsWrapper):
3005         (WebCore::RenderMathMLScriptsWrapper::renderName):
3006         (WebCore::RenderMathMLScriptsWrapper::isRenderMathMLScriptsWrapper):
3007         (WebCore::toRenderMathMLScriptsWrapper):
3008         (WebCore::RenderMathMLScripts::isRenderMathMLScripts):
3009         (WebCore::RenderMathMLScripts::renderName):
3010         (WebCore::toRenderMathMLScripts):
3011         * rendering/mathml/RenderMathMLSubSup.cpp: Removed.
3012         * rendering/mathml/RenderMathMLSubSup.h: Removed.
3013
3014 2013-09-15  Andreas Kling  <akling@apple.com>
3015
3016         Get rid of ref-counting on RenderWidget.
3017         <https://webkit.org/b/121357>
3018
3019         Reviewed by Darin Adler.
3020
3021         Instead of RenderView tracking RenderWidgets, have FrameView track Widgets
3022         that are currently in the render tree.
3023
3024         To protect ourselves during NPAPI tomfoolery, we now let RenderWidget hand
3025         out weak pointers through a createWeakPtr() method so call sites can monitor
3026         the renderer for deletion without having to take shared ownership.
3027
3028         This works out quite nicely since instead of keeping a limping object alive
3029         for a little longer just so we can call methods on it (to accomplish nothing),
3030         we're forced to check right away if it's gone, and take immediate action.
3031
3032         De-virtualized RenderObject::destroy() since it's no longer needed for
3033         RenderWidget to defer destruction.
3034
3035         * page/FrameView.cpp:
3036         (WebCore::FrameView::layout):
3037         (WebCore::FrameView::repaintFixedElementsAfterScrolling):
3038
3039             Call updateWidgetPositions() on FrameView instead of RenderView.
3040
3041         (WebCore::FrameView::updateEmbeddedObject):
3042
3043             Turn null checking of embedded object's element backpointer into an
3044             assertion. This will eventually go away completely once that renderer
3045             can return a HTMLFrameOwnerElement&.
3046
3047             Use WeakPtr to check for renderer destruction following the call out
3048             to updateWidget().
3049
3050         (WebCore::FrameView::updateEmbeddedObjects):
3051
3052             Slap a WidgetHierarchyUpdatesSuspensionScope guard on this function
3053             to defer Widget updates until all the updateEmbeddedObject calls are
3054             done. This avoids RenderWidget::setWidget() having to handle 'this'
3055             disappearing from underneath.
3056
3057             Also use a ListHashSet with a null sentinel to avoid looping forever.
3058
3059         (WebCore::FrameView::performPostLayoutTasks):
3060
3061             Only call updateEmbeddedObjects() once since that function no longer
3062             operates in chunks.
3063
3064         (WebCore::FrameView::notifyWidgetsInAllFrames):
3065
3066             Call notifyWidgets() on FrameView instead of RenderView.
3067
3068         (WebCore::FrameView::didAddWidgetToRenderTree):
3069         (WebCore::FrameView::willRemoveWidgetFromRenderTree):
3070
3071             Added. These are called by RenderWidget when a Widget is being
3072             added or removed from a RenderWidget.
3073
3074         (WebCore::collectWidgets):
3075
3076             Helper to collect raw Widget pointers into a Vector and ref them.
3077
3078         (WebCore::FrameView::updateWidgetPositions):
3079
3080             Moved here from RenderView. This function holds a ref on all the
3081             attached Widgets and calls RenderWidget::updateWidgetPosition() on
3082             their corresponding renderers.
3083
3084         (WebCore::FrameView::notifyWidgets):
3085
3086             Moved here from RenderView. Holds a ref on all the widgets while
3087             calling Widget::notifyWidget() on each one.
3088
3089         * rendering/RenderLayer.cpp:
3090         (WebCore::RenderLayer::scrollTo):
3091
3092             Call updateWidgetPositions() on FrameView instead of RenderView.
3093
3094         * rendering/RenderObject.h:
3095
3096             De-virtualized destroy().
3097
3098         * rendering/RenderView.cpp:
3099         * rendering/RenderView.h:
3100
3101             Moved a bunch of things to FrameView. Made protected section private
3102             since nothing inherits from RenderView.
3103
3104         * rendering/RenderWidget.h:
3105         (WebCore::RenderWidget::createWeakPtr):
3106
3107             Added a WeakPtr factory for clients that want to monitor this object
3108             for destruction.
3109             
3110         * rendering/RenderWidget.cpp:
3111         (WebCore::RenderWidget::RenderWidget):
3112         (WebCore::RenderWidget::willBeDestroyed):
3113         (WebCore::RenderWidget::~RenderWidget):
3114
3115             Removed ref counting.
3116             Removed registration with RenderView in ctor/willBeDestroyed.
3117
3118         (WebCore::RenderWidget::setWidgetGeometry):
3119
3120             Monitor the RenderWidget itself through a WeakPtr and check on it
3121             after each step that we're still alive. In that case just bail out.
3122
3123         (WebCore::RenderWidget::setWidget):
3124
3125             Register the incoming/outgoing Widget with the FrameView.
3126             Use a WeakPtr to check on 'this' after updateWidgetGeometry().
3127
3128         (WebCore::RenderWidget::updateWidgetPosition):
3129
3130             Use a WeakPtr to check on 'this' after updateWidgetGeometry().
3131
3132         * GNUmakefile.list.am:
3133         * rendering/RenderWidgetProtector.h:
3134
3135             Removed.
3136
3137
3138 2013-09-14  Sam Weinig  <sam@webkit.org>
3139
3140         [CTTE] Node subclasses should take a Document by reference in their constructor (Part 5)
3141         https://bugs.webkit.org/show_bug.cgi?id=121375
3142
3143         Reviewed by Andreas Kling.
3144
3145         * dom/make_names.pl:
3146         Add support for a top level 'constructorTakesDocumentReference' property to
3147         force using a Document reference for the whole factory.
3148
3149         * html/HTMLTagNames.in:
3150         Replace per-tag 'constructorTakesDocumentReference' with a top level declaration
3151         now that all of the HTML tag names are supported.
3152
3153         Converts the following to take a Document reference:
3154             - HTMLContentElement
3155             - HTMLElement
3156             - HTMLFrameElementBase
3157             - HTMLFrameOwnerElement
3158             - HTMLPlugInElement
3159             - HTMLPlugInImageElement
3160             - HTMLUnknownElement
3161             - InsertionPoint
3162             - StyledElement
3163             - TextTrackCueBox
3164             - TextTrackCueGenericBoxElement
3165
3166 2013-09-14  Eric Carlson  <eric.carlson@apple.com>
3167
3168         MediaStream API: Update RTCDataChannel
3169         https://bugs.webkit.org/show_bug.cgi?id=121102
3170
3171         Reviewed by Sam Weinig.
3172
3173         Based on https://chromium.googlesource.com/chromium/blink/+/c6975c41956acded7cf0363012d7d6b69d0c6d96,
3174         and https://chromium.googlesource.com/chromium/blink/+/214dab0bd6385f573c918ba5ce58a5aa206ce186.
3175
3176         No new tests, existing tests updated.
3177
3178         * Modules/mediastream/RTCDataChannel.cpp:
3179         (WebCore::RTCDataChannel::create): Take an options Dictionary.
3180         (WebCore::RTCDataChannel::didChangeReadyState): String -> AtomicString. Early return if the
3181             state hasn't changed.
3182         (WebCore::RTCDataChannel::binaryType): String -> AtomicString.
3183         (WebCore::RTCDataChannel::setBinaryType): String -> AtomicString.
3184         * Modules/mediastream/RTCDataChannel.h:
3185         * Modules/mediastream/RTCDataChannel.idl:
3186
3187         * Modules/mediastream/RTCPeerConnection.cpp:
3188         (WebCore::RTCPeerConnection::createDataChannel): Take an options struct.
3189         * platform/mediastream/RTCDataChannelHandler.h:
3190
3191         * platform/mediastream/RTCPeerConnectionHandler.h:
3192         (WebCore::RTCDataChannelInit::RTCDataChannelInit): Take an options struct.
3193
3194 2013-09-14  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3195
3196         MediaStream API: Update RTCDataChannel to match the specification
3197         https://bugs.webkit.org/show_bug.cgi?id=120889
3198
3199         Reviewed by Eric Carlson
3200
3201         Merged from https://chromium.googlesource.com/chromium/blink/+/c3862b0a83e20fc8b1f770c7e4a886a7cceb80d2
3202         by Tommy Widenflycht.
3203
3204         According to WebRTC specification, RTCDataChannel must have the following new attributes:
3205         boolean ordered
3206         unsigned short maxRetransmitTime
3207         unsigned short maxRetransmits
3208         DOMString protocol
3209         boolean negotiated
3210         unsigned short id
3211
3212         and the following one was deprecated:
3213         boolean reliable
3214
3215         Test updates will be landed with https://webkit.org/b/121102.
3216
3217         * Modules/mediastream/RTCDataChannel.cpp:
3218         (WebCore::RTCDataChannel::ordered):
3219         (WebCore::RTCDataChannel::maxRetransmitTime):
3220         (WebCore::RTCDataChannel::maxRetransmits):
3221         (WebCore::RTCDataChannel::protocol):
3222         (WebCore::RTCDataChannel::negotiated):
3223         (WebCore::RTCDataChannel::id):
3224         * Modules/mediastream/RTCDataChannel.h:
3225         * Modules/mediastream/RTCDataChannel.idl:
3226         * platform/mediastream/RTCDataChannelHandler.h:
3227
3228 2013-09-14  Sam Weinig  <sam@webkit.org>
3229
3230         [CTTE] Node subclasses should take a Document by reference in their constructor (Part 4)
3231         https://bugs.webkit.org/show_bug.cgi?id=121372
3232
3233         Reviewed by Eric Carlson.
3234
3235         Converts the following to take a Document reference:
3236             - HTMLFormControlElement
3237             - HTMLFormControlElementWithState
3238             - HTMLMapElement
3239             - HTMLMarqueeElement
3240             - HTMLMediaElement
3241             - HTMLMenuElement
3242             - HTMLMetaElement
3243             - HTMLMeterElement
3244             - HTMLOListElement
3245             - HTMLObjectElement
3246             - HTMLOptGroupElement
3247             - HTMLOptionElement
3248             - HTMLOutputElement
3249             - HTMLParagraphElement
3250             - HTMLParamElement
3251             - HTMLProgressElement
3252             - HTMLScriptElement
3253             - HTMLSelectElement
3254             - HTMLSourceElement
3255             - HTMLSpanElement
3256             - HTMLStyleElement
3257             - HTMLSummaryElement
3258             - HTMLTableCellElement
3259             - HTMLTableElement
3260             - HTMLTableRowElement
3261             - HTMLTableSectionElement
3262             - HTMLTemplateElement
3263             - HTMLTextAreaElement
3264             - HTMLTextFormControlElement
3265             - HTMLTitleElement
3266             - HTMLTrackElement
3267             - HTMLUListElement
3268             - InlineStyleSheetOwner
3269             - LabelableElement
3270             - All the MediaControl elements
3271
3272 2013-09-14  Joseph Pecoraro  <pecoraro@apple.com>
3273
3274         XMLViewer_js and XMLViewer_css should be minified
3275         https://bugs.webkit.org/show_bug.cgi?id=121334
3276
3277         Reviewed by Timothy Hatcher.
3278
3279         * CMakeLists.txt:
3280         * DerivedSources.make:
3281         * DerivedSources.pri:
3282         * GNUmakefile.am:
3283         * xml/XMLViewer.css:
3284         * xml/XMLViewer.js:
3285
3286 2013-09-14  Eric Carlson  <eric.carlson@apple.com>
3287
3288         [MediaStream] remove MediaStream.label
3289         https://bugs.webkit.org/show_bug.cgi?id=121337
3290
3291         Reviewed by Sam Weinig.
3292
3293         No new tests or modified tests, this attribute was apparently never tested.
3294
3295         * Modules/mediastream/MediaStream.h:
3296         * Modules/mediastream/MediaStream.idl:
3297
3298 2013-09-14  Sam Weinig  <sam@webkit.org>
3299
3300         [CTTE] Node subclasses should take a Document by reference in their constructor (Part 3)
3301         https://bugs.webkit.org/show_bug.cgi?id=121368
3302
3303         Reviewed by Darin Adler.
3304
3305         Converts the following to take a Document reference:
3306             - DeleteButton
3307             - DetailsContentElement
3308             - DetailsMarkerControl
3309             - DetailsSummaryElement
3310             - HTMLBDIElement
3311             - HTMLBRElement
3312             - HTMLBaseElement
3313             - HTMLBaseFontElement
3314             - HTMLButtonElement
3315             - HTMLCanvasElement
3316             - HTMLDListElement
3317             - HTMLDataListElement
3318             - HTMLDetailsElement
3319             - HTMLDirectoryElement
3320             - HTMLDivElement
3321             - HTMLEmbedElement
3322             - HTMLFieldSetElement
3323             - HTMLFontElement
3324             - HTMLFormElement
3325             - HTMLFrameElement
3326             - HTMLFrameSetElement
3327             - HTMLHRElement
3328             - HTMLHeadElement
3329             - HTMLHeadingElement
3330             - HTMLHtmlElement
3331             - HTMLIFrameElement
3332             - HTMLImageElement
3333             - HTMLInputElement
3334             - HTMLKeygenElement
3335             - HTMLLIElement
3336             - HTMLLabelElement
3337             - HTMLLegendElement
3338             - HTMLLinkElement
3339             - HTMLModElement
3340             - HTMLPreElement
3341             - HTMLQuoteElement
3342             - HTMLTableCaptionElement
3343             - HTMLTableColElement
3344             - ImageDocumentElement
3345             - KeygenSelectElement
3346             - SummaryContentElement
3347             - UploadButtonElement
3348
3349
3350 2013-09-14  Zan Dobersek  <zdobersek@igalia.com>
3351
3352         REGRESSION(r155228): Call to DragData::asFragment() nullifies PassRefPtr<Range> in documentFragmentFromDragData
3353         https://bugs.webkit.org/show_bug.cgi?id=121359
3354
3355         Reviewed by Darin Adler.
3356
3357         * page/DragController.cpp:
3358         (WebCore::documentFragmentFromDragData): Pass the naked pointer as the PassRefPtr<Range> argument to the DragData::asFragment()
3359         call. The naked pointer will get wrapped and protected by a new PassRefPtr. Passing the original PassRefPtr will also create
3360         a new PassRefPtr, but will leak the reference of the original one, leaving its pointer nullified.
3361
3362 2013-09-14  Zan Dobersek  <zdobersek@igalia.com>
3363
3364         Unreviewed GTK build fix after r155774.
3365
3366         * bindings/scripts/CodeGeneratorGObject.pm:
3367         (SkipFunction): Temporarily skip generation of bindings for the Console::profile() and Console::profileEnd() methods
3368         as they're not correctly generated for the moment.
3369
3370 2013-09-14  Darin Adler  <darin@apple.com>
3371
3372         Shrink the nameToPseudoTypeMap function
3373         https://bugs.webkit.org/show_bug.cgi?id=121367
3374
3375         Reviewed by Andreas Kling.
3376
3377         * css/CSSSelector.cpp:
3378         (WebCore::populatePseudoTypeByNameMap): Replaces the old nameToPseudoTypeMap
3379         function. Use a table instead of lots of globals and unrolled code to set up
3380         the map.
3381         (WebCore::CSSSelector::parsePseudoType): Updated to use the code above, and
3382         also use a different style that's tighter.
3383
3384 2013-09-14  Darin Adler  <darin@apple.com>
3385
3386         Shrink the listMarkerText function
3387         https://bugs.webkit.org/show_bug.cgi?id=121364
3388
3389         Reviewed by Andreas Kling.
3390
3391         Changed code to use StringBuilder, which is a better fit for what we are
3392         doing here. But mainly, inlining was out of hand, so hit that with the
3393         NEVER_INLINE stick. Might be worth revisiting this to optimize further for
3394         speed by making StringBuilder better at this.
3395
3396         * rendering/RenderListMarker.cpp:
3397         (WebCore::toRoman): NEVER_INLINE and use StringBuilder.
3398         (WebCore::toAlphabeticOrNumeric): Use StringBuilder.
3399         (WebCore::toSymbolic): NEVER_INLINE and use StringBuilder.
3400         (WebCore::toAlphabetic): Ditto.
3401         (WebCore::toNumeric): Ditto.
3402         (WebCore::toHebrewUnder1000): NEVER_INLINE.
3403         (WebCore::toHebrew): NEVER_INLINE and use StringBuilder.
3404         (WebCore::toArmenianUnder10000): NEVER_INLINE.
3405         (WebCore::toArmenian): NEVER_INLINE and use StringBuilder.
3406         (WebCore::toGeorgian): NEVER_INLINE and use StringBuilder.
3407         (WebCore::toCJKIdeographic): NEVER_INLINE and use StringBuilder.
3408         (WebCore::listMarkerText): Use StringBuilder.
3409
3410 2013-09-14  Sam Weinig  <sam@webkit.org>
3411
3412         [CTTE] Node subclasses should take a Document by reference in their 
3413         constructor (HTMLAnchorElement, HTMLAppletElement, HTMLAreaElement, HTMLAudioElement)
3414         https://bugs.webkit.org/show_bug.cgi?id=121365
3415
3416         Reviewed by Andreas Kling.
3417
3418         * editing/CreateLinkCommand.cpp:
3419         (WebCore::CreateLinkCommand::doApply):
3420         * editing/UnlinkCommand.cpp:
3421         (WebCore::UnlinkCommand::doApply):
3422         * html/HTMLAnchorElement.cpp:
3423         (WebCore::HTMLAnchorElement::HTMLAnchorElement):
3424         (WebCore::HTMLAnchorElement::create):
3425         * html/HTMLAnchorElement.h:
3426         * html/HTMLAppletElement.cpp:
3427         (WebCore::HTMLAppletElement::HTMLAppletElement):
3428         (WebCore::HTMLAppletElement::create):
3429         * html/HTMLAppletElement.h:
3430         * html/HTMLAreaElement.cpp:
3431         (WebCore::HTMLAreaElement::HTMLAreaElement):
3432         (WebCore::HTMLAreaElement::create):
3433         * html/HTMLAreaElement.h:
3434         * html/HTMLAudioElement.cpp:
3435         (WebCore::HTMLAudioElement::HTMLAudioElement):
3436         (WebCore::HTMLAudioElement::create):
3437         (WebCore::HTMLAudioElement::createForJSConstructor):
3438         * html/HTMLAudioElement.h:
3439         * html/HTMLTagNames.in:
3440         * html/HTMLViewSourceDocument.cpp:
3441         (WebCore::HTMLViewSourceDocument::addLink):
3442         * page/DragController.cpp:
3443         (WebCore::documentFragmentFromDragData):
3444
3445 2013-09-14  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3446
3447         Get INPUT_SPEECH compiling for Nix, EFL and GTK
3448         https://bugs.webkit.org/show_bug.cgi?id=121362
3449
3450         r154257 was not applied completely in HTMLInputElement.cpp and there was a wrong method signature
3451         in TextControlInnerElements.
3452         Also adding the files needed to build INPUT_SPEECH to each build system files.
3453
3454         Reviewed by Andreas Kling.
3455
3456         No new tests needed.
3457
3458         * CMakeLists.txt:
3459         * GNUmakefile.list.am:
3460       &nbs