1 2011-09-30 Dan Bernstein <mitz@apple.com>
3 <rdar://problem/10208291> first-letter in generated before content with display: table is not updated
5 Reviewed by Sam Weinig.
7 Test: fast/css-generated-content/first-letter-in-nested-before.html
9 * rendering/RenderObjectChildList.cpp:
10 (WebCore::RenderObjectChildList::updateBeforeAfterContent): Preserve the style type of anonymous
11 containers around the generated content when updating their style. This preserves the first-letter-ness
12 of the inline wrapping the first letter, which allows updateFirstLetter() to identify it later.
14 2011-09-30 Cary Clark <caryclark@google.com>
16 Inset focus ring (Skia on Mac)
17 https://bugs.webkit.org/show_bug.cgi?id=69166
18 http://code.google.com/p/chromium/issues/detail?id=97956
20 This focus ring was drawn too large and was left tracks
21 in subsequent invalidations. Make it more closely match
24 Reviewed by Stephen White.
26 No new tests. This platform is not enabled.
28 * platform/graphics/skia/GraphicsContextSkia.cpp:
29 (WebCore::getFocusRingOutset):
30 (WebCore::GraphicsContext::drawFocusRing):
32 2011-09-30 Sheriff Bot <webkit.review.bot@gmail.com>
34 Unreviewed, rolling out r96422.
35 http://trac.webkit.org/changeset/96422
36 https://bugs.webkit.org/show_bug.cgi?id=69170
38 Broke Windows build and kling wanted to roll it out as well
39 (Requested by rniwa on #webkit).
41 * rendering/InlineBox.cpp:
42 (WebCore::InlineBox::prevOnLineExists):
43 * rendering/InlineBox.h:
44 (WebCore::InlineBox::InlineBox):
46 2011-09-30 David Hyatt <hyatt@apple.com>
48 https://bugs.webkit.org/show_bug.cgi?id=69167
50 [CSS3 Regions] Fix some bugs in the computation of the logical left and width offsets
51 for blocks in variable width regions. Specifically, this patch addresses a minor bug
52 with overflow:hidden/scroll/auto block placement and with RTL directionality.
54 Reviewed by Sam Weinig.
56 Added five new tests in fast/regions.
58 * rendering/RenderBlock.cpp:
59 (WebCore::RenderBlock::logicalRightOffsetForContent):
60 Avoid a double fetch of the border box in a given region by not calling
61 logicalLeftOffsetForContent. No correctness change here. It's just cleaner.
63 * rendering/RenderBox.cpp:
64 (WebCore::RenderBox::borderBoxRectInRegion):
65 Change the shifted optimization to be cached for "self" rather than for "containing block".
66 Rework the adjustment loop to handle changes in directionality and to fix correctness
69 (WebCore::RenderBox::containingBlockLogicalWidthForContentInRegion):
70 Don't double adjust if an object uses line width as the containing block width. In that
71 case we already computed the line width in the region, so we don't need to apply any
74 (WebCore::RenderBox::renderBoxRegionInfo):
75 * rendering/RenderBoxRegionInfo.h:
76 (WebCore::RenderBoxRegionInfo::RenderBoxRegionInfo):
77 (WebCore::RenderBoxRegionInfo::isShifted):
78 Changed the shifted code to be on self rather than on containing block.
80 * rendering/RenderFlowThread.cpp:
81 (WebCore::RenderFlowThread::layout):
82 Refactor the layout code for RenderFlowThread to properly set up region rects assuming
83 right alignment in RTL code. This change forces us to compute our maximum logical width
84 first before looping through the regions again to set their content rects.
86 2011-09-30 Andreas Kling <kling@webkit.org>
88 REGRESSION(r82611) InlineBox has 33 bits of bitset, causing alignment issues and extra memory use.
89 https://bugs.webkit.org/show_bug.cgi?id=64914
91 Reviewed by Antti Koivisto.
93 Remove InlineBox::prevOnLineExists() and its two accompanying bitfields
94 since nobody is using them anymore. nextOnLineExists() is still used by
95 GTK+ accessibility code.
97 Also added a compile-time assertion to guard against future bloating of
100 * rendering/InlineBox.cpp:
101 (WebCore::SameSizeAsInlineBox::~SameSizeAsInlineBox):
102 * rendering/InlineBox.h:
103 (WebCore::InlineBox::InlineBox):
105 2011-09-30 Pierre Rossi <pierre.rossi@gmail.com>
107 [Qt] Build fix: Qt::escape is deprecated in Qt5
108 https://bugs.webkit.org/show_bug.cgi?id=69162
110 Use QString::toHtmlEscaped in the Qt5 case.
112 Reviewed by Andreas Kling.
116 * WebCore.pro: adjust the include path accordingly
119 2011-09-30 Ryosuke Niwa <rniwa@webkit.org>
121 Remove unused ReplaceSelectionCommand::copyStyleToChildren
122 https://bugs.webkit.org/show_bug.cgi?id=69153
124 Reviewed by Antonio Gomes.
126 Removed the function because it's no called anywhere.
128 * editing/ReplaceSelectionCommand.cpp:
129 * editing/ReplaceSelectionCommand.h:
131 2011-09-30 Aaron Colwell <acolwell@chromium.org>
133 Fix EnabledAtRuntime support for constants.
134 https://bugs.webkit.org/show_bug.cgi?id=67311
136 Reviewed by Adam Barth.
138 * bindings/scripts/CodeGeneratorV8.pm:
139 (GenerateImplementation):
141 2011-09-29 David Hyatt <hyatt@apple.com>
143 https://bugs.webkit.org/show_bug.cgi?id=69043
145 [CSS3 Regions] Blocks split across regions with variable width need to size
146 differently in each region.
148 This patch adds the capability for blocks to have variable width and positioning
149 when split across regions. It is very rudimentary and so far only operates on basic
150 normal flow RenderBlocks. Future patches will expand the support to cover other layout
151 constructs like flexible boxes and tables.
153 Reviewed by Sam Weinig.
155 Added new tests in fast/regions and updated existing results.
157 * WebCore.xcodeproj/project.pbxproj:
158 * rendering/HitTestResult.cpp:
159 (WebCore::HitTestResult::HitTestResult):
160 (WebCore::HitTestResult::operator=):
161 * rendering/HitTestResult.h:
162 (WebCore::HitTestResult::region):
163 (WebCore::HitTestResult::setRegion):
164 The hit test result now holds the active RenderRegion so that hit testing can adjust
165 block widths and positions when hit testing their border boxes.
167 * rendering/PaintInfo.h:
168 (WebCore::PaintInfo::PaintInfo):
169 The paint info struct now holds the active RenderRegion so that painting can adjust
170 block widths and positions when painting borders and backgrounds and shadows.
172 * rendering/RenderBlock.cpp:
173 (WebCore::RenderBlock::layoutBlock):
174 If our width ever changes, we invalidate all of our cached RenderBoxRegionInfo in all
175 regions that we span.
177 (WebCore::RenderBlock::clearRenderBoxRegionInfo):
178 Called to clear out our cached region-specific information in all regions that we span.
180 (WebCore::RenderBlock::borderBoxRectInRegionAtPosition):
181 Returns the borderBoxRect for the region at the specified vertical offset. This rect
182 can be both shifted horizontally and have a different width from our original border rect.
184 (WebCore::RenderBlock::logicalLeftOffsetForContent):
185 (WebCore::RenderBlock::logicalRightOffsetForContent):
186 Modified to call borderBoxRectInRegionAtPosition so that lines will fit inside
187 the content rect of the border box rect for the specific region.
189 * rendering/RenderBlock.h:
190 (WebCore::RenderBlock::logicalRightOffsetForContent):
191 Modified to call logicalLeftOffsetForContent since it's cleaner.
193 * rendering/RenderBox.cpp:
194 (WebCore::RenderBox::borderBoxRectInRegion):
195 Called to compute the border box rect in a specific region. The result is cached in a HashMap
196 in the region itself so that subsequent lookups are fast.
198 (WebCore::RenderBox::nodeAtPoint):
199 Modified to use the border box rect in the active region when hit testing the backgrounds of boxes.
201 (WebCore::RenderBox::paintBoxDecorations):
202 Modified to use the border box rect in the active region when painting the backgrounds of boxes.
204 (WebCore::RenderBox::containingBlockLogicalWidthForContent):
205 (WebCore::RenderBox::containingBlockLogicalWidthForContentInRegion):
206 (WebCore::RenderBox::computeLogicalWidth):
207 (WebCore::RenderBox::computeLogicalWidthInRegion):
208 Helpers for computing logical widths and margins in a specific region. The result is then cached
209 in a HashMap in the region.
211 (WebCore::RenderBox::renderBoxRegionInfo):
212 The function for obtaining the region-specific information for a given box.
214 * rendering/RenderBox.h:
215 (WebCore::RenderBox::borderBoxRectInRegion):
216 New function for returning the border box rect in a given region.
218 * rendering/RenderBoxModelObject.cpp:
219 (WebCore::RenderBoxModelObject::paintFillLayerExtended):
220 Make sure mask painting honors the active region.
222 * rendering/RenderBoxRegionInfo.h: Added.
223 (WebCore::RenderBoxRegionInfo::RenderBoxRegionInfo):
224 (WebCore::RenderBoxRegionInfo::logicalLeft):
225 (WebCore::RenderBoxRegionInfo::logicalWidth):
226 (WebCore::RenderBoxRegionInfo::containingBlockChainIsShifted):
227 New class held by RenderRegions that caches box-specific info for a given region. This will eventually
228 expand to include custom styles as well, but for now it is limited to a new logical left and a new
229 logical width, along with a bit for optimizing accumulated shifting when painting/hit testing to avoid
230 too much groveling up the containing block chain.
232 * rendering/RenderFlowThread.cpp:
233 (WebCore::RenderFlowThread::RenderFlowThread):
234 Removed the region fitting optimization, since eventually everyone is going to care, and there's no reason
235 to limit it with the results now being cached.
237 (WebCore::RenderFlowThread::layout):
238 All box-specific region information is always cleared whenever the regions are invalidated.
240 (WebCore::RenderFlowThread::computeLogicalWidth):
241 Modified to set up RenderBoxRegionInfo for the flow thread in all regions.
243 (WebCore::RenderFlowThread::paintIntoRegion):
244 (WebCore::RenderFlowThread::hitTestRegion):
245 Modified to take the region instead of the region's rectangle so that painting and hit testing of the flow
246 thread layer tree can properly receive the active region.
248 (WebCore::RenderFlowThread::removeRenderBoxRegionInfo):
249 Helper for removing a box's information from all regions. For now it grovels through every region, so eventually
250 we may want to have a cache of the start/end regions for a given box somewhere.
252 * rendering/RenderFlowThread.h:
253 Removal of the region fitting stuff.
255 * rendering/RenderLayer.cpp:
256 (WebCore::RenderLayer::paint):
257 (WebCore::RenderLayer::paintOverlayScrollbars):
258 (WebCore::RenderLayer::paintLayer):
259 (WebCore::RenderLayer::paintList):
260 (WebCore::RenderLayer::paintPaginatedChildLayer):
261 (WebCore::RenderLayer::paintChildLayerIntoColumns):
262 * rendering/RenderLayer.h:
263 * rendering/RenderLayerBacking.cpp:
264 (WebCore::RenderLayerBacking::paintIntoLayer):
265 Modified to pass the current region down through painting functions so that it is known at paint time.
267 * rendering/RenderObject.cpp:
268 (WebCore::RenderObject::RenderObject):
269 Added a new bit to RenderObjects, inRenderFlowThread(), so that it is quick to determine whether or not an
270 object needs flow thread special casing.
272 (WebCore::RenderObject::enclosingRenderFlowThread):
273 Modified enclosingRenderFlowThread to be able to quickly return 0 if the object is not in a flow thread.
275 (WebCore::RenderObject::containerForRepaint):
278 * rendering/RenderObject.h:
279 (WebCore::RenderObject::setParent):
280 setParent now updates inRenderFlowThread() state.
282 (WebCore::RenderObject::inRenderFlowThread):
283 (WebCore::RenderObject::setInRenderFlowThread):
286 * rendering/RenderObjectChildList.cpp:
287 (WebCore::RenderObjectChildList::removeChildNode):
288 Make sure when an object is removed from a RenderFlowThread that it deletes its box-specific information
291 * rendering/RenderRegion.cpp:
292 (WebCore::RenderRegion::~RenderRegion):
293 (WebCore::RenderRegion::paintReplaced):
294 (WebCore::RenderRegion::nodeAtPoint):
295 (WebCore::RenderRegion::renderBoxRegionInfo):
296 (WebCore::RenderRegion::setRenderBoxRegionInfo):
297 (WebCore::RenderRegion::removeRenderBoxRegionInfo):
298 (WebCore::RenderRegion::deleteAllRenderBoxRegionInfo):
299 (WebCore::RenderRegion::matchesRenderFlowThreadLogicalWidth):
300 * rendering/RenderRegion.h:
301 Added the new HashMap for holding box-specific region information. Also added an additional optimization to
302 check if a specific region matches the overall width of the RenderFlowThread. If it does, we don't need to
303 cache box-specific information for that region.
305 * rendering/RenderReplica.cpp:
306 (WebCore::RenderReplica::paint):
307 * rendering/RenderScrollbarPart.cpp:
308 (WebCore::RenderScrollbarPart::paintIntoRect):
309 * rendering/svg/SVGImageBufferTools.cpp:
310 (WebCore::SVGImageBufferTools::renderSubtreeToImageBuffer):
311 Modified the PaintInfo construction to include the region argument. It's not optional so that callers will
312 have to consider it (since masks illustrated this is necessary).
314 2011-09-30 Tim Horton <timothy_horton@apple.com>
316 feBlend uses a table of function pointers which reduces inlineability inside the main loop
317 https://bugs.webkit.org/show_bug.cgi?id=69154
318 <rdar://problem/10215221>
320 Reviewed by Darin Adler.
322 Don't use a table of function pointers inside the feBlend inner loop, instead
323 use switch and inline functions, bringing a 20% performance gain across the
326 No new tests, minor performance improvement.
328 * platform/graphics/filters/FEBlend.cpp:
334 (WebCore::FEBlend::apply):
336 2011-09-30 Mark Hahnenberg <mhahnenberg@apple.com>
338 Add getCallData to MethodTable in ClassInfo
339 https://bugs.webkit.org/show_bug.cgi?id=69024
341 Reviewed by Sam Weinig.
347 Changed getCallData from private to protected to allow subclasses who
348 don't override getCallData themselves to reference it in their own
349 method tables when calling the CREATE_METHOD_TABLE macro.
350 * bridge/runtime_method.h:
352 2011-09-30 Ned Holbrook <nholbrook@apple.com>
354 Complex spaces with synthetic bold are too wide
355 https://bugs.webkit.org/show_bug.cgi?id=69033
357 Reviewed by Dan Bernstein.
359 Test: fast/text/complex-synthetic-bold-space-width.html
361 * platform/graphics/mac/ComplexTextController.cpp:
362 (WebCore::ComplexTextController::adjustGlyphsAndAdvances): Subtract synthetic bold offset from spaceWidth.
363 * platform/graphics/win/UniscribeController.cpp:
364 (WebCore::UniscribeController::shapeAndPlaceItem): Ditto.
366 2011-09-30 Pavel Feldman <pfeldman@google.com>
368 Web Inspector: [chromium] expose inspector protocol version to the embedder.
369 https://bugs.webkit.org/show_bug.cgi?id=69092
371 This change also introduces major/minor inspector version components.
373 Reviewed by Yury Semikhatsky.
376 * CodeGenerators.pri:
377 * DerivedSources.make:
379 * GNUmakefile.list.am:
380 * WebCore.gyp/WebCore.gyp:
382 * inspector/Inspector-0.1.json: Renamed from Source/WebCore/inspector/Inspector.draft-01.json.
383 * inspector/Inspector.json:
384 * inspector/generate-inspector-protocol-version: Renamed from Source/WebCore/inspector/validate-protocol-compatibility.
386 2011-09-29 Antti Koivisto <antti@apple.com>
388 https://bugs.webkit.org/show_bug.cgi?id=69106
389 Universal attribute selectors disable style sharing
391 Reviewed by Dave Hyatt.
393 Selectors of type [foo="bar"] ended up marking every element style with the affectedByAttributeSelectors bit
394 rendering style sharing inoperative. This happens on http://www.whatwg.org/specs/web-apps/current-work/ for example.
396 Instead we now mark style with affectedByUncommonAttributeSelectors bit only if an attribute selector actually
397 matches the element. Before sharing, we also check the current element against collected attribute rules.
398 We can share the style if neither element was affected.
400 This speeds up style matching and applying ~15% on full HTML5 spec (=~0.7s). Sharing percentage goes from 0% to ~30%.
401 Increased sharing should also save a substantial amount of memory.
404 (WebCore::CSSSelector::isAttributeSelector):
405 * css/CSSStyleSelector.cpp:
406 (WebCore::RuleData::containsUncommonAttributeSelector):
407 (WebCore::collectSpecialRulesInDefaultStyle):
408 (WebCore::assertNoSiblingRulesInDefaultStyle):
409 (WebCore::CSSStyleSelector::CSSStyleSelector):
410 (WebCore::CSSStyleSelector::matchRules):
411 (WebCore::CSSStyleSelector::matchesRuleSet):
412 (WebCore::CSSStyleSelector::canShareStyleWithElement):
413 (WebCore::CSSStyleSelector::locateSharedStyle):
414 (WebCore::CSSStyleSelector::styleForElement):
415 (WebCore::selectorListContainsUncommonAttributeSelector):
416 (WebCore::isCommonAttributeSelectorAttribute):
417 (WebCore::containsUncommonAttributeSelector):
418 (WebCore::RuleData::RuleData):
419 (WebCore::collectFeaturesFromSelector):
420 (WebCore::collectFeaturesFromList):
421 * css/CSSStyleSelector.h:
422 * css/SelectorChecker.cpp:
423 (WebCore::SelectorChecker::checkOneSelector):
424 * rendering/style/RenderStyle.cpp:
425 (WebCore::RenderStyle::RenderStyle):
426 * rendering/style/RenderStyle.h:
427 (WebCore::InheritedFlags::affectedByUncommonAttributeSelectors):
428 (WebCore::InheritedFlags::setAffectedByUncommonAttributeSelectors):
430 2011-09-30 James Robinson <jamesr@chromium.org>
432 [chromium] Add WebKit API for sending input events to the compositor thread
433 https://bugs.webkit.org/show_bug.cgi?id=69117
435 Reviewed by Darin Fisher.
437 Convert to using an externally-provided thread instead of one managed by CCThreadProxy internally. Most changes
438 in these files are mechanically changing references from ccThread to s_ccThread to reflect the class-static
439 nature of this pointer, the rest are removing the old thread creation codepath.
441 These changes are covered by the CC* unit tests and by the gpu layout tests when run with the
442 use_threaded_compositing=1 gyp define.
444 * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
445 * platform/graphics/chromium/cc/CCLayerTreeHost.h:
446 * platform/graphics/chromium/cc/CCThreadProxy.cpp:
447 (WebCore::CCThreadProxy::setThread):
448 (WebCore::CCThreadProxy::CCThreadProxy):
449 (WebCore::CCThreadProxy::~CCThreadProxy):
450 (WebCore::CCThreadProxy::compositeAndReadback):
451 (WebCore::CCThreadProxy::finishAllRendering):
452 (WebCore::CCThreadProxy::initializeLayerRenderer):
453 (WebCore::CCThreadProxy::setNeedsCommit):
454 (WebCore::CCThreadProxy::setNeedsCommitAndRedraw):
455 (WebCore::CCThreadProxy::setNeedsRedraw):
456 (WebCore::CCThreadProxy::start):
457 (WebCore::CCThreadProxy::stop):
458 (WebCore::CCThreadProxy::beginFrameAndCommit):
459 (WebCore::CCThreadProxy::scheduleDrawTaskOnCCThread):
460 * platform/graphics/chromium/cc/CCThreadProxy.h:
462 2011-09-29 Fady Samuel <fsamuel@chromium.org>
464 Fixed Hit testing on Framesets when Frameset is transformed
465 https://bugs.webkit.org/show_bug.cgi?id=67740
467 Reviewed by Simon Fraser.
469 Tests: fast/frames/frame-set-rotation-hit.html
470 fast/frames/frame-set-scaling-hit.html
472 * rendering/RenderFrameSet.cpp:
473 (WebCore::RenderFrameSet::userResize):
475 2011-09-29 Dirk Pranke <dpranke@chromium.org>
477 fix gyp warnings in chromium for renamed files
478 https://bugs.webkit.org/show_bug.cgi?id=69116
480 Reviewed by Adam Barth.
484 2011-09-29 Martin Robinson <mrobinson@igalia.com>
486 [Freetype] Some text in Planet GNOME renders in the wrong place
487 https://bugs.webkit.org/show_bug.cgi?id=69099
489 Reviewed by Dirk Schulze.
491 Test: platform/gtk/fonts/synthetic-oblique-positioning.html
493 Fold the oblique transform into the font matrix itself rather than transforming
494 the CTM of the context at render time. Not only does this fix the issue, it
495 prevents unnecessary work on every paint.
497 * platform/graphics/cairo/FontCairo.cpp:
498 No longer set the synthetic oblique transformation matrix on the context
499 when rendering the text. Instead it is now folded into the TM of the font
501 * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
502 (WebCore::FontPlatformData::initializeWithFontFace): Fold the oblique transform into the scaled font.
503 * platform/graphics/win/FontPlatformDataCairoWin.cpp:
504 (WebCore::FontPlatformData::FontPlatformData): Ditto.
506 2011-09-29 Dan Bernstein <mitz@apple.com>
508 Follow-up fix for <rdar://problem/10191243> Glyph variants (line final swashes) appear where they should not
510 Reviewed by Simon Fraser.
512 * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
513 (WebCore::FontPlatformData::ctFont): Check for Hoefler Text Black Italic as well.
515 2011-09-29 Cary Clark <caryclark@google.com>
517 Enable LCD text in Skia on Mac
518 https://bugs.webkit.org/show_bug.cgi?id=68734
520 Reviewed by Stephen White.
522 No new tests. Existing layout tests are generated
523 with LCD text disabled for pixel comparisons.
525 Duplicate the logic in FontMac.mm to pass settings
526 for antialiasing and smoothing. Also disable smoothing
529 * platform/graphics/skia/FontSkia.cpp:
530 (WebCore::setupPaint):
531 (WebCore::Font::drawGlyphs):
533 2011-09-29 Varun Jain <varunjain@google.com>
535 Implement flick gesture in Chromium Gesture Recognizer
536 https://bugs.webkit.org/show_bug.cgi?id=67930
538 Reviewed by Dimitri Glazkov.
540 Test: Source/WebKit/chromium/tests/InnerGestureRecognizerTest.cpp
542 * platform/chromium/GestureRecognizerChromium.cpp:
543 (WebCore::GestureRecognizerChromium::isOverMinFlickSpeed):
544 (WebCore::GestureRecognizerChromium::appendScrollGestureEnd):
545 (WebCore::GestureRecognizerChromium::updateValues):
546 (WebCore::GestureRecognizerChromium::scrollEnd):
547 * platform/chromium/GestureRecognizerChromium.h:
549 2011-09-29 Noel Gordon <noel.gordon@gmail.com>
551 [chromium] canvas.toDataURL("image/jpeg"): use libjpeg-turbo data swizzle
552 https://bugs.webkit.org/show_bug.cgi?id=67402
554 Reviewed by Kenneth Russell.
556 libjpeg-turbo can read directly from the input data for the premultiplied BRGX
557 (SkBitmap) encoding case.
559 No change in behavior, covered by existing canvas 2d/3d tests
560 canvas/philip/tests/toDataURL.jpeg.alpha.html
561 fast/canvas/webgl/premultiplyalpha-test.html
563 * platform/image-encoders/skia/JPEGImageEncoder.cpp:
564 (WebCore::encodePixels): If JCS_EXTENSIONS is defined (libjpeg-turbo), swizzle
565 the input BRGX pixels directly within libjpeg-turbo.
567 2011-09-29 Adam Barth <abarth@webkit.org>
571 * bindings/v8/V8DOMWindowShell.cpp:
572 (WebCore::V8DOMWindowShell::namedItemAdded):
574 2011-09-29 Ryosuke Niwa <rniwa@webkit.org>
576 Remove direct reads to m_firstNodeInserted and m_lastLeafInserted in ReplaceSelectionCommand
577 https://bugs.webkit.org/show_bug.cgi?id=69023
579 Reviewed by Enrica Casucci.
581 Converted to removeUnrenderedTextNodesAtEnds to use InsertedNodes instead of m_firstNodeInserted
582 and m_lastLeafInserted. Extracted the logic to update nodes as InsertedNodes::willRemoveNode
583 (old one was renamed to InsertedNodes::willRemoveNodePreservingChildren).
585 Also extracted shouldPerformSmartReplace and addSpacesForSmartReplace out of doApply,
586 and rewrote the logic to obtain endNode and startNode using startOfInsertedContent and
587 endOfInsertedContent instead of m_firstNodeInserted and m_lastLeafInserted.
589 Finally, replaced the nullity checks of m_firstNodeInserted and m_lastLeafInserted in
590 completeHTMLReplacement by nullity checks of start and end positions.
593 (WebCore::Node::traversePreviousSibling): Added.
595 * editing/ReplaceSelectionCommand.cpp:
596 (WebCore::ReplaceSelectionCommand::InsertedNodes::willRemoveNodePreservingChildren): Renamed from
598 (WebCore::ReplaceSelectionCommand::InsertedNodes::willRemoveNode): Extracted from
599 removeUnrenderedTextNodesAtEnds.
600 (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
601 (WebCore::ReplaceSelectionCommand::removeUnrenderedTextNodesAtEnds):
602 (WebCore::ReplaceSelectionCommand::positionAtEndOfInsertedContent): Made const.
603 (WebCore::ReplaceSelectionCommand::positionAtStartOfInsertedContent): Made const.
604 (WebCore::ReplaceSelectionCommand::handleStyleSpans): Takes firstNodeInserted instead of directly
605 accessing m_firstNodeInserted.
606 (WebCore::ReplaceSelectionCommand::doApply):
607 (WebCore::ReplaceSelectionCommand::shouldPerformSmartReplace):
608 (WebCore::ReplaceSelectionCommand::addSpacesForSmartReplace):
609 (WebCore::ReplaceSelectionCommand::completeHTMLReplacement):
610 * editing/ReplaceSelectionCommand.h:
612 2011-09-29 Andreas Kling <kling@webkit.org>
614 Shrink HTMLAnchorElement on 32-bit.
615 https://bugs.webkit.org/show_bug.cgi?id=69094
617 Reviewed by Antti Koivisto.
619 * html/HTMLAnchorElement.h: Pack members into a bitfield.
621 2011-09-29 Dan Bernstein <mitz@apple.com>
623 <rdar://problem/10191243> Glyph variants (line final swashes) appear where they should not
625 Reviewed by Simon Fraser.
627 Test: fast/text/line-initial-and-final-swashes.html
629 Hoefler Text Italic enables line-initial and -final swashes by default, so disable them. This
630 change targets only this known-bad font rather than all fonts, because at least one font (Khmer MN)
631 incorrectly claims to have the line-initial feature enabled, but disabling it actually does
632 something different and bad (breaking some combining marks).
634 * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
635 (WebCore::createFeatureSettingDictionary): Added this helper function.
636 (WebCore::cascadeToLastResortFontDescriptor): Deployed WTF_ARRAY_LENGTH().
637 (WebCore::cascadeToLastResortAndDisableSwashesFontDescriptor): Added. Returns a font descriptor
638 that, in addition to having a cascade list consisting of the last resort font, also has feature
639 settings to disable line-initial and line-final swashes.
640 (WebCore::FontPlatformData::ctFont): For Hoefler Text Italic, use cascadeToLastResortAndDisableSwashesFontDescriptor().
642 2011-09-29 Mark Hahnenberg <mhahnenberg@apple.com>
644 Unreviewed: resetting baseline for code generator bindings
650 * bindings/scripts/test/JS/JSTestObj.cpp:
651 * bindings/scripts/test/JS/JSTestObj.h:
653 2011-09-29 Nate Chapin <japhet@chromium.org>
655 [V8, chromium] More logging to determine cause of a null
656 v8::Context in V8DOMWindowShell::namedItemAdded().
658 https://bugs.webkit.org/show_bug.cgi?id=68099
660 Reviewed by Adam Barth.
662 * bindings/v8/V8DOMWindowShell.cpp:
663 (WebCore::V8DOMWindowShell::namedItemAdded):
665 2011-09-29 Alexey Proskuryakov <ap@apple.com>
667 https://bugs.webkit.org/show_bug.cgi?id=69040
668 ScrollbarThemeComposite requires a ScrollView to draw scroll corner
670 Reviewed by Simon Fraser.
672 No new tests. This will be needed later.
674 * platform/ScrollbarThemeComposite.cpp:
675 (WebCore::pageForScrollView):
676 (WebCore::ScrollbarThemeComposite::paintScrollCorner):
677 Use pageForScrollView() function which already existed in this file, used in another similar
680 * platform/chromium/FramelessScrollView.cpp:
681 * platform/chromium/FramelessScrollView.h:
682 * platform/gtk/ScrollbarThemeGtk.cpp:
683 * platform/gtk/ScrollbarThemeGtk.h:
684 * platform/wx/ScrollbarThemeWx.cpp:
685 * platform/wx/ScrollbarThemeWx.h:
686 All these overrides are no longer needed, ScrollbarThemeComposite will do the right thing.
688 * platform/qt/ScrollbarThemeQt.cpp: (WebCore::ScrollbarThemeQt::paintScrollCorner):
689 Removed a special case for updatingControlTints phase. The same case is present in cross-platform
690 code now, and Qt doesn't have any custom subclasses of ScrollableArea or ScrollView to need
692 This was added in r37377 without a bug or much ChangeLog explanation.
694 2011-09-29 Mark Hahnenberg <mhahnenberg@apple.com>
696 De-virtualize JSCell::visitChildrenVirtual and remove all other visitChildrenVirtual methods
697 https://bugs.webkit.org/show_bug.cgi?id=68839
699 Reviewed by Geoffrey Garen.
703 Removed the remaining visitChildrenVirtual methods. This patch completes the process of
704 de-virtualizing visitChildren.
707 * bindings/js/JSAttrCustom.cpp:
708 * bindings/js/JSAudioContextCustom.cpp:
709 * bindings/js/JSCSSRuleCustom.cpp:
710 * bindings/js/JSCSSStyleDeclarationCustom.cpp:
711 * bindings/js/JSCanvasRenderingContextCustom.cpp:
712 * bindings/js/JSDOMGlobalObject.cpp:
713 (WebCore::JSDOMGlobalObject::~JSDOMGlobalObject):
714 (WebCore::JSDOMGlobalObject::finishCreation):
715 * bindings/js/JSDOMGlobalObject.h:
716 * bindings/js/JSDOMWindowCustom.cpp:
717 * bindings/js/JSDOMWindowShell.cpp:
718 * bindings/js/JSDOMWindowShell.h:
719 * bindings/js/JSJavaScriptAudioNodeCustom.cpp:
720 * bindings/js/JSMessageChannelCustom.cpp:
721 * bindings/js/JSMessagePortCustom.cpp:
722 * bindings/js/JSNamedNodeMapCustom.cpp:
723 * bindings/js/JSNodeCustom.cpp:
724 * bindings/js/JSNodeFilterCustom.cpp:
725 * bindings/js/JSNodeIteratorCustom.cpp:
726 * bindings/js/JSSVGElementInstanceCustom.cpp:
727 * bindings/js/JSSharedWorkerCustom.cpp:
728 * bindings/js/JSStyleSheetCustom.cpp:
729 * bindings/js/JSTreeWalkerCustom.cpp:
730 * bindings/js/JSWebGLRenderingContextCustom.cpp:
731 * bindings/js/JSWorkerContextCustom.cpp:
732 * bindings/js/JSXMLHttpRequestCustom.cpp:
733 * bindings/js/JSXPathResultCustom.cpp:
734 * bindings/scripts/CodeGeneratorJS.pm:
736 (GenerateImplementation):
737 * bridge/qt/qt_instance.cpp:
738 * bridge/qt/qt_runtime.cpp:
739 * bridge/qt/qt_runtime.h:
741 2011-09-23 Tor Arne Vestbø <tor.arne.vestbo@nokia.com>
743 [Qt] Fix build against Qt5 after refactor of widgets out of QtGUi
745 QWidget and friends now live in the QtWidgets library. We update
746 includes in implementation files and private headers to us the
747 non-module-prefixed path, and leave the lookup for the include
748 path. For public headers we have to ifdef the includes as the
749 user might now have the modules we need in his QT config.
751 Finally, QSGCanvas is no longer a QWidget but a QWindow, so we
752 have to update our code and use windowHandle() for setting the
753 parent relationships.
755 https://bugs.webkit.org/show_bug.cgi?id=68687
757 Reviewed by Andreas Kling.
760 * platform/graphics/qt/GraphicsLayerQt.cpp:
762 2011-09-29 Sheriff Bot <webkit.review.bot@gmail.com>
764 Unreviewed, rolling out r96340.
765 http://trac.webkit.org/changeset/96340
766 https://bugs.webkit.org/show_bug.cgi?id=69098
768 Caused 10 tests to crash in Debug (Requested by
769 abarth|gardener on #webkit).
771 * accessibility/AXObjectCache.cpp:
772 (WebCore::AXObjectCache::AXObjectCache):
773 (WebCore::AXObjectCache::~AXObjectCache):
774 (WebCore::AXObjectCache::remove):
775 (WebCore::AXObjectCache::childrenChanged):
776 * accessibility/AXObjectCache.h:
777 * accessibility/AccessibilityMenuList.cpp:
778 (WebCore::AccessibilityMenuList::childrenChanged):
779 * accessibility/AccessibilityMenuList.h:
780 * accessibility/AccessibilityMenuListPopup.cpp:
781 (WebCore::AccessibilityMenuListPopup::childrenChanged):
782 * accessibility/AccessibilityMenuListPopup.h:
783 * accessibility/AccessibilityObject.h:
784 (WebCore::AccessibilityObject::childrenChanged):
785 * accessibility/AccessibilityRenderObject.cpp:
786 (WebCore::startOfContinuations):
787 (WebCore::AccessibilityRenderObject::updateAccessibilityRole):
788 (WebCore::AccessibilityRenderObject::childrenChanged):
789 * accessibility/AccessibilityRenderObject.h:
790 * rendering/RenderObject.cpp:
791 (WebCore::RenderObject::willBeDestroyed):
793 2011-09-29 Andreas Kling <kling@webkit.org>
795 Shrink FontFallbackList.
796 https://bugs.webkit.org/show_bug.cgi?id=69093
798 Reviewed by Antti Koivisto.
800 Reduce the size of FontFallbackList by one CPU word, decreasing memory
801 consumption by 300 kB (on 64-bit) when loading the full HTML5 spec.
803 * platform/graphics/FontCache.h:
804 * platform/graphics/FontCache.cpp:
805 (WebCore::FontCache::generation):
807 Store the FontCache generation as an ushort rather than uint.
809 * platform/graphics/FontFallbackList.cpp:
810 (WebCore::FontFallbackList::FontFallbackList):
811 * platform/graphics/FontFallbackList.h:
813 Pack enum and bool members in a bitfield.
815 2011-09-29 Adam Barth <abarth@webkit.org>
817 We should ignore the return value of GetRealNamedProperty
818 https://bugs.webkit.org/show_bug.cgi?id=68840
820 Reviewed by Nate Chapin.
822 Instead of skipping the lookup process by using the result of real
823 named property, we should just indiciate that it wasn't handled by the
826 Test: http/tests/security/window-named-valueOf.html
828 * bindings/v8/custom/V8DOMWindowCustom.cpp:
829 (WebCore::V8DOMWindow::namedPropertyGetter):
831 2011-09-29 Chris Fleizach <cfleizach@apple.com>
833 ARIA live regions don't trigger notifications for elements that aren't in the AX tree
834 https://bugs.webkit.org/show_bug.cgi?id=62289
836 If an ARIA Live region udpates an element that is not in the AX object cache, then the Live region
837 notification is not sent. To fix this, the childrenChanged() method needs to actually create
838 the appropriate objects, but since that method gets called during a render tree update, we've learned
839 that it's generally not safe to create objects.
841 Instead a one shot timer can be fired that will update and create the necessary objects so that the
842 correct notification can be sent.
844 Reviewed by Darin Adler.
846 Test: platform/mac/accessibility/aria-liveregion-without-element-access.html
848 * accessibility/AXObjectCache.cpp:
849 (WebCore::AXObjectCache::AXObjectCache):
850 (WebCore::AXObjectCache::~AXObjectCache):
851 (WebCore::AXObjectCache::remove):
852 (WebCore::AXObjectCache::childrenUpdateTimerFired):
853 (WebCore::AXObjectCache::childrenChanged):
854 * accessibility/AXObjectCache.h:
855 * accessibility/AccessibilityMenuList.cpp:
856 (WebCore::AccessibilityMenuList::childrenChanged):
857 * accessibility/AccessibilityMenuList.h:
858 * accessibility/AccessibilityMenuListPopup.cpp:
859 (WebCore::AccessibilityMenuListPopup::childrenChanged):
860 * accessibility/AccessibilityMenuListPopup.h:
861 * accessibility/AccessibilityObject.h:
862 (WebCore::AccessibilityObject::childrenChanged):
863 * accessibility/AccessibilityRenderObject.cpp:
864 (WebCore::startOfContinuations):
865 (WebCore::AccessibilityRenderObject::updateAccessibilityRole):
866 (WebCore::AccessibilityRenderObject::childrenChanged):
867 * accessibility/AccessibilityRenderObject.h:
868 * rendering/RenderObject.cpp:
869 (WebCore::RenderObject::willBeDestroyed):
871 2011-09-29 Martin Robinson <mrobinson@igalia.com>
873 [GTK] Dragging a selection does not produce a drag image
874 https://bugs.webkit.org/show_bug.cgi?id=69064
876 Reviewed by Andreas Kling.
878 Moved Chromium's generic implementation of Frame::nodeImage and
879 Frame::dragImageForSeletion to Frame.cpp and simply excluded via
880 #ifdefs platforms that do not have their own implementation. Removed
881 all empty implementations of these functions and Qt's which was
882 functionally identical.
884 No new tests. Drag-and-drop drag image functionality changes
885 are incredibly difficult to test in a non-manual way.
887 * CMakeListsEfl.txt: Delist FrameEfl.cpp.
888 * GNUmakefile.list.am: Delist FrameGtk.cpp.
889 * WebCore.gypi: Delist removed Frame*.cpp.
890 * WebCore.pro: Delist FrameQt.cpp.
891 * page/Frame.cpp: Moved FrameChromium implementation here.
892 (WebCore::ScopedFramePaintingState::ScopedFramePaintingState):
893 (WebCore::ScopedFramePaintingState::~ScopedFramePaintingState):
894 (WebCore::Frame::nodeImage):
895 (WebCore::Frame::dragImageForSelection):
896 * page/chromium/FrameChromium.cpp: Removed.
897 * page/efl/FrameEfl.cpp: Removed.
898 * page/gtk/FrameGtk.cpp: Removed.
899 * page/qt/FrameQt.cpp: Removed.
900 * page/wx/FrameWx.cpp: Removed.
901 * platform/gtk/ClipboardGtk.cpp:
902 (WebCore::ClipboardGtk::createDragImage): Call nodeImage to get
903 the drag image for a node.
905 2011-09-29 Noel Gordon <noel.gordon@gmail.com>
907 [chromium skia] PNGImageEncoder: hoist constants out of the encoding loop
908 https://bugs.webkit.org/show_bug.cgi?id=68988
910 Reviewed by Kenneth Russell.
912 No new tests. Covered by existing canvas 2d and 3d tests.
913 canvas/philip/tests/toDataURL.png.*.html
914 fast/canvas/toDataURL-alpha.html
915 fast/canvas/webgl/premultiplyalpha-test.html
917 * platform/image-encoders/skia/PNGImageEncoder.cpp:
918 (WebCore::encodePixels): Move constant out of the encoding loop.
919 (WebCore::PNGImageEncoder::encode): Consistency & style: call encodePixels()
920 just like we do in the JPEG encoder.
922 2011-09-29 Iain Merrick <husky@google.com>
924 Add unit test for CCLayerSorter
925 https://bugs.webkit.org/show_bug.cgi?id=68622
927 Minor refactoring for testability:
928 - Made pointInTriangle public.
929 - Added LayerShape to decouple LayerIntersector and GraphNode.
930 - Added a public wrapper function for LayerIntersector.
932 Reviewed by James Robinson.
934 * platform/graphics/chromium/cc/CCLayerSorter.cpp:
935 (WebCore::CCLayerSorter::pointInTriangle):
936 (WebCore::CCLayerSorter::calculateZDiff):
937 (WebCore::CCLayerSorter::LayerIntersector::LayerIntersector):
938 (WebCore::CCLayerSorter::LayerIntersector::go):
939 (WebCore::CCLayerSorter::LayerIntersector::checkZDiff):
940 (WebCore::CCLayerSorter::LayerIntersector::layerZFromProjectedPoint):
941 (WebCore::CCLayerSorter::checkOverlap):
942 (WebCore::CCLayerSorter::LayerShape::LayerShape):
943 (WebCore::CCLayerSorter::createGraphNodes):
944 * platform/graphics/chromium/cc/CCLayerSorter.h:
945 (WebCore::CCLayerSorter::LayerShape::LayerShape):
946 (WebCore::CCLayerSorter::GraphNode::GraphNode):
948 2011-09-29 Ilya Tikhonovsky <loislo@chromium.org>
950 Web Inspector: UI performance test for network panel is incorrect. The time is including a timeout between scheduled refresh and actual refresh.
951 https://bugs.webkit.org/show_bug.cgi?id=69087
953 The fix has the changes for the test and minor perf framework improvements.
955 Reviewed by Yury Semikhatsky.
957 * inspector/front-end/NetworkPanel.js:
958 (WebInspector.NetworkLogView.prototype._defaultRefreshDelay.500._scheduleRefresh):
960 2011-09-29 Vsevolod Vlasov <vsevik@chromium.org>
962 Web Inspector: Make search-in-resource test simpler.
963 https://bugs.webkit.org/show_bug.cgi?id=69025
965 Changed search-in-resource test.
966 Removed error parameter from content provider's searchInContent callback.
968 Reviewed by Pavel Feldman.
970 * inspector/InspectorPageAgent.cpp:
971 (WebCore::InspectorPageAgent::searchInResource):
972 (WebCore::InspectorPageAgent::searchInResources):
973 * inspector/front-end/Resource.js:
974 (WebInspector.Resource.prototype.searchInContent):
976 2011-09-29 Hans Wennborg <hans@chromium.org>
978 IndexedDB: Use LevelDB also for in-memory databases
979 https://bugs.webkit.org/show_bug.cgi?id=68903
981 Reviewed by Steve Block.
983 Add LevelDBDatabase::openInMemory() which uses leveldb::NewMemEnv()
984 to create in-memory LevelDB databases.
986 Use this in IDBLeveLDBBackingStore::open() when the caller passes in
988 This happens in Chromium's incognito mode, and when running layout
991 Fix IDBSQLiteBackingStore::backingStoreExists() so it doesn't create
992 files when passed in an empty file path, but uses the in-memory mode
995 Existing layout tests will all be run in-memory.
997 * platform/leveldb/LevelDBDatabase.cpp:
998 (WebCore::LevelDBDatabase::~LevelDBDatabase):
1000 (WebCore::LevelDBDatabase::open):
1001 (WebCore::LevelDBDatabase::openInMemory):
1002 * platform/leveldb/LevelDBDatabase.h:
1003 * storage/IDBLevelDBBackingStore.cpp:
1004 (WebCore::IDBLevelDBBackingStore::open):
1005 * storage/IDBSQLiteBackingStore.cpp:
1006 (WebCore::IDBSQLiteBackingStore::backingStoreExists):
1008 2011-09-29 Ilya Tikhonovsky <loislo@chromium.org>
1010 Web Inspector: speed-up Network panel. Change _staleResources type from array to object.
1011 https://bugs.webkit.org/show_bug.cgi?id=69081
1013 There is a test with 30 requests.
1014 For the each stage of loading a resource we have an entry in _staleResources array. There are at least 4 stages per request.
1015 NetworkLogView._refresh function is creating/updating the resource row for the each such entry.
1016 This array can be replaced with a hash map just because the resource associated with the entry is the same for all the entries with the same request id.
1018 Reviewed by Pavel Feldman.
1020 Test: inspector/performance/resources/network-append-30-requests.html
1022 * inspector/front-end/NetworkPanel.js:
1023 (WebInspector.NetworkLogView):
1024 (WebInspector.NetworkLogView.prototype._invalidateAllItems):
1025 (WebInspector.NetworkLogView.prototype.refresh):
1026 (WebInspector.NetworkLogView.prototype._reset):
1027 (WebInspector.NetworkLogView.prototype._refreshResource):
1029 2011-09-28 Pavel Feldman <pfeldman@google.com>
1031 Web Inspector: make inspector protocol validation a part of the build process.
1032 https://bugs.webkit.org/show_bug.cgi?id=68999
1034 Since we'd like to commit to inspector protocol backwards compatibility, violating it
1035 should be a build failure.
1037 Reviewed by Yury Semikhatsky.
1040 * CodeGenerators.pri:
1041 * DerivedSources.make:
1043 * WebCore.gyp/WebCore.gyp:
1044 * inspector/Inspector.draft-01.json:
1045 * inspector/Inspector.json:
1046 * inspector/generate-inspector-idl:
1047 * inspector/generate-protocol-externs:
1048 * inspector/validate-protocol-compatibility:
1050 2011-09-27 Pavel Feldman <pfeldman@google.com>
1052 Web Inspector: Scripts panel without folders causes errors when creating content scripts section.
1053 https://bugs.webkit.org/show_bug.cgi?id=68827
1055 Reviewed by Yury Semikhatsky.
1057 * inspector/front-end/ScriptsPanel.js:
1058 (WebInspector.ScriptsPanel.prototype._addOptionToFilesSelect.insertOrdered.optionCompare):
1059 (WebInspector.ScriptsPanel.prototype._addOptionToFilesSelect.insertOrdered):
1060 (WebInspector.ScriptsPanel.prototype._addOptionToFilesSelect):
1062 2011-09-28 Andrey Kosyakov <caseq@chromium.org>
1064 Web Inspector: network log view refresh optimizations
1065 https://bugs.webkit.org/show_bug.cgi?id=69010
1067 Reviewed by Pavel Feldman.
1069 * inspector/front-end/NetworkPanel.js:
1070 (WebInspector.NetworkLogView.prototype.refresh):
1072 2011-09-29 Pavel Podivilov <podivilov@chromium.org>
1074 Web Inspector: split SourceFile.js into RawSourceCode.js and UISourceCodeContentProviders.js.
1075 https://bugs.webkit.org/show_bug.cgi?id=69068
1077 Reviewed by Yury Semikhatsky.
1080 * WebCore.vcproj/WebCore.vcproj:
1081 * inspector/front-end/RawSourceCode.js: Renamed from Source/WebCore/inspector/front-end/SourceFile.js.
1082 (WebInspector.RawSourceCode): Moved from SourceFile.js.
1083 (WebInspector.UILocation): Moved from SourceFile.js.
1084 * inspector/front-end/UISourceCodeContentProviders.js: Added. Moved ContentProvider implementations from SourceFile.js
1085 (WebInspector.ScriptContentProvider):
1086 (WebInspector.ScriptContentProvider.prototype.requestContent):
1087 (WebInspector.ConcatenatedScriptsContentProvider):
1088 (WebInspector.ConcatenatedScriptsContentProvider.prototype.requestContent):
1089 (WebInspector.ConcatenatedScriptsContentProvider.prototype._concatenateScriptsContent.appendChunk):
1090 (WebInspector.ConcatenatedScriptsContentProvider.prototype._concatenateScriptsContent):
1091 (WebInspector.ResourceContentProvider):
1092 (WebInspector.ResourceContentProvider.prototype.requestContent):
1093 (WebInspector.StaticContentProvider):
1094 (WebInspector.StaticContentProvider.prototype.requestContent):
1095 * inspector/front-end/WebKit.qrc:
1096 * inspector/front-end/inspector.html:
1098 2011-09-29 Philippe Normand <pnormand@igalia.com>
1100 [GStreamer] 2 flaky media tests
1101 https://bugs.webkit.org/show_bug.cgi?id=67407
1103 Reviewed by Martin Robinson.
1105 Workaround for GStreamer bug#639941. In GStreamer
1106 0.10.35 basesink reports wrong duration in case of EOS and
1107 negative playback rate. This workaround fixes two media tests,
1108 media/video-timeupdate-reverse-play.html and
1109 media/video-reverse-play-duration.html.
1111 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1112 (WebCore::MediaPlayerPrivateGStreamer::prepareToPlay):
1113 (WebCore::MediaPlayerPrivateGStreamer::currentTime):
1114 (WebCore::MediaPlayerPrivateGStreamer::didEnd):
1116 2011-09-29 Philippe Normand <pnormand@igalia.com>
1118 [GStreamer] fullscreen video pause/play fails
1119 https://bugs.webkit.org/show_bug.cgi?id=66936
1121 Reviewed by Martin Robinson.
1123 Don't use the identity element to avoid painting of the in-window
1124 video. Instead simply make the sink aware of the fullscreen state
1125 and ignore buffers if fullscreen and autovideosink are
1126 active. Also fixed two deadlocks happening when a paused pipeline
1127 is switched to fullscreen and when fullscreen is disabled for a
1130 * platform/graphics/gstreamer/GStreamerGWorld.cpp:
1131 (WebCore::GStreamerGWorld::enterFullscreen):
1132 (WebCore::GStreamerGWorld::exitFullscreen):
1133 * platform/graphics/gstreamer/GStreamerGWorld.h:
1134 (WebCore::GStreamerGWorld::isFullscreen):
1135 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1136 (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
1137 * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
1138 (webkit_video_sink_render):
1139 (webkit_video_sink_new):
1140 * platform/graphics/gstreamer/VideoSinkGStreamer.h:
1142 2011-09-29 Tim Horton <timothy_horton@apple.com>
1144 REGRESSION(87010): elements in ECMA-cloud neither filled nor blurred
1145 https://bugs.webkit.org/show_bug.cgi?id=68679
1146 <rdar://problem/10204649>
1148 Reviewed by Nikolas Zimmermann.
1150 Strip prefixes from SVG attributes before testing if they're supported.
1151 Namespaced attributes will be matched using their namespace instead of
1152 the (user-choosable) prefix.
1154 Test: svg/custom/xlink-custom-namespace.svg
1156 * svg/SVGAElement.cpp:
1157 (WebCore::SVGAElement::isSupportedAttribute):
1158 * svg/SVGAnimateMotionElement.cpp:
1159 (WebCore::SVGAnimateMotionElement::isSupportedAttribute):
1160 * svg/SVGAnimateTransformElement.cpp:
1161 (WebCore::SVGAnimateTransformElement::isSupportedAttribute):
1162 * svg/SVGAnimationElement.cpp:
1163 (WebCore::SVGAnimationElement::isSupportedAttribute):
1164 * svg/SVGCircleElement.cpp:
1165 (WebCore::SVGCircleElement::isSupportedAttribute):
1166 * svg/SVGClipPathElement.cpp:
1167 (WebCore::SVGClipPathElement::isSupportedAttribute):
1168 * svg/SVGComponentTransferFunctionElement.cpp:
1169 (WebCore::SVGComponentTransferFunctionElement::isSupportedAttribute):
1170 * svg/SVGCursorElement.cpp:
1171 (WebCore::SVGCursorElement::isSupportedAttribute):
1173 (WebCore::SVGAttributeHashTranslator::hash):
1174 (WebCore::SVGAttributeHashTranslator::equal):
1175 * svg/SVGEllipseElement.cpp:
1176 (WebCore::SVGEllipseElement::isSupportedAttribute):
1177 * svg/SVGExternalResourcesRequired.h:
1178 * svg/SVGFEBlendElement.cpp:
1179 (WebCore::SVGFEBlendElement::isSupportedAttribute):
1180 * svg/SVGFEColorMatrixElement.cpp:
1181 (WebCore::SVGFEColorMatrixElement::isSupportedAttribute):
1182 * svg/SVGFEComponentTransferElement.cpp:
1183 (WebCore::SVGFEComponentTransferElement::isSupportedAttribute):
1184 * svg/SVGFECompositeElement.cpp:
1185 (WebCore::SVGFECompositeElement::isSupportedAttribute):
1186 * svg/SVGFEConvolveMatrixElement.cpp:
1187 (WebCore::SVGFEConvolveMatrixElement::isSupportedAttribute):
1188 * svg/SVGFEDiffuseLightingElement.cpp:
1189 (WebCore::SVGFEDiffuseLightingElement::isSupportedAttribute):
1190 * svg/SVGFEDisplacementMapElement.cpp:
1191 (WebCore::SVGFEDisplacementMapElement::isSupportedAttribute):
1192 * svg/SVGFEDropShadowElement.cpp:
1193 (WebCore::SVGFEDropShadowElement::isSupportedAttribute):
1194 * svg/SVGFEGaussianBlurElement.cpp:
1195 (WebCore::SVGFEGaussianBlurElement::isSupportedAttribute):
1196 * svg/SVGFEImageElement.cpp:
1197 (WebCore::SVGFEImageElement::isSupportedAttribute):
1198 * svg/SVGFELightElement.cpp:
1199 (WebCore::SVGFELightElement::isSupportedAttribute):
1200 * svg/SVGFEMergeNodeElement.cpp:
1201 (WebCore::SVGFEMergeNodeElement::isSupportedAttribute):
1202 * svg/SVGFEMorphologyElement.cpp:
1203 (WebCore::SVGFEMorphologyElement::isSupportedAttribute):
1204 * svg/SVGFEOffsetElement.cpp:
1205 (WebCore::SVGFEOffsetElement::isSupportedAttribute):
1206 * svg/SVGFESpecularLightingElement.cpp:
1207 (WebCore::SVGFESpecularLightingElement::isSupportedAttribute):
1208 * svg/SVGFETileElement.cpp:
1209 (WebCore::SVGFETileElement::isSupportedAttribute):
1210 * svg/SVGFETurbulenceElement.cpp:
1211 (WebCore::SVGFETurbulenceElement::isSupportedAttribute):
1212 * svg/SVGFilterElement.cpp:
1213 (WebCore::SVGFilterElement::isSupportedAttribute):
1214 * svg/SVGFilterPrimitiveStandardAttributes.cpp:
1215 (WebCore::SVGFilterPrimitiveStandardAttributes::isSupportedAttribute):
1216 * svg/SVGForeignObjectElement.cpp:
1217 (WebCore::SVGForeignObjectElement::isSupportedAttribute):
1218 * svg/SVGGElement.cpp:
1219 (WebCore::SVGGElement::isSupportedAttribute):
1220 * svg/SVGGradientElement.cpp:
1221 (WebCore::SVGGradientElement::isSupportedAttribute):
1222 * svg/SVGImageElement.cpp:
1223 (WebCore::SVGImageElement::isSupportedAttribute):
1224 * svg/SVGLineElement.cpp:
1225 (WebCore::SVGLineElement::isSupportedAttribute):
1226 * svg/SVGLinearGradientElement.cpp:
1227 (WebCore::SVGLinearGradientElement::isSupportedAttribute):
1228 * svg/SVGMPathElement.cpp:
1229 (WebCore::SVGMPathElement::isSupportedAttribute):
1230 * svg/SVGMarkerElement.cpp:
1231 (WebCore::SVGMarkerElement::isSupportedAttribute):
1232 * svg/SVGMaskElement.cpp:
1233 (WebCore::SVGMaskElement::isSupportedAttribute):
1234 * svg/SVGPathElement.cpp:
1235 (WebCore::SVGPathElement::isSupportedAttribute):
1236 * svg/SVGPatternElement.cpp:
1237 (WebCore::SVGPatternElement::isSupportedAttribute):
1238 * svg/SVGPolyElement.cpp:
1239 (WebCore::SVGPolyElement::isSupportedAttribute):
1240 * svg/SVGRadialGradientElement.cpp:
1241 (WebCore::SVGRadialGradientElement::isSupportedAttribute):
1242 * svg/SVGRectElement.cpp:
1243 (WebCore::SVGRectElement::isSupportedAttribute):
1244 * svg/SVGScriptElement.cpp:
1245 (WebCore::SVGScriptElement::isSupportedAttribute):
1246 * svg/SVGStopElement.cpp:
1247 (WebCore::SVGStopElement::isSupportedAttribute):
1248 * svg/SVGStyleElement.cpp:
1249 (WebCore::SVGStyleElement::isSupportedAttribute):
1250 * svg/SVGStyledTransformableElement.cpp:
1251 (WebCore::SVGStyledTransformableElement::isSupportedAttribute):
1252 * svg/SVGSymbolElement.cpp:
1253 (WebCore::SVGSymbolElement::isSupportedAttribute):
1254 * svg/SVGTRefElement.cpp:
1255 (WebCore::SVGTRefElement::isSupportedAttribute):
1256 * svg/SVGTextContentElement.cpp:
1257 (WebCore::SVGTextContentElement::isSupportedAttribute):
1258 * svg/SVGTextElement.cpp:
1259 (WebCore::SVGTextElement::isSupportedAttribute):
1260 * svg/SVGTextPathElement.cpp:
1261 (WebCore::SVGTextPathElement::isSupportedAttribute):
1262 * svg/SVGTextPositioningElement.cpp:
1263 (WebCore::SVGTextPositioningElement::isSupportedAttribute):
1264 * svg/SVGURIReference.cpp:
1265 (WebCore::SVGURIReference::addSupportedAttributes):
1266 * svg/SVGUseElement.cpp:
1267 (WebCore::SVGUseElement::isSupportedAttribute):
1268 * svg/SVGViewElement.cpp:
1269 (WebCore::SVGViewElement::isSupportedAttribute):
1271 2011-09-28 Kentaro Hara <haraken@chromium.org>
1273 "ScriptValue" arguments of PopStateEvent methods should be "const ScriptValue&"
1274 https://bugs.webkit.org/show_bug.cgi?id=68984
1276 Reviewed by Darin Adler.
1278 Just a follow-up fix for the bug 68345. For performance,
1279 "ScriptValue" arguments of PopStateEvent methods should be "const ScriptValue&".
1281 Tests: fast/events/constructors/pop-state-event-constructor.html
1282 fast/events/fire-popstate-event.html
1284 * dom/PopStateEvent.cpp:
1285 (WebCore::PopStateEvent::PopStateEvent):
1286 (WebCore::PopStateEvent::create):
1287 (WebCore::PopStateEvent::initPopStateEvent):
1288 * dom/PopStateEvent.h:
1290 2011-09-28 Martin Robinson <mrobinson@igalia.com>
1292 [GTK] Move drag-and-drop code which can be shared with WebKit2 to WebCore
1293 https://bugs.webkit.org/show_bug.cgi?id=66890
1295 Added a GtkDragAndDropHelper class to hold all the logic that is common
1296 between WebKit1 and WebKit2. This will allow greater code sharing between
1299 Reviewed by Philippe Normand.
1301 No new tests. This patch should not change behavior.
1303 * GNUmakefile.list.am: Added the GtkDragAndDropHelper to the sources list.
1304 * platform/gtk/GtkDragAndDropHelper.cpp: Added.
1305 * platform/gtk/GtkDragAndDropHelper.h: Added.
1307 2011-09-28 Dan Bernstein <mitz@apple.com>
1309 <rdar://problem/10196497> first-letter after list marker not updated correctly
1311 Reviewed by Simon Fraser.
1313 Test: fast/dynamic/first-letter-after-list-marker.html
1315 * rendering/RenderBlock.cpp:
1316 (WebCore::RenderBlock::updateFirstLetter): Improved the logic for continuing past list markers
1317 when trying to locate a first letter to update.
1319 2011-09-28 Kent Tamura <tkent@chromium.org>
1321 REGRESSION(r93858): Can't type anything into input elements when maxlength is greater than 2^31
1322 https://bugs.webkit.org/show_bug.cgi?id=68981
1324 Reviewed by Darin Adler.
1326 * html/parser/HTMLParserIdioms.cpp:
1327 (WebCore::parseHTMLInteger):
1328 Check the failure of charactersToIntStrict().
1329 (WebCore::parseHTMLNonNegativeInteger):
1330 Check the failure of charactersToUIntStrict().
1332 2011-09-28 Antoine Labour <piman@chromium.org>
1334 Remove unused createRootLayerPainter from CCLayerTreeHostClient
1335 https://bugs.webkit.org/show_bug.cgi?id=69042
1337 Reviewed by James Robinson.
1339 No new test needed: no semantic change.
1341 * platform/graphics/chromium/cc/CCLayerTreeHost.h:
1343 2011-09-28 Luke Macpherson <macpherson@chromium.org>
1345 Only resolve direction aware properties when properties are direction aware.
1346 https://bugs.webkit.org/show_bug.cgi?id=68968
1348 Reviewed by Eric Seidel.
1350 No new tests / no functionality changed.
1352 Profiling showed a ~8% improvement in applyProperty by not calling resolveDirectionAwareProperty for every property.
1354 * css/CSSStyleSelector.cpp:
1355 (WebCore::CSSStyleSelector::applyProperty):
1357 2011-09-28 Simon Fraser <simon.fraser@apple.com>
1359 fast/dom/scroll-element-to-rect.html fails on WK1 Mac port
1360 https://bugs.webkit.org/show_bug.cgi?id=68815
1362 Reviewed by Dan Bernstein.
1364 FrameView::scrollElementToRect() was incorrectly using Element::boundsInWindowSpace(),
1365 which is window-relative (not web view-relative), and has flipped coordinates
1368 Change to use Node::getRect() which is what the author intended.
1371 * page/FrameView.cpp:
1372 (WebCore::FrameView::scrollElementToRect):
1374 2011-09-28 Peter Beverloo <peter@chromium.org>
1376 Don't clamp cubic-bezier timing functions between 0 and 1
1377 https://bugs.webkit.org/show_bug.cgi?id=45761
1379 Remove the limitation of clamping the cubic-bezier timing function
1380 values between 0 and 1, following the specification change made on
1381 April 5 of this year.
1383 Reviewed by Dean Jackson.
1385 Tests: transitions/cubic-bezier-overflow-color.html
1386 transitions/cubic-bezier-overflow-length.html
1387 transitions/cubic-bezier-overflow-shadow.html
1388 transitions/cubic-bezier-overflow-svg-length.html
1389 transitions/cubic-bezier-overflow-transform.html
1391 * css/CSSParser.cpp:
1392 (WebCore::CSSParser::parseCubicBezierTimingFunctionValue):
1394 2011-09-28 Chris Rogers <crogers@google.com>
1396 DelayNode must set the context on delayTime AudioParam to support automation
1397 https://bugs.webkit.org/show_bug.cgi?id=68828
1399 Reviewed by Kenneth Russell.
1401 Test: webaudio/delaynode-scheduling.html
1403 * webaudio/DelayNode.cpp:
1404 (WebCore::DelayNode::DelayNode):
1406 2011-09-28 Sergey Glazunov <serg.glazunov@gmail.com>
1408 JavaScript generated documents don't inherit the cookie URL
1409 https://bugs.webkit.org/show_bug.cgi?id=69003
1411 Reviewed by Adam Barth.
1413 Test: http/tests/security/cookies/cookie-theft-with-javascript-doc.html
1416 (WebCore::Document::setCookieURL):
1417 * loader/DocumentWriter.cpp:
1418 (WebCore::DocumentWriter::replaceDocument):
1419 (WebCore::DocumentWriter::begin):
1420 * loader/DocumentWriter.h:
1422 2011-09-27 Dimitri Glazkov <dglazkov@chromium.org>
1424 REGRESSION(r95573): Crash when loading SVG documents in a flattened frame or any SVG document in Chromium/Mac.
1425 https://bugs.webkit.org/show_bug.cgi?id=68938
1427 Reviewed by David Hyatt.
1429 Test: all svg tests in LayoutTests.
1431 * rendering/RenderBlock.cpp:
1432 (WebCore::RenderBlock::computeBlockPreferredLogicalWidths): Added a null-check for containingBlock.
1434 2011-09-28 Una Sabovic <una.sabovic@palm.com>
1436 Setting innerText to an empty string on editable div loses focus
1437 https://bugs.webkit.org/show_bug.cgi?id=62092
1439 Reviewed by Ryosuke Niwa.
1441 When selection start or end node is being deleted do not clear the selection.
1442 Instead update the start/end position to an equivalent parent-anchored positions.
1443 When text is inserted/deleted update selection per range modification spec:
1444 http://www.w3.org/TR/DOM-Level-2-Traversal-Range/ranges.html#Level-2-Range-Mutation
1446 Tests: editing/selection/document-mutation.html
1447 editing/selection/editable-div-clear-on-keydown.html
1449 * editing/FrameSelection.cpp:
1450 (WebCore::FrameSelection::respondToNodeModification):
1451 (WebCore::updatePositionAfterAdoptingTextReplacement):
1452 (WebCore::FrameSelection::textWillBeReplaced):
1453 * editing/htmlediting.cpp:
1454 (WebCore::updatePositionForNodeRemoval):
1456 2011-09-28 Joseph Pecoraro <joepeck@webkit.org>
1458 FTPDirectoryDocument Shows Garbled String for Last Modified Date
1459 https://bugs.webkit.org/show_bug.cgi?id=69011
1461 Reviewed by Dan Bernstein.
1463 Force WTF::String concatenation instead of an accidental char* pointer addition.
1465 * html/FTPDirectoryDocument.cpp:
1466 (WebCore::processFileDateString):
1468 2011-09-28 Nate Chapin <japhet@chromium.org>
1470 Fix a regression in r96060. ResourceLoader shouldn't get
1471 initialized with a null DocumentLoader.
1472 https://bugs.webkit.org/show_bug.cgi?id=69004
1474 Reviewed by Csaba Osztrogonác.
1476 This should fix a debug crash in some platforms in
1477 plugins/js-from-destroy.html
1479 * loader/ResourceLoader.cpp:
1480 (WebCore::ResourceLoader::init): Move the activeDocumentLoader() null checks back
1481 to SubresouceLoader::create().
1482 * loader/SubresourceLoader.cpp:
1483 (WebCore::SubresourceLoader::create):
1485 2011-09-28 Adam Barth <abarth@webkit.org>
1487 CSP doesn't work for a wide variety of cases
1488 https://bugs.webkit.org/show_bug.cgi?id=68921
1490 Reviewed by Darin Adler.
1492 Patch suggested by Sam Weinig. It's unclear to me how to test this
1493 change because all our tests run on non-default ports, which is why we
1494 have this bug in the first place. Mozilla uses a proxy while testing
1495 so they can test with URLs like http://example.com, but we don't have
1498 * page/ContentSecurityPolicy.cpp:
1499 (WebCore::CSPSource::portMatches):
1501 2011-09-28 Fady Samuel <fsamuel@chromium.org>
1503 [Chromium] Seperate GTK specific Gyp rules from X11 Gyp rules
1504 https://bugs.webkit.org/show_bug.cgi?id=68936
1506 Reviewed by Tony Chang.
1508 Chromium need to be built without Gtk for future version of ChromiumOS.
1510 * WebCore.gyp/WebCore.gyp:
1512 2011-09-28 Tom Sepez <tsepez@chromium.org>
1514 Revert change which broke displaying end script tags in view-source, instead
1515 deal with any trailing </script> tag included by mistake in the XSSAuditor
1516 itself. Correct tests to detect the missing close tags.
1517 https://bugs.webkit.org/show_bug.cgi?id=68898
1519 Reviewed by Adam Barth.
1521 * html/parser/HTMLSourceTracker.cpp:
1522 (WebCore::HTMLSourceTracker::end):
1523 * html/parser/HTMLTokenizer.cpp:
1524 (WebCore::HTMLTokenizer::nextToken):
1525 * html/parser/XSSAuditor.cpp:
1526 (WebCore::startsHTMLEndTagAt):
1527 (WebCore::XSSAuditor::snippetForJavaScript):
1529 2011-09-28 Adam Barth <abarth@webkit.org>
1531 Remove empty directories.
1533 * editing/brew: Removed.
1534 * page/brew: Removed.
1535 * platform/brew: Removed.
1536 * platform/graphics/brew: Removed.
1537 * platform/network/brew: Removed.
1538 * platform/text/brew: Removed.
1540 2011-09-28 Ilya Tikhonovsky <loislo@chromium.org>
1542 Web Inspector: optional arguments support for the frontend needs to be extended.
1543 https://bugs.webkit.org/show_bug.cgi?id=69005
1545 Generator supports optional arguments but they are transferred by value.
1546 It is not suitable if the used type doesn't have operator bool.
1547 I'll transfer such arguments by pointer.
1549 Reviewed by Pavel Feldman.
1553 * inspector/CodeGeneratorInspector.pm:
1554 (generateFrontendFunction):
1556 * inspector/InspectorDebuggerAgent.cpp:
1557 (WebCore::InspectorDebuggerAgent::didParseSource):
1558 * inspector/InspectorResourceAgent.cpp:
1559 (WebCore::InspectorResourceAgent::didFailLoading):
1561 2011-09-28 Antaryami Pandia <antaryami.pandia@motorola.com>
1563 Reflected attribute input.size wraps on negative values (Chrome), or
1564 returns them (Safari).
1565 https://bugs.webkit.org/show_bug.cgi?id=44886
1567 Reviewed by Darin Adler.
1569 Test: fast/dom/HTMLInputElement/input-size-attribute.html
1571 * html/HTMLInputElement.cpp:
1572 (WebCore::HTMLInputElement::parseMappedAttribute):
1574 2011-09-28 Vsevolod Vlasov <vsevik@chromium.org>
1576 Web Inspector: Add support for search in single resource to page agent.
1577 https://bugs.webkit.org/show_bug.cgi?id=68998
1579 Reviewed by Pavel Feldman.
1581 Test: http/tests/inspector/search/search-in-resource.html
1583 * inspector/ContentSearchUtils.cpp:
1584 (WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
1585 * inspector/ContentSearchUtils.h:
1586 * inspector/Inspector.json:
1587 * inspector/InspectorPageAgent.cpp:
1588 (WebCore::buildObjectForSearchMatch):
1589 (WebCore::InspectorPageAgent::searchInResource):
1590 * inspector/InspectorPageAgent.h:
1591 * inspector/front-end/Resource.js:
1592 (WebInspector.Resource.prototype.searchInContent):
1593 * inspector/front-end/SourceFile.js:
1594 (WebInspector.ResourceContentProvider.prototype.requestContent):
1595 (WebInspector.ResourceContentProvider.prototype.searchInContent):
1596 * inspector/front-end/UISourceCode.js:
1597 (WebInspector.ContentProvider.prototype.requestContent):
1598 (WebInspector.ContentProvider.prototype.searchInContent):
1600 2011-09-28 Ilya Tikhonovsky <loislo@chromium.org>
1602 Web Inspector: It'd be useful to have performance stats for the back-end to front-end communication channel.
1603 https://bugs.webkit.org/show_bug.cgi?id=69002
1605 Reviewed by Yury Semikhatsky.
1607 * inspector/CodeGeneratorInspector.pm:
1609 2011-09-27 Pavel Podivilov <podivilov@chromium.org>
1611 Web Inspector: live edit cursor always appears at the beginning of the file.
1612 https://bugs.webkit.org/show_bug.cgi?id=68900
1614 Reviewed by Pavel Feldman.
1616 * inspector/front-end/TextViewer.js:
1617 (WebInspector.TextEditorMainPanel.prototype._updateSelectionOnStartEditing):
1619 2011-09-28 Vsevolod Vlasov <vsevik@chromium.org>
1621 Web Inspector: Refactor searching in inspector, add test (fixed non regex search).
1622 https://bugs.webkit.org/show_bug.cgi?id=68930
1624 Reviewed by Yury Semikhatsky.
1626 Search moved out from page agent.
1627 Fixed search for non regex case which is not yet used.
1629 Test: http/tests/inspector/search/search-in-resources.html
1632 * GNUmakefile.list.am:
1635 * WebCore.vcproj/WebCore.vcproj:
1636 * WebCore.xcodeproj/project.pbxproj:
1637 * inspector/ContentSearchUtils.cpp: Added.
1638 (WebCore::ContentSearchUtils::createSearchRegexSource):
1639 (WebCore::ContentSearchUtils::createSearchRegex):
1640 (WebCore::ContentSearchUtils::countRegularExpressionMatches):
1641 * inspector/ContentSearchUtils.h: Added.
1642 * inspector/InspectorPageAgent.cpp:
1643 (WebCore::hasTextContent):
1644 (WebCore::InspectorPageAgent::cachedResourceContent):
1645 (WebCore::textContentForCachedResource):
1646 (WebCore::buildObjectForSearchResult):
1647 (WebCore::InspectorPageAgent::searchInResources):
1648 * inspector/front-end/utilities.js:
1651 2011-09-28 Kentaro Hara <haraken@chromium.org>
1653 Implement a PopStateEvent constructor for V8
1654 https://bugs.webkit.org/show_bug.cgi?id=68896
1656 Reviewed by Adam Barth.
1658 Test: fast/events/constructors/pop-state-event-constructor.html
1660 * bindings/v8/custom/V8EventConstructors.cpp: Added a PopStateEvent constructor.
1661 * dom/PopStateEvent.idl: Added a 'V8CustomConstructor' attribute.
1663 2011-09-28 No'am Rosenthal <noam.rosenthal@nokia.com>
1665 [Texmap] Allow TextureMapperGL to work without a GraphicsContext
1666 https://bugs.webkit.org/show_bug.cgi?id=68980
1668 Reviewed by Andreas Kling.
1670 Perform a null-check for m_context and initialize that variable.
1671 If a graphics-context doesn't exist, we don't need to reset it.
1673 No new functionality so no new tests.
1675 * platform/graphics/opengl/TextureMapperGL.cpp:
1676 (WebCore::TextureMapperGL::TextureMapperGL):
1677 (WebCore::TextureMapperGL::beginPainting):
1678 (WebCore::TextureMapperGL::endPainting):
1680 2011-09-28 Kentaro Hara <haraken@chromium.org>
1682 Implement an ErrorEvent constructor for V8
1683 https://bugs.webkit.org/show_bug.cgi?id=68336
1685 Reviewed by Adam Barth.
1687 Test: fast/events/constructors/error-event-constructor.html
1689 * bindings/v8/OptionsObject.cpp:
1690 (WebCore::OptionsObject::getKeyValue): Returns an unsigned value corresponding to a given key.
1691 * bindings/v8/OptionsObject.h:
1692 * bindings/v8/custom/V8EventConstructors.cpp: Added the ErrorEvent constructor.
1693 * dom/ErrorEvent.idl: Added a 'V8CustomConstructor' attribute.
1695 2011-09-27 Andy Estes <aestes@apple.com>
1697 WebKitLinkedOnOrAfter() check is ineffective for Solar Walk app-specific hack.
1698 https://bugs.webkit.org/show_bug.cgi?id=68863
1700 Reviewed by Darin Adler.
1702 The SolarWalk binary does not link against WebKit.framework directly,
1703 so calling NSVersionOfLinkTimeLibrary() will not return the version of
1704 WebKit against which SolarWalk was linked. Since Solar Walk has
1705 released an update that addresses the issue for which this app-specific
1706 hack was originally added, we should just remove the hack.
1708 * WebCore.exp.in: Remove applicationIsSolarWalkMac().
1709 * platform/RuntimeApplicationChecks.cpp: Ditto.
1710 * platform/RuntimeApplicationChecks.h: Ditto.
1712 2011-09-28 Tim Horton <timothy_horton@apple.com>
1714 Fix potential SVG performance regression (over-invalidation of caches) from 96052
1715 https://bugs.webkit.org/show_bug.cgi?id=68941
1716 <rdar://problem/10196224>
1718 Reviewed by Zoltan Herczeg.
1720 Only invalidate the cache of a filter when target style changes, as of the different types of cached
1721 resources, only filters make use of the style of the target element and thus need to be invalidated
1722 when the target style changes.
1724 No new tests, performance improvement.
1726 * rendering/svg/SVGResourcesCache.cpp:
1727 (WebCore::SVGResourcesCache::clientUpdatedFromElement):
1729 2011-09-28 Adenilson Cavalcanti <adenilson.silva@openbossa.org>
1731 Missing initialization of member in ImageFrameQt class
1732 https://bugs.webkit.org/show_bug.cgi?id=68943
1734 Reviewed by Kenneth Rohde Christiansen.
1736 No new tests, this fixes internal implementation detail.
1738 * platform/image-decoders/qt/ImageFrameQt.cpp:
1739 (WebCore::ImageFrame::ImageFrame):
1740 (WebCore::ImageFrame::operator=):
1742 2011-09-27 Luke Macpherson <macpherson@chromium.org>
1744 Defer call to CSSValue::isPrimitiveValue(), saves ~4% in CSSStyleSelector::applyProperty().
1745 https://bugs.webkit.org/show_bug.cgi?id=68964
1747 Reviewed by Eric Seidel.
1749 No new tests / no functionality changed.
1751 Doing value->isPrimitiveValue() is relatviely expensive, so moving it after the early returns but
1752 before the result is used saves a significant number of cycles. (Tested with Shark profiler in Safari).
1754 * css/CSSStyleSelector.cpp:
1755 (WebCore::CSSStyleSelector::applyProperty):
1757 2011-09-27 Ryosuke Niwa <rniwa@webkit.org>
1759 Simplify ReplaceSelectionCommand::positionAtStartOfInsertedContent
1760 https://bugs.webkit.org/show_bug.cgi?id=68939
1762 Reviewed by Darin Adler.
1764 Simplified ReplaceSelectionCommand::positionAtStartOfInsertedContent.
1766 This change revealed a bug in removeUnrenderedTextNodesAtEnds that text nodes without any visible
1767 text at ends are not removed when it has a render object. Fixed the bug by checking the length of
1768 the rendered text. (Tested by editing/pasteboard/pasting-word-in-div-extra-line.html)
1770 This further revealed that caretMaxRenderedOffset doesn't return an offset and caretMaxRenderedOffset
1771 on InlineBox, InlineTextBox, RenderObject, RenderBR, RenderPlaced are never called. To address this
1772 issue, renamed caretMaxRenderedOffset to renderedTextLength for RenderText and removed the rest.
1775 (WebCore::Position::rendersInDifferentPosition):
1776 * editing/ReplaceSelectionCommand.cpp:
1777 (WebCore::nodeHasVisibleRenderText): Added.
1778 (WebCore::ReplaceSelectionCommand::removeUnrenderedTextNodesAtEnds): Calls nodeHasVisibleRenderText.
1779 (WebCore::ReplaceSelectionCommand::positionAtStartOfInsertedContent): Simplified.
1780 * editing/visible_units.cpp:
1781 (WebCore::startOfParagraph): Calls renderedTextLength.
1782 (WebCore::endOfParagraph): Ditto.
1783 * rendering/InlineBox.cpp: Removed caretMaxRenderedOffset.
1784 * rendering/InlineBox.h: Ditto.
1785 * rendering/InlineTextBox.cpp: Ditto.
1786 * rendering/InlineTextBox.h: Ditto.
1787 * rendering/RenderBR.cpp: Ditto.
1788 * rendering/RenderBR.h: Ditto.
1789 * rendering/RenderObject.cpp: Ditto.
1790 * rendering/RenderObject.h: Ditto.
1791 * rendering/RenderReplaced.cpp: Ditto.
1792 * rendering/RenderReplaced.h: Ditto.
1793 * rendering/RenderText.cpp:
1794 (WebCore::RenderText::renderedTextLength): Renamed from caretMaxRenderedOffset.
1795 * rendering/RenderText.h:
1797 2011-09-27 James Robinson <jamesr@chromium.org>
1799 [chromium] LayerRenderChromium asserts about leaking textures.
1800 https://bugs.webkit.org/show_bug.cgi?id=68190
1802 Reviewed by Kenneth Russell.
1804 This introduces an interface TextureAllocator that the TextureManager uses to allocate/deallocate textures.
1805 This means that TextureManager does not need to depend directly on GraphicsContext3D, other than for the format
1806 enum type, making it more testable. It also allows us to track the allocations by subclassing TextureAllocator
1807 to make sure we aren't leaking any textures.
1810 * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
1811 (WebCore::Canvas2DLayerChromium::updateCompositorResources):
1812 * platform/graphics/chromium/Canvas2DLayerChromium.h:
1813 * platform/graphics/chromium/ImageLayerChromium.cpp:
1814 (WebCore::ImageLayerTextureUpdater::updateTextureRect):
1815 * platform/graphics/chromium/LayerChromium.h:
1816 (WebCore::LayerChromium::updateCompositorResources):
1817 * platform/graphics/chromium/LayerRendererChromium.cpp:
1818 (WebCore::LayerRendererChromium::LayerRendererChromium):
1819 (WebCore::LayerRendererChromium::releaseRenderSurfaceTextures):
1820 (WebCore::LayerRendererChromium::drawLayers):
1821 (WebCore::LayerRendererChromium::useRenderSurface):
1822 (WebCore::LayerRendererChromium::initializeSharedObjects):
1823 (WebCore::LayerRendererChromium::cleanupSharedObjects):
1824 * platform/graphics/chromium/LayerRendererChromium.h:
1825 (WebCore::LayerRendererChromium::renderSurfaceTextureAllocator):
1826 (WebCore::LayerRendererChromium::contentsTextureAllocator):
1827 * platform/graphics/chromium/LayerTextureUpdater.h:
1828 * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
1829 (WebCore::LayerTextureUpdaterBitmap::updateTextureRect):
1830 (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
1831 * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
1832 * platform/graphics/chromium/ManagedTexture.cpp:
1833 (WebCore::ManagedTexture::bindTexture):
1834 (WebCore::ManagedTexture::framebufferTexture2D):
1835 * platform/graphics/chromium/ManagedTexture.h:
1836 * platform/graphics/chromium/TextureManager.cpp:
1837 (WebCore::TextureManager::memoryUseBytes):
1838 (WebCore::TextureManager::deleteEvictedTextures):
1839 (WebCore::TextureManager::evictAndDeleteAllTextures):
1840 (WebCore::TextureManager::removeTexture):
1841 (WebCore::TextureManager::allocateTexture):
1842 (WebCore::TextureManager::requestTexture):
1843 * platform/graphics/chromium/TextureManager.h:
1844 (WebCore::TextureAllocator::~TextureAllocator):
1845 * platform/graphics/chromium/TiledLayerChromium.cpp:
1846 (WebCore::TiledLayerChromium::updateCompositorResources):
1847 * platform/graphics/chromium/TiledLayerChromium.h:
1848 * platform/graphics/chromium/TrackingTextureAllocator.cpp: Added.
1849 (WebCore::TrackingTextureAllocator::TrackingTextureAllocator):
1850 (WebCore::TrackingTextureAllocator::~TrackingTextureAllocator):
1851 (WebCore::TrackingTextureAllocator::createTexture):
1852 (WebCore::TrackingTextureAllocator::deleteTexture):
1853 * platform/graphics/chromium/TrackingTextureAllocator.h: Copied from Source/WebCore/platform/graphics/chromium/ManagedTexture.h.
1854 (WebCore::TrackingTextureAllocator::create):
1855 (WebCore::TrackingTextureAllocator::currentMemoryUseBytes):
1856 * platform/graphics/chromium/VideoLayerChromium.cpp:
1857 (WebCore::VideoLayerChromium::updateCompositorResources):
1858 (WebCore::VideoLayerChromium::updateTexture):
1859 * platform/graphics/chromium/VideoLayerChromium.h:
1860 * platform/graphics/chromium/WebGLLayerChromium.cpp:
1861 (WebCore::WebGLLayerChromium::updateCompositorResources):
1862 * platform/graphics/chromium/WebGLLayerChromium.h:
1863 * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
1864 (WebCore::CCHeadsUpDisplay::draw):
1865 * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
1866 (WebCore::CCLayerTreeHost::~CCLayerTreeHost):
1867 (WebCore::CCLayerTreeHost::deleteContentsTexturesOnCCThread):
1868 (WebCore::CCLayerTreeHost::commitToOnCCThread):
1869 (WebCore::CCLayerTreeHost::didRecreateGraphicsContext):
1870 (WebCore::CCLayerTreeHost::updateCompositorResources):
1871 * platform/graphics/chromium/cc/CCLayerTreeHost.h:
1872 * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1873 (WebCore::CCLayerTreeHostImpl::contentsTextureAllocator):
1874 (WebCore::CCLayerTreeHostImpl::initializeLayerRenderer):
1875 * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
1876 * platform/graphics/chromium/cc/CCRenderSurface.cpp:
1877 (WebCore::CCRenderSurface::drawSurface):
1878 * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
1879 (WebCore::CCSingleThreadProxy::setNeedsCommit):
1880 (WebCore::CCSingleThreadProxy::stop):
1881 (WebCore::CCSingleThreadProxy::recreateContextIfNeeded):
1882 (WebCore::CCSingleThreadProxy::commitIfNeeded):
1883 * platform/graphics/chromium/cc/CCThreadProxy.cpp:
1884 (WebCore::CCThreadProxy::commitOnCCThread):
1885 (WebCore::CCThreadProxy::layerTreeHostClosedOnCCThread):
1886 2011-09-27 James Robinson <jamesr@chromium.org>
1888 [chromium] Only initiate the beginFrameAndCommit sequence if a commit has been requested
1889 https://bugs.webkit.org/show_bug.cgi?id=68967
1891 Reviewed by Kenneth Russell.
1893 When updating the scheduler state, we should only initiate a new commit flow if a commit has been requested (as
1894 opposed to only a redraw).
1896 Covered by the unit test CCLayerTreeHostTestSetNeedsRedraw with USE(THREADED_COMPOSITING) set to true.
1898 * platform/graphics/chromium/cc/CCThreadProxy.cpp:
1899 (WebCore::CCThreadProxy::updateSchedulerStateOnCCThread):
1901 2011-09-27 Kentaro Hara <haraken@chromium.com>
1903 Implement a PageTransitionEvent constructor for V8
1904 https://bugs.webkit.org/show_bug.cgi?id=68067
1906 Reviewed by Adam Barth.
1908 Test: fast/events/constructors/page-transition-event-constructor.html
1910 * bindings/v8/custom/V8EventConstructors.cpp: Added the PageTransitionEvent constructor.
1911 * dom/PageTransitionEvent.idl: Added a 'V8CustomConstructor' attribute.
1913 2011-09-27 Kentaro Hara <haraken@chromium.org>
1915 Implement a MessageEvent constructor for JSC
1916 https://bugs.webkit.org/show_bug.cgi?id=68883
1918 Reviewed by Adam Barth.
1920 The spec for MessageEvent is here:
1921 http://www.whatwg.org/specs/web-apps/current-work/#messageevent
1923 Currently, some tests in fast/events/constructors/message-event-constructor.html
1924 are failing or crashing in DRT, as we commented in the test file.
1925 This is because MessageEvent.data is implemented as SerializedScriptValue,
1926 and thus it cannot keep ScriptValue passed by JavaScript.
1927 This is the same issue as the bug (https://bugs.webkit.org/show_bug.cgi?id=68345).
1928 We will soon make a follow-up patch to fix these failures, after this
1931 Test: fast/events/constructors/message-event-constructor.html
1933 * bindings/generic/EventConstructors.h: Added a definition for the MessageEvent constructor.
1934 * bindings/js/JSDictionary.cpp:
1935 (WebCore::JSDictionary::convertValue): Generates MessagePortArray from the list of message ports in the format of JSValues.
1936 * bindings/js/JSDictionary.h:
1937 * bindings/js/JSEventConstructors.cpp: Added #includes for MessageEvent.
1938 * dom/MessageEvent.cpp:
1939 (WebCore::MessageEventInit::MessageEventInit):
1940 (WebCore::MessageEvent::MessageEvent):
1941 (WebCore::MessageEvent::initMessageEvent):
1942 * dom/MessageEvent.h: Added a definition for MessageEvent. Removed an extra leading spaces.
1943 (WebCore::MessageEvent::create):
1944 (WebCore::MessageEvent::origin):
1945 (WebCore::MessageEvent::lastEventId):
1946 (WebCore::MessageEvent::source):
1947 (WebCore::MessageEvent::ports):
1948 (WebCore::MessageEvent::dataType):
1949 (WebCore::MessageEvent::dataAsSerializedScriptValue):
1950 (WebCore::MessageEvent::dataAsString):
1951 (WebCore::MessageEvent::dataAsBlob):
1952 (WebCore::MessageEvent::dataAsArrayBuffer):
1953 * dom/MessageEvent.idl: Makes MessageEvent constructible.
1955 2011-09-27 Eric Uhrhane <ericu@chromium.org>
1957 [Chromium/FileWriter] race condition in FileWriter completion can lead to assert
1958 https://bugs.webkit.org/show_bug.cgi?id=67684
1960 Reviewed by David Levin.
1962 Tests: fast/filesystem/file-writer-abort-continue.html
1963 fast/filesystem/file-writer-abort.html
1965 Track the state of the backend and be prepared for reentrant user
1966 requests. Limit recursion depth to an arbitrary small constant.
1967 * fileapi/FileWriter.cpp: Lots of event-handling changes.
1968 * fileapi/FileWriter.h:
1970 2011-09-27 Mihai Parparita <mihaip@chromium.org>
1972 Unreviewed, rolling out r96141.
1973 http://trac.webkit.org/changeset/96141
1974 https://bugs.webkit.org/show_bug.cgi?id=68190
1976 Breaks PrerenderBrowserTest.PrerenderHTML5Video in
1980 * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
1981 (WebCore::Canvas2DLayerChromium::updateCompositorResources):
1982 * platform/graphics/chromium/Canvas2DLayerChromium.h:
1983 * platform/graphics/chromium/ImageLayerChromium.cpp:
1984 (WebCore::ImageLayerTextureUpdater::updateTextureRect):
1985 * platform/graphics/chromium/LayerChromium.h:
1986 (WebCore::LayerChromium::updateCompositorResources):
1987 * platform/graphics/chromium/LayerRendererChromium.cpp:
1988 (WebCore::LayerRendererChromium::LayerRendererChromium):
1989 (WebCore::LayerRendererChromium::releaseRenderSurfaceTextures):
1990 (WebCore::LayerRendererChromium::drawLayers):
1991 (WebCore::LayerRendererChromium::createLayerTexture):
1992 (WebCore::LayerRendererChromium::deleteLayerTexture):
1993 (WebCore::LayerRendererChromium::useRenderSurface):
1994 (WebCore::LayerRendererChromium::initializeSharedObjects):
1995 (WebCore::LayerRendererChromium::cleanupSharedObjects):
1996 * platform/graphics/chromium/LayerRendererChromium.h:
1997 (WebCore::LayerRendererChromium::setContentsTextureMemoryUseBytes):
1998 * platform/graphics/chromium/LayerTextureUpdater.h:
1999 * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
2000 (WebCore::LayerTextureUpdaterBitmap::updateTextureRect):
2001 (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
2002 * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
2003 * platform/graphics/chromium/ManagedTexture.cpp:
2004 (WebCore::ManagedTexture::bindTexture):
2005 (WebCore::ManagedTexture::framebufferTexture2D):
2006 * platform/graphics/chromium/ManagedTexture.h:
2007 * platform/graphics/chromium/TextureManager.cpp:
2008 (WebCore::memoryUseBytes):
2009 (WebCore::TextureManager::deleteEvictedTextures):
2010 (WebCore::TextureManager::evictAndDeleteAllTextures):
2011 (WebCore::TextureManager::removeTexture):
2012 (WebCore::TextureManager::allocateTexture):
2013 (WebCore::TextureManager::requestTexture):
2014 * platform/graphics/chromium/TextureManager.h:
2015 * platform/graphics/chromium/TiledLayerChromium.cpp:
2016 (WebCore::TiledLayerChromium::updateCompositorResources):
2017 * platform/graphics/chromium/TiledLayerChromium.h:
2018 * platform/graphics/chromium/TrackingTextureAllocator.cpp: Removed.
2019 * platform/graphics/chromium/TrackingTextureAllocator.h: Removed.
2020 * platform/graphics/chromium/VideoLayerChromium.cpp:
2021 (WebCore::VideoLayerChromium::updateCompositorResources):
2022 (WebCore::VideoLayerChromium::updateTexture):
2023 * platform/graphics/chromium/VideoLayerChromium.h:
2024 * platform/graphics/chromium/WebGLLayerChromium.cpp:
2025 (WebCore::WebGLLayerChromium::updateCompositorResources):
2026 * platform/graphics/chromium/WebGLLayerChromium.h:
2027 * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
2028 (WebCore::CCHeadsUpDisplay::draw):
2029 * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2030 (WebCore::CCLayerTreeHost::~CCLayerTreeHost):
2031 (WebCore::CCLayerTreeHost::deleteContentsTextures):
2032 (WebCore::CCLayerTreeHost::commitTo):
2033 (WebCore::CCLayerTreeHost::didRecreateGraphicsContext):
2034 (WebCore::CCLayerTreeHost::updateCompositorResources):
2035 * platform/graphics/chromium/cc/CCLayerTreeHost.cpp.rej: Removed.
2036 * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2037 * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2038 (WebCore::CCLayerTreeHostImpl::initializeLayerRenderer):
2039 * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
2040 * platform/graphics/chromium/cc/CCRenderSurface.cpp:
2041 (WebCore::CCRenderSurface::drawSurface):
2042 * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
2043 (WebCore::CCSingleThreadProxy::setNeedsCommit):
2044 (WebCore::CCSingleThreadProxy::stop):
2045 (WebCore::CCSingleThreadProxy::recreateContextIfNeeded):
2046 (WebCore::CCSingleThreadProxy::commitIfNeeded):
2047 * platform/graphics/chromium/cc/CCThreadProxy.cpp:
2048 (WebCore::CCThreadProxy::commitOnCCThread):
2049 (WebCore::CCThreadProxy::layerTreeHostClosedOnCCThread):
2051 2011-09-27 James Robinson <jamesr@chromium.org>
2053 [chromium] Guard accelerated skia drawing logic with its own define to remove dependency on USE(THREADED_COMPOSITING)
2054 https://bugs.webkit.org/show_bug.cgi?id=68953
2056 Reviewed by Kenneth Russell.
2058 The accelerated drawing code is incompatible with threaded compositing. Rather than tying the two behaviors
2059 together via USE(THREADED_COMPOSITING), this patch guards the accelerated drawing code with its own USE() guard
2060 so the features can advance independently. Today, it's not safe to set both of these flags.
2062 * platform/graphics/chromium/ContentLayerChromium.cpp:
2063 (WebCore::ContentLayerChromium::createTextureUpdater):
2064 * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
2065 * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
2067 2011-09-27 Luke Macpherson <macpherson@chromium.org>
2069 Slightly improve performance of CSSStyleApplyProperty handler lookup.
2070 https://bugs.webkit.org/show_bug.cgi?id=68868
2072 Reviewed by Eric Seidel.
2074 No new tests as no functionality changed.
2076 * css/CSSStyleApplyProperty.h:
2077 (WebCore::CSSStyleApplyProperty::propertyHandler):
2078 Make propertyHandler() public and remove redirecting functions.
2079 * css/CSSStyleSelector.cpp:
2080 (WebCore::CSSStyleSelector::applyProperty):
2081 Perform property handler lookup once and reuse the result.
2083 2011-09-27 Kent Tamura <tkent@chromium.org>
2085 [V8] element.dataset.nonExistingKey should return undefined.
2086 https://bugs.webkit.org/show_bug.cgi?id=68877
2088 Reviewed by Nate Chapin.
2090 * bindings/v8/custom/V8DOMStringMapCustom.cpp:
2091 (WebCore::V8DOMStringMap::namedPropertyGetter): Uses v8StringOrUndefined() instead of v8String().
2093 2011-09-23 Mark Hahnenberg <mhahnenberg@apple.com>
2095 Add static version of JSCell::visitChildren
2096 https://bugs.webkit.org/show_bug.cgi?id=68404
2098 Reviewed by Darin Adler.
2102 In this patch we just extract the bodies of the virtual visitChildren methods
2103 throughout the JSCell inheritance hierarchy out into static methods, which are
2104 now called from the virtual methods. This is an intermediate step in trying to
2105 move the virtual-ness of visitChildren into our own custom vtable stored in
2106 ClassInfo. We need to convert the methods to static methods in order to be
2107 able to more easily store and refer to them in our custom vtable since normal
2108 member methods store some implicit information in their types, making it
2109 impossible to store them generically in ClassInfo.
2112 * bindings/js/JSAttrCustom.cpp:
2113 (WebCore::JSAttr::visitChildrenVirtual):
2114 (WebCore::JSAttr::visitChildren):
2115 * bindings/js/JSAudioContextCustom.cpp:
2116 (WebCore::JSAudioContext::visitChildrenVirtual):
2117 (WebCore::JSAudioContext::visitChildren):
2118 * bindings/js/JSCSSRuleCustom.cpp:
2119 (WebCore::JSCSSRule::visitChildrenVirtual):
2120 (WebCore::JSCSSRule::visitChildren):
2121 * bindings/js/JSCSSStyleDeclarationCustom.cpp:
2122 (WebCore::JSCSSStyleDeclaration::visitChildrenVirtual):
2123 (WebCore::JSCSSStyleDeclaration::visitChildren):
2124 * bindings/js/JSCanvasRenderingContextCustom.cpp:
2125 (WebCore::JSCanvasRenderingContext::visitChildrenVirtual):
2126 (WebCore::JSCanvasRenderingContext::visitChildren):
2127 * bindings/js/JSDOMGlobalObject.cpp:
2128 (WebCore::JSDOMGlobalObject::visitChildrenVirtual):
2129 (WebCore::JSDOMGlobalObject::visitChildren):
2130 * bindings/js/JSDOMGlobalObject.h:
2131 * bindings/js/JSDOMWindowCustom.cpp:
2132 (WebCore::JSDOMWindow::visitChildrenVirtual):
2133 (WebCore::JSDOMWindow::visitChildren):
2134 * bindings/js/JSDOMWindowShell.cpp:
2135 (WebCore::JSDOMWindowShell::visitChildrenVirtual):
2136 (WebCore::JSDOMWindowShell::visitChildren):
2137 * bindings/js/JSDOMWindowShell.h:
2138 * bindings/js/JSJavaScriptAudioNodeCustom.cpp:
2139 (WebCore::JSJavaScriptAudioNode::visitChildrenVirtual):
2140 (WebCore::JSJavaScriptAudioNode::visitChildren):
2141 * bindings/js/JSMessageChannelCustom.cpp:
2142 (WebCore::JSMessageChannel::visitChildrenVirtual):
2143 (WebCore::JSMessageChannel::visitChildren):
2144 * bindings/js/JSMessagePortCustom.cpp:
2145 (WebCore::JSMessagePort::visitChildrenVirtual):
2146 (WebCore::JSMessagePort::visitChildren):
2147 * bindings/js/JSNamedNodeMapCustom.cpp:
2148 (WebCore::JSNamedNodeMap::visitChildrenVirtual):
2149 (WebCore::JSNamedNodeMap::visitChildren):
2150 * bindings/js/JSNodeCustom.cpp:
2151 (WebCore::JSNode::visitChildrenVirtual):
2152 (WebCore::JSNode::visitChildren):
2153 * bindings/js/JSNodeFilterCustom.cpp:
2154 (WebCore::JSNodeFilter::visitChildrenVirtual):
2155 (WebCore::JSNodeFilter::visitChildren):
2156 * bindings/js/JSNodeIteratorCustom.cpp:
2157 (WebCore::JSNodeIterator::visitChildrenVirtual):
2158 (WebCore::JSNodeIterator::visitChildren):
2159 * bindings/js/JSSVGElementInstanceCustom.cpp:
2160 (WebCore::JSSVGElementInstance::visitChildrenVirtual):
2161 (WebCore::JSSVGElementInstance::visitChildren):
2162 * bindings/js/JSSharedWorkerCustom.cpp:
2163 (WebCore::JSSharedWorker::visitChildrenVirtual):
2164 (WebCore::JSSharedWorker::visitChildren):
2165 * bindings/js/JSStyleSheetCustom.cpp:
2166 (WebCore::JSStyleSheet::visitChildrenVirtual):
2167 (WebCore::JSStyleSheet::visitChildren):
2168 * bindings/js/JSTreeWalkerCustom.cpp:
2169 (WebCore::JSTreeWalker::visitChildrenVirtual):
2170 (WebCore::JSTreeWalker::visitChildren):
2171 * bindings/js/JSWebGLRenderingContextCustom.cpp:
2172 (WebCore::JSWebGLRenderingContext::visitChildrenVirtual):
2173 (WebCore::JSWebGLRenderingContext::visitChildren):
2174 * bindings/js/JSWorkerContextCustom.cpp:
2175 (WebCore::JSWorkerContext::visitChildrenVirtual):
2176 (WebCore::JSWorkerContext::visitChildren):
2177 * bindings/js/JSXMLHttpRequestCustom.cpp:
2178 (WebCore::JSXMLHttpRequest::visitChildrenVirtual):
2179 (WebCore::JSXMLHttpRequest::visitChildren):
2180 * bindings/js/JSXPathResultCustom.cpp:
2181 (WebCore::JSXPathResult::visitChildrenVirtual):
2182 (WebCore::JSXPathResult::visitChildren):
2183 * bindings/scripts/CodeGeneratorJS.pm:
2185 (GenerateImplementation):
2186 * bindings/scripts/test/JS/JSTestObj.cpp:
2187 (WebCore::JSTestObj::visitChildrenVirtual):
2188 (WebCore::JSTestObj::visitChildren):
2189 * bindings/scripts/test/JS/JSTestObj.h:
2190 * bridge/qt/qt_instance.cpp:
2191 (JSC::Bindings::QtRuntimeObject::visitChildrenVirtual):
2192 (JSC::Bindings::QtRuntimeObject::visitChildren):
2193 * bridge/qt/qt_runtime.cpp:
2194 (JSC::Bindings::QtRuntimeMetaMethod::visitChildrenVirtual):
2195 (JSC::Bindings::QtRuntimeMetaMethod::visitChildren):
2196 * bridge/qt/qt_runtime.h:
2197 * workers/WorkerContext.h:
2200 2011-09-27 Mark Hahnenberg <mhahnenberg@apple.com>
2202 Add static version of JSCell::getCallData
2203 https://bugs.webkit.org/show_bug.cgi?id=68741
2205 Reviewed by Darin Adler.
2209 In this patch we just extract the bodies of the virtual getCallData methods
2210 throughout the JSCell inheritance hierarchy out into static methods, which are
2211 now called from the virtual methods. This is an intermediate step in trying to
2212 move the virtual-ness of getCallData into our own method table stored in
2213 ClassInfo. We need to convert the methods to static methods because static methods
2214 can be represented as function pointers rather than pointers to member functions, and
2215 function pointers are smaller and faster to call than pointers to member functions.
2218 * bindings/js/JSCallbackData.cpp:
2219 (WebCore::JSCallbackData::invokeCallback):
2220 * bindings/js/JSCustomXPathNSResolver.cpp:
2221 (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
2222 * bindings/js/JSErrorHandler.cpp:
2223 (WebCore::JSErrorHandler::handleEvent):
2224 * bindings/js/JSEventListener.cpp:
2225 (WebCore::JSEventListener::handleEvent):
2226 * bindings/js/JSHTMLAllCollectionCustom.cpp:
2227 (WebCore::JSHTMLAllCollection::getCallDataVirtual):
2228 (WebCore::JSHTMLAllCollection::getCallData):
2229 * bindings/js/JSHTMLAppletElementCustom.cpp:
2230 (WebCore::JSHTMLAppletElement::getCallDataVirtual):
2231 (WebCore::JSHTMLAppletElement::getCallData):
2232 * bindings/js/JSHTMLEmbedElementCustom.cpp:
2233 (WebCore::JSHTMLEmbedElement::getCallDataVirtual):
2234 (WebCore::JSHTMLEmbedElement::getCallData):
2235 * bindings/js/JSHTMLObjectElementCustom.cpp:
2236 (WebCore::JSHTMLObjectElement::getCallDataVirtual):
2237 (WebCore::JSHTMLObjectElement::getCallData):
2238 * bindings/js/JSInjectedScriptHostCustom.cpp:
2239 (WebCore::JSInjectedScriptHost::evaluate):
2240 * bindings/js/JSPluginElementFunctions.cpp:
2241 (WebCore::runtimeObjectGetCallData):
2242 * bindings/scripts/CodeGeneratorJS.pm:
2244 * bridge/objc/objc_runtime.h:
2245 * bridge/objc/objc_runtime.mm:
2246 (JSC::Bindings::ObjcFallbackObjectImp::getCallDataVirtual):
2247 (JSC::Bindings::ObjcFallbackObjectImp::getCallData):
2248 * bridge/qt/qt_runtime.cpp:
2249 (JSC::Bindings::QtRuntimeMetaMethod::getCallDataVirtual):
2250 (JSC::Bindings::QtRuntimeMetaMethod::getCallData):
2251 (JSC::Bindings::QtRuntimeConnectionMethod::call):
2252 (JSC::Bindings::QtRuntimeConnectionMethod::getCallDataVirtual):
2253 (JSC::Bindings::QtRuntimeConnectionMethod::getCallData):
2254 (JSC::Bindings::isJavaScriptFunction):
2255 * bridge/qt/qt_runtime.h:
2256 * bridge/runtime_method.cpp:
2257 (JSC::RuntimeMethod::getCallDataVirtual):
2258 (JSC::RuntimeMethod::getCallData):
2259 * bridge/runtime_method.h:
2260 * bridge/runtime_object.cpp:
2261 (JSC::Bindings::RuntimeObject::getCallDataVirtual):
2262 (JSC::Bindings::RuntimeObject::getCallData):
2263 * bridge/runtime_object.h:
2266 2011-09-27 Dean Jackson <dino@apple.com>
2268 Unreviewed. Remove duplicate FilterOperation{s}.h that were
2269 accidentally added to the top level of the Xcode project.
2271 * WebCore.xcodeproj/project.pbxproj:
2274 2011-09-27 David Hyatt <hyatt@apple.com>
2276 https://bugs.webkit.org/show_bug.cgi?id=68940
2278 Narrow the float/lines pagination heuristic to only kick in if
2279 the previous line broke cleanly and if the floats are occurring
2280 at the start of the line.
2282 Reviewed by Dan Bernstein.
2284 * rendering/RenderBlockLineLayout.cpp:
2285 (WebCore::RenderBlock::positionNewFloatOnLine):
2287 2011-09-27 James Robinson <jamesr@chromium.org>
2289 Add a mechanism to test for the compositing tree mutated during painting
2290 https://bugs.webkit.org/show_bug.cgi?id=68738
2292 Reviewed by Adam Barth.
2294 Sets a static bool during GraphicsLayer::paintGraphicsLayerContents and ASSERT()s that we never create or
2295 destroy a GraphicsLayer inside this function. Painting should never mutate the GraphicsLayer tree.
2297 Test: compositing/video/video-with-invalid-source.html
2299 * platform/graphics/GraphicsLayer.cpp:
2300 (WebCore::GraphicsLayer::GraphicsLayer):
2301 (WebCore::GraphicsLayer::~GraphicsLayer):
2302 (WebCore::GraphicsLayer::paintGraphicsLayerContents):
2304 2011-09-27 Ojan Vafai <ojan@chromium.org>
2306 take padding/border on flexbox into account with direction:rtl
2307 https://bugs.webkit.org/show_bug.cgi?id=68846
2309 Reviewed by David Hyatt.
2311 Use the logicalWidth of the flexbox instead of it's availableLogicalWidth
2312 so that we include the flexbox's border and padding.
2314 Also, change all uses of availableLogicalWidth to contentLogicalWidth.
2315 The former takes multi-column into account. Multi-column flexboxes don't
2316 make any sense, so there's no point in calling availableLogicalWidth.
2318 * rendering/RenderFlexibleBox.cpp:
2319 (WebCore::RenderFlexibleBox::flowAwareLogicalWidth):
2320 (WebCore::RenderFlexibleBox::flowAwareContentLogicalWidth):
2321 (WebCore::RenderFlexibleBox::computePreferredLogicalWidth):
2322 (WebCore::RenderFlexibleBox::runFreeSpaceAllocationAlgorithmInlineDirection):
2323 (WebCore::RenderFlexibleBox::layoutAndPlaceChildrenInlineDirection):
2324 * rendering/RenderFlexibleBox.h:
2326 2011-09-27 Sheriff Bot <webkit.review.bot@gmail.com>
2328 Unreviewed, rolling out r96139.
2329 http://trac.webkit.org/changeset/96139
2330 https://bugs.webkit.org/show_bug.cgi?id=68933
2332 Broke table-percent-height.html on Mac bots (Requested by
2333 mwenge2 on #webkit).
2335 * rendering/RenderBox.cpp:
2336 (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
2337 (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
2338 * rendering/RenderBox.h:
2340 2011-09-27 Tim Horton <timothy_horton@apple.com>
2342 REGRESSION(65665): Pattern size being clamped to SVG size can prevent transformed elements from being fully covered by userSpaceOnUse patterns
2343 https://bugs.webkit.org/show_bug.cgi?id=67700
2344 <rdar://problem/10125102>
2346 Reviewed by Darin Adler.
2348 Clamp all resources to the same size, 4096x4096 (arbitrarily chosen), instead of to the size
2349 of the <svg> element. This fixes the case where a transformed element displays part of a resource
2350 outside of the size of the <svg> element.
2352 When drawing an oversized pattern into its tile image, scale the content down to fit. When drawing
2353 the tile image to the screen, scale it back up to fit the expected area. This will cause pixelation
2354 when patterns are over the 4k limit.
2356 Tests: svg/custom/transformed-pattern-clamp-svg-root.svg, svg/custom/oversized-pattern-scale.svg
2358 * rendering/svg/RenderSVGResourceClipper.cpp:
2359 (WebCore::RenderSVGResourceClipper::applyClippingToContext):
2360 * rendering/svg/RenderSVGResourceGradient.cpp:
2361 (WebCore::createMaskAndSwapContextForTextGradient):
2362 (WebCore::clipToTextMask):
2363 * rendering/svg/RenderSVGResourceMasker.cpp:
2364 (WebCore::RenderSVGResourceMasker::applyResource):
2365 * rendering/svg/RenderSVGResourcePattern.cpp:
2366 (WebCore::RenderSVGResourcePattern::applyResource):
2367 (WebCore::RenderSVGResourcePattern::createTileImage):
2368 * rendering/svg/RenderSVGResourcePattern.h:
2369 * rendering/svg/SVGImageBufferTools.cpp:
2370 (WebCore::SVGImageBufferTools::clampedAbsoluteTargetRect):
2371 * rendering/svg/SVGImageBufferTools.h:
2373 2011-09-27 Dan Bernstein <mitz@apple.com>
2375 <rdar://problem/10098679> Assertion failure in RenderLayer::paintPaginatedChildLayer()
2377 Reviewed by Simon Fraser.
2379 Test: fast/dynamic/layer-no-longer-paginated.html
2381 FrameView::layout() calls adjustViewSize() before calling RenderLayer::updateLayerPositions().
2382 The former may trigger painting with a layer tree that is not entirely up-to-date. Specifically,
2383 the isPaginated() state of a layer may be incorrect, leading to the assertion in this bug. Instead
2384 of asserting, return early and count on the upcoming updateLayerPositions() to repaint as needed.
2386 * rendering/RenderLayer.cpp:
2387 (WebCore::RenderLayer::paintPaginatedChildLayer): Replaced the assertion with an early return.
2389 2011-09-27 Ojan Vafai <ojan@chromium.org>
2391 offsetTop/offsetLeft return the wrong values for horizontal-bt/vertical-rl writing modes
2392 https://bugs.webkit.org/show_bug.cgi?id=68304
2394 Reviewed by David Hyatt.
2396 When grabbing the x/y values of the RenderBox, we need to take writing mode
2397 flipping into account.
2399 Test: fast/dom/offset-position-writing-modes.html
2401 * rendering/RenderBox.cpp:
2402 (WebCore::RenderBox::locationIncludingFlipping):
2403 * rendering/RenderBox.h:
2404 (WebCore::RenderBox::yFlippedForWritingMode):
2405 (WebCore::RenderBox::xFlippedForWritingMode):
2406 * rendering/RenderBoxModelObject.cpp:
2407 (WebCore::RenderBoxModelObject::offsetLeft):
2408 (WebCore::RenderBoxModelObject::offsetTop):
2410 2011-09-27 Tim Horton <timothy_horton@apple.com>
2412 Rapidly refreshing a feMorphology[erode] with r=0 can sometimes cause display corruption
2413 https://bugs.webkit.org/show_bug.cgi?id=68816
2414 <rdar://problem/10186468>
2416 Reviewed by Simon Fraser.
2418 If a filter returns without writing into its result buffer, make sure to return an cleared buffer.
2420 Test: svg/filters/feMorphology-zero-radius.svg
2422 * platform/graphics/filters/FEMorphology.cpp:
2423 (WebCore::FEMorphology::apply):
2424 * platform/graphics/filters/FETurbulence.cpp:
2425 (WebCore::FETurbulence::apply):
2427 2011-09-27 Ryosuke Niwa <rniwa@webkit.org>
2429 CompositeEditCommand::prune should remove subtree at once
2430 https://bugs.webkit.org/show_bug.cgi?id=68866
2432 Reviewed by Darin Adler.
2434 Extracted the logic to find the highest ancestor to remove as highestNodeToRemoveInPruning from prune.
2435 This reduces the number of node removals from O(n) to O(1) where n is the depth of the tree.
2437 * editing/CompositeEditCommand.cpp:
2438 (WebCore::hasARenderedDescendant): Takes excludedNode in addition to node. excludedNode is used to ignore
2439 the child node from which we climbed up the tree in highestNodeToRemoveInPruning.
2440 (WebCore::highestNodeToRemoveInPruning): Extracted from prune.
2441 (WebCore::CompositeEditCommand::prune):
2442 (WebCore::CompositeEditCommand::breakOutOfEmptyMailBlockquotedParagraph):
2444 2011-09-27 David Hyatt <hyatt@apple.com>
2446 https://bugs.webkit.org/show_bug.cgi?id=68922
2448 Paginated floats should not grow the height of a block when they don't end
2449 up being tied to a line. Floats encountered in skipLeadingWhitespace that
2450 paginate can't immediately grow the height of the block, since there may not
2451 end up being any actual line content. We only want to push the height of the
2452 block down if we have actual line content that we want to keep with the
2455 Make positionNewFloatOnLine check if the line is empty or not, and if it is,
2456 it just puts the desired pagination strut into LineInfo. If and when actual
2457 line content is encountered and setEmpty becomes false, we'll grow the block
2460 Reviewed by Dan Bernstein.
2462 Added fast/multicol/float-paginate-empty-lines.html and
2463 fast/regions/webkit-flow-double-pagination-float-push.html.
2465 * rendering/RenderBlock.h:
2466 * rendering/RenderBlockLineLayout.cpp:
2467 (WebCore::LineWidth::LineWidth):
2468 (WebCore::LineWidth::fitsOnLine):
2469 (WebCore::LineWidth::currentWidth):
2470 (WebCore::LineWidth::uncommittedWidth):
2471 (WebCore::LineWidth::committedWidth):
2472 (WebCore::LineWidth::availableWidth):
2473 (WebCore::LineWidth::addUncommittedWidth):
2474 (WebCore::LineWidth::commit):
2475 (WebCore::LineWidth::computeAvailableWidthFromLeftAndRight):
2476 (WebCore::LineWidth::updateAvailableWidth):
2477 (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
2478 (WebCore::LineWidth::applyOverhang):
2479 (WebCore::LineWidth::fitBelowFloats):
2480 (WebCore::LineInfo::LineInfo):
2481 (WebCore::LineInfo::floatPaginationStrut):
2482 (WebCore::LineInfo::setEmpty):
2483 (WebCore::LineInfo::setFloatPaginationStrut):
2484 (WebCore::RenderBlock::LineBreaker::skipLeadingWhitespace):
2485 (WebCore::RenderBlock::LineBreaker::nextLineBreak):
2486 (WebCore::RenderBlock::positionNewFloatOnLine):
2488 2011-09-27 Dean Jackson <dino@apple.com>
2490 Add 'filter' value to RenderStyle
2491 https://bugs.webkit.org/show_bug.cgi?id=68471
2493 Reviewed by Simon Fraser.
2495 Add a filter property to RenderStyle when ENABLE(CSS_FILTERS)
2496 is turned on. Similar to -webkit-transform, -webkit-filter is a
2497 list of FilterOperations, each identifying what type of operation
2498 it is. This change simply adds the basic objects, it does not
2499 parse the property to generate the list.
2502 * GNUmakefile.list.am:
2505 * WebCore.vcproj/WebCore.vcproj:
2506 * WebCore.xcodeproj/project.pbxproj:
2507 * platform/graphics/filters/FilterOperation.h: Added.
2508 (WebCore::FilterOperation::~FilterOperation):
2509 (WebCore::FilterOperation::operator!=):
2510 (WebCore::FilterOperation::getOperationType):
2511 (WebCore::FilterOperation::isSameType):
2512 (WebCore::FilterOperation::FilterOperation):
2513 (WebCore::ReferenceFilterOperation::create):
2514 (WebCore::ReferenceFilterOperation::reference):
2515 (WebCore::ReferenceFilterOperation::operator==):
2516 (WebCore::ReferenceFilterOperation::ReferenceFilterOperation):
2517 (WebCore::BasicColorMatrixFilterOperation::create):
2518 (WebCore::BasicColorMatrixFilterOperation::amount):
2519 (WebCore::BasicColorMatrixFilterOperation::operator==):
2520 (WebCore::BasicColorMatrixFilterOperation::BasicColorMatrixFilterOperation):
2521 (WebCore::BasicComponentTransferFilterOperation::create):
2522 (WebCore::BasicComponentTransferFilterOperation::amount):
2523 (WebCore::BasicComponentTransferFilterOperation::operator==):
2524 (WebCore::BasicComponentTransferFilterOperation::BasicComponentTransferFilterOperation):
2525 (WebCore::GammaFilterOperation::create):
2526 (WebCore::GammaFilterOperation::amplitude):
2527 (WebCore::GammaFilterOperation::exponent):
2528 (WebCore::GammaFilterOperation::offset):
2529 (WebCore::GammaFilterOperation::operator==):
2530 (WebCore::GammaFilterOperation::GammaFilterOperation):
2531 (WebCore::BlurFilterOperation::create):
2532 (WebCore::BlurFilterOperation::stdDeviationX):
2533 (WebCore::BlurFilterOperation::stdDeviationY):
2534 (WebCore::BlurFilterOperation::operator==):
2535 (WebCore::BlurFilterOperation::BlurFilterOperation):
2536 (WebCore::SharpenFilterOperation::create):
2537 (WebCore::SharpenFilterOperation::radius):
2538 (WebCore::SharpenFilterOperation::threshold):
2539 (WebCore::SharpenFilterOperation::amount):
2540 (WebCore::SharpenFilterOperation::operator==):
2541 (WebCore::SharpenFilterOperation::SharpenFilterOperation):
2542 (WebCore::DropShadowFilterOperation::create):
2543 (WebCore::DropShadowFilterOperation::shadow):
2544 (WebCore::DropShadowFilterOperation::operator==):
2545 (WebCore::DropShadowFilterOperation::DropShadowFilterOperation):
2546 * platform/graphics/filters/FilterOperations.cpp: Added.
2547 (WebCore::FilterOperations::FilterOperations):
2548 (WebCore::FilterOperations::operator==):
2549 * platform/graphics/filters/FilterOperations.h: Added.
2550 (WebCore::FilterOperations::operator!=):
2551 (WebCore::FilterOperations::clear):
2552 (WebCore::FilterOperations::operations):
2553 (WebCore::FilterOperations::size):
2554 (WebCore::FilterOperations::at):
2555 * rendering/style/RenderStyle.cpp:
2556 (WebCore::RenderStyle::RenderStyle):
2557 * rendering/style/RenderStyle.h:
2558 (WebCore::InheritedFlags::filter):
2559 (WebCore::InheritedFlags::hasFilter):
2560 (WebCore::InheritedFlags::setFilter):
2561 (WebCore::InheritedFlags::initialFilter):
2562 * rendering/style/StyleAllInOne.cpp: Added include of new StyleFilterData.
2563 * rendering/style/StyleFilterData.cpp: Added.
2564 (WebCore::StyleFilterData::StyleFilterData):
2565 (WebCore::StyleFilterData::operator==):
2566 * rendering/style/StyleFilterData.h: Added.
2567 (WebCore::StyleFilterData::create):
2568 (WebCore::StyleFilterData::copy):
2569 (WebCore::StyleFilterData::operator!=):
2570 * rendering/style/StyleRareNonInheritedData.cpp:
2571 (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
2572 (WebCore::StyleRareNonInheritedData::operator==):
2573 * rendering/style/StyleRareNonInheritedData.h: New filter DataRef.
2575 2011-09-27 James Robinson <jamesr@chromium.org>
2577 [chromium] LayerRenderChromium asserts about leaking textures.
2578 https://bugs.webkit.org/show_bug.cgi?id=68190
2580 Reviewed by Kenneth Russell.
2582 This introduces an interface TextureAllocator that the TextureManager uses to allocate/deallocate textures.
2583 This means that TextureManager does not need to depend directly on GraphicsContext3D, other than for the format
2584 enum type, making it more testable. It also allows us to track the allocations by subclassing TextureAllocator
2585 to make sure we aren't leaking any textures.
2588 * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
2589 (WebCore::Canvas2DLayerChromium::updateCompositorResources):
2590 * platform/graphics/chromium/Canvas2DLayerChromium.h:
2591 * platform/graphics/chromium/ImageLayerChromium.cpp:
2592 (WebCore::ImageLayerTextureUpdater::updateTextureRect):
2593 * platform/graphics/chromium/LayerChromium.h:
2594 (WebCore::LayerChromium::updateCompositorResources):
2595 * platform/graphics/chromium/LayerRendererChromium.cpp:
2596 (WebCore::LayerRendererChromium::LayerRendererChromium):
2597 (WebCore::LayerRendererChromium::releaseRenderSurfaceTextures):
2598 (WebCore::LayerRendererChromium::drawLayers):
2599 (WebCore::LayerRendererChromium::useRenderSurface):
2600 (WebCore::LayerRendererChromium::initializeSharedObjects):
2601 (WebCore::LayerRendererChromium::cleanupSharedObjects):
2602 * platform/graphics/chromium/LayerRendererChromium.h:
2603 (WebCore::LayerRendererChromium::renderSurfaceTextureAllocator):
2604 (WebCore::LayerRendererChromium::contentsTextureAllocator):
2605 * platform/graphics/chromium/LayerTextureUpdater.h:
2606 * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
2607 (WebCore::LayerTextureUpdaterBitmap::updateTextureRect):
2608 (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
2609 * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
2610 * platform/graphics/chromium/ManagedTexture.cpp:
2611 (WebCore::ManagedTexture::bindTexture):
2612 (WebCore::ManagedTexture::framebufferTexture2D):
2613 * platform/graphics/chromium/ManagedTexture.h:
2614 * platform/graphics/chromium/TextureManager.cpp:
2615 (WebCore::TextureManager::memoryUseBytes):
2616 (WebCore::TextureManager::deleteEvictedTextures):
2617 (WebCore::TextureManager::evictAndDeleteAllTextures):
2618 (WebCore::TextureManager::removeTexture):
2619 (WebCore::TextureManager::allocateTexture):
2620 (WebCore::TextureManager::requestTexture):
2621 * platform/graphics/chromium/TextureManager.h:
2622 (WebCore::TextureAllocator::~TextureAllocator):
2623 * platform/graphics/chromium/TiledLayerChromium.cpp:
2624 (WebCore::TiledLayerChromium::updateCompositorResources):
2625 * platform/graphics/chromium/TiledLayerChromium.h:
2626 * platform/graphics/chromium/TrackingTextureAllocator.cpp: Added.
2627 (WebCore::TrackingTextureAllocator::TrackingTextureAllocator):
2628 (WebCore::TrackingTextureAllocator::~TrackingTextureAllocator):
2629 (WebCore::TrackingTextureAllocator::createTexture):
2630 (WebCore::TrackingTextureAllocator::deleteTexture):
2631 * platform/graphics/chromium/TrackingTextureAllocator.h: Copied from Source/WebCore/platform/graphics/chromium/ManagedTexture.h.
2632 (WebCore::TrackingTextureAllocator::create):
2633 (WebCore::TrackingTextureAllocator::currentMemoryUseBytes):
2634 * platform/graphics/chromium/VideoLayerChromium.cpp:
2635 (WebCore::VideoLayerChromium::updateCompositorResources):
2636 (WebCore::VideoLayerChromium::updateTexture):
2637 * platform/graphics/chromium/VideoLayerChromium.h:
2638 * platform/graphics/chromium/WebGLLayerChromium.cpp:
2639 (WebCore::WebGLLayerChromium::updateCompositorResources):
2640 * platform/graphics/chromium/WebGLLayerChromium.h:
2641 * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
2642 (WebCore::CCHeadsUpDisplay::draw):
2643 * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2644 (WebCore::CCLayerTreeHost::~CCLayerTreeHost):
2645 (WebCore::CCLayerTreeHost::deleteContentsTexturesOnCCThread):
2646 (WebCore::CCLayerTreeHost::commitToOnCCThread):
2647 (WebCore::CCLayerTreeHost::didRecreateGraphicsContext):
2648 (WebCore::CCLayerTreeHost::updateCompositorResources):
2649 * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2650 * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2651 (WebCore::CCLayerTreeHostImpl::contentsTextureAllocator):
2652 (WebCore::CCLayerTreeHostImpl::initializeLayerRenderer):
2653 * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
2654 * platform/graphics/chromium/cc/CCRenderSurface.cpp:
2655 (WebCore::CCRenderSurface::drawSurface):
2656 * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
2657 (WebCore::CCSingleThreadProxy::setNeedsCommit):
2658 (WebCore::CCSingleThreadProxy::stop):
2659 (WebCore::CCSingleThreadProxy::recreateContextIfNeeded):
2660 (WebCore::CCSingleThreadProxy::commitIfNeeded):
2661 * platform/graphics/chromium/cc/CCThreadProxy.cpp:
2662 (WebCore::CCThreadProxy::commitOnCCThread):
2663 (WebCore::CCThreadProxy::layerTreeHostClosedOnCCThread):
2665 2011-06-28 Robert Hogan <robert@webkit.org>
2667 Reviewed by David Hyatt.
2669 Replaced elements squeezed when width is specified as percentage inside a table with Auto layout
2670 https://bugs.webkit.org/show_bug.cgi?id=29447
2672 If inserting a 'replaced' element (e.g. image, plugin) in a table cell that is not descendant from
2673 a block with fixed layout then do not squeeze the element, let it use its intrinsic width and height.
2675 Test: fast/replaced/table-percent-width.html
2677 * rendering/RenderBox.cpp:
2678 (WebCore::avoidSqueezingWidth):
2679 (WebCore::avoidSqueezingHeight):
2680 (WebCore::RenderBox::containingBlockReplacedLogicalWidthForContent):
2681 (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
2682 (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
2683 * rendering/RenderBox.h:
2685 2011-09-27 Simon Fraser <simon.fraser@apple.com>
2687 https://bugs.webkit.org/show_bug.cgi?id=67858
2689 Roll r96070 back in now that the crash has been fixed in r96130.
2691 Reviewed by Darin Adler.
2693 When non-overlay scrollbars are hidden on a composited iframe, nothing invalidated
2694 the scrollbar areas or the scroll corner, so the scrollbars appear to remain.
2696 Fix by invalidating the scrollbars and scroll corner when they are removed. Invalidation
2697 on scrollbar creation appears to happen via updating the scrollbar style.
2699 Tested by compositing/iframes/repaint-after-losing-scrollbars.html which no longer shows
2700 stale scrollbars when run manually, even though the green squares are missing from the
2701 pixel result (bug 67878).
2703 * page/FrameView.cpp:
2704 (WebCore::FrameView::updateScrollCorner): Pass the corner rect into invalidateScrollCorner().
2705 * platform/ScrollView.cpp:
2706 (WebCore::ScrollView::setHasHorizontalScrollbar): Invalidate the scrollbar area if hiding it.
2707 (WebCore::ScrollView::setHasVerticalScrollbar): Ditto.
2708 (WebCore::ScrollView::updateScrollbars): In the case where both scrollbars are going away,
2709 compute the scroll corner rect while we still have scrollbars, and then invalidate it
2710 explicitly. (updateScrollCorner() doesn't, because it doesn't have access to the old corner
2712 * platform/ScrollableArea.cpp:
2713 (WebCore::ScrollableArea::invalidateScrollCorner): Pass the rect in, because we can't
2714 compute it in the case where the scrollbars are going away.
2715 * platform/ScrollableArea.h: Pass in a rect to invalidateScrollCorner(), which matches
2716 invalidateScrollbar().
2717 * rendering/RenderLayerCompositor.cpp:
2718 (WebCore::RenderLayerCompositor::destroyRootLayer): Pass the corner rect into invalidateScrollCorner().
2719 * rendering/RenderScrollbarPart.cpp: Ditto.
2720 (WebCore::RenderScrollbarPart::imageChanged): Ditto.
2722 2011-09-27 Mihai Parparita <mihaip@chromium.org>
2724 Fix Chromium Mac build after r96130.
2726 * page/FrameView.cpp:
2727 (WebCore::FrameView::layerForOverhangAreas):
2729 2011-09-27 Kaustubh Atrawalkar <kaustubh@motorola.com>
2731 Autofocus on readonly inputs does not focus the element.
2732 https://bugs.webkit.org/show_bug.cgi?id=24092
2734 Reviewed by Ryosuke Niwa.
2736 Readonly input elements should be autofocusable. Removed the check.
2738 Tests: fast/forms/autofocus-readonly-attribute.html
2740 * html/HTMLFormControlElement.cpp:
2741 (WebCore::shouldAutofocus):
2743 2011-09-27 Simon Fraser <simon.fraser@apple.com>
2745 Clean up how FrameView accesses the RenderView
2746 https://bugs.webkit.org/show_bug.cgi?id=68914
2748 Reviewed by Sam Weinig.
2750 Clean up how FrameView accesses the content renderer of its
2751 frame. Previously, this was done in several different ways,
2752 only some of which did null-checking.
2754 Use an inline method to avoid having to expose Frame
2757 Standardize the terminology to use 'root' for this RenderView.
2759 * page/FrameView.cpp:
2760 (WebCore::rootRenderer):
2761 (WebCore::FrameView::setFrameRect):
2762 (WebCore::FrameView::adjustViewSize):
2763 (WebCore::FrameView::updateCompositingLayers):
2764 (WebCore::FrameView::clearBackingStores):
2765 (WebCore::FrameView::restoreBackingStores):
2766 (WebCore::FrameView::layerForHorizontalScrollbar):
2767 (WebCore::FrameView::layerForVerticalScrollbar):
2768 (WebCore::FrameView::layerForScrollCorner):
2769 (WebCore::FrameView::layerForOverhangAreas):
2770 (WebCore::FrameView::syncCompositingStateForThisFrame):
2771 (WebCore::FrameView::hasCompositedContent):
2772 (WebCore::FrameView::enterCompositingMode):
2773 (WebCore::FrameView::isSoftwareRenderable):
2774 (WebCore::FrameView::didMoveOnscreen):
2775 (WebCore::FrameView::willMoveOffscreen):
2776 (WebCore::FrameView::layout):
2777 (WebCore::FrameView::embeddedContentBox):
2778 (WebCore::FrameView::contentsInCompositedLayer):
2779 (WebCore::FrameView::scrollContentsFastPath):
2780 (WebCore::FrameView::scrollContentsSlowPath):
2781 (WebCore::FrameView::maintainScrollPositionAtAnchor):
2782 (WebCore::FrameView::scrollPositionChanged):
2783 (WebCore::FrameView::repaintFixedElementsAfterScrolling):
2784 (WebCore::FrameView::visibleContentsResized):
2785 (WebCore::FrameView::scheduleRelayoutOfSubtree):
2786 (WebCore::FrameView::needsLayout):
2787 (WebCore::FrameView::setNeedsLayout):
2788 (WebCore::FrameView::performPostLayoutTasks):
2789 (WebCore::FrameView::updateControlTints):
2790 (WebCore::FrameView::paintContents):
2791 (WebCore::FrameView::forceLayoutForPagination):
2792 (WebCore::FrameView::adjustPageHeightDeprecated):
2793 (WebCore::FrameView::isVerticalDocument):
2794 (WebCore::FrameView::isFlippedDocument):
2796 2011-09-27 Dominic Mazzoni <dmazzoni@google.com>
2798 AXObjectCache cleared unnecessarily when non-top Document is detached.
2799 https://bugs.webkit.org/show_bug.cgi?id=68636
2801 Reviewed by Chris Fleizach.
2803 Test: accessibility/deleting-iframe-destroys-axcache.html
2806 (WebCore::Document::attach):
2807 (WebCore::Document::detach):
2809 2011-09-27 Sheriff Bot <webkit.review.bot@gmail.com>
2811 Unreviewed, rolling out r96108, r96111, r96113, and r96116.
2812 http://trac.webkit.org/changeset/96108
2813 http://trac.webkit.org/changeset/96111
2814 http://trac.webkit.org/changeset/96113
2815 http://trac.webkit.org/changeset/96116
2816 https://bugs.webkit.org/show_bug.cgi?id=68913
2818 Wait for working Qt5 (Requested by ossy on #webkit).
2821 * platform/graphics/qt/GraphicsLayerQt.cpp:
2823 2011-09-27 Csaba Osztrogonác <ossy@webkit.org>
2825 Fix ENABLE(SQL_DATABASE)=0 build after r95919
2826 https://bugs.webkit.org/show_bug.cgi?id=68902
2828 r95919 enabled OFFLINE_WEB_APPLICATIONS by default and
2829 it needs SQLite stuff even if ENABLE_SQL_DATABASE=0.
2831 Reviewed by Adam Barth.
2833 * platform/sql/SQLiteAuthorizer.cpp:
2834 * platform/sql/SQLiteDatabase.cpp:
2835 * platform/sql/SQLiteFileSystem.cpp:
2836 * platform/sql/SQLiteStatement.cpp:
2837 * platform/sql/SQLiteTransaction.cpp:
2838 * storage/DatabaseAuthorizer.cpp:
2840 2011-09-27 Julien Chaffraix <jchaffraix@webkit.org>
2842 Crash because CSSPrimitiveValue::computeLengthDouble assumes fontMetrics are available
2843 https://bugs.webkit.org/show_bug.cgi?id=66291
2845 Reviewed by Darin Adler.
2847 Test: fast/canvas/crash-set-font.html
2849 This is Yet Another Missing updateFont (similar to bug 57756 and likely others). Here the issue is that
2850 applying one of the font properties could mutate the parent style's font if m_parentStyle == m_style.
2851 We would then query the newly created font when applying CSSPropertyFontSize, which has no font fallback
2852 list as Font::update was never called.
2854 The right fix would be to refactor of how we handle fonts to avoid such manual updates (see bug 62390).
2855 Until this happens, it is better not to crash.
2857 * css/CSSStyleSelector.cpp:
2858 (WebCore::CSSStyleSelector::applyProperty): Added updateFont() here as the fonts could have been
2859 mutated by the previous property change. Also added a comment explaining why it is safe to do it
2862 2011-09-27 No'am Rosenthal <noam.rosenthal@nokia.com>
2864 [Texmap] Code cleanup: remove unused boundingRect/visibleRect calculations
2865 https://bugs.webkit.org/show_bug.cgi?id=68897
2867 Reviewed by Andreas Kling.
2869 No new functionality so no new tests.
2871 * platform/graphics/texmap/TextureMapperNode.cpp:
2872 (WebCore::TextureMapperNode::computeAllTransforms):
2873 (WebCore::TextureMapperNode::computeTiles):
2874 (WebCore::TextureMapperNode::syncCompositingState):
2875 * platform/graphics/texmap/TextureMapperNode.h:
2877 2011-09-27 No'am Rosenthal <noam.rosenthal@nokia.com>
2879 [Texmap][Qt] Refactor texture-upload to allow direct chunk update
2880 https://bugs.webkit.org/show_bug.cgi?id=68808
2882 Add a function to BitmapTexture for direct pixel updates.
2883 Modify BitmapTextureGL::endPaint to use that function. Since the BGRA
2884 to RGBA swizzling is done inside that function, there's no need for the
2885 RGBA32PremultipliedBuffer class to contain such function. Also,
2886 RGBA32PremultipliedBuffer was renamed to BGRA32PremultipliedBuffer, correcting
2889 Reviewed by Andreas Kling.
2891 No new tests. Existing tests in LayoutTests/compositing test this.
2893 * platform/graphics/opengl/TextureMapperGL.cpp:
2894 (WebCore::BitmapTextureGL::beginPaint):
2895 (WebCore::BitmapTextureGL::endPaint):
2896 (WebCore::swizzleBGRAToRGBA):
2897 (WebCore::BitmapTextureGL::updateContents):
2898 * platform/graphics/opengl/TextureMapperGL.h:
2899 (WebCore::BGRA32PremultimpliedBuffer::~BGRA32PremultimpliedBuffer):
2900 * platform/graphics/qt/TextureMapperQt.cpp:
2901 (WebCore::BitmapTextureQt::updateContents):
2902 (WebCore::BGRA32PremultimpliedBufferQt::data):
2903 (WebCore::BGRA32PremultimpliedBuffer::create):
2904 * platform/graphics/qt/TextureMapperQt.h:
2905 * platform/graphics/texmap/TextureMapper.h:
2907 2011-09-23 Tor Arne Vestbø <tor.arne.vestbo@nokia.com>
2909 [Qt] Fix build against Qt5 after refactor of widgets out of QtGUi
2911 QWidget and friends now live in the QtWidgets library. We update
2912 includes in implementation files and private headers to us the
2913 non-module-prefixed path, and leave the lookup for the include
2914 path. For public headers we have to ifdef the includes as the
2915 user might now have the modules we need in his QT config.
2917 Finally, QSGCanvas is no longer a QWidget but a QWindow, so we
2918 have to update our code and use windowHandle() for setting the
2919 parent relationships.
2921 https://bugs.webkit.org/show_bug.cgi?id=68687
2923 Reviewed by Andreas Kling.
2926 * platform/graphics/qt/GraphicsLayerQt.cpp:
2928 2011-09-27 Pavel Feldman <pfeldman@google.com>
2930 Web Inspector: split DOM.attributesUpdated into attributeModified and attributeRemoved.
2931 Send attribute name and value within the event.
2932 https://bugs.webkit.org/show_bug.cgi?id=68613
2934 Reviewed by Yury Semikhatsky.
2937 (WebCore::Element::setAttribute):
2938 (WebCore::Element::removeAttribute):
2939 * inspector/Inspector.draft-01.json:
2940 * inspector/Inspector.json:
2941 * inspector/InspectorDOMAgent.cpp:
2942 (WebCore::InspectorDOMAgent::didModifyDOMAttr):
2943 (WebCore::InspectorDOMAgent::didRemoveDOMAttr):
2944 * inspector/InspectorDOMAgent.h:
2945 * inspector/InspectorInstrumentation.cpp:
2946 (WebCore::InspectorInstrumentation::didModifyDOMAttrImpl):
2947 (WebCore::InspectorInstrumentation::didRemoveDOMAttrImpl):
2948 * inspector/InspectorInstrumentation.h:
2949 (WebCore::InspectorInstrumentation::didModifyDOMAttr):
2950 (WebCore::InspectorInstrumentation::didRemoveDOMAttr):
2951 * inspector/front-end/DOMAgent.js:
2952 (WebInspector.DOMNode.prototype._addAttribute):
2953 (WebInspector.DOMNode.prototype._setAttribute):
2954 (WebInspector.DOMNode.prototype._removeAttribute):
2955 (WebInspector.DOMAgent.prototype._attributeModified):
2956 (WebInspector.DOMAgent.prototype._attributeRemoved):
2957 (WebInspector.DOMAgent.prototype._inlineStyleInvalidated):
2958 (WebInspector.DOMAgent.prototype._loadNodeAttributes):
2959 (WebInspector.DOMDispatcher.prototype.attributeModified):
2960 (WebInspector.DOMDispatcher.prototype.attributeRemoved):
2961 * inspector/front-end/ElementsPanel.js:
2962 (WebInspector.ElementsPanel):
2963 (WebInspector.ElementsPanel.prototype._attributesUpdated):
2964 * inspector/front-end/MetricsSidebarPane.js:
2965 (WebInspector.MetricsSidebarPane):
2966 (WebInspector.MetricsSidebarPane.prototype._attributesUpdated):
2967 * inspector/front-end/StylesSidebarPane.js:
2968 (WebInspector.StylesSidebarPane):
2969 (WebInspector.StylesSidebarPane.prototype._attributesModified):
2970 (WebInspector.StylesSidebarPane.prototype._attributesRemoved):
2971 (WebInspector.StylesSidebarPane.prototype._styleInvalidated):
2972 (WebInspector.StylePropertyTreeElement.prototype.event):
2973 (WebInspector.StylePropertyTreeElement.prototype):
2974 * inspector/validate-protocol-compatibility:
2976 2011-09-27 Sheriff Bot <webkit.review.bot@gmail.com>
2978 Unreviewed, rolling out r96070 and r96075.
2979 http://trac.webkit.org/changeset/96070
2980 http://trac.webkit.org/changeset/96075
2981 https://bugs.webkit.org/show_bug.cgi?id=68893
2983 WK2 tests started crashing after r96070 for SL and Qt
2984 (Requested by torarne on #webkit).
2986 * page/FrameView.cpp:
2987 (WebCore::FrameView::updateScrollCorner):
2988 * platform/ScrollView.cpp:
2989 (WebCore::ScrollView::setHasHorizontalScrollbar):
2990 (WebCore::ScrollView::setHasVerticalScrollbar):
2991 (WebCore::ScrollView::updateScrollbars):
2992 * platform/ScrollableArea.cpp:
2993 (WebCore::ScrollableArea::invalidateScrollCorner):
2994 * platform/ScrollableArea.h:
2995 * rendering/RenderLayerCompositor.cpp:
2996 (WebCore::RenderLayerCompositor::destroyRootLayer):
2997 * rendering/RenderScrollbarPart.cpp:
2998 (WebCore::RenderScrollbarPart::imageChanged):
3000 2011-09-27 Andrey Kosyakov <caseq@chromium.org>
3002 Web Inspector: JS exception upon clicking on "Word Wrap" checkbox in Settings screen
3003 https://bugs.webkit.org/show_bug.cgi?id=68888
3005 Reviewed by Pavel Feldman.
3007 * inspector/front-end/ElementsPanel.js:
3008 (WebInspector.ElementsPanel.prototype._domWordWrapSettingChanged):
3010 2011-09-21 Pavel Podivilov <podivilov@chromium.org>
3012 Web Inspector: migrate RawSourceCode clients to SourceMapping class.
3013 https://bugs.webkit.org/show_bug.cgi?id=68524
3015 Clients should use uiSourceCode(), rawLocationToUILocation(), uiLocationToRawLocation() methods of SourceMapping class.
3016 Initially, RawSourceCode may not have associated SourceMapping, so it is natural to extract this methods and associated state to a separate class.
3018 Reviewed by Yury Semikhatsky.
3020 * inspector/front-end/BreakpointManager.js:
3021 (WebInspector.BreakpointManager.prototype._materializeBreakpoint):
3022 (WebInspector.BreakpointManager.prototype._breakpointDebuggerLocationChanged):
3023 * inspector/front-end/DebuggerPresentationModel.js:
3024 (WebInspector.DebuggerPresentationModel.prototype.linkifyLocation.updateAnchor):
3025 (WebInspector.DebuggerPresentationModel.prototype.linkifyLocation):
3026 (WebInspector.DebuggerPresentationModel.prototype._addScript):
3027 (WebInspector.DebuggerPresentationModel.prototype._updateSourceMapping):
3028 (WebInspector.DebuggerPresentationModel.prototype._restoreBreakpoints):
3029 (WebInspector.DebuggerPresentationModel.prototype._restoreConsoleMessages):
3030 (WebInspector.DebuggerPresentationModel.prototype._consoleMessageAdded):
3031 (WebInspector.DebuggerPresentationModel.prototype._createPresentationMessage):
3032 (WebInspector.DebuggerPresentationModel.prototype.continueToLine):
3033 (WebInspector.PresentationCallFrame.prototype.get url):
3034 (WebInspector.PresentationCallFrame.prototype.sourceLine.sourceMappingUpdated):
3035 (WebInspector.PresentationCallFrame.prototype.sourceLine):
3036 (WebInspector.DebuggerPresentationModelResourceBinding.prototype.canSetContent):
3037 (WebInspector.DebuggerPresentationModelResourceBinding.prototype.setContent):
3038 * inspector/front-end/SourceFile.js:
3039 (WebInspector.RawSourceCode.prototype.get sourceMapping):
3041 2011-09-27 Vineet Chaudhary <vineet.chaudhary@motorola.com>
3043 wrap attribute of textarea element cannot be accessed by JavaScript.
3044 https://bugs.webkit.org/show_bug.cgi?id=68592
3046 Reviewed by Kent Tamura.
3048 Added JS interface for wrap attribute to HTMLTextAreaElement.idl.
3050 Test: fast/forms/textarea-wrap-attribute.html
3052 * html/HTMLTextAreaElement.idl:
3054 2011-09-27 Xan Lopez <xlopez@igalia.com>
3056 [GTK] Add compatibility methods for DOM bindings
3057 https://bugs.webkit.org/show_bug.cgi?id=68884
3059 Reviewed by Philippe Normand.
3061 Add compatibility methods for our DOM bindings.
3063 * bindings/gobject/WebKitDOMCustom.cpp:
3064 (webkit_dom_blob_slice): alias to the new method name.
3065 (webkit_dom_html_form_element_dispatch_form_change): this was
3066 removed from WebCore, so just print a warning about it.
3067 (webkit_dom_html_form_element_dispatch_form_input): ditto.
3068 * bindings/gobject/WebKitDOMCustom.h:
3070 2011-09-27 Ryosuke Niwa <rniwa@webkit.org>
3072 Encapsulate m_firstNodeInserted and m_lastLeafInserted in node insertion logic
3073 https://bugs.webkit.org/show_bug.cgi?id=68875
3075 Reviewed by Kent Tamura.
3077 Added InsertedNode class inside ReplaceSelection to encapsulate m_firstNodeInserted and m_lastLeafInserted.
3078 Deployed it in removeRedundantStylesAndKeepStyleSpanInline, doApply, and insertAsListItems of ReplaceSelectionCommand.
3080 * editing/DeleteSelectionCommand.cpp:
3081 (WebCore::DeleteSelectionCommand::removeNode):
3082 (WebCore::DeleteSelectionCommand::handleGeneralDelete):
3083 * editing/ReplaceSelectionCommand.cpp:
3084 (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
3085 (WebCore::ReplaceSelectionCommand::doApply):
3086 (WebCore::ReplaceSelectionCommand::insertAsListItems):
3087 * editing/ReplaceSelectionCommand.h:
3088 (WebCore::ReplaceSelectionCommand::InsertedNodes::respondToNodeInsertion):
3089 (WebCore::ReplaceSelectionCommand::InsertedNodes::willRemoveNode):
3090 (WebCore::ReplaceSelectionCommand::InsertedNodes::firstNodeInserted):
3091 (WebCore::ReplaceSelectionCommand::InsertedNodes::lastLeafInserted):
3092 (WebCore::ReplaceSelectionCommand::InsertedNodes::pastLastLeaf):
3093 * editing/htmlediting.cpp:
3094 (WebCore::updatePositionForNodeRemoval): Moved from DeleteSelectionCommand.cpp.
3095 * editing/htmlediting.h:
3097 2011-09-27 Arun Patole <bmf834@motorola.com>
3099 Audio element doesn't emit the 'playing' event every time it starts playing, after it has finished playing.
3100 https://bugs.webkit.org/show_bug.cgi?id=60972
3102 Reviewed by Philippe Normand.
3104 The paused attribute should be set to true and the media element should emit a 'paused' at the end of playback.
3105 WHATWG revision r6562: http://html5.org/tools/web-apps-tracker?from=6561&to=6562
3107 Test: media/media-element-play-after-eos.html
3109 * html/HTMLMediaElement.cpp:
3110 (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): set m_paused to true and schedule 'pause' event when playback ended.
3112 2011-09-27 Rakesh KN <rakesh.kn@motorola.com>
3114 <input> with autofocus doesn't lose focus when it has a certain onblur listener
3115 https://bugs.webkit.org/show_bug.cgi?id=68513
3117 Reviewed by Kent Tamura.
3119 Test: fast/forms/autofocus-focus-only-once.html
3121 These changes make sure that an element is focused only once when autofocus attribute is used.
3123 * html/HTMLFormControlElement.cpp:
3124 (WebCore::HTMLFormControlElement::HTMLFormControlElement):
3125 (WebCore::shouldAutofocus):
3126 (WebCore::HTMLFormControlElement::attach):
3127 * html/HTMLFormControlElement.h:
3128 (WebCore::HTMLFormControlElement::hasAutofocused):
3129 (WebCore::HTMLFormControlElement::setAutofocused):
3131 2011-09-26 Kentaro Hara <haraken@chromium.org>
3133 Implement PopStateEvent.state with SerializedScriptValue and ScriptValue
3134 https://bugs.webkit.org/show_bug.cgi?id=68345
3136 Reviewed by Adam Barth.
3138 Previously, the following test cases fail or crash:
3140 - shouldBe("new PopStateEvent('eventType', { state: object1 }).state", "object1") -> FAIL
3141 - new PopStateEvent('eventType', { state: document }).state -> CRASH in DRT
3143 This is because PopStateEvent.state is implemented not as ScriptValue but as SerializedScriptValue.
3144 However, we cannot simply change the type of PopStateEvent.state to ScriptValue,
3145 since PopStateEvent can be constructed in the context that does not know ScriptValue.
3146 For example, Document.cpp calls PopStateEvent::create() with SerializedScriptValue
3147 popped from HistoryItem, but we cannot deserialize the SerializedScriptValue into
3148 the corresponding ScriptValue here because the deserialization requires ExecState.
3149 In other words, although we want to store PopStateEvent.state by ScriptValue internally,
3150 PopStateEvent still needs to provide an API to construct it with SerializedScriptValue.
3151 With these observations, this patch makes the following changes:
3153 - If PopStateEvent is constructed with ScriptValue, it is stored as ScriptValue internally.
3154 When PopStateEvent.state is called, the ScriptValue is returned.
3155 - If PopStateEvent is constructed with SerializedScriptValue, it is stored as
3156 SerializedScriptValue internally (since we cannot deserialize it into ScriptValue
3157 at this point). When PopStateEvent.state is called, the SerializedScriptValue is
3158 deserialized into the corresponding ScriptValue, and the ScriptValue is returned.
3160 Tests: fast/events/constructors/pop-state-event-constructor.html
3161 fast/events/fire-popstate-event.html
3163 * GNUmakefile.list.am: Added JSPopStateEventCustom.cpp.
3164 * UseJSC.cmake: Ditto.
3165 * WebCore.gypi: Ditto.
3166 * WebCore.pro: Ditto.
3167 * WebCore.xcodeproj/project.pbxproj: Ditto.
3168 * bindings/js/JSBindingsAllInOne.cpp: Ditto.
3169 * bindings/js/JSPopStateEventCustom.cpp:
3170 (WebCore::JSPopStateEvent::state): Custom getter for PopStateEvent.state.
3171 * bindings/v8/custom/V8PopStateEventCustom.cpp:
3172 (WebCore::V8PopStateEvent::stateAccessorGetter): Custom getter for PopStateEvent.state.
3173 * dom/PopStateEvent.cpp:
3174 (WebCore::PopStateEventInit::PopStateEventInit): Added initialization code for PopStateEvent.m_state.
3175 (WebCore::PopStateEvent::PopStateEvent): Ditto.
3176 (WebCore::PopStateEvent::create): Ditto.
3177 (WebCore::PopStateEvent::initPopStateEvent): Ditto.
3178 * dom/PopStateEvent.h:
3179 (WebCore::PopStateEvent::serializedState): Getter.
3180 (WebCore::PopStateEvent::state): Getter.
3181 * dom/PopStateEvent.idl: Change the type of 'stateArg' and 'state' to DOMObject. Added [CustomGetter] to 'state'.
3183 2011-09-09 Simon Fraser <simon.fraser@apple.com>
3185 Pixel result shows that compositing/iframes/repaint-after-losing-scrollbars.html is failing
3186 https://bugs.webkit.org/show_bug.cgi?id=67858
3188 Reviewed by Darin Adler.
3190 When non-overlay scrollbars are hidden on a composited iframe, nothing invalidated
3191 the scrollbar areas or the scroll corner, so the scrollbars appear to remain.
3193 Fix by invalidating the scrollbars and scroll corner when they are removed. Invalidation
3194 on scrollbar creation appears to happen via updating the scrollbar style.
3196 Tested by compositing/iframes/repaint-after-losing-scrollbars.html which no longer shows
3197 stale scrollbars when run manually, even though the green squares are missing from the
3198 pixel result (bug 67878).
3200 * page/FrameView.cpp:
3201 (WebCore::FrameView::updateScrollCorner): Pass the corner rect into invalidateScrollCorner().
3202 * platform/ScrollView.cpp:
3203 (WebCore::ScrollView::setHasHorizontalScrollbar): Invalidate the scrollbar area if hiding it.
3204 (WebCore::ScrollView::setHasVerticalScrollbar): Ditto.
3205 (WebCore::ScrollView::updateScrollbars): In the case where both scrollbars are going away,
3206 compute the scroll corner rect while we still have scrollbars, and then invalidate it
3207 explicitly. (updateScrollCorner() doesn't, because it doesn't have access to the old corner
3209 * platform/ScrollableArea.cpp:
3210 (WebCore::ScrollableArea::invalidateScrollCorner): Pass the rect in, because we can't
3211 compute it in the case where the scrollbars are going away.
3212 * platform/ScrollableArea.h: Pass in a rect to invalidateScrollCorner(), which matches
3213 invalidateScrollbar().
3214 * rendering/RenderLayerCompositor.cpp:
3215 (WebCore::RenderLayerCompositor::destroyRootLayer): Pass the corner rect into invalidateScrollCorner().
3216 * rendering/RenderScrollbarPart.cpp: Ditto.
3217 (WebCore::RenderScrollbarPart::imageChanged): Ditto.
3219 2011-09-09 Simon Fraser <simon.fraser@apple.com>
3221 Translucent scrollbars on composited layers render incorrectly
3222 https://bugs.webkit.org/show_bug.cgi?id=58515
3224 Reviewed by Sam Weinig.
3226 Scrollbars in composited elements were getting drawn twice,
3227 because r41203 moved the call to paintOverflowControls() out of
3228 RenderLayer::paintLayer(), but forgot to change RenderLayerBacking::paintIntoLayer().
3230 Test: compositing/scrollbar-painting.html
3232 * rendering/RenderLayerBacking.cpp:
3233 (WebCore::RenderLayerBacking::paintIntoLayer):
3235 2011-09-26 Nat Duca <nduca@chromium.org>
3237 [chromium] Make CCThreadProxy draw
3238 https://bugs.webkit.org/show_bug.cgi?id=67417
3240 Update the CCThreadProxy to correctly implement the CCProxy
3241 interface, do all the right committing and updating steps, and
3242 draw a picture on the screen.
3244 Reviewed by James Robinson.
3246 * platform/graphics/IntRect.h:
3247 * platform/graphics/chromium/LayerRendererChromium.cpp:
3248 (WebCore::LayerRendererChromium::~LayerRendererChromium):
3249 * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
3250 (WebCore::CCHeadsUpDisplay::enabled):
3251 * platform/graphics/chromium/cc/CCLayerImpl.cpp:
3252 (WebCore::CCLayerImpl::CCLayerImpl):
3253 (WebCore::CCLayerImpl::~CCLayerImpl):
3254 * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3255 (WebCore::CCLayerTreeHost::CCLayerTreeHost):
3256 (WebCore::CCLayerTreeHost::commitTo):
3257 (WebCore::CCLayerTreeHost::commitComplete):
3258 (WebCore::CCLayerTreeHost::setNeedsRedraw):
3259 * platform/graphics/chromium/cc/CCLayerTreeHost.h:
3260 * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3261 (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
3262 (WebCore::CCLayerTreeHostImpl::~CCLayerTreeHostImpl):
3263 * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
3264 (WebCore::CCSingleThreadProxy::finishAllRendering):
3265 (WebCore::CCSingleThreadProxy::setNeedsCommit):
3266 (WebCore::CCSingleThreadProxy::commitIfNeeded):
3267 * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3268 (WebCore::CCThreadProxy::CCThreadProxy):
3269 (WebCore::CCThreadProxy::~CCThreadProxy):
3270 (WebCore::CCThreadProxy::compositeAndReadback):
3271 (WebCore::CCThreadProxy::drawLayersAndReadbackOnCCThread):
3272 (WebCore::CCThreadProxy::finishAllRendering):
3273 (WebCore::CCThreadProxy::isStarted):
3274 (WebCore::CCThreadProxy::setNeedsCommit):
3275 (WebCore::CCThreadProxy::setNeedsCommitAndRedraw):
3276 (WebCore::CCThreadProxy::setNeedsRedraw):
3277 (WebCore::CCThreadProxy::start):
3278 (WebCore::CCThreadProxy::stop):
3279 (WebCore::CCThreadProxy::finishAllRenderingOnCCThread):
3280 (WebCore::CCThreadProxy::createBeginFrameAndCommitTaskOnCCThread):
3281 (WebCore::CCThreadProxy::beginFrameAndCommit):
3282 (WebCore::CCThreadProxy::commitOnCCThread):
3283 (WebCore::CCThreadProxy::scheduleDrawTaskOnCCThread):
3284 (WebCore::CCThreadProxy::drawLayersAndPresentOnCCThread):
3285 (WebCore::CCThreadProxy::drawLayersOnCCThread):
3286 (WebCore::CCThreadProxy::updateSchedulerStateOnCCThread):
3287 * platform/graphics/chromium/cc/CCThreadProxy.h:
3289 2011-09-26 Adam Klein <adamk@chromium.org>
3291 [MutationObservers] implement MutationRecord
3292 https://bugs.webkit.org/show_bug.cgi?id=68824
3294 Reviewed by Darin Adler.
3296 Implements MutationRecord as specified in the thread at
3297 http://lists.w3.org/Archives/Public/public-webapps/2011JulSep/1622.html,
3298 including some minor naming changes from the original proposal.
3300 This is a small part of the MutationObserver API, see
3301 https://bugs.webkit.org/show_bug.cgi?id=68729 for the metabug covering
3304 No new tests as this isn't yet exposed to the platform.
3307 * DerivedSources.cpp:
3308 * DerivedSources.make:
3309 * GNUmakefile.list.am:
3312 * WebCore.vcproj/WebCore.vcproj:
3313 * WebCore.xcodeproj/project.pbxproj:
3314 * dom/MutationRecord.cpp: Added.
3315 (WebCore::MutationRecord::createChildList):
3316 (WebCore::MutationRecord::createAttributes):
3317 (WebCore::MutationRecord::createCharacterData):
3318 (WebCore::MutationRecord::MutationRecord):
3319 (WebCore::MutationRecord::~MutationRecord):
3320 * dom/MutationRecord.h: Added.
3321 (WebCore::MutationRecord::target):
3322 (WebCore::MutationRecord::addedNodes):
3323 (WebCore::MutationRecord::removedNodes):
3324 (WebCore::MutationRecord::previousSibling):
3325 (WebCore::MutationRecord::nextSibling):
3326 (WebCore::MutationRecord::attributeName):
3327 (WebCore::MutationRecord::attributeNamespace):
3328 (WebCore::MutationRecord::oldValue):
3329 (WebCore::MutationRecord::setOldValue):
3330 * dom/MutationRecord.idl: Added.
3332 2011-09-26 Kentaro Hara <haraken@chromium.org>
3334 Implement a CloseEvent constructor for V8
3335 https://bugs.webkit.org/show_bug.cgi?id=68793
3337 Reviewed by Adam Barth.
3339 Test: fast/events/constructors/close-event-constructor.html
3341 * bindings/v8/OptionsObject.cpp:
3342 (WebCore::OptionsObject::getKey): Just removed an extra space.
3343 (WebCore::OptionsObject::getKeyValue): Returns an unsigned short value corresponding to the given key.
3344 * bindings/v8/OptionsObject.h:
3345 * bindings/v8/custom/V8EventConstructors.cpp: Added the CloseEvent constructor.
3346 * websockets/CloseEvent.idl: Added a 'V8CustomConstructor' attribute.
3348 2011-09-26 Nate Chapin <japhet@chromium.org>
3350 Clean up CachedResource::load(). Collapse its
3351 logic into a single callsite, taking just a
3352 CachedResourceLoader and a ResourceLoaderOptions.
3354 1. Its 'incremental' parameter is redundant.
3355 2. With 'incremental' removed, the SecurityCheckPolicy is the only
3356 parameter difference between the CachedResource::load() variants.
3357 Making it a part of ResourceLoaderOptions removes yet another random
3358 enum that is passed around individually.
3359 3. We currently have to call setResourceLoaderOptions() before load() on a
3360 new CachedResource, so we should just take the ResourceLoaderOptions in load().
3362 https://bugs.webkit.org/show_bug.cgi?id=67443
3364 Reviewed by Antti Koivisto.
3366 No new tests, refactor only.
3368 * loader/DocumentThreadableLoader.cpp:
3369 * loader/FrameLoaderTypes.h: Move SecurityCheckPolicy to ResourceLoaderOptions.h.
3370 * loader/MainResourceLoader.cpp:
3371 * loader/NetscapePlugInStreamLoader.cpp:
3372 * loader/ResourceLoadScheduler.cpp:
3373 * loader/ResourceLoadScheduler.h:
3374 * loader/ResourceLoader.cpp: Enforce SecurityCheckPolicy here instead of SubresourceLoader.
3375 * loader/ResourceLoaderOptions.h: Store SecurityCheckPolicy on ResourceLoaderOptions.
3376 * loader/SubresourceLoader.cpp:
3377 * loader/SubresourceLoader.h:
3378 * loader/cache/CachedFont.cpp:
3379 * loader/cache/CachedFont.h:
3380 * loader/cache/CachedImage.cpp:
3381 * loader/cache/CachedImage.h:
3382 * loader/cache/CachedResource.cpp:
3383 * loader/cache/CachedResource.h:
3384 * loader/cache/CachedResourceLoader.cpp:
3385 (WebCore::defaultCachedResourceOptions): Define the default ResourceLoaderOptions for
3386 CachedResource loads here instead of as a default parameter on requestResource().
3387 * loader/cache/CachedResourceLoader.h:
3388 * loader/cache/CachedResourceRequest.cpp:
3389 (WebCore::CachedResourceRequest::didReceiveData): Remove m_incremental, since its purpose
3390 is already enforced in the data() implementation of every CachedResource that doesn't want
3392 * loader/cache/CachedResourceRequest.h:
3394 2011-09-26 Joshua Bell <jsbell@chromium.org>
3396 IndexedDB: Second half of IDBFactory.getDatabaseNames implementation
3397 https://bugs.webkit.org/show_bug.cgi?id=68818
3399 Reviewed by Tony Chang.
3401 Test: storage/indexeddb/factory-basics.html
3403 Adds ability to enumerate IndexedDB databases within an origin.
3405 * bindings/v8/custom/V8IDBAnyCustom.cpp:
3407 * storage/IDBAny.cpp:
3408 (WebCore::IDBAny::domStringList):
3409 (WebCore::IDBAny::set):
3411 * storage/IDBBackingStore.h:
3412 * storage/IDBCallbacks.h:
3413 * storage/IDBFactory.cpp:
3414 (WebCore::IDBFactory::getDatabaseNames):
3415 * storage/IDBFactory.h:
3416 * storage/IDBFactory.idl:
3417 * storage/IDBFactoryBackendImpl.cpp:
3418 (WebCore::IDBFactoryBackendImpl::getDatabaseNames):
3419 (WebCore::IDBFactoryBackendImpl::open):
3420 (WebCore::IDBFactoryBackendImpl::openBackingStore):
3421 * storage/IDBFactoryBackendImpl.h:
3422 * storage/IDBFactoryBackendInterface.h:
3423 * storage/IDBLevelDBBackingStore.cpp:
3424 (WebCore::IDBLevelDBBackingStore::getDatabaseNames):
3425 (WebCore::IDBLevelDBBackingStore::getObjectStores):
3426 (WebCore::IDBLevelDBBackingStore::getIndexes):
3427 * storage/IDBLevelDBBackingStore.h:
3428 * storage/IDBLevelDBCoding.cpp:
3429 (WebCore::IDBLevelDBCoding::DatabaseNameKey::encodeMinKeyForOrigin):
3430 (WebCore::IDBLevelDBCoding::DatabaseNameKey::encodeStopKeyForOrigin):
3431 * storage/IDBLevelDBCoding.h:
3432 * storage/IDBRequest.cpp:
3433 (WebCore::IDBRequest::onSuccess):
3434 * storage/IDBRequest.h:
3435 * storage/IDBSQLiteBackingStore.cpp:
3436 (WebCore::IDBSQLiteBackingStore::getDatabaseNames):
3437 * storage/IDBSQLiteBackingStore.h:
3439 2011-09-26 Tim Horton <timothy_horton@apple.com>
3441 <animateColor> applied to filtered ellipse does not update
3442 https://bugs.webkit.org/show_bug.cgi?id=68457
3443 <rdar://problem/10154777>
3445 Reviewed by Darin Adler.
3447 Invalidate the filter's cache when style changes take place so that style changes are respected.
3449 Test: svg/filters/animate-fill.svg
3451 * rendering/svg/SVGResourcesCache.cpp:
3452 (WebCore::SVGResourcesCache::clientStyleChanged):
3453 (WebCore::SVGResourcesCache::clientUpdatedFromElement):
3455 2011-09-26 Max Perepelitsyn <pph34r@gmail.com>
3457 Set but unused variables cleanup in v8 bindings (gcc 4.6)