Fix for <rdar://problem/8890255>
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-01-20  Beth Dakin  <bdakin@apple.com>
2
3         Reviewed by Geoffrey Garen.
4
5         Fix for <rdar://problem/8890255>
6
7         Allow WebKitSystemInterface to draw scrollbars 
8         when appropriate.
9         * WebCore.exp.in:
10         * platform/mac/ScrollbarThemeMac.mm:
11         (WebCore::scrollbarMap):
12         (+[ScrollbarPrefsObserver appearancePrefsChanged:]):
13         (WebCore::ScrollbarThemeMac::registerScrollbar):
14         (WebCore::ScrollbarThemeMac::unregisterScrollbar):
15         (WebCore::ScrollbarThemeMac::paint):
16         * platform/mac/WebCoreSystemInterface.h:
17         * platform/mac/WebCoreSystemInterface.mm:
18
19 2011-01-20  Sam Weinig  <sam@webkit.org>
20
21         Reviewed by Dave Hyatt.
22
23         Cleanup Scrollbar/ScrollbarClient relationship
24         https://bugs.webkit.org/show_bug.cgi?id=52779
25
26         Pipe all scrolling through the ScrollbarClient/ScrollAnimator
27         rather than through the Scrollbar. The Scrollbar now is just
28         a "view" on the scroll position of the scrollable area it is
29         attached to.
30
31         There are now two ways to scroll a scrollable area:
32         - ScrollbarClient::scroll()
33         - ScrollbarClient::scrollToOffsetWithoutAnimation()
34
35         Both of these go through the ScrollAnimator (updating its state
36         or starting an animation). The ScrollAnimator, in turn, now calls
37         ScrollbarClient::setScrollOffsetFromAnimation, which tells the
38         Scrollbars to pull a new offset (via Scrollbar::offsetDidChange)
39         and tells the class that derives from ScrollbarClient to scroll
40         its contents (via ScrollbarClient::setScrollOffset).
41
42         * WebCore.xcodeproj/project.pbxproj:
43         Move Scrollbar.cpp to the right place.
44
45         * accessibility/AccessibilityScrollbar.cpp:
46         (WebCore::AccessibilityScrollbar::setValue):
47         Initiate the scroll through the scrollbar client, rather than the
48         scrollbar itself.
49
50         * page/FrameView.cpp:
51         (WebCore::FrameView::scrollTo):
52         * page/FrameView.h:
53         Condense the two valueChanged overrides to a single override of the
54         scrollTo function.
55
56         * platform/ScrollAnimator.cpp:
57         (WebCore::ScrollAnimator::scroll):
58         (WebCore::ScrollAnimator::scrollToOffsetWithoutAnimation):
59         (WebCore::ScrollAnimator::currentPosition):
60         (WebCore::ScrollAnimator::notityPositionChanged):
61         * platform/ScrollAnimator.h:
62         * platform/ScrollAnimatorWin.cpp:
63         (WebCore::ScrollAnimatorWin::scrollToOffsetWithoutAnimation):
64         (WebCore::ScrollAnimatorWin::animateScroll):
65         * platform/ScrollAnimatorWin.h:
66         * platform/mac/ScrollAnimatorMac.h:
67         * platform/mac/ScrollAnimatorMac.mm:
68         (WebCore::ScrollAnimatorMac::scrollToOffsetWithoutAnimation):
69         (WebCore::ScrollAnimatorMac::immediateScrollToPoint):
70         Change setScrollPositionAndStopAnimation to scrollToOffsetWithoutAnimation
71         and bottleneck all client notification of changed position through a new
72         notityPositionChanged() function.
73
74         * platform/ScrollView.cpp:
75         (WebCore::ScrollView::setScrollOffset):
76         (WebCore::ScrollView::scrollTo):
77         (WebCore::ScrollView::scrollPosition):
78         (WebCore::ScrollView::scroll):
79         (WebCore::ScrollView::updateScrollbars):
80         (WebCore::ScrollView::wheelEvent):
81         * platform/ScrollView.h:
82         (WebCore::ScrollView::horizontalScrollbar):
83         (WebCore::ScrollView::verticalScrollbar):
84         Update to scroll via the ScrollbarClient rather than the Scrollbar.
85
86         * platform/Scrollbar.cpp:
87         (WebCore::Scrollbar::offsetDidChange):
88         (WebCore::Scrollbar::autoscrollPressedPart):
89         (WebCore::Scrollbar::moveThumb):
90         (WebCore::Scrollbar::mouseMoved):
91         * platform/Scrollbar.h:
92         (WebCore::Scrollbar::setPressedPos):
93         Change the scrollbar to only updates its offset in response to
94         an offsetDidChange call.
95
96         * platform/ScrollbarClient.cpp:
97         (WebCore::ScrollbarClient::scroll):
98         (WebCore::ScrollbarClient::scrollToOffsetWithoutAnimation):
99         (WebCore::ScrollbarClient::scrollToXOffsetWithoutAnimation):
100         (WebCore::ScrollbarClient::scrollToYOffsetWithoutAnimation):
101         (WebCore::ScrollbarClient::setScrollOffsetFromAnimation):
102         * platform/ScrollbarClient.h:
103         (WebCore::ScrollbarClient::horizontalScrollbar):
104         (WebCore::ScrollbarClient::verticalScrollbar):
105         Make the increasingly misnamed ScrollbarClient responsible for
106         scrolling.
107
108         * platform/efl/ScrollbarEfl.cpp:
109         (scrollbarEflEdjeMessage):
110         * platform/gtk/MainFrameScrollbarGtk.cpp:
111         (MainFrameScrollbarGtk::gtkValueChanged):
112         * platform/qt/ScrollbarQt.cpp:
113         (WebCore::Scrollbar::contextMenu):
114         Update to move scrolling through the client.
115
116         * platform/win/PopupMenuWin.cpp:
117         (WebCore::PopupMenuWin::scrollToRevealSelection):
118         (WebCore::PopupMenuWin::scrollPosition):
119         (WebCore::PopupMenuWin::setScrollOffset):
120         (WebCore::PopupMenuWin::scrollTo):
121         (WebCore::PopupMenuWin::wndProc):
122         * platform/win/PopupMenuWin.h:
123         (WebCore::PopupMenuWin::verticalScrollbar):
124         * rendering/RenderLayer.cpp:
125         (WebCore::RenderLayer::scrollToOffset):
126         (WebCore::RenderLayer::scrollTo):
127         (WebCore::RenderLayer::setScrollOffset):
128         (WebCore::RenderLayer::scrollPosition):
129         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
130         (WebCore::RenderLayer::scroll):
131         * rendering/RenderLayer.h:
132         * rendering/RenderListBox.cpp:
133         (WebCore::RenderListBox::scrollToRevealElementAtListIndex):
134         (WebCore::RenderListBox::scroll):
135         (WebCore::RenderListBox::logicalScroll):
136         (WebCore::RenderListBox::scrollPosition):
137         (WebCore::RenderListBox::setScrollOffset):
138         (WebCore::RenderListBox::scrollTo):
139         (WebCore::RenderListBox::setScrollTop):
140         * rendering/RenderListBox.h:
141         (WebCore::RenderListBox::verticalScrollbar):
142         Update to scroll via the ScrollbarClient rather than the Scrollbar.
143
144         * rendering/RenderMarquee.cpp:
145         (WebCore::RenderMarquee::start):
146         Simplify initial paint to just do an immediate scroll to the position.
147
148 2011-01-20  Patrick Gansterer  <paroga@webkit.org>
149
150         Unreviewed WinCE build fix for r76170.
151
152         * platform/graphics/wince/FontWinCE.cpp: Added a missing include.
153         * platform/graphics/wince/ImageBufferData.h: Added a missing include and fixed style.
154
155 2011-01-20  James Robinson  <jamesr@chromium.org>
156
157         Reviewed by Darin Fisher.
158
159         Implement mozilla's requestAnimationFrame API
160         https://bugs.webkit.org/show_bug.cgi?id=51218
161
162         This implements mozilla's proposed requestAnimationFrame API.  The idea with this API is that
163         an author driving an animation from script could use window.requestAnimationFrame(callback)
164         instead of window.setTimeout(callback, 0) to schedule their update logic and let the browser
165         decide when to update the animations.  This avoids doing unnecessary work when the page content
166         is offscreen or is being displayed at a different framerate than what the page author expects.
167
168         Mozilla's proposal is here: https://developer.mozilla.org/en/DOM/window.mozRequestAnimationFrame
169         This implements window.mozRequestAnimationFrame as window.webkitRequestAnimationFrame with the
170         following changes:
171         *) Only the callback syntax is supported, there is no before paint event
172         *) webkitRequestAnimationFrame supports a second parameter Element to let the author indicate
173             what content they intend to animate.  That way if the page is being displayed but the element
174             in question is offscreen, we can avoid invoking the callback.
175         *) No timestamp is provided to the caller and there is no window.animationStartTime property
176             (see https://bugs.webkit.org/show_bug.cgi?id=51952 for discussion of this property)
177         *) window.webkitRequestAnimationFrame returns a numerical id that can be used to cancel the callback
178             using window.cancelWebkitRequestAnimationFrame, to parallel window.setTimeout()/window.clearTime().
179
180         The implementation depends on the embedder scheduling the callbacks since the callback invocation
181         depends on the page's visibility and the embedder's paint scheduling, neither of which are exposed
182         to WebCore.  The expectation for the embedder is that at some point Chrome::scheduleAnimation() is
183         called FrameView::serviceScriptedAnimations() should be called for the associated Page's main frame.
184         Ideally serviceScriptedAnimations() would be called prior to rendering - although in practice the
185         embedder has to rate limit callbacks and may not be able to tie the callback directly to the
186         rendering loop.
187
188         Tests: fast/animation/request-animation-frame-cancel.html
189                fast/animation/request-animation-frame-cancel2.html
190                fast/animation/request-animation-frame-display.html
191                fast/animation/request-animation-frame-within-callback.html
192                fast/animation/request-animation-frame.html
193
194         * WebCore.gypi:
195         * dom/Document.cpp:
196         (WebCore::Document::Document):
197         (WebCore::Document::webkitRequestAnimationFrame):
198         (WebCore::Document::webkitCancelRequestAnimationFrame):
199         (WebCore::Document::serviceScriptedAnimations):
200         * dom/Document.h:
201         * dom/RequestAnimationFrameCallback.h: Added.
202         (WebCore::RequestAnimationFrameCallback::~RequestAnimationFrameCallback):
203         * dom/RequestAnimationFrameCallback.idl: Added.
204         * loader/EmptyClients.h:
205         (WebCore::EmptyChromeClient::scheduleAnimation):
206         * page/Chrome.cpp:
207         (WebCore::Chrome::scheduleAnimation):
208         * page/Chrome.h:
209         * page/ChromeClient.h:
210         * page/DOMWindow.cpp:
211         (WebCore::DOMWindow::webkitRequestAnimationFrame):
212         (WebCore::DOMWindow::webkitCancelRequestAnimationFrame):
213         * page/DOMWindow.h:
214         * page/DOMWindow.idl:
215         * page/FrameView.cpp:
216         (WebCore::FrameView::scheduleAnimation):
217         (WebCore::FrameView::serviceScriptedAnimations):
218         * page/FrameView.h:
219         * platform/HostWindow.h:
220
221 2011-01-20  James Robinson  <jamesr@chromium.org>
222
223         Reviewed by Nate Chapin.
224
225         [v8] CodeGeneratorV8 generates incorrect code for callbacks with no parameters
226         https://bugs.webkit.org/show_bug.cgi?id=52837
227
228         When generating code to invoke a callback with no parameters CodeGeneratorV8.pm was generating the following:
229         v8::Handle<v8::Value> argv[] = {}; which does not compile in visual studio.  Instead, if the argument count
230         is 0, we can just pass a NULL pointer for the argv parameter.
231
232         Test added to bindings/scripts/test/TestCallback.idl and covered by run-bindings-tests.  This
233         patch also includes some spurious changes to the bindings tests golden files (mostly GObject)
234         because the old golden files were out of date.
235
236         * bindings/scripts/CodeGeneratorV8.pm:
237         * bindings/scripts/test/CPP/WebDOMTestCallback.cpp:
238         (WebDOMTestCallback::callbackWithNoParam):
239         * bindings/scripts/test/CPP/WebDOMTestCallback.h:
240         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
241         (webkit_dom_test_callback_callback_with_no_param):
242         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
243         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
244         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
245         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
246         * bindings/scripts/test/JS/JSTestCallback.cpp:
247         (WebCore::JSTestCallback::callbackWithNoParam):
248         * bindings/scripts/test/JS/JSTestCallback.h:
249         * bindings/scripts/test/JS/JSTestInterface.cpp:
250         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
251         * bindings/scripts/test/JS/JSTestObj.cpp:
252         * bindings/scripts/test/ObjC/DOMTestCallback.h:
253         * bindings/scripts/test/ObjC/DOMTestCallback.mm:
254         (-[DOMTestCallback callbackWithNoParam]):
255         * bindings/scripts/test/TestCallback.idl:
256         * bindings/scripts/test/V8/V8TestCallback.cpp:
257         (WebCore::V8TestCallback::callbackWithNoParam):
258         * bindings/scripts/test/V8/V8TestCallback.h:
259         * bindings/scripts/test/V8/V8TestObj.cpp:
260         (WebCore::TestObjInternal::reflectedUnsignedIntegralAttrAttrGetter):
261
262 2011-01-20  James Robinson  <jamesr@chromium.org>
263
264         Reviewed by Eric "Baller" Seidel.
265
266         RenderTableSection's setNeedsCellRecalc needs to null check table()
267         https://bugs.webkit.org/show_bug.cgi?id=52770
268
269         Null checks table() before deferencing it in RenderTableSection::setNeedsCellRecalc.
270         This can be null during detach().  Test constructed by Eric Seidel.
271
272         Test: fast/css-generated-content/table-with-scrollbar-corner.html
273
274         * rendering/RenderTableSection.cpp:
275         (WebCore::RenderTableSection::setNeedsCellRecalc):
276         * rendering/RenderTableSection.h:
277
278 2011-01-20  Dirk Schulze  <krit@webkit.org>
279
280         Reviewed by Rob Buis.
281
282         SVG Pattern doesn't take preserveAspectRatio of references Pattern
283         https://bugs.webkit.org/show_bug.cgi?id=52802
284
285         SVGPattern didn't take preserveAspectRatio of a referenced SVGPattern into account. Store preserveAspectRatio
286         in PatternAttributes as well, if the attribute was set on the referenced SVGPattern element.
287
288         Test: svg/custom/pattern-referencing-preserve-aspect-ratio.svg
289
290         * rendering/svg/RenderSVGResourcePattern.cpp:
291         (WebCore::RenderSVGResourcePattern::buildTileImageTransform):
292         * svg/PatternAttributes.h:
293         (WebCore::PatternAttributes::PatternAttributes):
294         (WebCore::PatternAttributes::preserveAspectRatio):
295         (WebCore::PatternAttributes::setPreserveAspectRatio):
296         (WebCore::PatternAttributes::hasPreserveAspectRatio):
297         * svg/SVGPatternElement.cpp:
298         (WebCore::SVGPatternElement::collectPatternAttributes):
299
300 2011-01-20  Dan Bernstein  <mitz@apple.com>
301
302         Reviewed by Adele Peterson.
303
304         <rdar://problem/8765498> REGRESSION (r72141): Cannot order prints with Aperture 3.1
305
306         <rdar://problem/8884648> REGRESSION (r72141): Safari hangs when visiting a page on www.bfmtv.com
307         https://bugs.webkit.org/show_bug.cgi?id=52765
308
309         <rdar://problem/8890909> REGRESSION (r72141): Very Slow Rendering With Certain Markup
310         https://bugs.webkit.org/show_bug.cgi?id=52265
311
312         Test: fast/block/line-layout/negative-max-height.html
313
314         Integer overflow detection led to a block having a huge height. This manifested as broken layout
315         in the first bug and as extreme slowness in the latter bugs because of
316         https://bugs.webkit.org/show_bug.cgi?id=52832
317
318         * rendering/RootInlineBox.cpp:
319         (WebCore::RootInlineBox::alignBoxesInBlockDirection): Clamp maxHeight to 0 so the next line
320         cannot start above this line. The negative maxHeight also caused the integer overflow detection
321         logic to give the block a huge height.
322
323 2011-01-20  Yi Shen  <yi.4.shen@nokia.com>
324
325         Reviewed by Eric Carlson.
326
327         Clean up the Media Controls CSS for Qt
328         https://bugs.webkit.org/show_bug.cgi?id=52822
329
330         Split the audio::-webkit-media-xxx and video::-webkit-media-xxx rules 
331         in mediaControlsQt.css, and remove the duplicate audio::-webkit-media-xxx
332         rules from mediaControlsQtFullscreen.css.
333
334         * css/mediaControlsQt.css:
335         (audio::-webkit-media-controls-panel):
336         (video::-webkit-media-controls-panel):
337         (audio::-webkit-media-controls-mute-button):
338         (video::-webkit-media-controls-mute-button):
339         (audio::-webkit-media-controls-play-button):
340         (video::-webkit-media-controls-play-button):
341         (audio::-webkit-media-controls-timeline-container):
342         (video::-webkit-media-controls-timeline-container):
343         (audio::-webkit-media-controls-current-time-display):
344         (video::-webkit-media-controls-current-time-display):
345         (audio::-webkit-media-controls-time-remaining-display):
346         (video::-webkit-media-controls-time-remaining-display):
347         (audio::-webkit-media-controls-timeline):
348         (video::-webkit-media-controls-timeline):
349         (audio::-webkit-media-controls-volume-slider-container):
350         (video::-webkit-media-controls-volume-slider-container):
351         (audio::-webkit-media-controls-volume-slider):
352         (video::-webkit-media-controls-volume-slider):
353         (audio::-webkit-media-controls-seek-back-button):
354         (video::-webkit-media-controls-seek-back-button):
355         (audio::-webkit-media-controls-seek-forward-button):
356         (video::-webkit-media-controls-seek-forward-button):
357         (audio::-webkit-media-controls-fullscreen-button):
358         (video::-webkit-media-controls-fullscreen-button):
359         (audio::-webkit-media-controls-rewind-button):
360         (video::-webkit-media-controls-rewind-button):
361         (audio::-webkit-media-controls-return-to-realtime-button):
362         (video::-webkit-media-controls-return-to-realtime-button):
363         (audio::-webkit-media-controls-toggle-closed-captions-button):
364         (video::-webkit-media-controls-toggle-closed-captions-button):
365         * css/mediaControlsQtFullscreen.css:
366         (video::-webkit-media-controls-time-remaining-display):
367         (video::-webkit-media-controls-seek-back-button):
368         (video::-webkit-media-controls-seek-forward-button):
369         (video::-webkit-media-controls-rewind-button):
370         (video::-webkit-media-controls-return-to-realtime-button):
371         (video::-webkit-media-controls-toggle-closed-captions-button):
372
373 2011-01-20  Alexander Pavlov  <apavlov@chromium.org>
374
375         Reviewed by Pavel Feldman.
376
377         Web Inspector: [REGRESSION] Canceling of CSS numeric values increment/decrement is broken
378         https://bugs.webkit.org/show_bug.cgi?id=52816
379
380         * inspector/front-end/StylesSidebarPane.js:
381         (WebInspector.StylePropertyTreeElement.prototype):
382
383 2011-01-20  Dawit Alemayehu  <adawit@kde.org>
384
385         Reviewed by Andreas Kling.
386
387         [Qt] Fix Layering violation in MediaPlayerPrivateQt.
388         https://bugs.webkit.org/show_bug.cgi?id=52733
389
390         No new tests. no behavioral change.
391
392        * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
393         (WebCore::MediaPlayerPrivateQt::commitLoad):
394
395 2011-01-20  Nate Chapin  <japhet@chromium.org>
396
397         Reviewed by Darin Fisher.
398
399         [V8] Call malloc and memcpy directly instead of
400         of strdup in convertV8ObjectToNPVariant() when
401         converting strings. If there is a null character
402         in the string, our use of strdup causes us to allocate
403         too little memory, leading to out of bounds reads.
404
405         https://bugs.webkit.org/show_bug.cgi?id=52631
406
407         * bindings/v8/V8NPUtils.cpp:
408         (WebCore::convertV8ObjectToNPVariant):
409
410 2011-01-20  Andreas Kling  <kling@webkit.org>
411
412         Reviewed by Ariya Hidayat.
413
414         [Qt] Fill shadow scratch buffer with proper transparent pixels
415
416         QImage::fill() has no Qt::GlobalColor overload in Qt 4.7 (coming in 4.8)
417         so doing QImage::fill(Qt::transparent) will actually fill all pixels with
418         the RGBA value 0x00000013.
419
420         * platform/graphics/qt/ContextShadowQt.cpp:
421         (WebCore::ShadowBuffer::scratchImage):
422
423 2011-01-19  Adam Roben  <aroben@apple.com>
424
425         Remove WKCACFContextFlusher
426
427         It wasn't doing anything.
428
429         Fixes <http://webkit.org/b/52752> WKCACFContextFlusher is unused
430
431         Reviewed by Simon Fraser.
432
433         * WebCore.vcproj/WebCore.vcproj: Removed WKCACFContextFlusher. Also let VS have its way with
434         the file.
435
436         * platform/graphics/win/WKCACFContextFlusher.cpp: Removed.
437         * platform/graphics/win/WKCACFContextFlusher.h: Removed.
438
439         * platform/graphics/win/WKCACFLayerRenderer.cpp:
440         (WebCore::WKCACFLayerRenderer::~WKCACFLayerRenderer):
441         (WebCore::WKCACFLayerRenderer::layerTreeDidChange):
442         Stop telling WKCACFContextFlusher about our context, since it never did anything with it.
443
444 2011-01-19  Adam Roben  <aroben@apple.com>
445
446         Only flush our own context when we get resized
447
448         Fixes <http://webkit.org/b/52751> All WKCACFContexts with uncommitted
449         changes get flushed whenever any composited page is resized
450
451         Reviewed by Simon Fraser.
452
453         * platform/graphics/win/WKCACFLayerRenderer.cpp:
454         (WebCore::WKCACFLayerRenderer::resize): Just flush our own context, not all contexts
455         WKCACFContextFlusher knows about. After all, ours is the only one that just got resized!
456
457 2011-01-19  Adam Roben  <aroben@apple.com>
458
459         Make WKCACFLayerRenderer ref-counted
460
461         This will be needed to handle cases where the client might release its reference to us while
462         we're calling out to it.
463
464         WKCACFLayerRenderer now has a setClient function, which is used rather than passing the
465         client to create(). This allows clients to null out the client pointer when they're done
466         with the renderer.
467
468         Fixes <http://webkit.org/b/52749> WKCACFLayerRenderer should be
469         ref-counted
470
471         Reviewed by Simon Fraser.
472
473         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.cpp:
474         (WebCore::MediaPlayerPrivateFullscreenWindow::MediaPlayerPrivateFullscreenWindow):
475         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h:
476         Updated for WKCACFLayerRenderer changes.
477
478         * platform/graphics/win/WKCACFLayerRenderer.cpp:
479         (WebCore::WKCACFLayerRenderer::acceleratedCompositingAvailable): Updated for changes to
480         create().
481         (WebCore::WKCACFLayerRenderer::create): No longer takes a WKCACFLayerRendererClient. Now
482         returns a PassOwnPtr.
483         (WebCore::WKCACFLayerRenderer::WKCACFLayerRenderer): No longer takes a
484         WKCACFLayerRendererClient.
485
486         * platform/graphics/win/WKCACFLayerRenderer.h: Made WKCACFLayerRenderer inherit from
487         RefCounted.
488         (WebCore::WKCACFLayerRenderer::setClient): Added this simple setter.
489
490 2011-01-20  Csaba Osztrogonác  <ossy@webkit.org>
491
492         [Qt][V8] Unreviewed buildfix after r76248.
493
494         * bindings/v8/ScriptCachedFrameData.h: Add missing include.
495
496 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
497
498         Reviewed by Yury Semikhatsky.
499
500         Web Inspector: enable resource agent upon request.
501         https://bugs.webkit.org/show_bug.cgi?id=52815
502
503         We should not send network-related notifications unless front-end
504         is interested.
505
506         * inspector/Inspector.idl:
507         * inspector/InspectorController.cpp:
508         (WebCore::InspectorController::restoreInspectorStateFromCookie):
509         (WebCore::InspectorController::connectFrontend):
510         (WebCore::InspectorController::resourceAgent):
511         * inspector/InspectorController.h:
512         (WebCore::InspectorController::consoleAgent):
513         (WebCore::InspectorController::cssAgent):
514         (WebCore::InspectorController::domAgent):
515         (WebCore::InspectorController::injectedScriptAgent):
516         (WebCore::InspectorController::runtimeAgent):
517         (WebCore::InspectorController::databaseAgent):
518         (WebCore::InspectorController::domStorageAgent):
519         (WebCore::InspectorController::fileSystemAgent):
520         * inspector/InspectorInstrumentation.cpp:
521         (WebCore::InspectorInstrumentation::retrieveResourceAgent):
522         * inspector/InspectorResourceAgent.cpp:
523         (WebCore::InspectorResourceAgent::restore):
524         (WebCore::InspectorResourceAgent::~InspectorResourceAgent):
525         (WebCore::InspectorResourceAgent::InspectorResourceAgent):
526         * inspector/InspectorResourceAgent.h:
527         (WebCore::InspectorResourceAgent::create):
528         * inspector/InspectorState.cpp:
529         (WebCore::InspectorState::InspectorState):
530         * inspector/InspectorState.h:
531
532 2011-01-20  Zoltan Horvath  <zoltan@webkit.org>
533
534         Reviewed by Csaba Osztrogonác.
535
536         Refactoring of the custom allocation framework
537         https://bugs.webkit.org/show_bug.cgi?id=49897
538
539         Inheriting from FastAllocBase can result in objects getting larger (bug #33896, #46589).
540         The modification replaces Noncopyable and FastAllocBase classes and these inherits with their
541         equivalent macro implementation at the necessary places.
542
543 2011-01-20  Mikhail Naganov  <mnaganov@chromium.org>
544
545         Reviewed by Pavel Feldman.
546
547         Web Inspector: [Chromium] CPU Profiles are cleared when navigating back and forth.
548
549         Profiles are now not cleared unless renderer instance was changed.
550
551         https://bugs.webkit.org/show_bug.cgi?id=52807
552
553         * inspector/InspectorController.cpp:
554         (WebCore::InspectorController::restoreProfiler):
555         * inspector/InspectorProfilerAgent.cpp:
556         (WebCore::InspectorProfilerAgent::resetState):
557         (WebCore::InspectorProfilerAgent::resetFrontendProfiles):
558         * inspector/InspectorProfilerAgent.h:
559
560 2011-01-20  Alexander Pavlov  <apavlov@chromium.org>
561
562         Unreviewed, add new JS file refs missing from r76116.
563
564         * WebCore.gypi:
565         * WebCore.vcproj/WebCore.vcproj:
566         * inspector/front-end/WebKit.qrc:
567
568 2011-01-20  Alexander Pavlov  <apavlov@chromium.org>
569
570         Reviewed by Pavel Feldman.
571
572         Web Inspector: Crash when adding a rule for an ImageDocument
573         https://bugs.webkit.org/show_bug.cgi?id=52811
574
575         * inspector/InspectorCSSAgent.cpp:
576         (WebCore::InspectorCSSAgent::addRule2):
577         (WebCore::InspectorCSSAgent::viaInspectorStyleSheet):
578
579 2011-01-20  Ilya Tikhonovsky  <loislo@chromium.org>
580
581         Reviewed by Pavel Feldman.
582
583         Web Inspector: cleanup InspectorController's friends list.
584         We have a plan to extract InspectorAgent from InspectorController.
585         InspectorAgent will be accessible only from InspectorController.
586         As result we can simply made some methods public and remove long
587         friends list.
588
589         https://bugs.webkit.org/show_bug.cgi?id=52806
590
591         * inspector/InjectedScriptHost.cpp:
592         (WebCore::InjectedScriptHost::databaseForId):
593         (WebCore::InjectedScriptHost::selectDatabase):
594         (WebCore::InjectedScriptHost::selectDOMStorage):
595         (WebCore::InjectedScriptHost::inspectorDOMAgent):
596         (WebCore::InjectedScriptHost::frontend):
597         * inspector/InspectorBrowserDebuggerAgent.cpp:
598         (WebCore::InspectorBrowserDebuggerAgent::setDOMBreakpoint):
599         (WebCore::InspectorBrowserDebuggerAgent::removeDOMBreakpoint):
600         (WebCore::InspectorBrowserDebuggerAgent::willInsertDOMNode):
601         (WebCore::InspectorBrowserDebuggerAgent::willRemoveDOMNode):
602         (WebCore::InspectorBrowserDebuggerAgent::willModifyDOMAttr):
603         (WebCore::InspectorBrowserDebuggerAgent::descriptionForDOMEvent):
604         (WebCore::InspectorBrowserDebuggerAgent::pauseOnNativeEventIfNeeded):
605         (WebCore::InspectorBrowserDebuggerAgent::willSendXMLHttpRequest):
606         * inspector/InspectorController.h:
607         (WebCore::InspectorController::frontend):
608         * inspector/InspectorInstrumentation.cpp:
609         (WebCore::InspectorInstrumentation::willInsertDOMNodeImpl):
610         (WebCore::InspectorInstrumentation::didInsertDOMNodeImpl):
611         (WebCore::InspectorInstrumentation::willRemoveDOMNodeImpl):
612         (WebCore::InspectorInstrumentation::didRemoveDOMNodeImpl):
613         (WebCore::InspectorInstrumentation::willModifyDOMAttrImpl):
614         (WebCore::InspectorInstrumentation::didModifyDOMAttrImpl):
615         (WebCore::InspectorInstrumentation::characterDataModifiedImpl):
616         (WebCore::InspectorInstrumentation::willSendXMLHttpRequestImpl):
617         (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
618         (WebCore::InspectorInstrumentation::didFailLoadingImpl):
619         (WebCore::InspectorInstrumentation::resourceRetrievedByXMLHttpRequestImpl):
620         (WebCore::InspectorInstrumentation::addStartProfilingMessageToConsoleImpl):
621         (WebCore::InspectorInstrumentation::pauseOnNativeEventIfNeeded):
622         (WebCore::InspectorInstrumentation::cancelPauseOnNativeEvent):
623         (WebCore::InspectorInstrumentation::retrieveTimelineAgent):
624         (WebCore::InspectorInstrumentation::retrieveResourceAgent):
625
626 2011-01-19  Pavel Podivilov  <podivilov@chromium.org>
627
628         Reviewed by Yury Semikhatsky.
629
630         Web Inspector: implement JavaScriptBreakpointsSidebarPane based on events from debugger model.
631         https://bugs.webkit.org/show_bug.cgi?id=52723
632
633         Extract all breakpoints-related presentation code from debugger model to JavaScriptBreakpointSidebarPane.
634
635         * inspector/front-end/Breakpoint.js:
636         (WebInspector.Breakpoint):
637         (WebInspector.Breakpoint.prototype.get data):
638         (WebInspector.Breakpoint.prototype.remove):
639         * inspector/front-end/BreakpointsSidebarPane.js:
640         (WebInspector.JavaScriptBreakpointsSidebarPane):
641         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointAdded):
642         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointRemoved):
643         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointEnableChanged):
644         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointItemCheckboxClicked):
645         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._contextMenuEventFired):
646         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._debuggerPaused):
647         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._debuggerResumed):
648         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._addListElement):
649         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._removeListElement):
650         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._projectChanged):
651         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._compare):
652         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._compareBreakpoints):
653         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._setupBreakpointElement.didGetSourceLine):
654         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._setupBreakpointElement):
655         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointIdForDebuggerPausedEvent):
656         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._setBreakpointEnabled):
657         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._removeBreakpoint):
658         (WebInspector.NativeBreakpointsSidebarPane):
659         (WebInspector.XHRBreakpointsSidebarPane.prototype.addBreakpointItem):
660         * inspector/front-end/DebuggerModel.js:
661         (WebInspector.DebuggerModel.prototype.removeBreakpoint):
662         (WebInspector.DebuggerModel.prototype.breakpointForId):
663         (WebInspector.DebuggerModel.prototype._pausedScript):
664         (WebInspector.DebuggerModel.prototype._resumedScript):
665         * inspector/front-end/ScriptsPanel.js:
666         (WebInspector.ScriptsPanel):
667         * inspector/front-end/inspector.js:
668
669 2011-01-20  Dirk Schulze  <krit@webkit.org>
670
671         Reviewed by Andreas Kling.
672
673         SVG Pattern doesn't take the viewBox of a referenced Pattern
674         https://bugs.webkit.org/show_bug.cgi?id=52804
675         
676         SVGPattern element didn't use the viewBox of another SVGPattern element, referenced
677         by xlink:href. Modified PatternAttributes, to take the value of the viewBox of the
678         SVGPattern element as well, if the attribute was set.
679         This gets checked by a W3C SVG test case.        
680
681         Test: svg/W3C-SVG-1.1-SE/pservers-pattern-04-f.svg
682
683         * rendering/svg/RenderSVGResourcePattern.cpp:
684         (WebCore::RenderSVGResourcePattern::buildTileImageTransform):
685         * svg/PatternAttributes.h:
686         (WebCore::PatternAttributes::PatternAttributes):
687         (WebCore::PatternAttributes::viewBox):
688         (WebCore::PatternAttributes::setViewBox):
689         (WebCore::PatternAttributes::hasViewBox):
690         * svg/SVGPatternElement.cpp:
691         (WebCore::SVGPatternElement::collectPatternAttributes):
692
693 2011-01-19  Stephen White  <senorblanco@chromium.org>
694
695         [Re-land of r76159 with a compile fix for the Chromium linux shlib
696         build.]
697
698         Reviewed by James Robinson.
699
700         Implement accelerated path drawing and clipping for the Canvas2D GPU
701         path.
702         https://bugs.webkit.org/show_bug.cgi?id=52627
703         
704         This is done with a simple curve interpolator and the GLU tesselator,
705         which is good enough for a 3-5X speedup on
706         http://ie.microsoft.com/testdrive/Performance/Galactic/Default.html.
707
708         Covered by canvas/philip/2d.path.clip.basic.html, and many, many more.
709         All tests canvas/philip and fast/canvas paths pass with no
710         regressions, although two have minor pixel differences which require
711         rebaselining.
712
713         * WebCore.gyp/WebCore.gyp:
714         Add internal_glu include path to chromium build.
715         * WebCore.gypi:
716         Add internal_glu files to chromium build.
717         * html/canvas/CanvasRenderingContext2D.cpp:
718         (WebCore::CanvasRenderingContext2D::reset):
719         (WebCore::CanvasRenderingContext2D::platformLayer):
720         Make CanvasRenderingContext2D more robust against failure to create
721         a DrawingBuffer.
722         * platform/graphics/chromium/DrawingBufferChromium.cpp:
723         (WebCore::DrawingBuffer::DrawingBuffer):
724         As in DrawingBufferMac.cpp, call reset() from the constructor.
725         Also initialize size to (-1, -1), so reset() doesn't early-out.
726         Add initializers for depthBuffer and stencilBuffer, and remove
727         multisampleDepthStencilBuffer.
728         * platform/graphics/chromium/GLES2Canvas.cpp:
729         Remove some unused #includes.
730         (WebCore::GLES2Canvas::State::State):
731         Add clipping state, and implement save/restore via the copy constructor.
732         (WebCore::operator*):
733         (WebCore::Quadratic::Quadratic):
734         (WebCore::Quadratic::fromBezier):
735         (WebCore::Quadratic::evaluate):
736         Quadratic Bezier curve class.
737         (WebCore::Cubic::Cubic):
738         (WebCore::Cubic::fromBezier):
739         (WebCore::Cubic::evaluate):
740         Cubic Bezier curve class.
741         (WebCore::GLES2Canvas::clearRect):
742         Add clipping support to clearRect().
743         (WebCore::GLES2Canvas::fillPath):
744         Implement fillPath().
745         (WebCore::GLES2Canvas::fillRect):
746         Add clipping support to fillRect().
747         (WebCore::GLES2Canvas::clipPath):
748         Implement clipPath().
749         (WebCore::GLES2Canvas::clipOut):
750         Stub out clipOut() (not called by Canvas 2D).
751         (WebCore::GLES2Canvas::restore):
752         When restoring, draw any remaining clipping paths to the stencil buffer.
753         (WebCore::GLES2Canvas::drawTexturedRect):
754         Add clipping support.
755         (WebCore::interpolateQuadratic):
756         (WebCore::interpolateCubic):
757         Simple curve interpolation, using the Cubic and Quadratic classes.
758         (WebCore::PolygonData::PolygonData):
759         A struct to hold the tesselation data for callbacks.
760         (WebCore::beginData):
761         (WebCore::edgeFlagData):
762         (WebCore::vertexData):
763         (WebCore::endData):
764         (WebCore::combineData):
765         internal_glu tesselation callbacks.
766         (WebCore::GLES2Canvas::createVertexBufferFromPath):
767         Build an interpolated, tesselated vertex buffer and element array buffer from a given path, suitable for filling.
768         (WebCore::GLES2Canvas::beginStencilDraw):
769         Enable stencilling, and disable draws to the color buffer.
770         (WebCore::GLES2Canvas::applyClipping):
771         If clipping is enabled, set the appropriate GL state.
772         * platform/graphics/chromium/GLES2Canvas.h:
773         Document the flavours of drawTexturedRect() a bit, so I don't get confused.
774         * platform/graphics/gpu/DrawingBuffer.cpp:
775         (WebCore::DrawingBuffer::clear):
776         (WebCore::DrawingBuffer::createSecondaryBuffers):
777         (WebCore::DrawingBuffer::resizeDepthStencil):
778         (WebCore::DrawingBuffer::reset):
779         * platform/graphics/gpu/DrawingBuffer.h:
780         Unify m_multisampleDepthStencilBuffer with m_depthStencilBuffer. 
781         Implement separate depth and stencil buffers for when
782         OES_packed_depth_stencil is not available.  Refactor creation of
783         multisampled and non-multisampled depth and stencil buffers into
784         resizeDepthStencil().
785         * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
786         (WebCore::SharedGraphicsContext3D::create):
787         Turn on stencil, turn off depth, turn off antialiasing (for now).
788         (WebCore::SharedGraphicsContext3D::enableStencil):
789         * platform/graphics/gpu/SharedGraphicsContext3D.h:
790         Implement stencil enable/disable.
791         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
792         (WebCore::DrawingBuffer::DrawingBuffer):
793         Remove m_multisampleDepthStencilBuffer.  Set the size to (-1, -1)
794         on creation, so reset() doesn't early-out.  Initialize m_depthBuffer
795         and m_stencilBuffer.
796         * platform/graphics/skia/GraphicsContextSkia.cpp:
797         (WebCore::GraphicsContext::canvasClip):
798         (WebCore::GraphicsContext::clipOut):
799         (WebCore::GraphicsContext::clipPath):
800         (WebCore::GraphicsContext::fillPath):
801         Put in GPU hooks for path clipping, and path drawing.
802         * platform/graphics/skia/PlatformContextSkia.cpp:
803         (WebCore::PlatformContextSkia::canAccelerate):
804         Don't check for clipping paths in canAccelerate() (since we can
805         now accelerate them).
806         (WebCore::PlatformContextSkia::uploadSoftwareToHardware):
807         Don't do clipping when uploading software draws to hardware.
808         * thirdparty/glu/README.webkit:
809         * thirdparty/glu/gluos.h:
810         #undef MIN and MAX, to fix warnings-as-errors in Chrome/Mac build.
811         * thirdparty/glu/libtess/geom.c:
812         * thirdparty/glu/libtess/priorityq.c:
813         * thirdparty/glu/libtess/render.c:
814         Use do{}while(0) instead of if(1)else construct in macro.
815         * thirdparty/glu/libtess/sweep.c:
816         (IsWindingInside):
817         (DoneEdgeDict):
818         Fix some warnings treated as errors for the Linux Release build.
819
820
821 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
822
823         Web Inspector: move releaseObjectGroup to the new Runtime agent.
824         https://bugs.webkit.org/show_bug.cgi?id=52803
825         (accedentally landed as r76231)
826
827         * inspector/InspectorContorller.h:
828         * inspector/InspectorContorller.cpp:
829         * inspector/InspectorRuntimeAgent.h:
830         * inspector/InspectorRuntimeAgent.cpp:
831
832 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
833
834         Not reviewed: build fix.
835
836         * inspector/InspectorState.h:
837         (WebCore::InspectorState::setBoolean):
838         (WebCore::InspectorState::setString):
839         (WebCore::InspectorState::setLong):
840
841 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
842
843         Reviewed by Yury Semikhatsky.
844
845         Web Inspector: further simplify InspectorState.
846         https://bugs.webkit.org/show_bug.cgi?id=52731
847
848         This change moves XHR logging flag into console agent,
849         removes InspectorState pushing to the front-end.
850
851         * inspector/Inspector.idl:
852         * inspector/InspectorConsoleAgent.cpp:
853         (WebCore::InspectorConsoleAgent::InspectorConsoleAgent):
854         (WebCore::InspectorConsoleAgent::resourceRetrievedByXMLHttpRequest):
855         (WebCore::InspectorConsoleAgent::setMonitoringXHREnabled):
856         (WebCore::InspectorConsoleAgent::setConsoleMessagesEnabled):
857         (WebCore::InspectorConsoleAgent::addConsoleMessage):
858         * inspector/InspectorConsoleAgent.h:
859         * inspector/InspectorController.cpp:
860         (WebCore::InspectorController::InspectorController):
861         * inspector/InspectorController.h:
862         (WebCore::InspectorController::state):
863         (WebCore::InspectorController::settings):
864         * inspector/InspectorState.cpp:
865         (WebCore::InspectorState::InspectorState):
866         (WebCore::InspectorState::registerBoolean):
867         (WebCore::InspectorState::registerString):
868         (WebCore::InspectorState::registerLong):
869         (WebCore::InspectorState::registerObject):
870         (WebCore::InspectorState::Property::create):
871         * inspector/InspectorState.h:
872         * inspector/front-end/ConsoleView.js:
873         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.consoleMessagesCleared):
874         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.monitoringXHRStateChanged):
875         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher):
876         (WebInspector.ConsoleView.prototype._handleContextMenuEvent):
877         * inspector/front-end/inspector.js:
878
879 2011-01-20  Csaba Osztrogonác  <ossy@webkit.org>
880
881         Unreviewed buildfix.
882
883         [Qt][V8] Remove unnecessary files after r76224.
884
885         * WebCore.pro:
886
887 2011-01-20  Ilya Tikhonovsky  <loislo@chromium.org>
888
889         Reviewed by Yury Semikhatsky.
890
891         Web Inspector: prepare for extracting InspectorAgent from InspectorController.
892         https://bugs.webkit.org/show_bug.cgi?id=52797
893
894         * inspector/CodeGeneratorInspector.pm:
895         * inspector/InspectorController.h:
896         (WebCore::InspectorController::inspectorAgent):
897         (WebCore::InspectorController::cssAgent):
898         (WebCore::InspectorController::injectedScriptAgent):
899         (WebCore::InspectorController::resourceAgent):
900         (WebCore::InspectorController::runtimeAgent):
901         (WebCore::InspectorController::timelineAgent):
902         (WebCore::InspectorController::databaseAgent):
903         (WebCore::InspectorController::domStorageAgent):
904         (WebCore::InspectorController::fileSystemAgent):
905         (WebCore::InspectorController::browserDebuggerAgent):
906         (WebCore::InspectorController::debuggerAgent):
907         (WebCore::InspectorController::profilerAgent):
908         (WebCore::InspectorController::applicationCacheAgent):
909
910 2011-01-20  Sheriff Bot  <webkit.review.bot@gmail.com>
911
912         Unreviewed, rolling out r76215.
913         http://trac.webkit.org/changeset/76215
914         https://bugs.webkit.org/show_bug.cgi?id=52799
915
916         Caused regressions in Chromium; morrita is going to look at it
917         tomrorow (Requested by jorlow on #webkit).
918
919         * dom/TextEvent.h:
920         * dom/TextEventInputType.h:
921         * editing/CompositeEditCommand.cpp:
922         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt):
923         * editing/CompositeEditCommand.h:
924         * editing/Editor.cpp:
925         (WebCore::Editor::insertTextWithoutSendingTextEvent):
926         (WebCore::Editor::confirmComposition):
927         (WebCore::Editor::setComposition):
928         * editing/Editor.h:
929         * editing/InsertTextCommand.cpp:
930         (WebCore::InsertTextCommand::input):
931         * editing/InsertTextCommand.h:
932         * editing/TypingCommand.cpp:
933         (WebCore::TypingCommand::TypingCommand):
934         (WebCore::TypingCommand::insertText):
935         (WebCore::TypingCommand::insertTextRunWithoutNewlines):
936         * editing/TypingCommand.h:
937         (WebCore::TypingCommand::create):
938
939 2010-12-14  Yury Semikhatsky  <yurys@chromium.org>
940
941         Reviewed by Adam Barth.
942
943         [V8] Get rid of delayed exception reporting in V8ConsoleMessage.cpp
944         https://bugs.webkit.org/show_bug.cgi?id=51044
945
946         * WebCore.gypi:
947         * bindings/v8/V8ConsoleMessage.cpp: Removed.
948         * bindings/v8/V8ConsoleMessage.h: Removed.
949         * bindings/v8/V8DOMWindowShell.cpp:
950         (WebCore::v8UncaughtExceptionHandler):
951         (WebCore::reportUnsafeJavaScriptAccess):
952         (WebCore::V8DOMWindowShell::initContextIfNeeded):
953         * bindings/v8/V8Proxy.cpp:
954         (WebCore::addMessageToConsole):
955         (WebCore::logInfo):
956         (WebCore::V8Proxy::reportUnsafeAccessTo):
957         (WebCore::V8Proxy::runScript):
958         (WebCore::V8Proxy::callFunction):
959         (WebCore::V8Proxy::newInstance):
960         * bindings/v8/V8Proxy.h:
961         * bindings/v8/WorkerContextExecutionProxy.cpp:
962         * bindings/v8/specialization/V8BindingState.cpp:
963         (WebCore::::immediatelyReportUnsafeAccessTo):
964
965 2011-01-19  MORITA Hajime  <morrita@google.com>
966
967         Reviewed by Eric Seidel.
968
969         ShadowElement::m_shadowParent should be removed
970         https://bugs.webkit.org/show_bug.cgi?id=52558
971
972         No new tests. No behavioral change.
973
974         * rendering/ShadowElement.h:
975         (WebCore::ShadowElement::ShadowElement):
976
977 2011-01-20  Hans Wennborg  <hans@chromium.org>
978
979         Reviewed by Jeremy Orlow.
980
981         IndexedDB: IDBObjectStore.get should fire onsuccess rather than onerror
982         https://bugs.webkit.org/show_bug.cgi?id=52725
983
984         Let IDBObjectStore.get() fire the onsuccess handler with the value
985         'undefined' for when an object does not exist in the store.
986
987         Update SerializedScriptValue to provide such an undefined value.
988
989         * bindings/v8/SerializedScriptValue.cpp:
990         (WebCore::SerializedScriptValue::nullValue):
991         (WebCore::SerializedScriptValue::undefinedValue):
992         * bindings/v8/SerializedScriptValue.h:
993         * storage/IDBObjectStoreBackendImpl.cpp:
994         (WebCore::IDBObjectStoreBackendImpl::getInternal):
995
996 2010-12-27  Yury Semikhatsky  <yurys@chromium.org>
997
998         Reviewed by Pavel Feldman.
999
1000         WebCore doesn't fire window.onerror event when uncaught JavaScript exceptions are thrown
1001         https://bugs.webkit.org/show_bug.cgi?id=8519
1002
1003         Uncaught exceptions are propagated to window.onerror hander if one is present.
1004         The handler is expected to be a function accepting three arguments: error message,
1005         resource url and line number where the exception occured.
1006
1007         It was decided to dispatch ErrorEvent to all listeners/handlers no matter if they
1008         were created in the same isolated world where the exception occured or not.
1009
1010         Tests: fast/events/window-onerror1.html
1011                fast/events/window-onerror10.html
1012                fast/events/window-onerror11.html
1013                fast/events/window-onerror12.html
1014                fast/events/window-onerror2.html
1015                fast/events/window-onerror3.html
1016                fast/events/window-onerror4.html
1017                fast/events/window-onerror5.html
1018                fast/events/window-onerror6.html
1019                fast/events/window-onerror7.html
1020                fast/events/window-onerror8.html
1021                fast/events/window-onerror9.html
1022                http/tests/security/window-onerror-exception-in-iframe.html
1023                userscripts/window-onerror-for-isolated-world-1.html
1024                userscripts/window-onerror-for-isolated-world-2.html
1025
1026         * Android.jscbindings.mk:
1027         * CMakeLists.txt:
1028         * GNUmakefile.am:
1029         * WebCore.gypi:
1030         * WebCore.order:
1031         * WebCore.pro:
1032         * WebCore.vcproj/WebCore.vcproj:
1033         * WebCore.xcodeproj/project.pbxproj:
1034         * bindings/js/JSBindingsAllInOne.cpp:
1035         * bindings/js/JSDOMBinding.cpp:
1036         (WebCore::reportException):
1037         * bindings/js/JSErrorHandler.cpp: Renamed from WebCore/bindings/js/JSWorkerContextErrorHandler.cpp.
1038         (WebCore::JSErrorHandler::JSErrorHandler):
1039         (WebCore::JSErrorHandler::~JSErrorHandler):
1040         (WebCore::JSErrorHandler::handleEvent):
1041         * bindings/js/JSErrorHandler.h: Copied from WebCore/bindings/js/JSWorkerContextErrorHandler.h.
1042         (WebCore::JSErrorHandler::create):
1043         (WebCore::createJSErrorHandler):
1044         * bindings/js/JSEventListener.h:
1045         * bindings/scripts/CodeGeneratorJS.pm:
1046         * bindings/scripts/CodeGeneratorV8.pm:
1047         * bindings/v8/V8ConsoleMessage.cpp:
1048         (WebCore::V8ConsoleMessage::dispatchNow):
1049         (WebCore::V8ConsoleMessage::handler): the method was changed to use generic WebCore exception
1050         reporting mechanism which is also used by JSC bindings.
1051         * bindings/v8/V8ConsoleMessage.h:
1052         * bindings/v8/V8EventListener.h:
1053         * bindings/v8/V8WindowErrorHandler.cpp: Renamed from WebCore/bindings/js/JSWorkerContextErrorHandler.h.
1054         (WebCore::V8WindowErrorHandler::V8WindowErrorHandler):
1055         (WebCore::V8WindowErrorHandler::callListenerFunction):
1056         * bindings/v8/V8WindowErrorHandler.h: Copied from WebCore/dom/ErrorEvent.cpp.
1057         (WebCore::V8WindowErrorHandler::create):
1058         * bindings/v8/WorkerContextExecutionProxy.cpp:
1059         (WebCore::v8MessageHandler):
1060         * bindings/v8/WorkerScriptController.cpp:
1061         (WebCore::WorkerScriptController::evaluate):
1062         * dom/Document.cpp:
1063         (WebCore::Document::errorEventTarget):
1064         (WebCore::Document::logExceptionToConsole):
1065         (WebCore::Document::addMessage):
1066         * dom/Document.h:
1067         * dom/ErrorEvent.cpp:
1068         * dom/ErrorEvent.h:
1069         * dom/Event.cpp:
1070         (WebCore::Event::isErrorEvent):
1071         * dom/Event.h:
1072         * dom/ScriptExecutionContext.cpp:
1073         (WebCore::ScriptExecutionContext::PendingException::PendingException):
1074         (WebCore::ScriptExecutionContext::ScriptExecutionContext):
1075         (WebCore::ScriptExecutionContext::reportException): this method is not virtual anymore to
1076         ensure that error event dispatching algorithm is the same in WorkerContext and in Document.
1077         (WebCore::ScriptExecutionContext::dispatchErrorEvent):
1078         * dom/ScriptExecutionContext.h:
1079         * websockets/WebSocket.cpp:
1080         (WebCore::WebSocket::connect):
1081         * websockets/WebSocketChannel.cpp:
1082         (WebCore::WebSocketChannel::didOpen):
1083         (WebCore::WebSocketChannel::didFail):
1084         (WebCore::WebSocketChannel::appendToBuffer):
1085         * websockets/WebSocketHandshake.cpp:
1086         (WebCore::WebSocketHandshake::readServerHandshake):
1087         (WebCore::WebSocketHandshake::readStatusLine):
1088         (WebCore::WebSocketHandshake::readHTTPHeaders):
1089         (WebCore::WebSocketHandshake::checkResponseHeaders):
1090         * workers/DefaultSharedWorkerRepository.cpp:
1091         (WebCore::postExceptionTask):
1092         (WebCore::postConsoleMessageTask):
1093         * workers/WorkerContext.cpp:
1094         (WebCore::WorkerContext::WorkerContext):
1095         (WebCore::WorkerContext::errorEventTarget):
1096         (WebCore::WorkerContext::logExceptionToConsole):
1097         (WebCore::WorkerContext::addMessage):
1098         * workers/WorkerContext.h:
1099         * workers/WorkerMessagingProxy.cpp:
1100         (WebCore::WorkerExceptionTask::performTask):
1101         (WebCore::postConsoleMessageTask):
1102         * xml/XMLHttpRequest.cpp:
1103         (WebCore::reportUnsafeUsage):
1104
1105 2011-01-19  MORITA Hajime  <morrita@google.com>
1106
1107         Reviewed by Ryosuke Niwa.
1108
1109         Space and tab characters "sent" by an input method give totally different results than typing them directly
1110         https://bugs.webkit.org/show_bug.cgi?id=5241
1111         
1112         * Introduced TextEvent::InputTypeComposition and TypingCommand::TextCompositionType to 
1113           distinguish text input which is originated by composition.
1114         * Generalized rebalanceWhitespaceAt() to rebalanceWhitespaceOnTextSubstring() to rebalancing 
1115           range of string on text node, instead of surrounding part of that.
1116
1117         Test: editing/inserting/insert-composition-whitespace.html
1118
1119         * dom/TextEvent.h:
1120         (WebCore::TextEvent::isComposition):
1121         * dom/TextEventInputType.h: Added TextEventInputComposition as a member of TextEvent::InputType
1122         * editing/CompositeEditCommand.cpp:
1123         (WebCore::containsOnlyWhitespace):
1124         (WebCore::CompositeEditCommand::shouldRebalanceLeadingWhitespaceFor):
1125         (WebCore::CompositeEditCommand::canRebalance):
1126         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt):
1127         (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring): Added: A generalized version of rebalanceWhitespaceAt(), which takes a range inside Text string.
1128         * editing/CompositeEditCommand.h:
1129         * editing/Editor.cpp:
1130         (WebCore::Editor::insertTextForConfirmedComposition): Added.
1131         (WebCore::Editor::insertTextWithoutSendingTextEvent):
1132         (WebCore::Editor::confirmComposition): Now uses insertTextForConfirmedComposition().
1133         (WebCore::Editor::setComposition):
1134         * editing/Editor.h:
1135         * editing/InsertTextCommand.cpp:
1136         (WebCore::InsertTextCommand::input):
1137         * editing/InsertTextCommand.h:
1138         * editing/TypingCommand.cpp:
1139         (WebCore::TypingCommand::TypingCommand):
1140         (WebCore::TypingCommand::insertText):
1141         (WebCore::TypingCommand::insertTextRunWithoutNewlines):
1142         * editing/TypingCommand.h: Added TypingCommand::m_compositionType and TypingCommand::TextCompositionType
1143         (WebCore::TypingCommand::setCompositionType): Added.
1144         (WebCore::TypingCommand::create):
1145
1146 2011-01-19  Dominic Cooney  <dominicc@google.com>
1147
1148         Reviewed by Kent Tamura.
1149
1150         Make <keygen> no longer appear to be a <select> element to script.
1151         https://bugs.webkit.org/show_bug.cgi?id=52557
1152
1153         The intent is to put <keygen> options into shadow DOM. This change
1154         takes the first step by hiding the <select> element from
1155         JavaScript.
1156
1157         Test: fast/dom/HTMLKeygenElement/keygen.html
1158
1159         * CMakeLists.txt: Adds new IDL-derived wrapper.
1160         * DerivedSources.cpp:
1161         * DerivedSources.make:
1162         * GNUmakefile.am:
1163         * WebCore.gypi:
1164         * WebCore.pri:
1165         * WebCore.vcproj/WebCore.vcproj:
1166         * WebCore.xcodeproj/project.pbxproj:
1167         * bindings/gobject/GNUmakefile.am:
1168         * bindings/gobject/WebKitHTMLElementWrapperFactory.cpp:
1169         (WebKit::createKeygenWrapper):
1170         (WebKit::createHTMLElementWrapper):
1171         * bindings/objc/DOM.mm:
1172         (WebCore::createElementClassMap): Keygen no longer DOMHTMLSelectElement
1173         * html/HTMLKeygenElement.h:
1174         (WebCore::HTMLKeygenElement::willValidate): Now public.
1175         * html/HTMLKeygenElement.idl: Added.
1176         * html/HTMLTagNames.in: Keygen's wrapper is HTMLKeygenElement.
1177         * page/DOMWindow.idl: Add HTMLKeygenElement constructor.
1178
1179 2011-01-19  Sheriff Bot  <webkit.review.bot@gmail.com>
1180
1181         Unreviewed, rolling out r76203.
1182         http://trac.webkit.org/changeset/76203
1183         https://bugs.webkit.org/show_bug.cgi?id=52784
1184
1185         Broke Win compile on Chromium bots (Requested by dimich on
1186         #webkit).
1187
1188         * WebCore.gypi:
1189         * bindings/v8/V8DOMWindowShell.cpp:
1190         (WebCore::reportFatalErrorInV8):
1191         * page/PageGroup.cpp:
1192         (WebCore::PageGroup::isLinkVisited):
1193         * platform/android/PlatformBridge.h:
1194         * platform/audio/chromium/AudioBusChromium.cpp:
1195         (WebCore::createBusFromInMemoryAudioFile):
1196         * platform/chromium/ChromiumBridge.h: Added.
1197         * platform/chromium/ChromiumDataObjectLegacy.cpp:
1198         (WebCore::ChromiumDataObjectLegacy::getData):
1199         * platform/chromium/DragDataChromium.cpp:
1200         (WebCore::DragData::asURL):
1201         * platform/chromium/FileSystemChromium.cpp:
1202         (WebCore::deleteFile):
1203         (WebCore::deleteEmptyDirectory):
1204         (WebCore::getFileSize):
1205         (WebCore::getFileModificationTime):
1206         (WebCore::revealFolderInOS):
1207         (WebCore::directoryName):
1208         (WebCore::pathByAppendingComponent):
1209         (WebCore::makeAllDirectories):
1210         (WebCore::fileExists):
1211         (WebCore::openFile):
1212         (WebCore::closeFile):
1213         (WebCore::seekFile):
1214         (WebCore::truncateFile):
1215         (WebCore::readFromFile):
1216         (WebCore::writeToFile):
1217         * platform/chromium/LanguageChromium.cpp:
1218         (WebCore::platformDefaultLanguage):
1219         * platform/chromium/LinkHashChromium.cpp:
1220         (WebCore::visitedLinkHash):
1221         * platform/chromium/MIMETypeRegistryChromium.cpp:
1222         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
1223         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
1224         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
1225         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
1226         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
1227         * platform/chromium/PasteboardChromium.cpp:
1228         (WebCore::Pasteboard::writeSelection):
1229         (WebCore::Pasteboard::writePlainText):
1230         (WebCore::Pasteboard::writeURL):
1231         (WebCore::Pasteboard::writeImage):
1232         (WebCore::Pasteboard::canSmartReplace):
1233         (WebCore::Pasteboard::plainText):
1234         (WebCore::Pasteboard::documentFragment):
1235         * platform/chromium/PlatformBridge.h:
1236         * platform/chromium/PlatformScreenChromium.cpp:
1237         (WebCore::screenDepth):
1238         (WebCore::screenDepthPerComponent):
1239         (WebCore::screenIsMonochrome):
1240         (WebCore::screenRect):
1241         (WebCore::screenAvailableRect):
1242         * platform/chromium/ReadableDataObject.cpp:
1243         (WebCore::ReadableDataObject::getData):
1244         (WebCore::ReadableDataObject::urlTitle):
1245         (WebCore::ReadableDataObject::htmlBaseUrl):
1246         (WebCore::ReadableDataObject::filenames):
1247         (WebCore::ReadableDataObject::ensureTypeCacheInitialized):
1248         * platform/chromium/SSLKeyGeneratorChromium.cpp:
1249         (WebCore::signedPublicKeyAndChallengeString):
1250         * platform/chromium/ScrollbarThemeChromium.cpp:
1251         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
1252         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
1253         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
1254         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
1255         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
1256         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
1257         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
1258         * platform/chromium/ScrollbarThemeChromiumMac.mm:
1259         (WebCore::scrollbarStateToThemeState):
1260         (WebCore::ScrollbarThemeChromiumMac::paint):
1261         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
1262         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
1263         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
1264         (WebCore::ScrollbarThemeChromiumWin::paintButton):
1265         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
1266         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
1267         * platform/chromium/SharedTimerChromium.cpp:
1268         (WebCore::setSharedTimerFiredFunction):
1269         (WebCore::setSharedTimerFireTime):
1270         (WebCore::stopSharedTimer):
1271         * platform/chromium/SuddenTerminationChromium.cpp:
1272         (WebCore::disableSuddenTermination):
1273         (WebCore::enableSuddenTermination):
1274         * platform/chromium/SystemTimeChromium.cpp:
1275         (WebCore::currentTime):
1276         * platform/chromium/WritableDataObject.cpp:
1277         (WebCore::WritableDataObject::setData):
1278         * platform/graphics/chromium/CrossProcessFontLoading.mm:
1279         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
1280         (WebCore::fontContainsCharacter):
1281         (WebCore::FillLogFont):
1282         * platform/graphics/chromium/FontCacheLinux.cpp:
1283         (WebCore::FontCache::getFontDataForCharacters):
1284         * platform/graphics/chromium/FontChromiumWin.cpp:
1285         (WebCore::Font::drawGlyphs):
1286         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
1287         (WebCore::FontPlatformData::scriptFontProperties):
1288         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
1289         (WebCore::FontPlatformData::querySystemForRenderStyle):
1290         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
1291         (WebCore::fillBMPGlyphs):
1292         * platform/graphics/chromium/ImageChromium.cpp:
1293         (WebCore::Image::loadPlatformResource):
1294         * platform/graphics/chromium/ImageChromiumMac.mm:
1295         (WebCore::Image::loadPlatformResource):
1296         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
1297         (WebCore::SimpleFontData::platformInit):
1298         (WebCore::SimpleFontData::determinePitch):
1299         (WebCore::SimpleFontData::platformWidthForGlyph):
1300         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
1301         (WebCore::UniscribeHelperTextRun::tryToPreloadFont):
1302         * platform/graphics/skia/FontCustomPlatformData.cpp:
1303         (WebCore::FontCustomPlatformData::fontPlatformData):
1304         * platform/network/chromium/CookieJarChromium.cpp:
1305         (WebCore::setCookies):
1306         (WebCore::cookies):
1307         (WebCore::cookieRequestHeaderFieldValue):
1308         (WebCore::cookiesEnabled):
1309         (WebCore::getRawCookies):
1310         (WebCore::deleteCookie):
1311         * platform/network/chromium/DNSChromium.cpp:
1312         (WebCore::prefetchDNS):
1313         * platform/qt/PlatformBridge.h:
1314         * platform/sql/chromium/SQLiteFileSystemChromium.cpp:
1315         (WebCore::SQLiteFileSystem::deleteDatabaseFile):
1316         (WebCore::SQLiteFileSystem::getDatabaseFileSize):
1317         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
1318         (chromiumOpen):
1319         (chromiumDelete):
1320         (chromiumAccess):
1321         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
1322         * plugins/chromium/PluginDataChromium.cpp:
1323         (WebCore::PluginCache::plugins):
1324         * rendering/RenderThemeChromiumMac.mm:
1325         (WebCore::RenderThemeChromiumMac::usesTestModeFocusRingColor):
1326         * rendering/RenderThemeChromiumSkia.cpp:
1327         (WebCore::RenderThemeChromiumSkia::caretBlinkInterval):
1328         * rendering/RenderThemeChromiumWin.cpp:
1329         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
1330         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
1331         (WebCore::RenderThemeChromiumWin::platformActiveSelectionForegroundColor):
1332         (WebCore::RenderThemeChromiumWin::systemColor):
1333         (WebCore::RenderThemeChromiumWin::paintButton):
1334         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
1335         (WebCore::menuListButtonWidth):
1336         (WebCore::RenderThemeChromiumWin::paintMenuList):
1337         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
1338         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
1339         (WebCore::RenderThemeChromiumWin::paintProgressBar):
1340         * storage/chromium/IDBFactoryBackendInterface.cpp:
1341         (WebCore::IDBFactoryBackendInterface::create):
1342         (WebCore::IDBFactoryBackendInterface::~IDBFactoryBackendInterface):
1343         * storage/chromium/IDBKeyPathBackendImpl.cpp:
1344         (WebCore::IDBKeyPathBackendImpl::createIDBKeysFromSerializedValuesAndKeyPath):
1345
1346 2011-01-19  Helder Correia  <helder@sencha.com>
1347
1348         Reviewed by Andreas Kling.
1349
1350         [Qt] GraphicsContext::strokePath() paints solid shadows with incorrect alpha
1351         https://bugs.webkit.org/show_bug.cgi?id=52705
1352
1353         This is related to bug 52611. The shadow color alpha must be multiplied
1354         by the context pen alpha. Fixing this results in correct behavior for
1355         Canvas path stroke() and strokeRect() [which relies on stroke()].
1356
1357         Tests: fast/canvas/canvas-strokePath-alpha-shadow.html
1358                fast/canvas/canvas-strokeRect-alpha-shadow.html
1359
1360         * platform/graphics/qt/GraphicsContextQt.cpp:
1361         (WebCore::GraphicsContext::strokePath):
1362
1363 2011-01-19  Darin Fisher  <darin@chromium.org>
1364
1365         Reviewed by Mihai Parparita.
1366
1367         Re-initialize the HistoryItem fully when navigating to a HistoryItem,
1368         or replacing a HistoryItem, results in a different URL.
1369
1370         https://bugs.webkit.org/show_bug.cgi?id=49654
1371
1372         This patch also forces all HistoryItems to record the post-redirect
1373         URL.  Previously, frames would remember the pre-redirect URL.  This is
1374         problematic since other members of the HistoryItem correspond to the
1375         post-redirect URL.
1376
1377         Tests: fast/history/history-replace-updates-current-item.html
1378                http/tests/navigation/redirect-on-back-updates-history-item.html
1379                http/tests/navigation/redirect-on-reload-updates-history-item.html
1380
1381         * history/HistoryItem.cpp:
1382         (WebCore::HistoryItem::HistoryItem):
1383         (WebCore::HistoryItem::reset):
1384         * history/HistoryItem.h:
1385         * loader/HistoryController.cpp:
1386         (WebCore::HistoryController::updateForBackForwardNavigation):
1387         (WebCore::HistoryController::updateForReload):
1388         (WebCore::HistoryController::updateForStandardLoad):
1389         (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
1390         (WebCore::HistoryController::initializeItem):
1391         (WebCore::HistoryController::createItem):
1392         (WebCore::HistoryController::createItemTree):
1393         (WebCore::HistoryController::updateCurrentItem):
1394         * loader/HistoryController.h:
1395
1396 2011-01-19  Adam Klein  <adamk@chromium.org>
1397
1398         Reviewed by Darin Fisher.
1399
1400         [chromium] Rename ChromiumBridge to PlatformBridge
1401         https://bugs.webkit.org/show_bug.cgi?id=52471
1402
1403         No tests added as this is a rename; no change in behavior.
1404
1405         * WebCore.gypi:
1406         * bindings/v8/V8DOMWindowShell.cpp:
1407         (WebCore::reportFatalErrorInV8):
1408         * page/PageGroup.cpp:
1409         (WebCore::PageGroup::isLinkVisited):
1410         * platform/android/PlatformBridge.h:
1411         * platform/audio/chromium/AudioBusChromium.cpp:
1412         (WebCore::createBusFromInMemoryAudioFile):
1413         * platform/chromium/ChromiumBridge.h: Removed.
1414         * platform/chromium/ChromiumDataObjectLegacy.cpp:
1415         (WebCore::ChromiumDataObjectLegacy::getData):
1416         * platform/chromium/DragDataChromium.cpp:
1417         (WebCore::DragData::asURL):
1418         * platform/chromium/FileSystemChromium.cpp:
1419         (WebCore::deleteFile):
1420         (WebCore::deleteEmptyDirectory):
1421         (WebCore::getFileSize):
1422         (WebCore::getFileModificationTime):
1423         (WebCore::revealFolderInOS):
1424         (WebCore::directoryName):
1425         (WebCore::pathByAppendingComponent):
1426         (WebCore::makeAllDirectories):
1427         (WebCore::fileExists):
1428         (WebCore::openFile):
1429         (WebCore::closeFile):
1430         (WebCore::seekFile):
1431         (WebCore::truncateFile):
1432         (WebCore::readFromFile):
1433         (WebCore::writeToFile):
1434         * platform/chromium/LanguageChromium.cpp:
1435         (WebCore::platformDefaultLanguage):
1436         * platform/chromium/LinkHashChromium.cpp:
1437         (WebCore::visitedLinkHash):
1438         * platform/chromium/MIMETypeRegistryChromium.cpp:
1439         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
1440         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
1441         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
1442         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
1443         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
1444         * platform/chromium/PasteboardChromium.cpp:
1445         (WebCore::Pasteboard::writeSelection):
1446         (WebCore::Pasteboard::writePlainText):
1447         (WebCore::Pasteboard::writeURL):
1448         (WebCore::Pasteboard::writeImage):
1449         (WebCore::Pasteboard::canSmartReplace):
1450         (WebCore::Pasteboard::plainText):
1451         (WebCore::Pasteboard::documentFragment):
1452         * platform/chromium/PlatformBridge.h:
1453         * platform/chromium/PlatformScreenChromium.cpp:
1454         (WebCore::screenDepth):
1455         (WebCore::screenDepthPerComponent):
1456         (WebCore::screenIsMonochrome):
1457         (WebCore::screenRect):
1458         (WebCore::screenAvailableRect):
1459         * platform/chromium/ReadableDataObject.cpp:
1460         (WebCore::ReadableDataObject::getData):
1461         (WebCore::ReadableDataObject::urlTitle):
1462         (WebCore::ReadableDataObject::htmlBaseUrl):
1463         (WebCore::ReadableDataObject::filenames):
1464         (WebCore::ReadableDataObject::ensureTypeCacheInitialized):
1465         * platform/chromium/SSLKeyGeneratorChromium.cpp:
1466         (WebCore::signedPublicKeyAndChallengeString):
1467         * platform/chromium/ScrollbarThemeChromium.cpp:
1468         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
1469         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
1470         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
1471         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
1472         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
1473         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
1474         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
1475         * platform/chromium/ScrollbarThemeChromiumMac.mm:
1476         (WebCore::scrollbarStateToThemeState):
1477         (WebCore::ScrollbarThemeChromiumMac::paint):
1478         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
1479         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
1480         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
1481         (WebCore::ScrollbarThemeChromiumWin::paintButton):
1482         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
1483         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
1484         * platform/chromium/SharedTimerChromium.cpp:
1485         (WebCore::setSharedTimerFiredFunction):
1486         (WebCore::setSharedTimerFireTime):
1487         (WebCore::stopSharedTimer):
1488         * platform/chromium/SuddenTerminationChromium.cpp:
1489         (WebCore::disableSuddenTermination):
1490         (WebCore::enableSuddenTermination):
1491         * platform/chromium/SystemTimeChromium.cpp:
1492         (WebCore::currentTime):
1493         * platform/chromium/WritableDataObject.cpp:
1494         (WebCore::WritableDataObject::setData):
1495         * platform/graphics/chromium/CrossProcessFontLoading.mm:
1496         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
1497         (WebCore::fontContainsCharacter):
1498         (WebCore::FillLogFont):
1499         * platform/graphics/chromium/FontCacheLinux.cpp:
1500         (WebCore::FontCache::getFontDataForCharacters):
1501         * platform/graphics/chromium/FontChromiumWin.cpp:
1502         (WebCore::Font::drawGlyphs):
1503         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
1504         (WebCore::FontPlatformData::scriptFontProperties):
1505         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
1506         (WebCore::FontPlatformData::querySystemForRenderStyle):
1507         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
1508         (WebCore::fillBMPGlyphs):
1509         * platform/graphics/chromium/ImageChromium.cpp:
1510         (WebCore::Image::loadPlatformResource):
1511         * platform/graphics/chromium/ImageChromiumMac.mm:
1512         (WebCore::Image::loadPlatformResource):
1513         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
1514         (WebCore::SimpleFontData::platformInit):
1515         (WebCore::SimpleFontData::determinePitch):
1516         (WebCore::SimpleFontData::platformWidthForGlyph):
1517         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
1518         (WebCore::UniscribeHelperTextRun::tryToPreloadFont):
1519         * platform/graphics/skia/FontCustomPlatformData.cpp:
1520         (WebCore::FontCustomPlatformData::fontPlatformData):
1521         * platform/network/chromium/CookieJarChromium.cpp:
1522         (WebCore::setCookies):
1523         (WebCore::cookies):
1524         (WebCore::cookieRequestHeaderFieldValue):
1525         (WebCore::cookiesEnabled):
1526         (WebCore::getRawCookies):
1527         (WebCore::deleteCookie):
1528         * platform/network/chromium/DNSChromium.cpp:
1529         (WebCore::prefetchDNS):
1530         * platform/qt/PlatformBridge.h:
1531         * platform/sql/chromium/SQLiteFileSystemChromium.cpp:
1532         (WebCore::SQLiteFileSystem::deleteDatabaseFile):
1533         (WebCore::SQLiteFileSystem::getDatabaseFileSize):
1534         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
1535         (chromiumOpen):
1536         (chromiumDelete):
1537         (chromiumAccess):
1538         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
1539         * plugins/chromium/PluginDataChromium.cpp:
1540         (WebCore::PluginCache::plugins):
1541         * rendering/RenderThemeChromiumMac.mm:
1542         (WebCore::RenderThemeChromiumMac::usesTestModeFocusRingColor):
1543         * rendering/RenderThemeChromiumSkia.cpp:
1544         (WebCore::RenderThemeChromiumSkia::caretBlinkInterval):
1545         * rendering/RenderThemeChromiumWin.cpp:
1546         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
1547         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
1548         (WebCore::RenderThemeChromiumWin::platformActiveSelectionForegroundColor):
1549         (WebCore::RenderThemeChromiumWin::systemColor):
1550         (WebCore::RenderThemeChromiumWin::paintButton):
1551         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
1552         (WebCore::menuListButtonWidth):
1553         (WebCore::RenderThemeChromiumWin::paintMenuList):
1554         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
1555         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
1556         (WebCore::RenderThemeChromiumWin::paintProgressBar):
1557         * storage/chromium/IDBFactoryBackendInterface.cpp:
1558         (WebCore::IDBFactoryBackendInterface::create):
1559         (WebCore::IDBFactoryBackendInterface::~IDBFactoryBackendInterface):
1560         * storage/chromium/IDBKeyPathBackendImpl.cpp:
1561         (WebCore::IDBKeyPathBackendImpl::createIDBKeysFromSerializedValuesAndKeyPath):
1562
1563 2011-01-19  Sheriff Bot  <webkit.review.bot@gmail.com>
1564
1565         Unreviewed, rolling out r76187.
1566         http://trac.webkit.org/changeset/76187
1567         https://bugs.webkit.org/show_bug.cgi?id=52778
1568
1569         Broke caret-showing tests on SnowLeopard and Chromium
1570         (Requested by dimich on #webkit).
1571
1572         * rendering/RenderText.cpp:
1573         (WebCore::RenderText::localCaretRect):
1574
1575 2011-01-19  Yuzo Fujishima  <yuzo@google.com>
1576
1577         Reviewed by Kent Tamura.
1578
1579         Fix for Bug 52279 - WebCore::RenderBlock::updateFirstLetter crashes for anonymous blocks
1580         https://bugs.webkit.org/show_bug.cgi?id=52279
1581
1582         In constructing text fragments to handle first-letter rule, first add
1583         the text for the non-first letters and then remove the original text,
1584         rather than the other way around. Otherwise, the text can be added to
1585         an anoymous block that is different from the original one. This breaks
1586         the assumption that a first letter render object has a non-null sibling
1587         for the non-first letters and causes a crash.
1588
1589         Test: fast/css/first-letter-anonymous-block-crash.html
1590
1591         * rendering/RenderBlock.cpp:
1592         (WebCore::RenderBlock::updateFirstLetter):
1593
1594 2011-01-19  James Robinson  <jamesr@chromium.org>
1595
1596         Unreviewed, rolling out r76194.
1597         http://trac.webkit.org/changeset/76194
1598         https://bugs.webkit.org/show_bug.cgi?id=51218
1599
1600         Caused mysterious compile failure on the chromium win
1601         build.webkit.org bots
1602
1603         * WebCore.gypi:
1604         * dom/Document.cpp:
1605         (WebCore::Document::Document):
1606         * dom/Document.h:
1607         * dom/RequestAnimationFrameCallback.h: Removed.
1608         * dom/RequestAnimationFrameCallback.idl: Removed.
1609         * loader/EmptyClients.h:
1610         * page/Chrome.cpp:
1611         * page/Chrome.h:
1612         * page/ChromeClient.h:
1613         * page/DOMWindow.cpp:
1614         * page/DOMWindow.h:
1615         * page/DOMWindow.idl:
1616         * page/FrameView.cpp:
1617         * page/FrameView.h:
1618         * platform/HostWindow.h:
1619
1620 2011-01-19  Simon Fraser  <simon.fraser@apple.com>
1621
1622         Reviewed by Sam Weinig.
1623
1624         GraphicsLayers in subframes can get sync'd multiple times
1625         https://bugs.webkit.org/show_bug.cgi?id=52489
1626
1627         Some cleanup that will work towards fixing this bug.
1628         
1629         Tested by existing iframe compositing tests.
1630
1631         * WebCore.exp.in: syncCompositingStateRecursive()
1632         was renamed to syncCompositingStateIncludingSubframes().
1633
1634         * page/FrameView.h:
1635         * page/FrameView.cpp:
1636         (WebCore::FrameView::syncCompositingStateForThisFrame): Some
1637         code cleanup: do all the word we need to do for this frame,
1638         including the needsLayout() check.
1639         (WebCore::FrameView::syncCompositingStateIncludingSubframes):
1640         This is no longer recursive; instead, it iterates over descendant
1641         frames via the frame tree, calling syncCompositingStateForThisFrame()
1642         on each Frame's view.
1643
1644         * rendering/RenderLayerCompositor.h:
1645         (WebCore::RenderLayerCompositor::isFlushingLayers): Getter for the flag.
1646         * rendering/RenderLayerCompositor.cpp: 
1647         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
1648         (WebCore::RenderLayerCompositor::flushPendingLayerChanges): Maintain
1649         a flag to say if we're flushing, which allows us to assert on re-entrant flushes.
1650         (WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers):
1651         Add the ability to get the rootmost compositor that is in the middle
1652         of a flush.
1653
1654 2011-01-19  James Robinson  <jamesr@chromium.org>
1655
1656         Reviewed by Darin Fisher.
1657
1658         Implement mozilla's requestAnimationFrame API
1659         https://bugs.webkit.org/show_bug.cgi?id=51218
1660
1661         This implements mozilla's proposed requestAnimationFrame API.  The idea with this API is that
1662         an author driving an animation from script could use window.requestAnimationFrame(callback)
1663         instead of window.setTimeout(callback, 0) to schedule their update logic and let the browser
1664         decide when to update the animations.  This avoids doing unnecessary work when the page content
1665         is offscreen or is being displayed at a different framerate than what the page author expects.
1666
1667         Mozilla's proposal is here: https://developer.mozilla.org/en/DOM/window.mozRequestAnimationFrame
1668         This implements window.mozRequestAnimationFrame as window.webkitRequestAnimationFrame with the
1669         following changes:
1670         *) Only the callback syntax is supported, there is no before paint event
1671         *) webkitRequestAnimationFrame supports a second parameter Element to let the author indicate
1672             what content they intend to animate.  That way if the page is being displayed but the element
1673             in question is offscreen, we can avoid invoking the callback.
1674         *) No timestamp is provided to the caller and there is no window.animationStartTime property
1675             (see https://bugs.webkit.org/show_bug.cgi?id=51952 for discussion of this property)
1676         *) window.webkitRequestAnimationFrame returns a numerical id that can be used to cancel the callback
1677             using window.cancelWebkitRequestAnimationFrame, to parallel window.setTimeout()/window.clearTime().
1678
1679         The implementation depends on the embedder scheduling the callbacks since the callback invocation
1680         depends on the page's visibility and the embedder's paint scheduling, neither of which are exposed
1681         to WebCore.  The expectation for the embedder is that at some point Chrome::scheduleAnimation() is
1682         called FrameView::serviceScriptedAnimations() should be called for the associated Page's main frame.
1683         Ideally serviceScriptedAnimations() would be called prior to rendering - although in practice the
1684         embedder has to rate limit callbacks and may not be able to tie the callback directly to the
1685         rendering loop.
1686
1687         Tests: fast/animation/request-animation-frame-cancel.html
1688                fast/animation/request-animation-frame-cancel2.html
1689                fast/animation/request-animation-frame-display.html
1690                fast/animation/request-animation-frame-within-callback.html
1691                fast/animation/request-animation-frame.html
1692
1693         * WebCore.gypi:
1694         * dom/Document.cpp:
1695         (WebCore::Document::Document):
1696         (WebCore::Document::webkitRequestAnimationFrame):
1697         (WebCore::Document::webkitCancelRequestAnimationFrame):
1698         (WebCore::Document::serviceScriptedAnimations):
1699         * dom/Document.h:
1700         * dom/RequestAnimationFrameCallback.h: Added.
1701         (WebCore::RequestAnimationFrameCallback::~RequestAnimationFrameCallback):
1702         * dom/RequestAnimationFrameCallback.idl: Added.
1703         * loader/EmptyClients.h:
1704         (WebCore::EmptyChromeClient::scheduleAnimation):
1705         * page/Chrome.cpp:
1706         (WebCore::Chrome::scheduleAnimation):
1707         * page/Chrome.h:
1708         * page/ChromeClient.h:
1709         * page/DOMWindow.cpp:
1710         (WebCore::DOMWindow::webkitRequestAnimationFrame):
1711         (WebCore::DOMWindow::webkitCancelRequestAnimationFrame):
1712         * page/DOMWindow.h:
1713         * page/DOMWindow.idl:
1714         * page/FrameView.cpp:
1715         (WebCore::FrameView::scheduleAnimation):
1716         (WebCore::FrameView::serviceScriptedAnimations):
1717         * page/FrameView.h:
1718         * platform/HostWindow.h:
1719
1720 2011-01-13  Martin Robinson  <mrobinson@igalia.com>
1721
1722         Reviewed by Daniel Bates.
1723
1724         [GTK] Move progress bar painting out of gtk2drawing.c
1725         https://bugs.webkit.org/show_bug.cgi?id=52385
1726
1727         Move progress bar painting to RenderThemeGtk2 and share some animation
1728         logic between the GTK+ 2.x and GTK+ 3.x port.
1729
1730         No new tests. This should not change functionality.
1731
1732         * platform/gtk/RenderThemeGtk.cpp:
1733         (WebCore::RenderThemeGtk::animationRepeatIntervalForProgressBar): Moved from RenderThemeGtk3.
1734         (WebCore::RenderThemeGtk::animationDurationForProgressBar): Ditto.
1735         (WebCore::RenderThemeGtk::calculateProgressRect): Calculate the proper rectangle for the
1736         progress indicator given the rect for the maximum size of the indicator.
1737         * platform/gtk/RenderThemeGtk.h: Added calculateProgressRect declaration and
1738         a new widget member for GTK+ 2.x
1739         * platform/gtk/RenderThemeGtk2.cpp:
1740         (WebCore::RenderThemeGtk::platformInit): Added initialization for the new widget member.
1741         (WebCore::RenderThemeGtk::paintProgressBar): Paint the progress bar manually instead of
1742         calling the old Mozilla code.
1743         (WebCore::RenderThemeGtk::gtkProgressBar): Added.
1744         * platform/gtk/RenderThemeGtk3.cpp:
1745         (WebCore::RenderThemeGtk::paintProgressBar): Call calculateProgressRect now to get
1746         the area of the progress indicator.
1747         * platform/gtk/gtk2drawing.c: Remove unused code.
1748         (moz_gtk_get_widget_border):
1749         (moz_gtk_widget_paint):
1750         * platform/gtk/gtkdrawing.h: Ditto.
1751
1752 2011-01-19  Dmitry Titov  <dimich@chromium.org>
1753
1754         [Chromium] Not reviewed, reverts the following changes:
1755         http://trac.webkit.org/changeset/76164 (build fix)
1756         http://trac.webkit.org/changeset/76159 (main change)
1757
1758         The change broke Chromium Linux-shlib build.
1759
1760         Original issue:
1761         Accelerated canvas2D has bad clipping performance.
1762         https://bugs.webkit.org/show_bug.cgi?id=52627
1763
1764         * WebCore.gyp/WebCore.gyp:
1765         * WebCore.gypi:
1766         * html/canvas/CanvasRenderingContext2D.cpp:
1767         (WebCore::CanvasRenderingContext2D::reset):
1768         (WebCore::CanvasRenderingContext2D::platformLayer):
1769         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1770         (WebCore::DrawingBuffer::DrawingBuffer):
1771         * platform/graphics/chromium/GLES2Canvas.cpp:
1772         (WebCore::GLES2Canvas::State::State):
1773         (WebCore::GLES2Canvas::clearRect):
1774         (WebCore::GLES2Canvas::fillRect):
1775         (WebCore::GLES2Canvas::restore):
1776         (WebCore::GLES2Canvas::drawTexturedRect):
1777         * platform/graphics/chromium/GLES2Canvas.h:
1778         * platform/graphics/gpu/DrawingBuffer.cpp:
1779         (WebCore::DrawingBuffer::clear):
1780         (WebCore::DrawingBuffer::createSecondaryBuffers):
1781         (WebCore::DrawingBuffer::reset):
1782         * platform/graphics/gpu/DrawingBuffer.h:
1783         * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
1784         (WebCore::SharedGraphicsContext3D::create):
1785         * platform/graphics/gpu/SharedGraphicsContext3D.h:
1786         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
1787         (WebCore::DrawingBuffer::DrawingBuffer):
1788         * platform/graphics/skia/GraphicsContextSkia.cpp:
1789         (WebCore::GraphicsContext::canvasClip):
1790         (WebCore::GraphicsContext::clipOut):
1791         (WebCore::GraphicsContext::clipPath):
1792         (WebCore::GraphicsContext::fillPath):
1793         * platform/graphics/skia/PlatformContextSkia.cpp:
1794         (WebCore::PlatformContextSkia::canAccelerate):
1795         (WebCore::PlatformContextSkia::uploadSoftwareToHardware):
1796         * thirdparty/glu/README.webkit:
1797         * thirdparty/glu/gluos.h:
1798         * thirdparty/glu/libtess/geom.c:
1799         * thirdparty/glu/libtess/priorityq.c:
1800         * thirdparty/glu/libtess/render.c:
1801         * thirdparty/glu/libtess/sweep.c:
1802         (IsWindingInside):
1803         (DoneEdgeDict):
1804
1805 2011-01-19  Levi Weintraub  <leviw@google.com>
1806
1807         Reviewed by Darin Adler.
1808
1809         Re-committing this with the proper expected results.
1810
1811         Changing RenderText::localCaretRect to clip to its containing block's logicalLeft and
1812         logicalRightLayoutOverflow instead of simply using logicalLeft and logicalRight, as this
1813         resulted in the caret being placed incorrectly in overflowing editable IFrame content.
1814
1815         Long lines in non-white-space-pre editable documents show cursor in wrong place
1816         https://bugs.webkit.org/show_bug.cgi?id=48132
1817
1818         Test: editing/selection/caret-painting-in-overflowing-autowrap-content.html
1819
1820         * rendering/RenderText.cpp:
1821         (WebCore::RenderText::localCaretRect):
1822
1823 2011-01-18 MORITA Hajime <morrita@google.com>
1824
1825         Reviewed by David Levin.
1826
1827         ElementRareData::m_shadowRoot should not be RefPtr.
1828         https://bugs.webkit.org/show_bug.cgi?id=51914
1829
1830         Makes ElementRareData::m_shadowRoot a raw pointer because
1831         ElementRareData::m_shadowRoot should be like a
1832         ContaineNode::m_firstChild, which is also a raw pointer.
1833         pointer. Which also means that both the shadow root and the shadow
1834         host reference each other as a parent-and-child relationship, via
1835         a raw pointer.
1836         
1837         Note that it is safe not to manipulate the ref-count of
1838         m_shadowRoot because Node::m_parent of the shadow root points its
1839         shadow host, and the object isn't deleted even if the refcount is
1840         zero, as long as the node has non-null m_parent. (See TreeShared.)
1841         
1842         The shadow root node is finally destroyed inside
1843         removeShadowRoot(), where we store the root node into a local
1844         RefPtr, then make the node's m_parent null, which results the
1845         destroy the node, at the end of the function, by RefPtr::~RefPtr.
1846         
1847         No new tests. No behavioral change.
1848
1849         * dom/Element.cpp:
1850         (WebCore::Element::~Element):
1851         (WebCore::Element::shadowRoot):
1852         (WebCore::Element::setShadowRoot):
1853         (WebCore::Element::removeShadowRoot):
1854         * dom/ElementRareData.h:
1855         (WebCore::ElementRareData::ElementRareData):
1856         (WebCore::ElementRareData::~ElementRareData):
1857
1858 2011-01-12  Martin Robinson  <mrobinson@igalia.com>
1859
1860         Reviewed by Gustavo Noronha Silva.
1861
1862         [GTK] Move text field painting out of gtk2drawing.c
1863         https://bugs.webkit.org/show_bug.cgi?id=52327
1864
1865         No new tests. This should not change behavior.
1866
1867         * platform/gtk/RenderThemeGtk2.cpp:
1868         (WebCore::RenderThemeGtk::paintButton): Use the setWidgetHasFocus helper.
1869         (WebCore::RenderThemeGtk::paintTextField): Do this manually now instead
1870         of calling into the Mozilla code.
1871         * platform/gtk/WidgetRenderingContext.cpp: Added a couple more wrappers
1872         for GTK+ theme functions.
1873         (WebCore::WidgetRenderingContext::gtkPaintFlatBox):
1874         (WebCore::WidgetRenderingContext::gtkPaintShadow):
1875         * platform/gtk/WidgetRenderingContext.h: Added new method declarations.
1876         * platform/gtk/gtk2drawing.c: Remove unused code.
1877         (moz_gtk_get_widget_border):
1878         (moz_gtk_widget_paint):
1879         * platform/gtk/gtkdrawing.h:
1880
1881 2011-01-19  Antti Koivisto  <antti@apple.com>
1882
1883         Reviewed by Oliver Hunt.
1884
1885         Cache function offsets to speed up javascript parsing
1886         https://bugs.webkit.org/show_bug.cgi?id=52622
1887         
1888         Use cache to save function offsets and some other info.
1889         This avoids quite a bit of work when reparsing the source.
1890
1891         * bindings/js/CachedScriptSourceProvider.h:
1892         (WebCore::CachedScriptSourceProvider::cache):
1893         (WebCore::CachedScriptSourceProvider::cacheSizeChanged):
1894         (WebCore::CachedScriptSourceProvider::CachedScriptSourceProvider):
1895         * bindings/js/ScriptSourceProvider.h:
1896         (WebCore::ScriptSourceProvider::ScriptSourceProvider):
1897         * loader/cache/CachedScript.cpp:
1898         (WebCore::CachedScript::destroyDecodedData):
1899         (WebCore::CachedScript::sourceProviderCache):
1900         (WebCore::CachedScript::sourceProviderCacheSizeChanged):
1901         * loader/cache/CachedScript.h:
1902
1903 2011-01-11  Martin Robinson  <mrobinson@igalia.com>
1904
1905         Reviewed by Gustavo Noronha Silva.
1906
1907         [GTK] Move toggle button rendering out of gtk2drawing.c
1908         https://bugs.webkit.org/show_bug.cgi?id=52258
1909
1910         * platform/gtk/RenderThemeGtk.h:
1911         * platform/gtk/RenderThemeGtk2.cpp:
1912         (WebCore::RenderThemeGtk::platformInit): Initialize new button members.
1913         (WebCore::adjustRectForFocus): Added this function which inflates a rect based
1914         on a widget's exterior focus.
1915         (WebCore::RenderThemeGtk::adjustRepaintRect): Account for exterior focus.
1916         (WebCore::setToggleSize): Only listen to indicator-size to properly size
1917         checkboxes and radio buttons.
1918         (WebCore::RenderThemeGtk::setCheckboxSize): Call new setToggleSize properly.
1919         (WebCore::paintToggle): Added.
1920         (WebCore::RenderThemeGtk::paintCheckbox): Call paintToggle.
1921         (WebCore::RenderThemeGtk::setRadioSize): Call new setToggleSize properly.
1922         (WebCore::RenderThemeGtk::paintRadio): Call paintToggle.
1923         (WebCore::RenderThemeGtk::gtkRadioButton): Added.
1924         (WebCore::RenderThemeGtk::gtkCheckButton): Added.
1925         * platform/gtk/WidgetRenderingContext.cpp:
1926         (WebCore::WidgetRenderingContext::WidgetRenderingContext): Use a static extra space
1927         variable. This is good enough for all themes that I've tested and prevents having to
1928         pass information from RenderThemeGtk about every single type of widget.
1929         (WebCore::WidgetRenderingContext::gtkPaintFocus): Use the paintRect
1930         to draw instead of m_paintRect. This is important when we're painting
1931         something that isn't the size of the total rect.
1932         (WebCore::WidgetRenderingContext::gtkPaintCheck): Added.
1933         (WebCore::WidgetRenderingContext::gtkPaintOption): Added.
1934         * platform/gtk/WidgetRenderingContext.h: Updated to reflect new methods.
1935         * platform/gtk/gtkdrawing.h: Remove newly unused code.
1936         * platform/gtk/gtk2drawing.c: Ditto.
1937
1938 2011-01-19  Tony Gentilcore  <tonyg@chromium.org>
1939
1940         Unreviewed build fix.
1941
1942         Build fix for r76170
1943         https://bugs.webkit.org/show_bug.cgi?id=52758
1944
1945         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
1946
1947 2011-01-19  David D. Kilzer  <ddkilzer@apple.com>
1948
1949         <http://webkit.org/b/52687> Clean up FrameLoader methods for PLUGIN_PROXY_FOR_VIDEO
1950
1951         Reviewed by Eric Carlson.
1952
1953         * loader/FrameLoader.cpp: Declare the methods here.
1954         (WebCore::FrameLoader::hideMediaPlayerProxyPlugin):
1955         (WebCore::FrameLoader::showMediaPlayerProxyPlugin):
1956         * loader/FrameLoader.cpp: Moved methods to here...
1957         (WebCore::FrameLoader::hideMediaPlayerProxyPlugin):
1958         (WebCore::FrameLoader::showMediaPlayerProxyPlugin):
1959         * loader/SubframeLoader.cpp: ...from here.
1960         (WebCore::FrameLoader::hideMediaPlayerProxyPlugin):
1961         (WebCore::FrameLoader::showMediaPlayerProxyPlugin):
1962
1963 2011-01-19  Tony Gentilcore  <tonyg@chromium.org>
1964
1965         Reviewed by Mihai Parparita.
1966
1967         Perform some forward declaration
1968         https://bugs.webkit.org/show_bug.cgi?id=52522
1969
1970         No new tests because no new functionality.
1971
1972         * accessibility/AccessibilityObject.h:
1973         * css/WebKitCSSMatrix.cpp:
1974         * html/HTMLAreaElement.cpp:
1975         * html/canvas/CanvasRenderingContext2D.cpp:
1976         * inspector/InspectorController.cpp:
1977         * platform/graphics/FloatPoint.cpp:
1978         * platform/graphics/Font.cpp:
1979         * platform/graphics/Font.h:
1980         * platform/graphics/FontFastPath.cpp:
1981         * platform/graphics/GraphicsContext.cpp:
1982         * platform/graphics/ImageBuffer.h:
1983         * platform/graphics/StringTruncator.cpp:
1984         * platform/graphics/WidthIterator.cpp:
1985         * platform/graphics/mac/ComplexTextController.cpp:
1986         * platform/graphics/mac/ComplexTextControllerCoreText.cpp:
1987         * platform/graphics/mac/FontComplexTextMac.cpp:
1988         * platform/graphics/transforms/TransformationMatrix.cpp:
1989         * platform/graphics/transforms/TransformationMatrix.h:
1990         * rendering/EllipsisBox.cpp:
1991         * rendering/InlineTextBox.cpp:
1992         * rendering/RenderBlock.cpp:
1993         * rendering/RenderBlockLineLayout.cpp:
1994         * rendering/RenderEmbeddedObject.cpp:
1995         * rendering/RenderFileUploadControl.cpp:
1996         * rendering/RenderFlexibleBox.cpp:
1997         * rendering/RenderImage.cpp:
1998         * rendering/RenderListBox.cpp:
1999         * rendering/RenderListMarker.cpp:
2000         * rendering/RenderMenuList.cpp:
2001         * rendering/RenderObject.h:
2002         * rendering/RenderText.cpp:
2003         * rendering/RenderTextControl.cpp:
2004         * rendering/svg/SVGInlineTextBox.cpp:
2005         * rendering/svg/SVGMarkerLayoutInfo.h:
2006         * rendering/svg/SVGTextMetrics.cpp:
2007         * svg/SVGFont.cpp:
2008
2009 2011-01-19  Adrienne Walker  <enne@google.com>
2010
2011         Reviewed by Kenneth Russell.
2012
2013         [chromium] Tiled compositor should use texture manager
2014         https://bugs.webkit.org/show_bug.cgi?id=52418
2015
2016         Test: compositing/
2017
2018         * platform/graphics/chromium/LayerRendererChromium.cpp:
2019         (WebCore::LayerRendererChromium::~LayerRendererChromium):
2020         (WebCore::LayerRendererChromium::cleanupSharedObjects):
2021         * platform/graphics/chromium/LayerTilerChromium.cpp:
2022         (WebCore::LayerTilerChromium::LayerTilerChromium):
2023         (WebCore::LayerTilerChromium::reset):
2024         (WebCore::LayerTilerChromium::createTile):
2025         (WebCore::LayerTilerChromium::update):
2026         (WebCore::LayerTilerChromium::draw):
2027         * platform/graphics/chromium/LayerTilerChromium.h:
2028         (WebCore::LayerTilerChromium::Tile::Tile):
2029         (WebCore::LayerTilerChromium::Tile::texture):
2030
2031 2011-01-19  Stephen White  <senorblanco@chromium.org>
2032
2033         Unreviewed; build fix for chromium.
2034
2035         * platform/graphics/chromium/GLES2Canvas.cpp:
2036         (WebCore::GLES2Canvas::fillPath):
2037
2038 2011-01-18  Stephen White  <senorblanco@chromium.org>
2039
2040         Reviewed by James Robinson.
2041
2042         Implement accelerated path drawing and clipping for the Canvas2D GPU
2043         path.
2044         https://bugs.webkit.org/show_bug.cgi?id=52627
2045         
2046         This is done with a simple curve interpolator and the GLU tesselator,
2047         which is good enough for a 3-5X speedup on
2048         http://ie.microsoft.com/testdrive/Performance/Galactic/Default.html.
2049
2050         Covered by canvas/philip/2d.path.clip.basic.html, and many, many more.
2051         All tests canvas/philip and fast/canvas paths pass with no
2052         regressions, although two have minor pixel differences which require
2053         rebaselining.
2054
2055         * WebCore.gyp/WebCore.gyp:
2056         Add internal_glu include path to chromium build.
2057         * WebCore.gypi:
2058         Add internal_glu files to chromium build.
2059         * html/canvas/CanvasRenderingContext2D.cpp:
2060         (WebCore::CanvasRenderingContext2D::reset):
2061         (WebCore::CanvasRenderingContext2D::platformLayer):
2062         Make CanvasRenderingContext2D more robust against failure to create
2063         a DrawingBuffer.
2064         * platform/graphics/chromium/DrawingBufferChromium.cpp:
2065         (WebCore::DrawingBuffer::DrawingBuffer):
2066         As in DrawingBufferMac.cpp, call reset() from the constructor.
2067         Also initialize size to (-1, -1), so reset() doesn't early-out.
2068         Add initializers for depthBuffer and stencilBuffer, and remove
2069         multisampleDepthStencilBuffer.
2070         * platform/graphics/chromium/GLES2Canvas.cpp:
2071         Remove some unused #includes.
2072         (WebCore::GLES2Canvas::State::State):
2073         Add clipping state, and implement save/restore via the copy constructor.
2074         (WebCore::operator*):
2075         (WebCore::Quadratic::Quadratic):
2076         (WebCore::Quadratic::fromBezier):
2077         (WebCore::Quadratic::evaluate):
2078         Quadratic Bezier curve class.
2079         (WebCore::Cubic::Cubic):
2080         (WebCore::Cubic::fromBezier):
2081         (WebCore::Cubic::evaluate):
2082         Cubic Bezier curve class.
2083         (WebCore::GLES2Canvas::clearRect):
2084         Add clipping support to clearRect().
2085         (WebCore::GLES2Canvas::fillPath):
2086         Implement fillPath().
2087         (WebCore::GLES2Canvas::fillRect):
2088         Add clipping support to fillRect().
2089         (WebCore::GLES2Canvas::clipPath):
2090         Implement clipPath().
2091         (WebCore::GLES2Canvas::clipOut):
2092         Stub out clipOut() (not called by Canvas 2D).
2093         (WebCore::GLES2Canvas::restore):
2094         When restoring, draw any remaining clipping paths to the stencil buffer.
2095         (WebCore::GLES2Canvas::drawTexturedRect):
2096         Add clipping support.
2097         (WebCore::interpolateQuadratic):
2098         (WebCore::interpolateCubic):
2099         Simple curve interpolation, using the Cubic and Quadratic classes.
2100         (WebCore::PolygonData::PolygonData):
2101         A struct to hold the tesselation data for callbacks.
2102         (WebCore::beginData):
2103         (WebCore::edgeFlagData):
2104         (WebCore::vertexData):
2105         (WebCore::endData):
2106         (WebCore::combineData):
2107         internal_glu tesselation callbacks.
2108         (WebCore::GLES2Canvas::createVertexBufferFromPath):
2109         Build an interpolated, tesselated vertex buffer and element array buffer from a given path, suitable for filling.
2110         (WebCore::GLES2Canvas::beginStencilDraw):
2111         Enable stencilling, and disable draws to the color buffer.
2112         (WebCore::GLES2Canvas::applyClipping):
2113         If clipping is enabled, set the appropriate GL state.
2114         * platform/graphics/chromium/GLES2Canvas.h:
2115         Document the flavours of drawTexturedRect() a bit, so I don't get confused.
2116         * platform/graphics/gpu/DrawingBuffer.cpp:
2117         (WebCore::DrawingBuffer::clear):
2118         (WebCore::DrawingBuffer::createSecondaryBuffers):
2119         (WebCore::DrawingBuffer::resizeDepthStencil):
2120         (WebCore::DrawingBuffer::reset):
2121         * platform/graphics/gpu/DrawingBuffer.h:
2122         Unify m_multisampleDepthStencilBuffer with m_depthStencilBuffer. 
2123         Implement separate depth and stencil buffers for when
2124         OES_packed_depth_stencil is not available.  Refactor creation of
2125         multisampled and non-multisampled depth and stencil buffers into
2126         resizeDepthStencil().
2127         * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
2128         (WebCore::SharedGraphicsContext3D::create):
2129         Turn on stencil, turn off depth, turn off antialiasing (for now).
2130         (WebCore::SharedGraphicsContext3D::enableStencil):
2131         * platform/graphics/gpu/SharedGraphicsContext3D.h:
2132         Implement stencil enable/disable.
2133         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
2134         (WebCore::DrawingBuffer::DrawingBuffer):
2135         Remove m_multisampleDepthStencilBuffer.  Set the size to (-1, -1)
2136         on creation, so reset() doesn't early-out.  Initialize m_depthBuffer
2137         and m_stencilBuffer.
2138         * platform/graphics/skia/GraphicsContextSkia.cpp:
2139         (WebCore::GraphicsContext::canvasClip):
2140         (WebCore::GraphicsContext::clipOut):
2141         (WebCore::GraphicsContext::clipPath):
2142         (WebCore::GraphicsContext::fillPath):
2143         Put in GPU hooks for path clipping, and path drawing.
2144         * platform/graphics/skia/PlatformContextSkia.cpp:
2145         (WebCore::PlatformContextSkia::canAccelerate):
2146         Don't check for clipping paths in canAccelerate() (since we can
2147         now accelerate them).
2148         (WebCore::PlatformContextSkia::uploadSoftwareToHardware):
2149         Don't do clipping when uploading software draws to hardware.
2150         * thirdparty/glu/README.webkit:
2151         * thirdparty/glu/gluos.h:
2152         #undef MIN and MAX, to fix warnings-as-errors in Chrome/Mac build.
2153         * thirdparty/glu/libtess/geom.c:
2154         * thirdparty/glu/libtess/priorityq.c:
2155         * thirdparty/glu/libtess/render.c:
2156         Use do{}while(0) instead of if(1)else construct in macro.
2157         * thirdparty/glu/libtess/sweep.c:
2158         (IsWindingInside):
2159         (DoneEdgeDict):
2160         Fix some warnings treated as errors for the Linux Release build.
2161
2162 2011-01-19  Sheriff Bot  <webkit.review.bot@gmail.com>
2163
2164         Unreviewed, rolling out r76144.
2165         http://trac.webkit.org/changeset/76144
2166         https://bugs.webkit.org/show_bug.cgi?id=52737
2167
2168         Broke tests on multiple bots, mostly Chromium Canaries
2169         (Requested by dimich on #webkit).
2170
2171         * rendering/RenderText.cpp:
2172         (WebCore::RenderText::localCaretRect):
2173
2174 2011-01-19  Simon Fraser  <simon.fraser@apple.com>
2175
2176         Reviewed by Adam Roben.
2177
2178         [CSS Gradients] Crash due to out-of-memory with repeating-linear-gradient and latter stop positioned before former
2179         https://bugs.webkit.org/show_bug.cgi?id=52732
2180         
2181         When repeating gradient stops, make sure that the first and last stops are not at the same
2182         place, otherwise we'll add stops indefinitely and run out of memory.
2183
2184         Test: fast/gradients/zero-range-repeating-gradient-hang.html
2185
2186         * css/CSSGradientValue.cpp:
2187         (WebCore::CSSGradientValue::addStops):
2188
2189 2011-01-14  Dimitri Glazkov  <dglazkov@chromium.org>
2190
2191         Reviewed by Darin Adler.
2192
2193         Remove event forwarding logic from input[type=range], simplify event flow and thumb positioning logic.
2194         https://bugs.webkit.org/show_bug.cgi?id=52464
2195
2196         This change has two parts:
2197
2198         1) Utilize shadow DOM event retargeting to get rid of forwarding events
2199            via render tree;
2200         2) Move thumb positioning logic from RenderSlider to SliderThumbElement.
2201
2202         These two are highly co-dependent. It looked ugly when I tried to
2203         separate them.
2204
2205         No change in behavior, covered by existing tests.
2206
2207         * html/HTMLInputElement.cpp:
2208         (WebCore::HTMLInputElement::defaultEventHandler): Added invocation of
2209             InputType::handleMouseDownEvent.
2210         * html/InputType.cpp:
2211         (WebCore::InputType::handleMouseDownEvent): Added empty decl.
2212         * html/InputType.h: Added def.
2213         * html/RangeInputType.cpp:
2214         (WebCore::RangeInputType::handleMouseDownEvent): Added to handle the case
2215             when the user clicks on the track of the slider. Also removed the
2216             forwardEvent method.
2217         * html/RangeInputType.h: Added/removed defs.
2218         * html/shadow/SliderThumbElement.cpp:
2219         (WebCore::SliderThumbElement::dragFrom): Added a helper method to start
2220             dragging from any position.
2221         (WebCore::SliderThumbElement::dragTo): Added a helper method to drag to
2222             specified position.
2223         (WebCore::SliderThumbElement::setPosition): Collapsed most of the positioning
2224             logic in RenderSlider into this method, which is now a simple calculation
2225             and adjusting of thumb position based on supplied coordinates.
2226         (WebCore::SliderThumbElement::startDragging): Added.
2227         (WebCore::SliderThumbElement::stopDragging): Added.
2228         (WebCore::SliderThumbElement::defaultEventHandler): Removed most of the
2229             old position-sniffing logic and replaced with simple calls to start,
2230             stop, and drag the thumb.
2231         * html/shadow/SliderThumbElement.h: Added defs.
2232         * rendering/RenderSlider.cpp: Removed a bunch of code that is no longer
2233             necessary.
2234         * rendering/RenderSlider.h: Removed defs, removed now-unnecessary friendliness.
2235
2236 2011-01-19  Shane Stephens  <shanestephens@google.com>
2237
2238         Reviewed by Chris Marrin.
2239
2240         Make AffineTransform and TransformationMatrix do matrix multiplication in the correct order (Column Major)
2241         https://bugs.webkit.org/show_bug.cgi?id=48031
2242
2243         Fixed reversal, renamed matrix methods to be clearer, found all examples of operator* and
2244         operator*= usage and switched operand order.
2245
2246         No new tests as this refactor doesn't add functionality.
2247
2248         * html/HTMLCanvasElement.cpp:
2249         (WebCore::HTMLCanvasElement::baseTransform):
2250         * html/canvas/CanvasRenderingContext2D.cpp:
2251         (WebCore::CanvasRenderingContext2D::transform):
2252         (WebCore::CanvasRenderingContext2D::setTransform):
2253         * platform/graphics/cg/PatternCG.cpp:
2254         (WebCore::Pattern::createPlatformPattern):
2255         * platform/graphics/chromium/GLES2Canvas.cpp:
2256         (WebCore::GLES2Canvas::fillRect):
2257         (WebCore::GLES2Canvas::concatCTM):
2258         (WebCore::GLES2Canvas::drawQuad):
2259         * platform/graphics/chromium/TransparencyWin.cpp:
2260         (WebCore::TransparencyWin::setupLayerForOpaqueCompositeLayer):
2261         (WebCore::TransparencyWin::setupTransformForKeepTransform):
2262         * platform/graphics/transforms/AffineTransform.cpp:
2263         (WebCore::AffineTransform::multiply):
2264         (WebCore::AffineTransform::rotate):
2265         * platform/graphics/transforms/AffineTransform.h:
2266         (WebCore::AffineTransform::operator*=):
2267         (WebCore::AffineTransform::operator*):
2268         * platform/graphics/wince/GraphicsContextWinCE.cpp:
2269         (WebCore::GraphicsContextPlatformPrivate::concatCTM):
2270         * platform/graphics/wince/SharedBitmap.cpp:
2271         (WebCore::SharedBitmap::drawPattern):
2272         * rendering/svg/RenderSVGResourceContainer.cpp:
2273         (WebCore::RenderSVGResourceContainer::transformOnNonScalingStroke):
2274         * rendering/svg/RenderSVGResourceGradient.cpp:
2275         (WebCore::clipToTextMask):
2276         (WebCore::RenderSVGResourceGradient::applyResource):
2277         * rendering/svg/RenderSVGResourcePattern.cpp:
2278         (WebCore::RenderSVGResourcePattern::applyResource):
2279         * rendering/svg/RenderSVGRoot.cpp:
2280         (WebCore::RenderSVGRoot::localToBorderBoxTransform):
2281         * rendering/svg/SVGImageBufferTools.cpp:
2282         (WebCore::SVGImageBufferTools::calculateTransformationToOutermostSVGCoordinateSystem):
2283         (WebCore::SVGImageBufferTools::renderSubtreeToImageBuffer):
2284         * rendering/svg/SVGTextLayoutEngine.cpp:
2285         (WebCore::SVGTextLayoutEngine::finalizeTransformMatrices):
2286         * svg/SVGLocatable.cpp:
2287         (WebCore::SVGLocatable::computeCTM):
2288         (WebCore::SVGLocatable::getTransformToElement):
2289         * svg/SVGMatrix.h:
2290         (WebCore::SVGMatrix::multiply):
2291         * svg/SVGSVGElement.cpp:
2292         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
2293         (WebCore::SVGSVGElement::viewBoxToViewTransform):
2294         * svg/SVGStyledTransformableElement.cpp:
2295         (WebCore::SVGStyledTransformableElement::animatedLocalTransform):
2296         * svg/SVGTextElement.cpp:
2297         (WebCore::SVGTextElement::animatedLocalTransform):
2298         * svg/SVGTransformList.cpp:
2299         (WebCore::SVGTransformList::concatenate):
2300
2301 2011-01-19  Chang Shu  <chang.shu@nokia.com>
2302
2303         Reviewed by Darin Adler.
2304
2305         The return value of contentEditable() function should depend on the DOM attribute
2306         instead of render style userModify. The code change fixed test cases in the bug
2307         and partially fixed test cases in other contentEditable bugs;
2308
2309         https://bugs.webkit.org/show_bug.cgi?id=52056
2310
2311         * html/HTMLElement.cpp:
2312         (WebCore::HTMLElement::contentEditable):
2313
2314 2011-01-19  Levi Weintraub  <leviw@chromium.org>
2315
2316         Reviewed by Darin Adler.
2317
2318         Changing RenderText::localCaretRect to clip to its containing block's logicalLeft and
2319         logicalRightLayoutOverflow instead of simply using logicalLeft and logicalRight, as this
2320         resulted in the caret being placed incorrectly in overflowing editable IFrame content.
2321
2322         Long lines in non-white-space-pre editable documents show cursor in wrong place
2323         https://bugs.webkit.org/show_bug.cgi?id=48132
2324
2325         Test: editing/selection/caret-painting-in-overflowing-autowrap-content.html
2326
2327         * rendering/RenderText.cpp:
2328         (WebCore::RenderText::localCaretRect):
2329
2330 2011-01-19  Chris Marrin  <cmarrin@apple.com>
2331
2332         Reviewed by Simon Fraser.
2333
2334         WK2 - Multiple crashes in PlatformCALayer::replaceSublayer
2335         https://bugs.webkit.org/show_bug.cgi?id=52695
2336
2337         Added ASSERTs to the places we assume a non-null superlayer.
2338
2339         * platform/graphics/ca/GraphicsLayerCA.cpp:
2340         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
2341         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
2342
2343 2011-01-18  Beth Dakin  <bdakin@apple.com>
2344
2345         Reviewed by Maciej Stachowiak.
2346
2347         Fix for <rdar://problem/8882916> Overlay scrollers require 
2348         content to layout underneath the scrollbar area
2349
2350         The render tree should not include scrollbar size for
2351         overlay scrollers. This patch will allow scrollers on
2352         the WebView to behave like overflow:overlay.
2353
2354         Treat overlay scrollers the same way as the !includeScrollbars
2355         case.
2356         * platform/ScrollView.cpp:
2357         (WebCore::ScrollView::visibleContentRect):
2358
2359         No corner rect for overlay scrollers.
2360         (WebCore::ScrollView::scrollCornerRect):
2361
2362         usesOverlayScrollbars() currently always returns no.
2363         * platform/ScrollbarTheme.h:
2364         (WebCore::ScrollbarTheme::usesOverlayScrollbars):
2365         * platform/mac/ScrollbarThemeMac.h:
2366         * platform/mac/ScrollbarThemeMac.mm:
2367         (WebCore::ScrollbarThemeMac::usesOverlayScrollbars):
2368
2369         includeVerticalScrollbarSize() and includeHorizontalScrollbarSize()
2370         should return false for overlay scrollers. They already return
2371         false for overflow:overlay.
2372         * rendering/RenderBox.cpp:
2373         (WebCore::RenderBox::includeVerticalScrollbarSize):
2374         (WebCore::RenderBox::includeHorizontalScrollbarSize):
2375         * rendering/RenderBox.h:
2376
2377         In the render tree, always treat overlay scrollers like
2378         they have a width and height of 0.
2379         * rendering/RenderLayer.cpp:
2380         (WebCore::RenderLayer::verticalScrollbarWidth):
2381         (WebCore::RenderLayer::horizontalScrollbarHeight):
2382         * rendering/RenderListBox.cpp:
2383         (WebCore::RenderListBox::verticalScrollbarWidth):
2384
2385 2011-01-18  Evan Martin  <evan@chromium.org>
2386
2387         Reviewed by Tony Chang.
2388
2389         [chromium] simplify complex text code, fixing a handful of layout tests
2390         https://bugs.webkit.org/show_bug.cgi?id=52661
2391
2392         Change ComplexTextControllerLinux to lay out RTL text to the left from
2393         the starting point.  (Previously it always went to the right.)  This allows
2394         us to map pixel offsets more directly into offsets within the text runs,
2395         simplifying a few of the text-fiddling functions (they no longer need to
2396         track the current position, as ComplexTextController now does it).
2397
2398         * platform/graphics/chromium/ComplexTextControllerLinux.cpp:
2399         (WebCore::ComplexTextController::ComplexTextController):
2400         (WebCore::ComplexTextController::reset):
2401         (WebCore::ComplexTextController::setGlyphXPositions):
2402         * platform/graphics/chromium/ComplexTextControllerLinux.h:
2403         (WebCore::ComplexTextController::offsetX):
2404         * platform/graphics/chromium/FontLinux.cpp:
2405         (WebCore::Font::drawComplexText):
2406         (WebCore::Font::floatWidthForComplexText):
2407         (WebCore::glyphIndexForXPositionInScriptRun):
2408         (WebCore::Font::offsetForPositionForComplexText):
2409         (WebCore::Font::selectionRectForComplexText):
2410
2411 2011-01-19  Pavel Feldman  <pfeldman@chromium.org>
2412
2413         Reviewed by Yury Semikhatsky.
2414
2415         Web Inspector: move methods from InjectedScript domain into DOM,
2416         Runtime and Debugger domains. Introduce InspectorRuntimeAgent.
2417         https://bugs.webkit.org/show_bug.cgi?id=52717
2418
2419         * CMakeLists.txt:
2420         * GNUmakefile.am:
2421         * WebCore.gypi:
2422         * WebCore.pro:
2423         * WebCore.vcproj/WebCore.vcproj:
2424         * WebCore.xcodeproj/project.pbxproj:
2425         * inspector/CodeGeneratorInspector.pm:
2426         * inspector/InjectedScript.cpp:
2427         (WebCore::InjectedScript::evaluateOnCallFrame):
2428         (WebCore::InjectedScript::getCompletions):
2429         (WebCore::InjectedScript::getCompletionsOnCallFrame):
2430         * inspector/InjectedScript.h:
2431         * inspector/InjectedScriptHost.cpp:
2432         (WebCore::InjectedScriptHost::injectedScriptForMainWorld):
2433         * inspector/InjectedScriptHost.h:
2434         * inspector/InjectedScriptSource.js:
2435         (.):
2436         ():
2437         * inspector/Inspector.idl:
2438         * inspector/InspectorController.cpp:
2439         (WebCore::InspectorController::connectFrontend):
2440         (WebCore::InspectorController::releaseFrontendLifetimeAgents):
2441         * inspector/InspectorController.h:
2442         * inspector/InspectorDOMAgent.cpp:
2443         (WebCore::InspectorDOMAgent::InspectorDOMAgent):
2444         (WebCore::InspectorDOMAgent::resolveNode):
2445         (WebCore::InspectorDOMAgent::getNodeProperties):
2446         (WebCore::InspectorDOMAgent::getNodePrototypes):
2447         (WebCore::InspectorDOMAgent::injectedScriptForNodeId):
2448         * inspector/InspectorDOMAgent.h:
2449         (WebCore::EventListenerInfo::EventListenerInfo):
2450         (WebCore::InspectorDOMAgent::DOMListener::~DOMListener):
2451         (WebCore::InspectorDOMAgent::create):
2452         (WebCore::InspectorDOMAgent::cast):
2453         (WebCore::InspectorDOMAgent::documents):
2454         * inspector/InspectorDebuggerAgent.cpp:
2455         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
2456         (WebCore::InspectorDebuggerAgent::getCompletionsOnCallFrame):
2457         (WebCore::InspectorDebuggerAgent::injectedScriptForCallFrameId):
2458         * inspector/InspectorDebuggerAgent.h:
2459         * inspector/InspectorRuntimeAgent.cpp: Added.
2460         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
2461         (WebCore::InspectorRuntimeAgent::~InspectorRuntimeAgent):
2462         (WebCore::InspectorRuntimeAgent::evaluate):
2463         (WebCore::InspectorRuntimeAgent::getCompletions):
2464         (WebCore::InspectorRuntimeAgent::getProperties):
2465         (WebCore::InspectorRuntimeAgent::setPropertyValue):
2466         (WebCore::InspectorRuntimeAgent::pushNodeToFrontend):
2467         (WebCore::InspectorRuntimeAgent::injectedScriptForObjectId):
2468         * inspector/InspectorRuntimeAgent.h: Copied from Source/WebCore/inspector/InjectedScript.h.
2469         (WebCore::InspectorRuntimeAgent::create):
2470         * inspector/front-end/ConsoleView.js:
2471         (WebInspector.ConsoleView.prototype.completions):
2472         * inspector/front-end/ScriptsPanel.js:
2473         (WebInspector.ScriptsPanel.prototype.doEvalInCallFrame):
2474
2475 2011-01-18  Pavel Podivilov  <podivilov@chromium.org>
2476
2477         Reviewed by Yury Semikhatsky.
2478
2479         Web Inspector: add UglifyJS parser and formatter files
2480         https://bugs.webkit.org/show_bug.cgi?id=51702
2481
2482         * WebCore.gypi:
2483         * WebCore.vcproj/WebCore.vcproj:
2484         * inspector/front-end/ScriptFormatter.js:
2485         (WebInspector.ScriptFormatter.positionToLocation):
2486         (WebInspector.ScriptFormatter.prototype.format.messageHandler):
2487         (WebInspector.ScriptFormatter.prototype.format):
2488         (WebInspector.ScriptFormatter.prototype._buildMapping):
2489         (WebInspector.ScriptFormatter.prototype._convertPosition):
2490         * inspector/front-end/SourceFrame.js:
2491         (WebInspector.SourceFrame.prototype.formatSource.didFormat):
2492         (WebInspector.SourceFrame.prototype.formatSource):
2493         * inspector/front-end/WebKit.qrc:
2494         * inspector/front-end/parse-js.js: Added. UglifyJS parser.
2495         * inspector/front-end/process.js: Added. UglifyJS formatter.
2496         * inspector/front-end/scriptFormatterWorker.js: Added. Worker script that wraps UglifyJS code.
2497         (onmessage):
2498         (beautify):
2499         (loadModule):
2500         (require):
2501         * inspector/front-end/utilities.js:
2502         ():
2503
2504 2011-01-19  Pavel Podivilov  <podivilov@chromium.org>
2505
2506         Reviewed by Yury Semikhatsky.
2507
2508         Web Inspector: [JSC] scripts have incorrect starting line (always 1).
2509         https://bugs.webkit.org/show_bug.cgi?id=52721
2510
2511         Test: inspector/debugger-scripts.html
2512
2513         * bindings/js/ScriptDebugServer.cpp:
2514         (WebCore::ScriptDebugServer::dispatchDidParseSource):
2515         (WebCore::ScriptDebugServer::dispatchFailedToParseSource):
2516         (WebCore::ScriptDebugServer::sourceParsed):
2517         * bindings/js/ScriptDebugServer.h:
2518         * bindings/js/ScriptSourceCode.h:
2519         (WebCore::ScriptSourceCode::ScriptSourceCode):
2520         * bindings/js/StringSourceProvider.h:
2521         (WebCore::StringSourceProvider::create):
2522         (WebCore::StringSourceProvider::startPosition):
2523         (WebCore::StringSourceProvider::StringSourceProvider):
2524
2525 2011-01-19  Satish Sampath  <satish@chromium.org>
2526
2527         Reviewed by Jeremy Orlow.
2528
2529         Send origin/url as part of speech input requests to the embedder.
2530         https://bugs.webkit.org/show_bug.cgi?id=52718
2531
2532         * page/SpeechInput.cpp:
2533         (WebCore::SpeechInput::startRecognition): Pass up additional origin parameter.
2534         * page/SpeechInput.h:
2535         * page/SpeechInputClient.h:
2536         * platform/mock/SpeechInputClientMock.cpp:
2537         (WebCore::SpeechInputClientMock::startRecognition): Updated prototype.
2538         * platform/mock/SpeechInputClientMock.h:
2539         * rendering/TextControlInnerElements.cpp:
2540         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler): Pass the frame origin to speech input request.
2541
2542 2011-01-19  Hans Wennborg  <hans@chromium.org>
2543
2544         Reviewed by Jeremy Orlow.
2545
2546         IndexedDB: Support auto-increment keys
2547         https://bugs.webkit.org/show_bug.cgi?id=52576
2548
2549         Add support for auto-increment keys.
2550
2551         Test: storage/indexeddb/objectstore-autoincrement.html
2552
2553         * storage/IDBDatabase.cpp:
2554         (WebCore::IDBDatabase::createObjectStore):
2555         * storage/IDBObjectStoreBackendImpl.cpp:
2556         (WebCore::genAutoIncrementKey):
2557         (WebCore::IDBObjectStoreBackendImpl::putInternal):
2558
2559 2011-01-19  Csaba Osztrogonác  <ossy@webkit.org>
2560
2561         Reviewed by Laszlo Gombos and Tor Arne Vestbø.
2562
2563         [Qt] Remove unnecessary "../Source" from paths
2564         after moving source files into Source is finished.
2565
2566         * WebCore.pri:
2567         * WebCore.pro:
2568
2569 2011-01-19  Alexander Pavlov  <apavlov@chromium.org>
2570
2571         Reviewed by Pavel Feldman.
2572
2573         Web Inspector: Employ TextPrompt for CSS property name/value autocompletion
2574         https://bugs.webkit.org/show_bug.cgi?id=52212
2575
2576         WebInspector.CSSKeywordCompletions contains a hand-written list of accepted CSS property value keywords
2577         for each property. WebInspector.TextPrompt is used to suggest both the name and value keywords while
2578         editing styles, in place of the old custom suggestion code.
2579
2580         * inspector/front-end/CSSCompletions.js:
2581         (WebInspector.CSSCompletions.prototype.startsWith): Fix array-out-of-bounds error.
2582         * inspector/front-end/CSSKeywordCompletions.js: Added.
2583         (WebInspector.CSSKeywordCompletions.forProperty):
2584         * inspector/front-end/StylesSidebarPane.js:
2585         (WebInspector.StylePropertyTreeElement.prototype.updateTitle):
2586         (WebInspector.StylePropertyTreeElement.prototype):
2587         ():
2588         * inspector/front-end/TextPrompt.js:
2589         (WebInspector.TextPrompt):
2590         (WebInspector.TextPrompt.prototype.removeFromElement):
2591         (WebInspector.TextPrompt.prototype._onKeyDown):
2592         (WebInspector.TextPrompt.prototype.tabKeyPressed):
2593         (WebInspector.TextPrompt.prototype.upKeyPressed):
2594         (WebInspector.TextPrompt.prototype.downKeyPressed):
2595         (WebInspector.TextPrompt.prototype._moveBackInHistory):
2596         (WebInspector.TextPrompt.prototype._moveForwardInHistory):
2597         * inspector/front-end/inspector.css:
2598         (.auto-complete-text, .editing .auto-complete-text):
2599         * inspector/front-end/inspector.html:
2600
2601 2011-01-19  Dai Mikurube  <dmikurube@google.com>
2602
2603         Reviewed by Kent Tamura.
2604
2605         Implement onformchange and onforminput event handlers
2606         https://bugs.webkit.org/show_bug.cgi?id=26141
2607
2608         Tests: fast/forms/formchange-event.html
2609                fast/forms/forminput-event.html
2610
2611         * bindings/scripts/CodeGeneratorGObject.pm: Added event names.
2612         * dom/Document.h: Added event definitions.
2613         * dom/Document.idl: Added event definitions.
2614         * dom/Element.h: Added event definitions.
2615         * dom/Element.idl: Added event definitions.
2616         * dom/Event.cpp:
2617         (WebCore::Event::fromUserGesture): Added a condition for a formchange event in handling user gestures.
2618         * dom/EventNames.h: Added event definitions.
2619         * dom/InputElement.cpp:
2620         (WebCore::InputElement::setValueFromRenderer): Replaced a direct dispatchEvent() call into dispatchInputEvents(), a virtual function which broadcasts forminput events for HTML elements.
2621         * dom/Node.cpp:
2622         (WebCore::Node::dispatchInputEvents): Defined basic dispatchInputEvents() described above.
2623         (WebCore::Node::dispatchChangeEvents): Defined basic dispatchChangeEvents() described above.
2624         (WebCore::Node::defaultEventHandler): Replaced a direct dispatchEvent() call into dispatchInputEvents().
2625         * dom/Node.h:
2626         * html/FormAssociatedElement.h: Added isResettable() to check the element is resettable or not.
2627         * html/HTMLAttributeNames.in: Added event names.
2628         * html/HTMLElement.cpp:
2629         (WebCore::HTMLElement::parseMappedAttribute): Added event handling.
2630         (WebCore::HTMLElement::shadowAncestorOwnerForm): Added to get an ancestor <form> element from a shadow element.
2631         (WebCore::HTMLElement::dispatchChangeEvents): Defined dispatchChangeEvents() for HTML elements described above.
2632         (WebCore::HTMLElement::dispatchInputEvents): Defined dispatchInputEvents() for HTML elements described above.
2633         * html/HTMLElement.h:
2634         * html/HTMLFormControlElement.cpp:
2635         (WebCore::HTMLFormControlElement::dispatchFormControlChangeEvent): Added calling dispatchFormChange() to broadcast formchange events.
2636         (WebCore::HTMLFormControlElement::dispatchFormControlInputEvent): Defined newly to dispatch an input event with broadcasting forminput events.
2637         * html/HTMLFormControlElement.h: Added isResettable().
2638         * html/HTMLFormElement.cpp:
2639         (WebCore::HTMLFormElement::broadcastFormEvent): Added to broadcast forminput or formchange events.
2640         (WebCore::HTMLFormElement::dispatchFormInput): Defined newly to broadcast forminput events.
2641         (WebCore::HTMLFormElement::dispatchFormChange): Defined newly to broadcast formchange events.
2642         * html/HTMLFormElement.h:
2643         * html/HTMLFormElement.idl: Added dispatchFormInput() and dispatchFormChange() DOM API definitions.
2644         * html/HTMLInputElement.cpp:
2645         (WebCore::HTMLInputElement::stepUpFromRenderer): Replaced a direct dispatchEvent() call into dispatchInputEvents().
2646         * html/HTMLInputElement.h: Added isResettable().
2647         * html/HTMLKeygenElement.h: Added isResettable().
2648         * html/HTMLObjectElement.h: Added isResettable().
2649         * html/HTMLOutputElement.h: Added isResettable().
2650         * html/HTMLSelectElement.h: Added isResettable().
2651         * html/HTMLTextAreaElement.h: Added isResettable().
2652         * page/DOMWindow.h: Added event definitions.
2653         * page/DOMWindow.idl: Added event definitions.
2654         * rendering/TextControlInnerElements.cpp:
2655         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler): Replaced a direct dispatchEvent() call into dispatchInputEvents().
2656
2657 2011-01-19  Andrey Kosyakov  <caseq@chromium.org>
2658
2659         Reviewed by Pavel Feldman.
2660
2661         Web Inspector: [Extensions API] delete pending callback from callback map before invoking it
2662         https://bugs.webkit.org/show_bug.cgi?id=52707
2663
2664         * inspector/front-end/ExtensionAPI.js:
2665         (WebInspector.injectedExtensionAPI.ExtensionServerClient.prototype._onCallback):
2666
2667 2011-01-19  Levi Weintraub  <leviw@google.com>
2668
2669         Reviewed by Ryosuke Niwa.
2670
2671         Replaced rangeCompliantEquivalent with Position::parentAnchoredEquivalent
2672         and simplified the logic a bit. Unfortunately, Tables and some legacy
2673         editing positions still need to be handled specifically.
2674
2675         remove rangeCompliantEquivalent and replace it with Position methods
2676         https://bugs.webkit.org/show_bug.cgi?id=25057
2677
2678         No new tests as this is a refactor that doesn't change behavior.
2679
2680         * WebCore.exp.in:
2681         * dom/Document.cpp:
2682         (WebCore::Document::caretRangeFromPoint):
2683         * dom/Position.cpp:
2684         (WebCore::Position::parentAnchoredEquivalent):
2685         * dom/Position.h:
2686         * editing/ApplyStyleCommand.cpp:
2687         (WebCore::ApplyStyleCommand::applyBlockStyle):
2688         * editing/CompositeEditCommand.cpp:
2689         (WebCore::CompositeEditCommand::insertNodeAt):
2690         (WebCore::CompositeEditCommand::moveParagraphs):
2691         * editing/DeleteSelectionCommand.cpp:
2692         (WebCore::DeleteSelectionCommand::initializePositionData):
2693         (WebCore::DeleteSelectionCommand::mergeParagraphs):
2694         * editing/Editor.cpp:
2695         (WebCore::Editor::textDirectionForSelection):
2696         (WebCore::Editor::advanceToNextMisspelling):
2697         * editing/InsertLineBreakCommand.cpp:
2698         (WebCore::InsertLineBreakCommand::shouldUseBreakElement):
2699         * editing/InsertParagraphSeparatorCommand.cpp:
2700         (WebCore::InsertParagraphSeparatorCommand::doApply):
2701         * editing/ReplaceSelectionCommand.cpp:
2702         (WebCore::handleStyleSpansBeforeInsertion):
2703         * editing/VisiblePosition.cpp:
2704         (WebCore::makeRange):
2705         (WebCore::setStart):
2706         (WebCore::setEnd):
2707         * editing/VisibleSelection.cpp:
2708         (WebCore::VisibleSelection::firstRange):
2709         (WebCore::VisibleSelection::toNormalizedRange):
2710         (WebCore::makeSearchRange):
2711         * editing/htmlediting.cpp:
2712         (WebCore::indexForVisiblePosition):
2713         * editing/htmlediting.h:
2714         * editing/visible_units.cpp:
2715         (WebCore::previousBoundary):
2716         (WebCore::nextBoundary):
2717         * page/DOMSelection.cpp:
2718         (WebCore::anchorPosition):
2719         (WebCore::focusPosition):
2720         (WebCore::basePosition):
2721         (WebCore::extentPosition):
2722
2723 2011-01-19  Peter Rybin  <peter.rybin@gmail.com>
2724
2725         Reviewed by Yury Semikhatsky.
2726
2727         Web Inspector: script column offset is incorrect
2728         https://bugs.webkit.org/show_bug.cgi?id=52580
2729
2730         Column is updated in 3 places, 2 less probable places contained error.
2731         Fixed now.
2732
2733         * platform/text/SegmentedString.cpp:
2734         (WebCore::SegmentedString::advanceSlowCase):
2735         * platform/text/SegmentedString.h:
2736         (WebCore::SegmentedString::advancePastNewline):
2737
2738 2011-01-18  Pavel Feldman  <pfeldman@chromium.org>
2739
2740         Reviewed by Yury Semikhatsky.
2741
2742         Web Inspector: make InjectedScriptAccess API a part of Web Inspector protocol.
2743         https://bugs.webkit.org/show_bug.cgi?id=52652
2744
2745         Calls served by the InjectedScript should be first class protocol
2746         citizens, not dispatched via single protocol message.
2747
2748         * WebCore.gypi:
2749         * WebCore.vcproj/WebCore.vcproj:
2750         * inspector/CodeGeneratorInspector.pm:
2751         * inspector/InjectedScript.cpp:
2752         (WebCore::InjectedScript::evaluate):
2753         (WebCore::InjectedScript::evaluateInCallFrame):
2754         (WebCore::InjectedScript::evaluateOnSelf):
2755         (WebCore::InjectedScript::getCompletions):
2756         (WebCore::InjectedScript::getProperties):
2757         (WebCore::InjectedScript::pushNodeToFrontend):
2758         (WebCore::InjectedScript::resolveNode):
2759         (WebCore::InjectedScript::getNodeProperties):
2760         (WebCore::InjectedScript::getNodePrototypes):
2761         (WebCore::InjectedScript::setPropertyValue):
2762         (WebCore::InjectedScript::makeCall):
2763         * inspector/InjectedScript.h:
2764         * inspector/InjectedScriptHost.cpp:
2765         (WebCore::InjectedScriptHost::evaluate):
2766         (WebCore::InjectedScriptHost::evaluateInCallFrame):
2767         (WebCore::InjectedScriptHost::evaluateOnSelf):
2768         (WebCore::InjectedScriptHost::getCompletions):
2769         (WebCore::InjectedScriptHost::getProperties):
2770         (WebCore::InjectedScriptHost::pushNodeToFrontend):
2771         (WebCore::InjectedScriptHost::resolveNode):
2772         (WebCore::InjectedScriptHost::getNodeProperties):
2773         (WebCore::InjectedScriptHost::getNodePrototypes):
2774         (WebCore::InjectedScriptHost::setPropertyValue):
2775         (WebCore::InjectedScriptHost::injectedScriptForObjectId):
2776         (WebCore::InjectedScriptHost::injectedScriptForNodeId):
2777         (WebCore::InjectedScriptHost::injectedScriptForMainWorld):
2778         * inspector/InjectedScriptHost.h:
2779         * inspector/InjectedScriptSource.js:
2780         (.):
2781         * inspector/Inspector.idl:
2782         * inspector/InspectorController.cpp:
2783         * inspector/InspectorController.h:
2784         * inspector/InspectorValues.cpp:
2785         (WebCore::InspectorObject::getNumber):
2786         * inspector/InspectorValues.h:
2787         * inspector/front-end/AuditRules.js:
2788         (WebInspector.AuditRules.evaluateInTargetWindow):
2789         * inspector/front-end/ConsoleView.js:
2790         (WebInspector.ConsoleView.prototype.completions):
2791         (WebInspector.ConsoleView.prototype.doEvalInWindow):
2792         * inspector/front-end/ElementsTreeOutline.js:
2793         (WebInspector.ElementsTreeElement.prototype._createTooltipForNode):
2794         * inspector/front-end/ExtensionPanel.js:
2795         (WebInspector.ExtensionWatchSidebarPane.prototype.setExpression):
2796         * inspector/front-end/ExtensionServer.js:
2797         (WebInspector.ExtensionServer.prototype._onEvaluateOnInspectedPage):
2798         * inspector/front-end/InjectedScriptAccess.js: Removed.
2799         * inspector/front-end/PropertiesSidebarPane.js:
2800         (WebInspector.PropertiesSidebarPane.prototype.update.callback):
2801         (WebInspector.PropertiesSidebarPane.prototype.update):
2802         * inspector/front-end/RemoteObject.js:
2803         (WebInspector.RemoteObject.resolveNode):
2804         (WebInspector.RemoteObject.prototype.getProperties):
2805         (WebInspector.RemoteObject.prototype.setPropertyValue):
2806         (WebInspector.RemoteObject.prototype.pushNodeToFrontend):
2807         * inspector/front-end/ScriptsPanel.js:
2808         (WebInspector.ScriptsPanel.prototype.doEvalInCallFrame):
2809         * inspector/front-end/WebKit.qrc:
2810         * inspector/front-end/inspector.html:
2811
2812 2011-01-18  Anton Muhin  <antonm@chromium.org>
2813
2814         Reviewed by Adam Barth.
2815
2816         [v8] Minor cleanup: make 2nd argument of removeIfPresnt accept only a value type stored in the DOM map
2817         https://bugs.webkit.org/show_bug.cgi?id=51683
2818
2819         Covered by the existing tests.
2820
2821         * bindings/v8/DOMDataStore.cpp:
2822         (WebCore::DOMDataStore::weakNodeCallback):
2823         (WebCore::DOMDataStore::IntrusiveDOMWrapperMap::removeIfPresent):
2824         * bindings/v8/DOMDataStore.h:
2825         * bindings/v8/V8DOMMap.h:
2826         (WebCore::WeakReferenceMap::removeIfPresent):
2827
2828 2011-01-18 MORITA Hajime  <morrita@google.com>
2829
2830         Reviewed by Ryosuke Niwa.
2831         
2832         Refactoring: EventHandler::handleTextInputEvent should accept an enum instead of bools.
2833         https://bugs.webkit.org/show_bug.cgi?id=52608
2834
2835         No new tests. no behavioral change.
2836
2837         * GNUmakefile.am:
2838         * WebCore.gypi:
2839         * WebCore.pro:
2840         * WebCore.vcproj/WebCore.vcproj:
2841         * WebCore.xcodeproj/project.pbxproj:
2842         * dom/TextEvent.cpp:
2843         (WebCore::TextEvent::create):
2844         (WebCore::TextEvent::createForDrop):
2845         (WebCore::TextEvent::TextEvent):
2846         * dom/TextEvent.h:
2847         (WebCore::TextEvent::isLineBreak):
2848         (WebCore::TextEvent::isBackTab):
2849         (WebCore::TextEvent::isPaste):
2850         (WebCore::TextEvent::isDrop):
2851         * dom/TextEventInputType.h: Added. Extracted from TextEvent::TextInputType.
2852         * editing/EditorCommand.cpp:
2853         (WebCore::executeInsertBacktab):
2854         (WebCore::executeInsertLineBreak):
2855         (WebCore::executeInsertNewline):
2856         (WebCore::executeInsertTab):
2857         * page/EventHandler.cpp:
2858         (WebCore::EventHandler::handleTextInputEvent):
2859         * page/EventHandler.h:
2860
2861 2011-01-18  Ben Vanik  <ben.vanik@gmail.com>
2862
2863         Reviewed by Kenneth Russell.
2864
2865         Updating ANGLE in WebKit to r533.
2866         https://bugs.webkit.org/show_bug.cgi?id=47194
2867
2868         * platform/graphics/ANGLEWebKitBridge.cpp:
2869         (WebCore::ANGLEWebKitBridge::ANGLEWebKitBridge):
2870         (WebCore::ANGLEWebKitBridge::~ANGLEWebKitBridge):
2871         (WebCore::ANGLEWebKitBridge::validateShaderSource):
2872         Update to new ANGLE API for shader validation.
2873         * platform/graphics/ANGLEWebKitBridge.h:
2874         (WebCore::ANGLEWebKitBridge::setResources): 
2875         Renaming types to new names.
2876         * platform/graphics/mac/GraphicsContext3DMac.mm:
2877         (WebCore::GraphicsContext3D::GraphicsContext3D):
2878         Initialize ANGLEResources with ANGLE init call to prevent uninitialized variables.
2879
2880 2011-01-18  MORITA Hajime  <morrita@google.com>
2881
2882         Reviewed by Simon Fraser.
2883
2884         Refactoring: Extract RoundedIntRect class
2885         https://bugs.webkit.org/show_bug.cgi?id=51664
2886
2887         RoundedIntRect is a pair of rect and four IntSize objects which represent
2888         corner radii of the rectangle. IntSize is grouped into RoundedIntRect::Radii.
2889         Now RenderStyle::getRoundedBorderFor() and RenderStyle::getRoundedInnerBorderWithBorderWidths()
2890         return RoundedIntRect and GraphicsContext::addRoundedRectClip(), GraphicsContext::fillRoundedRect()
2891         and other functions accept RoundedIntRect as an argument.
2892
2893         * Android.mk:
2894         * CMakeLists.txt:
2895         * GNUmakefile.am:
2896         * WebCore.gypi:
2897         * WebCore.pro:
2898         * WebCore.vcproj/WebCore.vcproj:
2899         * WebCore.xcodeproj/project.pbxproj:
2900         * platform/graphics/GraphicsContext.cpp:
2901         (WebCore::GraphicsContext::addRoundedRectClip):
2902         (WebCore::GraphicsContext::clipOutRoundedRect):
2903         (WebCore::GraphicsContext::fillRoundedRect):
2904         * platform/graphics/GraphicsContext.h:
2905         * platform/graphics/RoundedIntRect.cpp: Added.
2906         (WebCore::RoundedIntRect::Radii::isZero):
2907         (WebCore::RoundedIntRect::Radii::scale):
2908         (WebCore::RoundedIntRect::Radii::expand):
2909         (WebCore::RoundedIntRect::Radii::includeLogicalEdges):
2910         (WebCore::RoundedIntRect::Radii::excludeLogicalEdges):
2911         (WebCore::RoundedIntRect::RoundedIntRect):
2912         (WebCore::RoundedIntRect::includeLogicalEdges):
2913         (WebCore::RoundedIntRect::excludeLogicalEdges):
2914         * platform/graphics/RoundedIntRect.h: Added.
2915         (WebCore::RoundedIntRect::Radii::Radii):
2916         (WebCore::RoundedIntRect::Radii::setTopLeft):
2917         (WebCore::RoundedIntRect::Radii::setTopRight):
2918         (WebCore::RoundedIntRect::Radii::setBottomLeft):
2919         (WebCore::RoundedIntRect::Radii::setBottomRight):
2920         (WebCore::RoundedIntRect::Radii::topLeft):
2921         (WebCore::RoundedIntRect::Radii::topRight):
2922         (WebCore::RoundedIntRect::Radii::bottomLeft):
2923         (WebCore::RoundedIntRect::Radii::bottomRight):
2924         (WebCore::RoundedIntRect::Radii::expand):
2925         (WebCore::RoundedIntRect::Radii::shrink):
2926         (WebCore::RoundedIntRect::rect):
2927         (WebCore::RoundedIntRect::radii):
2928         (WebCore::RoundedIntRect::isRounded):
2929         (WebCore::RoundedIntRect::isEmpty):
2930         (WebCore::RoundedIntRect::setRect):
2931         (WebCore::RoundedIntRect::setRadii):
2932         (WebCore::RoundedIntRect::move):
2933         (WebCore::RoundedIntRect::inflate):
2934         (WebCore::RoundedIntRect::inflateWithRadii):
2935         (WebCore::RoundedIntRect::expandRadii):
2936         (WebCore::RoundedIntRect::shrinkRadii):
2937         * rendering/RenderBox.cpp:
2938         (WebCore::RenderBox::pushContentsClip):
2939         * rendering/RenderBoxModelObject.cpp:
2940         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2941         (WebCore::RenderBoxModelObject::paintBorder):
2942         (WebCore::RenderBoxModelObject::clipBorderSidePolygon):
2943         (WebCore::RenderBoxModelObject::paintBoxShadow):
2944         * rendering/RenderBoxModelObject.h:
2945         * rendering/RenderObject.cpp:
2946         (WebCore::RenderObject::drawBoxSideFromPath):
2947         * rendering/RenderReplaced.cpp:
2948         (WebCore::RenderReplaced::paint):
2949         * rendering/RenderThemeChromiumWin.cpp:
2950         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
2951         * rendering/RenderThemeMac.mm:
2952         (WebCore::RenderThemeMac::paintMenuListButtonGradients):
2953         (WebCore::RenderThemeMac::paintSliderTrack):
2954         * rendering/RenderThemeSafari.cpp:
2955         (WebCore::RenderThemeSafari::paintMenuListButtonGradients):
2956         (WebCore::RenderThemeSafari::paintSliderTrack):
2957         * rendering/RenderThemeWinCE.cpp:
2958         (WebCore::RenderThemeWinCE::paintSearchFieldCancelButton):
2959         * rendering/RenderWidget.cpp:
2960         (WebCore::RenderWidget::paint):
2961         * rendering/style/BorderData.h:
2962         * rendering/style/RenderStyle.cpp:
2963         (WebCore::calcRadiiFor):
2964         (WebCore::calcConstraintScaleFor):
2965         (WebCore::RenderStyle::getRoundedBorderFor):
2966         (WebCore::RenderStyle::getRoundedInnerBorderWithBorderWidths):
2967         * rendering/style/RenderStyle.h:
2968         (WebCore::InheritedFlags::setBorderRadius):
2969
2970 2011-01-18  MORITA Hajime  <morrita@google.com>
2971
2972         Reviewed by Simon Fraser.
2973
2974         Refactoring: Extract RoundedIntRect class
2975         https://bugs.webkit.org/show_bug.cgi?id=51664
2976
2977         RoundedIntRect is a pair of rect and four IntSize objects which represent
2978         corner radii of the rectangle. IntSize is grouped into RoundedIntRect::Radii.
2979         Now RenderStyle::getRoundedBorderFor() and RenderStyle::getRoundedInnerBorderWithBorderWidths()
2980         return RoundedIntRect and GraphicsContext::addRoundedRectClip(), GraphicsContext::fillRoundedRect()
2981         and other functions accept RoundedIntRect as an argument.
2982
2983         No new tests. No behavioral change.
2984
2985         * Android.mk:
2986         * CMakeLists.txt:
2987         * WebCore.gypi:
2988         * WebCore.pro:
2989         * WebCore.xcodeproj/project.pbxproj:
2990         * platform/graphics/GraphicsContext.cpp:
2991         (WebCore::GraphicsContext::addRoundedRectClip):
2992         (WebCore::GraphicsContext::clipOutRoundedRect):
2993         (WebCore::GraphicsContext::fillRoundedRect):
2994         * platform/graphics/GraphicsContext.h:
2995         * platform/graphics/RoundedIntRect.cpp: Added.
2996         (WebCore::RoundedIntRect::Radii::isZero):
2997         (WebCore::RoundedIntRect::Radii::scale):
2998         (WebCore::RoundedIntRect::Radii::expand):
2999         (WebCore::RoundedIntRect::Radii::includeLogicalEdges):
3000         (WebCore::RoundedIntRect::Radii::excludeLogicalEdges):
3001         (WebCore::RoundedIntRect::RoundedIntRect):
3002         (WebCore::RoundedIntRect::includeLogicalEdges):
3003         (WebCore::RoundedIntRect::excludeLogicalEdges):
3004         * platform/graphics/RoundedIntRect.h: Added.
3005         (WebCore::RoundedIntRect::Radii::Radii):
3006         (WebCore::RoundedIntRect::Radii::setTopLeft):
3007         (WebCore::RoundedIntRect::Radii::setTopRight):
3008         (WebCore::RoundedIntRect::Radii::setBottomLeft):
3009         (WebCore::RoundedIntRect::Radii::setBottomRight):
3010         (WebCore::RoundedIntRect::Radii::topLeft):
3011         (WebCore::RoundedIntRect::Radii::topRight):
3012         (WebCore::RoundedIntRect::Radii::bottomLeft):
3013         (WebCore::RoundedIntRect::Radii::bottomRight):
3014         (WebCore::RoundedIntRect::Radii::expand):
3015         (WebCore::RoundedIntRect::Radii::shrink):
3016         (WebCore::RoundedIntRect::rect):
3017         (WebCore::RoundedIntRect::radii):
3018         (WebCore::RoundedIntRect::isRounded):
3019         (WebCore::RoundedIntRect::isEmpty):
3020         (WebCore::RoundedIntRect::setRect):
3021         (WebCore::RoundedIntRect::setRadii):
3022         (WebCore::RoundedIntRect::move):
3023         (WebCore::RoundedIntRect::inflate):
3024         (WebCore::RoundedIntRect::inflateWithRadii):
3025         (WebCore::RoundedIntRect::expandRadii):
3026         (WebCore::RoundedIntRect::shrinkRadii):
3027         * rendering/RenderBox.cpp:
3028         (WebCore::RenderBox::pushContentsClip):
3029         * rendering/RenderBoxModelObject.cpp:
3030         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
3031         (WebCore::RenderBoxModelObject::paintBorder):
3032         (WebCore::RenderBoxModelObject::clipBorderSidePolygon):
3033         (WebCore::RenderBoxModelObject::paintBoxShadow):
3034         * rendering/RenderBoxModelObject.h:
3035         * rendering/RenderObject.cpp:
3036         (WebCore::RenderObject::drawBoxSideFromPath):
3037         * rendering/RenderReplaced.cpp:
3038         (WebCore::RenderReplaced::paint):
3039         * rendering/RenderThemeChromiumWin.cpp:
3040         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
3041         * rendering/RenderThemeMac.mm:
3042         (WebCore::RenderThemeMac::paintMenuListButtonGradients):
3043         (WebCore::RenderThemeMac::paintSliderTrack):
3044         * rendering/RenderThemeSafari.cpp:
3045         (WebCore::RenderThemeSafari::paintMenuListButtonGradients):
3046         (WebCore::RenderThemeSafari::paintSliderTrack):
3047         * rendering/RenderThemeWinCE.cpp:
3048         (WebCore::RenderThemeWinCE::paintSearchFieldCancelButton):
3049         * rendering/RenderWidget.cpp:
3050         (WebCore::RenderWidget::paint):
3051         * rendering/style/BorderData.h:
3052         * rendering/style/RenderStyle.cpp:
3053         (WebCore::calcRadiiFor):
3054         (WebCore::calcConstraintScaleFor):
3055         (WebCore::RenderStyle::getRoundedBorderFor):
3056         (WebCore::RenderStyle::getRoundedInnerBorderWithBorderWidths):
3057         * rendering/style/RenderStyle.h:
3058         (WebCore::InheritedFlags::setBorderRadius):
3059
3060 2011-01-18  Victoria Kirst  <vrk@chromium.org>
3061
3062         Reviewed by Kenneth Russell.
3063
3064         [chromium] Adding support for YV16 video frame formats.
3065         https://bugs.webkit.org/show_bug.cgi?id=52345
3066
3067         * platform/graphics/chromium/VideoLayerChromium.cpp:
3068         (WebCore::VideoLayerChromium::determineTextureFormat):
3069         (WebCore::VideoLayerChromium::draw):
3070
3071 2011-01-18  David Hyatt  <hyatt@apple.com>
3072
3073         Reviewed by Dan Bernstein.
3074
3075         <rdar://problem/8479998> REGRESSION (r67660): broken button layout at devforums.apple.com
3076         
3077         Exclude floating objects from shrinking to avoid floats.  They should never do this.  Timing-related bugs could
3078         occur as a result of this mistake, and the change to rewrite pagination to defer layout of floats until they
3079         got encountered on the correct line exposed this issue.
3080
3081         Added /fast/block/float/float-overflow-hidden-containing-block-width.html.
3082
3083         * rendering/RenderBox.cpp:
3084         (WebCore::RenderBox::shrinkToAvoidFloats):
3085
3086 2011-01-18  Zhenyao Mo  <zmo@google.com>
3087
3088         Reviewed by Kenneth Russell.
3089
3090         Make CheckedInt<long> and CheckedInt<unsigned long> work
3091         https://bugs.webkit.org/show_bug.cgi?id=52401
3092
3093         * html/canvas/CheckedInt.h:
3094         (WebCore::CheckedInt::CheckedInt): Merge with the patch provided by Benoit Jacob.
3095         * html/canvas/WebGLBuffer.cpp:
3096         (WebCore::WebGLBuffer::associateBufferDataImpl): Use CheckedInt<long> instead of CheckedInt<int>.
3097         (WebCore::WebGLBuffer::associateBufferSubDataImpl): Ditto.
3098
3099 2011-01-18  Kenneth Russell  <kbr@google.com>
3100
3101         Reviewed by David Levin.
3102
3103         Must strip comments from WebGL shaders before enforcing character set
3104         https://bugs.webkit.org/show_bug.cgi?id=52390
3105
3106         Strip comments from incoming shaders, preserving line numbers,
3107         before validating that they conform to the ESSL character set.
3108         Revert changes from http://trac.webkit.org/changeset/75735 which
3109         allowed invalid characters to be passed to certain APIs.
3110
3111         Tested with WebGL layout tests, conformance test suite and several
3112         WebGL demos in both Safari and Chromium.
3113
3114         * html/canvas/WebGLRenderingContext.cpp:
3115         (WebCore::StripComments::StripComments::process):
3116         (WebCore::WebGLRenderingContext::shaderSource):
3117
3118 2011-01-18  Ryosuke Niwa  <rniwa@webkit.org>
3119
3120         Reviewed by Eric Seidel.
3121
3122         Stop instantiating legacy editing positions in DeleteSelectionCommand, IndentOudentCommand,
3123         InsertLineBreakCommand, InsertListCOmmand.cpp, InsertParagraphSeparatorCommand, and htmlediting.cpp
3124         https://bugs.webkit.org/show_bug.cgi?id=52644
3125
3126         This is a cleanup to stop instantiating legacy editing positions in the following tests.
3127         firstDeepEditingPositionForNode and lastDeepEditingPositionForNode in htmlediting.h are not updated
3128         because doing so requires significant code changes. They are tracked on the bug 52642.
3129
3130         * editing/DeleteSelectionCommand.cpp:
3131         (WebCore::DeleteSelectionCommand::initializeStartEnd):
3132         (WebCore::updatePositionForNodeRemoval):
3133         (WebCore::DeleteSelectionCommand::removeNode):
3134         (WebCore::updatePositionForTextRemoval):
3135         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
3136         * editing/IndentOutdentCommand.cpp:
3137         (WebCore::IndentOutdentCommand::outdentParagraph):
3138         * editing/InsertLineBreakCommand.cpp:
3139         (WebCore::InsertLineBreakCommand::doApply):
3140         * editing/InsertListCommand.cpp:
3141         (WebCore::InsertListCommand::doApplyForSingleParagraph):
3142         (WebCore::InsertListCommand::unlistifyParagraph):
3143         (WebCore::InsertListCommand::listifyParagraph):
3144         * editing/InsertParagraphSeparatorCommand.cpp:
3145         (WebCore::InsertParagraphSeparatorCommand::doApply):
3146         * editing/htmlediting.cpp:
3147         (WebCore::enclosingBlock):
3148         (WebCore::enclosingList):
3149         (WebCore::enclosingListChild):
3150         (WebCore::indexForVisiblePosition):
3151         (WebCore::isNodeVisiblyContainedWithin):
3152         (WebCore::avoidIntersectionWithNode):
3153
3154 2011-01-18  Benjamin Kalman  <kalman@chromium.org>
3155
3156         Reviewed by Ryosuke Niwa.
3157
3158         Tweak style in visible_units.cpp and TextIterator.cpp in preparation for another patch
3159         https://bugs.webkit.org/show_bug.cgi?id=52610
3160
3161         This is a purely aesthetic change.
3162
3163         * editing/TextIterator.cpp:
3164         (WebCore::SimplifiedBackwardsTextIterator::advance):
3165         * editing/visible_units.cpp:
3166         (WebCore::previousBoundary):
3167
3168 2011-01-18  Adam Klein  <adamk@chromium.org>
3169
3170         Reviewed by Darin Fisher.
3171
3172         [Chromium] Replace ChromiumBridge::widgetSetCursor with ChromeClient::setCursor
3173         https://bugs.webkit.org/show_bug.cgi?id=42236
3174
3175         * platform/chromium/ChromiumBridge.h:
3176         * platform/chromium/WidgetChromium.cpp:
3177         (WebCore::Widget::setCursor):
3178
3179 2011-01-18  Chris Fleizach  <cfleizach@apple.com>
3180
3181         Reviewed by Darin Adler.
3182
3183         REGRESSION: A problem with Voiceover and finding links
3184         https://bugs.webkit.org/show_bug.cgi?id=52324
3185
3186         Fallout from recent change to make WebCore return its own scroll view.
3187            1) There were two scroll views in the hierarchy, one which no needed to be ignored.
3188            2) Hit tests for sub frames needed to be offset.
3189            3) The check for whether an attachment is ignored must happen earlier than using
3190               the helpText to determine if an element should be ignored.
3191
3192         Test: platform/mac/accessibility/iframe-with-title-correct-hierarchy.html
3193
3194         * accessibility/AccessibilityObject.cpp:
3195         (WebCore::AccessibilityObject::elementAccessibilityHitTest):
3196         * accessibility/AccessibilityRenderObject.cpp:
3197         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
3198         * accessibility/mac/AccessibilityObjectWrapper.mm:
3199         (-[AccessibilityObjectWrapper scrollViewParent]):
3200
3201 2011-01-18  Adam Roben  <aroben@apple.com>
3202
3203         Call alternate CFHTTPCookie functions if available
3204
3205         Fixes <http://webkit.org/b/52637> <rdar://problem/8878984>.
3206
3207         Reviewed by Darin Adler.
3208
3209         * platform/network/cf/CookieJarCFNet.cpp: Added soft-linking macros to
3210         pull in the alternate CFHTTPCookie functions.
3211
3212         (WebCore::cookieDomain):
3213         (WebCore::cookieExpirationTime):
3214         (WebCore::cookieName):
3215         (WebCore::cookiePath):
3216         (WebCore::cookieValue):
3217         Added these wrappers around the CFHTTPCookie functions. We call the
3218         alternate functions if they exist, otherwise fall back to the current
3219         functions.
3220
3221         (WebCore::filterCookies):
3222         (WebCore::getRawCookies):
3223         (WebCore::deleteCookie):
3224         Changed to use the wrapper functions.
3225
3226 2011-01-18  Martin Robinson  <mrobinson@igalia.com>
3227
3228         Reviewed by Eric Seidel.
3229
3230         [GTK] Filenames are converted to URLs during edit drags
3231         https://bugs.webkit.org/show_bug.cgi?id=52096
3232
3233         * platform/gtk/DragDataGtk.cpp: Only advertise and deliver filenames as URLs if the
3234         conversion policy allows it.
3235         (WebCore::DragData::containsURL): Ditto.
3236         (WebCore::DragData::asURL): Ditto.
3237
3238 2011-01-18  Helder Correia  <helder@sencha.com>
3239
3240         Reviewed by Kenneth Rohde Christiansen.
3241
3242         [Qt] Incorrect shadow alpha with semi-transparent solid fillStyle
3243         https://bugs.webkit.org/show_bug.cgi?id=52611
3244
3245         This is related to bug 52559. The shadow color alpha must be multiplied
3246         by the context brush alpha.
3247
3248         Test: fast/canvas/canvas-fillPath-alpha-shadow.html
3249
3250         * platform/graphics/qt/GraphicsContextQt.cpp:
3251         (WebCore::GraphicsContext::fillPath):
3252
3253 2011-01-18  Andrey Kosyakov  <caseq@chromium.org>
3254
3255         Reviewed by Yury Semikhatsky.
3256
3257         Web Inspector: fail resource.requestContent() immediately for WebSocket resources
3258         https://bugs.webkit.org/show_bug.cgi?id=52628
3259
3260         * English.lproj/localizedStrings.js: Rename WebSocket -> WebSockets in resource catetegories (rest are in plural, too)
3261         * inspector/front-end/ExtensionServer.js: Do not expose webInspector.resources.Types in extensions API (obsolete)
3262         (WebInspector.ExtensionServer.prototype._buildExtensionAPIInjectedScript):
3263         * inspector/front-end/Resource.js:
3264         (WebInspector.Resource.Type.toUIString): Remove ResourceType.Media as it's not used.
3265         (WebInspector.Resource.Type.toString): ditto.
3266         (WebInspector.Resource.prototype.requestContent): Fail immediately for WebSocket resources.
3267         * inspector/front-end/inspector.js: Rename WebSocket -> WebSockets in resource catetegories (rest are in plural, too)
3268
3269 2011-01-18  Helder Correia  <helder@sencha.com>
3270
3271         Reviewed by Dirk Schulze.
3272
3273         REGRESSION(75139): SVG gradients are not applied to texts
3274         https://bugs.webkit.org/show_bug.cgi?id=52531
3275
3276         r75139 caused a problem with filling and stroking text with a gradient
3277         fill in SVG. The order of CGContextConcatCTM and CGContextClipToRect
3278         was mixed up.
3279
3280         Test: svg/css/text-gradient-shadow.svg
3281
3282         * platform/graphics/cg/GraphicsContextCG.cpp:
3283         (WebCore::GraphicsContext::fillRect):
3284
3285 2011-01-18  Leo Yang  <leo.yang@torchmobile.com.cn>
3286
3287         Reviewed by Nikolas Zimmermann.
3288
3289         Unable to indirectly animate visibility of SVGUseElement
3290         https://bugs.webkit.org/show_bug.cgi?id=50240
3291
3292         SVGUseElement::recalcStyle should take care of its shadow
3293         tree's style recalculation when it is called with change >= Inherit
3294         or when childNeedsStyleRecalc() is true because in these two
3295         cases needStyleRecalc() may not be true.
3296
3297         Test: svg/custom/use-inherit-style.svg
3298
3299         * svg/SVGUseElement.cpp:
3300         (WebCore::SVGUseElement::recalcStyle):
3301
3302 2011-01-18  Pavel Podivilov  <podivilov@chromium.org>
3303
3304         Reviewed by Yury Semikhatsky.
3305
3306         Web Inspector: provide script length to frontend.
3307         https://bugs.webkit.org/show_bug.cgi?id=52620
3308
3309         * inspector/Inspector.idl:
3310         * inspector/InspectorDebuggerAgent.cpp:
3311         (WebCore::InspectorDebuggerAgent::didParseSource):
3312         * inspector/front-end/DebuggerModel.js:
3313         (WebInspector.DebuggerModel.prototype._parsedScriptSource):
3314         (WebInspector.DebuggerDispatcher.prototype.parsedScriptSource):
3315         * inspector/front-end/Script.js:
3316         (WebInspector.Script):
3317
3318 2011-01-18  Zoltan Herczeg  <zherczeg@webkit.org>
3319
3320         Rubber-stamped by Csaba Osztrogonác
3321
3322         Fixing ChangeLog
3323
3324         Removing a line introduced by
3325         http://trac.webkit.org/changeset/75743/trunk/Source/WebCore/ChangeLog
3326         Removing an unnecessary space before a time stamp.
3327
3328 2011-01-17  Andrey Kosyakov  <caseq@chromium.org>
3329
3330         Reviewed by Yury Semikhatsky.
3331
3332         Web Inspector: [refactoring] use events to notify NetworkManager clients
3333         https://bugs.webkit.org/show_bug.cgi?id=52588
3334
3335         * inspector/front-end/AuditLauncherView.js:
3336         (WebInspector.AuditLauncherView): Do not expose public interface to resource count. Do not reset resource count upon reset().
3337         (WebInspector.AuditLauncherView.prototype._resetResourceCount):
3338         (WebInspector.AuditLauncherView.prototype._onResourceStarted):
3339         (WebInspector.AuditLauncherView.prototype._onResourceFinished):
3340         * inspector/front-end/AuditsPanel.js: Do not expose public interface to resource start/finish events.
3341         * inspector/front-end/ExtensionServer.js:
3342         (WebInspector.ExtensionServer):
3343         (WebInspector.ExtensionServer.prototype._notifyResourceFinished):
3344         (WebInspector.ExtensionServer.prototype.initExtensions):
3345         * inspector/front-end/NetworkManager.js: Dispatch events rather than directly call clients.
3346         (WebInspector.NetworkManager):
3347         (WebInspector.NetworkManager.prototype.willSendRequest):
3348         (WebInspector.NetworkManager.prototype.markResourceAsCached):
3349         (WebInspector.NetworkManager.prototype.didReceiveResponse):
3350         (WebInspector.NetworkManager.prototype.didReceiveContentLength):
3351         (WebInspector.NetworkManager.prototype.setInitialContent):
3352         (WebInspector.NetworkManager.prototype.didCommitLoadForFrame):
3353         (WebInspector.NetworkManager.prototype.willSendWebSocketHandshakeRequest):
3354         (WebInspector.NetworkManager.prototype.didReceiveWebSocketHandshakeResponse):
3355         (WebInspector.NetworkManager.prototype._startResource):
3356         (WebInspector.NetworkManager.prototype._finishResource):
3357         * inspector/front-end/NetworkPanel.js:
3358         (WebInspector.NetworkPanel):
3359         (WebInspector.NetworkPanel.prototype._onResourceStarted):
3360         (WebInspector.NetworkPanel.prototype._appendResource):
3361         (WebInspector.NetworkPanel.prototype._onResourceUpdated):
3362         (WebInspector.NetworkPanel.prototype._refreshResource):
3363         (WebInspector.NetworkPanel.prototype._onMainResourceChanged):
3364         * inspector/front-end/ResourcesPanel.js:
3365         (WebInspector.ResourcesPanel):
3366         (WebInspector.ResourcesPanel.prototype._refreshResource):
3367
3368 2011-01-18  Pavel Feldman  <pfeldman@chromium.org>
3369
3370         Reviewed by Yury Semikhatsky.
3371
3372         Web Inspector: preserve pause on exception state in settings.
3373         https://bugs.webkit.org/show_bug.cgi?id=52619
3374
3375         * inspector/InspectorController.cpp:
3376         (WebCore::InspectorController::getInspectorState):
3377         * inspector/InspectorDebuggerAgent.cpp:
3378         (WebCore::InspectorDebuggerAgent::setPauseOnExceptionsState):
3379         * inspector/InspectorDebuggerAgent.h:
3380         * inspector/front-end/ScriptsPanel.js:
3381         (WebInspector.ScriptsPanel):
3382         (WebInspector.ScriptsPanel.prototype.debuggerWasEnabled):
3383         (WebInspector.ScriptsPanel.prototype._updatePauseOnExceptionsState):
3384         (WebInspector.ScriptsPanel.prototype._togglePauseOnExceptions):
3385         (WebInspector.ScriptsPanel.prototype._setPauseOnExceptions):
3386         * inspector/front-end/Settings.js:
3387         (WebInspector.Settings):
3388         * inspector/front-end/inspector.js:
3389         (WebInspector.doLoadedDone.populateInspectorState):
3390
3391 2011-01-18  Pavel Podivilov  <podivilov@chromium.org>
3392
3393         Reviewed by Yury Semikhatsky.
3394
3395         Web Inspector: [REGRESSION] JavaScript exceptions aren't shown in source frame.
3396         https://bugs.webkit.org/show_bug.cgi?id=52623
3397
3398         * inspector/front-end/ConsoleView.js:
3399         (WebInspector.ConsoleMessage):
3400         (WebInspector.ConsoleMessage.prototype._formatMessage):
3401
3402 2011-01-18  Pavel Feldman  <pfeldman@chromium.org>
3403
3404         Revert r76017. No need to guard InspectorInstrumentation:: in WebCore.
3405
3406         * page/Page.cpp:
3407         (WebCore::networkStateChanged):
3408
3409 2011-01-18  Konstantin Tokarev  <annulen@yandex.ru>
3410
3411         Reviewed by Kent Tamura.
3412
3413         Fixed compilation when Inspector is disabled
3414         https://bugs.webkit.org/show_bug.cgi?id=52564
3415
3416         * page/Page.cpp:
3417         (WebCore::networkStateChanged): Added ENABLE(INSPECTOR) guard
3418
3419 2011-01-18  MORITA Hajime  <morrita@google.com>
3420
3421         Unreviewed, rolling out r76004, r76005, r76007, and r76011.
3422         http://trac.webkit.org/changeset/76004
3423         http://trac.webkit.org/changeset/76005
3424         http://trac.webkit.org/changeset/76007
3425         http://trac.webkit.org/changeset/76011
3426         https://bugs.webkit.org/show_bug.cgi?id=51664
3427
3428         The r76004 broke pixel tests.
3429         (The failure was missed due to the tolerance.)
3430
3431         * Android.mk:
3432         * CMakeLists.txt:
3433         * GNUmakefile.am:
3434         * WebCore.gypi:
3435         * WebCore.pro:
3436         * WebCore.vcproj/WebCore.vcproj:
3437         * WebCore.xcodeproj/project.pbxproj:
3438         * platform/graphics/GraphicsContext.cpp:
3439         (WebCore::GraphicsContext::addRoundedRectClip):
3440         (WebCore::GraphicsContext::clipOutRoundedRect):
3441         * platform/graphics/GraphicsContext.h:
3442         * platform/graphics/RoundedIntRect.cpp: Removed.