1 2013-05-20 Zan Dobersek <zdobersek@igalia.com>
3 [GTK] Fix concatenations of string literals that are not C++11-compliant
4 https://bugs.webkit.org/show_bug.cgi?id=116449
6 Reviewed by Martin Robinson.
8 Fix the problematic concatenations of string literals so they are compilable under the C++11 standard. This
9 is simply a matter of separating the string and the string literal that are being concatenated with a space.
11 * platform/graphics/gtk/FullscreenVideoControllerGtk.cpp:
12 * platform/gtk/FileSystemGtk.cpp:
13 (WebCore::sharedResourcesPath):
15 2013-05-20 Zan Dobersek <zdobersek@igalia.com>
17 [GTK] Support application/x-mimearchive mimetype for MHTML archives instead of message/rfc822
18 https://bugs.webkit.org/show_bug.cgi?id=116442
20 Reviewed by Martin Robinson.
22 * loader/archive/ArchiveFactory.cpp:
23 (WebCore::archiveMIMETypes): Like EFL and Qt, register the application/x-mimearchive mime type as a MHTML archive type
24 and stop propagating the message/rfc822 mime type as such. This also removes a couple of PLATFORM ifdefs.
26 2013-05-20 Benjamin Poulain <bpoulain@apple.com>
28 Minor String fixes in CSS
29 https://bugs.webkit.org/show_bug.cgi?id=116291
31 Reviewed by Darin Adler.
33 Some trival changes to make up for a bad day :)
35 * css/CSSImageSetValue.cpp:
36 (WebCore::CSSImageSetValue::customCssText):
37 * css/CSSImageValue.cpp:
38 (WebCore::CSSImageValue::customCssText):
39 * css/CSSImportRule.cpp:
40 (WebCore::CSSImportRule::cssText):
41 * css/CSSInheritedValue.cpp:
42 (WebCore::CSSInheritedValue::customCssText):
43 * css/CSSInitialValue.cpp:
44 (WebCore::CSSInitialValue::customCssText):
45 * css/CSSPrimitiveValue.cpp:
46 (WebCore::CSSPrimitiveValue::customCssText):
47 * css/CSSPropertySourceData.cpp:
48 (WebCore::CSSPropertySourceData::toString):
49 * css/CSSSelector.cpp:
50 (WebCore::CSSSelector::selectorText):
51 * css/CSSStyleRule.cpp:
52 (WebCore::CSSStyleRule::generateSelectorText):
53 * css/CSSStyleSheet.h:
54 (WebCore::CSSStyleSheet::type):
55 * css/CSSTimingFunctionValue.cpp:
56 (WebCore::CSSLinearTimingFunctionValue::customCssText):
57 (WebCore::CSSCubicBezierTimingFunctionValue::customCssText):
58 * css/CSSValueList.cpp:
59 (WebCore::CSSValueList::customCssText):
60 (WebCore::CSSValueList::customSerializeResolvingVariables):
61 * css/MediaQueryExp.cpp:
62 (WebCore::MediaQueryExp::serialize):
63 * css/WebKitCSSFilterValue.cpp:
64 (WebCore::WebKitCSSFilterValue::customCssText):
65 * css/WebKitCSSKeyframesRule.cpp:
66 (WebCore::StyleRuleKeyframes::findKeyframeIndex):
67 (WebCore::WebKitCSSKeyframesRule::cssText):
68 * css/WebKitCSSMatFunctionValue.cpp:
69 (WebCore::WebKitCSSMatFunctionValue::customCssText):
70 * css/WebKitCSSMixFunctionValue.cpp:
71 (WebCore::WebKitCSSMixFunctionValue::customCssText):
73 2013-05-20 Ryosuke Niwa <rniwa@webkit.org>
75 Null pointer deference in WebCore::AppendNodeCommand::create
76 https://bugs.webkit.org/show_bug.cgi?id=116479
78 Reviewed by Andreas Kling.
80 Merge https://chromium.googlesource.com/chromium/blink/+/5cb43002a44f67a60ecf5a7ed76de2d0bcf89eb2
82 DeleteSelection::makeStylingElementsDirectChildrenOfEditableRootToPreventStyleLoss() make style and link elements
83 to be the direct children of the editable root. However, these style and link elements are not necessary editable
84 and WebKit crashes when they are not.
86 Test: editing/deleting/delete-uneditable-style.html
88 * editing/DeleteSelectionCommand.cpp:
89 (WebCore::DeleteSelectionCommand::makeStylingElementsDirectChildrenOfEditableRootToPreventStyleLoss):
91 2013-05-20 Beth Dakin <bdakin@apple.com>
93 Scrollbars still show sometimes even when WKPageSetSuppressScrollbarAnimations()
95 https://bugs.webkit.org/show_bug.cgi?id=116493
97 <rdar://problem/13912871>
99 Reviewed by Dean Jackson.
101 We need to be more aggressive with our approach since AppKit may still ask the
102 scrollbars to paint here.
104 scrollbarAnimationsAreSuppressed() will allow us to find out if the setting has
106 * page/FrameView.cpp:
107 (WebCore::FrameView::scrollbarAnimationsAreSuppressed):
109 * platform/ScrollableArea.h:
110 (WebCore::ScrollableArea::scrollbarAnimationsAreSuppressed):
111 * rendering/RenderLayer.cpp:
112 (WebCore::RenderLayer::scrollbarAnimationsAreSuppressed):
113 * rendering/RenderLayer.h:
115 * rendering/RenderListBox.cpp:
116 (WebCore::RenderListBox::scrollbarAnimationsAreSuppressed):
117 * rendering/RenderListBox.h:
119 Don’t allow animations if scrollbars are suppressed.
120 * platform/mac/ScrollAnimatorMac.mm:
121 (-[WebScrollbarPainterDelegate scrollerImp:animateKnobAlphaTo:duration:]):
123 Call cancelAnimations() to prevent a just-started animation from continuing.
124 (WebCore::ScrollAnimatorMac::finishCurrentScrollAnimations):
126 2013-05-20 Andreas Kling <akling@apple.com>
128 Avoid caret repaints if we're not showing carets anyway.
129 <http://webkit.org/b/116489>
131 Reviewed by Simon Fraser.
133 When moving the selection, check if we're inside a contenteditable element (or in caret browsing mode)
134 before repainting the caret's previous location.
136 * editing/FrameSelection.cpp:
137 (WebCore::FrameSelection::recomputeCaretRect):
139 2013-05-20 Simon Fraser <simon.fraser@apple.com>
141 position:sticky should stick for the enclosing overflow ancestor
142 https://bugs.webkit.org/show_bug.cgi?id=100054
144 Reviewed by Beth Dakin.
146 Make position: -webkit-sticky be constrained by an enclosing ancestor
147 with non-visible overflow if there is one, rather than being constained
148 always by the viewport.
150 Test: fast/css/sticky/sticky-top-overflow.html
152 * rendering/RenderBoxModelObject.cpp:
153 (WebCore::RenderBoxModelObject::computeStickyPositionConstraints): Rename
154 viewportRect to constrainingRect, since it isn't just about the viewport any more.
155 Fix an issue where just adding stickyLocation to absContainerFrame.location() was
156 incorrect when the container is scrolled; we also have to take the scroll offset
157 into account, and that offset is stored in the layer tree.
158 (WebCore::RenderBoxModelObject::stickyPositionOffset):
159 Look for an enclosing layer with overflow clipping, and, if found, use it to
160 compute the sticky constraint rect.
161 * rendering/RenderLayer.h: Add a helpful IncludeSelfOrNot, and fix several member functions
162 to use it place of hard-to-read boolean arguments.
163 Add enclosingOverflowClipLayer(IncludeSelfOrNot).
164 (WebCore::RenderLayer::ancestorCompositingLayer):
165 * rendering/RenderLayer.cpp:
166 (WebCore::RenderLayer::enclosingOverflowClipLayer): New function, finds the enclosing
167 layer with overflow clip.
168 (WebCore::RenderLayer::enclosingCompositingLayer): Use IncludeSelfOrNot.
169 (WebCore::RenderLayer::enclosingCompositingLayerForRepaint): Ditto.
170 (WebCore::RenderLayer::enclosingFilterLayer): Ditto.
171 * rendering/RenderLayerCompositor.cpp:
172 (WebCore::RenderLayerCompositor::repaintInCompositedAncestor): Use IncludeSelfOrNot.
173 (WebCore::isViewportConstrainedFixedOrStickyLayer): Renamed from isRootmostFixedOrStickyLayer
174 and moved up so we can use it in requiresCompositingForPosition().
175 (WebCore::RenderLayerCompositor::requiresCompositingForPosition): Only make sticky composited if
176 it's viewport-constrained.
177 (WebCore::RenderLayerCompositor::updateViewportConstraintStatus):
178 (WebCore::RenderLayerCompositor::computeStickyViewportConstraints): Declare StickyPositionViewportConstraints
179 one line down to just before it gets used.
181 2013-05-20 Jeff Rogers <jrogers@blackberry.com>
183 Remove DISABLE_ROUNDED_CORNER_CLIPPING
184 https://bugs.webkit.org/show_bug.cgi?id=115531
186 Reviewed by Andreas Kling.
188 BlackBerry port is no longer using this.
190 * rendering/RenderLayer.cpp:
191 (WebCore::inContainingBlockChain):
192 (WebCore::RenderLayer::clipToRect):
194 2013-05-20 Tim Horton <timothy_horton@apple.com>
196 Clients should have a way to extend rendering suppression
197 https://bugs.webkit.org/show_bug.cgi?id=116463
198 <rdar://problem/13738496>
200 Reviewed by Andy Estes.
203 Export FrameView::setVisualUpdatesAllowedByClient.
206 (WebCore::Document::setVisualUpdatesAllowed):
207 Move rendering-suppression watchdog into setVisualUpdatesAllowed(bool).
208 setVisualUpdatesAllowed(ReadyState) should not re-enable visual updates
209 if the client is itself disabling visual updates.
211 (WebCore::Document::visualUpdatesSuppressionTimerFired):
212 If the watchdog fires and the client is still disabling visual
213 updates, we should not re-enable visual updates, but instead
216 (WebCore::Document::setVisualUpdatesAllowedByClient):
217 Actually re-enable visual updates if we deferred the re-enabling above
218 (when the page finishes loading, but the client had them disabled).
221 (Document): Add setVisualUpdatesAllowedByClient.
222 * page/FrameView.cpp:
223 (WebCore::FrameView::FrameView): Visual updates are allowed by default.
224 (WebCore::FrameView::setVisualUpdatesAllowedByClient):
225 Forward through to the document, but we also need to persist the state
226 here in FrameView so that it survives through navigation.
229 (WebCore::FrameView::setVisualUpdatesAllowedByClient): Added.
230 (WebCore::FrameView::visualUpdatesAllowedByClient): Added.
231 Added storage for m_visualUpdatesAllowedByClient.
233 2013-05-20 Hans Muller <hmuller@adobe.com>
235 [CSS Exclusions] Add CSS parsing support for image URI shape-inside and shape-outside values
236 https://bugs.webkit.org/show_bug.cgi?id=116349
238 Reviewed by Alexandru Chiculita.
240 Add support for parsing image URI values for the shape-inside and shape-outside CSS properties.
241 Extended the ExclusionShapeValue class to support tracking the property's StyleImage value.
243 The ExclusionShapeValue::type enums were changed from all upper case to "Intercase" by order
246 The existing CSS parsing tests were extended to check URI values.
248 * css/CSSComputedStyleDeclaration.cpp:
249 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
251 (WebCore::CSSParser::parseValue):
252 * css/DeprecatedStyleBuilder.cpp:
253 (WebCore::ApplyPropertyExclusionShape::applyValue):
254 * css/StyleResolver.cpp:
255 (WebCore::StyleResolver::loadPendingImages):
256 * rendering/style/ExclusionShapeValue.h:
257 (WebCore::ExclusionShapeValue::createImageValue):
258 (ExclusionShapeValue):
259 (WebCore::ExclusionShapeValue::image):
260 (WebCore::ExclusionShapeValue::setImage):
261 (WebCore::ExclusionShapeValue::ExclusionShapeValue):
263 2013-05-20 Radu Stavila <stavila@adobe.com>
265 [CSSRegions] Fix offsetLeft / offsetTop for elements inside named flow
266 https://bugs.webkit.org/show_bug.cgi?id=115899
268 Reviewed by David Hyatt.
270 Elements in named flows that have the body as their offsetParent, need to compute their
271 offsetLeft and offsetTop values relative to the body.
273 Tests: fast/regions/offsetLeft-offsetTop-in-multiple-regions.html
274 fast/regions/offsetLeft-offsetTop-in-region-absolute-sticky-fixed.html
275 fast/regions/offsetLeft-offsetTop-in-region-float-vert-rl.html
276 fast/regions/offsetLeft-offsetTop-in-region-float.html
277 fast/regions/offsetLeft-offsetTop-inlines-region-in-element.html
279 * rendering/RenderBoxModelObject.cpp:
280 (WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
281 * rendering/RenderFlowThread.cpp:
283 (WebCore::RenderFlowThread::adjustedPositionRelativeToOffsetParent):
284 * rendering/RenderFlowThread.h:
286 2013-05-20 Zoltan Horvath <zoltan@webkit.org>
288 [CSS Regions][CSS Exclusions] shape-inside on regions should respect positioned shapes and overflow
289 https://bugs.webkit.org/show_bug.cgi?id=116252
291 Reviewed by David Hyatt.
293 Regions should respect shape-inside properties which have specified top offset. Since the content which overflows from the
294 shape should be pushed after the content box (for details check out r148975), I implemented overflowthe behavior for simple
295 cases when you have only one region. I'm going to implement it for additional regions in a follow up patch.
297 Tests: fast/regions/shape-inside/shape-inside-on-regions-block-content-basic-overflow-shape-top-offset.html
298 fast/regions/shape-inside/shape-inside-on-regions-inline-content-basic-overflow-shape-top-offset.html
300 * rendering/RenderBlockLineLayout.cpp:
301 (WebCore::RenderBlock::updateLineBoundariesForExclusions): Handle the flow thread case, push the overflowing content after the
302 content box. Respect existing shape-inside on region tests.
303 (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Set the correct logical top position for the shape-inside in
304 the case of regions. Respect the region's margins and paddings.
306 2013-05-20 Darin Adler <darin@apple.com>
308 Remove custom binding for the Clipboard clearData function
309 https://bugs.webkit.org/show_bug.cgi?id=116421
311 Reviewed by Andreas Kling.
313 * bindings/js/JSClipboardCustom.cpp: Removed the clearData binding.
315 * dom/Clipboard.idl: Removed [Custom].
318 (WebCore::Clipboard::clearData): Renamed from clearAllData.
319 * dom/Clipboard.h: Rename clearAllData to clearData so we just use
320 overloading for the one with and without a MIME type.
321 * platform/ios/ClipboardIOS.h: Rename clearAllData to clearData.
322 * platform/ios/ClipboardIOS.mm:
323 (WebCore::ClipboardIOS::clearData): Ditto.
324 * platform/qt/ClipboardQt.cpp:
325 (WebCore::ClipboardQt::clearData). Ditto.
326 * platform/qt/ClipboardQt.h: Ditto.
327 * platform/win/ClipboardWin.cpp:
328 (WebCore::ClipboardWin::clearData): Ditto.
329 * platform/win/ClipboardWin.h: Ditto.
331 2013-05-20 Eric Carlson <eric.carlson@apple.com>
333 [iOS] media/event-queue-crash.html ASSERTs in notifyChildInserted
334 https://bugs.webkit.org/show_bug.cgi?id=116444
336 Reviewed by Jer Noble.
338 No new tests, covered by existing tests.
340 * html/HTMLMediaElement.cpp:
341 (WebCore::HTMLMediaElement::configureMediaControls): Only create media controls when the
342 element is in a Document.
344 2013-05-20 Antoine Quint <graouts@apple.com>
346 [Mac] captions menu should behave more like a menu
347 https://bugs.webkit.org/show_bug.cgi?id=116436
349 Reviewed by Eric Carlson.
351 Let the captions menu behave more like a native Mac menu by hiding it when
352 clicking anywhere on the page and preventing the page from scrolling when
353 attempting to scroll the captions menu when it cannot scroll in the requested
356 Test: media/video-controls-captions-trackmenu-hide-on-click-outside.html
358 * dom/EventListener.h:
359 Add the new MediaControlsAppleEventListenerType.
361 * html/shadow/MediaControlsApple.cpp:
362 (WebCore::MediaControlsApple::defaultEventHandler):
363 (WebCore::MediaControlsApple::hide):
364 (WebCore::MediaControlsApple::makeTransparent):
365 (WebCore::MediaControlsApple::changedClosedCaptionsVisibility):
366 (WebCore::MediaControlsApple::reportedError):
367 (WebCore::MediaControlsApple::toggleClosedCaptionTrackList):
368 Use the hideClosedCaptionTrackList() and showClosedCaptionTrackList()
369 methods to hide and show the captions menu instead of calling hide()
370 and show() directly on m_closedCaptionsContainer.
372 (WebCore::MediaControlsApple::showClosedCaptionTrackList):
373 Show the m_closedCaptionsContainer and register a "mousewheel" event
374 listener on it as well as a "click" event listener on the entire document.
376 (WebCore::MediaControlsApple::hideClosedCaptionTrackList):
377 Hide the m_closedCaptionsContainer and remove the "mousewheel" event
378 listener on it as well as the "click" event listener on the entire document.
380 (WebCore::MediaControlsApple::shouldClosedCaptionsContainerPreventPageScrolling):
381 New private utility to determine whether the m_closedCaptionsContainer can scroll
382 in the provided scroll direction.
384 (WebCore::MediaControlsApple::eventListener):
385 Obtain the event listener used for "mousewheel" and "click" event handlers.
387 (WebCore::MediaControlsAppleEventListener::handleEvent):
388 Event handler for the "mousewheel" and "click" events. If we get a "click" event, we
389 toggle the captions menu visibility and if we get a "mousewheel" event, we call into
390 shouldClosedCaptionsContainerPreventPageScrolling() to see if we can scroll in the
391 current scroll direction, and if not prevent the event from resulting in a scroll by
392 calling preventDefault().
394 (WebCore::MediaControlsAppleEventListener::operator==):
395 Required for the successful subclassing of EventListener.
397 * html/shadow/MediaControlsApple.h:
398 (MediaControlsAppleEventListener):
399 (WebCore::MediaControlsAppleEventListener::create):
400 (WebCore::MediaControlsAppleEventListener::cast):
401 (WebCore::MediaControlsAppleEventListener::MediaControlsAppleEventListener):
402 New subclass of EventListener required to provide a custom event listener for the
403 "mousewheel" and "click" events registered in showClosedCaptionTrackList() and
404 hideClosedCaptionTrackList().
406 2013-05-18 Rashmi Shyamasundar <rashmi.s2@samsung.com>
408 [Cairo] Canvas-shadow behavior is not being as expected
409 https://bugs.webkit.org/show_bug.cgi?id=108897
411 Reviewed by Martin Robinson.
413 ShadowBlur::endShadowLayer copies the image from shadowContext to cairoContext.
414 CairoContext-path should be empty for doing this copy. Otherwise, the
415 original-image area will also get filled with the shadow.
417 Test: fast/canvas/canvas-image-shadow.html
419 * platform/graphics/cairo/GraphicsContextCairo.cpp:
420 (WebCore::drawPathShadow):
422 2013-05-20 Lamarque V. Souza <Lamarque.Souza@basyskom.com>
424 -webkit-text-underline-position should not be inherited
425 https://bugs.webkit.org/show_bug.cgi?id=116363
427 Reviewed by Dean Jackson.
429 Specification says text-underline-position should not be inherited.
431 No new tests, this updates existing tests.
433 * css/CSSProperty.cpp:
434 (WebCore::CSSProperty::isInheritedProperty): Make
435 CSSPropertyWebkitTextUnderlinePosition return false.
436 * rendering/style/RenderStyle.h: Treat TextUnderlinePosition as
438 * rendering/style/StyleRareInheritedData.cpp:
439 (WebCore::StyleRareInheritedData::StyleRareInheritedData):
440 (WebCore::StyleRareInheritedData::operator==): Remove m_textUnderlinePosition.
441 * rendering/style/StyleRareInheritedData.h:
442 (StyleRareInheritedData):
443 * rendering/style/StyleRareNonInheritedData.cpp:
444 (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
445 (WebCore::StyleRareNonInheritedData::operator==): Add m_textUnderlinePosition.
446 * rendering/style/StyleRareNonInheritedData.h:
447 (StyleRareNonInheritedData):
449 2013-05-20 Lamarque V. Souza <Lamarque.Souza@basyskom.com>
451 Add compile asserts for the size of RootInlineBox and InlineTextbox
452 https://bugs.webkit.org/show_bug.cgi?id=116337
454 Reviewed by Darin Adler.
456 Add compile asserts to ensure RootInlineBox and InlineTextbox stay small.
458 * rendering/InlineTextBox.cpp:
459 (SameSizeAsInlineTextBox):
461 * rendering/RootInlineBox.cpp:
462 (SameSizeAsRootInlineBox):
465 2013-05-20 Xan Lopez <xlopez@igalia.com>
467 [BlackBerry] LocalizedStringsBlackBerry: add dummy text track strings
468 https://bugs.webkit.org/show_bug.cgi?id=116300
470 Reviewed by Rob Buis.
472 These are dummy implementations necessary to make WebKit link.
474 * platform/blackberry/LocalizedStringsBlackBerry.cpp:
475 (WebCore::weekFormatInLDML):
477 (WebCore::textTrackClosedCaptionsText):
478 (WebCore::textTrackSubtitlesText):
479 (WebCore::textTrackOffText):
480 (WebCore::textTrackNoLabelText):
482 2013-05-19 Darin Adler <darin@apple.com>
484 [Mac] Improve string use in PasteboardMac
485 https://bugs.webkit.org/show_bug.cgi?id=116418
487 Reviewed by Sam Weinig.
489 Did a Ben Poulain all over this file.
491 * platform/mac/PasteboardMac.mm:
492 (WebCore::Pasteboard::plainText): Add the newline separately to the string builder.
493 Prepending it to the string first just does more allocations for no good reason.
494 (WebCore::Pasteboard::documentFragment): Use emptyString() instead of "" and use
495 ASCIILiteral where appropriate.
496 (WebCore::cocoaTypeFromHTMLClipboardType): More ASCIILiteral.
497 (WebCore::Pasteboard::clear): Use early return instead of a nested if here.
498 Use emptyString() instead of "".
499 (WebCore::addHTMLClipboardTypesForCocoaType): More ASCIILiteral.
501 2013-05-19 Anders Carlsson <andersca@apple.com>
503 Remove link prerendering code
504 https://bugs.webkit.org/show_bug.cgi?id=116415
506 Reviewed by Darin Adler.
508 * Configurations/FeatureDefines.xcconfig:
509 * GNUmakefile.list.am:
511 * WebCore.vcproj/WebCore.vcproj:
512 * WebCore.vcxproj/WebCore.vcxproj:
513 * WebCore.vcxproj/WebCore.vcxproj.filters:
514 * WebCore.xcodeproj/project.pbxproj:
516 (WebCore::Document::Document):
522 * html/HTMLLinkElement.cpp:
523 * html/HTMLLinkElement.h:
524 * html/LinkRelAttribute.cpp:
525 (WebCore::LinkRelAttribute::LinkRelAttribute):
526 * html/LinkRelAttribute.h:
528 * loader/LinkLoader.cpp:
529 (WebCore::LinkLoader::~LinkLoader):
530 (WebCore::LinkLoader::loadLink):
531 (WebCore::LinkLoader::released):
532 * loader/LinkLoader.h:
535 * loader/LinkLoaderClient.h:
537 * loader/Prerenderer.cpp: Removed.
538 * loader/Prerenderer.h: Removed.
539 * loader/PrerendererClient.cpp: Removed.
540 * loader/PrerendererClient.h: Removed.
541 * platform/PrerenderClient.h: Removed.
542 * platform/PrerenderHandle.h: Removed.
544 2013-05-19 Simon Fraser <simon.fraser@apple.com>
546 Change the terminology used by rendering code when painting a given node and its children from "paintingRoot" to "subtreePaintRoot"
547 https://bugs.webkit.org/show_bug.cgi?id=116417
549 Reviewed by Sam Weinig.
551 PaintInfo and RenderLayer code referred to a "paintingRoot". This is only set when
552 FrameView::setNodeToDraw() has been called and is used to restrict painting to
553 some part of the subtree, but it could easily be misinterpreted, and confused with
554 the "rootLayer" used by RenderLayer (which is usually not the layer associated with
557 Change the terminology from "paintingRoot" to "subtreePaintRoot" root to make the
558 purpose of this variable more obvious.
562 * page/FrameView.cpp: Add a comment for setNodeToDraw(); in future this should
563 be called setSubtreePaintRoot() or something. Not done in this patch to avoid
564 risk; this function is exported from WebCore.
565 * rendering/InlineFlowBox.cpp:
566 (WebCore::InlineFlowBox::paint):
567 * rendering/PaintInfo.h:
568 (WebCore::PaintInfo::PaintInfo):
569 (WebCore::PaintInfo::updateSubtreePaintRootForChildren):
570 (WebCore::PaintInfo::shouldPaintWithinRoot):
571 * rendering/RenderBlock.cpp:
572 (WebCore::RenderBlock::paintContents):
573 * rendering/RenderBox.cpp:
574 (WebCore::RenderBox::paint):
575 * rendering/RenderLayer.cpp:
576 (WebCore::RenderLayer::paint):
577 (WebCore::RenderLayer::paintOverlayScrollbars):
578 (WebCore::RenderLayer::paintLayerContents):
579 (WebCore::RenderLayer::paintLayerByApplyingTransform):
580 (WebCore::RenderLayer::paintBackgroundForFragments):
581 (WebCore::RenderLayer::paintForegroundForFragments):
582 (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
583 (WebCore::RenderLayer::paintOutlineForFragments):
584 (WebCore::RenderLayer::paintMaskForFragments):
585 * rendering/RenderLayer.h:
586 (WebCore::RenderLayer::LayerPaintingInfo::LayerPaintingInfo):
587 * rendering/RenderObject.cpp: Add a comment to recommend changing the name of
588 paintingRootRect() to refer to a subtree paint. Not done in this patch to avoid
589 risk; this function is exported from WebCore.
590 * rendering/RenderSnapshottedPlugIn.cpp:
591 (WebCore::RenderSnapshottedPlugIn::paint):
592 * rendering/RenderTable.cpp:
593 (WebCore::RenderTable::paintObject):
594 * rendering/svg/RenderSVGContainer.cpp:
595 (WebCore::RenderSVGContainer::paint):
597 2013-05-19 Darin Adler <darin@apple.com>
599 Use Element instead of Node in DragState, also redo DragState struct
600 https://bugs.webkit.org/show_bug.cgi?id=116411
602 Reviewed by Sam Weinig.
604 The drag source is an element, so use RefPtr<Element> instead of RefPtr<Node>.
606 Also, the entire drag state is about dragging, so no need for the word "drag" in the
607 name of its members. Also, it's a struct, so the members don't need m_ prefixes.
609 * page/DragController.cpp: Removed unneeded include of Node.h since it's included by
610 Element.h, which is also included.
611 (WebCore::DragController::draggableElement): Renamed from Node to Element and changed
612 the types and names of arguments accordingly. Also made this function handle a
613 startElement of 0 so callers don't need to. Also updated for changes to DragState members.
614 (WebCore::DragController::startDrag): Updated for changes to DragState members.
615 Since dragSource can only be an element, was able to get rid of isElementNode checks.
617 * page/DragController.h: Fixed style of forward declarations of structs. Updated for
618 change of draggableNode to draggableElement. Also removed declarations of nonexistent
619 selectionDraggingRect and doDrag functions.
621 * page/DragState.h: Rewrote practically this whole header. Added an include of Element
622 instead of Node since that's what we use now. Removed includes that are redundant.
623 There's no problem copying a DragState, so removed WTF_MAKE_NONCOPYABLE. There's no need
624 to allocate a DragState on the heap, so removed WTF_MAKE_FAST_ALLOCATED. The event dispatch
625 boolean is never set to a constant, so there's no need for a policy enum; it can just be
626 a boolean. Removed the "m_" prefixes from the struct members, since this is a struct with
627 public members and we don't use the prefix in those cases. Removed the word "drag" from the
628 struct member names since this entire struct is about dragging and has drag in its name.
629 Left the comments mostly intact, even though I'm not certain of their value.
631 * page/EventHandler.cpp:
632 (WebCore::EventHandler::handleMousePressEvent): Updated for changes to DragState.
633 (WebCore::EventHandler::eventMayStartDrag):
634 Use innerElement instead of innerNode to call draggableElement instead of draggableNode.
635 (WebCore::EventHandler::updateDragAndDrop): Updated for changes to DragState.
636 (WebCore::EventHandler::cancelDragAndDrop): Ditto.
637 (WebCore::EventHandler::handleWheelEvent): Added FIXME.
638 (WebCore::EventHandler::dragHysteresisExceeded): Updated for changes to DragState.
639 (WebCore::EventHandler::freeClipboard): Updated for changes to DragState. Also re-added
640 code to release the clipboard object, which is needed here to avoid keeping it around in
641 memory until the next drag.
642 (WebCore::EventHandler::dragSourceEndedAt): Updated for changes to DragState.
643 (WebCore::EventHandler::updateDragStateAfterEditDragIfNeeded): Ditto.
644 (WebCore::EventHandler::dispatchDragSrcEvent): Ditto.
645 (WebCore::EventHandler::handleDrag): Updated for changes to DragState. Use innerElement
646 instead of innerNode to call draggableElement instead of draggableNode. No longer need to
647 null check innerElement because draggableElement does that. Removed unneeded else that was
648 setting m_dragSrc to zero since it's guaranteed to already be zero.
650 2013-05-19 Anders Carlsson <andersca@apple.com>
652 Remove ChromeClient::webView()
653 https://bugs.webkit.org/show_bug.cgi?id=116054
655 Reviewed by Darin Adler.
657 This blatantly horrible layer violation was only used to know if a ChromeClient is an empty
658 client or not. We already have a (slightly less horrible) way to do that.
660 * loader/EmptyClients.h:
661 * page/ChromeClient.h:
664 2013-05-19 Darin Adler <darin@apple.com>
666 Eliminate the Editor::newGeneralClipboard function
667 https://bugs.webkit.org/show_bug.cgi?id=116410
669 Reviewed by Andreas Kling.
671 This is one of the clean-ups made possible by the changes to the DOM clipboard class.
672 I had been waiting until all the platforms were moved over to it, but it turns out to be
673 easy to do this now, just with #ifdefs.
675 * PlatformBlackBerry.cmake: Deleted EditorBlackBerry.cpp.
677 * editing/Editor.cpp:
678 (WebCore::Editor::dispatchCPPEvent): Call Clipboard::createForCopyAndPaste directly when
679 using the new version of the Clipboard class. Also some small style cleanup nearby.
681 * editing/blackberry/EditorBlackBerry.cpp: Removed. The only function in this file was
684 * editing/mac/EditorMac.mm: Deleted newGeneralClipboard.
685 * platform/efl/ClipboardEfl.cpp: Ditto.
686 * platform/gtk/ClipboardGtk.cpp: Ditto.
688 2013-05-19 Martin Robinson <mrobinson@igalia.com>
690 GtkSelectionData length is off by one
691 https://bugs.webkit.org/show_bug.cgi?id=113962
693 Reviewed by Anders Carlsson.
695 No new tests. Since drag data is interpreted as a null-terminated string
696 this is difficult to test with a C program and we have no infrastructure
697 built for using GIR tests.
699 * platform/gtk/PasteboardHelper.cpp:
700 (WebCore::PasteboardHelper::fillSelectionData): Instead of including the null
701 character in the paste data length, just include the string. This matches the behavior
704 2013-05-18 Simon Fraser <simon.fraser@apple.com>
706 Hoist several chunks of code at the top of RenderLayer::paintLayerContents() onto new functions
707 https://bugs.webkit.org/show_bug.cgi?id=116406
709 Reviewed by Andreas Kling.
711 RenderLayer::paintLayerContents() was getting polluted with code related to filters,
712 clipping and font subpixel quantization, and hard to follow.
714 Move three hunks of code into new functions:
715 setupFontSubpixelQuantization() now contains the code related to whether we disable
716 font subpixel quantization on the context.
717 setupClipPath() now contains code related to clipping to shapes and references.
718 setupFilters() and applyFilters() contain code related to CSS filters.
720 As part of this, the interaction with FilterEffectRendererHelper was simplified.
721 It was convenient for setupFilters() to return a FilterEffectRendererHelper object
722 if successful, so we use an OwnPtr<FilterEffectRendererHelper> now. In addition,
723 the GraphicsContext swapping was moved from FilterEffectRendererHelper code into RenderLayer
724 to make it easier to follow. FilterEffectRendererHelper no longer holds on to
725 the old GraphicsContext.
729 * rendering/FilterEffectRenderer.cpp:
730 (WebCore::FilterEffectRendererHelper::filterContext):
731 (WebCore::FilterEffectRendererHelper::beginFilterEffect):
732 (WebCore::FilterEffectRendererHelper::applyFilterEffect):
733 * rendering/FilterEffectRenderer.h:
734 (WebCore::FilterEffectRendererHelper::FilterEffectRendererHelper):
735 (WebCore::FilterEffectRendererHelper::hasStartedFilterEffect):
736 (FilterEffectRendererHelper):
737 * rendering/RenderLayer.cpp:
738 (WebCore::RenderLayer::setupFontSubpixelQuantization):
739 (WebCore::RenderLayer::setupClipPath):
740 (WebCore::RenderLayer::setupFilters):
741 (WebCore::RenderLayer::applyFilters):
742 (WebCore::RenderLayer::paintLayerContents):
743 * rendering/RenderLayer.h:
745 2013-05-18 Simon Fraser <simon.fraser@apple.com>
747 Refactor RenderStyle::diff()
748 https://bugs.webkit.org/show_bug.cgi?id=116397
750 Reviewed by Andreas Kling.
752 RenderStyle::diff() was prone to being changed incorrectly, since there was
753 a poorly documented ordering requirement: style changes that cause layout
754 have to be detected before those that cause only repainting.
756 In addition, the existing code made it impossible to separately ask whether
757 a given style change requires a repaint, if we've already detected that it
758 requires a positioned-movement-only layout.
760 Fix by factoring the code into member functions that check for each type
765 * rendering/style/RenderStyle.cpp:
766 (WebCore::positionChangeIsMovementOnly):
767 (WebCore::RenderStyle::changeRequiresLayout):
768 (WebCore::RenderStyle::changeRequiresPositionedLayoutOnly):
769 (WebCore::RenderStyle::changeRequiresLayerRepaint):
770 (WebCore::RenderStyle::changeRequiresRepaint):
771 (WebCore::RenderStyle::changeRequiresRepaintIfText):
772 (WebCore::RenderStyle::changeRequiresRecompositeLayer):
773 (WebCore::RenderStyle::diff):
774 * rendering/style/RenderStyle.h:
776 2013-05-18 Anders Carlsson <andersca@apple.com>
778 Simplify the StorageArea setter functions
779 https://bugs.webkit.org/show_bug.cgi?id=116402
781 Reviewed by Sam Weinig.
783 Move more security checking code to Storage so more code can be shared between WebKit1 and WebKit2.
785 * inspector/InspectorDOMStorageAgent.cpp:
786 (WebCore::InspectorDOMStorageAgent::setDOMStorageItem):
787 (WebCore::InspectorDOMStorageAgent::removeDOMStorageItem):
788 * storage/Storage.cpp:
789 (WebCore::Storage::setItem):
790 (WebCore::Storage::removeItem):
791 (WebCore::Storage::clear):
792 * storage/StorageArea.h:
794 * storage/StorageAreaImpl.cpp:
795 (WebCore::StorageAreaImpl::setItem):
796 (WebCore::StorageAreaImpl::removeItem):
797 (WebCore::StorageAreaImpl::clear):
798 * storage/StorageAreaImpl.h:
801 2013-05-18 Anders Carlsson <andersca@apple.com>
803 Simplify StorageArea getter functions
804 https://bugs.webkit.org/show_bug.cgi?id=116399
806 Reviewed by Sam Weinig.
808 Move the security and private browsing checks from StorageArea to Storage so we can share
809 more code between WebKit1 and WebKit2.
811 * inspector/InspectorDOMStorageAgent.cpp:
812 (WebCore::InspectorDOMStorageAgent::getDOMStorageItems):
813 Update to new StorageArea interface. The security checks are unnecessary here anyway because
814 InspectorDOMStorageAgent::findStorageArea will only return a StorageArea that can be accessed
815 by the frame's security origin.
817 * storage/Storage.cpp:
818 (WebCore::Storage::key):
819 (WebCore::Storage::getItem):
820 (WebCore::Storage::contains):
821 * storage/StorageArea.h:
823 * storage/StorageAreaImpl.cpp:
824 (WebCore::StorageAreaImpl::key):
825 (WebCore::StorageAreaImpl::item):
826 (WebCore::StorageAreaImpl::contains):
827 * storage/StorageAreaImpl.h:
830 2013-05-17 Simon Fraser <simon.fraser@apple.com>
832 Garbage on page background while http://canberraballoons.com.au is loading
833 https://bugs.webkit.org/show_bug.cgi?id=116384
834 <rdar://problem/13930328>
836 Reviewed by Dan Bernstein.
838 This page loads a large JPEG image as the body background.
839 ImageSource::frameHasAlphaAtIndex() always claims that JPEG images
840 are opaque, but this isn't true if the frame is only partially loaded.
841 However, this would cause FillLayer::hasOpaqueImage() to report that the
842 background image is opaque, so we'd skip painting the background color.
843 Unpainted content in an opaque layer results in garbage.
845 Fix by having ImageSource::frameHasAlphaAtIndex() always return true
846 for frames that are not complete. When the image load completes, we
847 recompute metadata and correctly determine that the frame is opaque.
849 * platform/graphics/cg/ImageSourceCG.cpp:
850 (WebCore::ImageSource::frameHasAlphaAtIndex):
852 2013-05-18 Timothy Hatcher <timothy@apple.com>
854 Simplify EventLoop::cycle() on Mac.
856 https://webkit.org/b/116392
858 Reviewed by Anders Carlsson.
860 * platform/mac/EventLoopMac.mm:
861 (WebCore::EventLoop::cycle): Use CFRunLoopRunInMode instead.
863 2013-05-18 Andreas Kling <akling@apple.com>
865 Use CSSParserSelector::appendTagHistory() from CSS grammar.
866 <http://webkit.org/b/116382>
868 Reviewed by Antti Koivisto.
870 CSSParserSelector already knows how to append another component to itself,
871 no need to duplicate that logic in the grammar.
873 * css/CSSGrammar.y.in:
875 2013-05-18 Patrick Gansterer <paroga@webkit.org>
877 [CMake] Replace *_LIBRARY_NAME with *_OUTPUT_NAME
878 https://bugs.webkit.org/show_bug.cgi?id=114554
880 Reviewed by Gyuyoung Kim.
882 Using variables as target names is very uncommon in CMake.
883 The usual way to specify the name of the resulting binary
884 is to set the OUTPUT_NAME target property.
888 2013-05-18 Carlos Garcia Campos <cgarcia@igalia.com>
890 [GTK] Move GTK port off legacy clipboard
891 https://bugs.webkit.org/show_bug.cgi?id=116221
893 Reviewed by Martin Robinson.
895 Merge clipboard methods into PasteboardGtk that now wraps a
898 * GNUmakefile.list.am: Remove ClipboardGtk.h.
899 * dom/Clipboard.h: Remove GTK from the list of ports using legacy
901 * page/gtk/EventHandlerGtk.cpp:
902 (WebCore::EventHandler::createDraggingClipboard): Use
903 Clipboard::createForDragAndDrop().
904 * platform/Pasteboard.h:
906 * platform/gtk/ClipboardGtk.cpp:
907 (WebCore::Editor::newGeneralClipboard): Use
908 Clipboard::createForCopyAndPaste().
909 (WebCore::Clipboard::createDragImage):
910 (WebCore::Clipboard::declareAndWriteDragImage):
911 * platform/gtk/ClipboardGtk.h: Removed.
912 * platform/gtk/DragDataGtk.cpp:
913 * platform/gtk/PasteboardGtk.cpp:
914 (WebCore::Pasteboard::create): Create a new Pasteboard for a given
915 GtkClipboard or DataObjectGtk.
916 (WebCore::Pasteboard::createForCopyAndPaste): Create a Pasteboard
917 for the GDK_SELECTION_CLIPBOARD clipboard.
918 (WebCore::Pasteboard::createPrivate): Create a Pasteboard without
919 a GtkClipboard associated.
920 (WebCore::Pasteboard::createForDragAndDrop): Create a Pasteboard
921 for drag and drop operations.
922 (WebCore::selectionClipboard): Return a static Pasteboard for the
923 GDK_SELECTION_CLIPBOARD clipboard.
924 (WebCore::primaryClipboard): Return a static Pasteboard for the
925 GDK_SELECTION_PRIMARY clipboard.
926 (WebCore::Pasteboard::generalPasteboard): Return
927 selectionClipboard() or primaryClipboard() depending on whether
928 primary selection clipboard is the active one or not.
929 (WebCore::Pasteboard::Pasteboard):
930 (WebCore::Pasteboard::~Pasteboard):
931 (WebCore::Pasteboard::dataObject): Return the wrapped DataObjectGtk.
932 (WebCore::dataObjectTypeFromHTMLClipboardType): Copied from
934 (WebCore::Pasteboard::writeString): Adapted to upate the wrapped
935 DataObjectGtk and the GtkClipboard if needed.
936 (WebCore::Pasteboard::writeSelection): Ditto.
937 (WebCore::Pasteboard::writePlainText): Ditto.
938 (WebCore::Pasteboard::writeURL): Ditto.
939 (WebCore::Pasteboard::writeImage): Ditto.
940 (WebCore::Pasteboard::writePasteboard): Copy the wrapped
941 DataObjectGtk from the DataObjectGtk of the given Pasteboard and
942 upsate the GtkClipboard if needed.
943 (WebCore::Pasteboard::clear): Copied from ClipboardGtk.cpp.
944 (WebCore::Pasteboard::canSmartReplace): Check if current
945 GtkClipboard supports smart replace.
946 (WebCore::Pasteboard::setDragImage):
947 (WebCore::Pasteboard::documentFragment): Adapted to use the
948 wrapped DataObjectGtk reading from the current GtkClipboard if
950 (WebCore::Pasteboard::plainText): Ditto.
951 (WebCore::Pasteboard::hasData): Copied from ClipboardGtk.cpp.
952 (WebCore::Pasteboard::types): Ditto.
953 (WebCore::Pasteboard::readString): Ditto.
954 (WebCore::Pasteboard::readFilenames): Ditto.
956 2013-05-18 Alberto Garcia <agarcia@igalia.com>
958 [GTK] Parallel build fails if gtk-doc is enabled
959 https://bugs.webkit.org/show_bug.cgi?id=116227
961 Reviewed by Martin Robinson.
964 Don't overwrite noinst_DATA, modify its existing value instead.
966 2013-05-17 Michelangelo De Simone <michelangelo@webkit.org>
968 CSSParser parsing of CSSPropertyFontStretch falls into CSSPropertyGeometry
969 https://bugs.webkit.org/show_bug.cgi?id=116370
971 CSSPropertyFontStretch mistakenly fell through the shader parsing logic.
973 Reviewed by Alexandru Chiculita.
975 No new test possible, the feature is not implemented nor exposed.
978 (WebCore::CSSParser::parseValue):
980 2013-05-17 Timothy Hatcher <timothy@apple.com>
982 Force the script debug server to continue when disabling the debugger.
984 There might be some cases where the debugger will stay in the nested run loop
985 which cause weird issues.
987 Speculative fix for: https://webkit.org/b/111438
989 Reviewed by Joseph Pecoraro.
991 * inspector/InspectorDebuggerAgent.cpp:
992 (WebCore::InspectorDebuggerAgent::disable):
994 2013-05-16 Darin Adler <darin@apple.com>
996 [BlackBerry] Get BlackBerry port off legacy clipboard
997 https://bugs.webkit.org/show_bug.cgi?id=116287
999 Reviewed by Rob Buis.
1001 * PlatformBlackBerry.cmake: Removed ClipboardBlackBerry.cpp.
1003 * dom/Clipboard.h: Removed BLACKBERRY from the list of platforms that
1004 use the legacy clipboard.
1006 * editing/blackberry/EditorBlackBerry.cpp:
1007 (WebCore::Editor::newGeneralClipboard): Changed to just create a copy
1008 and paste clipboard.
1010 * page/blackberry/EventHandlerBlackBerry.cpp: Removed a drag-related
1011 function that wasn't doing any good.
1013 * platform/blackberry/ClipboardBlackBerry.cpp: Removed.
1014 * platform/blackberry/ClipboardBlackBerry.h: Removed.
1016 * platform/blackberry/PasteboardBlackBerry.cpp:
1017 (WebCore::Pasteboard::createForCopyAndPaste): Added.
1018 (WebCore::Pasteboard::createPrivate): Added.
1019 (WebCore::Pasteboard::hasData): Added. Moved code here from ClipboardBlackBerry.cpp.
1020 (WebCore::Pasteboard::clear): Ditto.
1021 (WebCore::Pasteboard::readString): Ditto.
1022 (WebCore::Pasteboard::writeString): Ditto.
1023 (WebCore::Pasteboard::types): Ditto.
1024 (WebCore::Pasteboard::readFilenames): Ditto.
1026 2013-05-17 Andreas Kling <akling@apple.com>
1028 Ads on theverge.com cause repaints when hovered, even though content doesn't visibly change.
1029 <http://webkit.org/b/116344>
1031 Reviewed by Darin Adler.
1033 Teach RenderStyle::diff() to ignore differences in the outline value if both styles have non-visible outlines.
1035 * rendering/style/RenderStyle.cpp:
1036 (WebCore::RenderStyle::diff):
1037 * rendering/style/StyleBackgroundData.cpp:
1038 (WebCore::StyleBackgroundData::isEquivalentForPainting):
1039 * rendering/style/StyleBackgroundData.h:
1040 (StyleBackgroundData):
1042 2013-05-17 Andreas Kling <akling@apple.com>
1044 Plug leak in CSSSelectorList::deleteSelectors().
1045 <http://webkit.org/b/116371>
1046 <rdar://problem/13930698>
1048 Reviewed by Ryosuke Niwa.
1050 Don't forget to destroy the very last selector in the list.
1052 * css/CSSSelectorList.cpp:
1053 (WebCore::CSSSelectorList::deleteSelectors):
1055 2013-05-17 Anders Carlsson <andersca@apple.com>
1057 Share code between WebKit1 and WebKit2 StorageArea subclasses
1058 https://bugs.webkit.org/show_bug.cgi?id=116367
1060 Reviewed by Andreas Kling.
1062 * inspector/InspectorDOMStorageAgent.cpp:
1063 (WebCore::InspectorDOMStorageAgent::getDOMStorageItems):
1064 Remove ec parameter.
1066 * inspector/InspectorDOMStorageAgent.h:
1067 Add forward declaration.
1069 * page/DOMWindow.cpp:
1070 (WebCore::DOMWindow::sessionStorage):
1071 (WebCore::DOMWindow::localStorage):
1072 Storage::StorageArea returns a reference now.
1074 * storage/Storage.cpp:
1075 (WebCore::Storage::length):
1076 Check that the storage area can be accessed by the frame, and that it's not disabled by private browsing.
1077 Then call down to the (now simplified) StorageArea::length().
1079 (WebCore::Storage::isDisabledByPrivateBrowsing):
1080 New helper function that's based on StorageAreaImpl::disabledByPrivateBrowsingInFrame, but reordered
1081 to make it easier to follow.
1083 * storage/Storage.h:
1084 (WebCore::Storage::area):
1087 * storage/StorageAreaImpl.cpp:
1088 (WebCore::StorageAreaImpl::storageType):
1089 Add this new virtual member funciton that's needed by Storage::isDisabledByPrivateBrowsing.
1091 (WebCore::StorageAreaImpl::length):
1092 Remove unneeded code.
1094 2013-05-17 Commit Queue <commit-queue@webkit.org>
1096 Unreviewed, rolling out r150294.
1097 http://trac.webkit.org/changeset/150294
1098 https://bugs.webkit.org/show_bug.cgi?id=116369
1100 Caused 31 tests to fail (Requested by rniwa on #webkit).
1103 * rendering/InlineFlowBox.h:
1104 * rendering/InlineTextBox.h:
1106 * rendering/RenderApplet.h:
1107 * rendering/RenderBR.h:
1108 * rendering/RenderBlock.h:
1110 (WebCore::RenderBlock::virtualContinuation):
1111 * rendering/RenderBox.h:
1112 (WebCore::RenderBox::borderBoundingBox):
1114 (WebCore::RenderBox::marginLogicalLeft):
1115 (WebCore::RenderBox::marginLogicalRight):
1116 * rendering/RenderBoxModelObject.h:
1117 (WebCore::RenderBoxModelObject::isBoxModelObject):
1118 * rendering/RenderButton.h:
1119 * rendering/RenderCombineText.h:
1120 * rendering/RenderCounter.h:
1121 * rendering/RenderDeprecatedFlexibleBox.h:
1122 * rendering/RenderDetailsMarker.h:
1123 * rendering/RenderEmbeddedObject.h:
1124 (RenderEmbeddedObject):
1125 (WebCore::RenderEmbeddedObject::isEmbeddedObject):
1126 (WebCore::RenderEmbeddedObject::virtualChildren):
1127 * rendering/RenderFieldset.h:
1128 * rendering/RenderFileUploadControl.h:
1129 * rendering/RenderFlexibleBox.h:
1130 * rendering/RenderFlowThread.h:
1131 * rendering/RenderFrame.h:
1132 * rendering/RenderFrameSet.h:
1133 * rendering/RenderFullScreen.cpp:
1134 * rendering/RenderFullScreen.h:
1135 * rendering/RenderGrid.h:
1136 * rendering/RenderHTMLCanvas.h:
1137 * rendering/RenderIFrame.h:
1138 * rendering/RenderImage.h:
1140 (WebCore::RenderImage::isRenderImage):
1141 * rendering/RenderInline.h:
1143 (WebCore::RenderInline::virtualContinuation):
1144 (WebCore::RenderInline::virtualChildren):
1145 (WebCore::RenderInline::isRenderInline):
1146 (WebCore::RenderInline::layout):
1147 (WebCore::RenderInline::requiresLayer):
1148 (WebCore::RenderInline::offsetWidth):
1149 (WebCore::RenderInline::offsetHeight):
1150 (WebCore::RenderInline::borderBoundingBox):
1151 (WebCore::RenderInline::dirtyLinesFromChangedChild):
1152 * rendering/RenderLayerModelObject.h:
1153 * rendering/RenderListBox.h:
1154 * rendering/RenderListItem.h:
1155 * rendering/RenderListMarker.h:
1156 * rendering/RenderMedia.h:
1157 (WebCore::RenderMedia::virtualChildren):
1158 (WebCore::RenderMedia::canHaveChildren):
1159 (WebCore::RenderMedia::isMedia):
1160 (WebCore::RenderMedia::isImage):
1161 (WebCore::RenderMedia::requiresForcedStyleRecalcPropagation):
1162 * rendering/RenderMediaControlElements.h:
1163 * rendering/RenderMenuList.h:
1164 * rendering/RenderMeter.h:
1165 * rendering/RenderMultiColumnBlock.h:
1166 * rendering/RenderMultiColumnFlowThread.h:
1167 * rendering/RenderMultiColumnSet.h:
1168 * rendering/RenderNamedFlowThread.h:
1169 * rendering/RenderPart.h:
1171 (WebCore::RenderPart::isRenderPart):
1172 (WebCore::RenderPart::renderName):
1173 * rendering/RenderProgress.h:
1174 * rendering/RenderRegion.h:
1175 (WebCore::RenderRegion::isRenderRegion):
1176 * rendering/RenderRegionSet.h:
1177 * rendering/RenderReplaced.h:
1179 (WebCore::RenderReplaced::renderName):
1180 * rendering/RenderReplica.h:
1181 * rendering/RenderRuby.h:
1182 * rendering/RenderRubyBase.h:
1183 * rendering/RenderRubyRun.h:
1184 * rendering/RenderRubyText.h:
1185 * rendering/RenderScrollbarPart.h:
1186 * rendering/RenderSearchField.h:
1187 * rendering/RenderSlider.h:
1188 * rendering/RenderSnapshottedPlugIn.h:
1189 (RenderSnapshottedPlugIn):
1190 * rendering/RenderTable.h:
1192 (WebCore::RenderTable::renderName):
1193 (WebCore::RenderTable::isTable):
1194 (WebCore::RenderTable::avoidsFloats):
1195 * rendering/RenderTableCaption.h:
1196 * rendering/RenderTableCell.h:
1197 * rendering/RenderTableCol.h:
1198 * rendering/RenderTableRow.h:
1199 * rendering/RenderTableSection.h:
1200 * rendering/RenderText.h:
1202 (WebCore::RenderText::marginLeft):
1203 (WebCore::RenderText::marginRight):
1204 (WebCore::RenderText::styleWillChange):
1205 (WebCore::RenderText::length):
1206 (WebCore::RenderText::paint):
1207 (WebCore::RenderText::layout):
1208 * rendering/RenderTextControl.h:
1209 (RenderTextControl):
1210 (WebCore::RenderTextControl::renderName):
1211 (WebCore::RenderTextControl::isTextControl):
1212 (WebCore::RenderTextControl::avoidsFloats):
1213 * rendering/RenderTextControlMultiLine.h:
1214 * rendering/RenderTextControlSingleLine.h:
1215 (RenderTextControlSingleLine):
1216 (WebCore::RenderTextControlSingleLine::isTextField):
1217 * rendering/RenderTextFragment.h:
1218 * rendering/RenderTextTrackCue.h:
1219 * rendering/RenderVideo.h:
1220 * rendering/RenderView.h:
1221 * rendering/RenderWidget.h:
1223 (WebCore::RenderWidget::isWidget):
1224 * rendering/RenderWordBreak.h:
1225 * rendering/RootInlineBox.h:
1227 * rendering/mathml/RenderMathMLBlock.h:
1228 * rendering/svg/RenderSVGBlock.h:
1230 * rendering/svg/RenderSVGContainer.h:
1231 (WebCore::RenderSVGContainer::setNeedsBoundariesUpdate):
1232 (WebCore::RenderSVGContainer::virtualChildren):
1233 (WebCore::RenderSVGContainer::isSVGContainer):
1234 (WebCore::RenderSVGContainer::renderName):
1235 (RenderSVGContainer):
1236 (WebCore::RenderSVGContainer::objectBoundingBox):
1237 (WebCore::RenderSVGContainer::strokeBoundingBox):
1238 (WebCore::RenderSVGContainer::repaintRectInLocalCoordinates):
1239 * rendering/svg/RenderSVGEllipse.h:
1240 * rendering/svg/RenderSVGForeignObject.h:
1241 * rendering/svg/RenderSVGGradientStop.h:
1242 * rendering/svg/RenderSVGHiddenContainer.h:
1243 (WebCore::RenderSVGHiddenContainer::renderName):
1244 (RenderSVGHiddenContainer):
1245 (WebCore::RenderSVGHiddenContainer::isSVGHiddenContainer):
1246 * rendering/svg/RenderSVGImage.h:
1247 * rendering/svg/RenderSVGInline.h:
1248 (WebCore::RenderSVGInline::renderName):
1249 (WebCore::RenderSVGInline::requiresLayer):
1250 (WebCore::RenderSVGInline::isSVGInline):
1252 * rendering/svg/RenderSVGInlineText.h:
1253 * rendering/svg/RenderSVGModelObject.h:
1254 (WebCore::RenderSVGModelObject::requiresLayer):
1255 (RenderSVGModelObject):
1256 * rendering/svg/RenderSVGPath.h:
1257 * rendering/svg/RenderSVGRect.h:
1258 * rendering/svg/RenderSVGResourceClipper.h:
1259 * rendering/svg/RenderSVGResourceContainer.h:
1260 (RenderSVGResourceContainer):
1261 (WebCore::RenderSVGResourceContainer::isSVGResourceContainer):
1262 (WebCore::RenderSVGResourceContainer::toRenderSVGResourceContainer):
1263 * rendering/svg/RenderSVGResourceFilter.h:
1264 * rendering/svg/RenderSVGResourceFilterPrimitive.h:
1265 * rendering/svg/RenderSVGResourceGradient.h:
1266 (RenderSVGResourceGradient):
1267 (WebCore::RenderSVGResourceGradient::resourceBoundingBox):
1268 * rendering/svg/RenderSVGResourceLinearGradient.h:
1269 * rendering/svg/RenderSVGResourceMarker.h:
1270 * rendering/svg/RenderSVGResourceMasker.h:
1271 * rendering/svg/RenderSVGResourcePattern.h:
1272 * rendering/svg/RenderSVGResourceRadialGradient.h:
1273 * rendering/svg/RenderSVGRoot.h:
1274 * rendering/svg/RenderSVGShape.h:
1275 (WebCore::RenderSVGShape::setNeedsBoundariesUpdate):
1276 (WebCore::RenderSVGShape::setNeedsTransformUpdate):
1277 (WebCore::RenderSVGShape::repaintRectInLocalCoordinates):
1278 (WebCore::RenderSVGShape::localToParentTransform):
1279 (WebCore::RenderSVGShape::localTransform):
1280 (WebCore::RenderSVGShape::isSVGShape):
1282 (WebCore::RenderSVGShape::objectBoundingBox):
1283 (WebCore::RenderSVGShape::strokeBoundingBox):
1284 * rendering/svg/RenderSVGTSpan.h:
1285 * rendering/svg/RenderSVGText.h:
1286 * rendering/svg/RenderSVGTextPath.h:
1287 * rendering/svg/RenderSVGTransformableContainer.h:
1288 * rendering/svg/RenderSVGViewportContainer.h:
1290 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1292 Get rid of Custom code for Audio global constructor
1293 https://bugs.webkit.org/show_bug.cgi?id=116343
1295 Reviewed by Geoffrey Garen.
1297 Remove custom code for Audio global constructor. It is no longer needed
1298 now that the the bindings generator no longer require custom code for
1299 named constructors and now that [EnabledAtRuntime] extended attribute is
1300 supported for global constructors.
1302 HTMLAudioElement global constructors are now automatically generated.
1304 No new tests, no behavior change for layout tests.
1306 * bindings/js/JSDOMWindowCustom.cpp:
1307 * html/HTMLAudioElement.idl:
1308 * page/DOMWindow.idl:
1310 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1312 <rdar://problem/13819878> Disable SharedWorker when in multiple web process model
1313 https://bugs.webkit.org/show_bug.cgi?id=116359
1315 Reviewed by Anders Carlsson.
1317 This feature was already RuntimeEnabled. Call through layers to get the answer from
1318 a platform strategy.
1320 * workers/DefaultSharedWorkerRepository.cpp:
1321 (WebCore::DefaultSharedWorkerRepository::isAvailable):
1322 * workers/DefaultSharedWorkerRepository.h:
1323 * workers/SharedWorkerRepository.cpp:
1324 (WebCore::SharedWorkerRepository::isAvailable):
1325 * workers/SharedWorkerStrategy.h:
1326 (WebCore::SharedWorkerStrategy::isAvailable):
1328 2013-05-17 Anders Carlsson <andersca@apple.com>
1330 Move Storage member functions out of line
1331 https://bugs.webkit.org/show_bug.cgi?id=116364
1333 Reviewed by Andreas Kling.
1335 This is preparation for sharing more code between the WebKit1 and WebKit2 storage area subclasses.
1336 Also remove unnecessary null checks and make m_storageArea const.
1338 * storage/Storage.cpp:
1339 (WebCore::Storage::length):
1340 (WebCore::Storage::key):
1341 (WebCore::Storage::getItem):
1342 (WebCore::Storage::setItem):
1343 (WebCore::Storage::removeItem):
1344 (WebCore::Storage::clear):
1345 (WebCore::Storage::contains):
1346 * storage/Storage.h:
1347 (WebCore::Storage::area):
1349 2013-05-17 Beth Dakin <bdakin@apple.com>
1351 Headers and footers will sometimes disappear and re-appear during page loads
1352 https://bugs.webkit.org/show_bug.cgi?id=116336
1354 <rdar://problem/13886753>
1356 Reviewed by Simon Fraser.
1358 This patch changes the WebCore-level API that WebKit uses to create a banner.
1359 Specifically this patch removes FrameView::setWantsLayerForHeader(), which created
1360 and returned a layer. Instead, WK2 will call Page::addHeaderWithHeight(). When the
1361 layer has been created, it will call back into WK2 via ChromeClient. This will
1362 allow WebCore to re-create the header/footer layers as needed whenever the
1363 FrameView/RenderLayerCompositor have been destroyed and recreated.
1365 Remove references to old FrameView functions. Add references to new Page
1369 New ChromeClient functions will pass the new layers up to WK2.
1370 * page/ChromeClient.h:
1371 (WebCore::ChromeClient::didAddHeaderLayer):
1372 (WebCore::ChromeClient::didAddFooterLayer):
1375 Remove setWantsLayerForHeader/Footer.
1376 * page/FrameView.cpp:
1380 Page now caches the header and footer height. When the FrameView/RLC have been
1381 destroyed, and the cached layer/height information on those classes has been lost,
1382 this data on Page will persist so that we can build the layers back up.
1384 (WebCore::Page::Page):
1385 (WebCore::Page::addHeaderWithHeight):
1386 (WebCore::Page::addFooterWithHeight):
1388 (WebCore::Page::headerHeight):
1389 (WebCore::Page::footerHeight):
1391 As soon as the root gets a backing, recreate the header and footer layers if
1393 * rendering/RenderLayerCompositor.cpp:
1394 (WebCore::RenderLayerCompositor::updateBacking):
1396 Call into ChromeClient.
1397 (WebCore::RenderLayerCompositor::updateLayerForHeader):
1398 (WebCore::RenderLayerCompositor::updateLayerForFooter):
1400 2013-05-18 Claudio Saavedra <csaavedra@igalia.com>
1402 [CSS] Minor cleanups in CSS variables handling
1403 https://bugs.webkit.org/show_bug.cgi?id=116318
1405 Reviewed by Ryosuke Niwa.
1407 No new tests, only a cleanup.
1409 * css/CSSParser.cpp:
1410 (WebCore::CSSParserString::substring): Optimize.
1411 (WebCore::CSSParser::createPrimitiveVariableNameValue):
1412 Remove intermediate variable.
1414 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1416 [Mac] Add DOMWindowConstructors.idl to Xcode project file
1417 https://bugs.webkit.org/show_bug.cgi?id=116351
1419 Reviewed by Anders Carlsson.
1421 * WebCore.xcodeproj/project.pbxproj: Added the file, so that Xcode includes it
1424 2013-05-17 Ryosuke Niwa <rniwa@webkit.org>
1426 Remove the declaration of Element::detachAttrNodeAtIndex erroneously added in r150072.
1431 2013-05-17 Anders Carlsson <andersca@apple.com>
1433 WKKeyValueStorageManagerGetKeyValueStorageOrigins should get origins from the UI process
1434 https://bugs.webkit.org/show_bug.cgi?id=116346
1435 <rdar://problem/13852829>
1437 Reviewed by Andreas Kling.
1439 Export the UTF8Encoding symbol.
1443 2013-05-17 Andreas Kling <akling@apple.com>
1445 Apply FINAL to the RenderObject hierarchy.
1446 <http://webkit.org/b/115977>
1448 Mostly from Blink r148795 by <cevans@chromium.org>
1449 <http://src.chromium.org/viewvc/blink?view=revision&revision=148795>
1451 Re-landing without devirtualization tweaks.
1453 * rendering/: Beat things with the FINAL stick.
1454 * WebCore.exp.in: Export a now-needed symbol.
1456 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1460 * loader/FrameLoader.cpp: (WebCore::FrameLoader::willTransitionToCommitted):
1461 Frame:editor() now returns a reference.
1463 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1465 Get rid of [ConstructorParameters] extended attributes
1466 https://bugs.webkit.org/show_bug.cgi?id=116308
1468 Reviewed by Kentaro Hara.
1470 Get rid of WebKit-specific [ConstructorParameters] IDL extended attribute. Instead,
1471 [CustomConstructor] arguments are now explicitly specified, similarly to [Constructor]
1472 arguments and the constructor object's "length" property is now automatically
1473 computed for custom constructors as well.
1475 This is less error-prone as the value is not hardcoded, more consistent with
1476 [Constructor] extended attribute and gives more information about the custom constructor
1477 in the IDL file. We also get rid of a WebKit-specific IDL attribute which is always
1480 No new tests, already covered by fast/js/constructor-length.html.
1482 * Modules/mediastream/MediaStream.idl:
1483 * Modules/webaudio/AudioContext.idl:
1484 * Modules/websockets/WebSocket.idl:
1485 * bindings/scripts/CodeGeneratorJS.pm:
1486 (GenerateConstructorHelperMethods):
1487 * bindings/scripts/IDLAttributes.txt:
1488 * bindings/scripts/IDLParser.pm:
1490 (parseAttributeRest):
1491 (copyExtendedAttributes):
1492 (parseExtendedAttributeRest):
1493 (applyExtendedAttributeList):
1494 * bindings/scripts/test/JS/JSFloat64Array.cpp:
1495 (WebCore::JSFloat64ArrayConstructor::finishCreation):
1496 * bindings/scripts/test/TestTypedArray.idl:
1497 * dom/MutationObserver.idl:
1499 * html/DOMFormData.idl:
1500 * html/canvas/ArrayBuffer.idl:
1501 * html/canvas/DataView.idl:
1502 * page/WebKitPoint.idl:
1503 * workers/SharedWorker.idl:
1504 * workers/Worker.idl:
1506 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1508 Text input is largely broken when there are subframes loading
1509 http://bugs.webkit.org/show_bug.cgi?id=59121
1510 <rdar://problem/9320468>
1512 Reviewed by Darin Adler.
1514 This addresses text input being abandoned when another frame in a page is navigated.
1516 There are still many opportunities for improvement:
1517 - Track other cases where WebCore interferes may want to cancel input without
1518 direct user action (e.g. deleting the whole editable element on a timer).
1519 - Fix how dictionary panel and autocorrection are dismissed (they still have the
1520 same issue, and get dismissed with any frame navigation).
1522 Test: platform/mac/editing/input/unconfirmed-text-navigation-with-page-cache.html
1524 * loader/FrameLoader.h:
1525 * loader/FrameLoader.cpp:
1526 (WebCore::FrameLoader::willTransitionToCommitted): Make sure that we
1527 do not keep an inline session in a frame that's no longer active, as WebKit2 no
1528 longer takes care of this case (and more of the logic should be in WebCore anyway).
1529 (WebCore::FrameLoader::commitProvisionalLoad): Added a hook that gets invoked right
1530 before transitioning to committed state starts. We may want to move more code here
1531 eventually, e.g. from Frame::setView.
1533 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1535 Get rid of [CustomGetter] for global named constructors
1536 https://bugs.webkit.org/show_bug.cgi?id=116116
1538 Reviewed by Geoffrey Garen.
1540 Improve the JSC bindings generator so that global named constructors no longer
1541 require a [CustomGetter] IDL extended attribute. As a consequence, attributes
1542 on the global window object can now be automatically generated for interfaces
1543 that have a [NamedConstructor], namely HTMLOptionElement.
1545 The HTMLAudioElement global constructors are still manually defined because it
1546 requires custom code at the moment to check if the media player is available.
1548 No new tests, no behavior change.
1550 * bindings/js/JSDOMWindowCustom.cpp:
1551 * bindings/scripts/CodeGeneratorJS.pm:
1552 * bindings/scripts/preprocess-idls.pl:
1553 * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
1554 * bindings/scripts/test/JS/JSTestNamedConstructor.h:
1555 * html/HTMLOptionElement.idl:
1556 * page/DOMWindow.idl:
1558 2013-05-17 Joseph Pecoraro <pecoraro@apple.com>
1560 Web Inspector: SyntaxError evaluating "1+1; //@ sourceURL=test" in console
1561 https://bugs.webkit.org/show_bug.cgi?id=116292
1563 Add a newline after the expression so a single line comment doesn't
1564 erroneously comment out the closing brace of the with block.
1566 Reviewed by Timothy Hatcher.
1568 Test: inspector/console/console-eval-comment.html
1570 * inspector/InjectedScriptSource.js:
1572 2013-05-17 David Hyatt <hyatt@apple.com>
1574 fast/flexbox/auto-height-with-flex.html failing only on release builds.
1575 https://bugs.webkit.org/show_bug.cgi?id=116240
1577 Reviewed by Darin Adler.
1579 Fix the mainAxisContentExtent method so no overflow occurs, since it
1580 doesn't work right on release builds.
1582 * rendering/RenderFlexibleBox.cpp:
1583 (WebCore::RenderFlexibleBox::mainAxisContentExtent):
1585 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1587 Add [EnabledAtRuntime] extended attribute support for global constructors
1588 https://bugs.webkit.org/show_bug.cgi?id=116147
1590 Reviewed by Geoffrey Garen.
1592 Add [EnabledAtRuntime] extended attribute support for global constructors.
1593 This patch adds [EnabledAtRuntime] extended attribute to SharedWorker and
1594 WebSocket IDL interfaces so that their global constructors on the global
1595 Window object can now be automatically generated.
1597 The behavior on JavaScript side is unchanged. We simply leverage
1598 RuntimeEnabledFeatures class and the new [EnabledAtRuntime] IDL extended
1599 attribute to generate the code for global constructors getters instead
1600 of using custom code.
1602 No new tests, no behavior change for layout tests.
1604 * GNUmakefile.list.am:
1605 * Modules/websockets/WebSocket.cpp: Enable WebSockets at runtime by default.
1606 * Modules/websockets/WebSocket.idl:
1609 * WebCore.vcproj/WebCore.vcproj:
1610 * WebCore.vcxproj/WebCore.vcxproj:
1611 * WebCore.vcxproj/WebCore.vcxproj.filters:
1612 * WebCore.xcodeproj/project.pbxproj:
1613 * bindings/js/JSBindingsAllInOne.cpp:
1614 * bindings/js/JSDOMWindowCustom.cpp:
1616 * bindings/js/JSDOMWindowWebSocketCustom.cpp: Removed.
1617 * bindings/scripts/CodeGeneratorJS.pm:
1619 (GetRuntimeEnableFunctionName):
1620 (GenerateImplementation):
1621 * bindings/scripts/IDLAttributes.txt:
1622 * page/DOMWindow.idl:
1623 * workers/SharedWorker.idl:
1625 2013-05-17 Darin Adler <darin@apple.com>
1627 [EFL] Move EFL port off legacy clipboard
1628 https://bugs.webkit.org/show_bug.cgi?id=116181
1630 Reviewed by Anders Carlsson.
1632 * dom/Clipboard.h: Switched EFL away from "legacy" mode for Clipboard.
1634 * page/efl/EventHandlerEfl.cpp:
1635 (WebCore::EventHandler::createDraggingClipboard): Changed to call Clipboard member function.
1637 * platform/efl/ClipboardEfl.cpp: Deleted most of the functions.
1638 (WebCore::Editor::newGeneralClipboard): Changed to call Clipboard member function.
1639 (WebCore::Clipboard::createDragImage): Moved from ClipboardEfl to Clipboard.
1640 (WebCore::Clipboard::declareAndWriteDragImage): Moved from ClipboardEfl to Clipboard.
1641 (WebCore::Clipboard::items): Ditto.
1643 * platform/efl/PasteboardEfl.cpp: A lot of copyright notices for a file that
1644 has no code in it other than notImplemented lines! I didn't add a new one.
1645 (WebCore::Pasteboard::createForCopyAndPaste): Added.
1646 (WebCore::Pasteboard::createPrivate): Added.
1647 (WebCore::Pasteboard::createForDragAndDrop): Added.
1648 (WebCore::Pasteboard::hasData): Added.
1649 (WebCore::Pasteboard::readString): Added.
1650 (WebCore::Pasteboard::writeString): Added.
1651 (WebCore::Pasteboard::types): Added.
1652 (WebCore::Pasteboard::readFilenames): Added.
1653 (WebCore::Pasteboard::setDragImage): Added.
1654 (WebCore::Pasteboard::writePasteboard): Added.
1656 2013-05-17 Frédéric Wang <fred.wang@free.fr>
1658 Bad spacing inside MathML formulas when text-indent is specified
1659 https://bugs.webkit.org/show_bug.cgi?id=106600
1661 Reviewed by Martin Robinson.
1663 When MathML is used in a HTML page that modifies the CSS text-indent,
1664 large gaps appear inside the mathematical expressions. Resetting it to
1665 0 on the math root (as Gecko does) fixes the issue.
1667 Tests: mathml/presentation/text-indent.html
1668 mathml/presentation/text-indent-expected.html
1671 (math): reset text-indent to its default value.
1673 2013-05-17 Alberto Garcia <agarcia@igalia.com>
1675 Fix code that expects Page::chrome() to return a pointer
1676 https://bugs.webkit.org/show_bug.cgi?id=116313
1678 Reviewed by Darin Adler.
1680 Page::chrome() returns a reference after r150214.
1682 * platform/network/blackberry/NetworkManager.cpp:
1683 (WebCore::NetworkManager::startJob):
1684 * platform/network/blackberry/SocketStreamHandleBlackBerry.cpp:
1685 (WebCore::SocketStreamHandle::SocketStreamHandle):
1686 * testing/Internals.cpp:
1687 (WebCore::Internals::resetToConsistentState):
1688 (WebCore::Internals::setEnableMockPagePopup):
1690 2013-05-17 Alberto Garcia <agarcia@igalia.com>
1692 [BlackBerry] ImageBlackBerry: add missing BlendMode parameter
1693 https://bugs.webkit.org/show_bug.cgi?id=116316
1695 Reviewed by Carlos Garcia Campos.
1697 When the new BitmapImage::draw() method was added in r147110 it
1698 didn't include the BlendMode parameter, which has been there since
1701 * platform/graphics/blackberry/ImageBlackBerry.cpp:
1702 (WebCore::BitmapImage::draw):
1704 2013-05-16 Jer Noble <jer.noble@apple.com>
1706 Some media/track tests fail or assert on Mac
1707 https://bugs.webkit.org/show_bug.cgi?id=97132
1709 Reviewed by Simon Fraser.
1711 Rationalize the font and padding behavior of cues and cue boxes; ::cue pseudo elements cannot have padding
1712 values applied via CSS (due to padding not being included in the whitelist of applicable CSS properties).
1713 Also, the font values were being applied to the box at one level and the cue at another, leading to incorrect
1714 layout in the snapToLines case. Padding has been removed from the cue, and the font settings are now applied
1715 to the box exclusively.
1717 Additionally, a few drive-by changes were made in TextTrackCue to the return values of displayTreeInternal() &
1718 element(), which previously returned a PassRefPtr<> instead of a plain pointer.
1720 * css/mediaControls.css:
1721 (video::-webkit-media-text-track-container): Move the font size to the display selector.
1722 (video::cue): Remove the display:inline and padding:2px declarations.
1723 (video::-webkit-media-text-track-display): Remove the -webkit-line-content now that the ::cue has no padding.
1724 * html/track/TextTrackCue.cpp:
1725 (WebCore::TextTrackCue::TextTrackCue): The background box is now a span, rather than a forced-inline div.
1726 (WebCore::TextTrackCue::displayTreeInternal): Return a plain pointer.
1727 (WebCore::TextTrackCue::getDisplayTree): Ditto.
1728 (WebCore::TextTrackCue::setFontSize): Set the font on the box, not the cue.
1729 * html/track/TextTrackCue.h:
1730 (WebCore::TextTrackCue::element): Return a plain pointer.
1731 * html/track/TextTrackCueGeneric.cpp:
1732 (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties): The cue element is now a span, not a div.
1733 * page/CaptionUserPreferencesMac.mm:
1734 (WebCore::CaptionUserPreferencesMac::captionsWindowCSS): Whitespace.
1735 (WebCore::CaptionUserPreferencesMac::captionsBackgroundCSS): Do not set padding on the cue.
1737 2013-05-16 Andreas Kling <akling@apple.com>
1739 Changes in text-only properties shouldn't cause repaints unless there is actually text.
1740 <http://webkit.org/b/116250>
1742 Reviewed by Antti Koivisto.
1744 Add a new StyleDifferenceRepaintIfText value to the repertoire of RenderStyle::diff().
1745 This result means that the renderer only needs to repaint if one of its immediate children contains text.
1747 This lets us avoid repainting the same pixels when hovering over constructs like:
1750 a { text-decoration: none; }
1751 a:hover { text-decoration: underline; }
1753 <a href="http://is.gd/andersca">
1754 <img src="cool-hat.jpg">
1757 Since the change in text-decoration has no effect on the rendering of the <img> element,
1758 we'll now be smart enough to avoid repainting it.
1760 * rendering/style/RenderStyleConstants.h:
1761 * rendering/style/RenderStyle.cpp:
1762 (WebCore::RenderStyle::diff):
1764 Move checking of text-only properties until the very end, and return StyleDifferenceRepaintIfText
1765 in case a difference is found, giving precedence to StyleDifferenceRepaint.
1767 * rendering/RenderObject.h:
1768 * rendering/RenderObject.cpp:
1769 (WebCore::RenderObject::hasImmediateNonWhitespaceTextChild):
1771 Helper to check if a RenderObject has at least one RenderText child containing more than just
1772 collapsible whitespace.
1774 (WebCore::RenderObject::shouldRepaintForStyleDifference):
1776 Helper to check if a StyleDifference is either ...Repaint or ...RepaintIfText and the renderer
1777 has an immediate text child.
1779 (WebCore::RenderObject::styleWillChange):
1780 (WebCore::RenderObject::setStyle):
1782 Don't repaint for StyleDifferenceRepaintIfText unless hasImmediateNonWhitespaceTextChild().
1784 * rendering/RenderBox.cpp:
1785 (WebCore::RenderBox::styleDidChange):
1786 * rendering/svg/SVGResourcesCache.cpp:
1787 (WebCore::SVGResourcesCache::clientStyleChanged):
1789 Tweak for new StyleDifference enum value.
1791 * rendering/RenderText.h:
1792 * rendering/RenderText.cpp:
1793 (WebCore::RenderText::isAllCollapsibleWhitespace):
1797 2013-05-17 Lamarque V. Souza <Lamarque.Souza@basyskom.com>
1799 Improve -webkit-text-underline-position memory usage.
1800 https://bugs.webkit.org/show_bug.cgi?id=116108
1802 Reviewed by Benjamin Poulain.
1804 Remove m_maxLogicalTop private variable from RootInlineBox to reduce
1805 the overall memory used to render RootInlineBoxes (eight bytes per RootInlineBox
1806 instance in a 64-bit machine). RootInline::maxLogicalTop() now computes
1807 the maxLogicalTop value everytime it is called. In a typical page
1808 computeMaxLogicalTop is called less than 10 times for each
1809 InlineTextBox that uses -webkit-text-underline-position. That is a small
1810 price users of -webkit-text-underline-position will pay so that
1811 everybody can benefit from the memory reduction in RootInlineBox.
1813 No new tests, no change in behavior.
1815 * rendering/InlineFlowBox.cpp:
1816 (WebCore::InlineFlowBox::computeMaxLogicalTop): Make it const.
1817 * rendering/InlineFlowBox.h:
1818 * rendering/RootInlineBox.cpp:
1819 (WebCore::RootInlineBox::RootInlineBox): Remove m_maxLogicalTop.
1820 (WebCore::RootInlineBox::alignBoxesInBlockDirection): Remove
1821 computeMaxLogicalTop call and obsolete comment.
1823 (WebCore::RootInlineBox::maxLogicalTop): Compute maxLogicalTop before
1824 returning its value.
1825 * rendering/RootInlineBox.h:
1828 2013-05-17 Alexis Menard <alexis@webkit.org>
1830 Make sure to call release() on our smart pointers when we should.
1831 https://bugs.webkit.org/show_bug.cgi?id=116307
1833 Reviewed by Andreas Kling.
1835 Call release() when we should call it. There is probably more occurence
1836 of this problem on the codebase but this is a first bunch of fixes.
1838 No new tests : existing ones should cover.
1840 * css/CSSComputedStyleDeclaration.cpp:
1841 (WebCore::valueForNinePieceImage):
1842 (WebCore::getBorderRadiusShorthandValue):
1843 (WebCore::CSSComputedStyleDeclaration::valueForFilter):
1844 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1845 (WebCore::CSSComputedStyleDeclaration::getCSSPropertyValuesForSidesShorthand):
1846 (WebCore::CSSComputedStyleDeclaration::getCSSPropertyValuesForGridShorthand):
1847 * css/CSSParser.cpp:
1848 (WebCore::CSSParser::parseBorderImage):
1849 * html/HTMLBodyElement.cpp:
1850 (WebCore::HTMLBodyElement::collectStyleForPresentationAttribute):
1852 2013-05-17 Allan Sandfeld Jensen <allan.jensen@digia.com>
1854 Make PNGImageDecoder::rowAvailable auto-vectorizable
1855 https://bugs.webkit.org/show_bug.cgi?id=116151
1857 Reviewed by Benjamin Poulain.
1859 Changed the main loops under PNGImageDecoder::rowAvailable so that they
1860 avoid branches and non-sequential table look ups.
1862 Together with automatic vectorization by the compiler this provides around
1863 4x speed-up with AVX or 2x speed-up on generic x64. Shaving off 12-40% on
1864 PNG decoding in general.
1866 * platform/graphics/Color.cpp:
1867 (WebCore::premultipliedARGBFromColor):
1868 * platform/graphics/Color.h:
1869 (WebCore::fastDivideBy255):
1870 * platform/graphics/filters/FEBlend.cpp:
1871 * platform/image-decoders/png/PNGImageDecoder.cpp:
1872 (WebCore::setPixelRGB):
1873 (WebCore::setPixelRGBA):
1874 (WebCore::setPixelRGBA_Premultiplied):
1875 (WebCore::PNGImageDecoder::rowAvailable):
1877 2013-05-17 Joseph Pecoraro <pecoraro@apple.com>
1879 Web Inspector: Allow "//# sourceMappingURL" syntax alongside "//@"
1880 https://bugs.webkit.org/show_bug.cgi?id=116290
1882 Follow an update to the spec and support the new and old syntax.
1884 Reviewed by Timothy Hatcher.
1886 * inspector/ContentSearchUtils.cpp:
1887 (WebCore::ContentSearchUtils::scriptCommentPattern):
1888 (WebCore::ContentSearchUtils::stylesheetCommentPattern):
1889 * inspector/front-end/SASSSourceMapping.js:
1890 (WebInspector.SASSSourceMapping.prototype._loadAndProcessSourceMap):
1892 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1894 Remove custom code for MessageEvent.ports getter
1895 https://bugs.webkit.org/show_bug.cgi?id=116304
1897 Reviewed by Kentaro Hara.
1899 Remove Custom code for the "ports" attribute getter in MessageEvent
1900 IDL interface. The JSC bindings generator already supports attributes
1901 of type MessagePortArray.
1903 No new tests, already covered by existing layout tests and bindings
1906 * bindings/js/JSMessageEventCustom.cpp: Remove Custom code for ports getter.
1907 * bindings/scripts/CodeGeneratorJS.pm:
1908 (NativeToJSValue): Small tweak to correctly handle the case where impl->ports()
1909 returns NULL and avoid crashing in this case.
1910 * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp: Rebaseline due
1911 to bindings generator tweak.
1912 * dom/MessageEvent.idl: Remove [CustomGetter] extended attribute for 'ports' attribute
1913 and switch to MessagePortArray type.
1915 2013-05-16 Jesus Sanchez-Palencia <jesus.palencia@openbossa.org>
1917 Add stubs for ContextMenu and ContextMenuItem
1918 https://bugs.webkit.org/show_bug.cgi?id=116235
1920 Reviewed by Antonio Gomes.
1922 No new tests needed, only a refactor.
1924 Add ContextMenuNone.cpp and ContextMenuItemNone.cpp
1925 so ports using ENABLE(CROSS_PLATFORM_CONTEXT_MENU) don't
1926 need to replicate these stubs.
1928 * PlatformEfl.cmake:
1930 * platform/ContextMenuNone.cpp: Added.
1932 (WebCore::ContextMenu::ContextMenu):
1933 (WebCore::ContextMenu::getContextMenuItems):
1934 (WebCore::ContextMenu::createPlatformContextMenuFromItems):
1935 (WebCore::ContextMenu::platformContextMenu):
1936 * platform/ContextMenuItemNone.cpp: Added.
1938 (WebCore::ContextMenuItem::platformContextMenuItem):
1939 * platform/efl/ContextMenuEfl.cpp: Removed.
1940 * platform/efl/ContextMenuItemEfl.cpp: Removed.
1941 * platform/qt/ContextMenuQt.cpp: Removed.
1942 * platform/qt/ContextMenuItemQt.cpp: Removed.
1944 2013-05-16 Alexis Menard <alexis@webkit.org>
1946 Regression: Event#stopPropagation() does not halt bubbling for webkitTransitionEnd
1947 https://bugs.webkit.org/show_bug.cgi?id=115656
1949 Reviewed by Darin Adler.
1951 If we create a prefixed event to dispatch it (in the case we have only
1952 prefixed event listeners in client's code) then we need to make sure to
1953 keep it in sync with the original unprefixed event after it has been
1954 dispatched. While being dispatched the event can be modified by
1955 client's code and when propagated back to outer elements, attributes were
1956 not updated. This patch changes the old design of creating a separate event
1957 for the prefixed case and now change the type of the event (so the name) before
1958 dispatching it, keeping the attributes if changed and then rename it
1959 back to unprefixed when the dispatching is finished.
1961 Tests: transitions/transition-end-event-prefixed-01.html
1962 transitions/transition-end-event-prefixed-02.html
1963 transitions/transition-end-event-prefixed-03.html
1966 (WebCore::Event::setType):
1967 * dom/EventTarget.cpp:
1968 (WebCore::EventTarget::fireEventListeners):
1970 2013-05-16 Mike Fenton <mifenton@rim.com>
1972 [BlackBerry] Strip invoke URLs when writing to the clipboard.
1973 https://bugs.webkit.org/show_bug.cgi?id=116226
1975 Reviewed by Rob Buis.
1979 Invoke URLs should not be included in the paste data.
1981 Internally Reviewed by Gen Mak.
1983 * platform/blackberry/PasteboardBlackBerry.cpp:
1984 (WebCore::Pasteboard::writeSelection):
1986 2013-05-16 Eduardo Lima Mitev <elima@igalia.com>
1988 Missing UNUSED_PARAM macro for textPosition argument in WebKitAccessibleInterfaceText
1989 https://bugs.webkit.org/show_bug.cgi?id=116230
1991 Reviewed by Chris Fleizach.
1993 No new functionality, no new tests.
1995 * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
1996 (webkitAccessibleTextGetTextForOffset): List textPosition argument as
1997 unused parameter for all platforms except GTK.
1999 2013-05-16 Jaehun Lim <ljaehun.lim@samsung.com>
2001 Frame flattening prevents <HTML> in <OBJECT> from having scrollbars
2002 https://bugs.webkit.org/show_bug.cgi?id=115884
2004 Reviewed by Antonio Gomes.
2006 Frame flattening should be applied when the frame owner is frame or iframe. But when
2007 the frame owner is object element, frame flattening prevents it from having scrollbars.
2008 In this situation, we can't scroll the html document in object element.
2010 This patch adds two helper functions to verify flattening conditions.
2012 Test: fast/frames/flattening/scrolling-in-object.html
2014 * page/FrameView.cpp:
2015 (WebCore::frameFlatteningEnabled): Added. Helper to check whether flattening is enabled or not.
2016 (WebCore::supportsFrameFlattening): Added. Helper to check whether the frame owner is <frame> or <iframe>.
2017 (WebCore::FrameView::avoidScrollbarCreation):
2018 (WebCore::FrameView::calculateScrollbarModesForLayout): Use frameFlatteningEnabled().
2019 (WebCore::FrameView::layout): Use frameFlatteningEnabled().
2020 (WebCore::FrameView::isInChildFrameWithFrameFlattening): Use frameFlatteningEnabled().
2022 2013-05-16 Patrick Gansterer <paroga@webkit.org>
2024 Port functions for pathhandling to Windows CE in FileSystemWin
2025 https://bugs.webkit.org/show_bug.cgi?id=116208
2027 Reviewed by Darin Adler.
2029 This will allow us to remove FileSystemWinCE in a next step.
2031 * platform/win/FileSystemWin.cpp:
2032 (WebCore::pathByAppendingComponent):
2033 (WebCore::pathGetFileName):
2035 2013-05-16 Tim Horton <timothy_horton@apple.com>
2037 PDFPlugins don't load when plugins are disabled, but they should
2038 https://bugs.webkit.org/show_bug.cgi?id=75790
2039 <rdar://problem/11650197>
2041 Reviewed by Anders Carlsson.
2043 Make it possible to load "application" plug-ins even if settings or the FrameLoaderClient
2044 say that plug-ins should be disabled, providing a mechanism for WebKit* to offer built-in
2045 functionality which happens to use the plug-in infrastructure, and which also doesn't
2046 unexpectedly disappear for users with plug-ins off.
2049 Export SubframeLoader::allowPlugins().
2050 Update signature for PluginData::supportsMimeType to include the AllowedPluginTypes argument.
2052 * dom/DOMImplementation.cpp:
2053 (WebCore::DOMImplementation::createDocument):
2054 Load PluginData even if plug-ins are disabled, but if that is the case, only
2055 create a PluginDocument for application plug-ins.
2057 * html/PluginDocument.cpp:
2058 (WebCore::PluginDocumentParser::appendBytes):
2059 Don't bail if plug-ins are disabled, because we could still be a PluginDocument
2060 for an application plug-in.
2063 (WebCore::Page::pluginData):
2064 Allow PluginData to be constructed even if plug-ins are disabled, as there might
2065 be application plug-ins that we want to load anyway.
2067 * platform/mac/MIMETypeRegistryMac.mm:
2068 (WebCore::MIMETypeRegistry::isApplicationPluginMIMEType):
2069 On Mac, if we have PDFPlugin, we can support PDF and PostScript with a native application plug-in.
2071 * plugins/PluginData.cpp:
2072 (WebCore::PluginData::supportsMimeType):
2073 Add an AllowedPluginTypes argument to supportsMimeType, allowing callers to specify
2074 whether they are looking for any plug-in, or are looking only for application plug-ins.
2076 * plugins/PluginData.h:
2077 (PluginInfo): Added an isApplicationPlugin field, to specify whether this is a "built-in" plug-in.
2078 (PluginData): Add the aforementioned AllowedPluginTypes enum and the argument to supportsMimeType.
2080 2013-05-16 Carlos Garcia Campos <cgarcia@igalia.com>
2082 [BlackBerry] Crash due to an assert running test editing/execCommand/indent-paragraphs.html
2083 https://bugs.webkit.org/show_bug.cgi?id=114944
2085 Reviewed by Rob Buis.
2087 It crashes in network platform code when trying to save an
2088 invalid URL in the disk cache. That test contains references to
2089 empty URLs like http://. Those empty URLs, are parsed as http:/ by
2090 KURL and considered valid. BlackBerry network platform uses GURL
2091 which considers those URLs invalid. We needed to check that the
2092 URLs are valid for our platform before starting the network
2095 Fixes a crash running test
2096 editing/execCommand/indent-paragraphs.html.
2098 * platform/network/blackberry/NetworkManager.cpp:
2099 (WebCore::NetworkManager::startJob): Check if the request URL is
2100 valid from the platform point of view right after creating the
2101 platform network request and return early if the URL is invalid
2102 with StatusErrorInvalidUrl error.
2104 2013-05-16 Patrick Gansterer <paroga@webkit.org>
2106 Remove unused function safeCreateFile() from WebCore
2107 https://bugs.webkit.org/show_bug.cgi?id=116211
2109 Reviewed by Anders Carlsson.
2111 * platform/FileSystem.h:
2112 * platform/win/FileSystemWin.cpp:
2114 2013-05-16 Peter Gal <galpeter@inf.u-szeged.hu>
2116 [curl] MIME type should be in lowercase
2117 https://bugs.webkit.org/show_bug.cgi?id=116218
2119 Reviewed by Benjamin Poulain.
2121 Existing testcase: http/tests/mime/uppercase-mime-type.html
2123 * platform/network/curl/ResourceHandleManager.cpp:
2124 (WebCore::headerCallback): Convert the MIME type to lowercase.
2126 2013-05-16 Seokju Kwon <seokju.kwon@gmail.com>
2128 Web Inspector: Fix optional value of promptText in Inspector.json
2129 https://bugs.webkit.org/show_bug.cgi?id=116203
2131 Reviewed by Joseph Pecoraro.
2133 Merge from https://chromiumcodereview.appspot.com/14672031.
2135 No new tests needed.
2137 * inspector/Inspector.json:
2139 2013-05-16 Mary Wu <mary.wu@torchmobile.com.cn>
2141 [BlackBerry] Unable to download blob resource
2142 https://bugs.webkit.org/show_bug.cgi?id=115888
2144 Reviewed by Benjamin Poulain.
2146 Add BlobStream to handle over blob data from BlobResourceHandle to download stream.
2147 RIM bug 331086, internally reviewed by Charles Wei and Leo Yang.
2149 * PlatformBlackBerry.cmake:
2150 * platform/network/blackberry/BlobStream.cpp: Added.
2152 (WebCore::BlobStream::BlobStream):
2153 (WebCore::BlobStream::~BlobStream):
2154 (WebCore::BlobStream::didReceiveData):
2155 (WebCore::BlobStream::didFinishLoading):
2156 (WebCore::BlobStream::didFail):
2157 (WebCore::BlobStream::url):
2158 (WebCore::BlobStream::mimeType):
2159 * platform/network/blackberry/BlobStream.h: Added.
2163 2013-05-16 Anders Carlsson <andersca@apple.com>
2165 Remove SystemTime header and implementations
2166 https://bugs.webkit.org/show_bug.cgi?id=116200
2168 Reviewed by Alexey Proskuryakov.
2170 SystemTim just had a single function that's not called anymore. Remove it.
2172 * GNUmakefile.list.am:
2173 * PlatformBlackBerry.cmake:
2174 * PlatformEfl.cmake:
2175 * PlatformWinCE.cmake:
2177 * WebCore.vcproj/WebCore.vcproj:
2178 * WebCore.vcxproj/WebCore.vcxproj:
2179 * WebCore.vcxproj/WebCore.vcxproj.filters:
2180 * WebCore.xcodeproj/project.pbxproj:
2181 * history/PageCache.cpp:
2182 * platform/SystemTime.h: Removed.
2183 * platform/blackberry/SystemTimeBlackBerry.cpp: Removed.
2184 * platform/efl/SystemTimeEfl.cpp: Removed.
2185 * platform/graphics/ca/GraphicsLayerCA.cpp:
2186 * platform/mac/SystemTimeMac.cpp: Removed.
2187 * platform/qt/TemporaryLinkStubsQt.cpp:
2188 * platform/win/SystemTimeWin.cpp: Removed.
2190 2013-05-16 Glenn Adams <glenn@skynav.com>
2192 [Inspector] Don't filter syntax error caused by asterisk in CSS Property name.
2193 https://bugs.webkit.org/show_bug.cgi?id=116196
2195 Reviewed by Benjamin Poulain.
2197 * inspector/InspectorConsoleAgent.cpp:
2198 (WebCore::InspectorConsoleAgent::addMessageToConsole):
2199 - Remove questionable IE7 related error filtering
2201 2013-05-16 Andreas Kling <akling@apple.com>
2203 Page::chrome() should return a reference.
2204 <http://webkit.org/b/116185>
2206 Reviewed by Anders Carlsson.
2208 A Page's chrome() can never be null. Change Page::chrome() to return a reference to reflect this.
2209 Also, make Page::m_chrome a const member variable so nobody will accidentally set it to null.
2211 2013-05-16 Simon Fraser <simon.fraser@apple.com>
2213 Content disappears when scrolling http://www.childrenscancer.org/zach/
2214 https://bugs.webkit.org/show_bug.cgi?id=116206
2216 Reviewed by Darin Adler.
2218 When a RenderLayerBacking gains or loses a foregroundLayer or backgroundLayer,
2219 we need to repaint the primary layer, since what paints into that primary
2222 On the page in question, we gained/lost a foreground layer when scrolling because
2223 the page popped an element into position:fixed.
2225 Test: compositing/repaint/foreground-layer-change.html
2227 * rendering/RenderLayerBacking.cpp:
2228 (WebCore::RenderLayerBacking::updateForegroundLayer):
2229 (WebCore::RenderLayerBacking::updateBackgroundLayer):
2231 2013-05-16 Andy Estes <aestes@apple.com>
2233 Do not indefinitely cache resources from blob URLs.
2235 Reviewed by Alexey Proskuryakov.
2237 Alexey pointed out after I landed r150169 that blob URLs backed by
2238 files should return an error if the file changed after the URL was
2239 created. By indefinitely caching them in memory, we don't give the
2240 loader a chance to check for modification. Remove "blob" from the list
2241 of schemes that should be indefinitely cached.
2243 * platform/SchemeRegistry.cpp:
2244 (WebCore::SchemeRegistry::shouldCacheResponsesFromURLSchemeIndefinitely):
2246 2013-05-16 Claudio Saavedra <csaavedra@igalia.com>
2248 [CSS] CSS Variables are case-sensitive
2249 https://bugs.webkit.org/show_bug.cgi?id=116239
2251 Reviewed by Ryosuke Niwa.
2253 The CSS Variables specification states that variables are
2254 case-sensitive, unlike other CSS properties.
2256 Test: fast/css/variables/case-sensitive.html
2258 * css/CSSParser.cpp:
2259 (WebCore::CSSParserString::substring): Replace
2260 the now unnecessary lowerSubstring() with this method.
2261 Also, since the method is only used by the CSS variables
2262 implementation, #ifdef it.
2263 (WebCore::CSSParser::createPrimitiveVariableNameValue):
2264 (WebCore::CSSParser::storeVariableDeclaration):
2265 Do not normalize variable declarations to lowercase.
2266 * css/CSSParserValues.h:
2267 (CSSParserString): Replace the lowerSubstring() declaration
2268 and wrap with #if/#endif.
2270 2013-05-16 Brady Eidson <beidson@apple.com>
2272 svg/as-image/img-zoom-svg-stylesheet.html crashes with NetworkProcess enabled.
2273 <rdar://problem/13837408> and https://bugs.webkit.org/show_bug.cgi?id=115917
2275 Reviewed by Sam Weinig.
2277 Give WebKit2 the ability to not mis-cast.
2279 * loader/FrameLoaderClient.h:
2280 (WebCore::FrameLoaderClient::isEmptyFrameLoaderClient): Defaults to false, and include a FIXME
2281 to remove it once https://bugs.webkit.org/show_bug.cgi?id=116233 is resolved.
2283 * loader/EmptyClients.h: Make isEmptyFrameLoaderClient() return true, and add a FIXME to remove it.
2285 2013-05-14 Martin Robinson <mrobinson@igalia.com>
2287 [GTK] Add support for building WebCore to the cmake build
2288 https://bugs.webkit.org/show_bug.cgi?id=116128
2290 Reviewed by Gustavo Noronha Silva.
2292 * PlatformGTK.cmake: Added.
2293 * platform/gtk/GtkVersioning.c: Include "config.h" because we removed
2294 the autotoolsconfig.h include from the header.
2295 * platform/gtk/GtkVersioning.h: Remove autotoolsconfig.h include to support for
2296 non-autotools build systems.
2298 2013-05-15 Ryosuke Niwa <rniwa@webkit.org>
2300 DocumentOrderedMap doesn't need to have two HashMaps
2301 https://bugs.webkit.org/show_bug.cgi?id=116167
2303 Reviewed by Geoffrey Garen.
2305 Previously, we had two hash maps: m_map and m_duplicateCounts in DocumentOrderedMap to keep track
2306 of the first element and the number of duplicates for a given name. This patch simplifies this structure
2307 by having a single hash map that contains both the pointer and the number of duplicates.
2309 In addition, this patch fixes a regression introduced in r149652 that window and document name maps
2310 were not updated for some elements inside a SVG use element, and makes use of the newly added list of
2311 the matching elements in SelectorQuery.
2313 * dom/DocumentOrderedMap.cpp:
2314 (WebCore::DocumentOrderedMap::clear): Updated to use the new hash map.
2315 (WebCore::DocumentOrderedMap::add): Ditto.
2316 (WebCore::DocumentOrderedMap::remove): Ditto.
2317 (WebCore::DocumentOrderedMap::get): Ditto.
2318 (WebCore::DocumentOrderedMap::getAllElementsById): Added.
2320 * dom/DocumentOrderedMap.h:
2322 (WebCore::DocumentOrderedMap::MapEntry::MapEntry): Added.
2323 (WebCore::DocumentOrderedMap::containsSingle): Updated to use new hash map.
2324 (WebCore::DocumentOrderedMap::contains): Ditto.
2325 (WebCore::DocumentOrderedMap::containsMultiple): Ditto.
2328 (WebCore::Element::insertedInto): This function didn't add this element to window and document's name maps
2329 if the element had already been inserted into a tree scope, and the current call was inserting an ancestor
2330 of the tree scope into the document. We were exiting early per scope != treeScope().
2332 Fixed the bug by splitting updateId into two functions updateIdForTreeScope and updateIdForDocument.
2333 The former is called when this element is inserted into a new tree scope, and the latter is called when
2334 this element is inserted into a HTML document even if it had already been inside some tree scope.
2336 (WebCore::Element::removedFrom): This function didn't remove this element from tree scope's id maps if
2337 the tree scope wasn't a document. Fixed the bug by simply checking that the removal happens beneath the
2339 (WebCore::Element::updateName):
2340 (WebCore::Element::updateNameForTreeScope): Renamed from updateName.
2341 (WebCore::Element::updateNameForDocument): Extracted from updateName.
2342 (WebCore::Element::updateId):
2343 (WebCore::Element::updateIdForTreeScope): Renamed from updateId.
2344 (WebCore::Element::updateIdForDocument): Extracted from updateId.
2348 * dom/SelectorQuery.cpp:
2349 (WebCore::SelectorDataList::canUseIdLookup): Refactored to return the id subselector instead of checking if
2350 the first subselector happens to be matching an id.
2351 (WebCore::SelectorDataList::execute): Use the subselector canUseIdLookup returned. Also make use of newly
2352 added getAllElementsById when there are multiple matching elements for a given id.
2354 * dom/SelectorQuery.h:
2356 * dom/TreeScope.cpp:
2357 (WebCore::TreeScope::getAllElementsById): Added.
2361 2013-05-15 Darin Adler <darin@apple.com>
2363 [Mac] Make Clipboard::create functions for Mac platform independent by moving Pasteboard creation to Pasteboard functions
2364 https://bugs.webkit.org/show_bug.cgi?id=116179
2366 Reviewed by Andreas Kling.
2368 * dom/Clipboard.cpp:
2369 (WebCore::Clipboard::createForCopyAndPaste): Moved the function here from
2370 ClipboardMac, and have it use Pasteboard functions that are not Mac-specific.
2371 (WebCore::Clipboard::create): Ditto.
2372 (WebCore::Clipboard::createForDragAndDrop): Ditto.
2374 * platform/DragData.h:
2375 (WebCore::DragData::pasteboardName): Made this const.
2377 * platform/Pasteboard.h: Added new create functions, used by the clipboard
2378 create functions above.
2380 * platform/mac/ClipboardMac.mm: Removed the functions that were moved to the
2383 * platform/mac/PasteboardMac.mm:
2384 (WebCore::Pasteboard::createForCopyAndPaste): Added.
2385 (WebCore::Pasteboard::createPrivate): Added.
2386 (WebCore::Pasteboard::createForDragAndDrop): Added.
2388 2013-05-15 Anders Carlsson <andersca@apple.com>
2392 We want to invalidate the file icon loader if it exists, not create it!
2394 * html/FileInputType.cpp:
2395 (WebCore::FileInputType::requestIcon):
2397 2013-05-15 Darin Adler <darin@apple.com>
2399 Move drag-specific Clipboard functions inside ENABLE(DRAG_SUPPORT)
2400 https://bugs.webkit.org/show_bug.cgi?id=116176
2402 Reviewed by Andreas Kling.
2404 * dom/Clipboard.cpp:
2405 (WebCore::Clipboard::writeRange):
2406 (WebCore::Clipboard::writePlainText):
2407 (WebCore::Clipboard::writeURL):
2408 Move these three functions inside ENABLE(DRAG_SUPPORT). Even though their names do
2409 not make it obvious, these are here only for use by dragging code. Later we may
2410 refactor them away entirely, but for now it's good not to compile them in on any
2411 platform that does not support dragging.
2413 2013-05-15 Andy Estes <aestes@apple.com>
2415 Resources from non-HTTP schemes should not be cached indefinitely
2416 https://bugs.webkit.org/show_bug.cgi?id=113626
2418 Reviewed by Ryosuke Niwa.
2420 With the exception of schemes that we know will always return the same
2421 result for a given URL, we should not indefinitely cache non-HTTP
2422 resources when their freshness cannot be verified.
2424 Writing a test for this is blocked on https://webkit.org/b/116199.
2426 The following two existing tests of memory cache behavior were
2427 converted to HTTP tests so that they continue to function as expected:
2429 Tests: http/tests/cache/display-image-unset-allows-cached-image-load.html
2430 http/tests/cache/willsendrequest-returns-null-for-memory-cache-load.html
2432 * loader/cache/CachedResource.cpp:
2433 (WebCore::CachedResource::freshnessLifetime): Returned a freshness
2434 lifetime of 0 for non-HTTP schemes that can't be indefinitely cached.
2435 * platform/SchemeRegistry.cpp:
2436 (WebCore::SchemeRegistry::shouldCacheResponsesFromURLSchemeIndefinitely):
2437 Checked whether the scheme is blob:, data:, or applewebdata:.
2438 * platform/SchemeRegistry.h:
2440 2013-05-15 Tim Horton <timothy_horton@apple.com>
2442 makeRGBAFromNSColor throws an exception if given a color in a greyscale colorspace
2443 https://bugs.webkit.org/show_bug.cgi?id=116198
2444 <rdar://problem/13904395>
2446 Reviewed by Simon Fraser.
2448 Block Objective-C exceptions in makeRGBAFromNSColor.
2449 Remove a comment saying that they're impossible.
2451 Convert the incoming color to the DeviceRGB colorspace to match
2452 existing color sources. Some rare cases (attributed strings that come
2453 from PDFKit) can have DeviceGrayscale color spaces, which would
2454 previously throw an exception here.
2456 * platform/graphics/mac/ColorMac.mm:
2457 (WebCore::makeRGBAFromNSColor):
2459 2013-05-15 David Kilzer <ddkilzer@apple.com>
2461 BUILD FIX (r150140): Frame::editor() should return a reference for iOS, too
2463 * platform/ios/ClipboardIOS.mm:
2464 (WebCore::ClipboardIOS::ClipboardIOS):
2465 (WebCore::ClipboardIOS::hasData):
2466 (WebCore::ClipboardIOS::clearData):
2467 (WebCore::ClipboardIOS::clearAllData):
2468 (WebCore::ClipboardIOS::getData):
2469 (WebCore::ClipboardIOS::setData):
2470 (WebCore::ClipboardIOS::types):
2471 (WebCore::ClipboardIOS::writeRange):
2472 * platform/ios/PasteboardIOS.mm:
2473 (WebCore::Pasteboard::getStringSelection):
2474 (WebCore::Pasteboard::writeSelection):
2475 (WebCore::Pasteboard::writePlainText):
2476 (WebCore::Pasteboard::writeImage):
2477 (WebCore::Pasteboard::plainText):
2478 (WebCore::documentFragmentWithRTF):
2479 (WebCore::Pasteboard::documentFragmentForPasteboardItemAtIndex):
2480 (WebCore::Pasteboard::documentFragment):
2482 2013-05-15 Anders Carlsson <andersca@apple.com>
2484 Stop using the factory pattern in FileIconLoaderClient
2485 https://bugs.webkit.org/show_bug.cgi?id=116197
2487 Reviewed by Andreas Kling.
2489 Move the FileIconLoader member out of FileIconLoaderClient and into FileInputType and remove the factory gunk.
2491 * html/FileInputType.cpp:
2492 (WebCore::FileInputType::~FileInputType):
2493 (WebCore::FileInputType::requestIcon):
2494 * html/FileInputType.h:
2496 * platform/FileIconLoader.cpp:
2497 (WebCore::FileIconLoader::invalidate):
2498 * platform/FileIconLoader.h:
2499 (WebCore::FileIconLoaderClient::~FileIconLoaderClient):
2502 2013-05-15 Anders Carlsson <andersca@apple.com>
2504 Fix FileChooserClient design
2505 https://bugs.webkit.org/show_bug.cgi?id=116195
2507 Reviewed by Andreas Kling.
2509 FileChooserClient doesn't match the standard WebCore client idiom of only having virtual member functions.
2510 Instead it holds on to its FileChooser and it's even a factory for creating new file choosers(!).
2512 Fix this by making it an abstract class, and moving FileChooser into FileInputType.
2514 * html/FileInputType.cpp:
2515 (WebCore::FileInputType::~FileInputType):
2516 Invalidate the file chooser.
2518 (WebCore::FileInputType::handleDOMActivateEvent):
2519 Apply the file chooser settings.
2521 (WebCore::FileInputType::applyFileChooserSettings):
2522 Recreate the file chooser with new settings.
2524 (WebCore::FileInputType::receiveDropForDirectoryUpload):
2527 * platform/FileChooser.cpp:
2528 (WebCore::FileChooser::invalidate):
2529 Set m_client to null.
2531 (WebCore::FileChooser::chooseFiles):
2534 * platform/FileChooser.h:
2536 2013-05-15 Gavin Barraclough <barraclough@apple.com>
2538 ScriptedAnimationController::setThrottled should extend MinimumAnimationInterval
2539 https://bugs.webkit.org/show_bug.cgi?id=116193
2541 Reviewed by Darin Adler
2543 * dom/ScriptedAnimationController.cpp:
2544 (WebCore::ScriptedAnimationController::ScriptedAnimationController):
2545 (WebCore::ScriptedAnimationController::setThrottled):
2546 (WebCore::ScriptedAnimationController::scheduleAnimation):
2547 * dom/ScriptedAnimationController.h:
2548 (ScriptedAnimationController):
2549 - Fixes for review comments.
2551 2013-05-15 Anders Carlsson <andersca@apple.com>
2553 Move HTTPRequest class to WebKit2
2554 https://bugs.webkit.org/show_bug.cgi?id=116192
2556 Reviewed by Darin Adler.
2558 HTTPRequest is only used by the "remote inspector" feature in WebKit2,
2559 so there's no need to have it in WebCore.
2562 * GNUmakefile.list.am:
2564 * WebCore.vcproj/WebCore.vcproj:
2565 * WebCore.vcxproj/WebCore.vcxproj:
2566 * WebCore.vcxproj/WebCore.vcxproj.filters:
2567 * WebCore.xcodeproj/project.pbxproj:
2569 2013-05-15 Oliver Hunt <oliver@apple.com>
2571 RefCountedArray needs to use vector initialisers for its backing store
2572 https://bugs.webkit.org/show_bug.cgi?id=116194
2574 Reviewed by Gavin Barraclough.
2576 Update to use new functions for operating on the exception stack.
2578 * bindings/js/ScriptCallStackFactory.cpp:
2579 (WebCore::createScriptCallStackFromException):
2581 2013-05-15 Gavin Barraclough <barraclough@apple.com>
2583 ScriptedAnimationController::setThrottled should extend MinimumAnimationInterval
2584 https://bugs.webkit.org/show_bug.cgi?id=116193
2586 Reviewed by Simon Fraser.
2588 * dom/ScriptedAnimationController.cpp:
2589 (WebCore::ScriptedAnimationController::ScriptedAnimationController):
2590 - initialize m_throttled
2591 (WebCore::ScriptedAnimationController::setThrottled):
2592 - sets m_throttled, reschedule when this changes.
2593 (WebCore::ScriptedAnimationController::scheduleAnimation):
2594 - if throtled don't use a display link, and extend the timeout.
2595 * dom/ScriptedAnimationController.h:
2596 (ScriptedAnimationController):
2599 2013-05-08 Gavin Barraclough <barraclough@apple.com>
2601 Process suppression should throttle scripted animations
2602 https://bugs.webkit.org/show_bug.cgi?id=115812
2604 Reviewed by Simon Fraser.
2606 <rdar://problem/13799726>
2609 - Expose Page::setThrottled
2611 (WebCore::Document::scriptedAnimationControllerSetThrottled):
2615 - Forwards to ScriptedAnimationController::setThrottled
2616 * dom/ScriptedAnimationController.cpp:
2617 (WebCore::ScriptedAnimationController::setThrottled):
2619 * dom/ScriptedAnimationController.h:
2620 - Force use of a timer.
2621 (ScriptedAnimationController):
2623 (WebCore::Page::setThrottled):
2627 - When under throttling force the ScriptedAnimationController to use a timer.
2629 2013-05-15 Igor Oliveira <igor.o@sisa.samsung.com>
2631 Implement run-in remove child cases.
2632 https://bugs.webkit.org/show_bug.cgi?id=86520
2634 Move runin to original position when sibling element is destroyed.
2636 Reviewed by David Hyatt.
2638 Tests: fast/runin/runin-remove-child-simple.html
2639 fast/runin/runin-sibling-inline.html
2641 * rendering/RenderBlock.cpp:
2642 (WebCore::RenderBlock::willBeDestroyed):
2643 (WebCore::RenderBlock::moveRunInUnderSiblingBlockIfNeeded):
2644 If moveRunInUnderSiblingBlockIfNeeded is called when the sibling run-in block
2645 is being destroyed, it means that the run-in is moving to original position and
2646 we do not need to do nothing.
2648 2013-05-15 Anders Carlsson <andersca@apple.com>
2650 Remove WebSocketHandshakeResponse class
2651 https://bugs.webkit.org/show_bug.cgi?id=116190
2653 Reviewed by Andreas Kling.
2655 Just use ResourceResponse instead of WebSocketHandshakeResponse.
2658 * GNUmakefile.list.am:
2659 * Modules/websockets/WebSocketHandshake.cpp:
2660 (WebCore::WebSocketHandshake::readServerHandshake):
2661 (WebCore::WebSocketHandshake::serverWebSocketProtocol):
2662 (WebCore::WebSocketHandshake::serverSetCookie):
2663 (WebCore::WebSocketHandshake::serverSetCookie2):
2664 (WebCore::WebSocketHandshake::serverUpgrade):
2665 (WebCore::WebSocketHandshake::serverConnection):
2666 (WebCore::WebSocketHandshake::serverWebSocketAccept):
2667 (WebCore::WebSocketHandshake::serverHandshakeResponse):
2668 (WebCore::WebSocketHandshake::readHTTPHeaders):
2669 * Modules/websockets/WebSocketHandshake.h:
2670 * Modules/websockets/WebSocketHandshakeResponse.cpp: Removed.
2671 * Modules/websockets/WebSocketHandshakeResponse.h: Removed.
2673 * WebCore.vcproj/WebCore.vcproj:
2674 * WebCore.vcxproj/WebCore.vcxproj:
2675 * WebCore.vcxproj/WebCore.vcxproj.filters:
2676 * WebCore.xcodeproj/project.pbxproj:
2677 * inspector/InspectorInstrumentation.cpp:
2679 (WebCore::InspectorInstrumentation::didReceiveWebSocketHandshakeResponseImpl):
2680 * inspector/InspectorInstrumentation.h:
2681 (InspectorInstrumentation):
2682 (WebCore::InspectorInstrumentation::didReceiveWebSocketHandshakeResponse):
2683 * inspector/InspectorResourceAgent.cpp:
2684 (WebCore::InspectorResourceAgent::didReceiveWebSocketHandshakeResponse):
2685 * inspector/InspectorResourceAgent.h:
2687 (InspectorResourceAgent):
2689 2013-05-15 Eric Carlson <eric.carlson@apple.com>
2691 [Mac] media engine may deliver NULL in-band "cue"
2692 https://bugs.webkit.org/show_bug.cgi?id=116180
2694 Reviewed by Jer Noble.
2696 * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
2697 (WebCore::InbandTextTrackPrivateAVF::processCue): NULL check before logging cue count.
2699 2013-05-15 Darin Adler <darin@apple.com>
2701 List platforms that still use the legacy clipboard instead of just saying "not Mac"
2702 https://bugs.webkit.org/show_bug.cgi?id=116177
2704 Reviewed by Andreas Kling.
2706 * dom/Clipboard.h: Replaced the "!MAC || IOS" with a list of platforms still on the
2709 2013-05-15 Yongjun Zhang <yongjun_zhang@apple.com>
2711 We should clear mainResource in DocumentLoader::cancelMainResourceLoad.
2712 https://bugs.webkit.org/show_bug.cgi?id=116119
2714 Reviewed by Oliver Hunt.
2716 MainResourceLoader::clearResource() was left out in r146239 when moving MainResourceLoader::cancel()
2717 to DocumentLoader::cancelMainResourceLoad(), we need to add it back to make sure m_mainResource is
2718 cleared when we cancel the loader.
2720 No new tests needed.
2722 * loader/DocumentLoader.cpp:
2723 (WebCore::DocumentLoader::~DocumentLoader):
2724 (WebCore::DocumentLoader::continueAfterNavigationPolicy):
2725 (WebCore::DocumentLoader::cancelMainResourceLoad):
2726 (WebCore::DocumentLoader::clearMainResource):
2728 * loader/DocumentLoader.h: add helper method clearMainResource()
2731 2013-05-15 Joe Mason <jmason@blackberry.com>
2733 [BlackBerry] When HTTP auth fails, only purge credentials that match the failed credentials
2734 https://bugs.webkit.org/show_bug.cgi?id=116164
2736 Reviewed by Rob Buis.
2739 Internally Reviewed By: Lyon Chen
2741 When there are multiple HTTP requests in flight with the same bad credentials (common with
2742 proxy auth if the user mistyped their password), the first 407 that's received will cause
2743 the credentials to be purged and the password dialog to open for new credentials. This means
2744 that all 407's received after this should only purge the credentials if they have not
2745 already been updated from the dialog; otherwise they will be wiping out credentials that
2748 * platform/network/blackberry/NetworkJob.cpp:
2749 (WebCore::NetworkJob::sendRequestWithCredentials):
2750 (WebCore::NetworkJob::purgeCredentials):
2752 2013-05-15 Chris Fleizach <cfleizach@apple.com>
2754 AX: Use caching when requesting children object on iOS
2755 https://bugs.webkit.org/show_bug.cgi?id=116112
2757 Reviewed by David Kilzer.
2759 Building up the children list in the AX hierarchy can be time consuming. On iOS, this
2760 is now much more noticeable (I believe due to the way tables calculate their AX ignored flag).
2762 We can speed everything up if we just cache the isIgnored() attribute while building up children.
2764 * accessibility/AXObjectCache.cpp:
2765 (WebCore::AXAttributeCacheEnabler::AXAttributeCacheEnabler):
2767 (WebCore::AXAttributeCacheEnabler::~AXAttributeCacheEnabler):
2768 * accessibility/AXObjectCache.h:
2769 (AXAttributeCacheEnabler):
2771 * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
2772 (-[WebAccessibilityObjectWrapper accessibilityHitTest:]):
2773 (-[WebAccessibilityObjectWrapper accessibilityElementCount]):
2774 (-[WebAccessibilityObjectWrapper accessibilityElementAtIndex:]):
2775 (-[WebAccessibilityObjectWrapper indexOfAccessibilityElement:]):
2776 (-[WebAccessibilityObjectWrapper accessibilityContainer]):
2778 2013-05-15 Anders Carlsson <andersca@apple.com>
2780 Remove WebSocketHandshakeRequest class
2781 https://bugs.webkit.org/show_bug.cgi?id=116178
2783 Reviewed by Andreas Kling.
2785 Turns out WebSocketHandshakeRequest is just used by the web inspector, and there's no reason
2786 why we can't just use a ResourceRequest instead.
2789 * GNUmakefile.list.am:
2790 * Modules/websockets/WebSocketChannel.cpp:
2791 (WebCore::WebSocketChannel::didOpenSocketStream):
2792 * Modules/websockets/WebSocketHandshake.cpp:
2793 (WebCore::WebSocketHandshake::clientHandshakeRequest):
2794 * Modules/websockets/WebSocketHandshake.h:
2796 * Modules/websockets/WebSocketHandshakeRequest.cpp: Removed.
2797 * Modules/websockets/WebSocketHandshakeRequest.h: Removed.
2799 * WebCore.vcproj/WebCore.vcproj:
2800 * WebCore.vcxproj/WebCore.vcxproj:
2801 * WebCore.vcxproj/WebCore.vcxproj.filters:
2802 * WebCore.xcodeproj/project.pbxproj:
2803 * inspector/InspectorInstrumentation.cpp:
2805 (WebCore::InspectorInstrumentation::willSendWebSocketHandshakeRequestImpl):
2806 * inspector/InspectorInstrumentation.h:
2807 (InspectorInstrumentation):
2808 (WebCore::InspectorInstrumentation::willSendWebSocketHandshakeRequest):
2809 * inspector/InspectorResourceAgent.cpp:
2810 (WebCore::InspectorResourceAgent::willSendWebSocketHandshakeRequest):
2811 * inspector/InspectorResourceAgent.h:
2813 (InspectorResourceAgent):
2814 * platform/network/HTTPRequest.cpp:
2817 2013-05-15 Darin Adler <darin@apple.com>
2819 Try to fix iOS build.
2821 * platform/Pasteboard.h: Fix #if so that we don't try to compile pasteboard name code
2824 2013-05-13 Anders Carlsson <andersca@apple.com>
2826 Frame::editor() should return a reference
2827 https://bugs.webkit.org/show_bug.cgi?id=116037
2829 Reviewed by Darin Adler.
2831 A frame's editor can never be null. Change Frame::editor() to return a reference to reflect this.
2832 Also, make Frame::m_editor a const member variable so nobody will accidentally set it to null.
2834 * accessibility/AccessibilityObject.cpp:
2835 (WebCore::AccessibilityObject::hasMisspelling):
2836 * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2837 (AXAttributeStringSetSpelling):
2838 * dom/ContainerNode.cpp:
2839 (WebCore::ContainerNode::cloneChildNodes):
2841 (WebCore::acceptsEditingFocus):
2842 (WebCore::Document::setFocusedNode):
2844 * editing/AlternativeTextController.cpp:
2845 (WebCore::AlternativeTextController::timerFired):
2846 (WebCore::AlternativeTextController::applyDictationAlternative):
2847 * editing/CompositeEditCommand.cpp:
2848 (WebCore::EditCommandComposition::unapply):
2849 (WebCore::EditCommandComposition::reapply):
2850 (WebCore::CompositeEditCommand::apply):
2851 (WebCore::CompositeEditCommand::moveParagraphs):
2852 * editing/DeleteButton.cpp:
2853 (WebCore::DeleteButton::defaultEventHandler):
2854 * editing/DeleteButtonController.cpp:
2855 (WebCore::DeleteButtonController::show):
2856 * editing/DeleteButtonController.h:
2857 (WebCore::DeleteButtonControllerDisableScope::DeleteButtonControllerDisableScope):
2858 (WebCore::DeleteButtonControllerDisableScope::~DeleteButtonControllerDisableScope):
2859 * editing/DeleteSelectionCommand.cpp:
2860 (WebCore::DeleteSelectionCommand::mergeParagraphs):
2861 (WebCore::DeleteSelectionCommand::doApply):
2862 * editing/EditCommand.cpp:
2863 (WebCore::EditCommand::EditCommand):
2864 * editing/EditingStyle.cpp:
2865 (WebCore::StyleChange::StyleChange):
2866 * editing/Editor.cpp:
2867 (WebCore::Editor::markMisspellingsAfterTypingToWord):
2868 * editing/EditorCommand.cpp:
2869 (WebCore::applyCommandToFrame):
2870 (WebCore::executeToggleStyle):
2871 (WebCore::executeApplyParagraphStyle):
2872 (WebCore::expandSelectionToGranularity):
2873 (WebCore::stateStyle):
2874 (WebCore::valueStyle):
2875 (WebCore::executeCopy):
2876 (WebCore::executeCut):
2877 (WebCore::executeDefaultParagraphSeparator):
2878 (WebCore::executeDelete):
2879 (WebCore::executeDeleteBackward):
2880 (WebCore::executeDeleteBackwardByDecomposingPreviousCharacter):
2881 (WebCore::executeDeleteForward):
2882 (WebCore::executeDeleteToBeginningOfLine):
2883 (WebCore::executeDeleteToBeginningOfParagraph):
2884 (WebCore::executeDeleteToEndOfLine):
2885 (WebCore::executeDeleteToEndOfParagraph):
2886 (WebCore::executeDeleteToMark):
2887 (WebCore::executeDeleteWordBackward):
2888 (WebCore::executeDeleteWordForward):
2889 (WebCore::executeFindString):
2890 (WebCore::executeForwardDelete):
2891 (WebCore::executeIgnoreSpelling):
2892 (WebCore::executeInsertNewline):
2893 (WebCore::executeMakeTextWritingDirectionLeftToRight):
2894 (WebCore::executeMakeTextWritingDirectionNatural):
2895 (WebCore::executeMakeTextWritingDirectionRightToLeft):
2896 (WebCore::executeToggleOverwrite):
2897 (WebCore::executePaste):
2898 (WebCore::executePasteGlobalSelection):
2899 (WebCore::executePasteAndMatchStyle):
2900 (WebCore::executePasteAsPlainText):
2901 (WebCore::executeRedo):
2902 (WebCore::executeRemoveFormat):
2903 (WebCore::executeSelectToMark):
2904 (WebCore::executeSetMark):
2905 (WebCore::executeStyleWithCSS):
2906 (WebCore::executeUseCSS):
2907 (WebCore::executeSwapWithMark):
2908 (WebCore::executeTakeFindStringFromSelection):
2909 (WebCore::executeTranspose):
2910 (WebCore::executeUndo):
2911 (WebCore::executeYank):
2912 (WebCore::executeYankAndSelect):
2913 (WebCore::supportedCopyCut):
2914 (WebCore::supportedPaste):
2915 (WebCore::enabledVisibleSelection):
2916 (WebCore::enabledVisibleSelectionAndMark):
2917 (WebCore::enableCaretInEditableText):
2918 (WebCore::enabledCopy):
2919 (WebCore::enabledCut):
2920 (WebCore::enabledInEditableText):
2921 (WebCore::enabledDelete):
2922 (WebCore::enabledPaste):
2923 (WebCore::enabledRedo):
2924 (WebCore::enabledTakeFindStringFromSelection):
2925 (WebCore::enabledUndo):
2926 (WebCore::stateOrderedList):
2927 (WebCore::stateStyleWithCSS):
2928 (WebCore::stateUnorderedList):
2929 (WebCore::valueDefaultParagraphSeparator):
2930 * editing/FrameSelection.cpp:
2931 (WebCore::shouldAlwaysUseDirectionalSelection):
2932 (WebCore::FrameSelection::setSelection):
2933 (WebCore::FrameSelection::nextWordPositionForPlatform):
2934 (WebCore::FrameSelection::modifyMovingRight):
2935 (WebCore::FrameSelection::modifyMovingLeft):
2936 (WebCore::FrameSelection::modify):
2937 (WebCore::shouldStopBlinkingDueToTypingCommand):
2938 (WebCore::FrameSelection::shouldDeleteSelection):
2939 (WebCore::FrameSelection::shouldChangeSelection):
2940 * editing/InsertTextCommand.cpp:
2941 (WebCore::InsertTextCommand::doApply):
2942 * editing/SpellChecker.cpp:
2943 (WebCore::SpellChecker::didCheck):
2944 * editing/SpellingCorrectionCommand.cpp:
2945 * editing/TypingCommand.cpp:
2946 (WebCore::TypingCommand::insertText):
2947 (WebCore::TypingCommand::lastTypingCommandIfStillOpenForTyping):
2948 (WebCore::TypingCommand::markMisspellingsAfterTyping):
2949 (WebCore::TypingCommand::typingAddedToOpenCommand):
2950 (WebCore::TypingCommand::deleteKeyPressed):
2951 (WebCore::TypingCommand::forwardDeleteKeyPressed):
2952 * editing/htmlediting.cpp:
2953 (WebCore::createDefaultParagraphElement):
2954 * editing/mac/EditorMac.mm:
2955 (WebCore::Editor::pasteWithPasteboard):
2956 * editing/markup.cpp:
2957 (WebCore::createMarkup):
2958 * html/HTMLInputElement.cpp:
2959 (WebCore::HTMLInputElement::endEditing):
2960 * html/HTMLTextAreaElement.cpp:
2961 (WebCore::HTMLTextAreaElement::subtreeHasChanged):
2962 * html/TextFieldInputType.cpp:
2963 (WebCore::TextFieldInputType::handleKeydownEvent):
2964 (WebCore::TextFieldInputType::didSetValueByUserEdit):
2965 * loader/FrameLoader.cpp:
2966 (WebCore::FrameLoader::closeURL):
2967 (WebCore::FrameLoader::didOpenURL):
2968 (WebCore::FrameLoader::clear):
2969 * page/ContextMenuController.cpp:
2970 (WebCore::insertUnicodeCharacter):
2971 (WebCore::ContextMenuController::contextMenuItemSelected):
2972 (WebCore::ContextMenuController::populate):
2973 (WebCore::ContextMenuController::checkOrEnableIfNeeded):
2974 * page/DOMWindow.cpp:
2975 (WebCore::DOMWindow::find):
2976 * page/DragController.cpp:
2977 (WebCore::DragController::dispatchTextInputEventFor):
2978 (WebCore::DragController::concludeEditDrag):
2979 (WebCore::DragController::startDrag):
2980 * page/EventHandler.cpp:
2981 (WebCore::EventHandler::selectClosestWordFromMouseEvent):
2982 (WebCore::EventHandler::handleMousePressEventSingleClick):
2983 (WebCore::EventHandler::handlePasteGlobalSelection):
2984 (WebCore::EventHandler::sendContextMenuEvent):
2985 (WebCore::EventHandler::sendContextMenuEventForKey):
2986 (WebCore::EventHandler::keyEvent):
2987 (WebCore::EventHandler::defaultKeyboardEventHandler):
2988 (WebCore::EventHandler::defaultTextInputEventHandler):
2989 (WebCore::EventHandler::defaultBackspaceEventHandler):
2990 * page/FocusController.cpp:
2991 (WebCore::relinquishesEditingFocus):
2993 (WebCore::Frame::rangeForPoint):
2996 (WebCore::Frame::editor):
2998 (WebCore::Page::findString):
2999 (WebCore::Page::findStringMatchingRanges):
3000 (WebCore::Page::rangeOfString):
3001 (WebCore::Page::markAllMatchesForText):
3002 (WebCore::Page::setDeviceScaleFactor):
3003 * platform/mac/ClipboardMac.mm:
3004 (WebCore::ClipboardMac::writeRange):
3005 * platform/mac/DragDataMac.mm:
3006 (WebCore::DragData::asURL):
3007 * platform/mac/PasteboardMac.mm:
3008 (WebCore::Pasteboard::getStringSelection):
3009 (WebCore::Pasteboard::getDataSelection):
3010 (WebCore::Pasteboard::writeSelectionForTypes):
3011 (WebCore::writeURLForTypes):
3012 (WebCore::Pasteboard::plainText):
3013 (WebCore::documentFragmentWithRTF):
3014 (WebCore::Pasteboard::documentFragment):
3015 * rendering/HitTestResult.cpp:
3016 (WebCore::HitTestResult::dictationAlternatives):
3017 * rendering/InlineTextBox.cpp:
3018 (WebCore::InlineTextBox::paint):
3019 (WebCore::InlineTextBox::paintTextMatchMarker):
3020 * rendering/RenderBlock.cpp:
3021 (WebCore::RenderBlock::positionForPointWithInlineChildren):
3022 * testing/Internals.cpp:
3023 (WebCore::spellchecker):
3024 (WebCore::Internals::resetToConsistentState):
3025 (WebCore::Internals::hasSpellingMarker):
3026 (WebCore::Internals::hasAutocorrectedMarker):
3027 (WebCore::Internals::setContinuousSpellCheckingEnabled):
3028 (WebCore::Internals::setAutomaticQuoteSubstitutionEnabled):
3029 (WebCore::Internals::setAutomaticLinkDetectionEnabled):
3030 (WebCore::Internals::setAutomaticDashSubstitutionEnabled):
3031 (WebCore::Internals::setAutomaticTextReplacementEnabled):
3032 (WebCore::Internals::setAutomaticSpellingCorrectionEnabled):
3033 (WebCore::Internals::isOverwriteModeEnabled):
3034 (WebCore::Internals::toggleOverwriteModeEnabled):
3035 (WebCore::Internals::hasGrammarMarker):
3037 2013-05-15 Darin Adler <darin@apple.com>
3039 [Mac] Make Clipboard class no longer polymorphic by removing the last virtual functions
3040 https://bugs.webkit.org/show_bug.cgi?id=116166
3042 Reviewed by Anders Carlsson.
3044 * WebCore.exp.in: Add ~Clipboard since it's no longer a virtual function, but to the
3045 non-iOS section, since iOS is still using the legacy version of Clipboard.
3047 * dom/Clipboard.h: Mark items non-virtual, too. It's not implemented on Mac yet.
3049 2013-05-15 Dongseong Hwang <dongseong.hwang@intel.com>
3051 Remove an overloaded strokeRect in <canvas>
3052 https://bugs.webkit.org/show_bug.cgi?id=116017
3054 Reviewed by Benjamin Poulain.
3056 The canvas spec [1] does not define strokeRect with 5 arguments, so this issue
3057 remains only strokeRect with 4 arguments.
3059 [1] http://www.w3.org/TR/2dcontext2/
3061 Covered by existing tests: canvas/philip/tests/2d.missingargs.html
3063 * html/canvas/CanvasRenderingContext2D.cpp:
3064 (WebCore::CanvasRenderingContext2D::strokeRect):
3065 * html/canvas/CanvasRenderingContext2D.h:
3066 (CanvasRenderingContext2D):
3067 * html/canvas/CanvasRenderingContext2D.idl:
3069 2013-05-15 Bruno de Oliveira Abinader <bruno.abinader@basyskom.com>
3071 [css3-text] text-decoration-line now accepts "blink" as valid value
3072 https://bugs.webkit.org/show_bug.cgi?id=116104
3074 Reviewed by Andreas Kling.
3076 As of November 13th 2012, the W3C specification has been updated to
3077 accept "blink" as a valid property value in text-decoration-line. Though
3078 accepting the value as valid, it is ignored as CSS Level 1
3079 text-decoration property currently does.
3081 Updated related layout tests to reflect changes in specification.
3083 * css/CSSParser.cpp:
3084 (WebCore::CSSParser::parseValue):
3085 (WebCore::CSSParser::parseTextDecoration):
3087 2013-05-14 Simon Fraser <simon.fraser@apple.com>
3089 Revert http://trac.webkit.org/changeset/150047
3091 It introduced unwanted behavioral differences between
3092 Retina and non-Retina Mac hardware.
3094 * platform/graphics/ca/GraphicsLayerCA.cpp:
3095 (WebCore::GraphicsLayerCA::requiresTiledLayer):
3096 (WebCore::GraphicsLayerCA::computePixelAlignment):
3098 2013-05-15 Darin Adler <darin@apple.com>
3100 [Mac] Remove the ClipboardMac class and header file
3101 https://bugs.webkit.org/show_bug.cgi?id=116165
3103 Reviewed by Anders Carlsson.
3105 * WebCore.xcodeproj/project.pbxproj: Remove ClipboardMac.h.
3106 * editing/mac/EditorMac.mm: Import Clipboard.h rather than ClipboardMac.h.
3107 * page/mac/EventHandlerMac.mm: Ditto.
3108 * platform/mac/ClipboardMac.h: Removed.
3110 * platform/mac/ClipboardMac.mm: Import Clipboard.h rather than ClipboardMac.h.
3111 Deleted ClipboardMac constructor.
3113 2013-05-15 Darin Adler <darin@apple.com>
3115 [Mac] Change Clipboard::create functions so they don't use ClipboardMac::create any more
3116 https://bugs.webkit.org/show_bug.cgi?id=116163
3118 Reviewed by Anders Carlsson.
3120 * dom/Clipboard.h: Made the file drag boolean default to false, better for most callers.
3122 * platform/mac/ClipboardMac.mm: Remove #if ENABLE(DRAG_SUPPORT); that's always on for Mac
3123 and it's not helpful to have the conditionals in here. It's helpful in cross-platform
3125 (WebCore::Clipboard::create): Create a Pasteboard and then create a Clipboard with new.
3126 Later could refactor to have the Pasteboard creation be platform-specific, and make these
3127 functions platform-independent.
3128 (WebCore::Clipboard::createForDragAndDrop): Ditto.
3129 (WebCore::Clipboard::createForCopyAndPaste): Ditto.
3131 2013-05-15 Darin Adler <darin@apple.com>
3133 [Mac] Remove call to ClipboardMac::create from Editor::newGeneralClipboard
3134 https://bugs.webkit.org/show_bug.cgi?id=116162
3136 Reviewed by Andreas Kling.
3138 * dom/Clipboard.h: Add createForCopyAndPaste function.
3140 * editing/mac/EditorMac.mm:
3141 (WebCore::Editor::newGeneralClipboard): Call createForCopyAndPaste.
3143 * platform/mac/ClipboardMac.mm:
3144 (WebCore::Clipboard::createForCopyAndPaste): Added. Moved code here from
3145 Editor::newGeneralClipboard.
3147 2013-05-15 Darin Adler <darin@apple.com>
3149 [Mac] Remove call to ClipboardMac::create from EventHandler::createDraggingClipboard
3150 https://bugs.webkit.org/show_bug.cgi?id=116161
3152 Reviewed by Andreas Kling.
3154 * dom/Clipboard.h: Added createForDragAndDrop function.
3156 * page/mac/EventHandlerMac.mm:
3157 (WebCore::EventHandler::createDraggingClipboard): Changed to use new Clipboard function
3158 instead of ClipboardMac::create.
3160 * platform/mac/ClipboardMac.mm:
3161 (WebCore::Clipboard::createForDragAndDrop): Added. For now it does exactly what the
3162 EventHandler::createDraggingClipboard function did, soon to be refactored better.
3164 2013-05-15 Darin Adler <darin@apple.com>
3166 [Mac] Thin out the ClipboardMac class and header file to prepare for deleting them
3167 https://bugs.webkit.org/show_bug.cgi?id=116159
3169 Reviewed by Andreas Kling.
3172 (WebCore::Clipboard::pasteboard): Added. For clients that have a DOM clipboard
3173 object and need to get to the Pasteboard platform abstraction.
3175 * editing/Editor.cpp:
3176 (WebCore::Editor::dispatchCPPEvent): Call writePasteboard instead of writeClipboard.
3177 Our long term plan is to delete writeClipboard.
3179 * platform/Pasteboard.h: Added writePasteboard function.
3180 (WebCore::Pasteboard::name): Made this const.
3182 * platform/mac/ClipboardMac.h: Deleted unneeded includes and forward declarations.
3183 Deleted all the data members and the virtual destructor.
3185 * platform/mac/ClipboardMac.mm: Deleted the many includes that are no longer needed.
3186 Deleted the destructor, since it's now automatically generated. Deleted the comment
3187 on an #endif since it's only a few source lines away from the #if.
3188 (WebCore::ClipboardMac::ClipboardMac): Deleted the code to set the data members,
3189 since they are no longer used.
3191 * platform/mac/PasteboardMac.mm: Changed include to Clipboard.h instead of ClipboardMac.h.
3192 (WebCore::Pasteboard::writePasteboard): Replaced writeClipboard with this.
3194 2013-05-15 Seokju Kwon <seokju.kwon@gmail.com>
3196 Web Inspector: Get rid of addNativeSnapshotChunk and HeapSnapshotChunk from Memory domain
3197 https://bugs.webkit.org/show_bug.cgi?id=116144
3199 Reviewed by Timothy Hatcher.
3201 No new tests, no behavior change.
3203 * inspector/Inspector.json:
3205 2013-05-15 Jocelyn Turcotte <jocelyn.turcotte@digia.com>
3207 [Qt] Fix a crash under ~PingLoader when the QNAM on the page has been destroyed.
3208 https://bugs.webkit.org/show_bug.cgi?id=116035
3210 Reviewed by Allan Sandfeld Jensen.
3212 The previous fix only moved the crash location from WebKit down to QNetworkReplyHttpImpl
3213 which expects its QNetworkAccessManager to still be alive.
3215 Fix it by watching the QNetworkReply's destroyed() signal and avoid the dangling pointer
3216 instead. The QNetworkReply doesn't need to be aborted in this case anyway.
3218 * platform/network/qt/QNetworkReplyHandler.cpp:
3219 (WebCore::QNetworkReplyWrapper::QNetworkReplyWrapper):
3220 (WebCore::QNetworkReplyWrapper::release):
3221 (WebCore::QNetworkReplyWrapper::stopForwarding):
3222 Rename resetConnections to stopForwarding since not all connections are related
3223 to data forwarding to the client anymore.
3224 (WebCore::QNetworkReplyWrapper::receiveMetaData):
3225 (WebCore::QNetworkReplyWrapper::replyDestroyed):
3226 (WebCore::QNetworkReplyWrapper::didReceiveFinished):
3227 * platform/network/qt/QNetworkReplyHandler.h:
3228 (QNetworkReplyWrapper):
3230 2013-05-15 Darin Adler <darin@apple.com>
3232 [Mac] Make Clipboard::declareAndWriteDragImage non-virtual
3233 https://bugs.webkit.org/show_bug.cgi?id=116156
3235 Reviewed by Anders Carlsson.
3237 * dom/Clipboard.h: Make declareAndWriteDragImage non-virtual for non-legacy.
3239 * platform/Pasteboard.h:
3240 (WebCore::Pasteboard::name): Added. Can be used in Mac platform code to do
3241 pasteboard operations directly instead of through the Pasteboard class
3242 functions. Not sure if we'll need it long term or not.
3244 * platform/mac/ClipboardMac.h: Removed declareAndWriteDragImage function.
3246 * platform/mac/ClipboardMac.mm:
3247 (WebCore::Clipboard::declareAndWriteDragImage): Made this function a Clipboard
3248 member instead of ClipboardMac.
3250 2013-05-15 Peter Gal <galpeter@inf.u-szeged.hu>
3252 [curl] Remove version #if guards
3253 https://bugs.webkit.org/show_bug.cgi?id=116152
3255 Reviewed by Brent Fulgham.
3259 * platform/network/curl/ResourceHandleCurl.cpp:
3260 (WebCore::ResourceHandle::platformSetDefersLoading): Removed version guard.
3261 * platform/network/curl/ResourceHandleManager.cpp:
3262 (WebCore::writeCallback): Ditto.
3263 (WebCore::headerCallback): Ditto.
3264 (WebCore::readCallback): Ditto.
3265 (WebCore::ResourceHandleManager::dispatchSynchronousJob): Ditto.
3266 (WebCore::ResourceHandleManager::initializeHandle): Ditto.
3268 2013-05-15 David Kilzer <ddkilzer@apple.com>
3270 BUILD FIX (r150089): Make WebCoreTestShim build for iOS
3272 * Configurations/WebCoreTestShim.xcconfig: Exclude
3273 WebCoreTestShimLibrary.cpp when building for iOS.
3275 2013-05-15 Radu Stavila <stavila@adobe.com>
3277 [CSSRegions] Implement offsetParent for elements inside named flow
3278 https://bugs.webkit.org/show_bug.cgi?id=113276
3280 In the offsetParent algorithm, the nearest ancestor search skips from the topmost named flow elements directly to the body element.
3281 http://dev.w3.org/csswg/css-regions/#cssomview-offset-attributes
3283 As a result of this change, the DumpRenderTree tool would crash in
3284 WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent when running the selecting-text-through-different-region-flows.html
3285 test. The RenderObjects inside a flow are attached to the RenderFlowThread. However, the RenderFlowThread is attached to the
3286 RenderView directly, meaning that we are going to bypass the <body>'s RenderObject while iterating the parents.
3288 Reviewed by Darin Adler.
3290 Tests: fast/regions/offsetParent-body-in-flow-thread.html
3291 fast/regions/offsetParent-in-flow-thread.html
3293 * rendering/RenderBoxModelObject.cpp:
3294 (WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
3295 * rendering/RenderObject.cpp:
3296 (WebCore::RenderObject::offsetParent):
3298 2013-05-15 Darin Adler <darin@apple.com>
3300 [Mac] Make Clipboard::createDragImage non-virtual
3301 https://bugs.webkit.org/show_bug.cgi?id=116136
3303 Reviewed by Benjamin Poulain.
3305 * dom/Clipboard.h: Made createDragImage non-virtual for non-legacy.
3307 * platform/mac/ClipboardMac.h: Removed frame argument from create function
3308 and constructor. Removed createDragImage and dragNSImage. Removed m_frame
3311 * platform/mac/ClipboardMac.mm:
3312 (WebCore::ClipboardMac::ClipboardMac): Removed frame argument and code
3313 to initialize m_frame.
3314 (WebCore::Clipboard::createDragImage): Merged the createDragImage and
3315 dragNSImage functions, since they were the same thing. Changed code to get
3316 the frame from the drag image element. Made the createDragImage function
3317 a Clipboard member instead of ClipboardMac.
3319 2013-05-15 Patrick Gansterer <paroga@webkit.org>
3321 [WINCE] Fix calls to GlyphPage::setGlyphDataForIndex()
3322 https://bugs.webkit.org/show_bug.cgi?id=116137
3324 Reviewed by Andreas Kling.
3326 Use zero for the glyp when the fontData pointer is null.
3327 This aligns GlyphPageTreeNodeWinCE with the other implementations
3328 and makes all ASSERT() pass in setGlyphDataForIndex().
3330 * platform/graphics/wince/GlyphPageTreeNodeWinCE.cpp:
3331 (WebCore::GlyphPage::fill):
3333 2013-05-15 Benjamin Poulain <bpoulain@apple.com>
3335 Do not bloat HTMLTokenizer with a giant inline InputStreamPreprocessor::peek
3336 https://bugs.webkit.org/show_bug.cgi?id=116066
3338 Reviewed by Ryosuke Niwa.
3340 Merge https://chromium.googlesource.com/chromium/blink/+/45e0337b2f2db535ab08365f6e763a5015e4d990.
3342 On x86_64, this removes 40kb from the binary. On my machine it is completely neutral on performance.
3344 * html/parser/InputStreamPreprocessor.h:
3345 (WebCore::InputStreamPreprocessor::peek):
3346 (InputStreamPreprocessor):
3347 (WebCore::InputStreamPreprocessor::advance):
3348 (WebCore::InputStreamPreprocessor::skipNextNewLine):
3349 (WebCore::InputStreamPreprocessor::reset):
3350 (WebCore::InputStreamPreprocessor::processNextInputCharacter):
3352 2013-05-14 Carlos Garcia Campos <cgarcia@igalia.com>
3354 Remove WTF_USE_PLATFORM_STRATEGIES
3355 https://bugs.webkit.org/show_bug.cgi?id=114431
3357 Reviewed by Darin Adler.
3359 * Modules/webdatabase/DatabaseManager.cpp:
3360 (WebCore::DatabaseManager::DatabaseManager):
3361 * dom/ContainerNode.cpp:
3362 (WebCore::ContainerNode::suspendPostAttachCallbacks):
3363 (WebCore::ContainerNode::resumePostAttachCallbacks):
3364 * dom/VisitedLinkState.cpp:
3365 (WebCore::VisitedLinkState::determineLinkStateSlowCase):
3366 * loader/CookieJar.cpp:
3368 (WebCore::setCookies):
3369 (WebCore::cookiesEnabled):
3370 (WebCore::cookieRequestHeaderFieldValue):
3371 (WebCore::getRawCookies):
3372 (WebCore::deleteCookie):
3373 * loader/FrameLoader.cpp:
3374 (WebCore::FrameLoader::loadResourceSynchronously):
3375 * loader/HistoryController.cpp:
3376 (WebCore::addVisitedLink):
3377 * loader/LoaderStrategy.cpp:
3378 * loader/LoaderStrategy.h:
3379 * loader/ResourceLoadScheduler.cpp:
3380 (WebCore::resourceLoadScheduler):
3381 * loader/ResourceLoader.cpp:
3382 (WebCore::ResourceLoader::releaseResources):
3383 (WebCore::ResourceLoader::willSendRequest):
3384 * loader/cache/CachedResource.cpp:
3385 (WebCore::CachedResource::load):
3386 * loader/cache/CachedResourceLoader.cpp:
3387 (WebCore::CachedResourceLoader::performPostLoadActions):
3388 * platform/CookiesStrategy.h:
3389 * platform/DatabaseStrategy.cpp:
3390 * platform/DatabaseStrategy.h:
3391 * platform/PasteboardStrategy.h:
3392 * platform/PlatformStrategies.cpp:
3393 * platform/PlatformStrategies.h:
3394 * platform/VisitedLinkStrategy.h:
3395 * platform/mac/PasteboardMac.mm:
3396 * platform/network/BlobRegistry.cpp:
3397 (WebCore::blobRegistry):
3398 * plugins/PluginData.cpp:
3399 (WebCore::PluginData::initPlugins):
3400 * plugins/PluginStrategy.h:
3401 * storage/StorageNamespace.cpp:
3402 (WebCore::StorageNamespace::localStorageNamespace):
3403 (WebCore::StorageNamespace::transientLocalStorageNamespace):
3404 (WebCore::StorageNamespace::sessionStorageNamespace):
3405 * storage/StorageStrategy.cpp:
3406 * storage/StorageStrategy.h:
3407 * workers/SharedWorkerStrategy.h:
3409 2013-05-15 Dávid Szabolcs <David.Szabolcs@stud.u-szeged.hu>
3411 [curl] Add support for HttpOnly cookies
3412 https://bugs.webkit.org/show_bug.cgi?id=116102
3414 Reviewed by Brent Fulgham.
3416 * platform/network/curl/CookieJarCurl.cpp:
3417 (WebCore::addMatchingCurlCookie):
3418 (WebCore::cookiesForSession):
3419 (WebCore::cookiesForDOM):
3421 (WebCore::cookieRequestHeaderFieldValue):
3423 2013-05-14 Carlos Garcia Campos <cgarcia@igalia.com>
3425 REGRESSION(r147548): Broken comboboxes
3426 https://bugs.webkit.org/show_bug.cgi?id=115475
3428 Reviewed by Gustavo Noronha Silva.
3430 The problem is that r147548 made the popup to be closed when a
3431 blur event is received. Right before showing the popup the input
3432 element is focused, so that after the the popup is shown the focus
3433 event is emitted and the event handler is called again hiding the
3436 * html/HTMLSelectElement.cpp:
3437 (WebCore::HTMLSelectElement::menuListDefaultEventHandler): Check
3438 element has lost the focus before closing the popup menu.
3440 2013-05-14 Darin Adler <darin@apple.com>
3442 [Mac] Move setDragImage from ClipboardMac to PasteboardMac
3443 https://bugs.webkit.org/show_bug.cgi?id=116036
3445 Reviewed by Anders Carlsson.
3447 * dom/Clipboard.cpp:
3448 (WebCore::Clipboard::~Clipboard): Stop loading the drag image when
3449 the clipboard object is deallocated. It would be better if there was
3450 a more-well-defined time to stop the load.
3451 (WebCore::Clipboard::setDragImage): Added. Sets up a drag image
3452 based on a CachedImage. This tells the image loader to load the image
3453 and updates the drag image when the image arrives. Copied from the
3454 code in ClipboardMac, but refactored to use a separate loader object.
3455 (WebCore::Clipboard::setDragImageElement): Added. Sets up a drag image
3456 based on an element.
3457 (WebCore::Clipboard::updateDragImage): Added. Common code to update
3458 drag image when a new one is set or when a drag image load completes.
3459 (WebCore::DragImageLoader::create): Added.
3460 (WebCore::DragImageLoader::DragImageLoader): Ditto.
3461 (WebCore::DragImageLoader::startLoading): Ditto.
3462 (WebCore::DragImageLoader::stopLoading): Ditto.
3463 (WebCore::DragImageLoader::imageChanged): Ditto.
3465 * dom/Clipboard.h: Made setDragImage and setDragImageElement non-virtual
3466 for non-legacy. Added updateDragImage and m_dragImageLoader.
3468 * platform/Pasteboard.h: Added setDragImage function.
3470 * platform/mac/ClipboardMac.h: Removed CachedImageClient as a base class
3471 for ClipboardMac. Removed setDragImage and setDragImageElement.
3473 * platform/mac/ClipboardMac.mm: Removed setDragImage and setDragImageElement.
3474 (WebCore::ClipboardMac::~ClipboardMac): Removed code to remove self as
3475 client loading the drag image. This is now in the Clipboard base class.