1 2009-03-25 Darin Adler <darin@apple.com>
3 Reviewed by David Hyatt.
5 Bug 24740: crash in RenderSlider::setPositionFromValue when calling pause() after setting <video> to display: none
6 https://bugs.webkit.org/show_bug.cgi?id=24740
9 Bug 12104: Native Slider: When the thumb's height is specified as a percentage, it is not centered properly
10 https://bugs.webkit.org/show_bug.cgi?id=12104
12 Test: media/video-display-none-crash.html
14 The problem here was that RenderSlider was trying to position its thumb in a way that
15 requires it to call updateLayout inside rendering code. The right way to position a
16 child renderer is to do layout, so I had to write a layout function. And then fix a few
17 other small problems shown by the same test case.
19 * rendering/RenderSlider.cpp: Made defaultTrackLength have internal linkage.
20 Renamed HTMLSliderThumbElement to SliderThumbElement because we only use the HTML
21 prefix for public DOM classes, not elements used as implementation details.
22 Made SliderThumbElement function members private and got rid of unneeded default
23 argument value for shadowParent.
24 (WebCore::SliderRange::SliderRange): Added. Parses precision, max, and min attributes.
25 (WebCore::SliderRange::clampValue): Added. Does standard clamping based on the above.
26 (WebCore::SliderRange::valueFromElement): Added. Reads the value from the element in
27 a way that clamps to the range.
28 (WebCore::sliderPosition): Added. Computes the slider position: a double.
29 (WebCore::SliderThumbElement::SliderThumbElement): Removed unneeded explicit
30 initialization of m_initialClickPoint.
31 (WebCore::SliderThumbElement::defaultEventHandler): Call setValueForPosition instead
32 of calling setCurrentPosition and valueChanged.
33 (WebCore::RenderSlider::RenderSlider): Remove unneeded explicit initialization of m_thumb.
34 (WebCore::RenderSlider::styleDidChange): Remove unneeded second argument to createThumbStyle.
35 (WebCore::RenderSlider::createThumbStyle): Remove unneeded second argument. Get rid of code
36 setting the position to relative and setting the left and top. We now handle positioning
37 in a custom layout function.
38 (WebCore::RenderSlider::layout): Rewrote to handle positioning of the thumb as layout.
39 (WebCore::RenderSlider::updateFromElement): Added code to immediately update the value
40 in the element if it's out of range. This clamping used to be done as a side effect of
41 setPositionFromValue. Also, this has nothing to do with the renderer, so at some point
42 it could be moved into HTMLInputElement. Removed call to setPositionFromValue
43 and instead just rely on the call to setNeedsLayout. Fix the setNeedsLayout call to be
44 a normal setNeedsLayout(true), not a setNeedsLayout(true, false), because we do want
45 this to be propagated to the parent -- it's not called during layout.
46 (WebCore::RenderSlider::setValueForPosition): Refactor to use the new SliderRange
47 class. Also don't call setCurrentPosition; instead just call setNeedsLayout.
48 (WebCore::RenderSlider::currentPosition): Use the actual position of the renderer rather
49 than the style to find the position; that means this needs to be done after layout is done.
50 Also removed unneeded runtime checks and replaced them with assertions, after checking
51 all callers to see they already guarantee this.
52 (WebCore::RenderSlider::trackSize): Removed unneeded runtime checks and replaced them
53 with assertions, after checking all callers to see they already guarantee this.
54 (WebCore::RenderSlider::inDragMode): Added a null check for m_thumb so this won't
55 crash if called early on a brand new RenderSlider.
57 * rendering/RenderSlider.h: Made all functions private except for forwardEvent and inDragMode.
58 Renamed HTMLSliderThumbElement to SliderThumbElement because we only use the HTML
59 prefix for public DOM classes, not elements used as implementation details. Made the
60 mouseEventIsInThumb function non-virtual. Removed the return value and argument from
61 setPositionFromValue. Removed valueChanged and setCurrentPosition. Removed the oldStyle
62 argument to createThumbStyle (see above). Made SliderThumbElement a friend so it can use some
63 private member functions.
65 2009-03-25 Eli Fidler <eli.fidler@torchmobile.com>
67 Reviewed by George Staikos.
69 Fix ambiguous else cases by adding braces to nested if()s with elses.
71 * loader/MainResourceLoader.cpp:
72 (WebCore::MainResourceLoader::continueAfterContentPolicy):
73 * page/EventHandler.cpp:
74 (WebCore::EventHandler::updateDragAndDrop):
75 * rendering/RenderListMarker.cpp:
76 (WebCore::toArmenianUnder10000):
77 * rendering/TextControlInnerElements.cpp:
78 (WebCore::TextControlInnerTextElement::defaultEventHandler):
80 2009-03-24 Eli Fidler <eli.fidler@torchmobile.com>
82 Reviewed by George Staikos.
84 Move variable into proper platform block to quiet warning.
86 * html/CanvasRenderingContext2D.cpp:
87 (WebCore::CanvasRenderingContext2D::drawTextInternal):
89 2009-03-24 Eric Carlson <eric.carlson@apple.com>
91 Reviewed by Antti Koivisto.
93 Fix for <rdar://problem/6719375> Deal with QTKit loadstate changes when playing streaming movies
95 * WebCore/html/HTMLMediaElement.cpp:
96 (WebCore::HTMLMediaElement::setNetworkState): Deal with media engine reviving after having
97 network state of NETWORK_NO_SOURCE.
99 * WebCore/platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
100 (WebCore::MediaPlayerPrivate::updateStates): Reset m_readyState at each state change since
101 some types of movies currently cause QTKit's load state to bounce around. QTMovieLoadStatePlaythroughOK
102 corresponds to HaveFutureData, not HaveEnoughData.
104 2009-03-24 Adele Peterson <adele@apple.com>
106 Reviewed by Darin Adler.
108 Fix for https://bugs.webkit.org/show_bug.cgi?id=24707
109 <rdar://problem/6593021> Deleting with a caret in a blank, quoted line decreases the quoting, but does not delete the line
111 * editing/TypingCommand.cpp: (WebCore::TypingCommand::deleteKeyPressed):
112 After breaking out of an empty mail blockquote, we still want continue with the deletion
113 so actual content will get deleted, and not just the quote style.
115 2009-03-24 Darin Adler <darin@apple.com>
117 Reviewed by Brady Eidson.
119 <rdar://problem/6624662> REGRESSION (r39904): can't save certain web pages as web archive (ones without favicons!)
121 * loader/archive/cf/LegacyWebArchive.cpp:
122 (WebCore::LegacyWebArchive::create): Added a null check.
124 2009-03-24 Adam Langley <agl@google.com>
126 Reviewed by Darin Fisher.
128 https://bugs.webkit.org/show_bug.cgi?id=24685
130 The Skia drawLine function takes subpixel values and attempts to draw
131 a line with subpixel precision. This is complex and slow for drawing
132 scrollbars which use only vertical and horizontal lines.
134 This changes the Chromium Linux scrollbar code to use drawIRect.
136 * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
137 (WebCore::ScrollbarThemeChromium::invalidateOnMouseEnterExit):
138 (WebCore::drawVertLine):
139 (WebCore::drawHorizLine):
141 (WebCore::ScrollbarThemeChromium::paintTrackPiece):
142 (WebCore::ScrollbarThemeChromium::paintThumb):
144 2009-03-24 David Kilzer <ddkilzer@apple.com>
146 Bug 23310: Setting an absolute path (/abs) on an <iframe> with no src doesn't resolve the URL properly
148 <https://bugs.webkit.org/show_bug.cgi?id=23310>
150 Reviewed by Darin Adler.
152 Test: fast/frames/iframe-no-src-set-location.html
155 (WebCore::Document::completeURL): If m_baseURL is empty or is
156 about:blank and we have a parent document, use the parent
157 document's URL for the base when completing a new URL.
159 2009-03-24 Simon Fraser <simon.fraser@apple.com>
161 Reviewed by Dave Hyatt
163 https://bugs.webkit.org/show_bug.cgi?id=24659
165 When hit-testing 3d-transformed layers, it doesn't make sense to project the hitTestRect
166 into the coordinate space of the layer, and doing so can result in pathalogical quads
167 that break hit testing. In that case, simply use the same bounds as used for painting,
168 which are the composited bounds for this layer.
170 Test: transforms/3d/hit-testing/rotated-hit-test.html
172 * rendering/RenderLayer.cpp:
173 (WebCore::RenderLayer::hitTestLayer):
175 2009-03-24 Simon Fraser <simon.fraser@apple.com>
177 Reviewed by Dave Hyatt
179 https://bugs.webkit.org/show_bug.cgi?id=24436
181 When compositing is enabled, painting and hit testing end up using different
182 clipping roots, because, for painting, every composited layer is a clipping root,
183 but for hit testing only layers with transforms are. To fix this, we use
184 temporary clip rects for hit testing, if the page is in compositing mode.
186 * rendering/RenderLayer.cpp:
187 (WebCore::RenderLayer::paintLayer):
188 (WebCore::RenderLayer::hitTestLayer):
189 (WebCore::RenderLayer::parentClipRects):
190 (WebCore::RenderLayer::calculateRects):
191 * rendering/RenderLayer.h:
193 2009-03-24 Simon Fraser <simon.fraser@apple.com>
195 Reviewed by Dan Bernstein
197 https://bugs.webkit.org/show_bug.cgi?id=24782
199 Fix regression with CSS clip rects with non-length values, by reverting to
200 the original code, but passing the zoom multiplier through convertToLength().
202 Also make stylistic change in createTransformOperations(), renaming 'inStyle'
205 Tested by existing tests.
207 * css/CSSStyleSelector.cpp:
208 (WebCore::convertToLength):
209 (WebCore::CSSStyleSelector::applyProperty):
210 (WebCore::CSSStyleSelector::createTransformOperations):
212 2009-03-24 David Hyatt <hyatt@apple.com>
214 Reviewed by Simon Fraser
216 https://bugs.webkit.org/show_bug.cgi?id=21789, overflow:hidden elements should clip their foreground contents
219 This patch makes non-self-painting overflow layers and control clips work with border-radius. RenderLayers
220 that should be clipped by overflow ancestors with border-radius are still broken.
222 Added fast/clip/overflow-border-radius-clip.html
224 * rendering/RenderBox.cpp:
225 (WebCore::RenderBox::pushContentsClip):
227 2009-03-24 David Hyatt <hyatt@apple.com>
229 Reviewed by Simon Fraser
231 https://bugs.webkit.org/show_bug.cgi?id=21789, overflow:hidden elements should clip their foreground contents.
233 This first patch makes overflow:hidden properly clip the foreground contents of overflow:hidden replaced elements. Common
234 replaced elements now default to overflow:hidden in the UA stylesheet (this is what the spec specifically recommends be
237 Added fast/replaced/border-radius-clip.html
240 * rendering/RenderReplaced.cpp:
241 (WebCore::RenderReplaced::paint):
242 * rendering/RenderWidget.cpp:
243 (WebCore::RenderWidget::paint):
245 2009-03-24 Adele Peterson <adele@apple.com>
249 Only build these Mail quirks checks in on the Mac.
251 * dom/Document.cpp: (WebCore::disableRangeMutation):
252 * html/HTMLElement.cpp: (WebCore::HTMLElement::inEitherTagList):
254 2009-03-24 Brent Fulgham <bfulgham@webkit.org>
256 Build fix, no review.
258 Remove ResourceLoaderCFNet.cpp from build list for Cairo Releas
261 * WebCore.vcproj/WebCore.vcproj:
263 2009-03-24 Eric Carlson <eric.carlson@apple.com>
265 Fix layout tests broken by r41907.
267 * html/HTMLMediaElement.cpp:
268 (WebCore::HTMLMediaElement::setReadyState): Don't set "was playing" based on the new ready state
270 2009-03-24 Dmitry Titov <dimich@chromium.org>
272 Reviewed by Dimitri Glazkov.
274 https://bugs.webkit.org/show_bug.cgi?id=24689
275 Fix Chromium compilation errors.
277 * bindings/v8/WorkerContextExecutionProxy.cpp:
278 (WebCore::WorkerContextExecutionProxy::FindOrCreateEventListener):
279 (WebCore::WorkerContextExecutionProxy::RemoveEventListener):
281 2009-03-24 Yury Semikhatsky <yurys@chromium.org>
283 Reviewed by Darin Adler.
285 https://bugs.webkit.org/show_bug.cgi?id=24759
286 Add missing methods Element.prototype.removeMatchingStyleClasses and
287 Node.prototype.enclosingNodeOrSelfWithNodeNameInArray to SourceFrame content
288 iframe. These methods are called by Element.prototype.removeStyleClass and
289 Node.prototype.enclosingNodeOrSelfWithNodeName.
291 * inspector/front-end/SourceFrame.js:
292 (WebInspector.SourceFrame.prototype._loaded):
294 2009-03-24 Mark Mentovai <mark@chromium.org>
296 Reviewed by Mark Rowe.
298 https://bugs.webkit.org/show_bug.cgi?id=24653
299 WebKit should be buildable without prefix header injection.
300 Adds missing #includes and forward declarations as needed.
302 * editing/SmartReplaceCF.cpp:
303 * platform/graphics/mac/ColorMac.mm:
304 * platform/graphics/mac/FontCacheMac.mm:
305 * platform/graphics/mac/FontCustomPlatformData.h:
306 * platform/graphics/mac/FontMac.mm:
307 * platform/graphics/mac/FontMacATSUI.mm:
308 * platform/graphics/mac/FontPlatformData.h:
309 * platform/graphics/mac/FontPlatformDataMac.mm:
310 * platform/graphics/mac/GraphicsContextMac.mm:
311 * platform/graphics/mac/SimpleFontDataMac.mm:
312 * platform/mac/FoundationExtras.h:
313 * platform/mac/LocalCurrentGraphicsContext.h:
314 * platform/mac/WebCoreSystemInterface.h:
315 * platform/mac/WebCoreSystemInterface.mm:
316 * platform/mac/WebCoreTextRenderer.h:
317 * platform/mac/WebCoreTextRenderer.mm:
318 * platform/mac/WebFontCache.h:
319 * platform/mac/WebFontCache.mm:
320 * platform/text/PlatformString.h:
321 * platform/text/mac/ShapeArabic.c:
322 * platform/text/mac/StringMac.mm:
323 * rendering/RenderThemeChromiumMac.h:
325 2009-03-24 Dan Bernstein <mitz@apple.com>
327 Reviewed by Darin Adler.
329 - fix <rdar://problem/6107874> by capping the nesting depth of
330 "block-level" elements generated by the parser
332 Test: fast/parser/block-nesting-cap.html
334 * html/HTMLParser.cpp:
335 (WebCore::HTMLParser::HTMLParser):
336 (WebCore::HTMLParser::insertNode):
337 (WebCore::HTMLParser::pushBlock):
338 (WebCore::HTMLParser::popOneBlockCommon):
339 (WebCore::HTMLParser::freeBlock):
342 2009-03-23 Greg Bolsinga <bolsinga@apple.com>
344 Reviewed by David Kilzer.
346 https://bugs.webkit.org/show_bug.cgi?id=24771
348 DOMTimeStamps are based upon 1970.
350 * platform/mac/GeolocationServiceMac.mm:
351 (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
353 2009-03-23 Eric Seidel <eric@webkit.org>
355 Build fix, no review.
357 * rendering/RenderObject.cpp:
358 (WebCore::RenderObject::createVisiblePosition): change .container to .isNotNull()
360 2009-03-23 Eric Seidel <eric@webkit.org>
362 Reviewed by Darin Adler.
364 Rename Position::container to m_anchorNode and make it private
365 https://bugs.webkit.org/show_bug.cgi?id=24760
367 More code cleanup for Position.
369 Change all uses of m_container to node()
370 Eventually most uses of node() should change to anchorNode() to designate
371 that it's the node the Position is anchored to, but not necessarily the
372 container of the position (it could be the before/after neighbor).
374 Remove any code which sets m_container, and change it to use a new
375 Position::moveToPosition function which takes a node and offset.
376 It never makes sense to change the node and leave the offset.
379 (WebCore::Position::Position):
380 (WebCore::Position::clear):
381 (WebCore::Position::anchorNode):
382 (WebCore::Position::node):
383 (WebCore::Position::moveToPosition):
384 (WebCore::Position::moveToOffset):
385 (WebCore::Position::isNull):
386 (WebCore::Position::isNotNull):
387 (WebCore::operator==):
389 (WebCore::Range::create):
390 (WebCore::Range::compareBoundaryPoints):
391 * dom/RangeBoundaryPoint.h:
392 (WebCore::RangeBoundaryPoint::container):
393 (WebCore::RangeBoundaryPoint::set):
394 (WebCore::RangeBoundaryPoint::setOffset):
395 (WebCore::RangeBoundaryPoint::setToChild):
396 (WebCore::RangeBoundaryPoint::setToStart):
397 (WebCore::RangeBoundaryPoint::setToEnd):
399 2009-03-17 Eric Seidel <eric@webkit.org>
401 Reviewed by David Hyatt.
403 document.write() should be able to make a document strict mode
404 https://bugs.webkit.org/show_bug.cgi?id=24336
406 Remove an implicit write of "<html>" on the first document.write call
407 this was added as part of a KDE import http://trac.webkit.org/changeset/798
408 with no layout test or explanation. I can't think of any reason why
409 an implicit <html> write is necessary (or correct), so I'm removing it and
410 adding a test for the correct behavior. The parser will add any necessary
411 HTMLHTMLElements during the write() anyway.
413 Our behavior is now tested by fast/dom/Document/document-write-doctype
414 and matches IE, FF fails this new test. Mozilla bug filed:
415 https://bugzilla.mozilla.org/show_bug.cgi?id=483908
418 (WebCore::Document::write):
420 2009-03-23 Sam Weinig <sam@webkit.org>
422 Reviewed by Dan Bernstein.
424 Fix for <rdar://problem/6140966>
425 Empty Caches does not clear the Cross-site XMLHttpRequest preflight cache
428 * WebCore.xcodeproj/project.pbxproj:
429 * loader/CrossOriginPreflightResultCache.cpp:
430 (WebCore::CrossOriginPreflightResultCache::empty):
431 * loader/CrossOriginPreflightResultCache.h:
433 2009-03-23 Darin Adler <darin@apple.com>
435 Reviewed by Adele Peterson.
437 Bug 24726: hit testing doesn't work right when the click is on anonymous content
438 https://bugs.webkit.org/show_bug.cgi?id=24726
439 rdar://problem/6696992
441 Test: editing/selection/hit-test-anonymous.html
443 * rendering/RenderBR.cpp:
444 (WebCore::RenderBR::positionForPoint): Call createVisiblePosition instead of
445 creating a VisiblePosition directly. It will handle finding non-anonymous
446 content nearby if node() is 0.
447 * rendering/RenderBlock.cpp:
448 (WebCore::positionForPointRespectingEditingBoundaries): Ditto.
449 (WebCore::positionForPointWithInlineChildren): Ditto.
450 (WebCore::RenderBlock::positionForPoint): Ditto.
451 * rendering/RenderBox.cpp:
452 (WebCore::RenderBox::positionForPoint): Ditto.
453 * rendering/RenderObject.cpp:
454 (WebCore::RenderObject::positionForPoint): Ditto.
455 (WebCore::RenderObject::createVisiblePosition): Added.
456 * rendering/RenderObject.h: Added createVisiblePosition.
457 * rendering/RenderReplaced.cpp:
458 (WebCore::RenderReplaced::positionForPoint): Call createVisiblePosition.
459 * rendering/RenderSVGInlineText.cpp:
460 (WebCore::RenderSVGInlineText::positionForPoint): Ditto.
461 * rendering/RenderText.cpp:
462 (WebCore::RenderText::positionForPoint): Ditto.
464 2009-03-23 Adele Peterson <adele@apple.com>
466 Reviewed by Darin Adler & Dave Hyatt.
468 Fix for <rdar://problem/6621310> REGRESSION(35185): Apple Travel HTML emails missing some style after Safari 4 upgrade
470 Leopard Mail doesn't expect <style> to be in the body. This change reverts back to the old behavior of
471 moving <style> to <head> for that version of Mail.
473 * html/HTMLElement.cpp: (WebCore::HTMLElement::inEitherTagList):
475 2009-03-23 Adele Peterson <adele@apple.com>
477 Reviewed by Mark Rowe & Dave Hyatt.
479 Merge some of the individual Mail quirks into two settings that we can check for future quirks.
483 (WebCore::disableRangeMutation):
484 (WebCore::Document::nodeChildrenChanged):
485 (WebCore::Document::nodeWillBeRemoved):
486 (WebCore::Document::textInserted):
487 (WebCore::Document::textRemoved):
488 (WebCore::Document::textNodesMerged):
489 (WebCore::Document::textNodeSplit):
491 (WebCore::Settings::Settings):
492 (WebCore::Settings::setNeedsLeopardMailQuirks):
493 (WebCore::Settings::setNeedsTigerMailQuirks):
495 (WebCore::Settings::needsLeopardMailQuirks):
496 (WebCore::Settings::needsTigerMailQuirks):
498 2009-03-23 Ada Chan <adachan@apple.com>
500 https://bugs.webkit.org/show_bug.cgi?id=24762
501 Support text-indent in <option> elements on windows platform.
503 Reviewed by Adele Peterson.
506 * platform/PopupMenuStyle.h: We don't honor font specified on <option> elements right now. Make this
507 explicit via windows themed default stylesheet.
508 (WebCore::PopupMenuStyle::PopupMenuStyle): Also store text-indent and text-direction.
509 (WebCore::PopupMenuStyle::textIndent):
510 (WebCore::PopupMenuStyle::textDirection):
511 * platform/win/PopupMenuWin.cpp:
512 (WebCore::PopupMenu::paint): Adjust the text's x-coordinate if text-indent is supported for options and
513 text-indent is specified with LTR direction.
514 * rendering/RenderMenuList.cpp:
515 (WebCore::RenderMenuList::updateOptionsWidth): Take text-indent into account if theme supports text-indent for options.
516 (WebCore::RenderMenuList::itemStyle): Use new PopupMenuStyle constructor on windows.
517 (WebCore::RenderMenuList::menuStyle): Ditto.
518 * rendering/RenderTextControlSingleLine.cpp:
519 (WebCore::RenderTextControlSingleLine::menuStyle): Ditto.
520 * rendering/RenderTheme.h:
521 (WebCore::RenderTheme::popupOptionSupportsTextIndent): Added. Default is false since we are only supporting it in windows for now.
522 * rendering/RenderThemeWin.h:
523 (WebCore::RenderThemeWin::popupOptionSupportsTextIndent): Returns true for windows.
525 2009-03-23 Sam Weinig <sam@webkit.org>
527 Reviewed by Anders Carlsson.
529 Fix for https://bugs.webkit.org/show_bug.cgi?id=24699
530 REGRESSION: Java Applets broken
531 <rdar://problem/6707494>
533 Fix loading Java applets without a codeBase. Only pass the base (up to the
534 the last path component) of the baseURL to the plug-in.
536 * html/HTMLAppletElement.cpp:
537 (WebCore::HTMLAppletElement::createRenderer):
539 (WebCore::KURL::baseAsString):
542 2009-03-23 Darin Adler <darin@apple.com>
544 Reviewed by Sam Weinig.
546 * platform/KURL.h: Removed now-incorrect comments.
547 None of the parts include the separator characters any more, now that
548 query doesn't include the "?", so the comments explaining which do and do
549 not are no-longer helpful.
551 2009-03-23 David Levin <levin@chromium.org>
553 Reviewed by Dimitri Glazkov.
555 https://bugs.webkit.org/show_bug.cgi?id=24764
557 Renamed files V8NodeFilter -> V8NodeFilterCondition to reflect
558 class names. Also fixed some headers that got mangled in search/replace
561 No change in behavior, so no test.
563 * bindings/v8/V8NodeFilter.h: Removed.
564 * bindings/v8/V8NodeFilterCondition.cpp: Renamed from WebCore/bindings/v8/V8NodeFilter.cpp.
565 * bindings/v8/V8NodeFilterCondition.h: Added.
566 * bindings/v8/custom/V8ClipboardCustom.cpp:
567 * bindings/v8/custom/V8DocumentCustom.cpp:
568 * bindings/v8/custom/V8ElementCustom.cpp:
569 * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
570 * bindings/v8/custom/V8NavigatorCustom.cpp:
572 2009-03-23 Darin Fisher <darin@chromium.org>
574 Reviewed by Antti Koivisto.
576 https://bugs.webkit.org/show_bug.cgi?id=24741
578 Adds a unique across-browser-sessions identifier to FormData, which may
579 be used by ResourceHandle as a secondary cache key to enable cached
582 At issue: two otherwise identical form submissions may result in
583 completely independent responses, which may each be appropriate to
584 store and reuse from cache.
586 * html/HTMLFormElement.cpp: Added call to FormData::setIdentifier so that
587 we only enable cached form submissions for those generated by HTML. This
588 way we do not bother with POSTs generated by XMLHttpRequest.
589 (WebCore::generateFormDataIdentifier):
590 (WebCore::HTMLFormElement::createFormData):
591 * platform/network/FormData.cpp: Initialize m_identifier to 0, which means
592 the unspecified identifier. So by default there is no identifier and
594 (WebCore::FormData::FormData):
595 * platform/network/FormData.h: Added m_identifier with setter and getter.
596 (WebCore::FormData::setIdentifier):
597 (WebCore::FormData::identifier):
599 2009-03-23 Simon Fraser <simon.fraser@apple.com>
601 Reviewed by Antti Koivisto
603 https://bugs.webkit.org/show_bug.cgi?id=24733
605 Fix media controller with full-page zoom. Previously, the media controller
606 shadow nodes never saw style changes on the RenderMedia, so did not respond
607 to zooming at all. Now, we update the style on the shadow renderers
608 whenever RenderMedia gets a style change. Also fix the video thumb in
609 the theme to be scaled properly.
611 Test: media/video-controls-zoomed.html
613 * rendering/MediaControlElements.cpp:
614 (WebCore::MediaControlShadowRootElement::updateStyle):
615 (WebCore::MediaTextDisplayElement::MediaTextDisplayElement):
616 (WebCore::MediaTextDisplayElement::updateStyle):
617 (WebCore::MediaControlInputElement::MediaControlInputElement):
618 (WebCore::MediaControlInputElement::updateStyle):
619 * rendering/MediaControlElements.h:
620 * rendering/RenderMedia.cpp:
621 (WebCore::RenderMedia::styleDidChange):
622 * rendering/RenderMedia.h:
623 * rendering/RenderThemeMac.mm:
624 (WebCore::RenderThemeMac::adjustSliderThumbSize):
626 2009-03-23 Mike Belshe <mike@belshe.com>
628 Reviewed by Darin Adler.
630 https://bugs.webkit.org/show_bug.cgi?id=24739
632 Rework StringImpl::create methods to try to allocate a single buffer
633 rather than allocating both the StringImpl class and a separate data
636 * platform/text/StringImpl.cpp:
637 * platform/text/StringImpl.h:
639 2009-03-23 Darin Adler <darin@apple.com>
641 Reviewed by Antti Koivisto.
643 Based on a patch by Nico Weber <nicolasweber@gmx.de>
645 Bug 24755: LayoutTests/http/tests/misc/url-in-utf16le.html regression
646 https://bugs.webkit.org/show_bug.cgi?id=24755
648 * platform/text/TextEncoding.cpp:
649 (WebCore::TextEncoding::isUTF7Encoding): Added. Checks if the current encoding
650 is UTF7 without loading extended codecs.
651 (WebCore::TextEncoding::encodingForFormSubmission): Use isUTF7Encoding() instead
652 of comparing with UTF7Encoding(). Eliminate the explicit check of
653 noExtendedTextEncodingNameUsed() because that's now handled by the functions
654 that this function calls instead.
656 * platform/text/TextEncoding.h: Added isUTF7Encoding function.
657 Also tweaked formatting a bit.
659 2009-03-20 Peter Kasting <pkasting@google.com>
661 Reviewed by Darin Fisher.
663 https://bugs.webkit.org/show_bug.cgi?id=24720
664 RenderThemeChromium should draw something for Slider parts instead of
665 dropping them on the floor.
667 * platform/chromium/ChromiumBridge.h:
668 * rendering/RenderThemeChromiumWin.cpp:
669 (WebCore::RenderThemeChromiumWin::adjustSliderThumbSize):
670 (WebCore::RenderThemeChromiumWin::paintSliderTrack):
671 (WebCore::RenderThemeChromiumWin::determineSliderThumbState):
672 (WebCore::RenderThemeChromiumWin::getThemeData):
673 * rendering/RenderThemeChromiumWin.h:
674 (WebCore::RenderThemeChromiumWin::paintSliderThumb):
676 2009-03-23 Glen Murphy <glen@chromium.org>
678 Reviewed by Darin Fisher.
680 https://bugs.webkit.org/show_bug.cgi?id=24657
682 Fix Skia drawing of highly scaled bitmaps; the conversion to
683 IntRect produced visible layout test failures in highly scaled
686 Test: svg/custom/image-small-width-height.svg
688 * WebCore\platform\graphics\skia\ImageSkia.cpp:
690 2009-03-23 David Kilzer <ddkilzer@apple.com>
692 Provide JavaScript exception information after slow script timeout
694 Reviewed by Oliver Hunt.
696 * bindings/js/ScriptController.cpp:
697 (WebCore::ScriptController::evaluate): Changed to report
698 exceptions for the Interrupted completion type as well.
700 2009-03-23 Simon Fraser <simon.fraser@apple.com>
702 Reviewed by Darin Adler
704 https://bugs.webkit.org/show_bug.cgi?id=24736
706 Fix three mostly-unrelated problems with full-page zoom:
709 (WebCore::Document::elementFromPoint):
710 Document::elementFromPoint() needs to take full-page zoom into account.
712 * dom/MouseRelatedEvent.cpp:
713 (WebCore::MouseRelatedEvent::receivedTarget):
714 Take full-page zoom into account when computing offsetX/offsetY.
716 * html/HTMLSelectElement.cpp:
717 (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
718 Don't use offsetX/offsetY when hit testing list boxes; offsets were broken
719 with full-page zoom, and using pageX/pageY is easier because we don't
720 have to worry about the event target, and we already have a point in
721 absolute coordinates.
723 Tests: fast/forms/listbox-hit-test-zoomed.html
724 fast/forms/search-zoomed.html
725 fast/forms/slider-zoomed.html
727 2009-03-23 Simon Fraser <simon.fraser@apple.com>
729 Reviewed by Dan Bernstein
731 https://bugs.webkit.org/show_bug.cgi?id=24753
733 The rect for CSS 'clip' needs to have zooming applied to it.
735 Test: fast/css/clip-zooming.html
737 * css/CSSStyleSelector.cpp:
738 (WebCore::CSSStyleSelector::applyProperty):
740 2009-03-23 Eric Carlson <eric.carlson@apple.com>
742 Reviewed by Adam Roben.
744 <rdar://problem/6704282>
745 https://bugs.webkit.org/show_bug.cgi?id=24719
746 QTMovieWinTimer logic inversion
748 Fix logic inversion in the Win32 timer used by QTMovieWin that caused it to always
749 use SetTimer, even when the intervals was below USER_TIMER_MINIMUM. A side effect of
750 this was that a movie timer would sometimes be blocked for significant amounts of time
751 because WM_TIMER messages are not processed when the thread's message queue has any
752 higher priority messages, and WebCore/Win's timer uses PostMessage for low interval
753 timers. Also change SetTimer call to use HWND and custom message instead of
754 timer function since the timer already has an HWND for processing PostMessage.
756 Not possible to make a test for this because it is so timing dependant.
758 * platform/graphics/win/QTMovieWinTimer.cpp:
759 (TimerWindowWndProc):
760 (setSharedTimerFireDelay):
762 2009-03-23 Eric Carlson <eric.carlson@apple.com>
764 Reviewed by Adele Peterson.
766 https://bugs.webkit.org/show_bug.cgi?id=24588
768 Update media element implementation to current HTML5 spec
771 media/media-constants.html
772 media/video-seek-no-src-exception.html
773 media/video-source-add-src.html
774 media/video-src-invalid-remove.html
775 media/video-src-plus-source.html
776 media/video-timeupdate-during-playback.html
778 * dom/EventNames.h: Remove obsolute events, add new ones.
779 * html/HTMLMediaElement.cpp:
780 (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize new member vars.
781 (WebCore::HTMLMediaElement::attributeChanged): Trigger load() only when we don't
783 (WebCore::HTMLMediaElement::removedFromDocument): Deal with state name changes.
784 (WebCore::HTMLMediaElement::scheduleProgressEvent): New, create a progress event and
785 add it to the event queue to be dispatch when the timer fires.
786 (WebCore::HTMLMediaElement::scheduleEvent): New, create a generic event and add
787 it to the event queue to be dispatch when the timer fires.
788 (WebCore::HTMLMediaElement::enqueueEvent): Add an event to the queue and ticke the
790 (WebCore::HTMLMediaElement::asyncEventTimerFired): Dispatch all pending events.
791 (WebCore::HTMLMediaElement::loadTimerFired): Either trigger the initial load or
792 try to load the next <source> url.
793 (WebCore::HTMLMediaElement::load): Minor style change.
794 (WebCore::HTMLMediaElement::loadInternal): The first part of the spec load algorithm, cleanup
795 the current load (if any) and set up state for a new load.
796 (WebCore::HTMLMediaElement::selectMediaResource): Deal with no 'src' or <source>, post 'loadstart'
797 event, and initiate load from 'src' if present.
798 (WebCore::HTMLMediaElement::loadNextSourceChild): Initiate load from next <source> url, or trigger
799 noneSupported() if no more to consider.
800 (WebCore::HTMLMediaElement::loadResource): Instantiate a new MediaPlayer and ask it to load a url.
801 (WebCore::HTMLMediaElement::startProgressEventTimer): Start the repeating progress event timer.
802 (WebCore::HTMLMediaElement::noneSupported): Post error event and set up state when no valid
804 (WebCore::HTMLMediaElement::mediaEngineError): Post error event and set up state when no valid
805 media engine failed with a decode error or a network error.
806 (WebCore::HTMLMediaElement::mediaPlayerNetworkStateChanged):
807 (WebCore::HTMLMediaElement::setNetworkState): Updated for new spec network states.
808 (WebCore::HTMLMediaElement::mediaPlayerReadyStateChanged):
809 (WebCore::HTMLMediaElement::setReadyState): Updated for new spec ready state.
810 (WebCore::HTMLMediaElement::progressEventTimerFired): Bail if the network is not active.
811 (WebCore::HTMLMediaElement::seek): Return INVALID_STATE_ERR exception if state is too low or
812 if player hasn't been set up yet. This is necessary becase load() is async. Clear the flag
813 we use to guard against sending 'ended' more than once.
814 (WebCore::HTMLMediaElement::duration): Don't bother calling media engine before it has metadata.
815 (WebCore::HTMLMediaElement::setDefaultPlaybackRate): Remove exception param, 0 is no longer an
817 (WebCore::HTMLMediaElement::setPlaybackRate): Remove exception param, 0 is no longer an
818 invalid rate. Cache rate being set so we can use it later if media engine isn't ready now.
819 (WebCore::HTMLMediaElement::play): Remove exception param, play() before load() now just
820 starts loading asynchronously.
821 (WebCore::HTMLMediaElement::playInternal): Remove exception param. Fire 'waiting' or 'playing'
822 event depending on current state.
823 (WebCore::HTMLMediaElement::pause): Remove exception param, pause() before load() now just
824 starts loading asynchronously.
825 (WebCore::HTMLMediaElement::pauseInternal): Remove exception param.
826 (WebCore::HTMLMediaElement::setVolume): dispatchEventAsync -> scheduleEvent
827 (WebCore::HTMLMediaElement::setMuted): dispatchEventAsync -> scheduleEvent
828 (WebCore::HTMLMediaElement::togglePlayState): Remove exception param.
829 (WebCore::HTMLMediaElement::beginScrubbing): pause() doesn't take an exception param.
830 (WebCore::HTMLMediaElement::startPlaybackProgressTimer): New, starts timer that fires 4 times per
831 second when the movie is playing to timeupdate so we can post 'timeupdate' events.
832 (WebCore::HTMLMediaElement::playbackProgressTimerFired): Timer proc.
833 (WebCore::HTMLMediaElement::scheduleTimeupdateEvent): Bottleneck around scheduling a 'timeupdate'
834 event because we both fire them them when the spec says we should and when the media engine
835 says that time has jumped, but we don't want to fire more than one at a given movie time. We also
836 use this bottleneck to keep track of the last time one was posted so we won't fire too often
838 (WebCore::HTMLMediaElement::canPlay): readyState now tracks whether or not we have metadata.
839 (WebCore::HTMLMediaElement::havePotentialSourceChild): New, checks to see if there are a <source>
840 element with a 'src' attribute that we have not tried to load yet.
841 (WebCore::HTMLMediaElement::nextSourceChild): New, returns the url and content type of the next
842 <source> element that we haven't tried to load.
843 (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Schedule 'seeked' event when seeking completes.
844 Set a flag when we post the 'ended' event, clear it when time changed and we aren't at the end since
845 some media engines call this proc more than once when playback reaches the end and stops, but we
846 don't want to post 'ended' more than once.
847 (WebCore::HTMLMediaElement::mediaPlayerDurationChanged): New, added so media engine can inform
848 when the movie duration changes and we can post 'durationchanged' event.
849 (WebCore::HTMLMediaElement::mediaPlayerRateChanged): New, added so media engine can inform when
850 the rate changed and we can updated our cached rate. This is useful because we only want to know
851 post periodic 'timeupdate' events when the movie is actually playing, and because we want to know
852 the actual playback rate when it differs from what we tried to set.
853 (WebCore::HTMLMediaElement::mediaPlayerSizeChanged): New, added so media engine can inform when
854 a movie's intrinsic size changes and we can inform the renderer.
855 (WebCore::HTMLMediaElement::potentiallyPlaying): Renamed from activelyPlaying since the spec now
856 uses "actively playing" for this concept. Update logic for new state names and un-comment calls
857 to stoppedDueToErrors() and pausedForUserInteraction() since the spec says those condiditons
858 are part of the answer.
859 (WebCore::HTMLMediaElement::endedPlayback): Update logic for new state names.
860 (WebCore::HTMLMediaElement::stoppedDueToErrors): New, spec says this logic should be part of
861 the determination of "potentially playing".
862 (WebCore::HTMLMediaElement::pausedForUserInteraction): New, placeholder for when (if) user
863 agent supports this spec concept.
864 (WebCore::HTMLMediaElement::updatePlayState): Stop timer used to fire periodic 'timeupdate'
865 events when we pauses the movie. Set the media engine rate before calling play() in case it
866 wasn't set up when the rate was changed.
867 (WebCore::HTMLMediaElement::stopPeriodicTimers): New, stop the progress event and 'timeupate'
869 (WebCore::HTMLMediaElement::userCancelledLoad): New, logic pulled out of documentWillBecomeInactive
870 and updated for the current spec.
871 (WebCore::HTMLMediaElement::documentWillBecomeInactive): Moved some logic to userCancelledLoad.
872 (WebCore::HTMLMediaElement::documentDidBecomeActive): Update comments.
873 (WebCore::HTMLMediaElement::initialURL): Update for refactoring of code that determines the
875 * html/HTMLMediaElement.h: Change ReadyState and NetworkState enums to match names in the spec,
876 update for changes in .cpp.
877 (WebCore::HTMLMediaElement::):
879 * html/HTMLMediaElement.idl: Update ready state and network state constants for spec changes.
880 defaultPlaybackRate, playbackRate, play(), and pause() no longer raise exceptions.
882 * html/HTMLSourceElement.cpp:
883 (WebCore::HTMLSourceElement::insertedIntoDocument): Update for network state name changes.
885 * html/HTMLVideoElement.cpp:
886 (WebCore::HTMLVideoElement::updatePosterImage): Update for ready state name changes.
889 (WebCore::MediaError::): add MEDIA_ERR_NONE_SUPPORTED.
891 * html/MediaError.idl: add MEDIA_ERR_NONE_SUPPORTED.
893 * loader/MediaDocument.cpp:
894 (WebCore::MediaDocument::defaultEventHandler): play() and pause() don't take an exception.
896 * platform/graphics/MediaPlayer.cpp:
897 (WebCore::NullMediaPlayerPrivate::readyState): Update for newtork state name changes.
898 (WebCore::MediaPlayer::sizeChanged): New, so engine can report intrinsic size changes.
899 (WebCore::MediaPlayer::rateChanged): New, so engine can report rate changes.
900 (WebCore::MediaPlayer::durationChanged): New, so engine can report duration changes.
901 * platform/graphics/MediaPlayer.h: Update NetworkState and ReadyState enum names to match spec
903 (WebCore::MediaPlayerClient::mediaPlayerDurationChanged): New.
904 (WebCore::MediaPlayerClient::mediaPlayerRateChanged): New.
905 (WebCore::MediaPlayerClient::mediaPlayerSizeChanged): New.
906 (WebCore::MediaPlayer::):
908 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
909 (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): Update for network/ready state name changes.
910 (WebCore::MediaPlayerPrivate::load): Ditto.
911 (WebCore::MediaPlayerPrivate::updateStates): Ditto.
912 (WebCore::MediaPlayerPrivate::loadingFailed): Ditto.
914 * platform/graphics/mac/MediaPlayerPrivateQTKit.h: Update for network/ready state name changes.
915 Remove endPointTimer, it is no longer necessary. Add m_enabledTrackCount and m_duration.
916 (WebCore::MediaPlayerPrivate::metaDataAvailable):
917 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
918 (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): No more m_endPointTimer or m_endTime. Initialize
919 m_enabledTrackCount and m_duration. Update for network/ready state name changes.
920 (WebCore::MediaPlayerPrivate::load): Update for network/ready state name changes.
921 (WebCore::MediaPlayerPrivate::play): No more m_endPointTimer.
922 (WebCore::MediaPlayerPrivate::pause): Ditto.
923 (WebCore::MediaPlayerPrivate::currentTime): No more m_endTime.
924 (WebCore::MediaPlayerPrivate::seek): Ditto.
925 (WebCore::MediaPlayerPrivate::doSeek): Ditto, plus don't call setRate(0) when the rate is
927 (WebCore::MediaPlayerPrivate::setEndTime): No more m_endTime.
928 (WebCore::MediaPlayerPrivate::updateStates): Update for network/ready state name changes. Return
929 different errors depending on what causes a failure. Watch for and report duration changes.
930 (WebCore::MediaPlayerPrivate::rateChanged): Report rate changes.
931 (WebCore::MediaPlayerPrivate::sizeChanged): Report size changes.
932 (WebCore::MediaPlayerPrivate::didEnd): No more endpoint timer.
933 (WebCore::MediaPlayerPrivate::setVisible): Update for network/ready state name changes.
934 (WebCore::MediaPlayerPrivate::disableUnsupportedTracks): Don't return number of unsupported
935 tracks, store in m_enabledTrackCount so we can use it to help determine causes of failure.
937 * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
938 (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): Update for network/ready state name changes.
939 (WebCore::MediaPlayerPrivate::load): Ditto.
940 (WebCore::MediaPlayerPrivate::duration): Ditto.
941 (WebCore::MediaPlayerPrivate::updateStates): Ditto.
942 (WebCore::MediaPlayerPrivate::naturalSize): Ditto.
944 * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
945 (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): No more m_endPointTimer. Update for
946 network/ready state name changes.
947 (WebCore::MediaPlayerPrivate::load): Update for network/ready state name changes. No more
949 (WebCore::MediaPlayerPrivate::play): No more m_endPointTimer.
950 (WebCore::MediaPlayerPrivate::pause): Ditto.
951 (WebCore::MediaPlayerPrivate::setEndTime): Ditto.
952 (WebCore::MediaPlayerPrivate::updateStates): Update for network/ready state name changes.
953 (WebCore::MediaPlayerPrivate::didEnd): No more m_endPointTimer.
954 * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
956 * rendering/MediaControlElements.cpp:
957 (WebCore::MediaControlPlayButtonElement::defaultEventHandler): Update for network/ready state
959 (WebCore::MediaControlSeekButtonElement::defaultEventHandler): Ditto.
961 2009-03-22 Kevin Ollivier <kevino@theolliviers.com>
963 wxGTK build fix. Add missing header.
965 * platform/wx/wxcode/gtk/non-kerned-drawing.cpp:
967 2009-03-22 Simon Fraser <simon.fraser@apple.com>
969 Reviewed by Dan Bernstein
971 https://bugs.webkit.org/show_bug.cgi?id=24665
973 Image-map code in RenderImage could result in RenderImage::nodeAtPoint()
974 setting HitTestResult::innerNode(), but returning false, which violates
975 hit testing rules. Use a temporary HitTestResult so that we only fill in
976 result when we know we've hit.
978 * rendering/RenderImage.cpp:
979 (WebCore::RenderImage::nodeAtPoint):
981 2009-03-22 Simon Fraser <simon.fraser@apple.com>
983 Reviewed by Dan Bernstein
985 https://bugs.webkit.org/show_bug.cgi?id=24743
987 Fix hit testing regression from r41840. We need to pass the temporary
988 HitTestResult when testing sublayers, then only copy to 'result' when
989 the layer is known to have been hit.
991 Test: fast/layers/zindex-hit-test.html
993 * rendering/RenderLayer.cpp:
994 (WebCore::RenderLayer::hitTestLayer):
996 2009-03-20 Simon Fraser <simon.fraser@apple.com>
998 Reviewed by Darin Adler
1000 https://bugs.webkit.org/show_bug.cgi?id=24733
1002 Fix hit testing on video controls after full page zoom by fixing wider issue
1003 with event->pageX(), pageY() with zooming. pageX and pageY are "fixed" to be
1004 invariant under zooming (for JavaScript), so we keep an actual page point around
1005 in MouseEvent::absoluteLocation() to avoid the need to factor in zooming everywhere.
1007 * dom/MouseRelatedEvent.cpp:
1008 (WebCore::MouseRelatedEvent::initCoordinates):
1009 (WebCore::MouseRelatedEvent::computePageLocation):
1010 * dom/MouseRelatedEvent.h:
1011 (WebCore::MouseRelatedEvent::absoluteLocation):
1012 (WebCore::MouseRelatedEvent::setAbsoluteLocation):
1013 Member var, and getter and setter for absoluteLocation.
1014 New method, computePageLocation(), to compute the actual page point,
1015 and call it when creating and initting mouse-related events.
1018 (WebCore::Node::dispatchMouseEvent):
1019 (WebCore::Node::dispatchWheelEvent):
1020 Keep non-adjusted pageX and pageY around, and call setAbsoluteLocation()
1021 on the event to replace a potentially rounded point.
1023 * html/HTMLInputElement.cpp:
1024 (WebCore::HTMLInputElement::defaultEventHandler):
1025 Clean up slider handling code.
1027 * html/HTMLSelectElement.cpp:
1028 (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
1029 Add FIXME comment for use of offsetX/offsetY.
1031 * page/ContextMenuController.cpp:
1032 (WebCore::ContextMenuController::handleContextMenuEvent):
1033 Use absoluteLocation() when hit testing for context menus.
1035 * rendering/RenderFrameSet.cpp:
1036 (WebCore::RenderFrameSet::userResize):
1037 Use absoluteLocation() when resizing frames.
1039 * rendering/RenderMedia.cpp:
1040 (WebCore::RenderMedia::forwardEvent):
1041 Use absoluteLocation() when hit testing media controls.
1043 * rendering/RenderSlider.cpp:
1044 (WebCore::HTMLSliderThumbElement::defaultEventHandler):
1045 (WebCore::RenderSlider::mouseEventIsInThumb):
1046 Use absoluteLocation() when handling slider events.
1048 (WebCore::RenderSlider::forwardEvent):
1049 Factor some code out of HTMLInputElement::defaultEventHandler().
1051 * rendering/RenderTextControlSingleLine.cpp:
1052 (WebCore::RenderTextControlSingleLine::forwardEvent):
1053 Use absoluteLocation() when hit testing search field buttons, which fixees
1054 bugs in the search field with zooming.
1056 2009-03-21 David Levin <levin@chromium.org>
1058 Reviewed by Dimitri Glazkov.
1060 https://bugs.webkit.org/show_bug.cgi?id=24727
1061 Add V8XMLHttpRequest*.
1063 * bindings/v8/V8XMLHttpRequestUtilities.cpp: Added.
1064 * bindings/v8/V8XMLHttpRequestUtilities.h: Added.
1065 * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp: Added.
1066 * bindings/v8/custom/V8XMLHttpRequestCustom.cpp: Added.
1067 * bindings/v8/custom/V8XMLHttpRequestUploadCustom.cpp: Added.
1069 2009-03-21 David Levin <levin@chromium.org>
1071 Reviewed by Dimitri Glazkov.
1073 https://bugs.webkit.org/show_bug.cgi?id=24725
1076 * bindings/v8/V8NodeFilter.cpp: Added.
1077 * bindings/v8/V8NodeFilter.h: Added.
1079 2009-03-21 Dan Bernstein <mitz@apple.com>
1081 Rubber-stamped by Kevin Decker
1083 - remove some redundant #include statements
1085 * bindings/js/JSDOMWindowBase.cpp:
1087 2009-03-20 Dan Bernstein <mitz@apple.com>
1089 Reviewed by Mark Rowe.
1091 - fix <rdar://problem/6574185> REGRESSION (3.2.2-TOT): hang in text drawing code
1093 * platform/graphics/win/FontCGWin.cpp:
1094 (WebCore::drawGDIGlyphs): Changed glyph stroking to fill and stroke each
1095 glyph as a separate path, instead of all glyphs as a single path. This
1096 matches what CGContextShowGlyphsWithAdvances() does, and has comparable
1099 2009-03-20 Dean Jackson <dino@apple.com>
1101 Reviewed by Simon Fraser
1103 Build fix for ENABLE(3D_RENDERING)
1105 * rendering/RenderObject.h:
1106 (WebCore::makeMatrixRenderable):
1108 2009-03-20 Dave Moore <davemoore@google.com>
1110 Reviewed by Dimitri Glazkov.
1112 https://bugs.webkit.org/show_bug.cgi?id=24705
1114 A bug in the V8 bindings is preventing chromium from setting the href on the
1115 location object...any attempt throws a security error, not just for javascript
1118 * page/Location.idl:
1120 2009-03-20 Craig Schlenter <craig.schlenter@gmail.com>
1122 Reviewed by Dimitri Glazkov.
1124 https://bugs.webkit.org/show_bug.cgi?id=24608
1126 Include stdio.h needed for printf on gcc 4.4.0
1128 * platform/KURLGoogle.cpp:
1130 2009-03-20 Mike Belshe <mike@belshe.com>
1132 Reviewed by Darin Fisher.
1134 https://bugs.webkit.org/show_bug.cgi?id=24577
1136 Don't let comments at the end of an event handler
1137 break the event handler.
1139 No change in behavior, so no test.
1141 * bindings/v8/V8LazyEventListener.cpp:
1142 (WebCore::V8LazyEventListener::getWrappedListenerFunction):
1144 2009-03-20 Norbert Leser <norbert.leser@nokia.com>
1146 Reviewed by Darin Adler.
1148 https://bugs.webkit.org/show_bug.cgi?id=24535
1150 Fixes missing line terminator character (;) after macro call.
1151 It is common practice to add the trailing ";" where macros are substituted
1152 and not where they are defined with #define.
1153 This change is consistent with other macro declarations across webkit,
1154 and it also solves compilation failure with symbian compilers.
1156 No change in behavior, so no test.
1158 * bindings/js/JSDOMWindowShell.cpp:
1159 * bindings/js/JSEventListener.cpp:
1160 * bindings/js/JSImageConstructor.cpp:
1161 * bindings/js/JSInspectedObjectWrapper.cpp:
1162 * bindings/js/JSInspectorCallbackWrapper.cpp:
1163 * bindings/js/JSNamedNodesCollection.cpp:
1164 * bindings/js/JSNodeFilterCondition.cpp:
1165 * bindings/js/JSOptionConstructor.cpp:
1166 * bindings/js/JSQuarantinedObjectWrapper.cpp:
1167 * bindings/js/JSRGBColor.cpp:
1168 * bindings/js/JSWorkerContextBase.cpp:
1169 * bindings/js/JSXMLHttpRequestConstructor.cpp:
1170 * bindings/js/JSXSLTProcessorConstructor.cpp:
1171 * bindings/scripts/CodeGeneratorJS.pm:
1173 2009-03-20 Mike Belshe <mike@belshe.com>
1175 Reviewed by Dimitri Glazkov and Dave Hyatt.
1177 https://bugs.webkit.org/show_bug.cgi?id=24324
1179 Make the minimum timer configurable for different platforms.
1181 * page/DOMTimer.cpp:
1182 (WebCore::DOMTimer::DOMTimer):
1183 (WebCore::DOMTimer::fired):
1185 (WebCore::DOMTimer::minTimerInterval):
1186 (WebCore::DOMTimer::setMinTimerInterval):
1188 2009-03-20 Dean McNamee <deanm@chromium.org>
1190 Reviewed by Darin Adler.
1192 https://bugs.webkit.org/show_bug.cgi?id=22834
1194 Make sure to consistently match new/delete and fastMalloc/fastFree.
1196 * css/CSSSelectorList.cpp:
1197 (WebCore::CSSSelectorList::adoptSelectorVector):
1198 (WebCore::CSSSelectorList::deleteSelectors):
1200 2009-03-20 Dan Bernstein <mitz@apple.com>
1202 Reviewed by Dave Hyatt.
1204 - fix https://bugs.webkit.org/show_bug.cgi?id=23739
1205 <rdar://problem/6556371> REGRESSION (r36513): iframe isn't sized properly upon load
1207 * rendering/RenderBlock.cpp:
1208 (WebCore::RenderBlock::percentHeightDescendants): Added this accessor.
1209 * rendering/RenderBlock.h:
1210 * rendering/RenderTableSection.cpp:
1211 (WebCore::RenderTableSection::layoutRows): Extended the check for
1212 children that flex to include other descendants with percent height
1213 which is relative to the cell.
1215 2009-03-20 Dmitry Titov <dimich@chromium.org>
1217 Reviewed by Alexey Proskuryakov.
1219 https://bugs.webkit.org/show_bug.cgi?id=24706
1220 Remove ScriptExecutionContext::encoding() since Workers do not need it.
1221 WorkerContext::encoding() is simply removed, while Document::encoding()
1222 made non-virtual and private. Workers use UTF-8 now except when instructed
1223 otherwise by http header. Also updated test.
1225 * dom/Document.h: Made encoding() non-virtual and private.
1226 * dom/ScriptExecutionContext.h: removed encoding().
1228 * workers/Worker.cpp:
1229 (WebCore::Worker::Worker):
1230 (WebCore::Worker::notifyFinished):
1231 * workers/WorkerContext.cpp: removed encoding() implementation.
1232 (WebCore::WorkerContext::WorkerContext):
1233 (WebCore::WorkerContext::completeURL):
1234 * workers/WorkerContext.h: removed encoding()
1235 (WebCore::WorkerContext::create):
1236 * workers/WorkerContextProxy.h:
1237 * workers/WorkerImportScriptsClient.cpp:
1238 (WebCore::WorkerImportScriptsClient::didReceiveData):
1239 * workers/WorkerMessagingProxy.cpp:
1240 (WebCore::WorkerMessagingProxy::startWorkerContext):
1241 * workers/WorkerMessagingProxy.h:
1242 * workers/WorkerThread.cpp:
1243 (WebCore::WorkerThreadStartupData::create):
1244 (WebCore::WorkerThreadStartupData::WorkerThreadStartupData):
1245 (WebCore::WorkerThread::create):
1246 (WebCore::WorkerThread::WorkerThread):
1247 (WebCore::WorkerThread::workerThread):
1248 * workers/WorkerThread.h:
1249 In all these, removed storing encoding and 'inheriting' it from the parent.
1250 Instead, they are all using UTF-8 now.
1252 2009-03-20 Timothy Hatcher <timothy@apple.com>
1254 Change how threading exceptions are checked so they are reported
1255 by what round they were added. That way WebKit can decided the
1256 behavior per-round based on linked-on-or-after checks.
1258 <rdar://problem/6626741&6648478&6635474&6674079>
1260 Reviewed by Darin Adler.
1262 * WebCore.base.exp: Export the new symbols.
1263 * bindings/objc/DOMAbstractView.mm: Use the new WebCoreThreadViolationCheckRoundOne macro.
1264 * bindings/scripts/CodeGeneratorObjC.pm: Ditto.
1265 * platform/ThreadCheck.h:
1266 * platform/mac/ThreadCheck.mm:
1267 (WebCore::readThreadViolationBehaviorFromUserDefaults): Refactor how the default is read.
1268 (WebCore::setDefaultThreadViolationBehavior): Take a round argument.
1269 (WebCore::reportThreadViolation): Ditto.
1270 (WebCoreReportThreadViolation): Ditto.
1272 2009-03-20 Geoffrey Garen <ggaren@apple.com>
1274 Reviewed by Sam Weinig.
1276 Fixed up an out-of-date comment.
1278 * bindings/js/JSDOMWindowCustom.h:
1279 (WebCore::JSDOMWindow::customPut):
1281 2009-03-20 Beth Dakin <bdakin@apple.com>
1283 Reviewed by Dave Hyatt.
1285 Fix for https://bugs.webkit.org/show_bug.cgi?id=20909 REGRESSION
1286 (r35318): A press release at pfizer.com does not display correctly
1287 - and corresponding -
1288 <rdar://problem/6680073>
1290 * rendering/RenderObject.cpp:
1291 (WebCore::RenderObject::invalidateContainerPrefWidths):
1292 * rendering/RenderObject.h:
1293 (WebCore::RenderObject::markContainingBlocksForLayout):
1295 2009-03-20 Eric Seidel <eric@webkit.org>
1297 Reviewed by Justin Garcia.
1299 maxDeepOffset is confusing and should be removed
1300 https://bugs.webkit.org/show_bug.cgi?id=24586
1302 Abstract some hard-to-read (but shared) logic into a new renderedAsNonInlineTableOrHR function.
1303 Add first/lastDeepEditingPositionForNode Position creation functions
1304 and deploy them to places we used to call maxDeepOffset.
1306 Rename Position::atStart and atEnd to atStartOfTree atEndOfTree
1307 Add a new Position::atFirst/atLastEditingPositionForNode() and use these
1308 to replace a few more callers for maxDeepOffset()
1310 Rename maxDeepOffset to lastEditingOffsetForNode (so that we mere mortals have some clue what it does)
1312 "Editing positions" are confusing because they have one
1313 of two behaviors, depending on if the container node is ignored
1314 by editing (if editingIgnoresContent(node) returns true) or not.
1315 Positions referring to nodes ignored by editing are
1316 neighbor-relative (they are before or after the node) where as
1317 positions reffering to other nodes are container-relative
1318 (they are between two child nodes of the container, identified
1319 by the offset() member). I will be fixing this confusion in
1320 future patches. These renames hopefully make the current behavior clearer.
1323 (WebCore::Position::previous):
1324 (WebCore::Position::next):
1325 (WebCore::Position::atFirstEditingPositionForNode):
1326 (WebCore::Position::atLastEditingPositionForNode):
1327 (WebCore::Position::atStartOfTree):
1328 (WebCore::Position::atEndOfTree):
1329 (WebCore::Position::previousCharacterPosition):
1330 (WebCore::Position::nextCharacterPosition):
1331 (WebCore::Position::upstream):
1332 (WebCore::Position::isCandidate):
1333 (WebCore::firstDeepEditingPositionForNode):
1334 (WebCore::lastDeepEditingPositionForNode):
1336 * dom/PositionIterator.cpp:
1337 (WebCore::PositionIterator::operator Position):
1338 (WebCore::PositionIterator::increment):
1339 (WebCore::PositionIterator::decrement):
1340 (WebCore::PositionIterator::atEnd):
1341 (WebCore::PositionIterator::atEndOfNode):
1342 * editing/CompositeEditCommand.cpp:
1343 (WebCore::CompositeEditCommand::positionAvoidingSpecialElementBoundary):
1344 * editing/DeleteSelectionCommand.cpp:
1345 (WebCore::isTableCellEmpty):
1346 (WebCore::DeleteSelectionCommand::removeNode):
1347 (WebCore::DeleteSelectionCommand::handleGeneralDelete):
1348 * editing/Editor.cpp:
1349 (WebCore::Editor::advanceToNextMisspelling):
1350 * editing/InsertLineBreakCommand.cpp:
1351 (WebCore::InsertLineBreakCommand::doApply):
1352 * editing/InsertListCommand.cpp:
1353 (WebCore::InsertListCommand::doApply):
1354 * editing/ReplaceSelectionCommand.cpp:
1355 (WebCore::ReplaceSelectionCommand::positionAtEndOfInsertedContent):
1356 * editing/TypingCommand.cpp:
1357 (WebCore::TypingCommand::forwardDeleteKeyPressed):
1358 * editing/VisiblePosition.cpp:
1359 (WebCore::VisiblePosition::previous):
1360 (WebCore::VisiblePosition::leftVisuallyDistinctCandidate):
1361 (WebCore::VisiblePosition::left):
1362 (WebCore::VisiblePosition::rightVisuallyDistinctCandidate):
1363 (WebCore::VisiblePosition::right):
1364 * editing/VisibleSelection.cpp:
1365 (WebCore::VisibleSelection::selectionFromContentsOfNode):
1366 (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingEditingBoundaries):
1367 * editing/htmlediting.cpp:
1368 (WebCore::nextVisuallyDistinctCandidate):
1369 (WebCore::previousVisuallyDistinctCandidate):
1370 (WebCore::firstEditablePositionAfterPositionInRoot):
1371 (WebCore::lastEditablePositionBeforePositionInRoot):
1372 (WebCore::lastOffsetForEditing):
1373 (WebCore::isFirstPositionAfterTable):
1374 (WebCore::isLastPositionBeforeTable):
1375 (WebCore::positionBeforeNode):
1376 (WebCore::positionAfterNode):
1377 (WebCore::enclosingEmptyListItem):
1378 (WebCore::caretMaxOffset):
1379 * editing/htmlediting.h:
1380 * editing/visible_units.cpp:
1381 (WebCore::renderedAsNonInlineTableOrHR):
1382 (WebCore::startOfParagraph):
1383 (WebCore::endOfParagraph):
1384 (WebCore::startOfEditableContent):
1385 (WebCore::endOfEditableContent):
1386 * page/AccessibilityObject.cpp:
1387 (WebCore::endOfStyleRange):
1388 * page/AccessibilityRenderObject.cpp:
1389 (WebCore::AccessibilityRenderObject::visiblePositionRange):
1390 * rendering/RenderBox.cpp:
1391 (WebCore::RenderBox::positionForPoint):
1393 2009-03-20 Dmitry Titov <dimich@chromium.org>
1395 Reviewed by Dimitri Glazkov.
1397 https://bugs.webkit.org/show_bug.cgi?id=24689
1398 Add (upstream) V8 bindings for Workers. Mostly style cleaning.
1400 * bindings/v8/WorkerContextExecutionProxy.cpp: Added.
1401 * bindings/v8/WorkerContextExecutionProxy.h: Added.
1402 * bindings/v8/WorkerScriptController.cpp: Added.
1403 * bindings/v8/WorkerScriptController.h: Added.
1404 * bindings/v8/V8Index.h: Added. This is just a wrapper for v8_index.h, like V8Proxy.h
1405 * bindings/v8/V8Proxy.h: Added domObjectMap() function that wraps GetDOMObjectMap().
1406 * bindings/v8/V8WorkerContextEventListener.cpp:
1407 (WebCore::V8WorkerContextEventListener::callListenerFunction): TrackEvent() renamed trackEvent()
1409 2009-03-20 Stephen White <senorblanco@chromium.org>
1411 Reviewed by Eric Seidel.
1413 Fix for LayoutTests/fast/canvas/canvas-text-alignment.html
1414 on chromium/skia. The problem was that the gradient matrix
1415 for text was being applied twice. Fixed by reverting some of
1416 https://bugs.webkit.org/show_bug.cgi?id=23957, so that skiaDrawText
1417 is no longer responsible for measuring the text and scaling up
1418 the gradient matrix. Instead, the text bounding box is passed
1419 in from SVGPaintServerGradient. I didn't make this change for CG,
1420 since it uses a different method (the gradient is drawn using the
1421 text as a pre-rendered mask).
1422 https://bugs.webkit.org/show_bug.cgi?id=24687
1424 * platform/graphics/skia/SkiaFontWin.cpp:
1425 (WebCore::skiaDrawText):
1426 * svg/graphics/SVGPaintServerGradient.cpp:
1427 (WebCore::SVGPaintServerGradient::setup):
1429 2009-03-20 Xan Lopez <xlopez@igalia.com>
1431 Rubber-stamped by Holger Freyther.
1433 There seems to be some rounding error in cairo (or in how we use
1434 cairo) with some fonts, like DejaVu Sans Mono, which makes cairo
1435 report a height smaller than ascent + descent, which is wrong and
1436 confuses WebCore's layout system. Workaround this while we figure
1437 out what's going on.
1439 * platform/graphics/gtk/SimpleFontDataGtk.cpp:
1440 (WebCore::SimpleFontData::platformInit):
1441 * platform/graphics/gtk/SimpleFontDataPango.cpp:
1442 (WebCore::SimpleFontData::platformInit):
1444 2009-03-19 Alexey Proskuryakov <ap@webkit.org>
1446 Reviewed by Darin Adler.
1448 https://bugs.webkit.org/show_bug.cgi?id=24122
1449 <rdar://problem/6674179>
1450 REGRESSION: DOM Range extractContents/deleteContents failures seen on Moxiecode tests
1452 Test: fast/dom/Range/deleted-range-endpoints.html
1454 * dom/Range.cpp: (WebCore::Range::processContents): Set the final range in accordance
1455 to the specification.
1457 2009-03-19 Anders Carlsson <andersca@apple.com>
1459 Reviewed by Dan Bernstein.
1461 <rdar://problem/6682554> Flash content not being rendered (Shockwave Flash 10.0 r22)
1463 If calling updateWidget for some reason resulted in another widget being added to m_widgetUpdateSet, then
1464 that object would never be updated.
1466 * page/FrameView.cpp:
1467 (WebCore::FrameView::updateWidgets):
1468 Factor the widget updating code out into this method. Return true if the update set is empty.
1470 (WebCore::FrameView::performPostLayoutTasks):
1471 Loop over the update set multiple times until all widgets have been updated or until we reach the cap.
1475 2009-03-18 Timothy Hatcher <timothy@apple.com>
1477 Make the defered data loading timer honor the Page's scheduled runloop pairs.
1478 Introduces a new RunLoopTimer class that has an API mimicking Timer but
1479 allows it to be scheduled with one or more SchedulePairs.
1481 <rdar://problem/6687342> -[WebView scheduleInRunLoop:forMode:] has no affect on timers
1483 Reviewed by Darin Adler.
1485 * WebCore.xcodeproj/project.pbxproj: Adds the new RunLoopTimer.{cpp,h} files.
1486 * loader/MainResourceLoader.cpp:
1487 (WebCore::MainResourceLoader::handleDataLoadNow): Use the MainResourceLoaderTimer typedef.
1488 (WebCore::MainResourceLoader::startDataLoadTimer): Added. Start the timer and on
1489 Mac platforms also schedule with the Page's SchedulePairs.
1490 (WebCore::MainResourceLoader::handleDataLoadSoon): Call startDataLoadTimer().
1491 (WebCore::MainResourceLoader::setDefersLoading): Ditto.
1492 * loader/MainResourceLoader.h:
1493 * platform/cf/RunLoopTimerCF.cpp: Added.
1494 (WebCore::RunLoopTimerBase::~RunLoopTimerBase):
1495 (WebCore::timerFired):
1496 (WebCore::RunLoopTimerBase::start):
1497 (WebCore::RunLoopTimerBase::schedule):
1498 (WebCore::RunLoopTimerBase::stop):
1499 (WebCore::RunLoopTimerBase::isActive):
1500 * platform/RunLoopTimer.h: Added.
1501 (WebCore::RunLoopTimerBase::RunLoopTimerBase):
1502 (WebCore::RunLoopTimerBase::startRepeating):
1503 (WebCore::RunLoopTimerBase::startOneShot):
1504 (WebCore::RunLoopTimer::RunLoopTimer):
1505 (WebCore::RunLoopTimer::fired):
1507 2009-03-19 Dimitri Glazkov <dglazkov@chromium.org>
1509 Reviewed by Darin Fisher.
1511 https://bugs.webkit.org/show_bug.cgi?id=24702
1512 Upstream miscellaneous bindings changes.
1514 * bindings/v8/ScheduledAction.cpp:
1515 (WebCore::ScheduledAction::execute): Changed to call lower-case evaluate.
1516 * bindings/v8/ScriptCallStack.h: Added an extra include.
1518 2009-03-19 Simon Fraser <simon.fraser@apple.com>
1520 Reviewed by Dave Hyatt
1522 https://bugs.webkit.org/show_bug.cgi?id=24686
1524 When hit testing a RenderLayer whose parent lives in a preserves-3D hierarchy,
1525 we need to compare the computed z-offset with the depth-test z-offset before
1526 deciding that such a RenderLayer was hit. This fixes an issue, tested by the
1527 3d-point-mapping-overlapping.html test, where the child of a transformed element
1528 is found by hit testing, even when some other element with greater Z overlaps
1531 Improved the code by adding a utility method, isHitCandidate(), which computes and tests
1532 z-depth when necessary.
1534 Tests: transforms/3d/point-mapping/3d-point-mapping-coplanar.html
1535 transforms/3d/point-mapping/3d-point-mapping-overlapping.html
1537 * rendering/RenderLayer.cpp:
1538 (WebCore::isHitCandidate):
1539 (WebCore::RenderLayer::hitTestLayer):
1541 2009-03-19 Jeremy Moskovich <jeremy@chromium.org>
1543 Reviewed by Dimitri Glazkov.
1545 https://bugs.webkit.org/show_bug.cgi?id=24456
1546 Split ColorChromium.cpp into Mac & Windows variants.
1547 Remove Chromium Dependency on platform/graphics/mac/ColorMac.mm since we
1548 ultimately need to take a different approach. For now, createCGColor()
1549 is copied from ColorMac.mm.
1551 No observable change in behavior, so no test.
1553 * platform/graphics/chromium/ColorChromium.cpp:
1554 (WebCore::focusRingColor):
1555 * platform/graphics/chromium/ColorChromiumMac.mm: Added.
1557 2009-03-19 Pavel Feldman <pfeldman@chromium.org>
1559 Reviewed by Dimitri Glazkov.
1561 https://bugs.webkit.org/show_bug.cgi?id=24675
1562 Unforking frontend: add custom InspectorController methods
1565 * bindings/v8/custom/V8InspectorControllerCustom.cpp: Added.
1567 2009-03-19 Jay Campan <jcampan@google.com>
1569 Reviewed by Dimitri Glazkov.
1571 https://bugs.webkit.org/show_bug.cgi?id=24625
1572 Adding an accessor to the currently selected index in the PopupMenuChromium.
1573 This is required for implementing the deletion of an autocomplete entry in Chromium.
1575 * platform/chromium/PopupMenuChromium.cpp:
1576 (WebCore::PopupContainer::selectedIndex):
1577 * platform/chromium/PopupMenuChromium.h:
1579 2009-03-19 Evan Stade <estade@chromium.org>
1581 Reviewed by Dimitri Glazkov.
1583 https://bugs.webkit.org/show_bug.cgi?id=24526
1584 Improve windows skia text stroking.
1586 Test: LayoutTests/svg/custom/struct-use-09-b.svg
1588 * platform/graphics/skia/SkiaFontWin.cpp: Close the path representing
1589 each font glyph polygon, rather than only closing the path once per
1590 letter. This fixes stroking for letters with multiple polygons, such
1592 (WebCore::getPathForGlyph):
1593 (WebCore::skiaDrawText):
1595 2009-03-19 Simon Hausmann <simon.hausmann@nokia.com>
1597 Reviewed by Tor Arne Vestbø.
1599 Fixed support for doing calls from JavaScript into NPAPI Plugins for the Qt port on Windows.
1601 Removed dead code for distinguishing between Widget and PluginView in the Qt port.
1603 * bindings/js/ScriptControllerQt.cpp:
1604 (WebCore::ScriptController::createScriptInstanceForWidget): Removed incorrect isNPAPI check.
1605 * plugins/PluginView.cpp:
1606 (WebCore::PluginView::PluginView): Removed m_isNPAPIPlugin variable.
1607 * plugins/PluginView.h: Removed setter/getter.
1608 * plugins/mac/PluginViewMac.cpp:
1609 (WebCore::PluginView::init): Removed call to setIsNPAPIPlugin.
1610 * plugins/qt/PluginViewQt.cpp:
1611 (WebCore::PluginView::init): Ditto.
1613 2009-03-19 Cameron Zwarich <cwzwarich@uwaterloo.ca>
1615 Reviewed by Oliver Hunt.
1617 Bug 24596: ASSERT in JSC::PropertySlot::slotBase @ iGoogle homepage
1618 <https://bugs.webkit.org/show_bug.cgi?id=24596>
1619 <rdar://problem/6686493>
1621 JSDOMWindow::customGetOwnPropertySlot() does an access check after calling
1622 JSGlobalObject::getOwnPropertySlot(). This causes the PropertySlot to be
1623 set twice, once to the value that is illegal to access, and then to undefined
1624 This causes an assertion failure in property access caching code.
1626 The fix is to do the access check before calling JSGlobalObject::getOwnPropertySlot().
1628 * bindings/js/JSDOMWindowCustom.h:
1629 (WebCore::JSDOMWindow::customGetOwnPropertySlot):
1631 2009-03-18 Alexey Proskuryakov <ap@webkit.org>
1633 Reviewed by Sam Weinig.
1635 https://bugs.webkit.org/show_bug.cgi?id=24676
1636 Simple cross-origin requests shouldn't dispatch upload progress events
1638 Test: http/tests/xmlhttprequest/simple-cross-origin-progress-events.html
1640 * loader/CrossOriginAccessControl.cpp: (WebCore::passesAccessControlCheck): Added a comment
1641 explaining the somewhat unexpected behavior of this function.
1643 * xml/XMLHttpRequestUpload.cpp: (WebCore::XMLHttpRequestUpload::hasListeners):
1644 * xml/XMLHttpRequestUpload.h:
1645 Report whether there are any event listeners registered.
1647 * xml/XMLHttpRequest.h: Added m_uploadEventsAllowed.
1649 * xml/XMLHttpRequest.cpp:
1650 (WebCore::XMLHttpRequest::createRequest): Set m_uploadEventsAllowed flag.
1651 (WebCore::XMLHttpRequest::makeSameOriginRequest): Ditto.
1652 (WebCore::XMLHttpRequest::makeCrossOriginAccessRequest): Ditto.
1653 (WebCore::XMLHttpRequest::makeSimpleCrossOriginAccessRequest): Set request body - it can be
1654 non-empty for POST requests.
1655 (WebCore::XMLHttpRequest::makeCrossOriginAccessRequestWithPreflight): Set m_uploadEventsAllowed flag.
1656 (WebCore::XMLHttpRequest::handleAsynchronousPreflightResult): Ditto.
1657 (WebCore::XMLHttpRequest::abort): Only dispatch upload progress events if allowed.
1658 (WebCore::XMLHttpRequest::networkError): Ditto.
1659 (WebCore::XMLHttpRequest::abortError): Ditto.
1660 (WebCore::XMLHttpRequest::didSendData): Ditto.
1662 2009-03-18 Marc-Antoine Ruel <maruel@chromium.org>
1664 Reviewed by Darin Fisher.
1666 https://bugs.webkit.org/show_bug.cgi?id=24398
1667 Fix a crash when loading a svg file in Chromium's test_shell and
1668 then reloading the page.
1670 * history/BackForwardListChromium.cpp:
1671 (WebCore::BackForwardList::BackForwardList):
1672 (WebCore::BackForwardList::close):
1674 2009-03-18 Eric Carlson <eric.carlson@apple.com>
1676 Reviewed by Simon Fraser.
1678 Fix for <rdar://problem/6685235>
1679 <video> element poster cannot be set dynamically if not originally set up in HTML
1681 Allocate the media engine immediately so the plug-in proxy is available for
1682 scripting right away.
1684 * platform/graphics/MediaPlayer.cpp:
1685 (WebCore::MediaPlayer::MediaPlayer):
1687 2009-03-18 Beth Dakin <bdakin@apple.com>
1689 Reviewed by Dave Hyatt.
1691 Fix for <rdar://problem/6636747> REGRESSION (Safari 4 PB-r41326):
1692 Popup menu appears at the wrong location on page at http://
1693 www.signonsandiego.com/
1695 This was a regression from http://trac.webkit.org/changeset/40769,
1696 which changed the base class of RenderInline to
1697 RenderBoxModelObject rather than RenderBox.
1699 * rendering/RenderObject.cpp:
1700 (WebCore::RenderObject::offsetParent): offsetParent should return a
1701 RenderBoxModelObject rather than just a RenderBox, which is more
1704 2009-03-18 Anders Carlsson <andersca@apple.com>
1706 Reviewed by Darin Adler.
1708 <rdar://problem/6504776>
1709 CrashTracer: [USER] 188 crashes in Safari at com.apple.WebCore • WTF::HashTableIterator<WTF::RefPtr<WebCore::ResourceLoader>, ...
1711 Return early in case calling the client ends up spinning the run loop and completing/cancelling the load.
1713 * loader/NetscapePlugInStreamLoader.cpp:
1714 (WebCore::NetscapePlugInStreamLoader::didCancel):
1716 2009-03-18 David Levin <levin@chromium.org>
1718 Reviewed by Dimitri Glazkov.
1720 https://bugs.webkit.org/show_bug.cgi?id=24664
1721 Upstreaming v8 collection.h
1723 No change in behavior, so no test.
1725 * bindings/v8/V8Collection.h: Added.
1727 2009-03-18 Sam Weinig <sam@webkit.org>
1729 Reviewed by Simon Fraser.
1731 Fix for https://bugs.webkit.org/show_bug.cgi?id=23966
1732 REGRESSION: Custom arrow navigation functionality doesn't work at dropular.net
1733 <rdar://problem/6589657>
1735 Match the CSSOM spec for getClientRects and getBoundingClientRect by
1736 returning a 0x0 rect at the correct top/left position for empty inline
1739 * rendering/RenderInline.cpp:
1740 (WebCore::RenderInline::absoluteRects):
1741 (WebCore::RenderInline::absoluteQuads):
1743 2009-03-18 David Levin <levin@chromium.org>
1745 Reviewed by Eric Seidel.
1747 Match the changes done for windows in the bug
1748 https://bugs.webkit.org/show_bug.cgi?id=24530.
1750 No change in behavior, so no test.
1752 * rendering/RenderThemeChromiumLinux.cpp:
1753 (WebCore::RenderThemeChromiumLinux::extraDefaultStyleSheet):
1755 2009-03-18 Dirk Schulze <krit@webkit.org>
1757 Reviewed by Holger Freyther.
1759 Added support for SVG's stroked texts to Qt.
1761 [Qt] SVGs stroked text support missing
1762 https://bugs.webkit.org/show_bug.cgi?id=24262
1764 * platform/graphics/qt/FontQt.cpp:
1765 (WebCore::Font::drawComplexText):
1767 2009-03-18 Mark Rowe <mrowe@apple.com>
1769 Reviewed by Alexey Proskuryakov.
1771 Fix fast/encoding/char-decoding.html with recent ICU.
1773 * platform/text/TextCodecICU.cpp:
1774 (WebCore::TextCodecICU::decode): Look for gb18030 case-insensitively,
1775 as newer versions of ICU use GB18030 as the canonical name.
1777 2009-03-17 David Levin <levin@chromium.org>
1779 Reviewed by Dimitri Glazkov.
1781 https://bugs.webkit.org/show_bug.cgi?id=24662
1782 Chromium build fixes.
1784 Bug https://bugs.webkit.org/show_bug.cgi?id=24663 tracks
1785 the invalid implementation of ScriptCallStack.
1787 No change in behavior, so no test.
1789 * bindings/v8/ScriptCallStack.h:
1790 (WebCore::ScriptCallStack::state):
1791 * platform/graphics/skia/PlatformContextSkia.cpp:
1792 (PlatformContextSkia::drawRect):
1794 2009-03-17 David Carson <dacarson@apple.com>
1796 Reviewed by David Hyatt.
1798 Add anchor elements to the simple style sheet so that applications that
1799 are using WebKit just for simple text and links will also take advantage
1802 * css/CSSStyleSelector.cpp:
1803 (WebCore::elementCanUseSimpleDefaultStyle):
1805 2009-03-17 Darin Adler <darin@apple.com>
1807 Reviewed by Adele Peterson.
1809 <rdar://problem/6687005> Need support for new move-left/right selectors.
1811 * editing/EditorCommand.cpp:
1812 (WebCore::executeMoveToLeftEndOfLine): Added.
1813 (WebCore::executeMoveToLeftEndOfLineAndModifySelection): Added.
1814 (WebCore::executeMoveToRightEndOfLine): Added.
1815 (WebCore::executeMoveToRightEndOfLineAndModifySelection): Added.
1816 Added command entries for the functions above.
1818 2009-03-17 Ojan Vafai <ojan@chromium.org>
1820 Reviewed by Adele Peterson.
1822 Put the padding inside scrollbars on textareas.
1823 https://bugs.webkit.org/show_bug.cgi?id=24370
1825 Put the padding inside the scrollbars on textareas. This is done by moving the
1826 overflow from the shadowNode to the RenderTextControlMultiline. As a result,
1827 all of the scroll handing methods that RenderTextControl overrides can be moved
1828 down into RenderTextControlSingleLine since RenderTextControlMultiline can now
1829 just use RenderBlock's versions. This also allows RenderTextControlMultiLine to
1830 no longer need a custom layout method since the shadowNode can now just size
1833 * css/CSSStyleSelector.cpp:
1834 (WebCore::CSSStyleSelector::adjustRenderStyle):
1835 * rendering/RenderTextControl.cpp:
1836 (WebCore::RenderTextControl::styleDidChange):
1837 (WebCore::RenderTextControl::selection):
1838 (WebCore::RenderTextControl::calcHeight):
1839 (WebCore::RenderTextControl::hitInnerTextElement):
1840 * rendering/RenderTextControl.h:
1841 * rendering/RenderTextControlMultiLine.cpp:
1842 (WebCore::RenderTextControlMultiLine::nodeAtPoint):
1843 (WebCore::RenderTextControlMultiLine::createInnerTextStyle):
1844 * rendering/RenderTextControlMultiLine.h:
1845 * rendering/RenderTextControlSingleLine.cpp:
1846 (WebCore::RenderTextControlSingleLine::styleDidChange):
1847 (WebCore::RenderTextControlSingleLine::autoscroll):
1848 (WebCore::RenderTextControlSingleLine::scrollWidth):
1849 (WebCore::RenderTextControlSingleLine::scrollHeight):
1850 (WebCore::RenderTextControlSingleLine::scrollLeft):
1851 (WebCore::RenderTextControlSingleLine::scrollTop):
1852 (WebCore::RenderTextControlSingleLine::setScrollLeft):
1853 (WebCore::RenderTextControlSingleLine::setScrollTop):
1854 (WebCore::RenderTextControlSingleLine::scroll):
1855 * rendering/RenderTextControlSingleLine.h:
1856 * rendering/TextControlInnerElements.cpp:
1857 (WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock):
1858 (WebCore::RenderTextControlInnerBlock::positionForPoint):
1859 (WebCore::TextControlInnerTextElement::createRenderer):
1861 2009-03-17 Darin Adler <darin@apple.com>
1863 Reviewed by David Hyatt.
1865 Bug 24517: REGRESSION (r41552): innerHTML does an updateLayout -- unneeded and can be slow
1866 https://bugs.webkit.org/show_bug.cgi?id=24517
1868 * editing/DeleteButtonController.cpp:
1869 (WebCore::DeleteButtonController::enable): Added a call to updateRendering, since
1870 determining whether to display the delete button involves style and updateRendering
1871 also updates style (should probably be named updateStyle, in fact). Not needed to fix
1872 this bug, but would have prevented the crash that led to this bug in the first place.
1874 * editing/EditCommand.cpp:
1875 (WebCore::EditCommand::EditCommand): Get rid of unneeded null check. All frames have
1876 delete button controllers.
1877 * editing/Editor.cpp:
1878 (WebCore::Editor::rangeForPoint): Ditto.
1880 * editing/markup.cpp:
1881 (WebCore::appendStartMarkup): Changed a "&" to a "&&" so that generating markup
1882 doesn't depend on renderers at all when the convertBlocksToInlines boolean is false.
1883 This allows us to omit the call to updateLayoutIgnorePendingStylesheets in the
1884 createMarkup function that's called by innerHTML.
1885 (WebCore::MarkupAccumulator::appendMarkup): Turned this into a class with a member
1886 function. Added a feature where the accumulator will skip a node. Moved arguments
1887 that don't change during recursion into an object. This function still is a bit
1888 inefficient, since it creates a new HashMap at every level as it recurses, but for now
1889 I did not tackle that. Also replaced the onlyIncludeChildren boolean with EChildrenOnly
1890 for consistency and clarity.
1891 (WebCore::createMarkup): Removed the call to updateLayoutIgnorePendingStylesheets.
1892 Instead of calling disable/enable on the delete button controller's container element,
1893 pass it in to the markup accumulator as a node to skip.
1895 2009-03-17 Scott Violet <sky@google.com>
1897 Reviewed by Eric Seidel.
1899 https://bugs.webkit.org/show_bug.cgi?id=24651
1900 Skia does not always render text fill/stroke pattern/gradient/color correctly
1902 Changes Skia's font rendering to only render gradient/pattern if current
1903 color space indicates the gradient/pattern should be used.
1904 This is covered by LayoutTests/fast/canvas/canvas-text-alignment.html .
1906 * platform/graphics/GraphicsContext.cpp:
1907 (WebCore::GraphicsContext::strokeColorSpace):
1908 (WebCore::GraphicsContext::fillColorSpace):
1909 * platform/graphics/GraphicsContext.h:
1911 * platform/graphics/GraphicsContextPrivate.h:
1912 * platform/graphics/skia/SkiaFontWin.cpp:
1913 (WebCore::paintSkiaText):
1915 2009-03-17 Adele Peterson <adele@apple.com>
1917 Reviewed by Darin Adler.
1919 Fix for https://bugs.webkit.org/show_bug.cgi?id=24655
1920 <rdar://problem/6633727> Hitting return at the end of a line with an anchor jumps me to the bottom of the message
1922 Test: editing/inserting/6633727.html
1924 This changes does a few things:
1925 1) Renames pos to insertionPosition.
1926 2) Eliminates "startNode". It doesn't work well to consider the node separately from the insertionPosition.
1927 The insertionPosition gets updated at various times, and it seems likely that startNode can get out of sync.
1928 3) Before building up a list of ancestors to move around when we insert the new block, make sure to use the deepest
1929 representation of the insertionPosition, so all ancestor nodes are correctly included.
1931 * editing/InsertParagraphSeparatorCommand.cpp: (WebCore::InsertParagraphSeparatorCommand::doApply):
1933 2009-03-17 Laszlo Gombos <laszlo.1.gombos@nokia.com>
1935 Reviewed by Kevin Ollivier.
1937 https://bugs.webkit.org/show_bug.cgi?id=24115
1938 Introduce platform independent stubs for plugins.
1940 * plugins/PluginDataNone.cpp: Copied from WebCore/plugins/wx/PluginDataWx.cpp.
1941 * plugins/PluginPackageNone.cpp: Copied from WebCore/plugins/wx/PluginPackageWx.cpp.
1942 * plugins/PluginViewNone.cpp: Copied from WebCore/plugins/wx/PluginViewWx.cpp.
1943 * plugins/wx/PluginDataWx.cpp: Removed.
1944 * plugins/wx/PluginPackageWx.cpp: Removed.
1945 * plugins/wx/PluginViewWx.cpp: Removed.
1948 2009-03-17 Darin Adler <darin@apple.com>
1950 Earlier version reviewed by Adele Peterson.
1952 Bug 24304: REGRESSION (r39864): Hitting the space bar to select an <input type=radio>
1953 or push an <input type=button> or <button> causes the page to scroll down.
1955 Would be best to add a regression test for Windows eventually; tested that this has
1956 no effect on the Mac OS X platform.
1958 * html/HTMLInputElement.cpp:
1959 (WebCore::HTMLInputElement::defaultEventHandler): Added FIXMEs and tweaked formatting.
1960 Use the code that calls the base class's defaultEventHandler early only in the cases
1961 where it's needed: keydown and keypress events in text fields. In other cases, do the
1962 more typical thing and call the default handler only at the end of the function.
1963 This function already had code to make sure the keypress event for space never gets
1964 through, but it was running too late since the scrolling code was moved into the
1965 base class default event handler.
1967 2009-03-17 Simon Fraser <simon.fraser@apple.com>
1969 Reviewed by Dave Hyatt
1971 https://bugs.webkit.org/show_bug.cgi?id=24632
1973 Fix repaint issues when composited layers come and go (only applies
1974 when ACCELERATED_COMPOSITING is turned on).
1976 * rendering/RenderLayer.cpp:
1977 (WebCore::RenderLayer::RenderLayer):
1978 * rendering/RenderLayer.h:
1979 (WebCore::RenderLayer::mustOverlayCompositedLayers):
1980 (WebCore::RenderLayer::setMustOverlayCompositedLayers):
1981 * rendering/RenderLayerBacking.cpp:
1982 (WebCore::RenderLayerBacking::RenderLayerBacking):
1983 * rendering/RenderLayerBacking.h:
1985 Move what used to be the 'forceCompositingLayer' flag from RenderLayerBacking
1986 to RenderLayer, because we don't want the side-effects of creating RenderLayerBacking
1987 when setting this flag.
1989 * rendering/RenderLayerCompositor.cpp:
1990 (WebCore::RenderLayerCompositor::updateLayerCompositingState):
1991 When a RenderLayer flips into or out of compositing mode, compute a repaint
1992 rect relative to the containerForRepaint, and repaint it.
1994 (WebCore::RenderLayerCompositor::computeCompositingRequirements):
1995 Call layer->setMustOverlayCompositedLayers() rather than setForcedCompositingLayer().
1997 (WebCore::RenderLayerCompositor::needsToBeComposited):
1998 (WebCore::RenderLayerCompositor::requiresCompositingLayer):
1999 (WebCore::RenderLayerCompositor::requiresCompositingForTransform):
2000 (WebCore::RenderLayerCompositor::requiresCompositingForAnimation):
2001 * rendering/RenderLayerCompositor.h:
2003 Rename requiresCompositingLayerForTransform() to requiresCompositingForTransform()
2004 and make it a class static method to match requiresCompositingForAnimation(). Both
2005 now take RenderObjects, rathern than RenderLayers.
2007 * rendering/style/RenderStyle.h:
2008 (WebCore::InheritedFlags::hasTransformRelatedProperty):
2009 Minor tidyup using convenience methods added in an earlier commit.
2011 2009-03-17 Simon Fraser <simon.fraser@apple.com>
2013 Reviewed by Darin Adler
2015 https://bugs.webkit.org/show_bug.cgi?id=24396
2018 Add WTF_USE_ACCELERATED_COMPOSITING, defined to 0 for now, and add some
2019 comments to make the #ifdefs more readable.
2021 * css/CSSComputedStyleDeclaration.cpp:
2022 (WebCore::computedTransform):
2023 Add a comment to mention that we don't flatten the matrix.
2025 * css/MediaQueryEvaluator.cpp:
2026 (WebCore::transform_3dMediaFeatureEval):
2027 Have the 'transform-3d' media query evaluate to 'true' if 3d-rendering
2030 * platform/graphics/mac/GraphicsLayerCA.mm:
2031 (WebCore::GraphicsLayerCA::animateTransform):
2032 No need for the #ifdef here. If we don't support 3d, we will have already flattened
2035 * platform/graphics/transforms/TransformationMatrix.cpp:
2036 (WebCore::TransformationMatrix::makeAffine):
2037 * platform/graphics/transforms/TransformationMatrix.h:
2038 New method to convert the matrix to an affine matrix by throwing a way the non-affine
2041 * rendering/RenderLayer.cpp:
2042 (WebCore::RenderLayer::updateTransform):
2043 (WebCore::RenderLayer::currentTransform):
2044 * rendering/RenderLayerBacking.cpp:
2045 (WebCore::RenderLayerBacking::updateLayerTransform):
2046 If 3d rendering is not supported, convert the matrix to an affine matrix
2047 which can be rendered, and used for hit testing.
2049 * rendering/RenderLayerCompositor.cpp:
2050 Change the name of the exported symbol that webkitdirs.pm uses to know if
2051 3d rendering is supported. There is no other 3d-rendering-specific symbol we can sniff.
2053 * rendering/RenderObject.cpp:
2054 (WebCore::RenderObject::transformFromContainer):
2055 Only take perspective into account if 3d rendering is supported.
2057 * rendering/RenderObject.h:
2058 (WebCore::makeMatrixRenderable):
2059 Utility method that flattens a matrix if 3d rendering is not supported.
2061 2009-03-17 Kevin Ollivier <kevino@theolliviers.com>
2063 wx build fix. Fix typo after mouse wheel changes.
2065 * platform/wx/MouseWheelEventWx.cpp:
2066 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2068 2009-03-17 Darin Adler <darin@apple.com>
2070 * inspector/ConsoleMessage.cpp:
2071 (WebCore::ConsoleMessage::isEqual): Fix build, remove stray parenthesis.
2073 2009-03-17 Darin Adler <darin@apple.com>
2075 Fix crash seen right away when running run-webkit-tests.
2077 * inspector/ConsoleMessage.cpp:
2078 (WebCore::ConsoleMessage::isEqual): Restore assertion to its behavior pre-refactoring.
2079 Also tweaked formatting a bit.
2081 2009-03-17 Alexey Proskuryakov <ap@webkit.org>
2083 Reviewed by Darin Adler.
2085 HTMLSelectElement::add() doesn't look at exception code returned from insertBefore(), so
2086 it doesn't need to zero it out before calling.
2088 * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::add): Removed "ec = 0" line.
2090 2009-03-17 Dan Bernstein <mitz@apple.com>
2092 Reviewed by Adam Roben.
2094 - WebCore part of adding a mechanism for controlling the caching of
2095 responses through WebFrameLoaderClient
2097 Mac already has such a mechanism, and this adds one for CFNetwork ports.
2099 * WebCore.vcproj/WebCore.vcproj: Added EmptyClients.h
2100 and ResourceLoaderCFNet.cpp.
2102 * loader/EmptyClients.h:
2103 (WebCore::EmptyFrameLoaderClient::shouldCacheResponse): Added an
2104 implementation that always returns true.
2106 * loader/FrameLoaderClient.h: Declared shouldCacheResponse().
2108 * loader/ResourceLoader.h: Ditto.
2110 * loader/cf/ResourceLoaderCFNet.cpp: Added.
2111 (WebCore::ResourceLoader::shouldCacheResponse): Added. Calls through to
2112 FrameLoaderClient::shouldCacheResponse().
2114 * platform/network/ResourceHandleClient.h:
2115 (WebCore::ResourceHandleClient::shouldCacheResponse): Added an
2116 implementation that always returns true.
2118 * platform/network/cf/ResourceHandleCFNet.cpp:
2119 (WebCore::willCacheResponse): Added a call to
2120 ResourceHandleClient::shouldCacheResponse(). If the client returns
2121 false, return 0, which will prevent CFNetwork from caching the response.
2123 2009-03-17 Alexey Proskuryakov <ap@webkit.org>
2125 Reviewed by Darin Adler.
2127 https://bugs.webkit.org/show_bug.cgi?id=13287
2128 Cannot change SELECT to a dynamically created option
2130 Tests: fast/forms/add-and-remove-option.html
2131 fast/forms/add-remove-option-modification-event.html
2132 fast/forms/add-selected-option.html
2133 fast/forms/select-cache-desynchronization.html
2135 * dom/ContainerNode.cpp:
2136 (WebCore::dispatchChildInsertionEvents): Increment DOM tree version. This will happen when
2137 dispatching DOMSubtreeModified again, but the version should be incremented for event
2138 listeners to have an up to date view of the DOM.
2139 (WebCore::dispatchChildRemovalEvents): Ditto.
2141 * html/HTMLOptionElement.cpp: (WebCore::HTMLOptionElement::insertedIntoTree):
2142 Make sure that the select element knows about its new selected option.
2144 * html/HTMLOptionElement.h: Use insertedIntoTree() instead of insertedIntoDocument(),
2145 because DOM also needs to be updated for forms that are not in document yet. Similar
2146 problems exist for node removing, but removedFromTree() is called at a wrong time, so
2147 those problems cannot be fixed without deeper refactoring.
2149 * html/HTMLSelectElement.cpp:
2150 (WebCore::HTMLSelectElement::setRecalcListItems): Reset m_activeSelectionAnchorIndex - it
2151 doesn't make sense to keep the anchor after programmatically changing the selection, and
2152 keeping it was causing a failure in fast/forms/listbox-selection.html.
2154 * html/HTMLSelectElement.h: Removed overrides for ContainerNode methods that only called
2155 base class versions.
2157 2009-03-17 Steve Falkenburg <sfalken@apple.com>
2159 <rdar://problem/6690324> Accessing FTP sites reads unallocated memory, can result in garbled entries or crashes
2161 Reviewed by Darin Adler.
2163 * loader/FTPDirectoryDocument.cpp:
2164 (WebCore::FTPDirectoryTokenizer::parseAndAppendOneLine): Assign CString to a local while we hold pointers into it.
2166 2009-03-16 David Hyatt <hyatt@apple.com>
2168 <rdar://problem/6648411> REGRESSION: Layout of page is wrong at http://www.popcap.com/
2170 Make sure that the initial shouldPaint check that looks at enclosingLayers properly skips over
2171 layers that don't paint themselves. This is done by adding a new enclosingSelfPaintingLayer method
2172 so that RenderObjects can walk up the enclosing layer chain and skip any layers that don't paint
2175 Reviewed by Darin Adler.
2177 Added fast/block/float/overlapping-floats-with-overflow-hidden.html
2180 * rendering/RenderBlock.cpp:
2181 (WebCore::RenderBlock::addOverhangingFloats):
2182 * rendering/RenderObject.cpp:
2183 (WebCore::RenderObject::enclosingSelfPaintingLayer):
2184 * rendering/RenderObject.h:
2186 2009-03-17 Xan Lopez <xlopez@igalia.com>
2188 Reviewed by Holger Freyther.
2190 https://bugs.webkit.org/show_bug.cgi?id=24592
2191 [GTK] Crash in FcPatternHash
2195 * platform/graphics/gtk/FontPlatformDataGtk.cpp:
2196 (WebCore::FontPlatformData::operator=):
2197 * platform/graphics/gtk/FontPlatformDataPango.cpp:
2199 2009-03-17 Xan Lopez <xlopez@igalia.com>
2201 Reviewed by Holger Freyther.
2203 https://bugs.webkit.org/show_bug.cgi?id=24592
2204 [GTK] Crash in FcPatternHash
2206 Sanitize memory management in pango fonts.
2208 Release memory allocated by FontPlatformDataPango in its own
2209 destructor instead of doing it from other classes, and add copy
2210 constructor and '=' operator to be able to track referenced
2213 * platform/graphics/gtk/FontPlatformDataPango.cpp:
2214 (WebCore::FontPlatformData::~FontPlatformData):
2215 (WebCore::FontPlatformData::operator=):
2216 (WebCore::FontPlatformData::FontPlatformData):
2217 * platform/graphics/gtk/SimpleFontDataPango.cpp:
2219 2009-03-17 Darin Adler <darin@apple.com>
2221 Reviewed by Alexey Proskuryakov.
2223 Bug 24624: Crash in imageLoadEventTimerFired after adoptNode used on <img>,
2224 seen with inspector, which uses adoptNode
2225 https://bugs.webkit.org/show_bug.cgi?id=24624
2226 rdar://problem/6422850
2228 Test: fast/dom/HTMLImageElement/image-load-cross-document.html
2231 (WebCore::Document::Document): Removed m_imageLoadEventTimer.
2232 (WebCore::Document::detach): Removed m_imageLoadEventDispatchSoonList and
2233 m_imageLoadEventDispatchingList.
2234 (WebCore::Document::implicitClose): Called ImageLoader::dispatchPendingLoadEvents
2235 instead of dispatchImageLoadEventsNow.
2237 * dom/Document.h: Removed ImageLoader, dispatchImageLoadEventSoon,
2238 dispatchImageLoadEventsNow, removeImage, m_imageLoadEventDispatchSoonList,
2239 m_imageLoadEventDispatchingList, m_imageLoadEventTimer, and imageLoadEventTimerFired.
2241 * loader/ImageLoader.cpp:
2242 (WebCore::loadEventSender): Added. Returns the single global ImageLoadEventSender
2243 object used privately as the target of the load event timer.
2244 (WebCore::ImageLoader::~ImageLoader): Call ImageLoadEventSender::cancelLoadEvent
2245 rather than Document::removeImage.
2246 (WebCore::ImageLoader::setImage): Use m_element directly, not element().
2247 (WebCore::ImageLoader::updateFromElement): Ditto. Also name the local variable
2248 document instead of doc.
2249 (WebCore::ImageLoader::notifyFinished): Call ImageLoadEventSender::dispatchLoadEventSoon
2250 rather than Document::dispatchImageLoadEventSoon.
2251 (WebCore::ImageLoader::dispatchPendingLoadEvent): Added. Handles the common logic
2252 about when load events can be dispatched so that dispatchLoadEvent only has to
2253 have the specific part for each derived class. This includes a check that the
2254 document is attached, which used to be handled by having documents empty out the
2255 image load event vectors in the detach function.
2256 (WebCore::ImageLoader::dispatchPendingLoadEvents): Added. Calls the appropriate
2257 function on the ImageLoadEventSender, which avoids the need to have that class be
2258 public in the ImageLoader header.
2259 (WebCore::ImageLoadEventSender::ImageLoadEventSender): Added. Has the code that
2260 was previously in the Document constructor.
2261 (WebCore::ImageLoadEventSender::dispatchLoadEventSoon): Added. Has the code that
2262 was previously in Document::dispatchImageLoadEventSoon.
2263 (WebCore::ImageLoadEventSender::cancelLoadEvent): Added. Has the code that was
2264 previously in Document::removeImage.
2265 (WebCore::ImageLoadEventSender::dispatchPendingLoadEvents): Added. Has the code
2266 that was previously in Document::dispatchImageLoadEventsNow.
2267 (WebCore::ImageLoadEventSender::timerFired): Added. Calls dispatchPendingLoadEvents.
2269 * loader/ImageLoader.h: Improved comments. Made the virtual functions private
2270 or protected rather than public. Added static dispatchPendingLoadEvents function
2271 for use by Document and private dispatchPendingLoadEvent function for use by
2272 ImageLoadEventSender. Made setLoadingImage private and eliminated
2273 setHaveFiredLoadEvent since that can all be done inside the class without any
2276 * html/HTMLImageLoader.cpp:
2277 (WebCore::HTMLImageLoader::dispatchLoadEvent): Removed logic to check whether a
2278 load event already fired and whether image() is 0. These are now both base class
2280 * svg/SVGImageLoader.cpp:
2281 (WebCore::SVGImageLoader::dispatchLoadEvent): Ditto.
2282 * wml/WMLImageLoader.cpp:
2283 (WebCore::WMLImageLoader::dispatchLoadEvent): Ditto.
2285 2009-03-17 Dimitri Glazkov <dglazkov@chromium.org>
2287 Reviewed by Timothy Hatcher.
2289 https://bugs.webkit.org/show_bug.cgi?id=24623
2290 Refactor ConsoleMessage to use ScriptFuncitonCall and eliminate JSC
2293 * bindings/js/ScriptFunctionCall.cpp:
2294 (WebCore::ScriptFunctionCall::appendArgument): Added uint and ScriptString-taking methods.
2295 * bindings/js/ScriptFunctionCall.h:
2296 * bindings/js/ScriptObjectQuarantine.cpp:
2297 (WebCore::quarantineValue): Added generic ScriptValue quarantine helper.
2298 * bindings/js/ScriptObjectQuarantine.h:
2299 * bindings/js/ScriptValue.cpp:
2300 (WebCore::ScriptValue::isEqual): Added.
2301 * bindings/js/ScriptValue.h:
2302 * inspector/ConsoleMessage.cpp:
2303 (WebCore::ConsoleMessage::ConsoleMessage):
2304 (WebCore::ConsoleMessage::addToConsole): Added.
2305 (WebCore::ConsoleMessage::isEqual): Changed to use ScriptValue::isEqual.
2306 * inspector/ConsoleMessage.h:
2307 (WebCore::ConsoleMessage::incrementCount): Added.
2308 * inspector/InspectorController.cpp:
2309 (WebCore::InspectorController::addConsoleMessage): Changed to use ConsoleMessage::addToConsole.
2310 (WebCore::InspectorController::populateScriptObjects): Ditto.
2311 * inspector/InspectorController.h:
2313 2009-03-17 Kevin Ollivier <kevino@theolliviers.com>
2315 Reviewed by Mark Rowe.
2317 Get BUILDING_ON_* defines from Platform.h.
2319 https://bugs.webkit.org/show_bug.cgi?id=24630
2323 2009-03-16 Xan Lopez <xlopez@igalia.com>
2325 Reviewed by Holger Freyther.
2327 https://bugs.webkit.org/show_bug.cgi?id=24592
2328 [GTK] Crash in FcPatternHash
2330 Sanitize memory management in gtk fonts.
2332 Release memory allocated by FontPlatformDataGtk in its own
2333 destructor instead of doing it from other classes, and add copy
2334 constructor and '=' operator to be able to track referenced
2337 * platform/graphics/gtk/FontPlatformData.h:
2338 * platform/graphics/gtk/FontPlatformDataGtk.cpp:
2339 (WebCore::FontPlatformData::operator=):
2340 (WebCore::FontPlatformData::FontPlatformData):
2341 (WebCore::FontPlatformData::~FontPlatformData):
2342 * platform/graphics/gtk/SimpleFontDataGtk.cpp:
2343 (WebCore::SimpleFontData::platformDestroy):
2345 2009-03-17 Ariya Hidayat <ariya.hidayat@nokia.com>
2347 Build fix for Qt < 4.5.
2349 As reported by Yael Aharon <yael.aharon@nokia.com>
2351 * platform/graphics/qt/GraphicsContextQt.cpp:
2352 (WebCore::GraphicsContext::drawLine):
2354 2009-03-17 Alexey Proskuryakov <ap@webkit.org>
2356 Reviewed by Sam Weinig.
2358 https://bugs.webkit.org/show_bug.cgi?id=24614
2359 Access control checks are different in cached and uncached cases
2361 Test: http/tests/xmlhttprequest/access-control-basic-non-simple-deny-cached.html
2363 * loader/CrossOriginAccessControl.cpp:
2364 (WebCore::isOnAccessControlSimpleRequestMethodWhitelist): Factored out simple method
2365 check for use in both cached and uncached cases. In cached case, an old definition that
2366 omitted HEAD was still used.
2367 (WebCore::isOnAccessControlSimpleRequestHeaderWhitelist): Check that content type has an
2368 allowed value. This is needed in all call sites. Also changed to compare MIME type, not
2370 (WebCore::isSimpleCrossOriginAccessRequest): Use the above methods.
2372 * loader/CrossOriginAccessControl.h: Expose isOnAccessControlSimpleRequestMethodWhitelist.
2374 * loader/CrossOriginPreflightResultCache.cpp:
2375 (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginMethod):
2376 (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders):
2377 Use the new checks for simple method and header.
2379 2009-03-16 Gustavo Noronha Silva <gns@gnome.org> and Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
2381 Reviewed by Mark Rowe.
2383 https://bugs.webkit.org/show_bug.cgi?id=24638
2384 [GTK] HTML5 media tags do not work
2386 Add a repaint-requested signal to the video sink, and use it to
2387 call MediaPlayerPrivate::repaint, so that the video actually
2390 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
2391 (WebCore::mediaPlayerPrivateRepaintCallback):
2392 (WebCore::MediaPlayerPrivate::createGSTPlayBin):
2393 * platform/graphics/gtk/VideoSinkGStreamer.cpp:
2394 (webkit_video_sink_idle_func):
2395 (webkit_video_sink_render):
2396 (webkit_video_sink_class_init):
2398 2009-03-16 Gustavo Noronha Silva <gns@gnome.org> and Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
2400 Reviewed by Holger Freyther.
2402 https://bugs.webkit.org/show_bug.cgi?id=24638
2403 [GTK] HTML5 media tags do not work
2405 Work-around the fact that gst_element_query_duration returns true even
2406 though it is unable to figure out the duration when in stream (push)
2409 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
2410 (WebCore::MediaPlayerPrivate::duration):
2412 2009-03-16 Darin Adler <darin@apple.com>
2414 Reviewed by Kevin Decker.
2416 <rdar://problem/6642742> Top Sites malfunction when switching text zoom mode
2419 (WebCore::Frame::setNeedsReapplyStyles): Don’t do anything if the frame is
2420 currently showing a non-HTML view.
2422 2009-03-16 Darin Adler <darin@apple.com>
2424 Reviewed by Adele Peterson.
2426 Bug 24629: moving forward or backward a paragraph fails at edge of document
2427 https://bugs.webkit.org/show_bug.cgi?id=24629
2428 rdar://problem/6544413
2430 Test: editing/selection/move-paragraph-document-edges.html
2432 * editing/visible_units.cpp:
2433 (WebCore::previousParagraphPosition): Use the last result from
2434 previousLinePosition rather than going all the way back to what was originally
2435 passed in when we hit exception cases like null or not moving. This correctly
2436 inherits the behavior of previousLinePosition when we are in a paragraph at the
2438 (WebCore::nextParagraphPosition): Ditto.
2440 2009-03-16 Darin Adler <darin@apple.com>
2442 Reviewed by Adele Peterson.
2444 Bug 24619: RenderObject::selectionStartEnd does not need to be a virtual function
2445 https://bugs.webkit.org/show_bug.cgi?id=24619
2447 * rendering/RenderObject.h: Remove virtual keyword from selectionStartEnd declaration.
2448 * rendering/RenderView.h: Ditto.
2450 2009-03-16 Peter Kasting <pkasting@google.com>
2452 Reviewed by David Hyatt.
2454 https://bugs.webkit.org/show_bug.cgi?id=24368
2455 DOM scroll events should be based off the actual number of wheel
2456 ticks, not off the number of lines scrolled. This matches IE.
2459 (WebCore::Node::dispatchWheelEvent):
2460 * dom/WheelEvent.cpp:
2461 (WebCore::WheelEvent::WheelEvent):
2463 (WebCore::WheelEvent::create):
2464 * platform/PlatformWheelEvent.h:
2465 (WebCore::PlatformWheelEvent::wheelTicksX):
2466 (WebCore::PlatformWheelEvent::wheelTicksY):
2467 * platform/gtk/WheelEventGtk.cpp:
2468 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2469 * platform/mac/WheelEventMac.mm:
2470 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2471 * platform/qt/WheelEventQt.cpp:
2472 * platform/win/WheelEventWin.cpp:
2473 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2474 * platform/wx/MouseWheelEventWx.cpp:
2475 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2477 2009-03-16 Simon Fraser <simon.fraser@apple.com>
2479 Reviewed by Eric Seidel
2481 Clean up a few issues in the Animation code:
2483 * page/animation/AnimationBase.cpp:
2484 (WebCore::AnimationBase::updateStateMachine):
2487 (WebCore::AnimationBase::willNeedService):
2488 Don't round to float, use std::max
2490 * page/animation/AnimationController.cpp:
2491 (WebCore::AnimationControllerPrivate::startTimeResponse):
2492 Fix erroneously copied line to null out m_lastResponseWaiter.
2494 2009-03-12 David Hyatt <hyatt@apple.com>
2496 Reviewed by Eric Seidel
2498 https://bugs.webkit.org/show_bug.cgi?id=13632
2500 Overflow scrolling needs to account for the bottom/right padding on the object itself as well
2501 as for bottom/right margins on children.
2503 Existing tests cover this.
2505 * rendering/RenderBlock.cpp:
2506 (WebCore::RenderBlock::lowestPosition):
2507 (WebCore::RenderBlock::rightmostPosition):
2509 2009-03-16 Sam Weinig <sam@webkit.org>
2511 Reviewed by Anders Carlsson.
2513 Fix for <rdar://problem/6320555>
2514 Add an upper limit for setting HTMLSelectElement.length.
2516 Test: fast/forms/select-max-length.html
2518 * html/HTMLSelectElement.cpp:
2519 (WebCore::HTMLSelectElement::setOption):
2520 (WebCore::HTMLSelectElement::setLength):
2522 2009-03-16 Eric Carlson <eric.carlson@apple.com>
2524 Reviewed by Simon Fraser.
2526 <rdar://problem/6686721> Media document crash in 64-bit WebKit
2528 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2529 (WebCore::MediaPlayerPrivate::createQTMovieView): QTMovieContentViewClass is only used when
2530 rendering inline with old versions of QuickTime, so don't look for it when we are in a
2533 2009-03-16 Dimitri Glazkov <dglazkov@chromium.org>
2535 Reviewed by Timothy Hatcher.
2537 https://bugs.webkit.org/show_bug.cgi?id=24590
2538 Refactor InspectorDOMStorageResource to use ScriptFunctionCall.
2540 * bindings/js/ScriptFunctionCall.cpp:
2541 (WebCore::ScriptFunctionCall::appendArgument): Added method for bool argument.
2542 * bindings/js/ScriptFunctionCall.h: Ditto, also cleaned up.
2543 * bindings/js/ScriptObjectQuarantine.cpp:
2544 (WebCore::getQuarantinedScriptObject): Added Storage helper.
2545 * bindings/js/ScriptObjectQuarantine.h: Ditto.
2546 * inspector/InspectorController.cpp:
2547 (WebCore::InspectorController::populateScriptObjects): Changed to use bind method.
2548 (WebCore::InspectorController::resetScriptObjects): Changed to use unbind method.
2549 (WebCore::InspectorController::didUseDOMStorage): Changed to use isSameHostAndType and bind methods.
2550 * inspector/InspectorController.h: Removed add/remove methods for DOM storage.
2551 * inspector/InspectorDOMStorageResource.cpp:
2552 (WebCore::InspectorDOMStorageResource::InspectorDOMStorageResource):
2553 (WebCore::InspectorDOMStorageResource::isSameHostAndType): Added.
2554 (WebCore::InspectorDOMStorageResource::bind): Added.
2555 (WebCore::InspectorDOMStorageResource::unbind): Added.
2556 * inspector/InspectorDOMStorageResource.h:
2558 2009-03-16 Mike Belshe <mike@belse.com>
2560 Reviewed by Dimitri Glazkov.
2562 https://bugs.webkit.org/show_bug.cgi?id=24580
2563 Fix query() to match KURL behavior, this time with the code that
2566 * platform/KURLGoogle.cpp:
2567 (WebCore::KURL::query): Fix copy/paste mistake.
2569 2009-03-16 Alexey Proskuryakov <ap@webkit.org>
2571 Reviewed by Darin Adler.
2573 https://bugs.webkit.org/show_bug.cgi?id=21752
2574 REGRESSION: referencing XHR constructor for a not yet loaded frame permanently breaks it
2576 Test: fast/dom/Window/window-early-properties-xhr.html
2578 For some transitions, the Window object is not replaced, but Document is. When this happened,
2579 window.document property was updated, but references to Document kept in cached constructors
2582 * bindings/js/JSAudioConstructor.cpp:
2583 (WebCore::JSAudioConstructor::JSAudioConstructor):
2584 (WebCore::JSAudioConstructor::document):
2585 (WebCore::JSAudioConstructor::mark):
2586 * bindings/js/JSAudioConstructor.h:
2587 * bindings/js/JSImageConstructor.cpp:
2588 (WebCore::JSImageConstructor::JSImageConstructor):
2589 (WebCore::JSImageConstructor::document):
2590 (WebCore::JSImageConstructor::mark):
2591 * bindings/js/JSImageConstructor.h:
2592 * bindings/js/JSMessageChannelConstructor.cpp:
2593 (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor):
2594 (WebCore::JSMessageChannelConstructor::scriptExecutionContext):
2595 (WebCore::JSMessageChannelConstructor::mark):
2596 * bindings/js/JSMessageChannelConstructor.h:
2597 * bindings/js/JSOptionConstructor.cpp:
2598 (WebCore::JSOptionConstructor::JSOptionConstructor):
2599 (WebCore::JSOptionConstructor::document):
2600 (WebCore::JSOptionConstructor::mark):
2601 * bindings/js/JSOptionConstructor.h:
2602 * bindings/js/JSXMLHttpRequestConstructor.cpp:
2603 (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
2604 (WebCore::JSXMLHttpRequestConstructor::scriptExecutionContext):
2605 (WebCore::JSXMLHttpRequestConstructor::mark):
2606 * bindings/js/JSXMLHttpRequestConstructor.h:
2607 Changed cached constructors to keep a reference to Window, not Document.
2609 2009-03-15 Alexey Proskuryakov <ap@webkit.org>
2611 Reviewed by Darin Adler.
2613 https://bugs.webkit.org/show_bug.cgi?id=24549
2614 Impose a limit on Access-Control-Max-Age value
2616 * loader/CrossOriginPreflightResultCache.cpp:
2617 (WebCore::CrossOriginPreflightResultCacheItem::parse):
2619 2009-03-15 Greg Bolsinga <bolsinga@apple.com>
2621 Reviewed by David Kilzer.
2623 <rdar://problem/6668875> Normalize Geolocation results
2625 * platform/mac/GeolocationServiceMac.mm:
2626 (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
2628 2009-03-15 Greg Bolsinga <bolsinga@apple.com>
2630 Reviewed by David Kilzer.
2632 Update ::toString format as suggested by Darin Adler.
2634 * page/Geoposition.cpp:
2635 (WebCore::Geoposition::toString):
2637 2009-03-15 David Kilzer <ddkilzer@apple.com>
2639 <rdar://problem/6668238> WebCore is registering text encodings needlessly from KURL constructor.
2641 Reviewed by Darin Adler.
2643 Yet another case where we would trigger extended encoding loading needlessly.
2645 * platform/text/TextEncoding.cpp:
2646 (WebCore::TextEncoding::encodingForFormSubmission):
2648 2009-03-15 Simon Fraser <simon.fraser@apple.com>
2650 Build fix: no review.
2652 * rendering/style/ContentData.h:
2654 2009-03-15 David Kilzer <ddkilzer@apple.com>
2656 Bug 24542: Improve ContentData encapsulation
2658 <https://bugs.webkit.org/show_bug.cgi?id=24542>
2660 Reviewed by Simon Fraser.
2662 No tests since there is no change in behavior.
2664 * rendering/RenderObject.cpp:
2665 (WebCore::RenderObject::createObject): Used getter methods
2666 instead of data members on ContentData class. Used isImage()
2668 * rendering/RenderObjectChildList.cpp:
2669 (WebCore::RenderObjectChildList::updateBeforeAfterContent): Ditto.
2671 * rendering/style/ContentData.cpp:
2672 (WebCore::ContentData::clear): Extracted code into
2673 deleteContent() method.
2674 (WebCore::ContentData::dataEquivalent): Added. Extracted code
2675 from StyleRareNonInheritedData::contentDataEquivalent().
2676 (WebCore::ContentData::deleteContent): Added. Used by setter
2678 * rendering/style/ContentData.h: Made m_type, m_content and
2680 (WebCore::ContentData::isCounter): Added.
2681 (WebCore::ContentData::isImage): Added.
2682 (WebCore::ContentData::isNone): Added.
2683 (WebCore::ContentData::isText): Added.
2684 (WebCore::ContentData::type): Added.
2685 (WebCore::ContentData::dataEquivalent): Added.
2686 (WebCore::ContentData::image): Added.
2687 (WebCore::ContentData::setImage): Added.
2688 (WebCore::ContentData::text): Added.
2689 (WebCore::ContentData::setText): Added.
2690 (WebCore::ContentData::counter): Added.
2691 (WebCore::ContentData::setCounter): Added.
2692 (WebCore::ContentData::next): Added.
2693 (WebCore::ContentData::setNext): Added.
2695 * rendering/style/CounterContent.h:
2696 (WebCore::operator!=): Removed.
2697 (WebCore::operator==): Renamed operator!=() and reversed its
2698 logic after extracting code from
2699 StyleRareNonInheritedData::contentDataEquivalent() to create
2700 ContentData::dataEquivalent().
2702 * rendering/style/RenderStyle.cpp:
2703 (WebCore::RenderStyle::setContent): Used new getters and setters
2704 on ContentData class. Changed first argument from a StringImpl*
2705 to a PassRefPtr<StrimgImpl>. Used isText() convenience method.
2706 * rendering/style/RenderStyle.h:
2707 (WebCore::RenderStyle::setContent): Updated declaration.
2708 * rendering/style/StyleRareNonInheritedData.cpp:
2709 (WebCore::StyleRareNonInheritedData::contentDataEquivalent):
2710 Extracted most logic in while() loop into
2711 ContentData::dataEquivalent().
2713 2009-03-15 Gustavo Noronha Silva <gns@gnome.org>
2715 Reviewed by Anders Carlsson.
2717 https://bugs.webkit.org/show_bug.cgi?id=24602
2718 [Gtk] Searching in thepiratebay.org doesn't work with more than 1 word
2720 Reintroduce the URI into the soup message after having set it in
2721 the KURL, on redirects, to make sure it is properly encoded. This
2722 fixes bad request problems when servers give bad URIs on their
2723 response's Location header.
2725 * platform/network/soup/ResourceHandleSoup.cpp:
2726 (WebCore::restartedCallback):
2728 2009-03-15 Alexey Proskuryakov <ap@webkit.org>
2730 Reviewed by Darin Adler.
2732 https://bugs.webkit.org/show_bug.cgi?id=19737
2733 No cursor and paste not enabled right clicking text field/area
2735 Test: fast/events/right-click-focus.html
2737 * page/EventHandler.cpp:
2738 (WebCore::EventHandler::handleMousePressEventSingleClick):
2739 (WebCore::EventHandler::handleMousePressEvent):
2740 Take normal code path for right clicks (we were taking it for Ctrl-clicks anyway).
2742 2009-03-15 Alexey Proskuryakov <ap@webkit.org>
2744 Reviewed by Adele Peterson.
2746 https://bugs.webkit.org/show_bug.cgi?id=23949
2747 HTMLSelectElement is in inconsistent state when handling mutation events
2749 Test: fast/forms/mutation-event-recalc.html
2751 * dom/ContainerNode.cpp:
2752 (WebCore::ContainerNode::insertBefore):
2753 (WebCore::ContainerNode::appendChild):
2754 Call childrenChanged() before dispatching modification events, not after.
2756 * html/HTMLOptGroupElement.cpp:
2757 (WebCore::HTMLOptGroupElement::insertBefore):
2758 (WebCore::HTMLOptGroupElement::replaceChild):
2759 (WebCore::HTMLOptGroupElement::removeChild):
2760 (WebCore::HTMLOptGroupElement::appendChild):
2761 (WebCore::HTMLOptGroupElement::removeChildren):
2762 * html/HTMLSelectElement.cpp:
2763 (WebCore::HTMLSelectElement::add):
2764 (WebCore::HTMLSelectElement::remove):
2765 (WebCore::HTMLSelectElement::insertBefore):
2766 (WebCore::HTMLSelectElement::replaceChild):
2767 (WebCore::HTMLSelectElement::removeChild):
2768 (WebCore::HTMLSelectElement::appendChild):
2769 (WebCore::HTMLSelectElement::removeChildren):
2770 Remove calls to recalcSelectOptions(). It is too late to recalc now, after mutation events
2771 were already dispatched.
2773 2009-03-14 Greg Bolsinga <bolsinga@apple.com>
2775 <rdar://problem/6683465>
2777 Geolocation has to be able to handle NULL Frames.
2779 Reviewed by Mark Rowe
2781 2009-03-14 Greg Bolsinga <bolsinga@apple.com>
2783 Reviewed by David Kilzer.
2785 Geoposition::toString was missing the Coordinates after the update.
2787 * page/Geoposition.cpp:
2788 (WebCore::Geoposition::toString):
2790 2009-03-14 Jan Michael Alonzo <jmalonzo@webkit.org>
2792 Reviewed by Mark Rowe.
2794 [Gtk] Build fix - pass a Coordinate to Geoposition::create
2795 https://bugs.webkit.org/show_bug.cgi?id=24603
2797 Gtk build fix per r41650
2798 https://bugs.webkit.org/show_bug.cgi?id=24506
2799 Geolocation in Safari differs from the spec, no Coordinates attribute on Position
2801 Pass a Coordinate to Geoposition::create.
2803 * platform/gtk/GeolocationServiceGtk.cpp:
2804 (WebCore::GeolocationServiceGtk::updatePosition):
2806 2009-03-14 Alexey Proskuryakov <ap@webkit.org>
2808 Reviewed by Darin Adler.
2810 https://bugs.webkit.org/show_bug.cgi?id=24545
2811 Make cross-site XHR simple request definition match current spec draft
2813 Tests: http/tests/xmlhttprequest/access-control-basic-post-fail-non-simple-content-type.html
2814 http/tests/xmlhttprequest/access-control-basic-whitelist-request-headers.html
2816 * loader/CrossOriginAccessControl.cpp:
2817 (WebCore::isOnAccessControlSimpleRequestHeaderWhitelist): Added Content-Language.
2818 (WebCore::isSimpleCrossOriginAccessRequest): Added HEAD. Restricted content types to those
2819 that could be sent via form submission.
2821 2009-03-14 Alexey Proskuryakov <ap@webkit.org>
2823 Reviewed by Darin Adler.
2825 https://bugs.webkit.org/show_bug.cgi?id=15172
2826 object fallback - empty string for first argument of setAttributeNS does not work like null
2828 https://bugs.webkit.org/show_bug.cgi?id=24548
2829 createElementNS("", name) should create an element in null namespace
2831 Tests: fast/dom/createElementNS-empty-namespace.html
2832 fast/dom/setAttributeNS-empty-namespace.html
2834 * dom/QualifiedName.h: (WebCore::QualifiedName::QualifiedNameImpl::QualifiedNameImpl):
2835 Convert empty namespaces to null.
2837 2009-03-13 Mark Rowe <mrowe@apple.com>
2839 Rubber-stamped by Dan Bernstein.
2841 Take advantage of the ability of recent versions of Xcode to easily switch the active
2844 * Configurations/DebugRelease.xcconfig:
2846 2009-03-13 John Abd-El-Malek <jam@google.com>
2848 Reviewed by Darin Fisher.
2850 https://bugs.webkit.org/show_bug.cgi?id=24593
2851 Added requestorID so we can track the request to its WebView without using frame (which was removed).
2853 * platform/network/chromium/ResourceRequest.h:
2854 (WebCore::ResourceRequest::ResourceRequest):
2855 (WebCore::ResourceRequest::requestorID):
2856 (WebCore::ResourceRequest::setRequestorID):
2857 (WebCore::ResourceRequest::setTargetType):
2858 (WebCore::ResourceRequest::policyURL):
2859 (WebCore::ResourceRequest::setPolicyURL):
2860 (WebCore::ResourceRequest::requestorPid):
2861 (WebCore::ResourceRequest::setRequestorPid):
2863 2009-03-13 Mike Belshe <mike@belshe.com>
2865 Reviewed by Dimitri Glazkov.
2867 https://bugs.webkit.org/show_bug.cgi?id=24561
2868 Add custom V8 bindings for HTMLElementCanvas, Location.
2870 * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp: Added.
2871 * bindings/v8/custom/V8LocationCustom.cpp: Added.
2873 2009-03-13 Stephen White <senorblanco@chromium.org>
2875 Reviewed by Eric Seidel.
2877 https://bugs.webkit.org/show_bug.cgi?id=24584
2879 Fix transparent text rendering on Chromium. FontChromiumWin
2880 was calling beginTransparencyLayer()/endTransparencyLayer(), with
2881 a TransparencyWin inside to do GDI ClearType rendering over an
2882 opaque background. TransparencyWin does its special sauce
2883 in the destructor, but it was being called too late to be used
2884 correctly in the layer. Put the special sauce into a new function,
2885 composite(), and call that explicitly instead.
2887 * platform/graphics/chromium/FontChromiumWin.cpp:
2888 (WebCore::TransparencyAwareFontPainter::TransparencyAwareFontPainter::~TransparencyAwareFontPainter):
2889 * platform/graphics/chromium/TransparencyWin.cpp:
2890 (WebCore::TransparencyWin::~TransparencyWin):
2891 (WebCore::TransparencyWin::composite):
2892 (WebCore::TransparencyWin::init):
2893 * platform/graphics/chromium/TransparencyWin.h:
2894 * rendering/RenderThemeChromiumWin.cpp:
2897 2009-03-13 Mike Belshe <mike@belshe.com>
2899 Reviewed by Dimitri Glazkov.
2901 https://bugs.webkit.org/show_bug.cgi?id=24562
2902 Add custom implementation for getCSSCanvasContext to V8 bindings.
2904 * bindings/v8/custom/V8DocumentCustom.cpp: Added new method.
2906 2009-03-13 Mike Belshe <mike@belse.com>
2908 Reviewed by Dimitri Glazkov.
2910 https://bugs.webkit.org/show_bug.cgi?id=24580
2911 Fix query() to match KURL behavior.
2913 * platform/KURLGoogle.cpp:
2914 (WebCore::KURL::query): remove extra logic around question mark.
2916 2009-03-13 Chris Fleizach <cfleizach@apple.com>
2918 Reviewed by Beth Dakin.
2920 Bug 24474: AX: in multi-body tables, asking for a cell at a specific coordinate can return nil
2921 https://bugs.webkit.org/show_bug.cgi?id=24474
2923 Test: platform/mac-snowleopard/accessibility/table-multi-bodies.html
2925 * page/AccessibilityTable.cpp:
2926 (WebCore::AccessibilityTable::cellForColumnAndRow):
2928 2009-03-13 Jian Li <jianli@chromium.org>
2930 Reviewed by Dimitri Glazkov.
2932 https://bugs.webkit.org/show_bug.cgi?id=24589
2933 Upstream changes to V8 event listeners (Chromium r11133) in order to
2934 fix worker functionality break in Chromium.
2936 * bindings/v8/V8AbstractEventListener.cpp:
2937 (WebCore::V8AbstractEventListener::invokeEventHandler):
2938 (WebCore::V8AbstractEventListener::handleEvent):
2939 * bindings/v8/V8AbstractEventListener.h:
2940 * bindings/v8/V8WorkerContextEventListener.cpp:
2941 (WebCore::V8WorkerContextEventListener::handleEvent):
2943 2009-03-13 Dimitri Glazkov <dglazkov@chromium.org>
2945 Reviewed by Timothy Hatcher.
2947 https://bugs.webkit.org/show_bug.cgi?id=24524
2948 Introduce ScriptObject and ScriptFunctionCall abstractions.
2950 * GNUmakefile.am: Added ScriptObject and ScriptFunctionCall to project.
2951 * WebCore.pro: Ditto.
2952 * WebCore.vcproj/WebCore.vcproj: Ditto.
2953 * WebCore.xcodeproj/project.pbxproj: Ditto.
2954 * WebCoreSources.bkl: Ditto.
2955 * bindings/js/ScriptFunctionCall.cpp: Added.
2956 * bindings/js/ScriptFunctionCall.h: Added.
2957 * bindings/js/ScriptObject.cpp: Added.
2958 * bindings/js/ScriptObject.h: Added.
2959 * bindings/js/ScriptObjectQuarantine.cpp: Added.
2960 * bindings/js/ScriptObjectQuarantine.h: Added.
2961 * inspector/InspectorController.cpp:
2962 (WebCore::InspectorController::populateScriptObjects): Changed to use InspectorDatabaseResource::bind.
2963 (WebCore::InspectorController::resetScriptObjects): Changed to use InspectorDatabaseResource::unbind.
2964 (WebCore::InspectorController::didOpenDatabase): Changed to use InspectorDatabaseResource::unbind.
2965 * inspector/InspectorController.h: Removed addScriptDatabaseResource and
2966 removeScriptDatabaseResource declarations.
2967 * inspector/InspectorDatabaseResource.cpp:
2968 (WebCore::InspectorDatabaseResource::InspectorDatabaseResource):
2969 (WebCore::InspectorDatabaseResource::bind): Added.
2970 (WebCore::InspectorDatabaseResource::unbind): Added.
2971 * inspector/InspectorDatabaseResource.h: Added bind and unbind declarations.
2973 2009-03-13 Peter Kasting <pkasting@google.com>
2975 Reviewed by Eric Seidel.
2977 https://bugs.webkit.org/show_bug.cgi?id=24467
2978 Make Skia drawRect() and stroke behavior match CG.
2980 This makes drawRect() ignore the stroke width (like CG does), and
2981 adds a warning comment about that to the appropriate header.
2983 It also eliminates some hacky code in Skia's stroke preparation,
2984 which tried to adjust odd-width strokes to fall on pixel boundaries.
2985 Not only did this not match CG, it wouldn't necessarily work right,
2986 because there could be other transforms (e.g. full-page zoom) that
2987 would affect the stroke before it reached the device pixel level.
2989 * platform/graphics/GraphicsContext.h:
2990 * platform/graphics/skia/GraphicsContextSkia.cpp:
2991 (WebCore::GraphicsContext::drawRect):
2992 (WebCore::GraphicsContext::fillRect):
2993 * platform/graphics/skia/PlatformContextSkia.cpp:
2994 (PlatformContextSkia::drawRect):
2995 (PlatformContextSkia::setupPaintForStroking):
2997 2009-03-13 Jian Li <jianli@chromium.org>
2999 Reviewed by Dimitri Glazkov.
3001 https://bugs.webkit.org/show_bug.cgi?id=24583
3002 Need to change scope of constructor and destructor of V8ObjectEventListener from private
3003 to protected so that they could be used in its derived class V8WorkerContextEventListener.
3005 * bindings/v8/V8ObjectEventListener.h:
3007 2009-03-13 David Levin <levin@chromium.org>
3009 Reviewed by Dimitri Glazkov.
3011 https://bugs.webkit.org/show_bug.cgi?id=24579
3012 Many V8*Event* files are misplaced.
3014 This code is infrastructure for supporting the bindings and thus should
3015 be in the bindings/v8 directory.
3017 * bindings/v8/V8AbstractEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8AbstractEventListener.cpp.
3018 * bindings/v8/V8AbstractEventListener.h: Renamed from WebCore/bindings/v8/custom/V8AbstractEventListener.h.
3019 * bindings/v8/V8LazyEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8LazyEventListener.cpp.
3020 * bindings/v8/V8LazyEventListener.h: Renamed from WebCore/bindings/v8/custom/V8LazyEventListener.h.
3021 * bindings/v8/V8ObjectEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8ObjectEventListener.cpp.
3022 * bindings/v8/V8ObjectEventListener.h: Renamed from WebCore/bindings/v8/custom/V8ObjectEventListener.h.
3023 * bindings/v8/V8WorkerContextEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8WorkerContextEventListener.cpp.
3024 * bindings/v8/V8WorkerContextEventListener.h: Renamed from WebCore/bindings/v8/custom/V8WorkerContextEventListener.h.
3026 2009-03-13 Adele Peterson <adele@apple.com>
3028 Reviewed by Justin Garcia.
3030 Fix for <rdar://problem/5089327> Color of quoted content is wrong when pasted inside other quoted content
3032 Test: editing/pasteboard/5089327.html
3034 Handle spans being pasted within a quoted region in the same way we handle "paste as quotation" content.
3036 * editing/ReplaceSelectionCommand.cpp:
3037 (WebCore::handleStyleSpansBeforeInsertion):
3038 (WebCore::ReplaceSelectionCommand::handleStyleSpans):
3040 2009-03-13 Greg Bolsinga <bolsinga@apple.com>
3042 Reviewed by Simon Fraser.
3044 Update Geolocation perimission dialogs to be asynchronous.
3045 https://bugs.webkit.org/show_bug.cgi?id=24505
3047 Geolocation now requests permission from the Chrome asynchronously.
3048 The Chrome is passed the Geolocation object, and the Chrome sets the permission
3049 on the Geolocation. Geolocation also tracks if the Chrome should clear its cache
3050 of SecurityOrigins with geolocation permission. This is so that the GeolocationService
3051 can inform the Chrome of its request, and the Chrome is also free to implement its
3055 * WebCore.xcodeproj/project.pbxproj:
3057 (WebCore::Chrome::requestGeolocationPermissionForFrame):
3059 * page/ChromeClient.h:
3060 (WebCore::ChromeClient::requestGeolocationPermissionForFrame):
3061 * page/Geolocation.cpp:
3062 (WebCore::Geolocation::Geolocation):
3063 (WebCore::Geolocation::getCurrentPosition):
3064 (WebCore::Geolocation::watchPosition):
3065 (WebCore::Geolocation::setIsAllowed):
3066 (WebCore::Geolocation::displayChallengeIfNecessary):
3067 (WebCore::Geolocation::geolocationServicePositionChanged):
3068 * page/Geolocation.h:
3069 (WebCore::Geolocation::isAllowed):
3070 (WebCore::Geolocation::setShouldClearCache):
3071 (WebCore::Geolocation::shouldClearCache):
3072 (WebCore::Geolocation::):
3074 2009-03-13 Anders Carlsson <andersca@apple.com>
3076 Reviewed by Dan Bernstein.
3078 <rdar://problem/6610666> Revise the Cocoa event model text API
3080 Add a NPCocoaEventTextInput event type. Remove the text input variables.
3085 2009-03-13 Kevin Decker <kdecker@apple.com>
3089 <rdar://problem/6630340> REGRESSION (39114-39115): Unity Web Player no longer works if Flip4Mac is also installed
3091 The code assumed if we have a plug-in that supports "application/x-oleobject" we should always prefer the object tag
3092 over of an embed tag. That assumption can cause the Mac platform to load the wrong plug-in, as Flip4Mac claims supports
3095 * rendering/RenderPartObject.cpp:
3096 (WebCore::shouldUseEmbedDescendant): Made the Mac platform always return true here.
3098 2009-03-13 Jian Li <jianli@chromium.org>
3100 Reviewed by Dimitri Glazkov.
3102 https://bugs.webkit.org/show_bug.cgi?id=24559
3103 Need to port JSC fix (r41565) to V8 in order to fix layout test onload-single-line-comment.html.
3105 * bindings/v8/custom/V8LazyEventListener.cpp:
3106 (WebCore::V8LazyEventListener::getListenerFunction):
3107 (WebCore::V8LazyEventListener::getWrappedListenerFunction):
3109 2009-03-13 Jian Li <jianli@chromium.org>
3111 Reviewed by Dimitri Glazkov.
3113 https://bugs.webkit.org/show_bug.cgi?id=24557
3114 This is to support running multiple workers in a single worker process in chromium.
3116 * bindings/v8/custom/V8WorkerContextEventListener.cpp:
3117 (WebCore::V8WorkerContextEventListener::handleEvent):
3118 Add locker to v8 event listener of worker context.
3120 2009-03-13 Alexey Proskuryakov <ap@webkit.org>
3122 Reviewed by Sam Weinig.
3124 https://bugs.webkit.org/show_bug.cgi?id=24575
3125 XHR response is incorrect after a network error.
3127 Tests: http/tests/xmlhttprequest/cross-site-denied-response-sync-2.html
3128 http/tests/xmlhttprequest/cross-site-denied-response-sync.html
3129 http/tests/xmlhttprequest/cross-site-denied-response.html
3131 * xml/XMLHttpRequest.cpp:
3132 (WebCore::XMLHttpRequest::networkError): Call internalAbort() to fully reset the request.
3133 (WebCore::XMLHttpRequest::didFailRedirectCheck): No need to call internalAbort() here. Note
3134 that since internalAbort() can drop GC protection, it is not safe to use the object after
3136 (WebCore::XMLHttpRequest::didReceiveData): Check that the request wasn't aborted, and
3137 return early if it was. This can happen during sync requests, as the loader does not know
3138 that it was aborted, and just synthesizes all callbacks.
3140 2009-03-13 Adam Bergkvist <adam.bergkvist@ericsson.com>
3142 Reviewed by Alexey Proskuryakov.
3144 https://bugs.webkit.org/show_bug.cgi?id=3547
3145 XMLHttpRequest.statusText returns always "OK"
3147 Covered by existing tests (which now pass on all platforms but Mac).
3149 * xml/XMLHttpRequest.cpp:
3150 (WebCore::XMLHttpRequest::statusText): Return ResourceResponse status text. It is now up
3151 to each platform to correctly set the status text or set it to "OK" to retain current
3154 2009-03-13 Adam Bergkvist <adam.bergkvist@ericsson.com>
3156 Reviewed by Alexey Proskuryakov.
3158 https://bugs.webkit.org/show_bug.cgi?id=24349
3159 [QT] HTTP status text is never set
3161 Set HTTP status text to the reason phrase attribute of QNetworkReply.
3163 * platform/network/qt/QNetworkReplyHandler.cpp:
3164 (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
3166 2009-03-12 Simon Fraser <simon.fraser@apple.com>
3168 Reviewed by Mark Rowe
3170 <rdar://problem/6622300>: Reproducible crash on
3171 <http://www.editgrid.com/explore/tnc/dave/FusionChart%3A_Candlestick>
3173 Prevent CSSStyleSheet::checkLoaded() writing to freed memory when it gets
3174 deleted from under itself. The sheetLoaded() notification can allow scripts
3175 to run via HTMLTokenizer::executeScriptsWaitingForStylesheets(),
3176 which can cause the last ref to the CSSStyleSheet to be released.
3178 * css/CSSStyleSheet.cpp:
3179 (WebCore::CSSStyleSheet::checkLoaded):
3181 2009-03-12 Kevin Ollivier <kevino@theolliviers.com>
3183 wx build fix. Allow make-generated-sources.sh to pass args down to DerivedSources.make
3185 * make-generated-sources.sh:
3187 2009-03-12 Adam Treat <adam.treat@torchmobile.com>
3189 Reviewed by Oliver Hunt.
3191 https://bugs.webkit.org/show_bug.cgi?id=24498
3192 Fix the Qt port to use the same algorithm for drawing dashed and dotted
3193 borders as the other ports. This makes the Qt port pixel-for-pixel perfect
3194 compared to border drawing with Apple's canonical mac port and much closer
3195 to konqueror and firefox behavior.
3197 * platform/graphics/qt/GraphicsContextQt.cpp:
3198 (WebCore::GraphicsContext::drawLine):
3200 2009-02-26 Eric Seidel <eric@webkit.org>
3202 Reviewed by Justin Garcia.
3204 Clean up DOMSelection to use some helper functions
3205 making the code smaller, and less error-prone.
3206 https://bugs.webkit.org/show_bug.cgi?id=19221
3208 I tried moving DOMSelection off of rangeCompliantEquivalent
3209 but failed. VisibleSelection holds positions like (table, 1) to mean
3212 * page/DOMSelection.cpp:
3213 (WebCore::DOMSelection::visibleSelection):
3214 (WebCore::anchorPosition):
3215 (WebCore::focusPosition):
3216 (WebCore::basePosition):
3217 (WebCore::extentPosition):
3218 (WebCore::DOMSelection::anchorNode):
3219 (WebCore::DOMSelection::anchorOffset):
3220 (WebCore::DOMSelection::focusNode):
3221 (WebCore::DOMSelection::focusOffset):
3222 (WebCore::DOMSelection::baseNode):
3223 (WebCore::DOMSelection::baseOffset):
3224 (WebCore::DOMSelection::extentNode):
3225 (WebCore::DOMSelection::extentOffset):
3226 * page/DOMSelection.h:
3228 2009-03-12 Dmitry Titov <dimich@chromium.org>
3230 Reviewed by Dimitri Glazkov.
3232 https://bugs.webkit.org/show_bug.cgi?id=24563
3233 Change ResourceRequest to be a struct rather then a class to match other declarations.
3235 * platform/network/chromium/ResourceRequest.h:
3237 2009-03-12 David Levin <levin@chromium.org>
3239 Reviewed by Darin Fisher.
3241 Bug 24530: width100percent-searchfield.html should be fixed for chromium.
3242 <https://bugs.webkit.org/show_bug.cgi?id=24530>
3244 Compensate for r39924 in chromium, which broke LayoutTests/fast/replaced/width100percent-searchfield.html
3246 * css/themeChromiumWin.css: Added.
3247 Overrides the changes to start supporting input[type="search"] on Windows (since
3248 Chromium doesn't do anything special for this).
3250 * rendering/RenderThemeChromiumWin.cpp:
3251 (WebCore::supportsFocus):
3252 (WebCore::RenderThemeChromiumWin::extraDefaultStyleSheet):
3253 (WebCore::RenderThemeChromiumWin::determineState):
3254 (WebCore::RenderThemeChromiumWin::getThemeData):
3256 2009-03-12 Greg Bolsinga <bolsinga@apple.com>
3258 Reviewed by Antti Koivisto.
3260 https://bugs.webkit.org/show_bug.cgi?id=24506
3261 Geolocation in Safari differs from the spec, no Coordinates attribute on Position
3265 * DerivedSources.make:
3269 * WebCore.vcproj/WebCore.vcproj:
3270 * WebCore.xcodeproj/project.pbxproj:
3271 * WebCoreSources.bkl:
3272 * bindings/js/JSGeolocationCustom.cpp:
3273 (WebCore::createPositionOptions):
3274 * page/Coordinates.cpp: Added.
3275 (WebCore::Coordinates::toString):
3276 * page/Coordinates.h: Added.
3277 (WebCore::Coordinates::create):
3278 (WebCore::Coordinates::latitude):
3279 (WebCore::Coordinates::longitude):
3280 (WebCore::Coordinates::altitude):
3281 (WebCore::Coordinates::accuracy):
3282 (WebCore::Coordinates::altitudeAccuracy):
3283 (WebCore::Coordinates::heading):
3284 (WebCore::Coordinates::speed):
3285 (WebCore::Coordinates::Coordinates):
3286 * page/Coordinates.idl: Added.
3287 * page/Geoposition.cpp:
3288 (WebCore::Geoposition::toString):
3289 * page/Geoposition.h:
3290 (WebCore::Geoposition::create):
3291 (WebCore::Geoposition::coords):
3292 (WebCore::Geoposition::Geoposition):
3293 * page/Geoposition.idl:
3294 * page/PositionOptions.h:
3295 (WebCore::PositionOptions::create):
3296 (WebCore::PositionOptions::maximumAge):
3297 (WebCore::PositionOptions::setMaximumAge):
3298 (WebCore::PositionOptions::PositionOptions):
3299 * platform/mac/GeolocationServiceMac.mm:
3300 (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
3302 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
3304 Reviewed by Darin Fisher.
3306 https://bugs.webkit.org/show_bug.cgi?id=24496
3307 Fix console logging of non-string values by coercing the argument to
3308 a string, for V8 bindings.
3310 Test: fast/js/console-non-string-values.html
3312 * bindings/v8/ScriptValue.cpp: Added toString method.
3313 (WebCore::ScriptValue::toString):
3314 * bindings/v8/ScriptValue.h: Added PlatformString, ScriptState includes
3315 and toString declaration.
3317 2009-03-12 Darin Fisher <darin@chromium.org>
3319 Reviewed by Dimitri Glazkov.
3321 Eliminate ChromiumBridge::uiResourceProtocol
3322 https://bugs.webkit.org/show_bug.cgi?id=24558
3324 * platform/chromium/ChromiumBridge.h:
3326 2009-03-12 Greg Bolsinga <bolsinga@apple.com>
3328 Reviewed by Simon Fraser.
3330 Missing breaks in switch statement
3331 https://bugs.webkit.org/show_bug.cgi?id=24556
3333 * platform/mac/GeolocationServiceMac.mm:
3334 (-[WebCoreCoreLocationObserver locationManager:didFailWithError:]):
3336 2009-03-12 Darin Fisher <darin@chromium.org>
3338 Reviewed by Dimitri Glazkov.
3340 https://bugs.webkit.org/show_bug.cgi?id=24554
3341 Remove some unused functions from ChromiumBridge.
3343 * platform/chromium/ChromiumBridge.h:
3345 2009-03-02 Eric Seidel <eric@webkit.org>
3347 Reviewed by Darin Fisher and Justin Garcia.
3349 Safari crashes during drag and drop in Google presentations
3350 due to mutation event handlers removing DOM content during insertNode
3351 https://bugs.webkit.org/show_bug.cgi?id=22634
3353 Added a bunch of "null" checks to make sure nodes are still
3354 in the document before we operate on them. This is an
3355 inelegant solution, but it's the best we have for now.
3357 Test: editing/selection/crash-on-drag-with-mutation-events.html
3359 * editing/CompositeEditCommand.cpp:
3360 (WebCore::CompositeEditCommand::insertNodeAt):
3361 * editing/ReplaceSelectionCommand.cpp:
3362 (WebCore::ReplaceSelectionCommand::doApply):
3364 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
3366 Reviewed by Adam Treat.
3368 https://bugs.webkit.org/show_bug.cgi?id=24525
3369 REGRESSION: Inspector window doesn't close when inspected page is
3370 destroyed. This is a revert of r41158, which became unnecessary when
3371 InspectorController became ref-counted in r41462.
3373 * inspector/InspectorController.cpp:
3374 (WebCore::InspectorController::inspectedPageDestroyed): Reset m_inspectedPage
3375 after calling close().
3376 (WebCore::InspectorController::stopUserInitiatedProfiling): Remove
3377 m_inspectedPage check guard around profile logic.
3379 2009-03-12 Peter Kasting <pkasting@google.com>
3381 Reviewed by Darin Fisher.
3383 https://bugs.webkit.org/show_bug.cgi?id=24502
3384 Make horizontal scrolling on Windows always go the correct direction.
3386 * platform/PlatformWheelEvent.h:
3387 * platform/win/WheelEventWin.cpp:
3388 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
3390 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
3392 Reviewed by Simon Fraser.
3394 https://bugs.webkit.org/show_bug.cgi?id=24496
3395 Fix console logging of non-string values by coercing the argument to
3398 Test: fast/js/console-non-string-values.html
3400 * bindings/js/ScriptValue.cpp: Removed PlatformString include.
3401 * bindings/js/ScriptValue.h: Added toString method.
3402 (WebCore::ScriptValue::toString):
3404 (WebCore::getFirstArgumentAsString): Changed firstArgumentAsString method to use
3405 ScriptValue::toString.
3406 (WebCore::Console::addMessage): added extra ScriptState argument to callsite.
3407 (WebCore::Console::count): Ditto.
3409 2009-03-12 Simon Fraser <simon.fraser@apple.com>
3411 Reviewed by Adele Peterson.
3413 https://bugs.webkit.org/show_bug.cgi?id=24508
3415 Fix updating of text field with placeholder text when value is set
3416 by ensuring that updatePlaceholderVisibility() is called after
3417 the value has been updated, not before.
3419 Test: fast/forms/placeholder-set-value.html
3421 * html/HTMLInputElement.cpp:
3422 (WebCore::HTMLInputElement::setValue):
3424 2009-03-12 Simon Fraser <simon.fraser@apple.com>
3426 Reviewed by Dave Hyatt
3428 https://bugs.webkit.org/show_bug.cgi?id=24552
3430 Hit testing involving normal flow, self-painting layers (e.g. reflections)
3431 was broken because it was not null-testing the result of hitTestLayer(),
3432 so bailing early with a nil hit layer.
3434 Test: fast/layers/normal-flow-hit-test.html
3436 * rendering/RenderLayer.cpp:
3437 (WebCore::RenderLayer::hitTestLayer):
3439 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
3441 Reviewed by Cameron Zwarich.
3443 Removed zero-sized files, left over from improperly applied patch.
3445 * platform/graphics/chromium/ThemeHelperChromiumWin.cpp: Removed.
3446 * platform/graphics/chromium/ThemeHelperChromiumWin.h: Removed.
3448 2009-03-12 Adam Treat <adam.treat@torchmobile.com>
3450 Reviewed by George Staikos.
3452 Do not ignore alpha color in optimization. Hard to believe, but there
3453 are websites that fill the entire page with a tiled image consisting of
3454 nothing but a 100% transparent 1x1 image. <cough>orbitz.com</cough>
3456 * platform/graphics/qt/ImageQt.cpp:
3457 (WebCore::BitmapImage::checkForSolidColor):
3459 2009-03-12 Julien Chaffraix <jchaffraix@webkit.org>
3461 Reviewed by Darin Adler.
3463 Bug 24110: cloneNode should call cloneElement and not the reverse
3465 - Splitted the code from cloneNode into cloneElementWithChildren and cloneElementWithChildren.
3466 Now cloneNode calls one of the 2 previous methods.
3468 - Renamed cloneElement to cloneElementWithoutChildren as it was the previous behaviour.
3470 - Moved cloneNode to the Element private section so that WebCore callers cannot use it.
3472 - Removed Element::cloneNode usage through WebCore.
3475 (WebCore::Element::cloneNode): Moved to Element's private section and it
3476 now calls the two next methods.
3477 (WebCore::Element::cloneElementWithChildren): Added.
3478 (WebCore::Element::cloneElementWithoutChildren): Renamed from cloneElement
3482 * editing/ApplyStyleCommand.cpp:
3483 (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded): Changed call to cloneElement
3484 to call to cloneElementWithoutChildren.
3485 * editing/BreakBlockquoteCommand.cpp:
3486 (WebCore::BreakBlockquoteCommand::doApply): Ditto.
3487 * editing/IndentOutdentCommand.cpp:
3488 (WebCore::IndentOutdentCommand::indentRegion): Ditto.
3489 * editing/InsertParagraphSeparatorCommand.cpp:
3490 (WebCore::InsertParagraphSeparatorCommand::doApply): Ditto.
3491 * editing/ModifySelectionListLevel.cpp:
3492 (WebCore::IncreaseSelectionListLevelCommand::doApply): Ditto.
3493 * editing/SplitElementCommand.cpp:
3494 (WebCore::SplitElementCommand::doApply): Ditto.
3495 * editing/markup.cpp:
3496 (WebCore::createFragmentFromText): Ditto.
3497 * svg/SVGUseElement.cpp:
3498 (WebCore::SVGUseElement::buildShadowTree): Ditto.
3499 (WebCore::SVGUseElement::expandUseElementsInShadowTree): Ditto.
3501 2009-03-12 Dirk Schulze <krit@webkit.org>
3503 Reviewed by Oliver Hunt.
3505 Fixed a crash on the 1x1 pixel check for background image in gtk.
3506 We need to load the image first and need to be sure that the image
3507 is not null before checking the type.
3509 * platform/graphics/cairo/ImageCairo.cpp:
3510 (WebCore::BitmapImage::checkForSolidColor):
3512 2009-03-12 Xan Lopez <xlopez@igalia.com>
3514 Reviewed by Alexey Proskuryakov.
3516 https://bugs.webkit.org/show_bug.cgi?id=24544
3517 Rename setUrl to setURL
3519 Use proper case for setUrl method, rename it to setURL.
3521 * platform/network/ResourceResponseBase.cpp:
3522 (WebCore::ResourceResponseBase::adopt):
3523 * platform/network/ResourceResponseBase.h:
3524 * platform/network/curl/ResourceHandleManager.cpp:
3525 (WebCore::writeCallback):
3526 (WebCore::headerCallback):
3527 * platform/network/soup/ResourceHandleSoup.cpp:
3528 (WebCore::fillResponseFromMessage):
3529 (WebCore::queryInfoCallback):
3531 2009-03-12 Xan Lopez <xlopez@igalia.com>
3533 Reviewed by Alexey Proskuryakov.
3535 https://bugs.webkit.org/show_bug.cgi?id=24519
3536 [GTK] Use two argument KURL ctor in ResourceHandleSoup
3538 Use two argument KURL ctor, the single argument ctor expects its
3539 input to be the output of a previous KURL::parse call, which is
3542 * platform/network/soup/ResourceHandleSoup.cpp:
3543 (WebCore::fillResponseFromMessage):
3544 (WebCore::queryInfoCallback):
3546 2009-03-11 Jon Honeycutt <jhoneycutt@apple.com>
3548 Fix for <rdar://6418681>
3549 https://bugs.webkit.org/show_bug.cgi?id=22644
3551 Reviewed by Steve Falkenburg.
3553 * plugins/win/PluginPackageWin.cpp:
3554 (WebCore::PluginPackage::isPluginBlacklisted): Add the Citrix ICA
3555 Client plug-in to the blacklist; it requires a Mozilla-based browser.
3557 2009-03-12 Oliver Hunt <oliver@apple.com>
3559 Reviewed by NOBODY (build fix).