fc767e2402a248bfe8345eb49549437795c279cd
[WebKit.git] / WebCore / ChangeLog
1 2010-12-09  Kenneth Russell  <kbr@google.com>
2
3         Unreviewed. Speculative Gtk build fix after
4         https://bugs.webkit.org/show_bug.cgi?id=36512 / r73669. Process
5         all of the WebGL classes' IDL files.
6
7         * CMakeLists.txt:
8
9 2010-12-09  Zhenyao Mo  <zmo@google.com>
10
11         Reviewed by Kenneth Russell.
12
13         Expose constructor functions for instanceof checks of WebGL objects
14         https://bugs.webkit.org/show_bug.cgi?id=36512
15
16         Test: fast/canvas/webgl/instanceof-test.html
17
18         * bindings/generic/RuntimeEnabledFeatures.h:
19         (WebCore::RuntimeEnabledFeatures::webGLActiveInfoEnabled):
20         (WebCore::RuntimeEnabledFeatures::webGLBufferEnabled):
21         (WebCore::RuntimeEnabledFeatures::webGLFramebufferEnabled):
22         (WebCore::RuntimeEnabledFeatures::webGLProgramEnabled):
23         (WebCore::RuntimeEnabledFeatures::webGLRenderbufferEnabled):
24         (WebCore::RuntimeEnabledFeatures::webGLShaderEnabled):
25         (WebCore::RuntimeEnabledFeatures::webGLTextureEnabled):
26         (WebCore::RuntimeEnabledFeatures::webGLUniformLocationEnabled):
27         * html/canvas/WebGLActiveInfo.idl: Remove OmitConstructor.
28         * html/canvas/WebGLBuffer.idl: Ditto.
29         * html/canvas/WebGLFramebuffer.idl: Ditto.
30         * html/canvas/WebGLProgram.idl: Ditto.
31         * html/canvas/WebGLRenderbuffer.idl: Ditto.
32         * html/canvas/WebGLShader.idl: Ditto.
33         * html/canvas/WebGLTexture.idl: Ditto.
34         * html/canvas/WebGLUniformLocation.idl: Ditto.
35         * page/DOMWindow.idl: Expose constructors for WebGL objects in DOMWindow.
36
37 2010-12-09  Timothy Hatcher  <timothy@apple.com>
38
39         Export Color::white and Color::transparent.
40
41         Reviewed by Anders Carlsson.
42
43         * WebCore.exp.in:
44
45 2010-12-09  Sam Weinig  <sam@webkit.org>
46
47         Fix failing Mac tests.
48
49         * platform/mac/ScrollAnimatorMac.mm:
50         (WebCore::ScrollAnimatorMac::scroll): Don't smooth scroll if the default
51         AppleScrollAnimationEnabled is false.
52
53 2010-12-09  James Robinson  <jamesr@chromium.org>
54
55         Reviewed by Kenneth Russell.
56
57         [chromium] Compositor needs to manage its VRAM use
58         https://bugs.webkit.org/show_bug.cgi?id=49629
59
60         This adds a basic texture manager to the Chromium compositor to limit the amount of VRAM
61         used by compositor textures and switches ContentLayerChromium, ImageLayerChromium, and
62         RenderSurfaceChromium to use managed LayerTexture.  The other *LayerChromium classes (Canvas,
63         Video, and WebGL) and the root layer are still unmanaged.
64
65         The TextureManager works by providing tokens to callers that want to use a managed texture.
66         The token can be used to request a texture, see if the previously requested texture is still
67         available, and to protect/unprotect textures when they cannot be collected.  Whenever a
68         texture is created the manager attempts to free up the least recently used textures until the
69         total memory use is below the provided threshhold.  If the manager cannot satisfy the memory
70         limit it will not return any new textures until some old textures are released.
71
72         A LayerTexture wraps a TextureManager token, size, and format.  A LayerChromium can check if a
73         previously requested texture is still available for use and reserve the LayerTexture's underlying
74         storage between the updateContentsIfDirty() and the draw() call.
75
76         Also changes LayerChromium from having separate contentsDirty()/updateContents() calls to a single
77         updateContentsIfDirty().
78
79         Tests: platform/chromium/compositing/lots-of-img-layers-with-opacity.html
80                platform/chromium/compositing/lots-of-img-layers.html
81
82         * WebCore.gypi:
83         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
84         (WebCore::Canvas2DLayerChromium::updateContentsIfDirty):
85         * platform/graphics/chromium/Canvas2DLayerChromium.h:
86         * platform/graphics/chromium/ContentLayerChromium.cpp:
87         (WebCore::ContentLayerChromium::cleanupResources):
88         (WebCore::ContentLayerChromium::updateContentsIfDirty):
89         (WebCore::ContentLayerChromium::updateTextureRect):
90         (WebCore::ContentLayerChromium::draw):
91         * platform/graphics/chromium/ContentLayerChromium.h:
92         * platform/graphics/chromium/ImageLayerChromium.cpp:
93         (WebCore::ImageLayerChromium::updateContentsIfDirty):
94         * platform/graphics/chromium/ImageLayerChromium.h:
95         * platform/graphics/chromium/LayerChromium.h:
96         (WebCore::LayerChromium::updateContentsIfDirty):
97         (WebCore::LayerChromium::draw):
98         * platform/graphics/chromium/LayerRendererChromium.cpp:
99         (WebCore::LayerRendererChromium::LayerRendererChromium):
100         (WebCore::LayerRendererChromium::useShader):
101         (WebCore::LayerRendererChromium::prepareToDrawLayers):
102         (WebCore::LayerRendererChromium::updateRootLayerTextureRect):
103         (WebCore::LayerRendererChromium::drawLayers):
104         (WebCore::LayerRendererChromium::getFramebufferPixels):
105         (WebCore::LayerRendererChromium::createLayerTexture):
106         (WebCore::LayerRendererChromium::deleteLayerTexture):
107         (WebCore::LayerRendererChromium::updateLayersRecursive):
108         (WebCore::LayerRendererChromium::useRenderSurface):
109         (WebCore::LayerRendererChromium::drawLayer):
110         (WebCore::LayerRendererChromium::setScissorToRect):
111         (WebCore::LayerRendererChromium::setDrawViewportRect):
112         (WebCore::LayerRendererChromium::initializeSharedObjects):
113         (WebCore::LayerRendererChromium::cleanupSharedObjects):
114         * platform/graphics/chromium/LayerRendererChromium.h:
115         (WebCore::LayerRendererChromium::renderSurfaceSharedValues):
116         (WebCore::LayerRendererChromium::textureManager):
117         * platform/graphics/chromium/LayerTexture.cpp: Added.
118         (WebCore::LayerTexture::LayerTexture):
119         (WebCore::LayerTexture::~LayerTexture):
120         (WebCore::LayerTexture::isValid):
121         (WebCore::LayerTexture::reserve):
122         (WebCore::LayerTexture::unreserve):
123         (WebCore::LayerTexture::bindTexture):
124         (WebCore::LayerTexture::framebufferTexture2D):
125         * platform/graphics/chromium/LayerTexture.h: Added.
126         (WebCore::LayerTexture::create):
127         * platform/graphics/chromium/PluginLayerChromium.cpp:
128         (WebCore::PluginLayerChromium::updateContentsIfDirty):
129         * platform/graphics/chromium/PluginLayerChromium.h:
130         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
131         (WebCore::RenderSurfaceChromium::SharedValues::SharedValues):
132         (WebCore::RenderSurfaceChromium::SharedValues::~SharedValues):
133         (WebCore::RenderSurfaceChromium::RenderSurfaceChromium):
134         (WebCore::RenderSurfaceChromium::cleanupResources):
135         (WebCore::RenderSurfaceChromium::prepareContentsTexture):
136         (WebCore::RenderSurfaceChromium::draw):
137         * platform/graphics/chromium/RenderSurfaceChromium.h:
138         (WebCore::RenderSurfaceChromium::SharedValues::shaderProgram):
139         (WebCore::RenderSurfaceChromium::SharedValues::shaderSamplerLocation):
140         (WebCore::RenderSurfaceChromium::SharedValues::shaderMatrixLocation):
141         (WebCore::RenderSurfaceChromium::SharedValues::shaderAlphaLocation):
142         (WebCore::RenderSurfaceChromium::SharedValues::initialized):
143         * platform/graphics/chromium/TextureManager.cpp: Added.
144         (WebCore::memoryUseBytes):
145         (WebCore::TextureManager::TextureManager):
146         (WebCore::TextureManager::getToken):
147         (WebCore::TextureManager::releaseToken):
148         (WebCore::TextureManager::hasTexture):
149         (WebCore::TextureManager::protectTexture):
150         (WebCore::TextureManager::unprotectTexture):
151         (WebCore::TextureManager::reduceMemoryToLimit):
152         (WebCore::TextureManager::addTexture):
153         (WebCore::TextureManager::removeTexture):
154         (WebCore::TextureManager::requestTexture):
155         * platform/graphics/chromium/TextureManager.h: Added.
156         (WebCore::TextureManager::create):
157         * platform/graphics/chromium/VideoLayerChromium.cpp:
158         (WebCore::VideoLayerChromium::updateContentsIfDirty):
159         * platform/graphics/chromium/VideoLayerChromium.h:
160         * platform/graphics/chromium/WebGLLayerChromium.cpp:
161         (WebCore::WebGLLayerChromium::updateContentsIfDirty):
162         * platform/graphics/chromium/WebGLLayerChromium.h:
163
164 2010-12-09  Darin Adler  <darin@apple.com>
165
166         Reviewed by Sam Weinig.
167
168         Rework my recent setLocation refactoring to use DOMWindow instead of Frame.
169         It's difficult to make correct security decisions based on Frame since a
170         Frame can navigate to a new document.
171
172         Fixes some test failures that I somehow missed before the last check-in.
173
174         * bindings/js/JSDOMWindowBase.cpp:
175         (WebCore::JSDOMWindowBase::crossDomainAccessErrorMessage): Call to the
176         shell DOMWindow; not sure this one matters, but it's closer to the old
177         code before my last patch. Also pass the DOMWindow rather than the
178         frame to crossDomainAccessErrorMessage.
179
180         * bindings/js/JSDOMWindowCustom.cpp:
181         (WebCore::JSDOMWindow::setLocation): Pass DOMWindow rather than Frame
182         to the DOMWindow::setLocation function.
183
184         * page/DOMWindow.cpp:
185         (WebCore::DOMWindow::setLocation): Take DOMWindow rather than Frame.
186         (WebCore::DOMWindow::crossDomainAccessErrorMessage): Ditto.
187
188         * page/DOMWindow.h: Update new functions to take DOMWindow rather
189         than Frame.
190
191 2010-12-09  Sam Weinig  <sam@webkit.org>
192
193         Try and fix the mac build.
194
195         * WebCore.exp.in:
196
197 2010-12-09  Dan Bernstein  <mitz@apple.com>
198
199         Reviewed by Dave Hyatt.
200
201         Removed an unused variable.
202
203         * rendering/InlineFlowBox.cpp:
204         (WebCore::InlineFlowBox::computeLogicalBoxHeights): Removed parentLineHeight.
205
206 2010-12-09  Darin Adler  <darin@apple.com>
207
208         Reviewed by Geoffrey Garen.
209
210         Move DOMWindow::setLocation logic into DOMWindow class and out of JavaScript binding
211         https://bugs.webkit.org/show_bug.cgi?id=50640
212
213         * bindings/js/JSDOMBinding.cpp:
214         (WebCore::printErrorMessageForFrame): Removed body; just call through to
215         DOMWindow::printErrorMessage.
216
217         * bindings/js/JSDOMWindowBase.cpp:
218         (WebCore::JSDOMWindowBase::crossDomainAccessErrorMessage): Removed body;
219         just call through to DOMWindow::crossDomainAccessErrorMessage.
220
221         * bindings/js/JSDOMWindowCustom.cpp:
222         (WebCore::JSDOMWindow::setLocation): Changed terminology to use activeFrame and
223         firstFrame, rather than the older lexicalFrame and dynamicFrame. Removed most
224         of the body and moved it into DOMWindow::setLocation.
225
226         * page/DOMWindow.cpp:
227         (WebCore::DOMWindow::setLocation): Added. Does all the same work that
228         JSDOMWindow::setLocation used to do, but in a way that's not specific
229         to JavaScript.
230         (WebCore::DOMWindow::printErrorMessage): Added.
231         (WebCore::DOMWindow::crossDomainAccessErrorMessage): Added.
232
233         * page/DOMWindow.h: Added setLocation, printErrorMessage, and
234         crossDomainAccessErrorMessage.
235
236 2010-12-09  Sam Weinig  <sam@webkit.org>
237
238         Reviewed by Dan Bernstein.
239
240         WebKit2 needs smooth scrolling support on the mac
241         <rdar://problem/8219402>
242
243         * WebCore.xcodeproj/project.pbxproj: Change ScrollAnimatorMac.cpp to ScrollAnimatorMac.mm.
244         * platform/mac/ScrollAnimatorMac.cpp: Removed.
245         * platform/mac/ScrollAnimatorMac.h:
246         * platform/mac/ScrollAnimatorMac.mm: Copied from platform/mac/ScrollAnimatorMac.cpp.
247         (-[ScrollAnimationHelperDelegate initWithScrollAnimator:WebCore::]):
248         (-[ScrollAnimationHelperDelegate bounds]):
249         (-[ScrollAnimationHelperDelegate _immediateScrollToPoint:]):
250         (-[ScrollAnimationHelperDelegate convertSizeToBase:]):
251         (-[ScrollAnimationHelperDelegate convertSizeFromBase:]):
252         (-[ScrollAnimationHelperDelegate superview]):
253         (-[ScrollAnimationHelperDelegate documentView]):
254         (-[ScrollAnimationHelperDelegate window]):
255         (-[ScrollAnimationHelperDelegate _recursiveRecomputeToolTips]):
256         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
257         (WebCore::ScrollAnimatorMac::scroll):
258         (WebCore::ScrollAnimatorMac::setScrollPositionAndStopAnimation):
259         (WebCore::ScrollAnimatorMac::currentPosition):
260         (WebCore::ScrollAnimatorMac::immediateScrollToPoint):
261         Add implementation of ScrollAnimator for the Mac.
262
263 2010-12-09  Brady Eidson  <beidson@apple.com>
264
265         Reviewed by Anders Carlsson.
266
267         <rdar://problem/8613779> and https://bugs.webkit.org/show_bug.cgi?id=50777
268         WebKit2 ContextMenuClient support
269
270         Export some symbols and headers needed by WebKit2 Mac:
271         * WebCore.exp.in:
272         * WebCore.xcodeproj/project.pbxproj:
273
274 2010-12-09  Sheriff Bot  <webkit.review.bot@gmail.com>
275
276         Unreviewed, rolling out r73635.
277         http://trac.webkit.org/changeset/73635
278         https://bugs.webkit.org/show_bug.cgi?id=50778
279
280         'Side-effects on 3 css tests needs closer review' (Requested
281         by mwenge on #webkit).
282
283         * platform/graphics/qt/ImageQt.cpp:
284         (loadResourcePixmap):
285         * platform/qt/RenderThemeQt.cpp:
286         (WebCore::RenderThemeQt::computeSizeBasedOnStyle):
287         (WebCore::RenderThemeQt::paintSearchField):
288         (WebCore::RenderThemeQt::adjustSearchFieldStyle):
289         (WebCore::RenderThemeQt::adjustSearchFieldCancelButtonStyle):
290         (WebCore::RenderThemeQt::paintSearchFieldCancelButton):
291         * platform/qt/RenderThemeQt.h:
292
293 2010-12-09  Robert Hogan  <robert@webkit.org>
294
295         Reviewed by Andreas Kling.
296
297         [Qt] Search input field doesn't have cancel button
298
299         Add a cancel button to the search field and make it customizable
300         by the client. For now, use the close dialog button associated
301         with the application's style as the default.
302
303         https://bugs.webkit.org/show_bug.cgi?id=42887
304
305         * platform/graphics/qt/ImageQt.cpp:
306         (loadResourcePixmap):
307         * platform/qt/RenderThemeQt.cpp:
308         (WebCore::RenderThemeQt::computeSizeBasedOnStyle):
309         (WebCore::RenderThemeQt::paintSearchField):
310         (WebCore::RenderThemeQt::adjustSearchFieldStyle):
311         (WebCore::RenderThemeQt::adjustSearchFieldCancelButtonStyle):
312         (WebCore::RenderThemeQt::convertToPaintingRect):
313         (WebCore::RenderThemeQt::paintSearchFieldCancelButton):
314         * platform/qt/RenderThemeQt.h:
315
316 2010-12-09  Yael Aharon  <yael.aharon@nokia.com>
317
318         Reviewed by Antonio Gomes.
319
320         Spatial Navigation: Crash when handling iframe of size 0.
321         https://bugs.webkit.org/show_bug.cgi?id=50730
322
323         if we have a frame of size 0, we would get into infinite loop and eventually crash. The reason is
324         that when the algorithm sees a starting rect of size 0, it assumes that there is no focused node,
325         thus restarts itself. The solution is to avoid considering iframes with size 0 for the spatial
326         navigation algorithm.
327
328         Test: fast/spatial-navigation/snav-hidden-iframe-zero-size.html
329
330         * page/FocusController.cpp:
331         (WebCore::updateFocusCandidateIfNeeded):
332
333 2010-12-09  Sheriff Bot  <webkit.review.bot@gmail.com>
334
335         Unreviewed, rolling out r73616.
336         http://trac.webkit.org/changeset/73616
337         https://bugs.webkit.org/show_bug.cgi?id=50772
338
339         Breaks chromium win build (Requested by hwennborg on #webkit).
340
341         * bindings/v8/IDBBindingUtilities.cpp:
342         (WebCore::createIDBKeyFromValue):
343         * bindings/v8/custom/V8IDBKeyCustom.cpp:
344         (WebCore::toV8):
345         * storage/IDBFactoryBackendImpl.cpp:
346         (WebCore::createTables):
347         (WebCore::IDBFactoryBackendImpl::open):
348         * storage/IDBKey.cpp:
349         (WebCore::IDBKey::IDBKey):
350         (WebCore::IDBKey::fromQuery):
351         (WebCore::IDBKey::bind):
352         (WebCore::IDBKey::bindWithNulls):
353         * storage/IDBKey.h:
354         (WebCore::IDBKey::create):
355         (WebCore::IDBKey::number):
356
357 2010-12-09  Antonio Gomes  <agomes@rim.com>
358
359         Rubber stamped by by Gustavo Noronha Silva.
360
361         Buildfix for GTK+ with building with -no-video.
362
363         paintStockIcon static function was implemented under the ENABLE(VIDEO) guard
364         but used from outside the guard. See RenderThemeGtk::paintSearchFieldResultsDecoration()
365         and RenderThemeGtk::paintSearchFieldCancelButton() methods.
366
367         * platform/gtk/RenderThemeGtk.cpp:
368         (WebCore::getMediaElementFromRenderObject):
369
370 2010-12-07  Antonio Gomes  <agomes@rim.com>
371
372         Reviewed by Daniel Bates.
373
374         Spatial Navigation: code clean up
375         https://bugs.webkit.org/show_bug.cgi?id=50666
376
377         Patch unifies two FocusCandidate constructors, making caller sites
378         simpler. Now the special handling HTMLAreaElement gets is done within
379         the non default constructor (i.e. FocusCanditate(Node*, FocusDirection)).
380
381         No new tests needed.
382
383         * page/FocusController.cpp:
384         (WebCore::FocusController::findFocusCandidateInContainer):
385         * page/SpatialNavigation.cpp:
386         (WebCore::FocusCandidate::FocusCandidate):
387
388 2010-12-09  Philippe Normand  <pnormand@igalia.com>
389
390         Reviewed by Eric Carlson.
391
392         [GStreamer] disable fullscreen on MacOS Tiger and Leopard
393         https://bugs.webkit.org/show_bug.cgi?id=50748
394
395         Don't support fullscreen video on Tiger and Leopard, just like the
396         QTKit player.
397
398         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
399         (WebCore::MediaPlayerPrivateGStreamer::supportsFullscreen):
400
401 2010-12-06  Philippe Normand  <pnormand@igalia.com>
402
403         Reviewed by Martin Robinson.
404
405         [GTK] Support the Mozilla-style Fullscreen Javascript API
406         https://bugs.webkit.org/show_bug.cgi?id=50572
407
408         * GNUmakefile.am: enable the Javascript Fullscreen API feature if
409         it's been requested at configure time.
410
411 2010-12-09  Yong Li  <yoli@rim.com>
412
413         Reviewed by Darin Adler.
414
415         Check the return value of ImageBuffer::create()
416         to avoid crash when ImageBuffer::create() fails.
417         https://bugs.webkit.org/show_bug.cgi?id=50631
418
419         No new test because it relies on the platform implementation
420         of ImageBuffer. It is hard to make ImageBuffer::create() fail
421         in most ports.
422
423         * platform/graphics/GeneratedImage.cpp:
424         (WebCore::GeneratedImage::drawPattern):
425
426 2010-12-09  Maciej Stachowiak  <mjs@apple.com>
427
428         Reviewed by Dan Bernstein.
429
430         Implement "Use Selection for Find" in WebKit2
431         https://bugs.webkit.org/show_bug.cgi?id=50737
432         <rdar://problem/8564881>
433
434         Implement a TakeFindStringFromSelection editor command. This is
435         used solely to implement the "Use Selection for Find" menu command
436         on Mac, and is not made available to script. On WebKit2, it is
437         very convenient to reuse the editing machinery since this command
438         is very similar to Copy.
439
440         * editing/Editor.h:
441         * editing/EditorCommand.cpp:
442         (WebCore::executeTakeFindStringFromSelection): Call to a mac-only Editor function.
443         (WebCore::enabledTakeFindStringFromSelection): Check using Editor::canCopyExcludingStandaloneImage
444         (WebCore::createCommandMap): Add "TakeFindStringFromSelection" command.
445         * editing/mac/EditorMac.mm:
446         (WebCore::Editor::canCopyExcludingStandaloneImages): Helper function; we can't use Editor::canCopy
447         since it would make no sense to enable "Use Selection for Find" when viewing a standalone image
448         document.
449         (WebCore::Editor::takeFindStringFromSelection): Implement by copying the selected text
450         to the special Find pasteboard.
451
452 2010-12-09  Abhishek Arya  <inferno@chromium.org>
453
454         Reviewed by Dimitri Glazkov.
455
456         As part of r73559, I added the referenceNode check to validate whether the root
457         node of the iterator matches the node which is getting moved to other document.
458         referenceNode is initialized to root, however can get moved using previousNode
459         and nextNode methods, so it is required to use root directly.
460         https://bugs.webkit.org/show_bug.cgi?id=50764
461
462         Test: fast/dom/node-iterator-reference-node-moved-crash.html
463
464         * dom/Document.cpp:
465         (WebCore::Document::moveNodeIteratorsToNewDocument): change referenceNode to root.
466
467 2010-12-08  Dimitri Glazkov  <dglazkov@chromium.org>
468
469         Reviewed by Darin Adler.
470
471         Provide a generic way to store shadowParent on a Node.
472         https://bugs.webkit.org/show_bug.cgi?id=50184
473
474         This patch makes TreeShared::m_parent act as either parentNode() or
475         shadowHost() for Node. The distinction is controlled by IsShadowRootFlag.
476
477         Refactoring, so no new tests. See performance result testing in bug.
478
479         * dom/Element.cpp:
480         (WebCore::Element::recalcStyle): Changed to use parentOrHostNode().
481         * dom/Node.cpp:
482         (WebCore::Node::shadowHost): Added.
483         (WebCore::Node::setShadowHost): Added.
484         (WebCore::Node::isContentEditable): Changed to use parentOrHostNode().
485         (WebCore::Node::isContentRichlyEditable): Ditto.
486         (WebCore::Node::nextRenderer): Ditto.
487         (WebCore::Node::virtualComputedStyle): Ditto.
488         (WebCore::Node::canStartSelection): Ditto.
489         (WebCore::Node::shadowTreeRootNode): Changed to use parentNodeGuaranteedHostFree().
490         (WebCore::Node::getEventAncestors): Ditto.
491         (WebCore::Node::defaultEventHandler): Changed to use parentOrHostNode(). 
492         * dom/Node.h: Added an extra flag and adjusted bit counts.
493         (WebCore::Node::isShadowNode): Made non-virtual, switched to use flag.
494         (WebCore::Node::parentNode): Made to recognize flag.
495         (WebCore::Node::parentOrHostNode): Changed to use straight parent() and made const.
496         (WebCore::Node::parentNodeGuaranteedHostFree): Added.
497         (WebCore::Node::shadowParentNode): Made non-virtual and const.
498         * editing/TextIterator.cpp:
499         (WebCore::depthCrossingShadowBoundaries): Changed to use parentOrHostNode();
500         (WebCore::nextInPreOrderCrossingShadowBoundaries): Ditto.
501         (WebCore::previousInPostOrderCrossingShadowBoundaries):  Ditto.
502         (WebCore::setUpFullyClippedStack): Ditto.
503         (WebCore::TextIterator::advance): Ditto.
504         (WebCore::SimplifiedBackwardsTextIterator::advance): Ditto.
505         * page/DOMSelection.cpp:
506         (WebCore::DOMSelection::anchorNode): Changed to use parentNodeGuaranteedHostFree().
507         (WebCore::DOMSelection::focusNode): Ditto.
508         (WebCore::DOMSelection::baseNode): Ditto.
509         (WebCore::DOMSelection::extentNode): Ditto.
510         (WebCore::DOMSelection::getRangeAt): Ditto.
511         * rendering/MediaControlElements.cpp:
512         (WebCore::MediaControlShadowRootElement::MediaControlShadowRootElement):
513             Changed to setShadowHost().
514         (WebCore::MediaControlShadowRootElement::updateStyle): Changed to use shadowHost().
515         (WebCore::MediaControlShadowRootElement::detach): Added an override to
516             explicitly set shadowHost to 0. Otherwise, the element will leak.
517         * rendering/MediaControlElements.h: Added detach def, removed members that are
518             no longer needed.
519         * rendering/RenderSVGShadowTreeRootContainer.cpp:
520         (WebCore::RenderSVGShadowTreeRootContainer::~RenderSVGShadowTreeRootContainer):
521             Added explicit clearing of shadowHost to avoid leaking and crashes,
522             because SVG shadow DOM can be dynamically attached/detached, producing
523             stale nodes in over/out event handling.
524         * rendering/RenderSlider.cpp:
525         (WebCore::SliderThumbElement::defaultEventHandler): Changed to use shadowHost().
526         * rendering/RenderTextControlSingleLine.cpp:
527         (WebCore::RenderTextControlSingleLine::~RenderTextControlSingleLine):
528             Added explicit clearing of shadowHost and explicit destruction to
529             avoid out-of-order removal of children.
530         * rendering/RenderTreeAsText.cpp:
531         (WebCore::nodePosition): Simplified code.
532         * rendering/SVGShadowTreeElements.cpp:
533         (WebCore::SVGShadowTreeRootElement::SVGShadowTreeRootElement): Added
534             setting of shadowHost.
535         (WebCore::SVGShadowTreeRootElement::attachElement): Changed to use shadowHost().
536         (WebCore::SVGShadowTreeRootElement::clearShadowHost): Added.
537         * rendering/SVGShadowTreeElements.h: Added def, removed members that are
538              no longer needed.
539         * rendering/ShadowElement.cpp:
540         (WebCore::ShadowBlockElement::initAsPart): Changed to use shadowHost().
541         * rendering/ShadowElement.h: Removed members that are no longer needed.
542         (WebCore::ShadowElement::ShadowElement): Added setting of shadowHost.
543         (WebCore::ShadowElement::detach): Added.
544         * rendering/TextControlInnerElements.cpp:
545         (WebCore::TextControlInnerElement::TextControlInnerElement): Added setting
546             of shadowHost.
547         (WebCore::TextControlInnerElement::attachInnerElement): Changed to use
548             isShadowNode().
549         (WebCore::TextControlInnerElement::detach): Added.
550         * rendering/TextControlInnerElements.h: Removed members that are no
551             longer needed.
552         * svg/SVGElement.cpp:
553         (WebCore::SVGElement::ownerSVGElement): Simplified code.
554         (WebCore::SVGElement::viewportElement): Ditto.
555         * svg/SVGLocatable.cpp:
556         (WebCore::SVGLocatable::computeCTM): Ditto.
557         * svg/SVGStyledElement.cpp:
558         (WebCore::SVGStyledElement::title): Ditto.
559         * svg/SVGUseElement.cpp:
560         (WebCore::ShadowTreeUpdateBlocker::while): Ditto.
561
562 2010-12-09  Hans Wennborg  <hans@chromium.org>
563
564         Reviewed by Jeremy Orlow.
565
566         IndexedDB: Numeric keys are floats.
567         https://bugs.webkit.org/show_bug.cgi?id=50674
568
569         Use floating point to represent numeric keys,
570         add version meta data to the SQLite db,
571         and migrate object stores that use integers.
572
573         * bindings/v8/IDBBindingUtilities.cpp:
574         (WebCore::createIDBKeyFromValue):
575         * bindings/v8/custom/V8IDBKeyCustom.cpp:
576         (WebCore::toV8):
577         * storage/IDBFactoryBackendImpl.cpp:
578         (WebCore::createTables):
579         (WebCore::migrateDatabase):
580         (WebCore::IDBFactoryBackendImpl::open):
581         * storage/IDBKey.cpp:
582         (WebCore::IDBKey::IDBKey):
583         (WebCore::IDBKey::fromQuery):
584         (WebCore::IDBKey::bind):
585         (WebCore::IDBKey::bindWithNulls):
586         * storage/IDBKey.h:
587         (WebCore::IDBKey::create):
588         (WebCore::IDBKey::number):
589
590 2010-12-09  Brady Eidson  <beidson@apple.com>
591
592         Reviewed by Maciej Stachowiak.
593
594         <rdar://problem/7660733> and https://bugs.webkit.org/show_bug.cgi?id=50191
595         WebKit2 Authentication Support
596
597         * WebCore.exp.in:
598
599 2010-12-09  Peter Beverloo  <peter@lvp-media.com>
600
601         Reviewed by Maciej Stachowiak.
602
603         Default CSS definitions for the figure and figcaption elements.
604
605         Tests: fast/html/figcaption-element.html
606                fast/html/figure-element.html
607
608         * css/html.css:
609         (figure): The default figure-style equals a blockquote
610         (figcaption): A non-sectioning block-level element
611
612 2010-12-09  Yury Semikhatsky  <yurys@chromium.org>
613
614         Reviewed by Pavel Feldman.
615
616         Web Inspector: Console records for failed XHRs should contain call stack and request method
617         https://bugs.webkit.org/show_bug.cgi?id=50390
618
619         When inspector front-end is open we capture call stack at the place where request is sent and
620         pass the stack along with other request data. There is a new type of console messages which
621         is NetworkErrorMessageType, all messages of that type will have requestId field initialized
622         with the corresponding network request identifier so that later on when we need to display
623         that message in the front-end we could pull request data from the Network panel using
624         this identifier. If there are no data for given requestId message formatting falls back to
625         the old implementation which lacks such things as call stack, request method and exact
626         source location.
627
628         * inspector/ConsoleMessage.cpp:
629         (WebCore::ConsoleMessage::ConsoleMessage):
630         (WebCore::ConsoleMessage::addToFrontend):
631         (WebCore::ConsoleMessage::isEqual):
632         * inspector/ConsoleMessage.h:
633         * inspector/Inspector.idl:
634         * inspector/InspectorController.cpp:
635         (WebCore::InspectorController::didReceiveResponse):
636         (WebCore::InspectorController::didFailLoading):
637         * inspector/InspectorResourceAgent.cpp:
638         (WebCore::InspectorResourceAgent::identifierForInitialRequest):
639         * inspector/front-end/ConsoleView.js:
640         (WebInspector.ConsoleView.prototype.updateMessageRepeatCount):
641         (WebInspector.ConsoleMessage):
642         (WebInspector.ConsoleMessage.prototype._formatMessage):
643         (WebInspector.ConsoleMessage.prototype.toMessageElement):
644         (WebInspector.ConsoleMessage.prototype.toString):
645         (WebInspector.ConsoleMessage.prototype.isEqual):
646         * inspector/front-end/ResourceManager.js:
647         (WebInspector.ResourceManager.prototype.identifierForInitialRequest):
648         * inspector/front-end/inspector.js:
649         (WebInspector.addConsoleMessage):
650         * page/Console.h:
651
652 2010-12-09  Dai Mikurube  <dmikurube@google.com>
653
654         Reviewed by Kent Tamura.
655
656         Implement "required" attribute for select tags
657         https://bugs.webkit.org/show_bug.cgi?id=50380
658
659         Test: fast/forms/select-live-pseudo-selectors.html
660               platform/mac/fast/objc/dom-html-select-live-pseudo-selectors.html
661
662         * dom/SelectElement.cpp:
663         (WebCore::SelectElement::updateValidity): Added. It's a pure virtual function which is prepared so that HTMLSelectElement::updateValidity() calls HTMLSelectElement::setNeedsValidityCheck().
664         (WebCore::SelectElement::parseMultipleAttribute): Added calling updateValidity().
665         * html/HTMLSelectElement.cpp:
666         (WebCore::HTMLSelectElement::deselectItems): Added calling setNeedsValidityCheck() to enable validity check after changing. No tests for this change since this function is not exposed to JavaScript or any web interface.
667         (WebCore::HTMLSelectElement::setSelectedIndex): Added calling setNeedsValidityCheck().
668         (WebCore::HTMLSelectElement::setSelectedIndexByUser): Added calling setNeedsValidityCheck().
669         (WebCore::HTMLSelectElement::valueMissing): Added valueMissing() to check if selecting an invalid or placeholder label option when a valid required attribute is specified.
670         (WebCore::HTMLSelectElement::listBoxSelectItem): Added calling setNeedsValidityCheck(). No tests for this change since it is not called yet. Look at the bug 36177 and the changeset 56180.
671         (WebCore::HTMLSelectElement::add): Added calling setNeedsValidityCheck().
672         (WebCore::HTMLSelectElement::remove): Added calling setNeedsValidityCheck().
673         (WebCore::HTMLSelectElement::restoreFormControlState): Added calling setNeedsValidityCheck().
674         (WebCore::HTMLSelectElement::parseMappedAttribute): Added calling setNeedsValidityCheck().
675         (WebCore::HTMLSelectElement::selectAll): Added calling setNeedsValidityCheck().
676         (WebCore::HTMLSelectElement::reset): Added calling setNeedsValidityCheck().
677         (WebCore::HTMLSelectElement::updateListBoxSelection): Added calling setNeedsValidityCheck(). Skipped adding tests for this change as too complicated..
678         (WebCore::HTMLSelectElement::setLength): Added calling setNeedsValidityCheck().
679         (WebCore::HTMLSelectElement::isRequiredFormControl): Check if required or not.
680         (WebCore::HTMLSelectElement::hasPlaceholderLabelOption): Added.
681         (WebCore::HTMLSelectElement::updateValidity): Added. It calls setNeedsValidityCheck().
682         * html/HTMLSelectElement.h:
683         (WebCore::HTMLSelectElement::isOptionalFormControl): Check if not required.
684         * html/HTMLSelectElement.idl: Added a required attribute to select elements..
685         * html/ValidityState.cpp:
686         (WebCore::ValidityState::valueMissing): Added valueMissing check for select elements into the global checker, ValidityState::valueMissing().
687         * wml/WMLSelectElement.h:
688         (WebCore::WMLSelectElement::updateValidity): Added. It does nothing.
689
690 2010-12-07  Jeremy Orlow  <jorlow@chromium.org>
691
692         Reviewed by Steve Block.
693
694         IndexedDB returns the wrong exceptions
695         https://bugs.webkit.org/show_bug.cgi?id=50632
696
697         IndexedDB exceptions need to have an offset so they can
698         be distinguished from DOM exceptions.  We also need to
699         add strings for the various exceptions.  Lastly, make
700         IDBDatabaseException use the common exception base class.
701
702         * bindings/js/JSDOMBinding.cpp:
703         (WebCore::setDOMException):
704         * bindings/v8/V8Proxy.cpp:
705         (WebCore::V8Proxy::setDOMException):
706         * dom/ExceptionCode.cpp:
707         (WebCore::getExceptionCodeDescription):
708         * dom/ExceptionCode.h:
709         * storage/IDBDatabaseError.h:
710         (WebCore::IDBDatabaseError::code):
711         * storage/IDBDatabaseException.h:
712         (WebCore::IDBDatabaseException::create):
713         (WebCore::IDBDatabaseException::ErrorCodeToExceptionCode):
714         (WebCore::IDBDatabaseException::IDBDatabaseException):
715         * storage/IDBDatabaseException.idl:
716
717 2010-12-09  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
718
719         Build fix for GTK+3. Use functions added for GTK+ 2.24 to get the
720         GDK window size.
721
722         * plugins/gtk/gtk2xtbin.c:
723         (gtk_xtbin_realize):
724
725 2010-12-09  Siddharth Mathur  <siddharth.mathur@nokia.com>
726
727         Reviewed by Laszlo Gombos.
728
729         Use BUILDING_WEBKIT like other ports
730         https://bugs.webkit.org/show_bug.cgi?id=50713
731
732         * WebCore.pro: Change BUILD_WEBKIT to BUILDING_WEBKIT
733
734 2010-12-08  Erik Arvidsson  <arv@chromium.org>
735
736         Reviewed by Darin Adler.
737
738         Replace getAttribute().isNull() with fastHasAttribute()
739         https://bugs.webkit.org/show_bug.cgi?id=50719
740
741         Covered by existing tests.
742
743         * dom/SelectElement.cpp:
744         (WebCore::SelectElement::reset):
745         * html/HTMLAppletElement.cpp:
746         (WebCore::HTMLAppletElement::rendererIsNeeded):
747         * html/HTMLCollection.cpp:
748         (WebCore::HTMLCollection::itemAfter):
749         * html/HTMLFormControlElement.cpp:
750         (WebCore::HTMLFormControlElement::formNoValidate):
751         * html/HTMLFormElement.cpp:
752         (WebCore::HTMLFormElement::noValidate):
753         * html/HTMLInputElement.cpp:
754         (WebCore::HTMLInputElement::defaultChecked):
755         (WebCore::HTMLInputElement::multiple):
756         (WebCore::HTMLInputElement::webkitdirectory):
757         * html/HTMLOptionElement.cpp:
758         (WebCore::HTMLOptionElement::defaultSelected):
759         * html/HTMLScriptElement.cpp:
760         (WebCore::HTMLScriptElement::asyncAttributeValue):
761         (WebCore::HTMLScriptElement::deferAttributeValue):
762         * rendering/RenderFileUploadControl.cpp:
763         (WebCore::RenderFileUploadControl::allowsMultipleFiles):
764         (WebCore::RenderFileUploadControl::allowsDirectoryUpload):
765
766 2010-12-08  Nicolas Dufresne  <nicolas.dufresne@collabora.co.uk>
767
768         Reviewed by Martin Robinson.
769
770         Full page size flash plugins do not show in all situations
771         https://bugs.webkit.org/show_bug.cgi?id=47742
772
773         This patch moves the plugin widget size allocation after the
774         NPP_SetWindow is called with the effect that the resize of Flash
775         content no longer result in grey flash. This seems logical since the
776         widget tree cannot be fully constructed before the plugin receives
777         the new container window.
778
779         Test: manual-tests/plugins/gtk-windowed-grey-glitch.html
780
781         * plugins/gtk/PluginViewGtk.cpp:
782         (WebCore::PluginView::setNPWindowIfNeeded):
783
784 2010-12-08  David Hyatt  <hyatt@apple.com>
785
786         Reviewed by Simon Fraser.
787
788         Fix regression from xji's wheel scroll patch.  The vertical case is looking at the horizontal
789         maximum position and not the vertical position.
790
791         * platform/ScrollView.cpp:
792         (WebCore::ScrollView::wheelEvent):
793
794 2010-12-08  Sam Weinig  <sam@webkit.org>
795
796         Reviewed by Darin Adler.
797
798         Need a way to get a WKBundleFrameRef from JS HTMLIFrameElement
799         https://bugs.webkit.org/show_bug.cgi?id=50726
800
801         * WebCore.xcodeproj/project.pbxproj: Expose HTMLIFrameElement.h.
802
803 2010-12-08  Matthew Delaney  <mdelaney@apple.com>
804
805         Reviewed by Simon Fraser.
806
807         Add getter and setters for acceleratesRendering flag on layers
808         https://bugs.webkit.org/show_bug.cgi?id=50717
809
810         * platform/graphics/GraphicsLayer.cpp:
811         * platform/graphics/ca/GraphicsLayerCA.cpp:
812         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
813         Plumbed through acceleratedRendering flag.
814
815 2010-12-07  Zhenyao Mo  <zmo@google.com>
816
817         Reviewed by Kenneth Russell.
818
819         WebGLUniformLocation objects must be invalidated during linkProgram
820         https://bugs.webkit.org/show_bug.cgi?id=37118
821
822         * html/canvas/WebGLProgram.cpp:
823         (WebCore::WebGLProgram::WebGLProgram): Initialize link count to 0.
824         (WebCore::WebGLProgram::cacheActiveAttribLocations): Don't check link status through gl call; use the cached status instead.
825         * html/canvas/WebGLProgram.h:
826         (WebCore::WebGLProgram::getLinkCount): Get link count.
827         (WebCore::WebGLProgram::increaseLinkCount): Increase link count by 1.
828         * html/canvas/WebGLRenderingContext.cpp:
829         (WebCore::WebGLRenderingContext::getUniform): Fix a bug where wrong error is generated.
830         (WebCore::WebGLRenderingContext::linkProgram): call increaseLinkCount after linkProgram.
831         * html/canvas/WebGLUniformLocation.cpp:
832         (WebCore::WebGLUniformLocation::WebGLUniformLocation): Set program's link count upon creation.
833         (WebCore::WebGLUniformLocation::program): Return null if count doesn't match the program's.
834         (WebCore::WebGLUniformLocation::location): Return -1 if count doesn't match the program's.
835         * html/canvas/WebGLUniformLocation.h:
836
837 2010-12-08  Adele Peterson  <adele@apple.com>
838
839         Reviewed by Darin Adler.
840
841         Fix for https://bugs.webkit.org/show_bug.cgi?id=50725
842         <rdar://problem/8694972> REGRESSION (r72052): "Search" placeholder in MobileMe mail is positioned too high
843
844         Test: fast/forms/placeholder-position.html
845
846         Since we center the inner text element for single line text controls, 
847         we should ask the subclass to give us the y offset instead of trying to calculate it in the RenderTextControl class.
848
849         * rendering/RenderTextControl.cpp: (WebCore::RenderTextControl::paintPlaceholder):
850         * rendering/RenderTextControl.h:
851         * rendering/RenderTextControlMultiLine.cpp: (WebCore::RenderTextControlMultiLine::textBlockInsetTop):
852         * rendering/RenderTextControlMultiLine.h:
853         * rendering/RenderTextControlSingleLine.cpp: (WebCore::RenderTextControlSingleLine::textBlockInsetTop):
854         * rendering/RenderTextControlSingleLine.h:
855
856 2010-12-08  Chris Rogers  <crogers@google.com>
857
858         Reviewed by Kenneth Russell.
859
860         Add web audio files to mac port Xcode projects
861         https://bugs.webkit.org/show_bug.cgi?id=50721
862
863         No new tests since audio API is not yet implemented.
864
865         * WebCore.xcodeproj/project.pbxproj:
866         * bindings/js/JSDOMWindowCustom.cpp:
867         (WebCore::JSDOMWindow::webkitAudioContext):
868
869 2010-12-08  Kent Tamura  <tkent@chromium.org>
870
871         Reviewed by Alexey Proskuryakov.
872
873         Yensign hack should work with Shift_JIS and ISO-2022-JP encodings.
874         https://bugs.webkit.org/show_bug.cgi?id=49714
875
876         IE chooses a font which shows a yensign for 0x5c code point for a page
877         encoded in x-mac-japanese, ISO-2022-JP, EUC-JP, Shift_JIS, Shift_JIS_X0213-2000,
878         x-sjis, and Windows-31J.
879         We have emulated this behavior by replacing 0x5c with 0xa5 for EUC-JP and
880         Shift_JIS_X0213-2000. This change adds other encodings above.
881
882         Also, we move the HashSet initialization for isJapanese() and
883         backslashAsCurrencySymbol() to TextEncodingRegistry.cpp because of
884         ease of making them multi-thread safe.
885
886         * platform/text/TextEncoding.cpp:
887         (WebCore::TextEncoding::isJapanese): Just calls isJapaneseEncoding().
888         (WebCore::TextEncoding::backslashAsCurrencySymbol): Uses shouldShowBackslashAsCurrencySymbolIn().
889         * platform/text/TextEncodingRegistry.cpp:
890         (WebCore::addEncodingName): Moved from TextEncoding.cpp, and stop using atomicCanonicalTextEncodingName().
891         (WebCore::buildQuirksSets): Added. Initializes HashSets for isJapaneseEncoding() and shouldShowBackslashAsCurrencySymbolIn().
892         (WebCore::isJapaneseEncoding):
893         (WebCore::shouldShowBackslashAsCurrencySymbolIn):
894         (WebCore::extendTextCodecMaps): Add a call to buildQuirksSets().
895         * platform/text/TextEncodingRegistry.h:
896
897 2010-12-08  Andy Estes  <aestes@apple.com>
898
899         Reviewed by Darin Adler.
900
901         Reflected unsigned attributes should be in the range [0, 2^31).
902         https://bugs.webkit.org/show_bug.cgi?id=50472
903
904         HTML5 says that unsigned reflected attributes should be in the range
905         [0, 2^31). When a value isn't in this range, a default value (or 0)
906         should be returned instead. Update the JS bindings code generator to
907         ensure 0 is returned when a content attribute value falls outside of
908         this range.
909
910         Tests: bindings/scripts/test/TestObj.idl
911                fast/html/marquee-element.html
912
913         * bindings/scripts/CodeGeneratorJS.pm: Return the maximum of 0 and the
914         content attribute as a 32-bit signed int when converting a native value
915         to an unsigned JS value.
916         * bindings/scripts/test/TestObj.idl: Add a reflected unsigned attribute
917         to test code generation.
918         * bindings/scripts/test/CPP/WebDOMTestObj.cpp: Update test results.
919         * bindings/scripts/test/CPP/WebDOMTestObj.h: Ditto.
920         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp: Ditto.
921         * bindings/scripts/test/GObject/WebKitDOMTestObj.h: Ditto.
922         * bindings/scripts/test/JS/JSTestObj.cpp: Ditto.
923         * bindings/scripts/test/JS/JSTestObj.h: Ditto.
924         * bindings/scripts/test/ObjC/DOMTestObj.h: Ditto.
925         * bindings/scripts/test/ObjC/DOMTestObj.mm: Ditto.
926         * bindings/scripts/test/V8/V8TestObj.cpp: Ditto.
927
928 2010-12-08  Carlos Garcia Campos  <cgarcia@igalia.com>
929
930         Reviewed by Martin Robinson.
931
932         [GTK] Use gtk_icon_set_render_icon() to render icons in RenderThemeGtk
933         https://bugs.webkit.org/show_bug.cgi?id=50623
934
935         We don't need to cache the icons since the will be cached by GTK+,
936         and they will be rendered using the state and text direction.
937
938         * platform/gtk/RenderThemeGtk.cpp:
939         (WebCore::paintStockIcon):
940         (WebCore::getMediaButtonIconSize):
941         (WebCore::RenderThemeGtk::initMediaColors):
942         (WebCore::RenderThemeGtk::initMediaButtons):
943         (WebCore::RenderThemeGtk::RenderThemeGtk):
944         (WebCore::RenderThemeGtk::~RenderThemeGtk):
945         (WebCore::RenderThemeGtk::gtkIconState):
946         (WebCore::RenderThemeGtk::adjustSearchFieldResultsDecorationStyle):
947         (WebCore::centerRectVerticallyInParentInputElement):
948         (WebCore::RenderThemeGtk::paintSearchFieldResultsDecoration):
949         (WebCore::RenderThemeGtk::adjustSearchFieldCancelButtonStyle):
950         (WebCore::RenderThemeGtk::paintSearchFieldCancelButton):
951         (WebCore::RenderThemeGtk::platformColorsDidChange):
952         (WebCore::RenderThemeGtk::paintMediaButton):
953         (WebCore::RenderThemeGtk::paintMediaFullscreenButton):
954         (WebCore::RenderThemeGtk::paintMediaMuteButton):
955         (WebCore::RenderThemeGtk::paintMediaPlayButton):
956         (WebCore::RenderThemeGtk::paintMediaSeekBackButton):
957         (WebCore::RenderThemeGtk::paintMediaSeekForwardButton):
958         * platform/gtk/RenderThemeGtk.h:
959
960 2010-12-08  Abhishek Arya  <inferno@chromium.org>
961
962         Reviewed by Dimitri Glazkov.
963
964         Detach node iterator and move to new document when node gets moved.
965         https://bugs.webkit.org/show_bug.cgi?id=50697
966
967         Test: fast/dom/node-iterator-document-moved-crash.html
968
969         * dom/Document.cpp: Method that takes a node and new document as argument.
970         It detaches the node iterators belonging to the current document and attaches
971         them to the new document.
972         (WebCore::Document::moveNodeIteratorsToNewDocument):
973         * dom/Document.h: Function definition.
974         * dom/Node.cpp: When node is moved to another document, call the function to move
975         the iterators appropriately.
976         (WebCore::Node::setDocument):
977
978 2010-12-08  James Robinson  <jamesr@chromium.org>
979
980         Reviewed by Kenneth Russell.
981
982         [chromium] Text is blurry on a large composited layer with an odd center x/y coordinate
983         https://bugs.webkit.org/show_bug.cgi?id=50702
984
985         Compute the center of a large layer using floats instead of ints to avoid roundoff errors.
986
987         Test: compositing/text-on-large-layer.html
988
989         * platform/graphics/chromium/ContentLayerChromium.cpp:
990         (WebCore::ContentLayerChromium::draw):
991
992 2010-12-08  Ryosuke Niwa  <rniwa@webkit.org>
993
994         Reviewed by Dan Bernstein.
995
996         REGRESSION: LayoutTests/editing/selection/caret-rtl-2.html fails
997         https://bugs.webkit.org/show_bug.cgi?id=33503
998
999         The bug was caused by Font::offsetForPosition's not taking into account the containing block's text direction.
1000         When RTL text appears in a LTR block, the offset at the beginning of RTL text is on the left of RTL text,
1001         and the offset at the end of RTL text is on the right of RTL text. For example, if we had RTL text CBA,
1002         then the correspondance between letters and offsets in logical order are: A -> 0, B -> 1, and C -> 2.
1003
1004         Case 1. CBA appears in a RTL block:
1005           In this case, clicking on the visual left of CBA puts the caret naturally at Position("CBA", 2).
1006           Clicking on the visual right of CBA puts the caret at Position("CBA", 0) as expected.
1007         Case 2. CBA appears in a LTR block:
1008           Because the containing block flows from left to right, by convention, Position("CBA", 2") corresponds
1009           to the visual right of CBA, and Position("CBA", 0) corresponds to the visual left of CBA.
1010           Therefore, clicking on the visual left of CBA should put the caret at Position("CBA", 0),
1011           and clicking on the visual right should put it at Position("CBA", 2).
1012
1013         The bug was caused by WebKit's not considering case 2. The same bug also exist for LTR text in a RTL block.
1014         Fixed the bug by taking care of the case 2 in InlineTextBox::offsetForPosition.
1015
1016         Tests: editing/selection/caret-ltr-2-left.html
1017                editing/selection/caret-ltr-2.html
1018                editing/selection/caret-ltr-right.html
1019                editing/selection/caret-ltr.html
1020                editing/selection/caret-rtl-2-left.html
1021                editing/selection/caret-rtl-right.html
1022
1023         * rendering/InlineTextBox.cpp:
1024         (WebCore::InlineTextBox::offsetForPosition):
1025
1026 2010-12-08  Anders Carlsson  <andersca@apple.com>
1027
1028         Reviewed by Darin Adler.
1029
1030         Fix some clang++ warnings (one of which was an actual bug)
1031         https://bugs.webkit.org/show_bug.cgi?id=50700
1032
1033         * page/mac/DragControllerMac.mm:
1034         (WebCore::DragController::dragOperation):
1035         Add parentheses to silent a clang warning.
1036
1037         * page/mac/EventHandlerMac.mm:
1038         (WebCore::EventHandler::needsKeyboardEventDisambiguationQuirks):
1039         Fix || vs && precedence bug uncovered by clang.
1040
1041         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
1042         (WebCore::GraphicsContext3D::reshape):
1043         Use an early return to avoid a warning.
1044
1045 2010-12-08  Chris Marrin  <cmarrin@apple.com>
1046
1047         Reviewed by Simon Fraser.
1048
1049         Share code between Mac (CA) and Windows (CACF) GraphicsLayer implementations
1050         https://bugs.webkit.org/show_bug.cgi?id=49388
1051
1052         Added copy constructors and casting operators to go between 
1053         TransformationMatrix and CATransform3D. Also added a copy
1054         constructor to go from CGAffineTransform to TransformationMatrix.
1055         Used these new methods to clean up platform CA code. This will
1056         make it easier to port to Windows.
1057
1058         I also fixed a couple of build issues found when trying out a 
1059         Windows build.
1060
1061         This is a resubmission of changesets r73477 and r73483 with a 
1062         fix for the SL build. The failure was because TransformationMatrix
1063         included QuartzCore/CATransform3D.h which brought in some system
1064         libraries, including Quickdraw, which has a definition for
1065         'Cursor' which clashed with WebCore's 'Cursor' class. So I had
1066         to qualify its use in WebChromeClient.cpp in WebKit2.
1067
1068         * WebCore.xcodeproj/project.pbxproj:
1069         * platform/graphics/ca/GraphicsLayerCA.cpp:
1070         (WebCore::GraphicsLayerCA::updateContentsTransform):
1071         (WebCore::GraphicsLayerCA::ensureCloneLayers):
1072         (WebCore::GraphicsLayerCA::fetchCloneLayers):
1073         * platform/graphics/ca/TransformationMatrixCA.cpp: Copied from WebCore/platform/graphics/ca/TransformationMatrixCA.cpp.
1074         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
1075         (PlatformCAAnimation::setFromValue):
1076         (PlatformCAAnimation::setToValue):
1077         (PlatformCAAnimation::setValues):
1078         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1079         (PlatformCALayer::transform):
1080         (PlatformCALayer::setTransform):
1081         (PlatformCALayer::sublayerTransform):
1082         (PlatformCALayer::setSublayerTransform):
1083         (PlatformCALayer::contentsTransform):
1084         (PlatformCALayer::setContentsTransform):
1085         * platform/graphics/cg/TransformationMatrixCG.cpp:
1086         (WebCore::TransformationMatrix::TransformationMatrix):
1087         * platform/graphics/transforms/TransformationMatrix.h:
1088
1089 2010-12-07  Brian Weinstein  <bweinstein@apple.com>
1090
1091         Reviewed by John Sullivan.
1092
1093         Layering Violation in ContextMenu - member variable of type HitTestResult
1094         https://bugs.webkit.org/show_bug.cgi?id=50586
1095         
1096         ContextMenu had a layering violation by having a member variable of type HitTestResult, because
1097         classes in WebCore/platform can't know about classes in WebCore.
1098         
1099         This patch moves the HitTestResult and all functions that use it out of ContextMenu into ContextMenuController.
1100         All of the functions that dealt with populating the ContextMenu are now in ContextMenuController, and this
1101         allowed us to delete the ContextMenu file, putting all of the cross-platform code that used to be it
1102         in ContextMenuController, and the rest of the code is in the platform-specific files.
1103
1104         No change in behavior, no new tests.
1105
1106         * Android.mk: Removed ContextMenu.cpp.
1107         * CMakeLists.txt: Ditto.
1108         * GNUmakefile.am: Ditto.
1109         * WebCore.gypi: Ditto.
1110         * WebCore.pro: Ditto.
1111         * WebCore.vcproj/WebCore.vcproj: Ditto.
1112         * WebCore.xcodeproj/project.pbxproj: Ditto.
1113
1114         * page/ContextMenuController.cpp:
1115         (WebCore::ContextMenuController::ContextMenuController): Initialized m_hitTestResult to an empty HitTestResult.
1116         (WebCore::ContextMenuController::handleContextMenuEvent): Call populate on the ContextMenuController instead
1117             of the ContextMenu.
1118         (WebCore::ContextMenuController::createContextMenu): Fix some indination, and store the HitTestResult in a member
1119             variable.
1120         (WebCore::ContextMenuController::showContextMenu): Call addInspectElementItem on the ContextMenuController.
1121         (WebCore::ContextMenuController::contextMenuItemSelected): Use m_hitTestResult whenever we need a HitTestResult.
1122         (WebCore::ContextMenuController::appendItem): Validates the item for its state, and then appends it to the parent menu.
1123             This allowed us to move checkOrEnableIfNeeded from ContextMenu.
1124
1125         These functions were all moved from ContextMenu, and changed slightly to fit in ContextMenuController.
1126         All calls to ContextMenu::appendItem were changed to ContextMenuController::appendItem, which takes care
1127         of validating the menu.
1128         (WebCore::separatorItem): Moved from ContextMenu.
1129         (WebCore::ContextMenuController::createAndAppendFontSubMenu): Ditto.
1130         (WebCore::ContextMenuController::createAndAppendSpellingAndGrammarSubMenu): Ditto.
1131         (WebCore::ContextMenuController::createAndAppendSpeechSubMenu): Ditto.
1132         (WebCore::ContextMenuController::createAndAppendWritingDirectionSubMenu): Ditto.
1133         (WebCore::ContextMenuController::createAndAppendTextDirectionSubMenu): Ditto.
1134         (WebCore::ContextMenuController::createAndAppendSubstitutionsSubMenu): Ditto.
1135         (WebCore::ContextMenuController::createAndAppendTransformationsSubMenu): Ditto.
1136         (WebCore::selectionContainsPossibleWord): Ditto.
1137         (WebCore::ContextMenuController::populate): Ditto.
1138         (WebCore::ContextMenuController::addInspectElementItem): Ditto.
1139         (WebCore::ContextMenuController::checkOrEnableIfNeeded): Ditto.
1140         
1141         * page/ContextMenuController.h:
1142         (WebCore::ContextMenuController::hitTestResult): Returns the HitTestResult of the current ContextMenu.
1143
1144         * platform/ContextMenu.cpp: Removed.
1145         * platform/ContextMenu.h:
1146         * platform/efl/ContextMenuEfl.cpp:
1147         (WebCore::ContextMenu::ContextMenu): Removed m_hitTestResult from the constructor.
1148         (WebCore::ContextMenu::appendItem): Removed the call to checkOrEnableIfNeeded.
1149         * platform/gtk/ContextMenuGtk.cpp:
1150         (WebCore::ContextMenu::ContextMenu): Removed m_hitTestResult from the constructor.
1151         (WebCore::ContextMenu::appendItem): Ditto.
1152         * platform/haiku/ContextMenuHaiku.cpp:
1153         (WebCore::ContextMenu::ContextMenu): Removed m_hitTestResult from the constructor.
1154         (WebCore::ContextMenu::appendItem): Ditto.
1155         (WebCore::ContextMenu::insertItem): Ditto.
1156         * platform/mac/ContextMenuMac.mm:
1157         (-[WebCoreMenuTarget validateMenuItem:]): Calls checkOrEnableIfNeeded on the controller instead of
1158             the context menu.
1159         (WebCore::ContextMenu::ContextMenu): Removed m_hitTestResult from the constructor.
1160         (WebCore::ContextMenu::appendItem): Removed the call to checkOrEnableIfNeeded.
1161         (WebCore::ContextMenu::insertItem): Ditto.
1162         * platform/win/ContextMenuWin.cpp:
1163         (WebCore::ContextMenu::ContextMenu): Removed m_hitTestResult from the constructor.
1164         (WebCore::ContextMenu::insertItem): Removed the call to checkOrEnableIfNeeded.
1165         * platform/wx/ContextMenuWx.cpp:
1166         (WebCore::ContextMenu::ContextMenu): Removed m_hitTestResult from the constructor.
1167         (ContextMenu::appendItem): Ditto.
1168
1169 2010-12-08  Martin Robinson  <mrobinson@igalia.com>
1170
1171         Reviewed by John Sullivan.
1172
1173         [GTK] Layering violation in ContextMenuGtk.cpp
1174         https://bugs.webkit.org/show_bug.cgi?id=50676
1175
1176         ContextMenuGtk accesses the page's ContextMenuController, which is a layering
1177         violation. This was fixed for Mac with change r73469. We make a similar fix here
1178         by moving the "activated" signal connection to the WebKit layer.
1179
1180         * platform/gtk/ContextMenuGtk.cpp:
1181         (WebCore::ContextMenu::appendItem): Remove access of ContextMenuController. This
1182         is a layering violation.
1183
1184 2010-12-08  Jessie Berlin  <jberlin@apple.com>
1185
1186         Reviewed by Adam Roben.
1187
1188         WebKit2: Implement WebChromeClient::exceededDatabaseQuota
1189         https://bugs.webkit.org/show_bug.cgi?id=50656
1190
1191         * WebCore.exp.in:
1192         Export the symbol for SecurityOrigin::databaseIdentifier.
1193
1194 2010-12-08  Csaba Osztrogon√°c  <ossy@webkit.org>
1195
1196         Unreviewed, rolling out r73521.
1197         http://trac.webkit.org/changeset/73521
1198         https://bugs.webkit.org/show_bug.cgi?id=50640
1199
1200         It broke 90 layout tests
1201
1202         * bindings/js/JSDOMBinding.cpp:
1203         (WebCore::printErrorMessageForFrame):
1204         * bindings/js/JSDOMWindowBase.cpp:
1205         (WebCore::JSDOMWindowBase::crossDomainAccessErrorMessage):
1206         * bindings/js/JSDOMWindowCustom.cpp:
1207         (WebCore::JSDOMWindow::setLocation):
1208         * page/DOMWindow.cpp:
1209         * page/DOMWindow.h:
1210
1211 2010-12-08  David Hyatt  <hyatt@apple.com>
1212
1213         Reviewed by Anders Carlsson.
1214
1215         https://bugs.webkit.org/show_bug.cgi?id=50576
1216
1217         REGRESSION in position of autocomplete popup on RTL page.
1218
1219         RTL static position computation did not subtract out the width of the enclosing box if the
1220         immediate parent was a RenderInline.  This bug was exposed by properly changing the RenderView
1221         to be RTL when the document was RTL.
1222
1223         Added three new tests in fast/block/positioning.
1224
1225         * rendering/RenderBox.cpp:
1226         (WebCore::RenderBox::computePositionedLogicalWidth):
1227
1228 2010-12-08  Xiaomei Ji  <xji@chromium.org>
1229
1230         Reviewed by David Hyatt.
1231
1232         Fix backward mouse wheeling not working when scroll position is below 0.
1233         https://bugs.webkit.org/show_bug.cgi?id=50370
1234
1235         Tests: fast/events/wheelevent-in-horizontal-scrollbar-in-rtl.html
1236                fast/events/wheelevent-in-vertical-scrollbar-in-rtl.html
1237
1238         * platform/ScrollView.cpp:
1239         (WebCore::ScrollView::wheelEvent):
1240
1241 2010-12-08  Simon Fraser  <simon.fraser@apple.com>
1242
1243         Reviewed by Dan Bernstein.
1244
1245         Fix pauseAnimation API to work with shorthand properties
1246         https://bugs.webkit.org/show_bug.cgi?id=50639
1247         
1248         The pause API is always called with a long-hand property, but that
1249         property may be animating via a shorthand. Detect this, and pause
1250         such shorthand animations.
1251
1252         * page/animation/AnimationBase.cpp:
1253         (WebCore::ShorthandPropertyWrapper::propertyWrappers): Expose the vector
1254         of wrappers used by a shorthand wrapper.
1255
1256         (WebCore::gatherEnclosingShorthandProperties): Utility function that walks
1257         through the shorthand wrappers, keeping track of which can affect the given
1258         property.
1259         (WebCore::AnimationBase::animatableShorthandsAffectingProperty): Return a set
1260         of shorthand properties that can affect the given property.
1261
1262         * page/animation/AnimationBase.h: New method.
1263         * page/animation/CompositeAnimation.cpp:
1264         (WebCore::CompositeAnimation::pauseTransitionAtTime): If we don't find the
1265         property itself, check whether it's being animated via shorthands.
1266
1267 2010-12-08  David Hyatt  <hyatt@apple.com>
1268
1269         Reviewed by Beth Dakin.
1270
1271         <rdar://problem/8740920> Gestures: Frame::scalePage() broken by r73885
1272
1273         Make sure the transform applied to the RenderView for page scaling is incorporated into the
1274         docTop/Bottom/Left/Right accessors.
1275
1276         * rendering/RenderView.cpp:
1277         (WebCore::RenderView::docTop):
1278         (WebCore::RenderView::docBottom):
1279         (WebCore::RenderView::docLeft):
1280         (WebCore::RenderView::docRight):
1281
1282 2010-12-08  Ilya Tikhonovsky  <loislo@chromium.org>
1283
1284         Reviewed by Yury Semikhatsky.
1285
1286         Web Inspector: Protocol cleanup task. Remove WebInspector wrappers
1287         for TimelineAgent functions.
1288
1289         https://bugs.webkit.org/show_bug.cgi?id=50690
1290
1291         * inspector/Inspector.idl:
1292         * inspector/front-end/TimelineAgent.js:
1293         * inspector/front-end/TimelinePanel.js:
1294         (WebInspector.TimelinePanel):
1295         (WebInspector.TimelinePanel.prototype.timelineProfilerWasStarted):
1296         (WebInspector.TimelinePanel.prototype.timelineProfilerWasStopped):
1297
1298 2010-12-08  Philippe Normand  <pnormand@igalia.com>
1299
1300         Reviewed by Gustavo Noronha Silva.
1301
1302         [GTK] media/fullscreen* failing on 64-bits Debug
1303         https://bugs.webkit.org/show_bug.cgi?id=50394
1304
1305         Avoid emiting durationchanged in the case where the previous
1306         duration was 0 because that case is already handled by the
1307         HTMLMediaElement.
1308
1309         Test: media/media-fullscreen*.html
1310
1311         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1312         (WebCore::MediaPlayerPrivateGStreamer::durationChanged):
1313
1314 2010-12-07  Darin Adler  <darin@apple.com>
1315
1316         Reviewed by Geoffrey Garen.
1317
1318         Move DOMWindow::setLocation logic into DOMWindow class and out of JavaScript binding
1319         https://bugs.webkit.org/show_bug.cgi?id=50640
1320
1321         * bindings/js/JSDOMBinding.cpp:
1322         (WebCore::printErrorMessageForFrame): Removed body; just call through to
1323         DOMWindow::printErrorMessage.
1324
1325         * bindings/js/JSDOMWindowBase.cpp:
1326         (WebCore::JSDOMWindowBase::crossDomainAccessErrorMessage): Removed body;
1327         just call through to DOMWindow::crossDomainAccessErrorMessage.
1328
1329         * bindings/js/JSDOMWindowCustom.cpp:
1330         (WebCore::JSDOMWindow::setLocation): Changed terminology to use activeFrame and
1331         firstFrame, rather than the older lexicalFrame and dynamicFrame. Removed most
1332         of the body and moved it into DOMWindow::setLocation.
1333
1334         * page/DOMWindow.cpp:
1335         (WebCore::DOMWindow::setLocation): Added. Does all the same work that
1336         JSDOMWindow::setLocation used to do, but in a way that's not specific
1337         to JavaScript.
1338         (WebCore::DOMWindow::printErrorMessage): Added.
1339         (WebCore::DOMWindow::crossDomainAccessErrorMessage): Added.
1340
1341         * page/DOMWindow.h: Added setLocation, printErrorMessage, and
1342         crossDomainAccessErrorMessage.
1343
1344 2010-12-08  Alejandro G. Castro  <alex@igalia.com>
1345
1346         Unreviewed, rolling out r73494.
1347         http://trac.webkit.org/changeset/73494
1348         https://bugs.webkit.org/show_bug.cgi?id=50380
1349
1350         The tests added are crashing in the debug bots (macn and gtk)
1351
1352         * html/HTMLSelectElement.cpp:
1353         (WebCore::HTMLSelectElement::deselectItems):
1354         (WebCore::HTMLSelectElement::setSelectedIndex):
1355         (WebCore::HTMLSelectElement::setSelectedIndexByUser):
1356         (WebCore::HTMLSelectElement::listBoxSelectItem):
1357         (WebCore::HTMLSelectElement::add):
1358         (WebCore::HTMLSelectElement::remove):
1359         (WebCore::HTMLSelectElement::restoreFormControlState):
1360         (WebCore::HTMLSelectElement::parseMappedAttribute):
1361         (WebCore::HTMLSelectElement::selectAll):
1362         (WebCore::HTMLSelectElement::reset):
1363         (WebCore::HTMLSelectElement::updateListBoxSelection):
1364         (WebCore::HTMLSelectElement::setLength):
1365         * html/HTMLSelectElement.h:
1366         (WebCore::HTMLSelectElement::isOptionalFormControl):
1367         * html/HTMLSelectElement.idl:
1368         * html/ValidityState.cpp:
1369         (WebCore::ValidityState::valueMissing):
1370
1371 2010-12-07  Ilya Tikhonovsky  <loislo@chromium.org>
1372
1373         Reviewed by Pavel Feldman.
1374
1375         Web Inspector: Inspector protocol cleanup task. Remove
1376         WebInspector wrappers for DOMAgent functions.
1377
1378         There were a lot of wrappers in WebInspector namespace
1379         for different WebInspector agents functions. As far as we have a
1380         generic mechanic for such functions we can remove these
1381         wrappers and register domAgent instance as a handler for
1382         DOM domain notifications.
1383
1384         https://bugs.webkit.org/show_bug.cgi?id=50626
1385
1386         * inspector/Inspector.idl:
1387         * inspector/front-end/DOMAgent.js:
1388         (WebInspector.DOMNode):
1389         (WebInspector.DOMAgent):
1390         (WebInspector.DOMAgent.prototype.attributesUpdated):
1391         (WebInspector.DOMAgent.prototype.characterDataModified):
1392         (WebInspector.DOMAgent.prototype.setDocument):
1393         (WebInspector.DOMAgent.prototype.setDetachedRoot):
1394         (WebInspector.DOMAgent.prototype.setChildNodes):
1395         (WebInspector.DOMAgent.prototype.childNodeCountUpdated):
1396         (WebInspector.DOMAgent.prototype.childNodeInserted):
1397         (WebInspector.DOMAgent.prototype.childNodeRemoved):
1398         (WebInspector.EventListeners.getEventListenersForNodeAsync):
1399         * inspector/front-end/inspector.js:
1400         (WebInspector.didCommitLoad):
1401
1402 2010-12-08  Yury Semikhatsky  <yurys@chromium.org>
1403
1404         Reviewed by Pavel Feldman.
1405
1406         Web Inspector: remove groupLevel counter from console messages
1407         https://bugs.webkit.org/show_bug.cgi?id=50672
1408
1409         * inspector/ConsoleMessage.cpp:
1410         (WebCore::ConsoleMessage::ConsoleMessage):
1411         (WebCore::ConsoleMessage::addToFrontend):
1412         (WebCore::ConsoleMessage::isEqual):
1413         * inspector/ConsoleMessage.h:
1414         * inspector/InspectorController.cpp:
1415         (WebCore::InspectorController::InspectorController):
1416         (WebCore::InspectorController::addMessageToConsole):
1417         (WebCore::InspectorController::clearConsoleMessages):
1418         (WebCore::InspectorController::startGroup):
1419         (WebCore::InspectorController::endGroup):
1420         * inspector/InspectorController.h:
1421         * inspector/front-end/ConsoleView.js:
1422         (WebInspector.ConsoleView.createFilterElement):
1423         (WebInspector.ConsoleView):
1424         (WebInspector.ConsoleView.prototype.filter):
1425         (WebInspector.ConsoleView.prototype.afterShow):
1426         (WebInspector.ConsoleView.prototype.addMessage):
1427         (WebInspector.ConsoleView.prototype.updateMessageRepeatCount):
1428         (WebInspector.ConsoleView.prototype.clearMessages):
1429         (WebInspector.ConsoleMessage):
1430         (WebInspector.ConsoleMessage.createTextMessage):
1431         (WebInspector.ConsoleMessage.prototype.toMessageElement):
1432         (WebInspector.ConsoleMessage.prototype._addMessageHeader):
1433         (WebInspector.ConsoleMessage.prototype._updateRepeatCount):
1434         (WebInspector.ConsoleMessage.prototype.toString):
1435         (WebInspector.ConsoleMessage.prototype.isEqual):
1436         (WebInspector.ConsoleGroup):
1437         * inspector/front-end/Resource.js:
1438         (WebInspector.Resource.prototype._checkWarning):
1439         * inspector/front-end/SourceFrame.js:
1440         (WebInspector.SourceFrame.prototype._addMessageToSource):
1441         * inspector/front-end/inspector.js:
1442         (WebInspector.addConsoleMessage):
1443         (WebInspector.log.logMessage):
1444         (WebInspector.log):
1445
1446 2010-12-07  Pavel Podivilov  <podivilov@chromium.org>
1447
1448         Reviewed by Pavel Feldman.
1449
1450         Web Inspector: introduce DebuggerModel class representing InspectorDebuggerAgent state.
1451         https://bugs.webkit.org/show_bug.cgi?id=50567
1452
1453         Moved debugging-related code from BreakpointManager to DebuggerModel. Moved Breakpoint class to a separate file.
1454
1455         * English.lproj/localizedStrings.js:
1456         * WebCore.gypi:
1457         * WebCore.vcproj/WebCore.vcproj:
1458         * inspector/front-end/Breakpoint.js: Added.
1459         (WebInspector.Breakpoint): Moved from BreakpointManager.js.
1460         * inspector/front-end/BreakpointManager.js:
1461         (WebInspector.BreakpointManager): Remove debugger-related methods.
1462         * inspector/front-end/CallStackSidebarPane.js:
1463         (WebInspector.CallStackSidebarPane):
1464         (WebInspector.CallStackSidebarPane.prototype._nativeBreakpointHit):
1465         (WebInspector.CallStackSidebarPane.prototype._scriptBreakpointHit):
1466         * inspector/front-end/DebuggerModel.js: Added.
1467         (WebInspector.DebuggerModel): Moved debugger-related methods from BreakpointManager.
1468         * inspector/front-end/ScriptsPanel.js:
1469         (WebInspector.ScriptsPanel):
1470         (WebInspector.ScriptsPanel.prototype.continueToLine):
1471         (WebInspector.ScriptsPanel.prototype.editScriptSource.mycallback):
1472         (WebInspector.ScriptsPanel.prototype.editScriptSource):
1473         (WebInspector.ScriptsPanel.prototype._debuggerPaused):
1474         (WebInspector.ScriptsPanel.prototype._debuggerResumed):
1475         (WebInspector.ScriptsPanel.prototype.reset):
1476         * inspector/front-end/SourceFrame.js:
1477         (WebInspector.SourceFrame.prototype._createViewerIfNeeded):
1478         (WebInspector.SourceFrameDelegate.prototype.addBreakpoint):
1479         (WebInspector.SourceFrameDelegate.prototype.breakpoints):
1480         (WebInspector.SourceFrameDelegate.prototype.findBreakpoint):
1481         * inspector/front-end/WebKit.qrc:
1482         * inspector/front-end/inspector.html:
1483         * inspector/front-end/inspector.js:
1484         (WebInspector.createJSBreakpointsSidebarPane):
1485         (WebInspector.restoredBreakpoint):
1486         (WebInspector.pausedScript):
1487         (WebInspector.resumedScript):
1488         (WebInspector.reset):
1489
1490 2010-12-08  Pavel Podivilov  <podivilov@chromium.org>
1491
1492         Reviewed by Pavel Feldman.
1493
1494         Web Inspector: SourceFrame refactoring.
1495         https://bugs.webkit.org/show_bug.cgi?id=50223
1496
1497         SourceFrame should ask BreakpointManager about existing breakpoints instead of maintaining
1498         it's own storages. Move common code from ScriptView and SourceView to SourceFrame.
1499
1500         * inspector/front-end/BreakpointManager.js:
1501         (WebInspector.BreakpointManager.prototype.findBreakpoints):
1502         (WebInspector.BreakpointManager.prototype.findBreakpoint):
1503         * inspector/front-end/Script.js:
1504         (WebInspector.Script):
1505         (WebInspector.Script.prototype.get linesCount):
1506         (WebInspector.Script.prototype.get source):
1507         (WebInspector.Script.prototype.set source):
1508         * inspector/front-end/ScriptView.js:
1509         (WebInspector.ScriptView):
1510         (WebInspector.ScriptView.prototype._scriptSourceChanged):
1511         (WebInspector.ScriptFrameDelegateImpl):
1512         (WebInspector.ScriptFrameDelegateImpl.prototype.canEditScripts):
1513         (WebInspector.ScriptFrameDelegateImpl.prototype.editLineComplete):
1514         (WebInspector.ScriptFrameDelegateImpl.prototype.scripts):
1515         * inspector/front-end/ScriptsPanel.js:
1516         (WebInspector.ScriptsPanel):
1517         * inspector/front-end/SourceFrame.js:
1518         (WebInspector.SourceFrame): Add common methods of ScriptView and SourceView.
1519         (WebInspector.SourceFrameDelegate):
1520         (WebInspector.SourceFrameDelegate.prototype.canEditScripts):
1521         (WebInspector.SourceFrameDelegate.prototype.editLineComplete):
1522         (WebInspector.SourceFrameDelegate.prototype.scripts):
1523         * inspector/front-end/SourceView.js:
1524         (WebInspector.SourceView):
1525         (WebInspector.SourceView.prototype._contentLoaded):
1526         (WebInspector.ResourceFrameDelegateImpl):
1527         (WebInspector.ResourceFrameDelegateImpl.prototype.canEditScripts):
1528         (WebInspector.ResourceFrameDelegateImpl.prototype.editLineComplete):
1529         (WebInspector.ResourceFrameDelegateImpl.prototype.scripts):
1530
1531 2010-12-08  Yuta Kitamura  <yutak@chromium.org>
1532
1533         Unreviewed, rolling out r73492.
1534         http://trac.webkit.org/changeset/73492
1535         https://bugs.webkit.org/show_bug.cgi?id=49914
1536
1537         Caused a lot of pixel test failures and broke Windows build.
1538
1539         * WebCore.xcodeproj/project.pbxproj:
1540         * platform/graphics/GraphicsContext.cpp:
1541         (WebCore::GraphicsContext::createGraphicsContextPrivate):
1542         (WebCore::GraphicsContext::destroyGraphicsContextPrivate):
1543         (WebCore::GraphicsContext::save):
1544         (WebCore::GraphicsContext::restore):
1545         (WebCore::GraphicsContext::setStrokeThickness):
1546         (WebCore::GraphicsContext::setStrokeStyle):
1547         (WebCore::GraphicsContext::setStrokeColor):
1548         (WebCore::GraphicsContext::setShadow):
1549         (WebCore::GraphicsContext::clearShadow):
1550         (WebCore::GraphicsContext::getShadow):
1551         (WebCore::GraphicsContext::strokeThickness):
1552         (WebCore::GraphicsContext::strokeStyle):
1553         (WebCore::GraphicsContext::strokeColor):
1554         (WebCore::GraphicsContext::strokeColorSpace):
1555         (WebCore::GraphicsContext::fillRule):
1556         (WebCore::GraphicsContext::setFillRule):
1557         (WebCore::GraphicsContext::setFillColor):
1558         (WebCore::GraphicsContext::fillColor):
1559         (WebCore::GraphicsContext::fillColorSpace):
1560         (WebCore::GraphicsContext::setShouldAntialias):
1561         (WebCore::GraphicsContext::shouldAntialias):
1562         (WebCore::GraphicsContext::setStrokePattern):
1563         (WebCore::GraphicsContext::setFillPattern):
1564         (WebCore::GraphicsContext::setStrokeGradient):
1565         (WebCore::GraphicsContext::setFillGradient):
1566         (WebCore::GraphicsContext::fillGradient):
1567         (WebCore::GraphicsContext::strokeGradient):
1568         (WebCore::GraphicsContext::fillPattern):
1569         (WebCore::GraphicsContext::strokePattern):
1570         (WebCore::GraphicsContext::setShadowsIgnoreTransforms):
1571         (WebCore::GraphicsContext::updatingControlTints):
1572         (WebCore::GraphicsContext::setUpdatingControlTints):
1573         (WebCore::GraphicsContext::setPaintingDisabled):
1574         (WebCore::GraphicsContext::paintingDisabled):
1575         (WebCore::GraphicsContext::textDrawingMode):
1576         (WebCore::GraphicsContext::setTextDrawingMode):
1577         * platform/graphics/GraphicsContext.h:
1578         * platform/graphics/GraphicsContextPrivate.h: Added.
1579         (WebCore::GraphicsContextState::GraphicsContextState):
1580         (WebCore::GraphicsContextPrivate::GraphicsContextPrivate):
1581         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1582         (WebCore::setPlatformFill):
1583         (WebCore::setPlatformStroke):
1584         (WebCore::drawPathShadow):
1585         (WebCore::fillCurrentCairoPath):
1586         (WebCore::strokeCurrentCairoPath):
1587         (WebCore::GraphicsContext::GraphicsContext):
1588         (WebCore::GraphicsContext::~GraphicsContext):
1589         (WebCore::GraphicsContext::fillPath):
1590         (WebCore::GraphicsContext::strokePath):
1591         (WebCore::GraphicsContext::fillRect):
1592         (WebCore::GraphicsContext::setPlatformShadow):
1593         (WebCore::GraphicsContext::strokeRect):
1594         (WebCore::GraphicsContext::setAlpha):
1595         (WebCore::GraphicsContext::getAlpha):
1596         * platform/graphics/cg/GraphicsContextCG.cpp:
1597         (WebCore::GraphicsContext::GraphicsContext):
1598         (WebCore::GraphicsContext::~GraphicsContext):
1599         (WebCore::GraphicsContext::applyStrokePattern):
1600         (WebCore::GraphicsContext::applyFillPattern):
1601         (WebCore::GraphicsContext::drawPath):
1602         (WebCore::GraphicsContext::fillPath):
1603         (WebCore::GraphicsContext::strokePath):
1604         (WebCore::GraphicsContext::fillRect):
1605         (WebCore::GraphicsContext::setPlatformShadow):
1606         (WebCore::GraphicsContext::strokeRect):
1607         * platform/graphics/haiku/GraphicsContextHaiku.cpp:
1608         (WebCore::GraphicsContext::GraphicsContext):
1609         (WebCore::GraphicsContext::~GraphicsContext):
1610         * platform/graphics/openvg/GraphicsContextOpenVG.cpp:
1611         (WebCore::GraphicsContext::GraphicsContext):
1612         (WebCore::GraphicsContext::~GraphicsContext):
1613         (WebCore::GraphicsContext::fillPath):
1614         (WebCore::GraphicsContext::strokePath):
1615         (WebCore::GraphicsContext::clip):
1616         (WebCore::GraphicsContext::clipOut):
1617         (WebCore::GraphicsContext::addInnerRoundedRectClip):
1618         * platform/graphics/qt/GraphicsContextQt.cpp:
1619         (WebCore::GraphicsContext::GraphicsContext):
1620         (WebCore::GraphicsContext::~GraphicsContext):
1621         (WebCore::GraphicsContext::fillPath):
1622         (WebCore::GraphicsContext::strokePath):
1623         (WebCore::GraphicsContext::fillRect):
1624         (WebCore::GraphicsContext::setPlatformShadow):
1625         * platform/graphics/skia/GraphicsContextSkia.cpp:
1626         (WebCore::GraphicsContext::GraphicsContext):
1627         (WebCore::GraphicsContext::~GraphicsContext):
1628         (WebCore::GraphicsContext::fillPath):
1629         (WebCore::GraphicsContext::setPlatformShadow):
1630         * platform/graphics/win/GraphicsContextCGWin.cpp:
1631         (WebCore::GraphicsContext::GraphicsContext):
1632         * platform/graphics/win/GraphicsContextCairoWin.cpp:
1633         (WebCore::GraphicsContext::GraphicsContext):
1634         * platform/graphics/wince/GraphicsContextWinCE.cpp:
1635         (WebCore::GraphicsContext::GraphicsContext):
1636         (WebCore::GraphicsContext::~GraphicsContext):
1637         (WebCore::GraphicsContext::fillPath):
1638         (WebCore::GraphicsContext::fillRect):
1639         * platform/graphics/wx/GraphicsContextWx.cpp:
1640         (WebCore::GraphicsContext::GraphicsContext):
1641         (WebCore::GraphicsContext::~GraphicsContext):
1642
1643 2010-12-08  Dai Mikurube  <dmikurube@google.com>
1644
1645         Reviewed by Kent Tamura.
1646
1647         Implement "required" attribute for select tags
1648         https://bugs.webkit.org/show_bug.cgi?id=50380
1649
1650         Test: fast/forms/select-live-pseudo-selectors.html
1651               platform/mac/fast/objc/dom-html-select-live-pseudo-selectors.html
1652
1653         * html/HTMLSelectElement.cpp:
1654         (WebCore::HTMLSelectElement::deselectItems): Added calling setNeedsValidityCheck() to enable validity check after changing. No tests for this change since this function is not exposed to JavaScript or any web interface.
1655         (WebCore::HTMLSelectElement::setSelectedIndex): Added calling setNeedsValidityCheck().
1656         (WebCore::HTMLSelectElement::setSelectedIndexByUser): Added calling setNeedsValidityCheck().
1657         (WebCore::HTMLSelectElement::valueMissing): Added valueMissing() to check if selecting an invalid or placeholder label option when a valid required attribute is specified.
1658         (WebCore::HTMLSelectElement::listBoxSelectItem): Added calling setNeedsValidityCheck(). No tests for this change since it is not called yet. Look at the bug 36177 and the changeset 56180.
1659         (WebCore::HTMLSelectElement::add): Added calling setNeedsValidityCheck().
1660         (WebCore::HTMLSelectElement::remove): Added calling setNeedsValidityCheck().
1661         (WebCore::HTMLSelectElement::restoreFormControlState): Added calling setNeedsValidityCheck().
1662         (WebCore::HTMLSelectElement::parseMappedAttribute): Added calling setNeedsValidityCheck().
1663         (WebCore::HTMLSelectElement::selectAll): Added calling setNeedsValidityCheck().
1664         (WebCore::HTMLSelectElement::reset): Added calling setNeedsValidityCheck().
1665         (WebCore::HTMLSelectElement::updateListBoxSelection): Added calling setNeedsValidityCheck(). Skipped adding tests for this change as too complicated..
1666         (WebCore::HTMLSelectElement::setLength): Added calling setNeedsValidityCheck().
1667         (WebCore::HTMLSelectElement::isRequiredFormControl): Check if required or not.
1668         (WebCore::HTMLSelectElement::hasPlaceholderLabelOption): Added.
1669         * html/HTMLSelectElement.h:
1670         (WebCore::HTMLSelectElement::isOptionalFormControl): Check if not required.
1671         * html/HTMLSelectElement.idl: Added a required attribute to select elements..
1672         * html/ValidityState.cpp:
1673         (WebCore::ValidityState::valueMissing): Added valueMissing check for select elements into the global checker, ValidityState::valueMissing().
1674
1675 2010-12-08  Renata Hodovan  <reni@webkit.org>
1676
1677         Reviewed by Andreas Kling.
1678
1679         GraphicsContext: Merge m_common and m_data
1680         https://bugs.webkit.org/show_bug.cgi?id=49914
1681
1682         Move data members from GraphicsContextPrivate into GraphicsContext. So GraphicsContextPlatform.h
1683         and m_common became unnecessary. They are removed.
1684         Add two methods to GraphicsContext: platformInit() and platformDestroy(), which
1685         make the constructor of GraphicsContext clearer.
1686         Besides add a getter to the private GraphicsContext::m_state member, because some inline
1687         functions in cairo need it.
1688
1689         No new test is needed, because this is a refactoring.
1690
1691         * WebCore.xcodeproj/project.pbxproj:
1692         * platform/graphics/GraphicsContext.cpp:
1693         (WebCore::GraphicsContext::GraphicsContext):
1694         (WebCore::GraphicsContext::~GraphicsContext):
1695         (WebCore::GraphicsContext::save):
1696         (WebCore::GraphicsContext::restore):
1697         (WebCore::GraphicsContext::setStrokeThickness):
1698         (WebCore::GraphicsContext::setStrokeStyle):
1699         (WebCore::GraphicsContext::setStrokeColor):
1700         (WebCore::GraphicsContext::setShadow):
1701         (WebCore::GraphicsContext::clearShadow):
1702         (WebCore::GraphicsContext::getShadow):
1703         (WebCore::GraphicsContext::strokeThickness):
1704         (WebCore::GraphicsContext::strokeStyle):
1705         (WebCore::GraphicsContext::strokeColor):
1706         (WebCore::GraphicsContext::strokeColorSpace):
1707         (WebCore::GraphicsContext::fillRule):
1708         (WebCore::GraphicsContext::setFillRule):
1709         (WebCore::GraphicsContext::setFillColor):
1710         (WebCore::GraphicsContext::fillColor):
1711         (WebCore::GraphicsContext::fillColorSpace):
1712         (WebCore::GraphicsContext::setShouldAntialias):
1713         (WebCore::GraphicsContext::shouldAntialias):
1714         (WebCore::GraphicsContext::state):
1715         (WebCore::GraphicsContext::setStrokePattern):
1716         (WebCore::GraphicsContext::setFillPattern):
1717         (WebCore::GraphicsContext::setStrokeGradient):
1718         (WebCore::GraphicsContext::setFillGradient):
1719         (WebCore::GraphicsContext::fillGradient):
1720         (WebCore::GraphicsContext::strokeGradient):
1721         (WebCore::GraphicsContext::fillPattern):
1722         (WebCore::GraphicsContext::strokePattern):
1723         (WebCore::GraphicsContext::setShadowsIgnoreTransforms):
1724         (WebCore::GraphicsContext::updatingControlTints):
1725         (WebCore::GraphicsContext::setUpdatingControlTints):
1726         (WebCore::GraphicsContext::setPaintingDisabled):
1727         (WebCore::GraphicsContext::paintingDisabled):
1728         (WebCore::GraphicsContext::textDrawingMode):
1729         (WebCore::GraphicsContext::setTextDrawingMode):
1730         * platform/graphics/GraphicsContext.h:
1731         (WebCore::GraphicsContextState::GraphicsContextState):
1732         * platform/graphics/GraphicsContextPrivate.h: Removed.
1733         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1734         (WebCore::setPlatformFill):
1735         (WebCore::setPlatformStroke):
1736         (WebCore::drawPathShadow):
1737         (WebCore::fillCurrentCairoPath):
1738         (WebCore::strokeCurrentCairoPath):
1739         (WebCore::GraphicsContext::platformInit):
1740         (WebCore::GraphicsContext::platformDestroy):
1741         (WebCore::GraphicsContext::fillPath):
1742         (WebCore::GraphicsContext::strokePath):
1743         (WebCore::GraphicsContext::fillRect):
1744         (WebCore::GraphicsContext::setPlatformShadow):
1745         (WebCore::GraphicsContext::strokeRect):
1746         (WebCore::GraphicsContext::setAlpha):
1747         (WebCore::GraphicsContext::getAlpha):
1748         * platform/graphics/cg/GraphicsContextCG.cpp:
1749         (WebCore::GraphicsContext::platformInit):
1750         (WebCore::GraphicsContext::platformDestroy):
1751         (WebCore::GraphicsContext::applyStrokePattern):
1752         (WebCore::GraphicsContext::applyFillPattern):
1753         (WebCore::GraphicsContext::drawPath):
1754         (WebCore::GraphicsContext::fillPath):
1755         (WebCore::GraphicsContext::strokePath):
1756         (WebCore::GraphicsContext::fillRect):
1757         (WebCore::GraphicsContext::setPlatformShadow):
1758         (WebCore::GraphicsContext::strokeRect):
1759         * platform/graphics/haiku/GraphicsContextHaiku.cpp:
1760         (WebCore::GraphicsContext::platformInit):
1761         (WebCore::GraphicsContext::platformDestroy):
1762         * platform/graphics/openvg/GraphicsContextOpenVG.cpp:
1763         (WebCore::GraphicsContext::platformInit):
1764         (WebCore::GraphicsContext::platformDestroy):
1765         (WebCore::GraphicsContext::fillPath):
1766         (WebCore::GraphicsContext::strokePath):
1767         (WebCore::GraphicsContext::clip):
1768         (WebCore::GraphicsContext::clipOut):
1769         (WebCore::GraphicsContext::addInnerRoundedRectClip):
1770         * platform/graphics/qt/GraphicsContextQt.cpp:
1771         (WebCore::GraphicsContext::platformInit):
1772         (WebCore::GraphicsContext::platformDestroy):
1773         (WebCore::GraphicsContext::fillPath):
1774         (WebCore::GraphicsContext::strokePath):
1775         (WebCore::GraphicsContext::fillRect):
1776         (WebCore::GraphicsContext::setPlatformShadow):
1777         * platform/graphics/skia/GraphicsContextSkia.cpp:
1778         (WebCore::GraphicsContext::platformInit):
1779         (WebCore::GraphicsContext::platformDestroy):
1780         (WebCore::GraphicsContext::fillPath):
1781         (WebCore::GraphicsContext::setPlatformShadow):
1782         * platform/graphics/win/GraphicsContextCGWin.cpp:
1783         (WebCore::GraphicsContext::platformInit):
1784         * platform/graphics/win/GraphicsContextCairoWin.cpp:
1785         (WebCore::GraphicsContext::platformInit):
1786         * platform/graphics/wince/GraphicsContextWinCE.cpp:
1787         (WebCore::GraphicsContext::platformInit):
1788         (WebCore::GraphicsContext::platformDestroy):
1789         (WebCore::GraphicsContext::fillPath):
1790         (WebCore::GraphicsContext::fillRect):
1791         * platform/graphics/wx/GraphicsContextWx.cpp:
1792         (WebCore::GraphicsContext::platformInit):
1793         (WebCore::GraphicsContext::platformDestroy):
1794
1795 2010-12-07  Anton Muhin  <antonm@chromium.org>
1796
1797         Reviewed by Nate Chapin.
1798
1799         Port http://trac.webkit.org/changeset/72819/ to v8-backed ports.
1800         https://bugs.webkit.org/show_bug.cgi?id=50246
1801
1802         * bindings/v8/V8DOMMap.h:
1803         (WebCore::AbstractWeakReferenceMap::Visitor::startMap):
1804         (WebCore::AbstractWeakReferenceMap::Visitor::endMap):
1805         (WebCore::WeakReferenceMap::visit):
1806         * bindings/v8/V8GCController.cpp:
1807         (WebCore::GrouperItem::GrouperItem):
1808         (WebCore::GrouperItem::groupId):
1809         (WebCore::makeV8ObjectGroups):
1810         (WebCore::NodeGrouperVisitor::NodeGrouperVisitor):
1811         (WebCore::NodeGrouperVisitor::visitDOMWrapper):
1812         (WebCore::NodeGrouperVisitor::applyGrouping):
1813         (WebCore::DOMObjectGrouperVisitor::ObjectGrouperVisitor):
1814         (WebCore::DOMObjectGrouperVisitor::startMap):
1815         (WebCore::DOMObjectGrouperVisitor::endMap):
1816         (WebCore::DOMObjectGrouperVisitor::visitDOMWrapper):
1817         (WebCore::V8GCController::gcPrologue):
1818
1819 2010-12-07  Daniel Bates  <dbates@rim.com>
1820
1821         Reviewed by Martin Robinson.
1822
1823         Implement focus ring support for image maps
1824         https://bugs.webkit.org/show_bug.cgi?id=50371
1825
1826         Implement GraphicsContext::drawFocusRing(const Path&, ...) so as to support
1827         drawing a focus ring for image maps.
1828
1829         Tests: fast/images/imagemap-circle-focus-ring.html
1830                fast/images/imagemap-polygon-focus-ring.html
1831
1832         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1833         (WebCore::adjustFocusRingColor): Added.
1834         (WebCore::adjustFocusRingLineWidth): Added.
1835         (WebCore::focusRingStrokeStyle): Added.
1836         (WebCore::GraphicsContext::drawFocusRing): Moved code for determining focus ring- color,
1837         line width and stroke style into functions adjustFocusRingColor(), adjustFocusRingLineWidth(),
1838         and focusRingStrokeStyle(), respectively. Implemented GraphicsContext::drawFocusRing(const Path&, ...).
1839
1840 2010-12-07  Sergio Villar Senin  <svillar@igalia.com>
1841
1842         Reviewed by Xan Lopez.
1843
1844         [GTK] WebKitSoupCache fails to load resources when cache contents are externally removed
1845         https://bugs.webkit.org/show_bug.cgi?id=50577
1846
1847         Try to download cached resources again if they are no longer
1848         accesible by the cache.
1849
1850         * platform/network/soup/cache/soup-request-http.c:
1851         (send_async_cb):
1852         (webkit_soup_request_http_send_async):
1853
1854 2010-12-06  MORITA Hajime  <morrita@google.com>
1855
1856         Reviewed by Dimitri Glazkov.
1857
1858         RenderIndicator subclasses should not change the render tree during layout.
1859         https://bugs.webkit.org/show_bug.cgi?id=50026
1860
1861         The old code created shadow elements during a layout computation,
1862         that makes the layout state inconsisntent and cause an assertion failure. 
1863         This change created shadow elements before the layout to avoid  
1864         state inconsistencies.
1865         
1866         Instead of creating shadows on demand, RenderMeter and
1867         RenderProgress now create all necessary shadows before layouts,
1868         and change its visibilities during the layout: Changing
1869         visibilities doesn't trigger relayout and keep the state
1870         consistent.
1871         
1872         RenderMeter uses new HidablePartElement for shadow elements,
1873         which can toggle visibiliby between hidden and original value.
1874
1875         Test: fast/dom/HTMLMeterElement/meter-element-crash.html
1876
1877         * html/HTMLMeterElement.cpp:
1878         (WebCore::HTMLMeterElement::attach): Calling updateFromElement()
1879         * html/HTMLMeterElement.h:
1880         * html/HTMLProgressElement.cpp:
1881         (WebCore::HTMLProgressElement::attach): Calling updateFromElement()
1882         * html/HTMLProgressElement.h:
1883         * rendering/RenderIndicator.cpp:
1884         * rendering/RenderIndicator.h:
1885         * rendering/RenderMeter.cpp:
1886         (WebCore::MeterPartElement::MeterPartElement): Added to hold a restorable visibility.
1887         (WebCore::MeterPartElement::createForPart):
1888         (WebCore::MeterPartElement::hide):
1889         (WebCore::MeterPartElement::restoreVisibility):
1890         (WebCore::MeterPartElement::updateStyleForPart):
1891         (WebCore::MeterPartElement::saveVisibility):
1892         (WebCore::RenderMeter::~RenderMeter):
1893         (WebCore::RenderMeter::createPart): Extracted
1894         (WebCore::RenderMeter::updateFromElement): Had a shadow generation.
1895         (WebCore::RenderMeter::layoutParts): Removed shadow generation code.
1896         (WebCore::RenderMeter::shouldHaveParts):
1897         (WebCore::RenderMeter::valuePartRect): Adopted orientation.
1898         (WebCore::RenderMeter::orientation): Morphed from isHorizontal()
1899         (WebCore::RenderMeter::valuePseudoId): Adoptedn orientation
1900         (WebCore::RenderMeter::barPseudoId): Adopted orientation.
1901         * rendering/RenderMeter.h:
1902         (WebCore::RenderMeter::shadowAttached):
1903         * rendering/RenderProgress.cpp:
1904         (WebCore::RenderProgress::updateFromElement): Had a shadow generation.
1905         (WebCore::RenderProgress::layoutParts):
1906         * rendering/RenderProgress.h:
1907         * rendering/ShadowElement.cpp:
1908         (WebCore::ShadowBlockElement::createForPart): Extracted initAsPart().
1909         (WebCore::ShadowBlockElement::initAsPart): Extracted from createForPart().
1910         * rendering/ShadowElement.h:
1911
1912 2010-11-29  Mihai Parparita  <mihaip@chromium.org>
1913
1914         Reviewed by Adam Barth.
1915
1916         returning to a POST result within a frame does a GET instead of a POST
1917         https://bugs.webkit.org/show_bug.cgi?id=10199
1918         
1919         FrameLoader::loadURLIntoChildFrame had a check for whether a frame
1920         had a HistoryItem, and if so used that item's URL. However, that did
1921         not handle the case where the HistoryItem had FormData and thus was the
1922         result of a POST request. FrameLoader::navigateToDifferentDocument (now
1923         renamed to loadDifferentDocumentItem) does all that, so just switch to
1924         using it instead.
1925         
1926         Besides the bug fix, the only difference in behavior is that we use the
1927         HistoryItem's URL instead of original URL when restoring it in a child
1928         frame. This seems desirable too (for consistency with other browsers, and
1929         so that we can avoid form double-submits for forms that that do
1930         POST-then-redirect), and is tested by
1931         fast/history/history-back-initial-vs-final-url.html.
1932         
1933         Tests: fast/history/history-back-initial-vs-final-url.html
1934                http/tests/navigation/post-frames-goback1.html
1935                http/tests/navigation/postredirect-frames-goback1.html
1936
1937         * loader/FrameLoader.cpp:
1938         (WebCore::FrameLoader::loadURLIntoChildFrame): Switch to using
1939             loadDifferentDocumentItem. Also cleaned up ordering slightly (if
1940             on the archive path, there's no need to do any of the other checks).
1941         (WebCore::FrameLoader::loadDifferentDocumentItem): Renamed from
1942             navigateToDifferentDocument so that calling it from loadItem and
1943             loadURLIntoChildFrame flows more easily.
1944         (WebCore::FrameLoader::loadSameDocumentItem): Similarly, renamed from
1945             navigateWithinDocument.
1946         (WebCore::FrameLoader::loadItem): Update callsites to the above methods.
1947         * loader/FrameLoader.h:
1948
1949 2010-12-07  Dan Bernstein  <mitz@apple.com>
1950
1951         Reviewed by Darin Adler.
1952
1953         Made tables repaint correctly in all writing modes
1954         Part of: Make tables work with vertical text
1955         https://bugs.webkit.org/show_bug.cgi?id=46417
1956
1957         Tests: fast/repaint/table-writing-modes-h.html
1958                fast/repaint/table-writing-modes-v.html
1959
1960         * rendering/RenderTableSection.cpp:
1961         (WebCore::RenderTableSection::paintObject): Compute the ranges of rows and
1962         columns to repaint based on the logical extent of the repaint rect.
1963
1964 2010-12-07  Alexey Marinichev  <amarinichev@chromium.org>
1965
1966         Reviewed by James Robinson.
1967
1968         [chromium] compositor lost context recovery fix
1969         https://bugs.webkit.org/show_bug.cgi?id=50614
1970
1971         To test, load a page that triggers the compositor, kill the GPU
1972         process and hover over a link to redraw and thus restart the GPU
1973         process.  Without this patch it will assert in
1974         ContentLayerChromium::updateTextureRect; with this patch it will not.
1975
1976         * platform/graphics/chromium/LayerChromium.cpp:
1977         (WebCore::LayerChromium::setNeedsDisplay):
1978
1979 2010-12-07  Anders Carlsson  <andersca@apple.com>
1980
1981         Fix the last clang++ build error.
1982
1983         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1984         (PlatformCALayer::animationForKey):
1985         Cast the returned animation to the correct type.
1986
1987 2010-12-07  Anders Carlsson  <andersca@apple.com>
1988
1989         Fix some clang++ build errors.
1990
1991         * platform/graphics/ca/GraphicsLayerCA.cpp:
1992         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
1993         Remove unused variable.
1994
1995         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
1996         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1997         Fix constness of pointers.
1998
1999 2010-12-07  Simon Fraser  <simon.fraser@apple.com>
2000
2001         Reviewed by Chris Marrin.
2002
2003         Fix the Color -> CGColorRef conversions for the debug colors
2004         used for compositing layers.
2005
2006         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2007         (PlatformCALayer::setBackgroundColor):
2008         (PlatformCALayer::setBorderColor):
2009
2010 2010-12-07  Brian Weinstein  <bweinstein@apple.com>
2011
2012         Reviewed by John Sullivan.
2013
2014         Part of Layering Violation in ContextMenu
2015         https://bugs.webkit.org/show_bug.cgi?id=50586
2016         
2017         ContextMenuMac.mm had a WebCoreMenuTarget class, which was responsible for wrapping
2018         a ContextMenuItem, and calling through to the ContextMenuController to validate it
2019         and call a function when it was selected.
2020         
2021         It was a layering violation to have this class here, because ContextMenu can't know
2022         about ContextMenuController.
2023         
2024         This patch moves the class that wraps the ContextMenuItems to WebKit/mac/WebHTMLView.mm,
2025         and sets up the menu targets there.
2026
2027         No change in behavior, no new tests.
2028
2029         * WebCore.exp.in: Added function that needs to be exported.
2030         * platform/mac/ContextMenuMac.mm:
2031         (WebCore::ContextMenu::ContextMenu): Don't set the sharedMenuTarget anymore.
2032         (WebCore::ContextMenu::appendItem): Don't call setMenuItemTarget (this is done in WebKit now).
2033         (WebCore::ContextMenu::insertItem): Ditto.
2034
2035 2010-12-07  Simon Fraser  <simon.fraser@apple.com>
2036
2037         Reviewed by Dan Bernstein.
2038
2039         -webkit-transition Fails on Multiple text-shadow Shadows
2040         https://bugs.webkit.org/show_bug.cgi?id=42281
2041         
2042         When transitioning multiple shadows, the blend function for
2043         ShadowData dropped all but the first and last shadow because
2044         of a failure to append to the end of the list. Fixed.
2045
2046         Test: transitions/multiple-text-shadow-transition.html
2047
2048         * page/animation/AnimationBase.cpp:
2049         (WebCore::PropertyWrapperShadow::blend):
2050
2051 2010-12-07  Simon Fraser  <simon.fraser@apple.com>
2052
2053         Reviewed by Beth Dakin.
2054
2055         CSS animation doesn't work for border-radius
2056         https://bugs.webkit.org/show_bug.cgi?id=48340
2057         
2058         Include CSSPropertyBorderRadius in the list of shorthand
2059         properties, so that the individual border-radius properties
2060         get animated.
2061
2062         Test: transitions/border-radius-transition.html
2063
2064         * page/animation/AnimationBase.cpp:
2065         (WebCore::addShorthandProperties):
2066
2067 2010-12-07  Maciej Stachowiak  <mjs@apple.com>
2068
2069         Reviewed by Kent Tamura.
2070
2071         Implement HTML5 hidden attribute
2072         https://bugs.webkit.org/show_bug.cgi?id=40511
2073
2074         Test: fast/html/hidden-attr.html
2075
2076         * html/HTMLElement.cpp:
2077         (WebCore::HTMLElement::mapToEntry): Pick up hidden as a global mapped attribute.
2078         (WebCore::HTMLElement::parseMappedAttribute): Map hidden attribute to display: none.
2079
2080 2010-12-07  Kenneth Russell  <kbr@google.com>
2081
2082         Reviewed by David Levin.
2083
2084         Fix compilation of core web audio files on Windows
2085         https://bugs.webkit.org/show_bug.cgi?id=50603
2086
2087         Changed a few constructs using C99 features of math.h to use
2088         wtf/MathExtras.h instead. Changed inline definitions of a couple of
2089         const static doubles in classes to out-of-line. Built Chrome with
2090         web audio enabled on Windows and Mac OS X to test these changes.
2091
2092         No new tests since audio API is not yet implemented.
2093
2094         * WebCore.gypi:
2095         * platform/audio/AudioResampler.cpp:
2096         * platform/audio/Biquad.cpp:
2097         (WebCore::Biquad::setLowpassParams):
2098         (WebCore::Biquad::setHighpassParams):
2099         (WebCore::Biquad::setLowShelfParams):
2100         * platform/audio/Cone.cpp:
2101         (WebCore::ConeEffect::gain):
2102         * platform/audio/EqualPowerPanner.cpp:
2103         (WebCore::EqualPowerPanner::pan):
2104         * platform/audio/FFTFrame.cpp:
2105         (WebCore::FFTFrame::interpolateFrequencyComponents):
2106         (WebCore::FFTFrame::extractAverageGroupDelay):
2107         (WebCore::FFTFrame::addConstantGroupDelay):
2108         * platform/audio/HRTFKernel.cpp:
2109         * platform/audio/HRTFPanner.cpp:
2110         * webaudio/AudioBufferSourceNode.cpp:
2111         (WebCore::AudioBufferSourceNode::readFromBufferWithGrainEnvelope):
2112         * webaudio/AudioPannerNode.cpp:
2113         (WebCore::AudioPannerNode::getAzimuthElevation):
2114         * webaudio/AudioParam.cpp: Added.
2115         (AudioParam::setValue):
2116         (AudioParam::smooth):
2117         * webaudio/AudioParam.h:
2118         * webaudio/RealtimeAnalyser.cpp:
2119
2120 2010-11-25  Philippe Normand  <pnormand@igalia.com>
2121
2122         Reviewed by Martin Robinson.
2123
2124         [GStreamer] faster elements linking
2125         https://bugs.webkit.org/show_bug.cgi?id=50067
2126
2127         Perform less checks during GStreamer elements linking if building
2128         against GStreamer >= 0.10.30.
2129
2130         * platform/graphics/gstreamer/GStreamerGWorld.cpp:
2131         (WebCore::GStreamerGWorld::enterFullscreen):
2132         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2133         (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
2134
2135 2010-12-07  Philippe Normand  <pnormand@igalia.com>
2136
2137         Reviewed by Gustavo Noronha Silva.
2138
2139         [GStreamer] ::buffered() should return multiple ranges in some cases
2140         https://bugs.webkit.org/show_bug.cgi?id=45101
2141
2142         Improved the ::buffered() method thanks to the new buffering query
2143         support that landed in GStreamer 0.10.31. The method now
2144         queries the media buffered-ranges on the pipeline and queue2
2145         handles it if it's buffering the media to disk.
2146
2147         The webkitwebsrc element also gained BYTES duration query
2148         support. This is needed in the rare cases where uridecodebin
2149         configures its queue before the HTTP server returns the media
2150         Content-Length.
2151
2152         Test: http/tests/media/video-buffered.html
2153
2154         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2155         (WebCore::MediaPlayerPrivateGStreamer::buffered):
2156         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
2157         (webkit_web_src_init):
2158         (webKitWebSrcQuery): Make webkitwebsrc handle the duration queries
2159         if it's aware of the media content-length.
2160         * platform/gtk/RenderThemeGtk.cpp:
2161         (WebCore::RenderThemeGtk::paintMediaSliderTrack): Fix position of
2162         the second and next buffered ranges.
2163
2164 2010-12-07  Yael Aharon  <yael.aharon@nokia.com>
2165
2166         Reviewed by Antonio Gomes.
2167
2168         Spatial navigation not Working for Map and Area Tags
2169         https://bugs.webkit.org/show_bug.cgi?id=47142
2170
2171         Give area elements special treatment in spatial navigation algorithm by getting the
2172         rect of the area from the associated image. Since area elements are likely to overlap
2173         if they are not rects, or if authors are not careful, we flatten the rect of area elements.
2174
2175         Tests: fast/spatial-navigation/snav-imagemap-area-not-focusable.html
2176                fast/spatial-navigation/snav-imagemap-area-without-image.html
2177                fast/spatial-navigation/snav-imagemap-overlapped-areas.html
2178                fast/spatial-navigation/snav-imagemap-simple.html
2179
2180         * page/FocusController.cpp:
2181         (WebCore::FocusController::findFocusCandidateInContainer):
2182         (WebCore::FocusController::advanceFocusDirectionallyInContainer):
2183         (WebCore::FocusController::advanceFocusDirectionally):
2184         * page/SpatialNavigation.cpp:
2185         (WebCore::FocusCandidate::FocusCandidate):
2186         (WebCore::virtualRectForDirection):
2187         (WebCore::virtualRectForAreaElementAndDirection):
2188         * page/SpatialNavigation.h:
2189         (WebCore::FocusCandidate::FocusCandidate):
2190
2191 2010-12-07  Darin Adler  <darin@apple.com>
2192
2193         Try to fix V8 build.
2194
2195         * bindings/generic/BindingDOMWindow.h:
2196         (WebCore::BindingDOMWindow::createWindow): Pass security origin.
2197
2198 2010-12-07  Darin Adler  <darin@apple.com>
2199
2200         Another build fix.
2201
2202         * loader/CrossOriginAccessControl.cpp: Added a missing include.
2203
2204 2010-12-07  Darin Adler  <darin@apple.com>
2205
2206         Try to fix build.
2207
2208         * plugins/PluginView.cpp:
2209         (WebCore::PluginView::start): Pass security origin.
2210         (WebCore::PluginView::getURLNotify): Ditto.
2211         (WebCore::PluginView::getURL): Ditto.
2212         (WebCore::PluginView::handlePost): Ditto.
2213
2214 2010-12-06  Darin Adler  <darin@apple.com>
2215
2216         Reviewed by Sam Weinig.
2217
2218         Pass security origin to make local file decision correctly
2219         https://bugs.webkit.org/show_bug.cgi?id=48603
2220
2221         * bindings/generic/BindingDOMWindow.h:
2222         (WebCore::BindingDOMWindow::createWindow): Pass security origin.
2223         (WebCore::BindingDOMWindow::open): Ditto.
2224         * bindings/generic/BindingFrame.h:
2225         (WebCore::BindingFrame::navigateIfAllowed): Ditto.
2226
2227         * bindings/js/JSDOMWindowCustom.cpp:
2228         (WebCore::JSDOMWindow::setLocation): Pass security origin.
2229         (WebCore::createWindow): Ditto.
2230         (WebCore::JSDOMWindow::open): Ditto.
2231
2232         * bindings/js/JSDocumentCustom.cpp:
2233         (WebCore::JSDocument::setLocation): Pass security origin.
2234
2235         * dom/Document.cpp:
2236         (WebCore::Document::processHttpEquiv): Pass security origin.
2237
2238         * inspector/InspectorController.cpp:
2239         (WebCore::InspectorController::openInInspectedWindow):
2240         Pass security origin.
2241
2242         * loader/FrameLoader.cpp:
2243         (WebCore::FrameLoader::changeLocation): Added a security origin
2244         argument, passed through to urlSelected.
2245         (WebCore::FrameLoader::urlSelected): Replaced the resource request
2246         and frame name arguments with a frame load request arguments in one
2247         overload, and changed the other overload to pass in the current
2248         frame's document for the security origin.
2249         (WebCore::FrameLoader::loadFrameRequest): Moved the canDisplay
2250         check before the referrer computation because it no longer needs
2251         to look at the referrer. Replaced the call to canDisplay that
2252         used the target frame's security origin and the call to
2253         deprecatedCanDisplay with a single call to canDisplay that uses
2254         the requester security origin.
2255
2256         * loader/FrameLoader.h: Updated for argument changes above.
2257
2258         * loader/NavigationScheduler.cpp:
2259         (WebCore::ScheduledURLNavigation::ScheduledURLNavigation): Added
2260         a security origin.
2261         (WebCore::ScheduledURLNavigation::fire): Pass the security origin
2262         in to FrameLoader::changeLocation.
2263         (WebCore::ScheduledURLNavigation::securityOrigin): Added.
2264         (WebCore::ScheduledRedirect::ScheduledRedirect): Added a security
2265         origin argument.
2266         (WebCore::ScheduledLocationChange::ScheduledLocationChange): Ditto.
2267         (WebCore::ScheduledRefresh::ScheduledRefresh): Ditto.
2268         (WebCore::ScheduledRefresh::fire): Pass the security origin in to
2269         FrameLoader::changeLocation.
2270         (WebCore::ScheduledFormSubmission::fire): Include the security
2271         origin when constructing form submission.
2272         (WebCore::NavigationScheduler::scheduleRedirect): Include the security
2273         origin when creating the scheduled navigation object.
2274         (WebCore::NavigationScheduler::scheduleLocationChange): Ditto.
2275         (WebCore::NavigationScheduler::scheduleRefresh): Ditto.
2276
2277         * loader/NavigationScheduler.h: Added the security origin argument
2278         to scheduleLocationChange.
2279
2280         * loader/SubframeLoader.cpp:
2281         (WebCore::SubframeLoader::loadOrRedirectSubframe): Pass in the security
2282         origin when calling scheduleLocationChange.
2283         * loader/appcache/ApplicationCacheGroup.cpp:
2284         (WebCore::ApplicationCacheGroup::selectCache): Ditto.
2285
2286         * page/ContextMenuController.cpp:
2287         (WebCore::openNewWindow): Pass in the security origin.
2288         (WebCore::ContextMenuController::contextMenuItemSelected): Ditto.
2289
2290         * page/FrameLoadRequest.h: Added a security origin called the requester
2291         to all FrameLoadRequest objects.
2292
2293         * page/XSSAuditor.cpp:
2294         (WebCore::XSSAuditor::findInRequest): Added the security origin.
2295
2296 2010-12-07  Yury Semikhatsky  <yurys@chromium.org>
2297
2298         Reviewed by Pavel Feldman.
2299
2300         Web Inspector: avoid initializing Context on when creating attaching listener to ScriptDebugServer
2301         https://bugs.webkit.org/show_bug.cgi?id=50627
2302
2303         * bindings/v8/ScriptDebugServer.cpp:
2304         (WebCore::ScriptDebugServer::addListener): don't try to collect already parsed scripts if context has
2305         not been initialized yet.
2306
2307 2010-12-07  Csaba Osztrogon√°c  <ossy@webkit.org>
2308
2309         Unreviewed. Rolling out r73421, because it made transitions/color-transition-all.html flakey.
2310
2311         * page/animation/AnimationBase.cpp:
2312         (WebCore::addShorthandProperties):
2313
2314 2010-12-07  Martin Robinson  <mrobinson@igalia.com>
2315
2316         Unreviewed, rolling out r73392.
2317         http://trac.webkit.org/changeset/73392
2318         https://bugs.webkit.org/show_bug.cgi?id=50489
2319
2320         This commit caused crashes on the GTK+ bots
2321
2322         * bindings/ScriptControllerBase.cpp:
2323         (WebCore::ScriptController::executeIfJavaScriptURL):
2324         * dom/Document.cpp:
2325         (WebCore::Document::Document):
2326         (WebCore::Document::close):
2327         (WebCore::Document::lastModified):
2328         (WebCore::Document::finishedParsing):
2329         (WebCore::Document::initSecurityContext):
2330         (WebCore::Document::updateURLForPushOrReplaceState):
2331         * dom/Document.h:
2332         * dom/ProcessingInstruction.cpp:
2333         (WebCore::ProcessingInstruction::checkStyleSheet):
2334         * dom/ScriptElement.cpp:
2335         (WebCore::ScriptElement::scriptCharset):
2336         * html/HTMLLinkElement.cpp:
2337         (WebCore::HTMLLinkElement::process):
2338         * html/MediaDocument.cpp:
2339         (WebCore::MediaDocument::replaceMediaElementTimerFired):
2340         * html/PluginDocument.cpp:
2341         (WebCore::PluginDocumentParser::createDocumentStructure):
2342         * loader/DocumentLoader.cpp:
2343         (WebCore::DocumentLoader::DocumentLoader):
2344         (WebCore::DocumentLoader::finishedLoading):
2345         (WebCore::DocumentLoader::commitData):
2346         (WebCore::DocumentLoader::setupForReplaceByMIMEType):
2347         (WebCore::DocumentLoader::setFrame):
2348         * loader/DocumentLoader.h:
2349         * loader/DocumentWriter.cpp:
2350         (WebCore::DocumentWriter::begin):
2351         * loader/DocumentWriter.h:
2352         * loader/FrameLoader.cpp:
2353         (WebCore::FrameLoader::FrameLoader):
2354         (WebCore::FrameLoader::init):
2355         (WebCore::FrameLoader::clear):
2356         (WebCore::FrameLoader::receivedFirstData):
2357         (WebCore::FrameLoader::transitionToCommitted):
2358         (WebCore::FrameLoader::open):
2359         (WebCore::FrameLoader::finishedLoadingDocument):
2360         (WebCore::FrameLoader::addExtraFieldsToRequest):
2361         * loader/FrameLoader.h:
2362         (WebCore::FrameLoader::writer):
2363         * loader/cache/CachedResourceLoader.cpp:
2364         (WebCore::CachedResourceLoader::requestPreload):
2365         * platform/network/FormDataBuilder.cpp:
2366         (WebCore::FormDataBuilder::encodingFromAcceptCharset):
2367         * svg/graphics/SVGImage.cpp:
2368         (WebCore::SVGImage::dataChanged):
2369
2370 2010-12-07  Patrick Gansterer  <paroga@webkit.org>
2371
2372         Reviewed by Andreas Kling.
2373
2374         [CMake] Remove WebKitGenerators
2375         https://bugs.webkit.org/show_bug.cgi?id=50445
2376
2377         Move remaining logic into main CMakeLists.txt.
2378
2379         * CMakeLists.txt:
2380
2381 2010-12-07  Justin Schuh  <jschuh@chromium.org>
2382
2383         Reviewed by Nikolas Zimmermann.
2384
2385         Clear old SVG cursor entry before adding a new one
2386         https://bugs.webkit.org/show_bug.cgi?id=50549
2387
2388         Test: svg/css/cursor-replace.svg
2389
2390         * css/CSSCursorImageValue.cpp:
2391         (WebCore::CSSCursorImageValue::~CSSCursorImageValue):
2392         * svg/SVGCursorElement.cpp:
2393         (WebCore::SVGCursorElement::~SVGCursorElement):
2394         (WebCore::SVGCursorElement::removeClient):
2395         (WebCore::SVGCursorElement::removeReferencedElement):
2396         * svg/SVGCursorElement.h:
2397         * svg/SVGElement.cpp:
2398         (WebCore::SVGElement::setCursorElement):
2399         (WebCore::SVGElement::cursorElementRemoved):
2400         (WebCore::SVGElement::setCursorImageValue):
2401         (WebCore::SVGElement::cursorImageElementRemoved):
2402         * svg/SVGElement.h:
2403
2404 2010-12-07  Kenichi Ishibashi  <bashi@google.com>
2405
2406         Reviewed by Kent Tamura.
2407
2408         Let HTMLObjectElement be a form associated element
2409         https://bugs.webkit.org/show_bug.cgi?id=48821
2410
2411         Introduces FormAssociatedElement class which would be a super class
2412         of form assocated elements. Some of member functions and variables of
2413         HTMLFormControlElement are migrated into this class.
2414         Following the HTML5 spec, HTMLFormControlElement class and
2415         HTMLObjectElement class are subclasses of it for now.
2416
2417         Test: fast/forms/form-collection-elements-order.html
2418
2419         * Android.mk: Added FormAssociatedElement.cpp
2420         * CMakeLists.txt: Ditto.
2421         * GNUmakefile.am: Added FormAssociatedElement.{cpp,h}
2422         * WebCore.exp.in: Added the symbol for toHTMLElement(FormAssociatedElement*)
2423         * WebCore.gypi: Added FormAssociatedElement.{cpp,h}
2424         * WebCore.pro: Ditto.
2425         * WebCore.vcproj/WebCore.vcproj: Ditto.
2426         * WebCore.xcodeproj/project.pbxproj: Ditto.
2427         * dom/CheckedRadioButtons.h: Fixed class forward declaration order.
2428         * dom/Document.cpp:
2429         (WebCore::Document::registerFormElementWithFormAttribute): Modified to
2430         use FormAssociatedElement instead of HTMLFormControlElement
2431         (WebCore::Document::unregisterFormElementWithFormAttribute): Ditto.
2432         (WebCore::Document::resetFormElementsOwner):
2433         * dom/Document.h: Ditto.
2434         * html/DOMFormData.cpp: Ditto.
2435         (WebCore::DOMFormData::DOMFormData):
2436         * html/FormAssociatedElement.cpp: Copied and renamed from WebCore/html/HTMLFormControlElement.cpp.
2437         (WebCore::FormAssociatedElement::FormAssociatedElement):
2438         (WebCore::FormAssociatedElement::~FormAssociatedElement):
2439         (WebCore::FormAssociatedElement::validity):
2440         (WebCore::FormAssociatedElement::insertedIntoTree):
2441         (WebCore::FormAssociatedElement::removedFromTree):
2442         (WebCore::FormAssociatedElement::removeFromForm):
2443         (WebCore::FormAssociatedElement::resetFormOwner):
2444         (WebCore::FormAssociatedElement::formAttributeChanged):
2445         (WebCore::toHTMLElement):
2446         * html/FormAssociatedElement.h: Ditto.
2447         (WebCore::FormAssociatedElement::ref):
2448         (WebCore::FormAssociatedElement::deref):
2449         (WebCore::FormAssociatedElement::formDestroyed):
2450         (WebCore::FormAssociatedElement::setForm):
2451         * html/HTMLElement.h: Changed the access level of findFormAncestor().
2452         * html/HTMLFormCollection.cpp:
2453         (WebCore::HTMLFormCollection::item): Modified to use FormAssociatedElement
2454         instead of HTMLFormControlElement.
2455         (WebCore::HTMLFormCollection::getNamedFormItem): Ditto.
2456         (WebCore::HTMLFormCollection::updateNameCache): Ditto.
2457         * html/HTMLFormControlElement.cpp: Modified regarding with the change of class
2458         hierarchy.
2459         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
2460         (WebCore::HTMLFormControlElement::~HTMLFormControlElement):
2461         (WebCore::HTMLFormControlElement::insertedIntoTree):
2462         (WebCore::HTMLFormControlElement::removedFromTree):
2463         (WebCore::HTMLFormControlElement::supportsFocus):
2464         (WebCore::HTMLFormControlElement::checkValidity):
2465         (WebCore::HTMLFormControlElement::virtualForm):
2466         (WebCore::HTMLFormControlElement::isDefaultButtonForForm):
2467         (WebCore::HTMLFormControlElement::attributeChanged):
2468         * html/HTMLFormControlElement.h: Ditto.
2469         (WebCore::HTMLFormControlElement::form):
2470         (WebCore::HTMLFormControlElement::disabled):
2471         (WebCore::HTMLFormControlElement::type):
2472         (WebCore::HTMLFormControlElement::refFormAssociatedElement):
2473         (WebCore::HTMLFormControlElement::derefFormAssociatedElement):
2474         * html/HTMLFormElement.cpp: Modified to use FormAssociatedElement
2475         instead of HTMLFormControlElement.
2476         (WebCore::HTMLFormElement::submitImplicitly):
2477         (WebCore::HTMLFormElement::validateInteractively):
2478         (WebCore::HTMLFormElement::submit):
2479         (WebCore::HTMLFormElement::reset):
2480         (WebCore::HTMLFormElement::formElementIndexWithFormAttribute):
2481         (WebCore::HTMLFormElement::formElementIndex):
2482         (WebCore::HTMLFormElement::registerFormElement):
2483         (WebCore::HTMLFormElement::removeFormElement):
2484         (WebCore::HTMLFormElement::defaultButton):
2485         (WebCore::HTMLFormElement::checkValidity):
2486         (WebCore::HTMLFormElement::collectUnhandledInvalidControls):
2487         (WebCore::HTMLFormElement::documentDidBecomeActive):
2488         * html/HTMLFormElement.h: Ditto.
2489         (WebCore::HTMLFormElement::associatedElements):
2490         * html/HTMLInputElement.cpp: Ditto.
2491         (WebCore::HTMLInputElement::updateCheckedRadioButtons):
2492         * html/HTMLObjectElement.cpp: Modified regarding with the change of class
2493         hierarchy.
2494         (WebCore::HTMLObjectElement::HTMLObjectElement):
2495         (WebCore::HTMLObjectElement::~HTMLObjectElement):
2496         (WebCore::HTMLObjectElement::create):
2497         (WebCore::HTMLObjectElement::attributeChanged):
2498         (WebCore::HTMLObjectElement::insertedIntoTree):
2499         (WebCore::HTMLObjectElement::removedFromTree):
2500         (WebCore::HTMLObjectElement::appendFormData):
2501         (WebCore::HTMLObjectElement::formControlName):
2502         * html/HTMLObjectElement.h: Ditto.
2503         (WebCore::HTMLObjectElement::form):
2504         (WebCore::HTMLObjectElement::isFormControlElement):
2505         (WebCore::HTMLObjectElement::isEnumeratable):
2506         (WebCore::HTMLObjectElement::refFormAssociatedElement):
2507         (WebCore::HTMLObjectElement::derefFormAssociatedElement):
2508         * html/HTMLTagNames.in: Added constructorNeedsFormElement to object tag.
2509         * html/ValidationMessage.cpp: Modified to use FormAssociatedElement
2510         instead of HTMLFormControlElement.
2511         (WebCore::ValidationMessage::ValidationMessage):
2512         (WebCore::ValidationMessage::create):
2513         * html/ValidationMessage.h: Ditto.
2514         * html/ValidityState.cpp: Ditto.
2515         (WebCore::ValidityState::validationMessage):
2516         (WebCore::ValidityState::setCustomErrorMessage):
2517         (WebCore::ValidityState::valueMissing):
2518         (WebCore::ValidityState::typeMismatch):
2519         (WebCore::ValidityState::patternMismatch):
2520         (WebCore::ValidityState::tooLong):
2521         (WebCore::ValidityState::rangeUnderflow):
2522         (WebCore::ValidityState::rangeOverflow):
2523         (WebCore::ValidityState::stepMismatch):
2524         * html/ValidityState.h: Ditto.
2525         (WebCore::ValidityState::create):
2526         (WebCore::ValidityState::ValidityState):
2527         * loader/FormSubmission.cpp: Ditto.
2528         (WebCore::FormSubmission::create):
2529
2530 2010-12-06  Pavel Feldman  <pfeldman@chromium.org>
2531
2532         Not reviewed. Rolling out r72988 for breaking iframes.
2533
2534         * css/CSSImportRule.cpp:
2535         (WebCore::CSSImportRule::insertedIntoParent):
2536
2537 2010-12-06  Hironori Bono  <hbono@chromium.org>
2538
2539         Reviewed by David Levin.
2540
2541         [Chromium] Refactor FontCacheChromiumWin.cpp
2542         https://bugs.webkit.org/show_bug.cgi?id=50611
2543         
2544         This change just moved the helper functions for the WebCore::FontCache class to the beginning of ths file.
2545
2546         No new tests are added since this is a refactoring.
2547
2548         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
2549         (WebCore::fontDataFromDescriptionAndLogFont): Moved to the beginning of the file.
2550         (WebCore::toGDIFontWeight): Moved to the beginning of the file.
2551         (WebCore::FillLogFont): Moved to the beginning of the file.
2552         (WebCore::TraitsInFamilyProcData::TraitsInFamilyProcData): Moved to the beginning of the file.
2553         (WebCore::traitsInFamilyEnumProc): Moved to the beginning of the file.
2554         (WebCore::FontCache::platformInit): Moved after the static functions.
2555
2556 2010-12-06  Alexey Marinichev  <amarinichev@chromium.org>
2557
2558         Reviewed by Kenneth Russell.
2559
2560         Throw webglcontextlost and webglcontextrestored events when a WebGL context is lost and restored.
2561         https://bugs.webkit.org/show_bug.cgi?id=50364
2562
2563         No new tests since there is currently no way to force a context lost event.
2564
2565         * html/canvas/WebGLRenderingContext.cpp:
2566         (WebCore::WebGLRenderingContext::WebGLRenderingContextRestoreTimer::fired):
2567         (WebCore::WebGLRenderingContext::create):
2568         (WebCore::WebGLRenderingContext::WebGLRenderingContext):
2569         (WebCore::WebGLRenderingContext::isContextLost):
2570         (WebCore::WebGLRenderingContext::loseContext):
2571         (WebCore::WebGLRenderingContext::restoreContext):
2572         * html/canvas/WebGLRenderingContext.h:
2573         (WebCore::WebGLRenderingContext::WebGLRenderingContextRestoreTimer::WebGLRenderingContextRestoreTimer):
2574
2575 2010-12-06  David Hyatt  <hyatt@apple.com>
2576
2577         Reviewed by Simon Fraser.
2578
2579         https://bugs.webkit.org/show_bug.cgi?id=50593
2580         
2581         Fix background canvas painting for documents with left/top overflow.  The math from the original RTL patch was incorrect.
2582         
2583         Just use the RenderView's document dimensions always.
2584
2585         * rendering/RenderBox.cpp:
2586         (WebCore::RenderBox::paintRootBoxDecorations):
2587
2588 2010-12-06  Simon Fraser  <simon.fraser@apple.com>
2589
2590         Reviewed by Beth Dakin.
2591
2592         CSS animation doesn't work for border-radius
2593         https://bugs.webkit.org/show_bug.cgi?id=48340
2594         
2595         Include CSSPropertyBorderRadius in the list of shorthand
2596         properties, so that the individual border-radius properties
2597         get animated.
2598
2599         Test: transitions/border-radius-transition.html
2600
2601         * page/animation/AnimationBase.cpp:
2602         (WebCore::addShorthandProperties):
2603
2604 2010-12-06  Ryosuke Niwa  <rniwa@webkit.org>
2605
2606         Reviewed by Tony Chang.
2607
2608         ApplyStyleCommand should take EditingStyle instead of CSSStyleDeclaration
2609         https://bugs.webkit.org/show_bug.cgi?id=49938
2610
2611         Modified ApplyStyleCommand::ApplyStyleCommand and ApplyStyleCommand::create to take EditingStyle*
2612         instead of CSSStyleDeclaration*. Also replaced much of code in Editor::computeAndSetTypingStyle
2613         by calls to EditingStyle's member functions and extracted EditingStyle::overrideWith and
2614         EditingStyle::extractAndRemoveBlockProperties.
2615
2616         No new tests are added since this is a refactoring.
2617
2618         * WebCore.exp.in: Added SelectionController::copyTypingStyle and EditingStyle::~EditingStyle.
2619         * css/CSSMutableStyleDeclaration.cpp: Made CSSMutableStyleDeclaration* in the argument list const.
2620         (WebCore::CSSMutableStyleDeclaration::merge):
2621         * css/CSSMutableStyleDeclaration.h:
2622         * editing/ApplyStyleCommand.cpp:
2623         (WebCore::ApplyStyleCommand::ApplyStyleCommand): Takes EditingStyle* instead of CSSStyleDeclaration*.
2624         (WebCore::ApplyStyleCommand::doApply): Uses EditingStyle.
2625         * editing/ApplyStyleCommand.h: m_style is now a ref-pointer to EditingStyle instead of CSSMutableStyleDeclaration.
2626         (WebCore::ApplyStyleCommand::create): Takes EditingStyle* instead of CSSStyleDeclaration*.
2627         * editing/CompositeEditCommand.cpp:
2628         (WebCore::CompositeEditCommand::applyStyle): Ditto.
2629         (WebCore::CompositeEditCommand::moveParagraphs): Calls applyStyle.
2630         (WebCore::CompositeEditCommand::breakOutOfEmptyListItem): Ditto.
2631         * editing/CompositeEditCommand.h:
2632         * editing/DeleteSelectionCommand.cpp:
2633         (WebCore::DeleteSelectionCommand::calculateTypingStyleAfterDelete): Ditto.
2634         * editing/EditCommand.cpp:
2635         * editing/EditCommand.h:
2636         * editing/EditingStyle.cpp:
2637         (WebCore::EditingStyle::~EditingStyle): Added.
2638         (WebCore::EditingStyle::overrideWithStyle): Extracted from Editor::calculateTypingStyleAfterDelete.
2639         (WebCore::EditingStyle::copy): Added.
2640         (WebCore::EditingStyle::extractAndRemoveBlockProperties): Extracted from Editor::calculateTypingStyleAfterDelete.
2641         * editing/EditingStyle.h:
2642         * editing/Editor.cpp:
2643         (WebCore::Editor::applyStyle): Calls ApplyStyleCommand::create.
2644         (WebCore::Editor::applyParagraphStyle): Ditto.
2645         (WebCore::Editor::computeAndSetTypingStyle): Ditto.
2646         * editing/InsertLineBreakCommand.cpp:
2647         (WebCore::InsertLineBreakCommand::doApply): Calls applyStyle.
2648         * editing/InsertParagraphSeparatorCommand.cpp:
2649         (WebCore::InsertParagraphSeparatorCommand::applyStyleAfterInsertion): Ditto.
2650         * editing/InsertTextCommand.cpp:
2651         (WebCore::InsertTextCommand::input): Ditto.
2652         * editing/RemoveFormatCommand.cpp:
2653         (WebCore::RemoveFormatCommand::doApply): Calls ApplyStyleCommand::create.
2654         * editing/ReplaceSelectionCommand.cpp:
2655         (WebCore::ReplaceSelectionCommand::completeHTMLReplacement): Calls applyStyle.
2656         * editing/SelectionController.cpp:
2657         (WebCore::SelectionController::copyTypingStyle): Moved from SelectionController.h
2658         * editing/SelectionController.h:
2659
2660 2010-12-05  Ryosuke Niwa  <rniwa@webkit.org>
2661
2662         Reviewed by Tony Chang.
2663
2664         Executing FormatBlock on multiple paragraphs inside pre does not remove the outer pre
2665         https://bugs.webkit.org/show_bug.cgi?id=47300
2666
2667         The bug was caused by FormatBlockCommand::formatRange's not removing refNode when the refNode
2668         contains more than one paragraphs even when the refNode is fully selected.
2669
2670         Fixed the bug by modifying FormatBlockCommand::formatRange to correctly remove the node in
2671         such a situation.
2672
2673         Also fixed a bug in ApplyBlockElementCommand::formatSelection that the end of selection
2674         is not properly updated when the end of selection resides in the node split by
2675         rangeForParagraphSplittingTextNodesIfNeeded or endOfNextParagrahSplittingTextNodesIfNeeded.
2676
2677         Test: editing/execCommand/format-block-multiple-paragraphs-in-pre.html
2678
2679         * editing/ApplyBlockElementCommand.cpp:
2680         (WebCore::ApplyBlockElementCommand::formatSelection): Calls formatRange with m_endOfLastParagraph.
2681         (WebCore::ApplyBlockElementCommand::rangeForParagraphSplittingTextNodesIfNeeded): Updates
2682         m_endOfLastParagraph when the position points to the node split by this function.
2683         (WebCore::ApplyBlockElementCommand::endOfNextParagrahSplittingTextNodesIfNeeded): Ditto.
2684         * editing/ApplyBlockElementCommand.h: Added m_endOfLastParagraph as a member variable.
2685         * editing/FormatBlockCommand.cpp:
2686         (WebCore::FormatBlockCommand::formatRange): See above.
2687         * editing/FormatBlockCommand.h:
2688         * editing/IndentOutdentCommand.cpp:
2689         (WebCore::IndentOutdentCommand::formatRange): Ignores the end of selection.
2690         * editing/IndentOutdentCommand.h:
2691
2692 2010-12-03  Zhenyao Mo  <zmo@google.com>
2693
2694         Reviewed by Kenneth Russell.
2695
2696         Postpone gl delete* calls until shaders/programs are no longer attached
2697         https://bugs.webkit.org/show_bug.cgi?id=50501
2698
2699         * html/canvas/WebGLBuffer.cpp:
2700         (WebCore::WebGLBuffer::deleteObjectImpl): Simply delete GL resource.
2701         * html/canvas/WebGLFramebuffer.cpp:
2702         (WebCore::WebGLFramebuffer::deleteObjectImpl): Ditto.
2703         * html/canvas/WebGLObject.cpp:
2704         (WebCore::WebGLObject::deleteObject): Tracking whether deleteObjectImpl should be called or not.
2705         * html/canvas/WebGLObject.h:
2706         (WebCore::WebGLObject::detachContext): Set attachmentCount to 0 to ensure OpenGL resource deletion.
2707         (WebCore::WebGLObject::onDetached): No need to track attachmentCount here as we track it in deleteObject.
2708         (WebCore::WebGLObject::isDeleted): Make this public.
2709         * html/canvas/WebGLProgram.cpp:
2710         (WebCore::WebGLProgram::deleteObjectImpl): Simply delete GL resource.
2711         * html/canvas/WebGLRenderbuffer.cpp:
2712         (WebCore::WebGLRenderbuffer::deleteObjectImpl): Ditto.
2713         * html/canvas/WebGLRenderingContext.cpp:
2714         (WebCore::WebGLRenderingContext::getProgramParameter): intercept DELETE_STATUS.
2715         (WebCore::WebGLRenderingContext::getShaderParameter): Ditto.
2716         * html/canvas/WebGLShader.cpp:
2717         (WebCore::WebGLShader::deleteObjectImpl): Simply delete GL resource.
2718         * html/canvas/WebGLTexture.cpp:
2719         (WebCore::WebGLTexture::deleteObjectImpl): Simply delete GL resource.
2720
2721 2010-12-06  Ryosuke Niwa  <rniwa@webkit.org>
2722
2723         Yet unreviewed another Leopard build fix for r73380.
2724
2725         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
2726         (PlatformCAAnimation::setKeyTimes):
2727         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2728         (PlatformCALayer::platformCALayer):
2729
2730 2010-12-06  Andy Estes  <aestes@apple.com>
2731
2732         Reviewed by Darin Adler.
2733
2734         Marquee elements do not stop animating when scrollAmount is set to 0.
2735         https://bugs.webkit.org/show_bug.cgi?id=50434
2736
2737         Test: fast/html/marquee-scrollamount.html
2738
2739         * rendering/RenderMarquee.cpp:
2740         (WebCore::RenderMarquee::timerFired): Allow increment to be 0.
2741
2742 2010-12-06  Ryosuke Niwa  <rniwa@webkit.org>
2743
2744         Unreviewed Leopard buildfix for r73380.
2745
2746         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
2747         (PlatformCAAnimation::setTimingFunctions):
2748         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2749         (PlatformCALayer::PlatformCALayer):
2750
2751 2010-12-06  Philippe Normand  <pnormand@igalia.com>
2752
2753         Reviewed by Martin Robinson.
2754
2755         [GStreamer] use ResourceHandle::setDefersLoading in WebKitWebSourceGStreamer
2756         https://bugs.webkit.org/show_bug.cgi?id=44157
2757
2758         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
2759         (webKitWebSrcNeedDataMainCb):
2760         (webKitWebSrcEnoughDataMainCb): Replaced platform-specific code
2761         with cross-platform ResourceHandle::setDefersLoading calls.
2762
2763 2010-12-06  Ryosuke Niwa  <rniwa@webkit.org>
2764
2765         Unreviewed Leopard build fix for r73388.
2766
2767         * accessibility/AccessibilitySlider.cpp:
2768         (WebCore::AccessibilitySlider::maxValueForRange):
2769         (WebCore::AccessibilitySlider::minValueForRange):
2770
2771 2010-12-06  Ryosuke Niwa  <rniwa@webkit.org>
2772
2773         Unreviewed build fix for Leopard after r73379.
2774
2775         * platform/graphics/cg/GraphicsContextCG.cpp:
2776         (WebCore::GraphicsContext::setAllowsFontSmoothing):
2777
2778 2010-12-06  Nate Chapin  <japhet@chromium.org>
2779
2780         Reviewed by Adam Barth.
2781
2782         Make DocumentWriter a member of DocumentLoader
2783         instead of FrameLoader.
2784         https://bugs.webkit.org/show_bug.cgi?id=50489
2785
2786         Refactor, no new tests.
2787
2788         * bindings/ScriptControllerBase.cpp:
2789         (WebCore::ScriptController::executeIfJavaScriptURL):
2790         * dom/Document.cpp:
2791         (WebCore::Document::Document):
2792         (WebCore::Document::close):
2793         (WebCore::Document::lastModified):
2794         (WebCore::Document::finishedParsing):
2795         (WebCore::Document::initSecurityContext):
2796         (WebCore::Document::updateURLForPushOrReplaceState):
2797         * dom/Document.h:
2798         (WebCore::Document::setDocumentLoader):
2799         (WebCore::Document::loader):
2800         * dom/ProcessingInstruction.cpp:
2801         (WebCore::ProcessingInstruction::checkStyleSheet):
2802         * dom/ScriptElement.cpp:
2803         (WebCore::ScriptElement::scriptCharset):
2804         * html/HTMLLinkElement.cpp:
2805         (WebCore::HTMLLinkElement::process):
2806         * html/MediaDocument.cpp:
2807         (WebCore::MediaDocument::replaceMediaElementTimerFired):
2808         * html/PluginDocument.cpp:
2809         (WebCore::PluginDocumentParser::createDocumentStructure):
2810         * loader/DocumentLoader.cpp:
2811         (WebCore::DocumentLoader::DocumentLoader):
2812         (WebCore::DocumentLoader::finishedLoading):
2813         (WebCore::DocumentLoader::commitData):
2814         (WebCore::DocumentLoader::setupForReplaceByMIMEType):
2815         (WebCore::DocumentLoader::setFrame):
2816         * loader/DocumentLoader.h:
2817         (WebCore::DocumentLoader::writer):
2818         * loader/DocumentWriter.h:
2819         (WebCore::DocumentWriter::setFrame):
2820         * loader/FrameLoader.cpp:
2821         (WebCore::FrameLoader::FrameLoader):
2822         (WebCore::FrameLoader::init):
2823         (WebCore::FrameLoader::clear):
2824         (WebCore::FrameLoader::receivedFirstData):
2825         (WebCore::FrameLoader::transitionToCommitted):
2826         (WebCore::FrameLoader::open):
2827         (WebCore::FrameLoader::finishedLoadingDocument):
2828         (WebCore::FrameLoader::addExtraFieldsToRequest):
2829         * loader/FrameLoader.h:
2830         (WebCore::FrameLoader::notifier):
2831         * loader/cache/CachedResourceLoader.cpp:
2832         (WebCore::CachedResourceLoader::requestPreload):
2833         * platform/network/FormDataBuilder.cpp:
2834         (WebCore::FormDataBuilder::encodingFromAcceptCharset):
2835         * svg/graphics/SVGImage.cpp:
2836         (WebCore::SVGImage::dataChanged):
2837
2838 2010-12-06  Mark Rowe  <mrowe@apple.com>
2839
2840         Build fix.
2841
2842         * WebCore.xcodeproj/project.pbxproj: Don't force WebCore to build against the 10.5 SDK.
2843         That's just plain wrong.
2844
2845 2010-12-06  Chris Fleizach  <cfleizach@apple.com>
2846
2847         Reviewed by Darin Adler.
2848
2849         HTML5 Slider does not work correctly with VoiceOver
2850         https://bugs.webkit.org/show_bug.cgi?id=50505
2851
2852         Address a few problems with the Mac implementation for the accessibility slider.
2853             1) The value indicator is not hit testable.
2854             2) The value indicator does not return an AXValue.
2855             3) In the slider, the min/max values are not correct when min/max attributes are not present.
2856             4) When you change the value with the keyboard, it doesn't send out the right notification.
2857             5) Sliders were returning AXValue and AXTopLevelUIElement attributes twice in their list of attributes.
2858  
2859         Test: platform/mac/accessibility/html-slider-indicator.html
2860
2861         * accessibility/AccessibilityObject.cpp:
2862         (WebCore::AccessibilityObject::getAttribute):
2863             Use fastGetAttribute on Element, instead of getAttribute.
2864         * accessibility/AccessibilityObject.h:
2865         (WebCore::AccessibilityObject::isInputSlider):
2866         * accessibility/AccessibilityRenderObject.cpp:
2867         (WebCore::AccessibilityRenderObject::doAccessibilityHitTest):
2868         * accessibility/AccessibilitySlider.cpp:
2869         (WebCore::AccessibilitySlider::doAccessibilityHitTest):
2870         (WebCore::AccessibilitySlider::maxValueForRange):
2871         (WebCore::AccessibilitySlider::minValueForRange):
2872         * accessibility/AccessibilitySlider.h:
2873         (WebCore::AccessibilitySlider::isInputSlider):
2874         * accessibility/mac/AccessibilityObjectWrapper.mm:
2875         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
2876         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
2877         * html/HTMLInputElement.cpp:
2878         (WebCore::HTMLInputElement::applyStep):
2879
2880 2010-12-06  David Hyatt  <hyatt@apple.com>
2881
2882         Reviewed by Simon Fraser.
2883
2884         Fix for https://bugs.webkit.org/show_bug.cgi?id=49220 <<rdar://problem/8644849>, REGRESSION: transforms now
2885         O(n^3) from pathological behavior in lowestPosition, rightmostPosition, leftmostPosition and topmostPosition.
2886
2887         This patch throws out the lowest/rightmost/leftmost/topmostPosition functions and re-architects layout overflow
2888         in the engine to cache all the information required to properly handle scrolling.
2889
2890         In the old code, there were two types of overflow: layout overflow and visual overflow.  The former could
2891         affect scrolling and the latter could not.  The distinction was largely meaningless, since layout overflow
2892         wasn't actually used to determine scroll width or scroll height.  It didn't propagate across self-painting layer
2893         boundaries either.  In the old code, the term visible overflow meant the union of the layout overflow and
2894         visual overflow rects.
2895
2896         In the new code, the two types of overflow remain, but the distinction between the two is now clear.  Visual overflow
2897         is used purely for painting and hit testing checks and layout overflow is used specifically for scrolling.  It has
2898         been expanded to propagate across self-painting layers, to factor in relative positioning and transforms, and to
2899         work with writing modes.
2900
2901         In order to minimize layout test changes, layers no longer incorporate right/bottom overflow into their width/height members.
2902         Doing so uncovered two bugs where left/top overflow was ignored (proof that even having layer dimensions is harmful).
2903         A render tree dump hack has been put into the code to keep this overflow dumping for the RenderView's layer, since otherwise
2904         a huge number of tests would change.
2905
2906         Added fast/overflow/overflow-rtl-vertical.html to test vertical writing-mode overflow.  Existing tests cover the rest.
2907
2908         * page/FrameView.cpp:
2909         (WebCore::FrameView::adjustViewSize):
2910         (WebCore::FrameView::forceLayoutForPagination):
2911         Changed to use RenderView's docTop/Left/Width/Height accessors, which simply grab the overflow and properly flip it
2912         to account for writing modes.
2913
2914         * platform/graphics/IntRect.h:
2915         (WebCore::IntRect::shiftLeftEdgeTo):
2916         (WebCore::IntRect::shiftRightEdgeTo):
2917         (WebCore::IntRect::shiftTopEdgeTo):
2918         (WebCore::IntRect::shiftBottomEdgeTo):
2919         New helper functions for sliding the edge of a rectangle without moving any of the other three edges.
2920
2921         * rendering/InlineBox.h:
2922         (WebCore::InlineBox::frameRect):
2923         frameRect is a helper for obtaining the x, y, width, height of an InlineBox as an IntRect.
2924
2925         * rendering/InlineFlowBox.cpp:
2926         (WebCore::InlineFlowBox::placeBoxesInInlineDirection):
2927         All of the overflow setting in the inline direction has been removed from this function.  All line overflow is computed
2928         at once now in a single function: computeOverflow.
2929
2930         (WebCore::InlineFlowBox::addBoxShadowVisualOverflow):
2931         (WebCore::InlineFlowBox::addTextBoxVisualOverflow):
2932         (WebCore::InlineFlowBox::addReplacedChildOverflow):
2933         Helper for propagating overflow from specific types of children that occur on a line into the InlineFlowBox's overflow.
2934
2935         (WebCore::InlineFlowBox::computeOverflow):
2936         The new function that computes both horizontal and vertical overflow for a line box.
2937
2938         (WebCore::InlineFlowBox::setLayoutOverflow):
2939         (WebCore::InlineFlowBox::setVisualOverflow):
2940         (WebCore::InlineFlowBox::setOverflowFromLogicalRects):
2941         New functions that set the overflow computed by computeOverflow.  These replace setBlockDirectionOverflowPositions
2942         and setInlineDirectionOverflowPositions.  They essentially do the same thing, but they operate on rectangles.
2943
2944         (WebCore::InlineFlowBox::nodeAtPoint):
2945         (WebCore::InlineFlowBox::paint):
2946         Changed to use visual overflow instead of visible overflow.  (Visible overflow as a union of layout and visual
2947         overflow is no longer necessary, since visual overflow is now equivalent to the old visible overflow concept.)
2948
2949         * rendering/InlineFlowBox.h:
2950         (WebCore::InlineFlowBox::logicalLayoutOverflowRect):
2951         (WebCore::InlineFlowBox::logicalVisualOverflowRect):
2952         Helpers for obtaining logical overflow rectangles, since lines compute their overflow in logical terms before
2953         converting to block coordinates at the end.
2954
2955         * rendering/RenderBlock.cpp:
2956         (WebCore::RenderBlock::layoutBlock):
2957         (WebCore::RenderBlock::addOverflowFromChildren):
2958         (WebCore::RenderBlock::computeOverflow):
2959         (WebCore::RenderBlock::addOverflowFromFloats):
2960         (WebCore::RenderBlock::addOverflowFromPositionedObjects):
2961         Blocks now have a computeOverflow function called at the end of layout that adds in all the types of overflow.  The addOverflowFromChildren
2962         method is virtual so that RenderListItem and RenderTable can subclass it.  RenderListItem has to position its list marker and
2963         propagate marker overflow up, and RenderTable adds in overflow from its sections.
2964
2965         (WebCore::RenderBlock::layoutOnlyPositionedObjects):
2966         (WebCore::RenderBlock::layoutPositionedObjects):
2967         When only positioned objects lay out, overflow must still be recomputed.  The refactoring of overflow computation into a single
2968         callable method: computeOverflow, makes it possible for this to be done easily.
2969
2970         (WebCore::RenderBlock::paint):
2971         visible -> visual.
2972
2973         (WebCore::RenderBlock::addOverhangingFloats):
2974         The propagation of float overflow has changed substantially.  The basic rules are:
2975             (1) The float must be in our floating objects list to contribute to overflow.
2976             (2) The float must be a descendant to contribute to overflow.
2977             (3) The block must have the outermost list that contains the float, or it has a self-painting layer and
2978                 so the float needs to be included in its overflow.
2979
2980         (WebCore::RenderBlock::nodeAtPoint):
2981         visible -> visual.
2982
2983         (WebCore::RenderBlock::layoutColumns):
2984         Remove column overflow computation from layoutColumns and move it to computeOverflow.
2985
2986         (WebCore::RenderBlock::adjustLinePositionForPagination):
2987         visible -> visual.
2988
2989         * rendering/RenderBlock.h:
2990         (WebCore::RenderBlock::scrollbarsChanged):
2991         Added a new virtual method used by table cells when scrollbars in an overflow:auto/scroll table cell come and go.
2992
2993         * rendering/RenderBlockLineLayout.cpp:
2994         (WebCore::RenderBlock::layoutInlineChildren):
2995         (WebCore::RenderBlock::determineStartPosition):
2996         (WebCore::RenderBlock::matchedEndLine):
2997         (WebCore::RenderBlock::addOverflowFromInlineChildren):
2998         (WebCore::RenderBlock::beforeSideVisualOverflowForLine):
2999         (WebCore::RenderBlock::afterSideVisualOverflowForLine):
3000         visible -> visual.
3001
3002         * rendering/RenderBox.cpp:
3003         (WebCore::RenderBox::scrollWidth):
3004         (WebCore::RenderBox::scrollHeight):
3005         Patched to use layoutOverflow functions instead of the old rightmost/leftmostPosition functions.
3006
3007         (WebCore::RenderBox::paintRootBoxDecorations):
3008         Use docLeft and docTop here, so that writing modes are handled.
3009
3010         (WebCore::RenderBox::clippedOverflowRectForRepaint):
3011         visible -> visual.
3012
3013         (WebCore::RenderBox::addOverflowFromChild):
3014         (WebCore::RenderBox::addLayoutOverflow):
3015         (WebCore::RenderBox::addVisualOverflow):
3016         (WebCore::RenderBox::logicalVisualOverflowRectForPropagation):
3017         (WebCore::RenderBox::visualOverflowRectForPropagation):
3018         (WebCore::RenderBox::logicalLayoutOverflowRectForPropagation):
3019         (WebCore::RenderBox::layoutOverflowRectForPropagation):
3020         * rendering/RenderBox.h:
3021         The new overflow system for boxes.  Layout overflow now crosses self-painting layer boundaries and adjusts child boxes
3022         for transforms, relative positioning and writing mode differences.
3023
3024         (WebCore::RenderBox::layoutOverflowRect):
3025         (WebCore::RenderBox::topLayoutOverflow):
3026         (WebCore::RenderBox::bottomLayoutOverflow):
3027         (WebCore::RenderBox::leftLayoutOverflow):
3028         (WebCore::RenderBox::rightLayoutOverflow):
3029         Changed the default rectangle for layout overflow to be the client box to match the scrollable areas of overflow regions.
3030
3031         (WebCore::RenderBox::clientLogicalBottom):
3032         New helper for obtaining the logical bottom of the client box.
3033
3034         (WebCore::RenderBox::clientBoxRect):
3035         New helper for obtaining the clientLeft/Top/Width/Height box.
3036
3037         * rendering/RenderBoxModelObject.h:
3038         (WebCore::RenderBoxModelObject::relativePositionLogicalOffset):
3039         Helper for obtaining the relative position offset transposed for vertical writing modes.  Used by line overflow.
3040
3041         * rendering/RenderFlexibleBox.cpp:
3042         (WebCore::RenderFlexibleBox::layoutBlock):
3043         Changed flexible boxes to just call the base class computeOverflow method.
3044
3045         * rendering/RenderInline.cpp:
3046         (WebCore::RenderInline::linesVisualOverflowBoundingBox):
3047         (WebCore::RenderInline::clippedOverflowRectForRepaint):
3048         visible -> visual.
3049
3050         * rendering/RenderInline.h:
3051         * rendering/RenderLayer.cpp:
3052         (WebCore::RenderLayer::updateLayerPosition):
3053         Changed layers to no longer incorporate right/bottom overflow into width/height.  This is the reason many layout
3054         tests change.  (Not doing this makes the layout test changes far worse, since overflow propagates across self-painting
3055         layers now.)
3056
3057         (WebCore::RenderLayer::overflowTop):
3058         (WebCore::RenderLayer::overflowBottom):
3059         (WebCore::RenderLayer::overflowLeft):
3060         (WebCore::RenderLayer::overflowRight):
3061         overflowTop/Bottom/Left/Right return overflow that accounts for writing modes, i.e., purely physical overflow that can be used
3062         to set up the scroll area.
3063
3064         (WebCore::RenderLayer::computeScrollDimensions):
3065         Drastically simplified this method now that overflowTop/Bottom/Left/Right just do the right thing regarding unreachable overflow.
3066
3067         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
3068         Make sure to explicitly set the vertical scrollbar's position just as we did with horizontal scrollbars, so that clamping to the
3069         bottom works.
3070
3071         (WebCore::performOverlapTests):
3072         (WebCore::RenderLayer::paintLayer):
3073         Fix a bug in performOverlapTests.  It incorrectly used the layer's bounds, and so it didn't account for left/top overflow out
3074         of the layer (see why I hate layers even having dimensions?).  Changed it to use the bounding box of the layer instead.
3075
3076         (WebCore::RenderLayer::hitTest):
3077         Fix a bug in hit testing.  It incorrectly used the root layer's bounds as the limit of the hit test, and so it didn't account
3078         for left/top overflow in a ScrollView (hate hate hate layers having dimensions).  I changed it to use the hit test rect instead,
3079         so that the damage rect never stops the point from being tested (unless the hit test request says not to ignore clipping).
3080
3081         (WebCore::RenderLayer::localBoundingBox):
3082         visible -> visual.
3083
3084         * rendering/RenderLayer.h:
3085         Added the new overflowTop/Left/Right/Bottom accessors.
3086
3087         * rendering/RenderLineBoxList.cpp:
3088         (WebCore::RenderLineBoxList::anyLineIntersectsRect):
3089         (WebCore::RenderLineBoxList::lineIntersectsDirtyRect):
3090         (WebCore::RenderLineBoxList::paint):
3091         (WebCore::RenderLineBoxList::hitTest):
3092         visible -> visual.
3093
3094         * rendering/RenderListItem.cpp:
3095         (WebCore::RenderListItem::addOverflowFromChildren):
3096         (WebCore::RenderListItem::positionListMarker):
3097         * rendering/RenderListItem.h:
3098         RenderListItem now positions the list marker when computing its overflow, since the marker propagates overflow back up to the list item.
3099
3100         * rendering/RenderListMarker.cpp:
3101         (WebCore::RenderListMarker::paint):
3102         visible -> visual.
3103
3104         * rendering/RenderMarquee.cpp:
3105         (WebCore::RenderMarquee::computePosition):
3106         Changed to use overflow functions instead of rightmost/lowestPosition.
3107
3108         * rendering/RenderMedia.cpp:
3109         * rendering/RenderMedia.h:
3110         Removed the lowest/topmost/rightmost/leftmostPosition functions, since control overflow is handled properly already.
3111
3112         * rendering/RenderOverflow.h:
3113         (WebCore::RenderOverflow::RenderOverflow):
3114         (WebCore::RenderOverflow::setLayoutOverflow):
3115         (WebCore::RenderOverflow::setVisualOverflow):
3116         Add new setters for layout and visual overflow as rects.
3117
3118         * rendering/RenderReplaced.cpp:
3119         (WebCore::RenderReplaced::shouldPaint):
3120         (WebCore::RenderReplaced::clippedOverflowRectForRepaint):
3121         visible -> visual.
3122
3123         * rendering/RenderRubyRun.cpp:
3124         (WebCore::RenderRubyRun::layout):
3125         Call computeOverflow to recompute our overflow information after we adjust the ruby.
3126
3127         * rendering/RenderTable.cpp:
3128         (WebCore::RenderTable::layout):
3129         (WebCore::RenderTable::addOverflowFromChildren):
3130         (WebCore::RenderTable::paint):
3131         * rendering/RenderTable.h:
3132         Move section overflow propagation into addOverflowFromChildren, and change RenderTable to just call computeOverflow.
3133
3134         * rendering/RenderTableCell.cpp:
3135         (WebCore::RenderTableCell::clippedOverflowRectForRepaint):
3136         visible -> visual.
3137
3138         (WebCore::RenderTableCell::scrollbarsChanged):
3139         Adding unreachable overflow support (something that in the old code only existed for positioned objects in the root view) exposed
3140         a bug in table layout.  If scrollbars are added during the layout that occurs after intrinsic padding was incorporated into the
3141         cell, then the cell won't lay out properly the second time (after the scrollbars have been added).  We have to adjust the intrinsic
3142         padding accounting for the presence of the new scrollbar so the second layout will get the right dimensions.
3143
3144         * rendering/RenderTableCell.h:
3145         (WebCore::RenderTableCell::hasVisualOverflow):
3146         visible -> visual.
3147
3148         * rendering/RenderTableSection.cpp:
3149         (WebCore::RenderTableSection::layoutRows):
3150         * rendering/RenderTableSection.h:
3151         visible -> visual.  Removed the leftmost/rightmost/topmost/bottommostPosition functions.
3152
3153         * rendering/RenderTreeAsText.cpp:
3154         (WebCore::writeLayers):
3155         Added a hack to render tree dumping to include right/bottom overflow for the root layer only.  This keeps a zillion layout tests
3156         from failing.
3157
3158         * rendering/RenderView.cpp:
3159         (WebCore::RenderView::layout):
3160         (WebCore::RenderView::docTop):
3161         (WebCore::RenderView::docBottom):
3162         (WebCore::RenderView::docLeft):
3163         (WebCore::RenderView::docRight):
3164         * rendering/RenderView.h:
3165         (WebCore::RenderView::docHeight):
3166         (WebCore::RenderView::docWidth):
3167         RenderView now uses docLeft/Top/Height/Width functions, which are just overflow queries that account for writing modes.  These methods
3168         are now the preferred way to query for the physical dimensions of a document.
3169
3170         * rendering/RootInlineBox.cpp:
3171         (WebCore::RootInlineBox::addHighlightOverflow):
3172         Changed to call setOverflowFromLogicalRects instead of the block/inline position functions.
3173
3174         (WebCore::RootInlineBox::alignBoxesInBlockDirection):
3175         Remove the computation of block direction overflow, since it now all happens at once after the line is built.
3176
3177         (WebCore::RootInlineBox::paddedLayoutOverflowRect):
3178         * rendering/RootInlineBox.h:
3179         Added a new helper function for incorporating the end padding into a line.  This end padding also includes the single pixel for a caret
3180         in LTR if needed.
3181
3182 2010-12-06  Chris Marrin  <cmarrin@apple.com>
3183
3184         Reviewed by Simon Fraser.
3185
3186         Share code between Mac (CA) and Windows (CACF) GraphicsLayer implementations
3187         https://bugs.webkit.org/show_bug.cgi?id=49388
3188
3189         Replaced GraphicsLayerMac with GraphicsLayerCA. GraphicsLayerCA is essentially 
3190         identical to GraphicsLayerMac, but replaces all the CoreAnimation specific calls 
3191         with calls to PlatformCALayer and PlatformCAAnimation. This makes GraphicsLayerCA 
3192         platform neutral as long as implementations of those two classes are available. 
3193         Added implementations in PlatformCALayerMac and PlatformCAAnimationMac. Also got 
3194         rid of GraphicsLayer::nativeLayer() and replaced it with GraphicsLayer::platformLayer() 
3195         to avoid confusion since both names were used to refer to the same thing. 
3196
3197         This patch is only for Mac. Windows implementation has not changed.
3198
3199         * WebCore.xcodeproj/project.pbxproj:
3200         * platform/graphics/GraphicsLayer.h:
3201         * platform/graphics/ca/GraphicsLayerCA.cpp: Copied from WebCore/platform/graphics/ca/GraphicsLayerCA.cpp.
3202         * platform/graphics/ca/GraphicsLayerCA.h: Copied from WebCore/platform/graphics/ca/GraphicsLayerCA.h.
3203         * platform/graphics/ca/PlatformCAAnimation.h: Copied from WebCore/platform/graphics/ca/PlatformCAAnimation.h.
3204         * platform/graphics/ca/PlatformCALayer.h: Copied from WebCore/platform/graphics/ca/PlatformCALayer.h.
3205         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm: Copied from WebCore/platform/graphics/ca/mac/PlatformCAAnimationMac.mm.
3206         (toCAMediaTimingFunction):
3207         * platform/graphics/ca/mac/PlatformCALayerMac.mm: Copied from WebCore/platform/graphics/ca/mac/PlatformCALayerMac.mm.
3208         (PlatformCALayer::PlatformCALayer):
3209         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
3210         * platform/graphics/chromium/GraphicsLayerChromium.h:
3211         * platform/graphics/mac/GraphicsLayerMac.h: Removed.
3212         * platform/graphics/mac/GraphicsLayerMac.mm: Removed.
3213         * platform/graphics/mac/WebLayer.h:
3214         * platform/graphics/mac/WebLayer.mm:
3215         (-[WebLayer setNeedsDisplay]):
3216         (-[WebLayer setNeedsDisplayInRect:]):
3217         (-[WebLayer display]):
3218         (-[WebLayer drawInContext:]):
3219         * platform/graphics/mac/WebTiledLayer.h:
3220         * platform/graphics/mac/WebTiledLayer.mm:
3221         (-[WebTiledLayer setNeedsDisplay]):
3222         (-[WebTiledLayer setNeedsDisplayInRect:]):
3223         (-[WebTiledLayer display]):
3224         (-[WebTiledLayer drawInContext:]):
3225         * platform/graphics/qt/GraphicsLayerQt.cpp:
3226         (WebCore::GraphicsLayerQtImpl::flushChanges):
3227         * platform/graphics/qt/GraphicsLayerQt.h:
3228         * platform/graphics/win/GraphicsLayerCACF.cpp:
3229         * platform/graphics/win/GraphicsLayerCACF.h:
3230
3231 2010-12-06  Simon Fraser  <simon.fraser@apple.com>
3232
3233         Reviewed by Dan Bernstein.
3234
3235         Font antialiasing (smoothing) changes when elements are rendered into compositing layers
3236         https://bugs.webkit.org/show_bug.cgi?id=23364
3237
3238         Text rendered by Core Graphics over a transparent background looks bad because of 
3239         font smoothing, so turn off smoothing when rendering text into compositing layers.
3240
3241         * platform/graphics/GraphicsContext.h:
3242         * platform/graphics/cg/GraphicsContextCG.cpp:
3243         (WebCore::GraphicsContext::setAllowsFontSmoothing):
3244         * platform/graphics/mac/WebLayer.mm:
3245         (drawLayerContents):
3246
3247 2010-12-06  Patrick Gansterer  <paroga@webkit.org>
3248
3249         Reviewed by Andreas Kling.
3250
3251         [WINCE] Add build system
3252         https://bugs.webkit.org/show_bug.cgi?id=50522
3253
3254         * CMakeListsWinCE.txt: Added.
3255
3256 2010-12-06  Chris Fleizach  <cfleizach@apple.com>
3257
3258         Reviewed by Oliver Hunt.
3259
3260         AX does not support HTML5 "required"
3261         https://bugs.webkit.org/show_bug.cgi?id=50507
3262
3263         Test: platform/mac/accessibility/html5-required-attribute.html
3264
3265         * accessibility/AccessibilityRenderObject.cpp:
3266         (WebCore::AccessibilityRenderObject::isRequired):
3267
3268 2010-12-06  Alejandro G. Castro  <alex@igalia.com>
3269
3270         Reviewed by Martin Robinson.
3271
3272         [GTK] using shadows leaks memory
3273         https://bugs.webkit.org/show_bug.cgi?id=50541
3274
3275         Fixed leaks in the shadow code.
3276         * platform/graphics/cairo/CairoUtilities.cpp:
3277         (WebCore::drawPatternToCairoContext): adoptRef instead of just
3278         getting a new reference.
3279         * platform/graphics/cairo/GraphicsContextCairo.cpp:
3280         (WebCore::drawPathShadow): handle cairo_path_t with smart
3281         pointers.
3282
3283 2010-12-06  Yury Semikhatsky  <yurys@chromium.org>
3284
3285         Reviewed by Pavel Feldman.
3286
3287         [v8] Web Inspector: remove duplicate code for capturing stack trace
3288         https://bugs.webkit.org/show_bug.cgi?id=50461
3289
3290         No new tests. Covered with existing inspector tests.
3291
3292         * bindings/js/ScriptCallStackFactory.cpp:
3293         (WebCore::createScriptCallStack):
3294         * bindings/js/ScriptCallStackFactory.h:
3295         * bindings/v8/ScriptCallStackFactory.cpp:
3296         (WebCore::toScriptCallFrame):
3297         (WebCore::toScriptCallFramesVector):
3298         (WebCore::createScriptCallStack):
3299         * bindings/v8/ScriptCallStackFactory.h:
3300         * bindings/v8/V8ConsoleMessage.cpp:
3301         (WebCore::V8ConsoleMessage::handler):
3302         * inspector/ScriptCallFrame.cpp:
3303         (WebCore::ScriptCallFrame::ScriptCallFrame):
3304         (WebCore::ScriptCallFrame::isEqual):
3305         (WebCore::ScriptCallFrame::buildInspectorObject):
3306         * inspector/ScriptCallFrame.h:
3307         (WebCore::ScriptCallFrame::sourceURL):
3308         * inspector/ScriptCallStack.h:
3309         * inspector/TimelineRecordFactory.cpp:
3310         (WebCore::TimelineRecordFactory::createGenericRecord):
3311         * inspector/front-end/ConsoleView.js:
3312         (WebInspector.ConsoleMessage.prototype._populateStackTraceTreeElement):
3313
3314 == Rolled over to ChangeLog-2010-12-06 ==