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