2011-01-21 Chris Rogers <crogers@google.com>
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-01-21  Chris Rogers  <crogers@google.com>
2
3         Reviewed by Kenneth Russell.
4
5         Fix audio build: change ChromiumBridge to PlatformBridge
6         https://bugs.webkit.org/show_bug.cgi?id=52928
7
8         No new tests since audio API is not yet implemented.
9
10         * platform/audio/chromium/AudioBusChromium.cpp:
11         (WebCore::AudioBus::loadPlatformResource):
12
13 2011-01-21  Chris Rogers  <crogers@google.com>
14
15         Reviewed by Kenneth Russell.
16
17         Add FFTFrameStub to avoid link errors during bringup on platforms without an FFT implementation
18         https://bugs.webkit.org/show_bug.cgi?id=52922
19
20         No new tests since audio API is not yet implemented.
21
22         * WebCore.gypi:
23         * platform/audio/FFTFrameStub.cpp: Added.
24         (WebCore::FFTFrame::FFTFrame):
25         (WebCore::FFTFrame::~FFTFrame):
26         (WebCore::FFTFrame::multiply):
27         (WebCore::FFTFrame::doFFT):
28         (WebCore::FFTFrame::doInverseFFT):
29         (WebCore::FFTFrame::cleanup):
30         (WebCore::FFTFrame::realData):
31         (WebCore::FFTFrame::imagData):
32
33 2011-01-21  Tony Chang  <tony@chromium.org>
34
35         Reviewed by Sam Weinig.
36
37         reduce number of FrameLoaderClient::didChangeScrollOffset calls
38         https://bugs.webkit.org/show_bug.cgi?id=52915
39
40         Only notify of changes in scroll offset when there actually is a change.
41         This regressed in r76291.
42
43         Covered by Chromium browser_tests.
44
45         * platform/ScrollAnimator.cpp:
46         (WebCore::ScrollAnimator::scrollToOffsetWithoutAnimation):
47
48 2011-01-21  Pavel Feldman  <pfeldman@chromium.org>
49
50         Reviewed by Yury Semikhatsky.
51
52         Web Inspector: ~InspectorResourceAgent crashes on closing inspected page.
53         https://bugs.webkit.org/show_bug.cgi?id=52900
54
55         * inspector/InspectorController.cpp:
56         (WebCore::InspectorController::~InspectorController):
57         (WebCore::InspectorController::inspectedPageDestroyed):
58
59 2011-01-21  Chris Rogers  <crogers@google.com>
60
61         Reviewed by Darin Fisher.
62
63         Add run-time enable support for the web audio API
64         https://bugs.webkit.org/show_bug.cgi?id=52741
65
66         No new tests since audio API is not yet implemented.
67
68         * WebCore.exp.in:
69         * bindings/generic/RuntimeEnabledFeatures.cpp:
70         * bindings/generic/RuntimeEnabledFeatures.h:
71         (WebCore::RuntimeEnabledFeatures::setWebkitAudioContextEnabled):
72         (WebCore::RuntimeEnabledFeatures::webkitAudioContextEnabled):
73         * page/DOMWindow.idl:
74         * page/Settings.cpp:
75         (WebCore::Settings::Settings):
76         (WebCore::Settings::setWebAudioEnabled):
77         * page/Settings.h:
78         (WebCore::Settings::webAudioEnabled):
79
80 2011-01-21  Martin Robinson  <mrobinson@igalia.com>
81
82         Reviewed by Xan Lopez.
83
84         [GTK] Menulist text often collides with separator
85         https://bugs.webkit.org/show_bug.cgi?id=51155
86
87         Move menulist rendering to RenderThemeGtk and correct padding code
88         for separators in menulists.
89
90         * platform/gtk/RenderThemeGtk.cpp:
91         (WebCore::RenderThemeGtk::RenderThemeGtk): Initialize new widget members.
92         (WebCore::RenderThemeGtk::getComboBoxSeparatorWidth): Added.
93         (WebCore::RenderThemeGtk::comboBoxArrowSize): Added.
94         (WebCore::getButtonInnerBorder): Added.
95         (WebCore::RenderThemeGtk::getComboBoxPadding): Do this manually instead of using
96         Mozilla code.
97         (WebCore::RenderThemeGtk::paintMenuList): Ditto.
98         (WebCore::setupWidget): Abstracted this part of the setupWidgetAndAddToContainer
99         out to handle child widgets of comboboxes.
100         (WebCore::RenderThemeGtk::setupWidgetAndAddToContainer): Abstracted out setupWidget.
101         (WebCore::RenderThemeGtk::gtkContainer): Added.
102         (WebCore::getGtkComboBoxButton): Added.
103         (WebCore::getGtkComboBoxPieces): Added.
104         (WebCore::RenderThemeGtk::gtkComboBox): Call setupWidget here.
105         (WebCore::RenderThemeGtk::refreshComboBoxChildren): Added.
106         (WebCore::RenderThemeGtk::gtkComboBoxButton): Added.
107         (WebCore::RenderThemeGtk::gtkComboBoxArrow): Added.
108         (WebCore::RenderThemeGtk::gtkComboBoxSeparator): Added.
109         * platform/gtk/RenderThemeGtk.h: Added new members and methods.
110         * platform/gtk/WidgetRenderingContext.h: Added new members and methods.
111         * platform/gtk/WidgetRenderingContextGtk2.cpp:
112         (WebCore::WidgetRenderingContext::gtkPaintArrow):
113         (WebCore::WidgetRenderingContext::gtkPaintVLine):
114         * platform/gtk/WidgetRenderingContextGtk3.cpp:
115         (WebCore::WidgetRenderingContext::gtkPaintArrow):
116         (WebCore::WidgetRenderingContext::gtkPaintVLine):
117         * platform/gtk/gtk2drawing.c: Removed code for drawing menulists and buttons.
118         (moz_gtk_init):
119         (moz_gtk_get_widget_border):
120         (moz_gtk_widget_paint):
121         * platform/gtk/gtk3drawing.c:
122         (moz_gtk_init):
123         (moz_gtk_get_widget_border):
124         (moz_gtk_widget_paint):
125         * platform/gtk/gtkdrawing.h:
126
127 2011-01-21  Sam Weinig  <sam@webkit.org>
128
129         Fix chromium mac build.
130
131         * platform/chromium/ScrollbarThemeChromiumMac.mm:
132         (WebCore::scrollbarStateToThemeState):
133         (WebCore::ScrollbarThemeChromiumMac::paint):
134
135 2011-01-21  Sam Weinig  <sam@webkit.org>
136
137         Fix the windows build.
138
139         * platform/ScrollbarThemeComposite.cpp:
140         (WebCore::ScrollbarThemeComposite::paint):
141
142 2011-01-21  Chris Rogers  <crogers@google.com>
143
144         Reviewed by Kenneth Russell.
145
146         Add chromium bundled audio spatialization resources to WebAudio.grd
147         https://bugs.webkit.org/show_bug.cgi?id=52651
148
149         No new tests since audio API is not yet implemented.
150
151         * WebCore.gyp/WebCore.gyp:
152         * platform/audio/chromium/AudioBusChromium.cpp:
153         (WebCore::AudioBus::loadPlatformResource):
154
155 2011-01-21  Xiyuan Xia  <xiyuan@chromium.org>
156
157         Reviewed by Tony Chang.
158
159         Use WebThemeEngine for relevant RenderTheme parts for chromium/linux.
160         https://bugs.webkit.org/show_bug.cgi?id=52826
161
162         * platform/chromium/ChromiumBridge.h:
163         * rendering/RenderThemeChromiumLinux.cpp:
164         (WebCore::getWebThemeState):
165         (WebCore::RenderThemeChromiumLinux::adjustSliderThumbSize):
166         (WebCore::RenderThemeChromiumLinux::paintCheckbox):
167         (WebCore::RenderThemeChromiumLinux::setCheckboxSize):
168         (WebCore::RenderThemeChromiumLinux::paintRadio):
169         (WebCore::RenderThemeChromiumLinux::setRadioSize):
170         (WebCore::RenderThemeChromiumLinux::paintButton):
171         (WebCore::RenderThemeChromiumLinux::paintTextField):
172         (WebCore::RenderThemeChromiumLinux::paintMenuList):
173         (WebCore::RenderThemeChromiumLinux::paintSliderTrack):
174         (WebCore::RenderThemeChromiumLinux::paintSliderThumb):
175         (WebCore::RenderThemeChromiumLinux::adjustInnerSpinButtonStyle):
176         (WebCore::RenderThemeChromiumLinux::paintInnerSpinButton):
177         (WebCore::RenderThemeChromiumLinux::paintProgressBar):
178         * rendering/RenderThemeChromiumLinux.h:
179         * rendering/RenderThemeChromiumSkia.cpp:
180         (WebCore::RenderThemeChromiumSkia::setCheckboxSize):
181         (WebCore::RenderThemeChromiumSkia::setSizeIfAuto):
182         (WebCore::RenderThemeChromiumSkia::indeterminateProgressValueRectFor):
183         * rendering/RenderThemeChromiumSkia.h:
184
185 2011-01-21  Sam Weinig  <sam@webkit.org>
186
187         Reviewed by Anders Carlsson.
188
189         Part 2 of "Cleanup Scrollbar/ScrollbarClient relationship"
190         https://bugs.webkit.org/show_bug.cgi?id=52779
191
192         Rename ScrollbarClient -> ScrollableArea.
193
194         - Also replaces Scrollbar::setClient with Scrollbar::disconnectFromScrollableArea
195           since that was its only use case.
196
197         * CMakeLists.txt:
198         * GNUmakefile.am:
199         * WebCore.gypi:
200         * WebCore.pro:
201         * WebCore.vcproj/WebCore.vcproj:
202         * WebCore.xcodeproj/project.pbxproj:
203         * accessibility/AccessibilityScrollbar.cpp:
204         (WebCore::AccessibilityScrollbar::setValue):
205         * css/CSSStyleSelector.cpp:
206         (WebCore::CSSStyleSelector::SelectorChecker::checkScrollbarPseudoClass):
207         * page/FrameView.h:
208         * platform/PopupMenuClient.h:
209         * platform/ScrollAnimator.cpp:
210         (WebCore::ScrollAnimator::create):
211         (WebCore::ScrollAnimator::ScrollAnimator):
212         (WebCore::ScrollAnimator::scroll):
213         (WebCore::ScrollAnimator::notityPositionChanged):
214         * platform/ScrollAnimator.h:
215         * platform/ScrollAnimatorWin.cpp:
216         (WebCore::ScrollAnimator::create):
217         (WebCore::ScrollAnimatorWin::ScrollAnimatorWin):
218         (WebCore::ScrollAnimatorWin::scroll):
219         * platform/ScrollAnimatorWin.h:
220         * platform/ScrollView.cpp:
221         (WebCore::ScrollView::scroll):
222         (WebCore::ScrollView::updateScrollbars):
223         (WebCore::ScrollView::wheelEvent):
224         * platform/ScrollView.h:
225         * platform/ScrollableArea.cpp: Copied from WebCore/platform/ScrollbarClient.cpp.
226         (WebCore::ScrollableArea::ScrollableArea):
227         (WebCore::ScrollableArea::~ScrollableArea):
228         (WebCore::ScrollableArea::scroll):
229         (WebCore::ScrollableArea::scrollToOffsetWithoutAnimation):
230         (WebCore::ScrollableArea::scrollToXOffsetWithoutAnimation):
231         (WebCore::ScrollableArea::scrollToYOffsetWithoutAnimation):
232         (WebCore::ScrollableArea::setScrollOffsetFromAnimation):
233         * platform/ScrollableArea.h: Copied from WebCore/platform/ScrollbarClient.h.
234         * platform/Scrollbar.cpp:
235         (WebCore::Scrollbar::createNativeScrollbar):
236         (WebCore::Scrollbar::Scrollbar):
237         (WebCore::Scrollbar::offsetDidChange):
238         (WebCore::Scrollbar::autoscrollPressedPart):
239         (WebCore::Scrollbar::moveThumb):
240         (WebCore::Scrollbar::mouseMoved):
241         (WebCore::Scrollbar::isWindowActive):
242         (WebCore::Scrollbar::invalidateRect):
243         (WebCore::Scrollbar::convertToContainingView):
244         (WebCore::Scrollbar::convertFromContainingView):
245         * platform/Scrollbar.h:
246         (WebCore::Scrollbar::disconnectFromScrollableArea):
247         (WebCore::Scrollbar::scrollableArea):
248         * platform/ScrollbarClient.cpp: Removed.
249         * platform/ScrollbarClient.h: Removed.
250         * platform/ScrollbarThemeComposite.cpp:
251         * platform/chromium/FramelessScrollView.h:
252         * platform/chromium/ScrollbarThemeChromium.cpp:
253         (WebCore::ScrollbarThemeChromium::paintTickmarks):
254         * platform/efl/ScrollbarEfl.cpp:
255         (Scrollbar::createNativeScrollbar):
256         (ScrollbarEfl::ScrollbarEfl):
257         (scrollbarEflEdjeMessage):
258         * platform/efl/ScrollbarEfl.h:
259         * platform/gtk/MainFrameScrollbarGtk.cpp:
260         (MainFrameScrollbarGtk::create):
261         (MainFrameScrollbarGtk::MainFrameScrollbarGtk):
262         (MainFrameScrollbarGtk::gtkValueChanged):
263         * platform/gtk/MainFrameScrollbarGtk.h:
264         * platform/mac/ScrollAnimatorMac.h:
265         * platform/mac/ScrollAnimatorMac.mm:
266         (WebCore::ScrollAnimator::create):
267         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
268         (WebCore::ScrollAnimatorMac::scroll):
269         * platform/mac/ScrollbarThemeMac.mm:
270         (WebCore::ScrollbarThemeMac::paint):
271         * platform/qt/ScrollbarQt.cpp:
272         (WebCore::Scrollbar::contextMenu):
273         * platform/win/PopupMenuWin.cpp:
274         (WebCore::PopupMenuWin::scrollToRevealSelection):
275         (WebCore::PopupMenuWin::wndProc):
276         * platform/win/PopupMenuWin.h:
277         * platform/win/ScrollbarThemeSafari.cpp:
278         (WebCore::ScrollbarThemeSafari::paintTrackBackground):
279         (WebCore::ScrollbarThemeSafari::paintButton):
280         (WebCore::ScrollbarThemeSafari::paintThumb):
281         * platform/wx/ScrollbarThemeWx.cpp:
282         (WebCore::ScrollbarThemeWx::paint):
283         * rendering/RenderDataGrid.h:
284         * rendering/RenderLayer.cpp:
285         (WebCore::RenderLayer::scrollToOffset):
286         (WebCore::RenderLayer::destroyScrollbar):
287         (WebCore::RenderLayer::scroll):
288         * rendering/RenderLayer.h:
289         * rendering/RenderListBox.cpp:
290         (WebCore::RenderListBox::scrollToRevealElementAtListIndex):
291         (WebCore::RenderListBox::scroll):
292         (WebCore::RenderListBox::logicalScroll):
293         (WebCore::RenderListBox::setScrollTop):
294         (WebCore::RenderListBox::destroyScrollbar):
295         * rendering/RenderListBox.h:
296         * rendering/RenderMenuList.cpp:
297         (WebCore::RenderMenuList::createScrollbar):
298         * rendering/RenderMenuList.h:
299         * rendering/RenderScrollbar.cpp:
300         (WebCore::RenderScrollbar::createCustomScrollbar):
301         (WebCore::RenderScrollbar::RenderScrollbar):
302         * rendering/RenderScrollbar.h:
303         * rendering/RenderTextControlSingleLine.cpp:
304         (WebCore::RenderTextControlSingleLine::createScrollbar):
305         * rendering/RenderTextControlSingleLine.h:
306
307 2011-01-21  Darin Adler  <darin@apple.com>
308
309         Fix Leopard build.
310
311         * rendering/mathml/RenderMathMLFraction.cpp:
312         (WebCore::RenderMathMLFraction::layout): Use ceilf instead of ceil.
313
314 2011-01-21  Anton Muhin  <antonm@chromium.org>
315
316         Reviewed by Nate Chapin.
317
318         [v8] Properly deal with the case when conversion to string throws an exception for HTMLCollection accessors
319         https://bugs.webkit.org/show_bug.cgi?id=52901
320
321         Test: fast/dom/htmlcollection-conversion-throws-exception.html
322
323         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
324         (WebCore::getItem):
325
326 2011-01-21  Adam Roben  <aroben@apple.com>
327
328         Separate flushing layer changes from rendering in CACFLayerTreeHost
329
330         Old model:
331           1) A change is made to a GraphicsLayer.
332           2) CACFLayerTreeHost::flushPendingGraphicsLayerChangesSoon is called, which schedules the
333              render timer.
334           3) The timer fires, which calls through to CACFLayerTreeHost::render, which performs the
335              flush and then renders.
336
337         New model:
338           1) A change is made to a GraphicsLayer.
339           2) CACFLayerTreeHost::flushPendingGraphicsLayerChangesSoon is called, which tells the new
340              LayerChangesFlusher singleton that this host has changes that need to be flushed.
341           3) LayerChangesFlusher sets up a Windows hook that will get called on the next iteration
342              of the message loop.
343           4) LayerChangesFlusher's hook is called, which calls through to
344              CACFLayerTreeHost::flushPendingLayerChangesNow.
345           5) CACFLayerTreeHost::flushPendingLayerChangesNow schedules the render timer so the changes
346              that were just flushed to the context will be rendered.
347
348         When a change is made to a PlatformCALayer that doesn't have a corresponding GraphicsLayer
349         (e.g., for rendering <video>), CACFLayerTreeHost::layerTreeDidChange takes care of
350         scheduling the flush.
351
352         This change has three advantages:
353           1) Whenever we flush layer changes, we first update layout. This can cause the page to
354              leave compositing mode, which in turn can cause all references to the CACFLayerTreeHost
355              to be dropped. By separating flushing (and thus updating layout) from rendering, we no
356              longer have to worry about this happen during rendering.
357           2) The new model is much more similar to how things work on the Mac, so will hopefully
358              reduce the number of platform-specific bugs.
359           3) CACFLayerTreeHost::shouldRender, which was used to make sure we didn't render while a
360              layout was pending, is no longer needed. It actually hasn't been needed since at least
361              r75987, but removing it before now would have resulted in a crash whenever a page came
362              out of compositing mode due to (1).
363
364         Fixes <http://webkit.org/b/52852> Flushing layer changes and rendering are intertwined in
365         CACFLayerTreeHost, but shouldn't be
366
367         Reviewed by Simon Fraser.
368
369         * WebCore.vcproj/WebCore.vcproj: Added LayerChangesFlusher.
370
371         * platform/graphics/ca/win/CACFLayerTreeHost.cpp: Added new #include, sorted existing
372         #includes.
373         (WebCore::CACFLayerTreeHost::CACFLayerTreeHost): Initialize new member.
374         (WebCore::CACFLayerTreeHost::layerTreeDidChange): If we aren't already flushing changes,
375         schedule a flush. Removed the call to renderSoon(), which now happens when the flush is
376         finished.
377         (WebCore::CACFLayerTreeHost::destroyRenderer): Cancel any pending flush we had scheduled. Also
378         fixed a bug where we'd fail to clear the context's layer.
379         (WebCore::CACFLayerTreeHost::render): Removed code to ask the client if we should render, which
380         is no longer needed. Moved code to flush layer changes from here to
381         flushPendingLayerChangesNow, which is called via the above-described mechanism.
382         (WebCore::CACFLayerTreeHost::flushPendingGraphicsLayerChangesSoon): Schedule a flush. Removed
383         code to schedule a render, which now happens after we've flushed.
384         (WebCore::CACFLayerTreeHost::flushPendingLayerChangesNow): Added. Some of this code came from
385         render(). First we flush GraphicsLayer changes from GraphicsLayers to their underlying
386         PlatformCALayers, then we flush changes from PlatformCALayers to the context, then we
387         schedule a render so that the changes will be rendered to the screen.
388
389         * platform/graphics/ca/win/CACFLayerTreeHost.h: Removed
390         CACFLayerTreeHostClient::shouldRender. Added flushPendingLayerChangesNow and
391         m_isFlushingLayerChanges.
392
393         * platform/graphics/ca/win/LayerChangesFlusher.cpp: Added.
394         (WebCore::LayerChangesFlusher::shared):
395         (WebCore::LayerChangesFlusher::LayerChangesFlusher):
396         (WebCore::LayerChangesFlusher::flushPendingLayerChangesSoon):
397         (WebCore::LayerChangesFlusher::cancelPendingFlush):
398         (WebCore::LayerChangesFlusher::hookCallback):
399         (WebCore::LayerChangesFlusher::hookFired):
400         (WebCore::LayerChangesFlusher::setHook):
401         (WebCore::LayerChangesFlusher::removeHook):
402
403         * platform/graphics/ca/win/LayerChangesFlusher.cpp: Added.
404         (WebCore::LayerChangesFlusher::shared): Returns the singleton.
405         (WebCore::LayerChangesFlusher::LayerChangesFlusher): Initialize our members.
406         (WebCore::LayerChangesFlusher::flushPendingLayerChangesSoon): Add the host to the set of
407         hosts with changes that need to be flushed, and set up our hook if we haven't already.
408         (WebCore::LayerChangesFlusher::cancelPendingFlush): Remove the host from the set of hosts
409         with changes that need to be flushed. If we have no more such hosts, remove our hook, unless
410         we're currently in the process of calling out to our hosts, in which case we'll take care of
411         the hook once we're done calling out.
412         (WebCore::LayerChangesFlusher::hookCallback): This is the function that Windows calls when
413         our hook fires. Just calls through to hookFired on the singleton.
414         (WebCore::LayerChangesFlusher::hookFired): Tell all the hosts with changes that needed to be
415         flushed that it's time to flush. If no hosts re-added themselves to our set during this
416         process, remove our hook.
417         (WebCore::LayerChangesFlusher::setHook): Calls through to ::SetWindowsHookExW.
418         (WebCore::LayerChangesFlusher::removeHook): Calls through to ::UnhookWindowsHookEx.
419
420         * platform/graphics/ca/win/LayerChangesFlusher.h: Added.
421
422 2011-01-21  Simon Fraser  <simon.fraser@apple.com>
423
424         Reviewed by Sam Weinig.
425
426         GraphicsLayer should be non-copyable
427         https://bugs.webkit.org/show_bug.cgi?id=52909
428
429         Use WTF_MAKE_NONCOPYABLE on GraphicsLayer, and WTF_MAKE_FAST_ALLOCATED
430         on that and KeyframeValueList.
431         
432         * platform/graphics/GraphicsLayer.h:
433
434 2011-01-21  Simon Fraser  <simon.fraser@apple.com>
435
436         Reviewed by Sam Weinig.
437
438         Report the sized used by canvases and types arrays
439         https://bugs.webkit.org/show_bug.cgi?id=52856
440
441         Report the memory cost associated with canvas elements,
442         and typed arrays to JavaScript as extraCost, so that it
443         can figure this into its GC behavior.
444
445         * bindings/js/JSArrayBufferViewHelper.h:
446         (WebCore::toJSArrayBufferView): New templatized function, similar
447         to getDOMObjectWrapper() but calls reportExtraMemoryCost() with
448         the byteLength of the array.
449         
450         * bindings/js/JSFloat32ArrayCustom.cpp:
451         (WebCore::toJS): Use toJSArrayBufferView.
452         * bindings/js/JSInt16ArrayCustom.cpp:
453         (WebCore::toJS): Use toJSArrayBufferView.
454         * bindings/js/JSInt32ArrayCustom.cpp:
455         (WebCore::toJS): Use toJSArrayBufferView.
456         * bindings/js/JSInt8ArrayCustom.cpp:
457         (WebCore::toJS): Use toJSArrayBufferView.
458         * bindings/js/JSUint16ArrayCustom.cpp:
459         (WebCore::toJS): Use toJSArrayBufferView.
460         * bindings/js/JSUint32ArrayCustom.cpp:
461         (WebCore::toJS): Use toJSArrayBufferView.
462         * bindings/js/JSUint8ArrayCustom.cpp:
463         (WebCore::toJS): Use toJSArrayBufferView.
464
465         * html/HTMLCanvasElement.cpp:
466         (WebCore::HTMLCanvasElement::createImageBuffer): Call heap.reportExtraMemoryCost()
467         with the size of the canvas backing store.
468         
469         * html/canvas/TypedArrayBase.h:
470         (WebCore::TypedArrayBase::byteLength): byteLength needs to
471         be public.
472         
473         * platform/graphics/ImageBuffer.h: Add dataSize() method.
474         
475         * platform/graphics/cairo/ImageBufferCairo.cpp:
476         (WebCore::ImageBuffer::dataSize): Implement dataSize().
477         * platform/graphics/cg/ImageBufferCG.cpp:
478         (WebCore::ImageBuffer::dataSize): Implement dataSize().
479         * platform/graphics/haiku/ImageBufferHaiku.cpp:
480         (WebCore::ImageBuffer::dataSize): Implement dataSize().
481         * platform/graphics/qt/ImageBufferQt.cpp:
482         (WebCore::ImageBuffer::dataSize): Implement dataSize().
483         * platform/graphics/skia/ImageBufferSkia.cpp:
484         (WebCore::ImageBuffer::dataSize): Implement dataSize().
485         * platform/graphics/wince/ImageBufferWinCE.cpp:
486         (WebCore::ImageBuffer::dataSize): Implement dataSize().
487         * platform/graphics/wx/ImageBufferWx.cpp:
488         (WebCore::ImageBuffer::dataSize): Implement dataSize().
489
490 2011-01-21  Adam Roben  <aroben@apple.com>
491
492         Rename WKCACFLayerRenderer[Client] to CACFLayerTreeHost[Client]
493
494         Also renamed a few functions and data members to match.
495
496         Fixes <http://webkit.org/b/52898> WKCACFLayerRenderer sounds like a render object, but isn't
497
498         Reviewed by Simon Fraser.
499
500         * WebCore.vcproj/WebCore.vcproj: Updated files' names and paths.
501
502         * WebCore.vcproj/WebCoreQuartzCore.vsprops: Added platform/graphics/ca/win to the include
503         path.
504
505         * WebCore.vcproj/copyForwardingHeaders.cmd: Copy headers from platform/graphics/ca/win, too.
506
507         * platform/graphics/ca/win/CACFLayerTreeHost.cpp: Renamed from Source/WebCore/platform/graphics/win/WKCACFLayerRenderer.cpp.
508         * platform/graphics/ca/win/CACFLayerTreeHost.h: Renamed from Source/WebCore/platform/graphics/win/WKCACFLayerRenderer.h.
509
510         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
511         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.cpp:
512         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h:
513         Updated for renames.
514
515 2011-01-21  Patrick Gansterer  <paroga@paroga.com>
516
517         Original patch from François Sausset  <sausset@gmail.com>
518
519         Reviewed by Darin Adler.
520
521         Code cleaning in rendering/mathml/RenderMathMLFraction.cpp
522         https://bugs.webkit.org/show_bug.cgi?id=52201
523
524         Replace unneeded doubles by floats and remove unneeded casts.
525
526         * rendering/mathml/RenderMathMLFraction.cpp:
527         (WebCore::RenderMathMLFraction::paint):
528         * rendering/mathml/RenderMathMLFraction.h:
529
530 2011-01-21  Dimitri Glazkov  <dglazkov@chromium.org>
531
532         Reviewed by Darin Adler.
533
534         REGRESSION(r73618): Clicking on a search input causes a crash.
535         https://bugs.webkit.org/show_bug.cgi?id=52905
536
537         The problem is caused by TextControlInnerElement being used both as
538         shadow root and an element in a shadow subtree. The code assumed it is
539         only used as a shadow root.
540
541         Since this code is all just workaround for in-progress conversion to
542         new shadow DOM, I am just adding a check. This code will disappear
543         completely once bug 52788 is fixed.
544
545         Test: fast/dom/search-shadow-host-crash.html
546
547         * dom/Node.cpp:
548         (WebCore::Node::setShadowHost): Added an ASSERT for early detection
549             of attempting to stomp on the parentNode.
550         * rendering/TextControlInnerElements.cpp:
551         (WebCore::TextControlInnerElement::detach): Added a check to only
552             clear shadow host if we have one.
553
554 2011-01-21  Adam Roben  <aroben@apple.com>
555
556         Replace some "sync compositing state" terminology with "flush pending GraphicsLayer changes"
557
558         This seems to be the direction in which our code is moving. I chose "GraphicsLayer" as
559         opposed to just "layer" because there are cases where we flush changes to CACFLayers that
560         don't have a corresponding GraphicsLayer.
561
562         Fixes <http://webkit.org/b/52894> "Sync compositing state" terminology in
563         WKCACFLayerRenderer and friends is confusing
564
565         Reviewed by Simon Fraser.
566
567         * platform/graphics/win/WKCACFLayerRenderer.cpp:
568         (WebCore::WKCACFLayerRenderer::WKCACFLayerRenderer):
569         (WebCore::WKCACFLayerRenderer::render):
570         Updated for renames.
571
572         (WebCore::WKCACFLayerRenderer::flushPendingGraphicsLayerChangesSoon): Renamed from
573         syncCompositingStateSoon, and updated for other renames.
574
575         * platform/graphics/win/WKCACFLayerRenderer.h: Renamed m_syncLayerChanges to
576         * m_shouldFlushPendingGraphicsLayerChanges.
577         (WebCore::WKCACFLayerRendererClient::flushPendingGraphicsLayerChanges): Renamed from
578         syncCompositingState.
579
580 2011-01-21  Adam Roben  <aroben@apple.com>
581
582         Clean up PlatformCAAnimationWin
583
584         Fixes <http://webkit.org/b/52904> PlatformCAAnimationWin is leaky and inefficient
585
586         Reviewed by Simon Fraser.
587
588         * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
589         (toCACFFillModeType):
590         (fromCACFFillModeType):
591         (toCACFValueFunctionType):
592         (fromCACFValueFunctionType):
593         Changed to take and return CFStringRefs. There's no need to convert to WebCore::String just
594         so we can later convert back to CFStringRef.
595
596         (toCACFTimingFunction): Fixed leaks by changing this to return a RetainPtr and adopting the
597         results of CACFTimingFunctionCreate.
598         (PlatformCAAnimation::PlatformCAAnimation): Changed not to needlessly roundtrip through
599         WebCore::String. Also changed an ASSERT(0) to ASSERT_NOT_REACHED().
600
601         (PlatformCAAnimation::setFillMode):
602         (PlatformCAAnimation::setTimingFunction):
603         (PlatformCAAnimation::setValueFunction):
604         (PlatformCAAnimation::setTimingFunctions):
605         Updated for changes to the above conversion functions.
606
607 2011-01-21  Charlie Reis  <creis@chromium.org>
608
609         Reviewed by Darin Fisher.
610
611         FrameLoader::checkLoadCompleteForThisFrame uses wrong history item
612         https://bugs.webkit.org/show_bug.cgi?id=48812
613
614         Most calls to stopAllLoaders now clear the history's provisional item(s).
615         We can now avoid resetting the back/forward state if a new navigation
616         is in progress.
617
618         Test: http/tests/navigation/back-twice-without-commit.html
619         Test: http/tests/navigation/forward-and-cancel.html
620
621         * loader/FrameLoader.cpp:
622         * loader/FrameLoader.h:
623         * loader/FrameLoaderTypes.h:
624         * WebCore.exp.in: Update stopAllLoaders signature.
625
626 2011-01-21  Carlos Garcia Campos  <cgarcia@igalia.com>
627
628         Reviewed by Martin Robinson.
629
630         [GTK] Show caps lock indicator in password fields
631         https://bugs.webkit.org/show_bug.cgi?id=52878
632
633         Test: manual-tests/password-caps-lock.html
634
635         * platform/gtk/KeyEventGtk.cpp:
636         (WebCore::PlatformKeyboardEvent::currentCapsLockState): Implement
637         currentCapsLockState() using GDK API.
638         * platform/gtk/RenderThemeGtk.cpp:
639         (WebCore::RenderThemeGtk::paintCapsLockIndicator): Paint an icon
640         in the password field when the caps lock modifier is locked.
641         * platform/gtk/RenderThemeGtk.h:
642
643 2011-01-21  Pavel Podivilov  <podivilov@chromium.org>
644
645         Reviewed by Pavel Feldman.
646
647         Web Inspector: move sticky breakpoints management from InspectorController to InspectorBrowserDebuggerAgent.
648         https://bugs.webkit.org/show_bug.cgi?id=52874
649
650         This is the first step of debugger api refactoring (see bug 52879).
651         JavaScript breakpoints are still in the same list as native breakpoints and are restored by InspectorBrowserDebuggerAgent.
652         The second step will be to move sticky JavaScript breakpoints to InspectorDebuggerAgent.
653
654         * inspector/Inspector.idl:
655         * inspector/InspectorBrowserDebuggerAgent.cpp:
656         (WebCore::InspectorBrowserDebuggerAgent::setAllBrowserBreakpoints):
657         (WebCore::InspectorBrowserDebuggerAgent::inspectedURLChanged):
658         (WebCore::InspectorBrowserDebuggerAgent::restoreStickyBreakpoint):
659         (WebCore::InspectorBrowserDebuggerAgent::discardBindings):
660         (WebCore::InspectorBrowserDebuggerAgent::didInsertDOMNode):
661         (WebCore::InspectorBrowserDebuggerAgent::didRemoveDOMNode):
662         (WebCore::InspectorBrowserDebuggerAgent::setDOMBreakpoint):
663         (WebCore::InspectorBrowserDebuggerAgent::removeDOMBreakpoint):
664         (WebCore::InspectorBrowserDebuggerAgent::descriptionForDOMEvent):
665         (WebCore::InspectorBrowserDebuggerAgent::hasBreakpoint):
666         (WebCore::InspectorBrowserDebuggerAgent::updateSubtreeBreakpoints):
667         * inspector/InspectorBrowserDebuggerAgent.h:
668         * inspector/InspectorController.cpp:
669         (WebCore::InspectorController::restoreInspectorStateFromCookie):
670         (WebCore::InspectorController::connectFrontend):
671         (WebCore::InspectorController::didCommitLoad):
672         (WebCore::InspectorController::enableDebugger):
673         (WebCore::InspectorController::resume):
674         (WebCore::InspectorController::inspectedURL):
675         * inspector/InspectorController.h:
676         * inspector/InspectorState.cpp:
677         (WebCore::InspectorState::InspectorState):
678         * inspector/InspectorState.h:
679         * inspector/front-end/BreakpointManager.js:
680         (WebInspector.BreakpointManager):
681         (WebInspector.BreakpointManager.prototype._saveBreakpoints):
682
683 2011-01-21  John Knottenbelt  <jknotten@chromium.org>
684
685         Reviewed by Jeremy Orlow.
686
687         Turn off uninitialized errors for ARM linux build.
688         https://bugs.webkit.org/show_bug.cgi?id=52893
689
690         Fix ARM compiler breakage.
691
692         * WebCore.gyp/WebCore.gyp:
693
694 2011-01-21  Mikhail Naganov  <mnaganov@chromium.org>
695
696         Reviewed by Yury Semikhatsky.
697
698         Web Inspector: [Chromium] REGRESSION: Using the "Back" button
699         while profiling causes renderer crash.
700
701         https://bugs.webkit.org/show_bug.cgi?id=52808
702
703         * inspector/InspectorProfilerAgent.cpp:
704         (WebCore::InspectorProfilerAgent::addProfileFinishedMessageToConsole):
705         (WebCore::InspectorProfilerAgent::addStartProfilingMessageToConsole):
706
707 2011-01-20  Ilya Tikhonovsky  <loislo@chromium.org>
708
709         Reviewed by Pavel Feldman.
710
711         Web Inspector: switch page/Console implementation from InspectorController to InspectorInstrumentation.
712
713         There are some places in WebCore where we still using direct InspectorController calls.
714         The idea is to pass all the Inspector related calls via InspectorInstrumentaion which is the
715         Inspector facade for WebCore.
716
717         https://bugs.webkit.org/show_bug.cgi?id=52869
718
719         * inspector/InspectorController.cpp:
720         * inspector/InspectorController.h:
721         * inspector/InspectorInstrumentation.cpp:
722         (WebCore::InspectorInstrumentation::addProfileImpl):
723         (WebCore::InspectorInstrumentation::profilerEnabledImpl):
724         (WebCore::InspectorInstrumentation::getCurrentUserInitiatedProfileNameImpl):
725         * inspector/InspectorInstrumentation.h:
726         (WebCore::InspectorInstrumentation::addProfile):
727         (WebCore::InspectorInstrumentation::profilerEnabled):
728         (WebCore::InspectorInstrumentation::getCurrentUserInitiatedProfileName):
729         * page/Console.cpp:
730         (WebCore::Console::profile):
731         (WebCore::Console::profileEnd):
732
733 2011-01-12  Pavel Podivilov  <podivilov@chromium.org>
734
735         Reviewed by Pavel Feldman.
736
737         Web Inspector: breakpoints are restored incorrectly when reverting live edit.
738         https://bugs.webkit.org/show_bug.cgi?id=52300
739
740         Fix breakpoints restoring when reverting to old revision by using text diff.
741         Move live edit logic from ScriptsPanel to DebuggerModel.
742         Eliminate unnecessary editLine delegate in TextViewer.
743
744         * inspector/front-end/DebuggerModel.js:
745         (WebInspector.DebuggerModel):
746         (WebInspector.DebuggerModel.prototype.reset):
747         (WebInspector.DebuggerModel.prototype.editScriptSource):
748         (WebInspector.DebuggerModel.prototype._updateScriptSource):
749         (WebInspector.DebuggerModel.prototype.get callFrames):
750         (WebInspector.DebuggerModel.prototype.pausedScript):
751         (WebInspector.DebuggerModel.prototype.resumedScript):
752         * inspector/front-end/Script.js:
753         (WebInspector.Script.prototype.get source):
754         * inspector/front-end/ScriptView.js:
755         (WebInspector.ScriptView):
756         * inspector/front-end/ScriptsPanel.js:
757         (WebInspector.ScriptsPanel):
758         (WebInspector.ScriptsPanel.prototype._scriptSourceChanged):
759         * inspector/front-end/SourceFrame.js:
760         (WebInspector.SourceFrame):
761         (WebInspector.SourceFrame.prototype._createViewerIfNeeded):
762         (WebInspector.SourceFrame.prototype._doubleClick.didEditLine):
763         (WebInspector.SourceFrame.prototype._doubleClick):
764         * inspector/front-end/SourceView.js:
765         (WebInspector.SourceView):
766         * inspector/front-end/TextViewer.js:
767         (WebInspector.TextViewer):
768         (WebInspector.TextViewer.prototype._handleKeyDown):
769         (WebInspector.TextViewer.prototype.editLine.finishEditing):
770         (WebInspector.TextViewer.prototype.editLine):
771         (WebInspector.TextChunk.prototype._createRow):
772
773 2011-01-21  Adam Klein  <adamk@chromium.org>
774
775         Reviewed by Eric Seidel.
776
777         [chromium] Rename ChromiumBridge to PlatformBridge
778         https://bugs.webkit.org/show_bug.cgi?id=52471
779
780         No tests added as this is a rename; no change in behavior.
781
782         * WebCore.gypi:
783         * bindings/v8/V8DOMWindowShell.cpp:
784         (WebCore::reportFatalErrorInV8):
785         * page/PageGroup.cpp:
786         (WebCore::PageGroup::isLinkVisited):
787         * platform/android/PlatformBridge.h:
788         * platform/audio/chromium/AudioBusChromium.cpp:
789         (WebCore::createBusFromInMemoryAudioFile):
790         * platform/chromium/ChromiumBridge.h: Removed.
791         * platform/chromium/ChromiumDataObjectLegacy.cpp:
792         (WebCore::ChromiumDataObjectLegacy::getData):
793         * platform/chromium/DragDataChromium.cpp:
794         (WebCore::DragData::asURL):
795         * platform/chromium/FileSystemChromium.cpp:
796         (WebCore::deleteFile):
797         (WebCore::deleteEmptyDirectory):
798         (WebCore::getFileSize):
799         (WebCore::getFileModificationTime):
800         (WebCore::revealFolderInOS):
801         (WebCore::directoryName):
802         (WebCore::pathByAppendingComponent):
803         (WebCore::makeAllDirectories):
804         (WebCore::fileExists):
805         (WebCore::openFile):
806         (WebCore::closeFile):
807         (WebCore::seekFile):
808         (WebCore::truncateFile):
809         (WebCore::readFromFile):
810         (WebCore::writeToFile):
811         * platform/chromium/LanguageChromium.cpp:
812         (WebCore::platformDefaultLanguage):
813         * platform/chromium/LinkHashChromium.cpp:
814         (WebCore::visitedLinkHash):
815         * platform/chromium/MIMETypeRegistryChromium.cpp:
816         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
817         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
818         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
819         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
820         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
821         * platform/chromium/PasteboardChromium.cpp:
822         (WebCore::Pasteboard::writeSelection):
823         (WebCore::Pasteboard::writePlainText):
824         (WebCore::Pasteboard::writeURL):
825         (WebCore::Pasteboard::writeImage):
826         (WebCore::Pasteboard::canSmartReplace):
827         (WebCore::Pasteboard::plainText):
828         (WebCore::Pasteboard::documentFragment):
829         * platform/chromium/PlatformBridge.h:
830         * platform/chromium/PlatformScreenChromium.cpp:
831         (WebCore::screenDepth):
832         (WebCore::screenDepthPerComponent):
833         (WebCore::screenIsMonochrome):
834         (WebCore::screenRect):
835         (WebCore::screenAvailableRect):
836         * platform/chromium/ReadableDataObject.cpp:
837         (WebCore::ReadableDataObject::getData):
838         (WebCore::ReadableDataObject::urlTitle):
839         (WebCore::ReadableDataObject::htmlBaseUrl):
840         (WebCore::ReadableDataObject::filenames):
841         (WebCore::ReadableDataObject::ensureTypeCacheInitialized):
842         * platform/chromium/SSLKeyGeneratorChromium.cpp:
843         (WebCore::signedPublicKeyAndChallengeString):
844         * platform/chromium/ScrollbarThemeChromium.cpp:
845         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
846         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
847         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
848         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
849         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
850         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
851         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
852         * platform/chromium/ScrollbarThemeChromiumMac.mm:
853         (WebCore::scrollbarStateToThemeState):
854         (WebCore::ScrollbarThemeChromiumMac::paint):
855         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
856         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
857         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
858         (WebCore::ScrollbarThemeChromiumWin::paintButton):
859         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
860         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
861         * platform/chromium/SharedTimerChromium.cpp:
862         (WebCore::setSharedTimerFiredFunction):
863         (WebCore::setSharedTimerFireTime):
864         (WebCore::stopSharedTimer):
865         * platform/chromium/SuddenTerminationChromium.cpp:
866         (WebCore::disableSuddenTermination):
867         (WebCore::enableSuddenTermination):
868         * platform/chromium/SystemTimeChromium.cpp:
869         (WebCore::currentTime):
870         * platform/chromium/WritableDataObject.cpp:
871         (WebCore::WritableDataObject::setData):
872         * platform/graphics/chromium/CrossProcessFontLoading.mm:
873         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
874         (WebCore::fontContainsCharacter):
875         (WebCore::FillLogFont):
876         * platform/graphics/chromium/FontCacheLinux.cpp:
877         (WebCore::FontCache::getFontDataForCharacters):
878         * platform/graphics/chromium/FontChromiumWin.cpp:
879         (WebCore::Font::drawGlyphs):
880         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
881         (WebCore::FontPlatformData::scriptFontProperties):
882         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
883         (WebCore::FontPlatformData::querySystemForRenderStyle):
884         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
885         (WebCore::fillBMPGlyphs):
886         * platform/graphics/chromium/ImageChromium.cpp:
887         (WebCore::Image::loadPlatformResource):
888         * platform/graphics/chromium/ImageChromiumMac.mm:
889         (WebCore::Image::loadPlatformResource):
890         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
891         (WebCore::SimpleFontData::platformInit):
892         (WebCore::SimpleFontData::determinePitch):
893         (WebCore::SimpleFontData::platformWidthForGlyph):
894         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
895         (WebCore::UniscribeHelperTextRun::tryToPreloadFont):
896         * platform/graphics/skia/FontCustomPlatformData.cpp:
897         (WebCore::FontCustomPlatformData::fontPlatformData):
898         * platform/network/chromium/CookieJarChromium.cpp:
899         (WebCore::setCookies):
900         (WebCore::cookies):
901         (WebCore::cookieRequestHeaderFieldValue):
902         (WebCore::cookiesEnabled):
903         (WebCore::getRawCookies):
904         (WebCore::deleteCookie):
905         * platform/network/chromium/DNSChromium.cpp:
906         (WebCore::prefetchDNS):
907         * platform/qt/PlatformBridge.h:
908         * platform/sql/chromium/SQLiteFileSystemChromium.cpp:
909         (WebCore::SQLiteFileSystem::deleteDatabaseFile):
910         (WebCore::SQLiteFileSystem::getDatabaseFileSize):
911         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
912         (chromiumOpen):
913         (chromiumDelete):
914         (chromiumAccess):
915         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
916         * plugins/chromium/PluginDataChromium.cpp:
917         (WebCore::PluginCache::plugins):
918         * rendering/RenderThemeChromiumMac.mm:
919         (WebCore::RenderThemeChromiumMac::usesTestModeFocusRingColor):
920         * rendering/RenderThemeChromiumSkia.cpp:
921         (WebCore::RenderThemeChromiumSkia::caretBlinkInterval):
922         * rendering/RenderThemeChromiumWin.cpp:
923         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
924         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
925         (WebCore::RenderThemeChromiumWin::platformActiveSelectionForegroundColor):
926         (WebCore::RenderThemeChromiumWin::systemColor):
927         (WebCore::RenderThemeChromiumWin::paintButton):
928         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
929         (WebCore::menuListButtonWidth):
930         (WebCore::RenderThemeChromiumWin::paintMenuList):
931         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
932         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
933         (WebCore::RenderThemeChromiumWin::paintProgressBar):
934         * storage/chromium/IDBFactoryBackendInterface.cpp:
935         (WebCore::IDBFactoryBackendInterface::create):
936         (WebCore::IDBFactoryBackendInterface::~IDBFactoryBackendInterface):
937         * storage/chromium/IDBKeyPathBackendImpl.cpp:
938         (WebCore::IDBKeyPathBackendImpl::createIDBKeysFromSerializedValuesAndKeyPath):
939
940 2011-01-21  Sheriff Bot  <webkit.review.bot@gmail.com>
941
942         Unreviewed, rolling out r76335.
943         http://trac.webkit.org/changeset/76335
944         https://bugs.webkit.org/show_bug.cgi?id=52875
945
946         profiler tests were broken (Requested by loislo on #webkit).
947
948         * inspector/InspectorController.cpp:
949         (WebCore::InspectorController::addProfile):
950         (WebCore::InspectorController::getCurrentUserInitiatedProfileName):
951         * inspector/InspectorController.h:
952         * inspector/InspectorInstrumentation.cpp:
953         (WebCore::InspectorInstrumentation::addStartProfilingMessageToConsoleImpl):
954         * inspector/InspectorInstrumentation.h:
955         (WebCore::InspectorInstrumentation::addStartProfilingMessageToConsole):
956         (WebCore::InspectorInstrumentation::inspectorControllerWithFrontendForPage):
957         * page/Console.cpp:
958         (WebCore::Console::profile):
959         (WebCore::Console::profileEnd):
960
961 2011-01-21  Ilya Tikhonovsky  <loislo@chromium.org>
962
963         Reviewed by Yury Semikhatsky.
964
965         Web Inspector: switch page/Console implementation from InspectorController to InspectorInstrumentation.
966
967         There are some places in WebCore where we still using direct InspectorController calls.
968         The idea is to pass all the Inspector related calls via InspectorInstrumentaion which is the
969         Inspector facade for WebCore.
970
971         https://bugs.webkit.org/show_bug.cgi?id=52869
972
973         * inspector/InspectorController.cpp:
974         * inspector/InspectorController.h:
975         * inspector/InspectorInstrumentation.cpp:
976         (WebCore::InspectorInstrumentation::addProfileImpl):
977         (WebCore::InspectorInstrumentation::profilerEnabledImpl):
978         (WebCore::InspectorInstrumentation::getCurrentUserInitiatedProfileNameImpl):
979         * inspector/InspectorInstrumentation.h:
980         (WebCore::InspectorInstrumentation::addProfile):
981         (WebCore::InspectorInstrumentation::profilerEnabled):
982         (WebCore::InspectorInstrumentation::getCurrentUserInitiatedProfileName):
983         * page/Console.cpp:
984         (WebCore::Console::profile):
985         (WebCore::Console::profileEnd):
986
987 2011-01-20  Sam Weinig  <sam@webkit.org>
988
989         Reviewed by Gavin Barraclough.
990
991         Fix failing tests from r76291.
992
993         * platform/ScrollView.cpp:
994         (WebCore::ScrollView::scrollPosition):
995         (WebCore::ScrollView::updateScrollbars):
996         Take the scroll origin into account in more places.
997
998 2011-01-20  Kent Tamura  <tkent@chromium.org>
999
1000         Unreviewed, sorting an Xcode project file.
1001
1002         * WebCore.xcodeproj/project.pbxproj:
1003
1004 2011-01-20  Ben Vanik  <ben.vanik@gmail.com>
1005
1006         Reviewed by Kenneth Russell.
1007
1008         Implementation of the OES_standard_derivatives WebGL extension.
1009         https://bugs.webkit.org/show_bug.cgi?id=51678
1010
1011         Changes are modeled off of the existing OESTextureFloat extension. New files,
1012         extension retrieval, etc all match the existing code.
1013
1014         Changed ANGLEWebKitBridge to allow for multiple sets of the ANGLE shader compiler
1015         options. This supports the enabling of the standard derivatives flag when the
1016         extension is enabled. Refactored the cleanup code to make the destruction of the
1017         compilers (if they had been created) cleaner.
1018
1019         Tested with the WebGL conformance test:
1020         https://cvs.khronos.org/svn/repos/registry/trunk/public/webgl/sdk/tests/conformance/oes-standard-derivatives.html
1021         Passes on WebKit/OSX, Chromium/OSX, and Chromium/Windows.
1022
1023         * CMakeLists.txt:
1024         * DerivedSources.make:
1025         * GNUmakefile.am:
1026         * WebCore.gypi:
1027         * WebCore.pri:
1028         * WebCore.pro:
1029         * WebCore.xcodeproj/project.pbxproj:
1030         * bindings/js/JSWebGLRenderingContextCustom.cpp:
1031         (WebCore::toJS):
1032         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
1033         (WebCore::toV8Object):
1034         * html/canvas/OESStandardDerivatives.cpp: Added.
1035         (WebCore::OESStandardDerivatives::OESStandardDerivatives):
1036         (WebCore::OESStandardDerivatives::~OESStandardDerivatives):
1037         (WebCore::OESStandardDerivatives::getName):
1038         (WebCore::OESStandardDerivatives::create):
1039         * html/canvas/OESStandardDerivatives.h: Added.
1040         * html/canvas/OESStandardDerivatives.idl: Added.
1041         * html/canvas/WebGLExtension.h:
1042         * html/canvas/WebGLRenderingContext.cpp:
1043         (WebCore::WebGLRenderingContext::getExtension): Enable and return the new extension.
1044         (WebCore::WebGLRenderingContext::getParameter): Support extension enum when enabled.
1045         (WebCore::WebGLRenderingContext::getSupportedExtensions): 
1046         (WebCore::WebGLRenderingContext::hint): Validate extension enum when enabled.
1047         (WebCore::WebGLRenderingContext::getNumberOfExtensions):
1048         (WebCore::WebGLRenderingContext::getExtensionNumber):
1049         * html/canvas/WebGLRenderingContext.h:
1050         * platform/graphics/ANGLEWebKitBridge.cpp:
1051         (WebCore::ANGLEWebKitBridge::~ANGLEWebKitBridge): Cleaned up compiler cleanup.
1052         (WebCore::ANGLEWebKitBridge::cleanupCompilers): Destruct compilers.
1053         (WebCore::ANGLEWebKitBridge::setResources): Cleanup existing compilers when changing
1054         ANGLE settings.
1055         (WebCore::ANGLEWebKitBridge::validateShaderSource): Cleaned up compiler cleanup on error.
1056         * platform/graphics/ANGLEWebKitBridge.h:
1057         (WebCore::ANGLEWebKitBridge::getResources):
1058         * platform/graphics/Extensions3D.h: Added enumeration for the extension.
1059         * platform/graphics/GraphicsContext3D.h: lumbing for GraphicsContext3D.
1060         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
1061         (WebCore::Extensions3DOpenGL::Extensions3DOpenGL): Plumbed through a pointer to the
1062         GraphicsContext3D to handle resetting the shader compilers.
1063         (WebCore::Extensions3DOpenGL::supports): Desktop GL always supports this extension,
1064         so always return true.
1065         (WebCore::Extensions3DOpenGL::ensureEnabled): Reset shader compilers as required.
1066         * platform/graphics/opengl/Extensions3DOpenGL.h: Plumbing for GraphicsContext3D.
1067         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
1068         (WebCore::GraphicsContext3D::getExtensions): Plumbing for GraphicsContext3D to
1069         Extensions3DOpenGL.
1070
1071 2011-01-20  Xiaomei Ji  <xji@chromium.org>
1072
1073         Reviewed by Dan Bernstein.
1074
1075         Fix regression(r71566): PDF in RTL block might messes up text directionality.
1076         https://bugs.webkit.org/show_bug.cgi?id=52776
1077
1078         Test: fast/dom/52776.html
1079
1080         * platform/text/BidiResolver.h:
1081         (WebCore::::checkDirectionInLowerRaiseEmbeddingLevel):
1082         (WebCore::::lowerExplicitEmbeddingLevel):
1083         (WebCore::::raiseExplicitEmbeddingLevel):
1084         (WebCore::::createBidiRunsForLine):
1085
1086 2011-01-20  Beth Dakin  <bdakin@apple.com>
1087
1088         Reviewed by Anders Carlsson.
1089
1090         Follow-on for <rdar://problem/8890255>
1091
1092         This fixes a painting error with ScrollbarPainter scrollers
1093         and the new drawing area code path.
1094         * platform/mac/ScrollbarThemeMac.mm:
1095         (WebCore::updateArrowPlacement):
1096
1097 2011-01-20  Levi Weintraub  <leviw@chromium.org>
1098
1099         Unreviewed.
1100
1101         Fixing build breakage.
1102
1103         * editing/SelectionController.cpp:
1104         (WebCore::SelectionController::willBeModified):
1105
1106 2011-01-20  Levi Weintraub  <leviw@chromium.org>
1107
1108         Reviewed by Ryosuke Niwa.
1109
1110         RTL: Caret goes to the opposite direction when pressing an arrow key after selection is made
1111         https://bugs.webkit.org/show_bug.cgi?id=49511
1112
1113         Test: editing/selection/rtl-move-selection-right-left.html
1114
1115         * editing/SelectionController.cpp:
1116         (WebCore::SelectionController::willBeModified):
1117         Respecting the direction of the containing block when switching selection base and extent in
1118         RTL content.
1119
1120         (WebCore::SelectionController::modifyMovingRight):
1121         (WebCore::SelectionController::modifyMovingLeft):
1122         Using directionOfEnclosingBlock when deciding to use the selection start or end to do the
1123         correct thing for RTL.
1124
1125 2011-01-20  Nate Chapin  <japhet@chromium.org>
1126
1127         Reviewed by Adam Barth.
1128
1129         Null-check m_frame in DOMWindow::setLocation(), since it's
1130         possible to reach this point without it having been checked
1131         already.
1132         https://bugs.webkit.org/show_bug.cgi?id=52769
1133
1134         Test: fast/dom/Window/Location/set-location-after-close.html
1135
1136         * page/DOMWindow.cpp:
1137         (WebCore::DOMWindow::setLocation):
1138
1139 2011-01-20  Chang Shu  <chang.shu@nokia.com>
1140
1141         Reviewed by Darin Adler.
1142
1143         setContentEditable with invalid string should throw exception.
1144         https://bugs.webkit.org/show_bug.cgi?id=52057
1145
1146         Implemented exception throwing for setContentEditable according to the following spec:
1147         http://www.whatwg.org/specs/web-apps/current-work/multipage/editing.html#attr-contenteditable
1148         Related quotas: "On setting, if the new value is an ASCII case-insensitive match for the 
1149         string 'inherit' then the content attribute must be removed, if the new value is an ASCII 
1150         case-insensitive match for the string 'true' then the content attribute must be set to the 
1151         string 'true', if the new value is an ASCII case-insensitive match for the string 'false' 
1152         then the content attribute must be set to the string 'false', and otherwise the attribute 
1153         setter must raise a SYNTAX_ERR exception."
1154
1155         * html/HTMLElement.cpp:
1156         (WebCore::HTMLElement::setContentEditable): Throw exception on invalid input strings; Make setting values case-insensitive and also convert them to lower cases according to the spec.
1157         * html/HTMLElement.h: Add additional parameter ExceptionCode& for function setContentEditable.
1158         * html/HTMLElement.idl: Add exception throwing support for contentEditable setter.
1159
1160 2011-01-19  Adrienne Walker  <enne@google.com>
1161
1162         Reviewed by James Robinson.
1163
1164         [chromium] Composited render surfaces should allow writes to alpha channel.
1165         https://bugs.webkit.org/show_bug.cgi?id=52766
1166
1167         Test: LayoutTests/platform/chromium/compositing
1168
1169         * platform/graphics/chromium/LayerRendererChromium.cpp:
1170         (WebCore::LayerRendererChromium::drawLayers):
1171
1172 2011-01-14  Jer Noble  <jer.noble@apple.com>
1173
1174         Reviewed by Eric Carlson.
1175
1176         REGRESSION (r71842): Compass video is not playing in Safari welcome page
1177         https://bugs.webkit.org/show_bug.cgi?id=52506
1178
1179         New test: LayoutTests/media/video-currentTime-delay.html
1180
1181         Call invalidateCachedTime() every time one of the cached property dependencies changes,
1182         i.e. m_paused and m_playbackRate.
1183
1184         * html/HTMLMediaElement.cpp:
1185         (WebCore::HTMLMediaElement::prepareForLoad):
1186         (WebCore::HTMLMediaElement::setReadyState):
1187         (WebCore::HTMLMediaElement::setPlaybackRate):
1188         (WebCore::HTMLMediaElement::mediaPlayerRateChanged):
1189
1190 2011-01-20  Beth Dakin  <bdakin@apple.com>
1191
1192         Reviewed by Geoffrey Garen.
1193
1194         Fix for <rdar://problem/8890255>
1195
1196         Allow WebKitSystemInterface to draw scrollbars 
1197         when appropriate.
1198         * WebCore.exp.in:
1199         * platform/mac/ScrollbarThemeMac.mm:
1200         (WebCore::scrollbarMap):
1201         (+[ScrollbarPrefsObserver appearancePrefsChanged:]):
1202         (WebCore::ScrollbarThemeMac::registerScrollbar):
1203         (WebCore::ScrollbarThemeMac::unregisterScrollbar):
1204         (WebCore::ScrollbarThemeMac::paint):
1205         * platform/mac/WebCoreSystemInterface.h:
1206         * platform/mac/WebCoreSystemInterface.mm:
1207
1208 2011-01-20  Sam Weinig  <sam@webkit.org>
1209
1210         Reviewed by Dave Hyatt.
1211
1212         Cleanup Scrollbar/ScrollbarClient relationship
1213         https://bugs.webkit.org/show_bug.cgi?id=52779
1214
1215         Pipe all scrolling through the ScrollbarClient/ScrollAnimator
1216         rather than through the Scrollbar. The Scrollbar now is just
1217         a "view" on the scroll position of the scrollable area it is
1218         attached to.
1219
1220         There are now two ways to scroll a scrollable area:
1221         - ScrollbarClient::scroll()
1222         - ScrollbarClient::scrollToOffsetWithoutAnimation()
1223
1224         Both of these go through the ScrollAnimator (updating its state
1225         or starting an animation). The ScrollAnimator, in turn, now calls
1226         ScrollbarClient::setScrollOffsetFromAnimation, which tells the
1227         Scrollbars to pull a new offset (via Scrollbar::offsetDidChange)
1228         and tells the class that derives from ScrollbarClient to scroll
1229         its contents (via ScrollbarClient::setScrollOffset).
1230
1231         * WebCore.xcodeproj/project.pbxproj:
1232         Move Scrollbar.cpp to the right place.
1233
1234         * accessibility/AccessibilityScrollbar.cpp:
1235         (WebCore::AccessibilityScrollbar::setValue):
1236         Initiate the scroll through the scrollbar client, rather than the
1237         scrollbar itself.
1238
1239         * page/FrameView.cpp:
1240         (WebCore::FrameView::scrollTo):
1241         * page/FrameView.h:
1242         Condense the two valueChanged overrides to a single override of the
1243         scrollTo function.
1244
1245         * platform/ScrollAnimator.cpp:
1246         (WebCore::ScrollAnimator::scroll):
1247         (WebCore::ScrollAnimator::scrollToOffsetWithoutAnimation):
1248         (WebCore::ScrollAnimator::currentPosition):
1249         (WebCore::ScrollAnimator::notityPositionChanged):
1250         * platform/ScrollAnimator.h:
1251         * platform/ScrollAnimatorWin.cpp:
1252         (WebCore::ScrollAnimatorWin::scrollToOffsetWithoutAnimation):
1253         (WebCore::ScrollAnimatorWin::animateScroll):
1254         * platform/ScrollAnimatorWin.h:
1255         * platform/mac/ScrollAnimatorMac.h:
1256         * platform/mac/ScrollAnimatorMac.mm:
1257         (WebCore::ScrollAnimatorMac::scrollToOffsetWithoutAnimation):
1258         (WebCore::ScrollAnimatorMac::immediateScrollToPoint):
1259         Change setScrollPositionAndStopAnimation to scrollToOffsetWithoutAnimation
1260         and bottleneck all client notification of changed position through a new
1261         notityPositionChanged() function.
1262
1263         * platform/ScrollView.cpp:
1264         (WebCore::ScrollView::setScrollOffset):
1265         (WebCore::ScrollView::scrollTo):
1266         (WebCore::ScrollView::scrollPosition):
1267         (WebCore::ScrollView::scroll):
1268         (WebCore::ScrollView::updateScrollbars):
1269         (WebCore::ScrollView::wheelEvent):
1270         * platform/ScrollView.h:
1271         (WebCore::ScrollView::horizontalScrollbar):
1272         (WebCore::ScrollView::verticalScrollbar):
1273         Update to scroll via the ScrollbarClient rather than the Scrollbar.
1274
1275         * platform/Scrollbar.cpp:
1276         (WebCore::Scrollbar::offsetDidChange):
1277         (WebCore::Scrollbar::autoscrollPressedPart):
1278         (WebCore::Scrollbar::moveThumb):
1279         (WebCore::Scrollbar::mouseMoved):
1280         * platform/Scrollbar.h:
1281         (WebCore::Scrollbar::setPressedPos):
1282         Change the scrollbar to only updates its offset in response to
1283         an offsetDidChange call.
1284
1285         * platform/ScrollbarClient.cpp:
1286         (WebCore::ScrollbarClient::scroll):
1287         (WebCore::ScrollbarClient::scrollToOffsetWithoutAnimation):
1288         (WebCore::ScrollbarClient::scrollToXOffsetWithoutAnimation):
1289         (WebCore::ScrollbarClient::scrollToYOffsetWithoutAnimation):
1290         (WebCore::ScrollbarClient::setScrollOffsetFromAnimation):
1291         * platform/ScrollbarClient.h:
1292         (WebCore::ScrollbarClient::horizontalScrollbar):
1293         (WebCore::ScrollbarClient::verticalScrollbar):
1294         Make the increasingly misnamed ScrollbarClient responsible for
1295         scrolling.
1296
1297         * platform/efl/ScrollbarEfl.cpp:
1298         (scrollbarEflEdjeMessage):
1299         * platform/gtk/MainFrameScrollbarGtk.cpp:
1300         (MainFrameScrollbarGtk::gtkValueChanged):
1301         * platform/qt/ScrollbarQt.cpp:
1302         (WebCore::Scrollbar::contextMenu):
1303         Update to move scrolling through the client.
1304
1305         * platform/win/PopupMenuWin.cpp:
1306         (WebCore::PopupMenuWin::scrollToRevealSelection):
1307         (WebCore::PopupMenuWin::scrollPosition):
1308         (WebCore::PopupMenuWin::setScrollOffset):
1309         (WebCore::PopupMenuWin::scrollTo):
1310         (WebCore::PopupMenuWin::wndProc):
1311         * platform/win/PopupMenuWin.h:
1312         (WebCore::PopupMenuWin::verticalScrollbar):
1313         * rendering/RenderLayer.cpp:
1314         (WebCore::RenderLayer::scrollToOffset):
1315         (WebCore::RenderLayer::scrollTo):
1316         (WebCore::RenderLayer::setScrollOffset):
1317         (WebCore::RenderLayer::scrollPosition):
1318         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
1319         (WebCore::RenderLayer::scroll):
1320         * rendering/RenderLayer.h:
1321         * rendering/RenderListBox.cpp:
1322         (WebCore::RenderListBox::scrollToRevealElementAtListIndex):
1323         (WebCore::RenderListBox::scroll):
1324         (WebCore::RenderListBox::logicalScroll):
1325         (WebCore::RenderListBox::scrollPosition):
1326         (WebCore::RenderListBox::setScrollOffset):
1327         (WebCore::RenderListBox::scrollTo):
1328         (WebCore::RenderListBox::setScrollTop):
1329         * rendering/RenderListBox.h:
1330         (WebCore::RenderListBox::verticalScrollbar):
1331         Update to scroll via the ScrollbarClient rather than the Scrollbar.
1332
1333         * rendering/RenderMarquee.cpp:
1334         (WebCore::RenderMarquee::start):
1335         Simplify initial paint to just do an immediate scroll to the position.
1336
1337 2011-01-20  Patrick Gansterer  <paroga@webkit.org>
1338
1339         Unreviewed WinCE build fix for r76170.
1340
1341         * platform/graphics/wince/FontWinCE.cpp: Added a missing include.
1342         * platform/graphics/wince/ImageBufferData.h: Added a missing include and fixed style.
1343
1344 2011-01-20  James Robinson  <jamesr@chromium.org>
1345
1346         Reviewed by Darin Fisher.
1347
1348         Implement mozilla's requestAnimationFrame API
1349         https://bugs.webkit.org/show_bug.cgi?id=51218
1350
1351         This implements mozilla's proposed requestAnimationFrame API.  The idea with this API is that
1352         an author driving an animation from script could use window.requestAnimationFrame(callback)
1353         instead of window.setTimeout(callback, 0) to schedule their update logic and let the browser
1354         decide when to update the animations.  This avoids doing unnecessary work when the page content
1355         is offscreen or is being displayed at a different framerate than what the page author expects.
1356
1357         Mozilla's proposal is here: https://developer.mozilla.org/en/DOM/window.mozRequestAnimationFrame
1358         This implements window.mozRequestAnimationFrame as window.webkitRequestAnimationFrame with the
1359         following changes:
1360         *) Only the callback syntax is supported, there is no before paint event
1361         *) webkitRequestAnimationFrame supports a second parameter Element to let the author indicate
1362             what content they intend to animate.  That way if the page is being displayed but the element
1363             in question is offscreen, we can avoid invoking the callback.
1364         *) No timestamp is provided to the caller and there is no window.animationStartTime property
1365             (see https://bugs.webkit.org/show_bug.cgi?id=51952 for discussion of this property)
1366         *) window.webkitRequestAnimationFrame returns a numerical id that can be used to cancel the callback
1367             using window.cancelWebkitRequestAnimationFrame, to parallel window.setTimeout()/window.clearTime().
1368
1369         The implementation depends on the embedder scheduling the callbacks since the callback invocation
1370         depends on the page's visibility and the embedder's paint scheduling, neither of which are exposed
1371         to WebCore.  The expectation for the embedder is that at some point Chrome::scheduleAnimation() is
1372         called FrameView::serviceScriptedAnimations() should be called for the associated Page's main frame.
1373         Ideally serviceScriptedAnimations() would be called prior to rendering - although in practice the
1374         embedder has to rate limit callbacks and may not be able to tie the callback directly to the
1375         rendering loop.
1376
1377         Tests: fast/animation/request-animation-frame-cancel.html
1378                fast/animation/request-animation-frame-cancel2.html
1379                fast/animation/request-animation-frame-display.html
1380                fast/animation/request-animation-frame-within-callback.html
1381                fast/animation/request-animation-frame.html
1382
1383         * WebCore.gypi:
1384         * dom/Document.cpp:
1385         (WebCore::Document::Document):
1386         (WebCore::Document::webkitRequestAnimationFrame):
1387         (WebCore::Document::webkitCancelRequestAnimationFrame):
1388         (WebCore::Document::serviceScriptedAnimations):
1389         * dom/Document.h:
1390         * dom/RequestAnimationFrameCallback.h: Added.
1391         (WebCore::RequestAnimationFrameCallback::~RequestAnimationFrameCallback):
1392         * dom/RequestAnimationFrameCallback.idl: Added.
1393         * loader/EmptyClients.h:
1394         (WebCore::EmptyChromeClient::scheduleAnimation):
1395         * page/Chrome.cpp:
1396         (WebCore::Chrome::scheduleAnimation):
1397         * page/Chrome.h:
1398         * page/ChromeClient.h:
1399         * page/DOMWindow.cpp:
1400         (WebCore::DOMWindow::webkitRequestAnimationFrame):
1401         (WebCore::DOMWindow::webkitCancelRequestAnimationFrame):
1402         * page/DOMWindow.h:
1403         * page/DOMWindow.idl:
1404         * page/FrameView.cpp:
1405         (WebCore::FrameView::scheduleAnimation):
1406         (WebCore::FrameView::serviceScriptedAnimations):
1407         * page/FrameView.h:
1408         * platform/HostWindow.h:
1409
1410 2011-01-20  James Robinson  <jamesr@chromium.org>
1411
1412         Reviewed by Nate Chapin.
1413
1414         [v8] CodeGeneratorV8 generates incorrect code for callbacks with no parameters
1415         https://bugs.webkit.org/show_bug.cgi?id=52837
1416
1417         When generating code to invoke a callback with no parameters CodeGeneratorV8.pm was generating the following:
1418         v8::Handle<v8::Value> argv[] = {}; which does not compile in visual studio.  Instead, if the argument count
1419         is 0, we can just pass a NULL pointer for the argv parameter.
1420
1421         Test added to bindings/scripts/test/TestCallback.idl and covered by run-bindings-tests.  This
1422         patch also includes some spurious changes to the bindings tests golden files (mostly GObject)
1423         because the old golden files were out of date.
1424
1425         * bindings/scripts/CodeGeneratorV8.pm:
1426         * bindings/scripts/test/CPP/WebDOMTestCallback.cpp:
1427         (WebDOMTestCallback::callbackWithNoParam):
1428         * bindings/scripts/test/CPP/WebDOMTestCallback.h:
1429         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
1430         (webkit_dom_test_callback_callback_with_no_param):
1431         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
1432         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
1433         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
1434         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
1435         * bindings/scripts/test/JS/JSTestCallback.cpp:
1436         (WebCore::JSTestCallback::callbackWithNoParam):
1437         * bindings/scripts/test/JS/JSTestCallback.h:
1438         * bindings/scripts/test/JS/JSTestInterface.cpp:
1439         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
1440         * bindings/scripts/test/JS/JSTestObj.cpp:
1441         * bindings/scripts/test/ObjC/DOMTestCallback.h:
1442         * bindings/scripts/test/ObjC/DOMTestCallback.mm:
1443         (-[DOMTestCallback callbackWithNoParam]):
1444         * bindings/scripts/test/TestCallback.idl:
1445         * bindings/scripts/test/V8/V8TestCallback.cpp:
1446         (WebCore::V8TestCallback::callbackWithNoParam):
1447         * bindings/scripts/test/V8/V8TestCallback.h:
1448         * bindings/scripts/test/V8/V8TestObj.cpp:
1449         (WebCore::TestObjInternal::reflectedUnsignedIntegralAttrAttrGetter):
1450
1451 2011-01-20  James Robinson  <jamesr@chromium.org>
1452
1453         Reviewed by Eric "Baller" Seidel.
1454
1455         RenderTableSection's setNeedsCellRecalc needs to null check table()
1456         https://bugs.webkit.org/show_bug.cgi?id=52770
1457
1458         Null checks table() before deferencing it in RenderTableSection::setNeedsCellRecalc.
1459         This can be null during detach().  Test constructed by Eric Seidel.
1460
1461         Test: fast/css-generated-content/table-with-scrollbar-corner.html
1462
1463         * rendering/RenderTableSection.cpp:
1464         (WebCore::RenderTableSection::setNeedsCellRecalc):
1465         * rendering/RenderTableSection.h:
1466
1467 2011-01-20  Dirk Schulze  <krit@webkit.org>
1468
1469         Reviewed by Rob Buis.
1470
1471         SVG Pattern doesn't take preserveAspectRatio of references Pattern
1472         https://bugs.webkit.org/show_bug.cgi?id=52802
1473
1474         SVGPattern didn't take preserveAspectRatio of a referenced SVGPattern into account. Store preserveAspectRatio
1475         in PatternAttributes as well, if the attribute was set on the referenced SVGPattern element.
1476
1477         Test: svg/custom/pattern-referencing-preserve-aspect-ratio.svg
1478
1479         * rendering/svg/RenderSVGResourcePattern.cpp:
1480         (WebCore::RenderSVGResourcePattern::buildTileImageTransform):
1481         * svg/PatternAttributes.h:
1482         (WebCore::PatternAttributes::PatternAttributes):
1483         (WebCore::PatternAttributes::preserveAspectRatio):
1484         (WebCore::PatternAttributes::setPreserveAspectRatio):
1485         (WebCore::PatternAttributes::hasPreserveAspectRatio):
1486         * svg/SVGPatternElement.cpp:
1487         (WebCore::SVGPatternElement::collectPatternAttributes):
1488
1489 2011-01-20  Dan Bernstein  <mitz@apple.com>
1490
1491         Reviewed by Adele Peterson.
1492
1493         <rdar://problem/8765498> REGRESSION (r72141): Cannot order prints with Aperture 3.1
1494
1495         <rdar://problem/8884648> REGRESSION (r72141): Safari hangs when visiting a page on www.bfmtv.com
1496         https://bugs.webkit.org/show_bug.cgi?id=52765
1497
1498         <rdar://problem/8890909> REGRESSION (r72141): Very Slow Rendering With Certain Markup
1499         https://bugs.webkit.org/show_bug.cgi?id=52265
1500
1501         Test: fast/block/line-layout/negative-max-height.html
1502
1503         Integer overflow detection led to a block having a huge height. This manifested as broken layout
1504         in the first bug and as extreme slowness in the latter bugs because of
1505         https://bugs.webkit.org/show_bug.cgi?id=52832
1506
1507         * rendering/RootInlineBox.cpp:
1508         (WebCore::RootInlineBox::alignBoxesInBlockDirection): Clamp maxHeight to 0 so the next line
1509         cannot start above this line. The negative maxHeight also caused the integer overflow detection
1510         logic to give the block a huge height.
1511
1512 2011-01-20  Yi Shen  <yi.4.shen@nokia.com>
1513
1514         Reviewed by Eric Carlson.
1515
1516         Clean up the Media Controls CSS for Qt
1517         https://bugs.webkit.org/show_bug.cgi?id=52822
1518
1519         Split the audio::-webkit-media-xxx and video::-webkit-media-xxx rules 
1520         in mediaControlsQt.css, and remove the duplicate audio::-webkit-media-xxx
1521         rules from mediaControlsQtFullscreen.css.
1522
1523         * css/mediaControlsQt.css:
1524         (audio::-webkit-media-controls-panel):
1525         (video::-webkit-media-controls-panel):
1526         (audio::-webkit-media-controls-mute-button):
1527         (video::-webkit-media-controls-mute-button):
1528         (audio::-webkit-media-controls-play-button):
1529         (video::-webkit-media-controls-play-button):
1530         (audio::-webkit-media-controls-timeline-container):
1531         (video::-webkit-media-controls-timeline-container):
1532         (audio::-webkit-media-controls-current-time-display):
1533         (video::-webkit-media-controls-current-time-display):
1534         (audio::-webkit-media-controls-time-remaining-display):
1535         (video::-webkit-media-controls-time-remaining-display):
1536         (audio::-webkit-media-controls-timeline):
1537         (video::-webkit-media-controls-timeline):
1538         (audio::-webkit-media-controls-volume-slider-container):
1539         (video::-webkit-media-controls-volume-slider-container):
1540         (audio::-webkit-media-controls-volume-slider):
1541         (video::-webkit-media-controls-volume-slider):
1542         (audio::-webkit-media-controls-seek-back-button):
1543         (video::-webkit-media-controls-seek-back-button):
1544         (audio::-webkit-media-controls-seek-forward-button):
1545         (video::-webkit-media-controls-seek-forward-button):
1546         (audio::-webkit-media-controls-fullscreen-button):
1547         (video::-webkit-media-controls-fullscreen-button):
1548         (audio::-webkit-media-controls-rewind-button):
1549         (video::-webkit-media-controls-rewind-button):
1550         (audio::-webkit-media-controls-return-to-realtime-button):
1551         (video::-webkit-media-controls-return-to-realtime-button):
1552         (audio::-webkit-media-controls-toggle-closed-captions-button):
1553         (video::-webkit-media-controls-toggle-closed-captions-button):
1554         * css/mediaControlsQtFullscreen.css:
1555         (video::-webkit-media-controls-time-remaining-display):
1556         (video::-webkit-media-controls-seek-back-button):
1557         (video::-webkit-media-controls-seek-forward-button):
1558         (video::-webkit-media-controls-rewind-button):
1559         (video::-webkit-media-controls-return-to-realtime-button):
1560         (video::-webkit-media-controls-toggle-closed-captions-button):
1561
1562 2011-01-20  Alexander Pavlov  <apavlov@chromium.org>
1563
1564         Reviewed by Pavel Feldman.
1565
1566         Web Inspector: [REGRESSION] Canceling of CSS numeric values increment/decrement is broken
1567         https://bugs.webkit.org/show_bug.cgi?id=52816
1568
1569         * inspector/front-end/StylesSidebarPane.js:
1570         (WebInspector.StylePropertyTreeElement.prototype):
1571
1572 2011-01-20  Dawit Alemayehu  <adawit@kde.org>
1573
1574         Reviewed by Andreas Kling.
1575
1576         [Qt] Fix Layering violation in MediaPlayerPrivateQt.
1577         https://bugs.webkit.org/show_bug.cgi?id=52733
1578
1579         No new tests. no behavioral change.
1580
1581        * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
1582         (WebCore::MediaPlayerPrivateQt::commitLoad):
1583
1584 2011-01-20  Nate Chapin  <japhet@chromium.org>
1585
1586         Reviewed by Darin Fisher.
1587
1588         [V8] Call malloc and memcpy directly instead of
1589         of strdup in convertV8ObjectToNPVariant() when
1590         converting strings. If there is a null character
1591         in the string, our use of strdup causes us to allocate
1592         too little memory, leading to out of bounds reads.
1593
1594         https://bugs.webkit.org/show_bug.cgi?id=52631
1595
1596         * bindings/v8/V8NPUtils.cpp:
1597         (WebCore::convertV8ObjectToNPVariant):
1598
1599 2011-01-20  Andreas Kling  <kling@webkit.org>
1600
1601         Reviewed by Ariya Hidayat.
1602
1603         [Qt] Fill shadow scratch buffer with proper transparent pixels
1604
1605         QImage::fill() has no Qt::GlobalColor overload in Qt 4.7 (coming in 4.8)
1606         so doing QImage::fill(Qt::transparent) will actually fill all pixels with
1607         the RGBA value 0x00000013.
1608
1609         * platform/graphics/qt/ContextShadowQt.cpp:
1610         (WebCore::ShadowBuffer::scratchImage):
1611
1612 2011-01-19  Adam Roben  <aroben@apple.com>
1613
1614         Remove WKCACFContextFlusher
1615
1616         It wasn't doing anything.
1617
1618         Fixes <http://webkit.org/b/52752> WKCACFContextFlusher is unused
1619
1620         Reviewed by Simon Fraser.
1621
1622         * WebCore.vcproj/WebCore.vcproj: Removed WKCACFContextFlusher. Also let VS have its way with
1623         the file.
1624
1625         * platform/graphics/win/WKCACFContextFlusher.cpp: Removed.
1626         * platform/graphics/win/WKCACFContextFlusher.h: Removed.
1627
1628         * platform/graphics/win/WKCACFLayerRenderer.cpp:
1629         (WebCore::WKCACFLayerRenderer::~WKCACFLayerRenderer):
1630         (WebCore::WKCACFLayerRenderer::layerTreeDidChange):
1631         Stop telling WKCACFContextFlusher about our context, since it never did anything with it.
1632
1633 2011-01-19  Adam Roben  <aroben@apple.com>
1634
1635         Only flush our own context when we get resized
1636
1637         Fixes <http://webkit.org/b/52751> All WKCACFContexts with uncommitted
1638         changes get flushed whenever any composited page is resized
1639
1640         Reviewed by Simon Fraser.
1641
1642         * platform/graphics/win/WKCACFLayerRenderer.cpp:
1643         (WebCore::WKCACFLayerRenderer::resize): Just flush our own context, not all contexts
1644         WKCACFContextFlusher knows about. After all, ours is the only one that just got resized!
1645
1646 2011-01-19  Adam Roben  <aroben@apple.com>
1647
1648         Make WKCACFLayerRenderer ref-counted
1649
1650         This will be needed to handle cases where the client might release its reference to us while
1651         we're calling out to it.
1652
1653         WKCACFLayerRenderer now has a setClient function, which is used rather than passing the
1654         client to create(). This allows clients to null out the client pointer when they're done
1655         with the renderer.
1656
1657         Fixes <http://webkit.org/b/52749> WKCACFLayerRenderer should be
1658         ref-counted
1659
1660         Reviewed by Simon Fraser.
1661
1662         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.cpp:
1663         (WebCore::MediaPlayerPrivateFullscreenWindow::MediaPlayerPrivateFullscreenWindow):
1664         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h:
1665         Updated for WKCACFLayerRenderer changes.
1666
1667         * platform/graphics/win/WKCACFLayerRenderer.cpp:
1668         (WebCore::WKCACFLayerRenderer::acceleratedCompositingAvailable): Updated for changes to
1669         create().
1670         (WebCore::WKCACFLayerRenderer::create): No longer takes a WKCACFLayerRendererClient. Now
1671         returns a PassOwnPtr.
1672         (WebCore::WKCACFLayerRenderer::WKCACFLayerRenderer): No longer takes a
1673         WKCACFLayerRendererClient.
1674
1675         * platform/graphics/win/WKCACFLayerRenderer.h: Made WKCACFLayerRenderer inherit from
1676         RefCounted.
1677         (WebCore::WKCACFLayerRenderer::setClient): Added this simple setter.
1678
1679 2011-01-20  Csaba Osztrogonác  <ossy@webkit.org>
1680
1681         [Qt][V8] Unreviewed buildfix after r76248.
1682
1683         * bindings/v8/ScriptCachedFrameData.h: Add missing include.
1684
1685 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
1686
1687         Reviewed by Yury Semikhatsky.
1688
1689         Web Inspector: enable resource agent upon request.
1690         https://bugs.webkit.org/show_bug.cgi?id=52815
1691
1692         We should not send network-related notifications unless front-end
1693         is interested.
1694
1695         * inspector/Inspector.idl:
1696         * inspector/InspectorController.cpp:
1697         (WebCore::InspectorController::restoreInspectorStateFromCookie):
1698         (WebCore::InspectorController::connectFrontend):
1699         (WebCore::InspectorController::resourceAgent):
1700         * inspector/InspectorController.h:
1701         (WebCore::InspectorController::consoleAgent):
1702         (WebCore::InspectorController::cssAgent):
1703         (WebCore::InspectorController::domAgent):
1704         (WebCore::InspectorController::injectedScriptAgent):
1705         (WebCore::InspectorController::runtimeAgent):
1706         (WebCore::InspectorController::databaseAgent):
1707         (WebCore::InspectorController::domStorageAgent):
1708         (WebCore::InspectorController::fileSystemAgent):
1709         * inspector/InspectorInstrumentation.cpp:
1710         (WebCore::InspectorInstrumentation::retrieveResourceAgent):
1711         * inspector/InspectorResourceAgent.cpp:
1712         (WebCore::InspectorResourceAgent::restore):
1713         (WebCore::InspectorResourceAgent::~InspectorResourceAgent):
1714         (WebCore::InspectorResourceAgent::InspectorResourceAgent):
1715         * inspector/InspectorResourceAgent.h:
1716         (WebCore::InspectorResourceAgent::create):
1717         * inspector/InspectorState.cpp:
1718         (WebCore::InspectorState::InspectorState):
1719         * inspector/InspectorState.h:
1720
1721 2011-01-20  Zoltan Horvath  <zoltan@webkit.org>
1722
1723         Reviewed by Csaba Osztrogonác.
1724
1725         Refactoring of the custom allocation framework
1726         https://bugs.webkit.org/show_bug.cgi?id=49897
1727
1728         Inheriting from FastAllocBase can result in objects getting larger (bug #33896, #46589).
1729         The modification replaces Noncopyable and FastAllocBase classes and these inherits with their
1730         equivalent macro implementation at the necessary places.
1731
1732 2011-01-20  Mikhail Naganov  <mnaganov@chromium.org>
1733
1734         Reviewed by Pavel Feldman.
1735
1736         Web Inspector: [Chromium] CPU Profiles are cleared when navigating back and forth.
1737
1738         Profiles are now not cleared unless renderer instance was changed.
1739
1740         https://bugs.webkit.org/show_bug.cgi?id=52807
1741
1742         * inspector/InspectorController.cpp:
1743         (WebCore::InspectorController::restoreProfiler):
1744         * inspector/InspectorProfilerAgent.cpp:
1745         (WebCore::InspectorProfilerAgent::resetState):
1746         (WebCore::InspectorProfilerAgent::resetFrontendProfiles):
1747         * inspector/InspectorProfilerAgent.h:
1748
1749 2011-01-20  Alexander Pavlov  <apavlov@chromium.org>
1750
1751         Unreviewed, add new JS file refs missing from r76116.
1752
1753         * WebCore.gypi:
1754         * WebCore.vcproj/WebCore.vcproj:
1755         * inspector/front-end/WebKit.qrc:
1756
1757 2011-01-20  Alexander Pavlov  <apavlov@chromium.org>
1758
1759         Reviewed by Pavel Feldman.
1760
1761         Web Inspector: Crash when adding a rule for an ImageDocument
1762         https://bugs.webkit.org/show_bug.cgi?id=52811
1763
1764         * inspector/InspectorCSSAgent.cpp:
1765         (WebCore::InspectorCSSAgent::addRule2):
1766         (WebCore::InspectorCSSAgent::viaInspectorStyleSheet):
1767
1768 2011-01-20  Ilya Tikhonovsky  <loislo@chromium.org>
1769
1770         Reviewed by Pavel Feldman.
1771
1772         Web Inspector: cleanup InspectorController's friends list.
1773         We have a plan to extract InspectorAgent from InspectorController.
1774         InspectorAgent will be accessible only from InspectorController.
1775         As result we can simply made some methods public and remove long
1776         friends list.
1777
1778         https://bugs.webkit.org/show_bug.cgi?id=52806
1779
1780         * inspector/InjectedScriptHost.cpp:
1781         (WebCore::InjectedScriptHost::databaseForId):
1782         (WebCore::InjectedScriptHost::selectDatabase):
1783         (WebCore::InjectedScriptHost::selectDOMStorage):
1784         (WebCore::InjectedScriptHost::inspectorDOMAgent):
1785         (WebCore::InjectedScriptHost::frontend):
1786         * inspector/InspectorBrowserDebuggerAgent.cpp:
1787         (WebCore::InspectorBrowserDebuggerAgent::setDOMBreakpoint):
1788         (WebCore::InspectorBrowserDebuggerAgent::removeDOMBreakpoint):
1789         (WebCore::InspectorBrowserDebuggerAgent::willInsertDOMNode):
1790         (WebCore::InspectorBrowserDebuggerAgent::willRemoveDOMNode):
1791         (WebCore::InspectorBrowserDebuggerAgent::willModifyDOMAttr):
1792         (WebCore::InspectorBrowserDebuggerAgent::descriptionForDOMEvent):
1793         (WebCore::InspectorBrowserDebuggerAgent::pauseOnNativeEventIfNeeded):
1794         (WebCore::InspectorBrowserDebuggerAgent::willSendXMLHttpRequest):
1795         * inspector/InspectorController.h:
1796         (WebCore::InspectorController::frontend):
1797         * inspector/InspectorInstrumentation.cpp:
1798         (WebCore::InspectorInstrumentation::willInsertDOMNodeImpl):
1799         (WebCore::InspectorInstrumentation::didInsertDOMNodeImpl):
1800         (WebCore::InspectorInstrumentation::willRemoveDOMNodeImpl):
1801         (WebCore::InspectorInstrumentation::didRemoveDOMNodeImpl):
1802         (WebCore::InspectorInstrumentation::willModifyDOMAttrImpl):
1803         (WebCore::InspectorInstrumentation::didModifyDOMAttrImpl):
1804         (WebCore::InspectorInstrumentation::characterDataModifiedImpl):
1805         (WebCore::InspectorInstrumentation::willSendXMLHttpRequestImpl):
1806         (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
1807         (WebCore::InspectorInstrumentation::didFailLoadingImpl):
1808         (WebCore::InspectorInstrumentation::resourceRetrievedByXMLHttpRequestImpl):
1809         (WebCore::InspectorInstrumentation::addStartProfilingMessageToConsoleImpl):
1810         (WebCore::InspectorInstrumentation::pauseOnNativeEventIfNeeded):
1811         (WebCore::InspectorInstrumentation::cancelPauseOnNativeEvent):
1812         (WebCore::InspectorInstrumentation::retrieveTimelineAgent):
1813         (WebCore::InspectorInstrumentation::retrieveResourceAgent):
1814
1815 2011-01-19  Pavel Podivilov  <podivilov@chromium.org>
1816
1817         Reviewed by Yury Semikhatsky.
1818
1819         Web Inspector: implement JavaScriptBreakpointsSidebarPane based on events from debugger model.
1820         https://bugs.webkit.org/show_bug.cgi?id=52723
1821
1822         Extract all breakpoints-related presentation code from debugger model to JavaScriptBreakpointSidebarPane.
1823
1824         * inspector/front-end/Breakpoint.js:
1825         (WebInspector.Breakpoint):
1826         (WebInspector.Breakpoint.prototype.get data):
1827         (WebInspector.Breakpoint.prototype.remove):
1828         * inspector/front-end/BreakpointsSidebarPane.js:
1829         (WebInspector.JavaScriptBreakpointsSidebarPane):
1830         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointAdded):
1831         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointRemoved):
1832         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointEnableChanged):
1833         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointItemCheckboxClicked):
1834         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._contextMenuEventFired):
1835         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._debuggerPaused):
1836         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._debuggerResumed):
1837         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._addListElement):
1838         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._removeListElement):
1839         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._projectChanged):
1840         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._compare):
1841         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._compareBreakpoints):
1842         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._setupBreakpointElement.didGetSourceLine):
1843         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._setupBreakpointElement):
1844         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointIdForDebuggerPausedEvent):
1845         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._setBreakpointEnabled):
1846         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._removeBreakpoint):
1847         (WebInspector.NativeBreakpointsSidebarPane):
1848         (WebInspector.XHRBreakpointsSidebarPane.prototype.addBreakpointItem):
1849         * inspector/front-end/DebuggerModel.js:
1850         (WebInspector.DebuggerModel.prototype.removeBreakpoint):
1851         (WebInspector.DebuggerModel.prototype.breakpointForId):
1852         (WebInspector.DebuggerModel.prototype._pausedScript):
1853         (WebInspector.DebuggerModel.prototype._resumedScript):
1854         * inspector/front-end/ScriptsPanel.js:
1855         (WebInspector.ScriptsPanel):
1856         * inspector/front-end/inspector.js:
1857
1858 2011-01-20  Dirk Schulze  <krit@webkit.org>
1859
1860         Reviewed by Andreas Kling.
1861
1862         SVG Pattern doesn't take the viewBox of a referenced Pattern
1863         https://bugs.webkit.org/show_bug.cgi?id=52804
1864         
1865         SVGPattern element didn't use the viewBox of another SVGPattern element, referenced
1866         by xlink:href. Modified PatternAttributes, to take the value of the viewBox of the
1867         SVGPattern element as well, if the attribute was set.
1868         This gets checked by a W3C SVG test case.        
1869
1870         Test: svg/W3C-SVG-1.1-SE/pservers-pattern-04-f.svg
1871
1872         * rendering/svg/RenderSVGResourcePattern.cpp:
1873         (WebCore::RenderSVGResourcePattern::buildTileImageTransform):
1874         * svg/PatternAttributes.h:
1875         (WebCore::PatternAttributes::PatternAttributes):
1876         (WebCore::PatternAttributes::viewBox):
1877         (WebCore::PatternAttributes::setViewBox):
1878         (WebCore::PatternAttributes::hasViewBox):
1879         * svg/SVGPatternElement.cpp:
1880         (WebCore::SVGPatternElement::collectPatternAttributes):
1881
1882 2011-01-19  Stephen White  <senorblanco@chromium.org>
1883
1884         [Re-land of r76159 with a compile fix for the Chromium linux shlib
1885         build.]
1886
1887         Reviewed by James Robinson.
1888
1889         Implement accelerated path drawing and clipping for the Canvas2D GPU
1890         path.
1891         https://bugs.webkit.org/show_bug.cgi?id=52627
1892         
1893         This is done with a simple curve interpolator and the GLU tesselator,
1894         which is good enough for a 3-5X speedup on
1895         http://ie.microsoft.com/testdrive/Performance/Galactic/Default.html.
1896
1897         Covered by canvas/philip/2d.path.clip.basic.html, and many, many more.
1898         All tests canvas/philip and fast/canvas paths pass with no
1899         regressions, although two have minor pixel differences which require
1900         rebaselining.
1901
1902         * WebCore.gyp/WebCore.gyp:
1903         Add internal_glu include path to chromium build.
1904         * WebCore.gypi:
1905         Add internal_glu files to chromium build.
1906         * html/canvas/CanvasRenderingContext2D.cpp:
1907         (WebCore::CanvasRenderingContext2D::reset):
1908         (WebCore::CanvasRenderingContext2D::platformLayer):
1909         Make CanvasRenderingContext2D more robust against failure to create
1910         a DrawingBuffer.
1911         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1912         (WebCore::DrawingBuffer::DrawingBuffer):
1913         As in DrawingBufferMac.cpp, call reset() from the constructor.
1914         Also initialize size to (-1, -1), so reset() doesn't early-out.
1915         Add initializers for depthBuffer and stencilBuffer, and remove
1916         multisampleDepthStencilBuffer.
1917         * platform/graphics/chromium/GLES2Canvas.cpp:
1918         Remove some unused #includes.
1919         (WebCore::GLES2Canvas::State::State):
1920         Add clipping state, and implement save/restore via the copy constructor.
1921         (WebCore::operator*):
1922         (WebCore::Quadratic::Quadratic):
1923         (WebCore::Quadratic::fromBezier):
1924         (WebCore::Quadratic::evaluate):
1925         Quadratic Bezier curve class.
1926         (WebCore::Cubic::Cubic):
1927         (WebCore::Cubic::fromBezier):
1928         (WebCore::Cubic::evaluate):
1929         Cubic Bezier curve class.
1930         (WebCore::GLES2Canvas::clearRect):
1931         Add clipping support to clearRect().
1932         (WebCore::GLES2Canvas::fillPath):
1933         Implement fillPath().
1934         (WebCore::GLES2Canvas::fillRect):
1935         Add clipping support to fillRect().
1936         (WebCore::GLES2Canvas::clipPath):
1937         Implement clipPath().
1938         (WebCore::GLES2Canvas::clipOut):
1939         Stub out clipOut() (not called by Canvas 2D).
1940         (WebCore::GLES2Canvas::restore):
1941         When restoring, draw any remaining clipping paths to the stencil buffer.
1942         (WebCore::GLES2Canvas::drawTexturedRect):
1943         Add clipping support.
1944         (WebCore::interpolateQuadratic):
1945         (WebCore::interpolateCubic):
1946         Simple curve interpolation, using the Cubic and Quadratic classes.
1947         (WebCore::PolygonData::PolygonData):
1948         A struct to hold the tesselation data for callbacks.
1949         (WebCore::beginData):
1950         (WebCore::edgeFlagData):
1951         (WebCore::vertexData):
1952         (WebCore::endData):
1953         (WebCore::combineData):
1954         internal_glu tesselation callbacks.
1955         (WebCore::GLES2Canvas::createVertexBufferFromPath):
1956         Build an interpolated, tesselated vertex buffer and element array buffer from a given path, suitable for filling.
1957         (WebCore::GLES2Canvas::beginStencilDraw):
1958         Enable stencilling, and disable draws to the color buffer.
1959         (WebCore::GLES2Canvas::applyClipping):
1960         If clipping is enabled, set the appropriate GL state.
1961         * platform/graphics/chromium/GLES2Canvas.h:
1962         Document the flavours of drawTexturedRect() a bit, so I don't get confused.
1963         * platform/graphics/gpu/DrawingBuffer.cpp:
1964         (WebCore::DrawingBuffer::clear):
1965         (WebCore::DrawingBuffer::createSecondaryBuffers):
1966         (WebCore::DrawingBuffer::resizeDepthStencil):
1967         (WebCore::DrawingBuffer::reset):
1968         * platform/graphics/gpu/DrawingBuffer.h:
1969         Unify m_multisampleDepthStencilBuffer with m_depthStencilBuffer. 
1970         Implement separate depth and stencil buffers for when
1971         OES_packed_depth_stencil is not available.  Refactor creation of
1972         multisampled and non-multisampled depth and stencil buffers into
1973         resizeDepthStencil().
1974         * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
1975         (WebCore::SharedGraphicsContext3D::create):
1976         Turn on stencil, turn off depth, turn off antialiasing (for now).
1977         (WebCore::SharedGraphicsContext3D::enableStencil):
1978         * platform/graphics/gpu/SharedGraphicsContext3D.h:
1979         Implement stencil enable/disable.
1980         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
1981         (WebCore::DrawingBuffer::DrawingBuffer):
1982         Remove m_multisampleDepthStencilBuffer.  Set the size to (-1, -1)
1983         on creation, so reset() doesn't early-out.  Initialize m_depthBuffer
1984         and m_stencilBuffer.
1985         * platform/graphics/skia/GraphicsContextSkia.cpp:
1986         (WebCore::GraphicsContext::canvasClip):
1987         (WebCore::GraphicsContext::clipOut):
1988         (WebCore::GraphicsContext::clipPath):
1989         (WebCore::GraphicsContext::fillPath):
1990         Put in GPU hooks for path clipping, and path drawing.
1991         * platform/graphics/skia/PlatformContextSkia.cpp:
1992         (WebCore::PlatformContextSkia::canAccelerate):
1993         Don't check for clipping paths in canAccelerate() (since we can
1994         now accelerate them).
1995         (WebCore::PlatformContextSkia::uploadSoftwareToHardware):
1996         Don't do clipping when uploading software draws to hardware.
1997         * thirdparty/glu/README.webkit:
1998         * thirdparty/glu/gluos.h:
1999         #undef MIN and MAX, to fix warnings-as-errors in Chrome/Mac build.
2000         * thirdparty/glu/libtess/geom.c:
2001         * thirdparty/glu/libtess/priorityq.c:
2002         * thirdparty/glu/libtess/render.c:
2003         Use do{}while(0) instead of if(1)else construct in macro.
2004         * thirdparty/glu/libtess/sweep.c:
2005         (IsWindingInside):
2006         (DoneEdgeDict):
2007         Fix some warnings treated as errors for the Linux Release build.
2008
2009
2010 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
2011
2012         Web Inspector: move releaseObjectGroup to the new Runtime agent.
2013         https://bugs.webkit.org/show_bug.cgi?id=52803
2014         (accedentally landed as r76231)
2015
2016         * inspector/InspectorContorller.h:
2017         * inspector/InspectorContorller.cpp:
2018         * inspector/InspectorRuntimeAgent.h:
2019         * inspector/InspectorRuntimeAgent.cpp:
2020
2021 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
2022
2023         Not reviewed: build fix.
2024
2025         * inspector/InspectorState.h:
2026         (WebCore::InspectorState::setBoolean):
2027         (WebCore::InspectorState::setString):
2028         (WebCore::InspectorState::setLong):
2029
2030 2011-01-20  Pavel Feldman  <pfeldman@chromium.org>
2031
2032         Reviewed by Yury Semikhatsky.
2033
2034         Web Inspector: further simplify InspectorState.
2035         https://bugs.webkit.org/show_bug.cgi?id=52731
2036
2037         This change moves XHR logging flag into console agent,
2038         removes InspectorState pushing to the front-end.
2039
2040         * inspector/Inspector.idl:
2041         * inspector/InspectorConsoleAgent.cpp:
2042         (WebCore::InspectorConsoleAgent::InspectorConsoleAgent):
2043         (WebCore::InspectorConsoleAgent::resourceRetrievedByXMLHttpRequest):
2044         (WebCore::InspectorConsoleAgent::setMonitoringXHREnabled):
2045         (WebCore::InspectorConsoleAgent::setConsoleMessagesEnabled):
2046         (WebCore::InspectorConsoleAgent::addConsoleMessage):
2047         * inspector/InspectorConsoleAgent.h:
2048         * inspector/InspectorController.cpp:
2049         (WebCore::InspectorController::InspectorController):
2050         * inspector/InspectorController.h:
2051         (WebCore::InspectorController::state):
2052         (WebCore::InspectorController::settings):
2053         * inspector/InspectorState.cpp:
2054         (WebCore::InspectorState::InspectorState):
2055         (WebCore::InspectorState::registerBoolean):
2056         (WebCore::InspectorState::registerString):
2057         (WebCore::InspectorState::registerLong):
2058         (WebCore::InspectorState::registerObject):
2059         (WebCore::InspectorState::Property::create):
2060         * inspector/InspectorState.h:
2061         * inspector/front-end/ConsoleView.js:
2062         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.consoleMessagesCleared):
2063         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.monitoringXHRStateChanged):
2064         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher):
2065         (WebInspector.ConsoleView.prototype._handleContextMenuEvent):
2066         * inspector/front-end/inspector.js:
2067
2068 2011-01-20  Csaba Osztrogonác  <ossy@webkit.org>
2069
2070         Unreviewed buildfix.
2071
2072         [Qt][V8] Remove unnecessary files after r76224.
2073
2074         * WebCore.pro:
2075
2076 2011-01-20  Ilya Tikhonovsky  <loislo@chromium.org>
2077
2078         Reviewed by Yury Semikhatsky.
2079
2080         Web Inspector: prepare for extracting InspectorAgent from InspectorController.
2081         https://bugs.webkit.org/show_bug.cgi?id=52797
2082
2083         * inspector/CodeGeneratorInspector.pm:
2084         * inspector/InspectorController.h:
2085         (WebCore::InspectorController::inspectorAgent):
2086         (WebCore::InspectorController::cssAgent):
2087         (WebCore::InspectorController::injectedScriptAgent):
2088         (WebCore::InspectorController::resourceAgent):
2089         (WebCore::InspectorController::runtimeAgent):
2090         (WebCore::InspectorController::timelineAgent):
2091         (WebCore::InspectorController::databaseAgent):
2092         (WebCore::InspectorController::domStorageAgent):
2093         (WebCore::InspectorController::fileSystemAgent):
2094         (WebCore::InspectorController::browserDebuggerAgent):
2095         (WebCore::InspectorController::debuggerAgent):
2096         (WebCore::InspectorController::profilerAgent):
2097         (WebCore::InspectorController::applicationCacheAgent):
2098
2099 2011-01-20  Sheriff Bot  <webkit.review.bot@gmail.com>
2100
2101         Unreviewed, rolling out r76215.
2102         http://trac.webkit.org/changeset/76215
2103         https://bugs.webkit.org/show_bug.cgi?id=52799
2104
2105         Caused regressions in Chromium; morrita is going to look at it
2106         tomrorow (Requested by jorlow on #webkit).
2107
2108         * dom/TextEvent.h:
2109         * dom/TextEventInputType.h:
2110         * editing/CompositeEditCommand.cpp:
2111         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt):
2112         * editing/CompositeEditCommand.h:
2113         * editing/Editor.cpp:
2114         (WebCore::Editor::insertTextWithoutSendingTextEvent):
2115         (WebCore::Editor::confirmComposition):
2116         (WebCore::Editor::setComposition):
2117         * editing/Editor.h:
2118         * editing/InsertTextCommand.cpp:
2119         (WebCore::InsertTextCommand::input):
2120         * editing/InsertTextCommand.h:
2121         * editing/TypingCommand.cpp:
2122         (WebCore::TypingCommand::TypingCommand):
2123         (WebCore::TypingCommand::insertText):
2124         (WebCore::TypingCommand::insertTextRunWithoutNewlines):
2125         * editing/TypingCommand.h:
2126         (WebCore::TypingCommand::create):
2127
2128 2010-12-14  Yury Semikhatsky  <yurys@chromium.org>
2129
2130         Reviewed by Adam Barth.
2131
2132         [V8] Get rid of delayed exception reporting in V8ConsoleMessage.cpp
2133         https://bugs.webkit.org/show_bug.cgi?id=51044
2134
2135         * WebCore.gypi:
2136         * bindings/v8/V8ConsoleMessage.cpp: Removed.
2137         * bindings/v8/V8ConsoleMessage.h: Removed.
2138         * bindings/v8/V8DOMWindowShell.cpp:
2139         (WebCore::v8UncaughtExceptionHandler):
2140         (WebCore::reportUnsafeJavaScriptAccess):
2141         (WebCore::V8DOMWindowShell::initContextIfNeeded):
2142         * bindings/v8/V8Proxy.cpp:
2143         (WebCore::addMessageToConsole):
2144         (WebCore::logInfo):
2145         (WebCore::V8Proxy::reportUnsafeAccessTo):
2146         (WebCore::V8Proxy::runScript):
2147         (WebCore::V8Proxy::callFunction):
2148         (WebCore::V8Proxy::newInstance):
2149         * bindings/v8/V8Proxy.h:
2150         * bindings/v8/WorkerContextExecutionProxy.cpp:
2151         * bindings/v8/specialization/V8BindingState.cpp:
2152         (WebCore::::immediatelyReportUnsafeAccessTo):
2153
2154 2011-01-19  MORITA Hajime  <morrita@google.com>
2155
2156         Reviewed by Eric Seidel.
2157
2158         ShadowElement::m_shadowParent should be removed
2159         https://bugs.webkit.org/show_bug.cgi?id=52558
2160
2161         No new tests. No behavioral change.
2162
2163         * rendering/ShadowElement.h:
2164         (WebCore::ShadowElement::ShadowElement):
2165
2166 2011-01-20  Hans Wennborg  <hans@chromium.org>
2167
2168         Reviewed by Jeremy Orlow.
2169
2170         IndexedDB: IDBObjectStore.get should fire onsuccess rather than onerror
2171         https://bugs.webkit.org/show_bug.cgi?id=52725
2172
2173         Let IDBObjectStore.get() fire the onsuccess handler with the value
2174         'undefined' for when an object does not exist in the store.
2175
2176         Update SerializedScriptValue to provide such an undefined value.
2177
2178         * bindings/v8/SerializedScriptValue.cpp:
2179         (WebCore::SerializedScriptValue::nullValue):
2180         (WebCore::SerializedScriptValue::undefinedValue):
2181         * bindings/v8/SerializedScriptValue.h:
2182         * storage/IDBObjectStoreBackendImpl.cpp:
2183         (WebCore::IDBObjectStoreBackendImpl::getInternal):
2184
2185 2010-12-27  Yury Semikhatsky  <yurys@chromium.org>
2186
2187         Reviewed by Pavel Feldman.
2188
2189         WebCore doesn't fire window.onerror event when uncaught JavaScript exceptions are thrown
2190         https://bugs.webkit.org/show_bug.cgi?id=8519
2191
2192         Uncaught exceptions are propagated to window.onerror hander if one is present.
2193         The handler is expected to be a function accepting three arguments: error message,
2194         resource url and line number where the exception occured.
2195
2196         It was decided to dispatch ErrorEvent to all listeners/handlers no matter if they
2197         were created in the same isolated world where the exception occured or not.
2198
2199         Tests: fast/events/window-onerror1.html
2200                fast/events/window-onerror10.html
2201                fast/events/window-onerror11.html
2202                fast/events/window-onerror12.html
2203                fast/events/window-onerror2.html
2204                fast/events/window-onerror3.html
2205                fast/events/window-onerror4.html
2206                fast/events/window-onerror5.html
2207                fast/events/window-onerror6.html
2208                fast/events/window-onerror7.html
2209                fast/events/window-onerror8.html
2210                fast/events/window-onerror9.html
2211                http/tests/security/window-onerror-exception-in-iframe.html
2212                userscripts/window-onerror-for-isolated-world-1.html
2213                userscripts/window-onerror-for-isolated-world-2.html
2214
2215         * Android.jscbindings.mk:
2216         * CMakeLists.txt:
2217         * GNUmakefile.am:
2218         * WebCore.gypi:
2219         * WebCore.order:
2220         * WebCore.pro:
2221         * WebCore.vcproj/WebCore.vcproj:
2222         * WebCore.xcodeproj/project.pbxproj:
2223         * bindings/js/JSBindingsAllInOne.cpp:
2224         * bindings/js/JSDOMBinding.cpp:
2225         (WebCore::reportException):
2226         * bindings/js/JSErrorHandler.cpp: Renamed from WebCore/bindings/js/JSWorkerContextErrorHandler.cpp.
2227         (WebCore::JSErrorHandler::JSErrorHandler):
2228         (WebCore::JSErrorHandler::~JSErrorHandler):
2229         (WebCore::JSErrorHandler::handleEvent):
2230         * bindings/js/JSErrorHandler.h: Copied from WebCore/bindings/js/JSWorkerContextErrorHandler.h.
2231         (WebCore::JSErrorHandler::create):
2232         (WebCore::createJSErrorHandler):
2233         * bindings/js/JSEventListener.h:
2234         * bindings/scripts/CodeGeneratorJS.pm:
2235         * bindings/scripts/CodeGeneratorV8.pm:
2236         * bindings/v8/V8ConsoleMessage.cpp:
2237         (WebCore::V8ConsoleMessage::dispatchNow):
2238         (WebCore::V8ConsoleMessage::handler): the method was changed to use generic WebCore exception
2239         reporting mechanism which is also used by JSC bindings.
2240         * bindings/v8/V8ConsoleMessage.h:
2241         * bindings/v8/V8EventListener.h:
2242         * bindings/v8/V8WindowErrorHandler.cpp: Renamed from WebCore/bindings/js/JSWorkerContextErrorHandler.h.
2243         (WebCore::V8WindowErrorHandler::V8WindowErrorHandler):
2244         (WebCore::V8WindowErrorHandler::callListenerFunction):
2245         * bindings/v8/V8WindowErrorHandler.h: Copied from WebCore/dom/ErrorEvent.cpp.
2246         (WebCore::V8WindowErrorHandler::create):
2247         * bindings/v8/WorkerContextExecutionProxy.cpp:
2248         (WebCore::v8MessageHandler):
2249         * bindings/v8/WorkerScriptController.cpp:
2250         (WebCore::WorkerScriptController::evaluate):
2251         * dom/Document.cpp:
2252         (WebCore::Document::errorEventTarget):
2253         (WebCore::Document::logExceptionToConsole):
2254         (WebCore::Document::addMessage):
2255         * dom/Document.h:
2256         * dom/ErrorEvent.cpp:
2257         * dom/ErrorEvent.h:
2258         * dom/Event.cpp:
2259         (WebCore::Event::isErrorEvent):
2260         * dom/Event.h:
2261         * dom/ScriptExecutionContext.cpp:
2262         (WebCore::ScriptExecutionContext::PendingException::PendingException):
2263         (WebCore::ScriptExecutionContext::ScriptExecutionContext):
2264         (WebCore::ScriptExecutionContext::reportException): this method is not virtual anymore to
2265         ensure that error event dispatching algorithm is the same in WorkerContext and in Document.
2266         (WebCore::ScriptExecutionContext::dispatchErrorEvent):
2267         * dom/ScriptExecutionContext.h:
2268         * websockets/WebSocket.cpp:
2269         (WebCore::WebSocket::connect):
2270         * websockets/WebSocketChannel.cpp:
2271         (WebCore::WebSocketChannel::didOpen):
2272         (WebCore::WebSocketChannel::didFail):
2273         (WebCore::WebSocketChannel::appendToBuffer):
2274         * websockets/WebSocketHandshake.cpp:
2275         (WebCore::WebSocketHandshake::readServerHandshake):
2276         (WebCore::WebSocketHandshake::readStatusLine):
2277         (WebCore::WebSocketHandshake::readHTTPHeaders):
2278         (WebCore::WebSocketHandshake::checkResponseHeaders):
2279         * workers/DefaultSharedWorkerRepository.cpp:
2280         (WebCore::postExceptionTask):
2281         (WebCore::postConsoleMessageTask):
2282         * workers/WorkerContext.cpp:
2283         (WebCore::WorkerContext::WorkerContext):
2284         (WebCore::WorkerContext::errorEventTarget):
2285         (WebCore::WorkerContext::logExceptionToConsole):
2286         (WebCore::WorkerContext::addMessage):
2287         * workers/WorkerContext.h:
2288         * workers/WorkerMessagingProxy.cpp:
2289         (WebCore::WorkerExceptionTask::performTask):
2290         (WebCore::postConsoleMessageTask):
2291         * xml/XMLHttpRequest.cpp:
2292         (WebCore::reportUnsafeUsage):
2293
2294 2011-01-19  MORITA Hajime  <morrita@google.com>
2295
2296         Reviewed by Ryosuke Niwa.
2297
2298         Space and tab characters "sent" by an input method give totally different results than typing them directly
2299         https://bugs.webkit.org/show_bug.cgi?id=5241
2300         
2301         * Introduced TextEvent::InputTypeComposition and TypingCommand::TextCompositionType to 
2302           distinguish text input which is originated by composition.
2303         * Generalized rebalanceWhitespaceAt() to rebalanceWhitespaceOnTextSubstring() to rebalancing 
2304           range of string on text node, instead of surrounding part of that.
2305
2306         Test: editing/inserting/insert-composition-whitespace.html
2307
2308         * dom/TextEvent.h:
2309         (WebCore::TextEvent::isComposition):
2310         * dom/TextEventInputType.h: Added TextEventInputComposition as a member of TextEvent::InputType
2311         * editing/CompositeEditCommand.cpp:
2312         (WebCore::containsOnlyWhitespace):
2313         (WebCore::CompositeEditCommand::shouldRebalanceLeadingWhitespaceFor):
2314         (WebCore::CompositeEditCommand::canRebalance):
2315         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt):
2316         (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring): Added: A generalized version of rebalanceWhitespaceAt(), which takes a range inside Text string.
2317         * editing/CompositeEditCommand.h:
2318         * editing/Editor.cpp:
2319         (WebCore::Editor::insertTextForConfirmedComposition): Added.
2320         (WebCore::Editor::insertTextWithoutSendingTextEvent):
2321         (WebCore::Editor::confirmComposition): Now uses insertTextForConfirmedComposition().
2322         (WebCore::Editor::setComposition):
2323         * editing/Editor.h:
2324         * editing/InsertTextCommand.cpp:
2325         (WebCore::InsertTextCommand::input):
2326         * editing/InsertTextCommand.h:
2327         * editing/TypingCommand.cpp:
2328         (WebCore::TypingCommand::TypingCommand):
2329         (WebCore::TypingCommand::insertText):
2330         (WebCore::TypingCommand::insertTextRunWithoutNewlines):
2331         * editing/TypingCommand.h: Added TypingCommand::m_compositionType and TypingCommand::TextCompositionType
2332         (WebCore::TypingCommand::setCompositionType): Added.
2333         (WebCore::TypingCommand::create):
2334
2335 2011-01-19  Dominic Cooney  <dominicc@google.com>
2336
2337         Reviewed by Kent Tamura.
2338
2339         Make <keygen> no longer appear to be a <select> element to script.
2340         https://bugs.webkit.org/show_bug.cgi?id=52557
2341
2342         The intent is to put <keygen> options into shadow DOM. This change
2343         takes the first step by hiding the <select> element from
2344         JavaScript.
2345
2346         Test: fast/dom/HTMLKeygenElement/keygen.html
2347
2348         * CMakeLists.txt: Adds new IDL-derived wrapper.
2349         * DerivedSources.cpp:
2350         * DerivedSources.make:
2351         * GNUmakefile.am:
2352         * WebCore.gypi:
2353         * WebCore.pri:
2354         * WebCore.vcproj/WebCore.vcproj:
2355         * WebCore.xcodeproj/project.pbxproj:
2356         * bindings/gobject/GNUmakefile.am:
2357         * bindings/gobject/WebKitHTMLElementWrapperFactory.cpp:
2358         (WebKit::createKeygenWrapper):
2359         (WebKit::createHTMLElementWrapper):
2360         * bindings/objc/DOM.mm:
2361         (WebCore::createElementClassMap): Keygen no longer DOMHTMLSelectElement
2362         * html/HTMLKeygenElement.h:
2363         (WebCore::HTMLKeygenElement::willValidate): Now public.
2364         * html/HTMLKeygenElement.idl: Added.
2365         * html/HTMLTagNames.in: Keygen's wrapper is HTMLKeygenElement.
2366         * page/DOMWindow.idl: Add HTMLKeygenElement constructor.
2367
2368 2011-01-19  Sheriff Bot  <webkit.review.bot@gmail.com>
2369
2370         Unreviewed, rolling out r76203.
2371         http://trac.webkit.org/changeset/76203
2372         https://bugs.webkit.org/show_bug.cgi?id=52784
2373
2374         Broke Win compile on Chromium bots (Requested by dimich on
2375         #webkit).
2376
2377         * WebCore.gypi:
2378         * bindings/v8/V8DOMWindowShell.cpp:
2379         (WebCore::reportFatalErrorInV8):
2380         * page/PageGroup.cpp:
2381         (WebCore::PageGroup::isLinkVisited):
2382         * platform/android/PlatformBridge.h:
2383         * platform/audio/chromium/AudioBusChromium.cpp:
2384         (WebCore::createBusFromInMemoryAudioFile):
2385         * platform/chromium/ChromiumBridge.h: Added.
2386         * platform/chromium/ChromiumDataObjectLegacy.cpp:
2387         (WebCore::ChromiumDataObjectLegacy::getData):
2388         * platform/chromium/DragDataChromium.cpp:
2389         (WebCore::DragData::asURL):
2390         * platform/chromium/FileSystemChromium.cpp:
2391         (WebCore::deleteFile):
2392         (WebCore::deleteEmptyDirectory):
2393         (WebCore::getFileSize):
2394         (WebCore::getFileModificationTime):
2395         (WebCore::revealFolderInOS):
2396         (WebCore::directoryName):
2397         (WebCore::pathByAppendingComponent):
2398         (WebCore::makeAllDirectories):
2399         (WebCore::fileExists):
2400         (WebCore::openFile):
2401         (WebCore::closeFile):
2402         (WebCore::seekFile):
2403         (WebCore::truncateFile):
2404         (WebCore::readFromFile):
2405         (WebCore::writeToFile):
2406         * platform/chromium/LanguageChromium.cpp:
2407         (WebCore::platformDefaultLanguage):
2408         * platform/chromium/LinkHashChromium.cpp:
2409         (WebCore::visitedLinkHash):
2410         * platform/chromium/MIMETypeRegistryChromium.cpp:
2411         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
2412         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
2413         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
2414         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
2415         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
2416         * platform/chromium/PasteboardChromium.cpp:
2417         (WebCore::Pasteboard::writeSelection):
2418         (WebCore::Pasteboard::writePlainText):
2419         (WebCore::Pasteboard::writeURL):
2420         (WebCore::Pasteboard::writeImage):
2421         (WebCore::Pasteboard::canSmartReplace):
2422         (WebCore::Pasteboard::plainText):
2423         (WebCore::Pasteboard::documentFragment):
2424         * platform/chromium/PlatformBridge.h:
2425         * platform/chromium/PlatformScreenChromium.cpp:
2426         (WebCore::screenDepth):
2427         (WebCore::screenDepthPerComponent):
2428         (WebCore::screenIsMonochrome):
2429         (WebCore::screenRect):
2430         (WebCore::screenAvailableRect):
2431         * platform/chromium/ReadableDataObject.cpp:
2432         (WebCore::ReadableDataObject::getData):
2433         (WebCore::ReadableDataObject::urlTitle):
2434         (WebCore::ReadableDataObject::htmlBaseUrl):
2435         (WebCore::ReadableDataObject::filenames):
2436         (WebCore::ReadableDataObject::ensureTypeCacheInitialized):
2437         * platform/chromium/SSLKeyGeneratorChromium.cpp:
2438         (WebCore::signedPublicKeyAndChallengeString):
2439         * platform/chromium/ScrollbarThemeChromium.cpp:
2440         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
2441         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
2442         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
2443         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
2444         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
2445         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
2446         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
2447         * platform/chromium/ScrollbarThemeChromiumMac.mm:
2448         (WebCore::scrollbarStateToThemeState):
2449         (WebCore::ScrollbarThemeChromiumMac::paint):
2450         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
2451         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
2452         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
2453         (WebCore::ScrollbarThemeChromiumWin::paintButton):
2454         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
2455         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
2456         * platform/chromium/SharedTimerChromium.cpp:
2457         (WebCore::setSharedTimerFiredFunction):
2458         (WebCore::setSharedTimerFireTime):
2459         (WebCore::stopSharedTimer):
2460         * platform/chromium/SuddenTerminationChromium.cpp:
2461         (WebCore::disableSuddenTermination):
2462         (WebCore::enableSuddenTermination):
2463         * platform/chromium/SystemTimeChromium.cpp:
2464         (WebCore::currentTime):
2465         * platform/chromium/WritableDataObject.cpp:
2466         (WebCore::WritableDataObject::setData):
2467         * platform/graphics/chromium/CrossProcessFontLoading.mm:
2468         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
2469         (WebCore::fontContainsCharacter):
2470         (WebCore::FillLogFont):
2471         * platform/graphics/chromium/FontCacheLinux.cpp:
2472         (WebCore::FontCache::getFontDataForCharacters):
2473         * platform/graphics/chromium/FontChromiumWin.cpp:
2474         (WebCore::Font::drawGlyphs):
2475         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
2476         (WebCore::FontPlatformData::scriptFontProperties):
2477         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
2478         (WebCore::FontPlatformData::querySystemForRenderStyle):
2479         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
2480         (WebCore::fillBMPGlyphs):
2481         * platform/graphics/chromium/ImageChromium.cpp:
2482         (WebCore::Image::loadPlatformResource):
2483         * platform/graphics/chromium/ImageChromiumMac.mm:
2484         (WebCore::Image::loadPlatformResource):
2485         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
2486         (WebCore::SimpleFontData::platformInit):
2487         (WebCore::SimpleFontData::determinePitch):
2488         (WebCore::SimpleFontData::platformWidthForGlyph):
2489         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
2490         (WebCore::UniscribeHelperTextRun::tryToPreloadFont):
2491         * platform/graphics/skia/FontCustomPlatformData.cpp:
2492         (WebCore::FontCustomPlatformData::fontPlatformData):
2493         * platform/network/chromium/CookieJarChromium.cpp:
2494         (WebCore::setCookies):
2495         (WebCore::cookies):
2496         (WebCore::cookieRequestHeaderFieldValue):
2497         (WebCore::cookiesEnabled):
2498         (WebCore::getRawCookies):
2499         (WebCore::deleteCookie):
2500         * platform/network/chromium/DNSChromium.cpp:
2501         (WebCore::prefetchDNS):
2502         * platform/qt/PlatformBridge.h:
2503         * platform/sql/chromium/SQLiteFileSystemChromium.cpp:
2504         (WebCore::SQLiteFileSystem::deleteDatabaseFile):
2505         (WebCore::SQLiteFileSystem::getDatabaseFileSize):
2506         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
2507         (chromiumOpen):
2508         (chromiumDelete):
2509         (chromiumAccess):
2510         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
2511         * plugins/chromium/PluginDataChromium.cpp:
2512         (WebCore::PluginCache::plugins):
2513         * rendering/RenderThemeChromiumMac.mm:
2514         (WebCore::RenderThemeChromiumMac::usesTestModeFocusRingColor):
2515         * rendering/RenderThemeChromiumSkia.cpp:
2516         (WebCore::RenderThemeChromiumSkia::caretBlinkInterval):
2517         * rendering/RenderThemeChromiumWin.cpp:
2518         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
2519         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
2520         (WebCore::RenderThemeChromiumWin::platformActiveSelectionForegroundColor):
2521         (WebCore::RenderThemeChromiumWin::systemColor):
2522         (WebCore::RenderThemeChromiumWin::paintButton):
2523         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
2524         (WebCore::menuListButtonWidth):
2525         (WebCore::RenderThemeChromiumWin::paintMenuList):
2526         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
2527         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
2528         (WebCore::RenderThemeChromiumWin::paintProgressBar):
2529         * storage/chromium/IDBFactoryBackendInterface.cpp:
2530         (WebCore::IDBFactoryBackendInterface::create):
2531         (WebCore::IDBFactoryBackendInterface::~IDBFactoryBackendInterface):
2532         * storage/chromium/IDBKeyPathBackendImpl.cpp:
2533         (WebCore::IDBKeyPathBackendImpl::createIDBKeysFromSerializedValuesAndKeyPath):
2534
2535 2011-01-19  Helder Correia  <helder@sencha.com>
2536
2537         Reviewed by Andreas Kling.
2538
2539         [Qt] GraphicsContext::strokePath() paints solid shadows with incorrect alpha
2540         https://bugs.webkit.org/show_bug.cgi?id=52705
2541
2542         This is related to bug 52611. The shadow color alpha must be multiplied
2543         by the context pen alpha. Fixing this results in correct behavior for
2544         Canvas path stroke() and strokeRect() [which relies on stroke()].
2545
2546         Tests: fast/canvas/canvas-strokePath-alpha-shadow.html
2547                fast/canvas/canvas-strokeRect-alpha-shadow.html
2548
2549         * platform/graphics/qt/GraphicsContextQt.cpp:
2550         (WebCore::GraphicsContext::strokePath):
2551
2552 2011-01-19  Darin Fisher  <darin@chromium.org>
2553
2554         Reviewed by Mihai Parparita.
2555
2556         Re-initialize the HistoryItem fully when navigating to a HistoryItem,
2557         or replacing a HistoryItem, results in a different URL.
2558
2559         https://bugs.webkit.org/show_bug.cgi?id=49654
2560
2561         This patch also forces all HistoryItems to record the post-redirect
2562         URL.  Previously, frames would remember the pre-redirect URL.  This is
2563         problematic since other members of the HistoryItem correspond to the
2564         post-redirect URL.
2565
2566         Tests: fast/history/history-replace-updates-current-item.html
2567                http/tests/navigation/redirect-on-back-updates-history-item.html
2568                http/tests/navigation/redirect-on-reload-updates-history-item.html
2569
2570         * history/HistoryItem.cpp:
2571         (WebCore::HistoryItem::HistoryItem):
2572         (WebCore::HistoryItem::reset):
2573         * history/HistoryItem.h:
2574         * loader/HistoryController.cpp:
2575         (WebCore::HistoryController::updateForBackForwardNavigation):
2576         (WebCore::HistoryController::updateForReload):
2577         (WebCore::HistoryController::updateForStandardLoad):
2578         (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
2579         (WebCore::HistoryController::initializeItem):
2580         (WebCore::HistoryController::createItem):
2581         (WebCore::HistoryController::createItemTree):
2582         (WebCore::HistoryController::updateCurrentItem):
2583         * loader/HistoryController.h:
2584
2585 2011-01-19  Adam Klein  <adamk@chromium.org>
2586
2587         Reviewed by Darin Fisher.
2588
2589         [chromium] Rename ChromiumBridge to PlatformBridge
2590         https://bugs.webkit.org/show_bug.cgi?id=52471
2591
2592         No tests added as this is a rename; no change in behavior.
2593
2594         * WebCore.gypi:
2595         * bindings/v8/V8DOMWindowShell.cpp:
2596         (WebCore::reportFatalErrorInV8):
2597         * page/PageGroup.cpp:
2598         (WebCore::PageGroup::isLinkVisited):
2599         * platform/android/PlatformBridge.h:
2600         * platform/audio/chromium/AudioBusChromium.cpp:
2601         (WebCore::createBusFromInMemoryAudioFile):
2602         * platform/chromium/ChromiumBridge.h: Removed.
2603         * platform/chromium/ChromiumDataObjectLegacy.cpp:
2604         (WebCore::ChromiumDataObjectLegacy::getData):
2605         * platform/chromium/DragDataChromium.cpp:
2606         (WebCore::DragData::asURL):
2607         * platform/chromium/FileSystemChromium.cpp:
2608         (WebCore::deleteFile):
2609         (WebCore::deleteEmptyDirectory):
2610         (WebCore::getFileSize):
2611         (WebCore::getFileModificationTime):
2612         (WebCore::revealFolderInOS):
2613         (WebCore::directoryName):
2614         (WebCore::pathByAppendingComponent):
2615         (WebCore::makeAllDirectories):
2616         (WebCore::fileExists):
2617         (WebCore::openFile):
2618         (WebCore::closeFile):
2619         (WebCore::seekFile):
2620         (WebCore::truncateFile):
2621         (WebCore::readFromFile):
2622         (WebCore::writeToFile):
2623         * platform/chromium/LanguageChromium.cpp:
2624         (WebCore::platformDefaultLanguage):
2625         * platform/chromium/LinkHashChromium.cpp:
2626         (WebCore::visitedLinkHash):
2627         * platform/chromium/MIMETypeRegistryChromium.cpp:
2628         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
2629         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
2630         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
2631         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
2632         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
2633         * platform/chromium/PasteboardChromium.cpp:
2634         (WebCore::Pasteboard::writeSelection):
2635         (WebCore::Pasteboard::writePlainText):
2636         (WebCore::Pasteboard::writeURL):
2637         (WebCore::Pasteboard::writeImage):
2638         (WebCore::Pasteboard::canSmartReplace):
2639         (WebCore::Pasteboard::plainText):
2640         (WebCore::Pasteboard::documentFragment):
2641         * platform/chromium/PlatformBridge.h:
2642         * platform/chromium/PlatformScreenChromium.cpp:
2643         (WebCore::screenDepth):
2644         (WebCore::screenDepthPerComponent):
2645         (WebCore::screenIsMonochrome):
2646         (WebCore::screenRect):
2647         (WebCore::screenAvailableRect):
2648         * platform/chromium/ReadableDataObject.cpp:
2649         (WebCore::ReadableDataObject::getData):
2650         (WebCore::ReadableDataObject::urlTitle):
2651         (WebCore::ReadableDataObject::htmlBaseUrl):
2652         (WebCore::ReadableDataObject::filenames):
2653         (WebCore::ReadableDataObject::ensureTypeCacheInitialized):
2654         * platform/chromium/SSLKeyGeneratorChromium.cpp:
2655         (WebCore::signedPublicKeyAndChallengeString):
2656         * platform/chromium/ScrollbarThemeChromium.cpp:
2657         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
2658         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
2659         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
2660         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
2661         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
2662         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
2663         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
2664         * platform/chromium/ScrollbarThemeChromiumMac.mm:
2665         (WebCore::scrollbarStateToThemeState):
2666         (WebCore::ScrollbarThemeChromiumMac::paint):
2667         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
2668         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
2669         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
2670         (WebCore::ScrollbarThemeChromiumWin::paintButton):
2671         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
2672         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
2673         * platform/chromium/SharedTimerChromium.cpp:
2674         (WebCore::setSharedTimerFiredFunction):
2675         (WebCore::setSharedTimerFireTime):
2676         (WebCore::stopSharedTimer):
2677         * platform/chromium/SuddenTerminationChromium.cpp:
2678         (WebCore::disableSuddenTermination):
2679         (WebCore::enableSuddenTermination):
2680         * platform/chromium/SystemTimeChromium.cpp:
2681         (WebCore::currentTime):
2682         * platform/chromium/WritableDataObject.cpp:
2683         (WebCore::WritableDataObject::setData):
2684         * platform/graphics/chromium/CrossProcessFontLoading.mm:
2685         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
2686         (WebCore::fontContainsCharacter):
2687         (WebCore::FillLogFont):
2688         * platform/graphics/chromium/FontCacheLinux.cpp:
2689         (WebCore::FontCache::getFontDataForCharacters):
2690         * platform/graphics/chromium/FontChromiumWin.cpp:
2691         (WebCore::Font::drawGlyphs):
2692         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
2693         (WebCore::FontPlatformData::scriptFontProperties):
2694         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
2695         (WebCore::FontPlatformData::querySystemForRenderStyle):
2696         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
2697         (WebCore::fillBMPGlyphs):
2698         * platform/graphics/chromium/ImageChromium.cpp:
2699         (WebCore::Image::loadPlatformResource):
2700         * platform/graphics/chromium/ImageChromiumMac.mm:
2701         (WebCore::Image::loadPlatformResource):
2702         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
2703         (WebCore::SimpleFontData::platformInit):
2704         (WebCore::SimpleFontData::determinePitch):
2705         (WebCore::SimpleFontData::platformWidthForGlyph):
2706         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
2707         (WebCore::UniscribeHelperTextRun::tryToPreloadFont):
2708         * platform/graphics/skia/FontCustomPlatformData.cpp:
2709         (WebCore::FontCustomPlatformData::fontPlatformData):
2710         * platform/network/chromium/CookieJarChromium.cpp:
2711         (WebCore::setCookies):
2712         (WebCore::cookies):
2713         (WebCore::cookieRequestHeaderFieldValue):
2714         (WebCore::cookiesEnabled):
2715         (WebCore::getRawCookies):
2716         (WebCore::deleteCookie):
2717         * platform/network/chromium/DNSChromium.cpp:
2718         (WebCore::prefetchDNS):
2719         * platform/qt/PlatformBridge.h:
2720         * platform/sql/chromium/SQLiteFileSystemChromium.cpp:
2721         (WebCore::SQLiteFileSystem::deleteDatabaseFile):
2722         (WebCore::SQLiteFileSystem::getDatabaseFileSize):
2723         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
2724         (chromiumOpen):
2725         (chromiumDelete):
2726         (chromiumAccess):
2727         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
2728         * plugins/chromium/PluginDataChromium.cpp:
2729         (WebCore::PluginCache::plugins):
2730         * rendering/RenderThemeChromiumMac.mm:
2731         (WebCore::RenderThemeChromiumMac::usesTestModeFocusRingColor):
2732         * rendering/RenderThemeChromiumSkia.cpp:
2733         (WebCore::RenderThemeChromiumSkia::caretBlinkInterval):
2734         * rendering/RenderThemeChromiumWin.cpp:
2735         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
2736         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
2737         (WebCore::RenderThemeChromiumWin::platformActiveSelectionForegroundColor):
2738         (WebCore::RenderThemeChromiumWin::systemColor):
2739         (WebCore::RenderThemeChromiumWin::paintButton):
2740         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
2741         (WebCore::menuListButtonWidth):
2742         (WebCore::RenderThemeChromiumWin::paintMenuList):
2743         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
2744         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
2745         (WebCore::RenderThemeChromiumWin::paintProgressBar):
2746         * storage/chromium/IDBFactoryBackendInterface.cpp:
2747         (WebCore::IDBFactoryBackendInterface::create):
2748         (WebCore::IDBFactoryBackendInterface::~IDBFactoryBackendInterface):
2749         * storage/chromium/IDBKeyPathBackendImpl.cpp:
2750         (WebCore::IDBKeyPathBackendImpl::createIDBKeysFromSerializedValuesAndKeyPath):
2751
2752 2011-01-19  Sheriff Bot  <webkit.review.bot@gmail.com>
2753
2754         Unreviewed, rolling out r76187.
2755         http://trac.webkit.org/changeset/76187
2756         https://bugs.webkit.org/show_bug.cgi?id=52778
2757
2758         Broke caret-showing tests on SnowLeopard and Chromium
2759         (Requested by dimich on #webkit).
2760
2761         * rendering/RenderText.cpp:
2762         (WebCore::RenderText::localCaretRect):
2763
2764 2011-01-19  Yuzo Fujishima  <yuzo@google.com>
2765
2766         Reviewed by Kent Tamura.
2767
2768         Fix for Bug 52279 - WebCore::RenderBlock::updateFirstLetter crashes for anonymous blocks
2769         https://bugs.webkit.org/show_bug.cgi?id=52279
2770
2771         In constructing text fragments to handle first-letter rule, first add
2772         the text for the non-first letters and then remove the original text,
2773         rather than the other way around. Otherwise, the text can be added to
2774         an anoymous block that is different from the original one. This breaks
2775         the assumption that a first letter render object has a non-null sibling
2776         for the non-first letters and causes a crash.
2777
2778         Test: fast/css/first-letter-anonymous-block-crash.html
2779
2780         * rendering/RenderBlock.cpp:
2781         (WebCore::RenderBlock::updateFirstLetter):
2782
2783 2011-01-19  James Robinson  <jamesr@chromium.org>
2784
2785         Unreviewed, rolling out r76194.
2786         http://trac.webkit.org/changeset/76194
2787         https://bugs.webkit.org/show_bug.cgi?id=51218
2788
2789         Caused mysterious compile failure on the chromium win
2790         build.webkit.org bots
2791
2792         * WebCore.gypi:
2793         * dom/Document.cpp:
2794         (WebCore::Document::Document):
2795         * dom/Document.h:
2796         * dom/RequestAnimationFrameCallback.h: Removed.
2797         * dom/RequestAnimationFrameCallback.idl: Removed.
2798         * loader/EmptyClients.h:
2799         * page/Chrome.cpp:
2800         * page/Chrome.h:
2801         * page/ChromeClient.h:
2802         * page/DOMWindow.cpp:
2803         * page/DOMWindow.h:
2804         * page/DOMWindow.idl:
2805         * page/FrameView.cpp:
2806         * page/FrameView.h:
2807         * platform/HostWindow.h:
2808
2809 2011-01-19  Simon Fraser  <simon.fraser@apple.com>
2810
2811         Reviewed by Sam Weinig.
2812
2813         GraphicsLayers in subframes can get sync'd multiple times
2814         https://bugs.webkit.org/show_bug.cgi?id=52489
2815
2816         Some cleanup that will work towards fixing this bug.
2817         
2818         Tested by existing iframe compositing tests.
2819
2820         * WebCore.exp.in: syncCompositingStateRecursive()
2821         was renamed to syncCompositingStateIncludingSubframes().
2822
2823         * page/FrameView.h:
2824         * page/FrameView.cpp:
2825         (WebCore::FrameView::syncCompositingStateForThisFrame): Some
2826         code cleanup: do all the word we need to do for this frame,
2827         including the needsLayout() check.
2828         (WebCore::FrameView::syncCompositingStateIncludingSubframes):
2829         This is no longer recursive; instead, it iterates over descendant
2830         frames via the frame tree, calling syncCompositingStateForThisFrame()
2831         on each Frame's view.
2832
2833         * rendering/RenderLayerCompositor.h:
2834         (WebCore::RenderLayerCompositor::isFlushingLayers): Getter for the flag.
2835         * rendering/RenderLayerCompositor.cpp: 
2836         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
2837         (WebCore::RenderLayerCompositor::flushPendingLayerChanges): Maintain
2838         a flag to say if we're flushing, which allows us to assert on re-entrant flushes.
2839         (WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers):
2840         Add the ability to get the rootmost compositor that is in the middle
2841         of a flush.
2842
2843 2011-01-19  James Robinson  <jamesr@chromium.org>
2844
2845         Reviewed by Darin Fisher.
2846
2847         Implement mozilla's requestAnimationFrame API
2848         https://bugs.webkit.org/show_bug.cgi?id=51218
2849
2850         This implements mozilla's proposed requestAnimationFrame API.  The idea with this API is that
2851         an author driving an animation from script could use window.requestAnimationFrame(callback)
2852         instead of window.setTimeout(callback, 0) to schedule their update logic and let the browser
2853         decide when to update the animations.  This avoids doing unnecessary work when the page content
2854         is offscreen or is being displayed at a different framerate than what the page author expects.
2855
2856         Mozilla's proposal is here: https://developer.mozilla.org/en/DOM/window.mozRequestAnimationFrame
2857         This implements window.mozRequestAnimationFrame as window.webkitRequestAnimationFrame with the
2858         following changes:
2859         *) Only the callback syntax is supported, there is no before paint event
2860         *) webkitRequestAnimationFrame supports a second parameter Element to let the author indicate
2861             what content they intend to animate.  That way if the page is being displayed but the element
2862             in question is offscreen, we can avoid invoking the callback.
2863         *) No timestamp is provided to the caller and there is no window.animationStartTime property
2864             (see https://bugs.webkit.org/show_bug.cgi?id=51952 for discussion of this property)
2865         *) window.webkitRequestAnimationFrame returns a numerical id that can be used to cancel the callback
2866             using window.cancelWebkitRequestAnimationFrame, to parallel window.setTimeout()/window.clearTime().
2867
2868         The implementation depends on the embedder scheduling the callbacks since the callback invocation
2869         depends on the page's visibility and the embedder's paint scheduling, neither of which are exposed
2870         to WebCore.  The expectation for the embedder is that at some point Chrome::scheduleAnimation() is
2871         called FrameView::serviceScriptedAnimations() should be called for the associated Page's main frame.
2872         Ideally serviceScriptedAnimations() would be called prior to rendering - although in practice the
2873         embedder has to rate limit callbacks and may not be able to tie the callback directly to the
2874         rendering loop.
2875
2876         Tests: fast/animation/request-animation-frame-cancel.html
2877                fast/animation/request-animation-frame-cancel2.html
2878                fast/animation/request-animation-frame-display.html
2879                fast/animation/request-animation-frame-within-callback.html
2880                fast/animation/request-animation-frame.html
2881
2882         * WebCore.gypi:
2883         * dom/Document.cpp:
2884         (WebCore::Document::Document):
2885         (WebCore::Document::webkitRequestAnimationFrame):
2886         (WebCore::Document::webkitCancelRequestAnimationFrame):
2887         (WebCore::Document::serviceScriptedAnimations):
2888         * dom/Document.h:
2889         * dom/RequestAnimationFrameCallback.h: Added.
2890         (WebCore::RequestAnimationFrameCallback::~RequestAnimationFrameCallback):
2891         * dom/RequestAnimationFrameCallback.idl: Added.
2892         * loader/EmptyClients.h:
2893         (WebCore::EmptyChromeClient::scheduleAnimation):
2894         * page/Chrome.cpp:
2895         (WebCore::Chrome::scheduleAnimation):
2896         * page/Chrome.h:
2897         * page/ChromeClient.h:
2898         * page/DOMWindow.cpp:
2899         (WebCore::DOMWindow::webkitRequestAnimationFrame):
2900         (WebCore::DOMWindow::webkitCancelRequestAnimationFrame):
2901         * page/DOMWindow.h:
2902         * page/DOMWindow.idl:
2903         * page/FrameView.cpp:
2904         (WebCore::FrameView::scheduleAnimation):
2905         (WebCore::FrameView::serviceScriptedAnimations):
2906         * page/FrameView.h:
2907         * platform/HostWindow.h:
2908
2909 2011-01-13  Martin Robinson  <mrobinson@igalia.com>
2910
2911         Reviewed by Daniel Bates.
2912
2913         [GTK] Move progress bar painting out of gtk2drawing.c
2914         https://bugs.webkit.org/show_bug.cgi?id=52385
2915
2916         Move progress bar painting to RenderThemeGtk2 and share some animation
2917         logic between the GTK+ 2.x and GTK+ 3.x port.
2918
2919         No new tests. This should not change functionality.
2920
2921         * platform/gtk/RenderThemeGtk.cpp:
2922         (WebCore::RenderThemeGtk::animationRepeatIntervalForProgressBar): Moved from RenderThemeGtk3.
2923         (WebCore::RenderThemeGtk::animationDurationForProgressBar): Ditto.
2924         (WebCore::RenderThemeGtk::calculateProgressRect): Calculate the proper rectangle for the
2925         progress indicator given the rect for the maximum size of the indicator.
2926         * platform/gtk/RenderThemeGtk.h: Added calculateProgressRect declaration and
2927         a new widget member for GTK+ 2.x
2928         * platform/gtk/RenderThemeGtk2.cpp:
2929         (WebCore::RenderThemeGtk::platformInit): Added initialization for the new widget member.
2930         (WebCore::RenderThemeGtk::paintProgressBar): Paint the progress bar manually instead of
2931         calling the old Mozilla code.
2932         (WebCore::RenderThemeGtk::gtkProgressBar): Added.
2933         * platform/gtk/RenderThemeGtk3.cpp:
2934         (WebCore::RenderThemeGtk::paintProgressBar): Call calculateProgressRect now to get
2935         the area of the progress indicator.
2936         * platform/gtk/gtk2drawing.c: Remove unused code.
2937         (moz_gtk_get_widget_border):
2938         (moz_gtk_widget_paint):
2939         * platform/gtk/gtkdrawing.h: Ditto.
2940
2941 2011-01-19  Dmitry Titov  <dimich@chromium.org>
2942
2943         [Chromium] Not reviewed, reverts the following changes:
2944         http://trac.webkit.org/changeset/76164 (build fix)
2945         http://trac.webkit.org/changeset/76159 (main change)
2946
2947         The change broke Chromium Linux-shlib build.
2948
2949         Original issue:
2950         Accelerated canvas2D has bad clipping performance.
2951         https://bugs.webkit.org/show_bug.cgi?id=52627
2952
2953         * WebCore.gyp/WebCore.gyp:
2954         * WebCore.gypi:
2955         * html/canvas/CanvasRenderingContext2D.cpp:
2956         (WebCore::CanvasRenderingContext2D::reset):
2957         (WebCore::CanvasRenderingContext2D::platformLayer):
2958         * platform/graphics/chromium/DrawingBufferChromium.cpp:
2959         (WebCore::DrawingBuffer::DrawingBuffer):
2960         * platform/graphics/chromium/GLES2Canvas.cpp:
2961         (WebCore::GLES2Canvas::State::State):
2962         (WebCore::GLES2Canvas::clearRect):
2963         (WebCore::GLES2Canvas::fillRect):
2964         (WebCore::GLES2Canvas::restore):
2965         (WebCore::GLES2Canvas::drawTexturedRect):
2966         * platform/graphics/chromium/GLES2Canvas.h:
2967         * platform/graphics/gpu/DrawingBuffer.cpp:
2968         (WebCore::DrawingBuffer::clear):
2969         (WebCore::DrawingBuffer::createSecondaryBuffers):
2970         (WebCore::DrawingBuffer::reset):
2971         * platform/graphics/gpu/DrawingBuffer.h:
2972         * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
2973         (WebCore::SharedGraphicsContext3D::create):
2974         * platform/graphics/gpu/SharedGraphicsContext3D.h:
2975         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
2976         (WebCore::DrawingBuffer::DrawingBuffer):
2977         * platform/graphics/skia/GraphicsContextSkia.cpp:
2978         (WebCore::GraphicsContext::canvasClip):
2979         (WebCore::GraphicsContext::clipOut):
2980         (WebCore::GraphicsContext::clipPath):
2981         (WebCore::GraphicsContext::fillPath):
2982         * platform/graphics/skia/PlatformContextSkia.cpp:
2983         (WebCore::PlatformContextSkia::canAccelerate):
2984         (WebCore::PlatformContextSkia::uploadSoftwareToHardware):
2985         * thirdparty/glu/README.webkit:
2986         * thirdparty/glu/gluos.h:
2987         * thirdparty/glu/libtess/geom.c:
2988         * thirdparty/glu/libtess/priorityq.c:
2989         * thirdparty/glu/libtess/render.c:
2990         * thirdparty/glu/libtess/sweep.c:
2991         (IsWindingInside):
2992         (DoneEdgeDict):
2993
2994 2011-01-19  Levi Weintraub  <leviw@google.com>
2995
2996         Reviewed by Darin Adler.
2997
2998         Re-committing this with the proper expected results.
2999
3000         Changing RenderText::localCaretRect to clip to its containing block's logicalLeft and
3001         logicalRightLayoutOverflow instead of simply using logicalLeft and logicalRight, as this
3002         resulted in the caret being placed incorrectly in overflowing editable IFrame content.
3003
3004         Long lines in non-white-space-pre editable documents show cursor in wrong place
3005         https://bugs.webkit.org/show_bug.cgi?id=48132
3006
3007         Test: editing/selection/caret-painting-in-overflowing-autowrap-content.html
3008
3009         * rendering/RenderText.cpp:
3010         (WebCore::RenderText::localCaretRect):
3011
3012 2011-01-18 MORITA Hajime <morrita@google.com>
3013
3014         Reviewed by David Levin.
3015
3016         ElementRareData::m_shadowRoot should not be RefPtr.
3017         https://bugs.webkit.org/show_bug.cgi?id=51914
3018
3019         Makes ElementRareData::m_shadowRoot a raw pointer because
3020         ElementRareData::m_shadowRoot should be like a
3021         ContaineNode::m_firstChild, which is also a raw pointer.
3022         pointer. Which also means that both the shadow root and the shadow
3023         host reference each other as a parent-and-child relationship, via
3024         a raw pointer.
3025         
3026         Note that it is safe not to manipulate the ref-count of
3027         m_shadowRoot because Node::m_parent of the shadow root points its
3028         shadow host, and the object isn't deleted even if the refcount is
3029         zero, as long as the node has non-null m_parent. (See TreeShared.)
3030         
3031         The shadow root node is finally destroyed inside
3032         removeShadowRoot(), where we store the root node into a local
3033         RefPtr, then make the node's m_parent null, which results the
3034         destroy the node, at the end of the function, by RefPtr::~RefPtr.
3035         
3036         No new tests. No behavioral change.
3037
3038         * dom/Element.cpp:
3039         (WebCore::Element::~Element):
3040         (WebCore::Element::shadowRoot):
3041         (WebCore::Element::setShadowRoot):
3042         (WebCore::Element::removeShadowRoot):
3043         * dom/ElementRareData.h:
3044         (WebCore::ElementRareData::ElementRareData):
3045         (WebCore::ElementRareData::~ElementRareData):
3046
3047 2011-01-12  Martin Robinson  <mrobinson@igalia.com>
3048
3049         Reviewed by Gustavo Noronha Silva.
3050
3051         [GTK] Move text field painting out of gtk2drawing.c
3052         https://bugs.webkit.org/show_bug.cgi?id=52327
3053
3054         No new tests. This should not change behavior.
3055
3056         * platform/gtk/RenderThemeGtk2.cpp:
3057         (WebCore::RenderThemeGtk::paintButton): Use the setWidgetHasFocus helper.
3058         (WebCore::RenderThemeGtk::paintTextField): Do this manually now instead
3059         of calling into the Mozilla code.
3060         * platform/gtk/WidgetRenderingContext.cpp: Added a couple more wrappers
3061         for GTK+ theme functions.
3062         (WebCore::WidgetRenderingContext::gtkPaintFlatBox):
3063         (WebCore::WidgetRenderingContext::gtkPaintShadow):
3064         * platform/gtk/WidgetRenderingContext.h: Added new method declarations.
3065         * platform/gtk/gtk2drawing.c: Remove unused code.
3066         (moz_gtk_get_widget_border):
3067         (moz_gtk_widget_paint):
3068         * platform/gtk/gtkdrawing.h:
3069
3070 2011-01-19  Antti Koivisto  <antti@apple.com>
3071
3072         Reviewed by Oliver Hunt.
3073
3074         Cache function offsets to speed up javascript parsing
3075         https://bugs.webkit.org/show_bug.cgi?id=52622
3076         
3077         Use cache to save function offsets and some other info.
3078         This avoids quite a bit of work when reparsing the source.
3079
3080         * bindings/js/CachedScriptSourceProvider.h:
3081         (WebCore::CachedScriptSourceProvider::cache):
3082         (WebCore::CachedScriptSourceProvider::cacheSizeChanged):
3083         (WebCore::CachedScriptSourceProvider::CachedScriptSourceProvider):
3084         * bindings/js/ScriptSourceProvider.h:
3085         (WebCore::ScriptSourceProvider::ScriptSourceProvider):
3086         * loader/cache/CachedScript.cpp:
3087         (WebCore::CachedScript::destroyDecodedData):
3088         (WebCore::CachedScript::sourceProviderCache):
3089         (WebCore::CachedScript::sourceProviderCacheSizeChanged):
3090         * loader/cache/CachedScript.h:
3091
3092 2011-01-11  Martin Robinson  <mrobinson@igalia.com>
3093
3094         Reviewed by Gustavo Noronha Silva.
3095
3096         [GTK] Move toggle button rendering out of gtk2drawing.c
3097         https://bugs.webkit.org/show_bug.cgi?id=52258
3098
3099         * platform/gtk/RenderThemeGtk.h:
3100         * platform/gtk/RenderThemeGtk2.cpp:
3101         (WebCore::RenderThemeGtk::platformInit): Initialize new button members.
3102         (WebCore::adjustRectForFocus): Added this function which inflates a rect based
3103         on a widget's exterior focus.
3104         (WebCore::RenderThemeGtk::adjustRepaintRect): Account for exterior focus.
3105         (WebCore::setToggleSize): Only listen to indicator-size to properly size
3106         checkboxes and radio buttons.
3107         (WebCore::RenderThemeGtk::setCheckboxSize): Call new setToggleSize properly.
3108         (WebCore::paintToggle): Added.
3109         (WebCore::RenderThemeGtk::paintCheckbox): Call paintToggle.
3110         (WebCore::RenderThemeGtk::setRadioSize): Call new setToggleSize properly.
3111         (WebCore::RenderThemeGtk::paintRadio): Call paintToggle.
3112         (WebCore::RenderThemeGtk::gtkRadioButton): Added.
3113         (WebCore::RenderThemeGtk::gtkCheckButton): Added.
3114         * platform/gtk/WidgetRenderingContext.cpp:
3115         (WebCore::WidgetRenderingContext::WidgetRenderingContext): Use a static extra space
3116         variable. This is good enough for all themes that I've tested and prevents having to
3117         pass information from RenderThemeGtk about every single type of widget.
3118         (WebCore::WidgetRenderingContext::gtkPaintFocus): Use the paintRect
3119         to draw instead of m_paintRect. This is important when we're painting
3120         something that isn't the size of the total rect.
3121         (WebCore::WidgetRenderingContext::gtkPaintCheck): Added.
3122         (WebCore::WidgetRenderingContext::gtkPaintOption): Added.
3123         * platform/gtk/WidgetRenderingContext.h: Updated to reflect new methods.
3124         * platform/gtk/gtkdrawing.h: Remove newly unused code.
3125         * platform/gtk/gtk2drawing.c: Ditto.
3126
3127 2011-01-19  Tony Gentilcore  <tonyg@chromium.org>
3128
3129         Unreviewed build fix.
3130
3131         Build fix for r76170
3132         https://bugs.webkit.org/show_bug.cgi?id=52758
3133
3134         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
3135
3136 2011-01-19  David D. Kilzer  <ddkilzer@apple.com>
3137
3138         <http://webkit.org/b/52687> Clean up FrameLoader methods for PLUGIN_PROXY_FOR_VIDEO
3139
3140         Reviewed by Eric Carlson.
3141
3142         * loader/FrameLoader.cpp: Declare the methods here.
3143         (WebCore::FrameLoader::hideMediaPlayerProxyPlugin):
3144         (WebCore::FrameLoader::showMediaPlayerProxyPlugin):
3145         * loader/FrameLoader.cpp: Moved methods to here...
3146         (WebCore::FrameLoader::hideMediaPlayerProxyPlugin):
3147         (WebCore::FrameLoader::showMediaPlayerProxyPlugin):
3148         * loader/SubframeLoader.cpp: ...from here.
3149         (WebCore::FrameLoader::hideMediaPlayerProxyPlugin):
3150         (WebCore::FrameLoader::showMediaPlayerProxyPlugin):
3151
3152 2011-01-19  Tony Gentilcore  <tonyg@chromium.org>
3153
3154         Reviewed by Mihai Parparita.
3155
3156         Perform some forward declaration
3157         https://bugs.webkit.org/show_bug.cgi?id=52522
3158
3159         No new tests because no new functionality.
3160
3161         * accessibility/AccessibilityObject.h:
3162         * css/WebKitCSSMatrix.cpp:
3163         * html/HTMLAreaElement.cpp:
3164         * html/canvas/CanvasRenderingContext2D.cpp:
3165         * inspector/InspectorController.cpp:
3166         * platform/graphics/FloatPoint.cpp:
3167         * platform/graphics/Font.cpp:
3168         * platform/graphics/Font.h:
3169         * platform/graphics/FontFastPath.cpp:
3170         * platform/graphics/GraphicsContext.cpp:
3171         * platform/graphics/ImageBuffer.h:
3172         * platform/graphics/StringTruncator.cpp:
3173         * platform/graphics/WidthIterator.cpp:
3174         * platform/graphics/mac/ComplexTextController.cpp:
3175         * platform/graphics/mac/ComplexTextControllerCoreText.cpp:
3176         * platform/graphics/mac/FontComplexTextMac.cpp:
3177         * platform/graphics/transforms/TransformationMatrix.cpp:
3178         * platform/graphics/transforms/TransformationMatrix.h:
3179         * rendering/EllipsisBox.cpp:
3180         * rendering/InlineTextBox.cpp:
3181         * rendering/RenderBlock.cpp:
3182         * rendering/RenderBlockLineLayout.cpp:
3183         * rendering/RenderEmbeddedObject.cpp:
3184         * rendering/RenderFileUploadControl.cpp:
3185         * rendering/RenderFlexibleBox.cpp:
3186         * rendering/RenderImage.cpp:
3187         * rendering/RenderListBox.cpp:
3188         * rendering/RenderListMarker.cpp:
3189         * rendering/RenderMenuList.cpp:
3190         * rendering/RenderObject.h:
3191         * rendering/RenderText.cpp:
3192         * rendering/RenderTextControl.cpp:
3193         * rendering/svg/SVGInlineTextBox.cpp:
3194         * rendering/svg/SVGMarkerLayoutInfo.h:
3195         * rendering/svg/SVGTextMetrics.cpp:
3196         * svg/SVGFont.cpp:
3197
3198 2011-01-19  Adrienne Walker  <enne@google.com>
3199
3200         Reviewed by Kenneth Russell.
3201
3202         [chromium] Tiled compositor should use texture manager
3203         https://bugs.webkit.org/show_bug.cgi?id=52418
3204
3205         Test: compositing/
3206
3207         * platform/graphics/chromium/LayerRendererChromium.cpp:
3208         (WebCore::LayerRendererChromium::~LayerRendererChromium):
3209         (WebCore::LayerRendererChromium::cleanupSharedObjects):
3210         * platform/graphics/chromium/LayerTilerChromium.cpp:
3211         (WebCore::LayerTilerChromium::LayerTilerChromium):
3212         (WebCore::LayerTilerChromium::reset):
3213         (WebCore::LayerTilerChromium::createTile):
3214         (WebCore::LayerTilerChromium::update):
3215         (WebCore::LayerTilerChromium::draw):
3216         * platform/graphics/chromium/LayerTilerChromium.h:
3217         (WebCore::LayerTilerChromium::Tile::Tile):
3218         (WebCore::LayerTilerChromium::Tile::texture):
3219
3220 2011-01-19  Stephen White  <senorblanco@chromium.org>
3221
3222         Unreviewed; build fix for chromium.
3223
3224         * platform/graphics/chromium/GLES2Canvas.cpp:
3225         (WebCore::GLES2Canvas::fillPath):
3226
3227 2011-01-18  Stephen White  <senorblanco@chromium.org>
3228
3229         Reviewed by James Robinson.
3230
3231         Implement accelerated path drawing and clipping for the Canvas2D GPU
3232         path.
3233         https://bugs.webkit.org/show_bug.cgi?id=52627
3234         
3235         This is done with a simple curve interpolator and the GLU tesselator,
3236         which is good enough for a 3-5X speedup on
3237         http://ie.microsoft.com/testdrive/Performance/Galactic/Default.html.
3238
3239         Covered by canvas/philip/2d.path.clip.basic.html, and many, many more.
3240         All tests canvas/philip and fast/canvas paths pass with no
3241         regressions, although two have minor pixel differences which require
3242         rebaselining.
3243
3244         * WebCore.gyp/WebCore.gyp:
3245         Add internal_glu include path to chromium build.
3246         * WebCore.gypi:
3247         Add internal_glu files to chromium build.
3248         * html/canvas/CanvasRenderingContext2D.cpp:
3249         (WebCore::CanvasRenderingContext2D::reset):
3250         (WebCore::CanvasRenderingContext2D::platformLayer):
3251         Make CanvasRenderingContext2D more robust against failure to create
3252         a DrawingBuffer.
3253         * platform/graphics/chromium/DrawingBufferChromium.cpp:
3254         (WebCore::DrawingBuffer::DrawingBuffer):
3255         As in DrawingBufferMac.cpp, call reset() from the constructor.
3256         Also initialize size to (-1, -1), so reset() doesn't early-out.
3257         Add initializers for depthBuffer and stencilBuffer, and remove
3258         multisampleDepthStencilBuffer.
3259         * platform/graphics/chromium/GLES2Canvas.cpp:
3260         Remove some unused #includes.
3261         (WebCore::GLES2Canvas::State::State):
3262         Add clipping state, and implement save/restore via the copy constructor.
3263         (WebCore::operator*):
3264         (WebCore::Quadratic::Quadratic):
3265         (WebCore::Quadratic::fromBezier):
3266         (WebCore::Quadratic::evaluate):
3267         Quadratic Bezier curve class.
3268         (WebCore::Cubic::Cubic):
3269         (WebCore::Cubic::fromBezier):
3270         (WebCore::Cubic::evaluate):
3271         Cubic Bezier curve class.
3272         (WebCore::GLES2Canvas::clearRect):
3273         Add clipping support to clearRect().
3274         (WebCore::GLES2Canvas::fillPath):
3275         Implement fillPath().
3276         (WebCore::GLES2Canvas::fillRect):
3277         Add clipping support to fillRect().
3278         (WebCore::GLES2Canvas::clipPath):
3279         Implement clipPath().
3280         (WebCore::GLES2Canvas::clipOut):
3281         Stub out clipOut() (not called by Canvas 2D).
3282         (WebCore::GLES2Canvas::restore):
3283         When restoring, draw any remaining clipping paths to the stencil buffer.
3284         (WebCore::GLES2Canvas::drawTexturedRect):
3285         Add clipping support.
3286         (WebCore::interpolateQuadratic):
3287         (WebCore::interpolateCubic):
3288         Simple curve interpolation, using the Cubic and Quadratic classes.
3289         (WebCore::PolygonData::PolygonData):
3290         A struct to hold the tesselation data for callbacks.
3291         (WebCore::beginData):
3292         (WebCore::edgeFlagData):
3293         (WebCore::vertexData):
3294         (WebCore::endData):
3295         (WebCore::combineData):
3296         internal_glu tesselation callbacks.
3297         (WebCore::GLES2Canvas::createVertexBufferFromPath):
3298         Build an interpolated, tesselated vertex buffer and element array buffer from a given path, suitable for filling.
3299         (WebCore::GLES2Canvas::beginStencilDraw):
3300         Enable stencilling, and disable draws to the color buffer.
3301         (WebCore::GLES2Canvas::applyClipping):
3302         If clipping is enabled, set the appropriate GL state.
3303         * platform/graphics/chromium/GLES2Canvas.h:
3304         Document the flavours of drawTexturedRect() a bit, so I don't get confused.
3305         * platform/graphics/gpu/DrawingBuffer.cpp:
3306         (WebCore::DrawingBuffer::clear):
3307         (WebCore::DrawingBuffer::createSecondaryBuffers):
3308         (WebCore::DrawingBuffer::resizeDepthStencil):
3309         (WebCore::DrawingBuffer::reset):
3310         * platform/graphics/gpu/DrawingBuffer.h:
3311         Unify m_multisampleDepthStencilBuffer with m_depthStencilBuffer. 
3312         Implement separate depth and stencil buffers for when
3313         OES_packed_depth_stencil is not available.  Refactor creation of
3314         multisampled and non-multisampled depth and stencil buffers into
3315         resizeDepthStencil().
3316         * platform/graphics/gpu/SharedGraphicsContext3D.cpp:
3317         (WebCore::SharedGraphicsContext3D::create):
3318         Turn on stencil, turn off depth, turn off antialiasing (for now).
3319         (WebCore::SharedGraphicsContext3D::enableStencil):
3320         * platform/graphics/gpu/SharedGraphicsContext3D.h:
3321         Implement stencil enable/disable.
3322         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
3323         (WebCore::DrawingBuffer::DrawingBuffer):
3324         Remove m_multisampleDepthStencilBuffer.  Set the size to (-1, -1)
3325         on creation, so reset() doesn't early-out.  Initialize m_depthBuffer
3326         and m_stencilBuffer.
3327         * platform/graphics/skia/GraphicsContextSkia.cpp:
3328         (WebCore::GraphicsContext::canvasClip):
3329         (WebCore::GraphicsContext::clipOut):
3330         (WebCore::GraphicsContext::clipPath):
3331         (WebCore::GraphicsContext::fillPath):
3332         Put in GPU hooks for path clipping, and path drawing.
3333         * platform/graphics/skia/PlatformContextSkia.cpp:
3334         (WebCore::PlatformContextSkia::canAccelerate):
3335         Don't check for clipping paths in canAccelerate() (since we can
3336         now accelerate them).
3337         (WebCore::PlatformContextSkia::uploadSoftwareToHardware):
3338         Don't do clipping when uploading software draws to hardware.
3339         * thirdparty/glu/README.webkit:
3340         * thirdparty/glu/gluos.h:
3341         #undef MIN and MAX, to fix warnings-as-errors in Chrome/Mac build.
3342         * thirdparty/glu/libtess/geom.c:
3343         * thirdparty/glu/libtess/priorityq.c:
3344         * thirdparty/glu/libtess/render.c:
3345         Use do{}while(0) instead of if(1)else construct in macro.
3346         * thirdparty/glu/libtess/sweep.c:
3347         (IsWindingInside):
3348         (DoneEdgeDict):
3349         Fix some warnings treated as errors for the Linux Release build.
3350
3351 2011-01-19  Sheriff Bot  <webkit.review.bot@gmail.com>
3352
3353         Unreviewed, rolling out r76144.
3354         http://trac.webkit.org/changeset/76144
3355         https://bugs.webkit.org/show_bug.cgi?id=52737
3356
3357         Broke tests on multiple bots, mostly Chromium Canaries
3358         (Requested by dimich on #webkit).
3359
3360         * rendering/RenderText.cpp:
3361         (WebCore::RenderText::localCaretRect):
3362
3363 2011-01-19  Simon Fraser  <simon.fraser@apple.com>
3364
3365         Reviewed by Adam Roben.
3366
3367         [CSS Gradients] Crash due to out-of-memory with repeating-linear-gradient and latter stop positioned before former
3368         https://bugs.webkit.org/show_bug.cgi?id=52732
3369         
3370         When repeating gradient stops, make sure that the first and last stops are not at the same
3371         place, otherwise we'll add stops indefinitely and run out of memory.
3372
3373         Test: fast/gradients/zero-range-repeating-gradient-hang.html
3374
3375         * css/CSSGradientValue.cpp:
3376         (WebCore::CSSGradientValue::addStops):
3377
3378 2011-01-14  Dimitri Glazkov  <dglazkov@chromium.org>
3379
3380         Reviewed by Darin Adler.
3381
3382         Remove event forwarding logic from input[type=range], simplify event flow and thumb positioning logic.
3383         https://bugs.webkit.org/show_bug.cgi?id=52464
3384
3385         This change has two parts:
3386
3387         1) Utilize shadow DOM event retargeting to get rid of forwarding events
3388            via render tree;
3389         2) Move thumb positioning logic from RenderSlider to SliderThumbElement.
3390
3391         These two are highly co-dependent. It looked ugly when I tried to
3392         separate them.
3393
3394         No change in behavior, covered by existing tests.
3395
3396         * html/HTMLInputElement.cpp:
3397         (WebCore::HTMLInputElement::defaultEventHandler): Added invocation of
3398             InputType::handleMouseDownEvent.
3399         * html/InputType.cpp:
3400         (WebCore::InputType::handleMouseDownEvent): Added empty decl.
3401         * html/InputType.h: Added def.
3402         * html/RangeInputType.cpp:
3403         (WebCore::RangeInputType::handleMouseDownEvent): Added to handle the case
3404             when the user clicks on the track of the slider. Also removed the
3405             forwardEvent method.
3406         * html/RangeInputType.h: Added/removed defs.
3407         * html/shadow/SliderThumbElement.cpp:
3408         (WebCore::SliderThumbElement::dragFrom): Added a helper method to start
3409             dragging from any position.
3410         (WebCore::SliderThumbElement::dragTo): Added a helper method to drag to
3411             specified position.
3412         (WebCore::SliderThumbElement::setPosition): Collapsed most of the positioning
3413             logic in RenderSlider into this method, which is now a simple calculation
3414             and adjusting of thumb position based on supplied coordinates.
3415         (WebCore::SliderThumbElement::startDragging): Added.
3416         (WebCore::SliderThumbElement::stopDragging): Added.
3417         (WebCore::SliderThumbElement::defaultEventHandler): Removed most of the
3418             old position-sniffing logic and replaced with simple calls to start,
3419             stop, and drag the thumb.
3420         * html/shadow/SliderThumbElement.h: Added defs.
3421         * rendering/RenderSlider.cpp: Removed a bunch of code that is no longer
3422             necessary.
3423         * rendering/RenderSlider.h: Removed defs, removed now-unnecessary friendliness.
3424
3425 2011-01-19  Shane Stephens  <shanestephens@google.com>
3426
3427         Reviewed by Chris Marrin.
3428
3429         Make AffineTransform and TransformationMatrix do matrix multiplication in the correct order (Column Major)
3430         https://bugs.webkit.org/show_bug.cgi?id=48031
3431
3432         Fixed reversal, renamed matrix methods to be clearer, found all examples of operator* and
3433         operator*= usage and switched operand order.
3434
3435         No new tests as this refactor doesn't add functionality.
3436
3437         * html/HTMLCanvasElement.cpp:
3438         (WebCore::HTMLCanvasElement::baseTransform):
3439         * html/canvas/CanvasRenderingContext2D.cpp:
3440         (WebCore::CanvasRenderingContext2D::transform):
3441         (WebCore::CanvasRenderingContext2D::setTransform):
3442         * platform/graphics/cg/PatternCG.cpp:
3443         (WebCore::Pattern::createPlatformPattern):
3444         * platform/graphics/chromium/GLES2Canvas.cpp:
3445         (WebCore::GLES2Canvas::fillRect):
3446         (WebCore::GLES2Canvas::concatCTM):
3447         (WebCore::GLES2Canvas::drawQuad):
3448         * platform/graphics/chromium/TransparencyWin.cpp:
3449         (WebCore::TransparencyWin::setupLayerForOpaqueCompositeLayer):
3450         (WebCore::TransparencyWin::setupTransformForKeepTransform):
3451         * platform/graphics/transforms/AffineTransform.cpp:
3452         (WebCore::AffineTransform::multiply):
3453         (WebCore::AffineTransform::rotate):
3454         * platform/graphics/transforms/AffineTransform.h:
3455         (WebCore::AffineTransform::operator*=):
3456         (WebCore::AffineTransform::operator*):
3457         * platform/graphics/wince/GraphicsContextWinCE.cpp:
3458         (WebCore::GraphicsContextPlatformPrivate::concatCTM):
3459         * platform/graphics/wince/SharedBitmap.cpp:
3460         (WebCore::SharedBitmap::drawPattern):
3461         * rendering/svg/RenderSVGResourceContainer.cpp:
3462         (WebCore::RenderSVGResourceContainer::transformOnNonScalingStroke):
3463         * rendering/svg/RenderSVGResourceGradient.cpp:
3464         (WebCore::clipToTextMask):
3465         (WebCore::RenderSVGResourceGradient::applyResource):
3466         * rendering/svg/RenderSVGResourcePattern.cpp:
3467         (WebCore::RenderSVGResourcePattern::applyResource):
3468         * rendering/svg/RenderSVGRoot.cpp:
3469         (WebCore::RenderSVGRoot::localToBorderBoxTransform):
3470         * rendering/svg/SVGImageBufferTools.cpp:
3471         (WebCore::SVGImageBufferTools::calculateTransformationToOutermostSVGCoordinateSystem):
3472         (WebCore::SVGImageBufferTools::renderSubtreeToImageBuffer):
3473         * rendering/svg/SVGTextLayoutEngine.cpp:
3474         (WebCore::SVGTextLayoutEngine::finalizeTransformMatrices):
3475         * svg/SVGLocatable.cpp:
3476         (WebCore::SVGLocatable::computeCTM):
3477         (WebCore::SVGLocatable::getTransformToElement):
3478         * svg/SVGMatrix.h:
3479         (WebCore::SVGMatrix::multiply):
3480         * svg/SVGSVGElement.cpp:
3481         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
3482         (WebCore::SVGSVGElement::viewBoxToViewTransform):
3483         * svg/SVGStyledTransformableElement.cpp:
3484         (WebCore::SVGStyledTransformableElement::animatedLocalTransform):
3485         * svg/SVGTextElement.cpp:
3486         (WebCore::SVGTextElement::animatedLocalTransform):
3487         * svg/SVGTransformList.cpp:
3488         (WebCore::SVGTransformList::concatenate):
3489
3490 2011-01-19  Chang Shu  <chang.shu@nokia.com>
3491
3492         Reviewed by Darin Adler.
3493
3494         The return value of contentEditable() function should depend on the DOM attribute
3495         instead of render style userModify. The code change fixed test cases in the bug
3496         and partially fixed test cases in other contentEditable bugs;
3497
3498         https://bugs.webkit.org/show_bug.cgi?id=52056
3499
3500         * html/HTMLElement.cpp:
3501         (WebCore::HTMLElement::contentEditable):
3502
3503 2011-01-19  Levi Weintraub  <leviw@chromium.org>
3504
3505         Reviewed by Darin Adler.
3506
3507         Changing RenderText::localCaretRect to clip to its containing block's logicalLeft and
3508         logicalRightLayoutOverflow instead of simply using logicalLeft and logicalRight, as this
3509         resulted in the caret being placed incorrectly in overflowing editable IFrame content.
3510
3511         Long lines in non-white-space-pre editable documents show cursor in wrong place
3512         https://bugs.webkit.org/show_bug.cgi?id=48132
3513
3514         Test: editing/selection/caret-painting-in-overflowing-autowrap-content.html
3515
3516         * rendering/RenderText.cpp:
3517         (WebCore::RenderText::localCaretRect):
3518
3519 2011-01-19  Chris Marrin  <cmarrin@apple.com>
3520
3521         Reviewed by Simon Fraser.
3522
3523         WK2 - Multiple crashes in PlatformCALayer::replaceSublayer
3524         https://bugs.webkit.org/show_bug.cgi?id=52695
3525
3526         Added ASSERTs to the places we assume a non-null superlayer.
3527
3528         * platform/graphics/ca/GraphicsLayerCA.cpp:
3529         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
3530         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
3531
3532 2011-01-18  Beth Dakin  <bdakin@apple.com>
3533
3534         Reviewed by Maciej Stachowiak.
3535
3536         Fix for <rdar://problem/8882916> Overlay scrollers require 
3537         content to layout underneath the scrollbar area
3538
3539         The render tree should not include scrollbar size for
3540         overlay scrollers. This patch will allow scrollers on
3541         the WebView to behave like overflow:overlay.
3542
3543         Treat overlay scrollers the same way as the !includeScrollbars
3544         case.
3545         * platform/ScrollView.cpp:
3546         (WebCore::ScrollView::visibleContentRect):
3547
3548         No corner rect for overlay scrollers.
3549         (WebCore::ScrollView::scrollCornerRect):
3550
3551         usesOverlayScrollbars() currently always returns no.
3552         * platform/ScrollbarTheme.h:
3553         (WebCore::ScrollbarTheme::usesOverlayScrollbars):
3554         * platform/mac/ScrollbarThemeMac.h:
3555         * platform/mac/ScrollbarThemeMac.mm:
3556         (WebCore::ScrollbarThemeMac::usesOverlayScrollbars):
3557
3558         includeVerticalScrollbarSize() and includeHorizontalScrollbarSize()
3559         should return false for overlay scrollers. They already return
3560         false for overflow:overlay.
3561         * rendering/RenderBox.cpp:
3562         (WebCore::RenderBox::includeVerticalScrollbarSize):
3563         (WebCore::RenderBox::includeHorizontalScrollbarSize):
3564         * rendering/RenderBox.h:
3565
3566         In the render tree, always treat overlay scrollers like
3567         they have a width and height of 0.
3568         * rendering/RenderLayer.cpp:
3569         (WebCore::RenderLayer::verticalScrollbarWidth):
3570         (WebCore::RenderLayer::horizontalScrollbarHeight):
3571         * rendering/RenderListBox.cpp:
3572         (WebCore::RenderListBox::verticalScrollbarWidth):
3573
3574 2011-01-18  Evan Martin  <evan@chromium.org>
3575
3576         Reviewed by Tony Chang.
3577
3578         [chromium] simplify complex text code, fixing a handful of layout tests
3579         https://bugs.webkit.org/show_bug.cgi?id=52661
3580
3581         Change ComplexTextControllerLinux to lay out RTL text to the left from
3582         the starting point.  (Previously it always went to the right.)  This allows
3583         us to map pixel offsets more directly into offsets within the text runs,
3584         simplifying a few of the text-fiddling functions (they no longer need to
3585         track the current position, as ComplexTextController now does it).
3586
3587         * platform/graphics/chromium/ComplexTextControllerLinux.cpp:
3588         (WebCore::ComplexTextController::ComplexTextController):
3589         (WebCore::ComplexTextController::reset):
3590         (WebCore::ComplexTextController::setGlyphXPositions):
3591         * platform/graphics/chromium/ComplexTextControllerLinux.h:
3592         (WebCore::ComplexTextController::offsetX):
3593         * platform/graphics/chromium/FontLinux.cpp:
3594         (WebCore::Font::drawComplexText):
3595         (WebCore::Font::floatWidthForComplexText):
3596         (WebCore::glyphIndexForXPositionInScriptRun):
3597         (WebCore::Font::offsetForPositionForComplexText):
3598         (WebCore::Font::selectionRectForComplexText):
3599
3600 2011-01-19  Pavel Feldman  <pfeldman@chromium.org>
3601
3602         Reviewed by Yury Semikhatsky.
3603
3604         Web Inspector: move methods from InjectedScript domain into DOM,
3605         Runtime and Debugger domains. Introduce InspectorRuntimeAgent.
3606         https://bugs.webkit.org/show_bug.cgi?id=52717
3607
3608         * CMakeLists.txt:
3609         * GNUmakefile.am:
3610         * WebCore.gypi:
3611         * WebCore.pro:
3612         * WebCore.vcproj/WebCore.vcproj:
3613         * WebCore.xcodeproj/project.pbxproj:
3614         * inspector/CodeGeneratorInspector.pm:
3615         * inspector/InjectedScript.cpp:
3616         (WebCore::InjectedScript::evaluateOnCallFrame):
3617         (WebCore::InjectedScript::getCompletions):
3618         (WebCore::InjectedScript::getCompletionsOnCallFrame):
3619         * inspector/InjectedScript.h:
3620         * inspector/InjectedScriptHost.cpp:
3621         (WebCore::InjectedScriptHost::injectedScriptForMainWorld):
3622         * inspector/InjectedScriptHost.h:
3623         * inspector/InjectedScriptSource.js:
3624         (.):
3625         ():
3626         * inspector/Inspector.idl:
3627         * inspector/InspectorController.cpp:
3628         (WebCore::InspectorController::connectFrontend):
3629         (WebCore::InspectorController::releaseFrontendLifetimeAgents):
3630         * inspector/InspectorController.h:
3631         * inspector/InspectorDOMAgent.cpp:
3632         (WebCore::InspectorDOMAgent::InspectorDOMAgent):
3633         (WebCore::InspectorDOMAgent::resolveNode):
3634         (WebCore::InspectorDOMAgent::getNodeProperties):
3635         (WebCore::InspectorDOMAgent::getNodePrototypes):
3636         (WebCore::InspectorDOMAgent::injectedScriptForNodeId):
3637         * inspector/InspectorDOMAgent.h:
3638         (WebCore::EventListenerInfo::EventListenerInfo):
3639         (WebCore::InspectorDOMAgent::DOMListener::~DOMListener):
3640         (WebCore::InspectorDOMAgent::create):
3641         (WebCore::InspectorDOMAgent::cast):
3642         (WebCore::InspectorDOMAgent::documents):
3643         * inspector/InspectorDebuggerAgent.cpp:
3644         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
3645         (WebCore::InspectorDebuggerAgent::getCompletionsOnCallFrame):
3646         (WebCore::InspectorDebuggerAgent::injectedScriptForCallFrameId):
3647         * inspector/InspectorDebuggerAgent.h:
3648         * inspector/InspectorRuntimeAgent.cpp: Added.
3649         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
3650         (WebCore::InspectorRuntimeAgent::~InspectorRuntimeAgent):
3651         (WebCore::InspectorRuntimeAgent::evaluate):
3652         (WebCore::InspectorRuntimeAgent::getCompletions):
3653         (WebCore::InspectorRuntimeAgent::getProperties):
3654         (WebCore::InspectorRuntimeAgent::setPropertyValue):
3655         (WebCore::InspectorRuntimeAgent::pushNodeToFrontend):
3656         (WebCore::InspectorRuntimeAgent::injectedScriptForObjectId):
3657         * inspector/InspectorRuntimeAgent.h: Copied from Source/WebCore/inspector/InjectedScript.h.
3658         (WebCore::InspectorRuntimeAgent::create):
3659         * inspector/front-end/ConsoleView.js:
3660         (WebInspector.ConsoleView.prototype.completions):
3661         * inspector/front-end/ScriptsPanel.js:
3662         (WebInspector.ScriptsPanel.prototype.doEvalInCallFrame):
3663
3664 2011-01-18  Pavel Podivilov  <podivilov@chromium.org>
3665
3666         Reviewed by Yury Semikhatsky.
3667
3668         Web Inspector: add UglifyJS parser and formatter files
3669         https://bugs.webkit.org/show_bug.cgi?id=51702
3670
3671         * WebCore.gypi:
3672         * WebCore.vcproj/WebCore.vcproj:
3673         * inspector/front-end/ScriptFormatter.js:
3674         (WebInspector.ScriptFormatter.positionToLocation):
3675         (WebInspector.ScriptFormatter.prototype.format.messageHandler):
3676         (WebInspector.ScriptFormatter.prototype.format):
3677         (WebInspector.ScriptFormatter.prototype._buildMapping):
3678         (WebInspector.ScriptFormatter.prototype._convertPosition):
3679         * inspector/front-end/SourceFrame.js:
3680         (WebInspector.SourceFrame.prototype.formatSource.didFormat):
3681         (WebInspector.SourceFrame.prototype.formatSource):
3682         * inspector/front-end/WebKit.qrc:
3683         * inspector/front-end/parse-js.js: Added. UglifyJS parser.
3684         * inspector/front-end/process.js: Added. UglifyJS formatter.
3685         * inspector/front-end/scriptFormatterWorker.js: Added. Worker script that wraps UglifyJS code.
3686         (onmessage):
3687         (beautify):
3688         (loadModule):
3689         (require):
3690         * inspector/front-end/utilities.js:
3691         ():
3692
3693 2011-01-19  Pavel Podivilov  <podivilov@chromium.org>
3694
3695         Reviewed by Yury Semikhatsky.
3696
3697         Web Inspector: [JSC] scripts have incorrect starting line (always 1).
3698         https://bugs.webkit.org/show_bug.cgi?id=52721
3699
3700         Test: inspector/debugger-scripts.html
3701
3702         * bindings/js/ScriptDebugServer.cpp:
3703         (WebCore::ScriptDebugServer::dispatchDidParseSource):
3704         (WebCore::ScriptDebugServer::dispatchFailedToParseSource):
3705         (WebCore::ScriptDebugServer::sourceParsed):
3706         * bindings/js/ScriptDebugServer.h:
3707         * bindings/js/ScriptSourceCode.h:
3708         (WebCore::ScriptSourceCode::ScriptSourceCode):
3709         * bindings/js/StringSourceProvider.h:
3710         (WebCore::StringSourceProvider::create):
3711         (WebCore::StringSourceProvider::startPosition):
3712         (WebCore::StringSourceProvider::StringSourceProvider):
3713
3714 2011-01-19  Satish Sampath  <satish@chromium.org>
3715
3716         Reviewed by Jeremy Orlow.
3717
3718         Send origin/url as part of speech input requests to the embedder.
3719         https://bugs.webkit.org/show_bug.cgi?id=52718
3720
3721         * page/SpeechInput.cpp:
3722         (WebCore::SpeechInput::startRecognition): Pass up additional origin parameter.
3723         * page/SpeechInput.h:
3724         * page/SpeechInputClient.h:
3725         * platform/mock/SpeechInputClientMock.cpp:
3726         (WebCore::SpeechInputClientMock::startRecognition): Updated prototype.
3727         * platform/mock/SpeechInputClientMock.h:
3728         * rendering/TextControlInnerElements.cpp:
3729         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler): Pass the frame origin to speech input request.
3730
3731 2011-01-19  Hans Wennborg  <hans@chromium.org>
3732
3733         Reviewed by Jeremy Orlow.
3734
3735         IndexedDB: Support auto-increment keys
3736         https://bugs.webkit.org/show_bug.cgi?id=52576
3737
3738         Add support for auto-increment keys.
3739
3740         Test: storage/indexeddb/objectstore-autoincrement.html
3741
3742         * storage/IDBDatabase.cpp:
3743         (WebCore::IDBDatabase::createObjectStore):
3744         * storage/IDBObjectStoreBackendImpl.cpp:
3745         (WebCore::genAutoIncrementKey):
3746         (WebCore::IDBObjectStoreBackendImpl::putInternal):
3747
3748 2011-01-19  Csaba Osztrogonác  <ossy@webkit.org>
3749
3750         Reviewed by Laszlo Gombos and Tor Arne Vestbø.
3751
3752         [Qt] Remove unnecessary "../Source" from paths
3753         after moving source files into Source is finished.
3754
3755         * WebCore.pri:
3756         * WebCore.pro:
3757
3758 2011-01-19  Alexander Pavlov  <apavlov@chromium.org>
3759
3760         Reviewed by Pavel Feldman.
3761
3762         Web Inspector: Employ TextPrompt for CSS property name/value autocompletion
3763         https://bugs.webkit.org/show_bug.cgi?id=52212
3764
3765         WebInspector.CSSKeywordCompletions contains a hand-written list of accepted CSS property value keywords
3766         for each property. WebInspector.TextPrompt is used to suggest both the name and value keywords while
3767         editing styles, in place of the old custom suggestion code.
3768
3769         * inspector/front-end/CSSCompletions.js:
3770         (WebInspector.CSSCompletions.prototype.startsWith): Fix array-out-of-bounds error.
3771         * inspector/front-end/CSSKeywordCompletions.js: Added.
3772         (WebInspector.CSSKeywordCompletions.forProperty):
3773         * inspector/front-end/StylesSidebarPane.js:
3774         (WebInspector.StylePropertyTreeElement.prototype.updateTitle):
3775         (WebInspector.StylePropertyTreeElement.prototype):
3776         ():
3777         * inspector/front-end/TextPrompt.js:
3778         (WebInspector.TextPrompt):
3779         (WebInspector.TextPrompt.prototype.removeFromElement):
3780         (WebInspector.TextPrompt.prototype._onKeyDown):
3781         (WebInspector.TextPrompt.prototype.tabKeyPressed):
3782         (WebInspector.TextPrompt.prototype.upKeyPressed):
3783         (WebInspector.TextPrompt.prototype.downKeyPressed):
3784         (WebInspector.TextPrompt.prototype._moveBackInHistory):
3785         (WebInspector.TextPrompt.prototype._moveForwardInHistory):
3786         * inspector/front-end/inspector.css:
3787         (.auto-complete-text, .editing .auto-complete-text):
3788         * inspector/front-end/inspector.html:
3789
3790 2011-01-19  Dai Mikurube  <dmikurube@google.com>
3791
3792         Reviewed by Kent Tamura.
3793
3794         Implement onformchange and onforminput event handlers
3795         https://bugs.webkit.org/show_bug.cgi?id=26141
3796
3797         Tests: fast/forms/formchange-event.html
3798                fast/forms/forminput-event.html
3799
3800         * bindings/scripts/CodeGeneratorGObject.pm: Added event names.
3801         * dom/Document.h: Added event definitions.
3802         * dom/Document.idl: Added event definitions.
3803         * dom/Element.h: Added event definitions.
3804         * dom/Element.idl: Added event definitions.
3805         * dom/Event.cpp:
3806         (WebCore::Event::fromUserGesture): Added a condition for a formchange event in handling user gestures.
3807         * dom/EventNames.h: Added event definitions.
3808         * dom/InputElement.cpp:
3809         (WebCore::InputElement::setValueFromRenderer): Replaced a direct dispatchEvent() call into dispatchInputEvents(), a virtual function which broadcasts forminput events for HTML elements.
3810         * dom/Node.cpp:
3811         (WebCore::Node::dispatchInputEvents): Defined basic dispatchInputEvents() described above.
3812         (WebCore::Node::dispatchChangeEvents): Defined basic dispatchChangeEvents() described above.
3813         (WebCore::Node::defaultEventHandler): Replaced a direct dispatchEvent() call into dispatchInputEvents().
3814         * dom/Node.h:
3815         * html/FormAssociatedElement.h: Added isResettable() to check the element is resettable or not.
3816         * html/HTMLAttributeNames.in: Added event names.
3817         * html/HTMLElement.cpp:
3818         (WebCore::HTMLElement::parseMappedAttribute): Added event handling.
3819         (WebCore::HTMLElement::shadowAncestorOwnerForm): Added to get an ancestor <form> element from a shadow element.
3820         (WebCore::HTMLElement::dispatchChangeEvents): Defined dispatchChangeEvents() for HTML elements described above.
3821         (WebCore::HTMLElement::dispatchInputEvents): Defined dispatchInputEvents() for HTML elements described above.
3822         * html/HTMLElement.h:
3823         * html/HTMLFormControlElement.cpp:
3824         (WebCore::HTMLFormControlElement::dispatchFormControlChangeEvent): Added calling dispatchFormChange() to broadcast formchange events.
3825         (WebCore::HTMLFormControlElement::dispatchFormControlInputEvent): Defined newly to dispatch an input event with broadcasting forminput events.
3826         * html/HTMLFormControlElement.h: Added isResettable().
3827         * html/HTMLFormElement.cpp:
3828         (WebCore::HTMLFormElement::broadcastFormEvent): Added to broadcast forminput or formchange events.
3829         (WebCore::HTMLFormElement::dispatchFormInput): Defined newly to broadcast forminput events.
3830         (WebCore::HTMLFormElement::dispatchFormChange): Defined newly to broadcast formchange events.
3831         * html/HTMLFormElement.h:
3832         * html/HTMLFormElement.idl: Added dispatchFormInput() and dispatchFormChange() DOM API definitions.
3833         * html/HTMLInputElement.cpp:
3834         (WebCore::HTMLInputElement::stepUpFromRenderer): Replaced a direct dispatchEvent() call into dispatchInputEvents().
3835         * html/HTMLInputElement.h: Added isResettable().
3836         * html/HTMLKeygenElement.h: Added isResettable().
3837         * html/HTMLObjectElement.h: Added isResettable().
3838         * html/HTMLOutputElement.h: Added isResettable().
3839         * html/HTMLSelectElement.h: Added isResettable().
3840         * html/HTMLTextAreaElement.h: Added isResettable().
3841         * page/DOMWindow.h: Added event definitions.
3842         * page/DOMWindow.idl: Added event definitions.
3843         * rendering/TextControlInnerElements.cpp:
3844         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler): Replaced a direct dispatchEvent() call into dispatchInputEvents().
3845
3846 2011-01-19  Andrey Kosyakov  <caseq@chromium.org>
3847
3848         Reviewed by Pavel Feldman.
3849
3850         Web Inspector: [Extensions API] delete pending callback from callback map before invoking it
3851         https://bugs.webkit.org/show_bug.cgi?id=52707
3852
3853         * inspector/front-end/ExtensionAPI.js:
3854         (WebInspector.injectedExtensionAPI.ExtensionServerClient.prototype._onCallback):
3855
3856 2011-01-19  Levi Weintraub  <leviw@google.com>
3857
3858         Reviewed by Ryosuke Niwa.
3859
3860         Replaced rangeCompliantEquivalent with Position::parentAnchoredEquivalent
3861         and simplified the logic a bit. Unfortunately, Tables and some legacy
3862         editing positions still need to be handled specifically.
3863
3864         remove rangeCompliantEquivalent and replace it with Position methods
3865         https://bugs.webkit.org/show_bug.cgi?id=25057
3866
3867         No new tests as this is a refactor that doesn't change behavior.
3868
3869         * WebCore.exp.in:
3870         * dom/Document.cpp:
3871         (WebCore::Document::caretRangeFromPoint):
3872         * dom/Position.cpp:
3873         (WebCore::Position::parentAnchoredEquivalent):
3874         * dom/Position.h:
3875         * editing/ApplyStyleCommand.cpp:
3876         (WebCore::ApplyStyleCommand::applyBlockStyle):
3877         * editing/CompositeEditCommand.cpp:
3878         (WebCore::CompositeEditCommand::insertNodeAt):
3879         (WebCore::CompositeEditCommand::moveParagraphs):
3880         * editing/DeleteSelectionCommand.cpp:
3881         (WebCore::DeleteSelectionCommand::initializePositionData):
3882         (WebCore::DeleteSelectionCommand::mergeParagraphs):
3883         * editing/Editor.cpp:
3884         (WebCore::Editor::textDirectionForSelection):
3885         (WebCore::Editor::advanceToNextMisspelling):
3886         * editing/InsertLineBreakCommand.cpp:
3887         (WebCore::InsertLineBreakCommand::shouldUseBreakElement):
3888         * editing/InsertParagraphSeparatorCommand.cpp:
3889         (WebCore::InsertParagraphSeparatorCommand::doApply):
3890         * editing/ReplaceSelectionCommand.cpp:
3891         (WebCore::handleStyleSpansBeforeInsertion):
3892         * editing/VisiblePosition.cpp:
3893         (WebCore::makeRange):
3894         (WebCore::setStart):
3895         (WebCore::setEnd):
3896         * editing/VisibleSelection.cpp:
3897         (WebCore::VisibleSelection::firstRange):
3898         (WebCore::VisibleSelection::toNormalizedRange):
3899         (WebCore::makeSearchRange):
3900         * editing/htmlediting.cpp:
3901         (WebCore::indexForVisiblePosition):
3902         * editing/htmlediting.h:
3903         * editing/visible_units.cpp:
3904         (WebCore::previousBoundary):
3905         (WebCore::nextBoundary):
3906         * page/DOMSelection.cpp:
3907         (WebCore::anchorPosition):
3908         (WebCore::focusPosition):
3909         (WebCore::basePosition):
3910         (WebCore::extentPosition):
3911
3912 2011-01-19  Peter Rybin  <peter.rybin@gmail.com>
3913
3914         Reviewed by Yury Semikhatsky.
3915
3916         Web Inspector: script column offset is incorrect
3917         https://bugs.webkit.org/show_bug.cgi?id=52580
3918
3919         Column is updated in 3 places, 2 less probable places contained error.
3920         Fixed now.
3921
3922         * platform/text/SegmentedString.cpp:
3923         (WebCore::SegmentedString::advanceSlowCase):
3924         * platform/text/SegmentedString.h:
3925         (WebCore::SegmentedString::advancePastNewline):
3926
3927 2011-01-18  Pavel Feldman  <pfeldman@chromium.org>
3928
3929         Reviewed by Yury Semikhatsky.
3930
3931         Web Inspector: make InjectedScriptAccess API a part of Web Inspector protocol.
3932         https://bugs.webkit.org/show_bug.cgi?id=52652
3933
3934         Calls served by the InjectedScript should be first class protocol
3935         citizens, not dispatched via single protocol message.
3936
3937         * WebCore.gypi:
3938         * WebCore.vcproj/WebCore.vcproj:
3939         * inspector/CodeGeneratorInspector.pm:
3940         * inspector/InjectedScript.cpp:
3941         (WebCore::InjectedScript::evaluate):
3942         (WebCore::InjectedScript::evaluateInCallFrame):
3943         (WebCore::InjectedScript::evaluateOnSelf):
3944         (WebCore::InjectedScript::getCompletions):
3945         (WebCore::InjectedScript::getProperties):
3946         (WebCore::InjectedScript::pushNodeToFrontend):
3947         (WebCore::InjectedScript::resolveNode):
3948         (WebCore::InjectedScript::getNodeProperties):
3949         (WebCore::InjectedScript::getNodePrototypes):
3950         (WebCore::InjectedScript::setPropertyValue):
3951         (WebCore::InjectedScript::makeCall):
3952         * inspector/InjectedScript.h:
3953         * inspector/InjectedScriptHost.cpp:
3954         (WebCore::InjectedScriptHost::evaluate):
3955         (WebCore::InjectedScriptHost::evaluateInCallFrame):
3956         (WebCore::InjectedScriptHost::evaluateOnSelf):
3957         (WebCore::InjectedScriptHost::getCompletions):
3958         (WebCore::InjectedScriptHost::getProperties):
3959         (WebCore::InjectedScriptHost::pushNodeToFrontend):
3960         (WebCore::InjectedScriptHost::resolveNode):
3961         (WebCore::InjectedScriptHost::getNodeProperties):
3962         (WebCore::InjectedScriptHost::getNodePrototypes):
3963         (WebCore::InjectedScriptHost::setPropertyValue):
3964         (WebCore::InjectedScriptHost::injectedScriptForObjectId):
3965         (WebCore::InjectedScriptHost::injectedScriptForNodeId):
3966         (WebCore::InjectedScriptHost::injectedScriptForMainWorld):
3967         * inspector/InjectedScriptHost.h:
3968         * inspector/InjectedScriptSource.js:
3969         (.):
3970         * inspector/Inspector.idl:
3971         * inspector/InspectorController.cpp:
3972         * inspector/InspectorController.h:
3973         * inspector/InspectorValues.cpp:
3974         (WebCore::InspectorObject::getNumber):
3975         * inspector/InspectorValues.h:
3976         * inspector/front-end/AuditRules.js:
3977         (WebInspector.AuditRules.evaluateInTargetWindow):
3978         * inspector/front-end/ConsoleView.js:
3979         (WebInspector.ConsoleView.prototype.completions):
3980         (WebInspector.ConsoleView.prototype.doEvalInWindow):
3981         * inspector/front-end/ElementsTreeOutline.js:
3982         (WebInspector.ElementsTreeElement.prototype._createTooltipForNode):
3983         * inspector/front-end/ExtensionPanel.js:
3984         (WebInspector.ExtensionWatchSidebarPane.prototype.setExpression):
3985         * inspector/front-end/ExtensionServer.js:
3986         (WebInspector.ExtensionServer.prototype._onEvaluateOnInspectedPage):
3987         * inspector/front-end/InjectedScriptAccess.js: Removed.
3988         * inspector/front-end/PropertiesSidebarPane.js:
3989         (WebInspector.PropertiesSidebarPane.prototype.update.callback):
3990         (WebInspector.PropertiesSidebarPane.prototype.update):
3991         * inspector/front-end/RemoteObject.js:
3992         (WebInspector.RemoteObject.resolveNode):
3993         (WebInspector.RemoteObject.prototype.getProperties):
3994         (WebInspector.RemoteObject.prototype.setPropertyValue):
3995         (WebInspector.RemoteObject.prototype.pushNodeToFrontend):
3996         * inspector/front-end/ScriptsPanel.js:
3997         (WebInspector.ScriptsPanel.prototype.doEvalInCallFrame):
3998         * inspector/front-end/WebKit.qrc:
3999         * inspector/front-end/inspector.html: