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