1 2013-09-10 Andreas Kling <akling@apple.com>
3 AnimationController should have a Frame& internally.
4 <https://webkit.org/b/121078>
6 Reviewed by Anders Carlsson.
8 The AnimationController is owned by the Frame so make the back-pointer
9 a reference. This knocks off a couple of null checks.
11 2013-09-10 Anders Carlsson <andersca@apple.com>
13 More WTF/Alignment.h removal
14 https://bugs.webkit.org/show_bug.cgi?id=121125
16 Reviewed by Andreas Kling.
18 * platform/PODArena.h:
20 2013-09-10 Eric Carlson <eric.carlson@apple.com>
22 Make MediaStream objects ScriptWrappable
23 https://bugs.webkit.org/show_bug.cgi?id=120879
25 Reviewed by Jer Noble.
27 * Modules/mediastream/MediaStream.h: Inherit from ScriptWrappable.
28 * Modules/mediastream/MediaStreamTrack.h: Ditto.
29 * Modules/mediastream/RTCDTMFSender.h: Ditto.
30 * Modules/mediastream/RTCDataChannel.h: Ditto.
31 * Modules/mediastream/RTCIceCandidate.h: Ditto.
32 * Modules/mediastream/RTCPeerConnection.h: Ditto.
33 * Modules/mediastream/RTCSessionDescription.h: Ditto.
34 * Modules/mediastream/RTCStatsReport.h: Ditto.
35 * Modules/mediastream/RTCStatsResponse.h: Ditto.
37 2013-09-10 Eric Carlson <eric.carlson@apple.com>
39 Split MediaStreamDescriptor.h and MediaStreamComponent.h into .h and .cpp
40 https://bugs.webkit.org/show_bug.cgi?id=120878
42 Reviewed by Jer Noble.
44 No new tests, no functional change.
46 * CMakeLists.txt: Add MediaStreamComponent.cpp and MediaStreamDescriptor.cpp.
47 * GNUmakefile.list.am: Ditto.
49 * Modules/mediastream/LocalMediaStream.cpp:
50 (WebCore::LocalMediaStream::create): MediaStreamDescriptor::create() doesn't take a UUID.
52 * Modules/mediastream/MediaStream.cpp:
53 (WebCore::createFromSourceVectors): Ditto.
55 * WebCore.xcodeproj/project.pbxproj: Add MediaStreamComponent.cpp and MediaStreamDescriptor.cpp.
57 * platform/mediastream/MediaStreamComponent.cpp: Added.
58 * platform/mediastream/MediaStreamComponent.h:
60 * platform/mediastream/MediaStreamDescriptor.cpp: Added.
61 * platform/mediastream/MediaStreamDescriptor.h:
63 2013-09-10 Brent Fulgham <bfulgham@apple.com>
65 [Windows] Create SharedGDIObject Class Template
66 https://bugs.webkit.org/show_bug.cgi?id=121037
68 Reviewed by Anders Carlsson.
70 * WebCore.vcxproj/WebCore.vcxproj: Remove RefCountedGDIHandle.h, and
71 add new SharedGDIObject.h file.
72 * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
73 * platform/graphics/FontPlatformData.h:
74 (WebCore::FontPlatformData::hfont): Switch to new SharedGDIObject.
75 * platform/graphics/win/FontPlatformDataCGWin.cpp:
76 (WebCore::FontPlatformData::FontPlatformData): Ditto.
77 * platform/graphics/win/FontPlatformDataCairoWin.cpp:
78 (WebCore::FontPlatformData::FontPlatformData): Ditto.
79 * platform/graphics/win/FontPlatformDataWin.cpp:
80 (WebCore::FontPlatformData::FontPlatformData): Ditto.
81 * platform/graphics/win/RefCountedGDIHandle.h: Removed.
82 * platform/graphics/win/SharedGDIObject.h: Added.
83 (WebCore::SharedGDIObject::create):
84 (WebCore::SharedGDIObject::get):
85 (WebCore::SharedGDIObject::hash):
86 (WebCore::SharedGDIObject::SharedGDIObject):
88 2013-09-10 Tim Horton <timothy_horton@apple.com>
90 [mac] PDFDocumentImage should use PDFKit to draw
91 https://bugs.webkit.org/show_bug.cgi?id=120651
92 <rdar://problem/12810731>
94 Unreviewed hopeful build fix.
96 * platform/graphics/mac/PDFDocumentImageMac.mm:
98 2013-09-10 Tim Horton <timothy_horton@apple.com>
100 [mac] PDFDocumentImage should use PDFKit to draw
101 https://bugs.webkit.org/show_bug.cgi?id=120651
102 <rdar://problem/12810731>
104 Reviewed by Alexey Proskuryakov.
106 Use PDFKit to draw PDF-in-<img> on Mac, so that annotations in PDF are painted.
108 Test: fast/images/pdf-as-image-with-annotations.html
110 * WebCore.xcodeproj/project.pbxproj:
111 Add PDFDocumentImageMac.mm.
113 * platform/graphics/cg/PDFDocumentImage.cpp:
114 (WebCore::PDFDocumentImage::PDFDocumentImage):
115 We don't need to initialize m_document anymore because it's now a RetainPtr.
116 Initialize m_hasPage to false.
118 (WebCore::PDFDocumentImage::~PDFDocumentImage):
119 We don't need to manually release our CGPDFDocumentRef anymore because it's now a RetainPtr.
121 (WebCore::PDFDocumentImage::size):
122 Use expandedIntSize for explicitness.
124 (WebCore::PDFDocumentImage::applyRotationForPainting):
125 Rename adjustCTM to applyRotationForPainting, and move the one non-rotation related transformation out.
126 We need to do this because PDFKit applies the rotation transformation itself, so we don't need to.
127 Also, explicitly use std::min instead of importing the whole std namespace.
129 (WebCore::PDFDocumentImage::dataChanged):
130 Assert that we don't re-enter dataChanged after we've created a document,
131 because it seems like that shouldn't happen - we only create a document when
132 we've supposedly received all data, and it would be nice if we didn't have
133 all this varying code to deal with SharedBuffers changing out from under each other.
134 Factor the code to create a CGPDFDocumentRef out into createPDFDocument, so we can
135 replace it with a different implementation that creates a PDFDocument.
137 (WebCore::PDFDocumentImage::setCurrentPage):
138 Make all page-number-related things unsigned, since they are in CG and PDFKit,
139 and add m_hasPage to denote whether we've acquired a valid page yet.
140 Factor code to retrieve the PDF box bounds into computeBoundsForCurrentPage.
141 Remove setCurrentPage itself, as we never use a page other than the first page;
142 we will call computeBoundsForCurrentPage and set hasPage in dataChanged, now.
144 (WebCore::PDFDocumentImage::draw):
146 Factor code that actually draws the PDF out into drawPDFPage.
148 The rest of the functions in this file are only built for USE(CG) && !PLATFORM(MAC):
150 (WebCore::PDFDocumentImage::createPDFDocument):
151 Factored out of dataChanged(). Use the PLATFORM(MAC) way of making a
152 CGDataProvider from a SharedBuffer everywhere; we're already using it on
153 iOS, and it should also work for Windows, the only other USE(CG) platform.
154 Since we only createPDFDocument() after all data has been received, remove
155 the comment about the SharedBuffer being secretly written to behind its back.
157 (WebCore::PDFDocumentImage::computeBoundsForCurrentPage):
158 Factored out of setCurrentPage().
159 Use deg2rad since we have it.
161 (WebCore::PDFDocumentImage::pageCount):
162 (WebCore::PDFDocumentImage::drawPDFPage):
163 Factored out of draw().
164 Reduced an unnecessary transform (we were effectively doing mediaBox.origin - cropBox.origin - mediaBox.origin).
166 * platform/graphics/cg/PDFDocumentImage.h:
167 Unindent all the things, as we don't indent the first level inside a namespace scope.
168 Forward-declare PDFDocument.
169 Make m_currentPage unsigned as it should be.
171 Make m_document a PDFDocument on PLATFORM(MAC) and a CGPDFDocumentRef on other platforms.
173 * platform/graphics/mac/PDFDocumentImageMac.mm: Added.
174 Soft-link in PDFKit and specifically the PDFDocument class.
176 (WebCore::PDFDocumentImage::createPDFDocument):
177 Create our PDFDocument from the SharedBuffer's NSData directly. This shouldn't be a problem
178 (with respect to the SharedBuffer's data being appended to in secret), because we've waited
179 for the document to finish loading before getting here.
181 (WebCore::PDFDocumentImage::computeBoundsForCurrentPage):
182 Ask PDFKit for the page's media and crop boxes; it automatically performs the correct fallback.
183 Ask PDFKit for the page's rotation.
185 (WebCore::PDFDocumentImage::pageCount):
186 Ask PDFKit for the page count.
188 (WebCore::PDFDocumentImage::drawPDFPage):
189 Paint the current page of the PDF. Note that we do not apply the rotation here
190 via applyRotationForPainting because PDFKit will do it itself.
191 Save and restore two bits of CG state which aren't saved and restored with the
192 graphics state, as PDFKit can mutate them above us (<rdar://problem/14951759>).
194 * platform/mac/SoftLinking.h:
195 I couldn't find any clients of SOFT_LINK_FRAMEWORK_IN_CORESERVICES_UMBRELLA,
196 so I made it the more generic SOFT_LINK_FRAMEWORK_IN_UMBRELLA, taking the name
197 of the umbrella framework and the subframework, so I could use it to soft link
198 Quartz.framework's PDFKit.framework.
200 2013-09-10 Tim Horton <timothy_horton@apple.com>
202 [mac] <progress> has rendering artifacts along the bottom
203 https://bugs.webkit.org/show_bug.cgi?id=120865
204 <rdar://problem/11571240>
206 Reviewed by Simon Fraser.
208 Allow RenderTheme to force the height of a <progress> bar.
210 Test: platform/mac/fast/forms/indeterminate-progress-inline-height.html
212 * rendering/RenderProgress.cpp:
213 (WebCore::RenderProgress::computeLogicalHeight):
214 Borrowed from RenderMeter, allow the theme to override the size of the progress bar.
216 * rendering/RenderProgress.h:
217 Drive-by add OVERRIDE to a few things.
219 * rendering/RenderTheme.cpp:
220 (WebCore::RenderTheme::progressBarRectForBounds):
221 * rendering/RenderTheme.h:
222 Add a default implementation of progressBarRectForBounds that just passes the bounds through.
224 * rendering/RenderThemeMac.h:
225 * rendering/RenderThemeMac.mm:
226 (WebCore::RenderThemeMac::progressBarRectForBounds):
227 Override progressBarRectForBounds; the implementation is factored out of paintProgressBar.
229 (WebCore::RenderThemeMac::paintProgressBar):
230 Make use of the factored-out progressBarRectForBounds().
232 Drive-by apply the device scale factor to the progress bar's image buffer,
233 so that it is rendered at 2x on appropriate hardware. Also, multiply the
234 progress animation phase by the device scale factor, as the phase value seems
235 to be proportional to the actual pixel offset of the animation; without this,
236 the animation would appear to progress half as slowly in HiDPI.
238 2013-09-10 Chris Fleizach <cfleizach@apple.com>
240 AX: Expose DOM ID and ClassList to AX APIs for automation and AT element hashes
241 https://bugs.webkit.org/show_bug.cgi?id=120552
243 Reviewed by Darin Adler.
245 Add Mac support for exposing the DOM ID and DOM class list so that accessibility
246 clients can leverage that information.
248 Test: platform/mac/accessibility/id-class-attributes.html
250 * accessibility/AccessibilityObject.cpp:
251 (WebCore::AccessibilityObject::domIdentifier):
252 (WebCore::AccessibilityObject::domClassList):
253 * accessibility/AccessibilityObject.h:
254 * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
255 (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
256 (convertStringsToNSArray):
257 (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
259 2013-09-10 Denis Nomiyama <d.nomiyama@samsung.com>
261 [GTK] accessibility/loading-iframe-sends-notification.html is failing
262 https://bugs.webkit.org/show_bug.cgi?id=98370
264 Reviewed by Chris Fleizach.
266 Enabled AXLayoutComplete on the GTK platform.
268 No new tests are required because this feature will use an existing
269 accessibility layout test that is currently failing on the GTK+ platform
270 (e.g. loading-iframe-sends-notification.html).
272 * accessibility/atk/AXObjectCacheAtk.cpp:
273 (WebCore::AXObjectCache::postPlatformNotification): Send layout-complete
274 signal in case of AXLayoutComplete.
276 (WebCore::Document::implicitClose): Enabled AXLayoutComplete on the GTK
278 * page/FrameView.cpp:
279 (WebCore::FrameView::layout): Enabled AXLayoutComplete on the GTK
282 2013-09-09 Brent Fulgham <bfulgham@apple.com>
284 [Windows] Change from using OwnPtr<GDI Stuff> to new GDIObject template.
285 https://bugs.webkit.org/show_bug.cgi?id=120778
287 Reviewed by Anders Carlsson.
289 Change code to use a GDI-specific smart pointer, rather than OwnPtr. This
290 is a first step to simplifying OwnPtr. It also gets rid of some Windows-
291 specific code in WTF.
293 * WebCore.vcxproj/WebCore.vcxproj: Add the new header file.
294 * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
295 * page/win/FrameCGWin.cpp:
296 (WebCore::imageFromRect): Switch to GDIObject.
297 * page/win/FrameCairoWin.cpp:
298 (WebCore::imageFromRect): Switch to GDIObject.
299 * page/win/FrameWin.cpp:
300 (WebCore::imageFromSelection): Switch to GDIObject.
301 (WebCore::Frame::dragImageForSelection): Ditto.
302 (WebCore::Frame::nodeImage): Ditto.
303 * page/win/FrameWin.h:
304 * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
305 (WebCore::getDirtyRects): Switch from OwnPtr to GDIObject.
306 * platform/graphics/win/FontCacheWin.cpp:
307 (WebCore::createGDIFont): Switch to GDIObject.
308 (WebCore::FontCache::createFontPlatformData): Ditto.
309 * platform/graphics/win/FontCustomPlatformData.cpp:
310 (WebCore::FontCustomPlatformData::fontPlatformData): Switch to GDIObject.
311 * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
312 (WebCore::FontCustomPlatformData::fontPlatformData): Switch to GDIObject.
313 * platform/graphics/win/GraphicsContextCGWin.cpp:
314 (WebCore::GraphicsContext::releaseWindowsContext): Switch to GDIObject.
315 * platform/graphics/win/GraphicsContextCairoWin.cpp:
316 (WebCore::GraphicsContext::releaseWindowsContext): Switch to GDIObject.
317 * platform/graphics/win/GraphicsContextWin.cpp:
318 (WebCore::GraphicsContext::getWindowsContext): Switch to GDIObject.
319 * platform/graphics/win/SimpleFontDataWin.cpp:
320 (WebCore::SimpleFontData::platformCreateScaledFontData): Switch to GDIObject.
321 * platform/win/CursorWin.cpp:
322 (WebCore::createSharedCursor): Switch to GDIObject.
323 * platform/win/DragImageCGWin.cpp:
324 (WebCore::scaleDragImage): Switch to GDIObject.
325 (WebCore::createDragImageFromImage):
326 * platform/win/DragImageCairoWin.cpp:
327 (WebCore::scaleDragImage): Switch to GDIObject.
328 (WebCore::createDragImageFromImage): Ditto.
329 * platform/win/DragImageWin.cpp:
330 (WebCore::createDragImageForLink): Switch to GDIObject.
331 * platform/win/PasteboardWin.cpp:
332 (WebCore::Pasteboard::writeImage): Switch to GDIObject.
333 * platform/win/ScrollbarThemeWin.cpp:
334 (WebCore::ScrollbarThemeWin::paintTrackPiece): Switch to GDIObject.
335 * plugins/win/PluginViewWin.cpp:
336 (WebCore::PluginView::updatePluginWidget): Switch to GDIObject.
337 (WebCore::PluginView::snapshot): Ditto.
338 * rendering/RenderThemeWin.cpp:
339 (WebCore::drawControl): Switch to GDIObject.
341 2013-09-10 Allan Sandfeld Jensen <allan.jensen@digia.com>
343 REGRESSION (r147454): Youtube annotation links to new window broken
344 https://bugs.webkit.org/show_bug.cgi?id=114242
346 Reviewed by Anders Carlsson.
348 Set the UserGestureIndicator to allow popups the same way the issue was solved for WebKit2.
350 * plugins/PluginView.cpp:
351 (WebCore::PluginView::performRequest):
353 2013-09-10 Alberto Garcia <berto@igalia.com>
355 [GTK] The code generator produces a warning if a parameter can be NULL
356 https://bugs.webkit.org/show_bug.cgi?id=121093
358 Reviewed by Christophe Dumez.
360 Return an empty string instead of an undefined value if a
361 particular parameter doesn't need to be checked.
363 * bindings/scripts/CodeGeneratorGObject.pm:
366 2013-09-10 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
368 MediaStream API: Enhance MediaStreamDescriptor add/remove component
369 https://bugs.webkit.org/show_bug.cgi?id=120874
371 Merge blink https://chromium.googlesource.com/chromium/blink/+/67fcacf13ce922a762d7a1c6fb9e1b8e51e662ea
373 Reviewed by Eric Carlson.
377 * Modules/mediastream/MediaStream.cpp:
378 (WebCore::MediaStream::addTrack):
379 (WebCore::MediaStream::removeTrack):
380 (WebCore::MediaStream::addRemoteTrack):
381 (WebCore::MediaStream::removeRemoteTrack):
382 * platform/mediastream/MediaStreamDescriptor.h:
383 (WebCore::MediaStreamDescriptor::addRemoteTrack):
384 (WebCore::MediaStreamDescriptor::removeRemoteTrack):
385 (WebCore::MediaStreamDescriptor::addComponent):
386 (WebCore::MediaStreamDescriptor::removeComponent):
388 2013-09-10 Andreas Kling <akling@apple.com>
390 toFooElement() should use static_cast, not reinterpret_cast.
391 <https://webkit.org/b/121087>
393 Reviewed by Antti Koivisto.
395 reinterpret_cast is not safe for downcasting with multiple inheritance.
396 Add a ELEMENT_TYPE_CASTS(classname) macro that goes after class definitions.
397 It expands into the following methods:
399 - FooElement* toFooElement(Node*)
400 - const FooElement* toFooElement(const Node*)
401 - FooElement& toFooElement(Node&)
402 - const FooElement& toFooElement(const Node&)
404 As a bonus, it also adds these to catch unnecessary casting:
406 - void toFooElement(const Node*)
407 - void toFooElement(const Node&)
409 There might be a more clever way of doing this, but this gets us to a
410 correct place so we can think in peace.
412 * bridge/qt/qt_pixmapruntime.cpp:
413 (JSC::Bindings::assignToHTMLImageElement):
414 (JSC::Bindings::QtPixmapRuntime::toQt):
416 (WebCore::isElement):
419 * html/HTMLAnchorElement.h:
420 * html/HTMLAreaElement.h:
421 * html/HTMLAudioElement.h:
422 * html/HTMLBaseElement.h:
423 * html/HTMLCanvasElement.h:
424 * html/HTMLElement.h:
425 (WebCore::isHTMLElement):
426 * html/HTMLFieldSetElement.h:
427 * html/HTMLFormElement.h:
428 * html/HTMLFrameSetElement.h:
429 * html/HTMLImageElement.h:
430 * html/HTMLInputElement.h:
431 * html/HTMLLabelElement.h:
432 * html/HTMLLegendElement.h:
433 * html/HTMLMapElement.h:
434 * html/HTMLMeterElement.h:
435 * html/HTMLOptGroupElement.h:
436 * html/HTMLOptionElement.h:
437 * html/HTMLParamElement.h:
438 * html/HTMLProgressElement.h:
439 * html/HTMLScriptElement.h:
440 * html/HTMLSourceElement.h:
441 * html/HTMLStyleElement.h:
442 * html/HTMLTableElement.h:
443 * html/HTMLTableRowElement.h:
444 * html/HTMLTextAreaElement.h:
445 * html/HTMLTitleElement.h:
446 * html/HTMLTrackElement.h:
447 * svg/SVGAltGlyphDefElement.h:
448 * svg/SVGAltGlyphElement.h:
449 * svg/SVGAltGlyphItemElement.h:
450 * svg/SVGAnimateMotionElement.h:
451 * svg/SVGAnimateTransformElement.h:
452 * svg/SVGCircleElement.h:
453 * svg/SVGClipPathElement.h:
454 * svg/SVGCursorElement.h:
455 * svg/SVGEllipseElement.h:
456 * svg/SVGFEDistantLightElement.h:
457 * svg/SVGFEFuncAElement.h:
458 * svg/SVGFEFuncBElement.h:
459 * svg/SVGFEFuncGElement.h:
460 * svg/SVGFEFuncRElement.h:
461 * svg/SVGFEMergeNodeElement.h:
462 * svg/SVGFEPointLightElement.h:
463 * svg/SVGFESpotLightElement.h:
464 * svg/SVGFilterElement.h:
465 * svg/SVGFontElement.h:
466 * svg/SVGFontFaceElement.h:
467 * svg/SVGFontFaceNameElement.h:
468 * svg/SVGFontFaceSrcElement.h:
469 * svg/SVGFontFaceUriElement.h:
470 * svg/SVGForeignObjectElement.h:
471 * svg/SVGGlyphElement.h:
472 * svg/SVGGlyphRefElement.h:
473 * svg/SVGHKernElement.h:
474 * svg/SVGImageElement.h:
475 * svg/SVGLineElement.h:
476 * svg/SVGLinearGradientElement.h:
477 * svg/SVGMPathElement.h:
478 * svg/SVGMarkerElement.h:
479 * svg/SVGMaskElement.h:
480 * svg/SVGMissingGlyphElement.h:
481 * svg/SVGPathElement.h:
482 * svg/SVGPatternElement.h:
483 * svg/SVGRadialGradientElement.h:
484 * svg/SVGRectElement.h:
485 * svg/SVGSVGElement.h:
486 * svg/SVGScriptElement.h:
487 * svg/SVGStyleElement.h:
488 * svg/SVGTextElement.h:
489 * svg/SVGTextPathElement.h:
490 * svg/SVGTitleElement.h:
491 * svg/SVGUseElement.h:
492 * svg/SVGVKernElement.h:
493 * svg/SVGViewElement.h:
495 2013-09-10 Mario Sanchez Prada <mario.prada@samsung.com>
497 [GTK] Test /webkit/atk/getTextInParagraphAndBodyModerate fails
498 https://bugs.webkit.org/show_bug.cgi?id=105538
500 Reviewed by Chris Fleizach.
502 Expose '\n' for linebreaks when they were explicitly set by the
503 author of the web content with a <br> tag.
505 Tests: accessibility/paragraph-with-linebreaks.html
507 * accessibility/AccessibilityNodeObject.cpp:
508 (WebCore::shouldAddSpaceBeforeAppendingNextElement): Helper
509 function to decide when to append spaces when building the text
510 under an element, considering line breaks.
511 (WebCore::AccessibilityNodeObject::textUnderElement): Use the
512 shouldAddSpaceBeforeAppendingNextElement() function here.
513 * accessibility/AccessibilityRenderObject.cpp:
514 (WebCore::AccessibilityRenderObject::textUnderElement): Return the
515 renderer's text for accessibility objects exposing <br> elements.
516 * html/parser/HTMLParserIdioms.h:
517 (WebCore::isHTMLSpaceButNotLineBreak): New helper function, useful
518 to be passed to other functions like simplifyWhiteSpace().
520 2013-09-10 Arpita Bahuguna <a.bah@samsung.com>
522 When deleting editable content, typing style should be reset when moving into another node.
523 https://bugs.webkit.org/show_bug.cgi?id=120726
525 Reviewed by Ryosuke Niwa.
527 When moving from one text node to the other, while deleting characters,
528 the deleted text node's style was being applied to any new characters
529 added into the existing text node.
531 Typing Style in the frame selection maintains the editing style for the
532 deleted text node, so that if new characters are inserted at the position
533 of the deleted text node, it's style can be applied to them.
535 However, when moving into another text node, we should reset or clear the
536 typing style maintained by the frame selection. This ensures that any new
537 content inserted within the existing node does not take on any uncleared
538 style of the deleted node.
540 Test: editing/deleting/maintain-style-after-delete.html
542 * editing/DeleteSelectionCommand.cpp:
543 (WebCore::DeleteSelectionCommand::saveTypingStyleState):
544 Calling clearTypingStyle() on frame selection whenever deletion occurs
545 within the same text node. Thus any existing typing styleh held by the
546 frame selection shall be cleared.
548 2013-09-09 Darin Adler <darin@apple.com>
550 Some refinements in FrameView::layout
551 https://bugs.webkit.org/show_bug.cgi?id=121076
553 Reviewed by Andreas Kling.
555 * page/FrameView.cpp:
556 (WebCore::FrameView::layout): Use a reference for the document in
557 this function since code assumes it's non-null anyway. Change code to
558 only call styleResolverIfExists once. Rewrite comments about blocks
559 and the scopes they create for better clarity. Make m_nestedLayoutCount
560 easier to read. Use HTMLElement* for the pointer to the body element.
561 Moved the call to calculateScrollbarModesForLayout in so we don't
562 waste time doing it for subtree layouts. Get rid of the unhelpful
563 currentHMode and currentVMode local variables. Get rid of an extra
564 block scope we did not need.
566 2013-09-09 Santosh Mahto <santosh.ma@samsung.com>
568 Adding "explicit" keyword in DOM related classes constructor
569 https://bugs.webkit.org/show_bug.cgi?id=121031
571 Reviewed by Ryosuke Niwa.
573 Added the explicit keyword in constructors.
575 * dom/ActiveDOMObject.h:
576 * dom/ContainerNode.h:
577 * dom/DocumentStyleSheetCollection.h:
578 * dom/ElementAncestorIterator.h:
580 * dom/ElementRareData.h:
581 * dom/EventListenerMap.h:
582 * dom/QualifiedName.h:
583 (WebCore::QualifiedName::QualifiedName):
585 * dom/ViewportArguments.h:
586 (WebCore::ViewportArguments::ViewportArguments):
587 * dom/VisitedLinkState.h:
589 2013-09-09 Andreas Kling <akling@apple.com>
591 Remove unreviewed gunk I just accidentally committed :|
593 2013-09-09 Andreas Kling <akling@apple.com>
595 HTMLTextAreaElement no longer needs custom style resolve callbacks.
596 <https://webkit.org/b/121073>
598 Reviewed by Ryosuke Niwa.
600 After r155408 HTMLTextAreaElement doesn't override didAttachRenderer() anymore,
601 so we don't need to fire callbacks on textarea elements during style resolve.
603 * html/HTMLTextAreaElement.cpp:
604 (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
606 2013-09-09 Andreas Kling <akling@apple.com>
608 ScriptController should have a Frame& internally.
609 <https://webkit.org/b/121071>
611 Reviewed by Anders Carlsson.
613 Change ScriptController::m_frame to a reference since it's tied to
614 the lifetime of the owning Frame.
616 2013-09-09 Andreas Kling <akling@apple.com>
618 ScriptRunner should have a Document& internally.
619 <https://webkit.org/b/121072>
621 Reviewed by Anders Carlsson.
623 Change ScriptRunner::m_document to a reference since it's tied to
624 the lifetime of the Document.
626 2013-09-09 Andreas Kling <akling@apple.com>
628 Ref-ify more stack guards.
629 <https://webkit.org/b/121070>
631 Rubber-stamped by Anders Carlsson.
633 RefPtr<Foo> protect(this) => Ref<Foo> protect(*this).
635 2013-09-09 Andreas Kling <akling@apple.com>
637 Generate more SVG type checks and conversions.
638 <https://webkit.org/b/121066>
640 Reviewed by Anders Carlsson.
642 Switch another slew of SVG elements to auto-generated isFooElement()
643 and toFooElement() helpers.
645 Removed now-unnecessary casts and assertions as appropriate.
646 Converted some simple loops to childrenOfType iteration instead of
647 traversing child Nodes.
649 PS. This patch also adds const versions of toFooElement().
651 2013-09-09 Dean Jackson <dino@apple.com>
653 [WebGL] Allow multithreaded OpenGL contexts
654 https://bugs.webkit.org/show_bug.cgi?id=121062
656 Reviewed by Simon Fraser.
658 Expose a new preference "multithreadedWebGLEnabled".
660 Also examine the value of that preference and, on Mac,
661 tell the CGLContext that it should go to multithreaded mode.
663 * html/canvas/WebGLRenderingContext.cpp:
664 (WebCore::WebGLRenderingContext::create): Look at the value of the new setting, and
665 toggle a flag on the context attributes.
666 * page/Settings.in: New Setting "multithreadedWebGLEnabled".
667 * platform/graphics/GraphicsContext3D.h:
668 (WebCore::GraphicsContext3D::Attributes::Attributes): Add a "multithreaded" flag.
669 * platform/graphics/mac/GraphicsContext3DMac.mm:
670 (WebCore::GraphicsContext3D::GraphicsContext3D): If the context attributes
671 suggest we should, tell the OpenGL context to go into multithreaded mode.
673 2013-09-09 Ryosuke Niwa <rniwa@webkit.org>
675 Remove HTMLTextFormControl::fixPlaceholderRenderer
676 https://bugs.webkit.org/show_bug.cgi?id=121058
678 Reviewed by Kent Tamura.
680 HTMLTextFormControl::fixPlaceholderRenderer was added in r118733 to swap the order in which placeholder appears.
681 Namely, when a text form control element is focused, placeholder should be rendered behind the text for the caret
682 to render on top of, not behind, the placeholder text. However, we can achieve the same effect by changing
683 the order of elements in the shadow DOM instead of manually manipuating the render tree as the assertion failure
684 mentioned in the change log is a bogus one.
686 Cleaned up the code by removing HTMLTextFormControl::fixPlaceholderRenderer and changed the order in which inner
687 text element and placeholder element appear. Also fixed the assertion in Position's constructor.
690 (WebCore::Position::Position): The original assertion was bogus. What we don't want have is for a Position to be
691 before or after a shadow root. It's fine for it be anchroed against the shadow root as long as it's inside.
693 * html/HTMLTextAreaElement.cpp:
694 (WebCore::HTMLTextAreaElement::updatePlaceholderText): Insert the placeholder before the inner text element.
695 * html/HTMLTextAreaElement.h:
696 * html/HTMLTextFormControlElement.cpp:
697 * html/HTMLTextFormControlElement.h:
698 * html/TextFieldInputType.cpp:
699 (WebCore::TextFieldInputType::updatePlaceholderText): Ditto.
700 * html/TextFieldInputType.h:
702 2013-09-09 Andreas Kling <akling@apple.com>
704 Hide node() below RenderSVGModelObject, use element() instead.
705 <https://webkit.org/b/121051>
707 Reviewed by Darin Adler.
709 This was almost already there, just delete node() and add an element() that returns a SVGElement*.
710 The SVG render tree is crazy casual about compile-time types, this is only scratching the surface.
712 2013-09-09 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
715 https://bugs.webkit.org/show_bug.cgi?id=121048
717 Reviewed by Darin Adler.
721 * platform/efl/RenderThemeEfl.cpp:
722 (WebCore::RenderThemeEfl::applyEdjeRTLState):
724 2013-09-09 Bem Jones-Bey <bjonesbe@adobe.com>
726 Move Floats out of RenderBlock
727 https://bugs.webkit.org/show_bug.cgi?id=120779
729 Reviewed by Alexandru Chiculita.
731 Move FloatingObject, FloatingObjects and related code into
732 FloatingObjects.{h,cpp}. This not only makes the code more readable
733 and maintainable, it also will allow for more decoupling of
734 RenderBlock and the FloatingObjects, hopefully making it possible for
735 FloatingObjects to be more central and not need to have one for each
736 RenderBlock that is affected by floats.
738 No new tests, no behavior change.
741 * GNUmakefile.list.am:
743 * WebCore.vcxproj/WebCore.vcxproj:
744 * WebCore.xcodeproj/project.pbxproj:
745 * rendering/FloatingObjects.cpp: Added.
746 (WebCore::ComputeFloatOffsetAdapter::ComputeFloatOffsetAdapter):
747 (WebCore::ComputeFloatOffsetAdapter::lowValue):
748 (WebCore::ComputeFloatOffsetAdapter::highValue):
749 (WebCore::ComputeFloatOffsetAdapter::outermostFloat):
750 (WebCore::FloatingObjects::FloatingObjects):
751 (WebCore::FloatingObjects::~FloatingObjects):
752 (WebCore::FloatingObjects::clearLineBoxTreePointers):
753 (WebCore::FloatingObjects::clear):
754 (WebCore::FloatingObjects::increaseObjectsCount):
755 (WebCore::FloatingObjects::decreaseObjectsCount):
756 (WebCore::FloatingObjects::intervalForFloatingObject):
757 (WebCore::FloatingObjects::addPlacedObject):
758 (WebCore::FloatingObjects::removePlacedObject):
759 (WebCore::FloatingObjects::add):
760 (WebCore::FloatingObjects::remove):
761 (WebCore::FloatingObjects::computePlacedFloatsTree):
762 (WebCore::FloatingObjects::logicalLeftOffset):
763 (WebCore::FloatingObjects::logicalRightOffset):
764 (WebCore::rangesIntersect):
765 (WebCore::::updateOffsetIfNeeded):
766 (WebCore::::collectIfNeeded):
767 (WebCore::::getHeightRemaining):
769 * rendering/FloatingObjects.h: Added.
770 (WebCore::FloatingObject::FloatingObject):
771 (WebCore::FloatingObject::clone):
772 (WebCore::FloatingObject::type):
773 (WebCore::FloatingObject::renderer):
774 (WebCore::FloatingObject::isPlaced):
775 (WebCore::FloatingObject::setIsPlaced):
776 (WebCore::FloatingObject::x):
777 (WebCore::FloatingObject::maxX):
778 (WebCore::FloatingObject::y):
779 (WebCore::FloatingObject::maxY):
780 (WebCore::FloatingObject::width):
781 (WebCore::FloatingObject::height):
782 (WebCore::FloatingObject::setX):
783 (WebCore::FloatingObject::setY):
784 (WebCore::FloatingObject::setWidth):
785 (WebCore::FloatingObject::setHeight):
786 (WebCore::FloatingObject::frameRect):
787 (WebCore::FloatingObject::setFrameRect):
788 (WebCore::FloatingObject::paginationStrut):
789 (WebCore::FloatingObject::setPaginationStrut):
790 (WebCore::FloatingObject::isInPlacedTree):
791 (WebCore::FloatingObject::setIsInPlacedTree):
792 (WebCore::FloatingObject::shouldPaint):
793 (WebCore::FloatingObject::setShouldPaint):
794 (WebCore::FloatingObject::isDescendant):
795 (WebCore::FloatingObject::setIsDescendant):
796 (WebCore::FloatingObject::setRenderer):
797 (WebCore::FloatingObject::originatingLine):
798 (WebCore::FloatingObject::setOriginatingLine):
799 (WebCore::FloatingObject::logicalTop):
800 (WebCore::FloatingObject::logicalBottom):
801 (WebCore::FloatingObject::logicalLeft):
802 (WebCore::FloatingObject::logicalRight):
803 (WebCore::FloatingObject::logicalWidth):
804 (WebCore::FloatingObject::pixelSnappedLogicalTop):
805 (WebCore::FloatingObject::pixelSnappedLogicalBottom):
806 (WebCore::FloatingObject::pixelSnappedLogicalLeft):
807 (WebCore::FloatingObject::pixelSnappedLogicalRight):
808 (WebCore::FloatingObject::setLogicalTop):
809 (WebCore::FloatingObject::setLogicalLeft):
810 (WebCore::FloatingObject::setLogicalHeight):
811 (WebCore::FloatingObject::setLogicalWidth):
812 (WebCore::FloatingObjectHashFunctions::hash):
813 (WebCore::FloatingObjectHashFunctions::equal):
814 (WebCore::FloatingObjectHashTranslator::hash):
815 (WebCore::FloatingObjectHashTranslator::equal):
816 (WebCore::FloatingObjects::setHorizontalWritingMode):
817 (WebCore::FloatingObjects::hasLeftObjects):
818 (WebCore::FloatingObjects::hasRightObjects):
819 (WebCore::FloatingObjects::set):
820 (WebCore::FloatingObjects::placedFloatsTree):
821 * rendering/RenderBlock.cpp:
822 (WebCore::RenderBlock::RenderBlock):
823 (WebCore::RenderBlock::insertFloatingObject):
824 * rendering/RenderBlock.h:
825 * rendering/RenderBlockLineLayout.cpp:
826 (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
827 (WebCore::LineLayoutState::lastFloat):
828 (WebCore::LineLayoutState::setLastFloat):
829 * rendering/RenderView.cpp:
830 (WebCore::RenderView::intervalArena):
832 2013-09-09 David Hyatt <hyatt@apple.com>
834 REGRESSION (r155377): Convert the media elements that were RenderBlocks to RenderBlockFlows
835 https://bugs.webkit.org/show_bug.cgi?id=121052
837 Reviewed by Anders Carlsson.
839 Convert a couple of media renderers that I missed from RenderBlock to RenderBlockFlow.
840 The previous patch that I landed added asserts that get triggered now when this
843 * rendering/RenderMediaControlElements.cpp:
844 (WebCore::RenderMediaVolumeSliderContainer::RenderMediaVolumeSliderContainer):
845 (WebCore::RenderMediaVolumeSliderContainer::layout):
846 (WebCore::RenderTextTrackContainerElement::RenderTextTrackContainerElement):
847 (WebCore::RenderTextTrackContainerElement::layout):
848 * rendering/RenderMediaControlElements.h:
850 2013-09-09 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
852 [Bug Fix] Calling m_audioComponents.remove in removeAudioComponent (MediaStreamDescriptor)
853 https://bugs.webkit.org/show_bug.cgi?id=121034
855 Reviewed by Eric Carlson.
859 * platform/mediastream/MediaStreamDescriptor.h:
860 (WebCore::MediaStreamDescriptor::removeAudioComponent):
862 2013-09-09 Anders Carlsson <andersca@apple.com>
864 Stop using WTF type traits in WebCore
865 https://bugs.webkit.org/show_bug.cgi?id=121042
867 Reviewed by Andreas Kling.
869 Replace uses of WTF type traits in CrossThreadCopier with a simpler solution
870 that uses std::is_convertible_to and some helpers.
872 * dom/CrossThreadTask.h:
873 * platform/CrossThreadCopier.h:
874 * platform/MainThreadTask.h:
876 2013-09-06 Ryosuke Niwa <rniwa@webkit.org>
878 Internals should always cause a layout before calling into TextIterator
879 https://bugs.webkit.org/show_bug.cgi?id=120891
881 Reviewed by Antti Koivisto.
883 Inspired by https://chromium.googlesource.com/chromium/blink/+/5fee5da7b04a710171c79bd6e87eca3533188e45.
885 Force a layout in the constructors of TextIterator, and SimplifiedBackwardsTextIterator and remove
886 superfluous calls to updateLayout() in other places.
888 As much as I hate for a constructor to have a side effect like this, I couldn't think of a better place
889 to update the layout. Unfortunately, we're slowly moving away from manually createing TextIterator and
890 wrapping them in a static function.
892 * editing/TextIterator.cpp:
893 (WebCore::TextIterator::TextIterator):
894 (WebCore::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator):
895 (WebCore::TextIterator::rangeFromLocationAndLength):
896 (WebCore::findPlainText):
898 2013-09-09 David Hyatt <hyatt@apple.com>
900 Move layoutBlock and layoutBlockChildren into RenderBlockFlow
901 https://bugs.webkit.org/show_bug.cgi?id=121036
903 Reviewed by Dean Jackson.
905 Move layoutBlock into RenderBlockFlow and make the base class version of
906 the method ASSERT_NOT_REACHED. Begin the process of moving block layout
907 into RenderBlockFlow by putting layoutBlockChildren there as well.
909 This patch also puts clearFloats into RenderBlockFlow and just ditches the
910 SVG-specific forceLayoutInlineChildren by letting RenderSVGText do what it
911 needs in its own file.
913 Convert RenderListBox to be a RenderBlockFlow, since this is necessary for it
914 to get the correct layoutBlock method.
916 Patch RenderRegion to call RenderBlockFlow::layoutBlock rather than RenderBlock::layoutBlock.
918 Fix run-ins so that they create block flows rather than blocks, and restrict run-ins to
921 * rendering/RenderBlock.cpp:
922 (WebCore::RenderBlock::layoutBlock):
923 (WebCore::RenderBlock::createReplacementRunIn):
924 (WebCore::RenderBlock::moveRunInUnderSiblingBlockIfNeeded):
925 * rendering/RenderBlock.h:
926 * rendering/RenderBlockFlow.cpp:
927 (WebCore::RenderBlockFlow::clearFloats):
928 (WebCore::RenderBlockFlow::layoutBlock):
929 (WebCore::RenderBlockFlow::layoutBlockChildren):
930 * rendering/RenderBlockFlow.h:
931 * rendering/RenderBlockLineLayout.cpp:
932 (WebCore::RenderBlockFlow::layoutInlineChildren):
933 * rendering/RenderListBox.cpp:
934 (WebCore::RenderListBox::RenderListBox):
935 (WebCore::RenderListBox::layout):
936 (WebCore::RenderListBox::paintObject):
937 (WebCore::RenderListBox::addFocusRingRects):
938 (WebCore::RenderListBox::nodeAtPoint):
939 * rendering/RenderListBox.h:
940 * rendering/RenderRegion.cpp:
941 (WebCore::RenderRegion::paintObject):
942 (WebCore::RenderRegion::styleDidChange):
943 (WebCore::RenderRegion::layoutBlock):
944 (WebCore::RenderRegion::insertedIntoTree):
945 (WebCore::RenderRegion::willBeRemovedFromTree):
946 (WebCore::RenderRegion::computeIntrinsicLogicalWidths):
947 (WebCore::RenderRegion::computePreferredLogicalWidths):
948 (WebCore::RenderRegion::updateLogicalHeight):
949 * rendering/RenderTextControlSingleLine.cpp:
950 (WebCore::RenderTextControlSingleLine::layout):
951 * rendering/svg/RenderSVGText.cpp:
952 (WebCore::RenderSVGText::layout):
954 2013-09-09 Antti Koivisto <antti@apple.com>
956 Try to fix GTK build.
960 * accessibility/AccessibilityTable.cpp:
961 (WebCore::AccessibilityTable::isTableExposableThroughAccessibility):
963 2013-09-09 Antti Koivisto <antti@apple.com>
965 Hide node() below RenderLayerModelObject, use element() instead
966 https://bugs.webkit.org/show_bug.cgi?id=121038
968 Reviewed by Dave Hyatt.
970 Switch all call sites to element(). Remove now unnecessary casts, type checks and dead code.
971 Make constructors below RenderLayerModelObject take an Element instead of a ContainerNode.
973 This also removes a branch from many hasTagName() and isFooElement() calls.
975 * accessibility/AccessibilityRenderObject.cpp:
976 (WebCore::startOfContinuations):
977 * accessibility/AccessibilityTable.cpp:
978 (WebCore::AccessibilityTable::isDataTable):
979 * accessibility/AccessibilityTableCell.cpp:
980 (WebCore::AccessibilityTableCell::titleUIElement):
981 * accessibility/AccessibilityTableColumn.cpp:
982 (WebCore::AccessibilityTableColumn::headerObjectForSection):
983 * editing/markup.cpp:
984 (WebCore::highestAncestorToWrapMarkup):
985 * html/HTMLTableCellElement.cpp:
986 (WebCore::HTMLTableCellElement::cellAbove):
987 * html/shadow/SliderThumbElement.cpp:
988 (WebCore::RenderSliderThumb::updateAppearance):
989 (WebCore::RenderSliderContainer::computeLogicalHeight):
990 (WebCore::RenderSliderContainer::layout):
992 (WebCore::Frame::frameForWidget):
993 * rendering/RenderBlock.cpp:
994 (WebCore::OverflowEventDispatcher::~OverflowEventDispatcher):
995 (WebCore::RenderBlock::RenderBlock):
996 (WebCore::RenderBlock::clone):
997 (WebCore::RenderBlock::createReplacementRunIn):
998 (WebCore::RenderBlock::paintObject):
999 (WebCore::RenderBlock::isSelectionRoot):
1000 (WebCore::RenderBlock::nodeForHitTest):
1001 (WebCore::RenderBlock::hasLineIfEmpty):
1002 (WebCore::RenderBlock::addFocusRingRects):
1003 * rendering/RenderBlock.h:
1004 * rendering/RenderBlockFlow.cpp:
1005 (WebCore::RenderBlockFlow::RenderBlockFlow):
1006 * rendering/RenderBlockFlow.h:
1007 * rendering/RenderBlockLineLayout.cpp:
1008 (WebCore::RenderBlock::addOverflowFromInlineChildren):
1009 * rendering/RenderBox.cpp:
1010 (WebCore::RenderBox::RenderBox):
1011 (WebCore::RenderBox::updateFromStyle):
1012 (WebCore::RenderBox::scroll):
1013 (WebCore::RenderBox::logicalScroll):
1014 (WebCore::RenderBox::canBeProgramaticallyScrolled):
1015 (WebCore::RenderBox::nodeAtPoint):
1016 (WebCore::RenderBox::paintCustomHighlight):
1017 (WebCore::RenderBox::computeLogicalWidthInRegion):
1018 (WebCore::RenderBox::sizesLogicalWidthToFitContent):
1019 (WebCore::RenderBox::localCaretRect):
1020 * rendering/RenderBox.h:
1021 * rendering/RenderBoxModelObject.cpp:
1022 (WebCore::RenderBoxModelObject::RenderBoxModelObject):
1023 * rendering/RenderBoxModelObject.h:
1024 * rendering/RenderButton.cpp:
1025 (WebCore::RenderButton::updateFromElement):
1026 (WebCore::RenderButton::canHaveGeneratedChildren):
1027 * rendering/RenderButton.h:
1028 * rendering/RenderEmbeddedObject.cpp:
1029 (WebCore::RenderEmbeddedObject::paintContents):
1030 (WebCore::RenderEmbeddedObject::isReplacementObscured):
1031 (WebCore::RenderEmbeddedObject::layout):
1032 (WebCore::RenderEmbeddedObject::viewCleared):
1033 (WebCore::RenderEmbeddedObject::handleUnavailablePluginIndicatorEvent):
1034 * rendering/RenderFileUploadControl.cpp:
1035 (WebCore::RenderFileUploadControl::updateFromElement):
1036 (WebCore::RenderFileUploadControl::maxFilenameWidth):
1037 (WebCore::RenderFileUploadControl::paintObject):
1038 (WebCore::RenderFileUploadControl::computeIntrinsicLogicalWidths):
1039 (WebCore::RenderFileUploadControl::uploadButton):
1040 (WebCore::RenderFileUploadControl::fileTextValue):
1041 * rendering/RenderFrame.cpp:
1042 (WebCore::RenderFrame::edgeInfo):
1043 (WebCore::RenderFrame::viewCleared):
1044 * rendering/RenderFrameBase.cpp:
1045 (WebCore::RenderFrameBase::layoutWithFlattening):
1046 * rendering/RenderFrameSet.cpp:
1047 (WebCore::RenderFrameSet::frameSet):
1048 * rendering/RenderHTMLCanvas.cpp:
1049 (WebCore::RenderHTMLCanvas::requiresLayer):
1050 (WebCore::RenderHTMLCanvas::paintReplaced):
1051 (WebCore::RenderHTMLCanvas::canvasSizeChanged):
1052 * rendering/RenderIFrame.cpp:
1053 (WebCore::RenderIFrame::isSeamless):
1054 (WebCore::RenderIFrame::flattenFrame):
1055 * rendering/RenderImage.cpp:
1056 (WebCore::RenderImage::imageChanged):
1057 (WebCore::RenderImage::paintAreaElementFocusRing):
1058 (WebCore::RenderImage::areaElementFocusChanged):
1059 (WebCore::RenderImage::paintIntoRect):
1060 (WebCore::RenderImage::imageMap):
1061 (WebCore::RenderImage::nodeAtPoint):
1062 (WebCore::RenderImage::updateAltText):
1063 * rendering/RenderInline.cpp:
1064 (WebCore::RenderInline::clone):
1065 (WebCore::RenderInline::hitTestCulledInline):
1066 (WebCore::RenderInline::updateHitTestResult):
1067 * rendering/RenderInline.h:
1068 * rendering/RenderLayer.cpp:
1069 (WebCore::RenderLayer::RenderLayer):
1070 (WebCore::RenderLayer::~RenderLayer):
1071 (WebCore::RenderLayer::name):
1072 (WebCore::RenderLayer::isTransparent):
1073 (WebCore::RenderLayer::scrollTo):
1074 (WebCore::RenderLayer::resize):
1075 (WebCore::RenderLayer::filterNeedsRepaint):
1076 * rendering/RenderLayerBacking.cpp:
1077 (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
1078 (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration):
1079 * rendering/RenderLayerCompositor.cpp:
1080 (WebCore::RenderLayerCompositor::frameContentsCompositor):
1081 * rendering/RenderLayerFilterInfo.cpp:
1082 (WebCore::RenderLayer::FilterInfo::notifyFinished):
1083 (WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients):
1084 (WebCore::RenderLayer::FilterInfo::notifyCustomFilterProgramLoaded):
1085 * rendering/RenderLayerModelObject.cpp:
1086 (WebCore::RenderLayerModelObject::RenderLayerModelObject):
1087 * rendering/RenderLayerModelObject.h:
1088 (WebCore::RenderLayerModelObject::element):
1089 * rendering/RenderListBox.cpp:
1090 (WebCore::RenderListBox::selectElement):
1091 (WebCore::RenderListBox::paintItemForeground):
1092 (WebCore::RenderListBox::paintItemBackground):
1093 (WebCore::RenderListBox::scrollTo):
1094 (WebCore::RenderListBox::createScrollbar):
1095 * rendering/RenderListItem.cpp:
1097 (WebCore::enclosingList):
1098 (WebCore::nextListItem):
1099 (WebCore::previousListItem):
1100 (WebCore::RenderListItem::calcValue):
1101 (WebCore::RenderListItem::explicitValueChanged):
1102 (WebCore::RenderListItem::setExplicitValue):
1103 (WebCore::RenderListItem::clearExplicitValue):
1104 (WebCore::previousOrNextItem):
1105 (WebCore::RenderListItem::updateListMarkerNumbers):
1106 * rendering/RenderMarquee.cpp:
1107 (WebCore::RenderMarquee::marqueeSpeed):
1108 * rendering/RenderMedia.cpp:
1109 (WebCore::RenderMedia::mediaElement):
1110 * rendering/RenderMediaControlElements.cpp:
1111 (WebCore::RenderMediaControlTimelineContainer::layout):
1112 (WebCore::RenderTextTrackContainerElement::layout):
1113 * rendering/RenderMenuList.cpp:
1114 (WebCore::RenderMenuList::selectElement):
1115 (WebCore::RenderMenuList::valueChanged):
1116 (WebCore::RenderMenuList::createScrollbar):
1117 * rendering/RenderMeter.cpp:
1118 (WebCore::RenderMeter::meterElement):
1119 * rendering/RenderPart.cpp:
1120 (WebCore::RenderPart::requiresAcceleratedCompositing):
1121 (WebCore::RenderPart::embeddedContentBox):
1122 * rendering/RenderProgress.cpp:
1123 (WebCore::RenderProgress::progressElement):
1124 * rendering/RenderReplaced.cpp:
1125 (WebCore::RenderReplaced::positionForPoint):
1126 (WebCore::RenderReplaced::isSelected):
1127 * rendering/RenderSearchField.cpp:
1128 (WebCore::RenderSearchField::autosaveName):
1129 (WebCore::RenderSearchField::createScrollbar):
1130 * rendering/RenderSlider.cpp:
1131 (WebCore::RenderSlider::layout):
1132 (WebCore::RenderSlider::inDragMode):
1133 * rendering/RenderSnapshottedPlugIn.cpp:
1134 (WebCore::RenderSnapshottedPlugIn::plugInImageElement):
1135 * rendering/RenderTable.cpp:
1136 (WebCore::RenderTable::convertStyleLogicalWidthToComputedWidth):
1137 (WebCore::RenderTable::convertStyleLogicalHeightToComputedHeight):
1138 (WebCore::RenderTable::nodeAtPoint):
1139 * rendering/RenderTableCell.cpp:
1140 (WebCore::RenderTableCell::parseColSpanFromDOM):
1141 (WebCore::RenderTableCell::parseRowSpanFromDOM):
1142 (WebCore::RenderTableCell::updateColAndRowSpanFlags):
1143 (WebCore::RenderTableCell::colSpanOrRowSpanChanged):
1144 (WebCore::RenderTableCell::computePreferredLogicalWidths):
1145 * rendering/RenderTableCol.cpp:
1146 (WebCore::RenderTableCol::updateFromElement):
1147 * rendering/RenderTextControl.cpp:
1148 (WebCore::RenderTextControl::textFormControlElement):
1149 (WebCore::RenderTextControl::adjustInnerTextStyle):
1150 (WebCore::RenderTextControl::updateFromElement):
1151 (WebCore::RenderTextControl::layoutSpecialExcludedChild):
1152 * rendering/RenderTextControlMultiLine.cpp:
1153 (WebCore::RenderTextControlMultiLine::~RenderTextControlMultiLine):
1154 (WebCore::RenderTextControlMultiLine::nodeAtPoint):
1155 (WebCore::RenderTextControlMultiLine::preferredContentLogicalWidth):
1156 (WebCore::RenderTextControlMultiLine::computeControlLogicalHeight):
1157 * rendering/RenderTextControlSingleLine.cpp:
1158 (WebCore::RenderTextControlSingleLine::nodeAtPoint):
1159 (WebCore::RenderTextControlSingleLine::capsLockStateMayHaveChanged):
1160 (WebCore::RenderTextControlSingleLine::textShouldBeTruncated):
1161 (WebCore::RenderTextControlSingleLine::inputElement):
1162 * rendering/RenderThemeMac.mm:
1163 (WebCore::RenderThemeMac::paintSnapshottedPluginOverlay):
1164 * rendering/RenderTreeAsText.cpp:
1165 (WebCore::writeRenderRegionList):
1166 * rendering/RenderVideo.cpp:
1167 (WebCore::RenderVideo::updateIntrinsicSize):
1168 (WebCore::RenderVideo::videoElement):
1169 * rendering/RenderWidget.cpp:
1170 (WebCore::RenderWidget::setWidgetGeometry):
1171 (WebCore::RenderWidget::updateWidgetPosition):
1172 (WebCore::RenderWidget::nodeAtPoint):
1173 * rendering/mathml/RenderMathMLFenced.cpp:
1174 (WebCore::RenderMathMLFenced::updateFromElement):
1175 (WebCore::RenderMathMLFenced::createMathMLOperator):
1176 (WebCore::RenderMathMLFenced::styleDidChange):
1177 * rendering/mathml/RenderMathMLFraction.cpp:
1178 (WebCore::RenderMathMLFraction::updateFromElement):
1179 * rendering/mathml/RenderMathMLOperator.cpp:
1180 (WebCore::RenderMathMLOperator::updateFromElement):
1181 (WebCore::RenderMathMLOperator::createGlyph):
1182 * rendering/mathml/RenderMathMLSpace.cpp:
1183 (WebCore::RenderMathMLSpace::updateFromElement):
1184 * rendering/svg/RenderSVGForeignObject.cpp:
1185 (WebCore::RenderSVGForeignObject::layout):
1186 * rendering/svg/RenderSVGRoot.cpp:
1187 (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation):
1188 (WebCore::RenderSVGRoot::isEmbeddedThroughSVGImage):
1189 (WebCore::RenderSVGRoot::isEmbeddedThroughFrameContainingSVGDocument):
1190 (WebCore::RenderSVGRoot::computeReplacedLogicalWidth):
1191 (WebCore::RenderSVGRoot::computeReplacedLogicalHeight):
1192 (WebCore::RenderSVGRoot::layout):
1193 (WebCore::RenderSVGRoot::paintReplaced):
1194 (WebCore::RenderSVGRoot::buildLocalToBorderBoxTransform):
1195 (WebCore::RenderSVGRoot::nodeAtPoint):
1196 (WebCore::RenderSVGRoot::hasRelativeDimensions):
1197 (WebCore::RenderSVGRoot::hasRelativeIntrinsicLogicalWidth):
1198 (WebCore::RenderSVGRoot::hasRelativeLogicalHeight):
1199 * rendering/svg/RenderSVGText.cpp:
1200 (WebCore::RenderSVGText::layout):
1201 (WebCore::RenderSVGText::strokeBoundingBox):
1202 * rendering/svg/RenderSVGTextPath.cpp:
1203 (WebCore::RenderSVGTextPath::layoutPath):
1204 (WebCore::RenderSVGTextPath::startOffset):
1205 (WebCore::RenderSVGTextPath::exactAlignment):
1206 (WebCore::RenderSVGTextPath::stretchMethod):
1208 2013-09-09 Antti Koivisto <antti@apple.com>
1210 Make RenderView anonymous
1211 https://bugs.webkit.org/show_bug.cgi?id=121013
1213 Reviewed by Darin Adler and Dave Hyatt.
1215 RenderView is currently the only renderer that has an associated Node that is not either Element or Text.
1216 By making it anonymous (not have associated node, RenderView::node() returns null) we will be able to
1217 significantly tighten typing in both render and DOM trees.
1219 * accessibility/AccessibilityRenderObject.cpp:
1220 (WebCore::AccessibilityRenderObject::node):
1222 We need to grab document() instead of node() in a few places for RenderViews to keep existing code
1223 behaving like it did.
1225 * inspector/InspectorLayerTreeAgent.cpp:
1226 (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
1228 Don't tell inspector that the root layer is anonymous for now to avoid changing behavior.
1230 * rendering/RenderBlock.cpp:
1231 (WebCore::RenderBlock::nodeForHitTest):
1232 * rendering/RenderBox.cpp:
1233 (WebCore::RenderBox::canBeProgramaticallyScrolled):
1235 The old non-virtual RenderView test renderer->node == &renderer->document() does not work anymore.
1236 Switch to isRenderView() which is now non-virtual in a number of places.
1238 (WebCore::RenderBox::canAutoscroll):
1239 (WebCore::RenderBox::findAutoscrollable):
1240 (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
1241 * rendering/RenderBoxModelObject.cpp:
1242 (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight):
1243 * rendering/RenderLayerBacking.cpp:
1244 (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
1245 * rendering/RenderObject.h:
1246 (WebCore::RenderObject::isRenderReplaced):
1247 (WebCore::RenderObject::isAnonymousBlock):
1249 RenderView is anonymous but not a CSS anonymous block.
1251 (WebCore::RenderObject::isText):
1252 (WebCore::RenderObject::isRenderView):
1254 Make isRenderView non-virtual since it is now hot. Reuse existing bits.
1256 (WebCore::RenderObject::setIsText):
1257 (WebCore::RenderObject::setIsRenderView):
1258 (WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
1259 * rendering/RenderTreeAsText.cpp:
1260 (WebCore::writeSelection):
1261 * rendering/RenderView.cpp:
1265 (WebCore::RenderView::RenderView):
1266 * rendering/RenderView.h:
1267 * rendering/svg/RenderSVGRoot.cpp:
1268 (WebCore::RenderSVGRoot::computeReplacedLogicalHeight):
1270 2013-09-09 Bem Jones-Bey <bjonesbe@adobe.com>
1272 Move logical(Left|Right)FloatOffsetForLine methods into FloatingObjects
1273 https://bugs.webkit.org/show_bug.cgi?id=120705
1275 Reviewed by Sam Weinig.
1277 These are the only consumers of the CalculateFloatOffsetAdapter and
1278 the placed floats tree, so it will allow us to reduce the public
1279 interface of FloatingObjects and make the placed floats tree private.
1281 No new tests, no behavior change.
1283 * rendering/RenderBlock.cpp:
1284 (WebCore::RenderBlock::logicalLeftFloatOffsetForLine):
1285 (WebCore::RenderBlock::logicalRightFloatOffsetForLine):
1286 (WebCore::RenderBlock::FloatingObjects::logicalLeftOffset):
1287 (WebCore::RenderBlock::FloatingObjects::logicalRightOffset):
1288 * rendering/RenderBlock.h:
1289 (WebCore::RenderBlock::FloatingObjects::placedFloatsTree):
1291 2013-09-09 Christophe Dumez <ch.dumez@sisa.samsung.com>
1293 Add support for BeforeUnloadEvent interface
1294 https://bugs.webkit.org/show_bug.cgi?id=120849
1296 Reviewed by Darin Adler.
1298 Add support for BeforeUnloadEvent as per the specification:
1299 http://www.whatwg.org/specs/web-apps/current-work/#beforeunloadevent
1301 BeforeUnloadEvent has a returnValue attribute. Setting returnValue to a non-empty
1302 string in an event handler causes the user agent should ask the user to confirm
1303 that they wish to unload the document. This is equivalent to returning a non-empty
1304 string in the EventHandler:
1305 http://www.whatwg.org/specs/web-apps/current-work/#onbeforeunloadeventhandler
1307 BeforeUnloadEvent and returnValue are already supported by IE and Firefox. Previously,
1308 WebKit was passing a base Event type to the beforeunload event handlers instead of
1309 a BeforeUnloadEvent.
1311 Note that this patch keeps support for the legacy Event.returnValue attribute. This used
1312 to be an IE extension but this is no longer supported by IE (nor Firefox). The standard
1313 preventDefault() should be used instead however (supported in IE >= 9).
1315 Test: fast/events/before-unload-returnValue.html
1318 * DerivedSources.cpp:
1319 * DerivedSources.make:
1320 * DerivedSources.pri:
1321 * GNUmakefile.list.am:
1323 * WebCore.vcxproj/WebCore.vcxproj:
1324 * bindings/js/JSEventListener.cpp:
1325 (WebCore::JSEventListener::handleEvent):
1326 * dom/BeforeUnloadEvent.cpp:
1327 (WebCore::BeforeUnloadEvent::isBeforeUnloadEvent):
1328 (WebCore::BeforeUnloadEvent::~BeforeUnloadEvent):
1329 * dom/BeforeUnloadEvent.h:
1330 (WebCore::BeforeUnloadEvent::create):
1331 (WebCore::BeforeUnloadEvent::returnValue):
1332 (WebCore::BeforeUnloadEvent::setReturnValue):
1333 (WebCore::toBeforeUnloadEvent):
1334 * dom/BeforeUnloadEvent.idl: Added.
1336 (WebCore::Event::isBeforeUnloadEvent):
1338 (WebCore::Event::legacyReturnValue):
1339 (WebCore::Event::setLegacyReturnValue):
1341 * dom/EventNames.in:
1342 * loader/FrameLoader.cpp:
1343 (WebCore::FrameLoader::handleBeforeUnloadEvent):
1345 2013-09-06 David Hyatt <hyatt@apple.com>
1347 Get rid of isBlockFlowFlexBoxOrGrid().
1348 https://bugs.webkit.org/show_bug.cgi?id=120897
1350 Convert all callers and get rid of this method.
1352 Reviewed by Beth Dakin.
1354 * accessibility/AccessibilityRenderObject.cpp:
1355 (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
1356 (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
1358 (WebCore::Position::isCandidate):
1359 (WebCore::Position::getInlineBoxAndOffset):
1360 (WebCore::Position::primaryDirection):
1361 * dom/PositionIterator.cpp:
1362 (WebCore::PositionIterator::isCandidate):
1363 * editing/CompositeEditCommand.cpp:
1364 (WebCore::CompositeEditCommand::addBlockPlaceholderIfNeeded):
1365 * editing/Editor.cpp:
1366 (WebCore::Editor::baseWritingDirectionForSelectionStart):
1367 * editing/FrameSelection.cpp:
1368 (WebCore::caretRenderer):
1369 * editing/TextIterator.cpp:
1370 (WebCore::TextIterator::shouldRepresentNodeOffsetZero):
1371 * editing/TypingCommand.cpp:
1372 (WebCore::TypingCommand::makeEditableRootEmpty):
1373 * editing/htmlediting.cpp:
1374 (WebCore::isBlockFlowElement):
1375 * rendering/LayoutState.cpp:
1376 (WebCore::LayoutState::LayoutState):
1377 * rendering/RenderBlock.cpp:
1378 (WebCore::RenderBlock::layoutBlock):
1379 (WebCore::RenderBlock::collapseMargins):
1380 (WebCore::RenderBlock::selectionGaps):
1381 (WebCore::RenderBlock::firstLineBoxBaseline):
1382 (WebCore::RenderBlock::lastLineBoxBaseline):
1383 (WebCore::RenderBlock::firstLineBlock):
1384 (WebCore::findFirstLetterBlock):
1385 (WebCore::shouldCheckLines):
1386 (WebCore::RenderBlock::adjustForBorderFit):
1387 * rendering/RenderBox.cpp:
1388 (WebCore::RenderBox::computeRectForRepaint):
1389 (WebCore::RenderBox::positionForPoint):
1390 * rendering/RenderBoxModelObject.h:
1391 (WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion):
1392 * rendering/RenderInline.cpp:
1393 (WebCore::RenderInline::computeRectForRepaint):
1394 * rendering/RenderLineBoxList.cpp:
1395 (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
1396 * rendering/RenderObject.cpp:
1397 (WebCore::RenderObject::computeRectForRepaint):
1398 (WebCore::RenderObject::styleWillChange):
1399 (WebCore::firstLineStyleForCachedUncachedType):
1400 * rendering/RenderObject.h:
1401 * rendering/RenderObjectChildList.cpp:
1402 (WebCore::RenderObjectChildList::insertChildNode):
1403 * rendering/RenderView.h:
1405 2013-09-09 Eric Carlson <eric.carlson@apple.com>
1407 MediaStream API: Stop means stop
1408 https://bugs.webkit.org/show_bug.cgi?id=120873
1410 Reviewed by Jer Noble.
1412 Merge blink https://chromium.googlesource.com/chromium/blink/+/9a97b0f3892320fa5741485e06a78183b77c3635
1413 by Tommy Widenflycht.
1415 Removing notification functionality from MediaStreamTrack::stop because the world is being torn down.
1417 No new tests, the original author was unable to come up with a reliable test case.
1419 * Modules/mediastream/MediaStreamTrack.cpp:
1420 (WebCore::MediaStreamTrack::stop): Don't call didEndTrack, the world is going away.
1422 2013-09-09 Filip Pizlo <fpizlo@apple.com>
1424 Unreviewed, fix build.
1426 * Modules/encryptedmedia/MediaKeySession.h:
1428 2013-09-09 Eric Carlson <eric.carlson@apple.com>
1430 MediaStream API: Moving Add/Remove track from WebMediaStreamCenterClient to WebMediaStream
1431 https://bugs.webkit.org/show_bug.cgi?id=120872
1433 Reviewed by Jer Noble.
1435 Merge https://chromium.googlesource.com/chromium/blink/+/7d740fd27c1f345b59c846df01c3adce53c18e6e
1436 Simple cleanup that makes the API cleaner.
1438 * Modules/mediastream/MediaStream.cpp:
1439 (WebCore::MediaStream::removeTrack):
1440 (WebCore::MediaStream::addRemoteTrack):
1441 (WebCore::MediaStream::removeRemoteTrack):
1442 * platform/mediastream/MediaStreamCenter.cpp:
1443 * platform/mediastream/MediaStreamCenter.h:
1444 * platform/mediastream/MediaStreamDescriptor.h:
1445 (WebCore::MediaStreamDescriptor::removeAudioComponent):
1446 (WebCore::MediaStreamDescriptor::addRemoteTrack):
1447 (WebCore::MediaStreamDescriptor::removeRemoteTrack):
1449 2013-09-09 ChangSeok Oh <changseok.oh@collabora.com>
1451 [WK2] Assertion failure in WebCore::Page::checkSubframeCountConsistency when going back
1452 https://bugs.webkit.org/show_bug.cgi?id=119781
1454 Reviewed by Alexey Proskuryakov.
1456 We should pair restoring a cached frame and adding it to FrameTree so that
1457 actual added frame count in FrameTree keeps same with restored frame count.
1458 Otherwise assert failure occurs in Page::CheckSubframeCountConsistency.
1459 We have added cached frames to FrameTree ahead and then restored them by tree travelsal.
1460 But this way doesn't guarantee subframecount of Page and the number of child of FrameTree are equal.
1461 In addition, we still make sure that adding a cached frame to FrameTree should happen
1462 before opening it. Because FrameTree might be used while restoring a cached page.
1464 Test: fast/history/go-back-to-iframe-with-plugin.html
1466 * history/CachedFrame.cpp:
1467 (WebCore::CachedFrameBase::restore):
1468 (WebCore::CachedFrame::open):
1470 2013-09-09 Luciano Wolf <luciano.wolf@openbossa.org>
1472 Nix upstreaming - Adding stubs and Nix specific platform files
1473 https://bugs.webkit.org/show_bug.cgi?id=118358
1475 Reviewed by Benjamin Poulain.
1477 Basically adding all files that have "Nix" in their names and
1478 are related to WebCore module.
1480 No new tests. They will be uploaded on another patch during the
1481 upstreaming process.
1483 * css/mediaControlsNix.css: Added.
1484 * css/mediaControlsNixFullscreen.css: Added.
1485 * page/nix/EventHandlerNix.cpp: Added.
1486 * platform/graphics/egl/GLContextFromCurrentEGL.cpp: Added.
1487 * platform/graphics/egl/GLContextFromCurrentEGL.h: Added.
1488 * platform/graphics/gstreamer/PlatformVideoWindowNix.cpp: Added.
1489 * platform/graphics/nix/IconNix.cpp: Added.
1490 * platform/graphics/nix/ImageNix.cpp: Added.
1491 * platform/nix/CursorNix.cpp: Added.
1492 * platform/nix/DragDataNix.cpp: Added.
1493 * platform/nix/DragImageNix.cpp: Added.
1494 * platform/nix/GamepadsNix.cpp: Added.
1495 * platform/nix/LanguageNix.cpp: Added.
1496 * platform/nix/LocalizedStringsNix.cpp: Added.
1497 * platform/nix/NixKeyboardUtilities.cpp: Added.
1498 * platform/nix/NixKeyboardUtilities.h: Added.
1499 * platform/nix/PasteboardNix.cpp: Added.
1500 * platform/nix/PlatformKeyboardEventNix.cpp: Added.
1501 * platform/nix/PlatformScreenNix.cpp: Added.
1502 * platform/nix/SoundNix.cpp: Added.
1503 * platform/nix/WidgetNix.cpp: Added.
1504 * platform/text/nix/TextBreakIteratorInternalICUNix.cpp: Added.
1506 2013-09-09 Hugo Parente Lima <hugo.lima@openbossa.org>
1508 Preparing WebCore to receive Nix Port
1509 https://bugs.webkit.org/show_bug.cgi?id=118326
1511 Reviewed by Eric Carlson.
1513 Only adding the compilation directives that are Nix specific, in the
1514 existent WebCore files
1516 * loader/FrameLoader.cpp:
1517 (WebCore::FrameLoader::defaultObjectContentType):
1518 * platform/Cursor.h:
1519 * platform/DragData.h:
1520 * platform/DragImage.h:
1521 * platform/FileSystem.h:
1522 * platform/RunLoop.h:
1523 * platform/Widget.h:
1524 * platform/audio/FFTFrame.h:
1525 * platform/audio/HRTFElevation.cpp:
1526 * platform/cairo/WidgetBackingStore.h:
1527 * platform/graphics/ANGLEWebKitBridge.h:
1528 * platform/graphics/FontPlatformData.h:
1529 * platform/graphics/GraphicsContext3D.cpp:
1530 * platform/graphics/GraphicsContext3D.h:
1531 * platform/graphics/OpenGLESShims.h:
1532 * platform/graphics/OpenGLShims.cpp:
1533 (WebCore::getProcAddress):
1534 * platform/graphics/OpenGLShims.h:
1535 * platform/graphics/PlatformLayer.h:
1536 * platform/graphics/cairo/GLContext.cpp:
1537 (WebCore::GLContext::createContextForWindow):
1538 * platform/graphics/cairo/GraphicsContext3DPrivate.cpp:
1539 (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
1540 * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
1541 * platform/graphics/opengl/Extensions3DOpenGL.cpp:
1542 (WebCore::Extensions3DOpenGL::createVertexArrayOES):
1543 (WebCore::Extensions3DOpenGL::deleteVertexArrayOES):
1544 (WebCore::Extensions3DOpenGL::isVertexArrayOES):
1545 (WebCore::Extensions3DOpenGL::bindVertexArrayOES):
1546 (WebCore::Extensions3DOpenGL::supportsExtension):
1547 * platform/graphics/opengl/Extensions3DOpenGL.h:
1548 * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
1549 * platform/graphics/opengl/Extensions3DOpenGLES.h:
1550 * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
1551 * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
1552 (WebCore::GraphicsContext3D::reshape):
1553 * platform/graphics/texmap/TextureMapper.h:
1554 * plugins/PluginPackage.cpp:
1555 * plugins/PluginView.cpp:
1556 (WebCore::PluginView::PluginView):
1557 * plugins/PluginView.h:
1558 * plugins/PluginViewNone.cpp:
1560 2013-09-08 Darin Adler <darin@apple.com>
1562 Tighten up EventQueue classes a bit, less indirection and memory allocation
1563 https://bugs.webkit.org/show_bug.cgi?id=121016
1565 Reviewed by Andreas Kling.
1567 * Modules/encryptedmedia/MediaKeySession.cpp:
1568 (WebCore::MediaKeySession::MediaKeySession): Updated since event queue is now
1569 a member rather than an OwnPtr.
1570 (WebCore::MediaKeySession::close): Ditto.
1571 (WebCore::MediaKeySession::keyRequestTimerFired): Ditto.
1572 (WebCore::MediaKeySession::addKeyTimerFired): Ditto.
1573 * Modules/encryptedmedia/MediaKeySession.h: Ditto.
1575 * Modules/indexeddb/IDBDatabase.cpp:
1576 (WebCore::IDBDatabase::closeConnection): Updated since ScriptExecutionContext's
1577 eventQueue function now returns a reference rather than a pointer. Also, the
1578 cancelEvent function takes a reference instead of a pointer.
1579 (WebCore::IDBDatabase::enqueueEvent): Ditto.
1580 * Modules/indexeddb/IDBRequest.cpp:
1581 (WebCore::IDBRequest::abort): Ditto.
1582 (WebCore::IDBRequest::enqueueEvent): Ditto.
1583 * Modules/indexeddb/IDBTransaction.cpp:
1584 (WebCore::IDBTransaction::enqueueEvent): Ditto.
1586 * Modules/mediasource/MediaSource.cpp:
1587 (WebCore::MediaSource::MediaSource): Updated since event queue is now a
1588 member rather than an OwnPtr. Also use initialization instead of assignment
1589 to set up source buffers.
1590 (WebCore::MediaSource::hasPendingActivity): Ditto.
1591 (WebCore::MediaSource::stop): Ditto.
1592 (WebCore::MediaSource::scheduleEvent): Ditto.
1593 * Modules/mediasource/MediaSource.h: Ditto.
1595 * Modules/mediasource/SourceBufferList.cpp:
1596 (WebCore::SourceBufferList::SourceBufferList): Take references instead of
1598 (WebCore::SourceBufferList::length): Changed type to unsigned instead of
1599 unsigned long. This is an IDL "unsigned long", which corresponds to "unsigned"
1600 in our C++ DOM implementation.
1601 (WebCore::SourceBufferList::createAndFireEvent): Updated since event queue is
1603 (WebCore::SourceBufferList::scriptExecutionContext): Updated since script
1604 execution context is now a reference.
1605 * Modules/mediasource/SourceBufferList.h: Ditto.
1608 (WebCore::Document::Document): Updated since event queue is now a member rather
1610 (WebCore::Document::detach): Ditto.
1611 (WebCore::Document::enqueueWindowEvent): Ditto.
1612 (WebCore::Document::enqueueDocumentEvent): Ditto.
1613 * dom/Document.h: Ditto.
1615 * dom/DocumentEventQueue.cpp: Renamed DocumentEventQueueTimer to just Timer and
1616 made it a class member of DocumentEventQueue. Also changed it to use references
1617 instead of pointers and removed unneeded ScriptExecutionContext argument.
1618 (WebCore::DocumentEventQueue::DocumentEventQueue): Updated to take a document
1619 reference instead of a script execution context pointer.
1620 (WebCore::DocumentEventQueue::enqueueEvent): Wrote the assertions in a clearer
1621 style and do the assertions even when the queue is closed.
1622 (WebCore::DocumentEventQueue::enqueueOrDispatchScrollEvent): Removed the unneeded
1623 ScrollEventTargetType argument, since the policy is specific to the document node.
1624 Made the argument a reference instead of a PassRefPtr, and rewrote the function
1625 to be more straightforward and readable.
1626 (WebCore::DocumentEventQueue::cancelEvent): Use the return value recently added to
1627 the remove function to avoid the need for use of iterators and a find/remove pair.
1628 (WebCore::DocumentEventQueue::pendingEventTimerFired): Rewrote this to use the
1629 recently added ListHashSet takeFirst function. Also protect the document instead
1630 of protecting just this object during the dispatch. Can't really protect the
1631 event queue since it's no longer separately reference counted.
1632 (WebCore::DocumentEventQueue::dispatchEvent): Changed this to take a reference and
1633 added a FIXME about some curious code in here that needs a "why" comment.
1634 * dom/DocumentEventQueue.h: Removed many unneeded includes, some unneeded forward
1635 declarations, marked the class final, made it no longer derive from RefCounted,
1636 removed ScrollEventTargetType and create, and did the other changes mentioned above.
1638 * dom/EventQueue.h: Got rid of many uneeded includes, changed the argument type
1639 of cancelEvent to Event& and rewrote the comment for close.
1641 * dom/GenericEventQueue.cpp:
1642 (WebCore::GenericEventQueue::GenericEventQueue): Updated to take a reference.
1643 (WebCore::GenericEventQueue::enqueueEvent): Ditto.
1644 (WebCore::GenericEventQueue::timerFired): Ditto.
1645 * dom/GenericEventQueue.h: Changed this class to no longer derive from EventQueue
1646 since there was no value coming from that polymorphism. Removed all the virtual
1647 keywords from the class. Switched from pointers to references. Removed the unused
1648 cancelEvent function. Removed the create function since this is always used as a
1649 data member, not a pointer on the heap.
1651 * dom/ScriptExecutionContext.h: Changed the return type of eventQueue to a reference.
1653 * html/HTMLMediaElement.cpp:
1654 (WebCore::HTMLMediaElement::HTMLMediaElement): Updated since event queue is now a
1655 member rather than an OwnPtr.
1656 (WebCore::HTMLMediaElement::~HTMLMediaElement): Ditto.
1657 (WebCore::HTMLMediaElement::scheduleEvent): Ditto.
1658 (WebCore::HTMLMediaElement::updateActiveTextTrackCues): Ditto.
1659 (WebCore::HTMLMediaElement::cancelPendingEventsAndCallbacks): Ditto.
1660 (WebCore::HTMLMediaElement::mediaPlayerKeyAdded): Ditto.
1661 (WebCore::HTMLMediaElement::mediaPlayerKeyError): Ditto.
1662 (WebCore::HTMLMediaElement::mediaPlayerKeyMessage): Ditto.
1663 (WebCore::HTMLMediaElement::mediaPlayerKeyNeeded): Ditto.
1664 (WebCore::HTMLMediaElement::stop): Ditto.
1665 (WebCore::HTMLMediaElement::hasPendingActivity): Ditto.
1666 * html/HTMLMediaElement.h: Ditto.
1668 * page/EventHandler.cpp:
1669 (WebCore::EventHandler::sendScrollEvent): Updated to remove the now-uneeded
1670 ScrollEventTargetType argument, and also to use references instead of pointers.
1671 * rendering/RenderLayer.cpp:
1672 (WebCore::RenderLayer::scrollTo): Ditto.
1673 * rendering/RenderListBox.cpp:
1674 (WebCore::RenderListBox::scrollTo): Ditto.
1676 * workers/WorkerEventQueue.cpp:
1677 (WebCore::WorkerEventQueue::WorkerEventQueue): Updated to work with references
1678 instead of pointers.
1679 (WebCore::WorkerEventQueue::enqueueEvent): Ditto.
1680 (WebCore::WorkerEventQueue::cancelEvent): Use the take function instead of a
1681 get/remove pair, to eliminate double hashing.
1682 * workers/WorkerEventQueue.h: Removed unneeded includes, forward declarations,
1683 the create function, and the private removeEvent function. Marked class final.
1685 * workers/WorkerGlobalScope.cpp:
1686 (WebCore::WorkerGlobalScope::WorkerGlobalScope): Updated since eventQueue is
1688 (WebCore::WorkerGlobalScope::eventQueue): Ditto.
1689 * workers/WorkerGlobalScope.h: Made m_eventQueue a queue instead of a pointer
1690 to a queue. Also made the eventQueue function private and final.
1692 2013-09-09 Hans Muller <hmuller@adobe.com>
1694 [CSS Shapes] Heap-buffer-overflow in WebCore::ShapeInterval<float>::subtractShapeIntervals
1695 https://bugs.webkit.org/show_bug.cgi?id=120802
1697 Reviewed by Darin Adler.
1699 Revised the implementation of subtractShapeIntervals() to isloate and check the
1700 places where it dereferences ShapeInterval vector iterators.
1702 Test: fast/shapes/shape-inside/shape-inside-subtract-intervals-crash.html
1704 * rendering/shapes/ShapeInterval.h:
1705 (WebCore::ShapeInterval::subtractShapeIntervals):
1707 2013-09-09 Darin Adler <darin@apple.com>
1709 matchingShorthandsForLonghand builds map using a giant function
1710 https://bugs.webkit.org/show_bug.cgi?id=121029
1712 Reviewed by Anders Carlsson.
1714 There is no need to use a map for this; a switch statement is fine.
1715 Also, these structures are simple enough that we can build them
1716 every time; we don't need to keep them in globals.
1718 * css/CSSParser.cpp:
1719 (WebCore::CSSParser::addProperty): Got rid of non-helpful local in
1720 CSS_VARIABLES code. Updated for change in return value of the
1721 matchingShorthandsForLonghand.
1722 (WebCore::CSSParser::parseShorthand): Updated for change in return
1723 type of propertiesForInitialization.
1725 * css/CSSProperty.cpp:
1726 (WebCore::StylePropertyMetadata::shorthandID): Updated for change in
1727 return value of matchingShorthandsForLonghand.
1729 * css/StylePropertyShorthand.cpp:
1730 (WebCore::backgroundShorthand): Got rid of local variable, constructing
1731 the StylePropertyShorthand every time.
1732 (WebCore::backgroundPositionShorthand): Ditto.
1733 (WebCore::backgroundRepeatShorthand): Ditto.
1734 (WebCore::borderShorthand): Ditto.
1735 (WebCore::borderAbridgedShorthand): Ditto.
1736 (WebCore::borderBottomShorthand): Ditto.
1737 (WebCore::borderColorShorthand): Ditto.
1738 (WebCore::borderImageShorthand): Ditto.
1739 (WebCore::borderLeftShorthand): Ditto.
1740 (WebCore::borderRadiusShorthand): Ditto.
1741 (WebCore::webkitBorderRadiusShorthand): Ditto.
1742 (WebCore::borderRightShorthand): Ditto.
1743 (WebCore::borderSpacingShorthand): Ditto.
1744 (WebCore::borderStyleShorthand): Ditto.
1745 (WebCore::borderTopShorthand): Ditto.
1746 (WebCore::borderWidthShorthand): Ditto.
1747 (WebCore::listStyleShorthand): Ditto.
1748 (WebCore::fontShorthand): Ditto.
1749 (WebCore::marginShorthand): Ditto. Ditto.
1750 (WebCore::markerShorthand): Ditto.
1751 (WebCore::outlineShorthand): Ditto.
1752 (WebCore::overflowShorthand): Ditto.
1753 (WebCore::paddingShorthand): Ditto.
1754 (WebCore::transitionShorthand): Ditto.
1755 (WebCore::webkitAnimationShorthand): Ditto.
1756 (WebCore::webkitAnimationShorthandForParsing): Ditto.
1757 (WebCore::webkitBorderAfterShorthand): Ditto.
1758 (WebCore::webkitBorderBeforeShorthand): Ditto.
1759 (WebCore::webkitBorderEndShorthand): Ditto.
1760 (WebCore::webkitBorderStartShorthand): Ditto.
1761 (WebCore::webkitColumnsShorthand): Ditto.
1762 (WebCore::webkitColumnRuleShorthand): Ditto.
1763 (WebCore::webkitFlexFlowShorthand): Ditto.
1764 (WebCore::webkitFlexShorthand): Ditto.
1765 (WebCore::webkitMarginCollapseShorthand): Ditto.
1766 (WebCore::webkitGridColumnShorthand): Ditto.
1767 (WebCore::webkitGridRowShorthand): Ditto.
1768 (WebCore::webkitMarqueeShorthand): Ditto.
1769 (WebCore::webkitMaskShorthand): Ditto.
1770 (WebCore::webkitMaskPositionShorthand): Ditto.
1771 (WebCore::webkitMaskRepeatShorthand): Ditto.
1772 (WebCore::webkitTextDecorationShorthand): Ditto.
1773 (WebCore::webkitTextEmphasisShorthand): Ditto.
1774 (WebCore::webkitTextStrokeShorthand): Ditto.
1775 (WebCore::webkitTransitionShorthand): Ditto.
1776 (WebCore::webkitTransformOriginShorthand): Ditto.
1777 (WebCore::widthShorthand): Ditto.
1778 (WebCore::heightShorthand): Ditto.
1779 (WebCore::shorthandForProperty): Ditto.
1780 (WebCore::makeVector): Added. Helper function for the cases in the
1781 switch inside matchingShorthandsForLonghand.
1782 (WebCore::matchingShorthandsForLonghand): Rewrote this to use a switch
1784 (WebCore::indexOfShorthandForLonghand): Tightened up the coding style a bit.
1786 * css/StylePropertyShorthand.h: Changed type of StylePropertyShorthand's
1787 propertiesForInitialization to be an array of shorthands rather than an
1788 array of pointers to shorthands. Changed return types of the shorthand
1789 functions to return a shorthand object rather than a reference. Did the same
1790 for the other functions.
1792 2013-09-09 Allan Sandfeld Jensen <allan.jensen@digia.com>
1794 MouseEnter and MouseLeave may be emitted on Document nodes
1795 https://bugs.webkit.org/show_bug.cgi?id=120862
1797 Reviewed by Antonio Gomes.
1799 Replace the overgeneric use of Nodes with Elements in updateHoverActiveState.
1800 This also fixes the bug of emitting mouseenter/mouseleave events on Document,
1801 since Document is not an Element.
1803 This is tested by fast/events/mouseenterleave-on-subframe.html
1806 (WebCore::Document::updateHoverActiveState):
1808 2013-09-09 Allan Sandfeld Jensen <allan.jensen@digia.com>
1810 MouseLeave not always emitted when cursor leaves subframe
1811 https://bugs.webkit.org/show_bug.cgi?id=121026
1813 Reviewed by Antonio Gomes.
1815 Forward the PlatformMouseEvent in the recursive calls so nested documents
1816 also get a chance to emit mouseleave when the hover moves out.
1818 Test: fast/events/mouseenterleave-on-subframe.html
1821 (WebCore::Document::updateHoverActiveState):
1823 2013-09-09 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
1825 Adding username to RTCIceServer
1826 https://bugs.webkit.org/show_bug.cgi?id=120861
1828 Reviewed by Eric Carlson.
1830 No new tests needed. Existing media stream tests already cover it
1832 * Modules/mediastream/RTCPeerConnection.cpp:
1833 (WebCore::RTCPeerConnection::parseConfiguration):
1834 * platform/mediastream/RTCConfiguration.h:
1835 (WebCore::RTCIceServer::create):
1836 (WebCore::RTCIceServer::username):
1837 (WebCore::RTCIceServer::RTCIceServer):
1839 2013-09-09 Antti Koivisto <antti@apple.com>
1841 Hide Document::renderer()
1842 https://bugs.webkit.org/show_bug.cgi?id=121028
1844 Reviewed by Andreas Kling.
1846 Use less generic Document::renderView() instead.
1848 * accessibility/AXObjectCache.cpp:
1849 (WebCore::AXObjectCache::postNotification):
1850 * accessibility/AccessibilityObject.cpp:
1851 (WebCore::appendAccessibilityObject):
1852 * accessibility/AccessibilityScrollView.cpp:
1853 (WebCore::AccessibilityScrollView::webAreaObject):
1854 * css/CSSFontSelector.cpp:
1855 (WebCore::CSSFontSelector::dispatchInvalidationCallbacks):
1856 * css/StyleResolver.cpp:
1857 (WebCore::StyleResolver::appendAuthorStyleSheets):
1859 (WebCore::Document::~Document):
1860 (WebCore::Document::webkitGetNamedFlows):
1861 (WebCore::Document::setVisualUpdatesAllowed):
1862 (WebCore::Document::elementFromPoint):
1863 (WebCore::Document::caretRangeFromPoint):
1864 (WebCore::Document::updateLayout):
1865 (WebCore::Document::existingAXObjectCache):
1866 (WebCore::Document::axObjectCache):
1867 (WebCore::Document::setVisuallyOrdered):
1868 (WebCore::Document::implicitClose):
1869 (WebCore::Document::prepareMouseEvent):
1870 (WebCore::Document::styleResolverChanged):
1871 (WebCore::Document::documentWillBecomeInactive):
1872 (WebCore::Document::documentDidResumeFromPageCache):
1874 * dom/DocumentStyleSheetCollection.cpp:
1875 (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
1877 (WebCore::Element::~Element):
1878 * dom/InlineStyleSheetOwner.cpp:
1879 (WebCore::InlineStyleSheetOwner::removedFromDocument):
1880 * dom/ProcessingInstruction.cpp:
1881 (WebCore::ProcessingInstruction::removedFrom):
1882 * editing/FrameSelection.cpp:
1883 (WebCore::FrameSelection::contains):
1884 * html/HTMLElement.cpp:
1885 (WebCore::HTMLElement::adjustDirectionalityIfNeededAfterChildrenChanged):
1886 * html/HTMLLinkElement.cpp:
1887 (WebCore::HTMLLinkElement::removedFrom):
1888 * html/HTMLStyleElement.cpp:
1889 (WebCore::HTMLStyleElement::parseAttribute):
1890 (WebCore::HTMLStyleElement::registerWithScopingNode):
1891 (WebCore::HTMLStyleElement::unregisterWithScopingNode):
1892 * html/parser/HTMLResourcePreloader.cpp:
1893 (WebCore::HTMLResourcePreloader::preload):
1894 * loader/ImageLoader.cpp:
1895 (WebCore::ImageLoader::updateFromElement):
1896 * page/EventHandler.cpp:
1897 (WebCore::EventHandler::handleWheelEvent):
1898 (WebCore::EventHandler::handleGestureScrollBegin):
1900 (WebCore::Frame::setPageAndTextZoomFactors):
1901 * page/FrameView.cpp:
1902 (WebCore::FrameView::layout):
1903 (WebCore::FrameView::doLayoutWithFrameFlattening):
1905 (WebCore::Page::setPageScaleFactor):
1906 * page/PrintContext.cpp:
1907 (WebCore::PrintContext::spoolAllPagesWithBoundaries):
1908 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1909 (WebCore::MediaPlayerPrivateQTKit::paint):
1910 * style/StyleResolveTree.cpp:
1911 (WebCore::Style::resolveTree):
1912 * svg/SVGDocument.cpp:
1913 (WebCore::SVGDocument::updatePan):
1915 2013-09-09 Christophe Dumez <ch.dumez@sisa.samsung.com>
1917 [DOM4] Have ProcessingInstruction inherit CharacterData
1918 https://bugs.webkit.org/show_bug.cgi?id=120691
1920 Reviewed by Darin Adler.
1922 Have ProcessingInstruction inherit CharacterData as per the latest DOM4
1924 http://dom.spec.whatwg.org/#processinginstruction
1926 Previously, ProcessingInstruction was inheriting from Node as per DOM
1929 Firefox and Blink already follow DOM4 here but not IE10.
1930 This change leads to less code duplication.
1932 Test: fast/dom/processing-instruction-inherit-characterdata.xhtml
1934 * bindings/objc/PublicDOMInterfaces.h:
1935 * dom/CharacterData.cpp:
1936 (WebCore::CharacterData::setDataAndUpdate):
1937 * dom/ProcessingInstruction.cpp:
1938 (WebCore::ProcessingInstruction::ProcessingInstruction):
1939 (WebCore::ProcessingInstruction::cloneNode):
1940 (WebCore::ProcessingInstruction::checkStyleSheet):
1941 (WebCore::ProcessingInstruction::insertedInto):
1942 (WebCore::ProcessingInstruction::removedFrom):
1943 (WebCore::ProcessingInstruction::finishParsingChildren):
1944 * dom/ProcessingInstruction.h:
1945 (WebCore::toProcessingInstruction):
1946 * dom/ProcessingInstruction.idl:
1948 2013-09-09 Krzysztof Czech <k.czech@samsung.com>
1950 [AX][ATK] AccessibilityObject representing ProgressBar element should be ATK_VALUE type
1951 https://bugs.webkit.org/show_bug.cgi?id=121023
1953 Reviewed by Mario Sanchez Prada.
1955 Test: accessibility/progressbar.html
1957 ProgressBar element should support ATK_VALUE interface.
1959 * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
1960 (getInterfaceMaskFromObject):
1962 2013-09-09 Claudio Saavedra <csaavedra@igalia.com>
1964 [GTK] ghost cursor when mouse hovers over an image file in a tab
1965 https://bugs.webkit.org/show_bug.cgi?id=120675
1967 Reviewed by Carlos Garcia Campos.
1969 No new tests, covered by existing.
1971 * platform/gtk/CursorGtk.cpp:
1972 (WebCore::createNamedCursor): Use new gdk_cursor_new_from_surface()
1973 when compiling against GTK+ 3.9.12 or newer.
1975 2013-09-08 Santosh Mahto <santosh.ma@samsung.com>
1977 HTMLDocument.h : Removing unnecessary forward declaration.
1978 https://bugs.webkit.org/show_bug.cgi?id=121002
1980 Reviewed by Darin Adler.
1983 Removed the two forward declaration in HTMLDocument.h file.
1985 * html/HTMLDocument.h:
1987 2013-09-08 Gurpreet Kaur <k.gurpreet@samsung.com>
1989 defining line height affects height of text box
1990 https://bugs.webkit.org/show_bug.cgi?id=17619
1992 Reviewed by Darin Adler.
1994 Giving line height to input elements increase the height
1995 of the element. To make it work similiar as Mozilla and IE
1996 line-height :normal should be applied for input elements.
1998 Test: fast/dom/HTMLInputElement/input-line-height.html
2002 Made the line-height: normal as !important so that it does not
2003 consider any other line-height specified through internal or
2006 2013-09-08 Gurpreet Kaur <k.gurpreet@samsung.com>
2008 Scrollbar width is not applied when element hidden
2009 https://bugs.webkit.org/show_bug.cgi?id=90546
2011 Reviewed by Simon Fraser.
2013 Webkit has css properties through which custom scroll
2014 bars can be added. Incase the element's visible property
2015 is hidden and custom scrollbar properties are applied
2016 the scrollbar width is not considered when quering the
2017 element.clientWidth. Incase of non-custom scrollbars
2018 whether the element's visible property is hidden or not
2019 correct scrollbar width is considered.
2021 Tests: fast/dom/Element/scroll-width-hidden.html
2022 fast/dom/Element/scroll-width-visible.html
2024 * rendering/RenderScrollbar.cpp:
2025 (WebCore::RenderScrollbar::updateScrollbarPart):
2026 Incase custom scrollbar is created there is a check whether
2027 the renderer to which scrollbar is added is visible or not.
2028 This check is not required since for non-custom scrollbars same
2029 check is not present. Also whether element's visible property is
2030 hidden or not a placeholder is set for the element. Both behavoiur
2031 i.e custom and non-custom scrollbars should be same.
2033 2013-09-08 Tamas Czene <tczene@inf.u-szeged.hu>
2035 GStreamer 0.10 build fix after r155251.
2037 Reviewed by Csaba Osztrogonác.
2039 * platform/graphics/gstreamer/GStreamerVersioning.cpp:
2041 2013-09-08 Christophe Dumez <ch.dumez@sisa.samsung.com>
2043 [wk2] REGRESSION (r154673): PDF scrolling moves very slowly
2044 https://bugs.webkit.org/show_bug.cgi?id=120542
2046 Reviewed by Tim Horton.
2048 Handle 'wheel' events in addition to 'mousewheel'.
2050 * html/shadow/MediaControlsApple.cpp:
2051 Listen for the standard 'wheel' event instead of the legacy 'mousewheel' one.
2052 While not strictly needed, we should use the legacy events as little as
2054 * plugins/PluginView.cpp:
2055 Handle 'wheel' events in addition to 'mousewheel'.
2057 2013-09-08 Darin Adler <darin@apple.com>
2059 Make Editor::deleteButtonController a reference
2060 https://bugs.webkit.org/show_bug.cgi?id=121019
2062 Reviewed by Andreas Kling.
2064 * dom/ContainerNode.cpp:
2065 (WebCore::ContainerNode::cloneChildNodes): Updated to use . instead of ->.
2066 * editing/DeleteButton.cpp:
2067 (WebCore::DeleteButton::defaultEventHandler): Ditto.
2069 * editing/DeleteButtonController.cpp:
2070 (WebCore::DeleteButtonController::DeleteButtonController): Updated to take a Frame&
2071 instead of a Frame*.
2072 (WebCore::DeleteButtonController::respondToChangedSelection): Ditto.
2073 (WebCore::DeleteButtonController::createDeletionUI): Ditto.
2074 (WebCore::DeleteButtonController::show): Ditto.
2075 (WebCore::DeleteButtonController::enable): Ditto.
2076 (WebCore::DeleteButtonController::deleteTarget): Ditto.
2077 * editing/DeleteButtonController.h: Ditto.
2079 * editing/Editor.cpp:
2080 (WebCore::Editor::avoidIntersectionWithDeleteButtonController): Removed bogus
2081 null check from both versions of this function.
2082 (WebCore::Editor::Editor): Use construction rather than assignment and pass
2083 a reference instead of a pointer to make m_deleteButtonController.
2084 (WebCore::Editor::clear): Ditto.
2086 * editing/Editor.h: Made deleteButtonController return a reference.
2087 Also reorganized the header to put all the conditional functions together,
2088 and not mixed in with non-conditional ones.
2090 * editing/markup.cpp:
2091 (WebCore::createMarkup): Updated to use . instead of -> and also to use
2092 emptyString() instead of constructing a new empty string.
2094 2013-09-08 Andreas Kling <akling@apple.com>
2096 InlineBox::root() should return a reference.
2097 <https://webkit.org/b/121014>
2099 Reviewed by Antti Koivisto.
2101 There is always a root inline box, so make root() return a reference.
2102 Also make some effort to cache the result in a local at call sites.
2104 2013-09-08 Andreas Kling <akling@apple.com>
2106 FrameView::scheduleEvent() is over-engineered.
2107 <https://webkit.org/b/121004>
2109 Reviewed by Antti Koivisto.
2111 Remove gratuitous FrameActionScheduler class that was really only being used
2112 to defer the occassional "overflowchanged" event until layout had finished.
2115 * GNUmakefile.list.am:
2117 * WebCore.vcxproj/WebCore.vcxproj:
2118 * WebCore.vcxproj/WebCore.vcxproj.filters:
2119 * WebCore.xcodeproj/project.pbxproj:
2120 * page/FrameActionScheduler.cpp:
2121 * page/FrameActionScheduler.h:
2123 Removed FrameActionScheduler.
2126 * page/FrameView.cpp:
2127 (WebCore::FrameView::FrameView):
2128 (WebCore::FrameView::~FrameView):
2129 (WebCore::FrameView::layout):
2130 (WebCore::FrameView::ScheduledEvent::ScheduledEvent):
2131 (WebCore::FrameView::scheduleEvent):
2132 (WebCore::FrameView::pauseScheduledEvents):
2133 (WebCore::FrameView::resumeScheduledEvents):
2134 (WebCore::FrameView::performPostLayoutTasks):
2135 (WebCore::FrameView::updateOverflowStatus):
2137 Replaced it with a Vector<ScheduledEvent> and a suppression counter.
2138 A ScheduledEvent is just a { Node, Event } pair.
2140 2013-09-08 Anders Carlsson <andersca@apple.com>
2142 Move WTF::notFound to Vector.h and delete NotFound.h
2143 https://bugs.webkit.org/show_bug.cgi?id=120990
2145 Reviewed by Sam Weinig.
2147 * html/HTMLImageElement.cpp:
2148 * loader/archive/mhtml/MHTMLParser.cpp:
2149 * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
2150 * platform/graphics/win/GraphicsContext3DWin.cpp:
2151 * platform/network/soup/SocketStreamHandleSoup.cpp:
2153 2013-09-08 Commit Queue <commit-queue@webkit.org>
2155 Unreviewed, rolling out r155069 and r155138.
2156 http://trac.webkit.org/changeset/155069
2157 http://trac.webkit.org/changeset/155138
2158 https://bugs.webkit.org/show_bug.cgi?id=121008
2160 Seems to have broken many tests (bug 120963) (Requested by ap
2163 * WebCore.xcodeproj/project.pbxproj:
2164 * platform/graphics/cg/PDFDocumentImage.cpp:
2165 (WebCore::PDFDocumentImage::PDFDocumentImage):
2166 (WebCore::PDFDocumentImage::~PDFDocumentImage):
2167 (WebCore::PDFDocumentImage::size):
2168 (WebCore::PDFDocumentImage::dataChanged):
2169 (WebCore::PDFDocumentImage::adjustCTM):
2170 (WebCore::PDFDocumentImage::setCurrentPage):
2171 (WebCore::PDFDocumentImage::pageCount):
2172 (WebCore::PDFDocumentImage::draw):
2173 * platform/graphics/cg/PDFDocumentImage.h:
2174 (WebCore::PDFDocumentImage::create):
2175 (WebCore::PDFDocumentImage::hasSingleSecurityOrigin):
2176 (WebCore::PDFDocumentImage::destroyDecodedData):
2177 (WebCore::PDFDocumentImage::decodedSize):
2178 * platform/graphics/mac/PDFDocumentImageMac.mm: Removed.
2179 * platform/mac/SoftLinking.h:
2181 2013-09-08 Andreas Kling <akling@apple.com>
2183 ScriptExecutionContext: Use FINAL instead of foo() { virtualFoo() }
2184 <https://webkit.org/b/120827>
2186 Reviewed by Darin Adler.
2188 Now that we have FINAL, we can just use that to have fast versions of url()
2189 and completeURL() when calling through a Document or WorkerGlobalScope pointer.
2193 * dom/ScriptExecutionContext.h:
2194 * workers/WorkerGlobalScope.cpp:
2195 * workers/WorkerGlobalScope.h:
2197 2013-09-08 Antti Koivisto <antti@apple.com>
2199 Rename needsShadowTreeWalker
2200 https://bugs.webkit.org/show_bug.cgi?id=121005
2202 Reviewed by Andreas Kling.
2204 Rename to needsNodeRenderingTraversalSlowPath.
2206 * dom/ContainerNode.h:
2207 (WebCore::Node::needsNodeRenderingTraversalSlowPath):
2209 (WebCore::shouldUseNodeRenderingTraversalSlowPath):
2210 (WebCore::Element::resetNeedsNodeRenderingTraversalSlowPath):
2212 Only Elements can have this flag. Move the code here from Node.
2214 (WebCore::Element::addShadowRoot):
2215 (WebCore::Element::setBeforePseudoElement):
2216 (WebCore::Element::setAfterPseudoElement):
2217 (WebCore::Element::clearBeforePseudoElement):
2218 (WebCore::Element::clearAfterPseudoElement):
2220 Reset after clear too.
2226 (WebCore::Node::isInsertionPoint):
2227 (WebCore::Node::setNeedsNodeRenderingTraversalSlowPath):
2231 * dom/NodeRenderingTraversal.h:
2232 (WebCore::NodeRenderingTraversal::parent):
2233 (WebCore::NodeRenderingTraversal::nextSibling):
2234 (WebCore::NodeRenderingTraversal::previousSibling):
2236 2013-09-08 Andreas Kling <akling@apple.com>
2238 Render{Block,Inline}::lineBoxes() should return a reference.
2239 <https://webkit.org/b/120995>
2241 Reviewed by Antti Koivisto.
2243 This function was already just returning the address of a member variable.
2245 2013-09-08 Andreas Kling <akling@apple.com>
2247 Move "using software CSS filters" optimization flag to RenderView.
2248 <https://webkit.org/b/120999>
2250 Reviewed by Antti Koivisto.
2252 This flag is used to avoid an extra tree walk when there are no software CSS filters in use.
2253 Move it from FrameView to RenderView where it belongs.
2256 * rendering/RenderLayer.cpp:
2257 (WebCore::RenderLayer::updateOrRemoveFilterEffectRenderer):
2258 * rendering/RenderObject.cpp:
2259 (WebCore::RenderObject::containerForRepaint):
2260 * rendering/RenderView.cpp:
2261 (WebCore::RenderView::RenderView):
2262 * rendering/RenderView.h:
2264 2013-09-08 Andreas Kling <akling@apple.com>
2266 FrameLoader::icon() should return a reference.
2267 <https://webkit.org/b/120993>
2269 Reviewed by Antti Koivisto.
2271 This function never returns null. Make it return a reference!
2273 2013-09-08 Andreas Kling <akling@apple.com>
2275 Remove unused Scrollbar tickmark stuff.
2276 <https://webkit.org/b/121000>
2278 Reviewed by Antti Koivisto.
2280 This code is no longer used by any ports.
2282 * page/FrameView.cpp:
2284 * platform/ScrollableArea.h:
2285 * platform/Scrollbar.cpp:
2286 * platform/Scrollbar.h:
2287 * platform/ScrollbarThemeClient.h:
2289 2013-09-08 Antti Koivisto <antti@apple.com>
2291 Remove ComposedShadowTreeWalker
2292 https://bugs.webkit.org/show_bug.cgi?id=120997
2294 Reviewed by Andreas Kling.
2296 Move the code to NodeRenderingTraversal which is the only client besides Internals.
2299 * GNUmakefile.list.am:
2302 * WebCore.vcxproj/WebCore.vcxproj:
2303 * WebCore.xcodeproj/project.pbxproj:
2304 * dom/ComposedShadowTreeWalker.cpp: Removed.
2305 * dom/ComposedShadowTreeWalker.h: Removed.
2306 * dom/NodeRenderingTraversal.cpp:
2307 (WebCore::NodeRenderingTraversal::nodeCanBeDistributed):
2308 (WebCore::NodeRenderingTraversal::findFirstSiblingEnteringInsertionPoints):
2309 (WebCore::NodeRenderingTraversal::findFirstEnteringInsertionPoints):
2310 (WebCore::NodeRenderingTraversal::findFirstFromDistributedNode):
2311 (WebCore::NodeRenderingTraversal::findLastSiblingEnteringInsertionPoints):
2312 (WebCore::NodeRenderingTraversal::findLastEnteringInsertionPoints):
2313 (WebCore::NodeRenderingTraversal::findLastFromDistributedNode):
2314 (WebCore::NodeRenderingTraversal::traverseParent):
2315 (WebCore::NodeRenderingTraversal::traverseFirstChild):
2316 (WebCore::NodeRenderingTraversal::traverseLastChild):
2317 (WebCore::NodeRenderingTraversal::traverseNextSibling):
2318 (WebCore::NodeRenderingTraversal::traversePreviousSibling):
2320 Make former members of ComposedShadowTreeWalker standalone functions in NodeRenderingTraversal.
2322 (WebCore::NodeRenderingTraversal::parentSlow):
2323 (WebCore::NodeRenderingTraversal::nextSiblingSlow):
2324 (WebCore::NodeRenderingTraversal::previousSiblingSlow):
2325 (WebCore::NodeRenderingTraversal::nextInScope):
2326 (WebCore::NodeRenderingTraversal::previousInScope):
2327 (WebCore::NodeRenderingTraversal::parentInScope):
2328 (WebCore::NodeRenderingTraversal::lastChildInScope):
2329 * testing/Internals.cpp:
2330 * testing/Internals.h:
2331 * testing/Internals.idl:
2333 2013-09-08 Andreas Kling <akling@apple.com>
2335 FrameLoader::policyChecker() should return a reference.
2336 <https://webkit.org/b/120991>
2338 Reviewed by Antti Koivisto.
2340 This function never returns null. Make it return a reference!
2342 2013-09-08 Andreas Kling <akling@apple.com>
2344 FrameLoader::mixedContentChecker() should return a reference.
2345 <https://webkit.org/b/120992>
2347 Reviewed by Antti Koivisto.
2349 This function was already just returning the address of a member variable.
2351 2013-09-07 Antti Koivisto <antti@apple.com>
2353 Separate forward and backward paths in ComposedShadowTreeWalker
2354 https://bugs.webkit.org/show_bug.cgi?id=120979
2356 Reviewed by Andreas Kling.
2358 Have separate first/last and next/previous paths instead of using a direction enum.
2360 Reduce the number of helper functions and give them more understandable names.
2362 * dom/ComposedShadowTreeWalker.cpp:
2363 (WebCore::findFirstSiblingEnteringInsertionPoints):
2364 (WebCore::findFirstEnteringInsertionPoints):
2365 (WebCore::findFirstFromDistributedNode):
2366 (WebCore::findLastSiblingEnteringInsertionPoints):
2367 (WebCore::findLastEnteringInsertionPoints):
2368 (WebCore::findLastFromDistributedNode):
2369 (WebCore::ComposedShadowTreeWalker::firstChild):
2370 (WebCore::ComposedShadowTreeWalker::traverseFirstChild):
2371 (WebCore::ComposedShadowTreeWalker::lastChild):
2372 (WebCore::ComposedShadowTreeWalker::traverseLastChild):
2373 (WebCore::ComposedShadowTreeWalker::nextSibling):
2374 (WebCore::ComposedShadowTreeWalker::previousSibling):
2375 (WebCore::ComposedShadowTreeWalker::traverseNextSibling):
2376 (WebCore::ComposedShadowTreeWalker::traversePreviousSibling):
2377 * dom/ComposedShadowTreeWalker.h:
2379 2013-09-07 Andreas Kling <akling@apple.com>
2381 Beat FrameView with the FINAL stick.
2382 <https://webkit.org/b/120989>
2384 Reviewed by Anders Carlsson.
2386 ... and mark everything virtual with OVERRIDE, exposing a couple of things
2387 that didn't actually override anything.
2392 2013-09-07 Anders Carlsson <andersca@apple.com>
2394 Remove NonCopyableSort.h from WTF
2395 https://bugs.webkit.org/show_bug.cgi?id=120984
2397 Reviewed by Andreas Kling.
2399 * css/MediaQuery.cpp:
2400 (WebCore::MediaQuery::MediaQuery):
2401 * html/HTMLMediaElement.cpp:
2402 (WebCore::HTMLMediaElement::updateActiveTextTrackCues):
2403 * html/RangeInputType.cpp:
2404 (WebCore::RangeInputType::updateTickMarkValues):
2405 * inspector/InspectorMemoryAgent.cpp:
2406 * page/CaptionUserPreferences.cpp:
2407 (WebCore::CaptionUserPreferences::sortedTrackListForMenu):
2408 * page/CaptionUserPreferences.h:
2409 * page/CaptionUserPreferencesMediaAF.cpp:
2410 (WebCore::CaptionUserPreferencesMediaAF::sortedTrackListForMenu):
2411 * platform/graphics/texmap/TextureMapper.cpp:
2412 (WebCore::BitmapTexturePool::releaseUnusedTexturesTimerFired):
2414 2013-09-07 Antti Koivisto <antti@apple.com>
2416 Simplify ComposedShadowTreeWalker parent traversal
2417 https://bugs.webkit.org/show_bug.cgi?id=120971
2419 Reviewed by Andreas Kling.
2421 Combine a bunch of parent traversal functions into one.
2423 * dom/ComposedShadowTreeWalker.cpp:
2424 (WebCore::ComposedShadowTreeWalker::traverseParent):
2425 (WebCore::ComposedShadowTreeWalker::previous):
2426 * dom/ComposedShadowTreeWalker.h:
2428 Remove unused fromFirstChild.
2430 2013-09-07 Anders Carlsson <andersca@apple.com>
2432 Get rid of PassOwnArrayPtr
2433 https://bugs.webkit.org/show_bug.cgi?id=120964
2435 Reviewed by Andreas Kling.
2437 Use OwnArrayPtr instead of PassOwnArrayPtr.
2439 * html/canvas/WebGLRenderingContext.cpp:
2440 * platform/Length.cpp:
2441 (WebCore::newCoordsArray):
2442 (WebCore::newLengthArray):
2443 * platform/Length.h:
2444 * platform/audio/FFTFrame.h:
2445 * platform/graphics/GraphicsContext3D.cpp:
2446 * platform/graphics/GraphicsContext3D.h:
2447 * platform/graphics/texmap/TextureMapperGL.cpp:
2448 * platform/graphics/wince/SharedBitmap.cpp:
2450 2013-09-07 Antti Koivisto <antti@apple.com>
2452 Remove unnecessary sibling text renderers after attach
2453 https://bugs.webkit.org/show_bug.cgi?id=120953
2455 Reviewed by the Swedish Review Team: Anders Carlsson and Andreas Kling.
2457 The current createTextRenderersForSiblingsAfterAttachIfNeeded code only adds text renderers, never removes them.
2458 Style changes can go either way.
2460 The patch causes no visible changes in rendered output. The whitespace nodes that it affects are leftovers that
2461 have no rendering effect. However it does change results of many dumpAsText and render tree dump based layout
2462 tests as unnecessary text nodes disappear.
2464 The main goal is to make results of dynamic attach and parsing time attach produce more similar results. As
2465 an added bonus we get slightly simpler rendering trees.
2467 Rendering tree dumps show us still leaving behind empty anonymous blocks when removing whitespace text nodes.
2468 Those should collapse away too.
2470 * style/StyleResolveTree.cpp:
2471 (WebCore::Style::reattachTextRenderersForWhitespaceOnlySiblingsAfterAttachIfNeeded):
2473 Allow the code both create and remove text renderers.
2474 Tighten to bail out faster if case is not the exact one that matters.
2475 Use NodeRenderingTraversal to mirror textRendererIsNeeded.
2476 Renamed for clarity.
2478 (WebCore::Style::updateTextRendererAfterContentChange):
2479 (WebCore::Style::resolveLocal):
2480 (WebCore::Style::updateTextStyle):
2481 (WebCore::Style::attachRenderTree):
2483 2013-09-07 Anders Carlsson <andersca@apple.com>
2485 Get rid of FastAllocBase.h
2486 https://bugs.webkit.org/show_bug.cgi?id=120952
2488 Reviewed by Antti Koivisto.
2490 Include FastMalloc.h instead of FastAllocBase.h.
2492 * Modules/webdatabase/SQLTransactionClient.h:
2493 * bindings/js/GCController.h:
2495 * bridge/IdentifierRep.h:
2496 * dom/DocumentStyleSheetCollection.h:
2497 * dom/TransformSource.h:
2499 * inspector/InspectorCounters.h:
2500 * inspector/InstrumentingAgents.h:
2501 * inspector/WorkerInspectorController.h:
2502 * loader/cache/CachedResourceClient.h:
2503 * page/FrameActionScheduler.h:
2504 * platform/Length.h:
2505 * platform/MemoryPressureHandler.h:
2506 * platform/ScrollAnimator.h:
2507 * platform/SharedTimer.h:
2508 * platform/audio/gstreamer/FFTFrameGStreamer.cpp:
2509 * platform/cairo/WidgetBackingStore.h:
2510 * platform/graphics/Color.h:
2511 * platform/graphics/FontData.h:
2512 * platform/graphics/Path.h:
2513 * platform/graphics/qt/FontCustomPlatformData.h:
2514 * platform/graphics/transforms/AffineTransform.h:
2515 * platform/graphics/transforms/TransformationMatrix.h:
2516 * platform/gtk/GtkDragAndDropHelper.h:
2517 * platform/gtk/GtkPopupMenu.h:
2518 * platform/network/NetworkStateNotifier.h:
2519 * platform/sql/SQLiteTransaction.h:
2520 * platform/text/enchant/TextCheckerEnchant.h:
2521 * rendering/RenderArena.h:
2522 * rendering/TableLayout.h:
2523 * rendering/style/StyleCustomFilterProgram.h:
2524 * rendering/style/StyleCustomFilterProgramCache.h:
2525 * svg/SVGPathConsumer.h:
2526 * workers/WorkerScriptLoader.h:
2528 2013-09-07 Eric Carlson <eric.carlson@apple.com>
2530 MediaStream should fire ended event when all tracks are ended
2531 https://bugs.webkit.org/show_bug.cgi?id=120871
2533 Reviewed by Jer Noble.
2535 Merge https://chromium.googlesource.com/chromium/blink/+/bebd179b65be69e46f2f434a3ec8b1e4aa85cc42
2537 Test: fast/mediastream/MediaStream-onended.html
2539 * Modules/mediastream/MediaStream.cpp:
2540 (WebCore::MediaStream::trackEnded): New.
2541 * Modules/mediastream/MediaStream.h:
2543 * Modules/mediastream/MediaStreamTrack.cpp:
2544 (WebCore::MediaStreamTrack::sourceChangedState): Call didEndTrack when state changes to ReadyStateEnded.
2545 (WebCore::MediaStreamTrack::didEndTrack): New.
2546 (WebCore::MediaStreamTrack::stop): Call didEndTrack.
2547 * Modules/mediastream/MediaStreamTrack.h:
2549 * platform/mediastream/MediaStreamDescriptor.h:
2550 (WebCore::MediaStreamDescriptor::MediaStreamDescriptor): Require didEndTrack.
2552 2013-09-06 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
2554 Get MEDIA_STREAM compiling for other ports (EFL and GTK)
2555 https://bugs.webkit.org/show_bug.cgi?id=120811
2557 Reviewed by Eric Carlson.
2560 * GNUmakefile.list.am:
2561 * Modules/mediastream/LocalMediaStream.h:
2562 * Modules/mediastream/MediaStreamRegistry.cpp:
2563 (WebCore::MediaStreamRegistry::lookupMediaStreamDescriptor):
2564 * Modules/mediastream/RTCStatsResponse.h:
2566 2013-09-06 Bem Jones-Bey <bjonesbe@adobe.com>
2568 [CSS Shapes] Floats with shape-outside aren't painting in the correct order
2569 https://bugs.webkit.org/show_bug.cgi?id=118492
2571 Reviewed by Darin Adler.
2573 When removing the old positioning behavior, the code that makes a
2574 float with shape-outside gain a layer was left behind. This patch
2575 removes that, so now floats with shape-outside are painted just like
2576 floats without shape-outside.
2578 Also remove the isFloatingWithShapeOutside helper method because its
2579 use is now somewhat redundant, and the check it does is now only
2580 needed in one place.
2582 Test: fast/shapes/shape-outside-floats/shape-outside-floats-not-a-layer.html
2584 * rendering/RenderBox.h:
2585 (WebCore::RenderBox::shapeOutsideInfo):
2586 * rendering/RenderObject.h:
2587 * rendering/shapes/ShapeOutsideInfo.cpp:
2588 (WebCore::ShapeOutsideInfo::isEnabledFor):
2590 2013-09-06 Anders Carlsson <andersca@apple.com>
2592 Add a new smart pointer type for fastMalloc'ed memory
2593 https://bugs.webkit.org/show_bug.cgi?id=120911
2595 Reviewed by Andreas Kling.
2597 Update for WTF changes.
2599 * platform/network/cf/FormDataStreamCFNet.cpp:
2600 (WebCore::advanceCurrentStream):
2602 2013-09-06 Dirk Schulze <krit@webkit.org>
2604 Interpolate between CSS filter() and cached images
2605 https://bugs.webkit.org/show_bug.cgi?id=120602
2607 Reviewed by Simon Fraser.
2609 Interpolate from a filter() image function to a url() image reference and
2610 the other way around, if the input image on the filter function is the same
2611 as the referenced image on url().
2613 * page/animation/CSSPropertyAnimation.cpp: Replaced old
2614 filterBlend function with blendFilter function which is more generic
2615 and can be reused in multiple places.
2616 (WebCore::blendFilterOperations):
2617 (WebCore::blendFunc):
2618 (WebCore::blendFilter):
2620 2013-09-06 Ryosuke Niwa <rniwa@webkit.org>
2622 Elements retained by AccessibilityImageMapLink leak
2623 https://bugs.webkit.org/show_bug.cgi?id=120917
2625 Reviewed by Chris Fleizach.
2627 Merge https://chromium.googlesource.com/chromium/blink/+/df0bd288efe65e5e38425fbdcdfc68b5a2a79e42
2629 Unfortunately, the test added by the Blink change doesn't reproduce a leak in WebKit.
2631 * accessibility/AccessibilityImageMapLink.cpp:
2632 (WebCore::AccessibilityImageMapLink::detachFromParent):
2633 * accessibility/AccessibilityImageMapLink.h:
2634 * accessibility/AccessibilityMockObject.h:
2635 (WebCore::AccessibilityMockObject::detachFromParent):
2637 2013-09-06 Andreas Kling <akling@apple.com>
2639 Make Obj-C bindings generator less #include-happy.
2640 <https://webkit.org/b/120913>
2642 Reviewed by Anders Carlsson.
2644 Knock out an old FIXME in CodeGeneratorObjC.pm and avoid including unrelated
2645 interface declarations from implementation files where they are not needed.
2647 * bindings/scripts/CodeGeneratorObjC.pm:
2648 (GenerateImplementation):
2650 Only include DOMFooInternal.h relevant to the current interface.
2652 * bindings/scripts/test/ObjC/*
2654 Rebaseline Obj-C bindings tests now that they include fewer things.
2656 2013-09-06 Andreas Kling <akling@apple.com>
2658 Rebaseline bindings tests after Swedish breakage.
2660 2013-09-06 Andreas Kling <akling@apple.com>
2662 Don't include Document.h from JSDOMBinding.h
2663 <https://webkit.org/b/120909>
2665 Reviewed by Anders Carlsson.
2667 Move DOMConstructorWithDocument out of JSDOMBinding.h to its own header.
2668 This was the only part of JSDOMBinding.h that needed Document's definition.
2670 This reduces the include dependency graph of many bindings files.
2672 * WebCore.xcodeproj/project.pbxproj:
2673 * bindings/js/DOMConstructorWithDocument.h:
2674 * bindings/js/JSDOMBinding.cpp:
2675 * bindings/js/JSDOMBinding.h:
2676 * bindings/scripts/CodeGeneratorJS.pm:
2677 * bindings/scripts/CodeGeneratorGObject.pm:
2679 2013-09-06 Ryosuke Niwa <rniwa@webkit.org>
2681 Range::ownerDocument should return Document&
2682 https://bugs.webkit.org/show_bug.cgi?id=120908
2684 Reviewed by Andreas Kling.
2686 Return Document& in Range::ownerDocument(). Also make setDocument take Document& so that this invariant is self-evident.
2688 * bindings/objc/DOM.mm:
2689 (-[DOMRange boundingBox]):
2690 (-[DOMRange renderedImageForcingBlackText:]):
2691 (-[DOMRange textRects]):
2693 (WebCore::Range::setDocument):
2694 (WebCore::Range::setStart):
2695 (WebCore::Range::setEnd):
2696 (WebCore::Range::selectNode):
2697 (WebCore::Range::selectNodeContents):
2699 (WebCore::Range::ownerDocument):
2700 * editing/AlternativeTextController.cpp:
2701 (WebCore::AlternativeTextController::handleAlternativeTextUIResult):
2702 * editing/Editor.cpp:
2703 (WebCore::Editor::avoidIntersectionWithDeleteButtonController):
2704 (WebCore::isFrameInRange):
2705 (WebCore::Editor::countMatchesForText):
2706 * editing/EditorCommand.cpp:
2707 (WebCore::unionDOMRanges):
2708 * editing/TextCheckingHelper.cpp:
2709 (WebCore::TextCheckingHelper::unifiedTextCheckerEnabled):
2710 * editing/TextIterator.cpp:
2711 (WebCore::plainText):
2712 (WebCore::findPlainText):
2713 * editing/htmlediting.cpp:
2714 (WebCore::extendRangeToWrappingNodes):
2715 * editing/markup.cpp:
2716 (WebCore::createMarkup):
2717 (WebCore::createFragmentFromText):
2718 * page/DragController.cpp:
2719 (WebCore::documentFragmentFromDragData):
2720 (WebCore::DragController::concludeEditDrag):
2722 (WebCore::Page::rangeOfString):
2723 * rendering/RenderObject.cpp:
2724 (WebCore::RenderObject::absoluteBoundingBoxRectForRange):
2725 * testing/Internals.cpp:
2726 (WebCore::Internals::addTextMatchMarker):
2728 2013-09-06 Brent Fulgham <bfulgham@apple.com>
2730 [Windows] StructuredExceptionHandlerSuppressor Causes Bad Interactions with Support Libraries
2731 https://bugs.webkit.org/show_bug.cgi?id=120901
2733 Reviewed by Anders Carlsson.
2735 Change from old "crash on any exception" implementation to a new version that leaves normal
2736 exception handling infrastructure in place for use by support libraries. We check exceptions
2737 and decide whether to abort or not based on the failure type.
2739 * WebCore.vcxproj/WebCore.vcxproj: Add new implementation files.
2740 * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
2741 * platform/graphics/ca/win/LayerChangesFlusher.cpp:
2742 (WebCore::LayerChangesFlusher::hookCallback): Allocate handler struct on stack.
2743 * platform/win/StructuredExceptionHandlerSuppressor.cpp: Added.
2744 (exceptionShouldTerminateProgram): New.
2745 (exceptionHandler): New.
2746 (WebCore::StructuredExceptionHandlerSuppressor::StructuredExceptionHandlerSuppressor): Moved
2747 from header, and updated to add our new exception handler.
2748 (WebCore::StructuredExceptionHandlerSuppressor::~StructuredExceptionHandlerSuppressor): Moved
2750 * platform/win/StructuredExceptionHandlerSuppressor.h: Move implementation of constructor and
2751 destructor from header file.
2752 * platform/win/makesafeseh.asm: Added.
2754 2013-09-06 Vivek Galatage <vivek.vg@samsung.com>
2756 Refactor XMLDocumentParser to defer creation of XMLErrors until error occurs
2757 https://bugs.webkit.org/show_bug.cgi?id=120850
2759 Reviewed by Darin Adler.
2761 XMLErrors is created as soon as XMLDocumentParser is constructed. It may not be required
2762 for all the valid XML documents. Deferring its creation until an error for the invalid
2765 No new tests as code refactoring.
2767 * xml/parser/XMLDocumentParser.cpp:
2768 (WebCore::XMLDocumentParser::handleError):
2769 (WebCore::XMLDocumentParser::insertErrorMessageBlock):
2770 * xml/parser/XMLDocumentParser.h:
2771 * xml/parser/XMLDocumentParserLibxml2.cpp:
2772 (WebCore::XMLDocumentParser::XMLDocumentParser):
2773 * xml/parser/XMLDocumentParserQt.cpp:
2774 (WebCore::XMLDocumentParser::XMLDocumentParser):
2776 2013-09-06 Anders Carlsson <andersca@apple.com>
2778 Remove fastNew/fastDelete
2779 https://bugs.webkit.org/show_bug.cgi?id=120904
2781 Reviewed by Andreas Kling.
2783 Call operator delete directly.
2785 * css/CSSSelectorList.cpp:
2786 (WebCore::CSSSelectorList::adoptSelectorVector):
2788 2013-09-06 Anders Carlsson <andersca@apple.com>
2790 Stop using fastNew/fastDelete in JavaScriptCore
2791 https://bugs.webkit.org/show_bug.cgi?id=120898
2793 Reviewed by Oliver Hunt.
2795 Update for changes to JavaScriptCore.
2797 * bindings/js/DOMObjectHashTableMap.h:
2798 (WebCore::DOMObjectHashTableMap::get):
2799 * bindings/js/JSDOMBinding.cpp:
2800 (WebCore::getHashTableForGlobalData):
2801 * bindings/js/JSDOMBinding.h:
2802 * bindings/js/JSDOMWindowCustom.cpp:
2803 (WebCore::JSDOMWindow::put):
2804 * bindings/js/JSPluginElementFunctions.h:
2805 (WebCore::pluginElementCustomGetOwnPropertySlot):
2806 * bindings/js/JSStorageCustom.cpp:
2807 (WebCore::JSStorage::deleteProperty):
2808 (WebCore::JSStorage::putDelegate):
2809 * bindings/scripts/CodeGeneratorJS.pm:
2810 (hashTableAccessor):
2811 (prototypeHashTableAccessor):
2812 (constructorHashTableAccessor):
2813 (GenerateGetOwnPropertySlotBody):
2814 (GenerateImplementation):
2815 (GenerateConstructorHelperMethods):
2817 2013-09-06 Andreas Kling <akling@apple.com>
2819 Include Frame.h in fewer places.
2820 <https://webkit.org/b/120868>
2822 Reviewed by Anders Carlsson.
2824 - Move JSMainThreadExecState::instrumentFunctionCall() to a separate header.
2825 This avoids including InspectorInstrumentation.h from JSMainThreadExecState.h
2826 which caused all JS and Objective-C bindings to depend on Frame.h
2828 - Out-of-line the three methods on FrameView that were operating on Frames.
2829 Most of the call sites were in FrameView.cpp so they will still get inlined.
2831 - Removed GenericBinding.h, nothing was using it anyway.
2833 After this, touching Frame.h and doing a (debug) rebuild goes from 9m30 to 3m30
2836 * GNUmakefile.list.am:
2838 * WebCore.vcxproj/WebCore.vcxproj:
2839 * WebCore.vcxproj/WebCore.vcxproj.filters:
2840 * WebCore.xcodeproj/project.pbxproj:
2841 * bindings/generic/GenericBinding.h: Removed.
2842 * bindings/js/JSCallbackData.cpp:
2843 * bindings/js/JSEventListener.cpp:
2844 * bindings/js/JSMainThreadExecState.h:
2845 * bindings/js/JSMainThreadExecStateInstrumentation.h: Added.
2846 (WebCore::JSMainThreadExecState::instrumentFunctionCall):
2847 * bindings/js/JSMutationCallback.cpp:
2848 * bindings/js/ScheduledAction.cpp:
2849 * css/DeprecatedStyleBuilder.cpp:
2850 * css/ElementRuleCollector.cpp:
2851 * css/MediaQueryEvaluator.cpp:
2852 * css/SelectorChecker.h:
2853 * dom/StyledElement.cpp:
2854 * html/HTMLPlugInImageElement.cpp:
2855 * inspector/InspectorPageAgent.h:
2856 * inspector/NetworkResourcesData.h:
2857 * inspector/PageRuntimeAgent.cpp:
2858 * loader/cache/CachedImage.cpp:
2859 * page/FrameView.cpp:
2860 (WebCore::FrameView::renderView):
2861 (WebCore::FrameView::mapFromLayoutToCSSUnits):
2862 (WebCore::FrameView::mapFromCSSToLayoutUnits):
2864 * page/TouchAdjustment.cpp:
2865 * rendering/RenderBoxModelObject.cpp:
2866 * rendering/RenderLayer.cpp:
2867 * rendering/RenderLayerCompositor.h:
2868 * rendering/RenderText.cpp:
2869 * svg/graphics/SVGImage.cpp:
2871 2013-09-06 Brent Fulgham <bfulgham@apple.com>
2873 [Windows] Unreviewed gardening: Spell 'Suppressor' properly
2875 * WebCore.vcxproj/WebCore.vcxproj: Change StructuredExceptionHandlerSupressor to StructuredExceptionHandlerSuppressor
2876 * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto
2877 * platform/graphics/ca/win/LayerChangesFlusher.cpp:
2878 (WebCore::LayerChangesFlusher::hookCallback): Ditto
2879 * platform/win/StructuredExceptionHandlerSuppressor.h: Copied from platform/win/StructuredExceptionHandlerSupressor.h.
2880 * platform/win/StructuredExceptionHandlerSupressor.h: Removed.
2882 2013-09-06 David Hyatt <hyatt@apple.com>
2884 Add new RenderBlockFlow class.
2885 https://bugs.webkit.org/show_bug.cgi?id=120777
2887 Reviewed by Beth Dakin.
2889 This patch adds a new RenderBlockFlow class. The idea is to get all of the line/float/margin
2890 code out of RenderBlock and into the subclass, and then we can make RenderBlock an abstract
2891 base. This will save memory for all of the classes that derive from RenderBlock but have
2892 their own layout systems (e.g., flexbox, grid, table), and it will let us tighten up
2893 types to make it more clear when we're talking about block layout code vs. a more generic
2894 block-level object that can have any kind of layout.
2896 This patch adds the new class and it makes sure all the objects that should be block flows
2897 inherit from the new class.
2899 isBlockFlow() proved to be a problematic method (and was the source of regressions when I
2900 landed this patch the first time). When the method was first implemented, it was added as
2901 "I'm a block but not a table." and at the time table was the only subclass of block. However
2902 when new subclasses were added, this function was never patched to account for them. This
2903 means, for example, that flexible boxes and grids claim to be block flows in the codebase
2904 and have for years. This is obviously wrong, since flexible boxes are not in fact block
2905 flows, but because of this mistake, code has started relying on the incorrect behavior of
2906 isBlockFlow() (form controls mostly).
2908 What I've done to deal with this problem is renamed isBlockFlow() to be
2909 isBlockFlowFlexBoxOrGrid() in order to make it obvious that this method is returning true
2910 for pretty much all blocks other than tables. This makes a lot of call sites look pretty
2911 stupid, since they obviously never intended to include flexible boxes or grids, but at least
2912 it is clear what the method is doing now.
2914 The plan is to land this patch and then start converting call sites from
2915 isBlockFlowFlexBoxOrGrid() to isRenderBlockFlow() one by one, and that way we can figure
2916 out which code is making bad assumptions and change those callers to be isRenderBlock()
2917 instead. Ultimately this isBlockFlowFlexBoxOrGrid() method will go away with callers either
2918 changing to use isRenderBlock() or isRenderBlockFlow().
2921 * GNUmakefile.list.am:
2923 * WebCore.vcxproj/WebCore.vcxproj:
2924 * WebCore.xcodeproj/project.pbxproj:
2925 * accessibility/AccessibilityRenderObject.cpp:
2926 (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
2927 (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
2929 (WebCore::Position::isCandidate):
2930 (WebCore::Position::getInlineBoxAndOffset):
2931 (WebCore::Position::primaryDirection):
2932 * dom/PositionIterator.cpp:
2933 (WebCore::PositionIterator::isCandidate):
2934 * editing/ApplyStyleCommand.cpp:
2935 (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown):
2936 * editing/CompositeEditCommand.cpp:
2937 (WebCore::CompositeEditCommand::addBlockPlaceholderIfNeeded):
2938 * editing/Editor.cpp:
2939 (WebCore::Editor::baseWritingDirectionForSelectionStart):
2940 * editing/FrameSelection.cpp:
2941 (WebCore::caretRenderer):
2942 * editing/TextIterator.cpp:
2943 (WebCore::TextIterator::shouldRepresentNodeOffsetZero):
2944 * editing/TypingCommand.cpp:
2945 (WebCore::TypingCommand::makeEditableRootEmpty):
2946 * editing/htmlediting.cpp:
2947 (WebCore::isBlockFlowElement):
2948 * html/HTMLDetailsElement.cpp:
2949 (WebCore::HTMLDetailsElement::createRenderer):
2950 * html/HTMLSummaryElement.cpp:
2951 (WebCore::HTMLSummaryElement::createRenderer):
2952 * html/shadow/SliderThumbElement.cpp:
2953 (WebCore::RenderSliderThumb::RenderSliderThumb):
2954 * html/shadow/SliderThumbElement.h:
2955 * rendering/LayoutState.cpp:
2956 (WebCore::LayoutState::LayoutState):
2957 * rendering/RenderBlock.cpp:
2958 (WebCore::RenderBlock::createAnonymous):
2959 (WebCore::RenderBlock::layoutBlock):
2960 (WebCore::RenderBlock::collapseMargins):
2961 (WebCore::RenderBlock::selectionGaps):
2962 (WebCore::RenderBlock::firstLineBoxBaseline):
2963 (WebCore::RenderBlock::lastLineBoxBaseline):
2964 (WebCore::RenderBlock::firstLineBlock):
2965 (WebCore::findFirstLetterBlock):
2966 (WebCore::shouldCheckLines):
2967 (WebCore::RenderBlock::adjustForBorderFit):
2968 * rendering/RenderBlock.h:
2969 * rendering/RenderBox.cpp:
2970 (WebCore::RenderBox::computeRectForRepaint):
2971 (WebCore::RenderBox::positionForPoint):
2972 * rendering/RenderBoxModelObject.h:
2973 (WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion):
2974 * rendering/RenderDeprecatedFlexibleBox.cpp:
2975 (WebCore::RenderDeprecatedFlexibleBox::applyLineClamp):
2976 (WebCore::RenderDeprecatedFlexibleBox::clearLineClamp):
2977 * rendering/RenderDetailsMarker.cpp:
2978 (WebCore::RenderDetailsMarker::RenderDetailsMarker):
2979 * rendering/RenderDetailsMarker.h:
2980 * rendering/RenderFieldset.cpp:
2981 (WebCore::RenderFieldset::RenderFieldset):
2982 * rendering/RenderFieldset.h:
2983 * rendering/RenderFileUploadControl.cpp:
2984 (WebCore::RenderFileUploadControl::RenderFileUploadControl):
2985 * rendering/RenderFileUploadControl.h:
2986 * rendering/RenderFlowThread.cpp:
2987 (WebCore::RenderFlowThread::RenderFlowThread):
2988 * rendering/RenderFlowThread.h:
2989 * rendering/RenderFullScreen.cpp:
2990 * rendering/RenderInline.cpp:
2991 (WebCore::RenderInline::computeRectForRepaint):
2992 * rendering/RenderLineBoxList.cpp:
2993 (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
2994 * rendering/RenderListItem.cpp:
2995 (WebCore::RenderListItem::RenderListItem):
2996 (WebCore::RenderListItem::willBeDestroyed):
2997 (WebCore::RenderListItem::willBeRemovedFromTree):
2998 (WebCore::RenderListItem::layout):
2999 (WebCore::RenderListItem::addOverflowFromChildren):
3000 (WebCore::RenderListItem::computePreferredLogicalWidths):
3001 (WebCore::RenderListItem::paint):
3002 * rendering/RenderListItem.h:
3003 * rendering/RenderMeter.cpp:
3004 (WebCore::RenderMeter::RenderMeter):
3005 * rendering/RenderMeter.h:
3006 * rendering/RenderMultiColumnBlock.cpp:
3007 (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
3008 * rendering/RenderMultiColumnBlock.h:
3009 * rendering/RenderObject.cpp:
3010 (WebCore::RenderObject::createObject):
3011 (WebCore::RenderObject::computeRectForRepaint):
3012 (WebCore::RenderObject::styleWillChange):
3013 (WebCore::firstLineStyleForCachedUncachedType):
3014 * rendering/RenderObject.h:
3015 (WebCore::RenderObject::isBR):
3016 (WebCore::RenderObject::isRenderBlockFlow):
3017 (WebCore::RenderObject::isBlockFlowFlexBoxOrGrid):
3018 * rendering/RenderObjectChildList.cpp:
3019 (WebCore::RenderObjectChildList::insertChildNode):
3020 * rendering/RenderProgress.cpp:
3021 (WebCore::RenderProgress::RenderProgress):
3022 * rendering/RenderProgress.h:
3023 * rendering/RenderRegion.cpp:
3024 (WebCore::RenderRegion::RenderRegion):
3025 * rendering/RenderRegion.h:
3026 * rendering/RenderRuby.cpp:
3027 (WebCore::RenderRubyAsBlock::RenderRubyAsBlock):
3028 * rendering/RenderRuby.h:
3029 * rendering/RenderRubyBase.cpp:
3030 (WebCore::RenderRubyBase::RenderRubyBase):
3031 * rendering/RenderRubyBase.h:
3032 * rendering/RenderRubyRun.cpp:
3033 (WebCore::RenderRubyRun::RenderRubyRun):
3034 * rendering/RenderRubyRun.h:
3035 * rendering/RenderRubyText.cpp:
3036 (WebCore::RenderRubyText::RenderRubyText):
3037 * rendering/RenderRubyText.h:
3038 * rendering/RenderTableCaption.cpp:
3039 (WebCore::RenderTableCaption::RenderTableCaption):
3040 * rendering/RenderTableCaption.h:
3041 * rendering/RenderTableCell.cpp:
3042 (WebCore::RenderTableCell::RenderTableCell):
3043 * rendering/RenderTableCell.h:
3044 * rendering/RenderTextControl.cpp:
3045 (WebCore::RenderTextControl::RenderTextControl):
3046 * rendering/RenderTextControl.h:
3047 * rendering/RenderTextControlSingleLine.h:
3048 (WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock):
3049 * rendering/RenderTextTrackCue.cpp:
3050 (WebCore::RenderTextTrackCue::RenderTextTrackCue):
3051 * rendering/RenderTextTrackCue.h:
3052 * rendering/RenderView.cpp:
3053 (WebCore::RenderView::RenderView):
3054 * rendering/RenderView.h:
3055 * rendering/RenderingAllInOne.cpp:
3056 * rendering/mathml/RenderMathMLOperator.cpp:
3057 (WebCore::RenderMathMLOperator::createGlyph):
3058 * rendering/svg/RenderSVGBlock.cpp:
3059 (WebCore::RenderSVGBlock::RenderSVGBlock):
3060 * rendering/svg/RenderSVGBlock.h:
3062 2013-09-06 Vivek Galatage <vivek.vg@samsung.com>
3064 Calling window.close() should indicate failure with warning message
3065 https://bugs.webkit.org/show_bug.cgi?id=120156
3067 Reviewed by Darin Adler.
3069 Closing of window is allowed for the tests for the automation.
3071 * page/DOMWindow.cpp:
3072 (WebCore::DOMWindow::close):
3074 2013-09-06 Mike West <mkwst@chromium.org>
3076 Revalidation header blacklisting should be case-insensitive.
3077 https://bugs.webkit.org/show_bug.cgi?id=120832
3079 Reviewed by Alexey Proskuryakov.
3081 Headers like 'content-type' should be ignored for 304 responses,
3082 even if they are delivered as 'Content-Type', or 'CoNtEnT-TyPe', etc.
3084 I broke this behavior in http://trac.webkit.org/changeset/142068
3085 ("Entity-header extension headers honored on 304 responses"). Pages like
3086 https://learndev.unm.edu/ currently break on reload, as they incorrectly
3087 send 'Content-Type: text/plain' for 304 responses for resources like
3088 CSS and JavaScript. The browser should drop these headers, but because
3089 we're comparing in a case-sensitive fashion, we don't.
3091 https://code.google.com/p/chromium/issues/detail?id=246875 documents the
3092 Blink-side fix; this patch is a port of that patch.
3094 Test: http/tests/cache/content-type-ignored-during-revalidation.html
3096 * loader/cache/CachedResource.cpp:
3097 (WebCore::shouldUpdateHeaderAfterRevalidation):
3098 Compare the provided AtomicString 'header' to the revalidation
3099 blacklists in a case-insensitive fashion.
3101 2013-09-06 Eric Carlson <eric.carlson@apple.com>
3103 [MediaStream API] Allow empty MediaStreams
3104 https://bugs.webkit.org/show_bug.cgi?id=120815
3106 Reviewed by Jer Noble.
3108 The spec is a bit unclear ecactly what should happen with newly created MediaStreams
3109 that doesn't have any tracks. The current implementation is too strict and the spec
3110 is being worked upon to be clearer. In the meantime this patch doesn't set eneded to
3111 true in the constructor.
3113 No new tests, existing test updated.
3115 (WebCore::MediaStreamRegistry::lookupMediaStreamDescriptor):
3116 * platform/mediastream/MediaStreamDescriptor.h:
3117 (WebCore::MediaStreamDescriptor::MediaStreamDescriptor):
3119 2013-09-06 Anders Carlsson <andersca@apple.com>
3121 Stop using fastNew/fastDelete in WebCore
3122 https://bugs.webkit.org/show_bug.cgi?id=120867
3124 Reviewed by Geoffrey Garen.
3126 Using fastNew/fastDelete can be dangerous, especially when put into a smart pointer
3127 such as OwnPtr which uses regular delete. Because of this I'd like to remove fastNew/fastDelete.
3128 Turns out it's only used in a couple of places in WebCore, so just use new/delete here instead.
3130 * platform/audio/FFTFrame.h:
3131 * platform/audio/gstreamer/FFTFrameGStreamer.cpp:
3132 (WebCore::FFTFrame::FFTFrame):
3133 (WebCore::FFTFrame::~FFTFrame):
3134 (WebCore::FFTFrame::doFFT):
3135 (WebCore::FFTFrame::doInverseFFT):
3136 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
3137 (WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
3138 (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
3139 * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
3140 (webkitVideoSinkDispose):
3142 2013-09-06 Anders Carlsson <andersca@apple.com>
3144 Fix fastMalloc/delete mismatches in CSS parser
3145 https://bugs.webkit.org/show_bug.cgi?id=120864
3147 Reviewed by Andreas Kling.
3149 Stop putting fastMalloced memory inside an OwnPtr.
3151 * css/CSSParserValues.cpp:
3152 (WebCore::CSSParserSelector::CSSParserSelector):
3153 (WebCore::CSSParserSelector::adoptSelectorVector):
3155 2013-09-06 Andreas Kling <akling@apple.com>
3157 FrameLoader::subresourceLoader() should return a reference.
3158 <https://webkit.org/b/120830>
3160 Reviewed by Anders Carlsson.
3162 There is always a SubresourceLoader, so this method could never return null.
3163 Also made m_subresourceLoader an OwnPtr to reduce header dependencies.
3165 2013-09-06 Chris Fleizach <cfleizach@apple.com>
3167 AX: aria-relevant does not expose AXARIARelevant
3168 https://bugs.webkit.org/show_bug.cgi?id=120373
3170 Reviewed by Darin Adler.
3172 When global ARIA attributes are present on an Element we need to ignore
3173 a presentational role, if set on that Element.
3175 Test: accessibility/global-aria-attributes-invalidate-presentational.html
3177 * accessibility/AccessibilityNodeObject.cpp:
3178 (WebCore::AccessibilityNodeObject::determineAriaRoleAttribute):
3179 * accessibility/AccessibilityObject.cpp:
3180 (WebCore::AccessibilityObject::supportsARIAAttributes):
3182 2013-09-06 Brendan Long <b.long@cablelabs.com>
3184 [Qt][BlackBerry] Text track localized string functions are named wrong
3185 https://bugs.webkit.org/show_bug.cgi?id=120788
3187 Reviewed by Philippe Normand.
3189 This renames textTrackOffText() to textTrackOffMenuItemText(), and
3190 adds textTrackAutomaticMenuItemText(), to make them match the
3191 definitions in LocalizedStrings.h.
3193 * platform/blackberry/LocalizedStringsBlackBerry.cpp:
3194 * platform/qt/LocalizedStringsQt.cpp:
3196 2013-09-06 Allan Sandfeld Jensen <allan.jensen@digia.com>
3198 [Qt][WK2] Cached credentials not cleared between tests
3199 https://bugs.webkit.org/show_bug.cgi?id=120775
3201 Reviewed by Jocelyn Turcotte.
3203 Clear the access credentials when resetting the state of a page for testing.
3205 * testing/Internals.cpp:
3206 (WebCore::Internals::resetToConsistentState):
3208 2013-09-06 Sergio Villar Senin <svillar@igalia.com>
3210 [CSS Grid Layout] Resolve named grid lines
3211 https://bugs.webkit.org/show_bug.cgi?id=119632
3213 Reviewed by Andreas Kling.
3215 From Blink r152659, r153794 by <jchaffraix@chromium.org>
3217 Test: fast/css-grid-layout/grid-item-named-grid-line-resolution.html
3219 This change adds the code which translates from a raw named grid
3220 line (stored in RenderStyle) to its actual grid position. This
3221 even includes named grid resolution for grid lines with the 'span'
3224 * rendering/RenderGrid.cpp:
3225 (WebCore::RenderGrid::explicitGridSizeForSide):
3226 (WebCore::adjustGridPositionForRowEndColumnEndSide):
3227 (WebCore::adjustGridPositionForSide):
3228 (WebCore::RenderGrid::resolveNamedGridLinePositionFromStyle):
3229 (WebCore::RenderGrid::resolveGridPositionFromStyle):
3230 (WebCore::RenderGrid::resolveGridPositionAgainstOppositePosition):
3231 (WebCore::RenderGrid::resolveNamedGridLinePositionAgainstOppositePosition):
3232 (WebCore::RenderGrid::resolveRowStartColumnStartNamedGridLinePositionAgainstOppositePosition):
3233 (WebCore::RenderGrid::resolveRowEndColumnEndNamedGridLinePositionAgainstOppositePosition):
3234 * rendering/RenderGrid.h:
3236 2013-09-06 Dirk Schulze <krit@webkit.org>
3238 Allow string as image reference on filter()
3239 https://bugs.webkit.org/show_bug.cgi?id=120829
3241 Reviewed by Andreas Kling.
3243 Beside <image> (which already includes url(), gradients, cross-fade() and
3244 image-set()), the filter() image function should support <string> as image
3247 http://dev.w3.org/fxtf/filters/#FilterCSSImageValue
3249 * css/CSSParser.cpp:
3250 (WebCore::CSSParser::parseFilterImage): Create CSSImageValue from string.
3252 2013-09-05 Dirk Schulze <krit@webkit.org>
3254 Support SVG filters on -webkit-filter() function
3255 https://bugs.webkit.org/show_bug.cgi?id=120806
3257 Reviewed by Darin Adler.
3259 Add support for SVG Filters on CSS -webkit-filter() image function.
3261 Test: fast/filter-image/filter-image-svg.html
3263 * css/CSSFilterImageValue.cpp:
3264 (WebCore::CSSFilterImageValue::image): Pass renderer to filter builder.
3266 2013-09-05 Yoav Weiss <yoav@yoav.ws>
3268 DRY out srcset related deviceScaleFactor calculations
3269 https://bugs.webkit.org/show_bug.cgi?id=120791
3271 Identical deviceScaleFactor calculations were performed in 3 different locations.
3272 I've added that calculation as a method of Document.
3273 Previous calculations are replaced by calls to this method.
3275 Reviewed by Andreas Kling.
3277 No new tests since this is a refactoring change. No functionality have changed.
3280 (WebCore::Document::deviceScaleFactor):
3282 * html/HTMLImageElement.cpp:
3283 (WebCore::HTMLImageElement::parseAttribute):
3284 * html/parser/HTMLDocumentParser.cpp:
3285 (WebCore::HTMLDocumentParser::pumpTokenizer):
3286 (WebCore::HTMLDocumentParser::insert):
3288 2013-09-05 Brendan Long <b.long@cablelabs.com>
3290 [Qt] DefaultFullScreenVideoHandler and PlatformVideoWindow are included in the build when they are disabled
3291 https://bugs.webkit.org/show_bug.cgi?id=117206
3293 Reviewed by Philippe Normand.
3295 No new tests because this just fixes a build warning.
3297 * Target.pri: Don't include PlatformVideoWindow* files in the build when they are disabled.
3299 2013-09-05 Andreas Kling <akling@apple.com>
3301 FrameView: Constructor should take Frame&.
3302 <https://webkit.org/b/120824>
3304 Reviewed by Anders Carlsson.
3307 * inspector/InspectorOverlay.cpp:
3308 (WebCore::InspectorOverlay::overlayPage):
3310 (WebCore::Frame::createView):
3311 * page/FrameView.cpp:
3312 (WebCore::FrameView::FrameView):
3313 (WebCore::FrameView::create):
3315 * svg/graphics/SVGImage.cpp:
3316 (WebCore::SVGImage::dataChanged):
3318 2013-09-05 Jinwoo Song <jinwoo7.song@samsung.com>
3320 Fix build warnings by unused parameter
3321 https://bugs.webkit.org/show_bug.cgi?id=120821
3323 Reviewed by Anders Carlsson.
3325 Fix warning by removing unused parameter.
3327 * platform/graphics/gstreamer/TextSinkGStreamer.cpp:
3328 (webkitTextSinkGetProperty):
3329 (webkitTextSinkSetProperty):
3330 * platform/network/soup/SynchronousLoaderClientSoup.cpp:
3331 (WebCore::SynchronousLoaderClient::didReceiveAuthenticationChallenge):
3333 2013-09-05 Andreas Kling <akling@apple.com>
3335 FrameLoader: Convert three little loops to using Vector<Ref<Frame>>.
3336 <https://webkit.org/b/120798>
3338 Reviewed by Antti Koivisto.
3340 Also apply a bit of inline capacity + reserveInitialCapacity + uncheckedAppend
3341 in FrameLoader::detachChildren() since we know the final size from the start.
3343 * loader/FrameLoader.cpp:
3344 (WebCore::FrameLoader::detachChildren):
3345 (WebCore::FrameLoader::checkLoadComplete):
3346 (WebCore::FrameLoader::shouldClose):
3348 2013-09-05 Andreas Kling <akling@apple.com>
3350 ContainerNode: Apply Ref<T> to some popular DOM functions.
3351 <https://webkit.org/b/120800>
3353 Reviewed by Antti Koivisto.
3355 Use Ref to avoid a bunch of null checks in some popular DOM functions.
3357 * dom/ContainerNode.cpp:
3358 (WebCore::ContainerNode::insertBefore):
3360 'refChild' is never null here, so store it in a Ref.
3362 (WebCore::ContainerNode::replaceChild):
3364 'removedChild' is never null here, so store it in a Ref.
3366 (WebCore::ContainerNode::removeChild):
3368 'child' is never null here, so store it in a Ref.
3369 Also return "true" at the end of the function since we can't
3370 null-check 'child' anymore (not that it would ever be false!)
3372 (WebCore::dispatchChildInsertionEvents):
3373 (WebCore::dispatchChildRemovalEvents):
3375 Use Ref<Document> in both of these methods.
3377 2013-09-05 Andreas Kling <akling@apple.com>
3379 ScrollView::children() should return a reference.
3380 <https://webkit.org/b/120795>
3382 Reviewed by Anders Carlsson.
3384 This function was already just returning the address of a member variable.
3385 Modernized some loops that were using it.
3387 * bindings/js/PageScriptDebugServer.cpp:
3388 (WebCore::PageScriptDebugServer::setJavaScriptPaused):
3389 * page/FrameView.cpp:
3390 (WebCore::FrameView::hasCustomScrollbars):
3391 (WebCore::FrameView::updateLayoutAndStyleIfNeededRecursive):
3393 (WebCore::Page::pluginViews):
3394 * page/scrolling/ScrollingCoordinator.cpp:
3395 (WebCore::ScrollingCoordinator::computeNonFastScrollableRegion):
3396 * platform/ScrollView.h:
3397 (WebCore::ScrollView::children):
3398 * plugins/IFrameShimSupport.cpp:
3399 (WebCore::getPluginOcclusions):
3401 2013-09-05 Beth Dakin <bdakin@apple.com>
3403 Reverting revisions 155139, 155141, 155142, and 155145 since they appear to have
3404 caused about 50 new test failures.
3407 * GNUmakefile.list.am:
3409 * WebCore.vcxproj/WebCore.vcxproj:
3410 * WebCore.xcodeproj/project.pbxproj:
3411 * accessibility/AccessibilityRenderObject.cpp:
3412 (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
3413 (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
3415 (WebCore::Position::isCandidate):
3416 (WebCore::Position::getInlineBoxAndOffset):
3417 (WebCore::Position::primaryDirection):
3418 * dom/PositionIterator.cpp:
3419 (WebCore::PositionIterator::isCandidate):
3420 * editing/ApplyStyleCommand.cpp:
3421 (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown):
3422 * editing/CompositeEditCommand.cpp:
3423 (WebCore::CompositeEditCommand::addBlockPlaceholderIfNeeded):
3424 * editing/Editor.cpp:
3425 (WebCore::Editor::baseWritingDirectionForSelectionStart):
3426 * editing/FrameSelection.cpp:
3427 (WebCore::caretRenderer):
3428 * editing/TextIterator.cpp:
3429 (WebCore::TextIterator::shouldRepresentNodeOffsetZero):
3430 * editing/TypingCommand.cpp:
3431 (WebCore::TypingCommand::makeEditableRootEmpty):
3432 * editing/htmlediting.cpp:
3433 (WebCore::isBlockFlowElement):
3434 * html/HTMLDetailsElement.cpp:
3435 (WebCore::HTMLDetailsElement::createRenderer):
3436 * html/HTMLSummaryElement.cpp:
3437 (WebCore::HTMLSummaryElement::createRenderer):
3438 * html/shadow/SliderThumbElement.cpp:
3439 (WebCore::RenderSliderThumb::RenderSliderThumb):
3440 * html/shadow/SliderThumbElement.h:
3441 * rendering/LayoutState.cpp:
3442 (WebCore::LayoutState::LayoutState):
3443 * rendering/RenderBlock.cpp:
3444 (WebCore::RenderBlock::createAnonymous):
3445 (WebCore::RenderBlock::layoutBlock):
3446 (WebCore::RenderBlock::collapseMargins):
3447 (WebCore::RenderBlock::selectionGaps):
3448 (WebCore::RenderBlock::firstLineBoxBaseline):
3449 (WebCore::RenderBlock::lastLineBoxBaseline):
3450 (WebCore::RenderBlock::firstLineBlock):
3451 (WebCore::findFirstLetterBlock):
3452 (WebCore::shouldCheckLines):
3453 (WebCore::RenderBlock::adjustForBorderFit):
3454 * rendering/RenderBlock.h:
3455 * rendering/RenderBlockFlow.cpp: Removed.
3456 * rendering/RenderBlockFlow.h: Removed.
3457 * rendering/RenderBox.cpp:
3458 (WebCore::RenderBox::computeRectForRepaint):
3459 (WebCore::RenderBox::positionForPoint):
3460 * rendering/RenderBoxModelObject.h:
3461 (WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion):
3462 * rendering/RenderDeprecatedFlexibleBox.cpp:
3463 (WebCore::RenderDeprecatedFlexibleBox::applyLineClamp):
3464 (WebCore::RenderDeprecatedFlexibleBox::clearLineClamp):
3465 * rendering/RenderDetailsMarker.cpp:
3466 (WebCore::RenderDetailsMarker::RenderDetailsMarker):
3467 * rendering/RenderDetailsMarker.h:
3468 * rendering/RenderFieldset.cpp:
3469 (WebCore::RenderFieldset::RenderFieldset):
3470 * rendering/RenderFieldset.h:
3471 * rendering/RenderFileUploadControl.cpp:
3472 (WebCore::RenderFileUploadControl::RenderFileUploadControl):
3473 * rendering/RenderFileUploadControl.h:
3474 * rendering/RenderFlowThread.cpp:
3475 (WebCore::RenderFlowThread::RenderFlowThread):
3476 * rendering/RenderFlowThread.h:
3477 * rendering/RenderFullScreen.cpp:
3478 * rendering/RenderInline.cpp:
3479 (WebCore::RenderInline::computeRectForRepaint):
3480 * rendering/RenderLineBoxList.cpp:
3481 (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
3482 * rendering/RenderListItem.cpp:
3483 (WebCore::RenderListItem::RenderListItem):
3484 (WebCore::RenderListItem::willBeDestroyed):
3485 (WebCore::RenderListItem::willBeRemovedFromTree):
3486 (WebCore::RenderListItem::layout):
3487 (WebCore::RenderListItem::addOverflowFromChildren):
3488 (WebCore::RenderListItem::computePreferredLogicalWidths):
3489 (WebCore::RenderListItem::paint):
3490 * rendering/RenderListItem.h:
3491 * rendering/RenderMeter.cpp:
3492 (WebCore::RenderMeter::RenderMeter):
3493 * rendering/RenderMeter.h:
3494 * rendering/RenderMultiColumnBlock.cpp:
3495 (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
3496 * rendering/RenderMultiColumnBlock.h:
3497 * rendering/RenderObject.cpp:
3498 (WebCore::RenderObject::createObject):
3499 (WebCore::RenderObject::computeRectForRepaint):
3500 (WebCore::RenderObject::styleWillChange):
3501 (WebCore::firstLineStyleForCachedUncachedType):
3502 * rendering/RenderObject.h:
3503 (WebCore::RenderObject::isBlockFlow):
3504 (WebCore::RenderObject::isRenderBlock):
3505 * rendering/RenderObjectChildList.cpp:
3506 (WebCore::RenderObjectChildList::insertChildNode):
3507 * rendering/RenderProgress.cpp:
3508 (WebCore::RenderProgress::RenderProgress):
3509 * rendering/RenderProgress.h:
3510 * rendering/RenderRegion.cpp:
3511 (WebCore::RenderRegion::RenderRegion):
3512 * rendering/RenderRegion.h:
3513 * rendering/RenderRuby.cpp:
3514 (WebCore::RenderRubyAsBlock::RenderRubyAsBlock):
3515 * rendering/RenderRuby.h:
3516 * rendering/RenderRubyBase.cpp:
3517 (WebCore::RenderRubyBase::RenderRubyBase):
3518 * rendering/RenderRubyBase.h:
3519 * rendering/RenderRubyRun.cpp:
3520 (WebCore::RenderRubyRun::RenderRubyRun):
3521 * rendering/RenderRubyRun.h:
3522 * rendering/RenderRubyText.cpp:
3523 (WebCore::RenderRubyText::RenderRubyText):
3524 * rendering/RenderRubyText.h:
3525 * rendering/RenderTableCaption.cpp:
3526 (WebCore::RenderTableCaption::RenderTableCaption):
3527 * rendering/RenderTableCaption.h:
3528 * rendering/RenderTableCell.cpp:
3529 (WebCore::RenderTableCell::RenderTableCell):
3530 * rendering/RenderTableCell.h:
3531 * rendering/RenderTextControl.cpp:
3532 (WebCore::RenderTextControl::RenderTextControl):
3533 * rendering/RenderTextControl.h:
3534 * rendering/RenderTextControlSingleLine.h:
3535 (WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock):
3536 * rendering/RenderTextTrackCue.cpp:
3537 (WebCore::RenderTextTrackCue::RenderTextTrackCue):
3538 * rendering/RenderTextTrackCue.h:
3539 * rendering/RenderView.cpp:
3540 (WebCore::RenderView::RenderView):
3541 * rendering/RenderView.h:
3542 * rendering/RenderingAllInOne.cpp:
3543 * rendering/mathml/RenderMathMLOperator.cpp:
3544 (WebCore::RenderMathMLOperator::createGlyph):
3545 * rendering/svg/RenderSVGBlock.cpp:
3546 (WebCore::RenderSVGBlock::RenderSVGBlock):
3547 * rendering/svg/RenderSVGBlock.h:
3549 2013-09-05 Alexey Proskuryakov <ap@apple.com>
3551 Flaky Test: platform/mac/editing/deleting/deletionUI-single-instance.html
3552 https://bugs.webkit.org/show_bug.cgi?id=114181
3554 Reviewed by Ryosuke Niwa.
3556 Editor survives navigations, and so did DeleteButtonController. But the state it holds
3557 is document specific (like nodes in the old document).
3559 * editing/Editor.cpp: (WebCore::Editor::clear): Replace DeleteButtonController.
3561 2013-09-05 Gyuyoung Kim <gyuyoung.kim@samsung.com>
3563 Generate toFooElement() functions from tagname data.
3564 https://bugs.webkit.org/show_bug.cgi?id=120676
3566 Reviewed by Andreas Kling.
3568 As r154965 introduced the isFooElement() generation, this patch adds generations of toFooElement() function
3569 to *generateTypeChecking* attribute. To represent isFooElement() and toFooElement(), *generateTypeChecking*
3570 is changed to *generateTypeHelpers*.
3572 Removed all the hand-written toFooElement() that can be covered by the *generateTypeHelpers*.
3575 * GNUmakefile.list.am:
3576 * WebCore.vcxproj/WebCore.vcxproj:
3577 * WebCore.xcodeproj/project.pbxproj:
3578 * dom/make_names.pl:
3579 (defaultTagPropertyHash):
3581 (printTypeHelpersHeaderFile):
3582 * html/HTMLAnchorElement.h:
3583 * html/HTMLAreaElement.h:
3584 * html/HTMLAudioElement.h:
3585 * html/HTMLCanvasElement.h:
3586 * html/HTMLElement.h:
3587 * html/HTMLFormElement.h:
3588 * html/HTMLFrameSetElement.h:
3589 * html/HTMLImageElement.h:
3590 * html/HTMLInputElement.h:
3591 * html/HTMLLabelElement.h:
3592 * html/HTMLMapElement.h:
3593 * html/HTMLMeterElement.h:
3594 * html/HTMLOptGroupElement.h:
3595 * html/HTMLOptionElement.h:
3596 * html/HTMLProgressElement.h:
3597 * html/HTMLScriptElement.h:
3598 * html/HTMLStyleElement.h:
3599 * html/HTMLTableElement.h:
3600 * html/HTMLTableRowElement.h:
3601 * html/HTMLTagNames.in:
3602 * html/HTMLTextAreaElement.h:
3603 * html/HTMLTitleElement.h:
3605 * svg/SVGFontElement.h:
3606 * svg/SVGFontFaceElement.h:
3607 * svg/SVGImageElement.h:
3608 * svg/SVGScriptElement.h:
3611 2013-09-05 Andreas Kling <akling@apple.com>
3613 Cached Page and Frame don't need to be ref-counted.
3614 <https://webkit.org/b/120710>
3616 Reviewed by Anders Carlsson.
3618 - CachedPage is owned by HistoryItem.
3619 - CachedFrame is owned by CachedPage.
3621 Remove the ref counting from these objects to make the code less confusing.
3625 - PassOwnPtr<CachedPage> PageCache::take(HistoryItem*)
3627 ..which is what it looks like - a combined get() and remove() that transfers
3628 ownership of the CachedPage to the caller.
3630 This is used by commitProvisionalLoad() and invalidateCurrentItemCachedPage()
3631 to accomplish in one swoop what they used to do in awkwardly spaced steps.
3633 * history/CachedFrame.h:
3634 (WebCore::CachedFrame::create):
3635 * history/CachedPage.cpp:
3636 (WebCore::CachedPage::create):
3637 * history/CachedPage.h:
3638 * history/HistoryItem.h:
3639 * history/PageCache.cpp:
3640 (WebCore::PageCache::take):
3641 * history/PageCache.h:
3642 * loader/FrameLoader.cpp:
3643 (WebCore::FrameLoader::commitProvisionalLoad):
3644 (WebCore::FrameLoader::transitionToCommitted):
3645 * loader/FrameLoader.h:
3646 * loader/HistoryController.cpp:
3647 (WebCore::HistoryController::invalidateCurrentItemCachedPage):
3649 2013-09-05 David Kilzer <ddkilzer@apple.com>
3651 BUILD FIX (r155108): Add SynchronousLoaderClientCFNet.cpp to Xcode project
3653 * WebCore.xcodeproj/project.pbxproj: The iOS port defines
3654 USE(CFNETWORK), so it needs to compile
3655 SynchronousLoaderClientCFNet.cpp to build successfully.
3657 2013-09-05 Anders Carlsson <andersca@apple.com>
3659 GCAssertions.h should use STL type traits and static_assert
3660 https://bugs.webkit.org/show_bug.cgi?id=120785
3662 Reviewed by Andreas Kling.
3664 Update for JavaScriptCore changes.
3666 * bindings/js/JSDOMBinding.cpp:
3667 * bindings/js/JSImageConstructor.cpp:
3669 2013-09-05 David Hyatt <hyatt@apple.com>
3671 Make RenderListItem inherit from RenderBlockFlow.
3672 https://bugs.webkit.org/show_bug.cgi?id=120789
3674 Reviewed by Beth Dakin.
3676 * rendering/RenderListItem.cpp:
3677 (WebCore::RenderListItem::RenderListItem):
3678 (WebCore::RenderListItem::willBeDestroyed):
3679 (WebCore::RenderListItem::willBeRemovedFromTree):
3680 (WebCore::RenderListItem::layout):
3681 (WebCore::RenderListItem::addOverflowFromChildren):
3682 (WebCore::RenderListItem::computePreferredLogicalWidths):
3683 (WebCore::RenderListItem::paint):
3684 * rendering/RenderListItem.h:
3686 2013-09-05 David Hyatt <hyatt@apple.com>
3688 Make RenderBlock have a protected constructor..
3689 https://bugs.webkit.org/show_bug.cgi?id=120787
3691 Reviewed by Beth Dakin.
3693 Make sure nobody can create a RenderBlock directly. Make sure RenderBlockFlows
3694 get made when a display:block/inline-block/compact/run-in is seen.
3696 * html/HTMLDetailsElement.cpp:
3697 (WebCore::HTMLDetailsElement::createRenderer):
3698 * html/HTMLSummaryElement.cpp:
3699 (WebCore::HTMLSummaryElement::createRenderer):
3700 * rendering/RenderBlock.cpp:
3701 (WebCore::RenderBlock::createAnonymous):
3702 * rendering/RenderBlock.h:
3703 * rendering/RenderObject.cpp:
3704 (WebCore::RenderObject::createObject):
3706 2013-09-05 David Hyatt <hyatt@apple.com>
3708 Add new RenderBlockFlow class
3709 https://bugs.webkit.org/show_bug.cgi?id=120777
3711 Reviewed by Simon Fraser.
3713 This patch adds a new RenderBlockFlow class. The idea is to get all of the line/float/margin
3714 code out of RenderBlock and into the subclass, and then we can make RenderBlock an abstract
3715 base. This will save memory for all of the classes that derive from RenderBlock but have
3716 their own layout systems (e.g., flexbox, grid, table), and it will let us tighten up
3717 types to make it more clear when we're talking about block layout code vs. a more generic
3718 block-level object that can have any kind of layout.
3720 The only real change here is that isBlockFlow() has been renamed to isRenderBlockFlow() and
3721 is now checking if the object is a RenderBlockFlow. All of the block subclasses have been patched
3722 to be a RenderBlock or RenderBlockFlow.
3725 * GNUmakefile.list.am:
3727 * WebCore.vcxproj/WebCore.vcxproj:
3728 * WebCore.xcodeproj/project.pbxproj:
3729 * accessibility/AccessibilityRenderObject.cpp:
3730 (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
3731 (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
3733 (WebCore::Position::isCandidate):
3734 (WebCore::Position::getInlineBoxAndOffset):
3735 (WebCore::Position::primaryDirection):
3736 * dom/PositionIterator.cpp:
3737 (WebCore::PositionIterator::isCandidate):
3738 * editing/ApplyStyleCommand.cpp:
3739 (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown):
3740 * editing/CompositeEditCommand.cpp:
3741 (WebCore::CompositeEditCommand::addBlockPlaceholderIfNeeded):
3742 * editing/Editor.cpp:
3743 (WebCore::Editor::baseWritingDirectionForSelectionStart):
3744 * editing/FrameSelection.cpp:
3745 (WebCore::caretRenderer):
3746 * editing/TextIterator.cpp:
3747 (WebCore::TextIterator::shouldRepresentNodeOffsetZero):
3748 * editing/TypingCommand.cpp:
3749 (WebCore::TypingCommand::makeEditableRootEmpty):
3750 * editing/htmlediting.cpp:
3751 (WebCore::isBlockFlowElement):
3752 * html/shadow/SliderThumbElement.cpp:
3753 (WebCore::RenderSliderThumb::RenderSliderThumb):
3754 * html/shadow/SliderThumbElement.h:
3755 * rendering/LayoutState.cpp:
3756 (WebCore::LayoutState::LayoutState):
3757 * rendering/RenderBlock.cpp:
3758 (WebCore::RenderBlock::layoutBlock):
3759 (WebCore::RenderBlock::collapseMargins):
3760 (WebCore::RenderBlock::selectionGaps):
3761 (WebCore::RenderBlock::firstLineBoxBaseline):
3762 (WebCore::RenderBlock::lastLineBoxBaseline):
3763 (WebCore::RenderBlock::firstLineBlock):
3764 (WebCore::findFirstLetterBlock):
3765 (WebCore::shouldCheckLines):
3766 (WebCore::RenderBlock::adjustForBorderFit):
3767 * rendering/RenderBlock.h:
3768 * rendering/RenderBlockFlow.cpp: Added.
3769 (WebCore::RenderBlockFlow::RenderBlockFlow):
3770 (WebCore::RenderBlockFlow::~RenderBlockFlow):
3771 * rendering/RenderBlockFlow.h: Added.
3772 (WebCore::toRenderBlockFlow):
3773 * rendering/RenderBox.cpp:
3774 (WebCore::RenderBox::computeRectForRepaint):
3775 (WebCore::RenderBox::positionForPoint):
3776 * rendering/RenderBoxModelObject.h:
3777 (WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion):
3778 * rendering/RenderDeprecatedFlexibleBox.cpp:
3779 (WebCore::RenderDeprecatedFlexibleBox::applyLineClamp):
3780 (WebCore::RenderDeprecatedFlexibleBox::clearLineClamp):
3781 * rendering/RenderDetailsMarker.cpp:
3782 (WebCore::RenderDetailsMarker::RenderDetailsMarker):
3783 * rendering/RenderDetailsMarker.h:
3784 * rendering/RenderFieldset.cpp:
3785 (WebCore::RenderFieldset::RenderFieldset):
3786 * rendering/RenderFieldset.h:
3787 * rendering/RenderFileUploadControl.cpp:
3788 (WebCore::RenderFileUploadControl::RenderFileUploadControl):
3789 * rendering/RenderFileUploadControl.h:
3790 * rendering/RenderFlowThread.cpp:
3791 (WebCore::RenderFlowThread::RenderFlowThread):
3792 * rendering/RenderFlowThread.h:
3793 * rendering/RenderFullScreen.cpp:
3794 * rendering/RenderInline.cpp:
3795 (WebCore::RenderInline::computeRectForRepaint):
3796 * rendering/RenderLineBoxList.cpp:
3797 (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
3798 * rendering/RenderMeter.cpp:
3799 (WebCore::RenderMeter::RenderMeter):
3800 * rendering/RenderMeter.h:
3801 * rendering/RenderMultiColumnBlock.cpp:
3802 (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
3803 * rendering/RenderMultiColumnBlock.h:
3804 * rendering/RenderObject.cpp:
3805 (WebCore::RenderObject::computeRectForRepaint):
3806 (WebCore::RenderObject::styleWillChange):
3807 (WebCore::firstLineStyleForCachedUncachedType):
3808 * rendering/RenderObject.h:
3809 (WebCore::RenderObject::isBR):
3810 (WebCore::RenderObject::isRenderBlockFlow):
3811 * rendering/RenderObjectChildList.cpp:
3812 (WebCore::RenderObjectChildList::insertChildNode):
3813 * rendering/RenderProgress.cpp:
3814 (WebCore::RenderProgress::RenderProgress):
3815 * rendering/RenderProgress.h:
3816 * rendering/RenderRegion.cpp:
3817 (WebCore::RenderRegion::RenderRegion):
3818 * rendering/RenderRegion.h:
3819 * rendering/RenderRuby.cpp:
3820 (WebCore::RenderRubyAsBlock::RenderRubyAsBlock):
3821 * rendering/RenderRuby.h:
3822 * rendering/RenderRubyBase.cpp:
3823 (WebCore::RenderRubyBase::RenderRubyBase):
3824 * rendering/RenderRubyBase.h:
3825 * rendering/RenderRubyRun.cpp:
3826 (WebCore::RenderRubyRun::RenderRubyRun):
3827 * rendering/RenderRubyRun.h:
3828 * rendering/RenderRubyText.cpp:
3829 (WebCore::RenderRubyText::RenderRubyText):
3830 * rendering/RenderRubyText.h:
3831 * rendering/RenderTableCaption.cpp:
3832 (WebCore::RenderTableCaption::RenderTableCaption):
3833 * rendering/RenderTableCaption.h:
3834 * rendering/RenderTableCell.cpp:
3835 (WebCore::RenderTableCell::RenderTableCell):
3836 * rendering/RenderTableCell.h:
3837 * rendering/RenderTextControl.cpp:
3838 (WebCore::RenderTextControl::RenderTextControl):
3839 * rendering/RenderTextControl.h:
3840 * rendering/RenderTextControlSingleLine.h:
3841 (WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock):
3842 * rendering/RenderTextTrackCue.cpp:
3843 (WebCore::RenderTextTrackCue::RenderTextTrackCue):
3844 * rendering/RenderTextTrackCue.h:
3845 * rendering/RenderView.cpp:
3846 (WebCore::RenderView::RenderView):
3847 * rendering/RenderView.h:
3848 * rendering/svg/RenderSVGBlock.cpp:
3849 (WebCore::RenderSVGBlock::RenderSVGBlock):
3850 * rendering/svg/RenderSVGBlock.h:
3852 2013-09-05 Tim Horton <timothy_horton@apple.com>
3854 iOS build broke with change to make Mac use PDFKit for PDFDocumentImage
3855 https://bugs.webkit.org/show_bug.cgi?id=120771
3857 Reviewed by Anders Carlsson.
3859 * platform/graphics/cg/PDFDocumentImage.cpp:
3860 (WebCore::PDFDocumentImage::createPDFDocument):
3861 Use the (removed in r155069) PLATFORM(MAC) way of making a CGDataProvider from a SharedBuffer
3862 everywhere; this is what iOS was expecting to use (where I accidentally changed behavior),
3863 and it should also work for Windows, the only other USE(CG) platform.
3865 Since we only createPDFDocument() after all data has been received, I'm not
3866 restoring the comment about the SharedBuffer being secretly written to behind its back.
3868 2013-09-04 Dean Jackson <dino@apple.com>
3870 Rename supportsContext to probablySupportsContext
3871 https://bugs.webkit.org/show_bug.cgi?id=120716
3872 <rdar://problem/14914499>
3874 Reviewed by Antoine Quint.
3876 As decided in: http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2013-September/040680.html
3878 * bindings/js/JSHTMLCanvasElementCustom.cpp:
3879 (WebCore::JSHTMLCanvasElement::probablySupportsContext):
3880 * html/HTMLCanvasElement.cpp:
3881 (WebCore::HTMLCanvasElement::probablySupportsContext):
3882 * html/HTMLCanvasElement.h:
3883 * html/HTMLCanvasElement.idl:
3885 2013-09-05 Joseph Pecoraro <pecoraro@apple.com>
3887 Fix build warning about unused variable.
3889 Unreviewed build fix.
3891 * bindings/js/ScriptDebugServer.cpp:
3892 (WebCore::ScriptDebugServer::evaluateBreakpointAction):
3894 2013-09-05 Anders Carlsson <andersca@apple.com>
3896 Enable C++11 wherever we build C++ files that include wtf/Platform.h
3897 https://bugs.webkit.org/show_bug.cgi?id=120782
3899 Reviewed by Andreas Kling.
3901 Pass -std=gnu++11 when preprocessing wtf/Platform.h.
3903 * DerivedSources.make:
3905 2013-09-05 Joseph Pecoraro <pecoraro@apple.com>
3907 Web Inspector: Breakpoint Actions
3908 https://bugs.webkit.org/show_bug.cgi?id=120576
3910 Reviewed by Timothy Hatcher.
3912 Tests: inspector-protocol/debugger/setBreakpoint-actions.html
3913 inspector-protocol/debugger/setBreakpoint-options-exception.html
3915 * inspector/ScriptBreakpoint.h:
3916 (WebCore::ScriptBreakpointAction::ScriptBreakpointAction):
3917 (WebCore::ScriptBreakpoint::ScriptBreakpoint):
3918 Struct for a breakpoint action. Type and string of data.
3920 * bindings/js/ScriptDebugServer.h:
3921 * bindings/js/ScriptDebugServer.cpp:
3922 (WebCore::ScriptDebugServer::hasBreakpoint):
3923 (WebCore::ScriptDebugServer::evaluateBreakpointAction):
3924 (WebCore::ScriptDebugServer::evaluateBreakpointActions):
3925 (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
3926 (WebCore::ScriptDebugServer::pauseIfNeeded):
3927 When a breakpoint is triggered evaluate each of its breakpoint
3928 actions in order. If there are exceptions, log them.
3930 * inspector/Inspector.json:
3931 * inspector/InspectorDebuggerAgent.cpp:
3932 (WebCore::buildObjectForBreakpointCookie):
3933 (WebCore::InspectorDebuggerAgent::didParseSource):
3934 Save and restore breakpoint actions where needed.
3936 (WebCore::breakpointActionTypeForString):
3937 (WebCore::breakpointActionsFromProtocol):
3938 (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
3939 (WebCore::InspectorDebuggerAgent::setBreakpoint):
3940 Parse optional breakpoint actions from the protocol into
3941 ScriptBreakpointAction objects.
3943 2013-09-05 Simon Fraser <simon.fraser@apple.com>
3945 Fix repaint issue on "paints into ancestor" filtered layers
3946 https://bugs.webkit.org/show_bug.cgi?id=120780
3948 Reviewed by Tim Horton.
3950 When a repaint happened on a layer with a filter, and which paints into
3951 its compositing ancestor, we'd repaint the wrong layer (and assert).
3953 Fix by ensuring that RenderLayer::enclosingFilterLayer() takes paintsIntoCompositedAncestor()
3954 into account, by adding a function that we share between three callers who
3955 check isComposited() && !paintsIntoCompositedAncestor(). I didn't use a function
3956 on RenderLayer, because I wanted it to be inline but to not #include RenderLayerBacking
3959 Test: compositing/filters/opacity-change-on-filtered-paints-into-ancestor.html
3961 * dom/Node.cpp: Drive-by removal of #include "RenderLayer.h"
3962 * rendering/RenderLayer.cpp:
3963 (WebCore::compositedWithOwnBackingStore):
3964 (WebCore::RenderLayer::enclosingCompositingLayerForRepaint):
3965 (WebCore::RenderLayer::enclosingFilterRepaintLayer):
3966 (WebCore::RenderLayer::clippingRootForPainting):
3968 2013-09-05 Brent Fulgham <bfulgham@apple.com>
3970 [Windows] Unreviewed build/link improvement after r155127 to be
3971 consistent about using debug-build support libraries.
3973 Now that <rdar://problem/9898937> is resolved, we should be linking
3974 to debug AVFoundationCF as well.
3976 * page/CaptionUserPreferencesMediaAF.cpp: Link to AVFoundationCF_debug
3977 when building with the DEBUG_ALL target.
3978 * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp: Ditto.
3979 * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h: Ditto.
3981 2013-09-04 Anders Carlsson <andersca@apple.com>
3983 Vector::releaseBuffer should return an OwnPtr
3984 https://bugs.webkit.org/show_bug.cgi?id=120718
3986 Reviewed by Andreas Kling.
3988 Change FormStreamFields::currentData to an OwnPtr.
3990 * platform/network/cf/FormDataStreamCFNet.cpp:
3991 (WebCore::closeCurrentStream):
3992 (WebCore::advanceCurrentStream):
3993 (WebCore::formCreate):
3995 2013-09-05 Andreas Kling <akling@apple.com>
3997 Reverting "Cached Page and Frame don't need to be ref-counted.
3998 <https://webkit.org/b/120758>
4000 This didn't work so well on Qt bots. Will have to take bigger steps
4001 here instead of iterating.
4003 * history/CachedFrame.h:
4004 (WebCore::CachedFrame::create):
4005 * history/CachedPage.cpp:
4006 (WebCore::CachedPage::create):
4007 * history/CachedPage.h:
4008 * history/HistoryItem.h:
4009 * loader/FrameLoader.cpp:
4010 (WebCore::FrameLoader::commitProvisionalLoad):
4011 (WebCore::FrameLoader::transitionToCommitted):
4012 * loader/FrameLoader.h:
4014 2013-09-04 Anders Carlsson <andersca@apple.com>
4016 Animations in an AnimationList are never null
4017 https://bugs.webkit.org/show_bug.cgi?id=120720
4019 Reviewed by Andreas Kling.
4021 Change AnimationList::operator[] to return an Animation& and fix up related code to also take references.
4023 * css/CSSComputedStyleDeclaration.cpp:
4024 * css/DeprecatedStyleBuilder.cpp:
4025 * page/animation/CompositeAnimation.cpp:
4026 * page/animation/KeyframeAnimation.cpp:
4027 * platform/animation/Animation.h:
4028 * platform/animation/AnimationList.cpp:
4029 * platform/animation/AnimationList.h:
4030 * rendering/RenderLayerBacking.cpp:
4032 2013-09-05 Antti Koivisto <antti@apple.com>
4034 Call createTextRenderersForSiblingsAfterAttachIfNeeded only for the attach root
4035 https://bugs.webkit.org/show_bug.cgi?id=120770
4037 Reviewed by Andreas Kling.
4039 There is no need to call this during recursive attach as siblings are going to be attached normally anyway.
4040 Move call sites to attach roots only.
4042 * style/StyleResolveTree.cpp:
4043 (WebCore::Style::createTextRenderersForSiblingsAfterAttachIfNeeded):
4045 Factor to take reference and do the inital tests itself.
4047 (WebCore::Style::createTextRendererIfNeeded):
4048 (WebCore::Style::updateTextRendererAfterContentChange):
4049 (WebCore::Style::attachChildren):
4051 Also tightened the condition where previously attached children may be encountered.
4053 (WebCore::Style::attachRenderTree):
4054 (WebCore::Style::resolveLocal):
4055 (WebCore::Style::updateTextStyle):
4056 (WebCore::Style::reattachRenderTree):
4058 2013-09-05 Enrique Ocaña González <eocanha@igalia.com>
4060 [GTK] Assertion fails when the mouse pointer is styled with a custom cursor
4061 https://bugs.webkit.org/show_bug.cgi?id=118905
4063 Reviewed by Philippe Normand.
4065 Checked that the custom cursor image and its pixbuf is valid and create a null
4068 * platform/gtk/CursorGtk.cpp:
4069 (WebCore::createCustomCursor):
4071 2013-09-05 Praveen R Jadhav <praveen.j@samsung.com>
4073 Precision updates in WebAudio.
4074 https://bugs.webkit.org/show_bug.cgi?id=119739
4076 Reviewed by Philippe Normand.
4078 WebAudio Specification suggests to use 'double' datatypes
4079 for minDecibels, maxDecibels and smoothingTimeConstant in
4080 AnalyserNode.idl and currentTime in AudioContext.idl.
4081 Current WebKit implementation has declared these attributes
4084 Spec: https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html#AudioContext-section
4085 https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html#AnalyserNode