1 2013-05-20 Ryosuke Niwa <rniwa@webkit.org>
3 dispatchEvent call can execute javascript and blow away endRoot from underneath
4 https://bugs.webkit.org/show_bug.cgi?id=116483
6 Reviewed by Andreas Kling.
8 Merge https://chromium.googlesource.com/chromium/blink/+/798cba0af9b2aff21e475e2e08ea3ca5e97dfc2c.
10 Test: editing/undo/undo-after-event-edited.html
13 (WebCore::dispatchEditableContentChangedEvents):
15 2013-05-21 Antti Koivisto <antti@apple.com>
17 Remove ContentDistribution
18 https://bugs.webkit.org/show_bug.cgi?id=116527
20 Reviewed by Andreas Kling.
22 Resolving distribution on traversal is simpler.
25 * dom/ComposedShadowTreeWalker.cpp:
26 (WebCore::ComposedShadowTreeWalker::traverseNode):
27 (WebCore::ComposedShadowTreeWalker::traverseDistributedNodes):
28 (WebCore::ComposedShadowTreeWalker::traverseSiblingOrBackToInsertionPoint):
29 * html/HTMLDetailsElement.cpp:
30 * html/shadow/ContentDistributor.cpp:
31 (WebCore::ContentDistributor::distributeSelectionsTo):
32 * html/shadow/ContentDistributor.h:
33 * html/shadow/HTMLContentElement.idl:
35 Remove getDistributedNodes().
37 * html/shadow/InsertionPoint.cpp:
38 (WebCore::InsertionPoint::InsertionPoint):
39 (WebCore::InsertionPoint::attach):
40 (WebCore::InsertionPoint::detach):
42 (WebCore::InsertionPoint::firstDistributed):
43 (WebCore::InsertionPoint::lastDistributed):
44 (WebCore::InsertionPoint::nextDistributedTo):
45 (WebCore::InsertionPoint::previousDistributedTo):
49 * html/shadow/InsertionPoint.h:
50 (WebCore::InsertionPoint::hasDistribution):
51 (WebCore::InsertionPoint::setHasDistribution):
52 (WebCore::InsertionPoint::clearDistribution):
53 (WebCore::InsertionPoint::matchTypeFor):
56 2013-05-21 Martin Robinson <mrobinson@igalia.com>
58 [GTK] [CMake] Add support for building WebKit2
59 https://bugs.webkit.org/show_bug.cgi?id=116372
61 Reviewed by Gustavo Noronha Silva.
63 * PlatformGTK.cmake: Add missing source files, include directories, and WebP properties.
65 2013-05-21 Jer Noble <jer.noble@apple.com>
67 REGRESSION(r101810): Media controls status text missing for live-stream videos.
68 https://bugs.webkit.org/show_bug.cgi?id=116547
70 Reviewed by Eric Carlson.
72 Un-reverse the logic in loadedMetadata() so that the status text isn't
73 hidden (when it should be shown) for live-stream videos.
75 * html/shadow/MediaControlsApple.cpp:
76 (WebCore::MediaControlsApple::loadedMetadata):
78 2013-05-21 Jer Noble <jer.noble@apple.com>
80 Implement overlap-avoidance for in-band text track cues.
81 https://bugs.webkit.org/show_bug.cgi?id=116540
83 Reviewed by Eric Carlson.
85 In-band (or Generic) cues need special casing for certain features
86 present in in-band tracks, like paint-on and roll-up modes. To avoid
87 the problem of overlap avoidance forcing a caption meant to appear
88 below a cue to appear above it when a larger font size is selected,
89 impose an additional sort ordering for "generic cues". Instead of
90 cues being ordered by the order they appear in the track, "generic
91 cues" further sorted by their position within the video area, such
92 that cues at the bottom of the video area appear first, and later
93 cues are pushed up to avoid them, preserving the desired apparent
96 * html/HTMLMediaElement.cpp:
97 (WebCore::compareCueInterval): Added; wrapper around
98 TextTrackCue::isOrderedBefore.
99 (WebCore::HTMLMediaElement::updateActiveTextTrackCues):
100 After creating the list of current cues, sort them.
101 * html/track/TextTrackCue.cpp:
102 (WebCore::TextTrackCue::isOrderedBefore): Added; implementation moved
103 from TextTrackCueList::add().
104 * html/track/TextTrackCue.h:
105 * html/track/TextTrackCueGeneric.cpp:
106 (WebCore::TextTrackCueGeneric::isOrderedBefore): Added override;
107 impose additional oredring on generic cues.
108 * html/track/TextTrackCueGeneric.h:
109 * html/track/TextTrackCueList.cpp:
110 (WebCore::TextTrackCueList::add): Moved ordering test into
112 * rendering/RenderTextTrackCue.cpp:
113 (WebCore::RenderTextTrackCue::repositionGenericCue):
114 Call repositionCueSnapToLinesNotSet() after positioning the cue.
116 2013-05-20 Jer Noble <jer.noble@apple.com>
118 Implement overlap avoidance for cues with snap-to-lines flag not set
119 https://bugs.webkit.org/show_bug.cgi?id=84296
121 Reviewed by Eric Carlson.
123 Test: media/track/track-cue-overlap-snap-to-lines-not-set.html
125 Support overlap avoidance for the non-snap-to-lines part of the WebVTT spec.
127 * rendering/RenderTextTrackCue.cpp:
128 (WebCore::RenderTextTrackCue::isOutside): Split implementation into rectIsWithinContainer().
129 (WebCore::RenderTextTrackCue::rectIsWithinContainer): Ditto.
130 (WebCore::RenderTextTrackCue::isOverlapping): Split into overlappingObject() and overlappingObjectForRect().
131 (WebCore::RenderTextTrackCue::overlappingObject): Ditto.
132 (WebCore::RenderTextTrackCue::overlappingObjectForRect): Ditto.
133 (WebCore::RenderTextTrackCue::moveIfNecessaryToKeepWithinContainer): Added.
134 (WebCore::RenderTextTrackCue::findNonOverlappingPosition): When an overlapping object is found, move the
135 cue to just above or below that object and try again.
136 (WebCore::RenderTextTrackCue::repositionCueSnapToLinesSet): Move implementation into moveIfNecessaryToKeepWithinContainer().
137 (WebCore::RenderTextTrackCue::repositionCueSnapToLinesNotSet): Add implementanton based on above.
138 * rendering/RenderTextTrackCue.h:
140 2013-05-21 Alberto Garcia <agarcia@igalia.com>
142 Remove GraphicsLayerClient::contentsVisible()
143 https://bugs.webkit.org/show_bug.cgi?id=116523
145 Reviewed by Darin Adler.
147 This is dead code from the BlackBerry port.
149 * platform/graphics/GraphicsLayerClient.h:
150 * rendering/RenderLayerBacking.cpp:
152 2013-05-21 Zan Dobersek <zdobersek@igalia.com>
154 PLATFORM(*) macros used in Source/WebCore/loader/archive/ArchiveFactory.cpp
155 https://bugs.webkit.org/show_bug.cgi?id=116453
157 Reviewed by Alexey Proskuryakov.
159 * loader/archive/ArchiveFactory.cpp: Remove a redundant PLATFORM(QT) macro when checking whether
160 to include the LegacyWebArchive.h header that's specific to the WebArchive support. The Qt port
161 does not enable the WebArchive feature at all (which is enabled only on AppleMac, AppleWin and iOS
162 platforms) so there's no reason to additionally condition the header include with building on
165 2013-05-21 Alberto Garcia <agarcia@igalia.com>
167 Add BlackBerry definition of NativeImagePtr
168 https://bugs.webkit.org/show_bug.cgi?id=116526
170 Reviewed by Darin Adler.
172 * platform/graphics/NativeImagePtr.h:
176 2013-05-21 Alberto Garcia <agarcia@igalia.com>
178 [BlackBerry] FontCache::getFontDataForCharacters() returns nullptr
179 https://bugs.webkit.org/show_bug.cgi?id=116529
181 Reviewed by Andreas Kling.
183 This cannot be converted to a PassRefPtr and breaks the build.
185 * platform/graphics/blackberry/FontCacheBlackBerry.cpp:
186 (WebCore::FontCache::getFontDataForCharacters):
188 2013-05-21 Iago Toral Quiroga <itoral@igalia.com>
190 [GTK] Always use EGL to create the GL context when running on Wayland
191 https://bugs.webkit.org/show_bug.cgi?id=115721
193 Reviewed by Martin Robinson.
195 * platform/graphics/cairo/GLContext.cpp:
196 (WebCore::GLContext::createContextForWindow):
197 (WebCore::GLContext::createOffscreenContext): Always use EGL to create the GL context
198 instead of GLX when running on Wayland and make createOffScreenContext reuse the code
199 in createContextWindow.
201 2013-05-21 Alberto Garcia <agarcia@igalia.com>
203 Add FloatRect::normalized() for BlackBerry
204 https://bugs.webkit.org/show_bug.cgi?id=116531
206 Reviewed by Carlos Garcia Campos.
208 This was added to FloatRectBlackBerry.cpp in r111072 when the
209 graphics platform code was upstreamed, but this change was
212 * platform/graphics/FloatRect.h:
215 2013-05-21 Balazs Kelemen <kbalazs@webkit.org>
217 [GStreamer] cleanup duration query
218 https://bugs.webkit.org/show_bug.cgi?id=116228
220 Reviewed by Philippe Normand.
222 Covered by existing tests.
224 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
225 (WebCore::MediaPlayerPrivateGStreamer::duration):
226 We can also cache the duration here if the query succeeds.
227 (MediaPlayerPrivateGStreamer::updateStates):
228 Don't query when we are in GST_STATE_READY state because it never succeeds.
229 Do it instead when we reached a stable state.
230 (MediaPlayerPrivateGStreamer::cacheDuration): Return early if it is already
231 cached. Recaching is not necessary and now we call it a lot of times.
232 Only look into the state if the query failed.
233 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
234 (MediaPlayerPrivateGStreamer): Made m_mediaDuration mutable to be
235 able to cache it in duration(). Internal cached values is one of
236 the sensible uses of mutable.
238 2013-05-21 Patrick Gansterer <paroga@webkit.org>
240 Build fix for !USE(ACCELERATED_COMPOSITING) after r150307.
242 * rendering/RenderLayerCompositor.h: Added missing #if USE(ACCELERATED_COMPOSITING).
244 2013-05-20 Antti Koivisto <antti@apple.com>
246 Simplify Shadow DOM distribution code
247 https://bugs.webkit.org/show_bug.cgi?id=116454
249 Reviewed by Andreas Kling.
251 Remove code supporting nested insertion points and distributing to multiple insertion points.
253 * html/HTMLDetailsElement.cpp:
254 (DetailsContentElement):
256 Make distribution to <details> and <summary> mutually exclusive.
258 * html/shadow/ContentDistributor.cpp:
260 (WebCore::ContentDistributor::distribute):
261 (WebCore::ContentDistributor::invalidate):
262 (WebCore::ContentDistributor::distributeSelectionsTo):
263 * html/shadow/ContentDistributor.h:
264 * html/shadow/InsertionPoint.cpp:
265 (WebCore::resolveReprojection):
267 2013-05-21 Mihnea Ovidenie <mihnea@adobe.com>
269 [CSSRegions] Constrain auto-height region computation in a different way
270 https://bugs.webkit.org/show_bug.cgi?id=116310
272 Reviewed by Alexandru Chiculita.
274 After https://bugs.webkit.org/show_bug.cgi?id=74132, the region is a render block. We can use RenderBox::constrainContentBoxLogicalHeightByMinMax
275 instead of RenderBox::computeReplacedLogicalHeightRespectingMinMaxHeight to better reflect the fact that the region is not a replaced element.
276 Covered by existing regions tests, since when replaced-based the region had an intrinsic height of 0 and now, block-based, it does not have any children.
278 * rendering/RenderFlowThread.cpp:
279 (WebCore::RenderFlowThread::addForcedRegionBreak):
281 2013-05-21 Ryosuke Niwa <rniwa@webkit.org>
283 REGRESSION(r150393): editing/inserting/typing-at-end-of-line.html fails
284 https://bugs.webkit.org/show_bug.cgi?id=116516
286 Reviewed by Antti Koivisto.
288 The bug was caused by DRT not resetting various auto correction states.
289 Do that in Internals::resetToConsistentState.
291 * testing/Internals.cpp:
292 (WebCore::Internals::resetToConsistentState):
294 2013-05-20 Zan Dobersek <zdobersek@igalia.com>
296 [GTK] Fix concatenations of string literals that are not C++11-compliant
297 https://bugs.webkit.org/show_bug.cgi?id=116449
299 Reviewed by Martin Robinson.
301 Fix the problematic concatenations of string literals so they are compilable under the C++11 standard. This
302 is simply a matter of separating the string and the string literal that are being concatenated with a space.
304 * platform/graphics/gtk/FullscreenVideoControllerGtk.cpp:
305 * platform/gtk/FileSystemGtk.cpp:
306 (WebCore::sharedResourcesPath):
308 2013-05-20 Zan Dobersek <zdobersek@igalia.com>
310 [GTK] Support application/x-mimearchive mimetype for MHTML archives instead of message/rfc822
311 https://bugs.webkit.org/show_bug.cgi?id=116442
313 Reviewed by Martin Robinson.
315 * loader/archive/ArchiveFactory.cpp:
316 (WebCore::archiveMIMETypes): Like EFL and Qt, register the application/x-mimearchive mime type as a MHTML archive type
317 and stop propagating the message/rfc822 mime type as such. This also removes a couple of PLATFORM ifdefs.
319 2013-05-20 Benjamin Poulain <bpoulain@apple.com>
321 Minor String fixes in CSS
322 https://bugs.webkit.org/show_bug.cgi?id=116291
324 Reviewed by Darin Adler.
326 Some trival changes to make up for a bad day :)
328 * css/CSSImageSetValue.cpp:
329 (WebCore::CSSImageSetValue::customCssText):
330 * css/CSSImageValue.cpp:
331 (WebCore::CSSImageValue::customCssText):
332 * css/CSSImportRule.cpp:
333 (WebCore::CSSImportRule::cssText):
334 * css/CSSInheritedValue.cpp:
335 (WebCore::CSSInheritedValue::customCssText):
336 * css/CSSInitialValue.cpp:
337 (WebCore::CSSInitialValue::customCssText):
338 * css/CSSPrimitiveValue.cpp:
339 (WebCore::CSSPrimitiveValue::customCssText):
340 * css/CSSPropertySourceData.cpp:
341 (WebCore::CSSPropertySourceData::toString):
342 * css/CSSSelector.cpp:
343 (WebCore::CSSSelector::selectorText):
344 * css/CSSStyleRule.cpp:
345 (WebCore::CSSStyleRule::generateSelectorText):
346 * css/CSSStyleSheet.h:
347 (WebCore::CSSStyleSheet::type):
348 * css/CSSTimingFunctionValue.cpp:
349 (WebCore::CSSLinearTimingFunctionValue::customCssText):
350 (WebCore::CSSCubicBezierTimingFunctionValue::customCssText):
351 * css/CSSValueList.cpp:
352 (WebCore::CSSValueList::customCssText):
353 (WebCore::CSSValueList::customSerializeResolvingVariables):
354 * css/MediaQueryExp.cpp:
355 (WebCore::MediaQueryExp::serialize):
356 * css/WebKitCSSFilterValue.cpp:
357 (WebCore::WebKitCSSFilterValue::customCssText):
358 * css/WebKitCSSKeyframesRule.cpp:
359 (WebCore::StyleRuleKeyframes::findKeyframeIndex):
360 (WebCore::WebKitCSSKeyframesRule::cssText):
361 * css/WebKitCSSMatFunctionValue.cpp:
362 (WebCore::WebKitCSSMatFunctionValue::customCssText):
363 * css/WebKitCSSMixFunctionValue.cpp:
364 (WebCore::WebKitCSSMixFunctionValue::customCssText):
366 2013-05-20 Ryosuke Niwa <rniwa@webkit.org>
368 Null pointer deference in WebCore::AppendNodeCommand::create
369 https://bugs.webkit.org/show_bug.cgi?id=116479
371 Reviewed by Andreas Kling.
373 Merge https://chromium.googlesource.com/chromium/blink/+/5cb43002a44f67a60ecf5a7ed76de2d0bcf89eb2
375 DeleteSelection::makeStylingElementsDirectChildrenOfEditableRootToPreventStyleLoss() make style and link elements
376 to be the direct children of the editable root. However, these style and link elements are not necessary editable
377 and WebKit crashes when they are not.
379 Test: editing/deleting/delete-uneditable-style.html
381 * editing/DeleteSelectionCommand.cpp:
382 (WebCore::DeleteSelectionCommand::makeStylingElementsDirectChildrenOfEditableRootToPreventStyleLoss):
384 2013-05-20 Beth Dakin <bdakin@apple.com>
386 Scrollbars still show sometimes even when WKPageSetSuppressScrollbarAnimations()
388 https://bugs.webkit.org/show_bug.cgi?id=116493
390 <rdar://problem/13912871>
392 Reviewed by Dean Jackson.
394 We need to be more aggressive with our approach since AppKit may still ask the
395 scrollbars to paint here.
397 scrollbarAnimationsAreSuppressed() will allow us to find out if the setting has
399 * page/FrameView.cpp:
400 (WebCore::FrameView::scrollbarAnimationsAreSuppressed):
402 * platform/ScrollableArea.h:
403 (WebCore::ScrollableArea::scrollbarAnimationsAreSuppressed):
404 * rendering/RenderLayer.cpp:
405 (WebCore::RenderLayer::scrollbarAnimationsAreSuppressed):
406 * rendering/RenderLayer.h:
408 * rendering/RenderListBox.cpp:
409 (WebCore::RenderListBox::scrollbarAnimationsAreSuppressed):
410 * rendering/RenderListBox.h:
412 Don’t allow animations if scrollbars are suppressed.
413 * platform/mac/ScrollAnimatorMac.mm:
414 (-[WebScrollbarPainterDelegate scrollerImp:animateKnobAlphaTo:duration:]):
416 Call cancelAnimations() to prevent a just-started animation from continuing.
417 (WebCore::ScrollAnimatorMac::finishCurrentScrollAnimations):
419 2013-05-20 Andreas Kling <akling@apple.com>
421 Avoid caret repaints if we're not showing carets anyway.
422 <http://webkit.org/b/116489>
424 Reviewed by Simon Fraser.
426 When moving the selection, check if we're inside a contenteditable element (or in caret browsing mode)
427 before repainting the caret's previous location.
429 * editing/FrameSelection.cpp:
430 (WebCore::FrameSelection::recomputeCaretRect):
432 2013-05-20 Simon Fraser <simon.fraser@apple.com>
434 position:sticky should stick for the enclosing overflow ancestor
435 https://bugs.webkit.org/show_bug.cgi?id=100054
437 Reviewed by Beth Dakin.
439 Make position: -webkit-sticky be constrained by an enclosing ancestor
440 with non-visible overflow if there is one, rather than being constained
441 always by the viewport.
443 Test: fast/css/sticky/sticky-top-overflow.html
445 * rendering/RenderBoxModelObject.cpp:
446 (WebCore::RenderBoxModelObject::computeStickyPositionConstraints): Rename
447 viewportRect to constrainingRect, since it isn't just about the viewport any more.
448 Fix an issue where just adding stickyLocation to absContainerFrame.location() was
449 incorrect when the container is scrolled; we also have to take the scroll offset
450 into account, and that offset is stored in the layer tree.
451 (WebCore::RenderBoxModelObject::stickyPositionOffset):
452 Look for an enclosing layer with overflow clipping, and, if found, use it to
453 compute the sticky constraint rect.
454 * rendering/RenderLayer.h: Add a helpful IncludeSelfOrNot, and fix several member functions
455 to use it place of hard-to-read boolean arguments.
456 Add enclosingOverflowClipLayer(IncludeSelfOrNot).
457 (WebCore::RenderLayer::ancestorCompositingLayer):
458 * rendering/RenderLayer.cpp:
459 (WebCore::RenderLayer::enclosingOverflowClipLayer): New function, finds the enclosing
460 layer with overflow clip.
461 (WebCore::RenderLayer::enclosingCompositingLayer): Use IncludeSelfOrNot.
462 (WebCore::RenderLayer::enclosingCompositingLayerForRepaint): Ditto.
463 (WebCore::RenderLayer::enclosingFilterLayer): Ditto.
464 * rendering/RenderLayerCompositor.cpp:
465 (WebCore::RenderLayerCompositor::repaintInCompositedAncestor): Use IncludeSelfOrNot.
466 (WebCore::isViewportConstrainedFixedOrStickyLayer): Renamed from isRootmostFixedOrStickyLayer
467 and moved up so we can use it in requiresCompositingForPosition().
468 (WebCore::RenderLayerCompositor::requiresCompositingForPosition): Only make sticky composited if
469 it's viewport-constrained.
470 (WebCore::RenderLayerCompositor::updateViewportConstraintStatus):
471 (WebCore::RenderLayerCompositor::computeStickyViewportConstraints): Declare StickyPositionViewportConstraints
472 one line down to just before it gets used.
474 2013-05-20 Jeff Rogers <jrogers@blackberry.com>
476 Remove DISABLE_ROUNDED_CORNER_CLIPPING
477 https://bugs.webkit.org/show_bug.cgi?id=115531
479 Reviewed by Andreas Kling.
481 BlackBerry port is no longer using this.
483 * rendering/RenderLayer.cpp:
484 (WebCore::inContainingBlockChain):
485 (WebCore::RenderLayer::clipToRect):
487 2013-05-20 Tim Horton <timothy_horton@apple.com>
489 Clients should have a way to extend rendering suppression
490 https://bugs.webkit.org/show_bug.cgi?id=116463
491 <rdar://problem/13738496>
493 Reviewed by Andy Estes.
496 Export FrameView::setVisualUpdatesAllowedByClient.
499 (WebCore::Document::setVisualUpdatesAllowed):
500 Move rendering-suppression watchdog into setVisualUpdatesAllowed(bool).
501 setVisualUpdatesAllowed(ReadyState) should not re-enable visual updates
502 if the client is itself disabling visual updates.
504 (WebCore::Document::visualUpdatesSuppressionTimerFired):
505 If the watchdog fires and the client is still disabling visual
506 updates, we should not re-enable visual updates, but instead
509 (WebCore::Document::setVisualUpdatesAllowedByClient):
510 Actually re-enable visual updates if we deferred the re-enabling above
511 (when the page finishes loading, but the client had them disabled).
514 (Document): Add setVisualUpdatesAllowedByClient.
515 * page/FrameView.cpp:
516 (WebCore::FrameView::FrameView): Visual updates are allowed by default.
517 (WebCore::FrameView::setVisualUpdatesAllowedByClient):
518 Forward through to the document, but we also need to persist the state
519 here in FrameView so that it survives through navigation.
522 (WebCore::FrameView::setVisualUpdatesAllowedByClient): Added.
523 (WebCore::FrameView::visualUpdatesAllowedByClient): Added.
524 Added storage for m_visualUpdatesAllowedByClient.
526 2013-05-20 Hans Muller <hmuller@adobe.com>
528 [CSS Exclusions] Add CSS parsing support for image URI shape-inside and shape-outside values
529 https://bugs.webkit.org/show_bug.cgi?id=116349
531 Reviewed by Alexandru Chiculita.
533 Add support for parsing image URI values for the shape-inside and shape-outside CSS properties.
534 Extended the ExclusionShapeValue class to support tracking the property's StyleImage value.
536 The ExclusionShapeValue::type enums were changed from all upper case to "Intercase" by order
539 The existing CSS parsing tests were extended to check URI values.
541 * css/CSSComputedStyleDeclaration.cpp:
542 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
544 (WebCore::CSSParser::parseValue):
545 * css/DeprecatedStyleBuilder.cpp:
546 (WebCore::ApplyPropertyExclusionShape::applyValue):
547 * css/StyleResolver.cpp:
548 (WebCore::StyleResolver::loadPendingImages):
549 * rendering/style/ExclusionShapeValue.h:
550 (WebCore::ExclusionShapeValue::createImageValue):
551 (ExclusionShapeValue):
552 (WebCore::ExclusionShapeValue::image):
553 (WebCore::ExclusionShapeValue::setImage):
554 (WebCore::ExclusionShapeValue::ExclusionShapeValue):
556 2013-05-20 Radu Stavila <stavila@adobe.com>
558 [CSSRegions] Fix offsetLeft / offsetTop for elements inside named flow
559 https://bugs.webkit.org/show_bug.cgi?id=115899
561 Reviewed by David Hyatt.
563 Elements in named flows that have the body as their offsetParent, need to compute their
564 offsetLeft and offsetTop values relative to the body.
566 Tests: fast/regions/offsetLeft-offsetTop-in-multiple-regions.html
567 fast/regions/offsetLeft-offsetTop-in-region-absolute-sticky-fixed.html
568 fast/regions/offsetLeft-offsetTop-in-region-float-vert-rl.html
569 fast/regions/offsetLeft-offsetTop-in-region-float.html
570 fast/regions/offsetLeft-offsetTop-inlines-region-in-element.html
572 * rendering/RenderBoxModelObject.cpp:
573 (WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
574 * rendering/RenderFlowThread.cpp:
576 (WebCore::RenderFlowThread::adjustedPositionRelativeToOffsetParent):
577 * rendering/RenderFlowThread.h:
579 2013-05-20 Zoltan Horvath <zoltan@webkit.org>
581 [CSS Regions][CSS Exclusions] shape-inside on regions should respect positioned shapes and overflow
582 https://bugs.webkit.org/show_bug.cgi?id=116252
584 Reviewed by David Hyatt.
586 Regions should respect shape-inside properties which have specified top offset. Since the content which overflows from the
587 shape should be pushed after the content box (for details check out r148975), I implemented overflowthe behavior for simple
588 cases when you have only one region. I'm going to implement it for additional regions in a follow up patch.
590 Tests: fast/regions/shape-inside/shape-inside-on-regions-block-content-basic-overflow-shape-top-offset.html
591 fast/regions/shape-inside/shape-inside-on-regions-inline-content-basic-overflow-shape-top-offset.html
593 * rendering/RenderBlockLineLayout.cpp:
594 (WebCore::RenderBlock::updateLineBoundariesForExclusions): Handle the flow thread case, push the overflowing content after the
595 content box. Respect existing shape-inside on region tests.
596 (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Set the correct logical top position for the shape-inside in
597 the case of regions. Respect the region's margins and paddings.
599 2013-05-20 Darin Adler <darin@apple.com>
601 Remove custom binding for the Clipboard clearData function
602 https://bugs.webkit.org/show_bug.cgi?id=116421
604 Reviewed by Andreas Kling.
606 * bindings/js/JSClipboardCustom.cpp: Removed the clearData binding.
608 * dom/Clipboard.idl: Removed [Custom].
611 (WebCore::Clipboard::clearData): Renamed from clearAllData.
612 * dom/Clipboard.h: Rename clearAllData to clearData so we just use
613 overloading for the one with and without a MIME type.
614 * platform/ios/ClipboardIOS.h: Rename clearAllData to clearData.
615 * platform/ios/ClipboardIOS.mm:
616 (WebCore::ClipboardIOS::clearData): Ditto.
617 * platform/qt/ClipboardQt.cpp:
618 (WebCore::ClipboardQt::clearData). Ditto.
619 * platform/qt/ClipboardQt.h: Ditto.
620 * platform/win/ClipboardWin.cpp:
621 (WebCore::ClipboardWin::clearData): Ditto.
622 * platform/win/ClipboardWin.h: Ditto.
624 2013-05-20 Eric Carlson <eric.carlson@apple.com>
626 [iOS] media/event-queue-crash.html ASSERTs in notifyChildInserted
627 https://bugs.webkit.org/show_bug.cgi?id=116444
629 Reviewed by Jer Noble.
631 No new tests, covered by existing tests.
633 * html/HTMLMediaElement.cpp:
634 (WebCore::HTMLMediaElement::configureMediaControls): Only create media controls when the
635 element is in a Document.
637 2013-05-20 Antoine Quint <graouts@apple.com>
639 [Mac] captions menu should behave more like a menu
640 https://bugs.webkit.org/show_bug.cgi?id=116436
642 Reviewed by Eric Carlson.
644 Let the captions menu behave more like a native Mac menu by hiding it when
645 clicking anywhere on the page and preventing the page from scrolling when
646 attempting to scroll the captions menu when it cannot scroll in the requested
649 Test: media/video-controls-captions-trackmenu-hide-on-click-outside.html
651 * dom/EventListener.h:
652 Add the new MediaControlsAppleEventListenerType.
654 * html/shadow/MediaControlsApple.cpp:
655 (WebCore::MediaControlsApple::defaultEventHandler):
656 (WebCore::MediaControlsApple::hide):
657 (WebCore::MediaControlsApple::makeTransparent):
658 (WebCore::MediaControlsApple::changedClosedCaptionsVisibility):
659 (WebCore::MediaControlsApple::reportedError):
660 (WebCore::MediaControlsApple::toggleClosedCaptionTrackList):
661 Use the hideClosedCaptionTrackList() and showClosedCaptionTrackList()
662 methods to hide and show the captions menu instead of calling hide()
663 and show() directly on m_closedCaptionsContainer.
665 (WebCore::MediaControlsApple::showClosedCaptionTrackList):
666 Show the m_closedCaptionsContainer and register a "mousewheel" event
667 listener on it as well as a "click" event listener on the entire document.
669 (WebCore::MediaControlsApple::hideClosedCaptionTrackList):
670 Hide the m_closedCaptionsContainer and remove the "mousewheel" event
671 listener on it as well as the "click" event listener on the entire document.
673 (WebCore::MediaControlsApple::shouldClosedCaptionsContainerPreventPageScrolling):
674 New private utility to determine whether the m_closedCaptionsContainer can scroll
675 in the provided scroll direction.
677 (WebCore::MediaControlsApple::eventListener):
678 Obtain the event listener used for "mousewheel" and "click" event handlers.
680 (WebCore::MediaControlsAppleEventListener::handleEvent):
681 Event handler for the "mousewheel" and "click" events. If we get a "click" event, we
682 toggle the captions menu visibility and if we get a "mousewheel" event, we call into
683 shouldClosedCaptionsContainerPreventPageScrolling() to see if we can scroll in the
684 current scroll direction, and if not prevent the event from resulting in a scroll by
685 calling preventDefault().
687 (WebCore::MediaControlsAppleEventListener::operator==):
688 Required for the successful subclassing of EventListener.
690 * html/shadow/MediaControlsApple.h:
691 (MediaControlsAppleEventListener):
692 (WebCore::MediaControlsAppleEventListener::create):
693 (WebCore::MediaControlsAppleEventListener::cast):
694 (WebCore::MediaControlsAppleEventListener::MediaControlsAppleEventListener):
695 New subclass of EventListener required to provide a custom event listener for the
696 "mousewheel" and "click" events registered in showClosedCaptionTrackList() and
697 hideClosedCaptionTrackList().
699 2013-05-18 Rashmi Shyamasundar <rashmi.s2@samsung.com>
701 [Cairo] Canvas-shadow behavior is not being as expected
702 https://bugs.webkit.org/show_bug.cgi?id=108897
704 Reviewed by Martin Robinson.
706 ShadowBlur::endShadowLayer copies the image from shadowContext to cairoContext.
707 CairoContext-path should be empty for doing this copy. Otherwise, the
708 original-image area will also get filled with the shadow.
710 Test: fast/canvas/canvas-image-shadow.html
712 * platform/graphics/cairo/GraphicsContextCairo.cpp:
713 (WebCore::drawPathShadow):
715 2013-05-20 Lamarque V. Souza <Lamarque.Souza@basyskom.com>
717 -webkit-text-underline-position should not be inherited
718 https://bugs.webkit.org/show_bug.cgi?id=116363
720 Reviewed by Dean Jackson.
722 Specification says text-underline-position should not be inherited.
724 No new tests, this updates existing tests.
726 * css/CSSProperty.cpp:
727 (WebCore::CSSProperty::isInheritedProperty): Make
728 CSSPropertyWebkitTextUnderlinePosition return false.
729 * rendering/style/RenderStyle.h: Treat TextUnderlinePosition as
731 * rendering/style/StyleRareInheritedData.cpp:
732 (WebCore::StyleRareInheritedData::StyleRareInheritedData):
733 (WebCore::StyleRareInheritedData::operator==): Remove m_textUnderlinePosition.
734 * rendering/style/StyleRareInheritedData.h:
735 (StyleRareInheritedData):
736 * rendering/style/StyleRareNonInheritedData.cpp:
737 (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
738 (WebCore::StyleRareNonInheritedData::operator==): Add m_textUnderlinePosition.
739 * rendering/style/StyleRareNonInheritedData.h:
740 (StyleRareNonInheritedData):
742 2013-05-20 Lamarque V. Souza <Lamarque.Souza@basyskom.com>
744 Add compile asserts for the size of RootInlineBox and InlineTextbox
745 https://bugs.webkit.org/show_bug.cgi?id=116337
747 Reviewed by Darin Adler.
749 Add compile asserts to ensure RootInlineBox and InlineTextbox stay small.
751 * rendering/InlineTextBox.cpp:
752 (SameSizeAsInlineTextBox):
754 * rendering/RootInlineBox.cpp:
755 (SameSizeAsRootInlineBox):
758 2013-05-20 Xan Lopez <xlopez@igalia.com>
760 [BlackBerry] LocalizedStringsBlackBerry: add dummy text track strings
761 https://bugs.webkit.org/show_bug.cgi?id=116300
763 Reviewed by Rob Buis.
765 These are dummy implementations necessary to make WebKit link.
767 * platform/blackberry/LocalizedStringsBlackBerry.cpp:
768 (WebCore::weekFormatInLDML):
770 (WebCore::textTrackClosedCaptionsText):
771 (WebCore::textTrackSubtitlesText):
772 (WebCore::textTrackOffText):
773 (WebCore::textTrackNoLabelText):
775 2013-05-19 Darin Adler <darin@apple.com>
777 [Mac] Improve string use in PasteboardMac
778 https://bugs.webkit.org/show_bug.cgi?id=116418
780 Reviewed by Sam Weinig.
782 Did a Ben Poulain all over this file.
784 * platform/mac/PasteboardMac.mm:
785 (WebCore::Pasteboard::plainText): Add the newline separately to the string builder.
786 Prepending it to the string first just does more allocations for no good reason.
787 (WebCore::Pasteboard::documentFragment): Use emptyString() instead of "" and use
788 ASCIILiteral where appropriate.
789 (WebCore::cocoaTypeFromHTMLClipboardType): More ASCIILiteral.
790 (WebCore::Pasteboard::clear): Use early return instead of a nested if here.
791 Use emptyString() instead of "".
792 (WebCore::addHTMLClipboardTypesForCocoaType): More ASCIILiteral.
794 2013-05-19 Anders Carlsson <andersca@apple.com>
796 Remove link prerendering code
797 https://bugs.webkit.org/show_bug.cgi?id=116415
799 Reviewed by Darin Adler.
801 * Configurations/FeatureDefines.xcconfig:
802 * GNUmakefile.list.am:
804 * WebCore.vcproj/WebCore.vcproj:
805 * WebCore.vcxproj/WebCore.vcxproj:
806 * WebCore.vcxproj/WebCore.vcxproj.filters:
807 * WebCore.xcodeproj/project.pbxproj:
809 (WebCore::Document::Document):
815 * html/HTMLLinkElement.cpp:
816 * html/HTMLLinkElement.h:
817 * html/LinkRelAttribute.cpp:
818 (WebCore::LinkRelAttribute::LinkRelAttribute):
819 * html/LinkRelAttribute.h:
821 * loader/LinkLoader.cpp:
822 (WebCore::LinkLoader::~LinkLoader):
823 (WebCore::LinkLoader::loadLink):
824 (WebCore::LinkLoader::released):
825 * loader/LinkLoader.h:
828 * loader/LinkLoaderClient.h:
830 * loader/Prerenderer.cpp: Removed.
831 * loader/Prerenderer.h: Removed.
832 * loader/PrerendererClient.cpp: Removed.
833 * loader/PrerendererClient.h: Removed.
834 * platform/PrerenderClient.h: Removed.
835 * platform/PrerenderHandle.h: Removed.
837 2013-05-19 Simon Fraser <simon.fraser@apple.com>
839 Change the terminology used by rendering code when painting a given node and its children from "paintingRoot" to "subtreePaintRoot"
840 https://bugs.webkit.org/show_bug.cgi?id=116417
842 Reviewed by Sam Weinig.
844 PaintInfo and RenderLayer code referred to a "paintingRoot". This is only set when
845 FrameView::setNodeToDraw() has been called and is used to restrict painting to
846 some part of the subtree, but it could easily be misinterpreted, and confused with
847 the "rootLayer" used by RenderLayer (which is usually not the layer associated with
850 Change the terminology from "paintingRoot" to "subtreePaintRoot" root to make the
851 purpose of this variable more obvious.
855 * page/FrameView.cpp: Add a comment for setNodeToDraw(); in future this should
856 be called setSubtreePaintRoot() or something. Not done in this patch to avoid
857 risk; this function is exported from WebCore.
858 * rendering/InlineFlowBox.cpp:
859 (WebCore::InlineFlowBox::paint):
860 * rendering/PaintInfo.h:
861 (WebCore::PaintInfo::PaintInfo):
862 (WebCore::PaintInfo::updateSubtreePaintRootForChildren):
863 (WebCore::PaintInfo::shouldPaintWithinRoot):
864 * rendering/RenderBlock.cpp:
865 (WebCore::RenderBlock::paintContents):
866 * rendering/RenderBox.cpp:
867 (WebCore::RenderBox::paint):
868 * rendering/RenderLayer.cpp:
869 (WebCore::RenderLayer::paint):
870 (WebCore::RenderLayer::paintOverlayScrollbars):
871 (WebCore::RenderLayer::paintLayerContents):
872 (WebCore::RenderLayer::paintLayerByApplyingTransform):
873 (WebCore::RenderLayer::paintBackgroundForFragments):
874 (WebCore::RenderLayer::paintForegroundForFragments):
875 (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
876 (WebCore::RenderLayer::paintOutlineForFragments):
877 (WebCore::RenderLayer::paintMaskForFragments):
878 * rendering/RenderLayer.h:
879 (WebCore::RenderLayer::LayerPaintingInfo::LayerPaintingInfo):
880 * rendering/RenderObject.cpp: Add a comment to recommend changing the name of
881 paintingRootRect() to refer to a subtree paint. Not done in this patch to avoid
882 risk; this function is exported from WebCore.
883 * rendering/RenderSnapshottedPlugIn.cpp:
884 (WebCore::RenderSnapshottedPlugIn::paint):
885 * rendering/RenderTable.cpp:
886 (WebCore::RenderTable::paintObject):
887 * rendering/svg/RenderSVGContainer.cpp:
888 (WebCore::RenderSVGContainer::paint):
890 2013-05-19 Darin Adler <darin@apple.com>
892 Use Element instead of Node in DragState, also redo DragState struct
893 https://bugs.webkit.org/show_bug.cgi?id=116411
895 Reviewed by Sam Weinig.
897 The drag source is an element, so use RefPtr<Element> instead of RefPtr<Node>.
899 Also, the entire drag state is about dragging, so no need for the word "drag" in the
900 name of its members. Also, it's a struct, so the members don't need m_ prefixes.
902 * page/DragController.cpp: Removed unneeded include of Node.h since it's included by
903 Element.h, which is also included.
904 (WebCore::DragController::draggableElement): Renamed from Node to Element and changed
905 the types and names of arguments accordingly. Also made this function handle a
906 startElement of 0 so callers don't need to. Also updated for changes to DragState members.
907 (WebCore::DragController::startDrag): Updated for changes to DragState members.
908 Since dragSource can only be an element, was able to get rid of isElementNode checks.
910 * page/DragController.h: Fixed style of forward declarations of structs. Updated for
911 change of draggableNode to draggableElement. Also removed declarations of nonexistent
912 selectionDraggingRect and doDrag functions.
914 * page/DragState.h: Rewrote practically this whole header. Added an include of Element
915 instead of Node since that's what we use now. Removed includes that are redundant.
916 There's no problem copying a DragState, so removed WTF_MAKE_NONCOPYABLE. There's no need
917 to allocate a DragState on the heap, so removed WTF_MAKE_FAST_ALLOCATED. The event dispatch
918 boolean is never set to a constant, so there's no need for a policy enum; it can just be
919 a boolean. Removed the "m_" prefixes from the struct members, since this is a struct with
920 public members and we don't use the prefix in those cases. Removed the word "drag" from the
921 struct member names since this entire struct is about dragging and has drag in its name.
922 Left the comments mostly intact, even though I'm not certain of their value.
924 * page/EventHandler.cpp:
925 (WebCore::EventHandler::handleMousePressEvent): Updated for changes to DragState.
926 (WebCore::EventHandler::eventMayStartDrag):
927 Use innerElement instead of innerNode to call draggableElement instead of draggableNode.
928 (WebCore::EventHandler::updateDragAndDrop): Updated for changes to DragState.
929 (WebCore::EventHandler::cancelDragAndDrop): Ditto.
930 (WebCore::EventHandler::handleWheelEvent): Added FIXME.
931 (WebCore::EventHandler::dragHysteresisExceeded): Updated for changes to DragState.
932 (WebCore::EventHandler::freeClipboard): Updated for changes to DragState. Also re-added
933 code to release the clipboard object, which is needed here to avoid keeping it around in
934 memory until the next drag.
935 (WebCore::EventHandler::dragSourceEndedAt): Updated for changes to DragState.
936 (WebCore::EventHandler::updateDragStateAfterEditDragIfNeeded): Ditto.
937 (WebCore::EventHandler::dispatchDragSrcEvent): Ditto.
938 (WebCore::EventHandler::handleDrag): Updated for changes to DragState. Use innerElement
939 instead of innerNode to call draggableElement instead of draggableNode. No longer need to
940 null check innerElement because draggableElement does that. Removed unneeded else that was
941 setting m_dragSrc to zero since it's guaranteed to already be zero.
943 2013-05-19 Anders Carlsson <andersca@apple.com>
945 Remove ChromeClient::webView()
946 https://bugs.webkit.org/show_bug.cgi?id=116054
948 Reviewed by Darin Adler.
950 This blatantly horrible layer violation was only used to know if a ChromeClient is an empty
951 client or not. We already have a (slightly less horrible) way to do that.
953 * loader/EmptyClients.h:
954 * page/ChromeClient.h:
957 2013-05-19 Darin Adler <darin@apple.com>
959 Eliminate the Editor::newGeneralClipboard function
960 https://bugs.webkit.org/show_bug.cgi?id=116410
962 Reviewed by Andreas Kling.
964 This is one of the clean-ups made possible by the changes to the DOM clipboard class.
965 I had been waiting until all the platforms were moved over to it, but it turns out to be
966 easy to do this now, just with #ifdefs.
968 * PlatformBlackBerry.cmake: Deleted EditorBlackBerry.cpp.
970 * editing/Editor.cpp:
971 (WebCore::Editor::dispatchCPPEvent): Call Clipboard::createForCopyAndPaste directly when
972 using the new version of the Clipboard class. Also some small style cleanup nearby.
974 * editing/blackberry/EditorBlackBerry.cpp: Removed. The only function in this file was
977 * editing/mac/EditorMac.mm: Deleted newGeneralClipboard.
978 * platform/efl/ClipboardEfl.cpp: Ditto.
979 * platform/gtk/ClipboardGtk.cpp: Ditto.
981 2013-05-19 Martin Robinson <mrobinson@igalia.com>
983 GtkSelectionData length is off by one
984 https://bugs.webkit.org/show_bug.cgi?id=113962
986 Reviewed by Anders Carlsson.
988 No new tests. Since drag data is interpreted as a null-terminated string
989 this is difficult to test with a C program and we have no infrastructure
990 built for using GIR tests.
992 * platform/gtk/PasteboardHelper.cpp:
993 (WebCore::PasteboardHelper::fillSelectionData): Instead of including the null
994 character in the paste data length, just include the string. This matches the behavior
997 2013-05-18 Simon Fraser <simon.fraser@apple.com>
999 Hoist several chunks of code at the top of RenderLayer::paintLayerContents() onto new functions
1000 https://bugs.webkit.org/show_bug.cgi?id=116406
1002 Reviewed by Andreas Kling.
1004 RenderLayer::paintLayerContents() was getting polluted with code related to filters,
1005 clipping and font subpixel quantization, and hard to follow.
1007 Move three hunks of code into new functions:
1008 setupFontSubpixelQuantization() now contains the code related to whether we disable
1009 font subpixel quantization on the context.
1010 setupClipPath() now contains code related to clipping to shapes and references.
1011 setupFilters() and applyFilters() contain code related to CSS filters.
1013 As part of this, the interaction with FilterEffectRendererHelper was simplified.
1014 It was convenient for setupFilters() to return a FilterEffectRendererHelper object
1015 if successful, so we use an OwnPtr<FilterEffectRendererHelper> now. In addition,
1016 the GraphicsContext swapping was moved from FilterEffectRendererHelper code into RenderLayer
1017 to make it easier to follow. FilterEffectRendererHelper no longer holds on to
1018 the old GraphicsContext.
1022 * rendering/FilterEffectRenderer.cpp:
1023 (WebCore::FilterEffectRendererHelper::filterContext):
1024 (WebCore::FilterEffectRendererHelper::beginFilterEffect):
1025 (WebCore::FilterEffectRendererHelper::applyFilterEffect):
1026 * rendering/FilterEffectRenderer.h:
1027 (WebCore::FilterEffectRendererHelper::FilterEffectRendererHelper):
1028 (WebCore::FilterEffectRendererHelper::hasStartedFilterEffect):
1029 (FilterEffectRendererHelper):
1030 * rendering/RenderLayer.cpp:
1031 (WebCore::RenderLayer::setupFontSubpixelQuantization):
1032 (WebCore::RenderLayer::setupClipPath):
1033 (WebCore::RenderLayer::setupFilters):
1034 (WebCore::RenderLayer::applyFilters):
1035 (WebCore::RenderLayer::paintLayerContents):
1036 * rendering/RenderLayer.h:
1038 2013-05-18 Simon Fraser <simon.fraser@apple.com>
1040 Refactor RenderStyle::diff()
1041 https://bugs.webkit.org/show_bug.cgi?id=116397
1043 Reviewed by Andreas Kling.
1045 RenderStyle::diff() was prone to being changed incorrectly, since there was
1046 a poorly documented ordering requirement: style changes that cause layout
1047 have to be detected before those that cause only repainting.
1049 In addition, the existing code made it impossible to separately ask whether
1050 a given style change requires a repaint, if we've already detected that it
1051 requires a positioned-movement-only layout.
1053 Fix by factoring the code into member functions that check for each type
1058 * rendering/style/RenderStyle.cpp:
1059 (WebCore::positionChangeIsMovementOnly):
1060 (WebCore::RenderStyle::changeRequiresLayout):
1061 (WebCore::RenderStyle::changeRequiresPositionedLayoutOnly):
1062 (WebCore::RenderStyle::changeRequiresLayerRepaint):
1063 (WebCore::RenderStyle::changeRequiresRepaint):
1064 (WebCore::RenderStyle::changeRequiresRepaintIfText):
1065 (WebCore::RenderStyle::changeRequiresRecompositeLayer):
1066 (WebCore::RenderStyle::diff):
1067 * rendering/style/RenderStyle.h:
1069 2013-05-18 Anders Carlsson <andersca@apple.com>
1071 Simplify the StorageArea setter functions
1072 https://bugs.webkit.org/show_bug.cgi?id=116402
1074 Reviewed by Sam Weinig.
1076 Move more security checking code to Storage so more code can be shared between WebKit1 and WebKit2.
1078 * inspector/InspectorDOMStorageAgent.cpp:
1079 (WebCore::InspectorDOMStorageAgent::setDOMStorageItem):
1080 (WebCore::InspectorDOMStorageAgent::removeDOMStorageItem):
1081 * storage/Storage.cpp:
1082 (WebCore::Storage::setItem):
1083 (WebCore::Storage::removeItem):
1084 (WebCore::Storage::clear):
1085 * storage/StorageArea.h:
1087 * storage/StorageAreaImpl.cpp:
1088 (WebCore::StorageAreaImpl::setItem):
1089 (WebCore::StorageAreaImpl::removeItem):
1090 (WebCore::StorageAreaImpl::clear):
1091 * storage/StorageAreaImpl.h:
1094 2013-05-18 Anders Carlsson <andersca@apple.com>
1096 Simplify StorageArea getter functions
1097 https://bugs.webkit.org/show_bug.cgi?id=116399
1099 Reviewed by Sam Weinig.
1101 Move the security and private browsing checks from StorageArea to Storage so we can share
1102 more code between WebKit1 and WebKit2.
1104 * inspector/InspectorDOMStorageAgent.cpp:
1105 (WebCore::InspectorDOMStorageAgent::getDOMStorageItems):
1106 Update to new StorageArea interface. The security checks are unnecessary here anyway because
1107 InspectorDOMStorageAgent::findStorageArea will only return a StorageArea that can be accessed
1108 by the frame's security origin.
1110 * storage/Storage.cpp:
1111 (WebCore::Storage::key):
1112 (WebCore::Storage::getItem):
1113 (WebCore::Storage::contains):
1114 * storage/StorageArea.h:
1116 * storage/StorageAreaImpl.cpp:
1117 (WebCore::StorageAreaImpl::key):
1118 (WebCore::StorageAreaImpl::item):
1119 (WebCore::StorageAreaImpl::contains):
1120 * storage/StorageAreaImpl.h:
1123 2013-05-17 Simon Fraser <simon.fraser@apple.com>
1125 Garbage on page background while http://canberraballoons.com.au is loading
1126 https://bugs.webkit.org/show_bug.cgi?id=116384
1127 <rdar://problem/13930328>
1129 Reviewed by Dan Bernstein.
1131 This page loads a large JPEG image as the body background.
1132 ImageSource::frameHasAlphaAtIndex() always claims that JPEG images
1133 are opaque, but this isn't true if the frame is only partially loaded.
1134 However, this would cause FillLayer::hasOpaqueImage() to report that the
1135 background image is opaque, so we'd skip painting the background color.
1136 Unpainted content in an opaque layer results in garbage.
1138 Fix by having ImageSource::frameHasAlphaAtIndex() always return true
1139 for frames that are not complete. When the image load completes, we
1140 recompute metadata and correctly determine that the frame is opaque.
1142 * platform/graphics/cg/ImageSourceCG.cpp:
1143 (WebCore::ImageSource::frameHasAlphaAtIndex):
1145 2013-05-18 Timothy Hatcher <timothy@apple.com>
1147 Simplify EventLoop::cycle() on Mac.
1149 https://webkit.org/b/116392
1151 Reviewed by Anders Carlsson.
1153 * platform/mac/EventLoopMac.mm:
1154 (WebCore::EventLoop::cycle): Use CFRunLoopRunInMode instead.
1156 2013-05-18 Andreas Kling <akling@apple.com>
1158 Use CSSParserSelector::appendTagHistory() from CSS grammar.
1159 <http://webkit.org/b/116382>
1161 Reviewed by Antti Koivisto.
1163 CSSParserSelector already knows how to append another component to itself,
1164 no need to duplicate that logic in the grammar.
1166 * css/CSSGrammar.y.in:
1168 2013-05-18 Patrick Gansterer <paroga@webkit.org>
1170 [CMake] Replace *_LIBRARY_NAME with *_OUTPUT_NAME
1171 https://bugs.webkit.org/show_bug.cgi?id=114554
1173 Reviewed by Gyuyoung Kim.
1175 Using variables as target names is very uncommon in CMake.
1176 The usual way to specify the name of the resulting binary
1177 is to set the OUTPUT_NAME target property.
1181 2013-05-18 Carlos Garcia Campos <cgarcia@igalia.com>
1183 [GTK] Move GTK port off legacy clipboard
1184 https://bugs.webkit.org/show_bug.cgi?id=116221
1186 Reviewed by Martin Robinson.
1188 Merge clipboard methods into PasteboardGtk that now wraps a
1191 * GNUmakefile.list.am: Remove ClipboardGtk.h.
1192 * dom/Clipboard.h: Remove GTK from the list of ports using legacy
1194 * page/gtk/EventHandlerGtk.cpp:
1195 (WebCore::EventHandler::createDraggingClipboard): Use
1196 Clipboard::createForDragAndDrop().
1197 * platform/Pasteboard.h:
1199 * platform/gtk/ClipboardGtk.cpp:
1200 (WebCore::Editor::newGeneralClipboard): Use
1201 Clipboard::createForCopyAndPaste().
1202 (WebCore::Clipboard::createDragImage):
1203 (WebCore::Clipboard::declareAndWriteDragImage):
1204 * platform/gtk/ClipboardGtk.h: Removed.
1205 * platform/gtk/DragDataGtk.cpp:
1206 * platform/gtk/PasteboardGtk.cpp:
1207 (WebCore::Pasteboard::create): Create a new Pasteboard for a given
1208 GtkClipboard or DataObjectGtk.
1209 (WebCore::Pasteboard::createForCopyAndPaste): Create a Pasteboard
1210 for the GDK_SELECTION_CLIPBOARD clipboard.
1211 (WebCore::Pasteboard::createPrivate): Create a Pasteboard without
1212 a GtkClipboard associated.
1213 (WebCore::Pasteboard::createForDragAndDrop): Create a Pasteboard
1214 for drag and drop operations.
1215 (WebCore::selectionClipboard): Return a static Pasteboard for the
1216 GDK_SELECTION_CLIPBOARD clipboard.
1217 (WebCore::primaryClipboard): Return a static Pasteboard for the
1218 GDK_SELECTION_PRIMARY clipboard.
1219 (WebCore::Pasteboard::generalPasteboard): Return
1220 selectionClipboard() or primaryClipboard() depending on whether
1221 primary selection clipboard is the active one or not.
1222 (WebCore::Pasteboard::Pasteboard):
1223 (WebCore::Pasteboard::~Pasteboard):
1224 (WebCore::Pasteboard::dataObject): Return the wrapped DataObjectGtk.
1225 (WebCore::dataObjectTypeFromHTMLClipboardType): Copied from
1227 (WebCore::Pasteboard::writeString): Adapted to upate the wrapped
1228 DataObjectGtk and the GtkClipboard if needed.
1229 (WebCore::Pasteboard::writeSelection): Ditto.
1230 (WebCore::Pasteboard::writePlainText): Ditto.
1231 (WebCore::Pasteboard::writeURL): Ditto.
1232 (WebCore::Pasteboard::writeImage): Ditto.
1233 (WebCore::Pasteboard::writePasteboard): Copy the wrapped
1234 DataObjectGtk from the DataObjectGtk of the given Pasteboard and
1235 upsate the GtkClipboard if needed.
1236 (WebCore::Pasteboard::clear): Copied from ClipboardGtk.cpp.
1237 (WebCore::Pasteboard::canSmartReplace): Check if current
1238 GtkClipboard supports smart replace.
1239 (WebCore::Pasteboard::setDragImage):
1240 (WebCore::Pasteboard::documentFragment): Adapted to use the
1241 wrapped DataObjectGtk reading from the current GtkClipboard if
1243 (WebCore::Pasteboard::plainText): Ditto.
1244 (WebCore::Pasteboard::hasData): Copied from ClipboardGtk.cpp.
1245 (WebCore::Pasteboard::types): Ditto.
1246 (WebCore::Pasteboard::readString): Ditto.
1247 (WebCore::Pasteboard::readFilenames): Ditto.
1249 2013-05-18 Alberto Garcia <agarcia@igalia.com>
1251 [GTK] Parallel build fails if gtk-doc is enabled
1252 https://bugs.webkit.org/show_bug.cgi?id=116227
1254 Reviewed by Martin Robinson.
1257 Don't overwrite noinst_DATA, modify its existing value instead.
1259 2013-05-17 Michelangelo De Simone <michelangelo@webkit.org>
1261 CSSParser parsing of CSSPropertyFontStretch falls into CSSPropertyGeometry
1262 https://bugs.webkit.org/show_bug.cgi?id=116370
1264 CSSPropertyFontStretch mistakenly fell through the shader parsing logic.
1266 Reviewed by Alexandru Chiculita.
1268 No new test possible, the feature is not implemented nor exposed.
1270 * css/CSSParser.cpp:
1271 (WebCore::CSSParser::parseValue):
1273 2013-05-17 Timothy Hatcher <timothy@apple.com>
1275 Force the script debug server to continue when disabling the debugger.
1277 There might be some cases where the debugger will stay in the nested run loop
1278 which cause weird issues.
1280 Speculative fix for: https://webkit.org/b/111438
1282 Reviewed by Joseph Pecoraro.
1284 * inspector/InspectorDebuggerAgent.cpp:
1285 (WebCore::InspectorDebuggerAgent::disable):
1287 2013-05-16 Darin Adler <darin@apple.com>
1289 [BlackBerry] Get BlackBerry port off legacy clipboard
1290 https://bugs.webkit.org/show_bug.cgi?id=116287
1292 Reviewed by Rob Buis.
1294 * PlatformBlackBerry.cmake: Removed ClipboardBlackBerry.cpp.
1296 * dom/Clipboard.h: Removed BLACKBERRY from the list of platforms that
1297 use the legacy clipboard.
1299 * editing/blackberry/EditorBlackBerry.cpp:
1300 (WebCore::Editor::newGeneralClipboard): Changed to just create a copy
1301 and paste clipboard.
1303 * page/blackberry/EventHandlerBlackBerry.cpp: Removed a drag-related
1304 function that wasn't doing any good.
1306 * platform/blackberry/ClipboardBlackBerry.cpp: Removed.
1307 * platform/blackberry/ClipboardBlackBerry.h: Removed.
1309 * platform/blackberry/PasteboardBlackBerry.cpp:
1310 (WebCore::Pasteboard::createForCopyAndPaste): Added.
1311 (WebCore::Pasteboard::createPrivate): Added.
1312 (WebCore::Pasteboard::hasData): Added. Moved code here from ClipboardBlackBerry.cpp.
1313 (WebCore::Pasteboard::clear): Ditto.
1314 (WebCore::Pasteboard::readString): Ditto.
1315 (WebCore::Pasteboard::writeString): Ditto.
1316 (WebCore::Pasteboard::types): Ditto.
1317 (WebCore::Pasteboard::readFilenames): Ditto.
1319 2013-05-17 Andreas Kling <akling@apple.com>
1321 Ads on theverge.com cause repaints when hovered, even though content doesn't visibly change.
1322 <http://webkit.org/b/116344>
1324 Reviewed by Darin Adler.
1326 Teach RenderStyle::diff() to ignore differences in the outline value if both styles have non-visible outlines.
1328 * rendering/style/RenderStyle.cpp:
1329 (WebCore::RenderStyle::diff):
1330 * rendering/style/StyleBackgroundData.cpp:
1331 (WebCore::StyleBackgroundData::isEquivalentForPainting):
1332 * rendering/style/StyleBackgroundData.h:
1333 (StyleBackgroundData):
1335 2013-05-17 Andreas Kling <akling@apple.com>
1337 Plug leak in CSSSelectorList::deleteSelectors().
1338 <http://webkit.org/b/116371>
1339 <rdar://problem/13930698>
1341 Reviewed by Ryosuke Niwa.
1343 Don't forget to destroy the very last selector in the list.
1345 * css/CSSSelectorList.cpp:
1346 (WebCore::CSSSelectorList::deleteSelectors):
1348 2013-05-17 Anders Carlsson <andersca@apple.com>
1350 Share code between WebKit1 and WebKit2 StorageArea subclasses
1351 https://bugs.webkit.org/show_bug.cgi?id=116367
1353 Reviewed by Andreas Kling.
1355 * inspector/InspectorDOMStorageAgent.cpp:
1356 (WebCore::InspectorDOMStorageAgent::getDOMStorageItems):
1357 Remove ec parameter.
1359 * inspector/InspectorDOMStorageAgent.h:
1360 Add forward declaration.
1362 * page/DOMWindow.cpp:
1363 (WebCore::DOMWindow::sessionStorage):
1364 (WebCore::DOMWindow::localStorage):
1365 Storage::StorageArea returns a reference now.
1367 * storage/Storage.cpp:
1368 (WebCore::Storage::length):
1369 Check that the storage area can be accessed by the frame, and that it's not disabled by private browsing.
1370 Then call down to the (now simplified) StorageArea::length().
1372 (WebCore::Storage::isDisabledByPrivateBrowsing):
1373 New helper function that's based on StorageAreaImpl::disabledByPrivateBrowsingInFrame, but reordered
1374 to make it easier to follow.
1376 * storage/Storage.h:
1377 (WebCore::Storage::area):
1380 * storage/StorageAreaImpl.cpp:
1381 (WebCore::StorageAreaImpl::storageType):
1382 Add this new virtual member funciton that's needed by Storage::isDisabledByPrivateBrowsing.
1384 (WebCore::StorageAreaImpl::length):
1385 Remove unneeded code.
1387 2013-05-17 Commit Queue <commit-queue@webkit.org>
1389 Unreviewed, rolling out r150294.
1390 http://trac.webkit.org/changeset/150294
1391 https://bugs.webkit.org/show_bug.cgi?id=116369
1393 Caused 31 tests to fail (Requested by rniwa on #webkit).
1396 * rendering/InlineFlowBox.h:
1397 * rendering/InlineTextBox.h:
1399 * rendering/RenderApplet.h:
1400 * rendering/RenderBR.h:
1401 * rendering/RenderBlock.h:
1403 (WebCore::RenderBlock::virtualContinuation):
1404 * rendering/RenderBox.h:
1405 (WebCore::RenderBox::borderBoundingBox):
1407 (WebCore::RenderBox::marginLogicalLeft):
1408 (WebCore::RenderBox::marginLogicalRight):
1409 * rendering/RenderBoxModelObject.h:
1410 (WebCore::RenderBoxModelObject::isBoxModelObject):
1411 * rendering/RenderButton.h:
1412 * rendering/RenderCombineText.h:
1413 * rendering/RenderCounter.h:
1414 * rendering/RenderDeprecatedFlexibleBox.h:
1415 * rendering/RenderDetailsMarker.h:
1416 * rendering/RenderEmbeddedObject.h:
1417 (RenderEmbeddedObject):
1418 (WebCore::RenderEmbeddedObject::isEmbeddedObject):
1419 (WebCore::RenderEmbeddedObject::virtualChildren):
1420 * rendering/RenderFieldset.h:
1421 * rendering/RenderFileUploadControl.h:
1422 * rendering/RenderFlexibleBox.h:
1423 * rendering/RenderFlowThread.h:
1424 * rendering/RenderFrame.h:
1425 * rendering/RenderFrameSet.h:
1426 * rendering/RenderFullScreen.cpp:
1427 * rendering/RenderFullScreen.h:
1428 * rendering/RenderGrid.h:
1429 * rendering/RenderHTMLCanvas.h:
1430 * rendering/RenderIFrame.h:
1431 * rendering/RenderImage.h:
1433 (WebCore::RenderImage::isRenderImage):
1434 * rendering/RenderInline.h:
1436 (WebCore::RenderInline::virtualContinuation):
1437 (WebCore::RenderInline::virtualChildren):
1438 (WebCore::RenderInline::isRenderInline):
1439 (WebCore::RenderInline::layout):
1440 (WebCore::RenderInline::requiresLayer):
1441 (WebCore::RenderInline::offsetWidth):
1442 (WebCore::RenderInline::offsetHeight):
1443 (WebCore::RenderInline::borderBoundingBox):
1444 (WebCore::RenderInline::dirtyLinesFromChangedChild):
1445 * rendering/RenderLayerModelObject.h:
1446 * rendering/RenderListBox.h:
1447 * rendering/RenderListItem.h:
1448 * rendering/RenderListMarker.h:
1449 * rendering/RenderMedia.h:
1450 (WebCore::RenderMedia::virtualChildren):
1451 (WebCore::RenderMedia::canHaveChildren):
1452 (WebCore::RenderMedia::isMedia):
1453 (WebCore::RenderMedia::isImage):
1454 (WebCore::RenderMedia::requiresForcedStyleRecalcPropagation):
1455 * rendering/RenderMediaControlElements.h:
1456 * rendering/RenderMenuList.h:
1457 * rendering/RenderMeter.h:
1458 * rendering/RenderMultiColumnBlock.h:
1459 * rendering/RenderMultiColumnFlowThread.h:
1460 * rendering/RenderMultiColumnSet.h:
1461 * rendering/RenderNamedFlowThread.h:
1462 * rendering/RenderPart.h:
1464 (WebCore::RenderPart::isRenderPart):
1465 (WebCore::RenderPart::renderName):
1466 * rendering/RenderProgress.h:
1467 * rendering/RenderRegion.h:
1468 (WebCore::RenderRegion::isRenderRegion):
1469 * rendering/RenderRegionSet.h:
1470 * rendering/RenderReplaced.h:
1472 (WebCore::RenderReplaced::renderName):
1473 * rendering/RenderReplica.h:
1474 * rendering/RenderRuby.h:
1475 * rendering/RenderRubyBase.h:
1476 * rendering/RenderRubyRun.h:
1477 * rendering/RenderRubyText.h:
1478 * rendering/RenderScrollbarPart.h:
1479 * rendering/RenderSearchField.h:
1480 * rendering/RenderSlider.h:
1481 * rendering/RenderSnapshottedPlugIn.h:
1482 (RenderSnapshottedPlugIn):
1483 * rendering/RenderTable.h:
1485 (WebCore::RenderTable::renderName):
1486 (WebCore::RenderTable::isTable):
1487 (WebCore::RenderTable::avoidsFloats):
1488 * rendering/RenderTableCaption.h:
1489 * rendering/RenderTableCell.h:
1490 * rendering/RenderTableCol.h:
1491 * rendering/RenderTableRow.h:
1492 * rendering/RenderTableSection.h:
1493 * rendering/RenderText.h:
1495 (WebCore::RenderText::marginLeft):
1496 (WebCore::RenderText::marginRight):
1497 (WebCore::RenderText::styleWillChange):
1498 (WebCore::RenderText::length):
1499 (WebCore::RenderText::paint):
1500 (WebCore::RenderText::layout):
1501 * rendering/RenderTextControl.h:
1502 (RenderTextControl):
1503 (WebCore::RenderTextControl::renderName):
1504 (WebCore::RenderTextControl::isTextControl):
1505 (WebCore::RenderTextControl::avoidsFloats):
1506 * rendering/RenderTextControlMultiLine.h:
1507 * rendering/RenderTextControlSingleLine.h:
1508 (RenderTextControlSingleLine):
1509 (WebCore::RenderTextControlSingleLine::isTextField):
1510 * rendering/RenderTextFragment.h:
1511 * rendering/RenderTextTrackCue.h:
1512 * rendering/RenderVideo.h:
1513 * rendering/RenderView.h:
1514 * rendering/RenderWidget.h:
1516 (WebCore::RenderWidget::isWidget):
1517 * rendering/RenderWordBreak.h:
1518 * rendering/RootInlineBox.h:
1520 * rendering/mathml/RenderMathMLBlock.h:
1521 * rendering/svg/RenderSVGBlock.h:
1523 * rendering/svg/RenderSVGContainer.h:
1524 (WebCore::RenderSVGContainer::setNeedsBoundariesUpdate):
1525 (WebCore::RenderSVGContainer::virtualChildren):
1526 (WebCore::RenderSVGContainer::isSVGContainer):
1527 (WebCore::RenderSVGContainer::renderName):
1528 (RenderSVGContainer):
1529 (WebCore::RenderSVGContainer::objectBoundingBox):
1530 (WebCore::RenderSVGContainer::strokeBoundingBox):
1531 (WebCore::RenderSVGContainer::repaintRectInLocalCoordinates):
1532 * rendering/svg/RenderSVGEllipse.h:
1533 * rendering/svg/RenderSVGForeignObject.h:
1534 * rendering/svg/RenderSVGGradientStop.h:
1535 * rendering/svg/RenderSVGHiddenContainer.h:
1536 (WebCore::RenderSVGHiddenContainer::renderName):
1537 (RenderSVGHiddenContainer):
1538 (WebCore::RenderSVGHiddenContainer::isSVGHiddenContainer):
1539 * rendering/svg/RenderSVGImage.h:
1540 * rendering/svg/RenderSVGInline.h:
1541 (WebCore::RenderSVGInline::renderName):
1542 (WebCore::RenderSVGInline::requiresLayer):
1543 (WebCore::RenderSVGInline::isSVGInline):
1545 * rendering/svg/RenderSVGInlineText.h:
1546 * rendering/svg/RenderSVGModelObject.h:
1547 (WebCore::RenderSVGModelObject::requiresLayer):
1548 (RenderSVGModelObject):
1549 * rendering/svg/RenderSVGPath.h:
1550 * rendering/svg/RenderSVGRect.h:
1551 * rendering/svg/RenderSVGResourceClipper.h:
1552 * rendering/svg/RenderSVGResourceContainer.h:
1553 (RenderSVGResourceContainer):
1554 (WebCore::RenderSVGResourceContainer::isSVGResourceContainer):
1555 (WebCore::RenderSVGResourceContainer::toRenderSVGResourceContainer):
1556 * rendering/svg/RenderSVGResourceFilter.h:
1557 * rendering/svg/RenderSVGResourceFilterPrimitive.h:
1558 * rendering/svg/RenderSVGResourceGradient.h:
1559 (RenderSVGResourceGradient):
1560 (WebCore::RenderSVGResourceGradient::resourceBoundingBox):
1561 * rendering/svg/RenderSVGResourceLinearGradient.h:
1562 * rendering/svg/RenderSVGResourceMarker.h:
1563 * rendering/svg/RenderSVGResourceMasker.h:
1564 * rendering/svg/RenderSVGResourcePattern.h:
1565 * rendering/svg/RenderSVGResourceRadialGradient.h:
1566 * rendering/svg/RenderSVGRoot.h:
1567 * rendering/svg/RenderSVGShape.h:
1568 (WebCore::RenderSVGShape::setNeedsBoundariesUpdate):
1569 (WebCore::RenderSVGShape::setNeedsTransformUpdate):
1570 (WebCore::RenderSVGShape::repaintRectInLocalCoordinates):
1571 (WebCore::RenderSVGShape::localToParentTransform):
1572 (WebCore::RenderSVGShape::localTransform):
1573 (WebCore::RenderSVGShape::isSVGShape):
1575 (WebCore::RenderSVGShape::objectBoundingBox):
1576 (WebCore::RenderSVGShape::strokeBoundingBox):
1577 * rendering/svg/RenderSVGTSpan.h:
1578 * rendering/svg/RenderSVGText.h:
1579 * rendering/svg/RenderSVGTextPath.h:
1580 * rendering/svg/RenderSVGTransformableContainer.h:
1581 * rendering/svg/RenderSVGViewportContainer.h:
1583 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1585 Get rid of Custom code for Audio global constructor
1586 https://bugs.webkit.org/show_bug.cgi?id=116343
1588 Reviewed by Geoffrey Garen.
1590 Remove custom code for Audio global constructor. It is no longer needed
1591 now that the the bindings generator no longer require custom code for
1592 named constructors and now that [EnabledAtRuntime] extended attribute is
1593 supported for global constructors.
1595 HTMLAudioElement global constructors are now automatically generated.
1597 No new tests, no behavior change for layout tests.
1599 * bindings/js/JSDOMWindowCustom.cpp:
1600 * html/HTMLAudioElement.idl:
1601 * page/DOMWindow.idl:
1603 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1605 <rdar://problem/13819878> Disable SharedWorker when in multiple web process model
1606 https://bugs.webkit.org/show_bug.cgi?id=116359
1608 Reviewed by Anders Carlsson.
1610 This feature was already RuntimeEnabled. Call through layers to get the answer from
1611 a platform strategy.
1613 * workers/DefaultSharedWorkerRepository.cpp:
1614 (WebCore::DefaultSharedWorkerRepository::isAvailable):
1615 * workers/DefaultSharedWorkerRepository.h:
1616 * workers/SharedWorkerRepository.cpp:
1617 (WebCore::SharedWorkerRepository::isAvailable):
1618 * workers/SharedWorkerStrategy.h:
1619 (WebCore::SharedWorkerStrategy::isAvailable):
1621 2013-05-17 Anders Carlsson <andersca@apple.com>
1623 Move Storage member functions out of line
1624 https://bugs.webkit.org/show_bug.cgi?id=116364
1626 Reviewed by Andreas Kling.
1628 This is preparation for sharing more code between the WebKit1 and WebKit2 storage area subclasses.
1629 Also remove unnecessary null checks and make m_storageArea const.
1631 * storage/Storage.cpp:
1632 (WebCore::Storage::length):
1633 (WebCore::Storage::key):
1634 (WebCore::Storage::getItem):
1635 (WebCore::Storage::setItem):
1636 (WebCore::Storage::removeItem):
1637 (WebCore::Storage::clear):
1638 (WebCore::Storage::contains):
1639 * storage/Storage.h:
1640 (WebCore::Storage::area):
1642 2013-05-17 Beth Dakin <bdakin@apple.com>
1644 Headers and footers will sometimes disappear and re-appear during page loads
1645 https://bugs.webkit.org/show_bug.cgi?id=116336
1647 <rdar://problem/13886753>
1649 Reviewed by Simon Fraser.
1651 This patch changes the WebCore-level API that WebKit uses to create a banner.
1652 Specifically this patch removes FrameView::setWantsLayerForHeader(), which created
1653 and returned a layer. Instead, WK2 will call Page::addHeaderWithHeight(). When the
1654 layer has been created, it will call back into WK2 via ChromeClient. This will
1655 allow WebCore to re-create the header/footer layers as needed whenever the
1656 FrameView/RenderLayerCompositor have been destroyed and recreated.
1658 Remove references to old FrameView functions. Add references to new Page
1662 New ChromeClient functions will pass the new layers up to WK2.
1663 * page/ChromeClient.h:
1664 (WebCore::ChromeClient::didAddHeaderLayer):
1665 (WebCore::ChromeClient::didAddFooterLayer):
1668 Remove setWantsLayerForHeader/Footer.
1669 * page/FrameView.cpp:
1673 Page now caches the header and footer height. When the FrameView/RLC have been
1674 destroyed, and the cached layer/height information on those classes has been lost,
1675 this data on Page will persist so that we can build the layers back up.
1677 (WebCore::Page::Page):
1678 (WebCore::Page::addHeaderWithHeight):
1679 (WebCore::Page::addFooterWithHeight):
1681 (WebCore::Page::headerHeight):
1682 (WebCore::Page::footerHeight):
1684 As soon as the root gets a backing, recreate the header and footer layers if
1686 * rendering/RenderLayerCompositor.cpp:
1687 (WebCore::RenderLayerCompositor::updateBacking):
1689 Call into ChromeClient.
1690 (WebCore::RenderLayerCompositor::updateLayerForHeader):
1691 (WebCore::RenderLayerCompositor::updateLayerForFooter):
1693 2013-05-18 Claudio Saavedra <csaavedra@igalia.com>
1695 [CSS] Minor cleanups in CSS variables handling
1696 https://bugs.webkit.org/show_bug.cgi?id=116318
1698 Reviewed by Ryosuke Niwa.
1700 No new tests, only a cleanup.
1702 * css/CSSParser.cpp:
1703 (WebCore::CSSParserString::substring): Optimize.
1704 (WebCore::CSSParser::createPrimitiveVariableNameValue):
1705 Remove intermediate variable.
1707 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1709 [Mac] Add DOMWindowConstructors.idl to Xcode project file
1710 https://bugs.webkit.org/show_bug.cgi?id=116351
1712 Reviewed by Anders Carlsson.
1714 * WebCore.xcodeproj/project.pbxproj: Added the file, so that Xcode includes it
1717 2013-05-17 Ryosuke Niwa <rniwa@webkit.org>
1719 Remove the declaration of Element::detachAttrNodeAtIndex erroneously added in r150072.
1724 2013-05-17 Anders Carlsson <andersca@apple.com>
1726 WKKeyValueStorageManagerGetKeyValueStorageOrigins should get origins from the UI process
1727 https://bugs.webkit.org/show_bug.cgi?id=116346
1728 <rdar://problem/13852829>
1730 Reviewed by Andreas Kling.
1732 Export the UTF8Encoding symbol.
1736 2013-05-17 Andreas Kling <akling@apple.com>
1738 Apply FINAL to the RenderObject hierarchy.
1739 <http://webkit.org/b/115977>
1741 Mostly from Blink r148795 by <cevans@chromium.org>
1742 <http://src.chromium.org/viewvc/blink?view=revision&revision=148795>
1744 Re-landing without devirtualization tweaks.
1746 * rendering/: Beat things with the FINAL stick.
1747 * WebCore.exp.in: Export a now-needed symbol.
1749 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1753 * loader/FrameLoader.cpp: (WebCore::FrameLoader::willTransitionToCommitted):
1754 Frame:editor() now returns a reference.
1756 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1758 Get rid of [ConstructorParameters] extended attributes
1759 https://bugs.webkit.org/show_bug.cgi?id=116308
1761 Reviewed by Kentaro Hara.
1763 Get rid of WebKit-specific [ConstructorParameters] IDL extended attribute. Instead,
1764 [CustomConstructor] arguments are now explicitly specified, similarly to [Constructor]
1765 arguments and the constructor object's "length" property is now automatically
1766 computed for custom constructors as well.
1768 This is less error-prone as the value is not hardcoded, more consistent with
1769 [Constructor] extended attribute and gives more information about the custom constructor
1770 in the IDL file. We also get rid of a WebKit-specific IDL attribute which is always
1773 No new tests, already covered by fast/js/constructor-length.html.
1775 * Modules/mediastream/MediaStream.idl:
1776 * Modules/webaudio/AudioContext.idl:
1777 * Modules/websockets/WebSocket.idl:
1778 * bindings/scripts/CodeGeneratorJS.pm:
1779 (GenerateConstructorHelperMethods):
1780 * bindings/scripts/IDLAttributes.txt:
1781 * bindings/scripts/IDLParser.pm:
1783 (parseAttributeRest):
1784 (copyExtendedAttributes):
1785 (parseExtendedAttributeRest):
1786 (applyExtendedAttributeList):
1787 * bindings/scripts/test/JS/JSFloat64Array.cpp:
1788 (WebCore::JSFloat64ArrayConstructor::finishCreation):
1789 * bindings/scripts/test/TestTypedArray.idl:
1790 * dom/MutationObserver.idl:
1792 * html/DOMFormData.idl:
1793 * html/canvas/ArrayBuffer.idl:
1794 * html/canvas/DataView.idl:
1795 * page/WebKitPoint.idl:
1796 * workers/SharedWorker.idl:
1797 * workers/Worker.idl:
1799 2013-05-17 Alexey Proskuryakov <ap@apple.com>
1801 Text input is largely broken when there are subframes loading
1802 http://bugs.webkit.org/show_bug.cgi?id=59121
1803 <rdar://problem/9320468>
1805 Reviewed by Darin Adler.
1807 This addresses text input being abandoned when another frame in a page is navigated.
1809 There are still many opportunities for improvement:
1810 - Track other cases where WebCore interferes may want to cancel input without
1811 direct user action (e.g. deleting the whole editable element on a timer).
1812 - Fix how dictionary panel and autocorrection are dismissed (they still have the
1813 same issue, and get dismissed with any frame navigation).
1815 Test: platform/mac/editing/input/unconfirmed-text-navigation-with-page-cache.html
1817 * loader/FrameLoader.h:
1818 * loader/FrameLoader.cpp:
1819 (WebCore::FrameLoader::willTransitionToCommitted): Make sure that we
1820 do not keep an inline session in a frame that's no longer active, as WebKit2 no
1821 longer takes care of this case (and more of the logic should be in WebCore anyway).
1822 (WebCore::FrameLoader::commitProvisionalLoad): Added a hook that gets invoked right
1823 before transitioning to committed state starts. We may want to move more code here
1824 eventually, e.g. from Frame::setView.
1826 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1828 Get rid of [CustomGetter] for global named constructors
1829 https://bugs.webkit.org/show_bug.cgi?id=116116
1831 Reviewed by Geoffrey Garen.
1833 Improve the JSC bindings generator so that global named constructors no longer
1834 require a [CustomGetter] IDL extended attribute. As a consequence, attributes
1835 on the global window object can now be automatically generated for interfaces
1836 that have a [NamedConstructor], namely HTMLOptionElement.
1838 The HTMLAudioElement global constructors are still manually defined because it
1839 requires custom code at the moment to check if the media player is available.
1841 No new tests, no behavior change.
1843 * bindings/js/JSDOMWindowCustom.cpp:
1844 * bindings/scripts/CodeGeneratorJS.pm:
1845 * bindings/scripts/preprocess-idls.pl:
1846 * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
1847 * bindings/scripts/test/JS/JSTestNamedConstructor.h:
1848 * html/HTMLOptionElement.idl:
1849 * page/DOMWindow.idl:
1851 2013-05-17 Joseph Pecoraro <pecoraro@apple.com>
1853 Web Inspector: SyntaxError evaluating "1+1; //@ sourceURL=test" in console
1854 https://bugs.webkit.org/show_bug.cgi?id=116292
1856 Add a newline after the expression so a single line comment doesn't
1857 erroneously comment out the closing brace of the with block.
1859 Reviewed by Timothy Hatcher.
1861 Test: inspector/console/console-eval-comment.html
1863 * inspector/InjectedScriptSource.js:
1865 2013-05-17 David Hyatt <hyatt@apple.com>
1867 fast/flexbox/auto-height-with-flex.html failing only on release builds.
1868 https://bugs.webkit.org/show_bug.cgi?id=116240
1870 Reviewed by Darin Adler.
1872 Fix the mainAxisContentExtent method so no overflow occurs, since it
1873 doesn't work right on release builds.
1875 * rendering/RenderFlexibleBox.cpp:
1876 (WebCore::RenderFlexibleBox::mainAxisContentExtent):
1878 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
1880 Add [EnabledAtRuntime] extended attribute support for global constructors
1881 https://bugs.webkit.org/show_bug.cgi?id=116147
1883 Reviewed by Geoffrey Garen.
1885 Add [EnabledAtRuntime] extended attribute support for global constructors.
1886 This patch adds [EnabledAtRuntime] extended attribute to SharedWorker and
1887 WebSocket IDL interfaces so that their global constructors on the global
1888 Window object can now be automatically generated.
1890 The behavior on JavaScript side is unchanged. We simply leverage
1891 RuntimeEnabledFeatures class and the new [EnabledAtRuntime] IDL extended
1892 attribute to generate the code for global constructors getters instead
1893 of using custom code.
1895 No new tests, no behavior change for layout tests.
1897 * GNUmakefile.list.am:
1898 * Modules/websockets/WebSocket.cpp: Enable WebSockets at runtime by default.
1899 * Modules/websockets/WebSocket.idl:
1902 * WebCore.vcproj/WebCore.vcproj:
1903 * WebCore.vcxproj/WebCore.vcxproj:
1904 * WebCore.vcxproj/WebCore.vcxproj.filters:
1905 * WebCore.xcodeproj/project.pbxproj:
1906 * bindings/js/JSBindingsAllInOne.cpp:
1907 * bindings/js/JSDOMWindowCustom.cpp:
1909 * bindings/js/JSDOMWindowWebSocketCustom.cpp: Removed.
1910 * bindings/scripts/CodeGeneratorJS.pm:
1912 (GetRuntimeEnableFunctionName):
1913 (GenerateImplementation):
1914 * bindings/scripts/IDLAttributes.txt:
1915 * page/DOMWindow.idl:
1916 * workers/SharedWorker.idl:
1918 2013-05-17 Darin Adler <darin@apple.com>
1920 [EFL] Move EFL port off legacy clipboard
1921 https://bugs.webkit.org/show_bug.cgi?id=116181
1923 Reviewed by Anders Carlsson.
1925 * dom/Clipboard.h: Switched EFL away from "legacy" mode for Clipboard.
1927 * page/efl/EventHandlerEfl.cpp:
1928 (WebCore::EventHandler::createDraggingClipboard): Changed to call Clipboard member function.
1930 * platform/efl/ClipboardEfl.cpp: Deleted most of the functions.
1931 (WebCore::Editor::newGeneralClipboard): Changed to call Clipboard member function.
1932 (WebCore::Clipboard::createDragImage): Moved from ClipboardEfl to Clipboard.
1933 (WebCore::Clipboard::declareAndWriteDragImage): Moved from ClipboardEfl to Clipboard.
1934 (WebCore::Clipboard::items): Ditto.
1936 * platform/efl/PasteboardEfl.cpp: A lot of copyright notices for a file that
1937 has no code in it other than notImplemented lines! I didn't add a new one.
1938 (WebCore::Pasteboard::createForCopyAndPaste): Added.
1939 (WebCore::Pasteboard::createPrivate): Added.
1940 (WebCore::Pasteboard::createForDragAndDrop): Added.
1941 (WebCore::Pasteboard::hasData): Added.
1942 (WebCore::Pasteboard::readString): Added.
1943 (WebCore::Pasteboard::writeString): Added.
1944 (WebCore::Pasteboard::types): Added.
1945 (WebCore::Pasteboard::readFilenames): Added.
1946 (WebCore::Pasteboard::setDragImage): Added.
1947 (WebCore::Pasteboard::writePasteboard): Added.
1949 2013-05-17 Frédéric Wang <fred.wang@free.fr>
1951 Bad spacing inside MathML formulas when text-indent is specified
1952 https://bugs.webkit.org/show_bug.cgi?id=106600
1954 Reviewed by Martin Robinson.
1956 When MathML is used in a HTML page that modifies the CSS text-indent,
1957 large gaps appear inside the mathematical expressions. Resetting it to
1958 0 on the math root (as Gecko does) fixes the issue.
1960 Tests: mathml/presentation/text-indent.html
1961 mathml/presentation/text-indent-expected.html
1964 (math): reset text-indent to its default value.
1966 2013-05-17 Alberto Garcia <agarcia@igalia.com>
1968 Fix code that expects Page::chrome() to return a pointer
1969 https://bugs.webkit.org/show_bug.cgi?id=116313
1971 Reviewed by Darin Adler.
1973 Page::chrome() returns a reference after r150214.
1975 * platform/network/blackberry/NetworkManager.cpp:
1976 (WebCore::NetworkManager::startJob):
1977 * platform/network/blackberry/SocketStreamHandleBlackBerry.cpp:
1978 (WebCore::SocketStreamHandle::SocketStreamHandle):
1979 * testing/Internals.cpp:
1980 (WebCore::Internals::resetToConsistentState):
1981 (WebCore::Internals::setEnableMockPagePopup):
1983 2013-05-17 Alberto Garcia <agarcia@igalia.com>
1985 [BlackBerry] ImageBlackBerry: add missing BlendMode parameter
1986 https://bugs.webkit.org/show_bug.cgi?id=116316
1988 Reviewed by Carlos Garcia Campos.
1990 When the new BitmapImage::draw() method was added in r147110 it
1991 didn't include the BlendMode parameter, which has been there since
1994 * platform/graphics/blackberry/ImageBlackBerry.cpp:
1995 (WebCore::BitmapImage::draw):
1997 2013-05-16 Jer Noble <jer.noble@apple.com>
1999 Some media/track tests fail or assert on Mac
2000 https://bugs.webkit.org/show_bug.cgi?id=97132
2002 Reviewed by Simon Fraser.
2004 Rationalize the font and padding behavior of cues and cue boxes; ::cue pseudo elements cannot have padding
2005 values applied via CSS (due to padding not being included in the whitelist of applicable CSS properties).
2006 Also, the font values were being applied to the box at one level and the cue at another, leading to incorrect
2007 layout in the snapToLines case. Padding has been removed from the cue, and the font settings are now applied
2008 to the box exclusively.
2010 Additionally, a few drive-by changes were made in TextTrackCue to the return values of displayTreeInternal() &
2011 element(), which previously returned a PassRefPtr<> instead of a plain pointer.
2013 * css/mediaControls.css:
2014 (video::-webkit-media-text-track-container): Move the font size to the display selector.
2015 (video::cue): Remove the display:inline and padding:2px declarations.
2016 (video::-webkit-media-text-track-display): Remove the -webkit-line-content now that the ::cue has no padding.
2017 * html/track/TextTrackCue.cpp:
2018 (WebCore::TextTrackCue::TextTrackCue): The background box is now a span, rather than a forced-inline div.
2019 (WebCore::TextTrackCue::displayTreeInternal): Return a plain pointer.
2020 (WebCore::TextTrackCue::getDisplayTree): Ditto.
2021 (WebCore::TextTrackCue::setFontSize): Set the font on the box, not the cue.
2022 * html/track/TextTrackCue.h:
2023 (WebCore::TextTrackCue::element): Return a plain pointer.
2024 * html/track/TextTrackCueGeneric.cpp:
2025 (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties): The cue element is now a span, not a div.
2026 * page/CaptionUserPreferencesMac.mm:
2027 (WebCore::CaptionUserPreferencesMac::captionsWindowCSS): Whitespace.
2028 (WebCore::CaptionUserPreferencesMac::captionsBackgroundCSS): Do not set padding on the cue.
2030 2013-05-16 Andreas Kling <akling@apple.com>
2032 Changes in text-only properties shouldn't cause repaints unless there is actually text.
2033 <http://webkit.org/b/116250>
2035 Reviewed by Antti Koivisto.
2037 Add a new StyleDifferenceRepaintIfText value to the repertoire of RenderStyle::diff().
2038 This result means that the renderer only needs to repaint if one of its immediate children contains text.
2040 This lets us avoid repainting the same pixels when hovering over constructs like:
2043 a { text-decoration: none; }
2044 a:hover { text-decoration: underline; }
2046 <a href="http://is.gd/andersca">
2047 <img src="cool-hat.jpg">
2050 Since the change in text-decoration has no effect on the rendering of the <img> element,
2051 we'll now be smart enough to avoid repainting it.
2053 * rendering/style/RenderStyleConstants.h:
2054 * rendering/style/RenderStyle.cpp:
2055 (WebCore::RenderStyle::diff):
2057 Move checking of text-only properties until the very end, and return StyleDifferenceRepaintIfText
2058 in case a difference is found, giving precedence to StyleDifferenceRepaint.
2060 * rendering/RenderObject.h:
2061 * rendering/RenderObject.cpp:
2062 (WebCore::RenderObject::hasImmediateNonWhitespaceTextChild):
2064 Helper to check if a RenderObject has at least one RenderText child containing more than just
2065 collapsible whitespace.
2067 (WebCore::RenderObject::shouldRepaintForStyleDifference):
2069 Helper to check if a StyleDifference is either ...Repaint or ...RepaintIfText and the renderer
2070 has an immediate text child.
2072 (WebCore::RenderObject::styleWillChange):
2073 (WebCore::RenderObject::setStyle):
2075 Don't repaint for StyleDifferenceRepaintIfText unless hasImmediateNonWhitespaceTextChild().
2077 * rendering/RenderBox.cpp:
2078 (WebCore::RenderBox::styleDidChange):
2079 * rendering/svg/SVGResourcesCache.cpp:
2080 (WebCore::SVGResourcesCache::clientStyleChanged):
2082 Tweak for new StyleDifference enum value.
2084 * rendering/RenderText.h:
2085 * rendering/RenderText.cpp:
2086 (WebCore::RenderText::isAllCollapsibleWhitespace):
2090 2013-05-17 Lamarque V. Souza <Lamarque.Souza@basyskom.com>
2092 Improve -webkit-text-underline-position memory usage.
2093 https://bugs.webkit.org/show_bug.cgi?id=116108
2095 Reviewed by Benjamin Poulain.
2097 Remove m_maxLogicalTop private variable from RootInlineBox to reduce
2098 the overall memory used to render RootInlineBoxes (eight bytes per RootInlineBox
2099 instance in a 64-bit machine). RootInline::maxLogicalTop() now computes
2100 the maxLogicalTop value everytime it is called. In a typical page
2101 computeMaxLogicalTop is called less than 10 times for each
2102 InlineTextBox that uses -webkit-text-underline-position. That is a small
2103 price users of -webkit-text-underline-position will pay so that
2104 everybody can benefit from the memory reduction in RootInlineBox.
2106 No new tests, no change in behavior.
2108 * rendering/InlineFlowBox.cpp:
2109 (WebCore::InlineFlowBox::computeMaxLogicalTop): Make it const.
2110 * rendering/InlineFlowBox.h:
2111 * rendering/RootInlineBox.cpp:
2112 (WebCore::RootInlineBox::RootInlineBox): Remove m_maxLogicalTop.
2113 (WebCore::RootInlineBox::alignBoxesInBlockDirection): Remove
2114 computeMaxLogicalTop call and obsolete comment.
2116 (WebCore::RootInlineBox::maxLogicalTop): Compute maxLogicalTop before
2117 returning its value.
2118 * rendering/RootInlineBox.h:
2121 2013-05-17 Alexis Menard <alexis@webkit.org>
2123 Make sure to call release() on our smart pointers when we should.
2124 https://bugs.webkit.org/show_bug.cgi?id=116307
2126 Reviewed by Andreas Kling.
2128 Call release() when we should call it. There is probably more occurence
2129 of this problem on the codebase but this is a first bunch of fixes.
2131 No new tests : existing ones should cover.
2133 * css/CSSComputedStyleDeclaration.cpp:
2134 (WebCore::valueForNinePieceImage):
2135 (WebCore::getBorderRadiusShorthandValue):
2136 (WebCore::CSSComputedStyleDeclaration::valueForFilter):
2137 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2138 (WebCore::CSSComputedStyleDeclaration::getCSSPropertyValuesForSidesShorthand):
2139 (WebCore::CSSComputedStyleDeclaration::getCSSPropertyValuesForGridShorthand):
2140 * css/CSSParser.cpp:
2141 (WebCore::CSSParser::parseBorderImage):
2142 * html/HTMLBodyElement.cpp:
2143 (WebCore::HTMLBodyElement::collectStyleForPresentationAttribute):
2145 2013-05-17 Allan Sandfeld Jensen <allan.jensen@digia.com>
2147 Make PNGImageDecoder::rowAvailable auto-vectorizable
2148 https://bugs.webkit.org/show_bug.cgi?id=116151
2150 Reviewed by Benjamin Poulain.
2152 Changed the main loops under PNGImageDecoder::rowAvailable so that they
2153 avoid branches and non-sequential table look ups.
2155 Together with automatic vectorization by the compiler this provides around
2156 4x speed-up with AVX or 2x speed-up on generic x64. Shaving off 12-40% on
2157 PNG decoding in general.
2159 * platform/graphics/Color.cpp:
2160 (WebCore::premultipliedARGBFromColor):
2161 * platform/graphics/Color.h:
2162 (WebCore::fastDivideBy255):
2163 * platform/graphics/filters/FEBlend.cpp:
2164 * platform/image-decoders/png/PNGImageDecoder.cpp:
2165 (WebCore::setPixelRGB):
2166 (WebCore::setPixelRGBA):
2167 (WebCore::setPixelRGBA_Premultiplied):
2168 (WebCore::PNGImageDecoder::rowAvailable):
2170 2013-05-17 Joseph Pecoraro <pecoraro@apple.com>
2172 Web Inspector: Allow "//# sourceMappingURL" syntax alongside "//@"
2173 https://bugs.webkit.org/show_bug.cgi?id=116290
2175 Follow an update to the spec and support the new and old syntax.
2177 Reviewed by Timothy Hatcher.
2179 * inspector/ContentSearchUtils.cpp:
2180 (WebCore::ContentSearchUtils::scriptCommentPattern):
2181 (WebCore::ContentSearchUtils::stylesheetCommentPattern):
2182 * inspector/front-end/SASSSourceMapping.js:
2183 (WebInspector.SASSSourceMapping.prototype._loadAndProcessSourceMap):
2185 2013-05-17 Christophe Dumez <ch.dumez@sisa.samsung.com>
2187 Remove custom code for MessageEvent.ports getter
2188 https://bugs.webkit.org/show_bug.cgi?id=116304
2190 Reviewed by Kentaro Hara.
2192 Remove Custom code for the "ports" attribute getter in MessageEvent
2193 IDL interface. The JSC bindings generator already supports attributes
2194 of type MessagePortArray.
2196 No new tests, already covered by existing layout tests and bindings
2199 * bindings/js/JSMessageEventCustom.cpp: Remove Custom code for ports getter.
2200 * bindings/scripts/CodeGeneratorJS.pm:
2201 (NativeToJSValue): Small tweak to correctly handle the case where impl->ports()
2202 returns NULL and avoid crashing in this case.
2203 * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp: Rebaseline due
2204 to bindings generator tweak.
2205 * dom/MessageEvent.idl: Remove [CustomGetter] extended attribute for 'ports' attribute
2206 and switch to MessagePortArray type.
2208 2013-05-16 Jesus Sanchez-Palencia <jesus.palencia@openbossa.org>
2210 Add stubs for ContextMenu and ContextMenuItem
2211 https://bugs.webkit.org/show_bug.cgi?id=116235
2213 Reviewed by Antonio Gomes.
2215 No new tests needed, only a refactor.
2217 Add ContextMenuNone.cpp and ContextMenuItemNone.cpp
2218 so ports using ENABLE(CROSS_PLATFORM_CONTEXT_MENU) don't
2219 need to replicate these stubs.
2221 * PlatformEfl.cmake:
2223 * platform/ContextMenuNone.cpp: Added.
2225 (WebCore::ContextMenu::ContextMenu):
2226 (WebCore::ContextMenu::getContextMenuItems):
2227 (WebCore::ContextMenu::createPlatformContextMenuFromItems):
2228 (WebCore::ContextMenu::platformContextMenu):
2229 * platform/ContextMenuItemNone.cpp: Added.
2231 (WebCore::ContextMenuItem::platformContextMenuItem):
2232 * platform/efl/ContextMenuEfl.cpp: Removed.
2233 * platform/efl/ContextMenuItemEfl.cpp: Removed.
2234 * platform/qt/ContextMenuQt.cpp: Removed.
2235 * platform/qt/ContextMenuItemQt.cpp: Removed.
2237 2013-05-16 Alexis Menard <alexis@webkit.org>
2239 Regression: Event#stopPropagation() does not halt bubbling for webkitTransitionEnd
2240 https://bugs.webkit.org/show_bug.cgi?id=115656
2242 Reviewed by Darin Adler.
2244 If we create a prefixed event to dispatch it (in the case we have only
2245 prefixed event listeners in client's code) then we need to make sure to
2246 keep it in sync with the original unprefixed event after it has been
2247 dispatched. While being dispatched the event can be modified by
2248 client's code and when propagated back to outer elements, attributes were
2249 not updated. This patch changes the old design of creating a separate event
2250 for the prefixed case and now change the type of the event (so the name) before
2251 dispatching it, keeping the attributes if changed and then rename it
2252 back to unprefixed when the dispatching is finished.
2254 Tests: transitions/transition-end-event-prefixed-01.html
2255 transitions/transition-end-event-prefixed-02.html
2256 transitions/transition-end-event-prefixed-03.html
2259 (WebCore::Event::setType):
2260 * dom/EventTarget.cpp:
2261 (WebCore::EventTarget::fireEventListeners):
2263 2013-05-16 Mike Fenton <mifenton@rim.com>
2265 [BlackBerry] Strip invoke URLs when writing to the clipboard.
2266 https://bugs.webkit.org/show_bug.cgi?id=116226
2268 Reviewed by Rob Buis.
2272 Invoke URLs should not be included in the paste data.
2274 Internally Reviewed by Gen Mak.
2276 * platform/blackberry/PasteboardBlackBerry.cpp:
2277 (WebCore::Pasteboard::writeSelection):
2279 2013-05-16 Eduardo Lima Mitev <elima@igalia.com>
2281 Missing UNUSED_PARAM macro for textPosition argument in WebKitAccessibleInterfaceText
2282 https://bugs.webkit.org/show_bug.cgi?id=116230
2284 Reviewed by Chris Fleizach.
2286 No new functionality, no new tests.
2288 * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
2289 (webkitAccessibleTextGetTextForOffset): List textPosition argument as
2290 unused parameter for all platforms except GTK.
2292 2013-05-16 Jaehun Lim <ljaehun.lim@samsung.com>
2294 Frame flattening prevents <HTML> in <OBJECT> from having scrollbars
2295 https://bugs.webkit.org/show_bug.cgi?id=115884
2297 Reviewed by Antonio Gomes.
2299 Frame flattening should be applied when the frame owner is frame or iframe. But when
2300 the frame owner is object element, frame flattening prevents it from having scrollbars.
2301 In this situation, we can't scroll the html document in object element.
2303 This patch adds two helper functions to verify flattening conditions.
2305 Test: fast/frames/flattening/scrolling-in-object.html
2307 * page/FrameView.cpp:
2308 (WebCore::frameFlatteningEnabled): Added. Helper to check whether flattening is enabled or not.
2309 (WebCore::supportsFrameFlattening): Added. Helper to check whether the frame owner is <frame> or <iframe>.
2310 (WebCore::FrameView::avoidScrollbarCreation):
2311 (WebCore::FrameView::calculateScrollbarModesForLayout): Use frameFlatteningEnabled().
2312 (WebCore::FrameView::layout): Use frameFlatteningEnabled().
2313 (WebCore::FrameView::isInChildFrameWithFrameFlattening): Use frameFlatteningEnabled().
2315 2013-05-16 Patrick Gansterer <paroga@webkit.org>
2317 Port functions for pathhandling to Windows CE in FileSystemWin
2318 https://bugs.webkit.org/show_bug.cgi?id=116208
2320 Reviewed by Darin Adler.
2322 This will allow us to remove FileSystemWinCE in a next step.
2324 * platform/win/FileSystemWin.cpp:
2325 (WebCore::pathByAppendingComponent):
2326 (WebCore::pathGetFileName):
2328 2013-05-16 Tim Horton <timothy_horton@apple.com>
2330 PDFPlugins don't load when plugins are disabled, but they should
2331 https://bugs.webkit.org/show_bug.cgi?id=75790
2332 <rdar://problem/11650197>
2334 Reviewed by Anders Carlsson.
2336 Make it possible to load "application" plug-ins even if settings or the FrameLoaderClient
2337 say that plug-ins should be disabled, providing a mechanism for WebKit* to offer built-in
2338 functionality which happens to use the plug-in infrastructure, and which also doesn't
2339 unexpectedly disappear for users with plug-ins off.
2342 Export SubframeLoader::allowPlugins().
2343 Update signature for PluginData::supportsMimeType to include the AllowedPluginTypes argument.
2345 * dom/DOMImplementation.cpp:
2346 (WebCore::DOMImplementation::createDocument):
2347 Load PluginData even if plug-ins are disabled, but if that is the case, only
2348 create a PluginDocument for application plug-ins.
2350 * html/PluginDocument.cpp:
2351 (WebCore::PluginDocumentParser::appendBytes):
2352 Don't bail if plug-ins are disabled, because we could still be a PluginDocument
2353 for an application plug-in.
2356 (WebCore::Page::pluginData):
2357 Allow PluginData to be constructed even if plug-ins are disabled, as there might
2358 be application plug-ins that we want to load anyway.
2360 * platform/mac/MIMETypeRegistryMac.mm:
2361 (WebCore::MIMETypeRegistry::isApplicationPluginMIMEType):
2362 On Mac, if we have PDFPlugin, we can support PDF and PostScript with a native application plug-in.
2364 * plugins/PluginData.cpp:
2365 (WebCore::PluginData::supportsMimeType):
2366 Add an AllowedPluginTypes argument to supportsMimeType, allowing callers to specify
2367 whether they are looking for any plug-in, or are looking only for application plug-ins.
2369 * plugins/PluginData.h:
2370 (PluginInfo): Added an isApplicationPlugin field, to specify whether this is a "built-in" plug-in.
2371 (PluginData): Add the aforementioned AllowedPluginTypes enum and the argument to supportsMimeType.
2373 2013-05-16 Carlos Garcia Campos <cgarcia@igalia.com>
2375 [BlackBerry] Crash due to an assert running test editing/execCommand/indent-paragraphs.html
2376 https://bugs.webkit.org/show_bug.cgi?id=114944
2378 Reviewed by Rob Buis.
2380 It crashes in network platform code when trying to save an
2381 invalid URL in the disk cache. That test contains references to
2382 empty URLs like http://. Those empty URLs, are parsed as http:/ by
2383 KURL and considered valid. BlackBerry network platform uses GURL
2384 which considers those URLs invalid. We needed to check that the
2385 URLs are valid for our platform before starting the network
2388 Fixes a crash running test
2389 editing/execCommand/indent-paragraphs.html.
2391 * platform/network/blackberry/NetworkManager.cpp:
2392 (WebCore::NetworkManager::startJob): Check if the request URL is
2393 valid from the platform point of view right after creating the
2394 platform network request and return early if the URL is invalid
2395 with StatusErrorInvalidUrl error.
2397 2013-05-16 Patrick Gansterer <paroga@webkit.org>
2399 Remove unused function safeCreateFile() from WebCore
2400 https://bugs.webkit.org/show_bug.cgi?id=116211
2402 Reviewed by Anders Carlsson.
2404 * platform/FileSystem.h:
2405 * platform/win/FileSystemWin.cpp:
2407 2013-05-16 Peter Gal <galpeter@inf.u-szeged.hu>
2409 [curl] MIME type should be in lowercase
2410 https://bugs.webkit.org/show_bug.cgi?id=116218
2412 Reviewed by Benjamin Poulain.
2414 Existing testcase: http/tests/mime/uppercase-mime-type.html
2416 * platform/network/curl/ResourceHandleManager.cpp:
2417 (WebCore::headerCallback): Convert the MIME type to lowercase.
2419 2013-05-16 Seokju Kwon <seokju.kwon@gmail.com>
2421 Web Inspector: Fix optional value of promptText in Inspector.json
2422 https://bugs.webkit.org/show_bug.cgi?id=116203
2424 Reviewed by Joseph Pecoraro.
2426 Merge from https://chromiumcodereview.appspot.com/14672031.
2428 No new tests needed.
2430 * inspector/Inspector.json:
2432 2013-05-16 Mary Wu <mary.wu@torchmobile.com.cn>
2434 [BlackBerry] Unable to download blob resource
2435 https://bugs.webkit.org/show_bug.cgi?id=115888
2437 Reviewed by Benjamin Poulain.
2439 Add BlobStream to handle over blob data from BlobResourceHandle to download stream.
2440 RIM bug 331086, internally reviewed by Charles Wei and Leo Yang.
2442 * PlatformBlackBerry.cmake:
2443 * platform/network/blackberry/BlobStream.cpp: Added.
2445 (WebCore::BlobStream::BlobStream):
2446 (WebCore::BlobStream::~BlobStream):
2447 (WebCore::BlobStream::didReceiveData):
2448 (WebCore::BlobStream::didFinishLoading):
2449 (WebCore::BlobStream::didFail):
2450 (WebCore::BlobStream::url):
2451 (WebCore::BlobStream::mimeType):
2452 * platform/network/blackberry/BlobStream.h: Added.
2456 2013-05-16 Anders Carlsson <andersca@apple.com>
2458 Remove SystemTime header and implementations
2459 https://bugs.webkit.org/show_bug.cgi?id=116200
2461 Reviewed by Alexey Proskuryakov.
2463 SystemTim just had a single function that's not called anymore. Remove it.
2465 * GNUmakefile.list.am:
2466 * PlatformBlackBerry.cmake:
2467 * PlatformEfl.cmake:
2468 * PlatformWinCE.cmake:
2470 * WebCore.vcproj/WebCore.vcproj:
2471 * WebCore.vcxproj/WebCore.vcxproj:
2472 * WebCore.vcxproj/WebCore.vcxproj.filters:
2473 * WebCore.xcodeproj/project.pbxproj:
2474 * history/PageCache.cpp:
2475 * platform/SystemTime.h: Removed.
2476 * platform/blackberry/SystemTimeBlackBerry.cpp: Removed.
2477 * platform/efl/SystemTimeEfl.cpp: Removed.
2478 * platform/graphics/ca/GraphicsLayerCA.cpp:
2479 * platform/mac/SystemTimeMac.cpp: Removed.
2480 * platform/qt/TemporaryLinkStubsQt.cpp:
2481 * platform/win/SystemTimeWin.cpp: Removed.
2483 2013-05-16 Glenn Adams <glenn@skynav.com>
2485 [Inspector] Don't filter syntax error caused by asterisk in CSS Property name.
2486 https://bugs.webkit.org/show_bug.cgi?id=116196
2488 Reviewed by Benjamin Poulain.
2490 * inspector/InspectorConsoleAgent.cpp:
2491 (WebCore::InspectorConsoleAgent::addMessageToConsole):
2492 - Remove questionable IE7 related error filtering
2494 2013-05-16 Andreas Kling <akling@apple.com>
2496 Page::chrome() should return a reference.
2497 <http://webkit.org/b/116185>
2499 Reviewed by Anders Carlsson.
2501 A Page's chrome() can never be null. Change Page::chrome() to return a reference to reflect this.
2502 Also, make Page::m_chrome a const member variable so nobody will accidentally set it to null.
2504 2013-05-16 Simon Fraser <simon.fraser@apple.com>
2506 Content disappears when scrolling http://www.childrenscancer.org/zach/
2507 https://bugs.webkit.org/show_bug.cgi?id=116206
2509 Reviewed by Darin Adler.
2511 When a RenderLayerBacking gains or loses a foregroundLayer or backgroundLayer,
2512 we need to repaint the primary layer, since what paints into that primary
2515 On the page in question, we gained/lost a foreground layer when scrolling because
2516 the page popped an element into position:fixed.
2518 Test: compositing/repaint/foreground-layer-change.html
2520 * rendering/RenderLayerBacking.cpp:
2521 (WebCore::RenderLayerBacking::updateForegroundLayer):
2522 (WebCore::RenderLayerBacking::updateBackgroundLayer):
2524 2013-05-16 Andy Estes <aestes@apple.com>
2526 Do not indefinitely cache resources from blob URLs.
2528 Reviewed by Alexey Proskuryakov.
2530 Alexey pointed out after I landed r150169 that blob URLs backed by
2531 files should return an error if the file changed after the URL was
2532 created. By indefinitely caching them in memory, we don't give the
2533 loader a chance to check for modification. Remove "blob" from the list
2534 of schemes that should be indefinitely cached.
2536 * platform/SchemeRegistry.cpp:
2537 (WebCore::SchemeRegistry::shouldCacheResponsesFromURLSchemeIndefinitely):
2539 2013-05-16 Claudio Saavedra <csaavedra@igalia.com>
2541 [CSS] CSS Variables are case-sensitive
2542 https://bugs.webkit.org/show_bug.cgi?id=116239
2544 Reviewed by Ryosuke Niwa.
2546 The CSS Variables specification states that variables are
2547 case-sensitive, unlike other CSS properties.
2549 Test: fast/css/variables/case-sensitive.html
2551 * css/CSSParser.cpp:
2552 (WebCore::CSSParserString::substring): Replace
2553 the now unnecessary lowerSubstring() with this method.
2554 Also, since the method is only used by the CSS variables
2555 implementation, #ifdef it.
2556 (WebCore::CSSParser::createPrimitiveVariableNameValue):
2557 (WebCore::CSSParser::storeVariableDeclaration):
2558 Do not normalize variable declarations to lowercase.
2559 * css/CSSParserValues.h:
2560 (CSSParserString): Replace the lowerSubstring() declaration
2561 and wrap with #if/#endif.
2563 2013-05-16 Brady Eidson <beidson@apple.com>
2565 svg/as-image/img-zoom-svg-stylesheet.html crashes with NetworkProcess enabled.
2566 <rdar://problem/13837408> and https://bugs.webkit.org/show_bug.cgi?id=115917
2568 Reviewed by Sam Weinig.
2570 Give WebKit2 the ability to not mis-cast.
2572 * loader/FrameLoaderClient.h:
2573 (WebCore::FrameLoaderClient::isEmptyFrameLoaderClient): Defaults to false, and include a FIXME
2574 to remove it once https://bugs.webkit.org/show_bug.cgi?id=116233 is resolved.
2576 * loader/EmptyClients.h: Make isEmptyFrameLoaderClient() return true, and add a FIXME to remove it.
2578 2013-05-14 Martin Robinson <mrobinson@igalia.com>
2580 [GTK] Add support for building WebCore to the cmake build
2581 https://bugs.webkit.org/show_bug.cgi?id=116128
2583 Reviewed by Gustavo Noronha Silva.
2585 * PlatformGTK.cmake: Added.
2586 * platform/gtk/GtkVersioning.c: Include "config.h" because we removed
2587 the autotoolsconfig.h include from the header.
2588 * platform/gtk/GtkVersioning.h: Remove autotoolsconfig.h include to support for
2589 non-autotools build systems.
2591 2013-05-15 Ryosuke Niwa <rniwa@webkit.org>
2593 DocumentOrderedMap doesn't need to have two HashMaps
2594 https://bugs.webkit.org/show_bug.cgi?id=116167
2596 Reviewed by Geoffrey Garen.
2598 Previously, we had two hash maps: m_map and m_duplicateCounts in DocumentOrderedMap to keep track
2599 of the first element and the number of duplicates for a given name. This patch simplifies this structure
2600 by having a single hash map that contains both the pointer and the number of duplicates.
2602 In addition, this patch fixes a regression introduced in r149652 that window and document name maps
2603 were not updated for some elements inside a SVG use element, and makes use of the newly added list of
2604 the matching elements in SelectorQuery.
2606 * dom/DocumentOrderedMap.cpp:
2607 (WebCore::DocumentOrderedMap::clear): Updated to use the new hash map.
2608 (WebCore::DocumentOrderedMap::add): Ditto.
2609 (WebCore::DocumentOrderedMap::remove): Ditto.
2610 (WebCore::DocumentOrderedMap::get): Ditto.
2611 (WebCore::DocumentOrderedMap::getAllElementsById): Added.
2613 * dom/DocumentOrderedMap.h:
2615 (WebCore::DocumentOrderedMap::MapEntry::MapEntry): Added.
2616 (WebCore::DocumentOrderedMap::containsSingle): Updated to use new hash map.
2617 (WebCore::DocumentOrderedMap::contains): Ditto.
2618 (WebCore::DocumentOrderedMap::containsMultiple): Ditto.
2621 (WebCore::Element::insertedInto): This function didn't add this element to window and document's name maps
2622 if the element had already been inserted into a tree scope, and the current call was inserting an ancestor
2623 of the tree scope into the document. We were exiting early per scope != treeScope().
2625 Fixed the bug by splitting updateId into two functions updateIdForTreeScope and updateIdForDocument.
2626 The former is called when this element is inserted into a new tree scope, and the latter is called when
2627 this element is inserted into a HTML document even if it had already been inside some tree scope.
2629 (WebCore::Element::removedFrom): This function didn't remove this element from tree scope's id maps if
2630 the tree scope wasn't a document. Fixed the bug by simply checking that the removal happens beneath the
2632 (WebCore::Element::updateName):
2633 (WebCore::Element::updateNameForTreeScope): Renamed from updateName.
2634 (WebCore::Element::updateNameForDocument): Extracted from updateName.
2635 (WebCore::Element::updateId):
2636 (WebCore::Element::updateIdForTreeScope): Renamed from updateId.
2637 (WebCore::Element::updateIdForDocument): Extracted from updateId.
2641 * dom/SelectorQuery.cpp:
2642 (WebCore::SelectorDataList::canUseIdLookup): Refactored to return the id subselector instead of checking if
2643 the first subselector happens to be matching an id.
2644 (WebCore::SelectorDataList::execute): Use the subselector canUseIdLookup returned. Also make use of newly
2645 added getAllElementsById when there are multiple matching elements for a given id.
2647 * dom/SelectorQuery.h:
2649 * dom/TreeScope.cpp:
2650 (WebCore::TreeScope::getAllElementsById): Added.
2654 2013-05-15 Darin Adler <darin@apple.com>
2656 [Mac] Make Clipboard::create functions for Mac platform independent by moving Pasteboard creation to Pasteboard functions
2657 https://bugs.webkit.org/show_bug.cgi?id=116179
2659 Reviewed by Andreas Kling.
2661 * dom/Clipboard.cpp:
2662 (WebCore::Clipboard::createForCopyAndPaste): Moved the function here from
2663 ClipboardMac, and have it use Pasteboard functions that are not Mac-specific.
2664 (WebCore::Clipboard::create): Ditto.
2665 (WebCore::Clipboard::createForDragAndDrop): Ditto.
2667 * platform/DragData.h:
2668 (WebCore::DragData::pasteboardName): Made this const.
2670 * platform/Pasteboard.h: Added new create functions, used by the clipboard
2671 create functions above.
2673 * platform/mac/ClipboardMac.mm: Removed the functions that were moved to the
2676 * platform/mac/PasteboardMac.mm:
2677 (WebCore::Pasteboard::createForCopyAndPaste): Added.
2678 (WebCore::Pasteboard::createPrivate): Added.
2679 (WebCore::Pasteboard::createForDragAndDrop): Added.
2681 2013-05-15 Anders Carlsson <andersca@apple.com>
2685 We want to invalidate the file icon loader if it exists, not create it!
2687 * html/FileInputType.cpp:
2688 (WebCore::FileInputType::requestIcon):
2690 2013-05-15 Darin Adler <darin@apple.com>
2692 Move drag-specific Clipboard functions inside ENABLE(DRAG_SUPPORT)
2693 https://bugs.webkit.org/show_bug.cgi?id=116176
2695 Reviewed by Andreas Kling.
2697 * dom/Clipboard.cpp:
2698 (WebCore::Clipboard::writeRange):
2699 (WebCore::Clipboard::writePlainText):
2700 (WebCore::Clipboard::writeURL):
2701 Move these three functions inside ENABLE(DRAG_SUPPORT). Even though their names do
2702 not make it obvious, these are here only for use by dragging code. Later we may
2703 refactor them away entirely, but for now it's good not to compile them in on any
2704 platform that does not support dragging.
2706 2013-05-15 Andy Estes <aestes@apple.com>
2708 Resources from non-HTTP schemes should not be cached indefinitely
2709 https://bugs.webkit.org/show_bug.cgi?id=113626
2711 Reviewed by Ryosuke Niwa.
2713 With the exception of schemes that we know will always return the same
2714 result for a given URL, we should not indefinitely cache non-HTTP
2715 resources when their freshness cannot be verified.
2717 Writing a test for this is blocked on https://webkit.org/b/116199.
2719 The following two existing tests of memory cache behavior were
2720 converted to HTTP tests so that they continue to function as expected:
2722 Tests: http/tests/cache/display-image-unset-allows-cached-image-load.html
2723 http/tests/cache/willsendrequest-returns-null-for-memory-cache-load.html
2725 * loader/cache/CachedResource.cpp:
2726 (WebCore::CachedResource::freshnessLifetime): Returned a freshness
2727 lifetime of 0 for non-HTTP schemes that can't be indefinitely cached.
2728 * platform/SchemeRegistry.cpp:
2729 (WebCore::SchemeRegistry::shouldCacheResponsesFromURLSchemeIndefinitely):
2730 Checked whether the scheme is blob:, data:, or applewebdata:.
2731 * platform/SchemeRegistry.h:
2733 2013-05-15 Tim Horton <timothy_horton@apple.com>
2735 makeRGBAFromNSColor throws an exception if given a color in a greyscale colorspace
2736 https://bugs.webkit.org/show_bug.cgi?id=116198
2737 <rdar://problem/13904395>
2739 Reviewed by Simon Fraser.
2741 Block Objective-C exceptions in makeRGBAFromNSColor.
2742 Remove a comment saying that they're impossible.
2744 Convert the incoming color to the DeviceRGB colorspace to match
2745 existing color sources. Some rare cases (attributed strings that come
2746 from PDFKit) can have DeviceGrayscale color spaces, which would
2747 previously throw an exception here.
2749 * platform/graphics/mac/ColorMac.mm:
2750 (WebCore::makeRGBAFromNSColor):
2752 2013-05-15 David Kilzer <ddkilzer@apple.com>
2754 BUILD FIX (r150140): Frame::editor() should return a reference for iOS, too
2756 * platform/ios/ClipboardIOS.mm:
2757 (WebCore::ClipboardIOS::ClipboardIOS):
2758 (WebCore::ClipboardIOS::hasData):
2759 (WebCore::ClipboardIOS::clearData):
2760 (WebCore::ClipboardIOS::clearAllData):
2761 (WebCore::ClipboardIOS::getData):
2762 (WebCore::ClipboardIOS::setData):
2763 (WebCore::ClipboardIOS::types):
2764 (WebCore::ClipboardIOS::writeRange):
2765 * platform/ios/PasteboardIOS.mm:
2766 (WebCore::Pasteboard::getStringSelection):
2767 (WebCore::Pasteboard::writeSelection):
2768 (WebCore::Pasteboard::writePlainText):
2769 (WebCore::Pasteboard::writeImage):
2770 (WebCore::Pasteboard::plainText):
2771 (WebCore::documentFragmentWithRTF):
2772 (WebCore::Pasteboard::documentFragmentForPasteboardItemAtIndex):
2773 (WebCore::Pasteboard::documentFragment):
2775 2013-05-15 Anders Carlsson <andersca@apple.com>
2777 Stop using the factory pattern in FileIconLoaderClient
2778 https://bugs.webkit.org/show_bug.cgi?id=116197
2780 Reviewed by Andreas Kling.
2782 Move the FileIconLoader member out of FileIconLoaderClient and into FileInputType and remove the factory gunk.
2784 * html/FileInputType.cpp:
2785 (WebCore::FileInputType::~FileInputType):
2786 (WebCore::FileInputType::requestIcon):
2787 * html/FileInputType.h:
2789 * platform/FileIconLoader.cpp:
2790 (WebCore::FileIconLoader::invalidate):
2791 * platform/FileIconLoader.h:
2792 (WebCore::FileIconLoaderClient::~FileIconLoaderClient):
2795 2013-05-15 Anders Carlsson <andersca@apple.com>
2797 Fix FileChooserClient design
2798 https://bugs.webkit.org/show_bug.cgi?id=116195
2800 Reviewed by Andreas Kling.
2802 FileChooserClient doesn't match the standard WebCore client idiom of only having virtual member functions.
2803 Instead it holds on to its FileChooser and it's even a factory for creating new file choosers(!).
2805 Fix this by making it an abstract class, and moving FileChooser into FileInputType.
2807 * html/FileInputType.cpp:
2808 (WebCore::FileInputType::~FileInputType):
2809 Invalidate the file chooser.
2811 (WebCore::FileInputType::handleDOMActivateEvent):
2812 Apply the file chooser settings.
2814 (WebCore::FileInputType::applyFileChooserSettings):
2815 Recreate the file chooser with new settings.
2817 (WebCore::FileInputType::receiveDropForDirectoryUpload):
2820 * platform/FileChooser.cpp:
2821 (WebCore::FileChooser::invalidate):
2822 Set m_client to null.
2824 (WebCore::FileChooser::chooseFiles):
2827 * platform/FileChooser.h:
2829 2013-05-15 Gavin Barraclough <barraclough@apple.com>
2831 ScriptedAnimationController::setThrottled should extend MinimumAnimationInterval
2832 https://bugs.webkit.org/show_bug.cgi?id=116193
2834 Reviewed by Darin Adler
2836 * dom/ScriptedAnimationController.cpp:
2837 (WebCore::ScriptedAnimationController::ScriptedAnimationController):
2838 (WebCore::ScriptedAnimationController::setThrottled):
2839 (WebCore::ScriptedAnimationController::scheduleAnimation):
2840 * dom/ScriptedAnimationController.h:
2841 (ScriptedAnimationController):
2842 - Fixes for review comments.
2844 2013-05-15 Anders Carlsson <andersca@apple.com>
2846 Move HTTPRequest class to WebKit2
2847 https://bugs.webkit.org/show_bug.cgi?id=116192
2849 Reviewed by Darin Adler.
2851 HTTPRequest is only used by the "remote inspector" feature in WebKit2,
2852 so there's no need to have it in WebCore.
2855 * GNUmakefile.list.am:
2857 * WebCore.vcproj/WebCore.vcproj:
2858 * WebCore.vcxproj/WebCore.vcxproj:
2859 * WebCore.vcxproj/WebCore.vcxproj.filters:
2860 * WebCore.xcodeproj/project.pbxproj:
2862 2013-05-15 Oliver Hunt <oliver@apple.com>
2864 RefCountedArray needs to use vector initialisers for its backing store
2865 https://bugs.webkit.org/show_bug.cgi?id=116194
2867 Reviewed by Gavin Barraclough.
2869 Update to use new functions for operating on the exception stack.
2871 * bindings/js/ScriptCallStackFactory.cpp:
2872 (WebCore::createScriptCallStackFromException):
2874 2013-05-15 Gavin Barraclough <barraclough@apple.com>
2876 ScriptedAnimationController::setThrottled should extend MinimumAnimationInterval
2877 https://bugs.webkit.org/show_bug.cgi?id=116193
2879 Reviewed by Simon Fraser.
2881 * dom/ScriptedAnimationController.cpp:
2882 (WebCore::ScriptedAnimationController::ScriptedAnimationController):
2883 - initialize m_throttled
2884 (WebCore::ScriptedAnimationController::setThrottled):
2885 - sets m_throttled, reschedule when this changes.
2886 (WebCore::ScriptedAnimationController::scheduleAnimation):
2887 - if throtled don't use a display link, and extend the timeout.
2888 * dom/ScriptedAnimationController.h:
2889 (ScriptedAnimationController):
2892 2013-05-08 Gavin Barraclough <barraclough@apple.com>
2894 Process suppression should throttle scripted animations
2895 https://bugs.webkit.org/show_bug.cgi?id=115812
2897 Reviewed by Simon Fraser.
2899 <rdar://problem/13799726>
2902 - Expose Page::setThrottled
2904 (WebCore::Document::scriptedAnimationControllerSetThrottled):
2908 - Forwards to ScriptedAnimationController::setThrottled
2909 * dom/ScriptedAnimationController.cpp:
2910 (WebCore::ScriptedAnimationController::setThrottled):
2912 * dom/ScriptedAnimationController.h:
2913 - Force use of a timer.
2914 (ScriptedAnimationController):
2916 (WebCore::Page::setThrottled):
2920 - When under throttling force the ScriptedAnimationController to use a timer.
2922 2013-05-15 Igor Oliveira <igor.o@sisa.samsung.com>
2924 Implement run-in remove child cases.
2925 https://bugs.webkit.org/show_bug.cgi?id=86520
2927 Move runin to original position when sibling element is destroyed.
2929 Reviewed by David Hyatt.
2931 Tests: fast/runin/runin-remove-child-simple.html
2932 fast/runin/runin-sibling-inline.html
2934 * rendering/RenderBlock.cpp:
2935 (WebCore::RenderBlock::willBeDestroyed):
2936 (WebCore::RenderBlock::moveRunInUnderSiblingBlockIfNeeded):
2937 If moveRunInUnderSiblingBlockIfNeeded is called when the sibling run-in block
2938 is being destroyed, it means that the run-in is moving to original position and
2939 we do not need to do nothing.
2941 2013-05-15 Anders Carlsson <andersca@apple.com>
2943 Remove WebSocketHandshakeResponse class
2944 https://bugs.webkit.org/show_bug.cgi?id=116190
2946 Reviewed by Andreas Kling.
2948 Just use ResourceResponse instead of WebSocketHandshakeResponse.
2951 * GNUmakefile.list.am:
2952 * Modules/websockets/WebSocketHandshake.cpp:
2953 (WebCore::WebSocketHandshake::readServerHandshake):
2954 (WebCore::WebSocketHandshake::serverWebSocketProtocol):
2955 (WebCore::WebSocketHandshake::serverSetCookie):
2956 (WebCore::WebSocketHandshake::serverSetCookie2):
2957 (WebCore::WebSocketHandshake::serverUpgrade):
2958 (WebCore::WebSocketHandshake::serverConnection):
2959 (WebCore::WebSocketHandshake::serverWebSocketAccept):
2960 (WebCore::WebSocketHandshake::serverHandshakeResponse):
2961 (WebCore::WebSocketHandshake::readHTTPHeaders):
2962 * Modules/websockets/WebSocketHandshake.h:
2963 * Modules/websockets/WebSocketHandshakeResponse.cpp: Removed.
2964 * Modules/websockets/WebSocketHandshakeResponse.h: Removed.
2966 * WebCore.vcproj/WebCore.vcproj:
2967 * WebCore.vcxproj/WebCore.vcxproj:
2968 * WebCore.vcxproj/WebCore.vcxproj.filters:
2969 * WebCore.xcodeproj/project.pbxproj:
2970 * inspector/InspectorInstrumentation.cpp:
2972 (WebCore::InspectorInstrumentation::didReceiveWebSocketHandshakeResponseImpl):
2973 * inspector/InspectorInstrumentation.h:
2974 (InspectorInstrumentation):
2975 (WebCore::InspectorInstrumentation::didReceiveWebSocketHandshakeResponse):
2976 * inspector/InspectorResourceAgent.cpp:
2977 (WebCore::InspectorResourceAgent::didReceiveWebSocketHandshakeResponse):
2978 * inspector/InspectorResourceAgent.h:
2980 (InspectorResourceAgent):
2982 2013-05-15 Eric Carlson <eric.carlson@apple.com>
2984 [Mac] media engine may deliver NULL in-band "cue"
2985 https://bugs.webkit.org/show_bug.cgi?id=116180
2987 Reviewed by Jer Noble.
2989 * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
2990 (WebCore::InbandTextTrackPrivateAVF::processCue): NULL check before logging cue count.
2992 2013-05-15 Darin Adler <darin@apple.com>
2994 List platforms that still use the legacy clipboard instead of just saying "not Mac"
2995 https://bugs.webkit.org/show_bug.cgi?id=116177
2997 Reviewed by Andreas Kling.
2999 * dom/Clipboard.h: Replaced the "!MAC || IOS" with a list of platforms still on the
3002 2013-05-15 Yongjun Zhang <yongjun_zhang@apple.com>
3004 We should clear mainResource in DocumentLoader::cancelMainResourceLoad.
3005 https://bugs.webkit.org/show_bug.cgi?id=116119
3007 Reviewed by Oliver Hunt.
3009 MainResourceLoader::clearResource() was left out in r146239 when moving MainResourceLoader::cancel()
3010 to DocumentLoader::cancelMainResourceLoad(), we need to add it back to make sure m_mainResource is
3011 cleared when we cancel the loader.
3013 No new tests needed.
3015 * loader/DocumentLoader.cpp:
3016 (WebCore::DocumentLoader::~DocumentLoader):
3017 (WebCore::DocumentLoader::continueAfterNavigationPolicy):
3018 (WebCore::DocumentLoader::cancelMainResourceLoad):
3019 (WebCore::DocumentLoader::clearMainResource):
3021 * loader/DocumentLoader.h: add helper method clearMainResource()
3024 2013-05-15 Joe Mason <jmason@blackberry.com>
3026 [BlackBerry] When HTTP auth fails, only purge credentials that match the failed credentials
3027 https://bugs.webkit.org/show_bug.cgi?id=116164
3029 Reviewed by Rob Buis.
3032 Internally Reviewed By: Lyon Chen
3034 When there are multiple HTTP requests in flight with the same bad credentials (common with
3035 proxy auth if the user mistyped their password), the first 407 that's received will cause
3036 the credentials to be purged and the password dialog to open for new credentials. This means
3037 that all 407's received after this should only purge the credentials if they have not
3038 already been updated from the dialog; otherwise they will be wiping out credentials that
3041 * platform/network/blackberry/NetworkJob.cpp:
3042 (WebCore::NetworkJob::sendRequestWithCredentials):
3043 (WebCore::NetworkJob::purgeCredentials):
3045 2013-05-15 Chris Fleizach <cfleizach@apple.com>
3047 AX: Use caching when requesting children object on iOS
3048 https://bugs.webkit.org/show_bug.cgi?id=116112
3050 Reviewed by David Kilzer.
3052 Building up the children list in the AX hierarchy can be time consuming. On iOS, this
3053 is now much more noticeable (I believe due to the way tables calculate their AX ignored flag).
3055 We can speed everything up if we just cache the isIgnored() attribute while building up children.
3057 * accessibility/AXObjectCache.cpp:
3058 (WebCore::AXAttributeCacheEnabler::AXAttributeCacheEnabler):
3060 (WebCore::AXAttributeCacheEnabler::~AXAttributeCacheEnabler):
3061 * accessibility/AXObjectCache.h:
3062 (AXAttributeCacheEnabler):
3064 * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
3065 (-[WebAccessibilityObjectWrapper accessibilityHitTest:]):
3066 (-[WebAccessibilityObjectWrapper accessibilityElementCount]):
3067 (-[WebAccessibilityObjectWrapper accessibilityElementAtIndex:]):
3068 (-[WebAccessibilityObjectWrapper indexOfAccessibilityElement:]):
3069 (-[WebAccessibilityObjectWrapper accessibilityContainer]):
3071 2013-05-15 Anders Carlsson <andersca@apple.com>
3073 Remove WebSocketHandshakeRequest class
3074 https://bugs.webkit.org/show_bug.cgi?id=116178
3076 Reviewed by Andreas Kling.
3078 Turns out WebSocketHandshakeRequest is just used by the web inspector, and there's no reason
3079 why we can't just use a ResourceRequest instead.
3082 * GNUmakefile.list.am:
3083 * Modules/websockets/WebSocketChannel.cpp:
3084 (WebCore::WebSocketChannel::didOpenSocketStream):
3085 * Modules/websockets/WebSocketHandshake.cpp:
3086 (WebCore::WebSocketHandshake::clientHandshakeRequest):
3087 * Modules/websockets/WebSocketHandshake.h:
3089 * Modules/websockets/WebSocketHandshakeRequest.cpp: Removed.
3090 * Modules/websockets/WebSocketHandshakeRequest.h: Removed.
3092 * WebCore.vcproj/WebCore.vcproj:
3093 * WebCore.vcxproj/WebCore.vcxproj:
3094 * WebCore.vcxproj/WebCore.vcxproj.filters:
3095 * WebCore.xcodeproj/project.pbxproj:
3096 * inspector/InspectorInstrumentation.cpp:
3098 (WebCore::InspectorInstrumentation::willSendWebSocketHandshakeRequestImpl):
3099 * inspector/InspectorInstrumentation.h:
3100 (InspectorInstrumentation):
3101 (WebCore::InspectorInstrumentation::willSendWebSocketHandshakeRequest):
3102 * inspector/InspectorResourceAgent.cpp:
3103 (WebCore::InspectorResourceAgent::willSendWebSocketHandshakeRequest):
3104 * inspector/InspectorResourceAgent.h:
3106 (InspectorResourceAgent):
3107 * platform/network/HTTPRequest.cpp:
3110 2013-05-15 Darin Adler <darin@apple.com>
3112 Try to fix iOS build.
3114 * platform/Pasteboard.h: Fix #if so that we don't try to compile pasteboard name code
3117 2013-05-13 Anders Carlsson <andersca@apple.com>
3119 Frame::editor() should return a reference
3120 https://bugs.webkit.org/show_bug.cgi?id=116037
3122 Reviewed by Darin Adler.
3124 A frame's editor can never be null. Change Frame::editor() to return a reference to reflect this.
3125 Also, make Frame::m_editor a const member variable so nobody will accidentally set it to null.
3127 * accessibility/AccessibilityObject.cpp:
3128 (WebCore::AccessibilityObject::hasMisspelling):
3129 * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
3130 (AXAttributeStringSetSpelling):
3131 * dom/ContainerNode.cpp:
3132 (WebCore::ContainerNode::cloneChildNodes):
3134 (WebCore::acceptsEditingFocus):
3135 (WebCore::Document::setFocusedNode):
3137 * editing/AlternativeTextController.cpp:
3138 (WebCore::AlternativeTextController::timerFired):
3139 (WebCore::AlternativeTextController::applyDictationAlternative):
3140 * editing/CompositeEditCommand.cpp:
3141 (WebCore::EditCommandComposition::unapply):
3142 (WebCore::EditCommandComposition::reapply):
3143 (WebCore::CompositeEditCommand::apply):
3144 (WebCore::CompositeEditCommand::moveParagraphs):
3145 * editing/DeleteButton.cpp:
3146 (WebCore::DeleteButton::defaultEventHandler):
3147 * editing/DeleteButtonController.cpp:
3148 (WebCore::DeleteButtonController::show):
3149 * editing/DeleteButtonController.h:
3150 (WebCore::DeleteButtonControllerDisableScope::DeleteButtonControllerDisableScope):
3151 (WebCore::DeleteButtonControllerDisableScope::~DeleteButtonControllerDisableScope):
3152 * editing/DeleteSelectionCommand.cpp:
3153 (WebCore::DeleteSelectionCommand::mergeParagraphs):
3154 (WebCore::DeleteSelectionCommand::doApply):
3155 * editing/EditCommand.cpp:
3156 (WebCore::EditCommand::EditCommand):
3157 * editing/EditingStyle.cpp:
3158 (WebCore::StyleChange::StyleChange):
3159 * editing/Editor.cpp:
3160 (WebCore::Editor::markMisspellingsAfterTypingToWord):
3161 * editing/EditorCommand.cpp:
3162 (WebCore::applyCommandToFrame):
3163 (WebCore::executeToggleStyle):
3164 (WebCore::executeApplyParagraphStyle):
3165 (WebCore::expandSelectionToGranularity):
3166 (WebCore::stateStyle):
3167 (WebCore::valueStyle):
3168 (WebCore::executeCopy):
3169 (WebCore::executeCut):
3170 (WebCore::executeDefaultParagraphSeparator):
3171 (WebCore::executeDelete):
3172 (WebCore::executeDeleteBackward):
3173 (WebCore::executeDeleteBackwardByDecomposingPreviousCharacter):
3174 (WebCore::executeDeleteForward):
3175 (WebCore::executeDeleteToBeginningOfLine):
3176 (WebCore::executeDeleteToBeginningOfParagraph):
3177 (WebCore::executeDeleteToEndOfLine):
3178 (WebCore::executeDeleteToEndOfParagraph):
3179 (WebCore::executeDeleteToMark):
3180 (WebCore::executeDeleteWordBackward):
3181 (WebCore::executeDeleteWordForward):
3182 (WebCore::executeFindString):
3183 (WebCore::executeForwardDelete):
3184 (WebCore::executeIgnoreSpelling):
3185 (WebCore::executeInsertNewline):
3186 (WebCore::executeMakeTextWritingDirectionLeftToRight):
3187 (WebCore::executeMakeTextWritingDirectionNatural):
3188 (WebCore::executeMakeTextWritingDirectionRightToLeft):
3189 (WebCore::executeToggleOverwrite):
3190 (WebCore::executePaste):
3191 (WebCore::executePasteGlobalSelection):
3192 (WebCore::executePasteAndMatchStyle):
3193 (WebCore::executePasteAsPlainText):
3194 (WebCore::executeRedo):
3195 (WebCore::executeRemoveFormat):
3196 (WebCore::executeSelectToMark):
3197 (WebCore::executeSetMark):
3198 (WebCore::executeStyleWithCSS):
3199 (WebCore::executeUseCSS):
3200 (WebCore::executeSwapWithMark):
3201 (WebCore::executeTakeFindStringFromSelection):
3202 (WebCore::executeTranspose):
3203 (WebCore::executeUndo):
3204 (WebCore::executeYank):
3205 (WebCore::executeYankAndSelect):
3206 (WebCore::supportedCopyCut):
3207 (WebCore::supportedPaste):
3208 (WebCore::enabledVisibleSelection):
3209 (WebCore::enabledVisibleSelectionAndMark):
3210 (WebCore::enableCaretInEditableText):
3211 (WebCore::enabledCopy):
3212 (WebCore::enabledCut):
3213 (WebCore::enabledInEditableText):
3214 (WebCore::enabledDelete):
3215 (WebCore::enabledPaste):
3216 (WebCore::enabledRedo):
3217 (WebCore::enabledTakeFindStringFromSelection):
3218 (WebCore::enabledUndo):
3219 (WebCore::stateOrderedList):
3220 (WebCore::stateStyleWithCSS):
3221 (WebCore::stateUnorderedList):
3222 (WebCore::valueDefaultParagraphSeparator):
3223 * editing/FrameSelection.cpp:
3224 (WebCore::shouldAlwaysUseDirectionalSelection):
3225 (WebCore::FrameSelection::setSelection):
3226 (WebCore::FrameSelection::nextWordPositionForPlatform):
3227 (WebCore::FrameSelection::modifyMovingRight):
3228 (WebCore::FrameSelection::modifyMovingLeft):
3229 (WebCore::FrameSelection::modify):
3230 (WebCore::shouldStopBlinkingDueToTypingCommand):
3231 (WebCore::FrameSelection::shouldDeleteSelection):
3232 (WebCore::FrameSelection::shouldChangeSelection):
3233 * editing/InsertTextCommand.cpp:
3234 (WebCore::InsertTextCommand::doApply):
3235 * editing/SpellChecker.cpp:
3236 (WebCore::SpellChecker::didCheck):
3237 * editing/SpellingCorrectionCommand.cpp:
3238 * editing/TypingCommand.cpp:
3239 (WebCore::TypingCommand::insertText):
3240 (WebCore::TypingCommand::lastTypingCommandIfStillOpenForTyping):
3241 (WebCore::TypingCommand::markMisspellingsAfterTyping):
3242 (WebCore::TypingCommand::typingAddedToOpenCommand):
3243 (WebCore::TypingCommand::deleteKeyPressed):
3244 (WebCore::TypingCommand::forwardDeleteKeyPressed):
3245 * editing/htmlediting.cpp:
3246 (WebCore::createDefaultParagraphElement):
3247 * editing/mac/EditorMac.mm:
3248 (WebCore::Editor::pasteWithPasteboard):
3249 * editing/markup.cpp:
3250 (WebCore::createMarkup):
3251 * html/HTMLInputElement.cpp:
3252 (WebCore::HTMLInputElement::endEditing):
3253 * html/HTMLTextAreaElement.cpp:
3254 (WebCore::HTMLTextAreaElement::subtreeHasChanged):
3255 * html/TextFieldInputType.cpp:
3256 (WebCore::TextFieldInputType::handleKeydownEvent):
3257 (WebCore::TextFieldInputType::didSetValueByUserEdit):
3258 * loader/FrameLoader.cpp:
3259 (WebCore::FrameLoader::closeURL):
3260 (WebCore::FrameLoader::didOpenURL):
3261 (WebCore::FrameLoader::clear):
3262 * page/ContextMenuController.cpp:
3263 (WebCore::insertUnicodeCharacter):
3264 (WebCore::ContextMenuController::contextMenuItemSelected):
3265 (WebCore::ContextMenuController::populate):
3266 (WebCore::ContextMenuController::checkOrEnableIfNeeded):
3267 * page/DOMWindow.cpp:
3268 (WebCore::DOMWindow::find):
3269 * page/DragController.cpp:
3270 (WebCore::DragController::dispatchTextInputEventFor):
3271 (WebCore::DragController::concludeEditDrag):
3272 (WebCore::DragController::startDrag):
3273 * page/EventHandler.cpp:
3274 (WebCore::EventHandler::selectClosestWordFromMouseEvent):
3275 (WebCore::EventHandler::handleMousePressEventSingleClick):
3276 (WebCore::EventHandler::handlePasteGlobalSelection):
3277 (WebCore::EventHandler::sendContextMenuEvent):
3278 (WebCore::EventHandler::sendContextMenuEventForKey):
3279 (WebCore::EventHandler::keyEvent):
3280 (WebCore::EventHandler::defaultKeyboardEventHandler):
3281 (WebCore::EventHandler::defaultTextInputEventHandler):
3282 (WebCore::EventHandler::defaultBackspaceEventHandler):
3283 * page/FocusController.cpp:
3284 (WebCore::relinquishesEditingFocus):
3286 (WebCore::Frame::rangeForPoint):
3289 (WebCore::Frame::editor):
3291 (WebCore::Page::findString):
3292 (WebCore::Page::findStringMatchingRanges):
3293 (WebCore::Page::rangeOfString):
3294 (WebCore::Page::markAllMatchesForText):
3295 (WebCore::Page::setDeviceScaleFactor):
3296 * platform/mac/ClipboardMac.mm:
3297 (WebCore::ClipboardMac::writeRange):
3298 * platform/mac/DragDataMac.mm:
3299 (WebCore::DragData::asURL):
3300 * platform/mac/PasteboardMac.mm:
3301 (WebCore::Pasteboard::getStringSelection):
3302 (WebCore::Pasteboard::getDataSelection):
3303 (WebCore::Pasteboard::writeSelectionForTypes):
3304 (WebCore::writeURLForTypes):
3305 (WebCore::Pasteboard::plainText):
3306 (WebCore::documentFragmentWithRTF):
3307 (WebCore::Pasteboard::documentFragment):
3308 * rendering/HitTestResult.cpp:
3309 (WebCore::HitTestResult::dictationAlternatives):
3310 * rendering/InlineTextBox.cpp:
3311 (WebCore::InlineTextBox::paint):
3312 (WebCore::InlineTextBox::paintTextMatchMarker):
3313 * rendering/RenderBlock.cpp:
3314 (WebCore::RenderBlock::positionForPointWithInlineChildren):
3315 * testing/Internals.cpp:
3316 (WebCore::spellchecker):
3317 (WebCore::Internals::resetToConsistentState):
3318 (WebCore::Internals::hasSpellingMarker):
3319 (WebCore::Internals::hasAutocorrectedMarker):
3320 (WebCore::Internals::setContinuousSpellCheckingEnabled):
3321 (WebCore::Internals::setAutomaticQuoteSubstitutionEnabled):
3322 (WebCore::Internals::setAutomaticLinkDetectionEnabled):
3323 (WebCore::Internals::setAutomaticDashSubstitutionEnabled):
3324 (WebCore::Internals::setAutomaticTextReplacementEnabled):
3325 (WebCore::Internals::setAutomaticSpellingCorrectionEnabled):
3326 (WebCore::Internals::isOverwriteModeEnabled):
3327 (WebCore::Internals::toggleOverwriteModeEnabled):
3328 (WebCore::Internals::hasGrammarMarker):
3330 2013-05-15 Darin Adler <darin@apple.com>
3332 [Mac] Make Clipboard class no longer polymorphic by removing the last virtual functions
3333 https://bugs.webkit.org/show_bug.cgi?id=116166
3335 Reviewed by Anders Carlsson.
3337 * WebCore.exp.in: Add ~Clipboard since it's no longer a virtual function, but to the
3338 non-iOS section, since iOS is still using the legacy version of Clipboard.
3340 * dom/Clipboard.h: Mark items non-virtual, too. It's not implemented on Mac yet.
3342 2013-05-15 Dongseong Hwang <dongseong.hwang@intel.com>
3344 Remove an overloaded strokeRect in <canvas>
3345 https://bugs.webkit.org/show_bug.cgi?id=116017
3347 Reviewed by Benjamin Poulain.
3349 The canvas spec [1] does not define strokeRect with 5 arguments, so this issue
3350 remains only strokeRect with 4 arguments.
3352 [1] http://www.w3.org/TR/2dcontext2/
3354 Covered by existing tests: canvas/philip/tests/2d.missingargs.html
3356 * html/canvas/CanvasRenderingContext2D.cpp:
3357 (WebCore::CanvasRenderingContext2D::strokeRect):
3358 * html/canvas/CanvasRenderingContext2D.h:
3359 (CanvasRenderingContext2D):
3360 * html/canvas/CanvasRenderingContext2D.idl:
3362 2013-05-15 Bruno de Oliveira Abinader <bruno.abinader@basyskom.com>
3364 [css3-text] text-decoration-line now accepts "blink" as valid value
3365 https://bugs.webkit.org/show_bug.cgi?id=116104
3367 Reviewed by Andreas Kling.
3369 As of November 13th 2012, the W3C specification has been updated to
3370 accept "blink" as a valid property value in text-decoration-line. Though
3371 accepting the value as valid, it is ignored as CSS Level 1
3372 text-decoration property currently does.
3374 Updated related layout tests to reflect changes in specification.
3376 * css/CSSParser.cpp:
3377 (WebCore::CSSParser::parseValue):
3378 (WebCore::CSSParser::parseTextDecoration):
3380 2013-05-14 Simon Fraser <simon.fraser@apple.com>
3382 Revert http://trac.webkit.org/changeset/150047
3384 It introduced unwanted behavioral differences between
3385 Retina and non-Retina Mac hardware.
3387 * platform/graphics/ca/GraphicsLayerCA.cpp:
3388 (WebCore::GraphicsLayerCA::requiresTiledLayer):
3389 (WebCore::GraphicsLayerCA::computePixelAlignment):
3391 2013-05-15 Darin Adler <darin@apple.com>
3393 [Mac] Remove the ClipboardMac class and header file
3394 https://bugs.webkit.org/show_bug.cgi?id=116165
3396 Reviewed by Anders Carlsson.
3398 * WebCore.xcodeproj/project.pbxproj: Remove ClipboardMac.h.
3399 * editing/mac/EditorMac.mm: Import Clipboard.h rather than ClipboardMac.h.
3400 * page/mac/EventHandlerMac.mm: Ditto.
3401 * platform/mac/ClipboardMac.h: Removed.
3403 * platform/mac/ClipboardMac.mm: Import Clipboard.h rather than ClipboardMac.h.
3404 Deleted ClipboardMac constructor.
3406 2013-05-15 Darin Adler <darin@apple.com>
3408 [Mac] Change Clipboard::create functions so they don't use ClipboardMac::create any more
3409 https://bugs.webkit.org/show_bug.cgi?id=116163
3411 Reviewed by Anders Carlsson.
3413 * dom/Clipboard.h: Made the file drag boolean default to false, better for most callers.
3415 * platform/mac/ClipboardMac.mm: Remove #if ENABLE(DRAG_SUPPORT); that's always on for Mac
3416 and it's not helpful to have the conditionals in here. It's helpful in cross-platform
3418 (WebCore::Clipboard::create): Create a Pasteboard and then create a Clipboard with new.
3419 Later could refactor to have the Pasteboard creation be platform-specific, and make these
3420 functions platform-independent.
3421 (WebCore::Clipboard::createForDragAndDrop): Ditto.
3422 (WebCore::Clipboard::createForCopyAndPaste): Ditto.
3424 2013-05-15 Darin Adler <darin@apple.com>
3426 [Mac] Remove call to ClipboardMac::create from Editor::newGeneralClipboard
3427 https://bugs.webkit.org/show_bug.cgi?id=116162
3429 Reviewed by Andreas Kling.
3431 * dom/Clipboard.h: Add createForCopyAndPaste function.
3433 * editing/mac/EditorMac.mm:
3434 (WebCore::Editor::newGeneralClipboard): Call createForCopyAndPaste.
3436 * platform/mac/ClipboardMac.mm:
3437 (WebCore::Clipboard::createForCopyAndPaste): Added. Moved code here from
3438 Editor::newGeneralClipboard.
3440 2013-05-15 Darin Adler <darin@apple.com>
3442 [Mac] Remove call to ClipboardMac::create from EventHandler::createDraggingClipboard
3443 https://bugs.webkit.org/show_bug.cgi?id=116161
3445 Reviewed by Andreas Kling.
3447 * dom/Clipboard.h: Added createForDragAndDrop function.
3449 * page/mac/EventHandlerMac.mm:
3450 (WebCore::EventHandler::createDraggingClipboard): Changed to use new Clipboard function
3451 instead of ClipboardMac::create.
3453 * platform/mac/ClipboardMac.mm:
3454 (WebCore::Clipboard::createForDragAndDrop): Added. For now it does exactly what the
3455 EventHandler::createDraggingClipboard function did, soon to be refactored better.
3457 2013-05-15 Darin Adler <darin@apple.com>
3459 [Mac] Thin out the ClipboardMac class and header file to prepare for deleting them
3460 https://bugs.webkit.org/show_bug.cgi?id=116159
3462 Reviewed by Andreas Kling.
3465 (WebCore::Clipboard::pasteboard): Added. For clients that have a DOM clipboard
3466 object and need to get to the Pasteboard platform abstraction.
3468 * editing/Editor.cpp:
3469 (WebCore::Editor::dispatchCPPEvent): Call writePasteboard instead of writeClipboard.
3470 Our long term plan is to delete writeClipboard.
3472 * platform/Pasteboard.h: Added writePasteboard function.
3473 (WebCore::Pasteboard::name): Made this const.
3475 * platform/mac/ClipboardMac.h: Deleted unneeded includes and forward declarations.
3476 Deleted all the data members and the virtual destructor.
3478 * platform/mac/ClipboardMac.mm: Deleted the many includes that are no longer needed.
3479 Deleted the destructor, since it's now automatically generated. Deleted the comment
3480 on an #endif since it's only a few source lines away from the #if.
3481 (WebCore::ClipboardMac::ClipboardMac): Deleted the code to set the data members,
3482 since they are no longer used.
3484 * platform/mac/PasteboardMac.mm: Changed include to Clipboard.h instead of ClipboardMac.h.
3485 (WebCore::Pasteboard::writePasteboard): Replaced writeClipboard with this.
3487 2013-05-15 Seokju Kwon <seokju.kwon@gmail.com>
3489 Web Inspector: Get rid of addNativeSnapshotChunk and HeapSnapshotChunk from Memory domain
3490 https://bugs.webkit.org/show_bug.cgi?id=116144
3492 Reviewed by Timothy Hatcher.
3494 No new tests, no behavior change.
3496 * inspector/Inspector.json:
3498 2013-05-15 Jocelyn Turcotte <jocelyn.turcotte@digia.com>
3500 [Qt] Fix a crash under ~PingLoader when the QNAM on the page has been destroyed.
3501 https://bugs.webkit.org/show_bug.cgi?id=116035
3503 Reviewed by Allan Sandfeld Jensen.
3505 The previous fix only moved the crash location from WebKit down to QNetworkReplyHttpImpl
3506 which expects its QNetworkAccessManager to still be alive.
3508 Fix it by watching the QNetworkReply's destroyed() signal and avoid the dangling pointer
3509 instead. The QNetworkReply doesn't need to be aborted in this case anyway.
3511 * platform/network/qt/QNetworkReplyHandler.cpp:
3512 (WebCore::QNetworkReplyWrapper::QNetworkReplyWrapper):
3513 (WebCore::QNetworkReplyWrapper::release):
3514 (WebCore::QNetworkReplyWrapper::stopForwarding):
3515 Rename resetConnections to stopForwarding since not all connections are related
3516 to data forwarding to the client anymore.
3517 (WebCore::QNetworkReplyWrapper::receiveMetaData):
3518 (WebCore::QNetworkReplyWrapper::replyDestroyed):
3519 (WebCore::QNetworkReplyWrapper::didReceiveFinished):
3520 * platform/network/qt/QNetworkReplyHandler.h:
3521 (QNetworkReplyWrapper):
3523 2013-05-15 Darin Adler <darin@apple.com>
3525 [Mac] Make Clipboard::declareAndWriteDragImage non-virtual
3526 https://bugs.webkit.org/show_bug.cgi?id=116156
3528 Reviewed by Anders Carlsson.
3530 * dom/Clipboard.h: Make declareAndWriteDragImage non-virtual for non-legacy.
3532 * platform/Pasteboard.h:
3533 (WebCore::Pasteboard::name): Added. Can be used in Mac platform code to do
3534 pasteboard operations directly instead of through the Pasteboard class
3535 functions. Not sure if we'll need it long term or not.
3537 * platform/mac/ClipboardMac.h: Removed declareAndWriteDragImage function.
3539 * platform/mac/ClipboardMac.mm:
3540 (WebCore::Clipboard::declareAndWriteDragImage): Made this function a Clipboard
3541 member instead of ClipboardMac.
3543 2013-05-15 Peter Gal <galpeter@inf.u-szeged.hu>
3545 [curl] Remove version #if guards
3546 https://bugs.webkit.org/show_bug.cgi?id=116152
3548 Reviewed by Brent Fulgham.
3552 * platform/network/curl/ResourceHandleCurl.cpp:
3553 (WebCore::ResourceHandle::platformSetDefersLoading): Removed version guard.
3554 * platform/network/curl/ResourceHandleManager.cpp:
3555 (WebCore::writeCallback): Ditto.
3556 (WebCore::headerCallback): Ditto.
3557 (WebCore::readCallback): Ditto.
3558 (WebCore::ResourceHandleManager::dispatchSynchronousJob): Ditto.
3559 (WebCore::ResourceHandleManager::initializeHandle): Ditto.
3561 2013-05-15 David Kilzer <ddkilzer@apple.com>
3563 BUILD FIX (r150089): Make WebCoreTestShim build for iOS
3565 * Configurations/WebCoreTestShim.xcconfig: Exclude
3566 WebCoreTestShimLibrary.cpp when building for iOS.
3568 2013-05-15 Radu Stavila <stavila@adobe.com>
3570 [CSSRegions] Implement offsetParent for elements inside named flow
3571 https://bugs.webkit.org/show_bug.cgi?id=113276
3573 In the offsetParent algorithm, the nearest ancestor search skips from the topmost named flow elements directly to the body element.
3574 http://dev.w3.org/csswg/css-regions/#cssomview-offset-attributes
3576 As a result of this change, the DumpRenderTree tool would crash in
3577 WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent when running the selecting-text-through-different-region-flows.html
3578 test. The RenderObjects inside a flow are attached to the RenderFlowThread. However, the RenderFlowThread is attached to the
3579 RenderView directly, meaning that we are going to bypass the <body>'s RenderObject while iterating the parents.
3581 Reviewed by Darin Adler.
3583 Tests: fast/regions/offsetParent-body-in-flow-thread.html
3584 fast/regions/offsetParent-in-flow-thread.html
3586 * rendering/RenderBoxModelObject.cpp:
3587 (WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
3588 * rendering/RenderObject.cpp:
3589 (WebCore::RenderObject::offsetParent):
3591 2013-05-15 Darin Adler <darin@apple.com>
3593 [Mac] Make Clipboard::createDragImage non-virtual
3594 https://bugs.webkit.org/show_bug.cgi?id=116136
3596 Reviewed by Benjamin Poulain.
3598 * dom/Clipboard.h: Made createDragImage non-virtual for non-legacy.
3600 * platform/mac/ClipboardMac.h: Removed frame argument from create function
3601 and constructor. Removed createDragImage and dragNSImage. Removed m_frame
3604 * platform/mac/ClipboardMac.mm:
3605 (WebCore::ClipboardMac::ClipboardMac): Removed frame argument and code
3606 to initialize m_frame.
3607 (WebCore::Clipboard::createDragImage): Merged the createDragImage and
3608 dragNSImage functions, since they were the same thing. Changed code to get
3609 the frame from the drag image element. Made the createDragImage function
3610 a Clipboard member instead of ClipboardMac.
3612 2013-05-15 Patrick Gansterer <paroga@webkit.org>
3614 [WINCE] Fix calls to GlyphPage::setGlyphDataForIndex()
3615 https://bugs.webkit.org/show_bug.cgi?id=116137
3617 Reviewed by Andreas Kling.
3619 Use zero for the glyp when the fontData pointer is null.
3620 This aligns GlyphPageTreeNodeWinCE with the other implementations
3621 and makes all ASSERT() pass in setGlyphDataForIndex().
3623 * platform/graphics/wince/GlyphPageTreeNodeWinCE.cpp:
3624 (WebCore::GlyphPage::fill):
3626 2013-05-15 Benjamin Poulain <bpoulain@apple.com>
3628 Do not bloat HTMLTokenizer with a giant inline InputStreamPreprocessor::peek
3629 https://bugs.webkit.org/show_bug.cgi?id=116066
3631 Reviewed by Ryosuke Niwa.
3633 Merge https://chromium.googlesource.com/chromium/blink/+/45e0337b2f2db535ab08365f6e763a5015e4d990.
3635 On x86_64, this removes 40kb from the binary. On my machine it is completely neutral on performance.
3637 * html/parser/InputStreamPreprocessor.h:
3638 (WebCore::InputStreamPreprocessor::peek):
3639 (InputStreamPreprocessor):
3640 (WebCore::InputStreamPreprocessor::advance):
3641 (WebCore::InputStreamPreprocessor::skipNextNewLine):
3642 (WebCore::InputStreamPreprocessor::reset):
3643 (WebCore::InputStreamPreprocessor::processNextInputCharacter):
3645 2013-05-14 Carlos Garcia Campos <cgarcia@igalia.com>
3647 Remove WTF_USE_PLATFORM_STRATEGIES
3648 https://bugs.webkit.org/show_bug.cgi?id=114431
3650 Reviewed by Darin Adler.
3652 * Modules/webdatabase/DatabaseManager.cpp:
3653 (WebCore::DatabaseManager::DatabaseManager):
3654 * dom/ContainerNode.cpp:
3655 (WebCore::ContainerNode::suspendPostAttachCallbacks):
3656 (WebCore::ContainerNode::resumePostAttachCallbacks):
3657 * dom/VisitedLinkState.cpp:
3658 (WebCore::VisitedLinkState::determineLinkStateSlowCase):
3659 * loader/CookieJar.cpp:
3661 (WebCore::setCookies):
3662 (WebCore::cookiesEnabled):
3663 (WebCore::cookieRequestHeaderFieldValue):
3664 (WebCore::getRawCookies):
3665 (WebCore::deleteCookie):
3666 * loader/FrameLoader.cpp:
3667 (WebCore::FrameLoader::loadResourceSynchronously):
3668 * loader/HistoryController.cpp:
3669 (WebCore::addVisitedLink):
3670 * loader/LoaderStrategy.cpp:
3671 * loader/LoaderStrategy.h:
3672 * loader/ResourceLoadScheduler.cpp:
3673 (WebCore::resourceLoadScheduler):
3674 * loader/ResourceLoader.cpp:
3675 (WebCore::ResourceLoader::releaseResources):
3676 (WebCore::ResourceLoader::willSendRequest):
3677 * loader/cache/CachedResource.cpp:
3678 (WebCore::CachedResource::load):
3679 * loader/cache/CachedResourceLoader.cpp:
3680 (WebCore::CachedResourceLoader::performPostLoadActions):
3681 * platform/CookiesStrategy.h:
3682 * platform/DatabaseStrategy.cpp:
3683 * platform/DatabaseStrategy.h:
3684 * platform/PasteboardStrategy.h:
3685 * platform/PlatformStrategies.cpp:
3686 * platform/PlatformStrategies.h:
3687 * platform/VisitedLinkStrategy.h:
3688 * platform/mac/PasteboardMac.mm:
3689 * platform/network/BlobRegistry.cpp:
3690 (WebCore::blobRegistry):
3691 * plugins/PluginData.cpp:
3692 (WebCore::PluginData::initPlugins):
3693 * plugins/PluginStrategy.h:
3694 * storage/StorageNamespace.cpp:
3695 (WebCore::StorageNamespace::localStorageNamespace):
3696 (WebCore::StorageNamespace::transientLocalStorageNamespace):
3697 (WebCore::StorageNamespace::sessionStorageNamespace):
3698 * storage/StorageStrategy.cpp:
3699 * storage/StorageStrategy.h:
3700 * workers/SharedWorkerStrategy.h:
3702 2013-05-15 Dávid Szabolcs <David.Szabolcs@stud.u-szeged.hu>
3704 [curl] Add support for HttpOnly cookies
3705 https://bugs.webkit.org/show_bug.cgi?id=116102
3707 Reviewed by Brent Fulgham.
3709 * platform/network/curl/CookieJarCurl.cpp:
3710 (WebCore::addMatchingCurlCookie):
3711 (WebCore::cookiesForSession):
3712 (WebCore::cookiesForDOM):
3714 (WebCore::cookieRequestHeaderFieldValue):
3716 2013-05-14 Carlos Garcia Campos <cgarcia@igalia.com>
3718 REGRESSION(r147548): Broken comboboxes
3719 https://bugs.webkit.org/show_bug.cgi?id=115475
3721 Reviewed by Gustavo Noronha Silva.
3723 The problem is that r147548 made the popup to be closed when a
3724 blur event is received. Right before showing the popup the input
3725 element is focused, so that after the the popup is shown the focus
3726 event is emitted and the event handler is called again hiding the
3729 * html/HTMLSelectElement.cpp:
3730 (WebCore::HTMLSelectElement::menuListDefaultEventHandler): Check
3731 element has lost the focus before closing the popup menu.
3733 2013-05-14 Darin Adler <darin@apple.com>
3735 [Mac] Move setDragImage from ClipboardMac to PasteboardMac
3736 https://bugs.webkit.org/show_bug.cgi?id=116036
3738 Reviewed by Anders Carlsson.
3740 * dom/Clipboard.cpp:
3741 (WebCore::Clipboard::~Clipboard): Stop loading the drag image when
3742 the clipboard object is deallocated. It would be better if there was
3743 a more-well-defined time to stop the load.
3744 (WebCore::Clipboard::setDragImage): Added. Sets up a drag image
3745 based on a CachedImage. This tells the image loader to load the image
3746 and updates the drag image when the image arrives. Copied from the
3747 code in ClipboardMac, but refactored to use a separate loader object.
3748 (WebCore::Clipboard::setDragImageElement): Added. Sets up a drag image
3749 based on an element.
3750 (WebCore::Clipboard::updateDragImage): Added. Common code to update
3751 drag image when a new one is set or when a drag image load completes.
3752 (WebCore::DragImageLoader::create): Added.
3753 (WebCore::DragImageLoader::DragImageLoader): Ditto.
3754 (WebCore::DragImageLoader::startLoading): Ditto.
3755 (WebCore::DragImageLoader::stopLoading): Ditto.
3756 (WebCore::DragImageLoader::imageChanged): Ditto.
3758 * dom/Clipboard.h: Made setDragImage and setDragImageElement non-virtual
3759 for non-legacy. Added updateDragImage and m_dragImageLoader.
3761 * platform/Pasteboard.h: Added setDragImage function.
3763 * platform/mac/ClipboardMac.h: Removed CachedImageClient as a base class
3764 for ClipboardMac. Removed setDragImage and setDragImageElement.
3766 * platform/mac/ClipboardMac.mm: Removed setDragImage and setDragImageElement.
3767 (WebCore::ClipboardMac::~ClipboardMac): Removed code to remove self as
3768 client loading the drag image. This is now in the Clipboard base class.
3770 * platform/mac/PasteboardMac.mm:
3771 (WebCore::Pasteboard::setDragImage): Added. Contains code moved here
3774 2013-05-14 Ryosuke Niwa <rniwa@webkit.org>
3776 Use ElementTraversal in SelectorDataList::execute
3777 https://bugs.webkit.org/show_bug.cgi?id=116131
3779 Reviewed by Darin Adler.
3781 Use ElementTraversal::firstWithin and ElementTraversal::next to simplify the code.
3783 * dom/SelectorQuery.cpp:
3784 (WebCore::SelectorDataList::execute):
3786 2013-05-14 Tim Horton <timothy_horton@apple.com>
3788 [wk2] Not updating tiled backing coverage when main frame scrollability changes
3789 https://bugs.webkit.org/show_bug.cgi?id=116123
3790 <rdar://problem/13836559>
3792 Reviewed by Simon Fraser.
3794 Export FrameView::adjustTiledBackingCoverage.
3798 2013-05-14 Alexey Proskuryakov <ap@apple.com>
3800 [Mac] Add a testing shim for secure event input functions
3801 https://bugs.webkit.org/show_bug.cgi?id=116122
3803 Reviewed by Mark Rowe.
3805 Added a new target with a dynamic library that interposes secure event input functions.
3806 We need this to avoid interfering with user session state.
3808 * Configurations/WebCoreTestShim.xcconfig: Added.
3809 * WebCore.xcodeproj/project.pbxproj:
3810 * platform/mac/DynamicLinkerInterposing.h: Moved from Source/WebKit2/Shared/mac/DyldInterpose.h.
3811 * testing/WebCoreTestShimLibrary.cpp: Added.
3812 (shimEnableSecureEventInput):
3813 (shimDisableSecureEventInput):
3814 (shimIsSecureEventInputEnabled):
3816 2013-05-14 Benjamin Poulain <bpoulain@apple.com>
3818 Get rid of Gradient::getColor()
3819 https://bugs.webkit.org/show_bug.cgi?id=116089
3821 Reviewed by Andreas Kling.
3823 This code is now useless, remove it.
3825 * html/canvas/CanvasGradient.h:
3827 * platform/graphics/Gradient.cpp:
3828 (WebCore::Gradient::Gradient):
3829 (WebCore::Gradient::hash):
3830 * platform/graphics/Gradient.h:
3833 2013-05-14 David Hyatt <hyatt@apple.com>
3835 REGRESSION: united.com has overlapping elements and is broken by flex box changes.
3836 https://bugs.webkit.org/show_bug.cgi?id=115329
3837 <rdar://problem/13690610>
3839 The new flexbox spec says that flex-basis omitted in the flex shorthand defaults to
3840 0 when flex-grow/shrink are set. This has undesirable behavior when objects don't
3841 end up flexing at all, and it's something the spec is going to eventually address.
3843 For now, though, to fix the regression, I'm making a targeted "hack" to deliberately
3844 violate the spec, but to do so as minimally as possible. This hack detects if there
3845 is infinite available space on a line, and if so, it treats a flex-basis of 0 like
3848 This means that when height is constrained and set by a container, flexing will do
3849 the right thing. Basically any time you end up actually flexing, the spec behavior
3850 should happen. If you're just laying out at intrinsic sizes, though, and no flexing
3851 is going to occur, we ignore a flex-basis of 0 and just use the child's normal size.
3853 Note that widths don't have to be patched because the preferred logical widths
3854 algorithm is broken right now and not checking flex-basis. If it did, we'd have seen
3855 the same bug in the width direction.
3857 This width issue is covered by https://bugs.webkit.org/show_bug.cgi?id=116117
3859 Reviewed by Simon Fraser.
3861 Added fast/flexbox/auto-height-with-flex.html
3863 * rendering/RenderFlexibleBox.cpp:
3864 (WebCore::RenderFlexibleBox::mainAxisContentExtent):
3865 Make sure we return LayoutUnit::max when you have infinite free space and not
3866 max - borderPadding.
3868 (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild):
3869 Only clear override size if it was set. Only mark for relayout if we did
3870 an override size clear (i.e., if we were actually flexed). Add a new parameter,
3871 hasInfiniteLineLength, that - if set - causes us to special case flex-basis:0
3872 and treat it like flex-basis:auto.
3874 (WebCore::RenderFlexibleBox::layoutFlexItems):
3875 Define hasInfiniteLineLength and pass it to all the functions that need it.
3877 (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
3878 Remove the code that marks for layout and does a layout so early. This code
3879 is moving (and changing) to preferredMainAxisContentExtentForChild.
3881 (WebCore::RenderFlexibleBox::computeNextFlexLine):
3882 Computes whether or not we have infinite line length now.
3884 (WebCore::RenderFlexibleBox::freezeViolations):
3885 (WebCore::RenderFlexibleBox::resolveFlexibleLengths):
3886 Propagate hasInfiniteLineLength through to preferredMainAxisContentExtentForChild.
3888 * rendering/RenderFlexibleBox.h:
3889 (RenderFlexibleBox):
3890 Add hasInfiniteLineLength parameter to a bunch of functions.
3892 2013-05-14 Andreas Kling <akling@apple.com>
3894 Assertion failure in GlyphPage::setGlyphDataForIndex: (!glyph || fontData == m_fontDataForAllGlyphs)
3895 <http://webkit.org/b/116113>
3896 <rdar://problem/13833790>
3898 Reviewed by Dan Bernstein.
3900 If we're filling a full GlyphPage with a SimpleFontData that is actually a composite font reference,
3901 we need to make sure we have per-glyph font data pointers, since it may end up using them.
3903 Added GlyphPage::mayUseMixedFontDataWhenFilling() which can be implemented by the platform to let
3904 GlyphPageTreeNode know that it should allocate a full-sized GlyphPage for mixed font data pointers
3905 in case the font is a composite font reference, or if there are CJK ideographs in the text.
3907 This code can be made smarter, but that's outside the scope of this change.
3908 Fixes heavy asserting on bots running unreleased software.
3910 * platform/graphics/GlyphPage.h:
3912 (WebCore::GlyphPage::mayUseMixedFontDataWhenFilling):
3913 * platform/graphics/GlyphPageTreeNode.cpp:
3914 (WebCore::GlyphPageTreeNode::initializePage):
3915 * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
3916 (WebCore::shouldUseCoreText):
3917 (WebCore::GlyphPage::mayUseMixedFontDataWhenFilling):
3919 2013-05-14 Bem Jones-Bey <bjonesbe@adobe.com>
3921 Heap-use-after-free in WebCore::RenderBox::exclusionShapeOutsideInfo
3922 https://bugs.webkit.org/show_bug.cgi?id=115566
3924 Reviewed by David Hyatt.
3926 When a portion of the render tree is being detached, anonymous blocks
3927 will be combined as their children are deleted. In this process, the
3928 anonymous block later in the tree is merged into the one preceeding it.
3929 It can happen that the later block contains floats that the previous
3930 block did not contain, and thus are not in the floating objects list for
3931 the new block. This can result in the new block containing floats that
3932 are not in it's floating objects list, but are in the floating objects
3933 lists of siblings and parents. This can cause problems when the float
3934 itself is deleted, since the deletion code assumes that if a float is not
3935 in it's containing block's floating objects list, it isn't in any
3936 floating objects list, causing dangling pointers in the floating objects
3937 lists of the siblings and parents. In order to preserve this condition
3938 (removing it has serious performance implications), we need to copy the
3939 floating objects from the old block to the new block. The float's
3940 metrics will likely all be wrong, but since the new block is already
3941 marked for layout, this will get fixed before anything gets displayed.
3943 Test: fast/block/float/float-append-child-crash.html
3945 * rendering/RenderBlock.cpp:
3946 (WebCore::RenderBlock::moveAllChildrenIncludingFloatsTo): Copy
3947 floating objects list in addition to children.
3948 (WebCore::RenderBlock::FloatingObject::clone): Added.
3949 (WebCore::RenderBlock::removeChild): Use new method to copy children.
3950 * rendering/RenderBlock.h:
3951 (RenderBlock): Add method.
3953 2013-05-14 Commit Queue <commit-queue@webkit.org>
3955 Unreviewed, rolling out r150023.
3956 http://trac.webkit.org/changeset/150023
3957 https://bugs.webkit.org/show_bug.cgi?id=116120
3959 Causes table layout issues (Bug 116118) and crashes on
3960 buildbot waterfall pages. (Requested by ddkilzer on #webkit).
3962 * rendering/RenderTableSection.cpp:
3963 (WebCore::RenderTableSection::calcRowLogicalHeight):
3964 * rendering/RenderTableSection.h:
3965 (RenderTableSection):
3967 2013-05-14 Antoine Quint <graouts@apple.com>
3969 Snapshotted plug-ins shadow tree should reset style inheritance
3970 https://bugs.webkit.org/show_bug.cgi?id=116098
3972 Reset the styles such that only injected user-agent stylesheets affect
3973 the rendering of snapshotted plug-ins' shadow content.
3975 Reviewed by Darin Adler.
3977 * html/HTMLPlugInImageElement.cpp:
3978 (WebCore::HTMLPlugInImageElement::didAddUserAgentShadowRoot):
3980 2013-05-14 Mihnea Ovidenie <mihnea@adobe.com>
3982 [CSSRegions] Improve hit testing for empty regions
3983 https://bugs.webkit.org/show_bug.cgi?id=115534
3985 Reviewed by David Hyatt.
3987 As a better follow up after WebKit bug https://bugs.webkit.org/show_bug.cgi?id=107752,
3988 we can improve the code by not doing hit testing on the render flow thread object when
3989 we are trying to hit test the render flow thread background. In this case, we should just bail out.
3990 No new tests, covered by existing regions tests.
3992 * rendering/RenderFlowThread.cpp:
3993 (WebCore::RenderFlowThread::nodeAtPoint):
3995 (WebCore::RenderFlowThread::hitTestFlowThreadPortionInRegion):
3996 * rendering/RenderFlowThread.h:
3998 2013-05-14 Carlos Garcia Campos <cgarcia@igalia.com>
4000 [BlackBerry] Handle network errors when starting a new job
4001 https://bugs.webkit.org/show_bug.cgi?id=116101
4003 Reviewed by Rob Buis.
4005 Make startJob() return a network status that can be used by the
4006 caller to create a network error.
4008 * platform/network/blackberry/NetworkJob.cpp:
4009 (WebCore::NetworkJob::initialize): createNetworkStream() should
4010 always return a valid pointer so use an ASSERT instead of an early
4011 return to make sure we have a valid stream.
4012 (WebCore::NetworkJob::startNewJobWithRequest): Only return true if
4013 the network job was started successfully.
4014 * platform/network/blackberry/NetworkJob.h:
4015 (NetworkJob): Make initialize method void instead of bool since it
4017 * platform/network/blackberry/NetworkManager.cpp:
4018 (WebCore::NetworkManager::startJob): Return a network error or
4020 * platform/network/blackberry/NetworkManager.h:
4022 * platform/network/blackberry/ResourceHandleBlackBerry.cpp:
4023 (WebCore::ResourceHandle::start): Return true if job was started
4025 (WebCore::ResourceHandle::platformLoadResourceSynchronously):
4026 Check return value of startJob and fill the ResourceError with the
4027 network status returned to finish the load.
4029 2013-05-14 Antoine Quint <graouts@apple.com>
4031 [Mac] captions menu is not positioned correctly in full-screen
4032 https://bugs.webkit.org/show_bug.cgi?id=116103
4034 Update the positioning properties of the captions menu in full-screen
4035 following the fix for https://webkit.org/b/115968.
4037 Reviewed by Darin Adler.
4039 * css/fullscreenQuickTime.css:
4040 (video:-webkit-full-screen::-webkit-media-controls-closed-captions-container):
4041 Add 50px to the bottom position since we're now positioned relative to the
4042 media element, and use a calc() command to be right-aligned to the captions
4043 icon in the media controller. The max-width and max-height properties follow
4044 the same technique used for the non-full-screen mode.
4046 2013-05-14 Zan Dobersek <zdobersek@igalia.com>
4048 [GTK] Move generated ColorData.cpp, WebKitFontFamilyNames.(cpp|h) build targets into libPlatform
4049 https://bugs.webkit.org/show_bug.cgi?id=115921
4051 Reviewed by Gustavo Noronha Silva.
4053 No new tests - no new functionality.
4055 * GNUmakefile.am: Add platform_cppflags to the list of CPPFLAGS for libWebCoreSVG, libWebCore,
4056 libWebCorePlatform, libWebCoreGtk. Remove generation rules for ColorData.cpp and WebKitFontFamilyNames.(cpp|h).
4057 * GNUmakefile.list.am: Include the ColorData.cpp and WebKitFontFamilyNames.(cpp|h) build targers under
4058 platform_built_sources.
4059 * bindings/gobject/GNUmakefile.am: Add platform_cppflags to the list of libWebCoreDOM CPPFLAGS.
4061 2013-05-14 Zan Dobersek <zdobersek@igalia.com>
4063 [GTK] libPlatform, libPlatformGtk must depend on the related GNUmakefiles
4064 https://bugs.webkit.org/show_bug.cgi?id=115937
4066 Reviewed by Martin Robinson.
4068 No new tests - no new functionality.
4070 * GNUmakefile.am: Fix typos in two libraries' names - Webcore -> WebCore.
4072 2013-05-13 Ryosuke Niwa <rniwa@webkit.org>
<