1 2009-03-17 Darin Adler <darin@apple.com>
3 Reviewed by Adele Peterson.
5 <rdar://problem/6687005> Need support for new move-left/right selectors.
7 * editing/EditorCommand.cpp:
8 (WebCore::executeMoveToLeftEndOfLine): Added.
9 (WebCore::executeMoveToLeftEndOfLineAndModifySelection): Added.
10 (WebCore::executeMoveToRightEndOfLine): Added.
11 (WebCore::executeMoveToRightEndOfLineAndModifySelection): Added.
12 Added command entries for the functions above.
14 2009-03-17 Ojan Vafai <ojan@chromium.org>
16 Reviewed by Adele Peterson.
18 Put the padding inside scrollbars on textareas.
19 https://bugs.webkit.org/show_bug.cgi?id=24370
21 Put the padding inside the scrollbars on textareas. This is done by moving the
22 overflow from the shadowNode to the RenderTextControlMultiline. As a result,
23 all of the scroll handing methods that RenderTextControl overrides can be moved
24 down into RenderTextControlSingleLine since RenderTextControlMultiline can now
25 just use RenderBlock's versions. This also allows RenderTextControlMultiLine to
26 no longer need a custom layout method since the shadowNode can now just size
29 * css/CSSStyleSelector.cpp:
30 (WebCore::CSSStyleSelector::adjustRenderStyle):
31 * rendering/RenderTextControl.cpp:
32 (WebCore::RenderTextControl::styleDidChange):
33 (WebCore::RenderTextControl::selection):
34 (WebCore::RenderTextControl::calcHeight):
35 (WebCore::RenderTextControl::hitInnerTextElement):
36 * rendering/RenderTextControl.h:
37 * rendering/RenderTextControlMultiLine.cpp:
38 (WebCore::RenderTextControlMultiLine::nodeAtPoint):
39 (WebCore::RenderTextControlMultiLine::createInnerTextStyle):
40 * rendering/RenderTextControlMultiLine.h:
41 * rendering/RenderTextControlSingleLine.cpp:
42 (WebCore::RenderTextControlSingleLine::styleDidChange):
43 (WebCore::RenderTextControlSingleLine::autoscroll):
44 (WebCore::RenderTextControlSingleLine::scrollWidth):
45 (WebCore::RenderTextControlSingleLine::scrollHeight):
46 (WebCore::RenderTextControlSingleLine::scrollLeft):
47 (WebCore::RenderTextControlSingleLine::scrollTop):
48 (WebCore::RenderTextControlSingleLine::setScrollLeft):
49 (WebCore::RenderTextControlSingleLine::setScrollTop):
50 (WebCore::RenderTextControlSingleLine::scroll):
51 * rendering/RenderTextControlSingleLine.h:
52 * rendering/TextControlInnerElements.cpp:
53 (WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock):
54 (WebCore::RenderTextControlInnerBlock::positionForPoint):
55 (WebCore::TextControlInnerTextElement::createRenderer):
57 2009-03-17 Darin Adler <darin@apple.com>
59 Reviewed by David Hyatt.
61 Bug 24517: REGRESSION (r41552): innerHTML does an updateLayout -- unneeded and can be slow
62 https://bugs.webkit.org/show_bug.cgi?id=24517
64 * editing/DeleteButtonController.cpp:
65 (WebCore::DeleteButtonController::enable): Added a call to updateRendering, since
66 determining whether to display the delete button involves style and updateRendering
67 also updates style (should probably be named updateStyle, in fact). Not needed to fix
68 this bug, but would have prevented the crash that led to this bug in the first place.
70 * editing/EditCommand.cpp:
71 (WebCore::EditCommand::EditCommand): Get rid of unneeded null check. All frames have
72 delete button controllers.
74 (WebCore::Editor::rangeForPoint): Ditto.
77 (WebCore::appendStartMarkup): Changed a "&" to a "&&" so that generating markup
78 doesn't depend on renderers at all when the convertBlocksToInlines boolean is false.
79 This allows us to omit the call to updateLayoutIgnorePendingStylesheets in the
80 createMarkup function that's called by innerHTML.
81 (WebCore::MarkupAccumulator::appendMarkup): Turned this into a class with a member
82 function. Added a feature where the accumulator will skip a node. Moved arguments
83 that don't change during recursion into an object. This function still is a bit
84 inefficient, since it creates a new HashMap at every level as it recurses, but for now
85 I did not tackle that. Also replaced the onlyIncludeChildren boolean with EChildrenOnly
86 for consistency and clarity.
87 (WebCore::createMarkup): Removed the call to updateLayoutIgnorePendingStylesheets.
88 Instead of calling disable/enable on the delete button controller's container element,
89 pass it in to the markup accumulator as a node to skip.
91 2009-03-17 Scott Violet <sky@google.com>
93 Reviewed by Eric Seidel.
95 https://bugs.webkit.org/show_bug.cgi?id=24651
96 Skia does not always render text fill/stroke pattern/gradient/color correctly
98 Changes Skia's font rendering to only render gradient/pattern if current
99 color space indicates the gradient/pattern should be used.
100 This is covered by LayoutTests/fast/canvas/canvas-text-alignment.html .
102 * platform/graphics/GraphicsContext.cpp:
103 (WebCore::GraphicsContext::strokeColorSpace):
104 (WebCore::GraphicsContext::fillColorSpace):
105 * platform/graphics/GraphicsContext.h:
107 * platform/graphics/GraphicsContextPrivate.h:
108 * platform/graphics/skia/SkiaFontWin.cpp:
109 (WebCore::paintSkiaText):
111 2009-03-17 Adele Peterson <adele@apple.com>
113 Reviewed by Darin Adler.
115 Fix for https://bugs.webkit.org/show_bug.cgi?id=24655
116 <rdar://problem/6633727> Hitting return at the end of a line with an anchor jumps me to the bottom of the message
118 Test: editing/inserting/6633727.html
120 This changes does a few things:
121 1) Renames pos to insertionPosition.
122 2) Eliminates "startNode". It doesn't work well to consider the node separately from the insertionPosition.
123 The insertionPosition gets updated at various times, and it seems likely that startNode can get out of sync.
124 3) Before building up a list of ancestors to move around when we insert the new block, make sure to use the deepest
125 representation of the insertionPosition, so all ancestor nodes are correctly included.
127 * editing/InsertParagraphSeparatorCommand.cpp: (WebCore::InsertParagraphSeparatorCommand::doApply):
129 2009-03-17 Laszlo Gombos <laszlo.1.gombos@nokia.com>
131 Reviewed by Kevin Ollivier.
133 https://bugs.webkit.org/show_bug.cgi?id=24115
134 Introduce platform independent stubs for plugins.
136 * plugins/PluginDataNone.cpp: Copied from WebCore/plugins/wx/PluginDataWx.cpp.
137 * plugins/PluginPackageNone.cpp: Copied from WebCore/plugins/wx/PluginPackageWx.cpp.
138 * plugins/PluginViewNone.cpp: Copied from WebCore/plugins/wx/PluginViewWx.cpp.
139 * plugins/wx/PluginDataWx.cpp: Removed.
140 * plugins/wx/PluginPackageWx.cpp: Removed.
141 * plugins/wx/PluginViewWx.cpp: Removed.
144 2009-03-17 Darin Adler <darin@apple.com>
146 Earlier version reviewed by Adele Peterson.
148 Bug 24304: REGRESSION (r39864): Hitting the space bar to select an <input type=radio>
149 or push an <input type=button> or <button> causes the page to scroll down.
151 Would be best to add a regression test for Windows eventually; tested that this has
152 no effect on the Mac OS X platform.
154 * html/HTMLInputElement.cpp:
155 (WebCore::HTMLInputElement::defaultEventHandler): Added FIXMEs and tweaked formatting.
156 Use the code that calls the base class's defaultEventHandler early only in the cases
157 where it's needed: keydown and keypress events in text fields. In other cases, do the
158 more typical thing and call the default handler only at the end of the function.
159 This function already had code to make sure the keypress event for space never gets
160 through, but it was running too late since the scrolling code was moved into the
161 base class default event handler.
163 2009-03-17 Simon Fraser <simon.fraser@apple.com>
165 Reviewed by Dave Hyatt
167 https://bugs.webkit.org/show_bug.cgi?id=24632
169 Fix repaint issues when composited layers come and go (only applies
170 when ACCELERATED_COMPOSITING is turned on).
172 * rendering/RenderLayer.cpp:
173 (WebCore::RenderLayer::RenderLayer):
174 * rendering/RenderLayer.h:
175 (WebCore::RenderLayer::mustOverlayCompositedLayers):
176 (WebCore::RenderLayer::setMustOverlayCompositedLayers):
177 * rendering/RenderLayerBacking.cpp:
178 (WebCore::RenderLayerBacking::RenderLayerBacking):
179 * rendering/RenderLayerBacking.h:
181 Move what used to be the 'forceCompositingLayer' flag from RenderLayerBacking
182 to RenderLayer, because we don't want the side-effects of creating RenderLayerBacking
183 when setting this flag.
185 * rendering/RenderLayerCompositor.cpp:
186 (WebCore::RenderLayerCompositor::updateLayerCompositingState):
187 When a RenderLayer flips into or out of compositing mode, compute a repaint
188 rect relative to the containerForRepaint, and repaint it.
190 (WebCore::RenderLayerCompositor::computeCompositingRequirements):
191 Call layer->setMustOverlayCompositedLayers() rather than setForcedCompositingLayer().
193 (WebCore::RenderLayerCompositor::needsToBeComposited):
194 (WebCore::RenderLayerCompositor::requiresCompositingLayer):
195 (WebCore::RenderLayerCompositor::requiresCompositingForTransform):
196 (WebCore::RenderLayerCompositor::requiresCompositingForAnimation):
197 * rendering/RenderLayerCompositor.h:
199 Rename requiresCompositingLayerForTransform() to requiresCompositingForTransform()
200 and make it a class static method to match requiresCompositingForAnimation(). Both
201 now take RenderObjects, rathern than RenderLayers.
203 * rendering/style/RenderStyle.h:
204 (WebCore::InheritedFlags::hasTransformRelatedProperty):
205 Minor tidyup using convenience methods added in an earlier commit.
207 2009-03-17 Simon Fraser <simon.fraser@apple.com>
209 Reviewed by Darin Adler
211 https://bugs.webkit.org/show_bug.cgi?id=24396
214 Add WTF_USE_ACCELERATED_COMPOSITING, defined to 0 for now, and add some
215 comments to make the #ifdefs more readable.
217 * css/CSSComputedStyleDeclaration.cpp:
218 (WebCore::computedTransform):
219 Add a comment to mention that we don't flatten the matrix.
221 * css/MediaQueryEvaluator.cpp:
222 (WebCore::transform_3dMediaFeatureEval):
223 Have the 'transform-3d' media query evaluate to 'true' if 3d-rendering
226 * platform/graphics/mac/GraphicsLayerCA.mm:
227 (WebCore::GraphicsLayerCA::animateTransform):
228 No need for the #ifdef here. If we don't support 3d, we will have already flattened
231 * platform/graphics/transforms/TransformationMatrix.cpp:
232 (WebCore::TransformationMatrix::makeAffine):
233 * platform/graphics/transforms/TransformationMatrix.h:
234 New method to convert the matrix to an affine matrix by throwing a way the non-affine
237 * rendering/RenderLayer.cpp:
238 (WebCore::RenderLayer::updateTransform):
239 (WebCore::RenderLayer::currentTransform):
240 * rendering/RenderLayerBacking.cpp:
241 (WebCore::RenderLayerBacking::updateLayerTransform):
242 If 3d rendering is not supported, convert the matrix to an affine matrix
243 which can be rendered, and used for hit testing.
245 * rendering/RenderLayerCompositor.cpp:
246 Change the name of the exported symbol that webkitdirs.pm uses to know if
247 3d rendering is supported. There is no other 3d-rendering-specific symbol we can sniff.
249 * rendering/RenderObject.cpp:
250 (WebCore::RenderObject::transformFromContainer):
251 Only take perspective into account if 3d rendering is supported.
253 * rendering/RenderObject.h:
254 (WebCore::makeMatrixRenderable):
255 Utility method that flattens a matrix if 3d rendering is not supported.
257 2009-03-17 Kevin Ollivier <kevino@theolliviers.com>
259 wx build fix. Fix typo after mouse wheel changes.
261 * platform/wx/MouseWheelEventWx.cpp:
262 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
264 2009-03-17 Darin Adler <darin@apple.com>
266 * inspector/ConsoleMessage.cpp:
267 (WebCore::ConsoleMessage::isEqual): Fix build, remove stray parenthesis.
269 2009-03-17 Darin Adler <darin@apple.com>
271 Fix crash seen right away when running run-webkit-tests.
273 * inspector/ConsoleMessage.cpp:
274 (WebCore::ConsoleMessage::isEqual): Restore assertion to its behavior pre-refactoring.
275 Also tweaked formatting a bit.
277 2009-03-17 Alexey Proskuryakov <ap@webkit.org>
279 Reviewed by Darin Adler.
281 HTMLSelectElement::add() doesn't look at exception code returned from insertBefore(), so
282 it doesn't need to zero it out before calling.
284 * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::add): Removed "ec = 0" line.
286 2009-03-17 Dan Bernstein <mitz@apple.com>
288 Reviewed by Adam Roben.
290 - WebCore part of adding a mechanism for controlling the caching of
291 responses through WebFrameLoaderClient
293 Mac already has such a mechanism, and this adds one for CFNetwork ports.
295 * WebCore.vcproj/WebCore.vcproj: Added EmptyClients.h
296 and ResourceLoaderCFNet.cpp.
298 * loader/EmptyClients.h:
299 (WebCore::EmptyFrameLoaderClient::shouldCacheResponse): Added an
300 implementation that always returns true.
302 * loader/FrameLoaderClient.h: Declared shouldCacheResponse().
304 * loader/ResourceLoader.h: Ditto.
306 * loader/cf/ResourceLoaderCFNet.cpp: Added.
307 (WebCore::ResourceLoader::shouldCacheResponse): Added. Calls through to
308 FrameLoaderClient::shouldCacheResponse().
310 * platform/network/ResourceHandleClient.h:
311 (WebCore::ResourceHandleClient::shouldCacheResponse): Added an
312 implementation that always returns true.
314 * platform/network/cf/ResourceHandleCFNet.cpp:
315 (WebCore::willCacheResponse): Added a call to
316 ResourceHandleClient::shouldCacheResponse(). If the client returns
317 false, return 0, which will prevent CFNetwork from caching the response.
319 2009-03-17 Alexey Proskuryakov <ap@webkit.org>
321 Reviewed by Darin Adler.
323 https://bugs.webkit.org/show_bug.cgi?id=13287
324 Cannot change SELECT to a dynamically created option
326 Tests: fast/forms/add-and-remove-option.html
327 fast/forms/add-remove-option-modification-event.html
328 fast/forms/add-selected-option.html
329 fast/forms/select-cache-desynchronization.html
331 * dom/ContainerNode.cpp:
332 (WebCore::dispatchChildInsertionEvents): Increment DOM tree version. This will happen when
333 dispatching DOMSubtreeModified again, but the version should be incremented for event
334 listeners to have an up to date view of the DOM.
335 (WebCore::dispatchChildRemovalEvents): Ditto.
337 * html/HTMLOptionElement.cpp: (WebCore::HTMLOptionElement::insertedIntoTree):
338 Make sure that the select element knows about its new selected option.
340 * html/HTMLOptionElement.h: Use insertedIntoTree() instead of insertedIntoDocument(),
341 because DOM also needs to be updated for forms that are not in document yet. Similar
342 problems exist for node removing, but removedFromTree() is called at a wrong time, so
343 those problems cannot be fixed without deeper refactoring.
345 * html/HTMLSelectElement.cpp:
346 (WebCore::HTMLSelectElement::setRecalcListItems): Reset m_activeSelectionAnchorIndex - it
347 doesn't make sense to keep the anchor after programmatically changing the selection, and
348 keeping it was causing a failure in fast/forms/listbox-selection.html.
350 * html/HTMLSelectElement.h: Removed overrides for ContainerNode methods that only called
353 2009-03-17 Steve Falkenburg <sfalken@apple.com>
355 <rdar://problem/6690324> Accessing FTP sites reads unallocated memory, can result in garbled entries or crashes
357 Reviewed by Darin Adler.
359 * loader/FTPDirectoryDocument.cpp:
360 (WebCore::FTPDirectoryTokenizer::parseAndAppendOneLine): Assign CString to a local while we hold pointers into it.
362 2009-03-16 David Hyatt <hyatt@apple.com>
364 <rdar://problem/6648411> REGRESSION: Layout of page is wrong at http://www.popcap.com/
366 Make sure that the initial shouldPaint check that looks at enclosingLayers properly skips over
367 layers that don't paint themselves. This is done by adding a new enclosingSelfPaintingLayer method
368 so that RenderObjects can walk up the enclosing layer chain and skip any layers that don't paint
371 Reviewed by Darin Adler.
373 Added fast/block/float/overlapping-floats-with-overflow-hidden.html
376 * rendering/RenderBlock.cpp:
377 (WebCore::RenderBlock::addOverhangingFloats):
378 * rendering/RenderObject.cpp:
379 (WebCore::RenderObject::enclosingSelfPaintingLayer):
380 * rendering/RenderObject.h:
382 2009-03-17 Xan Lopez <xlopez@igalia.com>
384 Reviewed by Holger Freyther.
386 https://bugs.webkit.org/show_bug.cgi?id=24592
387 [GTK] Crash in FcPatternHash
391 * platform/graphics/gtk/FontPlatformDataGtk.cpp:
392 (WebCore::FontPlatformData::operator=):
393 * platform/graphics/gtk/FontPlatformDataPango.cpp:
395 2009-03-17 Xan Lopez <xlopez@igalia.com>
397 Reviewed by Holger Freyther.
399 https://bugs.webkit.org/show_bug.cgi?id=24592
400 [GTK] Crash in FcPatternHash
402 Sanitize memory management in pango fonts.
404 Release memory allocated by FontPlatformDataPango in its own
405 destructor instead of doing it from other classes, and add copy
406 constructor and '=' operator to be able to track referenced
409 * platform/graphics/gtk/FontPlatformDataPango.cpp:
410 (WebCore::FontPlatformData::~FontPlatformData):
411 (WebCore::FontPlatformData::operator=):
412 (WebCore::FontPlatformData::FontPlatformData):
413 * platform/graphics/gtk/SimpleFontDataPango.cpp:
415 2009-03-17 Darin Adler <darin@apple.com>
417 Reviewed by Alexey Proskuryakov.
419 Bug 24624: Crash in imageLoadEventTimerFired after adoptNode used on <img>,
420 seen with inspector, which uses adoptNode
421 https://bugs.webkit.org/show_bug.cgi?id=24624
422 rdar://problem/6422850
424 Test: fast/dom/HTMLImageElement/image-load-cross-document.html
427 (WebCore::Document::Document): Removed m_imageLoadEventTimer.
428 (WebCore::Document::detach): Removed m_imageLoadEventDispatchSoonList and
429 m_imageLoadEventDispatchingList.
430 (WebCore::Document::implicitClose): Called ImageLoader::dispatchPendingLoadEvents
431 instead of dispatchImageLoadEventsNow.
433 * dom/Document.h: Removed ImageLoader, dispatchImageLoadEventSoon,
434 dispatchImageLoadEventsNow, removeImage, m_imageLoadEventDispatchSoonList,
435 m_imageLoadEventDispatchingList, m_imageLoadEventTimer, and imageLoadEventTimerFired.
437 * loader/ImageLoader.cpp:
438 (WebCore::loadEventSender): Added. Returns the single global ImageLoadEventSender
439 object used privately as the target of the load event timer.
440 (WebCore::ImageLoader::~ImageLoader): Call ImageLoadEventSender::cancelLoadEvent
441 rather than Document::removeImage.
442 (WebCore::ImageLoader::setImage): Use m_element directly, not element().
443 (WebCore::ImageLoader::updateFromElement): Ditto. Also name the local variable
444 document instead of doc.
445 (WebCore::ImageLoader::notifyFinished): Call ImageLoadEventSender::dispatchLoadEventSoon
446 rather than Document::dispatchImageLoadEventSoon.
447 (WebCore::ImageLoader::dispatchPendingLoadEvent): Added. Handles the common logic
448 about when load events can be dispatched so that dispatchLoadEvent only has to
449 have the specific part for each derived class. This includes a check that the
450 document is attached, which used to be handled by having documents empty out the
451 image load event vectors in the detach function.
452 (WebCore::ImageLoader::dispatchPendingLoadEvents): Added. Calls the appropriate
453 function on the ImageLoadEventSender, which avoids the need to have that class be
454 public in the ImageLoader header.
455 (WebCore::ImageLoadEventSender::ImageLoadEventSender): Added. Has the code that
456 was previously in the Document constructor.
457 (WebCore::ImageLoadEventSender::dispatchLoadEventSoon): Added. Has the code that
458 was previously in Document::dispatchImageLoadEventSoon.
459 (WebCore::ImageLoadEventSender::cancelLoadEvent): Added. Has the code that was
460 previously in Document::removeImage.
461 (WebCore::ImageLoadEventSender::dispatchPendingLoadEvents): Added. Has the code
462 that was previously in Document::dispatchImageLoadEventsNow.
463 (WebCore::ImageLoadEventSender::timerFired): Added. Calls dispatchPendingLoadEvents.
465 * loader/ImageLoader.h: Improved comments. Made the virtual functions private
466 or protected rather than public. Added static dispatchPendingLoadEvents function
467 for use by Document and private dispatchPendingLoadEvent function for use by
468 ImageLoadEventSender. Made setLoadingImage private and eliminated
469 setHaveFiredLoadEvent since that can all be done inside the class without any
472 * html/HTMLImageLoader.cpp:
473 (WebCore::HTMLImageLoader::dispatchLoadEvent): Removed logic to check whether a
474 load event already fired and whether image() is 0. These are now both base class
476 * svg/SVGImageLoader.cpp:
477 (WebCore::SVGImageLoader::dispatchLoadEvent): Ditto.
478 * wml/WMLImageLoader.cpp:
479 (WebCore::WMLImageLoader::dispatchLoadEvent): Ditto.
481 2009-03-17 Dimitri Glazkov <dglazkov@chromium.org>
483 Reviewed by Timothy Hatcher.
485 https://bugs.webkit.org/show_bug.cgi?id=24623
486 Refactor ConsoleMessage to use ScriptFuncitonCall and eliminate JSC
489 * bindings/js/ScriptFunctionCall.cpp:
490 (WebCore::ScriptFunctionCall::appendArgument): Added uint and ScriptString-taking methods.
491 * bindings/js/ScriptFunctionCall.h:
492 * bindings/js/ScriptObjectQuarantine.cpp:
493 (WebCore::quarantineValue): Added generic ScriptValue quarantine helper.
494 * bindings/js/ScriptObjectQuarantine.h:
495 * bindings/js/ScriptValue.cpp:
496 (WebCore::ScriptValue::isEqual): Added.
497 * bindings/js/ScriptValue.h:
498 * inspector/ConsoleMessage.cpp:
499 (WebCore::ConsoleMessage::ConsoleMessage):
500 (WebCore::ConsoleMessage::addToConsole): Added.
501 (WebCore::ConsoleMessage::isEqual): Changed to use ScriptValue::isEqual.
502 * inspector/ConsoleMessage.h:
503 (WebCore::ConsoleMessage::incrementCount): Added.
504 * inspector/InspectorController.cpp:
505 (WebCore::InspectorController::addConsoleMessage): Changed to use ConsoleMessage::addToConsole.
506 (WebCore::InspectorController::populateScriptObjects): Ditto.
507 * inspector/InspectorController.h:
509 2009-03-17 Kevin Ollivier <kevino@theolliviers.com>
511 Reviewed by Mark Rowe.
513 Get BUILDING_ON_* defines from Platform.h.
515 https://bugs.webkit.org/show_bug.cgi?id=24630
519 2009-03-16 Xan Lopez <xlopez@igalia.com>
521 Reviewed by Holger Freyther.
523 https://bugs.webkit.org/show_bug.cgi?id=24592
524 [GTK] Crash in FcPatternHash
526 Sanitize memory management in gtk fonts.
528 Release memory allocated by FontPlatformDataGtk in its own
529 destructor instead of doing it from other classes, and add copy
530 constructor and '=' operator to be able to track referenced
533 * platform/graphics/gtk/FontPlatformData.h:
534 * platform/graphics/gtk/FontPlatformDataGtk.cpp:
535 (WebCore::FontPlatformData::operator=):
536 (WebCore::FontPlatformData::FontPlatformData):
537 (WebCore::FontPlatformData::~FontPlatformData):
538 * platform/graphics/gtk/SimpleFontDataGtk.cpp:
539 (WebCore::SimpleFontData::platformDestroy):
541 2009-03-17 Ariya Hidayat <ariya.hidayat@nokia.com>
543 Build fix for Qt < 4.5.
545 As reported by Yael Aharon <yael.aharon@nokia.com>
547 * platform/graphics/qt/GraphicsContextQt.cpp:
548 (WebCore::GraphicsContext::drawLine):
550 2009-03-17 Alexey Proskuryakov <ap@webkit.org>
552 Reviewed by Sam Weinig.
554 https://bugs.webkit.org/show_bug.cgi?id=24614
555 Access control checks are different in cached and uncached cases
557 Test: http/tests/xmlhttprequest/access-control-basic-non-simple-deny-cached.html
559 * loader/CrossOriginAccessControl.cpp:
560 (WebCore::isOnAccessControlSimpleRequestMethodWhitelist): Factored out simple method
561 check for use in both cached and uncached cases. In cached case, an old definition that
562 omitted HEAD was still used.
563 (WebCore::isOnAccessControlSimpleRequestHeaderWhitelist): Check that content type has an
564 allowed value. This is needed in all call sites. Also changed to compare MIME type, not
566 (WebCore::isSimpleCrossOriginAccessRequest): Use the above methods.
568 * loader/CrossOriginAccessControl.h: Expose isOnAccessControlSimpleRequestMethodWhitelist.
570 * loader/CrossOriginPreflightResultCache.cpp:
571 (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginMethod):
572 (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders):
573 Use the new checks for simple method and header.
575 2009-03-16 Gustavo Noronha Silva <gns@gnome.org> and Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
577 Reviewed by Mark Rowe.
579 https://bugs.webkit.org/show_bug.cgi?id=24638
580 [GTK] HTML5 media tags do not work
582 Add a repaint-requested signal to the video sink, and use it to
583 call MediaPlayerPrivate::repaint, so that the video actually
586 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
587 (WebCore::mediaPlayerPrivateRepaintCallback):
588 (WebCore::MediaPlayerPrivate::createGSTPlayBin):
589 * platform/graphics/gtk/VideoSinkGStreamer.cpp:
590 (webkit_video_sink_idle_func):
591 (webkit_video_sink_render):
592 (webkit_video_sink_class_init):
594 2009-03-16 Gustavo Noronha Silva <gns@gnome.org> and Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
596 Reviewed by Holger Freyther.
598 https://bugs.webkit.org/show_bug.cgi?id=24638
599 [GTK] HTML5 media tags do not work
601 Work-around the fact that gst_element_query_duration returns true even
602 though it is unable to figure out the duration when in stream (push)
605 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
606 (WebCore::MediaPlayerPrivate::duration):
608 2009-03-16 Darin Adler <darin@apple.com>
610 Reviewed by Kevin Decker.
612 <rdar://problem/6642742> Top Sites malfunction when switching text zoom mode
615 (WebCore::Frame::setNeedsReapplyStyles): Don’t do anything if the frame is
616 currently showing a non-HTML view.
618 2009-03-16 Darin Adler <darin@apple.com>
620 Reviewed by Adele Peterson.
622 Bug 24629: moving forward or backward a paragraph fails at edge of document
623 https://bugs.webkit.org/show_bug.cgi?id=24629
624 rdar://problem/6544413
626 Test: editing/selection/move-paragraph-document-edges.html
628 * editing/visible_units.cpp:
629 (WebCore::previousParagraphPosition): Use the last result from
630 previousLinePosition rather than going all the way back to what was originally
631 passed in when we hit exception cases like null or not moving. This correctly
632 inherits the behavior of previousLinePosition when we are in a paragraph at the
634 (WebCore::nextParagraphPosition): Ditto.
636 2009-03-16 Darin Adler <darin@apple.com>
638 Reviewed by Adele Peterson.
640 Bug 24619: RenderObject::selectionStartEnd does not need to be a virtual function
641 https://bugs.webkit.org/show_bug.cgi?id=24619
643 * rendering/RenderObject.h: Remove virtual keyword from selectionStartEnd declaration.
644 * rendering/RenderView.h: Ditto.
646 2009-03-16 Peter Kasting <pkasting@google.com>
648 Reviewed by David Hyatt.
650 https://bugs.webkit.org/show_bug.cgi?id=24368
651 DOM scroll events should be based off the actual number of wheel
652 ticks, not off the number of lines scrolled. This matches IE.
655 (WebCore::Node::dispatchWheelEvent):
656 * dom/WheelEvent.cpp:
657 (WebCore::WheelEvent::WheelEvent):
659 (WebCore::WheelEvent::create):
660 * platform/PlatformWheelEvent.h:
661 (WebCore::PlatformWheelEvent::wheelTicksX):
662 (WebCore::PlatformWheelEvent::wheelTicksY):
663 * platform/gtk/WheelEventGtk.cpp:
664 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
665 * platform/mac/WheelEventMac.mm:
666 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
667 * platform/qt/WheelEventQt.cpp:
668 * platform/win/WheelEventWin.cpp:
669 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
670 * platform/wx/MouseWheelEventWx.cpp:
671 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
673 2009-03-16 Simon Fraser <simon.fraser@apple.com>
675 Reviewed by Eric Seidel
677 Clean up a few issues in the Animation code:
679 * page/animation/AnimationBase.cpp:
680 (WebCore::AnimationBase::updateStateMachine):
683 (WebCore::AnimationBase::willNeedService):
684 Don't round to float, use std::max
686 * page/animation/AnimationController.cpp:
687 (WebCore::AnimationControllerPrivate::startTimeResponse):
688 Fix erroneously copied line to null out m_lastResponseWaiter.
690 2009-03-12 David Hyatt <hyatt@apple.com>
692 Reviewed by Eric Seidel
694 https://bugs.webkit.org/show_bug.cgi?id=13632
696 Overflow scrolling needs to account for the bottom/right padding on the object itself as well
697 as for bottom/right margins on children.
699 Existing tests cover this.
701 * rendering/RenderBlock.cpp:
702 (WebCore::RenderBlock::lowestPosition):
703 (WebCore::RenderBlock::rightmostPosition):
705 2009-03-16 Sam Weinig <sam@webkit.org>
707 Reviewed by Anders Carlsson.
709 Fix for <rdar://problem/6320555>
710 Add an upper limit for setting HTMLSelectElement.length.
712 Test: fast/forms/select-max-length.html
714 * html/HTMLSelectElement.cpp:
715 (WebCore::HTMLSelectElement::setOption):
716 (WebCore::HTMLSelectElement::setLength):
718 2009-03-16 Eric Carlson <eric.carlson@apple.com>
720 Reviewed by Simon Fraser.
722 <rdar://problem/6686721> Media document crash in 64-bit WebKit
724 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
725 (WebCore::MediaPlayerPrivate::createQTMovieView): QTMovieContentViewClass is only used when
726 rendering inline with old versions of QuickTime, so don't look for it when we are in a
729 2009-03-16 Dimitri Glazkov <dglazkov@chromium.org>
731 Reviewed by Timothy Hatcher.
733 https://bugs.webkit.org/show_bug.cgi?id=24590
734 Refactor InspectorDOMStorageResource to use ScriptFunctionCall.
736 * bindings/js/ScriptFunctionCall.cpp:
737 (WebCore::ScriptFunctionCall::appendArgument): Added method for bool argument.
738 * bindings/js/ScriptFunctionCall.h: Ditto, also cleaned up.
739 * bindings/js/ScriptObjectQuarantine.cpp:
740 (WebCore::getQuarantinedScriptObject): Added Storage helper.
741 * bindings/js/ScriptObjectQuarantine.h: Ditto.
742 * inspector/InspectorController.cpp:
743 (WebCore::InspectorController::populateScriptObjects): Changed to use bind method.
744 (WebCore::InspectorController::resetScriptObjects): Changed to use unbind method.
745 (WebCore::InspectorController::didUseDOMStorage): Changed to use isSameHostAndType and bind methods.
746 * inspector/InspectorController.h: Removed add/remove methods for DOM storage.
747 * inspector/InspectorDOMStorageResource.cpp:
748 (WebCore::InspectorDOMStorageResource::InspectorDOMStorageResource):
749 (WebCore::InspectorDOMStorageResource::isSameHostAndType): Added.
750 (WebCore::InspectorDOMStorageResource::bind): Added.
751 (WebCore::InspectorDOMStorageResource::unbind): Added.
752 * inspector/InspectorDOMStorageResource.h:
754 2009-03-16 Mike Belshe <mike@belse.com>
756 Reviewed by Dimitri Glazkov.
758 https://bugs.webkit.org/show_bug.cgi?id=24580
759 Fix query() to match KURL behavior, this time with the code that
762 * platform/KURLGoogle.cpp:
763 (WebCore::KURL::query): Fix copy/paste mistake.
765 2009-03-16 Alexey Proskuryakov <ap@webkit.org>
767 Reviewed by Darin Adler.
769 https://bugs.webkit.org/show_bug.cgi?id=21752
770 REGRESSION: referencing XHR constructor for a not yet loaded frame permanently breaks it
772 Test: fast/dom/Window/window-early-properties-xhr.html
774 For some transitions, the Window object is not replaced, but Document is. When this happened,
775 window.document property was updated, but references to Document kept in cached constructors
778 * bindings/js/JSAudioConstructor.cpp:
779 (WebCore::JSAudioConstructor::JSAudioConstructor):
780 (WebCore::JSAudioConstructor::document):
781 (WebCore::JSAudioConstructor::mark):
782 * bindings/js/JSAudioConstructor.h:
783 * bindings/js/JSImageConstructor.cpp:
784 (WebCore::JSImageConstructor::JSImageConstructor):
785 (WebCore::JSImageConstructor::document):
786 (WebCore::JSImageConstructor::mark):
787 * bindings/js/JSImageConstructor.h:
788 * bindings/js/JSMessageChannelConstructor.cpp:
789 (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor):
790 (WebCore::JSMessageChannelConstructor::scriptExecutionContext):
791 (WebCore::JSMessageChannelConstructor::mark):
792 * bindings/js/JSMessageChannelConstructor.h:
793 * bindings/js/JSOptionConstructor.cpp:
794 (WebCore::JSOptionConstructor::JSOptionConstructor):
795 (WebCore::JSOptionConstructor::document):
796 (WebCore::JSOptionConstructor::mark):
797 * bindings/js/JSOptionConstructor.h:
798 * bindings/js/JSXMLHttpRequestConstructor.cpp:
799 (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
800 (WebCore::JSXMLHttpRequestConstructor::scriptExecutionContext):
801 (WebCore::JSXMLHttpRequestConstructor::mark):
802 * bindings/js/JSXMLHttpRequestConstructor.h:
803 Changed cached constructors to keep a reference to Window, not Document.
805 2009-03-15 Alexey Proskuryakov <ap@webkit.org>
807 Reviewed by Darin Adler.
809 https://bugs.webkit.org/show_bug.cgi?id=24549
810 Impose a limit on Access-Control-Max-Age value
812 * loader/CrossOriginPreflightResultCache.cpp:
813 (WebCore::CrossOriginPreflightResultCacheItem::parse):
815 2009-03-15 Greg Bolsinga <bolsinga@apple.com>
817 Reviewed by David Kilzer.
819 <rdar://problem/6668875> Normalize Geolocation results
821 * platform/mac/GeolocationServiceMac.mm:
822 (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
824 2009-03-15 Greg Bolsinga <bolsinga@apple.com>
826 Reviewed by David Kilzer.
828 Update ::toString format as suggested by Darin Adler.
830 * page/Geoposition.cpp:
831 (WebCore::Geoposition::toString):
833 2009-03-15 David Kilzer <ddkilzer@apple.com>
835 <rdar://problem/6668238> WebCore is registering text encodings needlessly from KURL constructor.
837 Reviewed by Darin Adler.
839 Yet another case where we would trigger extended encoding loading needlessly.
841 * platform/text/TextEncoding.cpp:
842 (WebCore::TextEncoding::encodingForFormSubmission):
844 2009-03-15 Simon Fraser <simon.fraser@apple.com>
846 Build fix: no review.
848 * rendering/style/ContentData.h:
850 2009-03-15 David Kilzer <ddkilzer@apple.com>
852 Bug 24542: Improve ContentData encapsulation
854 <https://bugs.webkit.org/show_bug.cgi?id=24542>
856 Reviewed by Simon Fraser.
858 No tests since there is no change in behavior.
860 * rendering/RenderObject.cpp:
861 (WebCore::RenderObject::createObject): Used getter methods
862 instead of data members on ContentData class. Used isImage()
864 * rendering/RenderObjectChildList.cpp:
865 (WebCore::RenderObjectChildList::updateBeforeAfterContent): Ditto.
867 * rendering/style/ContentData.cpp:
868 (WebCore::ContentData::clear): Extracted code into
869 deleteContent() method.
870 (WebCore::ContentData::dataEquivalent): Added. Extracted code
871 from StyleRareNonInheritedData::contentDataEquivalent().
872 (WebCore::ContentData::deleteContent): Added. Used by setter
874 * rendering/style/ContentData.h: Made m_type, m_content and
876 (WebCore::ContentData::isCounter): Added.
877 (WebCore::ContentData::isImage): Added.
878 (WebCore::ContentData::isNone): Added.
879 (WebCore::ContentData::isText): Added.
880 (WebCore::ContentData::type): Added.
881 (WebCore::ContentData::dataEquivalent): Added.
882 (WebCore::ContentData::image): Added.
883 (WebCore::ContentData::setImage): Added.
884 (WebCore::ContentData::text): Added.
885 (WebCore::ContentData::setText): Added.
886 (WebCore::ContentData::counter): Added.
887 (WebCore::ContentData::setCounter): Added.
888 (WebCore::ContentData::next): Added.
889 (WebCore::ContentData::setNext): Added.
891 * rendering/style/CounterContent.h:
892 (WebCore::operator!=): Removed.
893 (WebCore::operator==): Renamed operator!=() and reversed its
894 logic after extracting code from
895 StyleRareNonInheritedData::contentDataEquivalent() to create
896 ContentData::dataEquivalent().
898 * rendering/style/RenderStyle.cpp:
899 (WebCore::RenderStyle::setContent): Used new getters and setters
900 on ContentData class. Changed first argument from a StringImpl*
901 to a PassRefPtr<StrimgImpl>. Used isText() convenience method.
902 * rendering/style/RenderStyle.h:
903 (WebCore::RenderStyle::setContent): Updated declaration.
904 * rendering/style/StyleRareNonInheritedData.cpp:
905 (WebCore::StyleRareNonInheritedData::contentDataEquivalent):
906 Extracted most logic in while() loop into
907 ContentData::dataEquivalent().
909 2009-03-15 Gustavo Noronha Silva <gns@gnome.org>
911 Reviewed by Anders Carlsson.
913 https://bugs.webkit.org/show_bug.cgi?id=24602
914 [Gtk] Searching in thepiratebay.org doesn't work with more than 1 word
916 Reintroduce the URI into the soup message after having set it in
917 the KURL, on redirects, to make sure it is properly encoded. This
918 fixes bad request problems when servers give bad URIs on their
919 response's Location header.
921 * platform/network/soup/ResourceHandleSoup.cpp:
922 (WebCore::restartedCallback):
924 2009-03-15 Alexey Proskuryakov <ap@webkit.org>
926 Reviewed by Darin Adler.
928 https://bugs.webkit.org/show_bug.cgi?id=19737
929 No cursor and paste not enabled right clicking text field/area
931 Test: fast/events/right-click-focus.html
933 * page/EventHandler.cpp:
934 (WebCore::EventHandler::handleMousePressEventSingleClick):
935 (WebCore::EventHandler::handleMousePressEvent):
936 Take normal code path for right clicks (we were taking it for Ctrl-clicks anyway).
938 2009-03-15 Alexey Proskuryakov <ap@webkit.org>
940 Reviewed by Adele Peterson.
942 https://bugs.webkit.org/show_bug.cgi?id=23949
943 HTMLSelectElement is in inconsistent state when handling mutation events
945 Test: fast/forms/mutation-event-recalc.html
947 * dom/ContainerNode.cpp:
948 (WebCore::ContainerNode::insertBefore):
949 (WebCore::ContainerNode::appendChild):
950 Call childrenChanged() before dispatching modification events, not after.
952 * html/HTMLOptGroupElement.cpp:
953 (WebCore::HTMLOptGroupElement::insertBefore):
954 (WebCore::HTMLOptGroupElement::replaceChild):
955 (WebCore::HTMLOptGroupElement::removeChild):
956 (WebCore::HTMLOptGroupElement::appendChild):
957 (WebCore::HTMLOptGroupElement::removeChildren):
958 * html/HTMLSelectElement.cpp:
959 (WebCore::HTMLSelectElement::add):
960 (WebCore::HTMLSelectElement::remove):
961 (WebCore::HTMLSelectElement::insertBefore):
962 (WebCore::HTMLSelectElement::replaceChild):
963 (WebCore::HTMLSelectElement::removeChild):
964 (WebCore::HTMLSelectElement::appendChild):
965 (WebCore::HTMLSelectElement::removeChildren):
966 Remove calls to recalcSelectOptions(). It is too late to recalc now, after mutation events
967 were already dispatched.
969 2009-03-14 Greg Bolsinga <bolsinga@apple.com>
971 <rdar://problem/6683465>
973 Geolocation has to be able to handle NULL Frames.
975 Reviewed by Mark Rowe
977 2009-03-14 Greg Bolsinga <bolsinga@apple.com>
979 Reviewed by David Kilzer.
981 Geoposition::toString was missing the Coordinates after the update.
983 * page/Geoposition.cpp:
984 (WebCore::Geoposition::toString):
986 2009-03-14 Jan Michael Alonzo <jmalonzo@webkit.org>
988 Reviewed by Mark Rowe.
990 [Gtk] Build fix - pass a Coordinate to Geoposition::create
991 https://bugs.webkit.org/show_bug.cgi?id=24603
993 Gtk build fix per r41650
994 https://bugs.webkit.org/show_bug.cgi?id=24506
995 Geolocation in Safari differs from the spec, no Coordinates attribute on Position
997 Pass a Coordinate to Geoposition::create.
999 * platform/gtk/GeolocationServiceGtk.cpp:
1000 (WebCore::GeolocationServiceGtk::updatePosition):
1002 2009-03-14 Alexey Proskuryakov <ap@webkit.org>
1004 Reviewed by Darin Adler.
1006 https://bugs.webkit.org/show_bug.cgi?id=24545
1007 Make cross-site XHR simple request definition match current spec draft
1009 Tests: http/tests/xmlhttprequest/access-control-basic-post-fail-non-simple-content-type.html
1010 http/tests/xmlhttprequest/access-control-basic-whitelist-request-headers.html
1012 * loader/CrossOriginAccessControl.cpp:
1013 (WebCore::isOnAccessControlSimpleRequestHeaderWhitelist): Added Content-Language.
1014 (WebCore::isSimpleCrossOriginAccessRequest): Added HEAD. Restricted content types to those
1015 that could be sent via form submission.
1017 2009-03-14 Alexey Proskuryakov <ap@webkit.org>
1019 Reviewed by Darin Adler.
1021 https://bugs.webkit.org/show_bug.cgi?id=15172
1022 object fallback - empty string for first argument of setAttributeNS does not work like null
1024 https://bugs.webkit.org/show_bug.cgi?id=24548
1025 createElementNS("", name) should create an element in null namespace
1027 Tests: fast/dom/createElementNS-empty-namespace.html
1028 fast/dom/setAttributeNS-empty-namespace.html
1030 * dom/QualifiedName.h: (WebCore::QualifiedName::QualifiedNameImpl::QualifiedNameImpl):
1031 Convert empty namespaces to null.
1033 2009-03-13 Mark Rowe <mrowe@apple.com>
1035 Rubber-stamped by Dan Bernstein.
1037 Take advantage of the ability of recent versions of Xcode to easily switch the active
1040 * Configurations/DebugRelease.xcconfig:
1042 2009-03-13 John Abd-El-Malek <jam@google.com>
1044 Reviewed by Darin Fisher.
1046 https://bugs.webkit.org/show_bug.cgi?id=24593
1047 Added requestorID so we can track the request to its WebView without using frame (which was removed).
1049 * platform/network/chromium/ResourceRequest.h:
1050 (WebCore::ResourceRequest::ResourceRequest):
1051 (WebCore::ResourceRequest::requestorID):
1052 (WebCore::ResourceRequest::setRequestorID):
1053 (WebCore::ResourceRequest::setTargetType):
1054 (WebCore::ResourceRequest::policyURL):
1055 (WebCore::ResourceRequest::setPolicyURL):
1056 (WebCore::ResourceRequest::requestorPid):
1057 (WebCore::ResourceRequest::setRequestorPid):
1059 2009-03-13 Mike Belshe <mike@belshe.com>
1061 Reviewed by Dimitri Glazkov.
1063 https://bugs.webkit.org/show_bug.cgi?id=24561
1064 Add custom V8 bindings for HTMLElementCanvas, Location.
1066 * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp: Added.
1067 * bindings/v8/custom/V8LocationCustom.cpp: Added.
1069 2009-03-13 Stephen White <senorblanco@chromium.org>
1071 Reviewed by Eric Seidel.
1073 https://bugs.webkit.org/show_bug.cgi?id=24584
1075 Fix transparent text rendering on Chromium. FontChromiumWin
1076 was calling beginTransparencyLayer()/endTransparencyLayer(), with
1077 a TransparencyWin inside to do GDI ClearType rendering over an
1078 opaque background. TransparencyWin does its special sauce
1079 in the destructor, but it was being called too late to be used
1080 correctly in the layer. Put the special sauce into a new function,
1081 composite(), and call that explicitly instead.
1083 * platform/graphics/chromium/FontChromiumWin.cpp:
1084 (WebCore::TransparencyAwareFontPainter::TransparencyAwareFontPainter::~TransparencyAwareFontPainter):
1085 * platform/graphics/chromium/TransparencyWin.cpp:
1086 (WebCore::TransparencyWin::~TransparencyWin):
1087 (WebCore::TransparencyWin::composite):
1088 (WebCore::TransparencyWin::init):
1089 * platform/graphics/chromium/TransparencyWin.h:
1090 * rendering/RenderThemeChromiumWin.cpp:
1093 2009-03-13 Mike Belshe <mike@belshe.com>
1095 Reviewed by Dimitri Glazkov.
1097 https://bugs.webkit.org/show_bug.cgi?id=24562
1098 Add custom implementation for getCSSCanvasContext to V8 bindings.
1100 * bindings/v8/custom/V8DocumentCustom.cpp: Added new method.
1102 2009-03-13 Mike Belshe <mike@belse.com>
1104 Reviewed by Dimitri Glazkov.
1106 https://bugs.webkit.org/show_bug.cgi?id=24580
1107 Fix query() to match KURL behavior.
1109 * platform/KURLGoogle.cpp:
1110 (WebCore::KURL::query): remove extra logic around question mark.
1112 2009-03-13 Chris Fleizach <cfleizach@apple.com>
1114 Reviewed by Beth Dakin.
1116 Bug 24474: AX: in multi-body tables, asking for a cell at a specific coordinate can return nil
1117 https://bugs.webkit.org/show_bug.cgi?id=24474
1119 Test: platform/mac-snowleopard/accessibility/table-multi-bodies.html
1121 * page/AccessibilityTable.cpp:
1122 (WebCore::AccessibilityTable::cellForColumnAndRow):
1124 2009-03-13 Jian Li <jianli@chromium.org>
1126 Reviewed by Dimitri Glazkov.
1128 https://bugs.webkit.org/show_bug.cgi?id=24589
1129 Upstream changes to V8 event listeners (Chromium r11133) in order to
1130 fix worker functionality break in Chromium.
1132 * bindings/v8/V8AbstractEventListener.cpp:
1133 (WebCore::V8AbstractEventListener::invokeEventHandler):
1134 (WebCore::V8AbstractEventListener::handleEvent):
1135 * bindings/v8/V8AbstractEventListener.h:
1136 * bindings/v8/V8WorkerContextEventListener.cpp:
1137 (WebCore::V8WorkerContextEventListener::handleEvent):
1139 2009-03-13 Dimitri Glazkov <dglazkov@chromium.org>
1141 Reviewed by Timothy Hatcher.
1143 https://bugs.webkit.org/show_bug.cgi?id=24524
1144 Introduce ScriptObject and ScriptFunctionCall abstractions.
1146 * GNUmakefile.am: Added ScriptObject and ScriptFunctionCall to project.
1147 * WebCore.pro: Ditto.
1148 * WebCore.vcproj/WebCore.vcproj: Ditto.
1149 * WebCore.xcodeproj/project.pbxproj: Ditto.
1150 * WebCoreSources.bkl: Ditto.
1151 * bindings/js/ScriptFunctionCall.cpp: Added.
1152 * bindings/js/ScriptFunctionCall.h: Added.
1153 * bindings/js/ScriptObject.cpp: Added.
1154 * bindings/js/ScriptObject.h: Added.
1155 * bindings/js/ScriptObjectQuarantine.cpp: Added.
1156 * bindings/js/ScriptObjectQuarantine.h: Added.
1157 * inspector/InspectorController.cpp:
1158 (WebCore::InspectorController::populateScriptObjects): Changed to use InspectorDatabaseResource::bind.
1159 (WebCore::InspectorController::resetScriptObjects): Changed to use InspectorDatabaseResource::unbind.
1160 (WebCore::InspectorController::didOpenDatabase): Changed to use InspectorDatabaseResource::unbind.
1161 * inspector/InspectorController.h: Removed addScriptDatabaseResource and
1162 removeScriptDatabaseResource declarations.
1163 * inspector/InspectorDatabaseResource.cpp:
1164 (WebCore::InspectorDatabaseResource::InspectorDatabaseResource):
1165 (WebCore::InspectorDatabaseResource::bind): Added.
1166 (WebCore::InspectorDatabaseResource::unbind): Added.
1167 * inspector/InspectorDatabaseResource.h: Added bind and unbind declarations.
1169 2009-03-13 Peter Kasting <pkasting@google.com>
1171 Reviewed by Eric Seidel.
1173 https://bugs.webkit.org/show_bug.cgi?id=24467
1174 Make Skia drawRect() and stroke behavior match CG.
1176 This makes drawRect() ignore the stroke width (like CG does), and
1177 adds a warning comment about that to the appropriate header.
1179 It also eliminates some hacky code in Skia's stroke preparation,
1180 which tried to adjust odd-width strokes to fall on pixel boundaries.
1181 Not only did this not match CG, it wouldn't necessarily work right,
1182 because there could be other transforms (e.g. full-page zoom) that
1183 would affect the stroke before it reached the device pixel level.
1185 * platform/graphics/GraphicsContext.h:
1186 * platform/graphics/skia/GraphicsContextSkia.cpp:
1187 (WebCore::GraphicsContext::drawRect):
1188 (WebCore::GraphicsContext::fillRect):
1189 * platform/graphics/skia/PlatformContextSkia.cpp:
1190 (PlatformContextSkia::drawRect):
1191 (PlatformContextSkia::setupPaintForStroking):
1193 2009-03-13 Jian Li <jianli@chromium.org>
1195 Reviewed by Dimitri Glazkov.
1197 https://bugs.webkit.org/show_bug.cgi?id=24583
1198 Need to change scope of constructor and destructor of V8ObjectEventListener from private
1199 to protected so that they could be used in its derived class V8WorkerContextEventListener.
1201 * bindings/v8/V8ObjectEventListener.h:
1203 2009-03-13 David Levin <levin@chromium.org>
1205 Reviewed by Dimitri Glazkov.
1207 https://bugs.webkit.org/show_bug.cgi?id=24579
1208 Many V8*Event* files are misplaced.
1210 This code is infrastructure for supporting the bindings and thus should
1211 be in the bindings/v8 directory.
1213 * bindings/v8/V8AbstractEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8AbstractEventListener.cpp.
1214 * bindings/v8/V8AbstractEventListener.h: Renamed from WebCore/bindings/v8/custom/V8AbstractEventListener.h.
1215 * bindings/v8/V8LazyEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8LazyEventListener.cpp.
1216 * bindings/v8/V8LazyEventListener.h: Renamed from WebCore/bindings/v8/custom/V8LazyEventListener.h.
1217 * bindings/v8/V8ObjectEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8ObjectEventListener.cpp.
1218 * bindings/v8/V8ObjectEventListener.h: Renamed from WebCore/bindings/v8/custom/V8ObjectEventListener.h.
1219 * bindings/v8/V8WorkerContextEventListener.cpp: Renamed from WebCore/bindings/v8/custom/V8WorkerContextEventListener.cpp.
1220 * bindings/v8/V8WorkerContextEventListener.h: Renamed from WebCore/bindings/v8/custom/V8WorkerContextEventListener.h.
1222 2009-03-13 Adele Peterson <adele@apple.com>
1224 Reviewed by Justin Garcia.
1226 Fix for <rdar://problem/5089327> Color of quoted content is wrong when pasted inside other quoted content
1228 Test: editing/pasteboard/5089327.html
1230 Handle spans being pasted within a quoted region in the same way we handle "paste as quotation" content.
1232 * editing/ReplaceSelectionCommand.cpp:
1233 (WebCore::handleStyleSpansBeforeInsertion):
1234 (WebCore::ReplaceSelectionCommand::handleStyleSpans):
1236 2009-03-13 Greg Bolsinga <bolsinga@apple.com>
1238 Reviewed by Simon Fraser.
1240 Update Geolocation perimission dialogs to be asynchronous.
1241 https://bugs.webkit.org/show_bug.cgi?id=24505
1243 Geolocation now requests permission from the Chrome asynchronously.
1244 The Chrome is passed the Geolocation object, and the Chrome sets the permission
1245 on the Geolocation. Geolocation also tracks if the Chrome should clear its cache
1246 of SecurityOrigins with geolocation permission. This is so that the GeolocationService
1247 can inform the Chrome of its request, and the Chrome is also free to implement its
1251 * WebCore.xcodeproj/project.pbxproj:
1253 (WebCore::Chrome::requestGeolocationPermissionForFrame):
1255 * page/ChromeClient.h:
1256 (WebCore::ChromeClient::requestGeolocationPermissionForFrame):
1257 * page/Geolocation.cpp:
1258 (WebCore::Geolocation::Geolocation):
1259 (WebCore::Geolocation::getCurrentPosition):
1260 (WebCore::Geolocation::watchPosition):
1261 (WebCore::Geolocation::setIsAllowed):
1262 (WebCore::Geolocation::displayChallengeIfNecessary):
1263 (WebCore::Geolocation::geolocationServicePositionChanged):
1264 * page/Geolocation.h:
1265 (WebCore::Geolocation::isAllowed):
1266 (WebCore::Geolocation::setShouldClearCache):
1267 (WebCore::Geolocation::shouldClearCache):
1268 (WebCore::Geolocation::):
1270 2009-03-13 Anders Carlsson <andersca@apple.com>
1272 Reviewed by Dan Bernstein.
1274 <rdar://problem/6610666> Revise the Cocoa event model text API
1276 Add a NPCocoaEventTextInput event type. Remove the text input variables.
1281 2009-03-13 Kevin Decker <kdecker@apple.com>
1285 <rdar://problem/6630340> REGRESSION (39114-39115): Unity Web Player no longer works if Flip4Mac is also installed
1287 The code assumed if we have a plug-in that supports "application/x-oleobject" we should always prefer the object tag
1288 over of an embed tag. That assumption can cause the Mac platform to load the wrong plug-in, as Flip4Mac claims supports
1291 * rendering/RenderPartObject.cpp:
1292 (WebCore::shouldUseEmbedDescendant): Made the Mac platform always return true here.
1294 2009-03-13 Jian Li <jianli@chromium.org>
1296 Reviewed by Dimitri Glazkov.
1298 https://bugs.webkit.org/show_bug.cgi?id=24559
1299 Need to port JSC fix (r41565) to V8 in order to fix layout test onload-single-line-comment.html.
1301 * bindings/v8/custom/V8LazyEventListener.cpp:
1302 (WebCore::V8LazyEventListener::getListenerFunction):
1303 (WebCore::V8LazyEventListener::getWrappedListenerFunction):
1305 2009-03-13 Jian Li <jianli@chromium.org>
1307 Reviewed by Dimitri Glazkov.
1309 https://bugs.webkit.org/show_bug.cgi?id=24557
1310 This is to support running multiple workers in a single worker process in chromium.
1312 * bindings/v8/custom/V8WorkerContextEventListener.cpp:
1313 (WebCore::V8WorkerContextEventListener::handleEvent):
1314 Add locker to v8 event listener of worker context.
1316 2009-03-13 Alexey Proskuryakov <ap@webkit.org>
1318 Reviewed by Sam Weinig.
1320 https://bugs.webkit.org/show_bug.cgi?id=24575
1321 XHR response is incorrect after a network error.
1323 Tests: http/tests/xmlhttprequest/cross-site-denied-response-sync-2.html
1324 http/tests/xmlhttprequest/cross-site-denied-response-sync.html
1325 http/tests/xmlhttprequest/cross-site-denied-response.html
1327 * xml/XMLHttpRequest.cpp:
1328 (WebCore::XMLHttpRequest::networkError): Call internalAbort() to fully reset the request.
1329 (WebCore::XMLHttpRequest::didFailRedirectCheck): No need to call internalAbort() here. Note
1330 that since internalAbort() can drop GC protection, it is not safe to use the object after
1332 (WebCore::XMLHttpRequest::didReceiveData): Check that the request wasn't aborted, and
1333 return early if it was. This can happen during sync requests, as the loader does not know
1334 that it was aborted, and just synthesizes all callbacks.
1336 2009-03-13 Adam Bergkvist <adam.bergkvist@ericsson.com>
1338 Reviewed by Alexey Proskuryakov.
1340 https://bugs.webkit.org/show_bug.cgi?id=3547
1341 XMLHttpRequest.statusText returns always "OK"
1343 Covered by existing tests (which now pass on all platforms but Mac).
1345 * xml/XMLHttpRequest.cpp:
1346 (WebCore::XMLHttpRequest::statusText): Return ResourceResponse status text. It is now up
1347 to each platform to correctly set the status text or set it to "OK" to retain current
1350 2009-03-13 Adam Bergkvist <adam.bergkvist@ericsson.com>
1352 Reviewed by Alexey Proskuryakov.
1354 https://bugs.webkit.org/show_bug.cgi?id=24349
1355 [QT] HTTP status text is never set
1357 Set HTTP status text to the reason phrase attribute of QNetworkReply.
1359 * platform/network/qt/QNetworkReplyHandler.cpp:
1360 (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1362 2009-03-12 Simon Fraser <simon.fraser@apple.com>
1364 Reviewed by Mark Rowe
1366 <rdar://problem/6622300>: Reproducible crash on
1367 <http://www.editgrid.com/explore/tnc/dave/FusionChart%3A_Candlestick>
1369 Prevent CSSStyleSheet::checkLoaded() writing to freed memory when it gets
1370 deleted from under itself. The sheetLoaded() notification can allow scripts
1371 to run via HTMLTokenizer::executeScriptsWaitingForStylesheets(),
1372 which can cause the last ref to the CSSStyleSheet to be released.
1374 * css/CSSStyleSheet.cpp:
1375 (WebCore::CSSStyleSheet::checkLoaded):
1377 2009-03-12 Kevin Ollivier <kevino@theolliviers.com>
1379 wx build fix. Allow make-generated-sources.sh to pass args down to DerivedSources.make
1381 * make-generated-sources.sh:
1383 2009-03-12 Adam Treat <adam.treat@torchmobile.com>
1385 Reviewed by Oliver Hunt.
1387 https://bugs.webkit.org/show_bug.cgi?id=24498
1388 Fix the Qt port to use the same algorithm for drawing dashed and dotted
1389 borders as the other ports. This makes the Qt port pixel-for-pixel perfect
1390 compared to border drawing with Apple's canonical mac port and much closer
1391 to konqueror and firefox behavior.
1393 * platform/graphics/qt/GraphicsContextQt.cpp:
1394 (WebCore::GraphicsContext::drawLine):
1396 2009-02-26 Eric Seidel <eric@webkit.org>
1398 Reviewed by Justin Garcia.
1400 Clean up DOMSelection to use some helper functions
1401 making the code smaller, and less error-prone.
1402 https://bugs.webkit.org/show_bug.cgi?id=19221
1404 I tried moving DOMSelection off of rangeCompliantEquivalent
1405 but failed. VisibleSelection holds positions like (table, 1) to mean
1408 * page/DOMSelection.cpp:
1409 (WebCore::DOMSelection::visibleSelection):
1410 (WebCore::anchorPosition):
1411 (WebCore::focusPosition):
1412 (WebCore::basePosition):
1413 (WebCore::extentPosition):
1414 (WebCore::DOMSelection::anchorNode):
1415 (WebCore::DOMSelection::anchorOffset):
1416 (WebCore::DOMSelection::focusNode):
1417 (WebCore::DOMSelection::focusOffset):
1418 (WebCore::DOMSelection::baseNode):
1419 (WebCore::DOMSelection::baseOffset):
1420 (WebCore::DOMSelection::extentNode):
1421 (WebCore::DOMSelection::extentOffset):
1422 * page/DOMSelection.h:
1424 2009-03-12 Dmitry Titov <dimich@chromium.org>
1426 Reviewed by Dimitri Glazkov.
1428 https://bugs.webkit.org/show_bug.cgi?id=24563
1429 Change ResourceRequest to be a struct rather then a class to match other declarations.
1431 * platform/network/chromium/ResourceRequest.h:
1433 2009-03-12 David Levin <levin@chromium.org>
1435 Reviewed by Darin Fisher.
1437 Bug 24530: width100percent-searchfield.html should be fixed for chromium.
1438 <https://bugs.webkit.org/show_bug.cgi?id=24530>
1440 Compensate for r39924 in chromium, which broke LayoutTests/fast/replaced/width100percent-searchfield.html
1442 * css/themeChromiumWin.css: Added.
1443 Overrides the changes to start supporting input[type="search"] on Windows (since
1444 Chromium doesn't do anything special for this).
1446 * rendering/RenderThemeChromiumWin.cpp:
1447 (WebCore::supportsFocus):
1448 (WebCore::RenderThemeChromiumWin::extraDefaultStyleSheet):
1449 (WebCore::RenderThemeChromiumWin::determineState):
1450 (WebCore::RenderThemeChromiumWin::getThemeData):
1452 2009-03-12 Greg Bolsinga <bolsinga@apple.com>
1454 Reviewed by Antti Koivisto.
1456 https://bugs.webkit.org/show_bug.cgi?id=24506
1457 Geolocation in Safari differs from the spec, no Coordinates attribute on Position
1461 * DerivedSources.make:
1465 * WebCore.vcproj/WebCore.vcproj:
1466 * WebCore.xcodeproj/project.pbxproj:
1467 * WebCoreSources.bkl:
1468 * bindings/js/JSGeolocationCustom.cpp:
1469 (WebCore::createPositionOptions):
1470 * page/Coordinates.cpp: Added.
1471 (WebCore::Coordinates::toString):
1472 * page/Coordinates.h: Added.
1473 (WebCore::Coordinates::create):
1474 (WebCore::Coordinates::latitude):
1475 (WebCore::Coordinates::longitude):
1476 (WebCore::Coordinates::altitude):
1477 (WebCore::Coordinates::accuracy):
1478 (WebCore::Coordinates::altitudeAccuracy):
1479 (WebCore::Coordinates::heading):
1480 (WebCore::Coordinates::speed):
1481 (WebCore::Coordinates::Coordinates):
1482 * page/Coordinates.idl: Added.
1483 * page/Geoposition.cpp:
1484 (WebCore::Geoposition::toString):
1485 * page/Geoposition.h:
1486 (WebCore::Geoposition::create):
1487 (WebCore::Geoposition::coords):
1488 (WebCore::Geoposition::Geoposition):
1489 * page/Geoposition.idl:
1490 * page/PositionOptions.h:
1491 (WebCore::PositionOptions::create):
1492 (WebCore::PositionOptions::maximumAge):
1493 (WebCore::PositionOptions::setMaximumAge):
1494 (WebCore::PositionOptions::PositionOptions):
1495 * platform/mac/GeolocationServiceMac.mm:
1496 (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
1498 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
1500 Reviewed by Darin Fisher.
1502 https://bugs.webkit.org/show_bug.cgi?id=24496
1503 Fix console logging of non-string values by coercing the argument to
1504 a string, for V8 bindings.
1506 Test: fast/js/console-non-string-values.html
1508 * bindings/v8/ScriptValue.cpp: Added toString method.
1509 (WebCore::ScriptValue::toString):
1510 * bindings/v8/ScriptValue.h: Added PlatformString, ScriptState includes
1511 and toString declaration.
1513 2009-03-12 Darin Fisher <darin@chromium.org>
1515 Reviewed by Dimitri Glazkov.
1517 Eliminate ChromiumBridge::uiResourceProtocol
1518 https://bugs.webkit.org/show_bug.cgi?id=24558
1520 * platform/chromium/ChromiumBridge.h:
1522 2009-03-12 Greg Bolsinga <bolsinga@apple.com>
1524 Reviewed by Simon Fraser.
1526 Missing breaks in switch statement
1527 https://bugs.webkit.org/show_bug.cgi?id=24556
1529 * platform/mac/GeolocationServiceMac.mm:
1530 (-[WebCoreCoreLocationObserver locationManager:didFailWithError:]):
1532 2009-03-12 Darin Fisher <darin@chromium.org>
1534 Reviewed by Dimitri Glazkov.
1536 https://bugs.webkit.org/show_bug.cgi?id=24554
1537 Remove some unused functions from ChromiumBridge.
1539 * platform/chromium/ChromiumBridge.h:
1541 2009-03-02 Eric Seidel <eric@webkit.org>
1543 Reviewed by Darin Fisher and Justin Garcia.
1545 Safari crashes during drag and drop in Google presentations
1546 due to mutation event handlers removing DOM content during insertNode
1547 https://bugs.webkit.org/show_bug.cgi?id=22634
1549 Added a bunch of "null" checks to make sure nodes are still
1550 in the document before we operate on them. This is an
1551 inelegant solution, but it's the best we have for now.
1553 Test: editing/selection/crash-on-drag-with-mutation-events.html
1555 * editing/CompositeEditCommand.cpp:
1556 (WebCore::CompositeEditCommand::insertNodeAt):
1557 * editing/ReplaceSelectionCommand.cpp:
1558 (WebCore::ReplaceSelectionCommand::doApply):
1560 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
1562 Reviewed by Adam Treat.
1564 https://bugs.webkit.org/show_bug.cgi?id=24525
1565 REGRESSION: Inspector window doesn't close when inspected page is
1566 destroyed. This is a revert of r41158, which became unnecessary when
1567 InspectorController became ref-counted in r41462.
1569 * inspector/InspectorController.cpp:
1570 (WebCore::InspectorController::inspectedPageDestroyed): Reset m_inspectedPage
1571 after calling close().
1572 (WebCore::InspectorController::stopUserInitiatedProfiling): Remove
1573 m_inspectedPage check guard around profile logic.
1575 2009-03-12 Peter Kasting <pkasting@google.com>
1577 Reviewed by Darin Fisher.
1579 https://bugs.webkit.org/show_bug.cgi?id=24502
1580 Make horizontal scrolling on Windows always go the correct direction.
1582 * platform/PlatformWheelEvent.h:
1583 * platform/win/WheelEventWin.cpp:
1584 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1586 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
1588 Reviewed by Simon Fraser.
1590 https://bugs.webkit.org/show_bug.cgi?id=24496
1591 Fix console logging of non-string values by coercing the argument to
1594 Test: fast/js/console-non-string-values.html
1596 * bindings/js/ScriptValue.cpp: Removed PlatformString include.
1597 * bindings/js/ScriptValue.h: Added toString method.
1598 (WebCore::ScriptValue::toString):
1600 (WebCore::getFirstArgumentAsString): Changed firstArgumentAsString method to use
1601 ScriptValue::toString.
1602 (WebCore::Console::addMessage): added extra ScriptState argument to callsite.
1603 (WebCore::Console::count): Ditto.
1605 2009-03-12 Simon Fraser <simon.fraser@apple.com>
1607 Reviewed by Adele Peterson.
1609 https://bugs.webkit.org/show_bug.cgi?id=24508
1611 Fix updating of text field with placeholder text when value is set
1612 by ensuring that updatePlaceholderVisibility() is called after
1613 the value has been updated, not before.
1615 Test: fast/forms/placeholder-set-value.html
1617 * html/HTMLInputElement.cpp:
1618 (WebCore::HTMLInputElement::setValue):
1620 2009-03-12 Simon Fraser <simon.fraser@apple.com>
1622 Reviewed by Dave Hyatt
1624 https://bugs.webkit.org/show_bug.cgi?id=24552
1626 Hit testing involving normal flow, self-painting layers (e.g. reflections)
1627 was broken because it was not null-testing the result of hitTestLayer(),
1628 so bailing early with a nil hit layer.
1630 Test: fast/layers/normal-flow-hit-test.html
1632 * rendering/RenderLayer.cpp:
1633 (WebCore::RenderLayer::hitTestLayer):
1635 2009-03-12 Dimitri Glazkov <dglazkov@chromium.org>
1637 Reviewed by Cameron Zwarich.
1639 Removed zero-sized files, left over from improperly applied patch.
1641 * platform/graphics/chromium/ThemeHelperChromiumWin.cpp: Removed.
1642 * platform/graphics/chromium/ThemeHelperChromiumWin.h: Removed.
1644 2009-03-12 Adam Treat <adam.treat@torchmobile.com>
1646 Reviewed by George Staikos.
1648 Do not ignore alpha color in optimization. Hard to believe, but there
1649 are websites that fill the entire page with a tiled image consisting of
1650 nothing but a 100% transparent 1x1 image. <cough>orbitz.com</cough>
1652 * platform/graphics/qt/ImageQt.cpp:
1653 (WebCore::BitmapImage::checkForSolidColor):
1655 2009-03-12 Julien Chaffraix <jchaffraix@webkit.org>
1657 Reviewed by Darin Adler.
1659 Bug 24110: cloneNode should call cloneElement and not the reverse
1661 - Splitted the code from cloneNode into cloneElementWithChildren and cloneElementWithChildren.
1662 Now cloneNode calls one of the 2 previous methods.
1664 - Renamed cloneElement to cloneElementWithoutChildren as it was the previous behaviour.
1666 - Moved cloneNode to the Element private section so that WebCore callers cannot use it.
1668 - Removed Element::cloneNode usage through WebCore.
1671 (WebCore::Element::cloneNode): Moved to Element's private section and it
1672 now calls the two next methods.
1673 (WebCore::Element::cloneElementWithChildren): Added.
1674 (WebCore::Element::cloneElementWithoutChildren): Renamed from cloneElement
1678 * editing/ApplyStyleCommand.cpp:
1679 (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded): Changed call to cloneElement
1680 to call to cloneElementWithoutChildren.
1681 * editing/BreakBlockquoteCommand.cpp:
1682 (WebCore::BreakBlockquoteCommand::doApply): Ditto.
1683 * editing/IndentOutdentCommand.cpp:
1684 (WebCore::IndentOutdentCommand::indentRegion): Ditto.
1685 * editing/InsertParagraphSeparatorCommand.cpp:
1686 (WebCore::InsertParagraphSeparatorCommand::doApply): Ditto.
1687 * editing/ModifySelectionListLevel.cpp:
1688 (WebCore::IncreaseSelectionListLevelCommand::doApply): Ditto.
1689 * editing/SplitElementCommand.cpp:
1690 (WebCore::SplitElementCommand::doApply): Ditto.
1691 * editing/markup.cpp:
1692 (WebCore::createFragmentFromText): Ditto.
1693 * svg/SVGUseElement.cpp:
1694 (WebCore::SVGUseElement::buildShadowTree): Ditto.
1695 (WebCore::SVGUseElement::expandUseElementsInShadowTree): Ditto.
1697 2009-03-12 Dirk Schulze <krit@webkit.org>
1699 Reviewed by Oliver Hunt.
1701 Fixed a crash on the 1x1 pixel check for background image in gtk.
1702 We need to load the image first and need to be sure that the image
1703 is not null before checking the type.
1705 * platform/graphics/cairo/ImageCairo.cpp:
1706 (WebCore::BitmapImage::checkForSolidColor):
1708 2009-03-12 Xan Lopez <xlopez@igalia.com>
1710 Reviewed by Alexey Proskuryakov.
1712 https://bugs.webkit.org/show_bug.cgi?id=24544
1713 Rename setUrl to setURL
1715 Use proper case for setUrl method, rename it to setURL.
1717 * platform/network/ResourceResponseBase.cpp:
1718 (WebCore::ResourceResponseBase::adopt):
1719 * platform/network/ResourceResponseBase.h:
1720 * platform/network/curl/ResourceHandleManager.cpp:
1721 (WebCore::writeCallback):
1722 (WebCore::headerCallback):
1723 * platform/network/soup/ResourceHandleSoup.cpp:
1724 (WebCore::fillResponseFromMessage):
1725 (WebCore::queryInfoCallback):
1727 2009-03-12 Xan Lopez <xlopez@igalia.com>
1729 Reviewed by Alexey Proskuryakov.
1731 https://bugs.webkit.org/show_bug.cgi?id=24519
1732 [GTK] Use two argument KURL ctor in ResourceHandleSoup
1734 Use two argument KURL ctor, the single argument ctor expects its
1735 input to be the output of a previous KURL::parse call, which is
1738 * platform/network/soup/ResourceHandleSoup.cpp:
1739 (WebCore::fillResponseFromMessage):
1740 (WebCore::queryInfoCallback):
1742 2009-03-11 Jon Honeycutt <jhoneycutt@apple.com>
1744 Fix for <rdar://6418681>
1745 https://bugs.webkit.org/show_bug.cgi?id=22644
1747 Reviewed by Steve Falkenburg.
1749 * plugins/win/PluginPackageWin.cpp:
1750 (WebCore::PluginPackage::isPluginBlacklisted): Add the Citrix ICA
1751 Client plug-in to the blacklist; it requires a Mozilla-based browser.
1753 2009-03-12 Oliver Hunt <oliver@apple.com>
1755 Reviewed by NOBODY (build fix).
1759 * html/CanvasRenderingContext2D.h:
1761 2009-03-11 Oliver Hunt <oliver@apple.com>
1763 Reviewed by Adele Peterson.
1765 <rdar://problem/6673852> Widget "Simple World Clock" does not display with Safari 4
1767 A number of dashboard widgets rely on canvas failing silently when given invalid
1768 colors for gradient stops, but both the spec and firefox throw exceptions here.
1769 So we work around this by creating a dashboard quirk that will only suppress the
1770 exception in dashboard compatibility mode.
1772 Test: fast/canvas/canvas-gradient-addStop-error.html
1774 * html/CanvasGradient.cpp:
1775 (WebCore::CanvasGradient::CanvasGradient):
1776 (WebCore::CanvasGradient::addColorStop):
1777 * html/CanvasGradient.h:
1778 (WebCore::CanvasGradient::setDashboardCompatibilityMode):
1779 * html/CanvasRenderingContext2D.cpp:
1780 (WebCore::CanvasRenderingContext2D::prepareGradientForDashboard):
1781 (WebCore::CanvasRenderingContext2D::createLinearGradient):
1782 (WebCore::CanvasRenderingContext2D::createRadialGradient):
1783 * html/CanvasRenderingContext2D.h:
1785 2009-03-11 David Kilzer <ddkilzer@apple.com>
1787 Clarify comments regarding order of FEATURE_DEFINES
1789 Rubber-stamped by Mark Rowe.
1791 * Configurations/WebCore.xcconfig: Added warning about the
1792 consequences when FEATURE_DEFINES are not kept in sync.
1794 2009-03-11 Gustavo Noronha Silva <gns@gnome.org>
1796 Reviewed by Holger Freyther.
1798 https://bugs.webkit.org/show_bug.cgi?id=24515
1799 [GTK] soup backend should use GMappedFile instead of mmap directly
1801 Rewrite mmap code used to upload files to use GMappedFile, so that
1802 it is platform-independent.
1804 * platform/network/soup/ResourceHandleSoup.cpp:
1805 (WebCore::ResourceHandle::startHttp):
1807 2009-03-11 Dan Bernstein <mitz@apple.com>
1809 Reviewed by Darin Adler.
1811 - WebCore part of fixing <rdar://problem/3919124> Thai text selection
1812 in Safari is incorrect
1814 Test: platform/mac/editing/selection/word-thai.html
1816 Tested on Mac, but should work on all ICU platforms (or more precisely
1817 on all platforms that implement
1818 WTF::Unicode::hasLineBreakingPropertyComplexContext() correctly).
1820 * editing/TextIterator.cpp:
1821 (WebCore::BackwardsCharacterIterator::BackwardsCharacterIterator):
1823 (WebCore::BackwardsCharacterIterator::range): Added.
1824 (WebCore::BackwardsCharacterIterator::advance): Added.
1826 * editing/TextIterator.h: Added BackwardsCharacterIterator with the
1827 minimal functionality required for this patch.
1828 (WebCore::BackwardsCharacterIterator::atEnd): Added.
1830 * editing/visible_units.cpp:
1831 (WebCore::firstNonComplexContextLineBreak): Added this helper function
1832 that returns the index of the first character in the string whose
1833 Unicode line breaking property value is not SA ("Complex Context"), or
1834 the length of the string if there is no such character.
1835 (WebCore::lastNonComplexContextLineBreak): Added this helper function
1836 that returns the index of the last character in the string whose
1837 Unicode line breaking property value is not SA ("Complex Context"), or
1838 -1 if there is no such character.
1839 (WebCore::previousBoundary): Changed the signature of the search
1840 function to include an offset parameter. Renamed the 'exception' local
1841 variable to 'ec' and changed its type to ExceptionCode. Extend the
1842 string forwards until the first character with Unicode line breaking
1843 property value other than SA. This gives the boundary search function
1844 enough context in the forward direction. Changed to use a
1845 BackwardsCharacterIterator for translating the backwards offset into
1847 (WebCore::nextBoundary): Changed the signature of the search
1848 function to include an offset parameter. Extend the string backwards
1849 until the first character with Unicode line breaking property value
1850 other than SA. This gives the boundary search function enough context in
1851 the backwards direction. Restricted the workaround for <rdar://5192593>
1852 only to the line break case, because it was causing an extra character
1853 to be selected following a word that ended with a combining mark.
1854 (WebCore::startWordBoundary): Added an offset parameter. Check that
1855 going backwards from the given offset, there is a character with Unicode
1856 line breaking property value other than SA, and otherwise return 0 to
1857 request more context.
1858 (WebCore::endWordBoundary): Similar, but in reverse.
1859 (WebCore::previousWordPositionBoundary): Similar.
1860 (WebCore::nextWordPositionBoundary): Similar.
1861 (WebCore::startSentenceBoundary): Updated for the new search function
1863 (WebCore::endSentenceBoundary): Ditto.
1864 (WebCore::previousSentencePositionBoundary): Ditto.
1865 (WebCore::nextSentencePositionBoundary): Ditto.
1867 2009-03-11 Darin Adler <darin@apple.com>
1869 Reviewed by Mark Rowe.
1871 Don't use "::" in thread names because it is ugly!
1873 * loader/icon/IconDatabase.cpp:
1874 (WebCore::IconDatabase::open): Use "WebCore: " instead of "WebCore::".
1875 * platform/network/cf/ResourceHandleCFNet.cpp:
1876 (WebCore::ResourceHandle::loaderRunLoop): Call this "WebCore: CFNetwork Loader" to make
1877 it clear this is a WebCore-created thread.
1878 * storage/DatabaseThread.cpp:
1879 (WebCore::DatabaseThread::start): Use "WebCore: " instead of "WebCore::".
1880 * storage/LocalStorageThread.cpp:
1881 (WebCore::LocalStorageThread::start): Use "WebCore: " instead of "WebCore::".
1882 * workers/WorkerThread.cpp:
1883 (WebCore::WorkerThread::start): Use "WebCore: " instead of "WebCore::".
1885 2009-03-11 Mark Rowe <mrowe@apple.com>
1887 Rubber-stamped by Darin Adler.
1889 <rdar://problem/6653286> WebCore's implementation of screenIsMonochrome is needlessly complex
1891 * platform/mac/PlatformScreenMac.mm:
1892 (WebCore::screenIsMonochrome): Return false.
1894 2009-03-11 Beth Dakin <bdakin@apple.com>
1896 Reviewed by Dan Bernstein.
1898 Fix for https://bugs.webkit.org/show_bug.cgi?id=14749 percentage
1899 top value on position:relative child not calculated correctly if
1900 parent has percentage height
1901 - and corresponding -
1902 <rdar://problem/6172925>
1904 * rendering/RenderBoxModelObject.cpp:
1905 (WebCore::RenderBoxModelObject::relativePositionOffsetY):
1907 2009-03-11 Jian Li <jianli@chromium.org>
1909 Reviewed by Dimitri Glazkov.
1911 Implement ScriptValue::hasNoValue for V8.
1912 https://bugs.webkit.org/show_bug.cgi?id=24507
1914 * bindings/v8/ScriptValue.h:
1915 (WebCore::ScriptValue::hasNoValue):
1917 2009-03-11 David Levin <levin@chromium.org>
1919 Reviewed by Dimitri Glazkov.
1921 Bug 24459: Add v8 bindings for event.
1922 <https://bugs.webkit.org/show_bug.cgi?id=24459>
1924 Adding custom event bindings.
1926 * bindings/v8/custom/V8AbstractEventListener.cpp: Added.
1927 * bindings/v8/custom/V8AbstractEventListener.h: Added.
1928 * bindings/v8/custom/V8AttrCustom.cpp:
1929 Fixed messed up copyright header.
1930 * bindings/v8/custom/V8CustomEventListener.cpp: Added.
1931 * bindings/v8/custom/V8CustomEventListener.h:
1932 Replaced forwarding header with the real implementation.
1933 * bindings/v8/custom/V8ElementCustom.cpp:
1934 * bindings/v8/custom/V8LazyEventListener.cpp: Added.
1935 * bindings/v8/custom/V8LazyEventListener.h: Added.
1936 * bindings/v8/custom/V8ObjectEventListener.cpp: Added.
1937 * bindings/v8/custom/V8ObjectEventListener.h: Added.
1938 * bindings/v8/custom/V8WorkerContextEventListener.cpp: Added.
1939 * bindings/v8/custom/V8WorkerContextEventListener.h: Added.
1941 2009-03-11 Darin Fisher <darin@chromium.org>
1943 Reviewed by Dimitri Glazkov.
1945 https://bugs.webkit.org/show_bug.cgi?id=24521
1946 Add some missing includes for the non-JSC build.
1948 * platform/text/PlatformString.h: added OwnPtr.h
1949 * xml/XMLHttpRequest.cpp: added SecurityOrigin.h
1951 2009-03-11 Simon Fraser <simon.fraser@apple.com>
1953 Reviewed by Darin Adler
1955 https://bugs.webkit.org/show_bug.cgi?id=24531
1957 Make sure that AnimationControllerPrivate::getAnimatedStyleForRenderer() never
1958 returns a null style if it has a valid renderer, which could happen if a
1959 CompositeAnimation existed, but wasn't running any animations or transitions.
1961 * page/animation/AnimationController.cpp:
1962 (WebCore::AnimationControllerPrivate::getAnimatedStyleForRenderer):
1964 2009-03-11 Simon Fraser <simon.fraser@apple.com>
1966 Fix Scons build. Patch from Alexander Guy.
1970 2009-03-11 Simon Fraser <simon.fraser@apple.com>
1972 Reviewed by Dan Bernstein
1974 https://bugs.webkit.org/show_bug.cgi?id=23093
1976 When the cancel button in the search field is shown or hidden,
1977 we need to explicitly setStyle() on the cancel button's renderer,
1978 to ensure that repaint happens. Changing the style without telling
1979 the renderer won't work.
1981 Test: fast/repaint/search-field-cancel.html
1983 * rendering/RenderTextControlSingleLine.cpp:
1984 (WebCore::RenderTextControlSingleLine::subtreeHasChanged):
1985 (WebCore::RenderTextControlSingleLine::updateFromElement):
1986 (WebCore::RenderTextControlSingleLine::createCancelButtonStyle):
1987 (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility):
1988 (WebCore::RenderTextControlSingleLine::visibilityForCancelButton):
1989 * rendering/RenderTextControlSingleLine.h:
1991 2009-03-11 Hironori Bono <hbono@chromium.org>
1993 Reviewed by Alexey Proskuryakov.
1995 https://bugs.webkit.org/show_bug.cgi?id=15790
1996 Ligatures aren't accounted for when manipulating VisiblePositions
1998 Changed cursorMovementIterator rules to prevent a cursor from moving in the middle of an
1999 Indic ligature which uses a virama sign.
2001 Test: editing/deleting/skip-virama-001.html
2003 * platform/text/TextBreakIteratorICU.cpp:
2004 (WebCore::cursorMovementIterator):
2006 2009-03-11 Alexey Proskuryakov <ap@webkit.org>
2008 Reviewed by George Staikos.
2010 https://bugs.webkit.org/show_bug.cgi?id=24513
2011 REGRESSION: Cursor movement doesn't work on Tiger (ICU 3.2)
2013 Fixes existing tests on Tiger.
2015 * platform/text/TextBreakIteratorICU.cpp: (WebCore::cursorMovementIterator):
2016 Use characterBreakIterator on Tiger (like we used to do).
2018 2009-03-11 Alexey Proskuryakov <ap@webkit.org>
2020 Reviewed by Oliver Hunt.
2022 <rdar://problem/4072827> Downloaded non-ASCII file name becomes garbled
2024 * platform/network/mac/ResourceRequestMac.mm:
2025 (WebCore::ResourceRequest::doUpdatePlatformRequest): Correct selector name
2026 in instancesRespondToSelector.
2028 2009-03-11 Jan Michael Alonzo <jmalonzo@webkit.org>
2030 Reviewed by Holger Freyther.
2032 [GTK]DumpRenderTree doesn't compile for non-X11 GTK ports anymore
2033 https://bugs.webkit.org/show_bug.cgi?id=2260
2035 Add missing stdio.h include to get the build going
2037 * plugins/gtk/PluginPackageGtk.cpp:
2039 2009-03-10 Justin Garcia <justin.garcia@apple.com>
2041 Reviewed by Ken Kocienda.
2044 (WebCore::Range::addLineBoxRects): If the range ended at [div, 0], addLineBoxRects
2045 would include rects for the divs contents. Set the correct RenderObject to stop at.
2047 2009-03-10 Alexey Proskuryakov <ap@webkit.org>
2049 Reviewed by Sam Weinig.
2051 <rdar://problem/6123770> Restrict access to document.cookie when making a cross-site XHR
2053 * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::responseXML): Removed an incorrect
2054 comment about cookie support. Firefox doesn't expose cookies on responseXML at all, and
2055 there are security concerns with exposing them for cross-origin requests, so it's not clear
2056 if we want to change anything here.
2058 2009-03-10 Simon Fraser <simon.fraser@apple.com>
2060 Reviewed by Darin Adler
2062 https://bugs.webkit.org/show_bug.cgi?id=24503
2064 Fix hit testing of absolutely positioned single line text controls by
2065 ensuring that we set result.innerNode() correctly. If the hit node is
2066 a descendant of the inner text element or if it is the <input> itself,
2067 then we say we hit the innerTextElement.
2069 Rename hitInnerTextBlock() to hitInnerTextElement() to match the
2070 'innerTextElement' terminology used elsewhere.
2072 Assert that if renderer()->hitTest() returns false, no-one set
2075 Test: fast/forms/search-abs-pos-cancel-button.html
2077 * rendering/RenderLayer.cpp:
2078 (WebCore::RenderLayer::hitTestContents):
2079 * rendering/RenderTextControl.cpp:
2080 (WebCore::RenderTextControl::hitInnerTextElement):
2081 * rendering/RenderTextControl.h:
2082 * rendering/RenderTextControlMultiLine.cpp:
2083 (WebCore::RenderTextControlMultiLine::nodeAtPoint):
2084 * rendering/RenderTextControlSingleLine.cpp:
2085 (WebCore::RenderTextControlSingleLine::nodeAtPoint):
2087 2009-03-10 Antti Koivisto <antti@apple.com>
2089 Reviewed by Mark Rowe.
2091 <rdar://problem/6668238> WebCore is registering text encodings needlessly from KURL constructor.
2093 Another case where we would trigger extended encoding loading needlessly.
2095 * platform/text/TextEncoding.cpp:
2096 (WebCore::TextEncoding::isNonByteBasedEncoding):
2098 2009-03-10 Beth Dakin <bdakin@apple.com>
2100 Reviewed by Darin Adler.
2102 Fix for <rdar://problem/6624769> REGRESSION (Safari 4 PB): No
2103 scroll bar appears for long line of text with NOWRAP set
2105 This is a regression from http://trac.webkit.org/changeset/32226
2106 I talked with Dan about the original change, and we decided that
2107 the best fix was to remove his small potential-optimization that
2108 only created a separate line box for whitespace under certain
2109 circumstances. This new code will always create a separate line
2112 * rendering/bidi.cpp:
2113 (WebCore::RenderBlock::layoutInlineChildren):
2115 2009-03-10 Sam Weinig <sam@webkit.org>
2117 Reviewed by Geoffrey Garen.
2119 Fix for <rdar://problem/6166844>
2120 https://bugs.webkit.org/show_bug.cgi?id=24495
2122 Use same rule for loading java applets as we do for images.
2124 * html/HTMLAppletElement.cpp:
2125 (WebCore::HTMLAppletElement::createRenderer):
2126 * loader/FrameLoader.cpp:
2127 (WebCore::FrameLoader::loadItem):
2129 2009-03-10 Justin Garcia <justin.garcia@apple.com>
2131 Reviewed by David Kilzer.
2133 Get rid of revealCaret and use revealSelection instead.
2136 * editing/SelectionController.cpp:
2137 (WebCore::SelectionController::setSelection):
2139 (WebCore::Frame::revealSelection):
2142 2009-03-10 Cameron Zwarich <cwzwarich@uwaterloo.ca>
2144 Reviewed by Geoff Garen.
2146 Bug 23736: WebKit Crashes on http://g-conquest.fr/~server2
2147 <https://bugs.webkit.org/show_bug.cgi?id=23736>
2148 <rdar://problem/6560278>
2150 Before replacing the document, FrameLoader::executeIfJavaScriptURL()
2151 should call stopAllLoaders(), just like continueLoadAfterNavigationPolicy().
2153 * loader/FrameLoader.cpp:
2154 (WebCore::FrameLoader::executeIfJavaScriptURL):
2156 2009-03-10 Darin Adler <darin@apple.com>
2158 Reviewed by Alexey Proskuryakov.
2160 Bug 24494: crash when deleting at end of document and merging paragraphs
2161 https://bugs.webkit.org/show_bug.cgi?id=24494
2162 rdar://problem/6571537
2164 Test: editing/deleting/merge-at-end-of-document.html
2167 (WebCore::Range::compareBoundaryPoints): Split out assertion. It's better not to
2168 use && in assertions since we'd like to know which condition is failing.
2170 * editing/ApplyStyleCommand.cpp:
2171 (WebCore::ApplyStyleCommand::applyInlineStyleToRange): Added a null check before
2172 calling compareBoundaryPoints, since a 0 for the node is ambiguous and so the
2173 function doesn't know which value to return.
2175 2009-03-10 Dirk Schulze <krit@webkit.org>
2177 Reviewed by Eric Seidel. Math checked by Oliver Hunt.
2179 Implement the Cairo version of the checkForSolidColor() method. This halfes the
2180 time to draw on 1x1 px background images.
2181 I added two new calls to Color for the pixel manipulation on cairo_surface's.
2182 They are neede to premultiply/unpremultiply the colors of the surface.
2184 [CAIRO] Introduce single-pixel image optimizations
2185 https://bugs.webkit.org/show_bug.cgi?id=17284
2187 * platform/graphics/Color.cpp:
2188 (WebCore::colorFromPremultipliedARGB):
2189 (WebCore::premultipliedARGBFromColor):
2190 * platform/graphics/Color.h:
2191 * platform/graphics/cairo/ImageBufferCairo.cpp:
2192 (WebCore::ImageBuffer::getImageData):
2193 (WebCore::ImageBuffer::putImageData):
2194 * platform/graphics/cairo/ImageCairo.cpp:
2195 (WebCore::BitmapImage::checkForSolidColor):
2197 2009-03-06 Darin Fisher <darin@chromium.org>
2199 Reviewed by Sam Weinig.
2201 https://bugs.webkit.org/show_bug.cgi?id=24437
2203 Add support for registering noAccess URL schemes:
2204 1- Add FrameLoader::registerURLSchemeAsNoAccess, and have SecurityOrigin check
2205 that list upon construction (similar to how isLocal is implemented).
2206 2- Make InspectorController call grantUniversalAccess on its Document's
2207 SecurityOrigin at the time when windowScriptObjectAvailable is called.
2209 This enables content such as the inspector to be loaded from a custom (non-file)
2210 URL, which is how Chromium loads the inspector. It also allows other URL schemes
2211 to be treated like data: URLs, which Chromium utilizes for its various HTML-based
2214 * inspector/InspectorController.cpp:
2215 (WebCore::InspectorController::windowScriptObjectAvailable):
2216 * loader/FrameLoader.cpp:
2217 (WebCore::localSchemes):
2218 (WebCore::noAccessSchemes):
2219 (WebCore::FrameLoader::loadItem):
2220 * loader/FrameLoader.h:
2221 * page/SecurityOrigin.cpp:
2222 (WebCore::SecurityOrigin::SecurityOrigin):
2223 (WebCore::SecurityOrigin::isLocal):
2225 2009-03-10 Xan Lopez <xlopez@igalia.com>
2227 Build fix, no review
2229 * page/mac/AccessibilityObjectWrapper.mm:
2230 (textMarkerForVisiblePosition):
2231 (visiblePositionForTextMarker):
2233 2009-03-10 Xan Lopez <xlopez@igalia.com>
2235 Reviewed by Darin Adler.
2237 https://bugs.webkit.org/show_bug.cgi?id=24491
2238 Rename posOffset to m_offset, get rid of accessor
2240 As suggested in dom/Position.h, this patch gets rid of the
2241 'offset()' accessor and renames posOffset to m_offset. I've used
2242 m_offset instead of offset to follow the style guide lines, since
2243 Position is still a class and not a structure. If the long term
2244 plan is still to make it a structure it would be pretty easy to
2245 just s/m_offset/offset/ globally when that is achieved.
2248 (WebCore::Position::previous):
2249 (WebCore::Position::next):
2250 (WebCore::Position::atStart):
2251 (WebCore::Position::atEnd):
2252 (WebCore::Position::renderedOffset):
2253 (WebCore::Position::isCandidate):
2254 (WebCore::Position::inRenderedText):
2255 (WebCore::Position::isRenderedCharacter):
2256 (WebCore::Position::rendersInDifferentPosition):
2257 (WebCore::Position::leadingWhitespacePosition):
2258 (WebCore::Position::debugPosition):
2259 (WebCore::Position::formatForDebugger):
2261 (WebCore::Position::Position):
2262 * dom/PositionIterator.h:
2263 (WebCore::PositionIterator::PositionIterator):
2265 * dom/RangeBoundaryPoint.h:
2266 (WebCore::RangeBoundaryPoint::position):
2267 (WebCore::RangeBoundaryPoint::set):
2268 (WebCore::RangeBoundaryPoint::setOffset):
2269 (WebCore::RangeBoundaryPoint::setToChild):
2270 (WebCore::RangeBoundaryPoint::setToStart):
2271 (WebCore::RangeBoundaryPoint::setToEnd):
2272 (WebCore::RangeBoundaryPoint::childBeforeWillBeRemoved):
2273 * editing/ApplyStyleCommand.cpp:
2274 (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
2275 (WebCore::ApplyStyleCommand::applyInlineStyleToRange):
2276 (WebCore::ApplyStyleCommand::removeInlineStyle):
2277 (WebCore::ApplyStyleCommand::nodeFullySelected):
2278 (WebCore::ApplyStyleCommand::nodeFullyUnselected):
2279 (WebCore::ApplyStyleCommand::splitTextAtStartIfNeeded):
2280 (WebCore::ApplyStyleCommand::splitTextAtEndIfNeeded):
2281 (WebCore::ApplyStyleCommand::splitTextElementAtStartIfNeeded):
2282 (WebCore::ApplyStyleCommand::splitTextElementAtEndIfNeeded):
2283 (WebCore::ApplyStyleCommand::mergeStartWithPreviousIfIdentical):
2284 (WebCore::ApplyStyleCommand::mergeEndWithNextIfIdentical):
2285 (WebCore::ApplyStyleCommand::joinChildTextNodes):
2286 * editing/BreakBlockquoteCommand.cpp:
2287 (WebCore::BreakBlockquoteCommand::doApply):
2288 * editing/CompositeEditCommand.cpp:
2289 (WebCore::CompositeEditCommand::insertNodeAt):
2290 (WebCore::CompositeEditCommand::positionOutsideTabSpan):
2291 (WebCore::CompositeEditCommand::rebalanceWhitespaceAt):
2292 (WebCore::CompositeEditCommand::prepareWhitespaceAtPositionForSplit):
2293 (WebCore::CompositeEditCommand::deleteInsignificantText):
2294 (WebCore::CompositeEditCommand::removePlaceholderAt):
2295 (WebCore::CompositeEditCommand::moveParagraphs):
2296 (WebCore::CompositeEditCommand::breakOutOfEmptyMailBlockquotedParagraph):
2297 * editing/DeleteSelectionCommand.cpp:
2298 (WebCore::updatePositionForNodeRemoval):
2299 (WebCore::updatePositionForTextRemoval):
2300 (WebCore::DeleteSelectionCommand::handleGeneralDelete):
2301 (WebCore::DeleteSelectionCommand::fixupWhitespace):
2302 * editing/Editor.cpp:
2303 (WebCore::Editor::setComposition):
2304 (WebCore::Editor::advanceToNextMisspelling):
2305 (WebCore::Editor::getCompositionSelection):
2306 * editing/InsertLineBreakCommand.cpp:
2307 (WebCore::InsertLineBreakCommand::doApply):
2308 * editing/InsertParagraphSeparatorCommand.cpp:
2309 (WebCore::InsertParagraphSeparatorCommand::doApply):
2310 * editing/InsertTextCommand.cpp:
2311 (WebCore::InsertTextCommand::performTrivialReplace):
2312 (WebCore::InsertTextCommand::input):
2313 (WebCore::InsertTextCommand::insertTab):
2314 * editing/MoveSelectionCommand.cpp:
2315 (WebCore::MoveSelectionCommand::doApply):
2316 * editing/ReplaceSelectionCommand.cpp:
2317 (WebCore::ReplaceSelectionCommand::doApply):
2318 * editing/SelectionController.cpp:
2319 (WebCore::SelectionController::debugRenderer):
2320 * editing/TextIterator.cpp:
2321 (WebCore::TextIterator::rangeFromLocationAndLength):
2322 * editing/TypingCommand.cpp:
2323 (WebCore::TypingCommand::deleteKeyPressed):
2324 (WebCore::TypingCommand::forwardDeleteKeyPressed):
2325 * editing/VisiblePosition.cpp:
2326 (WebCore::VisiblePosition::characterAfter):
2327 (WebCore::VisiblePosition::debugPosition):
2328 (WebCore::makeRange):
2329 (WebCore::setStart):
2331 * editing/VisibleSelection.cpp:
2332 (WebCore::VisibleSelection::toNormalizedRange):
2333 (WebCore::makeSearchRange):
2334 (WebCore::VisibleSelection::debugPosition):
2335 (WebCore::VisibleSelection::showTreeForThis):
2336 * editing/htmlediting.cpp:
2337 (WebCore::comparePositions):
2338 (WebCore::rangeCompliantEquivalent):
2339 (WebCore::isFirstPositionAfterTable):
2340 (WebCore::isLastPositionBeforeTable):
2341 * editing/visible_units.cpp:
2342 (WebCore::previousBoundary):
2343 (WebCore::nextBoundary):
2344 (WebCore::startPositionForLine):
2345 (WebCore::startOfLine):
2346 (WebCore::endPositionForLine):
2347 (WebCore::nextLinePosition):
2348 (WebCore::startOfParagraph):
2349 (WebCore::endOfParagraph):
2350 * page/AccessibilityObject.cpp:
2351 (WebCore::updateAXLineStartForVisiblePosition):
2352 * page/AccessibilityRenderObject.cpp:
2353 (WebCore::AccessibilityRenderObject::indexForVisiblePosition):
2354 * page/DOMSelection.cpp:
2355 (WebCore::DOMSelection::anchorOffset):
2356 (WebCore::DOMSelection::baseOffset):
2357 (WebCore::DOMSelection::focusOffset):
2358 (WebCore::DOMSelection::extentOffset):
2359 * page/EventHandler.cpp:
2360 (WebCore::EventHandler::handleMousePressEventSingleClick):
2362 (WebCore::Frame::selectionLayoutChanged):
2363 * rendering/RenderTextControl.cpp:
2364 (WebCore::RenderTextControl::indexForVisiblePosition):
2365 * rendering/RenderTreeAsText.cpp:
2366 (WebCore::writeSelection):
2368 2009-03-10 Darin Adler <darin@apple.com>
2370 Reviewed by Dan Bernstein.
2372 Bug 23564: REGRESSION (r39230-39286): crash loading page that changes <input> display type and then calls innerHTML
2373 https://bugs.webkit.org/show_bug.cgi?id=23564
2374 rdar://problem/6537238
2376 Test: fast/dom/HTMLElement/innerHTML-selection-crash.html
2378 * editing/markup.cpp: (WebCore::createMarkup): Added updateLayoutIgnorePendingStylesheets
2379 call to the one of the two overloads of this function that wasn't calling it. This fixes
2380 this crash and other possible crashes inside innerHTML.
2382 2009-03-10 Alexey Proskuryakov <ap@webkit.org>
2384 Reviewed by Darin Adler.
2386 https://bugs.webkit.org/show_bug.cgi?id=24285
2387 Text resource loading checks for BOM twice
2389 This removes TextDecoder class, since its only purpose was to check for BOM, which is
2390 already done in TextResourceDecoder. Callers that use TextEncoding::decode() won't get
2391 BOM checked, but I didn't find any cases where it would significantly change behavior.
2396 * WebCore.vcproj/WebCore.vcproj:
2397 * WebCore.xcodeproj/project.pbxproj:
2398 * WebCoreSources.bkl:
2399 Remove TextDecoder.{h,cpp}.
2401 * platform/text/TextDecoder.cpp: Removed.
2402 * platform/text/TextDecoder.h: Removed.
2404 * loader/TextResourceDecoder.h: Instead of a TextDecoder object, keep TextEncoding and
2405 TextCodec separately.
2407 * loader/TextResourceDecoder.cpp:
2408 (WebCore::TextResourceDecoder::TextResourceDecoder): Updated for m_encoding being a member.
2409 (WebCore::TextResourceDecoder::setEncoding): Ditto.
2410 (WebCore::TextResourceDecoder::checkForBOM): Removed a FIXME saying that a BOM could override
2411 even a user-chosen encoding - this is how it already worked due to TextDecoder checking for
2412 BOM again. Made this function return the detected BOM length.
2413 (WebCore::TextResourceDecoder::decode): Skip the BOM if it was found at the beginning of
2415 (WebCore::TextResourceDecoder::flush): Reset m_checkedForBOM, so that re-decoding the same
2416 resource again (as frequently done by CachedResource subclasses) will skip the BOM correctly.
2418 * platform/text/TextEncoding.cpp: (WebCore::TextEncoding::decode):
2419 Use TextCodec directly without a TextDecoder wrapper. This means that this method no longer
2420 checks for BOM, which was a counter-intuitive feature.
2422 * loader/CachedScript.cpp:
2423 (WebCore::CachedScript::CachedScript):
2424 (WebCore::CachedScript::setEncoding):
2425 (WebCore::CachedScript::encoding):
2426 (WebCore::CachedScript::script):
2427 * loader/CachedScript.h:
2428 * loader/appcache/ManifestParser.cpp:
2429 (WebCore::parseManifest):
2430 Use TextResourceDecoder, as TextEncoding::decode() no longer checks for BOM.
2431 A side effect of this is that these resources will now be subject to encoding auto-detection.
2433 * loader/CachedFont.cpp: (WebCore::CachedFont::ensureSVGFontData):
2434 * page/Page.cpp: (WebCore::Page::userStyleSheet):
2435 Be sure to flush TextResourceDecoder, pushing any remaining bytes out, and making the decoder
2436 re-usable (for repeated decoding of the same resource).
2438 * platform/text/TextEncodingRegistry.h: Updated comments for newTextCodec().
2440 2009-03-10 Alexey Proskuryakov <ap@webkit.org>
2442 Reviewed by Darin Adler.
2444 https://bugs.webkit.org/show_bug.cgi?id=24488
2445 An assertion failure when updating an offline application cache after emptying caches
2447 Emptying appcache cannot be performed automatically, so no test.
2449 * loader/appcache/ApplicationCacheGroup.cpp:
2450 (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete): Ensure that the cache is in disk
2451 storage, even if the application wasn't updated server side.
2453 2009-03-10 Oliver Hunt <oliver@apple.com>
2455 Reviewed by Alexey Proskuryakov.
2457 <rdar://problem/6425807> Implement WorkerUtils.importScripts()
2458 <https://bugs.webkit.org/show_bug.cgi?id=22721>
2460 Implement importScripts, currently uses a series of synchronous loads
2461 to fetch the scripts, but this is simpler than a synchronous load of
2462 multiple loads in parallel. In future we'll want to switch to parallel
2463 loading, but this will do for now.
2465 Test: http/tests/workers/worker-importScripts.html
2468 * WebCore.vcproj/WebCore.vcproj:
2469 * WebCore.xcodeproj/project.pbxproj:
2470 * bindings/js/JSWorkerContextCustom.cpp:
2471 (WebCore::JSWorkerContext::importScripts):
2472 * bindings/js/ScriptValue.h:
2473 (WebCore::ScriptValue::hasNoValue):
2474 * bindings/js/WorkerScriptController.cpp:
2475 (WebCore::WorkerScriptController::evaluate):
2476 (WebCore::WorkerScriptController::setException):
2477 * bindings/js/WorkerScriptController.h:
2479 (WebCore::Document::scriptImported):
2481 * dom/ScriptExecutionContext.h:
2482 * inspector/InspectorController.cpp:
2483 (WebCore::InspectorController::scriptImported):
2484 * inspector/InspectorController.h:
2485 * inspector/InspectorResource.cpp:
2486 (WebCore::InspectorResource::setScriptProperties):
2487 * inspector/InspectorResource.h:
2488 * workers/WorkerContext.cpp:
2489 (WebCore::WorkerContext::scriptImported):
2490 (WebCore::WorkerContext::importScripts):
2491 * workers/WorkerContext.h:
2492 * workers/WorkerContext.idl:
2493 * workers/WorkerImportScriptsClient.cpp: Added.
2494 (WebCore::WorkerImportScriptsClient::didReceiveResponse):
2495 (WebCore::WorkerImportScriptsClient::didReceiveData):
2496 (WebCore::WorkerImportScriptsClient::didFinishLoading):
2497 (WebCore::WorkerImportScriptsClient::didFail):
2498 (WebCore::WorkerImportScriptsClient::didFailRedirectCheck):
2499 (WebCore::WorkerImportScriptsClient::didReceiveAuthenticationCancellation):
2500 * workers/WorkerImportScriptsClient.h: Added.
2501 (WebCore::WorkerImportScriptsClient::WorkerImportScriptsClient):
2502 (WebCore::WorkerImportScriptsClient::script):
2503 (WebCore::WorkerImportScriptsClient::failed):
2505 2009-03-10 Alexey Proskuryakov <ap@webkit.org>
2507 Reviewed by Darin Adler.
2509 https://bugs.webkit.org/show_bug.cgi?id=24462
2510 Move cross-origin access control code out of XMLHttpRequest
2512 Step 1: move preflight result cache and access control helper functions.
2514 No change in behavior, so no test.
2519 * WebCore.vcproj/WebCore.vcproj:
2520 * WebCore.xcodeproj/project.pbxproj:
2521 * WebCoreSources.bkl:
2522 * loader/CrossOriginAccessControl.cpp: Added.
2523 (WebCore::isOnAccessControlSimpleRequestHeaderWhitelist):
2524 (WebCore::isSimpleCrossOriginAccessRequest):
2525 (WebCore::createAllowedCrossOriginResponseHeadersSet):
2526 (WebCore::isOnAccessControlResponseHeaderWhitelist):
2527 (WebCore::passesAccessControlCheck):
2528 * loader/CrossOriginAccessControl.h: Added.
2529 * loader/CrossOriginPreflightResultCache.cpp: Added.
2530 (WebCore::parseAccessControlMaxAge):
2531 (WebCore::addToAccessControlAllowList):
2532 (WebCore::parseAccessControlAllowList):
2533 (WebCore::CrossOriginPreflightResultCacheItem::parse):
2534 (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginMethod):
2535 (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders):
2536 (WebCore::CrossOriginPreflightResultCacheItem::allowsRequest):
2537 (WebCore::CrossOriginPreflightResultCache::shared):
2538 (WebCore::CrossOriginPreflightResultCache::appendEntry):
2539 (WebCore::CrossOriginPreflightResultCache::canSkipPreflight):
2540 * loader/CrossOriginPreflightResultCache.h: Added.
2541 (WebCore::CrossOriginPreflightResultCacheItem::CrossOriginPreflightResultCacheItem):
2542 (WebCore::CrossOriginPreflightResultCache::CrossOriginPreflightResultCache):
2543 * xml/XMLHttpRequest.cpp:
2544 (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData):
2545 (WebCore::XMLHttpRequest::createRequest):
2546 (WebCore::XMLHttpRequest::makeCrossOriginAccessRequest):
2547 (WebCore::XMLHttpRequest::makeSimpleCrossOriginAccessRequest):
2548 (WebCore::XMLHttpRequest::makeCrossOriginAccessRequestWithPreflight):
2549 (WebCore::XMLHttpRequest::didReceiveResponse):
2550 (WebCore::XMLHttpRequest::didReceiveResponsePreflight):
2551 * xml/XMLHttpRequest.h:
2553 2009-03-10 Alexey Proskuryakov <ap@webkit.org>
2555 Reviewed by Darin Adler.
2557 https://bugs.webkit.org/show_bug.cgi?id=19797
2558 Bring the list of forbidden headers in sync with XMLHttpRequest spec draft
2560 Added new checks to http/tests/xmlhttprequest/set-dangerous-headers.html.
2562 * xml/XMLHttpRequest.cpp:
2563 (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData): Added all headers from
2564 XMLHttpRequest 2 draft.
2566 2009-03-10 Dan Bernstein <mitz@apple.com>
2568 Reviewed by Adele Peterson.
2570 - fix https://bugs.webkit.org/show_bug.cgi?id=23975
2571 <rdar://problem/6593610> REGRESSION: Scrollbar arrow not repainted
2573 * rendering/RenderLayer.cpp:
2574 (WebCore::RenderLayer::invalidateScrollbarRect): Corrected the vertical
2575 scrollbar rect calculation.
2577 2009-03-09 Simon Fraser <simon.fraser@apple.com>
2579 Reviewed by Dan Bernstein, Oliver Hunt
2581 https://bugs.webkit.org/show_bug.cgi?id=24475
2583 When repainting replaced elements, need to union the selection
2584 and overflow rects because either may extend outside the other.
2586 Test: fast/repaint/transform-replaced-shadows.html
2588 * rendering/RenderReplaced.cpp:
2589 (WebCore::RenderReplaced::clippedOverflowRectForRepaint):
2591 2009-03-09 Stephanie Lewis <slewis@apple.com>
2595 * editing/Editor.cpp:
2596 (WebCore::Editor::advanceToNextMisspelling):
2597 (WebCore::markAllMisspellingsAndBadGrammarInRanges):
2599 2009-03-09 Kim Christensen <kimworking@gmail.com>
2601 Reviewed by Darin Fisher.
2603 https://bugs.webkit.org/show_bug.cgi?id=24276
2604 Dropdown / select boxes do not consider the windows task bar in Chromium.
2606 * platform/chromium/PopupMenuChromium.cpp:
2607 (WebCore::PopupContainer::showPopup):
2609 2009-03-09 Dan Bernstein <mitz@apple.com>
2611 Reviewed by Adele Peterson and Dave Hyatt.
2613 - fix <rdar://problem/6654344> REGRESSION (r41041): Zillow.com has
2614 misaligned edit fields
2616 Test: fast/forms/legend-display-none.html
2618 * css/CSSStyleSelector.cpp:
2619 (WebCore::CSSStyleSelector::adjustRenderStyle): Change the display
2620 property of legend elements to 'block' unless it is 'none'.
2621 * css/html4.css: Do not force the display property of legend elements to
2622 'block' using CSS, because that prevents style rules from setting it to
2625 2009-03-09 Alpha Lam <hclam@chromium.org>
2627 Reviewed by Dave Hyatt.
2629 https://bugs.webkit.org/show_bug.cgi?id=23024
2631 Fix an incorrect criteria in the if statement that leaves references to
2632 deleted floating objects in RenderBlock.
2634 Test: fast/block/float/crash-on-absolute-positioning.html
2636 * rendering/RenderBlock.cpp:
2637 (WebCore::RenderBlock::markAllDescendantsWithFloatsForLayout):
2639 2009-03-09 Mike Belshe <mike@belshe.com>
2641 Reviewed by Eric Seidel.
2643 Unify JSC/V8 idl file.
2644 https://bugs.webkit.org/show_bug.cgi?id=24424
2646 * page/Location.idl:
2648 2009-03-09 Mike Belshe <mike@belshe.com>
2650 Reviewed by Eric Seidel.
2652 Unify JSC/V8 for History.idl.
2656 2009-03-09 Mike Belshe <mike@belshe.com>
2658 Reviewed by Eric Seidel.
2660 Unify JSC/V8 implementations of DOMWindow.idl.
2662 * page/DOMWindow.idl:
2664 2009-03-09 Simon Fraser <simon.fraser@apple.com>
2666 Reviewed by Dave Hyatt
2668 https://bugs.webkit.org/show_bug.cgi?id=24163
2670 Implement mapping of FloatQuads through 3D transforms.
2672 Removed the redundant localToContainerQuad() methods, which can now
2673 shared code with the old mapLocalToAbsolutePoint(), which was
2674 renamed to mapLocalToContainer(). This can now convert a point,
2675 and optionally a FloatQuad, which are carried along in the TransformState.
2677 Optimized TransformState to reduce to simple FloatPoint.move()
2678 if there are no transforms, and to heap-allocate a transform only if
2679 necessary to accumulate transforms (when using preserve-3d).
2681 Tested by 3d point mapping tests, and the inspector highlight (which now shows
2682 the correct quads for 3d-transformed elements).
2684 * platform/graphics/transforms/TransformationMatrix.cpp:
2685 (WebCore::TransformationMatrix::projectQuad):
2686 (WebCore::TransformationMatrix::translateRight):
2687 (WebCore::TransformationMatrix::translateRight3d):
2688 * platform/graphics/transforms/TransformationMatrix.h:
2689 * rendering/RenderBox.cpp:
2690 (WebCore::RenderBox::mapLocalToContainer):
2691 (WebCore::RenderBox::mapAbsoluteToLocalPoint):
2692 * rendering/RenderBox.h:
2693 * rendering/RenderObject.cpp:
2694 (WebCore::RenderObject::localToAbsolute):
2695 (WebCore::RenderObject::absoluteToLocal):
2696 (WebCore::RenderObject::mapLocalToContainer):
2697 (WebCore::RenderObject::localToContainerQuad):
2698 * rendering/RenderObject.h:
2699 * rendering/RenderTableCell.cpp:
2700 (WebCore::RenderTableCell::mapLocalToContainer):
2701 * rendering/RenderTableCell.h:
2702 * rendering/RenderView.cpp:
2703 (WebCore::RenderView::mapLocalToContainer):
2704 * rendering/RenderView.h:
2705 * rendering/TransformState.cpp:
2706 (WebCore::TransformState::move):
2707 (WebCore::TransformState::applyTransform):
2708 (WebCore::TransformState::flatten):
2709 (WebCore::TransformState::mappedPoint):
2710 (WebCore::TransformState::mappedQuad):
2711 (WebCore::TransformState::flattenWithTransform):
2712 (WebCore::HitTestingTransformState::mappedQuad):
2713 * rendering/TransformState.h:
2714 (WebCore::TransformState::TransformState):
2715 (WebCore::TransformState::move):
2716 (WebCore::TransformState::lastPlanarPoint):
2717 (WebCore::TransformState::lastPlanarQuad):
2718 * rendering/style/RenderStyle.h:
2719 (WebCore::InheritedFlags::preserves3D):
2721 2009-03-09 Simon Fraser <simon.fraser@apple.com>
2723 Reviewed by Dave Hyatt
2725 https://bugs.webkit.org/show_bug.cgi?id=24433
2727 During hit testing with transforms, if a layer has backface-visibility: hidden,
2728 we need to check for it whether or not the layer has a transform, because it
2729 might be an ancestor that is transformed.
2731 Test: transforms/3d/hit-testing/backface-no-transform-hit-test.html
2733 * rendering/RenderLayer.cpp:
2734 (WebCore::RenderLayer::hitTestLayer):
2736 2009-03-09 Laszlo Gombos <laszlo.1.gombos@nokia.com>
2738 Reviewed by George Staikos.
2740 https://bugs.webkit.org/show_bug.cgi?id=24353
2741 Allow to overrule default build options for Qt build.
2743 * WebCore.pro: Allow to overrule ENABLE_VIDEO and ENABLE_NETSCAPE_PLUGIN_API
2745 2009-03-09 Adam Treat <adam.treat@torchmobile.com>
2747 Reviewed by George Staikos.
2749 https://bugs.webkit.org/show_bug.cgi?id=24463
2750 WebCore::qstring is detaching and copying twice for every single
2751 WebCore::TextRun that is processed and drawn. This elevates this method
2752 to one of the top-ten most expensive methods in all of QtWebKit according
2753 to profiling. This changes the method so that QString only detaches
2754 when absolutely necessary.
2756 * platform/graphics/qt/FontQt.cpp:
2758 (WebCore::fixSpacing):
2759 (WebCore::Font::drawComplexText):
2760 (WebCore::Font::floatWidthForComplexText):
2761 (WebCore::Font::offsetForPositionForComplexText):
2762 (WebCore::Font::selectionRectForComplexText):
2764 2009-03-08 Mark Rowe <mrowe@apple.com>
2766 Reviewed by Oliver Hunt.
2768 Split ScrollAlignment and ScrollBehavior out of RenderLayer.h so that
2769 Frame.h no longer needs to include it. This cuts the size of the symbols
2770 for a debug build by around 3%.
2773 (WebCore::Element::scrollIntoView):
2774 (WebCore::Element::scrollIntoViewIfNeeded):
2775 * editing/Editor.cpp:
2776 (WebCore::Editor::insertTextWithoutSendingTextEvent):
2777 (WebCore::Editor::revealSelectionAfterEditingOperation):
2778 * editing/SelectionController.cpp:
2779 (WebCore::SelectionController::setSelection):
2780 * loader/FrameLoader.cpp:
2781 (WebCore::FrameLoader::gotoAnchor):
2782 * page/ContextMenuController.cpp:
2783 (WebCore::ContextMenuController::contextMenuItemSelected):
2785 (WebCore::Frame::revealSelection):
2786 (WebCore::Frame::revealCaret):
2788 * rendering/RenderLayer.cpp:
2789 (WebCore::RenderLayer::getRectToExpose):
2790 (WebCore::RenderLayer::autoscroll):
2791 * rendering/RenderLayer.h:
2792 * rendering/ScrollBehavior.cpp: Added.
2794 * rendering/ScrollBehavior.h: Added.
2796 (WebCore::ScrollAlignment::getVisibleBehavior):
2797 (WebCore::ScrollAlignment::getPartialBehavior):
2798 (WebCore::ScrollAlignment::getHiddenBehavior):
2800 Add the new files to the build systems:
2805 * WebCore.vcproj/WebCore.vcproj:
2806 * WebCore.xcodeproj/project.pbxproj:
2807 * WebCoreSources.bkl:
2809 Add includes that were previously pulled in by way of RenderLayer.h from Frame.h:
2810 * dom/Clipboard.cpp:
2811 * editing/EditorCommand.cpp:
2812 * editing/InsertLineBreakCommand.cpp:
2813 * editing/TypingCommand.cpp:
2814 * html/HTMLFormControlElement.cpp:
2815 * loader/archive/cf/LegacyWebArchive.cpp:
2816 * loader/icon/IconLoader.cpp:
2817 * page/animation/AnimationController.cpp:
2818 * rendering/RenderSlider.cpp:
2819 * rendering/RenderTextControl.cpp:
2822 2009-03-08 Mark Rowe <mrowe@apple.com>
2824 Reviewed Dan Bernstein.
2826 Push the include of Frame.h out of RenderView.h and down to those files
2827 that need it. This cuts the size of symbols for RenderFoo object files
2828 by around 15% in a debug build.
2830 * bindings/objc/DOM.mm:
2831 * rendering/RenderFileUploadControl.cpp:
2832 * rendering/RenderInline.cpp:
2833 * rendering/RenderObject.cpp:
2834 * rendering/RenderReplaced.cpp:
2835 * rendering/RenderText.cpp:
2836 * rendering/RenderView.cpp:
2837 (WebCore::RenderView::zoomFactor):
2838 * rendering/RenderView.h:
2840 2009-03-08 Mark Rowe <mrowe@apple.com>
2842 Rubber-stamped by Dan Bernstein.
2844 Remove some unnecessary or redundant includes from files related to the JS bindings.
2845 This cuts the size of the symbols for a debug build by around 3%.
2847 * bindings/js/JSCustomPositionCallback.cpp:
2848 * bindings/js/JSCustomPositionErrorCallback.cpp:
2849 * bindings/js/JSCustomSQLStatementCallback.cpp:
2850 * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
2851 * bindings/js/JSCustomSQLTransactionCallback.cpp:
2852 * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
2853 * bindings/js/JSCustomVoidCallback.cpp:
2854 * bindings/js/JSCustomXPathNSResolver.cpp:
2855 * bindings/js/JSDocumentCustom.cpp:
2856 * bindings/js/JSPluginElementFunctions.cpp:
2857 * bindings/js/JSSVGPODTypeWrapper.h:
2859 2009-03-08 Cameron Zwarich <cwzwarich@uwaterloo.ca>
2861 Reviewed by Oliver Hunt.
2863 Remove the unused methods previousHistoryItem(), setPreviousHistoryItem()
2864 and provisionalHistoryItem() from FrameLoader.
2868 * loader/FrameLoader.cpp:
2869 (WebCore::FrameLoader::frameLoadCompleted):
2870 (WebCore::FrameLoader::loadItem):
2871 * loader/FrameLoader.h:
2873 2009-03-08 Gustavo Noronha Silva <gns@gnome.org>
2875 Reviewed by Holger Freyther.
2877 Implement proper logging for the GTK+ port, inspired by the one in
2878 Qt. We use the WEBKIT_DEBUG environment variable which was already
2879 being used to decide whether to setup a logger for soup or not.
2881 * platform/gtk/LoggingGtk.cpp:
2882 (WebCore::getChannelFromName):
2883 (WebCore::InitializeLoggingChannelsIfNecessary):
2884 * platform/network/soup/ResourceHandleSoup.cpp:
2885 (WebCore::ensureSessionIsInitialized):
2887 2009-03-07 Dan Bernstein <mitz@apple.com>
2889 Reviewed by Mark Rowe.
2891 - WebCore part of removing build-time and run-time support for legacy
2892 versions of CFNetwork and Core Graphics
2894 * platform/graphics/win/FontCGWin.cpp:
2895 (WebCore::Font::drawGlyphs):
2896 * platform/graphics/win/FontCustomPlatformData.cpp:
2897 (WebCore::FontCustomPlatformData::fontPlatformData):
2898 * platform/graphics/win/FontPlatformDataCGWin.cpp:
2899 (WebCore::FontPlatformData::platformDataInit):
2900 * platform/network/cf/FormDataStreamCFNet.cpp:
2901 (WebCore::setHTTPBody):
2902 (WebCore::httpBodyFromRequest):
2903 * platform/network/cf/ResourceHandleCFNet.cpp:
2904 (WebCore::didSendBodyData):
2905 (WebCore::shouldUseCredentialStorageCallback):
2906 (WebCore::ResourceHandle::start):
2907 * platform/network/win/CookieJarCFNetWin.cpp:
2908 (WebCore::filterCookies):
2910 2009-03-07 Adele Peterson <adele@apple.com>
2912 Reviewed by Dan Bernstein.
2914 Fix for https://bugs.webkit.org/show_bug.cgi?id=24444
2915 No multiple JS property for <input type="file" multiple />
2917 * html/HTMLInputElement.cpp:
2918 (WebCore::HTMLInputElement::multiple):
2919 (WebCore::HTMLInputElement::setMultiple):
2920 * html/HTMLInputElement.h:
2921 * html/HTMLInputElement.idl:
2923 2009-03-07 Xan Lopez <xan@gnome.org>
2925 Reviewed by Holger Freyther.
2927 https://bugs.webkit.org/show_bug.cgi?id=24358
2928 [GTK] Scrollbars not clipped correctly
2930 ScrollView scrollbars in subframes are *not* native, so take that
2933 * platform/gtk/ScrollbarGtk.cpp:
2934 (ScrollbarGtk::getLocationInParentWindow):
2935 (ScrollbarGtk::frameRectsChanged):
2936 (ScrollbarGtk::paint):
2937 * platform/gtk/ScrollbarGtk.h:
2939 2009-03-06 Peter Kasting <pkasting@google.com>
2941 Reviewed by Darin Fisher.
2943 https://bugs.webkit.org/show_bug.cgi?id=24405
2944 Horizontal scrolling on Windows was reversed from Mac (and intuition).
2946 * platform/gtk/WheelEventGtk.cpp:
2947 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2948 * platform/win/WheelEventWin.cpp:
2949 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2951 2009-03-06 Peter Kasting <pkasting@google.com>
2953 Reviewed by Sam Weinig.
2955 Convert some C-style casts to static_cast<>()s.
2957 * platform/gtk/WheelEventGtk.cpp:
2958 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2959 * platform/mac/WheelEventMac.mm:
2960 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2961 * platform/win/WheelEventWin.cpp:
2962 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2963 * platform/wx/MouseWheelEventWx.cpp:
2964 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
2966 2009-03-06 Adele Peterson <adele@apple.com>
2968 Reviewed by Oliver Hunt.
2970 Fix for <rdar://problem/6607524> REGRESSION (Safari 3-4): I can't tab back to the URL field in an empty window (key loop is broken)
2972 I haven't been able to make a test for this since the problem is not reproducible within an empty iframe.
2974 * page/EventHandler.cpp: (WebCore::eventTargetNodeForDocument): We used to ensure that every html document had a body element.
2975 That is no longer true, so we should return the document element for a truly empty document.
2977 2009-03-06 Jay Campan <jcampan@google.com>
2979 Reviewed by Darin Fisher.
2981 https://bugs.webkit.org/show_bug.cgi?id=24306
2983 Adding a flag to ResourceRequestBase to indicate whether or not upload
2984 progress notifications are needed for a resource. This is useful to
2985 avoid sending these notifications when there are no consumers
2986 (especially in the Chromium case where IPC is involved).
2988 * platform/network/ResourceRequestBase.h:
2989 (WebCore::ResourceRequestBase::reportUploadProgress):
2990 (WebCore::ResourceRequestBase::setReportUploadProgress):
2991 (WebCore::ResourceRequestBase::ResourceRequestBase):
2992 * xml/XMLHttpRequest.cpp:
2993 (WebCore::XMLHttpRequest::loadRequestAsynchronously):
2995 2009-03-06 Dmitry Titov <dimich@chromium.org>
2997 Reviewed by Alexey Proskuryakov.
2999 https://bugs.webkit.org/show_bug.cgi?id=24150
3000 Add virtual ScriptExecutionContext::encoding()
3002 Test: http/tests/workers/text-encoding.html
3005 (WebCore::Document::encoding):
3007 (WebCore::Document::inputEncoding):
3008 (WebCore::Document::charset):
3009 (WebCore::Document::characterSet):
3010 Add new virtual method and route DOM synonym functions on Document through it.
3012 * dom/ScriptExecutionContext.h:
3013 * workers/Worker.cpp:
3014 (WebCore::Worker::Worker):
3015 (WebCore::Worker::notifyFinished):
3016 * workers/WorkerContext.cpp:
3017 (WebCore::WorkerContext::WorkerContext):
3018 (WebCore::WorkerContext::encoding):
3019 (WebCore::WorkerContext::completeURL): Added comment on why this is different from Document::completeURL
3020 * workers/WorkerContext.h:
3021 (WebCore::WorkerContext::create):
3022 * workers/WorkerContextProxy.h:
3023 * workers/WorkerMessagingProxy.cpp:
3024 (WebCore::WorkerMessagingProxy::startWorkerContext):
3025 * workers/WorkerMessagingProxy.h:
3026 * workers/WorkerThread.cpp:
3027 (WebCore::WorkerThreadStartupData::create):
3028 (WebCore::WorkerThreadStartupData::WorkerThreadStartupData):
3029 (WebCore::WorkerThread::create):
3030 (WebCore::WorkerThread::WorkerThread):
3031 (WebCore::WorkerThread::workerThread):
3032 * workers/WorkerThread.h:
3033 All of the above route the 'encoding' parameter of parent context to the new
3034 instance of WorkerContext - from Worker::notifyFinished() via WorkerMessagingProxy
3035 through WorkerThread through WorkerThreadStartupData and into constructor of WorkerContext.
3037 2009-03-06 Peter Kasting <pkasting@google.com>
3042 (WebCore::Node::dispatchWheelEvent):
3044 2009-03-06 Eric Carlson <eric.carlson@apple.com>
3046 Reviewed by Antti Koivisto.
3048 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3049 (WebCore::MediaPlayerPrivate::createQTMovieView): Delay callback while setting up movieview.
3051 2009-03-06 Douglas R. Davidson <ddavidso@apple.com>
3053 Reviewed by Justin Garcia.
3055 https://bugs.webkit.org/show_bug.cgi?id=24108
3057 Update spelling and grammar checking to use the new combined text
3058 checking (with automatic language identification) on Snow Leopard.
3059 Tested manually in Mail and Safari; automated tests to come later.
3061 * editing/Editor.cpp:
3062 (WebCore::findFirstMisspellingOrBadGrammarInRange):
3063 (WebCore::Editor::advanceToNextMisspelling):
3064 (WebCore::guessesForMisspelledOrUngrammaticalRange):
3065 (WebCore::Editor::guessesForMisspelledOrUngrammaticalSelection):
3066 (WebCore::Editor::markMisspellingsAfterTypingToPosition):
3067 (WebCore::markAllMisspellingsAndBadGrammarInRanges):
3068 (WebCore::Editor::markMisspellingsAndBadGrammar):
3070 * loader/EmptyClients.h:
3071 (WebCore::EmptyEditorClient::checkSpellingAndGrammarOfParagraph):
3072 * page/EditorClient.h:
3074 (WebCore::Frame::respondToChangedSelection):
3075 * platform/ContextMenu.cpp:
3076 (WebCore::ContextMenu::populate):
3078 2009-03-06 Peter Kasting <pkasting@google.com>
3080 Reviewed by Darin Fisher.
3082 https://bugs.webkit.org/show_bug.cgi?id=24407
3083 Windows scroll amount was too small, and wheel scroll distance
3084 conversion code was overly complex.
3086 * page/EventHandler.cpp:
3087 (WebCore::scrollAndAcceptEvent):
3088 * platform/PlatformWheelEvent.h:
3090 * platform/ScrollView.cpp:
3091 (WebCore::ScrollView::wheelEvent):
3092 * platform/Scrollbar.h:
3093 * platform/gtk/WheelEventGtk.cpp:
3094 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
3095 * platform/mac/WheelEventMac.mm:
3096 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
3097 * platform/qt/WheelEventQt.cpp:
3098 * platform/win/WheelEventWin.cpp:
3099 (WebCore::horizontalScrollChars):
3100 (WebCore::verticalScrollLines):
3101 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
3102 * platform/wx/MouseWheelEventWx.cpp:
3103 (WebCore::PlatformWheelEvent::PlatformWheelEvent):
3105 2009-03-06 Dimitri Glazkov <dglazkov@chromium.org>
3107 Reviewed by Adam Roben.
3109 Generate valid bindings with HTML5 database support disabled.
3111 * inspector/InspectorController.idl: Added feature guard around
3112 databaseTableNames definition.
3114 2009-03-04 Xan Lopez <xan@gnome.org>
3116 Reviewed by Holger Freyther.
3118 https://bugs.webkit.org/show_bug.cgi?id=24358
3119 [GTK] Scrollbars not clipped correctly
3121 Do not take into account the case of being a ScrollView scrollbar,
3122 since those are native in our case.
3124 * platform/gtk/ScrollbarGtk.cpp:
3125 (ScrollbarGtk::frameRectsChanged):
3127 2009-03-04 Xan Lopez <xan@gnome.org>
3129 Reviewed by Holger Freyther.
3131 https://bugs.webkit.org/show_bug.cgi?id=24358
3132 [GTK] Scrollbars not clipped correctly
3134 Move Widget::paint to ScrollbarGtk::paint, since it's scrollbar
3135 specific and it's our only Widget anyway.
3137 * platform/gtk/ScrollbarGtk.cpp:
3138 (ScrollbarGtk::paint):
3139 * platform/gtk/ScrollbarGtk.h:
3140 * platform/gtk/WidgetGtk.cpp:
3142 2009-03-04 Xan Lopez <xan@gnome.org>
3144 Reviewed by Holger Freyther.
3146 https://bugs.webkit.org/show_bug.cgi?id=24358
3147 [GTK] Scrollbars not clipped correctly
3149 Use correct clip rectangle and apply coordinate translation needed
3150 for non-ScrollView scrollbars.
3152 We were ignoring the clip rectangle passed as parameter, which is
3153 wrong in the case of non coalesced expose events. This, in turn,
3154 uncovers the fact that we were not applying coordinate translation
3157 * platform/gtk/WidgetGtk.cpp:
3158 (WebCore::Widget::paint):
3160 2009-03-06 Eric Carlson <eric.carlson@apple.com>
3162 Build fix, no review
3164 * platform/graphics/chromium/MediaPlayerPrivateChromium.h: fix setSize declaration
3166 2009-03-06 Eric Carlson <eric.carlson@apple.com>
3168 Reviewed by Simon Fraser.
3170 https://bugs.webkit.org/show_bug.cgi?id=22790
3171 Bug 22790: [Transforms] MediaPlayer::setRect() makes no sense with transforms
3172 Replace media engine setRect with setSize since they don't use about the
3175 * platform/graphics/MediaPlayer.cpp:
3176 (WebCore::NullMediaPlayerPrivate::setSize): Changed from setRect.
3177 (WebCore::MediaPlayer::setSize): Ditto.
3178 * platform/graphics/MediaPlayer.h:
3179 (WebCore::MediaPlayer::size): Changed from rect().
3181 * platform/graphics/MediaPlayerPrivate.h: Changed setRect to setSize.
3183 * platform/graphics/chromium/MediaPlayerPrivateChromium.h: Ditto.
3185 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
3186 (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): Initialize m_size instead of m_rect
3187 (WebCore::MediaPlayerPrivate::setSize): Changed from setRect
3188 (WebCore::MediaPlayerPrivate::paint): update comment
3189 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.h: m_rect -> m_size.
3191 * platform/graphics/mac/MediaPlayerPrivateQTKit.h: m_rect
3192 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3193 (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): Initialize m_rect.
3194 (WebCore::MediaPlayerPrivate::createQTMovieView): setRect-> setSize.
3195 (WebCore::MediaPlayerPrivate::setSize): Changed from setRect
3196 (WebCore::MediaPlayerPrivate::paint): Call view:setFrame: when in a media document so
3197 the movie is drawn in the correct location.
3199 * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
3200 (WebCore::MediaPlayerPrivate::setSize): Changed from setRect
3201 * platform/graphics/qt/MediaPlayerPrivatePhonon.h:
3203 * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
3204 (WebCore::MediaPlayerPrivate::setSize): Changed from setRect
3205 * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
3207 * rendering/RenderVideo.cpp:
3208 (WebCore::RenderVideo::updatePlayer): Call setSize instead of setRect.
3210 2009-03-06 Darin Adler <darin@apple.com>
3212 Reviewed by Darin Fisher.
3214 Bug 24422: REGRESSION: null-URL crash in FrameLoader setting location.hash on new window
3215 https://bugs.webkit.org/show_bug.cgi?id=24422
3216 rdar://problem/6402208
3218 Test: fast/dom/location-new-window-no-crash.html
3220 The issue here is empty (or null) URLs. I picked the "schedule navigation" bottleneck
3221 to add some checks for empty URLs. We could also put the empty URL checks at some
3222 other bottleneck level and add more assertions over time. I tried adding a few more
3223 assertions to functions like loadURL and hit them while running the regression tests,
3224 so it's probably going to be a bit tricky to clean this up throughout the loader.
3226 * loader/FrameLoader.cpp:
3227 (WebCore::ScheduledRedirection::ScheduledRedirection): Explicitly marked this struct
3228 immutable by making all its members const. Added assertions about the arguments,
3229 including that the URL is not empty. Initialized one uninitialized member in one of
3231 (WebCore::FrameLoader::scheduleHTTPRedirection): Added an early exit to make this
3232 a no-op if passed an empty URL.
3233 (WebCore::FrameLoader::scheduleLocationChange): Ditto.
3234 (WebCore::FrameLoader::scheduleRefresh): Ditto.
3236 2009-03-06 Gustavo Noronha Silva <gns@gnome.org>
3238 Reviewed by Holger Freyther.
3240 https://bugs.webkit.org/show_bug.cgi?id=24423
3241 Use new soup_message_body_set_accumulate API in soup backend
3243 Disable accumulating chunks for request_body on file uploads,
3244 using the new soup API.
3246 * platform/network/soup/ResourceHandleSoup.cpp:
3247 (WebCore::ResourceHandle::startHttp):
3249 2009-03-06 Gustavo Noronha Silva <gns@gnome.org>
3251 Reviewed by Holger Freyther.
3253 Replace use of deprecated SOUP_MESSAGE_OVERWRITE_CHUNKS flag with
3254 the new soup_message_body_set_accumulate API in soup.
3256 * platform/network/soup/ResourceHandleSoup.cpp:
3257 (WebCore::gotHeadersCallback):
3258 (WebCore::ResourceHandle::startHttp):
3260 2009-03-06 Gustavo Noronha Silva <gns@gnome.org>
3262 Reviewed by Holger Freyther.
3264 https://bugs.webkit.org/show_bug.cgi?id=24051
3265 Soup backend needs content sniffing capabilities
3267 Perform content sniffing when using soup, so that we have a chance
3268 of figuring out the Content-Type of the file if it's not sent by
3271 * platform/network/ResourceHandleInternal.h:
3272 (WebCore::ResourceHandleInternal::ResourceHandleInternal):
3273 * platform/network/soup/ResourceHandleSoup.cpp:
3274 (WebCore::gotHeadersCallback):
3275 (WebCore::gotChunkCallback):
3277 2009-03-06 Hironori Bono <hbono@chromium.org>
3279 Reviewed by Alexey Proskuryakov.
3281 https://bugs.webkit.org/show_bug.cgi?id=24342
3282 Cannot insert a Thai character after a Thai prepend character when using ICU 4.0
3284 This change creates a new break iterator "cursorMovementIterator" for
3285 moving cursors and use it when moving an input cursor.
3286 In "TextBreakIteratorICU.cpp", this break iterator uses custom ruleset
3287 based on the one of ICU 3.8.
3288 On the other hand, in "TextBreakIteratorQt.cpp", this break iterator
3289 just calls the characterBreakIterator() function.
3291 Test: editing/inserting/insert-thai-characters-001.html
3293 * platform/text/TextBreakIterator.h: Added a new function cursorMovementIterator().
3294 * platform/text/TextBreakIteratorICU.cpp: Implemented the cursorMovementIterator() function for ICU.
3295 (WebCore::setUpIteratorWithRules): Ditto.
3296 (WebCore::cursorMovementIterator): Ditto.
3297 * platform/text/qt/TextBreakIteratorQt.cpp: Implemented the cursorMovementIterator() function for Qt.
3298 (WebCore::cursorMovementIterator): Ditto.
3299 * rendering/RenderText.cpp: Call the cursorMovementIterator() function when moving an input cursor.
3300 (WebCore::RenderText::previousOffset): Ditto.
3301 (WebCore::RenderText::nextOffset): Ditto.
3303 2009-03-05 Alexey Proskuryakov <ap@webkit.org>
3305 Reviewed by Oliver Hunt.
3307 <rdar://problem/6621701> Safari 4 Beta Breaks XMLHttpRequest Response Text With Special
3308 Characters (a compatibility issue with widgets).
3310 Test: http/tests/xmlhttprequest/broken-xml-encoding.html
3312 Revert part of an Acid 3 fix - now we are no longer strict when decoding XMLHttpRequest XML
3315 * loader/TextResourceDecoder.cpp:
3316 (WebCore::TextResourceDecoder::TextResourceDecoder):
3317 (WebCore::TextResourceDecoder::decode):
3318 (WebCore::TextResourceDecoder::flush):
3319 * loader/TextResourceDecoder.h:
3320 (WebCore::TextResourceDecoder::useLenientXMLDecoding):
3321 Don't stop on XML decoding errors if useLenientXMLDecoding() was called.
3323 * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::didReceiveData): Don't stop on XML
3324 decoding errors. This behavior is now limited to other kinds of XML content.
3326 2009-03-05 Simone Fiorentino <simone.fiorentino@consulenti.fastweb.it>
3328 Bug 24382: request to add SH4 platform
3330 <https://bugs.webkit.org/show_bug.cgi?id=24382>
3332 Reviewed by David Kilzer.
3334 * platform/text/AtomicString.cpp:
3335 (WebCore::equal): Aligned memory access on SH4 platform.
3337 2009-03-05 Jeremy Moskovich <jeremy@chromium.org>
3339 Reviewed by Simon Fraser.
3341 Fix for https://bugs.webkit.org/show_bug.cgi?id=24215
3343 Gears expects an object tag with display:none to instantiate the plugin,
3344 so we add a workaround to make this work and fix Gears on WebKit trunk.
3346 * html/HTMLObjectElement.cpp:
3347 (WebCore::HTMLObjectElement::rendererIsNeeded):
3349 2009-03-05 Avi Drissman <avi@chromium.org>
3351 Reviewed by Darin Fisher.
3353 Need to have Chromium Mac match Safari Mac's accesskey handling
3354 https://bugs.webkit.org/show_bug.cgi?id=24404
3356 * page/chromium/EventHandlerChromium.cpp:
3357 (WebCore::EventHandler::accessKeyModifiers): Share access key modifiers with Mac Safari when building for the Mac.
3359 2009-03-05 Simon Fraser <simon.fraser@apple.com>
3361 Reviewed by Dave Hyatt
3363 https://bugs.webkit.org/show_bug.cgi?id=24412
3365 Fix crash when hit-testing elements with -webkit-transform-style: preserve-3d
3366 but no transform. We need to make localTransformState if we see preserve-3d.
3367 Also need to call update3DTransformedDescendantStatus() before we test
3368 m_has3DTransformedDescendant.
3370 Test: transforms/3d/hit-testing/hit-preserves-3d.html
3372 * rendering/RenderLayer.cpp:
3373 (WebCore::RenderLayer::hitTestLayer):
3375 2009-03-05 Eric Seidel <eric@webkit.org>
3377 Reviewed by David Hyatt.
3379 Changes to RenderLayer destruction to hopefully help catch an elusive crasher
3380 https://bugs.webkit.org/show_bug.cgi?id=24409
3382 Added a new RenderBoxModelObject::destroyLayer() call which is
3383 now the only way which RenderLayers should ever be destroyed.
3384 This ensures that the pointer to the layer is cleared in the
3385 RenderObject after destruction, allowing us to ASSERT in the
3386 RenderBoxModelObject destructor.
3388 * rendering/RenderBox.cpp:
3389 (WebCore::RenderBox::calcAbsoluteHorizontalReplaced):
3390 * rendering/RenderBoxModelObject.cpp:
3391 (WebCore::RenderBoxModelObject::~RenderBoxModelObject):
3392 (WebCore::RenderBoxModelObject::destroyLayer):
3393 (WebCore::RenderBoxModelObject::destroy):
3394 (WebCore::RenderBoxModelObject::styleDidChange):
3395 * rendering/RenderBoxModelObject.h:
3396 * rendering/RenderLayer.cpp:
3397 (WebCore::RenderLayer::stackingContext):
3398 (WebCore::RenderLayer::destroy):
3399 (WebCore::RenderLayer::removeOnlyThisLayer):
3400 * rendering/RenderLayer.h:
3401 * rendering/RenderObject.cpp:
3402 (WebCore::RenderObject::destroy):
3403 * rendering/RenderWidget.cpp:
3404 (WebCore::RenderWidget::destroy):
3406 2009-03-05 Eric Seidel <eric@webkit.org>
3408 Reviewed by David Hyatt.
3410 Remove old, unused IE 5.5 scrollbar-* CSS properties.
3411 Sort the unimplemented getComputedStyle properties so it's
3412 easier to see which ones actually need implementation.
3414 * css/CSSComputedStyleDeclaration.cpp:
3415 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3416 * css/CSSParser.cpp:
3417 (WebCore::CSSParser::parseValue):
3418 * css/CSSPropertyNames.in:
3419 * css/CSSStyleSelector.cpp:
3420 (WebCore::CSSStyleSelector::applyProperty):
3422 2009-03-05 Justin Garcia <justin.garcia@apple.com>
3424 Reviewed by Darin Adler.
3426 WebViewDidChangeSelectionNotifications weren't being sent for commands that change the selection's position
3427 within the document without changing its position in the DOM. For example, pressing return in (caret marked by ^):
3428 <div contentEditable="true"><div>^Hello</div></div>
3429 Undo was being enabled, shouldDeleteDOMRange called, etc. when doing no-op deletes (a delete in an empty document
3432 Changes to layout tests demonstrate fix.
3434 * editing/EditCommand.cpp:
3435 (WebCore::EditCommand::apply): Don't call applyEditing for a TypingCommand. The TypingCommand knows whether or
3436 not it did work that needs to be applied.
3437 * editing/Editor.cpp:
3438 (WebCore::Editor::appliedEditing): Moved code (but did not alter) to changeSelectionAfterCommand.
3439 (WebCore::Editor::unappliedEditing): Ditto.
3440 (WebCore::Editor::reappliedEditing): Ditto.
3441 (WebCore::Editor::changeSelectionAfterCommand): Moved code from *appliedEditing into here. Also call out to
3442 EditorClient::respondToChangedSelection() for commands that changed the selection's position in the document
3443 even if they did not change it's position in the DOM. Any TypingCommand that gets this far changed it's position
3446 * editing/TypingCommand.cpp:
3447 (WebCore::TypingCommand::TypingCommand): Removed unused m_appliedEditing.
3448 (WebCore::TypingCommand::typingAddedToOpenCommand): Always apply editing. We won't get this far if we don't need to.
3449 (WebCore::TypingCommand::deleteKeyPressed): Don't do any of the things that only make sense for Range selections, like
3450 adding to the killring and responding to a change in selections if the delete was a no-op.
3451 (WebCore::TypingCommand::forwardDeleteKeyPressed): Ditto.
3452 * editing/TypingCommand.h:
3454 2009-03-05 Dimitri Glazkov <dglazkov@chromium.org>
3456 Reviewed by Adam Roben.
3458 Eliminate a ref-counting leak in InspectorController.
3460 * inspector/InspectorController.h: Made constructor private, added static create method.
3462 (WebCore::Page::Page): Change initializer to use static create method.
3464 2009-03-05 Dimitri Glazkov <dglazkov@chromium.org>
3466 Reviewed by Timothy Hatcher.
3468 https://bugs.webkit.org/show_bug.cgi?id=24355
3469 Add InspectorController.idl and convert InspectorController.cpp to use
3472 * DerivedSources.make: Added InspectorController.idl
3473 * WebCore.xcodeproj/project.pbxproj: Added idl, bindings files.
3474 * bindings/js/JSInspectorControllerCustom.cpp: Added.
3475 * bindings/scripts/CodeGeneratorJS.pm: Added Array to no-header types.
3476 * inspector/InspectorController.cpp: Removed hand-rolled bindings.
3477 * inspector/InspectorController.h: Added platform and addSourceToFrame methods.
3478 * inspector/InspectorController.idl: Added.
3479 * page/Page.h: Changed member to RefPtr since InspectorController is now ref-counted.
3481 2009-03-05 Eric Carlson <eric.carlson@apple.com>
3483 Reviewed by Simon Fraser.
3485 https://bugs.webkit.org/show_bug.cgi?id=24400
3486 Bug 24400: Remove "start", "end", "loopStart", "loopEnd", "currentLoop", and "playCount"
3487 media element attributes
3489 Test: media/video-loop.html
3491 * html/HTMLMediaElement.cpp:
3492 (WebCore::HTMLMediaElement::HTMLMediaElement):
3493 (WebCore::HTMLMediaElement::loadInternal):
3494 (WebCore::HTMLMediaElement::setNetworkState):
3495 (WebCore::HTMLMediaElement::seek):
3496 (WebCore::HTMLMediaElement::playInternal):
3497 (WebCore::HTMLMediaElement::loop):
3498 (WebCore::HTMLMediaElement::setLoop):
3499 (WebCore::HTMLMediaElement::mediaPlayerTimeChanged):
3500 (WebCore::HTMLMediaElement::endedPlayback):
3501 (WebCore::HTMLMediaElement::updatePlayState):
3502 * html/HTMLMediaElement.h:
3503 * html/HTMLMediaElement.idl:
3505 2009-03-05 Steve Falkenburg <sfalken@apple.com>
3507 <rdar://problem/6651112> Safari asks about re-posting a form even when page is cached
3509 Reviewed by Ada Chan.
3511 * platform/network/cf/ResourceHandleCFNet.cpp:
3512 (WebCore::ResourceHandle::willLoadFromCache): Ported from Mac version.
3514 2009-03-05 David Hyatt <hyatt@apple.com>
3516 Reviewed by Eric Seidel
3518 https://bugs.webkit.org/show_bug.cgi?id=24248
3520 Make sure painting of overflow controls checks that visibility:visible is set on the block before
3521 painting. Pixel tests caught this regression.
3523 Make sure resizer painting pushes a clip of the corner rect. It was relying on the clip layers happened
3524 to do to their bounds (which had nothing to do with overflow).
3526 * rendering/RenderBlock.cpp:
3527 (WebCore::RenderBlock::paint):
3528 * rendering/RenderLayer.cpp:
3529 (WebCore::RenderLayer::paintResizer):
3531 2009-03-05 Yong Li <yong.li@torchmobile.com>
3533 Reviewed by Simon Fraser.
3535 https://bugs.webkit.org/show_bug.cgi?id=24386
3536 A faster implementation of extractMIMETypeFromMediaType.
3538 * platform/network/HTTPParsers.cpp:
3539 (WebCore::extractMIMETypeFromMediaType):
3541 2009-03-05 Yong Li <yong.li@torchmobile.com>
3543 Reviewed by Antti Koivisto.
3545 https://bugs.webkit.org/show_bug.cgi?id=24392
3546 Do not get the current time for unless we're doing PRELOAD_DEBUG as this
3547 can be unnecessarily expensive.
3549 * html/PreloadScanner.cpp:
3550 (WebCore::PreloadScanner::write):
3552 2009-03-04 Simon Fraser <simon.fraser@apple.com>
3554 Reviewed by Dave Hyatt
3556 https://bugs.webkit.org/show_bug.cgi?id=24327
3558 When mapping points and hit testing through transforms, work
3559 correctly when acclerated animations of transforms are running.
3561 Tested by LayoutTests/animations/animation-hit-test-transform.html,
3562 which only failed when ACCELERATED_COMPOSITING was turned on.
3564 * rendering/RenderLayer.cpp:
3565 (WebCore::RenderLayer::currentTransform):
3566 * rendering/RenderLayer.h:
3567 * rendering/RenderObject.cpp:
3568 (WebCore::RenderObject::transformFromContainer):
3570 2009-03-05 Mike Belshe <mike@belshe.com>
3572 Reviewed by Darin Fisher.
3574 https://bugs.webkit.org/show_bug.cgi?id=24391
3575 Frame.cpp uses JSC specific includes
3579 2009-03-05 Gustavo Noronha Silva <gns@gnome.org>
3581 Reviewed by Alexey Proskuryakov.
3583 https://bugs.webkit.org/show_bug.cgi?id=24389
3584 WebKitGTK+ crashes when cancelling plugin loads
3586 Remove bogus calls to the client's didFinishLoading method from
3587 our ResourceHandle::cancel implementation. Calling
3588 didFinishLoading here is mostly inoffensive for most loads, but
3589 causes crashes when plugin loads are cancelled.
3591 * platform/network/soup/ResourceHandleSoup.cpp:
3592 (WebCore::ResourceHandle::cancel):
3594 2009-03-05 Steve Falkenburg <sfalken@apple.com>