Finish removing layer-violating code from Pasteboard (just for Mac during this first...
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-09-12  Darin Adler  <darin@apple.com>
2
3         Finish removing layer-violating code from Pasteboard (just for Mac during this first step)
4         https://bugs.webkit.org/show_bug.cgi?id=121279
5
6         Reviewed by Anders Carlsson.
7
8         * editing/Editor.h: Added webContentFromPasteboard member function, private nested class
9         WebContentReader, private createFragmentForImageResourceAndAddResource and
10         createFragmentAndAddResources member functions.
11
12         * editing/mac/EditorMac.mm: Re-sorted includes and added some.
13         (WebCore::Editor::pasteWithPasteboard): Call the new webContentFromPasteboard function.
14         (WebCore::Editor::insertParagraphSeparatorInQuotedContent): Comment tweak.
15         (WebCore::styleForSelectionStart): Removed an unneeded call to String::impl.
16         (WebCore::Editor::readPlainTextFromPasteboard): Updated to use an isURL boolean instead
17         of a separate string named "url".
18         (WebCore::Editor::WebContentReader::readWebArchive): Added. Contains reworked code that
19         was originally in Pasteboard::documentFragment.
20         (WebCore::Editor::WebContentReader::readFilenames): Ditto.
21         (WebCore::Editor::WebContentReader::readHTML): Ditto.
22         (WebCore::Editor::WebContentReader::readRTFD): Ditto.
23         (WebCore::Editor::WebContentReader::readRTF): Ditto.
24         (WebCore::Editor::WebContentReader::readImage): Ditto.
25         (WebCore::Editor::WebContentReader::readURL): Ditto.
26         (WebCore::Editor::WebContentReader::readPlainText): Ditto.
27         (WebCore::Editor::webContentFromPasteboard): Added. Uses WebContentReader to read the
28         content from the pasteboard.
29         (WebCore::Editor::createFragmentForImageResourceAndAddResource): Added. Helper used
30         by code above.
31         (WebCore::Editor::createFragmentAndAddResources): Ditto.
32
33         * platform/Pasteboard.h: Added new PasteboardWebContentReader abstract class so
34         client can get the various types of pasteboard content and stop on the kind it
35         can handle. Improved comments and formatting a bit. Removed documentFragment
36         when compiling for PLATFORM(MAC).
37
38         * platform/mac/DragDataMac.mm:
39         (WebCore::DragData::asFragment): Changed to use Editor::webContentFromPasteboard.
40
41         * platform/mac/PasteboardMac.mm:
42         (WebCore::Pasteboard::read): Updated the plain text overload of this for changes
43         to the struct that holds the result. Added a new web content overload of this,
44         which retains the pasteboard-reading part of Pasteboard::documentFragment, but
45         omits the document fragment construction part.
46
47 2013-09-13  Andreas Kling  <akling@apple.com>
48
49         [CTTE] RenderSVGText always has a SVGTextElement.
50         <https://webkit.org/b/121299>
51
52         Reviewed by Antti Koivisto.
53
54         This renderer is never anonymous, and always has a corresponding <svg> element.
55         Tighten this up and remove some pointless assertions.
56
57 2013-09-13  Allan Sandfeld Jensen  <allan.jensen@digia.com>
58
59         Remove support for QXmlStream as the XML parser.
60         https://bugs.webkit.org/show_bug.cgi?id=121229
61
62         Reviewed by Andreas Kling.
63
64         Remove the implementation and all the #ifdef related to it.
65
66         * Target.pri:
67         * WebCore.pri:
68         * dom/TransformSource.h:
69         * xml/XMLErrors.h:
70         * xml/XSLStyleSheet.h:
71         * xml/XSLTProcessor.h:
72         * xml/parser/XMLDocumentParser.cpp:
73         (WebCore::XMLDocumentParser::enterText):
74         (WebCore::toString):
75         (WebCore::XMLDocumentParser::exitText):
76         (WebCore::XMLDocumentParser::insertErrorMessageBlock):
77         * xml/parser/XMLDocumentParser.h:
78         * xml/parser/XMLDocumentParserQt.cpp: Removed.
79
80 2013-09-13  Andreas Kling  <akling@apple.com>
81
82         [CTTE] RenderSVGViewportContainer always has a SVGSVGElement.
83         <https://webkit.org/b/121297>
84
85         Reviewed by Antti Koivisto.
86
87         This renderer is never anonymous, and always has a corresponding <svg> element.
88         Tighten this up and remove some pointless null checks and type checks.
89
90 2013-09-13  Andreas Kling  <akling@apple.com>
91
92         [CTTE] RenderSVGRoot always has a SVGSVGElement.
93         <https://webkit.org/b/121293>
94
95         Reviewed by Antti Koivisto.
96
97         This renderer is never anonymous, and always has a corresponding <svg> element.
98         Tighten this up and remove some pointless null checks and assertions.
99
100 2013-09-13  Andreas Kling  <akling@apple.com>
101
102         Remove support for anonymous deprecated flexboxes.
103         <https://webkit.org/b/121288>
104
105         Reviewed by Antti Koivisto.
106
107         There are no remaining internal clients of RenderDeprecatedFlexibleBox,
108         Nuke a FIXME from r143643 where the move to basing renderers on new flexbox started.
109
110         This was the only user of anonymous deprecated flexbox, so removed the ability to
111         construct those.
112
113         Also removed some Chrome-related feature observation gunk from constructor.
114
115 2013-09-13  Andreas Kling  <akling@apple.com>
116
117         [CTTE] RenderMultiColumnBlock is never anonymous.
118         <https://webkit.org/b/121292>
119
120         Reviewed by Antti Koivisto.
121
122         Hide element() and provide existingElement() instead, returning an Element&.
123
124 2013-09-13  Andreas Kling  <akling@apple.com>
125
126         [CTTE] RenderGrid is never anonymous.
127         <https://webkit.org/b/121290>
128
129         Reviewed by Antti Koivisto.
130
131         Hide element() and provide existingElement() instead, returning an Element&.
132
133 2013-09-13  Andreas Kling  <akling@apple.com>
134
135         [CTTE] RenderTableCaption is never anonymous.
136         <https://webkit.org/b/121289>
137
138         Reviewed by Antti Koivisto.
139
140         Hide element() and provide existingElement() instead, returning an Element&.
141
142 2013-09-13  Andreas Kling  <akling@apple.com>
143
144         [CTTE] RenderTableCol is never anonymous.
145         <https://webkit.org/b/121286>
146
147         Reviewed by Antti Koivisto.
148
149         Hide element() and provide existingElement() instead, returning an Element&.
150         Removed one bogus null check that was exposed.
151
152 2013-09-13  Andreas Kling  <akling@apple.com>
153
154         [CTTE] RenderListItem is never anonymous.
155         <https://webkit.org/b/121285>
156
157         Reviewed by Antti Koivisto.
158
159         Hide element() and provide existingElement() instead, returning an Element&.
160         Removed some bogus assertions that were exposed by this.
161
162 2013-09-13  Andreas Kling  <akling@apple.com>
163
164         [CTTE] Tighter element types for RenderSVGInline and subclasses.
165         <https://webkit.org/b/121283>
166
167         Reviewed by Antti Koivisto.
168
169         Codify the following:
170
171         - RenderSVGInline always has an SVGGraphicsElement.
172         - RenderSVGTextPath always has an SVGTextPathElement.
173         - RenderSVGTSpan always has an SVGTextPositioningElement.
174
175         None of these renderers are ever anonymous, so delete element() and provide
176         strongly typed reference getters instead.
177
178 2013-09-13  Andreas Kling  <akling@apple.com>
179
180         [CTTE] RenderFileUploadControl always has a HTMLInputElement.
181         <https://webkit.org/b/121278>
182
183         Reviewed by Darin Adler.
184
185         RenderFileUploadControl is never anonymous and always has a corresponding HTMLInputElement.
186
187 2013-09-13  Andreas Kling  <akling@apple.com>
188
189         [CTTE] RenderFieldset always has a HTMLFieldSetElement.
190         <https://webkit.org/b/121277>
191
192         Reviewed by Darin Adler.
193
194         RenderFieldset is never anonymous and always has a corresponding HTMLFieldSetElement.
195
196 2013-09-13  Andreas Kling  <akling@apple.com>
197
198         [CTTE] RenderButton always has a HTMLFormControlElement.
199         <https://webkit.org/b/121281>
200
201         Reviewed by Antti Koivisto.
202
203         RenderButton is never anonymous and has either a <button> or an <input> element,
204         and their nearest shared ancestor is HTMLFormControlElement.
205
206 2013-09-13  Darin Adler  <darin@apple.com>
207
208         Give actions in Range class NON_SHOUTING_NAMES
209         https://bugs.webkit.org/show_bug.cgi?id=121280
210
211         Reviewed by Andreas Kling.
212
213         * dom/Range.cpp:
214         (WebCore::Range::deleteContents):
215         (WebCore::Range::processContents):
216         (WebCore::Range::processContentsBetweenOffsets):
217         (WebCore::Range::processNodes):
218         (WebCore::Range::processAncestorsAndTheirSiblings):
219         (WebCore::Range::extractContents):
220         (WebCore::Range::cloneContents):
221         * dom/Range.h:
222         Just let do-webcore-rename do its thing.
223         - DELETE_CONTENTS -> Delete
224         - EXTRACT_CONTENTS -> Extract
225         - CLONE_CONTENTS -> Clone
226
227 2013-09-12  Santosh Mahto  <santosh.ma@samsung.com>
228
229         [EFL]Background Style of element not visible because of  default theme style
230         https://bugs.webkit.org/show_bug.cgi?id=117405
231
232         Reviewed by Gyuyoung Kim.
233
234         When select element is styled with css background property(color/image) the styling
235         gets hidden by Combo box non transparent image. This patch handle the
236         case and transparent images are used when select image is styled. So
237         now background-color and background-image are visible across the Combo box
238         
239         The code is added to support css styling of other theme control,
240         Basically an extra signal is emitted to edje which change the state 
241         of edje object whenever the control is styled.
242
243         Covered by existing test case, updated the test expected image.
244
245         * platform/efl/DefaultTheme/CMakeLists.txt:
246         * platform/efl/DefaultTheme/widget/combo/combo.edc:
247         * platform/efl/DefaultTheme/widget/combo/combo_focus_button_transparent.png: Added.
248         * platform/efl/DefaultTheme/widget/combo/combo_focus_transparent.png: Added.
249         * platform/efl/DefaultTheme/widget/combo/combo_hover_button_transparent.png: Added.
250         * platform/efl/DefaultTheme/widget/combo/combo_hover_transparent.png: Added.
251         * platform/efl/DefaultTheme/widget/combo/combo_normal_button_transparent.png: Added.
252         * platform/efl/DefaultTheme/widget/combo/combo_normal_transparent.png: Added.
253         * platform/efl/DefaultTheme/widget/combo/combo_press_button_transparent.png: Added.
254         * platform/efl/DefaultTheme/widget/combo/combo_press_transparent.png: Added.
255         * platform/efl/RenderThemeEfl.cpp:
256         (WebCore::RenderThemeEfl::applyEdjeStateFromForm):
257         (WebCore::RenderThemeEfl::isControlStyled):
258         (WebCore::RenderThemeEfl::paintThemePart):
259         * platform/efl/RenderThemeEfl.h:
260
261 2013-09-12  Andreas Kling  <akling@apple.com>
262
263         [CTTE] RenderMenuList always has a HTMLSelectElement.
264         <https://webkit.org/b/121276>
265
266         Reviewed by Anders Carlsson.
267
268         This renderer is never anonymous and always has a corresponding HTMLSelectElement.
269         Deleted element() in favor of HTMLSelectElement& selectElement().
270
271 2013-09-12  Andreas Kling  <akling@apple.com>
272
273         [CTTE] Tighten RenderTextControl element typing.
274         <https://webkit.org/b/121275>
275
276         Reviewed by Anders Carlsson.
277
278         Codify these invariants:
279
280         - RenderTextControl always has a HTMLTextFormControl.
281         - RenderSearchField always has a HTMLInputElement.
282         - RenderTextControlSingleLine always has a HTMLInputElement.
283
284         None of these renderers are ever anonymous. Deleted element() and added
285         strongly typed reference getters instead.
286
287 2013-09-12  Andreas Kling  <akling@apple.com>
288
289         [CTTE] RenderListMarker is always anonymous and owned by RenderListItem.
290         <https://webkit.org/b/121274>
291
292         Reviewed by Anders Carlsson.
293
294         Store a RenderListItem& instead of a pointer in RenderListMarker.
295         Deleted the element() function since list markers are always anonymous.
296
297 2013-09-12  Andreas Kling  <akling@apple.com>
298
299         [CTTE] RenderListBox's element is always a HTMLSelectElement.
300         <https://webkit.org/b/121273>
301
302         Reviewed by Anders Carlsson.
303
304         Hide element() on RenderListBox and make selectElement() return a reference
305         since this renderer cannot be anonymous.
306
307 2013-09-12  Andreas Kling  <akling@apple.com>
308
309         [CTTE] RenderHTMLCanvas's element is always a HTMLCanvasElement.
310         <https://webkit.org/b/121272>
311
312         Reviewed by Anders Carlsson.
313
314         Add RenderHTMLCanvas::canvasElement(), hiding element().
315         This function also returns a reference since this renderer cannot be anonymous.
316
317 2013-09-12  Andreas Kling  <akling@apple.com>
318
319         [CTTE] RenderTextControlMultiLine's element is always a HTMLTextAreaElement.
320         <https://webkit.org/b/121271>
321
322         Reviewed by Anders Carlsson.
323
324         Add RenderTextControlMultiLine::textAreaElement(), hiding element().
325         This function also returns a reference since this renderer cannot be anonymous.
326
327 2013-09-12  Tim Horton  <timothy_horton@apple.com>
328
329         [mac] Cache rendered image in PDFDocumentImage
330         https://bugs.webkit.org/show_bug.cgi?id=121207
331
332         Reviewed by Simon Fraser.
333
334         Tests: fast/images/pdf-as-image-too-big.html
335
336         * loader/cache/CachedImage.cpp:
337         (WebCore::CachedImage::createImage):
338         PDFDocumentImage takes a ImageObserver now so that it can report
339         decoded data size changes to the memory cache.
340
341         * platform/graphics/Image.h:
342         (WebCore::Image::isPDFDocumentImage): Added.
343
344         * platform/graphics/cg/PDFDocumentImage.cpp:
345         (WebCore::PDFDocumentImage::PDFDocumentImage):
346         PDFDocumentImage takes a ImageObserver now so that it can report
347         decoded data size changes to the memory cache.
348
349         (WebCore::PDFDocumentImage::applyRotationForPainting):
350         Fix up some comments, and use GraphicsContext instead of CG API.
351
352         (WebCore::PDFDocumentImage::cacheParametersMatch):
353         Determine whether our cached image is still valid, given the new
354         destination's size, CTM scale, and source rect.
355
356         (WebCore::transformContextForPainting): Added.
357
358         (WebCore::PDFDocumentImage::updateCachedImageIfNeeded):
359         Cache a rendered bitmap of the PDF. Invalidate the cache if cacheParametersMatch
360         decides that the parameters don't match, unless we're painting in low quality mode,
361         in which case we'll scale the existing image (and then fully repaint when the
362         high-quality repaint timer fires).
363         Inform the memory cache of our new size.
364
365         (WebCore::PDFDocumentImage::draw):
366         Update the cached image if needed.
367         Paint the cached image into the context if it's available (which it might not be,
368         if the image is way too big and the allocation fails). Otherwise, paint straight
369         into the context as we previously did.
370
371         (WebCore::PDFDocumentImage::destroyDecodedData):
372         Throw away the cached image if requested.
373
374         (WebCore::PDFDocumentImage::decodedSize):
375         (WebCore::PDFDocumentImage::drawPDFPage):
376         Drive-by use GraphicsContext instead of CG directly.
377
378         * platform/graphics/cg/PDFDocumentImage.h:
379         (WebCore::PDFDocumentImage::create):
380         Override isPDFDocumentImage().
381         Add storage for the cached image buffer and various cache parameters.
382
383         * rendering/ImageQualityController.cpp:
384         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
385         PDFDocumentImage is also interested in/capable of low-quality painting now.
386
387 2013-09-12  Tim Horton  <timothy_horton@apple.com>
388
389         Image doesn't always repaint at high quality in all tiles after a live resize
390         https://bugs.webkit.org/show_bug.cgi?id=121244
391
392         Reviewed by Darin Adler.
393
394         Currently, ImageQualityController removes an image from its low-quality-images
395         list from inside shouldPaintAtLowQuality, if this is the first paint outside
396         of a live resize, but does not force the renderer to repaint in its entirety.
397
398         However, there's no guarantee we've invalidated the whole renderer, so this can
399         leave some parts of the image painted in low-quality.
400
401         This just removes a short-circuit, instead using the ordinary high-quality-repaint
402         timer to ensure that the entire renderer is repainted.
403
404         No new test; all attempts have failed, as this depends on tiled drawing
405         and a live resize occurring.
406
407         * rendering/ImageQualityController.cpp:
408         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
409
410 2013-09-12  Brent Fulgham  <bfulgham@apple.com>
411
412         [EFL] Speculative build fix after r155638.
413
414         * platform/efl/PasteboardEfl.cpp: Add include for PassRefPtr, which
415         is no longer implicitly included.
416
417 2013-09-12  Simon Fraser  <simon.fraser@apple.com>
418
419         Avoid extra scrollbar-related layouts for overlay scrollbars
420         https://bugs.webkit.org/show_bug.cgi?id=121267
421
422         Reviewed by Beth Dakin.
423
424         If ScrollView::updateScrollbars() detected that scrollbars were added
425         and removed, it would call contentsResized(), which calls setNeedsLayout(),
426         followed by visibleContentsResized() which would trigger layout. There is no
427         point doing this with overlay scrollbars, so avoid it by having 
428         setHas*Scrollbar() return true if the addition/removal of a scrollbar changed
429         the available width.
430         
431         No tests: we can't test overlay scrollbars in tests.
432
433         * page/FrameView.cpp:
434         (WebCore::FrameView::setContentsSize): Drive-by assertion that
435         checks that the unsigned m_deferSetNeedsLayouts doesn't wrap when
436         decremented.
437         * platform/ScrollView.cpp:
438         (WebCore::ScrollView::setHasHorizontalScrollbar): Return true if the addition/removal
439         changed available space.
440         (WebCore::ScrollView::setHasVerticalScrollbar): Ditto.
441         (WebCore::ScrollView::updateScrollbars): Only set sendContentResizedNotification
442         if available space was changed by addition/removal of scrollbars.
443         * platform/ScrollView.h:
444
445 2013-09-12  Zoltan Horvath  <zoltan@webkit.org>
446
447         [CSS Shapes] Rename shapeContainingBlockHeight to shapeContainingBlockLogicalHeight
448         https://bugs.webkit.org/show_bug.cgi?id=121252
449
450         Reviewed by Oliver Hunt.
451
452         No new tests, no behavior change.
453
454         * rendering/RenderBlockLineLayout.cpp:
455         (WebCore::pushShapeContentOverflowBelowTheContentBox):
456         * rendering/shapes/ShapeInfo.h:
457         (WebCore::ShapeInfo::shapeContainingBlockLogicalHeight):
458
459 2013-09-12  Samuel White  <samuel_white@apple.com>
460
461         <meter> element AXValue is listed as a writable value
462         https://bugs.webkit.org/show_bug.cgi?id=117650
463
464         Reviewed by Chris Fleizach.
465
466         No new tests, updated existing accessibility/meter-element.html test
467         to check writability. Changed meter element value to be unwritable.
468
469         * accessibility/AccessibilityRenderObject.cpp:
470         (WebCore::AccessibilityRenderObject::canSetValueAttribute):
471
472 2013-09-12  Renata Hodovan  <reni@webkit.org>
473
474         [Qt] SHOULD NEVER BE REACHED is touched WebCore::InputType::createStepRange
475         https://bugs.webkit.org/show_bug.cgi?id=121148
476
477         Reviewed by Kent Tamura.
478
479         Non-steppable input types must not rendered as slider even if its webkit-apperance style
480         property is set to slider-vertical/horizontal.
481
482         Test: platform/qt/fast/forms/range/slider-crash-on-input.html
483
484         * platform/qt/RenderThemeQStyle.cpp:
485         (WebCore::RenderThemeQStyle::paintSliderTrack):
486
487 2013-09-12  Ryosuke Niwa  <rniwa@webkit.org>
488
489         Qt and Windows build fix.
490
491         * page/animation/CSSPropertyAnimation.cpp:
492
493 2013-09-11  Ryosuke Niwa  <rniwa@webkit.org>
494
495         Encapsulate globals in CSSPropertyAnimation.cpp
496         https://bugs.webkit.org/show_bug.cgi?id=121205
497
498         Reviewed by Antti Koivisto.
499
500         Encapsulated the globals inside a newly added CSSPropertyAnimationWrapperMap. Also removed the circular
501         dependency from ShorthandPropertyWrapper's constructor to CSSPropertyAnimationWrapperMap::instance().
502         The circular dependency still exists in ensurePropertyMap but I'm going to remove it in the bug 121199.
503
504         * page/animation/CSSPropertyAnimation.cpp:
505         (WebCore::ShorthandPropertyWrapper::ShorthandPropertyWrapper): Takes a Vector of longhand wrappers instead of
506         calling wrapperForProperty in the middle of constructing the very table. This circular dependency is now
507         encapsulated in CSSPropertyAnimationWrapperMap::ensurePropertyMap.
508         (WebCore::CSSPropertyAnimationWrapperMap::instance): Added.
509         (WebCore::CSSPropertyAnimationWrapperMap::wrapperForProperty): Renamed from WebCore::wrapperForProperty.
510         (WebCore::CSSPropertyAnimationWrapperMap::wrapperForIndex): Added.
511         (WebCore::CSSPropertyAnimationWrapperMap::size): Added.
512         (WebCore::CSSPropertyAnimationWrapperMap::addPropertyWrapper): Renamed from WebCore::addPropertyWrapper. Also
513         cleaned up boolean logics to use early exits instead of nested ifs.
514         (WebCore::CSSPropertyAnimationWrapperMap::addShorthandProperties): Renamed from WebCore::addShorthandProperties.
515         (WebCore::CSSPropertyAnimationWrapperMap::ensurePropertyMap): Renamed from WebCore::ensurePropertyMap.
516         Added an alias gPropertyWrappers for m_propertyWrappers; this aliasing will be removed in the bug 121199.
517         (WebCore::CSSPropertyAnimation::blendProperties):
518         (WebCore::CSSPropertyAnimation::animationOfPropertyIsAccelerated):
519         (WebCore::CSSPropertyAnimation::animatableShorthandsAffectingProperty):
520         (WebCore::CSSPropertyAnimation::propertiesEqual):
521         (WebCore::CSSPropertyAnimation::getPropertyAtIndex):
522         (WebCore::CSSPropertyAnimation::getNumProperties):
523         * page/animation/CSSPropertyAnimation.h:
524         * rendering/style/RenderStyle.h:
525
526 2013-09-12  Anders Carlsson  <andersca@apple.com>
527
528         SharedBuffer::createNSData should return a RetainPtr<NSData>
529         https://bugs.webkit.org/show_bug.cgi?id=121237
530
531         Reviewed by Darin Adler.
532
533         This makes memory management cleared and fixes a leak in PDFDocumentImage::createPDFDocument.
534         We use a RetainPtr subclass as a stopgap measure to prevent code that does [buffer->createNSData() autorelease]
535         from compiling and crashing due to the NSData object being overreleased.
536
537         * loader/ResourceBuffer.h:
538         * loader/mac/ResourceBuffer.mm:
539         (WebCore::ResourceBuffer::createNSData):
540         * platform/SharedBuffer.h:
541         (WebCore::SharedBuffer::NSDataRetainPtr::NSDataRetainPtr):
542         * platform/graphics/mac/PDFDocumentImageMac.mm:
543         (WebCore::PDFDocumentImage::createPDFDocument):
544         * platform/mac/HTMLConverter.mm:
545         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
546         (fileWrapperForURL):
547         * platform/mac/PasteboardMac.mm:
548         (WebCore::fileWrapper):
549         (WebCore::Pasteboard::read):
550         (WebCore::documentFragmentWithRTF):
551         (WebCore::fragmentFromWebArchive):
552         * platform/mac/PlatformPasteboardMac.mm:
553         (WebCore::PlatformPasteboard::setBufferForType):
554         * platform/mac/SharedBufferMac.mm:
555         (WebCore::SharedBuffer::createNSData):
556
557 2013-09-12  Timothy Hatcher  <timothy@apple.com>
558
559         Remove more Timeline stuff we don't use
560         https://bugs.webkit.org/show_bug.cgi?id=121246
561
562         Reviewed by Joseph Pecoraro.
563
564         * inspector/InspectorController.cpp:
565         * inspector/InspectorController.h:
566         * inspector/InspectorDOMDebuggerAgent.cpp:
567         * inspector/InspectorDOMDebuggerAgent.h:
568         * inspector/InspectorProfilerAgent.cpp:
569         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
570         * inspector/InspectorProfilerAgent.h:
571         * inspector/InspectorTimelineAgent.cpp:
572         (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline):
573         * inspector/InspectorTimelineAgent.h:
574
575 2013-09-12  Christophe Dumez  <ch.dumez@sisa.samsung.com>
576
577         [EFL] Get rid of layering violations in PasteboardEfl.cpp
578         https://bugs.webkit.org/show_bug.cgi?id=121241
579
580         Reviewed by Darin Adler.
581
582         Get rid of layering violations in PasteboardEfl.cpp. For now, just mimic
583         the Mac port to avoid divergences and leave port-specific functions
584         unimplemented as the EFL port does not support the pasteboard functionality
585         yet.
586
587         No new tests, no behavior change.
588
589         * PlatformEfl.cmake:
590         * editing/Editor.cpp:
591         (WebCore::Editor::pasteAsPlainTextWithPasteboard):
592         (WebCore::Editor::cut):
593         (WebCore::Editor::copy):
594         (WebCore::Editor::copyURL):
595         (WebCore::Editor::copyImage):
596         * editing/Editor.h:
597         * editing/efl/EditorEfl.cpp: Added.
598         (WebCore::Editor::writeSelectionToPasteboard):
599         (WebCore::Editor::writeURLToPasteboard):
600         (WebCore::Editor::writeImageToPasteboard):
601         (WebCore::Editor::readPlainTextFromPasteboard):
602         (WebCore::Editor::pasteWithPasteboard):
603         * page/DragController.cpp:
604         (WebCore::DragController::startDrag):
605         * platform/Pasteboard.h:
606         * platform/efl/PasteboardEfl.cpp:
607
608 2013-09-12  Alberto Garcia  <berto@igalia.com>
609
610         [GTK] Unreviewed build fix after r155635.
611
612         Include DragData.h
613
614         * platform/gtk/PasteboardGtk.cpp:
615
616 2013-09-12  Brent Fulgham  <bfulgham@apple.com>
617
618         [Windows] Build fix after r155635.
619
620         Rubber Stamped by Darin Adler.
621
622         * platform/Pasteboard.h: Add missing compile guards for Windows port.
623
624 2013-09-12  Darin Adler  <darin@apple.com>
625
626         Reorganize Pasteboard.h to make it easier to read, and express plan for future work
627         https://bugs.webkit.org/show_bug.cgi?id=121234
628
629         Reviewed by Anders Carlsson.
630
631         * platform/Pasteboard.h: Move Mac/iOS-specific pasteboard names to the bottom of the
632         file rather than putting them up with forward declarations before the class. Removed
633         unneeded forward class declarations. Changed #if statements about migration to the
634         more modern non-layering-violation API to list platforms not yet migrated, rather than
635         listing platforms that have migrated (Mac). Move conditional code down below the
636         uncondiditional code so it's easier to see what the class is doing. Move layering-
637         violation code down to the bottom too, so it's easier to see the future class without
638         having the design mistakes mixed in. Sort platform-specific sections in alphabetical
639         order instead of random order. Did the destructor in a cleaner way so the #if is out
640         of the way after the class rather than in the class. Removed WebSmartPastePboardType,
641         WebURLPboardType, and WebURLsWithTitlesPboard declarations, since they are only used
642         inside the PasteboardMac.mm source file.
643
644         * platform/ios/PasteboardIOS.mm: Aded a FIXME comment.
645         * platform/mac/PasteboardMac.mm: Made the constants for pasteboard types be actual
646         constants, rather than global variables.
647
648 2013-09-12  Tamas Czene  <tczene@inf.u-szeged.hu>
649
650         [curl] Use utf8 for headers in CurlDownload.
651         https://bugs.webkit.org/show_bug.cgi?id=120413
652
653         Reviewed by Brent Fulgham.
654
655         * platform/network/curl/CurlDownload.cpp:
656         (WebCore::CurlDownload::headerCallback):
657
658 2013-09-12  Peter Gal  <galpeter@inf.u-szeged.hu>
659
660         [curl] Improve multipart response handling
661         https://bugs.webkit.org/show_bug.cgi?id=117735
662
663         Reviewed by Brent Fulgham.
664
665         The multipart/x-mixed-replace mime type in responses are ignored
666         with the curl network backend. To handle such responses the
667         MultipartHandle is introduced which will split the content using
668         the boundary specified by the mime type.
669
670         There are already existing tests (http/tests/multipart).
671
672         * WebCore.vcxproj/WebCore.vcxproj:
673         * WebCore.vcxproj/WebCore.vcxproj.filters:
674         * platform/network/HTTPParsers.cpp:
675         (WebCore::parseHTTPHeader):
676         * platform/network/HTTPParsers.h:
677         * platform/network/ResourceHandleInternal.h:
678         * platform/network/curl/MultipartHandle.cpp: Added.
679         (WebCore::MultipartHandle::extractBoundary):
680         (WebCore::MultipartHandle::matchForBoundary):
681         (WebCore::MultipartHandle::checkForBoundary):
682         (WebCore::MultipartHandle::parseHeadersIfPossible):
683         (WebCore::MultipartHandle::contentReceived):
684         (WebCore::MultipartHandle::processContent):
685         (WebCore::MultipartHandle::contentEnded):
686         (WebCore::MultipartHandle::didReceiveData):
687         (WebCore::MultipartHandle::didReceiveResponse):
688         * platform/network/curl/MultipartHandle.h: Added.
689         (WebCore::MultipartHandle::MultipartHandle):
690         (WebCore::MultipartHandle::~MultipartHandle):
691         * platform/network/curl/ResourceHandleManager.cpp:
692         (WebCore::writeCallback):
693         (WebCore::headerCallback):
694         (WebCore::ResourceHandleManager::downloadTimerCallback):
695
696 2013-09-12  Andreas Kling  <akling@apple.com>
697
698         Remove RenderApplet.
699         <https://webkit.org/b/121231>
700
701         Reviewed by Darin Adler.
702
703         Add a RenderEmbeddedObject::createForApplet(HTMLAppletElement&) and nuke
704         the RenderApplet class from orbit.
705
706 2013-09-12  Brent Fulgham  <bfulgham@apple.com>
707
708         [Windows] Build fix after r155621
709
710         Rubber-stamped by Anders Carlsson.
711
712         See also https://bugs.webkit.org/show_bug.cgi?id=121235 for
713         why this was necessary.
714
715         * css/MediaQueryEvaluator.cpp: Work around VS compiler bug.
716         * dom/make_names.pl: Ditto.
717         * loader/archive/ArchiveFactory.cpp: Ditto.
718         * rendering/svg/SVGPathData.cpp: Ditto.
719
720 2013-09-12  Anders Carlsson  <andersca@apple.com>
721
722         SharedBuffer::createCFData should return RetainPtr<CFDataRef>
723         https://bugs.webkit.org/show_bug.cgi?id=121230
724
725         Reviewed by Darin Adler.
726
727         * loader/ResourceBuffer.cpp:
728         (WebCore::ResourceBuffer::createCFData):
729         * loader/ResourceBuffer.h:
730         * loader/archive/cf/LegacyWebArchive.cpp:
731         (WebCore::LegacyWebArchive::createPropertyListRepresentation):
732         (WebCore::LegacyWebArchive::create):
733         * platform/SharedBuffer.h:
734         * platform/cf/SharedBufferCF.cpp:
735         (WebCore::SharedBuffer::createCFData):
736         * platform/graphics/cg/ImageSourceCG.cpp:
737         (WebCore::ImageSource::setData):
738         * platform/graphics/cg/PDFDocumentImage.cpp:
739         (WebCore::PDFDocumentImage::createPDFDocument):
740         * platform/graphics/mac/FontCustomPlatformData.cpp:
741         (WebCore::createFontCustomPlatformData):
742         * platform/mac/SharedBufferMac.mm:
743         (WebCore::SharedBuffer::createCFData):
744
745 2013-09-12  Zoltan Horvath  <zoltan@webkit.org>
746
747         Move LineInfo class into LineInfo.h
748         https://bugs.webkit.org/show_bug.cgi?id=121191
749
750         Reviewed by David Hyatt.
751
752         No new tests, no behavior change.
753
754         * GNUmakefile.list.am:
755         * Target.pri:
756         * WebCore.vcxproj/WebCore.vcxproj:
757         * WebCore.xcodeproj/project.pbxproj:
758         * rendering/LineInfo.h: Added.
759         (WebCore::LineInfo::LineInfo):
760         (WebCore::LineInfo::isFirstLine):
761         (WebCore::LineInfo::isLastLine):
762         (WebCore::LineInfo::isEmpty):
763         (WebCore::LineInfo::previousLineBrokeCleanly):
764         (WebCore::LineInfo::floatPaginationStrut):
765         (WebCore::LineInfo::runsFromLeadingWhitespace):
766         (WebCore::LineInfo::resetRunsFromLeadingWhitespace):
767         (WebCore::LineInfo::incrementRunsFromLeadingWhitespace):
768         (WebCore::LineInfo::setFirstLine):
769         (WebCore::LineInfo::setLastLine):
770         (WebCore::LineInfo::setEmpty):
771         (WebCore::LineInfo::setPreviousLineBrokeCleanly):
772         (WebCore::LineInfo::setFloatPaginationStrut):
773         * rendering/RenderBlockLineLayout.cpp:
774
775 2013-09-12  Bem Jones-Bey  <bjonesbe@adobe.com>
776
777         [CSS Shapes] Remove unnecessarily complex template from ShapeInfo classes
778         https://bugs.webkit.org/show_bug.cgi?id=121213
779
780         Reviewed by Darin Adler.
781
782         These classes were trying to be way too clever, and as a result were
783         hard to read and hard to debug. Replace the complex templated method
784         calls with virtual methods to make these classes much easier to
785         understand and maintain.
786
787         No new tests, no behavior change.
788
789         * rendering/shapes/ShapeInfo.cpp:
790         (WebCore::::computedShape):
791         (WebCore::::computeSegmentsForLine):
792         * rendering/shapes/ShapeInfo.h:
793         * rendering/shapes/ShapeInsideInfo.cpp:
794         (WebCore::ShapeInsideInfo::getShapeValue):
795         * rendering/shapes/ShapeInsideInfo.h:
796         (WebCore::ShapeInsideInfo::computeSegmentsForLine):
797         (WebCore::ShapeInsideInfo::ShapeInsideInfo):
798         * rendering/shapes/ShapeOutsideInfo.cpp:
799         (WebCore::ShapeOutsideInfo::computeSegmentsForLine):
800         (WebCore::ShapeOutsideInfo::getShapeValue):
801         * rendering/shapes/ShapeOutsideInfo.h:
802         (WebCore::ShapeOutsideInfo::ShapeOutsideInfo):
803
804 2013-09-12  Zoltan Horvath  <zoltan@webkit.org>
805
806         [CSS Shapes] Turn shape's logicalwidth/height into a LayoutSize
807         https://bugs.webkit.org/show_bug.cgi?id=121187
808
809         Reviewed by David Hyatt.
810
811         No new tests, no behavior change.
812
813         * rendering/shapes/ShapeInfo.cpp:
814         (WebCore::::computedShape):
815         * rendering/shapes/ShapeInfo.h:
816         (WebCore::ShapeInfo::setShapeSize):
817         (WebCore::ShapeInfo::shapeContainingBlockHeight):
818
819 2013-09-12  Darin Adler  <darin@apple.com>
820
821         Move layering-violating code from Pasteboard::plainText into Editor (Mac only at first)
822         https://bugs.webkit.org/show_bug.cgi?id=121075
823
824         Reviewed by Anders Carlsson.
825
826         * editing/Editor.cpp:
827         (WebCore::Editor::pasteAsPlainTextBypassingDHTML): Pass pasteboard as a reference.
828         (WebCore::Editor::pasteAsPlainTextWithPasteboard): Use readPlainTextFromPasteboard
829         for Mac. Also update to take a reference.
830         (WebCore::Editor::paste): Pass pasteboard as a reference.
831         (WebCore::Editor::pasteAsPlainText): Ditto.
832         * editing/Editor.h: Ditto.
833
834         * editing/mac/EditorMac.mm:
835         (WebCore::Editor::readSelectionFromPasteboard): Pass pasteboard as a reference.
836         (WebCore::Editor::readPlainTextFromPasteboard): Added. The declaration of this
837         was added (by mistake) in an earlier patch. This has code that used to be inside
838         Pasteboard::plainText.
839
840         * platform/Pasteboard.h: Added PasteboardPlainText. Reorganized functions in the
841         Pasteboard class and added some FIXMEs. Sorted platforms alphabetically and grouped
842         functions together and data members separate from them.
843
844         * platform/mac/DragDataMac.mm:
845         (WebCore::DragData::asPlainText): Updated to call readPlainTextFromPasteboard.
846         (WebCore::DragData::asURL): Tweaked style of unused parameter.
847
848         * platform/mac/PasteboardMac.mm:
849         (WebCore::Pasteboard::read): Renamed this from plainText, and refactored so that
850         the data goes out in the PasteboardPlainText structure.
851
852 2013-09-12  Gurpreet Kaur  <k.gurpreet@samsung.com>
853
854         CSS Unit vw in border-width maps to 0px.
855         https://bugs.webkit.org/show_bug.cgi?id=109229
856
857         Reviewed by Darin Adler.
858
859         Border and outline properties were not applied incase
860         its values were given in vh/vw units.
861
862         Tests: fast/css/viewport-height-border.html
863                fast/css/viewport-height-outline.html
864                fast/css/viewport-width-border.html
865                fast/css/viewport-width-outline.html
866
867         * css/CSSPrimitiveValue.cpp:
868         (WebCore::CSSPrimitiveValue::computeLengthDouble):
869         Added case CSS_VH and CSS_VW. 
870         * css/CSSPrimitiveValue.h:
871         (WebCore::CSSPrimitiveValue::isViewportPercentageWidth):
872         (WebCore::CSSPrimitiveValue::isViewportPercentageHeight):
873         Added APIs to check the unit type(CSS_VW and CSS_VH). 
874         * css/DeprecatedStyleBuilder.cpp:
875         (WebCore::ApplyPropertyComputeLength::applyValue):
876         Calculating the border values which has been specified
877         in vh/vw units.The vh/vw units are calcultated as percent
878         of viewport height and viewport width respectively.
879
880 2013-09-12  Jocelyn Turcotte  <jocelyn.turcotte@digia.com>
881
882         [Coordinated Graphics] Fix the build on MacOS 10.9
883         https://bugs.webkit.org/show_bug.cgi?id=121225
884
885         Reviewed by Darin Adler.
886
887         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
888
889 2013-09-12  Mark Lam  <mark.lam@apple.com>
890
891         Change debug hooks to pass sourceID and position info via the DebuggerCallFrame.
892         https://bugs.webkit.org/show_bug.cgi?id=121214.
893
894         Reviewed by Geoffrey Garen.
895
896         No new tests.
897
898         Also changed the Inspector's JavaScriptCallFrame to get the sourceID and
899         position info from its DebuggerCallFrame instead of caching those values.
900
901         * bindings/js/JavaScriptCallFrame.cpp:
902         (WebCore::JavaScriptCallFrame::JavaScriptCallFrame):
903         * bindings/js/JavaScriptCallFrame.h:
904         (WebCore::JavaScriptCallFrame::create):
905         (WebCore::JavaScriptCallFrame::invalidate):
906         (WebCore::JavaScriptCallFrame::sourceID):
907         (WebCore::JavaScriptCallFrame::position):
908         (WebCore::JavaScriptCallFrame::line):
909         (WebCore::JavaScriptCallFrame::column):
910         (WebCore::JavaScriptCallFrame::update):
911         * bindings/js/ScriptDebugServer.cpp:
912         (WebCore::ScriptDebugServer::createCallFrame):
913         (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
914         (WebCore::ScriptDebugServer::callEvent):
915         (WebCore::ScriptDebugServer::atStatement):
916         (WebCore::ScriptDebugServer::returnEvent):
917         (WebCore::ScriptDebugServer::exception):
918         (WebCore::ScriptDebugServer::willExecuteProgram):
919         (WebCore::ScriptDebugServer::didExecuteProgram):
920         (WebCore::ScriptDebugServer::didReachBreakpoint):
921         * bindings/js/ScriptDebugServer.h:
922         * bindings/js/WorkerScriptDebugServer.cpp:
923         (WebCore::WorkerScriptDebugServer::willExecuteProgram):
924         * bindings/js/WorkerScriptDebugServer.h:
925
926 2013-09-12  peavo@outlook.com  <peavo@outlook.com>
927
928         [WinCairo] Compile errors, missing include.
929         https://bugs.webkit.org/show_bug.cgi?id=121222
930
931         Reviewed by Brent Fulgham.
932
933         * platform/graphics/win/GlyphPageTreeNodeCairoWin.cpp: Include required header.
934         * platform/win/DragImageCairoWin.cpp: Include required header.
935
936 2013-09-12  Vivek Galatage  <vivek.vg@samsung.com>
937
938         XMLSerializer.serializeToString() should throw exception for invalid node value.
939         https://bugs.webkit.org/show_bug.cgi?id=121209
940
941         Reviewed by Darin Adler.
942
943         FF and Opera 12 (pre blink/webkit) throw exception in case the node value is invalid.
944         Blink sends an empty string as the result of serializeToString operation with invalid node.
945         We should match with other browsers for throwing it as an exception.
946
947         Blink review URL: https://chromiumcodereview.appspot.com/23532055/
948
949         Test: fast/dom/xmlserializer-serialize-to-string-exception.html
950
951         * xml/XMLSerializer.cpp:
952         (WebCore::XMLSerializer::serializeToString):
953
954 2013-09-12  Zalan Bujtas  <zalan@apple.com>
955
956         Crash in ScrollingStateStickyNode::updateConstraints
957         https://bugs.webkit.org/show_bug.cgi?id=119638
958
959         Reviewed by Simon Fraser.
960
961         Ensure when a scrolling state node is removed from the state tree,
962         we remove both the current node and all its children from the
963         associated m_stateNodeMap lookup table.
964
965         Test: fast/css/sticky/multiple-layers-sticky-crash.html
966
967         * page/scrolling/ScrollingStateNode.cpp:
968         (WebCore::ScrollingStateNode::removeChild):
969         (WebCore::ScrollingStateNode::willBeRemovedFromStateTree):
970         * page/scrolling/ScrollingStateNode.h:
971
972 2013-09-12  Zalan Bujtas  <zalan@apple.com>
973
974         REGRESSION (r132516): Javascript menu text incorrectly disappearing and reappearing
975         https://bugs.webkit.org/show_bug.cgi?id=101047
976
977         Reviewed by Simon Fraser.
978
979         Compositing layers keep track of ancestors' clipping by constructing the RenderLayerBacking::m_ancestorClippingLayer.
980         It helps setting up the proper clipping context for the corresponding graphics layer.
981         When a RenderObject's clipping style changes, it needs to propagate this change not only
982         to the associated RenderLayer, but also to the descendants', if applicable.
983         Before r132516, it was mainly covered by initiating full style recalcs, which ensured that
984         style recalc on the descendant rendering tree took care of creating/destroying
985         RenderLayerBacking::m_ancestorClippingLayer at every compositing layer node. Without the full
986         recalc, the clipping of the compositing render layers and the corresponding render subtrees can get out of sync.
987         This patch updates the clipping context on the descendant subtree, when the clipping behaviour
988         changes on a render node.
989
990         Tests: compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants.html
991                compositing/overflow/clipping-behaviour-change-is-not-propagated-to-descendants2.html
992
993         * rendering/RenderLayer.cpp:
994         (WebCore::RenderLayer::updateDescendantClippingContext):
995         (WebCore::RenderLayer::styleChanged):
996         * rendering/RenderLayer.h:
997         * rendering/RenderLayerBacking.cpp:
998         (WebCore::RenderLayerBacking::~RenderLayerBacking):
999         (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration):
1000         (WebCore::RenderLayerBacking::updateAncestorClippingLayer):
1001         (WebCore::RenderLayerBacking::updateDescendantClippingLayer):
1002         * rendering/RenderLayerBacking.h:
1003
1004 2013-09-12  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
1005
1006         Remove home-brewed nullptr
1007         https://bugs.webkit.org/show_bug.cgi?id=119624
1008
1009         Reviewed by Anders Carlsson.
1010
1011         The standard C++11 nullptr and std::nullptr_t type should be used now.
1012
1013         * bindings/js/JSDOMBinding.h:
1014
1015 2013-09-12  Samuel White  <samuel_white@apple.com>
1016
1017         <meter> element text value exposed as AXTitle; should be exposing AXValueDescription
1018         https://bugs.webkit.org/show_bug.cgi?id=117651
1019
1020         Reviewed by Mario Sanchez Prada.
1021
1022         No new tests, updated accessibility/meter-element to handle platform specific output.
1023
1024         * accessibility/AccessibilityObject.cpp:
1025         (WebCore::AccessibilityObject::isMeter):
1026         * accessibility/AccessibilityObject.h:
1027         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
1028         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
1029
1030 2013-09-12  Santosh Mahto  <santosh.ma@samsung.com>
1031
1032         class WeekInputType invokes wrong constructor
1033         https://bugs.webkit.org/show_bug.cgi?id=120768
1034
1035         Reviewed by Andreas Kling.
1036
1037         Correcting wrong constuctor invocation.
1038
1039         * html/WeekInputType.h:
1040         (WebCore::WeekInputType::WeekInputType):
1041
1042 2013-09-12  Samuel White  <samuel_white@apple.com>
1043
1044         AX: Self-referencing aria-labelledby only uses contents.
1045         https://bugs.webkit.org/show_bug.cgi?id=120814
1046
1047         Reviewed by Mario Sanchez Prada.
1048
1049         Implemented additional 'Text Alternative Computation' steps documented at:
1050         http://www.w3.org/WAI/PF/aria/complete#textalternativecomputation. This allows us to remove
1051         our raw text node iteration that was previously forcing us to do our computation incorrectly.
1052         Element content is now sourced using textUnderElement (step 2C of the computation).
1053
1054         Test: accessibility/self-referencing-aria-labelledby.html
1055
1056         * accessibility/AccessibilityNodeObject.cpp:
1057         (WebCore::accessibleNameForNode):
1058         (WebCore::AccessibilityNodeObject::accessibilityDescriptionForElements):
1059
1060 2013-09-12  Commit Queue  <commit-queue@webkit.org>
1061
1062         Unreviewed, rolling out r155597.
1063         http://trac.webkit.org/changeset/155597
1064         https://bugs.webkit.org/show_bug.cgi?id=121220
1065
1066         broke windows build because there's no ews :( (Requested by
1067         thorton on #webkit).
1068
1069         * WebCore.exp.in:
1070         * platform/graphics/BitmapImage.cpp:
1071         (WebCore::BitmapImage::isBitmapImage):
1072         * platform/graphics/BitmapImage.h:
1073         (WebCore::BitmapImage::create):
1074         * platform/graphics/CrossfadeGeneratedImage.cpp:
1075         (WebCore::CrossfadeGeneratedImage::CrossfadeGeneratedImage):
1076         (WebCore::CrossfadeGeneratedImage::drawPattern):
1077         * platform/graphics/CrossfadeGeneratedImage.h:
1078         (WebCore::CrossfadeGeneratedImage::setContainerSize):
1079         (WebCore::CrossfadeGeneratedImage::usesContainerSize):
1080         (WebCore::CrossfadeGeneratedImage::hasRelativeWidth):
1081         (WebCore::CrossfadeGeneratedImage::hasRelativeHeight):
1082         (WebCore::CrossfadeGeneratedImage::size):
1083         * platform/graphics/GeneratedImage.h:
1084         (WebCore::GeneratedImage::hasSingleSecurityOrigin):
1085         (WebCore::GeneratedImage::setContainerSize):
1086         (WebCore::GeneratedImage::usesContainerSize):
1087         (WebCore::GeneratedImage::hasRelativeWidth):
1088         (WebCore::GeneratedImage::hasRelativeHeight):
1089         (WebCore::GeneratedImage::size):
1090         (WebCore::GeneratedImage::destroyDecodedData):
1091         (WebCore::GeneratedImage::decodedSize):
1092         * platform/graphics/GeneratorGeneratedImage.cpp:
1093         (WebCore::GeneratorGeneratedImage::draw):
1094         (WebCore::GeneratorGeneratedImage::drawPattern):
1095         * platform/graphics/GeneratorGeneratedImage.h:
1096         (WebCore::GeneratorGeneratedImage::GeneratorGeneratedImage):
1097         * svg/graphics/SVGImage.h:
1098         (WebCore::SVGImage::isSVGImage):
1099         (WebCore::SVGImage::usesContainerSize):
1100         (WebCore::SVGImage::destroyDecodedData):
1101         (WebCore::SVGImage::decodedSize):
1102         * svg/graphics/SVGImageForContainer.h:
1103         (WebCore::SVGImageForContainer::destroyDecodedData):
1104         (WebCore::SVGImageForContainer::decodedSize):
1105
1106 2013-09-12  Andreas Kling  <akling@apple.com>
1107
1108         RenderWidget elements are always HTMLFrameOwnerElement subclasses.
1109         <https://webkit.org/b/121217>
1110
1111         Reviewed by Antti Koivisto.
1112
1113         Make RenderWidget constructor take HTMLFrameOwnerElement* and update subclasses
1114         with even tighter types where possible.
1115
1116         Also added RenderWidget::frameOwnerElement() and deleted element().
1117         Removed a handful of unnecessary type checks that were exposed by this.
1118
1119 2013-09-11  Tim Horton  <timothy_horton@apple.com>
1120
1121         Apply OVERRIDE and FINAL to Image subclasses and clean them up
1122         https://bugs.webkit.org/show_bug.cgi?id=121086
1123
1124         Reviewed by Alexey Proskuryakov.
1125
1126         Everything other than the copious application of OVERRIDE and FINAL
1127         is explicitly called out below.
1128
1129         * WebCore.exp.in:
1130         Export the correct version of getCGImageRef for use by WebKit2.
1131
1132         * platform/graphics/BitmapImage.cpp:
1133         * platform/graphics/BitmapImage.h:
1134         Drive-by inline isBitmapImage.
1135         Move create(HBITMAP) to be near the other create() functions.
1136         Move all of the members and quite a few functions from protected to private.
1137         Devirtualize frameCount().
1138         Move notSolidColor() near the other solid color functions.
1139
1140         * platform/graphics/CrossfadeGeneratedImage.cpp:
1141         (WebCore::CrossfadeGeneratedImage::CrossfadeGeneratedImage):
1142         (WebCore::CrossfadeGeneratedImage::drawPattern):
1143         * platform/graphics/GeneratorGeneratedImage.cpp:
1144         (WebCore::GeneratorGeneratedImage::draw):
1145         (WebCore::GeneratorGeneratedImage::drawPattern):
1146         Use size() and setContainerSize() instead of directly accessing a
1147         superclass' (now private, previously protected) members.
1148
1149         * platform/graphics/CrossfadeGeneratedImage.h:
1150         * platform/graphics/GeneratedImage.h:
1151         Make m_size private, I don't think we do protected members.
1152         
1153         * platform/graphics/GeneratorGeneratedImage.h:
1154         Make all the members private.
1155
1156         * svg/graphics/SVGImage.h:
1157         * svg/graphics/SVGImageForContainer.h:
1158
1159 2013-09-11  Rashmi Shyamasundar  <rashmi.s2@samsung.com>
1160
1161         Canvas fillText and measureText handle ideographic spaces differently
1162         https://bugs.webkit.org/show_bug.cgi?id=108881
1163
1164         Reviewed by Darin Adler.
1165
1166         According to spec for text preparation algorithm
1167         http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#text-preparation-algorithm
1168         all the space characters mentioned in the spec
1169         http://www.whatwg.org/specs/web-apps/current-work/multipage/common-microsyntaxes.html#space-character
1170         should be replaced by U+0020 space character.
1171         The canvas functions fillText and measureText should run the text preparation algorithm.
1172         This patch modifies the canvas functions drawTextInternal and measureText to conform to the above spec.
1173
1174         Tests: fast/canvas/canvas-measureText-ideographicSpace.html
1175
1176         * html/canvas/CanvasRenderingContext2D.cpp:
1177         (WebCore::shouldSpaceBeReplaced):
1178         (WebCore::replaceCharacterInString):
1179         (WebCore::CanvasRenderingContext2D::measureText):
1180         (WebCore::CanvasRenderingContext2D::drawTextInternal):
1181
1182 2013-09-11  Andreas Kling  <akling@apple.com>
1183
1184         Fix Windows build.
1185
1186         * rendering/RenderingAllInOne.cpp:
1187
1188 2013-09-11  Andreas Kling  <akling@apple.com>
1189
1190         Merge RenderPart into RenderWidget.
1191         <https://webkit.org/b/121200>
1192
1193         Reviewed by Anders Carlsson.
1194
1195         Remove the RenderPart class and move its functionality into RenderWidget.
1196         It was acting as a pointless extra layer between RenderWidget and renderers
1197         for embedded objects, frames and iframes.
1198
1199 2013-09-11  Geoffrey Garen  <ggaren@apple.com>
1200
1201         Removed some unused functions from the debugger interface
1202         https://bugs.webkit.org/show_bug.cgi?id=121194
1203
1204         Reviewed by Joseph Pecoraro.
1205
1206         We plan to use the "evaluate" API and debugger activation property access for all the features we need.
1207
1208         * inspector/JavaScriptCallFrame.idl: These are the interfaces I removed.
1209
1210         * bindings/js/JSJavaScriptCallFrameCustom.cpp:
1211         * inspector/InjectedScript.cpp:
1212         * inspector/InjectedScript.h:
1213         * inspector/InjectedScriptSource.js:
1214         * inspector/Inspector.json:
1215         * inspector/InspectorDebuggerAgent.cpp:
1216         (WebCore::InspectorDebuggerAgent::setScriptSource):
1217         * inspector/InspectorDebuggerAgent.h:
1218         * inspector/JavaScriptCallFrame.idl:
1219         * inspector/front-end/RemoteObject.js:
1220         (WebInspector.RemoteObject.prototype.):
1221         (WebInspector.RemoteObject.prototype.setPropertyValue): These files are mechanical removals of code that used
1222         or implemented the interfaces I removed.
1223
1224 2013-09-11  Vivek Galatage  <vivek.vg@samsung.com>
1225
1226         DOMParser.parseFromString() should support creating HTML Document with mime-type text/html
1227         https://bugs.webkit.org/show_bug.cgi?id=120826
1228
1229         Reviewed by Darin Adler.
1230
1231         The specification http://domparsing.spec.whatwg.org/#the-domparser-interface for DOMParser.parseFromString()
1232         allows the document creation if the mimeType is one of the supported types:
1233         ["text/html", "text/xml", "application/xml", "application/xhtml+xml", "image/svg+xml"]
1234
1235         Also script elements get marked unexecutable and the contents of noscript get parsed as markup.
1236
1237         blink review URL: https://codereview.chromium.org/23903014/
1238
1239         Test: fast/dom/domparser-parsefromstring-mimetype-support.html
1240
1241         * xml/DOMParser.cpp:
1242         (WebCore::DOMParser::parseFromString):
1243
1244 2013-09-11  Hans Muller  <hmuller@adobe.com>
1245
1246         [CSS Shapes] Improve the performance of image valued shapes
1247         https://bugs.webkit.org/show_bug.cgi?id=120211
1248
1249         Reviewed by Alexandru Chiculita.
1250
1251         Replaced the implementation of RasterShapeIntervals with one based on the
1252         new ShapeInterval<int> class. This eliminates the dependency the Region class
1253         and delivers a 10X layout speedup for large image valued shapes.
1254
1255         This a just an implementation refactoring, no new tests were needed.
1256
1257         * rendering/shapes/RasterShape.cpp:
1258         (WebCore::RasterShapeIntervals::appendInterval): Renamed this method, it was called addInterval().
1259         (WebCore::shapeIntervalsContain):
1260         (WebCore::RasterShapeIntervals::contains):
1261         (WebCore::RasterShapeIntervals::getIntervalsInLine):
1262         (WebCore::compareX1):
1263         (WebCore::RasterShapeIntervals::firstIncludedIntervalY):
1264         (WebCore::RasterShapeIntervals::getIncludedIntervals):
1265         (WebCore::RasterShapeIntervals::getExcludedIntervals):
1266         (WebCore::RasterShape::getExcludedIntervals):
1267         (WebCore::RasterShape::getIncludedIntervals):
1268         * rendering/shapes/RasterShape.h:
1269         (WebCore::RasterShapeIntervals::RasterShapeIntervals): The constructor now takes a size argument which is used to allocate IntShapeIntervals storage.
1270         (WebCore::RasterShapeIntervals::size):
1271         (WebCore::RasterShapeIntervals::bounds):
1272         (WebCore::RasterShapeIntervals::isEmpty):
1273         (WebCore::RasterShapeIntervals::getIntervals):
1274         * rendering/shapes/Shape.cpp:
1275         (WebCore::Shape::createShape): Use appendInterval() instead of addInterval() (see above) and the new RasterShapeIntervals constructor.
1276
1277 2013-09-11  Eric Carlson  <eric.carlson@apple.com>
1278
1279         [MediaStream API] Updating NavigatorUserMediaError to match the spec
1280         https://bugs.webkit.org/show_bug.cgi?id=120880
1281
1282         Reviewed by Darin Adler.
1283         
1284         Merge https://chromium.googlesource.com/chromium/blink/+/f07305e49ddebaa166f5dee514bcc881a8efd341
1285         by Tommy Widenflycht.
1286
1287         The Blink change did not have any test changes because they don't appear to have any tests 
1288         for NavigatorUserMediaError. I can't add tests now because the MediaStream feature isn't enabled 
1289         yet, so https://bugs.webkit.org/show_bug.cgi?id=121182 tracks adding tests.
1290
1291         * Modules/mediastream/NavigatorUserMediaError.h:
1292         (WebCore::NavigatorUserMediaError::create):
1293         (WebCore::NavigatorUserMediaError::name):
1294         (WebCore::NavigatorUserMediaError::message):
1295         (WebCore::NavigatorUserMediaError::constraintName):
1296         (WebCore::NavigatorUserMediaError::NavigatorUserMediaError):
1297         * Modules/mediastream/NavigatorUserMediaError.idl:
1298         * Modules/mediastream/UserMediaRequest.cpp:
1299         (WebCore::UserMediaRequest::fail):
1300         (WebCore::UserMediaRequest::failConstraint):
1301         * Modules/mediastream/UserMediaRequest.h:
1302
1303 2013-09-11  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1304
1305         MediaStream API: Remove LocalMediaStream
1306         https://bugs.webkit.org/show_bug.cgi?id=120875
1307
1308         blink merge: https://chromium.googlesource.com/chromium/blink/+/81643ee3fe048a64fa8931132e1294fa2c8e821a
1309
1310         Reviewed by Eric Carlson.
1311
1312         Existing tests were updated.
1313
1314         * CMakeLists.txt:
1315         * DerivedSources.make:
1316         * GNUmakefile.list.am:
1317         * Modules/mediastream/LocalMediaStream.cpp: Removed.
1318         * Modules/mediastream/LocalMediaStream.h: Removed.
1319         * Modules/mediastream/LocalMediaStream.idl: Removed.
1320         * Modules/mediastream/MediaStream.cpp:
1321         (WebCore::MediaStream::stop):
1322         * Modules/mediastream/MediaStream.h:
1323         * Modules/mediastream/MediaStream.idl:
1324         * Modules/mediastream/NavigatorUserMediaSuccessCallback.h:
1325         * Modules/mediastream/NavigatorUserMediaSuccessCallback.idl:
1326         * Modules/mediastream/UserMediaRequest.cpp:
1327         (WebCore::UserMediaRequest::succeed):
1328         * Modules/mediastream/UserMediaRequest.h:
1329         * Modules/webaudio/AudioContext.cpp:
1330         (WebCore::AudioContext::createMediaStreamSource):
1331         * Modules/webaudio/MediaStreamAudioDestinationNode.cpp:
1332         (WebCore::MediaStreamAudioDestinationNode::MediaStreamAudioDestinationNode):
1333         * WebCore.xcodeproj/project.pbxproj:
1334         * dom/EventTarget.h:
1335         * dom/EventTargetFactory.in:
1336         * platform/mediastream/MediaStreamDescriptor.h:
1337
1338 2013-09-11  Timothy Hatcher  <timothy@apple.com>
1339
1340         Remove PlatformInstrumentation since we don't show decode or resize in the new Web Inspector
1341         https://bugs.webkit.org/show_bug.cgi?id=121181
1342
1343         Reviewed by Joseph Pecoraro.
1344
1345         * CMakeLists.txt:
1346         * GNUmakefile.list.am:
1347         * Target.pri:
1348         * WebCore.order:
1349         * WebCore.vcxproj/WebCore.vcxproj:
1350         * WebCore.vcxproj/WebCore.vcxproj.filters:
1351         * WebCore.xcodeproj/project.pbxproj:
1352         * inspector/InspectorTimelineAgent.cpp:
1353         (WebCore::InspectorTimelineAgent::willPaint):
1354         (WebCore::InspectorTimelineAgent::didCompleteCurrentRecord):
1355         (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
1356         (WebCore::InspectorTimelineAgent::pushCurrentRecord):
1357         (WebCore::InspectorTimelineAgent::clearRecordStack):
1358         * inspector/InspectorTimelineAgent.h:
1359         * platform/PlatformInstrumentation.cpp: Removed.
1360         * platform/PlatformInstrumentation.h: Removed.
1361         * platform/image-decoders/bmp/BMPImageDecoder.cpp:
1362         (WebCore::BMPImageDecoder::frameBufferAtIndex):
1363         * platform/image-decoders/gif/GIFImageDecoder.cpp:
1364         (WebCore::GIFImageDecoder::frameBufferAtIndex):
1365         * platform/image-decoders/ico/ICOImageDecoder.cpp:
1366         (WebCore::ICOImageDecoder::frameBufferAtIndex):
1367         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
1368         (WebCore::JPEGImageDecoder::frameBufferAtIndex):
1369         * platform/image-decoders/png/PNGImageDecoder.cpp:
1370         (WebCore::PNGImageDecoder::frameBufferAtIndex):
1371         * platform/image-decoders/webp/WEBPImageDecoder.cpp:
1372         (WebCore::WEBPImageDecoder::frameBufferAtIndex):
1373
1374 2013-09-11  Brent Fulgham  <bfulgham@apple.com>
1375
1376         [Windows] Avoid converting from IntSize->SIZE->IntSize.
1377         https://bugs.webkit.org/show_bug.cgi?id=121180
1378
1379         Reviewed by Anders Carlsson.
1380
1381         * platform/graphics/BitmapImage.h: Take const IntSize* as
1382         argument, rather than LPSIZE.
1383         * platform/graphics/Image.h: Ditto.
1384         (WebCore::Image::getHBITMAPOfSize):
1385         * platform/graphics/win/ImageCGWin.cpp:
1386         (WebCore::BitmapImage::getHBITMAPOfSize): Use passed-in
1387         IntSize, rather than converting from SIZE.
1388         * platform/graphics/win/ImageCairoWin.cpp:
1389         (WebCore::BitmapImage::getHBITMAPOfSize): Ditto.
1390
1391 2013-09-11  Zoltan Horvath  <zoltan@webkit.org>
1392
1393         Unreviewed debug build fix after r155567.
1394
1395         * rendering/LineWidth.cpp:
1396         (WebCore::LineWidth::LineWidth):
1397
1398 2013-09-11  Zoltan Horvath  <zoltan@webkit.org>
1399
1400         Move LineWidth out of RenderBlockLineLayout
1401         https://bugs.webkit.org/show_bug.cgi?id=121107
1402
1403         Reviewed by David Hyatt.
1404
1405         Move LineWidth class and related code into LineWidth.{h,cpp}.
1406
1407         No new tests, no behavior change.
1408
1409         * CMakeLists.txt:
1410         * GNUmakefile.list.am:
1411         * Target.pri:
1412         * WebCore.vcxproj/WebCore.vcxproj:
1413         * WebCore.xcodeproj/project.pbxproj:
1414         * rendering/LineWidth.cpp: Added.
1415         (WebCore::LineWidth::applyOverhang):
1416         (WebCore::LineWidth::fitBelowFloats):
1417         * rendering/LineWidth.h: Added.
1418         (WebCore::logicalHeightForLine):
1419         (WebCore::LineWidth::LineWidth):
1420         (WebCore::LineWidth::fitsOnLine):
1421         (WebCore::LineWidth::fitsOnLineIncludingExtraWidth):
1422         (WebCore::LineWidth::fitsOnLineExcludingTrailingWhitespace):
1423         (WebCore::LineWidth::currentWidth):
1424         (WebCore::LineWidth::uncommittedWidth):
1425         (WebCore::LineWidth::committedWidth):
1426         (WebCore::LineWidth::availableWidth):
1427         (WebCore::LineWidth::addUncommittedWidth):
1428         (WebCore::LineWidth::commit):
1429         (WebCore::LineWidth::setTrailingWhitespaceWidth):
1430         (WebCore::LineWidth::shouldIndentText):
1431         (WebCore::LineWidth::computeAvailableWidthFromLeftAndRight):
1432         (WebCore::LineWidth::fitsOnLineExcludingTrailingCollapsedWhitespace):
1433         (WebCore::LineWidth::updateAvailableWidth):
1434         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
1435         * rendering/RenderBlockLineLayout.cpp:
1436
1437 2013-09-11  Ryosuke Niwa  <rniwa@webkit.org>
1438
1439         HTMLEntityTable could use char to reduce binary size
1440         https://bugs.webkit.org/show_bug.cgi?id=121176
1441
1442         Reviewed by Anders Carlsson.
1443
1444         Use LChar instead.
1445
1446         * html/parser/HTMLEntityParser.cpp:
1447         (WebCore::HTMLEntityParser::consumeNamedEntity):
1448         * html/parser/HTMLEntityTable.h:
1449         (WebCore::HTMLEntityTableEntry::lastCharacter):
1450         * html/parser/create-html-entity-table:
1451
1452 2013-09-11  Brent Fulgham  <bfulgham@apple.com>
1453
1454         [Windows] Revise GDI Create Functions to use GDIObject Smart Pointer.
1455         https://bugs.webkit.org/show_bug.cgi?id=121100
1456
1457         Reviewed by Anders Carlsson.
1458
1459         * platform/graphics/FontPlatformData.h: Use GDIObject instead of bare pointer.
1460         * platform/graphics/win/FontCacheWin.cpp:
1461         (WebCore::createGDIFont): No longer need to leak the pointer; use move semantic
1462         to pass ownership to FontPlatformData.
1463         (WebCore::FontCache::createFontPlatformData):
1464         * platform/graphics/win/FontCustomPlatformData.cpp:
1465         (WebCore::FontCustomPlatformData::fontPlatformData): Use move operation.
1466         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
1467         (WebCore::FontCustomPlatformData::fontPlatformData): Ditto.
1468         * platform/graphics/win/FontPlatformDataCGWin.cpp:
1469         (WebCore::FontPlatformData::FontPlatformData): Ditto.
1470         * platform/graphics/win/FontPlatformDataCairoWin.cpp:
1471         (WebCore::FontPlatformData::FontPlatformData): Ditto.
1472         * platform/graphics/win/FontPlatformDataWin.cpp:
1473         (WebCore::FontPlatformData::FontPlatformData): Ditto.
1474         * platform/graphics/win/GlyphPageTreeNodeCairoWin.cpp:
1475         (WebCore::GlyphPage::fill): Use HWndDC smart pointer instead of bare HDC.
1476         * platform/graphics/win/SimpleFontDataWin.cpp:
1477         (WebCore::SimpleFontData::platformCreateScaledFontData): Use move operation.
1478         * platform/win/DragImageCGWin.cpp:
1479         (WebCore::allocImage): Change to use GDIObject.
1480         (WebCore::scaleDragImage): Use smart pointers to avoid manual deallocs.
1481         (WebCore::createDragImageFromImage): Ditto.
1482         * platform/win/DragImageCairoWin.cpp:
1483         (WebCore::allocImage): Change to use GDIObject.
1484         (WebCore::scaleDragImage): Use smart pointers to avoid manual deallocs.
1485         (WebCore::createDragImageFromImage): Ditto.
1486         * platform/win/DragImageWin.cpp:
1487         (WebCore::createDragImageForLink): Update for GDIObject.
1488         * platform/win/PopupMenuWin.cpp:
1489         (WebCore::PopupMenuWin::PopupMenuWin): Switch to GDIObject.
1490         (WebCore::PopupMenuWin::~PopupMenuWin): Remove uneeded deallocs.
1491         (WebCore::PopupMenuWin::paint): Update for GDIObject.
1492         * platform/win/PopupMenuWin.h: Use smart pointers instead of bare GDI objects.
1493
1494 2013-09-11  Patrick Gansterer  <paroga@webkit.org>
1495
1496         Fix animations with !USE(ACCELERATED_COMPOSITING) after r147792.
1497         https://bugs.webkit.org/show_bug.cgi?id=121159
1498
1499         Reviewed by Simon Fraser.
1500
1501         CSSPropertyAnimation::blendProperties() is available always
1502         and needs to be called to make the animations work.
1503
1504         * page/animation/ImplicitAnimation.cpp:
1505         (WebCore::ImplicitAnimation::animate):
1506         * page/animation/KeyframeAnimation.cpp:
1507         (WebCore::KeyframeAnimation::animate):
1508
1509 2013-09-11  David Hyatt  <hyatt@apple.com>
1510
1511         Move all collapsing margin code out of RenderBlock and into RenderBlockFlow.
1512         https://bugs.webkit.org/show_bug.cgi?id=121049
1513
1514         Reviewed by Dean Jackson.
1515
1516         This patch begins the migration of the rare data struct of RenderBlock into
1517         RenderBlockFlow. During this process we will temporarily have rare data structs
1518         in both places, but ultimately all of the members are going to move down into
1519         RenderBlockFlow, and if any don't, they will get forced into a hash.
1520         
1521         For this patch, the margin information is being shifted out of RenderBlock and into
1522         RenderBlockFlow. Any functions that refer to MarginValues or to MarginInfo also got
1523         moved down into RenderBlockFlow. Most of block child layout is now in RenderBlockFlow
1524         after this patch.
1525         
1526         Note that in many cases the code didn't simply move. There is some type tightening
1527         that happened as well, i.e., places that look for RenderBlock can now look for
1528         RenderBlockFlow instead and let RenderBlock execute the base RenderBox functions.
1529
1530         * rendering/RenderBlock.cpp:
1531         (WebCore::RenderBlock::RenderBlock):
1532         (WebCore::RenderBlock::setPaginationStrut):
1533         (WebCore::RenderBlock::setPageLogicalOffset):
1534         (WebCore::RenderBlock::setBreakAtLineToAvoidWidow):
1535         * rendering/RenderBlock.h:
1536         (WebCore::RenderBlock::setLineGridBox):
1537         (WebCore::RenderBlock::setShapeInsideInfo):
1538         (WebCore::RenderBlock::RenderBlockRareData::RenderBlockRareData):
1539         * rendering/RenderBlockFlow.cpp:
1540         (WebCore::RenderBlockFlow::MarginInfo::MarginInfo):
1541         (WebCore::RenderBlockFlow::RenderBlockFlow):
1542         (WebCore::RenderBlockFlow::layoutBlockChild):
1543         (WebCore::RenderBlockFlow::adjustPositionedBlock):
1544         (WebCore::RenderBlockFlow::adjustFloatingBlock):
1545         (WebCore::RenderBlockFlow::marginValuesForChild):
1546         (WebCore::RenderBlockFlow::collapseMargins):
1547         (WebCore::RenderBlockFlow::clearFloatsIfNeeded):
1548         (WebCore::RenderBlockFlow::marginBeforeEstimateForChild):
1549         (WebCore::RenderBlockFlow::estimateLogicalTopPosition):
1550         (WebCore::RenderBlockFlow::setCollapsedBottomMargin):
1551         (WebCore::RenderBlockFlow::handleAfterSideOfBlock):
1552         (WebCore::RenderBlockFlow::setMaxMarginBeforeValues):
1553         (WebCore::RenderBlockFlow::setMaxMarginAfterValues):
1554         (WebCore::RenderBlockFlow::setMustDiscardMarginBefore):
1555         (WebCore::RenderBlockFlow::setMustDiscardMarginAfter):
1556         (WebCore::RenderBlockFlow::mustDiscardMarginBefore):
1557         (WebCore::RenderBlockFlow::mustDiscardMarginAfter):
1558         (WebCore::RenderBlockFlow::mustDiscardMarginBeforeForChild):
1559         (WebCore::RenderBlockFlow::mustDiscardMarginAfterForChild):
1560         (WebCore::RenderBlockFlow::mustSeparateMarginBeforeForChild):
1561         (WebCore::RenderBlockFlow::mustSeparateMarginAfterForChild):
1562         (WebCore::inNormalFlow):
1563         (WebCore::RenderBlockFlow::applyBeforeBreak):
1564         (WebCore::RenderBlockFlow::applyAfterBreak):
1565         (WebCore::RenderBlockFlow::adjustBlockChildForPagination):
1566         * rendering/RenderBlockFlow.h:
1567         (WebCore::RenderBlockFlow::MarginValues::MarginValues):
1568         (WebCore::RenderBlockFlow::MarginValues::positiveMarginBefore):
1569         (WebCore::RenderBlockFlow::MarginValues::negativeMarginBefore):
1570         (WebCore::RenderBlockFlow::MarginValues::positiveMarginAfter):
1571         (WebCore::RenderBlockFlow::MarginValues::negativeMarginAfter):
1572         (WebCore::RenderBlockFlow::MarginValues::setPositiveMarginBefore):
1573         (WebCore::RenderBlockFlow::MarginValues::setNegativeMarginBefore):
1574         (WebCore::RenderBlockFlow::MarginValues::setPositiveMarginAfter):
1575         (WebCore::RenderBlockFlow::MarginValues::setNegativeMarginAfter):
1576         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::RenderBlockFlowRareData):
1577         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::positiveMarginBeforeDefault):
1578         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::negativeMarginBeforeDefault):
1579         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::positiveMarginAfterDefault):
1580         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::negativeMarginAfterDefault):
1581         (WebCore::RenderBlockFlow::MarginInfo::setAtBeforeSideOfBlock):
1582         (WebCore::RenderBlockFlow::MarginInfo::setAtAfterSideOfBlock):
1583         (WebCore::RenderBlockFlow::MarginInfo::clearMargin):
1584         (WebCore::RenderBlockFlow::MarginInfo::setHasMarginBeforeQuirk):
1585         (WebCore::RenderBlockFlow::MarginInfo::setHasMarginAfterQuirk):
1586         (WebCore::RenderBlockFlow::MarginInfo::setDeterminedMarginBeforeQuirk):
1587         (WebCore::RenderBlockFlow::MarginInfo::setPositiveMargin):
1588         (WebCore::RenderBlockFlow::MarginInfo::setNegativeMargin):
1589         (WebCore::RenderBlockFlow::MarginInfo::setPositiveMarginIfLarger):
1590         (WebCore::RenderBlockFlow::MarginInfo::setNegativeMarginIfLarger):
1591         (WebCore::RenderBlockFlow::MarginInfo::setMargin):
1592         (WebCore::RenderBlockFlow::MarginInfo::setCanCollapseMarginAfterWithChildren):
1593         (WebCore::RenderBlockFlow::MarginInfo::setDiscardMargin):
1594         (WebCore::RenderBlockFlow::MarginInfo::atBeforeSideOfBlock):
1595         (WebCore::RenderBlockFlow::MarginInfo::canCollapseWithMarginBefore):
1596         (WebCore::RenderBlockFlow::MarginInfo::canCollapseWithMarginAfter):
1597         (WebCore::RenderBlockFlow::MarginInfo::canCollapseMarginBeforeWithChildren):
1598         (WebCore::RenderBlockFlow::MarginInfo::canCollapseMarginAfterWithChildren):
1599         (WebCore::RenderBlockFlow::MarginInfo::quirkContainer):
1600         (WebCore::RenderBlockFlow::MarginInfo::determinedMarginBeforeQuirk):
1601         (WebCore::RenderBlockFlow::MarginInfo::hasMarginBeforeQuirk):
1602         (WebCore::RenderBlockFlow::MarginInfo::hasMarginAfterQuirk):
1603         (WebCore::RenderBlockFlow::MarginInfo::positiveMargin):
1604         (WebCore::RenderBlockFlow::MarginInfo::negativeMargin):
1605         (WebCore::RenderBlockFlow::MarginInfo::discardMargin):
1606         (WebCore::RenderBlockFlow::MarginInfo::margin):
1607         (WebCore::RenderBlockFlow::maxPositiveMarginBefore):
1608         (WebCore::RenderBlockFlow::maxNegativeMarginBefore):
1609         (WebCore::RenderBlockFlow::maxPositiveMarginAfter):
1610         (WebCore::RenderBlockFlow::maxNegativeMarginAfter):
1611         (WebCore::RenderBlockFlow::initMaxMarginValues):
1612         * rendering/RenderDeprecatedFlexibleBox.cpp:
1613         (WebCore::RenderDeprecatedFlexibleBox::layoutBlock):
1614         * rendering/RenderTable.cpp:
1615         (WebCore::RenderTable::layout):
1616
1617 2013-09-11  Myles C. Maxfield  <mmaxfield@apple.com>
1618
1619         Fix nested unicode-bidi: isolate
1620         https://bugs.webkit.org/show_bug.cgi?id=120504
1621
1622         Reviewed by Darin Adler.
1623
1624         When we have a nested isolate renderer if the outer isolate has a text
1625         and this text is not the first child, the isolated chain is not
1626         rendered correctly. This happens because constructBidiRunsForSegment
1627         uses always the first inner isolated renderer as isolated inline
1628         container. This patch fixes the behavior described changing
1629         containingIsolate to find the right isolated container.
1630
1631         Merged from Blink: https://chromium.googlesource.com/chromium/blink/+/840a57050eade39dd04dde0c6603e129b783151c
1632
1633         Tests: fast/text/international/unicode-bidi-isolate-nested-first-child-text.html
1634                fast/text/international/unicode-bidi-isolate-nested-simple.html
1635
1636         * rendering/InlineIterator.h:
1637         (WebCore::containingIsolate):
1638         * rendering/RenderBlockLineLayout.cpp:
1639         (WebCore::constructBidiRunsForSegment):
1640
1641 2013-09-11  Alexey Proskuryakov  <ap@apple.com>
1642
1643         https://bugs.webkit.org/show_bug.cgi?id=121169
1644         media/track/track-cue-rendering-vertical.html is flaky on Mac
1645
1646         Reviewed by Eric Carlson.
1647
1648         * html/shadow/MediaControlElements.cpp:
1649         (WebCore::MediaControlTextTrackContainerElement::updateSizes): Added a FIXME.
1650
1651 2013-09-11  Anders Carlsson  <andersca@apple.com>
1652
1653         Stop using deleteAllValues in SVG code
1654         https://bugs.webkit.org/show_bug.cgi?id=121172
1655
1656         Reviewed by Antti Koivisto.
1657
1658         Use OwnPtr for values instead.
1659
1660         * rendering/svg/RenderSVGResourceClipper.cpp:
1661         (WebCore::RenderSVGResourceClipper::~RenderSVGResourceClipper):
1662         (WebCore::RenderSVGResourceClipper::removeAllClientsFromCache):
1663         (WebCore::RenderSVGResourceClipper::removeClientFromCache):
1664         (WebCore::RenderSVGResourceClipper::applyClippingToContext):
1665         * rendering/svg/RenderSVGResourceClipper.h:
1666         * rendering/svg/RenderSVGResourceFilter.cpp:
1667         (WebCore::RenderSVGResourceFilter::~RenderSVGResourceFilter):
1668         (WebCore::RenderSVGResourceFilter::removeAllClientsFromCache):
1669         (WebCore::RenderSVGResourceFilter::removeClientFromCache):
1670         (WebCore::RenderSVGResourceFilter::applyResource):
1671         (WebCore::RenderSVGResourceFilter::postApplyResource):
1672         (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged):
1673         * rendering/svg/RenderSVGResourceFilter.h:
1674         * rendering/svg/RenderSVGResourceMasker.cpp:
1675         (WebCore::RenderSVGResourceMasker::~RenderSVGResourceMasker):
1676         (WebCore::RenderSVGResourceMasker::removeAllClientsFromCache):
1677         (WebCore::RenderSVGResourceMasker::removeClientFromCache):
1678         (WebCore::RenderSVGResourceMasker::applyResource):
1679         * rendering/svg/RenderSVGResourceMasker.h:
1680
1681 2013-09-11  Ryosuke Niwa  <rniwa@webkit.org>
1682
1683         Make the table static const.
1684
1685         * css/makeprop.pl:
1686
1687 2013-09-11  Timothy Hatcher  <timothy@apple.com>
1688
1689         Remove TimelineTraceEventProcessor since no current ports use it
1690         https://bugs.webkit.org/show_bug.cgi?id=121171
1691
1692         Reviewed by Joseph Pecoraro.
1693
1694         * CMakeLists.txt:
1695         * GNUmakefile.list.am:
1696         * Target.pri:
1697         * WebCore.vcxproj/WebCore.vcxproj:
1698         * WebCore.vcxproj/WebCore.vcxproj.filters:
1699         * WebCore.xcodeproj/project.pbxproj:
1700         * inspector/InspectorAllInOne.cpp:
1701         * inspector/InspectorClient.h:
1702         * inspector/InspectorInstrumentation.cpp:
1703         * inspector/InspectorInstrumentation.h:
1704         * inspector/InspectorTimelineAgent.cpp:
1705         (WebCore::InspectorTimelineAgent::start):
1706         (WebCore::InspectorTimelineAgent::stop):
1707         * inspector/InspectorTimelineAgent.h:
1708         * inspector/TimelineTraceEventProcessor.cpp: Removed.
1709         * inspector/TimelineTraceEventProcessor.h: Removed.
1710
1711 2013-09-11  Commit Queue  <commit-queue@webkit.org>
1712
1713         Unreviewed, rolling out r155519.
1714         http://trac.webkit.org/changeset/155519
1715         https://bugs.webkit.org/show_bug.cgi?id=121174
1716
1717         Included regression test fails, and an existing test started
1718         to crash (Requested by ap on #webkit).
1719
1720         * dom/Document.cpp:
1721         (WebCore::Document::hoveredElementDidDetach):
1722         * page/EventHandler.cpp:
1723         (WebCore::EventHandler::EventHandler):
1724         (WebCore::EventHandler::clear):
1725         (WebCore::EventHandler::handleMouseMoveEvent):
1726         (WebCore::EventHandler::scheduleHoverStateUpdate):
1727         (WebCore::EventHandler::hoverTimerFired):
1728         * page/EventHandler.h:
1729
1730 2013-09-11  Anders Carlsson  <andersca@apple.com>
1731
1732         Stop using deleteAllValues in SVG code
1733         https://bugs.webkit.org/show_bug.cgi?id=121172
1734
1735         Reviewed by Antti Koivisto.
1736
1737         Use OwnPtr for values instead.
1738
1739         * rendering/svg/RenderSVGResourceClipper.cpp:
1740         (WebCore::RenderSVGResourceClipper::~RenderSVGResourceClipper):
1741         (WebCore::RenderSVGResourceClipper::removeAllClientsFromCache):
1742         (WebCore::RenderSVGResourceClipper::removeClientFromCache):
1743         (WebCore::RenderSVGResourceClipper::applyClippingToContext):
1744         * rendering/svg/RenderSVGResourceClipper.h:
1745         * rendering/svg/RenderSVGResourceFilter.cpp:
1746         (WebCore::RenderSVGResourceFilter::~RenderSVGResourceFilter):
1747         (WebCore::RenderSVGResourceFilter::removeAllClientsFromCache):
1748         (WebCore::RenderSVGResourceFilter::removeClientFromCache):
1749         (WebCore::RenderSVGResourceFilter::applyResource):
1750         (WebCore::RenderSVGResourceFilter::postApplyResource):
1751         (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged):
1752         * rendering/svg/RenderSVGResourceFilter.h:
1753         * rendering/svg/RenderSVGResourceMasker.cpp:
1754         (WebCore::RenderSVGResourceMasker::~RenderSVGResourceMasker):
1755         (WebCore::RenderSVGResourceMasker::removeAllClientsFromCache):
1756         (WebCore::RenderSVGResourceMasker::removeClientFromCache):
1757         (WebCore::RenderSVGResourceMasker::applyResource):
1758         * rendering/svg/RenderSVGResourceMasker.h:
1759
1760 2013-09-10  Simon Fraser  <simon.fraser@apple.com>
1761
1762         REGRESSION (143483): overflow:hidden doesn't quash big repaints from text-indent: -9999px
1763         https://bugs.webkit.org/show_bug.cgi?id=121137
1764
1765         Reviewed by Ryosuke Niwa.
1766         
1767         The change in r143483 made it so that negative text-indent gets added
1768         to visual oveflow even when we have overflow:hidden, which is really bad
1769         because it causes large repaints (and large layers) for a common-on-the-web
1770         pattern.
1771         
1772         Revert the change, and add a new test to make sure it doesn't regress.
1773         
1774         I can't reproduce the bug it was trying to fix with the change reverted.
1775
1776         Tests: compositing/geometry/negative-text-indent-with-overflow-hidden-layer.html
1777                fast/repaint/negative-text-indent-with-overflow-hidden.html
1778
1779         * rendering/RenderBlock.cpp:
1780         (WebCore::RenderBlock::computeOverflow):
1781
1782 2013-09-10  Simon Fraser  <simon.fraser@apple.com>
1783
1784         Optionally show visual and layout overflow rects in layer tree dumps
1785         https://bugs.webkit.org/show_bug.cgi?id=121135
1786
1787         Reviewed by Beth Dakin.
1788
1789         When calling showLayerTree() from the debugger, show overflow rects
1790         (visaul and layout) for renderers.
1791         
1792         Does not affect test output.
1793
1794         * rendering/RenderLayer.cpp:
1795         (showLayerTree): Pass the new flag to show overflow rects.
1796         * rendering/RenderTreeAsText.cpp:
1797         (WebCore::RenderTreeAsText::writeRenderObject): Print the rects.
1798         (WebCore::write): Don't force layout on subframes if the "dont' layout"
1799         flag is set.
1800         * rendering/RenderTreeAsText.h: New flag.
1801
1802 2013-09-11  Chris Fleizach  <cfleizach@apple.com>
1803
1804         AX: WebKit exposes AXTitleUIElement incorrectly on checkboxes and radio buttons
1805         https://bugs.webkit.org/show_bug.cgi?id=121039
1806
1807         Reviewed by Sam Weinig.
1808
1809         Stop hiding <label> elements for radio buttons and checkboxes (and using the text inside them for the AXTitle).
1810         Instead, expose the <label> element as the titleUIElement if appropriate for the input.
1811
1812         This implies:
1813            1) The web will no longer match MacOS behavior exactly (the text and the checkbox control are combined on MacOS into one element)
1814            2) But, the user will now be able to explore the <label> element which may include links or other important controls.
1815         I think sacrificing 1) here is a good tradeoff. The user will likely never know the difference in terms of output.
1816
1817         Test: platform/mac/accessibility/label-elements-exposed-as-title-ui-elements.html
1818
1819         * accessibility/AccessibilityNodeObject.cpp:
1820         (WebCore::AccessibilityNodeObject::titleElementText):
1821         (WebCore::AccessibilityNodeObject::title):
1822         * accessibility/AccessibilityRenderObject.cpp:
1823         (WebCore::AccessibilityRenderObject::hasTextAlternative):
1824         (WebCore::AccessibilityRenderObject::exposesTitleUIElement):
1825
1826 2013-09-11  Andreas Kling  <akling@apple.com>
1827
1828         Remove unnecessary Document::frame() null checks in rendererIsNeeded().
1829         <https://webkit.org/b/121166>
1830
1831         Reviewed by Anders Carlsson.
1832
1833         rendererIsNeeded() is only called during style resolve, which only happens
1834         while there's a Frame present.
1835
1836         * html/HTMLEmbedElement.cpp:
1837         (WebCore::HTMLEmbedElement::rendererIsNeeded):
1838         * html/HTMLMediaElement.cpp:
1839         (WebCore::HTMLMediaElement::rendererIsNeeded):
1840         * html/HTMLObjectElement.cpp:
1841         * html/HTMLObjectElement.h:
1842
1843 2013-09-11  Csaba Osztrogon√°c  <ossy@webkit.org>
1844
1845         ARM buildfix after r155491
1846         https://bugs.webkit.org/show_bug.cgi?id=121152
1847
1848         Reviewed by Anders Carlsson.
1849
1850         FELightingNEON.cpp and FELightingNEON.h is inside COMPILER(GCC) guard, so it's safe to use GCC attribute.
1851
1852         * platform/graphics/cpu/arm/filters/FELightingNEON.cpp: Use __aligned__ GCC attribute directly.
1853         * platform/graphics/cpu/arm/filters/FELightingNEON.h: Use __aligned__ GCC attribute instead of ugly template magic.
1854         (WebCore::FELighting::platformApplyNeon):
1855
1856 2013-09-11  peavo@outlook.com  <peavo@outlook.com>
1857
1858         [WinCairo] Compile errors.
1859         https://bugs.webkit.org/show_bug.cgi?id=121153
1860
1861         Reviewed by Brent Fulgham.
1862
1863         * page/win/FrameCairoWin.cpp:
1864         (WebCore::imageFromRect): Return empty GDIObject.
1865         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
1866         (WebCore::FontCustomPlatformData::fontPlatformData): Get actual handle from GDIObject.
1867
1868 2013-09-11  Darin Adler  <darin@apple.com>
1869
1870         Rework CSS parser, eliminating "floating" concept and using %destructor
1871         https://bugs.webkit.org/show_bug.cgi?id=121161
1872
1873         Reviewed by Antti Koivisto.
1874
1875         This is some basic improvement, but there is still room for a lot more
1876         consistent approach and formatting in this file. There is a mix of code that
1877         works by side effects in the CSSParser class and code that works with the
1878         values that bison generates in the union that is more or less random. And
1879         the data structures seem too costly, with too much heap allocation. And the
1880         CSSParser class has grown massive, with a mix of both function for use by
1881         code that wants to trigger parsing, and helper functions called by code in
1882         the grammar file. All of that can benefit from more refinement in the future.
1883
1884         * css/CSSGrammar.y.in: Made some incremental improvements to the structure
1885         of the grammar file, including:
1886         - Breaking up the %union so types are declared next to their use
1887         - Eliminating one shift/reduce conflict caused by two "maybe_space" in a row
1888         - Breaking the conditional sections out into their own sections instead of
1889           scattering them in with the other code.
1890         - Eliminating unused return values in productions such as charset,
1891           ignored_charset, namespace, margin_box, invalid_rule, save_block,
1892           invalid_at, and declarations_and_margins.
1893         - Adding %destructor to productions that return values that need to be deleted
1894           or deref'd. This removes the need for CSSParser to separately track these
1895           as "floating" to clean up in case of errors.
1896         - Removing unneeded productions such as media_feature, region_selector,
1897           attr_name, and medium.
1898         - Removing explicit code blocks that just say "$$ = $1" or empty blocks when
1899           there is no return type, since those are default.
1900         - Formatting many productions on single lines since I find them easier to read.
1901           Later I think we could make many more CSSParser functions and make even
1902           more of the production single lines in the grammar file.
1903         - Using adoptPtr, adoptRef, delete, deref, leakPtr, and leakRef to put
1904           heap allocated values into and out of the union without storage leaks.
1905           
1906         * css/CSSParser.cpp:
1907         (WebCore::CSSParser::~CSSParser): Remove the now-unneeded deleteAllValues for
1908         the various colections of floating things.
1909         (WebCore::CSSParser::createFilterRule): Don't put the rule into m_parsedRules,
1910         just return a PassRefPtr instead.
1911         (WebCore::CSSParser::createImportRule): Ditto.
1912         (WebCore::CSSParser::createMediaRule): Ditto.
1913         (WebCore::CSSParser::createEmptyMediaRule): Ditto.
1914         (WebCore::CSSParser::createSupportsRule): Ditto.
1915         (WebCore::CSSParser::createKeyframesRule): Ditto.
1916         (WebCore::CSSParser::createStyleRule): Ditto.
1917         (WebCore::CSSParser::createFontFaceRule): Ditto.
1918         (WebCore::CSSParser::createHostRule): Ditto.
1919         (WebCore::CSSParser::rewriteSpecifiersWithNamespaceIfNeeded): Got rid of the
1920         unused return value from this function and changed it to to take a reference
1921         instead of a pointer.
1922         (WebCore::CSSParser::rewriteSpecifiersWithElementName): Ditto.
1923         (WebCore::CSSParser::rewriteSpecifiers): Changed this to take and return OwnPtr.
1924         (WebCore::CSSParser::createPageRule): Don't put rule into m_parsedRules, return
1925         PassRefPtr instead.
1926         (WebCore::CSSParser::createSelectorVector): Added. Used to implement the
1927         optimization where we recycle a single selector vector. Not sure we still need
1928         this, or maybe we need more optimizations like it, but for now keep it.
1929         (WebCore::CSSParser::recycleSelectorVector): Ditto.
1930         (WebCore::CSSParser::createRegionRule): Don't put rule into m_parsedRules, return
1931         PassRefPtr instead.
1932         (WebCore::CSSParser::createMarginAtRule): Got rid of unused return value.
1933         When this function is implemented for real, we might add a return value.
1934         (WebCore::CSSParser::createKeyframe): Don't put keyframe into m_parsedKeyframes,
1935         return PassRefPtr instead.
1936         (WebCore::CSSParser::createViewportRule): Don't put rule into m_parsedRules, return
1937         PassRefPtr instead.
1938
1939         * css/CSSParser.h: Removed many now-needed functions to manage floating items.
1940         Changed rule creation functions to return PassRefPtr. Other changes as mentioned above.
1941
1942         * css/CSSParserValues.cpp:
1943         (WebCore::destroy): Added.
1944         (WebCore::CSSParserValueList::~CSSParserValueList): Updated to call destroy.
1945         * css/CSSParserValues.h: Ditto.
1946
1947 2013-09-11  Mario Sanchez Prada  <mario.prada@samsung.com>
1948
1949         [GTK] Remove Gail dependency from build system for GTK3
1950         https://bugs.webkit.org/show_bug.cgi?id=119673
1951
1952         Reviewed by Gustavo Noronha Silva.
1953
1954         * GNUmakefile.am: Removed GAIL_CFLAGS.
1955         * PlatformGTK.cmake: Removed GAIL3_INCLUDE_DIRS and GAIL3_LIBRARIES.
1956
1957 2013-09-11  Andreas Kling  <akling@apple.com>
1958
1959         Remove Widget::widgetPositionsUpdated().
1960         <https://webkit.org/b/121160>
1961
1962         Reviewed by Anders Carlsson.
1963
1964         Remove this no-op virtual that was only used by chromium.
1965
1966 2013-09-11  Andreas Kling  <akling@apple.com>
1967
1968         Page::backForward() should return a reference.
1969         <https://webkit.org/b/121151>
1970
1971         Reviewed by Anders Carlsson.
1972
1973         There is always a BackForwardController, so make backForward() return a reference.
1974         Also made it store a Page& internally since it's tied to the lifetime of Page.
1975
1976 2013-09-11  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
1977
1978         WTF::OwnPtr should behave similarly with the rest of WTF smart pointers
1979         https://bugs.webkit.org/show_bug.cgi?id=120773
1980
1981         Reviewed by Anders Carlsson.
1982
1983         Before the change OwnPtr could take either the pointer type or the pointed-to type, which was bad
1984         for the following reasons:
1985         - It distinguished OwnPtr behaviour from other WTF smart pointer classes behaviour (so it was confusing for the Client).
1986         - It was potential error-prone as it actually modified the type given by the Client in opaque way.
1987
1988         * page/animation/CSSPropertyAnimation.cpp:
1989         (WebCore::PropertyWrapperShadow::blendSimpleOrMatchedShadowLists):
1990         (WebCore::PropertyWrapperShadow::blendMismatchedShadowLists):
1991
1992 2013-09-11  Andreas Kling  <akling@apple.com>
1993
1994         FrameView: Tighten widget handling code.
1995         <https://webkit.org/b/121155>
1996
1997         Reviewed by Antti Koivisto.
1998
1999         Harden typing in this code to work with RenderEmbeddedObject& instead of RenderObject*.
2000         Functions and members renamed to reflect that they only deal with embedded objects.
2001
2002         * html/HTMLPlugInImageElement.h:
2003         (WebCore::toHTMLPlugInImageElement):
2004
2005             Add a toHTMLPlugInImageElement that takes an Element&.
2006
2007         * html/HTMLTagNames.in:
2008
2009             Generate type helpers for applet and embed elements.
2010
2011         * page/FrameView.h:
2012         * page/FrameView.cpp:
2013         (WebCore::FrameView::addEmbeddedObjectToUpdate):
2014         (WebCore::FrameView::removeEmbeddedObjectToUpdate):
2015         (WebCore::FrameView::updateEmbeddedObjects):
2016         (WebCore::FrameView::updateEmbeddedObject):
2017
2018             Re-ordered this function in early return style. Change locals into references.
2019
2020         * rendering/RenderEmbeddedObject.cpp:
2021         (WebCore::RenderEmbeddedObject::~RenderEmbeddedObject):
2022         (WebCore::RenderEmbeddedObject::layout):
2023         * rendering/RenderSnapshottedPlugIn.cpp:
2024         (WebCore::RenderSnapshottedPlugIn::layout):
2025
2026             Updated for new FrameView function signatures.
2027
2028 2013-09-11  Patrick Gansterer  <paroga@webkit.org>
2029
2030         [CMake] Split out generic Windows files into its own file
2031         https://bugs.webkit.org/show_bug.cgi?id=119514
2032
2033         Reviewed by Gyuyoung Kim.
2034
2035         This allows us to add smaller CMakeLists.txt files when
2036         adding additional Windows ports.
2037
2038         * PlatformWin.cmake: Copied from Source/WebCore/PlatformWinCE.cmake.
2039         * PlatformWinCE.cmake:
2040
2041 2013-09-11  Mario Sanchez Prada  <mario.prada@samsung.com>
2042
2043         [GTK] Get rid of Pango/Gail dependencies in accessibility for ATK
2044         https://bugs.webkit.org/show_bug.cgi?id=114867
2045
2046         Reviewed by Martin Robinson.
2047
2048         Removed all trace of Gail and Pango specific code from the AtkText
2049         implementation, now everything has been reimplemented.
2050
2051         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
2052         (webkitAccessibleTextGetTextForOffset): Removed fallback code
2053         relying in Gail/Pango, now all the related code has been
2054         removed. Also, replaced the collection of if statements with a
2055         switch, for better readability of the code.
2056
2057 2013-09-11  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2058
2059         Mouseenter/-leave not triggered when element under cursor is moved/removed
2060         https://bugs.webkit.org/show_bug.cgi?id=120786
2061
2062         Reviewed by Antonio Gomes.
2063
2064         When a hovered element is detached it will now emit a fake mousemove event
2065         similar to what happens when a hovered element has CSS display set to none.
2066
2067         Test: fast/events/mouseenterleave-detached-element.html
2068
2069         * dom/Document.cpp:
2070         (WebCore::Document::hoveredElementDidDetach):
2071         * page/EventHandler.cpp:
2072         (WebCore::EventHandler::EventHandler):
2073         (WebCore::EventHandler::clear):
2074         (WebCore::EventHandler::handleMouseMoveEvent):
2075         * page/EventHandler.h:
2076
2077 2013-09-11  Krzysztof Czech  <k.czech@samsung.com>
2078
2079         [ATK] Adds mapping MenuItemRadioRole to ATK
2080         https://bugs.webkit.org/show_bug.cgi?id=121149
2081
2082         Reviewed by Mario Sanchez Prada.
2083
2084         Adds mapping MenuItemRadioRole to ATK.
2085
2086         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2087         (atkRole):
2088
2089 2013-09-10  Mario Sanchez Prada  <mario.prada@samsung.com>
2090
2091         [GTK] Reimplement atk_text_get_text_*_offset for LINE boundaries
2092         https://bugs.webkit.org/show_bug.cgi?id=114872
2093
2094         Reviewed by Gustavo Noronha Silva.
2095
2096         Re-implement these functions without using GailTextUtil nor Pango.
2097
2098         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
2099         (lineAtPositionForAtkBoundary): New helper function to find the
2100         line at a given position considering values of AtkTextBoundary.
2101         (webkitAccessibleTextLineForBoundary): New function,
2102         implementing atk_text_get_text_*_offset for LINE.
2103         (webkitAccessibleTextGetTextForOffset): Replace usage of Gail for
2104         LINE boundaries with webkitAccessibleTextLineForBoundary().
2105
2106 2013-09-11  Andreas Kling  <akling@apple.com>
2107
2108         Missed one BackForwardListImpl.h in the last commit.
2109
2110         * history/BackForwardList.cpp:
2111
2112 2013-09-11  Andreas Kling  <akling@apple.com>
2113
2114         Rename BackForwardListImpl.{cpp,h} => BackForwardClient.{cpp,h}
2115
2116         Rubber-stamped by Antti Koivisto.
2117
2118 2013-09-10  Ryosuke Niwa  <rniwa@webkit.org>
2119
2120         CSSProperty::isInheritedProperty is large
2121         https://bugs.webkit.org/show_bug.cgi?id=121083
2122
2123         Reviewed by Sam Weinig.
2124
2125         Support [Inherited] option in makeprop.pl and generate CSSProperty::isInheritedProperty in CSSPropertyNames.cpp
2126         using a lookup table. We can pack the table better by using bitfield in the future but I think boolean lookup
2127         table is a good first cut.
2128
2129         Updated CSSPropertyNames.in and SVGCSSPropertyNames.in to use the new option and removed the old code from
2130         CSSProperty.cpp.
2131
2132         * css/CSSProperty.cpp:
2133         * css/CSSPropertyNames.in:
2134         * css/SVGCSSPropertyNames.in:
2135         * css/makeprop.pl:
2136
2137 2013-09-11  Andreas Kling  <akling@apple.com>
2138
2139         Rename BackForwardListImpl => BackForwardList.
2140         <https://webkit.org/b/121146>
2141
2142         Reviewed by Antti Koivisto.
2143
2144         Nuke another old FIXME.
2145
2146 2013-09-11  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2147
2148         Generate more HTML type checks and casting
2149         https://bugs.webkit.org/show_bug.cgi?id=121080
2150
2151         Reviewed by Andreas Kling.
2152
2153         Clean-up remained functions of HTML elements using auto-generated isFooElement(),
2154         and replace toFooElement() with ELEMENT_TYPE_CASTS() macro.
2155
2156         Besides this patch clean-up unnecessary checks which are being supported by
2157         auto-generated isFooElement().
2158
2159         No new tests, no behavior change.
2160
2161         * accessibility/atk/AXObjectCacheAtk.cpp:
2162         (WebCore::notifyChildrenSelectionChange):
2163         * html/HTMLFrameElementBase.h:
2164         (WebCore::toHTMLFrameElementBase):
2165         * html/HTMLIFrameElement.h:
2166         * html/HTMLImageLoader.cpp:
2167         (WebCore::HTMLImageLoader::dispatchLoadEvent):
2168         (WebCore::HTMLImageLoader::notifyFinished):
2169         * html/HTMLObjectElemenaeh:
2170         * html/HTMLOptionsCollection.cpp:
2171         (WebCore::HTMLOptionsCollection::HTMLOptionsCollection):
2172         * html/HTMLSelectElement.h:
2173         * html/HTMLTagNames.in:
2174         * html/HTMLVideoElement.h:
2175         * html/shadow/HTMLContentElement.h:
2176         * loader/ImageLoader.cpp:
2177         (WebCore::ImageLoader::dispatchPendingBeforeLoadEvent):
2178         * loader/archive/cf/LegacyWebArchive.cpp:
2179         (WebCore::LegacyWebArchive::create):
2180         * page/PageSerializer.cpp:
2181         (WebCore::frameOwnerURLAttributeName):
2182         * page/SpatialNavigation.cpp:
2183         (WebCore::canScrollInDirection):
2184         * platform/gtk/PasteboardGtk.cpp:
2185         (WebCore::getURLForImageNode):
2186         * plugins/IFrameShimSupport.cpp:
2187         (WebCore::getPluginOcclusions):
2188         * rendering/HitTestResult.cpp:
2189         (WebCore::HitTestResult::mediaSupportsFullscreen):
2190         (WebCore::HitTestResult::mediaElement):
2191         (WebCore::HitTestResult::enterFullscreenForVideo):
2192         (WebCore::HitTestResult::mediaIsVideo):
2193
2194         * rendering/RenderLayerCompositor.cpp:
2195         (WebCore::RenderLayerCompositor::requiresCompositingForVideo):
2196         * rendering/RenderListBox.cpp:
2197         (WebCore::RenderListBox::RenderListBox):
2198         * rendering/RenderMenuList.cpp:
2199         (WebCore::RenderMenuList::RenderMenuList):
2200         * testing/Internals.cpp:
2201         (WebCore::Internals::isSelectPopupVisible):
2202
2203 2013-09-11  Chris Fleizach  <cfleizach@apple.com>
2204
2205         AX: Mac platform is not using accessibilityTitle from the Base implementation
2206         https://bugs.webkit.org/show_bug.cgi?id=121109
2207
2208         Reviewed by Sam Weinig.
2209
2210         Remove the Mac platform overrides of accessibilityTitle, Description, HelpText. 
2211         The Base implementation has these and we can share them between iOS and Mac
2212
2213         * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
2214         (-[WebAccessibilityObjectWrapperBase accessibilityTitle]):
2215         (-[WebAccessibilityObjectWrapperBase accessibilityDescription]):
2216         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2217
2218 2013-09-11  Andreas Kling  <akling@apple.com>
2219
2220         Rename BackForwardList.h => BackForwardClient.h
2221
2222         Rubber-stamped by Antti Koivisto.
2223
2224 2013-09-11  Andreas Kling  <akling@apple.com>
2225
2226         Rename BackForwardList => BackForwardClient.
2227         <https://webkit.org/b/121143>
2228
2229         Reviewed by Antti Koivisto.
2230
2231         Nuke a 3 year old FIXME about renaming this class.
2232
2233 2013-09-10  Daniel Bates  <dabates@apple.com>
2234
2235         [iOS] Upstream text autosizing
2236         https://bugs.webkit.org/show_bug.cgi?id=121111
2237
2238         Reviewed by Andy Estes and Sam Weinig.
2239
2240         Tests: platform/iphone-simulator/text-autosizing/anonymous-block.html
2241                platform/iphone-simulator/text-autosizing/contenteditable.html
2242                platform/iphone-simulator/text-autosizing/first-letter.html
2243                platform/iphone-simulator/text-autosizing/font-family-case-insensitive.html
2244                platform/iphone-simulator/text-autosizing/lists.html
2245                platform/iphone-simulator/text-autosizing/overflow.html
2246                platform/iphone-simulator/text-autosizing/percent-adjust-length-line-height.html
2247                platform/iphone-simulator/text-autosizing/percent-adjust-number-line-height.html
2248                platform/iphone-simulator/text-autosizing/percent-adjust-percent-line-height.html
2249
2250         * WebCore.exp.in:
2251         * WebCore.xcodeproj/project.pbxproj:
2252         * css/CSSComputedStyleDeclaration.cpp:
2253         (WebCore::ComputedStyleExtractor::propertyValue):
2254         * css/CSSParser.cpp:
2255         (WebCore::isValidKeywordPropertyAndValue):
2256         (WebCore::CSSParser::parseValue):
2257         * css/CSSProperty.cpp:
2258         (WebCore::CSSProperty::isInheritedProperty):
2259         * css/CSSPropertyNames.in: Add property -webkit-text-size-adjust.
2260         * css/DeprecatedStyleBuilder.cpp:
2261         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyValue): Added.
2262         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyInitialValue): Added.
2263         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyInheritValue): Added.
2264         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::createHandler): Added.
2265         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
2266         * css/StyleResolver.cpp:
2267         (WebCore::StyleResolver::updateFont):
2268         (WebCore::StyleResolver::applyProperties): Add COMPILE_ASSERT to ensure that
2269         all properties that affect font size, including -webkit-text-size-adjust, are
2270         resolved before properties that depend on them; see <rdar://problem/13522835>.
2271         (WebCore::StyleResolver::applyProperty):
2272         (WebCore::StyleResolver::checkForTextSizeAdjust): Added.
2273         * css/StyleResolver.h:
2274         * dom/Document.cpp:
2275         (WebCore::TextAutoSizingTraits::constructDeletedValue): Added.
2276         (WebCore::TextAutoSizingTraits::isDeletedValue): Added.
2277         (WebCore::Document::detach):
2278         (WebCore::Document::addAutoSizingNode): Added.
2279         (WebCore::Document::validateAutoSizingNodes): Added.
2280         (WebCore::Document::resetAutoSizingNodes): Added.
2281         * dom/Document.h:
2282         * editing/EditingStyle.cpp:
2283         * page/Frame.h: Add declarations for setTextAutosizingWidth(), textAutosizingWidth().
2284         * page/FrameView.cpp:
2285         (WebCore::FrameView::layout):
2286         * page/Settings.in: Generate setter and getter for setting minimumZoomFontSize.
2287         * platform/graphics/Font.h:
2288         (WebCore::Font::equalForTextAutoSizing): Added.
2289         * platform/graphics/FontDescription.cpp:
2290         (WebCore::FontDescription::familiesEqualForTextAutoSizing): Added.
2291         * platform/graphics/FontDescription.h:
2292         (WebCore::FontDescription::equalForTextAutoSizing): Added.
2293         * rendering/RenderBlock.cpp:
2294         (WebCore::RenderBlock::RenderBlock):
2295         (WebCore::isVisibleRenderText): Added.
2296         (WebCore::resizeTextPermitted): Added.
2297         (WebCore::RenderBlock::immediateLineCount): Added.
2298         (WebCore::isNonBlocksOrNonFixedHeightListItems): Added.
2299         (WebCore::oneLineTextMultiplier): Added.
2300         (WebCore::textMultiplier): Added.
2301         (WebCore::RenderBlock::adjustComputedFontSizes): Added.
2302         * rendering/RenderBlock.h:
2303         (WebCore::RenderBlock::resetComputedFontSize): Added.
2304         * rendering/RenderObject.cpp:
2305         (WebCore::RenderObject::traverseNext): Added.
2306         (WebCore::includeNonFixedHeight): Added.
2307         (WebCore::RenderObject::adjustComputedFontSizesOnBlocks): Added.
2308         (WebCore::RenderObject::resetTextAutosizing): Added.
2309         * rendering/RenderObject.h:
2310         * rendering/RenderText.cpp:
2311         (WebCore::RenderText::RenderText):
2312         * rendering/RenderText.h:
2313         (WebCore::RenderText::candidateComputedTextSize): Added.
2314         (WebCore::RenderText::setCandidateComputedTextSize): Added.
2315         * rendering/style/RenderStyle.cpp:
2316         (WebCore::computeFontHash):
2317         (WebCore::RenderStyle::hashForTextAutosizing): Added.
2318         (WebCore::RenderStyle::equalForTextAutosizing): Added.
2319         (WebCore::RenderStyle::changeRequiresLayout):
2320         (WebCore::RenderStyle::specifiedLineHeight): Added; iOS-specific variant.
2321         We should reconcile this getter with the getter of the same name that is
2322         compiled when building with IOS_TEXT_AUTOSIZING disabled.
2323         (WebCore::RenderStyle::setSpecifiedLineHeight): Added.
2324         * rendering/style/RenderStyle.h:
2325         (WebCore::RenderStyle::initialSpecifiedLineHeight): Added.
2326         (WebCore::RenderStyle::initialTextSizeAdjust): Added.
2327         (WebCore::RenderStyle::setTextSizeAdjust): Added.
2328         (WebCore::RenderStyle::textSizeAdjust): Added.
2329         * rendering/style/StyleInheritedData.cpp:
2330         (WebCore::StyleInheritedData::StyleInheritedData):
2331         (WebCore::StyleInheritedData::operator==):
2332         * rendering/style/StyleInheritedData.h:
2333         * rendering/style/StyleRareInheritedData.cpp:
2334         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
2335         (WebCore::StyleRareInheritedData::operator==):
2336         * rendering/style/StyleRareInheritedData.h:
2337         * rendering/style/TextSizeAdjustment.h: Added.
2338         (TextSizeAdjustment::TextSizeAdjustment):
2339         (TextSizeAdjustment::percentage):
2340         (TextSizeAdjustment::multiplier):
2341         (TextSizeAdjustment::isAuto):
2342         (TextSizeAdjustment::isNone):
2343         (TextSizeAdjustment::isPercentage):
2344         (TextSizeAdjustment::operator == ):
2345         (TextSizeAdjustment::operator != ):
2346
2347 2013-09-10  Chris Fleizach  <cfleizach@apple.com>
2348
2349         AX: AXValue/AXMenuItemMarkChar not defined for menuitemradio (should be false (0) with aria-checked=mixed | undefined)
2350         https://bugs.webkit.org/show_bug.cgi?id=120372
2351
2352         Reviewed by Mario Sanchez Prada.
2353
2354         Add new roles to make the distinction between menu item, menu item radio and menu item checkbox.
2355         Expose AXValue for menu items, so that they can convey the, on/off/mixed state of aria-checked.
2356
2357         Test: platform/mac/accessibility/menu-item-values.html
2358
2359         * accessibility/AccessibilityNodeObject.cpp:
2360         (WebCore::AccessibilityNodeObject::isMenuRelated):
2361         (WebCore::AccessibilityNodeObject::isMenuItem):
2362         (WebCore::AccessibilityNodeObject::isChecked):
2363         (WebCore::AccessibilityNodeObject::actionElement):
2364         (WebCore::AccessibilityNodeObject::visibleText):
2365         (WebCore::AccessibilityNodeObject::title):
2366         * accessibility/AccessibilityObject.cpp:
2367         (WebCore::createARIARoleMap):
2368         (WebCore::AccessibilityObject::checkboxOrRadioValue):
2369         * accessibility/AccessibilityObject.h:
2370         * accessibility/AccessibilityRenderObject.cpp:
2371         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
2372         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
2373         (-[WebAccessibilityObjectWrapper accessibilityCanFuzzyHitTest]):
2374         (-[WebAccessibilityObjectWrapper accessibilityTraits]):
2375         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2376         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
2377         (createAccessibilityRoleMap):
2378         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
2379
2380 2013-09-10  Anders Carlsson  <andersca@apple.com>
2381
2382         Remove wtf/Alignment.h
2383         https://bugs.webkit.org/show_bug.cgi?id=121077
2384
2385         Reviewed by Andreas Kling.
2386
2387         * platform/PODArena.h:
2388         (WebCore::PODArena::minAlignment):
2389         * platform/graphics/cpu/arm/filters/FELightingNEON.h:
2390         (WebCore::FELighting::platformApplyNeon):
2391
2392 2013-09-10  Zoltan Horvath  <zoltan@webkit.org>
2393
2394         [Qt] Add FloatingObjects.h to Target.pri
2395         https://bugs.webkit.org/show_bug.cgi?id=121117
2396
2397         Reviewed by Andreas Kling.
2398
2399         No new tests, no behavior change.
2400
2401         * Target.pri:
2402
2403 2013-09-10  Sergio Correia  <sergio.correia@openbossa.org>
2404
2405         Fix EFL build after r155477
2406         https://bugs.webkit.org/show_bug.cgi?id=121126
2407
2408         Reviewed by Antonio Gomes.
2409
2410         No new tests, build fix.
2411
2412         * CMakeLists.txt: MediaStreamComponent.cpp and MediaStreamDescriptor.cpp
2413         were added with an incorrect path.
2414
2415 2013-09-10  Andreas Kling  <akling@apple.com>
2416
2417         AnimationController should have a Frame& internally.
2418         <https://webkit.org/b/121078>
2419
2420         Reviewed by Anders Carlsson.
2421
2422         The AnimationController is owned by the Frame so make the back-pointer
2423         a reference. This knocks off a couple of null checks.
2424
2425 2013-09-10  Anders Carlsson  <andersca@apple.com>
2426
2427         More WTF/Alignment.h removal
2428         https://bugs.webkit.org/show_bug.cgi?id=121125
2429
2430         Reviewed by Andreas Kling.
2431
2432         * platform/PODArena.h:
2433
2434 2013-09-10  Eric Carlson  <eric.carlson@apple.com>
2435
2436         Make MediaStream objects ScriptWrappable
2437         https://bugs.webkit.org/show_bug.cgi?id=120879
2438
2439         Reviewed by Jer Noble.
2440
2441         * Modules/mediastream/MediaStream.h: Inherit from ScriptWrappable.
2442         * Modules/mediastream/MediaStreamTrack.h: Ditto.
2443         * Modules/mediastream/RTCDTMFSender.h: Ditto.
2444         * Modules/mediastream/RTCDataChannel.h: Ditto.
2445         * Modules/mediastream/RTCIceCandidate.h: Ditto.
2446         * Modules/mediastream/RTCPeerConnection.h: Ditto.
2447         * Modules/mediastream/RTCSessionDescription.h: Ditto.
2448         * Modules/mediastream/RTCStatsReport.h: Ditto.
2449         * Modules/mediastream/RTCStatsResponse.h: Ditto.
2450
2451 2013-09-10  Eric Carlson  <eric.carlson@apple.com>
2452
2453         Split MediaStreamDescriptor.h and MediaStreamComponent.h into .h and .cpp
2454         https://bugs.webkit.org/show_bug.cgi?id=120878
2455
2456         Reviewed by Jer Noble.
2457
2458         No new tests, no functional change.
2459
2460         * CMakeLists.txt: Add MediaStreamComponent.cpp and MediaStreamDescriptor.cpp.
2461         * GNUmakefile.list.am: Ditto.
2462
2463         * Modules/mediastream/LocalMediaStream.cpp:
2464         (WebCore::LocalMediaStream::create): MediaStreamDescriptor::create() doesn't take a UUID.
2465
2466         * Modules/mediastream/MediaStream.cpp:
2467         (WebCore::createFromSourceVectors): Ditto.
2468
2469         * WebCore.xcodeproj/project.pbxproj: Add MediaStreamComponent.cpp and MediaStreamDescriptor.cpp.
2470
2471         * platform/mediastream/MediaStreamComponent.cpp: Added.
2472         * platform/mediastream/MediaStreamComponent.h:
2473
2474         * platform/mediastream/MediaStreamDescriptor.cpp: Added.
2475         * platform/mediastream/MediaStreamDescriptor.h:
2476
2477 2013-09-10  Brent Fulgham  <bfulgham@apple.com>
2478
2479         [Windows] Create SharedGDIObject Class Template
2480         https://bugs.webkit.org/show_bug.cgi?id=121037
2481
2482         Reviewed by Anders Carlsson.
2483
2484         * WebCore.vcxproj/WebCore.vcxproj: Remove RefCountedGDIHandle.h, and
2485         add new SharedGDIObject.h file.
2486         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
2487         * platform/graphics/FontPlatformData.h:
2488         (WebCore::FontPlatformData::hfont): Switch to new SharedGDIObject.
2489         * platform/graphics/win/FontPlatformDataCGWin.cpp:
2490         (WebCore::FontPlatformData::FontPlatformData): Ditto.
2491         * platform/graphics/win/FontPlatformDataCairoWin.cpp:
2492         (WebCore::FontPlatformData::FontPlatformData): Ditto.
2493         * platform/graphics/win/FontPlatformDataWin.cpp:
2494         (WebCore::FontPlatformData::FontPlatformData): Ditto.
2495         * platform/graphics/win/RefCountedGDIHandle.h: Removed.
2496         * platform/graphics/win/SharedGDIObject.h: Added.
2497         (WebCore::SharedGDIObject::create):
2498         (WebCore::SharedGDIObject::get):
2499         (WebCore::SharedGDIObject::hash):
2500         (WebCore::SharedGDIObject::SharedGDIObject):
2501
2502 2013-09-10  Tim Horton  <timothy_horton@apple.com>
2503
2504         [mac] PDFDocumentImage should use PDFKit to draw
2505         https://bugs.webkit.org/show_bug.cgi?id=120651
2506         <rdar://problem/12810731>
2507
2508         Unreviewed hopeful build fix.
2509
2510         * platform/graphics/mac/PDFDocumentImageMac.mm:
2511
2512 2013-09-10  Tim Horton  <timothy_horton@apple.com>
2513
2514         [mac] PDFDocumentImage should use PDFKit to draw
2515         https://bugs.webkit.org/show_bug.cgi?id=120651
2516         <rdar://problem/12810731>
2517
2518         Reviewed by Alexey Proskuryakov.
2519
2520         Use PDFKit to draw PDF-in-<img> on Mac, so that annotations in PDF are painted.
2521
2522         Test: fast/images/pdf-as-image-with-annotations.html
2523
2524         * WebCore.xcodeproj/project.pbxproj:
2525         Add PDFDocumentImageMac.mm.
2526
2527         * platform/graphics/cg/PDFDocumentImage.cpp:
2528         (WebCore::PDFDocumentImage::PDFDocumentImage):
2529         We don't need to initialize m_document anymore because it's now a RetainPtr.
2530         Initialize m_hasPage to false.
2531
2532         (WebCore::PDFDocumentImage::~PDFDocumentImage):
2533         We don't need to manually release our CGPDFDocumentRef anymore because it's now a RetainPtr.
2534
2535         (WebCore::PDFDocumentImage::size):
2536         Use expandedIntSize for explicitness.
2537
2538         (WebCore::PDFDocumentImage::applyRotationForPainting):
2539         Rename adjustCTM to applyRotationForPainting, and move the one non-rotation related transformation out.
2540         We need to do this because PDFKit applies the rotation transformation itself, so we don't need to.
2541         Also, explicitly use std::min instead of importing the whole std namespace.
2542
2543         (WebCore::PDFDocumentImage::dataChanged):
2544         Assert that we don't re-enter dataChanged after we've created a document,
2545         because it seems like that shouldn't happen - we only create a document when
2546         we've supposedly received all data, and it would be nice if we didn't have
2547         all this varying code to deal with SharedBuffers changing out from under each other.
2548         Factor the code to create a CGPDFDocumentRef out into createPDFDocument, so we can
2549         replace it with a different implementation that creates a PDFDocument.
2550
2551         (WebCore::PDFDocumentImage::setCurrentPage):
2552         Make all page-number-related things unsigned, since they are in CG and PDFKit,
2553         and add m_hasPage to denote whether we've acquired a valid page yet.
2554         Factor code to retrieve the PDF box bounds into computeBoundsForCurrentPage.
2555         Remove setCurrentPage itself, as we never use a page other than the first page;
2556         we will call computeBoundsForCurrentPage and set hasPage in dataChanged, now.
2557
2558         (WebCore::PDFDocumentImage::draw):
2559         Fix a weird comment.
2560         Factor code that actually draws the PDF out into drawPDFPage.
2561
2562         The rest of the functions in this file are only built for USE(CG) && !PLATFORM(MAC):
2563
2564         (WebCore::PDFDocumentImage::createPDFDocument):
2565         Factored out of dataChanged(). Use the PLATFORM(MAC) way of making a
2566         CGDataProvider from a SharedBuffer everywhere; we're already using it on
2567         iOS, and it should also work for Windows, the only other USE(CG) platform.
2568         Since we only createPDFDocument() after all data has been received, remove
2569         the comment about the SharedBuffer being secretly written to behind its back.
2570
2571         (WebCore::PDFDocumentImage::computeBoundsForCurrentPage):
2572         Factored out of setCurrentPage().
2573         Use deg2rad since we have it.
2574
2575         (WebCore::PDFDocumentImage::pageCount):
2576         (WebCore::PDFDocumentImage::drawPDFPage):
2577         Factored out of draw().
2578         Reduced an unnecessary transform (we were effectively doing mediaBox.origin - cropBox.origin - mediaBox.origin).
2579
2580         * platform/graphics/cg/PDFDocumentImage.h:
2581         Unindent all the things, as we don't indent the first level inside a namespace scope.
2582         Forward-declare PDFDocument.
2583         Make m_currentPage unsigned as it should be.
2584         Add m_hasPage.
2585         Make m_document a PDFDocument on PLATFORM(MAC) and a CGPDFDocumentRef on other platforms.
2586
2587         * platform/graphics/mac/PDFDocumentImageMac.mm: Added.
2588         Soft-link in PDFKit and specifically the PDFDocument class.
2589
2590         (WebCore::PDFDocumentImage::createPDFDocument):
2591         Create our PDFDocument from the SharedBuffer's NSData directly. This shouldn't be a problem
2592         (with respect to the SharedBuffer's data being appended to in secret), because we've waited
2593         for the document to finish loading before getting here.
2594
2595         (WebCore::PDFDocumentImage::computeBoundsForCurrentPage):
2596         Ask PDFKit for the page's media and crop boxes; it automatically performs the correct fallback.
2597         Ask PDFKit for the page's rotation.
2598
2599         (WebCore::PDFDocumentImage::pageCount):
2600         Ask PDFKit for the page count.
2601
2602         (WebCore::PDFDocumentImage::drawPDFPage):
2603         Paint the current page of the PDF. Note that we do not apply the rotation here
2604         via applyRotationForPainting because PDFKit will do it itself.
2605         Save and restore two bits of CG state which aren't saved and restored with the
2606         graphics state, as PDFKit can mutate them above us (<rdar://problem/14951759>).
2607
2608         * platform/mac/SoftLinking.h:
2609         I couldn't find any clients of SOFT_LINK_FRAMEWORK_IN_CORESERVICES_UMBRELLA,
2610         so I made it the more generic SOFT_LINK_FRAMEWORK_IN_UMBRELLA, taking the name
2611         of the umbrella framework and the subframework, so I could use it to soft link
2612         Quartz.framework's PDFKit.framework.
2613
2614 2013-09-10  Tim Horton  <timothy_horton@apple.com>
2615
2616         [mac] <progress> has rendering artifacts along the bottom
2617         https://bugs.webkit.org/show_bug.cgi?id=120865
2618         <rdar://problem/11571240>
2619
2620         Reviewed by Simon Fraser.
2621
2622         Allow RenderTheme to force the height of a <progress> bar.
2623
2624         Test: platform/mac/fast/forms/indeterminate-progress-inline-height.html
2625
2626         * rendering/RenderProgress.cpp:
2627         (WebCore::RenderProgress::computeLogicalHeight):
2628         Borrowed from RenderMeter, allow the theme to override the size of the progress bar.
2629
2630         * rendering/RenderProgress.h:
2631         Drive-by add OVERRIDE to a few things.
2632
2633         * rendering/RenderTheme.cpp:
2634         (WebCore::RenderTheme::progressBarRectForBounds):
2635         * rendering/RenderTheme.h:
2636         Add a default implementation of progressBarRectForBounds that just passes the bounds through.
2637
2638         * rendering/RenderThemeMac.h:
2639         * rendering/RenderThemeMac.mm:
2640         (WebCore::RenderThemeMac::progressBarRectForBounds):
2641         Override progressBarRectForBounds; the implementation is factored out of paintProgressBar.
2642
2643         (WebCore::RenderThemeMac::paintProgressBar):
2644         Make use of the factored-out progressBarRectForBounds().
2645
2646         Drive-by apply the device scale factor to the progress bar's image buffer,
2647         so that it is rendered at 2x on appropriate hardware. Also, multiply the
2648         progress animation phase by the device scale factor, as the phase value seems
2649         to be proportional to the actual pixel offset of the animation; without this,
2650         the animation would appear to progress half as slowly in HiDPI.
2651
2652 2013-09-10  Chris Fleizach  <cfleizach@apple.com>
2653
2654         AX: Expose DOM ID and ClassList to AX APIs for automation and AT element hashes
2655         https://bugs.webkit.org/show_bug.cgi?id=120552
2656
2657         Reviewed by Darin Adler.
2658
2659         Add Mac support for exposing the DOM ID and DOM class list so that accessibility
2660         clients can leverage that information.
2661
2662         Test: platform/mac/accessibility/id-class-attributes.html
2663
2664         * accessibility/AccessibilityObject.cpp:
2665         (WebCore::AccessibilityObject::domIdentifier):
2666         (WebCore::AccessibilityObject::domClassList):
2667         * accessibility/AccessibilityObject.h:
2668         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2669         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
2670         (convertStringsToNSArray):
2671         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
2672
2673 2013-09-10  Denis Nomiyama  <d.nomiyama@samsung.com>
2674
2675         [GTK] accessibility/loading-iframe-sends-notification.html is failing
2676         https://bugs.webkit.org/show_bug.cgi?id=98370
2677
2678         Reviewed by Chris Fleizach.
2679
2680         Enabled AXLayoutComplete on the GTK platform.
2681
2682         No new tests are required because this feature will use an existing
2683         accessibility layout test that is currently failing on the GTK+ platform
2684         (e.g. loading-iframe-sends-notification.html).
2685
2686         * accessibility/atk/AXObjectCacheAtk.cpp:
2687         (WebCore::AXObjectCache::postPlatformNotification): Send layout-complete
2688         signal in case of AXLayoutComplete.
2689         * dom/Document.cpp:
2690         (WebCore::Document::implicitClose): Enabled AXLayoutComplete on the GTK
2691         platform.
2692         * page/FrameView.cpp:
2693         (WebCore::FrameView::layout): Enabled AXLayoutComplete on the GTK
2694         platform.
2695
2696 2013-09-09  Brent Fulgham  <bfulgham@apple.com>
2697
2698         [Windows] Change from using OwnPtr<GDI Stuff> to new GDIObject template.
2699         https://bugs.webkit.org/show_bug.cgi?id=120778
2700
2701         Reviewed by Anders Carlsson.
2702
2703         Change code to use a GDI-specific smart pointer, rather than OwnPtr. This
2704         is a first step to simplifying OwnPtr. It also gets rid of some Windows-
2705         specific code in WTF.
2706
2707         * WebCore.vcxproj/WebCore.vcxproj: Add the new header file.
2708         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
2709         * page/win/FrameCGWin.cpp:
2710         (WebCore::imageFromRect): Switch to GDIObject.
2711         * page/win/FrameCairoWin.cpp:
2712         (WebCore::imageFromRect): Switch to GDIObject.
2713         * page/win/FrameWin.cpp:
2714         (WebCore::imageFromSelection): Switch to GDIObject.
2715         (WebCore::Frame::dragImageForSelection): Ditto.
2716         (WebCore::Frame::nodeImage): Ditto.
2717         * page/win/FrameWin.h:
2718         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
2719         (WebCore::getDirtyRects): Switch from OwnPtr to GDIObject.
2720         * platform/graphics/win/FontCacheWin.cpp:
2721         (WebCore::createGDIFont): Switch to GDIObject.
2722         (WebCore::FontCache::createFontPlatformData): Ditto.
2723         * platform/graphics/win/FontCustomPlatformData.cpp:
2724         (WebCore::FontCustomPlatformData::fontPlatformData): Switch to GDIObject.
2725         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
2726         (WebCore::FontCustomPlatformData::fontPlatformData): Switch to GDIObject.
2727         * platform/graphics/win/GraphicsContextCGWin.cpp:
2728         (WebCore::GraphicsContext::releaseWindowsContext): Switch to GDIObject.
2729         * platform/graphics/win/GraphicsContextCairoWin.cpp:
2730         (WebCore::GraphicsContext::releaseWindowsContext): Switch to GDIObject.
2731         * platform/graphics/win/GraphicsContextWin.cpp:
2732         (WebCore::GraphicsContext::getWindowsContext): Switch to GDIObject.
2733         * platform/graphics/win/SimpleFontDataWin.cpp:
2734         (WebCore::SimpleFontData::platformCreateScaledFontData): Switch to GDIObject.
2735         * platform/win/CursorWin.cpp:
2736         (WebCore::createSharedCursor): Switch to GDIObject.
2737         * platform/win/DragImageCGWin.cpp:
2738         (WebCore::scaleDragImage): Switch to GDIObject.
2739         (WebCore::createDragImageFromImage):
2740         * platform/win/DragImageCairoWin.cpp: 
2741         (WebCore::scaleDragImage): Switch to GDIObject.
2742         (WebCore::createDragImageFromImage): Ditto.
2743         * platform/win/DragImageWin.cpp:
2744         (WebCore::createDragImageForLink): Switch to GDIObject.
2745         * platform/win/PasteboardWin.cpp:
2746         (WebCore::Pasteboard::writeImage): Switch to GDIObject.
2747         * platform/win/ScrollbarThemeWin.cpp:
2748         (WebCore::ScrollbarThemeWin::paintTrackPiece): Switch to GDIObject.
2749         * plugins/win/PluginViewWin.cpp:
2750         (WebCore::PluginView::updatePluginWidget): Switch to GDIObject.
2751         (WebCore::PluginView::snapshot): Ditto.
2752         * rendering/RenderThemeWin.cpp:
2753         (WebCore::drawControl): Switch to GDIObject.
2754
2755 2013-09-10  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2756
2757         REGRESSION (r147454): Youtube annotation links to new window broken
2758         https://bugs.webkit.org/show_bug.cgi?id=114242
2759
2760         Reviewed by Anders Carlsson.
2761
2762         Set the UserGestureIndicator to allow popups the same way the issue was solved for WebKit2.
2763
2764         * plugins/PluginView.cpp:
2765         (WebCore::PluginView::performRequest):
2766
2767 2013-09-10  Alberto Garcia  <berto@igalia.com>
2768
2769         [GTK] The code generator produces a warning if a parameter can be NULL
2770         https://bugs.webkit.org/show_bug.cgi?id=121093
2771
2772         Reviewed by Christophe Dumez.
2773
2774         Return an empty string instead of an undefined value if a
2775         particular parameter doesn't need to be checked.
2776
2777         * bindings/scripts/CodeGeneratorGObject.pm:
2778         (GetGReturnMacro):
2779
2780 2013-09-10  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
2781
2782         MediaStream API: Enhance MediaStreamDescriptor add/remove component
2783         https://bugs.webkit.org/show_bug.cgi?id=120874
2784
2785         Merge blink https://chromium.googlesource.com/chromium/blink/+/67fcacf13ce922a762d7a1c6fb9e1b8e51e662ea
2786
2787         Reviewed by Eric Carlson.
2788
2789         No new tests needed.
2790
2791         * Modules/mediastream/MediaStream.cpp:
2792         (WebCore::MediaStream::addTrack):
2793         (WebCore::MediaStream::removeTrack):
2794         (WebCore::MediaStream::addRemoteTrack):
2795         (WebCore::MediaStream::removeRemoteTrack):
2796         * platform/mediastream/MediaStreamDescriptor.h:
2797         (WebCore::MediaStreamDescriptor::addRemoteTrack):
2798         (WebCore::MediaStreamDescriptor::removeRemoteTrack):
2799         (WebCore::MediaStreamDescriptor::addComponent):
2800         (WebCore::MediaStreamDescriptor::removeComponent):
2801
2802 2013-09-10  Andreas Kling  <akling@apple.com>
2803
2804         toFooElement() should use static_cast, not reinterpret_cast.
2805         <https://webkit.org/b/121087>
2806
2807         Reviewed by Antti Koivisto.
2808
2809         reinterpret_cast is not safe for downcasting with multiple inheritance.
2810         Add a ELEMENT_TYPE_CASTS(classname) macro that goes after class definitions.
2811         It expands into the following methods:
2812
2813             - FooElement* toFooElement(Node*)
2814             - const FooElement* toFooElement(const Node*)
2815             - FooElement& toFooElement(Node&)
2816             - const FooElement& toFooElement(const Node&)
2817
2818         As a bonus, it also adds these to catch unnecessary casting:
2819
2820             - void toFooElement(const Node*)
2821             - void toFooElement(const Node&)
2822
2823         There might be a more clever way of doing this, but this gets us to a
2824         correct place so we can think in peace.
2825
2826         * bridge/qt/qt_pixmapruntime.cpp:
2827         (JSC::Bindings::assignToHTMLImageElement):
2828         (JSC::Bindings::QtPixmapRuntime::toQt):
2829         * dom/Element.h:
2830         (WebCore::isElement):
2831         * dom/make_names.pl:
2832         (printTypeHelpers):
2833         * html/HTMLAnchorElement.h:
2834         * html/HTMLAreaElement.h:
2835         * html/HTMLAudioElement.h:
2836         * html/HTMLBaseElement.h:
2837         * html/HTMLCanvasElement.h:
2838         * html/HTMLElement.h:
2839         (WebCore::isHTMLElement):
2840         * html/HTMLFieldSetElement.h:
2841         * html/HTMLFormElement.h:
2842         * html/HTMLFrameSetElement.h:
2843         * html/HTMLImageElement.h:
2844         * html/HTMLInputElement.h:
2845         * html/HTMLLabelElement.h:
2846         * html/HTMLLegendElement.h:
2847         * html/HTMLMapElement.h:
2848         * html/HTMLMeterElement.h:
2849         * html/HTMLOptGroupElement.h:
2850         * html/HTMLOptionElement.h:
2851         * html/HTMLParamElement.h:
2852         * html/HTMLProgressElement.h:
2853         * html/HTMLScriptElement.h:
2854         * html/HTMLSourceElement.h:
2855         * html/HTMLStyleElement.h:
2856         * html/HTMLTableElement.h:
2857         * html/HTMLTableRowElement.h:
2858         * html/HTMLTextAreaElement.h:
2859         * html/HTMLTitleElement.h:
2860         * html/HTMLTrackElement.h:
2861         * svg/SVGAltGlyphDefElement.h:
2862         * svg/SVGAltGlyphElement.h:
2863         * svg/SVGAltGlyphItemElement.h:
2864         * svg/SVGAnimateMotionElement.h:
2865         * svg/SVGAnimateTransformElement.h:
2866         * svg/SVGCircleElement.h:
2867         * svg/SVGClipPathElement.h:
2868         * svg/SVGCursorElement.h:
2869         * svg/SVGEllipseElement.h:
2870         * svg/SVGFEDistantLightElement.h:
2871         * svg/SVGFEFuncAElement.h:
2872         * svg/SVGFEFuncBElement.h:
2873         * svg/SVGFEFuncGElement.h:
2874         * svg/SVGFEFuncRElement.h:
2875         * svg/SVGFEMergeNodeElement.h:
2876         * svg/SVGFEPointLightElement.h:
2877         * svg/SVGFESpotLightElement.h:
2878         * svg/SVGFilterElement.h:
2879         * svg/SVGFontElement.h:
2880         * svg/SVGFontFaceElement.h:
2881         * svg/SVGFontFaceNameElement.h:
2882         * svg/SVGFontFaceSrcElement.h:
2883         * svg/SVGFontFaceUriElement.h:
2884         * svg/SVGForeignObjectElement.h:
2885         * svg/SVGGlyphElement.h:
2886         * svg/SVGGlyphRefElement.h:
2887         * svg/SVGHKernElement.h:
2888         * svg/SVGImageElement.h:
2889         * svg/SVGLineElement.h:
2890         * svg/SVGLinearGradientElement.h:
2891         * svg/SVGMPathElement.h:
2892         * svg/SVGMarkerElement.h:
2893         * svg/SVGMaskElement.h:
2894         * svg/SVGMissingGlyphElement.h:
2895         * svg/SVGPathElement.h:
2896         * svg/SVGPatternElement.h:
2897         * svg/SVGRadialGradientElement.h:
2898         * svg/SVGRectElement.h:
2899         * svg/SVGSVGElement.h:
2900         * svg/SVGScriptElement.h:
2901         * svg/SVGStyleElement.h:
2902         * svg/SVGTextElement.h:
2903         * svg/SVGTextPathElement.h:
2904         * svg/SVGTitleElement.h:
2905         * svg/SVGUseElement.h:
2906         * svg/SVGVKernElement.h:
2907         * svg/SVGViewElement.h:
2908
2909 2013-09-10  Mario Sanchez Prada  <mario.prada@samsung.com>
2910
2911         [GTK] Test /webkit/atk/getTextInParagraphAndBodyModerate fails
2912         https://bugs.webkit.org/show_bug.cgi?id=105538
2913
2914         Reviewed by Chris Fleizach.
2915
2916         Expose '\n' for linebreaks when they were explicitly set by the
2917         author of the web content with a <br> tag.
2918
2919         Tests: accessibility/paragraph-with-linebreaks.html
2920
2921         * accessibility/AccessibilityNodeObject.cpp:
2922         (WebCore::shouldAddSpaceBeforeAppendingNextElement): Helper
2923         function to decide when to append spaces when building the text
2924         under an element, considering line breaks.
2925         (WebCore::AccessibilityNodeObject::textUnderElement): Use the
2926         shouldAddSpaceBeforeAppendingNextElement() function here.
2927         * accessibility/AccessibilityRenderObject.cpp:
2928         (WebCore::AccessibilityRenderObject::textUnderElement): Return the
2929         renderer's text for accessibility objects exposing <br> elements.
2930         * html/parser/HTMLParserIdioms.h:
2931         (WebCore::isHTMLSpaceButNotLineBreak): New helper function, useful
2932         to be passed to other functions like simplifyWhiteSpace().
2933
2934 2013-09-10  Arpita Bahuguna  <a.bah@samsung.com>
2935
2936         When deleting editable content, typing style should be reset when moving into another node.
2937         https://bugs.webkit.org/show_bug.cgi?id=120726
2938
2939         Reviewed by Ryosuke Niwa.
2940
2941         When moving from one text node to the other, while deleting characters,
2942         the deleted text node's style was being applied to any new characters
2943         added into the existing text node.
2944
2945         Typing Style in the frame selection maintains the editing style for the
2946         deleted text node, so that if new characters are inserted at the position
2947         of the deleted text node, it's style can be applied to them.
2948
2949         However, when moving into another text node, we should reset or clear the
2950         typing style maintained by the frame selection. This ensures that any new
2951         content inserted within the existing node does not take on any uncleared
2952         style of the deleted node.
2953
2954         Test: editing/deleting/maintain-style-after-delete.html
2955
2956         * editing/DeleteSelectionCommand.cpp:
2957         (WebCore::DeleteSelectionCommand::saveTypingStyleState):
2958         Calling clearTypingStyle() on frame selection whenever deletion occurs
2959         within the same text node. Thus any existing typing styleh held by the
2960         frame selection shall be cleared.
2961
2962 2013-09-09  Darin Adler  <darin@apple.com>
2963
2964         Some refinements in FrameView::layout
2965         https://bugs.webkit.org/show_bug.cgi?id=121076
2966
2967         Reviewed by Andreas Kling.
2968
2969         * page/FrameView.cpp:
2970         (WebCore::FrameView::layout): Use a reference for the document in
2971         this function since code assumes it's non-null anyway. Change code to
2972         only call styleResolverIfExists once. Rewrite comments about blocks
2973         and the scopes they create for better clarity. Make m_nestedLayoutCount
2974         easier to read. Use HTMLElement* for the pointer to the body element.
2975         Moved the call to calculateScrollbarModesForLayout in so we don't
2976         waste time doing it for subtree layouts. Get rid of the unhelpful
2977         currentHMode and currentVMode local variables. Get rid of an extra
2978         block scope we did not need.
2979
2980 2013-09-09  Santosh Mahto  <santosh.ma@samsung.com>
2981
2982         Adding "explicit" keyword in DOM related classes constructor
2983         https://bugs.webkit.org/show_bug.cgi?id=121031
2984
2985         Reviewed by Ryosuke Niwa.
2986
2987         Added the explicit keyword in constructors.
2988
2989         * dom/ActiveDOMObject.h:
2990         * dom/ContainerNode.h:
2991         * dom/DocumentStyleSheetCollection.h:
2992         * dom/ElementAncestorIterator.h:
2993         * dom/ElementData.h:
2994         * dom/ElementRareData.h:
2995         * dom/EventListenerMap.h:
2996         * dom/QualifiedName.h:
2997         (WebCore::QualifiedName::QualifiedName):
2998         * dom/TreeScope.h:
2999         * dom/ViewportArguments.h:
3000         (WebCore::ViewportArguments::ViewportArguments):
3001         * dom/VisitedLinkState.h:
3002
3003 2013-09-09  Andreas Kling  <akling@apple.com>
3004
3005         Remove unreviewed gunk I just accidentally committed :|
3006
3007 2013-09-09  Andreas Kling  <akling@apple.com>
3008
3009         HTMLTextAreaElement no longer needs custom style resolve callbacks.
3010         <https://webkit.org/b/121073>
3011
3012         Reviewed by Ryosuke Niwa.
3013
3014         After r155408 HTMLTextAreaElement doesn't override didAttachRenderer() anymore,
3015         so we don't need to fire callbacks on textarea elements during style resolve.
3016
3017         * html/HTMLTextAreaElement.cpp:
3018         (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
3019
3020 2013-09-09  Andreas Kling  <akling@apple.com>
3021
3022         ScriptController should have a Frame& internally.
3023         <https://webkit.org/b/121071>
3024
3025         Reviewed by Anders Carlsson.
3026
3027         Change ScriptController::m_frame to a reference since it's tied to
3028         the lifetime of the owning Frame.
3029
3030 2013-09-09  Andreas Kling  <akling@apple.com>
3031
3032         ScriptRunner should have a Document& internally.
3033         <https://webkit.org/b/121072>
3034
3035         Reviewed by Anders Carlsson.
3036
3037         Change ScriptRunner::m_document to a reference since it's tied to
3038         the lifetime of the Document.
3039
3040 2013-09-09  Andreas Kling  <akling@apple.com>
3041
3042         Ref-ify more stack guards.
3043         <https://webkit.org/b/121070>
3044
3045         Rubber-stamped by Anders Carlsson.
3046
3047         RefPtr<Foo> protect(this) => Ref<Foo> protect(*this).
3048
3049 2013-09-09  Andreas Kling  <akling@apple.com>
3050
3051         Generate more SVG type checks and conversions.
3052         <https://webkit.org/b/121066>
3053
3054         Reviewed by Anders Carlsson.
3055
3056         Switch another slew of SVG elements to auto-generated isFooElement()
3057         and toFooElement() helpers.
3058
3059         Removed now-unnecessary casts and assertions as appropriate.
3060         Converted some simple loops to childrenOfType iteration instead of
3061         traversing child Nodes.
3062
3063         PS. This patch also adds const versions of toFooElement().
3064
3065 2013-09-09  Dean Jackson  <dino@apple.com>
3066
3067         [WebGL] Allow multithreaded OpenGL contexts
3068         https://bugs.webkit.org/show_bug.cgi?id=121062
3069
3070         Reviewed by Simon Fraser.
3071
3072         Expose a new preference "multithreadedWebGLEnabled".
3073
3074         Also examine the value of that preference and, on Mac,
3075         tell the CGLContext that it should go to multithreaded mode.
3076
3077         * html/canvas/WebGLRenderingContext.cpp:
3078         (WebCore::WebGLRenderingContext::create): Look at the value of the new setting, and
3079         toggle a flag on the context attributes.
3080         * page/Settings.in: New Setting "multithreadedWebGLEnabled".
3081         * platform/graphics/GraphicsContext3D.h:
3082         (WebCore::GraphicsContext3D::Attributes::Attributes): Add a "multithreaded" flag.
3083         * platform/graphics/mac/GraphicsContext3DMac.mm:
3084         (WebCore::GraphicsContext3D::GraphicsContext3D): If the context attributes
3085         suggest we should, tell the OpenGL context to go into multithreaded mode.
3086
3087 2013-09-09  Ryosuke Niwa  <rniwa@webkit.org>
3088
3089         Remove HTMLTextFormControl::fixPlaceholderRenderer
3090         https://bugs.webkit.org/show_bug.cgi?id=121058
3091
3092         Reviewed by Kent Tamura.
3093
3094         HTMLTextFormControl::fixPlaceholderRenderer was added in r118733 to swap the order in which placeholder appears.
3095         Namely, when a text form control element is focused, placeholder should be rendered behind the text for the caret
3096         to render on top of, not behind, the placeholder text.  However, we can achieve the same effect by changing
3097         the order of elements in the shadow DOM instead of manually manipuating the render tree as the assertion failure
3098         mentioned in the change log is a bogus one.
3099
3100         Cleaned up the code by removing HTMLTextFormControl::fixPlaceholderRenderer and changed the order in which inner
3101         text element and placeholder element appear. Also fixed the assertion in Position's constructor.
3102
3103         * dom/Position.cpp:
3104         (WebCore::Position::Position): The original assertion was bogus. What we don't want have is for a Position to be
3105         before or after a shadow root. It's fine for it be anchroed against the shadow root as long as it's inside.
3106
3107         * html/HTMLTextAreaElement.cpp:
3108         (WebCore::HTMLTextAreaElement::updatePlaceholderText): Insert the placeholder before the inner text element.
3109         * html/HTMLTextAreaElement.h:
3110         * html/HTMLTextFormControlElement.cpp:
3111         * html/HTMLTextFormControlElement.h:
3112         * html/TextFieldInputType.cpp:
3113         (WebCore::TextFieldInputType::updatePlaceholderText): Ditto.
3114         * html/TextFieldInputType.h:
3115
3116 2013-09-09  Andreas Kling  <akling@apple.com>
3117
3118         Hide node() below RenderSVGModelObject, use element() instead.
3119         <https://webkit.org/b/121051>
3120
3121         Reviewed by Darin Adler.
3122
3123         This was almost already there, just delete node() and add an element() that returns a SVGElement*.
3124         The SVG render tree is crazy casual about compile-time types, this is only scratching the surface.
3125
3126 2013-09-09  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3127
3128         Fixing EFL build
3129         https://bugs.webkit.org/show_bug.cgi?id=121048
3130
3131         Reviewed by Darin Adler.
3132
3133         No new tests needed.
3134
3135         * platform/efl/RenderThemeEfl.cpp:
3136         (WebCore::RenderThemeEfl::applyEdjeRTLState):
3137
3138 2013-09-09  Bem Jones-Bey  <bjonesbe@adobe.com>
3139
3140         Move Floats out of RenderBlock
3141         https://bugs.webkit.org/show_bug.cgi?id=120779
3142
3143         Reviewed by Alexandru Chiculita.
3144
3145         Move FloatingObject, FloatingObjects and related code into
3146         FloatingObjects.{h,cpp}. This not only makes the code more readable
3147         and maintainable, it also will allow for more decoupling of
3148         RenderBlock and the FloatingObjects, hopefully making it possible for
3149         FloatingObjects to be more central and not need to have one for each
3150         RenderBlock that is affected by floats.
3151
3152         No new tests, no behavior change.
3153
3154         * CMakeLists.txt:
3155         * GNUmakefile.list.am:
3156         * Target.pri:
3157         * WebCore.vcxproj/WebCore.vcxproj:
3158         * WebCore.xcodeproj/project.pbxproj:
3159         * rendering/FloatingObjects.cpp: Added.
3160         (WebCore::ComputeFloatOffsetAdapter::ComputeFloatOffsetAdapter):
3161         (WebCore::ComputeFloatOffsetAdapter::lowValue):
3162         (WebCore::ComputeFloatOffsetAdapter::highValue):
3163         (WebCore::ComputeFloatOffsetAdapter::outermostFloat):
3164         (WebCore::FloatingObjects::FloatingObjects):
3165         (WebCore::FloatingObjects::~FloatingObjects):
3166         (WebCore::FloatingObjects::clearLineBoxTreePointers):
3167         (WebCore::FloatingObjects::clear):
3168         (WebCore::FloatingObjects::increaseObjectsCount):
3169         (WebCore::FloatingObjects::decreaseObjectsCount):
3170         (WebCore::FloatingObjects::intervalForFloatingObject):
3171         (WebCore::FloatingObjects::addPlacedObject):
3172         (WebCore::FloatingObjects::removePlacedObject):
3173         (WebCore::FloatingObjects::add):
3174         (WebCore::FloatingObjects::remove):
3175         (WebCore::FloatingObjects::computePlacedFloatsTree):
3176         (WebCore::FloatingObjects::logicalLeftOffset):
3177         (WebCore::FloatingObjects::logicalRightOffset):
3178         (WebCore::rangesIntersect):
3179         (WebCore::::updateOffsetIfNeeded):
3180         (WebCore::::collectIfNeeded):
3181         (WebCore::::getHeightRemaining):
3182         (WebCore::::string):
3183         * rendering/FloatingObjects.h: Added.
3184         (WebCore::FloatingObject::FloatingObject):
3185         (WebCore::FloatingObject::clone):
3186         (WebCore::FloatingObject::type):
3187         (WebCore::FloatingObject::renderer):
3188         (WebCore::FloatingObject::isPlaced):
3189         (WebCore::FloatingObject::setIsPlaced):
3190         (WebCore::FloatingObject::x):
3191         (WebCore::FloatingObject::maxX):
3192         (WebCore::FloatingObject::y):
3193         (WebCore::FloatingObject::maxY):
3194         (WebCore::FloatingObject::width):
3195         (WebCore::FloatingObject::height):
3196         (WebCore::FloatingObject::setX):
3197         (WebCore::FloatingObject::setY):
3198         (WebCore::FloatingObject::setWidth):
3199         (WebCore::FloatingObject::setHeight):
3200         (WebCore::FloatingObject::frameRect):
3201         (WebCore::FloatingObject::setFrameRect):
3202         (WebCore::FloatingObject::paginationStrut):
3203         (WebCore::FloatingObject::setPaginationStrut):
3204         (WebCore::FloatingObject::isInPlacedTree):
3205         (WebCore::FloatingObject::setIsInPlacedTree):
3206         (WebCore::FloatingObject::shouldPaint):
3207         (WebCore::FloatingObject::setShouldPaint):
3208         (WebCore::FloatingObject::isDescendant):
3209         (WebCore::FloatingObject::setIsDescendant):
3210         (WebCore::FloatingObject::setRenderer):
3211         (WebCore::FloatingObject::originatingLine):
3212         (WebCore::FloatingObject::setOriginatingLine):
3213         (WebCore::FloatingObject::logicalTop):
3214         (WebCore::FloatingObject::logicalBottom):
3215         (WebCore::FloatingObject::logicalLeft):
3216         (WebCore::FloatingObject::logicalRight):
3217         (WebCore::FloatingObject::logicalWidth):
3218         (WebCore::FloatingObject::pixelSnappedLogicalTop):
3219         (WebCore::FloatingObject::pixelSnappedLogicalBottom):
3220         (WebCore::FloatingObject::pixelSnappedLogicalLeft):
3221         (WebCore::FloatingObject::pixelSnappedLogicalRight):
3222         (WebCore::FloatingObject::setLogicalTop):
3223         (WebCore::FloatingObject::setLogicalLeft):
3224         (WebCore::FloatingObject::setLogicalHeight):
3225         (WebCore::FloatingObject::setLogicalWidth):
3226         (WebCore::FloatingObjectHashFunctions::hash):
3227         (WebCore::FloatingObjectHashFunctions::equal):
3228         (WebCore::FloatingObjectHashTranslator::hash):
3229         (WebCore::FloatingObjectHashTranslator::equal):
3230         (WebCore::FloatingObjects::setHorizontalWritingMode):
3231         (WebCore::FloatingObjects::hasLeftObjects):
3232         (WebCore::FloatingObjects::hasRightObjects):
3233         (WebCore::FloatingObjects::set):
3234         (WebCore::FloatingObjects::placedFloatsTree):
3235         * rendering/RenderBlock.cpp:
3236         (WebCore::RenderBlock::RenderBlock):
3237         (WebCore::RenderBlock::insertFloatingObject):
3238         * rendering/RenderBlock.h:
3239         * rendering/RenderBlockLineLayout.cpp:
3240         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
3241         (WebCore::LineLayoutState::lastFloat):
3242         (WebCore::LineLayoutState::setLastFloat):
3243         * rendering/RenderView.cpp:
3244         (WebCore::RenderView::intervalArena):
3245
3246 2013-09-09  David Hyatt  <hyatt@apple.com>
3247
3248         REGRESSION (r155377): Convert the media elements that were RenderBlocks to RenderBlockFlows
3249         https://bugs.webkit.org/show_bug.cgi?id=121052
3250
3251         Reviewed by Anders Carlsson.
3252
3253         Convert a couple of media renderers that I missed from RenderBlock to RenderBlockFlow.
3254         The previous patch that I landed added asserts that get triggered now when this
3255         situation occurs.
3256
3257         * rendering/RenderMediaControlElements.cpp:
3258         (WebCore::RenderMediaVolumeSliderContainer::RenderMediaVolumeSliderContainer):
3259         (WebCore::RenderMediaVolumeSliderContainer::layout):
3260         (WebCore::RenderTextTrackContainerElement::RenderTextTrackContainerElement):
3261         (WebCore::RenderTextTrackContainerElement::layout):
3262         * rendering/RenderMediaControlElements.h:
3263
3264 2013-09-09  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3265
3266         [Bug Fix] Calling m_audioComponents.remove in removeAudioComponent (MediaStreamDescriptor)
3267         https://bugs.webkit.org/show_bug.cgi?id=121034
3268
3269         Reviewed by Eric Carlson.
3270
3271         No new tests needed.
3272
3273         * platform/mediastream/MediaStreamDescriptor.h:
3274         (WebCore::MediaStreamDescriptor::removeAudioComponent):
3275
3276 2013-09-09  Anders Carlsson  <andersca@apple.com>
3277
3278         Stop using WTF type traits in WebCore
3279         https://bugs.webkit.org/show_bug.cgi?id=121042
3280
3281         Reviewed by Andreas Kling.
3282
3283         Replace uses of WTF type traits in CrossThreadCopier with a simpler solution
3284         that uses std::is_convertible_to and some helpers.
3285
3286         * dom/CrossThreadTask.h:
3287         * platform/CrossThreadCopier.h:
3288         * platform/MainThreadTask.h:
3289
3290 2013-09-06  Ryosuke Niwa  <rniwa@webkit.org>
3291
3292         Internals should always cause a layout before calling into TextIterator
3293         https://bugs.webkit.org/show_bug.cgi?id=120891
3294
3295         Reviewed by Antti Koivisto.
3296
3297         Inspired by https://chromium.googlesource.com/chromium/blink/+/5fee5da7b04a710171c79bd6e87eca3533188e45.
3298
3299         Force a layout in the constructors of TextIterator, and SimplifiedBackwardsTextIterator and remove
3300         superfluous calls to updateLayout() in other places.
3301
3302         As much as I hate for a constructor to have a side effect like this, I couldn't think of a better place
3303         to update the layout. Unfortunately, we're slowly moving away from manually createing TextIterator and
3304         wrapping them in a static function.
3305
3306         * editing/TextIterator.cpp:
3307         (WebCore::TextIterator::TextIterator):
3308         (WebCore::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator):
3309         (WebCore::TextIterator::rangeFromLocationAndLength):
3310         (WebCore::findPlainText):
3311
3312 2013-09-09  David Hyatt  <hyatt@apple.com>
3313
3314         Move layoutBlock and layoutBlockChildren into RenderBlockFlow
3315         https://bugs.webkit.org/show_bug.cgi?id=121036
3316
3317         Reviewed by Dean Jackson.
3318
3319         Move layoutBlock into RenderBlockFlow and make the base class version of
3320         the method ASSERT_NOT_REACHED. Begin the process of moving block layout 
3321         into RenderBlockFlow by putting layoutBlockChildren there as well.
3322         
3323         This patch also puts clearFloats into RenderBlockFlow and just ditches the
3324         SVG-specific forceLayoutInlineChildren by letting RenderSVGText do what it
3325         needs in its own file.
3326
3327         Convert RenderListBox to be a RenderBlockFlow, since this is necessary for it
3328         to get the correct layoutBlock method.
3329         
3330         Patch RenderRegion to call RenderBlockFlow::layoutBlock rather than RenderBlock::layoutBlock.
3331         
3332         Fix run-ins so that they create block flows rather than blocks, and restrict run-ins to
3333         only be block flows.
3334
3335         * rendering/RenderBlock.cpp:
3336         (WebCore::RenderBlock::layoutBlock):
3337         (WebCore::RenderBlock::createReplacementRunIn):
3338         (WebCore::RenderBlock::moveRunInUnderSiblingBlockIfNeeded):
3339         * rendering/RenderBlock.h:
3340         * rendering/RenderBlockFlow.cpp:
3341         (WebCore::RenderBlockFlow::clearFloats):
3342         (WebCore::RenderBlockFlow::layoutBlock):
3343         (WebCore::RenderBlockFlow::layoutBlockChildren):
3344         * rendering/RenderBlockFlow.h:
3345         * rendering/RenderBlockLineLayout.cpp:
3346         (WebCore::RenderBlockFlow::layoutInlineChildren):
3347         * rendering/RenderListBox.cpp:
3348         (WebCore::RenderListBox::RenderListBox):
3349         (WebCore::RenderListBox::layout):
3350         (WebCore::RenderListBox::paintObject):
3351         (WebCore::RenderListBox::addFocusRingRects):
3352         (WebCore::RenderListBox::nodeAtPoint):
3353         * rendering/RenderListBox.h:
3354         * rendering/RenderRegion.cpp:
3355         (WebCore::RenderRegion::paintObject):
3356         (WebCore::RenderRegion::styleDidChange):
3357         (WebCore::RenderRegion::layoutBlock):
3358         (WebCore::RenderRegion::insertedIntoTree):
3359         (WebCore::RenderRegion::willBeRemovedFromTree):
3360         (WebCore::RenderRegion::computeIntrinsicLogicalWidths):
3361         (WebCore::RenderRegion::computePreferredLogicalWidths):
3362         (WebCore::RenderRegion::updateLogicalHeight):
3363         * rendering/RenderTextControlSingleLine.cpp:
3364         (WebCore::RenderTextControlSingleLine::layout):
3365         * rendering/svg/RenderSVGText.cpp:
3366         (WebCore::RenderSVGText::layout):
3367
3368 2013-09-09  Antti Koivisto  <antti@apple.com>
3369
3370         Try to fix GTK build.
3371         
3372         Not reviewed.
3373
3374         * accessibility/AccessibilityTable.cpp:
3375         (WebCore::AccessibilityTable::isTableExposableThroughAccessibility):
3376
3377 2013-09-09  Antti Koivisto  <antti@apple.com>
3378
3379         Hide node() below RenderLayerModelObject, use element() instead
3380         https://bugs.webkit.org/show_bug.cgi?id=121038
3381
3382         Reviewed by Dave Hyatt.
3383
3384         Switch all call sites to element(). Remove now unnecessary casts, type checks and dead code.
3385         Make constructors below RenderLayerModelObject take an Element instead of a ContainerNode.
3386         
3387         This also removes a branch from many hasTagName() and isFooElement() calls.
3388
3389         * accessibility/AccessibilityRenderObject.cpp:
3390         (WebCore::startOfContinuations):
3391         * accessibility/AccessibilityTable.cpp:
3392         (WebCore::AccessibilityTable::isDataTable):
3393         * accessibility/AccessibilityTableCell.cpp:
3394         (WebCore::AccessibilityTableCell::titleUIElement):
3395         * accessibility/AccessibilityTableColumn.cpp:
3396         (WebCore::AccessibilityTableColumn::headerObjectForSection):
3397         * editing/markup.cpp:
3398         (WebCore::highestAncestorToWrapMarkup):
3399         * html/HTMLTableCellElement.cpp:
3400         (WebCore::HTMLTableCellElement::cellAbove):
3401         * html/shadow/SliderThumbElement.cpp:
3402         (WebCore::RenderSliderThumb::updateAppearance):
3403         (WebCore::RenderSliderContainer::computeLogicalHeight):
3404         (WebCore::RenderSliderContainer::layout):
3405         * page/Frame.cpp:
3406         (WebCore::Frame::frameForWidget):
3407         * rendering/RenderBlock.cpp:
3408         (WebCore::OverflowEventDispatcher::~OverflowEventDispatcher):
3409         (WebCore::RenderBlock::RenderBlock):
3410         (WebCore::RenderBlock::clone):
3411         (WebCore::RenderBlock::createReplacementRunIn):
3412         (WebCore::RenderBlock::paintObject):
3413         (WebCore::RenderBlock::isSelectionRoot):
3414         (WebCore::RenderBlock::nodeForHitTest):
3415         (WebCore::RenderBlock::hasLineIfEmpty):
3416         (WebCore::RenderBlock::addFocusRingRects):
3417         * rendering/RenderBlock.h:
3418         * rendering/RenderBlockFlow.cpp:
3419         (WebCore::RenderBlockFlow::RenderBlockFlow):
3420         * rendering/RenderBlockFlow.h:
3421         * rendering/RenderBlockLineLayout.cpp:
3422         (WebCore::RenderBlock::addOverflowFromInlineChildren):
3423         * rendering/RenderBox.cpp:
3424         (WebCore::RenderBox::RenderBox):
3425         (WebCore::RenderBox::updateFromStyle):
3426         (WebCore::RenderBox::scroll):
3427         (WebCore::RenderBox::logicalScroll):
3428         (WebCore::RenderBox::canBeProgramaticallyScrolled):
3429         (WebCore::RenderBox::nodeAtPoint):
3430         (WebCore::RenderBox::paintCustomHighlight):
3431         (WebCore::RenderBox::computeLogicalWidthInRegion):
3432         (WebCore::RenderBox::sizesLogicalWidthToFitContent):
3433         (WebCore::RenderBox::localCaretRect):
3434         * rendering/RenderBox.h:
3435         * rendering/RenderBoxModelObject.cpp:
3436         (WebCore::RenderBoxModelObject::RenderBoxModelObject):
3437         * rendering/RenderBoxModelObject.h:
3438         * rendering/RenderButton.cpp:
3439         (WebCore::RenderButton::updateFromElement):
3440         (WebCore::RenderButton::canHaveGeneratedChildren):
3441         * rendering/RenderButton.h:
3442         * rendering/RenderEmbeddedObject.cpp:
3443         (WebCore::RenderEmbeddedObject::paintContents):
3444         (WebCore::RenderEmbeddedObject::isReplacementObscured):
3445         (WebCore::RenderEmbeddedObject::layout):
3446         (WebCore::RenderEmbeddedObject::viewCleared):
3447         (WebCore::RenderEmbeddedObject::handleUnavailablePluginIndicatorEvent):
3448         * rendering/RenderFileUploadControl.cpp:
3449         (WebCore::RenderFileUploadControl::updateFromElement):
3450         (WebCore::RenderFileUploadControl::maxFilenameWidth):
3451         (WebCore::RenderFileUploadControl::paintObject):
3452         (WebCore::RenderFileUploadControl::computeIntrinsicLogicalWidths):
3453         (WebCore::RenderFileUploadControl::uploadButton):
3454         (WebCore::RenderFileUploadControl::fileTextValue):
3455         * rendering/RenderFrame.cpp:
3456         (WebCore::RenderFrame::edgeInfo):
3457         (WebCore::RenderFrame::viewCleared):
3458         * rendering/RenderFrameBase.cpp:
3459         (WebCore::RenderFrameBase::layoutWithFlattening):
3460         * rendering/RenderFrameSet.cpp:
3461         (WebCore::RenderFrameSet::frameSet):
3462         * rendering/RenderHTMLCanvas.cpp:
3463         (WebCore::RenderHTMLCanvas::requiresLayer):
3464         (WebCore::RenderHTMLCanvas::paintReplaced):
3465         (WebCore::RenderHTMLCanvas::canvasSizeChanged):
3466         * rendering/RenderIFrame.cpp:
3467         (WebCore::RenderIFrame::isSeamless):
3468         (WebCore::RenderIFrame::flattenFrame):
3469         * rendering/RenderImage.cpp:
3470         (WebCore::RenderImage::imageChanged):
3471         (WebCore::RenderImage::paintAreaElementFocusRing):
3472         (WebCore::RenderImage::areaElementFocusChanged):
3473         (WebCore::RenderImage::paintIntoRect):
3474         (WebCore::RenderImage::imageMap):
3475         (WebCore::RenderImage::nodeAtPoint):
3476         (WebCore::RenderImage::updateAltText):
3477         * rendering/RenderInline.cpp:
3478         (WebCore::RenderInline::clone):
3479         (WebCore::RenderInline::hitTestCulledInline):
3480         (WebCore::RenderInline::updateHitTestResult):
3481         * rendering/RenderInline.h:
3482         * rendering/RenderLayer.cpp:
3483         (WebCore::RenderLayer::RenderLayer):
3484         (WebCore::RenderLayer::~RenderLayer):
3485         (WebCore::RenderLayer::name):
3486         (WebCore::RenderLayer::isTransparent):
3487         (WebCore::RenderLayer::scrollTo):
3488         (WebCore::RenderLayer::resize):
3489         (WebCore::RenderLayer::filterNeedsRepaint):
3490         * rendering/RenderLayerBacking.cpp:
3491         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
3492         (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration):
3493         * rendering/RenderLayerCompositor.cpp:
3494         (WebCore::RenderLayerCompositor::frameContentsCompositor):
3495         * rendering/RenderLayerFilterInfo.cpp:
3496         (WebCore::RenderLayer::FilterInfo::notifyFinished):
3497         (WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients):
3498         (WebCore::RenderLayer::FilterInfo::notifyCustomFilterProgramLoaded):
3499         * rendering/RenderLayerModelObject.cpp:
3500         (WebCore::RenderLayerModelObject::RenderLayerModelObject):
3501         * rendering/RenderLayerModelObject.h:
3502         (WebCore::RenderLayerModelObject::element):
3503         * rendering/RenderListBox.cpp:
3504         (WebCore::RenderListBox::selectElement):
3505         (WebCore::RenderListBox::paintItemForeground):
3506         (WebCore::RenderListBox::paintItemBackground):
3507         (WebCore::RenderListBox::scrollTo):
3508         (WebCore::RenderListBox::createScrollbar):
3509         * rendering/RenderListItem.cpp:
3510         (WebCore::isList):
3511         (WebCore::enclosingList):
3512         (WebCore::nextListItem):
3513         (WebCore::previousListItem):
3514         (WebCore::RenderListItem::calcValue):
3515         (WebCore::RenderListItem::explicitValueChanged):
3516         (WebCore::RenderListItem::setExplicitValue):
3517         (WebCore::RenderListItem::clearExplicitValue):
3518         (WebCore::previousOrNextItem):
3519         (WebCore::RenderListItem::updateListMarkerNumbers):
3520         * rendering/RenderMarquee.cpp:
3521         (WebCore::RenderMarquee::marqueeSpeed):
3522         * rendering/RenderMedia.cpp:
3523         (WebCore::RenderMedia::mediaElement):
3524         * rendering/RenderMediaControlElements.cpp:
3525         (WebCore::RenderMediaControlTimelineContainer::layout):
3526         (WebCore::RenderTextTrackContainerElement::layout):
3527         * rendering/RenderMenuList.cpp:
3528         (WebCore::RenderMenuList::selectElement):
3529         (WebCore::RenderMenuList::valueChanged):
3530         (WebCore::RenderMenuList::createScrollbar):
3531         * rendering/RenderMeter.cpp:
3532         (WebCore::RenderMeter::meterElement):
3533         * rendering/RenderPart.cpp:
3534         (WebCore::RenderPart::requiresAcceleratedCompositing):
3535         (WebCore::RenderPart::embeddedContentBox):
3536         * rendering/RenderProgress.cpp:
3537         (WebCore::RenderProgress::progressElement):
3538         * rendering/RenderReplaced.cpp:
3539         (WebCore::RenderReplaced::positionForPoint):
3540         (WebCore::RenderReplaced::isSelected):
3541         * rendering/RenderSearchField.cpp:
3542         (WebCore::RenderSearchField::autosaveName):
3543         (WebCore::RenderSearchField::createScrollbar):
3544         * rendering/RenderSlider.cpp:
3545         (WebCore::RenderSlider::layout):
3546         (WebCore::RenderSlider::inDragMode):
3547         * rendering/RenderSnapshottedPlugIn.cpp:
3548         (WebCore::RenderSnapshottedPlugIn::plugInImageElement):
3549         * rendering/RenderTable.cpp:
3550         (WebCore::RenderTable::convertStyleLogicalWidthToComputedWidth):
3551         (WebCore::RenderTable::convertStyleLogicalHeightToComputedHeight):
3552         (WebCore::RenderTable::nodeAtPoint):
3553         * rendering/RenderTableCell.cpp:
3554         (WebCore::RenderTableCell::parseColSpanFromDOM):
3555         (WebCore::RenderTableCell::parseRowSpanFromDOM):
3556         (WebCore::RenderTableCell::updateColAndRowSpanFlags):
3557         (WebCore::RenderTableCell::colSpanOrRowSpanChanged):
3558         (WebCore::RenderTableCell::computePreferredLogicalWidths):
3559         * rendering/RenderTableCol.cpp:
3560         (WebCore::RenderTableCol::updateFromElement):
3561         * rendering/RenderTextControl.cpp:
3562         (WebCore::RenderTextControl::textFormControlElement):
3563         (WebCore::RenderTextControl::adjustInnerTextStyle):
3564         (WebCore::RenderTextControl::updateFromElement):
3565         (WebCore::RenderTextControl::layoutSpecialExcludedChild):
3566         * rendering/RenderTextControlMultiLine.cpp:
3567         (WebCore::RenderTextControlMultiLine::~RenderTextControlMultiLine):
3568         (WebCore::RenderTextControlMultiLine::nodeAtPoint):
3569         (WebCore::RenderTextControlMultiLine::preferredContentLogicalWidth):
3570         (WebCore::RenderTextControlMultiLine::computeControlLogicalHeight):
3571         * rendering/RenderTextControlSingleLine.cpp:
3572         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
3573         (WebCore::RenderTextControlSingleLine::capsLockStateMayHaveChanged):
3574         (WebCore::RenderTextControlSingleLine::textShouldBeTruncated):
3575         (WebCore::RenderTextControlSingleLine::inputElement):
3576         * rendering/RenderThemeMac.mm:
3577         (WebCore::RenderThemeMac::paintSnapshottedPluginOverlay):
3578         * rendering/RenderTreeAsText.cpp:
3579         (WebCore::writeRenderRegionList):
3580         * rendering/RenderVideo.cpp:
3581         (WebCore::RenderVideo::updateIntrinsicSize):
3582         (WebCore::RenderVideo::videoElement):
3583         * rendering/RenderWidget.cpp:
3584         (WebCore::RenderWidget::setWidgetGeometry):
3585         (WebCore::RenderWidget::updateWidgetPosition):
3586         (WebCore::RenderWidget::nodeAtPoint):
3587         * rendering/mathml/RenderMathMLFenced.cpp:
3588         (WebCore::RenderMathMLFenced::updateFromElement):
3589         (WebCore::RenderMathMLFenced::createMathMLOperator):
3590         (WebCore::RenderMathMLFenced::styleDidChange):
3591         * rendering/mathml/RenderMathMLFraction.cpp:
3592         (WebCore::RenderMathMLFraction::updateFromElement):
3593         * rendering/mathml/RenderMathMLOperator.cpp:
3594         (WebCore::RenderMathMLOperator::updateFromElement):
3595         (WebCore::RenderMathMLOperator::createGlyph):
3596         * rendering/mathml/RenderMathMLSpace.cpp:
3597         (WebCore::RenderMathMLSpace::updateFromElement):
3598         * rendering/svg/RenderSVGForeignObject.cpp:
3599         (WebCore::RenderSVGForeignObject::layout):
3600         * rendering/svg/RenderSVGRoot.cpp:
3601         (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation):
3602         (WebCore::RenderSVGRoot::isEmbeddedThroughSVGImage):
3603         (WebCore::RenderSVGRoot::isEmbeddedThroughFrameContainingSVGDocument):
3604         (WebCore::RenderSVGRoot::computeReplacedLogicalWidth):
3605         (WebCore::RenderSVGRoot::computeReplacedLogicalHeight):
3606         (WebCore::RenderSVGRoot::layout):
3607         (WebCore::RenderSVGRoot::paintReplaced):
3608         (WebCore::RenderSVGRoot::buildLocalToBorderBoxTransform):
3609         (WebCore::RenderSVGRoot::nodeAtPoint):
3610         (WebCore::RenderSVGRoot::hasRelativeDimensions):
3611         (WebCore::RenderSVGRoot::hasRelativeIntrinsicLogicalWidth):
3612         (WebCore::RenderSVGRoot::hasRelativeLogicalHeight):
3613         * rendering/svg/RenderSVGText.cpp:
3614         (WebCore::RenderSVGText::layout):
3615         (WebCore::RenderSVGText::strokeBoundingBox):
3616         * rendering/svg/RenderSVGTextPath.cpp:
3617         (WebCore::RenderSVGTextPath::layoutPath):
3618         (WebCore::RenderSVGTextPath::startOffset):
3619         (WebCore::RenderSVGTextPath::exactAlignment):
3620         (WebCore::RenderSVGTextPath::stretchMethod):
3621
3622 2013-09-09  Antti Koivisto  <antti@apple.com>
3623
3624         Make RenderView anonymous
3625         https://bugs.webkit.org/show_bug.cgi?id=121013
3626
3627         Reviewed by Darin Adler and Dave Hyatt.
3628
3629         RenderView is currently the only renderer that has an associated Node that is not either Element or Text.
3630         By making it anonymous (not have associated node, RenderView::node() returns null) we will be able to 
3631         significantly tighten typing in both render and DOM trees.
3632
3633         * accessibility/AccessibilityRenderObject.cpp:
3634         (WebCore::AccessibilityRenderObject::node):
3635         
3636             We need to grab document() instead of node() in a few places for RenderViews to keep existing code
3637             behaving like it did.
3638
3639         * inspector/InspectorLayerTreeAgent.cpp:
3640         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
3641         
3642             Don't tell inspector that the root layer is anonymous for now to avoid changing behavior.
3643
3644         * rendering/RenderBlock.cpp:
3645         (WebCore::RenderBlock::nodeForHitTest):
3646         * rendering/RenderBox.cpp:
3647         (WebCore::RenderBox::canBeProgramaticallyScrolled):
3648         
3649             The old non-virtual RenderView test renderer->node == &renderer->document() does not work anymore.
3650             Switch to isRenderView() which is now non-virtual in a number of places.
3651
3652         (WebCore::RenderBox::canAutoscroll):
3653         (WebCore::RenderBox::findAutoscrollable):
3654         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
3655         * rendering/RenderBoxModelObject.cpp:
3656         (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight):
3657         * rendering/RenderLayerBacking.cpp:
3658         (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
3659         * rendering/RenderObject.h:
3660         (WebCore::RenderObject::isRenderReplaced):
3661         (WebCore::RenderObject::isAnonymousBlock):
3662         
3663             RenderView is anonymous but not a CSS anonymous block.
3664
3665         (WebCore::RenderObject::isText):
3666         (WebCore::RenderObject::isRenderView):
3667         
3668             Make isRenderView non-virtual since it is now hot. Reuse existing bits.
3669
3670         (WebCore::RenderObject::setIsText):
3671         (WebCore::RenderObject::setIsRenderView):
3672         (WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
3673         * rendering/RenderTreeAsText.cpp:
3674         (WebCore::writeSelection):
3675         * rendering/RenderView.cpp:
3676         
3677             Make anonymous.
3678
3679         (WebCore::RenderView::RenderView):
3680         * rendering/RenderView.h:
3681         * rendering/svg/RenderSVGRoot.cpp:
3682         (WebCore::RenderSVGRoot::computeReplacedLogicalHeight):
3683
3684 2013-09-09  Bem Jones-Bey  <bjonesbe@adobe.com>
3685
3686         Move logical(Left|Right)FloatOffsetForLine methods into FloatingObjects
3687         https://bugs.webkit.org/show_bug.cgi?id=120705
3688
3689         Reviewed by Sam Weinig.
3690
3691         These are the only consumers of the CalculateFloatOffsetAdapter and
3692         the placed floats tree, so it will allow us to reduce the public
3693         interface of FloatingObjects and make the placed floats tree private.
3694
3695         No new tests, no behavior change.
3696
3697         * rendering/RenderBlock.cpp:
3698         (WebCore::RenderBlock::logicalLeftFloatOffsetForLine):
3699         (WebCore::RenderBlock::logicalRightFloatOffsetForLine):
3700         (WebCore::RenderBlock::FloatingObjects::logicalLeftOffset):
3701         (WebCore::RenderBlock::FloatingObjects::logicalRightOffset):
3702         * rendering/RenderBlock.h:
3703         (WebCore::RenderBlock::FloatingObjects::placedFloatsTree):
3704
3705 2013-09-09  Christophe Dumez  <ch.dumez@sisa.samsung.com>
3706
3707         Add support for BeforeUnloadEvent interface
3708         https://bugs.webkit.org/show_bug.cgi?id=120849
3709
3710         Reviewed by Darin Adler.
3711
3712         Add support for BeforeUnloadEvent as per the specification:
3713         http://www.whatwg.org/specs/web-apps/current-work/#beforeunloadevent
3714
3715         BeforeUnloadEvent has a returnValue attribute. Setting returnValue to a non-empty
3716         string in an event handler causes the user agent should ask the user to confirm
3717         that they wish to unload the document. This is equivalent to returning a non-empty
3718         string in the EventHandler:
3719         http://www.whatwg.org/specs/web-apps/current-work/#onbeforeunloadeventhandler
3720
3721         BeforeUnloadEvent and returnValue are already supported by IE and Firefox. Previously,
3722         WebKit was passing a base Event type to the beforeunload event handlers instead of
3723         a BeforeUnloadEvent.
3724
3725         Note that this patch keeps support for the legacy Event.returnValue attribute. This used
3726         to be an IE extension but this is no longer supported by IE (nor Firefox). The standard
3727         preventDefault() should be used instead however (supported in IE >= 9).
3728
3729         Test: fast/events/before-unload-returnValue.html
3730
3731         * CMakeLists.txt:
3732         * DerivedSources.cpp:
3733         * DerivedSources.make:
3734         * DerivedSources.pri:
3735         * GNUmakefile.list.am:
3736         * WebCore.order:
3737         * WebCore.vcxproj/WebCore.vcxproj:
3738         * bindings/js/JSEventListener.cpp:
3739         (WebCore::JSEventListener::handleEvent):
3740         * dom/BeforeUnloadEvent.cpp:
3741         (WebCore::BeforeUnloadEvent::isBeforeUnloadEvent):
3742         (WebCore::BeforeUnloadEvent::~BeforeUnloadEvent):
3743         * dom/BeforeUnloadEvent.h:
3744         (WebCore::BeforeUnloadEvent::create):
3745         (WebCore::BeforeUnloadEvent::returnValue):
3746         (WebCore::BeforeUnloadEvent::setReturnValue):
3747         (WebCore::toBeforeUnloadEvent):
3748         * dom/BeforeUnloadEvent.idl: Added.
3749         * dom/Event.cpp:
3750         (WebCore::Event::isBeforeUnloadEvent):
3751         * dom/Event.h:
3752         (WebCore::Event::legacyReturnValue):
3753         (WebCore::Event::setLegacyReturnValue):
3754         * dom/Event.idl:
3755         * dom/EventNames.in:
3756         * loader/FrameLoader.cpp:
3757         (WebCore::FrameLoader::handleBeforeUnloadEvent):
3758
3759 2013-09-06  David Hyatt  <hyatt@apple.com>
3760
3761         Get rid of isBlockFlowFlexBoxOrGrid().
3762         https://bugs.webkit.org/show_bug.cgi?id=120897
3763
3764         Convert all callers and get rid of this method.
3765
3766         Reviewed by Beth Dakin.
3767
3768         * accessibility/AccessibilityRenderObject.cpp:
3769         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
3770         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
3771         * dom/Position.cpp:
3772         (WebCore::Position::isCandidate):
3773         (WebCore::Position::getInlineBoxAndOffset):
3774         (WebCore::Position::primaryDirection):
3775         * dom/PositionIterator.cpp:
3776         (WebCore::PositionIterator::isCandidate):
3777         * editing/CompositeEditCommand.cpp:
3778         (WebCore::CompositeEditCommand::addBlockPlaceholderIfNeeded):
3779         * editing/Editor.cpp:
3780         (WebCore::Editor::baseWritingDirectionForSelectionStart):
3781         * editing/FrameSelection.cpp:
3782         (WebCore::caretRenderer):
3783         * editing/TextIterator.cpp:
3784         (WebCore::TextIterator::shouldRepresentNodeOffsetZero):
3785         * editing/TypingCommand.cpp:
3786         (WebCore::TypingCommand::makeEditableRootEmpty):
3787         * editing/htmlediting.cpp:
3788         (WebCore::isBlockFlowElement):
3789         * rendering/LayoutState.cpp:
3790         (WebCore::LayoutState::LayoutState):
3791         * rendering/RenderBlock.cpp:
3792         (WebCore::RenderBlock::layoutBlock):
3793         (WebCore::RenderBlock::collapseMargins):
3794         (WebCore::RenderBlock::selectionGaps):
3795         (WebCore::RenderBlock::firstLineBoxBaseline):
3796         (WebCore::RenderBlock::lastLineBoxBaseline):
3797         (WebCore::RenderBlock::firstLineBlock):
3798         (WebCore::findFirstLetterBlock):
3799         (WebCore::shouldCheckLines):
3800         (WebCore::RenderBlock::adjustForBorderFit):
3801         * rendering/RenderBox.cpp:
3802         (WebCore::RenderBox::computeRectForRepaint):
3803         (WebCore::RenderBox::positionForPoint):
3804         * rendering/RenderBoxModelObject.h:
3805         (WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion):
3806         * rendering/RenderInline.cpp:
3807         (WebCore::RenderInline::computeRectForRepaint):
3808         * rendering/RenderLineBoxList.cpp:
3809         (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
3810         * rendering/RenderObject.cpp:
3811         (WebCore::RenderObject::computeRectForRepaint):
3812         (WebCore::RenderObject::styleWillChange):
3813         (WebCore::firstLineStyleForCachedUncachedType):
3814         * rendering/RenderObject.h:
3815         * rendering/RenderObjectChildList.cpp:
3816         (WebCore::RenderObjectChildList::insertChildNode):
3817         * rendering/RenderView.h:
3818
3819 2013-09-09  Eric Carlson  <eric.carlson@apple.com>
3820
3821         MediaStream API: Stop means stop
3822         https://bugs.webkit.org/show_bug.cgi?id=120873
3823
3824         Reviewed by Jer Noble.
3825
3826         Merge blink https://chromium.googlesource.com/chromium/blink/+/9a97b0f3892320fa5741485e06a78183b77c3635
3827         by Tommy Widenflycht.
3828
3829         Removing notification functionality from MediaStreamTrack::stop because the world is being torn down.
3830
3831         No new tests, the original author was unable to come up with a reliable test case.
3832
3833         * Modules/mediastream/MediaStreamTrack.cpp:
3834         (WebCore::MediaStreamTrack::stop): Don't call didEndTrack, the world is going away.
3835
3836 2013-09-09  Filip Pizlo  <fpizlo@apple.com>
3837
3838         Unreviewed, fix build.
3839
3840         * Modules/encryptedmedia/MediaKeySession.h:
3841
3842 2013-09-09  Eric Carlson  <eric.carlson@apple.com>
3843
3844         MediaStream API: Moving Add/Remove track from WebMediaStreamCenterClient to WebMediaStream
3845         https://bugs.webkit.org/show_bug.cgi?id=120872
3846
3847         Reviewed by Jer Noble.
3848
3849         Merge https://chromium.googlesource.com/chromium/blink/+/7d740fd27c1f345b59c846df01c3adce53c18e6e
3850         Simple cleanup that makes the API cleaner.
3851
3852         * Modules/mediastream/MediaStream.cpp:
3853         (WebCore::MediaStream::removeTrack):
3854         (WebCore::MediaStream::addRemoteTrack):
3855         (WebCore::MediaStream::removeRemoteTrack):
3856         * platform/mediastream/MediaStreamCenter.cpp:
3857         * platform/mediastream/MediaStreamCenter.h:
3858         * platform/mediastream/MediaStreamDescriptor.h:
3859         (WebCore::MediaStreamDescriptor::removeAudioComponent):
3860         (WebCore::MediaStreamDescriptor::addRemoteTrack):
3861         (WebCore::MediaStreamDescriptor::removeRemoteTrack):
3862
3863 2013-09-09  ChangSeok Oh  <changseok.oh@collabora.com>
3864
3865         [WK2] Assertion failure in WebCore::Page::checkSubframeCountConsistency when going back
3866         https://bugs.webkit.org/show_bug.cgi?id=119781
3867
3868         Reviewed by Alexey Proskuryakov.
3869
3870         We should pair restoring a cached frame and adding it to FrameTree so that
3871         actual added frame count in FrameTree keeps same with restored frame count.
3872         Otherwise assert failure occurs in Page::CheckSubframeCountConsistency.
3873         We have added cached frames to FrameTree ahead and then restored them by tree travelsal.
3874         But this way doesn't guarantee subframecount of Page and the number of child of FrameTree are equal.
3875         In addition, we still make sure that adding a cached frame to FrameTree should happen
3876         before opening it. Because FrameTree might be used while restoring a cached page.
3877
3878         Test: fast/history/go-back-to-iframe-with-plugin.html
3879
3880         * history/CachedFrame.cpp:
3881         (WebCore::CachedFrameBase::restore):
3882         (WebCore::CachedFrame::open):
3883
3884 2013-09-09  Luciano Wolf  <luciano.wolf@openbossa.org>
3885
3886         Nix upstreaming - Adding stubs and Nix specific platform files
3887         https://bugs.webkit.org/show_bug.cgi?id=118358
3888
3889         Reviewed by Benjamin Poulain.
3890
3891         Basically adding all files that have "Nix" in their names and
3892         are related to WebCore module.
3893
3894         No new tests. They will be uploaded on another patch during the
3895         upstreaming process.
3896
3897         * css/mediaControlsNix.css: Added.
3898         * css/mediaControlsNixFullscreen.css: Added.
3899         * page/nix/EventHandlerNix.cpp: Added.
3900         * platform/graphics/egl/GLContextFromCurrentEGL.cpp: Added.
3901         * platform/graphics/egl/GLContextFromCurrentEGL.h: Added.
3902         * platform/graphics/gstreamer/PlatformVideoWindowNix.cpp: Added.
3903         * platform/graphics/nix/IconNix.cpp: Added.
3904         * platform/graphics/nix/ImageNix.cpp: Added.
3905         * platform/nix/CursorNix.cpp: Added.
3906         * platform/nix/DragDataNix.cpp: Added.
3907         * platform/nix/DragImageNix.cpp: Added.
3908         * platform/nix/GamepadsNix.cpp: Added.
3909         * platform/nix/LanguageNix.cpp: Added.
3910         * platform/nix/LocalizedStringsNix.cpp: Added.
3911         * platform/nix/NixKeyboardUtilities.cpp: Added.
3912         * platform/nix/NixKeyboardUtilities.h: Added.
3913         * platform/nix/PasteboardNix.cpp: Added.
3914         * platform/nix/PlatformKeyboardEventNix.cpp: Added.
3915         * platform/nix/PlatformScreenNix.cpp: Added.
3916         * platform/nix/SoundNix.cpp: Added.
3917         * platform/nix/WidgetNix.cpp: Added.
3918         * platform/text/nix/TextBreakIteratorInternalICUNix.cpp: Added.
3919
3920 2013-09-09  Hugo Parente Lima  <hugo.lima@openbossa.org>
3921
3922         Preparing WebCore to receive Nix Port
3923         https://bugs.webkit.org/show_bug.cgi?id=118326
3924
3925         Reviewed by Eric Carlson.
3926
3927         Only adding the compilation directives that are Nix specific, in the
3928         existent WebCore files
3929
3930         * loader/FrameLoader.cpp:
3931         (WebCore::FrameLoader::defaultObjectContentType):
3932         * platform/Cursor.h:
3933         * platform/DragData.h:
3934         * platform/DragImage.h:
3935         * platform/FileSystem.h:
3936         * platform/RunLoop.h:
3937         * platform/Widget.h:
3938         * platform/audio/FFTFrame.h:
3939         * platform/audio/HRTFElevation.cpp:
3940         * platform/cairo/WidgetBackingStore.h:
3941         * platform/graphics/ANGLEWebKitBridge.h:
3942         * platform/graphics/FontPlatformData.h:
3943         * platform/graphics/GraphicsContext3D.cpp:
3944         * platform/graphics/GraphicsContext3D.h:
3945         * platform/graphics/OpenGLESShims.h:
3946         * platform/graphics/OpenGLShims.cpp:
3947         (WebCore::getProcAddress):
3948         * platform/graphics/OpenGLShims.h:
3949         * platform/graphics/PlatformLayer.h:
3950         * platform/graphics/cairo/GLContext.cpp:
3951         (WebCore::GLContext::createContextForWindow):
3952         * platform/graphics/cairo/GraphicsContext3DPrivate.cpp:
3953         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
3954         * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
3955         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
3956         (WebCore::Extensions3DOpenGL::createVertexArrayOES):
3957         (WebCore::Extensions3DOpenGL::deleteVertexArrayOES):
3958         (WebCore::Extensions3DOpenGL::isVertexArrayOES):
3959         (WebCore::Extensions3DOpenGL::bindVertexArrayOES):
3960         (WebCore::Extensions3DOpenGL::supportsExtension):
3961         * platform/graphics/opengl/Extensions3DOpenGL.h:
3962         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
3963         * platform/graphics/opengl/Extensions3DOpenGLES.h:
3964         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
3965         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
3966         (WebCore::GraphicsContext3D::reshape):
3967         * platform/graphics/texmap/TextureMapper.h:
3968         * plugins/PluginPackage.cpp:
3969         * plugins/PluginView.cpp:
3970         (WebCore::PluginView::PluginView):
3971         * plugins/PluginView.h:
3972         * plugins/PluginViewNone.cpp:
3973
3974 2013-09-08  Darin Adler  <darin@apple.com>
3975
3976         Tighten up EventQueue classes a bit, less indirection and memory allocation
3977         https://bugs.webkit.org/show_bug.cgi?id=121016
3978
3979         Reviewed by Andreas Kling.
3980
3981         * Modules/encryptedmedia/MediaKeySession.cpp:
3982         (WebCore::MediaKeySession::MediaKeySession): Updated since event queue is now
3983         a member rather than an OwnPtr.
3984         (WebCore::MediaKeySession::close): Ditto.
3985         (WebCore::MediaKeySession::keyRequestTimerFired): Ditto.
3986         (WebCore::MediaKeySession::addKeyTimerFired): Ditto.
3987         * Modules/encryptedmedia/MediaKeySession.h: Ditto.
3988
3989         * Modules/indexeddb/IDBDatabase.cpp:
3990         (WebCore::IDBDatabase::closeConnection): Updated since ScriptExecutionContext's
3991         eventQueue function now returns a reference rather than a pointer. Also, the
3992         cancelEvent function takes a reference instead of a pointer.
3993         (WebCore::IDBDatabase::enqueueEvent): Ditto.
3994         * Modules/indexeddb/IDBRequest.cpp:
3995         (WebCore::IDBRequest::abort): Ditto.
3996         (WebCore::IDBRequest::enqueueEvent): Ditto.
3997         * Modules/indexeddb/IDBTransaction.cpp:
3998         (WebCore::IDBTransaction::enqueueEvent): Ditto.
3999
4000         * Modules/mediasource/MediaSource.cpp:
4001         (WebCore::MediaSource::MediaSource): Updated since event queue is now a
4002         member rather than an OwnPtr. Also use initialization instead of assignment
4003         to set up source buffers.
4004         (WebCore::MediaSource::hasPendingActivity): Ditto.
4005         (WebCore::MediaSource::stop): Ditto.
4006         (WebCore::MediaSource::scheduleEvent): Ditto.
4007         * Modules/mediasource/MediaSource.h: Ditto.
4008
4009         * Modules/mediasource/SourceBufferList.cpp:
4010         (WebCore::SourceBufferList::SourceBufferList): Take references instead of
4011         pointers.
4012         (WebCore::SourceBufferList::length): Changed type to unsigned instead of
4013         unsigned long. This is an IDL "unsigned long", which corresponds to "unsigned"
4014         in our C++ DOM implementation.
4015         (WebCore::SourceBufferList::createAndFireEvent): Updated since event queue is
4016         now a reference.
4017         (WebCore::SourceBufferList::scriptExecutionContext): Updated since script
4018         execution context is now a reference.
4019         * Modules/mediasource/SourceBufferList.h: Ditto.
4020
4021         * dom/Document.cpp:
4022         (WebCore::Document::Document): Updated since event queue is now a member rather
4023         than a RefPtr.
4024         (WebCore::Document::detach): Ditto.
4025         (WebCore::Document::enqueueWindowEvent): Ditto.
4026         (WebCore::Document::enqueueDocumentEvent): Ditto.
4027         * dom/Document.h: Ditto.
4028
4029         * dom/DocumentEventQueue.cpp: Renamed DocumentEventQueueTimer to just Timer and
4030         made it a class member of DocumentEventQueue. Also changed it to use references
4031         instead of pointers and removed unneeded ScriptExecutionContext argument.
4032         (WebCore::DocumentEventQueue::DocumentEventQueue): Updated to take a document
4033         reference instead of a script execution context pointer.
4034         (WebCore::DocumentEventQueue::enqueueEvent): Wrote the assertions in a clearer
4035         style and do the assertions even when the queue is closed.
4036         (WebCore::DocumentEventQueue::enqueueOrDispatchScrollEvent): Removed the unneeded
4037         ScrollEventTargetType argument, since the policy is specific to the document node.
4038         Made the argument a reference instead of a PassRefPtr, and rewrote the function
4039         to be more straightforward and readable.
4040         (WebCore::DocumentEventQueue::cancelEvent): Use the return value recently added&n