1 2012-05-01 Kent Tamura <tkent@chromium.org>
3 Calendar Picker: Add capability to add platform-specific style sheet
4 https://bugs.webkit.org/show_bug.cgi?id=85272
6 Reviewed by Kentaro Hara.
8 Add RenderTheme::extraCalendarPickerStyleSheet(). The resultant string
9 of the function is inserted into the calendar picker page.
11 No new tests. Calendar picker apperance is not testable yet.
13 * Resources/calendarPicker.css: Removed styles for year-month buttons.
14 * Resources/calendarPickerMac.css:
15 Moved from calendarPicker.css, and adjust styles so that they look
16 standard Lion buttons.
18 (.year-month-button:active):
19 (.year-month-button:disabled):
20 * WebCore.gyp/WebCore.gyp: Add a rule to produce CalendarPickerMac.{cpp,h}.
21 * html/shadow/CalendarPickerElement.cpp:
22 (WebCore::CalendarPickerElement::writeDocument):
23 Add extraCalendarPickerStyleSheet() result to the document.
24 * rendering/RenderTheme.cpp:
25 (WebCore::RenderTheme::extraCalendarPickerStyleSheet):
26 Added. Returns an empty CString by default.
27 * rendering/RenderTheme.h:
28 (RenderTheme): Added extraCalendarPickerStyleSheet().
29 * rendering/RenderThemeChromiumMac.h: Added extraCalendarPickerStyleSheet().
30 * rendering/RenderThemeChromiumMac.mm:
31 (WebCore::RenderThemeChromiumMac::extraCalendarPickerStyleSheet):
32 Added. Returns the content of Resources/calendarPickerMac.css.
34 2012-05-01 James Simonsen <simonjam@chromium.org>
36 Ensure HTMLElementStack fails gracefully if it has a non-Element.
37 https://bugs.webkit.org/show_bug.cgi?id=85167
39 Reviewed by Adam Barth.
41 Test: Added to html5lib/resources/webkit02.dat
43 * html/parser/HTMLElementStack.cpp:
44 (WebCore::HTMLElementStack::oneBelowTop):
45 * html/parser/HTMLTreeBuilder.cpp:
46 (WebCore::HTMLTreeBuilder::processEndTag):
48 2012-05-01 Ryosuke Niwa <rniwa@webkit.org>
50 *Command.h files shouldn't be exported to WebKit layer
51 https://bugs.webkit.org/show_bug.cgi?id=74778
53 Reviewed by Eric Seidel.
55 Remove the dependency on *Command.h files from Mac port's WebKit layer.
56 Also wrapped the call to TypingCommand::insertParagraphSeparatorInQuotedContent in the Editor class
57 so that we can just expose Editor's method instead of directly exposing the said static method.
60 * WebCore.xcodeproj/project.pbxproj:
63 * editing/mac/EditorMac.mm:
64 (WebCore::Editor::insertParagraphSeparatorInQuotedContent):
67 2012-05-01 Julien Chaffraix <jchaffraix@webkit.org>
69 Remove one bit from m_column to pack RenderTableCell bits more
70 https://bugs.webkit.org/show_bug.cgi?id=85291
72 Reviewed by Ojan Vafai.
74 Memory improvement, covered by the existing unit tests.
76 * rendering/RenderTableCell.cpp:
77 * rendering/RenderTableCell.h:
78 Remove one bit from m_column (which should be fine as I wouldn't expect tables above 1 millions
79 columns to render at all anyway) to pack the bitfields in 32 bits. Re-arranged the bits to have the bigger
82 2012-05-01 Anders Carlsson <andersca@apple.com>
84 Slow scrolling on www.sholby.net
85 https://bugs.webkit.org/show_bug.cgi?id=85304
86 <rdar://problem/11138952>
88 Reviewed by Beth Dakin.
90 Fix two performance issues that showed up on the profiles.
92 * loader/FrameLoader.cpp:
93 (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
94 Reset the relevant painted object counter; it's only interesting when loading.
97 (WebCore::Page::startCountingRelevantRepaintedObjects):
98 Set m_isCountingRelevantRepaintedObjects to true after calling reset, since reset now sets it to false.
100 (WebCore::Page::resetRelevantPaintedObjectCounter):
101 Set m_isCountingRelevantRepaintedObjects to false.
103 (WebCore::Page::addRelevantRepaintedObject):
104 Use HashSet::find to avoid an extra hash lookup.
106 * page/scrolling/ScrollingCoordinator.cpp:
107 (WebCore::ScrollingCoordinator::updateMainFrameScrollPositionAndScrollLayerPosition):
108 Remove the call to FrameView::updateCompositingLayersAfterLayout now, since FrameView::notifyScrollPositionChanged
109 already calls this and was making us to a lot of work twice.
111 2012-05-01 Silvia Pfeiffer <silviapf@chromium.org>
113 Audio controls have a 1px surplus outline coming from RenderImage::paintReplaced base class,
114 which needs overwriting.
115 https://bugs.webkit.org/show_bug.cgi?id=84570
117 Reviewed by Eric Carlson.
119 No new tests - covered by existing audio rendering tests.
121 * rendering/RenderMedia.cpp:
122 (WebCore::RenderMedia::paintReplaced): Overwrite inherited function.
124 * rendering/RenderMedia.h:
127 2012-05-01 Terry Anderson <tdanderson@chromium.org>
129 Allow a pre-targeted node to be specified when dispatching a GestureTap event
130 https://bugs.webkit.org/show_bug.cgi?id=85296
132 Reviewed by Adam Barth.
134 https://bugs.webkit.org/show_bug.cgi?id=85101
135 The new parameter will be used and tested in this patch.
137 * page/EventHandler.cpp:
138 (WebCore::EventHandler::handleGestureTap):
139 The new preTargetedNode parameter can be used to pass in the Node that is
140 the target of the GestureTap event. If this parameter is used, adjustedPoint
141 is changed to be the center of the Node's bounding rectangle.
142 * page/EventHandler.h:
145 2012-05-01 Jessie Berlin <jberlin@apple.com>
147 Crash calling disconnectFrame on a DOMWindowExtension a second time.
148 https://bugs.webkit.org/show_bug.cgi?id=85301
150 Reviewed by Darin Adler.
152 DOMWindowExtension::disconnectFrame assumed it would only be called when there was a frame
153 to disconnect. However, DOMWindow's destructor invokes disconnectFrame on all its
154 DOMWindowProperties, even if it already did so when it entered the page cache.
156 * page/DOMWindowExtension.cpp:
157 (WebCore::DOMWindowExtension::disconnectFrame):
158 Don't do anything if the frame has already been disconnected.
160 2012-05-01 Aaron Colwell <acolwell@chromium.org>
162 Temporarily remove webkitSourceAddId() & webkitSourceRemoveId() from DOM
163 until the rest of the Media Source v0.5 methods are implemented. This is
164 to prevent ambiguity about whether v0.5 is fully supported or not.
165 https://bugs.webkit.org/show_bug.cgi?id=85295
167 Reviewed by Eric Carlson.
169 No new tests. Removing methods from DOM so relevant tests are removed.
171 * html/HTMLMediaElement.idl:
173 2012-05-01 Douglas Stockwell <dstockwell@chromium.org>
175 IndexedDB: stale index entries may not be removed in some cases
176 https://bugs.webkit.org/show_bug.cgi?id=85224
178 Reviewed by Ojan Vafai.
180 Ensure that stale index entries are removed when the corresponding
181 object store entry no longer exists.
183 No new tests. Addresses a performance / storage leak that is
184 not amenable to verification in a layout test.
186 * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
189 2012-05-01 Igor Oliveira <igor.o@sisa.samsung.com>
191 Use HashMap<OwnPtr> for CounterMap in RenderCounter
192 https://bugs.webkit.org/show_bug.cgi?id=85294
194 Reviewed by Eric Seidel.
196 * rendering/RenderCounter.cpp:
198 (WebCore::makeCounterNode):
199 (WebCore::RenderCounter::destroyCounterNodes):
201 2012-05-01 Philip Rogers <pdr@google.com>
203 Skip building instance tree for disallowed target
204 https://bugs.webkit.org/show_bug.cgi?id=85202
206 Reviewed by Nikolas Zimmermann.
208 When the target of a use is disallowed (e.g., a mask element) we can
209 skip building the instance tree because the shadow tree will be
212 Test: svg/custom/animate-disallowed-mask-element.svg
214 * svg/SVGUseElement.cpp:
215 (WebCore::SVGUseElement::buildInstanceTree):
217 2012-04-29 Nikolas Zimmermann <nzimmermann@rim.com>
219 Accumulation for values-animation is broken
220 https://bugs.webkit.org/show_bug.cgi?id=85158
222 Reviewed by Darin Adler.
225 <rect width="999" height="100" fill="green"/>
226 <animate begin="0s" values="0; 30; 20" accumulate="sum" repeatCount="5" dur="2s"/>
229 The rect should animate like this:
235 2.000s -> 20 (first accumulation, starts accumulating from the last set value, here '20').
240 4.000s -> 40 (second accumulation)
243 This is currently broken for values-animation. The accumulation should happen after a full cycle of the values animation ran (aka. at the end of the duration).
244 A values animation works like this: iterate over the list of values, and calculate a 'from' and 'to' value for a given time. Example for values="0; 30; 20" dur="2s":
245 - 0.0s .. 1.0s -> from=0, to=30
246 - 1.0s .. 2.0s -> from=30, to=20
248 Accumulation currently is taken into account at each interval for a values-animation instead of the end of the cycle. Fix that
249 by passing an additional 'toAtEndOfDuration' type to calculateAnimatedValue() which is used for accumulation instead of the
252 Test: svg/animations/accumulate-values-width-animation.html
254 * svg/SVGAnimateElement.cpp:
255 (WebCore::SVGAnimateElement::calculateAnimatedValue):
256 * svg/SVGAnimateElement.h:
258 * svg/SVGAnimateMotionElement.cpp:
259 (WebCore::SVGAnimateMotionElement::calculateAnimatedValue):
260 * svg/SVGAnimateMotionElement.h:
261 (SVGAnimateMotionElement):
262 * svg/SVGAnimatedAngle.cpp:
263 (WebCore::SVGAnimatedAngleAnimator::calculateAnimatedValue):
264 * svg/SVGAnimatedAngle.h:
265 (SVGAnimatedAngleAnimator):
266 * svg/SVGAnimatedBoolean.cpp:
267 (WebCore::SVGAnimatedBooleanAnimator::calculateAnimatedValue):
268 * svg/SVGAnimatedBoolean.h:
269 (SVGAnimatedBooleanAnimator):
270 * svg/SVGAnimatedColor.cpp:
271 (WebCore::SVGAnimatedColorAnimator::calculateAnimatedValue):
272 * svg/SVGAnimatedColor.h:
273 (SVGAnimatedColorAnimator):
274 * svg/SVGAnimatedEnumeration.cpp:
275 (WebCore::SVGAnimatedEnumerationAnimator::calculateAnimatedValue):
276 * svg/SVGAnimatedEnumeration.h:
277 (SVGAnimatedEnumerationAnimator):
278 * svg/SVGAnimatedInteger.cpp:
279 (WebCore::SVGAnimatedIntegerAnimator::calculateAnimatedInteger):
280 (WebCore::SVGAnimatedIntegerAnimator::calculateAnimatedValue):
281 * svg/SVGAnimatedInteger.h:
282 (SVGAnimatedIntegerAnimator):
283 * svg/SVGAnimatedIntegerOptionalInteger.cpp:
284 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::calculateAnimatedValue):
285 * svg/SVGAnimatedIntegerOptionalInteger.h:
286 (SVGAnimatedIntegerOptionalIntegerAnimator):
287 * svg/SVGAnimatedLength.cpp:
288 (WebCore::SVGAnimatedLengthAnimator::calculateAnimatedValue):
289 * svg/SVGAnimatedLength.h:
290 (SVGAnimatedLengthAnimator):
291 * svg/SVGAnimatedLengthList.cpp:
292 (WebCore::SVGAnimatedLengthListAnimator::calculateAnimatedValue):
293 * svg/SVGAnimatedLengthList.h:
294 (SVGAnimatedLengthListAnimator):
295 * svg/SVGAnimatedNumber.cpp:
296 (WebCore::SVGAnimatedNumberAnimator::calculateAnimatedValue):
297 * svg/SVGAnimatedNumber.h:
298 (SVGAnimatedNumberAnimator):
299 * svg/SVGAnimatedNumberList.cpp:
300 (WebCore::SVGAnimatedNumberListAnimator::calculateAnimatedValue):
301 * svg/SVGAnimatedNumberList.h:
302 (SVGAnimatedNumberListAnimator):
303 * svg/SVGAnimatedNumberOptionalNumber.cpp:
304 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateAnimatedValue):
305 * svg/SVGAnimatedNumberOptionalNumber.h:
306 (SVGAnimatedNumberOptionalNumberAnimator):
307 * svg/SVGAnimatedPath.cpp:
308 (WebCore::SVGAnimatedPathAnimator::calculateAnimatedValue):
309 * svg/SVGAnimatedPath.h:
310 (SVGAnimatedPathAnimator):
311 * svg/SVGAnimatedPointList.cpp:
312 (WebCore::SVGAnimatedPointListAnimator::calculateAnimatedValue):
313 * svg/SVGAnimatedPointList.h:
314 (SVGAnimatedPointListAnimator):
315 * svg/SVGAnimatedPreserveAspectRatio.cpp:
316 (WebCore::SVGAnimatedPreserveAspectRatioAnimator::calculateAnimatedValue):
317 * svg/SVGAnimatedPreserveAspectRatio.h:
318 (SVGAnimatedPreserveAspectRatioAnimator):
319 * svg/SVGAnimatedRect.cpp:
320 (WebCore::SVGAnimatedRectAnimator::calculateAnimatedValue):
321 * svg/SVGAnimatedRect.h:
322 (SVGAnimatedRectAnimator):
323 * svg/SVGAnimatedString.cpp:
324 (WebCore::SVGAnimatedStringAnimator::calculateAnimatedValue):
325 * svg/SVGAnimatedString.h:
326 (SVGAnimatedStringAnimator):
327 * svg/SVGAnimatedTransformList.cpp:
328 (WebCore::SVGAnimatedTransformListAnimator::calculateAnimatedValue):
329 * svg/SVGAnimatedTransformList.h:
330 (SVGAnimatedTransformListAnimator):
331 * svg/SVGAnimatedTypeAnimator.h:
332 (SVGAnimatedTypeAnimator):
333 * svg/SVGAnimationElement.cpp:
334 (WebCore::SVGAnimationElement::currentValuesForValuesAnimation):
335 (WebCore::SVGAnimationElement::updateAnimation):
336 * svg/SVGAnimationElement.h:
337 (WebCore::SVGAnimationElement::animateAdditiveNumber):
338 (SVGAnimationElement):
340 2012-05-01 Beth Dakin <bdakin@apple.com>
342 https://bugs.webkit.org/show_bug.cgi?id=85231
343 Fixed position objects that are removed from the DOM don't kick off
344 fixed position recalculation
346 <rdar://problem/11297916>
348 Reviewed by Darin Adler.
350 * rendering/RenderBox.cpp:
351 (WebCore::RenderBox::willBeDestroyed):
353 2012-05-01 Dana Jansens <danakj@chromium.org>
355 Early-out for subtracting a non-intersecting region
356 https://bugs.webkit.org/show_bug.cgi?id=85258
358 Reviewed by Hajime Morita.
360 Given regions A and B, if the bounds of the regions do not intersect,
361 then the regions themselves do not intersect. If the intersection of
362 A and B is empty, then A subtract B == A.
364 * platform/graphics/Region.cpp:
365 (WebCore::Region::subtract):
367 2012-04-30 Kent Tamura <tkent@chromium.org>
369 [Chromium/Windows] Add LocalizedDateWin
370 https://bugs.webkit.org/show_bug.cgi?id=84935
372 Reviewed by Kentaro Hara.
374 LocalizedDateICU.cpp doesn't reflect system settings. So there were some
375 problems such as <input type=date> doesn't use system's date format.
377 We need to use Windows API to get a date format and calendar parameters.
379 We obtain a date format like "MM/dd/yy" via Windows API, and
380 format/parse dates for the format by our own code because Windows API
381 can't handle years older than 1601 and doesn't have date parsing API.
383 Unit test: Source/WebKit/chromium/tests/LocaleWinTest.cpp
385 * WebCore.gypi: Add LocalizedDateWin.cpp.
386 * WebCore.gyp/WebCore.gyp:
387 For Windows, remove LocalizedDateICU.cpp and add LocalizedDateWin.cpp.
388 All of *Win.cpp files are excluded by default.
390 * platform/text/LocaleWin.cpp: Added.
391 (WebCore::LocaleWin::LocaleWin):
392 (WebCore::LocaleWin::create):
393 (WebCore::LocaleWin::currentLocale):
394 (WebCore::LocaleWin::~LocaleWin):
395 (WebCore::LocaleWin::getLocaleInfoString):
396 A helper function to obtain a string by GetLocaleInfo().
397 (WebCore::LocaleWin::initializeShortMonthLabels):
398 Obtain short month names from Windows.
400 (WebCore::DateFormatToken): A struct to represent a token in a date format.
401 e.g. A format string "MM/dd/yy" generates five DateFormatToken:
402 Month2, Literal, Day2, Literal, Year2.
403 (isEraSymbol): A readability helper function.
404 (isYearSymbol): ditto.
405 (isMonthSymbol): ditto.
406 (isDaySymbol): ditto.
407 (countContinuousLetters):
408 (commitLiteralToken): A helper for parseDateFormat().
410 Parse a format string, and generate a list of DateFormatToken.
412 (WebCore::parseNumber): A helper for parseDate().
413 (WebCore::LocaleWin::parseNumberOrMonth): ditto.
414 (WebCore::LocaleWin::parseDate):
415 Parse a user-provided date string by matching with a DateFormatToken list.
417 (WebCore::appendNumber): A helper for formatDate().
418 (WebCore::appendTwoDigitsNumber): ditto. Write at least two digits.
419 (WebCore::appendFourDigitsNumber): ditto. Write at least four digits.
420 (WebCore::LocaleWin::formatDate):
421 Format a DateComponents by iterating a DateFormatToken list.
423 (WebCore::LocaleWin::initializeShortDateTokens):
424 (WebCore::substituteLabelsIntoFormat):
425 Creates a user-visible format string by iterating a DateFormatToken list.
426 (WebCore::LocaleWin::dateFormatText):
427 (WebCore::LocaleWin::initializeMonthLabels):
428 Creates month names by Windows API.
429 (WebCore::LocaleWin::initializeWeekDayShortLabels):
430 Creates day names by Windows API.
431 (WebCore::LocaleWin::monthLabels):
432 Public accessor function for month names.
433 (WebCore::LocaleWin::weekDayShortLabels):
434 Public accessor function for day names.
435 * platform/text/LocaleWin.h: Added.
437 * platform/text/LocalizedDateWin.cpp:
438 Added. The following functions simply delegate to LocaleWin::currentLocale().
439 (WebCore::parseLocalizedDate):
440 (WebCore::formatLocalizedDate):
441 (WebCore::localizedDateFormatText):
442 (WebCore::monthLabels):
443 (WebCore::weekDayShortLabels):
444 (WebCore::firstDayOfWeek):
446 2012-04-30 Kent Tamura <tkent@chromium.org>
448 REGRESSION(r115600): parseLocalizedDate() should fail for invalid inputs
449 https://bugs.webkit.org/show_bug.cgi?id=85176
451 Reviewed by Kentaro Hara.
453 Test: fast/forms/date/input-date-commit-valid-only.html
455 * platform/text/mac/LocalizedDateMac.mm:
456 (WebCore::parseLocalizedDate):
457 We should check nil for the result of NSDateFormtter::dateFromString.
459 2012-04-30 Mark Rowe <mrowe@apple.com>
461 Fix another leak due to misuse of createCFString.
463 Reviewed by Darin Adler.
465 * plugins/mac/PluginPackageMac.cpp:
466 (WebCore::PluginPackage::fetchInfo): Adopt the result of createCFString.
468 2012-04-30 Mark Rowe <mrowe@apple.com>
470 <rdar://problem/11312198> Many leaks during fast/events/dropzone-002.html
472 Reviewed by Darin Adler.
474 * platform/mac/ClipboardMac.mm:
475 (WebCore::utiTypeFromCocoaType): Adopt the result of createCFString.
477 2012-04-30 Mark Rowe <mrowe@apple.com>
479 <rdar://problem/11352575> Many CGImageRefs leaked during media layout tests
481 Reviewed by Brian Weinstein.
483 * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
484 (WebCore::MediaPlayerPrivateAVFoundationObjC::createImageForTimeInRect): Adopt the CGImageRef.
486 2012-04-30 Emil A Eklund <eae@chromium.org>
488 Change RenderBoxModelObject::calculateBackgroundImageGeometry to use roundToInt
489 https://bugs.webkit.org/show_bug.cgi?id=85249
491 Reviewed by Eric Seidel.
493 Prepare RenderBoxModelObject for FractionalLayoutUnits by adding rounding
494 logic to calculateBackgroundImageGeometry. Background images, as all
495 images, needs to be layed out on pixel boundaries thus we need to convert
496 it to a integer value.
498 No new tests, no change in functionality.
500 * rendering/RenderBoxModelObject.cpp:
501 (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
503 2012-04-30 Ilya Sherman <isherman@chromium.org>
505 Unreviewed, rolling out r113511.
506 http://trac.webkit.org/changeset/113511
507 https://bugs.webkit.org/show_bug.cgi?id=66032
508 https://bugs.webkit.org/show_bug.cgi?id=85150
510 Regression: Many autofilled form fields lack the default
511 autofill background even when authors don’t override the
515 (input:-webkit-autofill): Restore !important modifiers
517 2012-04-30 Julien Chaffraix <jchaffraix@webkit.org>
519 Move RenderTableCell's row index to RenderTableRow
520 https://bugs.webkit.org/show_bug.cgi?id=85229
522 Reviewed by Ojan Vafai.
524 Covered by the existing table tests.
526 Row index is a RenderTableRow concept and as such this change moves
527 the relevant logic into the class.
529 While touching the code, renamed row() -> rowIndex() as now RenderTableCell
530 can return its parent RenderTableRow and we were returning an index, not the row
533 * accessibility/AccessibilityTable.cpp:
534 (WebCore::AccessibilityTable::cellForColumnAndRow):
535 * accessibility/AccessibilityTableCell.cpp:
536 (WebCore::AccessibilityTableCell::rowIndexRange):
537 (WebCore::AccessibilityTableCell::titleUIElement):
538 * rendering/RenderTable.cpp:
539 (WebCore::RenderTable::cellAbove):
540 (WebCore::RenderTable::cellBelow):
541 (WebCore::RenderTable::cellBefore):
542 (WebCore::RenderTable::cellAfter):
543 * rendering/RenderTreeAsText.cpp:
544 (WebCore::RenderTreeAsText::writeRenderObject):
545 Updated after the renaming RenderTableCell::row() -> rowIndex().
547 * rendering/RenderTableCell.cpp:
548 (WebCore::RenderTableCell::RenderTableCell):
549 (WebCore::RenderTableCell::computeCollapsedBeforeBorder):
550 (WebCore::RenderTableCell::computeCollapsedAfterBorder):
551 Updated after m_rowIndex removal and row() -> rowIndex() renaming.
553 (WebCore::RenderTableCell::styleDidChange):
554 Switched the rowWasSet check to an ASSERT. The new logic guarantees that
555 row index was set straight when we insert the row. The previous logic was
556 opened to some race conditions as we could wait for a recalcCells call before
557 setting the index on the rows which made this check necessary.
559 * rendering/RenderTableCell.h:
560 (WebCore::RenderTableCell::row):
561 Added this RenderTableRow getter.
563 (WebCore::RenderTableCell::rowIndex):
566 * rendering/RenderTableRow.cpp:
567 (WebCore::RenderTableRow::RenderTableRow):
568 (WebCore::RenderTableRow::styleDidChange):
569 Updated after adding m_rowIndex / rowIndex().
571 * rendering/RenderTableRow.h:
572 (WebCore::RenderTableRow::setRowIndex):
573 (WebCore::RenderTableRow::rowIndex):
574 Added those getter / setter. Also kept m_rowIndex's smaller size
575 for future optimization and for symmetry with the column index on
578 * rendering/RenderTableSection.cpp:
579 (WebCore::RenderTableSection::addChild):
580 (WebCore::RenderTableSection::recalcCells):
581 Made sure that whenever we insert or update our row index
582 we do call setRowIndex().
584 (WebCore::RenderTableSection::addCell):
585 This logic now doesn't need to query insertionRow as the cell's
586 should have the index of the row in which it is inserted.
588 (WebCore::RenderTableSection::calcRowLogicalHeight):
589 (WebCore::RenderTableSection::layoutRows):
590 (WebCore::compareCellPositionsWithOverflowingCells):
591 More updates after row() -> rowIndex() renaming.
593 * rendering/RenderTableSection.h:
594 Removed rowIndexForRenderer now that the row caches this informatin.
596 2012-04-30 Keishi Hattori <keishi@webkit.org>
598 datalist: Inconsistent behavior of HTMLInputElement::list
599 https://bugs.webkit.org/show_bug.cgi?id=84351
601 Each platform will have a different set of input types that support the datalist UI.
602 This patch makes shouldRespectListAttribute ask the RenderTheme if it supports datalist UI for that input type.
603 Thus making it possible to do feature detection with JS.
605 Reviewed by Kent Tamura.
607 * WebCore.gypi: Added RenderThemeChromiumCommon.{cpp,h}
608 * html/ColorInputType.cpp:
609 (WebCore::ColorInputType::shouldRespectListAttribute):
611 * html/ColorInputType.h:
613 * html/InputType.cpp:
614 (WebCore::InputType::themeSupportsDataListUI): Static method used by TextFieldInputType, RangeInputType, and ColorInputType.
618 * html/RangeInputType.cpp:
619 (WebCore::RangeInputType::shouldRespectListAttribute):
620 * html/TextFieldInputType.cpp:
621 (WebCore::TextFieldInputType::shouldRespectListAttribute):
622 * rendering/RenderTheme.h:
624 (WebCore::RenderTheme::supportsDataListUI): Returns true if the platform can show the datalist suggestions for a given input type.
625 * rendering/RenderThemeChromiumCommon.cpp: Added.
627 (WebCore::RenderThemeChromiumCommon::supportsDataListUI):
628 * rendering/RenderThemeChromiumCommon.h: Added.
630 (RenderThemeChromiumCommon):
631 * rendering/RenderThemeChromiumMac.h:
632 (RenderThemeChromiumMac):
633 * rendering/RenderThemeChromiumMac.mm:
634 (WebCore::RenderThemeChromiumMac::supportsDataListUI):
636 * rendering/RenderThemeChromiumSkia.cpp:
637 (WebCore::RenderThemeChromiumMac::supportsDataListUI):
639 * rendering/RenderThemeChromiumSkia.h:
640 (RenderThemeChromiumSkia):
642 2012-04-30 Levi Weintraub <leviw@chromium.org>
644 RenderObject incorrectly lists maximalOutlineSize as a LayoutUnit
645 https://bugs.webkit.org/show_bug.cgi?id=85248
647 Reviewed by Eric Seidel.
649 Reverting RenderObject::maximalOutlineSize to int. This is a slop value for repaint
650 rects that doesn't affect layout. It also derives its value from RenderView's function
651 of the same name, which is already an integer.
653 No new tests. No change in behavior.
655 * rendering/RenderObject.cpp:
656 (WebCore::RenderObject::maximalOutlineSize):
657 * rendering/RenderObject.h:
660 2012-04-30 Xingnan Wang <xingnan.wang@intel.com>
662 Add multichannel support for input of JavaScriptAudioNode
663 https://bugs.webkit.org/show_bug.cgi?id=84687
665 Reviewed by Chris Rogers.
667 Tests: webaudio/javascriptaudionode-downmix8-2channel-input.html
668 webaudio/javascriptaudionode-upmix2-8channel-input.html
670 * Modules/webaudio/JavaScriptAudioNode.cpp:
671 (WebCore::JavaScriptAudioNode::create):
672 (WebCore::JavaScriptAudioNode::JavaScriptAudioNode):
673 (WebCore::JavaScriptAudioNode::initialize):
674 (WebCore::JavaScriptAudioNode::process):
675 * Modules/webaudio/JavaScriptAudioNode.h:
676 (JavaScriptAudioNode):
678 2012-04-30 Oliver Hunt <oliver@apple.com>
680 Harden arithmetic in ImageBufferDataCG
681 https://bugs.webkit.org/show_bug.cgi?id=61373
683 Reviewed by Gavin Barraclough.
685 We have a checked type that allows us to automate many of the
686 bounds checks we want here, so let's replace the floating point
687 math, and just use Checked<> throughout. We use a non-recording
688 Checked<> as no overflows should reach this point, so we'll take
689 a hard early failure, over the cost of many branches when
690 accessing the raw values in loops.
692 * platform/graphics/cg/ImageBufferDataCG.cpp:
693 (WebCore::ImageBufferData::getData):
694 (WebCore::ImageBufferData::putData):
696 2012-04-30 Levi Weintraub <leviw@chromium.org>
698 Add absoluteValue method for LayoutUnits to allow overloading abs()
699 https://bugs.webkit.org/show_bug.cgi?id=85214
701 Reviewed by Eric Seidel.
703 Adding an absoluteValue free inline function that operates on LayoutUnits, which
704 allows us to have one function signature for ints or FractionalLayoutUnits. We
705 can't simply add a FractionalLayoutUnit flavor of abs because it confuses
706 some compilers due to the implicit FractionalLayoutUnit constructors that take
709 No new tests. No change in behavior.
711 * page/SpatialNavigation.cpp:
712 (WebCore::distanceDataForNode):
713 * rendering/LayoutTypes.h:
714 (WebCore::absoluteValue):
716 * rendering/RenderBlockLineLayout.cpp:
717 (WebCore::RenderBlock::checkPaginationAndFloatsAtEndLine):
718 * rendering/RenderLineBoxList.cpp:
719 (WebCore::RenderLineBoxList::rangeIntersectsRect):
720 * rendering/RenderObject.cpp:
721 (WebCore::RenderObject::repaintAfterLayoutIfNeeded):
723 2012-04-30 Levi Weintraub <leviw@chromium.org>
725 Update LayoutUnit usage in InlineFlowBox and RenderWidget
726 https://bugs.webkit.org/show_bug.cgi?id=85239
728 Reviewed by Eric Seidel.
730 Updating LayoutUnit usage in a pair of remaining functions to minimize the remaining work to switching
731 to FractionalLayoutUnits for layout instead of integers.
733 No new tests. No change in behavior.
735 * rendering/InlineFlowBox.cpp:
736 (WebCore::InlineFlowBox::placeBoxesInBlockDirection): Though stored as a float, the top is always
737 set to an integer value. When we move to sub-pixel, we need to preserve this. Not preserving this
738 behavior affects text decorations, most notably underlines.
739 * rendering/RenderWidget.cpp:
740 (WebCore::RenderWidget::updateWidgetGeometry): Adding pixel snapping for the content box if it's
741 not transformed (absoluteContentBox includes pixel snapping), and properly treating the boundingBox
744 2012-04-30 Levi Weintraub <leviw@chromium.org>
746 Prepare RenderDeprecatedFlexibleBox for sub-pixel layout
747 https://bugs.webkit.org/show_bug.cgi?id=85217
749 Reviewed by Eric Seidel.
751 Bailing from the space distribution loop in layoutHorizontal/VerticalBox when
752 the remaining space falls below one pixel. This has no effect in whole-pixel
753 layout, but avoids unnecessary work/infinite loops in the sub-pixel case.
755 No new tests. No change in behavior.
757 * rendering/RenderDeprecatedFlexibleBox.cpp:
758 (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox):
759 (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):
761 2012-04-30 Ryosuke Niwa <rniwa@webkit.org>
763 NULL ptr in WebCore::Range::getBorderAndTextQuads
764 https://bugs.webkit.org/show_bug.cgi?id=77218
766 Reviewed by Eric Seidel.
768 The crash was caused by a malformed range obtained within an event handler of mutation events
769 (DOMNodeRemovedFromDocument). Because this range wasn't updated per node removal, range functions
770 end up not behaving well.
772 Fixed the bug by changing the order of the notifications in ContainerNode::willRemoveChild.
773 We now fire mutation events first before updating ranges so that any range created inside those
774 event handlers can also be updated prior to the actual node removal.
776 Test: fast/dom/Range/range-created-in-mutation-event-crash.xhtml
778 * dom/ContainerNode.cpp:
779 (WebCore::willRemoveChild):
781 2012-04-30 Anders Carlsson <andersca@apple.com>
783 ScrollingCoordinator::requestScrollPositionUpdate should not update the main frame scroll position
784 https://bugs.webkit.org/show_bug.cgi?id=85240
785 <rdar://problem/11286609>
787 Reviewed by Sam Weinig.
789 The call to updateMainFrameScrollPosition was added to make the WebKit2 find overlay work, since it relies
790 on scroll position updates being synchronous. Change the find code in WebKit2 to handle asynchronous scroll
791 position updates and remove the call to updateMainFrameScrollPosition.
793 * page/scrolling/ScrollingCoordinator.cpp:
794 (WebCore::ScrollingCoordinator::requestScrollPositionUpdate):
796 2012-04-30 Anders Carlsson <andersca@apple.com>
798 Add a way to asynchronously call a function once the scroll position of a page has been updated
799 https://bugs.webkit.org/show_bug.cgi?id=85237
801 Reviewed by Sam Weinig.
804 Export functions needed by WebKit2.
806 * page/scrolling/ScrollingCoordinator.h:
807 Make commitTreeStateIfNeeded public.
809 2012-04-30 Kentaro Hara <haraken@chromium.org>
811 WebGLRenderingContext methods should throw TypeError for not enough arguments
812 https://bugs.webkit.org/show_bug.cgi?id=84787
814 Reviewed by Kenneth Russell.
816 Currently, WebGLRenderingcontext methods implement
817 "Not enough arguments" error as SyntaxError. The Web IDL
818 spec requires that it should be TypeError:
819 http://www.w3.org/TR/WebIDL/#dfn-overload-resolution-algorithm
821 This patch changes SyntaxError to TypeError.
823 I wanted to confirm the behavior of Firefox and Opera,
824 but they do not implement WebGL yet.
826 Test: fast/canvas/webgl/webgl-exceptions.html
828 * bindings/js/JSWebGLRenderingContextCustom.cpp:
829 (WebCore::getObjectParameter):
830 (WebCore::JSWebGLRenderingContext::getAttachedShaders):
831 (WebCore::JSWebGLRenderingContext::getExtension):
832 (WebCore::JSWebGLRenderingContext::getFramebufferAttachmentParameter):
833 (WebCore::JSWebGLRenderingContext::getParameter):
834 (WebCore::JSWebGLRenderingContext::getProgramParameter):
835 (WebCore::JSWebGLRenderingContext::getShaderParameter):
836 (WebCore::JSWebGLRenderingContext::getUniform):
837 (WebCore::dataFunctionf):
838 (WebCore::dataFunctioni):
839 (WebCore::dataFunctionMatrix):
840 * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
841 (WebCore::getObjectParameter):
842 (WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
843 (WebCore::V8WebGLRenderingContext::getExtensionCallback):
844 (WebCore::V8WebGLRenderingContext::getFramebufferAttachmentParameterCallback):
845 (WebCore::V8WebGLRenderingContext::getParameterCallback):
846 (WebCore::V8WebGLRenderingContext::getProgramParameterCallback):
847 (WebCore::V8WebGLRenderingContext::getShaderParameterCallback):
848 (WebCore::V8WebGLRenderingContext::getUniformCallback):
849 (WebCore::vertexAttribAndUniformHelperf):
850 (WebCore::uniformHelperi):
851 (WebCore::uniformMatrixHelper):
853 2012-04-30 Emil A Eklund <eae@chromium.org>
855 [gtk, qt, chromium, win] Fix usage of LayoutUnits and rounding in platform code
856 https://bugs.webkit.org/show_bug.cgi?id=85222
858 Reviewed by Eric Seidel.
860 Update platform code to use the pixel snapped values for painting rects
861 to line up with device pixels and change platform specific hit testing
862 code to use roundedPoint as hit testing is still mostly done on integer
865 No new tests, no change in functionality.
867 * platform/qt/RenderThemeQt.cpp:
868 (WebCore::RenderThemeQt::paintMediaVolumeSliderTrack):
869 * platform/win/PopupMenuWin.cpp:
870 (WebCore::PopupMenuWin::paint):
871 * rendering/RenderThemeChromiumSkia.cpp:
872 (WebCore::RenderThemeChromiumSkia::paintSearchFieldCancelButton):
873 (WebCore::RenderThemeChromiumSkia::paintSearchFieldResultsDecoration):
874 (WebCore::RenderThemeChromiumSkia::paintSearchFieldResultsButton):
876 2012-04-30 Kentaro Hara <haraken@chromium.org>
878 [V8][JSC] Remove hard-coded "Not enough arguments" errors
879 https://bugs.webkit.org/show_bug.cgi?id=85207
881 Reviewed by Sam Weinig.
883 In bug 85022 and bug 85097, we implemented
884 createNotEnoughArgumentsError() in JSC and
885 V8Proxy::throwNotEnoughArgumentsError() in V8 and partially
886 removed hard-coded "Not enough arguments" errors.
887 This patch removes hard-coded "Not enough arguments"
888 errors by using the helper methods.
890 No tests. No change in behavior.
892 * bindings/js/JSAudioContextCustom.cpp:
893 (WebCore::JSAudioContextConstructor::constructJSAudioContext):
894 * bindings/js/JSSVGLengthCustom.cpp:
895 (WebCore::JSSVGLength::convertToSpecifiedUnits):
896 * bindings/js/JSWebSocketCustom.cpp:
897 (WebCore::JSWebSocketConstructor::constructJSWebSocket):
898 (WebCore::JSWebSocket::send):
899 * bindings/js/JSXMLHttpRequestCustom.cpp:
900 (WebCore::JSXMLHttpRequest::open):
901 * bindings/v8/ScriptController.cpp:
902 (WebCore::setValueAndClosePopupCallback):
903 * bindings/v8/custom/V8AudioContextCustom.cpp:
904 (WebCore::V8AudioContext::constructorCallback):
905 * bindings/v8/custom/V8SVGLengthCustom.cpp:
906 (WebCore::V8SVGLength::convertToSpecifiedUnitsCallback):
907 * bindings/v8/custom/V8WebSocketCustom.cpp:
908 (WebCore::V8WebSocket::constructorCallback):
909 (WebCore::V8WebSocket::sendCallback):
910 * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
911 (WebCore::V8XMLHttpRequest::openCallback):
913 2012-04-30 Benjamin Poulain <benjamin@webkit.org>
915 Add String::startsWith() and endsWith() for string literals
916 https://bugs.webkit.org/show_bug.cgi?id=85154
918 Reviewed by Darin Adler.
920 Update WebCore to use the simpler startsWith() and endsWith() taking
924 (WebCore::CSSParser::markPropertyEnd):
925 * css/WebKitCSSKeyframeRule.cpp:
926 (WebCore::StyleKeyframe::parseKeyString):
927 * editing/markup.cpp:
928 (WebCore::createFragmentFromText):
929 * html/HTMLObjectElement.cpp:
930 (WebCore::HTMLObjectElement::addSubresourceAttributeURLs):
931 * html/HTMLTextFormControlElement.cpp:
932 (WebCore::HTMLTextFormControlElement::setInnerTextValue):
933 * inspector/ContentSearchUtils.cpp:
934 (WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
935 * inspector/InspectorCSSAgent.cpp:
936 (WebCore::InspectorCSSAgent::SetPropertyTextAction::redo):
937 * loader/MainResourceLoader.cpp:
938 (WebCore::MainResourceLoader::substituteMIMETypeFromPluginDatabase):
939 * loader/appcache/ManifestParser.cpp:
940 (WebCore::parseManifest):
941 * platform/blackberry/CookieManager.cpp:
942 (WebCore::CookieManager::shouldRejectForSecurityReason):
943 * platform/posix/FileSystemPOSIX.cpp:
944 (WebCore::pathByAppendingComponent):
945 * plugins/PluginDatabase.cpp:
946 (WebCore::PluginDatabase::findPlugin):
947 * svg/SVGStopElement.cpp:
948 (WebCore::SVGStopElement::parseAttribute):
949 * svg/animation/SVGSMILElement.cpp:
950 (WebCore::SVGSMILElement::parseOffsetValue):
951 (WebCore::SVGSMILElement::parseCondition):
953 2012-04-30 Abhishek Arya <inferno@chromium.org>
955 Remove positioned float code.
956 https://bugs.webkit.org/show_bug.cgi?id=84795
958 Reviewed by Dan Bernstein.
960 Backout r92004 and some pieces from r91702.
962 Test: fast/block/float/positioned-float-crash.html
965 (WebCore::isValidKeywordPropertyAndValue):
966 * css/CSSPrimitiveValueMappings.h:
967 (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
968 (WebCore::CSSPrimitiveValue::operator EFloat):
969 * css/CSSValueKeywords.in:
970 * rendering/RenderBlock.cpp:
971 (WebCore::RenderBlock::RenderBlock):
972 (WebCore::RenderBlock::layoutBlock):
973 (WebCore::RenderBlock::addOverflowFromFloats):
974 (WebCore::RenderBlock::layoutBlockChild):
975 (WebCore::RenderBlock::simplifiedLayout):
976 (WebCore::RenderBlock::layoutPositionedObjects):
977 (WebCore::RenderBlock::insertFloatingObject):
978 (WebCore::RenderBlock::positionNewFloats):
979 (WebCore::RenderBlock::clearFloats):
980 (WebCore::RenderBlock::FloatingObjects::clear):
981 (WebCore::RenderBlock::FloatingObjects::increaseObjectsCount):
982 (WebCore::RenderBlock::FloatingObjects::decreaseObjectsCount):
983 * rendering/RenderBlock.h:
985 (WebCore::RenderBlock::forceLayoutInlineChildren):
987 (WebCore::RenderBlock::FloatingObject::FloatingObject):
988 (WebCore::RenderBlock::hasOverhangingFloats):
989 (WebCore::RenderBlock::FloatingObjects::FloatingObjects):
991 * rendering/RenderBox.cpp:
992 (WebCore::RenderBox::updateBoxModelInfoFromStyle):
993 * rendering/RenderDeprecatedFlexibleBox.cpp:
994 (WebCore::RenderDeprecatedFlexibleBox::layoutBlock):
995 * rendering/RenderDeprecatedFlexibleBox.h:
996 (RenderDeprecatedFlexibleBox):
997 * rendering/RenderFlexibleBox.cpp:
998 (WebCore::RenderFlexibleBox::layoutBlock):
999 * rendering/RenderFlexibleBox.h:
1000 (RenderFlexibleBox):
1001 * rendering/RenderLayer.cpp:
1002 (WebCore::RenderLayer::updateScrollbarsAfterLayout):
1003 * rendering/style/RenderStyleConstants.h:
1005 2012-04-29 Sam Weinig <sam@webkit.org>
1008 https://bugs.webkit.org/show_bug.cgi?id=84036
1010 Reviewed by Anders Carlsson.
1013 * fileapi/WebKitBlobBuilder.idl:
1014 * page/DOMWindow.idl:
1015 * workers/WorkerContext.idl:
1016 Make exposing the WebKitBlobBuilder JS object conditional on a new
1017 ENABLE_LEGACY_WEBKIT_BLOB_BUILDER flag. Don't enable this for the Mac,
1018 but do for everyone else.
1020 2012-04-30 Anders Carlsson <andersca@apple.com>
1022 Add a barrier-style dispatch member function to ScrollingThread
1023 https://bugs.webkit.org/show_bug.cgi?id=85228
1025 Reviewed by Sam Weinig.
1027 Add a ScrollingThread::dispatchBarrier function which takes a WTF::Function and dispatches it to the main thread
1028 once all the currently scheduled scrolling thread functions have run. This is to be used for synchronization between the
1029 scrolling thread and the main thread.
1031 * page/scrolling/ScrollingThread.cpp:
1032 (WebCore::callFunctionOnMainThread):
1034 (WebCore::ScrollingThread::dispatchBarrier):
1035 * page/scrolling/ScrollingThread.h:
1038 2012-04-30 Min Qin <qinmin@google.com>
1040 Expose a flag so that fullscreen video on android can work with FULLSCREEN_API
1041 https://bugs.webkit.org/show_bug.cgi?id=84414
1043 Reviewed by Darin Fisher.
1045 No tests, just exposing the flag, and will be used by android later.
1046 Sorry, there is a merge error during the previous commit, resolved now
1048 * platform/graphics/MediaPlayer.cpp:
1049 (WebCore::MediaPlayer::setControls):
1051 (WebCore::MediaPlayer::enterFullscreen):
1052 (WebCore::MediaPlayer::exitFullscreen):
1053 * platform/graphics/MediaPlayer.h:
1055 * platform/graphics/MediaPlayerPrivate.h:
1056 (MediaPlayerPrivateInterface):
1057 (WebCore::MediaPlayerPrivateInterface::enterFullscreen):
1059 2012-04-30 Nate Chapin <japhet@chromium.org>
1061 Move more of committing and starting to write a Document
1063 https://bugs.webkit.org/show_bug.cgi?id=83908
1065 Reviewed by Adam Barth.
1067 No new tests, refactor only.
1069 * loader/DocumentLoader.cpp:
1070 (WebCore::DocumentLoader::commitIfReady): Ignore m_gotFirstByte here, since
1071 it was always true here anyway.
1072 (WebCore::DocumentLoader::finishedLoading): If we are finishing an empty
1073 document, create the document now, so that FrameLoaderClient doesn't
1074 have to do it later (FrameLoaderClient code will be removed in a later
1076 (WebCore::DocumentLoader::commitData): Call receivedFirstData() directly and
1077 do some work receivedFirstData() used to do, setEncoding() only once per
1079 (WebCore::DocumentLoader::receivedData):
1080 (WebCore::DocumentLoader::maybeCreateArchive):
1081 * loader/DocumentLoader.h:
1082 * loader/DocumentWriter.cpp:
1083 (WebCore::DocumentWriter::setEncoding):
1084 * loader/FrameLoader.cpp:
1085 (WebCore::FrameLoader::receivedFirstData): Move DocumentLoader calls
1087 * loader/FrameLoader.h: Remove m_hasReceivedFirstData and willSetEncoding(),
1088 allow hasReceivedData() to be called directly.
1091 2012-04-30 Kentaro Hara <haraken@chromium.org>
1093 Unreviewed. Fix test crashes in Win/Linux debug builds.
1095 * bindings/v8/V8LazyEventListener.cpp:
1096 (WebCore::V8LazyEventListener::V8LazyEventListener):
1097 (WebCore::V8LazyEventListener::prepareListenerObject):
1098 * bindings/v8/V8LazyEventListener.h:
1099 (V8LazyEventListener):
1101 2012-04-30 Tommy Widenflycht <tommyw@google.com>
1103 MediaStream API: Change LocalMediaStream::stop to be synchronous
1104 https://bugs.webkit.org/show_bug.cgi?id=84942
1106 Reviewed by Dimitri Glazkov.
1108 Since I changed LocalMediaStream to be a ActiveDOMObject recently the stop()
1109 behaviour needs to change since it is no longer a good idea to start a timer when called.
1111 Not possible to write a test for this.
1113 * Modules/mediastream/LocalMediaStream.cpp:
1114 (WebCore::LocalMediaStream::LocalMediaStream):
1115 (WebCore::LocalMediaStream::stop):
1116 * Modules/mediastream/LocalMediaStream.h:
1119 2012-04-28 Emil A Eklund <eae@chromium.org> and Levi Weintraub <leviw@chromium.org>
1121 Add ENABLE_SUBPIXEL_LAYOUT controlling FractionalLayoutUnit denominator
1122 https://bugs.webkit.org/show_bug.cgi?id=85146
1124 Reviewed by Eric Seidel.
1126 Add a new flag for controlling the fixed point denominator in
1127 FractionalLayoutUnit. Controls whether the denominator is set to 60 or 1.
1128 Until we change the LayoutUnit typedef this change will have no effect.
1130 No new tests, no change in functionality.
1132 * platform/FractionalLayoutUnit.h:
1134 (WebCore::FractionalLayoutUnit::operator++):
1135 (WebCore::operator/):
1136 (WebCore::operator+):
1137 Add ++, / double and and + double operators. These are needed when
1138 ENABLE_SUBPIXEL_LAYOUT is not enabled.
1140 * platform/graphics/FractionalLayoutRect.cpp:
1141 (WebCore::enclosingFractionalLayoutRect):
1143 2012-04-30 Justin Schuh <jschuh@chromium.org>
1145 loadOrRedirectSubframe should return the owner element's frame
1146 https://bugs.webkit.org/show_bug.cgi?id=84780
1148 Reviewed by Nate Chapin.
1150 Test: fast/loader/javascript-url-iframe-remove-on-navigate.html
1152 * loader/SubframeLoader.cpp:
1153 (WebCore::SubframeLoader::loadOrRedirectSubframe):
1155 2012-04-30 Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org>
1157 Use Vector<Attribute> directly instead of encapsulating it in AttributeVector
1158 https://bugs.webkit.org/show_bug.cgi?id=84413
1160 Reviewed by Andreas Kling.
1162 As commented in https://bugs.webkit.org/show_bug.cgi?id=79963#c16 we do not
1163 usually subclass basic types like Vector. This patch changes code to use
1164 Vector<Attribute> directly and move around the functionality of the former
1165 methods to more specific helper functions or inline code at the callers.
1168 (WebCore::Element::parserSetAttributes):
1169 (WebCore::Element::normalizeAttributes):
1172 * dom/ElementAttributeData.cpp:
1173 * dom/ElementAttributeData.h:
1174 (WebCore::findAttributeInVector):
1175 (WebCore::ElementAttributeData::getAttributeItem):
1176 (ElementAttributeData):
1177 (WebCore::ElementAttributeData::attributeVector):
1178 (WebCore::ElementAttributeData::clonedAttributeVector):
1179 (WebCore::ElementAttributeData::getAttributeItemIndex):
1181 * html/parser/HTMLConstructionSite.cpp:
1182 (WebCore::HTMLConstructionSite::createHTMLElementFromSavedElement):
1183 * html/parser/HTMLToken.h:
1184 (WebCore::AtomicHTMLToken::AtomicHTMLToken):
1185 * html/parser/HTMLTreeBuilder.cpp:
1186 (WebCore::HTMLTreeBuilder::processFakeStartTag):
1187 (WebCore::HTMLTreeBuilder::attributesForIsindexInput): Loop through the attributes
1188 backwards so we can remove items without affecting the rest of the loop run.
1189 * html/parser/HTMLTreeBuilder.h:
1190 * html/parser/TextDocumentParser.cpp:
1191 (WebCore::TextDocumentParser::insertFakePreElement):
1192 * xml/XMLErrors.cpp:
1193 (WebCore::createXHTMLParserErrorHeader):
1194 (WebCore::XMLErrors::insertErrorMessageBlock):
1195 * xml/parser/MarkupTokenBase.h:
1196 (WebCore::AtomicMarkupTokenBase::AtomicMarkupTokenBase):
1197 (WebCore::AtomicMarkupTokenBase::getAttributeItem):
1198 (WebCore::AtomicMarkupTokenBase::attributes):
1199 (AtomicMarkupTokenBase):
1200 (WebCore::::initializeAttributes):
1201 * xml/parser/XMLToken.h:
1202 (WebCore::AtomicXMLToken::AtomicXMLToken):
1204 2012-04-30 Mark Pilgrim <pilgrim@chromium.org>
1206 [Chromium] Remove PlatformSupport::loadPlatformAudioResource, call loadResource directly
1207 https://bugs.webkit.org/show_bug.cgi?id=85193
1209 Reviewed by Kentaro Hara.
1211 Part of a refactoring series. See tracking bug 82948.
1213 * platform/audio/chromium/AudioBusChromium.cpp:
1214 (WebCore::AudioBus::loadPlatformResource):
1215 * platform/chromium/PlatformSupport.h:
1218 2012-04-30 Mark Pilgrim <pilgrim@chromium.org>
1220 [Chromium] Call defaultLocale directly
1221 https://bugs.webkit.org/show_bug.cgi?id=85192
1223 Reviewed by Kentaro Hara.
1225 Part of a refactoring series. See tracking bug 82948.
1227 * platform/chromium/LanguageChromium.cpp:
1228 (WebCore::platformLanguage):
1229 * platform/chromium/PlatformSupport.h:
1232 2012-04-30 Beth Dakin <bdakin@apple.com>
1234 https://bugs.webkit.org/show_bug.cgi?id=82922
1235 border-image with image-set does not render correctly when viewed at
1238 <rdar://problem/11167820>
1240 Reviewed by Dan Bernstein.
1242 StyleImage::computeIntrinsicDimensions() is only called from one
1243 place: RenderBoxModelObject::calculateIntrinsicDimensions(), and that
1244 is only used for background images and border images. In my original
1245 image-set work, I decided that
1246 StyleCachedImageSet::computeIntrinsicDimensions() would compute
1247 "intrinsic" dimensions, meaning that they would compute the dimensions
1248 that the image resource was pretending to be rather than the actual
1249 dimensions of the resource. I chose to do this because it made
1250 background images work great without changing the call-site. But border
1251 images need to know the actual intrinsic dimensions, so this design
1252 decision (which was admittedly questionable from the start) won't
1255 This patch makes StyleImage::computeIntrinsicDimensions() return
1256 actual intrinsic dimensions. Then the border-image and background-
1257 image code is very lightly patched to account for the image's scale
1260 These functions no longer need the scale factor parameter.
1261 * loader/cache/CachedImage.cpp:
1262 (WebCore::CachedImage::computeIntrinsicDimensions):
1263 * loader/cache/CachedImage.h:
1265 * platform/graphics/GeneratedImage.h:
1267 * platform/graphics/GeneratorGeneratedImage.cpp:
1268 (WebCore::GeneratedImage::computeIntrinsicDimensions):
1269 * platform/graphics/Image.cpp:
1270 (WebCore::Image::computeIntrinsicDimensions):
1271 * platform/graphics/Image.h:
1273 * platform/graphics/cg/PDFDocumentImage.cpp:
1274 (WebCore::PDFDocumentImage::computeIntrinsicDimensions):
1275 * platform/graphics/cg/PDFDocumentImage.h:
1277 * svg/graphics/SVGImage.cpp:
1278 (WebCore::SVGImage::computeIntrinsicDimensions):
1279 * svg/graphics/SVGImage.h:
1281 * rendering/style/StyleCachedImageSet.cpp:
1282 (WebCore::StyleCachedImageSet::computeIntrinsicDimensions):
1284 New function on StyleImage returns the image's scale factor.
1285 * rendering/style/StyleCachedImageSet.h:
1286 (WebCore::StyleCachedImageSet::imageScaleFactor):
1287 * rendering/style/StyleImage.h:
1288 (WebCore::StyleImage::imageScaleFactor):
1290 Scale the intrinsic size of the background image down by the scale
1292 * rendering/RenderBoxModelObject.cpp:
1293 (WebCore::RenderBoxModelObject::calculateFillTileSize):
1295 Slices should be multiplied by the image's scale factor since they are
1296 always expected to the specified in the 1x image's coordinate space.
1297 (WebCore::RenderBoxModelObject::paintNinePieceImage):
1299 2012-04-30 Arko Saha <arko@motorola.com>
1301 Remove custom bindings code in JSHTMLCollectionCustom.cpp for HTMLPropertiesCollection.
1302 https://bugs.webkit.org/show_bug.cgi?id=85172
1304 Reviewed by Kentaro Hara.
1306 Use [JSGenerateToJSObject] in HTMLPropertiesCollection.idl, so that it can generate toJS()
1307 in JSHTMLPropertiesCollection.cpp automatically.
1309 * bindings/js/JSHTMLCollectionCustom.cpp:
1311 * html/HTMLPropertiesCollection.idl:
1313 2012-04-30 No'am Rosenthal <noam.rosenthal@nokia.com>
1315 [Texmap] TextureMapperLayer uses intermediate surfaces too eagerly
1316 https://bugs.webkit.org/show_bug.cgi?id=85103
1318 Reviewed by Kenneth Rohde Christiansen.
1320 Instead of automatically using an intermediate surface for layers with opacity and
1321 children, we limit surface usage for layers with more than one child and for layers with
1322 one child and contents of its own.
1324 This prevents us from using intermediate surfaces in cases where a single layer with
1325 opacity has a single descendant with content, in which case normal blending can be used.
1327 Covered by existing compositing layout tests.
1329 * platform/graphics/texmap/TextureMapperLayer.cpp:
1331 * platform/graphics/texmap/TextureMapperLayer.h:
1333 2012-04-30 Yi Shen <yi.4.shen@nokia.com>
1335 Inserting a paragraph between quoted lines in editing/deleting/delete-4038408-fix.html doesn't work
1336 https://bugs.webkit.org/show_bug.cgi?id=78193
1338 Reviewed by Ryosuke Niwa.
1340 When pasting a copied portion of a blockquote with a newline at the end into an unquoted area,
1341 the newline is inserted after the blockquote since we don't want it also to be quoted. However,
1342 this behavior has also applied when we insert a paragraph between quoted lines, which is incorrect.
1343 To figure out the right place to insert a paragraph, we need providing more information to the
1344 InsertParagraphSeparatorCommand by introducing a boolean parameter "pasteBlockqutoeIntoUnquotedArea".
1346 Tests: editing/inserting/insert-paragraph-separator-in-blockquote.html
1347 editing/pasteboard/paste-wrapped-blockquote-into-nonblockquote.html
1349 * editing/CompositeEditCommand.cpp:
1350 (WebCore::CompositeEditCommand::insertParagraphSeparator):
1351 * editing/CompositeEditCommand.h:
1352 (CompositeEditCommand):
1353 * editing/InsertParagraphSeparatorCommand.cpp:
1354 (WebCore::InsertParagraphSeparatorCommand::InsertParagraphSeparatorCommand):
1355 (WebCore::InsertParagraphSeparatorCommand::doApply):
1356 * editing/InsertParagraphSeparatorCommand.h:
1357 (WebCore::InsertParagraphSeparatorCommand::create):
1358 (InsertParagraphSeparatorCommand):
1359 * editing/ReplaceSelectionCommand.cpp:
1360 (WebCore::ReplaceSelectionCommand::doApply):
1362 2012-04-30 Antti Koivisto <antti@apple.com>
1364 Protect current element in HTMLLinkElement::setCSSStyleSheet
1365 https://bugs.webkit.org/show_bug.cgi?id=85166
1367 Reviewed by Andreas Kling.
1369 Stylesheet loading can trigger script execution.
1371 Test: fast/css/cached-sheet-restore-crash.html
1373 * html/HTMLLinkElement.cpp:
1374 (WebCore::HTMLLinkElement::setCSSStyleSheet):
1376 2012-04-29 Keishi Hattori <keishi@webkit.org>
1378 Build fix for LocalizedDateMac.mm
1379 https://bugs.webkit.org/show_bug.cgi?id=85164
1381 Reviewed by Kent Tamura.
1383 * platform/text/mac/LocalizedDateMac.mm:
1384 (WebCore::monthLabels):
1386 2012-04-29 Luke Macpherson <macpherson@chromium.org>
1388 Initialize member variables in CSSParser's constructor.
1389 https://bugs.webkit.org/show_bug.cgi?id=84377
1391 Reviewed by Kentaro Hara.
1393 It is good practice not to leave member variables uninitialized. They make debugging more difficult by reducing
1394 repeatability, and in some cases lead to the possibility of information leakage occuring. This patch simply adds
1395 initialization of m_numParsedPropertiesBeforeMarginBox to CSSParser's constructor to INVALID_NUM_PARSED_PROPERTIES
1396 so that the initial state is the same as the state after the properties are cleared.
1398 No tests added because this is a code style fix, not an actual bug so long as the bison generated code calls
1399 startDeclarationsForMarginBox() and endDeclarationsForMarginBox() symmetrically. The lack of initialization was
1400 originally detected by coverity.
1402 * css/CSSParser.cpp:
1403 (WebCore::CSSParser::CSSParser):
1405 2012-04-29 Kent Tamura <tkent@chromium.org>
1407 [Mac] Add LocalizedDateMac
1408 https://bugs.webkit.org/show_bug.cgi?id=85039
1410 Reviewed by Kentaro Hara.
1412 A date shown <input type=date> should be formatted for user's OS
1413 settings. Chromium-Mac used LocalizedDateICU.cpp to format/parse visible
1414 date strings and it didn't reflect user-settings.
1416 Test: covered by fast/forms/date/date-appearance.html
1418 * WebCore.gyp/WebCore.gyp:
1419 Use LocalizedDateMac.mm for OS X instead of LocalizedDateICU.cpp.
1420 * WebCore.gypi: Add LocalizedDateMac.mm
1421 * platform/text/mac/LocalizedDateMac.mm: Added.
1422 (WebCore::createShortDateFormatter):
1423 Creates a NSDateFormatter with desired settings.
1424 (WebCore::parseLocalizedDate): Impelment for tyep=date.
1425 (WebCore::formatLocalizedDate): ditto.
1426 (WebCore::isYearSymbol): A readability helper for format string parsing.
1427 (WebCore::isMonthSymbol): ditto.
1428 (WebCore::isDaySymbol): ditto.
1429 (WebCore::localizeDateFormat):
1430 Parse a format string, and replace symbols with user-friendly labels.
1431 (WebCore::localizedDateFormatText):
1432 Gets a format string, and apply localizeDateFormat().
1433 (WebCore::monthLabels): Obtain month names from the system.
1434 (WebCore::weekDayShortLabels): Obtain week day symbols from the system.
1435 (WebCore::firstDayOfWeek): Obtain first day of week from the system.
1436 * platform/text/ICULocale.cpp:
1437 (WebCore::createFallbackMonthLabels): Uses WTF::monthFullName.
1439 2012-04-29 Sam Weinig <sam@webkit.org>
1441 Add support for the Blob constructor (Part 2)
1442 https://bugs.webkit.org/show_bug.cgi?id=84555
1444 Address additional feedback on Blob construction.
1445 - Add exception when the dictionary is not an object.
1446 - Ensure the proper ordering of dictionary access. Tested via
1447 throwing exceptions in toString, and ensuring correct one is
1449 - Changed type of exception throw for invalid enumeration to a
1452 Reviewed by Kentaro Hara.
1454 Updated fast/files/blob-constructor.html to be more comprehensive.
1456 * bindings/js/JSBlobCustom.cpp:
1457 (WebCore::JSBlobConstructor::constructJSBlob):
1458 * bindings/v8/custom/V8BlobCustom.cpp:
1459 (WebCore::V8Blob::constructorCallback):
1461 2012-04-29 No'am Rosenthal <noam.rosenthal@nokia.com>
1463 [Texmap] Leaves demo: wrong geometry when opacity animation kicks in
1464 https://bugs.webkit.org/show_bug.cgi?id=85096
1466 Reviewed by Kenneth Rohde Christiansen.
1468 We should use combined() instead of combinedForChildren() since we don't allow
1469 intermediate surfaces for preserves-3d. Also, we should apply the offset before
1470 multiplying the transforms, otherwise the transform-origin is incorrect.
1472 Covered by existing compositing tests.
1474 * platform/graphics/texmap/TextureMapperLayer.cpp:
1475 (WebCore::TextureMapperLayer::paintSelf):
1476 (WebCore::TextureMapperLayer::paintRecursive):
1478 2012-04-29 Mark Pilgrim <pilgrim@chromium.org>
1480 [Chromium] Call highUsageDeltaMB directly
1481 https://bugs.webkit.org/show_bug.cgi?id=84844
1483 Reviewed by Kentaro Hara.
1485 Part of a refactoring series. See tracking bug 82948.
1487 * bindings/v8/V8GCController.cpp:
1488 (WebCore::V8GCController::checkMemoryUsage):
1489 * platform/MemoryUsageSupport.cpp:
1491 (WebCore::MemoryUsageSupport::highUsageDeltaMB):
1492 * platform/MemoryUsageSupport.h:
1493 (MemoryUsageSupport):
1494 * platform/chromium/MemoryUsageSupportChromium.cpp:
1495 (WebCore::MemoryUsageSupport::highUsageDeltaMB):
1497 * platform/chromium/PlatformSupport.h:
1500 2012-04-29 Kentaro Hara <haraken@chromium.org>
1502 REGRESSION(r113086): onresize event handler can be deleted in popup window
1503 https://bugs.webkit.org/show_bug.cgi?id=84908
1505 Reviewed by Ojan Vafai.
1507 In a nutshell, an onresize event handler in the popup window
1508 can be non-deterministically deleted. For more details, please
1509 look at Chromium issue 123642:
1510 http://code.google.com/p/chromium/issues/detail?id=123642
1512 I confirmed that this bug is the regression caused by r113086.
1514 r113086 introduced the following code:
1516 void V8LazyEventListener::prepareListenerObject(...) {
1517 if (hasExistingListenerObject())
1520 // Since we only parse once, there's no need to keep data
1521 // used for parsing around anymore.
1522 m_functionName = String();
1524 m_eventParameterName = String();
1525 m_sourceURL = String();
1527 setListenerObject(wrappedFunction);
1530 This is not correct. The parsing can be done more than once,
1531 and thus we cannot clear data. This patch removes the above code.
1533 Consider the following situation:
1535 (1) Assume '<body onresize="f()"></body>'.
1536 (2) prepareListenerObject() runs.
1537 (3) Since this is the first parsing, hasExistingListenerObject()
1538 returns false. After the parsing, the listener object is set
1539 by setListenerObject().
1540 (4) GC runs. Since there is no strong reference to the listener
1541 object, weakEventListenerCallback() is called back, and the listener
1543 (5) A resize event is triggered.
1544 (6) prepareListenerObject() is called again. Since the listener object
1545 is already disposed, hasExistingListenerObject() returns false,
1546 and the second parsing starts.
1548 In my investigation, the above situation is happening in the reported
1549 Chromium bug. Anyway, I am sure that potentially the parsing can be
1550 done more than once, and thus we must keep m_xxxx data.
1552 However, this is just a temporary fix. We should fix the code so that
1553 an alive event listener object is never reclaimed.
1554 See https://bugs.webkit.org/show_bug.cgi?id=85152 for more details.
1556 No tests: I tried hard to create a DRT test, but could not.
1557 The bug depends on the behavior of GC, and thus the reported bug is
1558 non-deterministic. For example, (as explained in the Chromium issue,)
1559 the bug does not happen if we load an HTML from network because
1560 the network latency hides the bug. Also the bug happens in the
1561 popup window only. If we open the reported HTML in the main window,
1562 we cannot reproduce the bug.
1564 * bindings/v8/V8LazyEventListener.cpp:
1565 (WebCore::V8LazyEventListener::prepareListenerObject):
1567 2012-04-28 Sam Weinig <sam@webkit.org>
1569 Smooth scrolling needs a new key
1570 <rdar://problem/11331632>
1572 Reviewed by Geoffrey Garen.
1574 * platform/mac/ScrollAnimatorMac.mm:
1575 (WebCore::scrollAnimationEnabledForSystem):
1576 (WebCore::ScrollAnimatorMac::scroll):
1579 2012-04-28 Li Yin <li.yin@intel.com>
1581 MessagePort must set m_closed to be true at the end of MessagePort::close function
1582 https://bugs.webkit.org/show_bug.cgi?id=85139
1584 In the function MessagePort::close, the "m_closed = true" must be executed at the end, not at the beginning.
1585 Or, the m_entangledChannel->close() will not be executed.
1586 And it resulted in the failure of MS bench mark messagechannel_close.htm.
1587 http://samples.msdn.microsoft.com/ietestcenter/WebWorkers/messagechannel_close.htm
1589 Reviewed by Kentaro Hara.
1591 Test: fast/events/message-port-close.html
1593 * dom/MessagePort.cpp:
1594 (WebCore::MessagePort::close):
1596 2012-04-28 Sam Weinig <sam@webkit.org>
1600 * bindings/v8/custom/V8BlobCustom.cpp:
1601 (WebCore::V8Blob::constructorCallback):
1603 2012-04-28 Sam Weinig <sam@webkit.org>
1605 Once again, try to make these puppies work.
1607 * bindings/v8/custom/V8BlobCustom.cpp:
1609 2012-04-28 Sam Weinig <sam@webkit.org>
1611 Fix the Chromium build.
1613 * bindings/v8/custom/V8BlobCustom.cpp:
1614 (WebCore::V8Blob::constructorCallback):
1616 2012-04-27 Sam Weinig <sam@webkit.org>
1618 Add support for the Blob constructor
1619 https://bugs.webkit.org/show_bug.cgi?id=84555
1621 Reviewed by Maciej Stachowiak.
1623 Test: fast/files/blob-constructor.html
1625 This adds an implementation of the Blob constructor that willfully
1626 violates the W3C Editor’s Draft 29 February 2012 in the following ways:
1627 - Elements in the parts array are coerced to DOMStrings https://www.w3.org/Bugs/Public/show_bug.cgi?id=16721
1628 - Don't throw for invalid key in the dictionary https://www.w3.org/Bugs/Public/show_bug.cgi?id=16727
1629 - Values for the endings property are treated as enums https://www.w3.org/Bugs/Public/show_bug.cgi?id=16729
1631 * bindings/js/JSBlobCustom.cpp:
1632 (WebCore::JSBlobConstructor::constructJSBlob):
1633 Implement blob constructor.
1635 * bindings/v8/custom/V8BlobCustom.cpp:
1636 (WebCore::V8Blob::constructorCallback):
1637 Implement blob constructor.
1640 Add constructor to IDL.
1642 * workers/WorkerContext.idl:
1643 Add Blob constructor to the worker global object.
1645 2012-04-28 Igor Oliveira <igor.o@sisa.samsung.com>
1647 Move PropertyWrapper out of the AnimationBase
1648 https://bugs.webkit.org/show_bug.cgi?id=84978
1650 Reviewed by Dean Jackson.
1652 AnimationBase is a complex class. It has a state machine and a bunch of
1653 property handlers. This patch moves the property handlers to a separate
1654 class making AnimationBase simpler.
1657 * GNUmakefile.list.am:
1660 * WebCore.vcproj/WebCore.vcproj:
1661 * WebCore.xcodeproj/project.pbxproj:
1662 * page/animation/AnimationBase.cpp:
1663 * page/animation/AnimationBase.h:
1665 * page/animation/AnimationController.cpp:
1666 (WebCore::AnimationController::supportsAcceleratedAnimationOfProperty):
1667 * page/animation/CSSPropertyAnimation.cpp: Added.
1669 (WebCore::blendFunc):
1670 (WebCore::crossfadeBlend):
1671 (AnimationPropertyWrapperBase):
1672 (WebCore::AnimationPropertyWrapperBase::AnimationPropertyWrapperBase):
1673 (WebCore::AnimationPropertyWrapperBase::~AnimationPropertyWrapperBase):
1674 (WebCore::AnimationPropertyWrapperBase::isShorthandWrapper):
1675 (WebCore::AnimationPropertyWrapperBase::property):
1676 (WebCore::AnimationPropertyWrapperBase::animationIsAccelerated):
1677 (WebCore::addPropertyWrapper):
1678 (WebCore::wrapperForProperty):
1679 (PropertyWrapperGetter):
1680 (WebCore::PropertyWrapperGetter::PropertyWrapperGetter):
1681 (WebCore::PropertyWrapperGetter::equals):
1683 (WebCore::PropertyWrapper::PropertyWrapper):
1684 (WebCore::PropertyWrapper::blend):
1685 (RefCountedPropertyWrapper):
1686 (WebCore::RefCountedPropertyWrapper::RefCountedPropertyWrapper):
1687 (WebCore::RefCountedPropertyWrapper::blend):
1688 (StyleImagePropertyWrapper):
1689 (WebCore::StyleImagePropertyWrapper::StyleImagePropertyWrapper):
1690 (WebCore::StyleImagePropertyWrapper::equals):
1691 (PropertyWrapperColor):
1692 (WebCore::PropertyWrapperColor::PropertyWrapperColor):
1693 (WebCore::PropertyWrapperColor::blend):
1694 (PropertyWrapperAcceleratedOpacity):
1695 (WebCore::PropertyWrapperAcceleratedOpacity::PropertyWrapperAcceleratedOpacity):
1696 (WebCore::PropertyWrapperAcceleratedOpacity::animationIsAccelerated):
1697 (WebCore::PropertyWrapperAcceleratedOpacity::blend):
1698 (PropertyWrapperAcceleratedTransform):
1699 (WebCore::PropertyWrapperAcceleratedTransform::PropertyWrapperAcceleratedTransform):
1700 (WebCore::PropertyWrapperAcceleratedTransform::animationIsAccelerated):
1701 (WebCore::PropertyWrapperAcceleratedTransform::blend):
1702 (PropertyWrapperAcceleratedFilter):
1703 (WebCore::PropertyWrapperAcceleratedFilter::PropertyWrapperAcceleratedFilter):
1704 (WebCore::PropertyWrapperAcceleratedFilter::animationIsAccelerated):
1705 (WebCore::PropertyWrapperAcceleratedFilter::blend):
1706 (WebCore::shadowListLength):
1707 (WebCore::shadowForBlending):
1708 (PropertyWrapperShadow):
1709 (WebCore::PropertyWrapperShadow::PropertyWrapperShadow):
1710 (WebCore::PropertyWrapperShadow::equals):
1711 (WebCore::PropertyWrapperShadow::blend):
1712 (WebCore::PropertyWrapperShadow::blendSimpleOrMatchedShadowLists):
1713 (WebCore::PropertyWrapperShadow::blendMismatchedShadowLists):
1714 (PropertyWrapperMaybeInvalidColor):
1715 (WebCore::PropertyWrapperMaybeInvalidColor::PropertyWrapperMaybeInvalidColor):
1716 (WebCore::PropertyWrapperMaybeInvalidColor::equals):
1717 (WebCore::PropertyWrapperMaybeInvalidColor::blend):
1718 (PropertyWrapperVisitedAffectedColor):
1719 (WebCore::PropertyWrapperVisitedAffectedColor::PropertyWrapperVisitedAffectedColor):
1720 (WebCore::PropertyWrapperVisitedAffectedColor::equals):
1721 (WebCore::PropertyWrapperVisitedAffectedColor::blend):
1722 (FillLayerAnimationPropertyWrapperBase):
1723 (WebCore::FillLayerAnimationPropertyWrapperBase::FillLayerAnimationPropertyWrapperBase):
1724 (WebCore::FillLayerAnimationPropertyWrapperBase::~FillLayerAnimationPropertyWrapperBase):
1725 (FillLayerPropertyWrapperGetter):
1726 (WebCore::FillLayerPropertyWrapperGetter::FillLayerPropertyWrapperGetter):
1727 (WebCore::FillLayerPropertyWrapperGetter::equals):
1728 (FillLayerPropertyWrapper):
1729 (WebCore::FillLayerPropertyWrapper::FillLayerPropertyWrapper):
1730 (WebCore::FillLayerPropertyWrapper::blend):
1731 (FillLayerRefCountedPropertyWrapper):
1732 (WebCore::FillLayerRefCountedPropertyWrapper::FillLayerRefCountedPropertyWrapper):
1733 (WebCore::FillLayerRefCountedPropertyWrapper::blend):
1734 (FillLayerStyleImagePropertyWrapper):
1735 (WebCore::FillLayerStyleImagePropertyWrapper::FillLayerStyleImagePropertyWrapper):
1736 (WebCore::FillLayerStyleImagePropertyWrapper::equals):
1737 (FillLayersPropertyWrapper):
1738 (WebCore::FillLayersPropertyWrapper::FillLayersPropertyWrapper):
1739 (WebCore::FillLayersPropertyWrapper::equals):
1740 (WebCore::FillLayersPropertyWrapper::blend):
1741 (ShorthandPropertyWrapper):
1742 (WebCore::ShorthandPropertyWrapper::ShorthandPropertyWrapper):
1743 (WebCore::ShorthandPropertyWrapper::isShorthandWrapper):
1744 (WebCore::ShorthandPropertyWrapper::equals):
1745 (WebCore::ShorthandPropertyWrapper::blend):
1746 (WebCore::ShorthandPropertyWrapper::propertyWrappers):
1747 (PropertyWrapperFlex):
1748 (WebCore::PropertyWrapperFlex::PropertyWrapperFlex):
1749 (WebCore::PropertyWrapperFlex::equals):
1750 (WebCore::PropertyWrapperFlex::blend):
1751 (PropertyWrapperSVGPaint):
1752 (WebCore::PropertyWrapperSVGPaint::PropertyWrapperSVGPaint):
1753 (WebCore::PropertyWrapperSVGPaint::equals):
1754 (WebCore::PropertyWrapperSVGPaint::blend):
1755 (WebCore::addShorthandProperties):
1756 (WebCore::CSSPropertyAnimation::ensurePropertyMap):
1757 (WebCore::gatherEnclosingShorthandProperties):
1758 (WebCore::CSSPropertyAnimation::blendProperties):
1759 (WebCore::CSSPropertyAnimation::animationOfPropertyIsAccelerated):
1760 (WebCore::CSSPropertyAnimation::animatableShorthandsAffectingProperty):
1761 (WebCore::CSSPropertyAnimation::propertiesEqual):
1762 (WebCore::CSSPropertyAnimation::getPropertyAtIndex):
1763 (WebCore::CSSPropertyAnimation::getNumProperties):
1764 * page/animation/CSSPropertyAnimation.h: Added.
1766 (CSSPropertyAnimation):
1767 * page/animation/CompositeAnimation.cpp:
1768 (WebCore::CompositeAnimation::updateTransitions):
1769 (WebCore::CompositeAnimation::pauseTransitionAtTime):
1770 * page/animation/ImplicitAnimation.cpp:
1771 (WebCore::ImplicitAnimation::animate):
1772 (WebCore::ImplicitAnimation::getAnimatedStyle):
1773 (WebCore::ImplicitAnimation::isTargetPropertyEqual):
1774 (WebCore::ImplicitAnimation::blendPropertyValueInStyle):
1775 (WebCore::ImplicitAnimation::timeToNextService):
1776 * page/animation/KeyframeAnimation.cpp:
1777 (WebCore::KeyframeAnimation::animate):
1778 (WebCore::KeyframeAnimation::getAnimatedStyle):
1779 (WebCore::KeyframeAnimation::timeToNextService):
1780 * rendering/style/RenderStyle.h:
1782 2012-04-28 Geoffrey Garen <ggaren@apple.com>
1784 Clarified JSGlobalData (JavaScript VM) lifetime
1785 https://bugs.webkit.org/show_bug.cgi?id=85142
1787 Reviewed by Anders Carlsson.
1789 * bindings/js/WorkerScriptController.cpp:
1790 (WebCore::WorkerScriptController::~WorkerScriptController): Slightly
1791 simpler than before. We can't just rely on our default destructor
1792 because we need to hold the JSLock when we tear down the VM.
1794 * bridge/NP_jsobject.cpp:
1795 (_NPN_InvokeDefault):
1798 (_NPN_Construct): Don't RefPtr<> the JSGlobalData because it makes it
1799 seem like you know something the rest of our code doesn't know. The
1800 plugin JSGlobalData is immortal, anyway.
1802 I also removed some timeout checker related code because that feature
1803 doesn't work anymore, so it was effectively dead code.
1805 2012-04-28 Ilya Tikhonovsky <loislo@chromium.org>
1807 Web Inspector: InspectorFrontendHost.append has to be implemented for saving heap snapshots.
1808 https://bugs.webkit.org/show_bug.cgi?id=85137
1810 We can save a file with help of InspectorFrontendHost.save method,
1811 but it is suitable only for relatively small portions of data and
1812 can't process the 6Gb heap snapshot.
1813 These methods just pass the url and content into embedder.
1815 Reviewed by Yury Semikhatsky.
1817 * inspector/InspectorFrontendClient.h:
1818 (InspectorFrontendClient):
1819 * inspector/InspectorFrontendClientLocal.h:
1820 (WebCore::InspectorFrontendClientLocal::append):
1821 * inspector/InspectorFrontendHost.cpp:
1822 (WebCore::InspectorFrontendHost::append):
1824 * inspector/InspectorFrontendHost.h:
1825 (InspectorFrontendHost):
1826 * inspector/InspectorFrontendHost.idl:
1828 2012-04-28 No'am Rosenthal <noam.rosenthal@nokia.com>
1830 [Qt][Texmap] Error of cross-compiling webkit with Qt 4.8.1
1831 https://bugs.webkit.org/show_bug.cgi?id=84321
1833 Speculative build-fix for Qt 4.8.
1834 Use QGLContext for Qt 4.x instead of the platform-specific context.
1836 Reviewed by Simon Hausmann.
1838 No new tests, build fix.
1840 * platform/graphics/texmap/TextureMapperGL.cpp:
1842 (WebCore::TextureMapperGLData::SharedGLData::getCurrentGLContext):
1844 2012-04-28 No'am Rosenthal <noam.rosenthal@nokia.com>
1846 [Texmap] Falling leaves demo missing opacity fade out animation
1847 https://bugs.webkit.org/show_bug.cgi?id=83691
1849 Reviewed by Martin Robinson.
1851 The bug originated from clearing an intermediate surface with glClear while the scissor
1853 When using intermediate surfaces, maintain a clip-stack for each surface, rather than
1854 a single clip-stack for the whole scene. When a surface is bound, its clip stack should
1857 Covered by existing compositing tests.
1859 * platform/graphics/texmap/TextureMapperGL.cpp:
1861 (WebCore::TextureMapperGL::ClipStack::push):
1863 (WebCore::TextureMapperGL::ClipStack::pop):
1864 (WebCore::scissorClip):
1865 (WebCore::TextureMapperGL::ClipStack::apply):
1866 (WebCore::TextureMapperGL::clipStack):
1867 (WebCore::TextureMapperGL::beginPainting):
1868 (WebCore::TextureMapperGL::drawTexture):
1869 (WebCore::BitmapTextureGL::didReset):
1870 (WebCore::BitmapTextureGL::clearIfNeeded):
1871 (WebCore::BitmapTextureGL::createFboIfNeeded):
1872 (WebCore::BitmapTextureGL::bind):
1873 (WebCore::TextureMapperGL::bindDefaultSurface):
1874 (WebCore::TextureMapperGL::bindSurface):
1875 (WebCore::TextureMapperGL::beginScissorClip):
1876 (WebCore::TextureMapperGL::beginClip):
1877 (WebCore::TextureMapperGL::endClip):
1878 * platform/graphics/texmap/TextureMapperGL.h:
1881 (WebCore::TextureMapperGL::ClipState::ClipState):
1883 (WebCore::TextureMapperGL::ClipStack::current):
1884 (WebCore::TextureMapperGL::ClipStack::clear):
1886 (WebCore::BitmapTextureGL::BitmapTextureGL):
1888 2012-04-26 Emil A Eklund <eae@chromium.org> and Levi Weintraub <leviw@chromium.org>
1890 Move Length and CSS length computation to float
1891 https://bugs.webkit.org/show_bug.cgi?id=84801
1893 Reviewed by Eric Seidel.
1895 Change Length and CSS length computation to floating point. This gets us
1896 closer to the goal of supporting subpixel layout and improves precision
1897 for SVG which already uses floating point for its layout.
1899 This change makes computedStyle return fractional values for pixel values
1900 if a fraction is specified. It also changes the result of computations
1901 where two or more values with fractional precision. Prior to this change
1902 the result of Length(2.9) + Length(2.9) would be 4 as each value would be
1903 floored. With this change the result is 5 as the addition is done with
1904 floating point precision and then the result will be floored. Once we
1905 enable subpixel layout the resulting value in this example would be 5.8.
1907 Updated existing layout tests.
1909 * css/CSSComputedStyleDeclaration.cpp:
1910 (WebCore::zoomAdjustedPixelValue):
1911 * css/CSSPrimitiveValue.cpp:
1912 (WebCore::CSSPrimitiveValue::computeLength):
1913 * css/CSSPrimitiveValue.h:
1915 (WebCore::roundForImpreciseConversion):
1916 Add specialized float version of roundForImpreciseConversion that matches
1917 the int versions rounding logic.
1919 If a value is sufficiently close to the next integer round it up to
1920 ensure that a style rule such as "width: 4.999px" evaluates to 5px
1921 instead of 4px. This is needed as, although Lengths are using floating
1922 point, the layout system still uses integer precision and floors the
1924 This will change once we move to FractionalLayoutUnits but for now this
1925 is needed to ensure compatibility with the existing system and tests.
1927 Without this specialized rounding logic we fail a handful of tests
1930 * platform/Length.h:
1931 (WebCore::Length::value):
1933 (WebCore::Length::intValue):
1934 * rendering/RenderTableCell.cpp:
1935 (WebCore::RenderTableCell::styleOrColLogicalWidth):
1937 2012-04-28 Alexander Pavlov <apavlov@chromium.org>
1939 Web Inspector: Enable touch events feature fails touch feature detection
1940 https://bugs.webkit.org/show_bug.cgi?id=84397
1942 Whenever the touch emulation is enabled, Inspector adds a script to evaluate on load,
1943 that adds ontouch(start|end|move|cancel) properties to window.__proto__ and document.__proto__.
1945 Reviewed by Pavel Feldman.
1947 * inspector/front-end/DOMAgent.js:
1948 (WebInspector.DOMAgent.prototype._emulateTouchEventsChanged.get if):
1949 (WebInspector.DOMAgent.prototype._emulateTouchEventsChanged.scriptAddedCallback):
1950 (WebInspector.DOMAgent.prototype._emulateTouchEventsChanged):
1951 * inspector/front-end/inspector.js:
1953 2012-04-28 Eugene Klyuchnikov <eustas.bug@gmail.com>
1955 Web Inspector: Shortcuts screen UI polish
1956 https://bugs.webkit.org/show_bug.cgi?id=84708
1958 1) remove inconsistent shadow;
1959 2) reduce border radius;
1960 3) vertically center the “X” button;
1961 4) replace unreadable symbolic shortcuts with text;
1962 5) gaps / colors / opacity adjustments;
1963 6) section-to-column distribution algorithm is replaced with a fair one.
1965 Reviewed by Pavel Feldman.
1967 This is a UI polising patch, so no new tests added.
1969 * English.lproj/localizedStrings.js: added keyboars arrow keys items
1970 * inspector/front-end/KeyboardShortcut.js: replace unreadable symbolic shortcuts with text
1971 * inspector/front-end/ShortcutsScreen.js:
1972 (WebInspector.ShortcutsScreen):
1973 (WebInspector.ShortcutsScreen.prototype.show): remove redundant parameter
1974 (WebInspector.ShortcutsScreen.prototype._buildTable): change section distributing algorithm
1975 (WebInspector.ShortcutsSection.prototype.renderSection): render colon with margins
1976 (WebInspector.ShortcutsSection.prototype._renderHeader): apply classname to th elements
1977 * inspector/front-end/helpScreen.css:
1978 (.help-window-main): reduce radius, remove shadow; tune color and opacity
1979 (.help-window-caption): fix spacing; add ruler
1980 (.help-window-title): fix spacing; remove ruler
1981 (.help-content): fix spacing
1982 (.help-close-button): fix spacing; adjust background color
1983 (.help-column-table): fix spacing
1984 (.help-table > tr > th): fix color
1985 (.help-key): fix color
1986 (.help-combine-keys, .help-key-delimiter): extract common style
1987 (.help-combine-keys): remove dupe
1988 (.help-section-title): add space between sections
1990 2012-04-28 Noel Gordon <noel.gordon@gmail.com>
1992 Remove PlatformTouchPointQt.cpp PlatformTouchEventQt.cpp from the gyp projects
1993 https://bugs.webkit.org/show_bug.cgi?id=85132
1995 Unreviewed VS2010 gyp project generation fix.
1997 PlatformTouchPointQt.cpp and PlatformTouchEventQt.cpp were removed in r115312,
1998 so remove them from the gyp projects.
2002 2012-04-28 Nikolas Zimmermann <nzimmermann@rim.com>
2004 <animateTransform type="scale"> should use '0' as effective from value not '1', if no base value is specified and from is not given
2005 https://bugs.webkit.org/show_bug.cgi?id=85133
2007 It should start from scale=0. I had that fixed before, but it got lost during merging. Restore the fix.
2008 See bug 85051, for more context why this is correct.
2010 Tests: svg/animations/animateTransform-by-scale-1-expected.svg
2011 svg/animations/animateTransform-by-scale-1.svg
2013 * svg/SVGAnimatedTransformList.cpp:
2014 (WebCore::SVGAnimatedTransformListAnimator::calculateAnimatedValue):
2016 2012-04-28 Nikolas Zimmermann <nzimmermann@rim.com>
2018 SVGAnimateColorElement doesn't support by/to animations properly
2019 https://bugs.webkit.org/show_bug.cgi?id=36704
2021 Reviewed by Antti Koivisto.
2023 Switch AnimatedColorAnimator to use the standard animateAdditiveNumber() method, taking progress & repeatCount into account.
2024 This gives us accumulation/repeatCount support for free.
2026 We just animate the four color components on their own now and clamp once at the end after addition/accumulation finished.
2027 Import <animateColor> tests from Dr. Olaf Hoffmanns SVG Animation test suite, which all pass now.
2029 While I was at it, remove the includeSMILProperties boolean from computeCSSPropertyValue - we always use the computed style
2030 without SMIL effects included, whenever we want to retrieve the "base value", or handle "inherit/currentColor".
2032 Tests: svg/animations/animateColor-additive-2a-expected.svg
2033 svg/animations/animateColor-additive-2a.svg
2034 svg/animations/animateColor-additive-2b-expected.svg
2035 svg/animations/animateColor-additive-2b.svg
2036 svg/animations/animateColor-additive-2c-expected.svg
2037 svg/animations/animateColor-additive-2c.svg
2038 svg/animations/animateColor-additive-2d-expected.svg
2039 svg/animations/animateColor-additive-2d.svg
2041 * svg/ColorDistance.cpp:
2042 (WebCore::ColorDistance::clampColor):
2043 (WebCore::ColorDistance::addColors):
2044 (WebCore::ColorDistance::addToColor):
2045 * svg/ColorDistance.h:
2047 * svg/SVGAnimateElement.cpp:
2048 (WebCore::SVGAnimateElement::resetToBaseValue):
2049 * svg/SVGAnimatedColor.cpp:
2050 (WebCore::SVGAnimatedColorAnimator::addAnimatedTypes):
2051 (WebCore::SVGAnimatedColorAnimator::calculateAnimatedValue):
2052 * svg/SVGAnimationElement.cpp:
2053 (WebCore::SVGAnimationElement::computeCSSPropertyValue):
2054 (WebCore::SVGAnimationElement::adjustForInheritance):
2055 * svg/SVGAnimationElement.h:
2056 (SVGAnimationElement):
2058 2012-04-28 Nikolas Zimmermann <nzimmermann@rim.com>
2060 Not reviewed. Fix Qt build -- I was too quick.
2062 * rendering/svg/SVGPathData.cpp: Add back Path.h include.
2064 2012-04-28 Nikolas Zimmermann <nzimmermann@rim.com>
2066 Rename SVGPathParserFactory to SVGPathUtilities and remove the obsolete singleton
2067 https://bugs.webkit.org/show_bug.cgi?id=85129
2069 SVGPathParserFactory implements the singleton pattern, but stores no members.
2070 Remove the singleton and move all functions to free-functions into SVGPathUtilities.h.
2072 Makes the code easier to read - doesn't affect any tests.
2075 * GNUmakefile.list.am:
2078 * WebCore.vcproj/WebCore.vcproj:
2079 * WebCore.xcodeproj/project.pbxproj:
2080 * rendering/svg/SVGPathData.cpp:
2081 (WebCore::updatePathFromPathElement):
2082 * rendering/svg/SVGRenderTreeAsText.cpp:
2083 (WebCore::operator<<):
2084 * svg/SVGAllInOne.cpp:
2085 * svg/SVGAnimateMotionElement.cpp:
2086 (WebCore::SVGAnimateMotionElement::parseAttribute):
2087 * svg/SVGAnimatedPath.cpp:
2088 (WebCore::SVGAnimatedPathAnimator::constructFromString):
2089 (WebCore::SVGAnimatedPathAnimator::startAnimValAnimation):
2090 (WebCore::SVGAnimatedPathAnimator::resetAnimValToBaseVal):
2091 (WebCore::SVGAnimatedPathAnimator::addAnimatedTypes):
2092 (WebCore::SVGAnimatedPathAnimator::calculateAnimatedValue):
2093 * svg/SVGAnimatedType.cpp:
2094 * svg/SVGGlyphElement.cpp:
2095 (WebCore::SVGGlyphElement::buildGenericGlyphIdentifier):
2096 * svg/SVGPathBlender.cpp: Fix typo s/;;/;/
2097 * svg/SVGPathElement.cpp:
2098 (WebCore::SVGPathElement::getTotalLength):
2099 (WebCore::SVGPathElement::getPointAtLength):
2100 (WebCore::SVGPathElement::getPathSegAtLength):
2101 (WebCore::SVGPathElement::parseAttribute):
2102 (WebCore::SVGPathElement::svgAttributeChanged):
2103 (WebCore::SVGPathElement::lookupOrCreateDWrapper):
2104 (WebCore::SVGPathElement::pathSegListChanged):
2105 * svg/SVGPathParserFactory.h: Removed.
2106 * svg/SVGPathSegList.cpp:
2107 (WebCore::SVGPathSegList::valueAsString):
2108 * svg/SVGPathUtilities.cpp: Renamed from Source/WebCore/svg/SVGPathParserFactory.cpp.
2110 (WebCore::globalSVGPathBuilder):
2111 (WebCore::globalSVGPathSegListBuilder):
2112 (WebCore::globalSVGPathByteStreamBuilder):
2113 (WebCore::globalSVGPathStringBuilder):
2114 (WebCore::globalSVGPathTraversalStateBuilder):
2115 (WebCore::globalSVGPathParser):
2116 (WebCore::globalSVGPathBlender):
2117 (WebCore::buildPathFromString):
2118 (WebCore::buildSVGPathByteStreamFromSVGPathSegList):
2119 (WebCore::buildPathFromByteStream):
2120 (WebCore::buildSVGPathSegListFromByteStream):
2121 (WebCore::buildStringFromByteStream):
2122 (WebCore::buildStringFromSVGPathSegList):
2123 (WebCore::buildSVGPathByteStreamFromString):
2124 (WebCore::buildAnimatedSVGPathByteStream):
2125 (WebCore::addToSVGPathByteStream):
2126 (WebCore::getSVGPathSegAtLengthFromSVGPathByteStream):
2127 (WebCore::getTotalLengthOfSVGPathByteStream):
2128 (WebCore::getPointAtLengthOfSVGPathByteStream):
2129 * svg/SVGPathUtilities.h: Added.
2131 * svg/properties/SVGAnimatedPathSegListPropertyTearOff.h:
2132 (WebCore::SVGAnimatedPathSegListPropertyTearOff::animValDidChange):
2134 2012-04-28 Nikolas Zimmermann <nzimmermann@rim.com>
2136 Fix repetitions & by animation support for path animations
2137 https://bugs.webkit.org/show_bug.cgi?id=85071
2139 Rubber-stamped by Antti Koivisto.
2141 Cleanup SVGPathBlender, to make it more readable.
2143 * svg/SVGPathBlender.cpp:
2144 (WebCore::SVGPathBlender::blendLineToHorizontalSegment):
2145 (WebCore::SVGPathBlender::blendLineToVerticalSegment):
2146 (WebCore::SVGPathBlender::blendArcToSegment):
2147 (WebCore::SVGPathBlender::blendAnimatedPath):
2149 2012-04-28 Yury Semikhatsky <yurys@chromium.org>
2151 Unreviewed. Qt build fix: added new exported symbols.
2155 2012-04-28 Yury Semikhatsky <yurys@chromium.org>
2157 Unreviewed. Fix Qt minimal build after r115553.
2159 * inspector/InspectorConsoleAgent.h:
2161 2012-04-27 Nikolas Zimmermann <nzimmermann@rim.com>
2163 Fix repetitions & by animation support for path animations
2164 https://bugs.webkit.org/show_bug.cgi?id=85071
2166 Reviewed by Antti Koivisto.
2168 Implement additive="sum" / by-animation support for path animations, eg.
2169 <path d="M 10 10 L 10 100 Z">
2170 <animate attributeName="d" begin="0s" dur="4s" by="M 0 0 L 90 0 Z"/>
2173 animates the d attribute to "M 10 10 L 100 100 0 Z".
2175 Now only <animateColor> and <animateMotion> are left to be fixed, all other types are working as expected now in all additive/accumulate/from-by/by/from-to animations.
2177 Tests: svg/animations/path-animation-expected.svg
2178 svg/animations/repeating-path-animation-expected.svg
2179 svg/animations/repeating-path-animation.svg
2181 * svg/SVGAnimatedPath.cpp:
2182 (WebCore::SVGAnimatedPathAnimator::addAnimatedTypes): Implemented, to support by-animations, instead of falling back to to-animations.
2183 (WebCore::SVGAnimatedPathAnimator::calculateAnimatedValue): Handle repetitions, accumulation & addition.
2184 * svg/SVGPathBlender.cpp: Allow empty from source everywhere, use default values if no from value is specified, needed for by-animations.
2185 (WebCore::SVGPathBlender::SVGPathBlender):
2186 (WebCore::SVGPathBlender::blendAnimatedDimensonalFloat):
2187 (WebCore::SVGPathBlender::blendAnimatedFloatPoint):
2188 (WebCore::SVGPathBlender::blendMoveToSegment):
2189 (WebCore::SVGPathBlender::blendLineToSegment):
2190 (WebCore::SVGPathBlender::blendLineToHorizontalSegment):
2191 (WebCore::SVGPathBlender::blendLineToVerticalSegment):
2192 (WebCore::SVGPathBlender::blendCurveToCubicSegment):
2193 (WebCore::SVGPathBlender::blendCurveToCubicSmoothSegment):
2194 (WebCore::SVGPathBlender::blendCurveToQuadraticSegment):
2195 (WebCore::SVGPathBlender::blendCurveToQuadraticSmoothSegment):
2196 (WebCore::SVGPathBlender::blendArcToSegment):
2197 (WebCore::SVGPathBlender::addAnimatedPath):
2198 (WebCore::SVGPathBlender::blendAnimatedPath):
2199 * svg/SVGPathBlender.h: Add new addAnimatedPath function.
2201 * svg/SVGPathByteStream.h:
2202 (SVGPathByteStream): Make SVGPathByteStreams copyable, needed for SVGAnimatedPathAnimator.
2203 (WebCore::SVGPathByteStream::size): Returns size of the SVGPathByteStream.
2204 * svg/SVGPathParserFactory.cpp:
2205 (WebCore::SVGPathParserFactory::buildAnimatedSVGPathByteStream): Allow empty from streams, needed for by animations.
2206 (WebCore::SVGPathParserFactory::addToSVGPathByteStream): Add 'byStream' 'repeatCount' times to 'toStream'. Both streams must match in size.
2207 * svg/SVGPathParserFactory.h: Add new addToSVGPathByteStream function.
2208 * svg/SVGPointList.cpp: Remove dead code.
2209 * svg/SVGPointList.h: Ditto.
2212 2012-04-28 Nikolas Zimmermann <nzimmermann@rim.com>
2214 SVGAnimateMotion does not handle accumulation
2215 https://bugs.webkit.org/show_bug.cgi?id=18564
2217 Reviewed by Antti Koivisto.
2219 Implement accumulation for <animateMotion>. Add lots of new
2220 reftests, verifying additive/accumulate behavior is correct.
2222 Tests: svg/animations/animateMotion-additive-1-expected.svg
2223 svg/animations/animateMotion-additive-1.svg
2224 svg/animations/animateMotion-additive-2a-expected.svg
2225 svg/animations/animateMotion-additive-2a.svg
2226 svg/animations/animateMotion-additive-2b-expected.svg
2227 svg/animations/animateMotion-additive-2b.svg
2228 svg/animations/animateMotion-additive-2c-expected.svg
2229 svg/animations/animateMotion-additive-2c.svg
2230 svg/animations/animateMotion-additive-2d-expected.svg
2231 svg/animations/animateMotion-additive-2d.svg
2232 svg/animations/mozilla/animateMotion-by-1-expected.svg
2233 svg/animations/mozilla/animateMotion-by-1.svg
2234 svg/animations/mozilla/animateMotion-from-to-1-expected.svg
2235 svg/animations/mozilla/animateMotion-from-to-1.svg
2236 svg/animations/mozilla/animateMotion-indefinite-to-1-expected.svg
2237 svg/animations/mozilla/animateMotion-indefinite-to-1.svg
2238 svg/animations/mozilla/animateMotion-indefinite-to-2-expected.svg
2239 svg/animations/mozilla/animateMotion-indefinite-to-2.svg
2240 svg/animations/mozilla/animateMotion-mpath-pathLength-1-expected.svg
2241 svg/animations/mozilla/animateMotion-mpath-pathLength-1.svg
2242 svg/animations/mozilla/animateMotion-mpath-targetChange-1-expected.svg
2243 svg/animations/mozilla/animateMotion-mpath-targetChange-1.svg
2244 svg/animations/mozilla/animateMotion-to-overridden-1-expected.svg
2245 svg/animations/mozilla/animateMotion-to-overridden-1.svg
2247 * svg/SVGAnimateMotionElement.cpp:
2248 (WebCore::SVGAnimateMotionElement::SVGAnimateMotionElement):
2249 (WebCore::SVGAnimateMotionElement::buildTransformForProgress):
2250 (WebCore::SVGAnimateMotionElement::calculateAnimatedValue):
2251 * svg/SVGAnimateMotionElement.h:
2253 2012-04-27 Yury Semikhatsky <yurys@chromium.org>
2255 ScriptStateProtectedPtr should not keep a strong reference to the context
2256 https://bugs.webkit.org/show_bug.cgi?id=85009
2258 Delete console message arguments when DOMWindow where the messages were created
2259 is reset on its frame.
2261 Reviewed by Pavel Feldman.
2263 Test: http/tests/inspector-enabled/console-clear-arguments-on-frame-navigation.html
2265 * inspector/ConsoleMessage.cpp:
2266 (WebCore::ConsoleMessage::addToFrontend):
2267 (WebCore::ConsoleMessage::windowCleared):
2268 (WebCore::ConsoleMessage::argumentCount):
2270 * inspector/ConsoleMessage.h:
2272 * inspector/InspectorConsoleAgent.cpp:
2273 (WebCore::InspectorConsoleAgent::consoleMessageArgumentCounts):
2275 * inspector/InspectorConsoleAgent.h:
2276 (InspectorConsoleAgent):
2278 (WebCore::Frame::clearDOMWindow):
2279 (WebCore::Frame::setDOMWindow):
2280 * testing/Internals.cpp:
2282 (WebCore::Internals::consoleMessageArgumentCounts):
2283 * testing/Internals.h:
2285 * testing/Internals.idl:
2287 2012-04-27 Jochen Eisinger <jochen@chromium.org>
2289 Ensure that there's always a provisional document loader if the frame loader is in provisional state
2290 https://bugs.webkit.org/show_bug.cgi?id=83894
2292 Reviewed by Nate Chapin.
2294 We're still seeing crashes in the FrameLoader where the FrameLoader's
2295 state is "provisional" but there is no provisional document loader. I
2296 added code to update the FrameLoader's state everytime the provisional
2297 document loader is cleared, and added checks that the FrameLoader's
2298 state can't be set to provisional without a provisional loader.
2300 If the crashes go away, or the newly added checks reveal the culprit,
2301 we should relex the checks to use ASSERT() instead of CRASH().
2303 * loader/FrameLoader.cpp:
2304 (WebCore::FrameLoader::init):
2305 (WebCore::FrameLoader::setupForReplace):
2306 (WebCore::FrameLoader::stopAllLoaders):
2307 (WebCore::FrameLoader::clearProvisionalLoad):
2308 (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
2309 (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
2311 2012-04-27 Geoffrey Garen <ggaren@apple.com>
2313 Try to fix the Qt build.
2315 * bridge/qt/qt_runtime.cpp:
2316 (JSC::Bindings::QtRuntimeMethod::finishCreation):
2318 2012-04-27 Geoffrey Garen <ggaren@apple.com>
2320 Made WeakSet::allocate() static and removed its JSGlobalData argument
2321 https://bugs.webkit.org/show_bug.cgi?id=85128
2323 Reviewed by Anders Carlsson.
2325 Mechanically removed JSGlobalData arguments from PassWeak<T> and Weak<T> allocation.
2327 * bindings/js/JSDOMBinding.cpp:
2328 (WebCore::jsStringSlowCase):
2329 * bindings/js/JSEventListener.h:
2330 (WebCore::JSEventListener::setWrapper):
2331 * bindings/js/JSNodeFilterCondition.cpp:
2332 (WebCore::JSNodeFilterCondition::JSNodeFilterCondition):
2333 * bindings/js/ScriptWrappable.h:
2334 (WebCore::ScriptWrappable::setWrapper):
2335 * bridge/jsc/BridgeJSC.cpp:
2336 (JSC::Bindings::Instance::createRuntimeObject):
2337 * bridge/qt/qt_runtime.cpp:
2338 (JSC::Bindings::QtRuntimeMethod::finishCreation):
2339 * bridge/runtime_root.cpp:
2340 (JSC::Bindings::RootObject::addRuntimeObject):
2342 2012-04-27 Mark Rowe <mrowe@apple.com>
2344 <rdar://problem/11313710> Leaks under WebCore::CSSImageSetValue::cachedImageSet when running tests
2346 There was a reference cycle between CSSImageSetValue and StyleCachedImageSet via
2347 CSSImageSetValue::m_imageSet / StyleCachedImageSet::m_imageSetValue. Break the cycle
2348 by having StyleCachedImageSet hold a weak reference to the CSSImageSetValue rather
2349 than a strong reference.
2351 Reviewed by Geoff Garen.
2353 * rendering/style/StyleCachedImageSet.cpp:
2354 (WebCore::StyleCachedImageSet::StyleCachedImageSet):
2355 * rendering/style/StyleCachedImageSet.h:
2356 (StyleCachedImageSet):
2358 2012-04-27 Mark Rowe <mrowe@apple.com>
2360 <rdar://problem/10346980> REGRESSION: Cannot enter text in Dashboard widget fields that have placeholder attribute
2362 Remove a dashboard backwards compatibility quirk that was in place to support an old version
2363 of the Stocks widget. It prevented the pointer-events property from being applied in Dashboard
2364 widgets, which caused -webkit-input-placeholder elements to eat mouse clicks rather than giving
2365 focus to the containing input elements. The offending widget has long since been fixed.
2367 Reviewed by Dan Bernstein.
2369 * css/StyleResolver.cpp:
2370 (WebCore::StyleResolver::collectMatchingRulesForList):
2372 2012-04-27 Dean Jackson <dino@apple.com>
2374 Support reverse and alternate-reverse in CA animations
2375 https://bugs.webkit.org/show_bug.cgi?id=78041
2377 Reviewed by Beth Dakin.
2379 CoreAnimation does not natively support reverse and alternate-reverse
2380 animation directions so we need to flip the animation values (keyframe
2381 keys and timing functions) that we send to GraphicsLayerCA. Unfortunately
2382 this code adds a lot of conditionals because it isn't as simple as
2383 reversing the order of keys. You also now have a different alignment of
2384 timing functions to the reversed list.
2386 New tests to cover the two new directions, making sure the timing
2387 functions are correctly inverted, and exercising fill modes.
2389 Tests: animations/animation-direction-reverse-fill-mode-hardware.html
2390 animations/animation-direction-reverse-fill-mode.html
2391 animations/animation-direction-reverse-hardware-opacity.html
2392 animations/animation-direction-reverse-hardware.html
2393 animations/animation-direction-reverse-non-hardware.html
2394 animations/animation-direction-reverse-timing-functions-hardware.html
2395 animations/animation-direction-reverse-timing-functions.html
2397 * platform/graphics/ca/GraphicsLayerCA.cpp:
2398 Handle the previously unsupported animation directions, reversing
2399 the list of values and keytimes that would be used to create
2401 (WebCore::GraphicsLayerCA::addAnimation):
2402 Do not create an animation if on Windows and using a reverse
2404 (WebCore::GraphicsLayerCA::createFilterAnimationsFromKeyframes):
2405 (WebCore::GraphicsLayerCA::setupAnimation):
2406 (WebCore::GraphicsLayerCA::setAnimationEndpoints):
2407 (WebCore::GraphicsLayerCA::setAnimationKeyframes):
2408 (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints):
2409 (WebCore::GraphicsLayerCA::setTransformAnimationKeyframes):
2410 (WebCore::GraphicsLayerCA::setFilterAnimationEndpoints):
2411 (WebCore::GraphicsLayerCA::setFilterAnimationKeyframes):
2412 * platform/graphics/ca/PlatformCAAnimation.h:
2413 (PlatformCAAnimation): Pass through a flag that tells the CA Animation
2414 that it should invert the timing functions.
2415 * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
2416 (toCAMediaTimingFunction): Add a parameter that will invert the timing
2417 function coefficients if necessary.
2418 (PlatformCAAnimation::setTimingFunction):
2419 (PlatformCAAnimation::setTimingFunctions):
2420 * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
2421 (toCACFTimingFunction):
2422 New unused parameter.
2424 2012-04-27 Sheriff Bot <webkit.review.bot@gmail.com>
2426 Unreviewed, rolling out r115407.
2427 http://trac.webkit.org/changeset/115407
2428 https://bugs.webkit.org/show_bug.cgi?id=85126
2430 Caused heap use after free (Requested by keishi_ on #webkit).
2432 * html/HTMLFormControlElement.cpp:
2433 (WebCore::HTMLFormControlElement::HTMLFormControlElement):
2434 (WebCore::HTMLFormControlElement::updateFieldSetAndLegendAncestor):
2435 (WebCore::HTMLFormControlElement::insertedInto):
2436 (WebCore::HTMLFormControlElement::removedFrom):
2437 (WebCore::HTMLFormControlElement::disabled):
2438 (WebCore::HTMLFormControlElement::recalcWillValidate):
2439 (WebCore::HTMLFormControlElement::setNeedsWillValidateCheck):
2440 * html/HTMLFormControlElement.h:
2441 (HTMLFormControlElement):
2443 2012-04-27 Kentaro Hara <haraken@chromium.org>
2445 [JSC] Implement a helper method createNotEnoughArgumentsError()
2446 https://bugs.webkit.org/show_bug.cgi?id=85102
2448 Reviewed by Geoffrey Garen.
2450 In bug 84787, kbr@ requested to avoid hard-coding
2451 createTypeError(exec, "Not enough arguments") here and there.
2452 This patch implements createNotEnoughArgumentsError(exec)
2453 and uses it in JSC bindings.
2455 c.f. a corresponding bug for V8 bindings is bug 85097.
2457 Test: bindings/scripts/test/TestObj.idl
2459 * bindings/scripts/CodeGeneratorJS.pm: Modified as described above.
2460 (GenerateArgumentsCountCheck):
2462 * bindings/js/JSDataViewCustom.cpp: Ditto.
2463 (WebCore::getDataViewMember):
2464 (WebCore::setDataViewMember):
2465 * bindings/js/JSDeprecatedPeerConnectionCustom.cpp:
2466 (WebCore::JSDeprecatedPeerConnectionConstructor::constructJSDeprecatedPeerConnection):
2467 * bindings/js/JSDirectoryEntryCustom.cpp:
2468 (WebCore::JSDirectoryEntry::getFile):
2469 (WebCore::JSDirectoryEntry::getDirectory):
2470 * bindings/js/JSSharedWorkerCustom.cpp:
2471 (WebCore::JSSharedWorkerConstructor::constructJSSharedWorker):
2472 * bindings/js/JSWebKitMutationObserverCustom.cpp:
2473 (WebCore::JSWebKitMutationObserverConstructor::constructJSWebKitMutationObserver):
2474 (WebCore::JSWebKitMutationObserver::observe):
2475 * bindings/js/JSWorkerCustom.cpp:
2476 (WebCore::JSWorkerConstructor::constructJSWorker):
2478 * bindings/scripts/test/JS/JSFloat64Array.cpp: Updated run-bindings-tests.
2479 (WebCore::jsFloat64ArrayPrototypeFunctionFoo):
2480 * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
2481 (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
2482 (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):
2483 * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
2484 (WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):
2485 * bindings/scripts/test/JS/JSTestEventTarget.cpp:
2486 (WebCore::jsTestEventTargetPrototypeFunctionItem):
2487 (WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
2488 (WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
2489 (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
2490 * bindings/scripts/test/JS/JSTestInterface.cpp:
2491 (WebCore::JSTestInterfaceConstructor::constructJSTestInterface):
2492 (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
2493 * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
2494 (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
2495 * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
2496 (WebCore::JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor):
2497 * bindings/scripts/test/JS/JSTestObj.cpp:
2498 (WebCore::JSTestObjConstructor::constructJSTestObj):
2499 (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
2500 (WebCore::jsTestObjPrototypeFunctionIntMethodWithArgs):
2501 (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
2502 (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
2503 (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
2504 (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
2505 (WebCore::jsTestObjPrototypeFunctionSerializedValue):
2506 (WebCore::jsTestObjPrototypeFunctionIdbKey):
2507 (WebCore::jsTestObjPrototypeFunctionOptionsObject):
2508 (WebCore::jsTestObjPrototypeFunctionAddEventListener):
2509 (WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
2510 (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
2511 (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
2512 (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
2513 (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
2514 (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
2515 (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
2516 (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
2517 (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
2518 (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
2519 (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
2520 (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
2521 (WebCore::jsTestObjConstructorFunctionClassMethod2):
2522 (WebCore::jsTestObjConstructorFunctionOverloadedMethod11):
2523 (WebCore::jsTestObjConstructorFunctionOverloadedMethod12):
2524 (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongArray):
2525 (WebCore::jsTestObjPrototypeFunctionConvert1):
2526 (WebCore::jsTestObjPrototypeFunctionConvert2):
2527 (WebCore::jsTestObjPrototypeFunctionConvert3):
2528 (WebCore::jsTestObjPrototypeFunctionConvert4):
2529 (WebCore::jsTestObjPrototypeFunctionConvert5):
2530 (WebCore::jsTestObjPrototypeFunctionStrictFunction):
2531 * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
2532 (WebCore::JSTestSerializedScriptValueInterfaceConstructor::constructJSTestSerializedScriptValueInterface):
2533 (WebCore::jsTestSerializedScriptValueInterfacePrototypeFunctionAcceptTransferList):
2535 2012-04-27 Mark Pilgrim <pilgrim@chromium.org>
2537 [Chromium] Call highMemoryUsageMB directly
2538 https://bugs.webkit.org/show_bug.cgi?id=84841
2540 Reviewed by Kentaro Hara.
2542 Part of a refactoring series. See tracking bug 82948.
2544 * bindings/v8/V8GCController.cpp:
2545 (WebCore::V8GCController::checkMemoryUsage):
2546 * platform/MemoryUsageSupport.cpp:
2547 (WebCore::MemoryUsageSupport::highMemoryUsageMB):
2549 * platform/MemoryUsageSupport.h:
2550 (MemoryUsageSupport):
2551 * platform/chromium/MemoryUsageSupportChromium.cpp:
2552 (WebCore::MemoryUsageSupport::highMemoryUsageMB):
2554 * platform/chromium/PlatformSupport.h:
2557 2012-04-27 Geoffrey Garen <ggaren@apple.com>
2559 Only allow non-null pointers in the WeakSet
2560 https://bugs.webkit.org/show_bug.cgi?id=85119
2562 Reviewed by Darin Adler.
2564 * bridge/jsc/BridgeJSC.cpp:
2565 (JSC::Bindings::Instance::Instance): Don't allocate a WeakImpl just to
2566 store null. This was needless, and is now a compile error. Instead,
2567 rely on the default constructor, which will produce a cheap null.
2569 2012-04-27 Kentaro Hara <haraken@chromium.org>
2571 "Not enough arguments" error should be TypeError
2572 https://bugs.webkit.org/show_bug.cgi?id=84628
2574 Reviewed by Darin Adler.
2576 Currently, some custom bindings implement "Not enough arguments"
2577 error as SyntaxError. The Web IDL spec requires that it should be
2578 TypeError: http://www.w3.org/TR/WebIDL/#dfn-overload-resolution-algorithm
2579 Thus, this patch changes SyntaxError to TypeError.
2581 Tests: http/tests/websocket/tests/hixie76/url-parsing.html:
2582 http/tests/websocket/tests/hybi/url-parsing.html:
2583 http/tests/xmlhttprequest/exceptions.html:
2584 svg/dom/SVGLength.html:
2585 webaudio/audionode.html:
2587 * bindings/js/JSAudioContextCustom.cpp:
2588 (WebCore::JSAudioContextConstructor::constructJSAudioContext):
2589 * bindings/js/JSSVGLengthCustom.cpp:
2590 (WebCore::JSSVGLength::convertToSpecifiedUnits):
2591 * bindings/js/JSWebSocketCustom.cpp:
2592 (WebCore::JSWebSocketConstructor::constructJSWebSocket):
2593 (WebCore::JSWebSocket::send):
2594 * bindings/js/JSXMLHttpRequestCustom.cpp:
2595 (WebCore::JSXMLHttpRequest::open):
2596 * bindings/v8/custom/V8AudioContextCustom.cpp:
2597 (WebCore::V8AudioContext::constructorCallback):
2598 * bindings/v8/custom/V8SVGLengthCustom.cpp:
2599 (WebCore::V8SVGLength::convertToSpecifiedUnitsCallback):
2600 * bindings/v8/custom/V8WebSocketCustom.cpp:
2601 (WebCore::V8WebSocket::constructorCallback):
2602 (WebCore::V8WebSocket::sendCallback):
2603 * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
2604 (WebCore::V8XMLHttpRequest::openCallback):
2606 2012-04-27 Kenneth Russell <kbr@google.com>
2608 Remove SHADER_COMPILER constant
2609 https://bugs.webkit.org/show_bug.cgi?id=85115
2611 Reviewed by Darin Adler.
2613 Removed constant which was previously removed from spec. Updated
2614 layout test and expected results.
2616 * html/canvas/WebGLRenderingContext.idl:
2618 2012-04-27 Arvid Nilsson <anilsson@rim.com>
2620 [BlackBerry] Fixed background is scrolling in http://www.nieuwecode.nl
2621 https://bugs.webkit.org/show_bug.cgi?id=85109
2623 Reviewed by Antonio Gomes.
2625 Since the BlackBerry port uses very similar fixed position acceleration
2626 as the Qt WebKit2 port, the same fix that worked for them in bug 83980
2629 Fixed by opting in to the FIXED_POSITION_CREATES_STACKING_CONTEXT
2632 Covered by existing manual test fixed-position-no-z-index.html.
2634 * css/StyleResolver.cpp:
2636 2012-04-27 Nat Duca <nduca@chromium.org>
2638 Expose high-resolution on requestAnimationFrame callback
2639 https://bugs.webkit.org/show_bug.cgi?id=66683
2641 This changes requestAnimationFrame's animationStartTime argument
2642 to be a high resolution DOM timestamp, per disucssion here:
2643 http://lists.w3.org/Archives/Public/public-web-perf/2012Apr/0004.html
2645 Reviewed by James Robinson.
2647 Covered by existing requestAnimationFrame tests.
2650 (WebCore::Document::serviceScriptedAnimations):
2653 * dom/ScriptedAnimationController.cpp:
2654 (WebCore::ScriptedAnimationController::ScriptedAnimationController):
2655 (WebCore::ScriptedAnimationController::serviceScriptedAnimations):
2657 (WebCore::ScriptedAnimationController::windowScreenDidChange):
2658 (WebCore::ScriptedAnimationController::scheduleAnimation):
2659 (WebCore::ScriptedAnimationController::animationTimerFired):
2660 (WebCore::ScriptedAnimationController::displayRefreshFired):
2661 * dom/ScriptedAnimationController.h:
2662 (ScriptedAnimationController):
2663 * page/FrameView.cpp:
2664 (WebCore::FrameView::serviceScriptedAnimations):
2667 * platform/graphics/DisplayRefreshMonitor.cpp:
2668 (WebCore::DisplayRefreshMonitor::DisplayRefreshMonitor):
2669 (WebCore::DisplayRefreshMonitor::notifyClients):
2670 * platform/graphics/DisplayRefreshMonitor.h:
2671 (DisplayRefreshMonitor):
2672 * platform/graphics/blackberry/DisplayRefreshMonitorBlackBerry.cpp:
2673 (WebCore::DisplayRefreshMonitor::displayLinkFired):
2674 * platform/graphics/mac/DisplayRefreshMonitorMac.cpp:
2676 (WebCore::DisplayRefreshMonitor::requestRefreshCallback):
2677 (WebCore::DisplayRefreshMonitor::displayLinkFired):
2679 2012-04-27 Kentaro Hara <haraken@chromium.org>
2681 [V8] Implement a helper method V8Proxy::throwNotEnoughArgumentsError()
2682 https://bugs.webkit.org/show_bug.cgi?id=85097
2684 Reviewed by Kenneth Russell.
2686 In bug 84787, kbr requested to avoid hard-coding
2687 throwError("Not enough arguments", V8Proxy::TypeError) here and there.
2688 This patch implements V8Proxy::throwNotEnoughArgumentsError()
2689 and uses it in V8 bindings.
2691 No tests. No change in behavior.
2693 * bindings/scripts/CodeGeneratorV8.pm:
2694 (GenerateArgumentsCountCheck):
2695 (GenerateEventConstructorCallback):
2696 * bindings/v8/V8Proxy.cpp:
2697 (WebCore::V8Proxy::throwNotEnoughArgmentsError):
2699 * bindings/v8/V8Proxy.h:
2701 * bindings/v8/custom/V8DataViewCustom.cpp:
2702 (WebCore::V8DataView::getInt8Callback):
2703 (WebCore::V8DataView::getUint8Callback):
2704 (WebCore::V8DataView::setInt8Callback):
2705 (WebCore::V8DataView::setUint8Callback):
2706 * bindings/v8/custom/V8DirectoryEntryCustom.cpp:
2707 (WebCore::V8DirectoryEntry::getDirectoryCallback):
2708 (WebCore::V8DirectoryEntry::getFileCallback):
2709 * bindings/v8/custom/V8IntentConstructor.cpp:
2710 (WebCore::V8Intent::constructorCallback):
2711 * bindings/v8/custom/V8WebKitMutationObserverCustom.cpp:
2712 (WebCore::V8WebKitMutationObserver::constructorCallback):
2713 (WebCore::V8WebKitMutationObserver::observeCallback):
2715 Test: bindings/scripts/test/TestObj.idl
2717 * bindings/scripts/CodeGeneratorV8.pm: Modified as described above.
2718 (GenerateArgumentsCountCheck):
2719 (GenerateEventConstructorCallback):
2721 * bindings/v8/V8Proxy.cpp: Ditto.
2722 (WebCore::V8Proxy::throwNotEnoughArgumentsError):
2724 * bindings/v8/V8Proxy.h:
2726 * bindings/v8/custom/V8DataViewCustom.cpp:
2727 (WebCore::V8DataView::getInt8Callback):
2728 (WebCore::V8DataView::getUint8Callback):
2729 (WebCore::V8DataView::setInt8Callback):
2730 (WebCore::V8DataView::setUint8Callback):
2731 * bindings/v8/custom/V8DirectoryEntryCustom.cpp:
2732 (WebCore::V8DirectoryEntry::getDirectoryCallback):
2733 (WebCore::V8DirectoryEntry::getFileCallback):
2734 * bindings/v8/custom/V8IntentConstructor.cpp:
2735 (WebCore::V8Intent::constructorCallback):
2736 * bindings/v8/custom/V8WebKitMutationObserverCustom.cpp:
2737 (WebCore::V8WebKitMutationObserver::constructorCallback):
2738 (WebCore::V8WebKitMutationObserver::observeCallback):
2740 * bindings/scripts/test/V8/V8Float64Array.cpp: Updated run-bindings-tests.
2741 (WebCore::Float64ArrayV8Internal::fooCallback):
2742 * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
2743 (WebCore::TestActiveDOMObjectV8Internal::excitingFunctionCallback):
2744 (WebCore::TestActiveDOMObjectV8Internal::postMessageCallback):
2745 * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
2746 (WebCore::TestCustomNamedGetterV8Internal::anotherFunctionCallback):
2747 * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
2748 (WebCore::V8TestEventConstructor::constructorCallback):
2749 * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2750 (WebCore::TestEventTargetV8Internal::itemCallback):
2751 (WebCore::TestEventTargetV8Internal::dispatchEventCallback):
2752 * bindings/scripts/test/V8/V8TestInterface.cpp:
2753 (WebCore::TestInterfaceV8Internal::supplementalMethod2Callback):
2754 (WebCore::V8TestInterface::constructorCallback):
2755 * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
2756 (WebCore::TestMediaQueryListListenerV8Internal::methodCallback):
2757 * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2758 (WebCore::V8TestNamedConstructorConstructorCallback):
2759 * bindings/scripts/test/V8/V8TestObj.cpp:
2760 (WebCore::TestObjV8Internal::voidMethodWithArgsCallback):
2761 (WebCore::TestObjV8Internal::intMethodWithArgsCallback):
2762 (WebCore::TestObjV8Internal::objMethodWithArgsCallback):
2763 (WebCore::TestObjV8Internal::methodWithSequenceArgCallback):
2764 (WebCore::TestObjV8Internal::methodReturningSequenceCallback):
2765 (WebCore::TestObjV8Internal::methodThatRequiresAllArgsAndThrowsCallback):
2766 (WebCore::TestObjV8Internal::serializedValueCallback):
2767 (WebCore::TestObjV8Internal::idbKeyCallback):
2768 (WebCore::TestObjV8Internal::optionsObjectCallback):
2769 (WebCore::TestObjV8Internal::methodWithNonOptionalArgAndOptionalArgCallback):
2770 (WebCore::TestObjV8Internal::methodWithNonOptionalArgAndTwoOptionalArgsCallback):
2771 (WebCore::TestObjV8Internal::methodWithCallbackArgCallback):
2772 (WebCore::TestObjV8Internal::methodWithNonCallbackArgAndCallbackArgCallback):
2773 (WebCore::TestObjV8Internal::overloadedMethod1Callback):
2774 (WebCore::TestObjV8Internal::overloadedMethod2Callback):
2775 (WebCore::TestObjV8Internal::overloadedMethod3Callback):
2776 (WebCore::TestObjV8Internal::overloadedMethod4Callback):
2777 (WebCore::TestObjV8Internal::overloadedMethod5Callback):
2778 (WebCore::TestObjV8Internal::overloadedMethod6Callback):
2779 (WebCore::TestObjV8Internal::overloadedMethod7Callback):
2780 (WebCore::TestObjV8Internal::overloadedMethod11Callback):
2781 (WebCore::TestObjV8Internal::overloadedMethod12Callback):
2782 (WebCore::TestObjV8Internal::enabledAtRuntimeMethod1Callback):
2783 (WebCore::TestObjV8Internal::enabledAtRuntimeMethod2Callback):
2784 (WebCore::TestObjV8Internal::convert1Callback):
2785 (WebCore::TestObjV8Internal::convert2Callback):
2786 (WebCore::TestObjV8Internal::convert3Callback):
2787 (WebCore::TestObjV8Internal::convert4Callback):
2788 (WebCore::TestObjV8Internal::convert5Callback):
2789 (WebCore::TestObjV8Internal::strictFunctionCallback):
2790 (WebCore::V8TestObj::constructorCallback):
2791 * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2792 (WebCore::TestSerializedScriptValueInterfaceV8Internal::acceptTransferListCallback):
2793 (WebCore::V8TestSerializedScriptValueInterface::constructorCallback):
2795 2012-04-27 Mark Pilgrim <pilgrim@chromium.org>
2797 [Chromium] Call lowMemoryUsageMB directly
2798 https://bugs.webkit.org/show_bug.cgi?id=84840
2800 Reviewed by Kentaro Hara.
2802 Part of a refactoring series. See tracking bug 82948.
2804 * bindings/v8/V8GCController.cpp:
2805 (WebCore::V8GCController::checkMemoryUsage):
2806 * platform/MemoryUsageSupport.cpp:
2807 (WebCore::MemoryUsageSupport::lowMemoryUsageMB):
2809 * platform/MemoryUsageSupport.h:
2810 (MemoryUsageSupport):
2811 * platform/chromium/MemoryUsageSupportChromium.cpp:
2812 (WebCore::MemoryUsageSupport::lowMemoryUsageMB):
2814 * platform/chromium/PlatformSupport.h:
2817 2012-04-27 Yi Shen <yi.4.shen@nokia.com>
2819 REGRESSION(113723): Pressing enter in this list example deletes the whole list
2820 https://bugs.webkit.org/show_bug.cgi?id=85016
2822 Reviewed by Enrica Casucci.
2824 The bug was caused by CompositeEditCommand::breakOutOfEmptyListItem, which calls isListItem
2825 on the empty list's siblings to decide which part of the list should get removed. However,
2826 the check fails when the empty list's sibling is a text node, or a list element (e.g. ul, ol).
2827 Fixed it by skipping empty list's non-element sibling and calling isListElement to do further
2830 Test: added new test cases in the existing test (break-out-of-empty-list-item.html)
2832 * editing/CompositeEditCommand.cpp:
2833 (WebCore::CompositeEditCommand::breakOutOfEmptyListItem):
2835 2012-04-27 Ian Vollick <vollick@chromium.org>
2837 [chromium] Add pause and resume support for accelerated css animations.
2838 https://bugs.webkit.org/show_bug.cgi?id=84601
2840 Reviewed by James Robinson.
2843 CCLayerAnimationControllerTest.syncPauseResume
2844 CCActiveAnimationTest.TrimTimeTimeOffset
2845 CCActiveAnimationTest.TrimTimeSuspendResume
2846 CCActiveAnimationTest.IsFinishedNeedsSynchronizedStartTime
2847 CCActiveAnimationTest.RunStateChangesIgnoredWhileSuspended
2849 * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2850 (WebCore::GraphicsLayerChromium::suspendAnimations):
2851 (WebCore::GraphicsLayerChromium::resumeAnimations):
2852 * platform/graphics/chromium/GraphicsLayerChromium.h:
2853 (GraphicsLayerChromium):
2854 * platform/graphics/chromium/LayerChromium.cpp:
2855 (WebCore::LayerChromium::suspendAnimations):
2856 (WebCore::LayerChromium::resumeAnimations):
2857 * platform/graphics/chromium/LayerChromium.h:
2859 * platform/graphics/chromium/cc/CCActiveAnimation.cpp:
2860 (WebCore::CCActiveAnimation::CCActiveAnimation):
2861 (WebCore::CCActiveAnimation::setRunState):
2862 (WebCore::CCActiveAnimation::suspend):
2863 (WebCore::CCActiveAnimation::resume):
2864 (WebCore::CCActiveAnimation::isFinishedAt):
2865 (WebCore::CCActiveAnimation::trimTimeToCurrentIteration):
2866 (WebCore::CCActiveAnimation::cloneForImplThread):
2867 (WebCore::CCActiveAnimation::pushPropertiesTo):
2868 * platform/graphics/chromium/cc/CCActiveAnimation.h:
2869 (CCActiveAnimation):
2870 (WebCore::CCActiveAnimation::setStartTime):
2871 (WebCore::CCActiveAnimation::timeOffset):
2872 (WebCore::CCActiveAnimation::setTimeOffset):
2873 (WebCore::CCActiveAnimation::isFinished):
2874 * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
2875 (WebCore::CCLayerAnimationController::addAnimation):
2876 (WebCore::CCLayerAnimationController::pauseAnimation):
2877 (WebCore::CCLayerAnimationController::suspendAnimations):
2878 (WebCore::CCLayerAnimationController::resumeAnimations):
2879 (WebCore::CCLayerAnimationController::pushAnimationUpdatesTo):
2880 (WebCore::CCLayerAnimationController::getActiveAnimation):
2881 (WebCore::CCLayerAnimationController::pushNewAnimationsToImplThread):
2882 (WebCore::CCLayerAnimationController::removeAnimationsCompletedOnMainThread):
2883 (WebCore::CCLayerAnimationController::pushPropertiesToImplThread):
2885 (WebCore::CCLayerAnimationController::tickAnimations):
2886 * platform/graphics/chromium/cc/CCLayerAnimationController.h:
2887 (CCLayerAnimationController):
2889 2012-04-27 Tim Horton <timothy_horton@apple.com>
2891 SMIL animation causes leak of the related Document (and many elements)
2892 https://bugs.webkit.org/show_bug.cgi?id=83856
2893 <rdar://problem/11216047>
2895 Reviewed by Dean Jackson.
2897 The SVGAnimatedProperty cache was previously holding a reference to the properties it contained;
2898 said references were cleared in the SVGAnimatedProperty destructor (which was never called because
2899 there was always one remaining reference from the cache).
2901 The SVGAnimatedProperty cache now holds raw pointers instead of RefPtrs; the SVGAnimateElement now
2902 owns its own SVGAnimatedProperties, both for itself and for any <use/> instances of itself. They're
2903 cleared and destroyed within SVGAnimateElement::targetElementWillChange, at which time they're removed
2906 SVGPropertyTearOffs now keep a reference to their SVGElement (m_contextElement) instead of their SVGAnimatedProperty;
2907 this way, there is no reference cycle, but the animated property (owned by the element) and the element itself are
2908 kept alive until the TearOff is garbage collected.
2910 Tests: svg/animations/smil-leak-dynamically-added-element-instances.svg
2911 svg/animations/smil-leak-elements.svg
2912 svg/animations/smil-leak-element-instances-noBaseValRef.svg
2913 svg/animations/smil-leak-element-instances.svg
2914 svg/animations/svglength-element-removed-crash.svg
2916 * svg/SVGAnimateElement.cpp:
2917 (WebCore::SVGAnimateElement::calculateAnimatedValue):
2918 (WebCore::propertyTypesAreConsistent):
2919 (WebCore::SVGAnimateElement::resetToBaseValue):
2920 (WebCore::SVGAnimateElement::applyResultsToTarget):
2921 (WebCore::SVGAnimateElement::targetElementWillChange):
2922 * svg/SVGAnimateElement.h:
2923 (SVGAnimateElement):
2924 * svg/SVGAnimatedAngle.cpp:
2925 (WebCore::SVGAnimatedAngleAnimator::startAnimValAnimation):
2926 (WebCore::SVGAnimatedAngleAnimator::stopAnimValAnimation):
2927 (WebCore::SVGAnimatedAngleAnimator::resetAnimValToBaseVal):
2928 (WebCore::SVGAnimatedAngleAnimator::animValWillChange):
2929 (WebCore::SVGAnimatedAngleAnimator::animValDidChange):
2930 * svg/SVGAnimatedAngle.h:
2931 (SVGAnimatedAngleAnimator):
2932 * svg/SVGAnimatedBoolean.cpp:
2933 (WebCore::SVGAnimatedBooleanAnimator::startAnimValAnimation):
2934 (WebCore::SVGAnimatedBooleanAnimator::stopAnimValAnimation):
2935 (WebCore::SVGAnimatedBooleanAnimator::resetAnimValToBaseVal):
2936 (WebCore::SVGAnimatedBooleanAnimator::animValWillChange):
2937 (WebCore::SVGAnimatedBooleanAnimator::animValDidChange):
2938 * svg/SVGAnimatedBoolean.h:
2939 (SVGAnimatedBooleanAnimator):
2940 * svg/SVGAnimatedColor.h:
2941 (WebCore::SVGAnimatedColorAnimator::startAnimValAnimation):
2942 (WebCore::SVGAnimatedColorAnimator::stopAnimValAnimation):
2943 (WebCore::SVGAnimatedColorAnimator::resetAnimValToBaseVal):
2944 (WebCore::SVGAnimatedColorAnimator::animValWillChange):
2945 (WebCore::SVGAnimatedColorAnimator::animValDidChange):
2946 * svg/SVGAnimatedEnumeration.cpp:
2947 (WebCore::SVGAnimatedEnumerationAnimator::startAnimValAnimation):
2948 (WebCore::SVGAnimatedEnumerationAnimator::stopAnimValAnimation):
2949 (WebCore::SVGAnimatedEnumerationAnimator::resetAnimValToBaseVal):
2950 (WebCore::SVGAnimatedEnumerationAnimator::animValWillChange):
2951 (WebCore::SVGAnimatedEnumerationAnimator::animValDidChange):
2952 * svg/SVGAnimatedEnumeration.h:
2953 (SVGAnimatedEnumerationAnimator):
2954 * svg/SVGAnimatedInteger.cpp:
2955 (WebCore::SVGAnimatedIntegerAnimator::startAnimValAnimation):
2956 (WebCore::SVGAnimatedIntegerAnimator::stopAnimValAnimation):
2957 (WebCore::SVGAnimatedIntegerAnimator::resetAnimValToBaseVal):
2958 (WebCore::SVGAnimatedIntegerAnimator::animValWillChange):
2959 (WebCore::SVGAnimatedIntegerAnimator::animValDidChange):
2960 * svg/SVGAnimatedInteger.h:
2961 (SVGAnimatedIntegerAnimator):
2962 * svg/SVGAnimatedIntegerOptionalInteger.cpp:
2963 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::startAnimValAnimation):
2964 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::stopAnimValAnimation):
2965 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::resetAnimValToBaseVal):
2966 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::animValWillChange):
2967 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::animValDidChange):
2968 * svg/SVGAnimatedIntegerOptionalInteger.h:
2969 (SVGAnimatedIntegerOptionalIntegerAnimator):
2970 * svg/SVGAnimatedLength.cpp:
2971 (WebCore::SVGAnimatedLengthAnimator::startAnimValAnimation):
2972 (WebCore::SVGAnimatedLengthAnimator::stopAnimValAnimation):
2973 (WebCore::SVGAnimatedLengthAnimator::resetAnimValToBaseVal):
2974 (WebCore::SVGAnimatedLengthAnimator::animValWillChange):
2975 (WebCore::SVGAnimatedLengthAnimator::animValDidChange):
2976 * svg/SVGAnimatedLength.h:
2977 (SVGAnimatedLengthAnimator):
2978 * svg/SVGAnimatedLengthList.cpp:
2979 (WebCore::SVGAnimatedLengthListAnimator::startAnimValAnimation):
2980 (WebCore::SVGAnimatedLengthListAnimator::stopAnimValAnimation):
2981 (WebCore::SVGAnimatedLengthListAnimator::resetAnimValToBaseVal):
2982 (WebCore::SVGAnimatedLengthListAnimator::animValWillChange):
2983 (WebCore::SVGAnimatedLengthListAnimator::animValDidChange):
2984 * svg/SVGAnimatedLengthList.h:
2985 (SVGAnimatedLengthListAnimator):
2986 * svg/SVGAnimatedNumber.cpp:
2987 (WebCore::SVGAnimatedNumberAnimator::startAnimValAnimation):
2988 (WebCore::SVGAnimatedNumberAnimator::stopAnimValAnimation):
2989 (WebCore::SVGAnimatedNumberAnimator::resetAnimValToBaseVal):
2990 (WebCore::SVGAnimatedNumberAnimator::animValWillChange):
2991 (WebCore::SVGAnimatedNumberAnimator::animValDidChange):
2992 * svg/SVGAnimatedNumber.h:
2993 (SVGAnimatedNumberAnimator):
2994 * svg/SVGAnimatedNumberList.cpp:
2995 (WebCore::SVGAnimatedNumberListAnimator::startAnimValAnimation):
2996 (WebCore::SVGAnimatedNumberListAnimator::stopAnimValAnimation):
2997 (WebCore::SVGAnimatedNumberListAnimator::resetAnimValToBaseVal):
2998 (WebCore::SVGAnimatedNumberListAnimator::animValWillChange):
2999 (WebCore::SVGAnimatedNumberListAnimator::animValDidChange):
3000 * svg/SVGAnimatedNumberList.h:
3001 (SVGAnimatedNumberListAnimator):
3002 * svg/SVGAnimatedNumberOptionalNumber.cpp:
3003 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::startAnimValAnimation):
3004 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::stopAnimValAnimation):
3005 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::resetAnimValToBaseVal):
3006 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::animValWillChange):
3007 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::animValDidChange):
3008 * svg/SVGAnimatedNumberOptionalNumber.h:
3009 (SVGAnimatedNumberOptionalNumberAnimator):
3010 * svg/SVGAnimatedPath.cpp:
3011 (WebCore::SVGAnimatedPathAnimator::startAnimValAnimation):
3012 (WebCore::SVGAnimatedPathAnimator::stopAnimValAnimation):
3013 (WebCore::SVGAnimatedPathAnimator::resetAnimValToBaseVal):
3014 (WebCore::SVGAnimatedPathAnimator::animValWillChange):
3015 (WebCore::SVGAnimatedPathAnimator::animValDidChange):
3016 * svg/SVGAnimatedPath.h:
3017 (SVGAnimatedPathAnimator):
3018 * svg/SVGAnimatedPointList.cpp:
3019 (WebCore::SVGAnimatedPointListAnimator::startAnimValAnimation):
3020 (WebCore::SVGAnimatedPointListAnimator::stopAnimValAnimation):
3021 (WebCore::SVGAnimatedPointListAnimator::resetAnimValToBaseVal):
3022 (WebCore::SVGAnimatedPointListAnimator::animValWillChange):
3023 (WebCore::SVGAnimatedPointListAnimator::animValDidChange):
3024 * svg/SVGAnimatedPointList.h:
3025 (SVGAnimatedPointListAnimator):
3026 * svg/SVGAnimatedPreserveAspectRatio.cpp:
3027 (WebCore::SVGAnimatedPreserveAspectRatioAnimator::startAnimValAnimation):
3028 (WebCore::SVGAnimatedPreserveAspectRatioAnimator::stopAnimValAnimation):
3029 (WebCore::SVGAnimatedPreserveAspectRatioAnimator::resetAnimValToBaseVal):
3030 (WebCore::SVGAnimatedPreserveAspectRatioAnimator::animValWillChange):
3031 (WebCore::SVGAnimatedPreserveAspectRatioAnimator::animValDidChange):
3032 * svg/SVGAnimatedPreserveAspectRatio.h:
3033 (SVGAnimatedPreserveAspectRatioAnimator):
3034 * svg/SVGAnimatedRect.cpp:
3035 (WebCore::SVGAnimatedRectAnimator::startAnimValAnimation):
3036 (WebCore::SVGAnimatedRectAnimator::stopAnimValAnimation):
3037 (WebCore::SVGAnimatedRectAnimator::resetAnimValToBaseVal):
3038 (WebCore::SVGAnimatedRectAnimator::animValWillChange):
3039 (WebCore::SVGAnimatedRectAnimator::animValDidChange):
3040 * svg/SVGAnimatedRect.h:
3041 (SVGAnimatedRectAnimator):
3042 * svg/SVGAnimatedString.cpp:
3043 (WebCore::SVGAnimatedStringAnimator::startAnimValAnimation):
3044 (WebCore::SVGAnimatedStringAnimator::stopAnimValAnimation):
3045 (WebCore::SVGAnimatedStringAnimator::resetAnimValToBaseVal):
3046 (WebCore::SVGAnimatedStringAnimator::animValWillChange):
3047 (WebCore::SVGAnimatedStringAnimator::animValDidChange):
3048 * svg/SVGAnimatedString.h:
3049 (SVGAnimatedStringAnimator):
3050 * svg/SVGAnimatedTransformList.cpp:
3051 (WebCore::SVGAnimatedTransformListAnimator::startAnimValAnimation):
3052 (WebCore::SVGAnimatedTransformListAnimator::stopAnimValAnimation):
3053 (WebCore::SVGAnimatedTransformListAnimator::resetAnimValToBaseVal):
3054 (WebCore::SVGAnimatedTransformListAnimator::animValWillChange):
3055 (WebCore::SVGAnimatedTransformListAnimator::animValDidChange):
3056 * svg/SVGAnimatedTransformList.h:
3057 (SVGAnimatedTransformListAnimator):
3058 * svg/SVGAnimatedTypeAnimator.h:
3059 (SVGAnimatedTypeAnimator):
3060 (WebCore::SVGAnimatedTypeAnimator::findAnimatedPropertiesForAttributeName):
3061 (WebCore::SVGAnimatedTypeAnimator::findAnimatedPropertiesFromInstancesForAttributeName):
3062 (WebCore::SVGAnimatedTypeAnimator::constructFromBaseValue):
3063 (WebCore::SVGAnimatedTypeAnimator::resetFromBaseValue):
3064 (WebCore::SVGAnimatedTypeAnimator::stopAnimValAnimationForType):
3065 (WebCore::SVGAnimatedTypeAnimator::animValDidChangeForType):
3066 (WebCore::SVGAnimatedTypeAnimator::animValWillChangeForType):
3067 (WebCore::SVGAnimatedTypeAnimator::constructFromBaseValues):
3068 (WebCore::SVGAnimatedTypeAnimator::resetFromBaseValues):
3069 (WebCore::SVGAnimatedTypeAnimator::stopAnimValAnimationForTypes):
3070 (WebCore::SVGAnimatedTypeAnimator::animValDidChangeForTypes):
3071 (WebCore::SVGAnimatedTypeAnimator::animValWillChangeForTypes):
3072 (WebCore::SVGAnimatedTypeAnimator::castAnimatedPropertyToActualType):
3073 (WebCore::SVGAnimatedTypeAnimator::executeAction):
3074 * svg/properties/SVGAnimatedProperty.h:
3075 (SVGAnimatedProperty):
3076 * svg/properties/SVGPropertyTearOff.h:
3077 (WebCore::SVGPropertyTearOff::animatedProperty):
3078 (SVGPropertyTearOff):
3080 2012-04-27 Adam Klein <adamk@chromium.org>
3082 Remove misspelled, unused, unimplemented method from V8Proxy
3083 https://bugs.webkit.org/show_bug.cgi?id=85091
3085 Reviewed by Dimitri Glazkov.
3087 * bindings/v8/V8Proxy.h:
3090 2012-04-24 Jeffrey Pfau <jpfau@apple.com>
3092 Disable RTF in JavaScript drag-and-drop
3093 https://bugs.webkit.org/show_bug.cgi?id=76597
3095 Reviewed by Maciej Stachowiak.
3097 Test: fast/events/drag-and-drop-subframe-dataTransfer.html
3099 * platform/mac/ClipboardMac.mm:
3100 (WebCore::cocoaTypeFromHTMLClipboardType):
3102 2012-04-26 James Robinson <jamesr@chromium.org>
3104 [chromium] Separate IOSurface layer type from texture layers
3105 https://bugs.webkit.org/show_bug.cgi?id=85030
3107 Reviewed by Adrienne Walker.
3109 Adds a new layer type for IOSurface layers and pipes through a separate path through to rendering. IOSurface
3110 layers are very simple - they have an IOSurface id and size, nothing else. All IOSurface layers are "flipped" in
3114 * platform/graphics/chromium/IOSurfaceLayerChromium.cpp:
3116 (WebCore::IOSurfaceLayerChromium::create):
3117 (WebCore::IOSurfaceLayerChromium::IOSurfaceLayerChromium):
3118 (WebCore::IOSurfaceLayerChromium::~IOSurfaceLayerChromium):
3119 (WebCore::IOSurfaceLayerChromium::setIOSurfaceProperties):
3120 (WebCore::IOSurfaceLayerChromium::createCCLayerImpl):
3121 (WebCore::IOSurfaceLayerChromium::drawsContent):
3122 (WebCore::IOSurfaceLayerChromium::pushPropertiesTo):
3123 * platform/graphics/chromium/IOSurfaceLayerChromium.h:
3125 (IOSurfaceLayerChromium):
3126 * platform/graphics/chromium/LayerRendererChromium.cpp:
3127 (WebCore::LayerRendererChromium::drawIOSurfaceQuad):
3128 (WebCore::LayerRendererChromium::cleanupSharedObjects):
3129 * platform/graphics/chromium/LayerRendererChromium.h:
3130 (LayerRendererChromium):
3131 * platform/graphics/chromium/TextureLayerChromium.cpp:
3132 (WebCore::TextureLayerChromium::TextureLayerChromium):
3133 (WebCore::TextureLayerChromium::drawsContent):
3134 (WebCore::TextureLayerChromium::pushPropertiesTo):
3135 * platform/graphics/chromium/TextureLayerChromium.h:
3136 (TextureLayerChromium):
3137 * platform/graphics/chromium/cc/CCIOSurfaceDrawQuad.cpp:
3138 (WebCore::CCIOSurfaceDrawQuad::create):
3139 (WebCore::CCIOSurfaceDrawQuad::CCIOSurfaceDrawQuad):
3140 * platform/graphics/chromium/cc/CCIOSurfaceDrawQuad.h:
3141 (CCIOSurfaceDrawQuad):
3142 * platform/graphics/chromium/cc/CCIOSurfaceLayerImpl.cpp:
3144 (WebCore::CCIOSurfaceLayerImpl::CCIOSurfaceLayerImpl):
3145 (WebCore::CCIOSurfaceLayerImpl::~CCIOSurfaceLayerImpl):
3146 (WebCore::CCIOSurfaceLayerImpl::willDraw):
3147 (WebCore::CCIOSurfaceLayerImpl::appendQuads):
3148 (WebCore::CCIOSurfaceLayerImpl::dumpLayerProperties):
3149 (WebCore::CCIOSurfaceLayerImpl::didLoseContext):
3150 (WebCore::CCIOSurfaceLayerImpl::setIOSurfaceProperties):
3151 * platform/graphics/chromium/cc/CCIOSurfaceLayerImpl.h:
3153 (CCIOSurfaceLayerImpl):
3154 (WebCore::CCIOSurfaceLayerImpl::create):
3155 * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
3156 (WebCore::CCTextureLayerImpl::CCTextureLayerImpl):
3157 (WebCore::CCTextureLayerImpl::~CCTextureLayerImpl):
3158 (WebCore::CCTextureLayerImpl::appendQuads):
3159 (WebCore::CCTextureLayerImpl::didLoseContext):
3160 * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
3161 (CCTextureLayerImpl):
3163 2012-04-27 Arvid Nilsson <anilsson@rim.com>
3165 [BlackBerry] OpenGL related bug fixes
3166 https://bugs.webkit.org/show_bug.cgi?id=84836
3168 Reviewed by Antonio Gomes.
3170 PR147254, 148933, 149117, 149721, 150228
3172 No new tests, covered by existing BlackBerry browser stress tests
3174 * platform/graphics/blackberry/CanvasLayerWebKitThread.cpp:
3175 (WebCore::CanvasLayerWebKitThread::updateTextureContentsIfNeeded):
3176 * platform/graphics/blackberry/LayerCompositingThread.cpp:
3177 (WebCore::LayerCompositingThread::drawTextures):
3178 * platform/graphics/blackberry/LayerRenderer.cpp:
3179 (WebCore::LayerRenderer::~LayerRenderer):
3180 (WebCore::LayerRenderer::drawLayers):
3181 (WebCore::LayerRenderer::initializeSharedGLObjects):
3183 2012-04-27 Nat Duca <nduca@chromium.org>
3185 Implement high-resolution time via window.performance.webkitNow()
3186 https://bugs.webkit.org/show_bug.cgi?id=66684
3188 This implements the high resolution time spec from
3189 http://www.w3.org/TR/hr-time/, giving javascript access to
3190 sub-millisecond timestamps that increase over time instead of being
3191 subject to skewing, for example when the host machine's clock changes.
3193 Reviewed by Tony Gentilcore.
3195 Test: fast/performance/performance-now-timestamps.html
3197 * page/Performance.cpp:
3198 (WebCore::Performance::now):
3200 * page/Performance.h:
3202 * page/Performance.idl:
3204 2012-04-27 Filip Pizlo <fpizlo@apple.com>
3206 If you get a list of DOMWrapperWorld*'s and then plan to allocate in the heap, you should ref
3207 the DOMWrapperWorld*'s
3208 https://bugs.webkit.org/show_bug.cgi?id=85098
3209 <rdar://problem/11318170>
3211 Reviewed by Sam Weinig.
3213 No new tests because this addresses hard-to-repro flaky behavior arising from GCs at inconvenient
3216 * bindings/js/ScriptController.cpp:
3217 (WebCore::ScriptController::getAllWorlds):
3218 * bindings/js/ScriptController.h:
3220 * bindings/js/WebCoreJSClientData.h:
3221 (WebCore::WebCoreJSClientData::getAllWorlds):
3222 * bindings/v8/ScriptController.cpp:
3223 (WebCore::ScriptController::getAllWorlds):
3224 * bindings/v8/ScriptController.h:
3226 * loader/FrameLoader.cpp:
3227 (WebCore::FrameLoader::dispatchDidClearWindowObjectsInAllWorlds):
3228 (WebCore::FrameLoader::dispatchGlobalObjectAvailableInAllWorlds):
3230 2012-04-27 Geoffrey Garen <ggaren@apple.com>
3232 Removed the sole use of Weak<Unknown>
3233 https://bugs.webkit.org/show_bug.cgi?id=85099
3235 Reviewed by Sam Weinig.
3237 The semantics and implementation of Weak<Unknown> are unclear because:
3238 - Should you call a finalizer for a non-GC thingy? If so, when?
3240 * Possible answer: No.
3242 - If WeakImpls for GC thingies live with the GC thingies in the
3243 heap, where do WeakImpls for non-GC thingies live?
3245 * Possible answer: Directly in the Weak<T>.
3247 Since no clients actually want these behaviors, it's hard to tell if
3248 they're the right behaviors, and it's not worth the implementation
3249 complexity. If we come up with a client that wants these behaviors, we
3250 can always revisit this.
3252 * bindings/js/JSNodeFilterCondition.cpp:
3253 (WebCore::JSNodeFilterCondition::JSNodeFilterCondition): Just leave our
3254 filter NULL if it's not an object -- that's a better way to indicate
3255 "not a valid filter object".
3257 (WebCore::JSNodeFilterCondition::acceptNode): Fixed up some naming to
3258 clarify that the object we're working with is not necessarily a function.
3260 * bindings/js/JSNodeFilterCondition.h:
3261 (JSNodeFilterCondition): Use Weak<JSObject>, since that more closely
3262 matches what we're trying to do.
3264 2012-04-26 Kentaro Hara <haraken@chromium.org>
3266 [V8] Pass Isolate to getDOMXXXMap()
3267 https://bugs.webkit.org/show_bug.cgi?id=85022
3269 Reviewed by Nate Chapin.
3271 The objective is to pass Isolate around in V8 bindings.
3272 This patch passes Isolate to getDOMXXXMap().
3274 Also this patch removes DOMMap::getDOMDataStore() and
3275 DOMData::getDefalutStore(), since the indirection by the
3276 methods is redundant. This is not for performance
3277 optimization but just for refactoring.
3279 No tests. No change in behavior.
3281 * bindings/v8/DOMData.cpp:
3282 (WebCore::DOMData::getCurrentStore):
3283 * bindings/v8/DOMData.h:
3285 * bindings/v8/V8DOMMap.cpp:
3286 (WebCore::getDOMNodeMap):
3287 (WebCore::getActiveDOMNodeMap):
3288 (WebCore::getDOMObjectMap):
3289 (WebCore::getActiveDOMObjectMap):
3290 (WebCore::removeAllDOMObjects):
3291 * bindings/v8/V8DOMMap.h:
3294 2012-04-26 Kentaro Hara <haraken@chromium.org>
3296 [V8] Pass Isolate to V8BindingPerIsolateData::current()
3297 https://bugs.webkit.org/show_bug.cgi?id=85023
3299 Reviewed by Nate Chapin.
3301 The objective is to pass Isolate around in V8 bindings.
3302 This patch passes Isolate to V8BindingPerIsolateData::current().
3304 No tests. No change in behavior.
3306 * bindings/v8/V8Binding.h:
3307 (WebCore::V8BindingPerIsolateData::current):
3308 (WebCore::v8ExternalString):
3310 2012-04-27 Dimitri Glazkov <dglazkov@chromium.org>
3312 Unreviewed, rolling out r115484.
3313 http://trac.webkit.org/changeset/115484
3314 https://bugs.webkit.org/show_bug.cgi?id=84555
3316 Broke Chromium compile.
3318 * bindings/js/JSBlobCustom.cpp:
3319 * bindings/v8/custom/V8BlobCustom.cpp:
3324 * workers/WorkerContext.idl:
3326 2012-04-27 Alexandru Chiculita <achicu@adobe.com>
3328 [CSS Shaders] Implement CSS Animations and Transitions for CSS Shaders
3329 https://bugs.webkit.org/show_bug.cgi?id=71406
3331 Reviewed by Dean Jackson.
3333 I've implemented the blend function for the CustomFilterOperation. This should enable animations for CSS Shaders.
3334 Currently, just floats are implemented. If any of the filter attributes like shader, mesh size or box mode are different,
3335 the fallback is to use the "to" part of the animation instead. If other shader parameters do not match, it will merge the parameter values
3336 between the "from" and "to" states.
3338 Test: css3/filters/custom/custom-filter-animation.html
3340 * platform/graphics/filters/CustomFilterNumberParameter.h:
3341 (WebCore::CustomFilterNumberParameter::blend):
3342 (CustomFilterNumberParameter):
3343 (WebCore::CustomFilterNumberParameter::operator==):
3344 * platform/graphics/filters/CustomFilterOperation.cpp:
3345 (WebCore::equalCustomFilterParameters):
3347 (WebCore::checkCustomFilterParametersOrder):
3348 (WebCore::blendCustomFilterParameters):
3349 (WebCore::CustomFilterOperation::CustomFilterOperation):
3350 (WebCore::CustomFilterOperation::blend):
3351 * platform/graphics/filters/CustomFilterOperation.h:
3353 (CustomFilterOperation):
3354 (WebCore::CustomFilterOperation::operator==):
3355 (WebCore::CustomFilterOperation::operator!=):
3356 * platform/graphics/filters/CustomFilterParameter.h:
3357 (CustomFilterParameter):
3358 (WebCore::CustomFilterParameter::isSameType):
3359 (WebCore::CustomFilterParameter::operator==):
3360 (WebCore::CustomFilterParameter::operator!=):
3361 * platform/graphics/filters/CustomFilterProgram.h:
3362 * rendering/style/StyleCustomFilterProgram.h:
3363 (StyleCustomFilterProgram):
3364 (WebCore::StyleCustomFilterProgram::cachedVertexShader):
3365 (WebCore::StyleCustomFilterProgram::cachedFragmentShader):
3366 (WebCore::StyleCustomFilterProgram::operator==):
3368 2012-04-27 Chris Rogers <crogers@google.com>
3370 Re-factor scheduling logic from AudioBufferSourceNode into AudioScheduledSourceNode
3371 https://bugs.webkit.org/show_bug.cgi?id=84639
3373 Reviewed by Eric Carlson.
3375 Playback logic involving noteOn(), noteOff(), and playbackState were intertwined with
3376 the AudioBufferSourceNode's buffer playback code. These are more general concepts and
3377 may be implemented separately in another class called AudioScheduledSourceNode.
3379 No new tests. Covered by existing layout tests.
3381 * GNUmakefile.list.am:
3382 Add AudioScheduledSourceNode files to makefile.
3384 * Modules/webaudio/AudioBufferSourceNode.cpp:
3386 (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
3387 Re-factor some member variables into new base class AudioScheduledSourceNode.
3389 (WebCore::AudioBufferSourceNode::process):
3390 Re-factor scheduling logic into AudioScheduledSourceNode.
3392 * Modules/webaudio/AudioBufferSourceNode.h:
3393 (AudioBufferSourceNode):
3394 Simplify by re-factoring scheduling logic into AudioScheduledSourceNode.
3396 * Modules/webaudio/AudioScheduledSourceNode.cpp: Added.
3398 (WebCore::AudioScheduledSourceNode::AudioScheduledSourceNode):
3399 (WebCore::AudioScheduledSourceNode::updateSchedulingInfo):
3400 Get frame information for the current time quantum.
3402 * Modules/webaudio/AudioScheduledSourceNode.h: Added.
3403 (WebCore::AudioScheduledSourceNode::noteOn):
3404 (WebCore::AudioScheduledSourceNode::noteOff):
3405 (WebCore::AudioScheduledSourceNode::finish):
3406 (WebCore::AudioScheduledSourceNode::playbackState):
3407 (WebCore::AudioScheduledSourceNode::isPlayingOrScheduled):
3408 (WebCore::AudioScheduledSourceNode::hasFinished):
3409 Re-factored from AudioBufferSourceNode.
3412 * WebCore.xcodeproj/project.pbxproj:
3413 Add AudioScheduledSourceNode files to makefiles.
3415 2012-04-26 Sam Weinig <sam@webkit.org>
3417 Add support for the Blob constructor
3418 https://bugs.webkit.org/show_bug.cgi?id=84555
3420 Reviewed by Maciej Stachowiak.
3422 Test: fast/files/blob-constructor.html
3424 This adds an implementation of the Blob constructor that willfully
3425 violates the W3C Editor’s Draft 29 February 2012 in the following ways:
3426 - Elements in the parts array are coerced to DOMStrings https://www.w3.org/Bugs/Public/show_bug.cgi?id=16721
3427 - Don't throw for invalid key in the dictionary https://www.w3.org/Bugs/Public/show_bug.cgi?id=16727
3428 - Values for the endings property are treated as enums https://www.w3.org/Bugs/Public/show_bug.cgi?id=16729
3430 * bindings/js/JSBlobCustom.cpp:
3431 (WebCore::JSBlobConstructor::constructJSBlob):
3432 Implement blob constructor.
3434 * bindings/v8/custom/V8BlobCustom.cpp:
3435 (WebCore::V8Blob::constructorCallback):
3436 Implement blob constructor.
3439 Add constructor to IDL.
3441 * workers/WorkerContext.idl:
3442 Add Blob constructor to the worker global object.
3444 2012-04-27 Allan Sandfeld Jensen <allan.jensen@nokia.com>
3446 [Qt] Fix minimal build.
3447 https://bugs.webkit.org/show_bug.cgi?id=85045
3449 Reviewed by Tor Arne Vestbø.
3451 Compile LIBXML XML parser even if ENABLE_XSLT is not set.
3455 2012-04-27 Shawn Singh <shawnsingh@chromium.org>
3457 Infinite backgroundClipR