<rdar://problem/9251515> and https://bugs.webkit.org/show_bug.cgi?id=58072
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-04-11  Brady Eidson  <beidson@apple.com>
2
3         Reviewed by Maciej Stachowiak.
4
5         <rdar://problem/9251515> and https://bugs.webkit.org/show_bug.cgi?id=58072
6         URLs accessed as a result of pushState/replaceState should count as "visited" and be in the global history
7
8         Test: fast/loader/stateobjects/state-url-sets-links-visited.html
9
10         * loader/HistoryController.cpp:
11         (WebCore::HistoryController::pushState): Notify the history client and add the visited link.
12         (WebCore::HistoryController::replaceState): Ditto.
13
14 2011-04-11  Dimitri Glazkov  <dglazkov@chromium.org>
15
16         Reviewed by Eric Carlson.
17
18         Rename MediaControls to MediaControlRootElement.
19         https://bugs.webkit.org/show_bug.cgi?id=58250
20
21         Mechanical move using do-webcore-rename.
22
23 2011-04-11  Dean Jackson  <dino@apple.com>
24
25         Reviewed by Simon Fraser.
26
27         https://bugs.webkit.org/show_bug.cgi?id=58285
28         CompositeAnimation is cleared while an AnimationBase is waiting for notification
29
30         Occasionally hardware animations would trigger a state where
31         they would tell the AnimationControllerPrivate that it should notify
32         any waiting animations that they are ready to start, even though
33         the RenderObject had gone away and hence the CompositeAnimation
34         had been destroyed. The fix is to zero the pointer from AnimationBase
35         when the CompositeAnimation destructor runs (or its animations are
36         cleared) and test the validity of the CompositeAnimation before it
37         is used in AnimationBase.
38
39         * page/animation/AnimationBase.cpp:
40         (WebCore::AnimationBase::updateStateMachine):
41         (WebCore::AnimationBase::fireAnimationEventsIfNeeded):
42         (WebCore::AnimationBase::updatePlayState):
43         (WebCore::AnimationBase::freezeAtTime):
44         (WebCore::AnimationBase::beginAnimationUpdateTime):
45         - test that the CompositeAnimation exists
46         * page/animation/AnimationBase.h:
47         (WebCore::AnimationBase::clear):
48         - rename clearRenderer() to clear() as it now also clears the CompositeAnimation
49         * page/animation/CompositeAnimation.cpp:
50         (WebCore::CompositeAnimation::clearRenderer):
51         (WebCore::CompositeAnimation::updateKeyframeAnimations):
52         - call clear() rather than clearRenderer()
53
54 2011-04-11  Justin Novosad  <junov@chromium.org>
55
56         Reviewed by Kenneth Russell.
57
58         [Chromium] Text anti-aliasing fails when rendering text with shadow
59         https://bugs.webkit.org/show_bug.cgi?id=57584
60
61         * platform/graphics/chromium/FontChromiumWin.cpp:
62         (WebCore::drawGlyphsWin): new static function, code factored-out
63         from WebCore::Font::drawGlyphs
64         (WebCore::Font::drawGlyphs): may separate font rendering into two
65         passes to allow foreground glyphs to be rendered with GDI when Skia 
66         is required for rendering shadows
67         * platform/graphics/skia/SkiaFontWin.cpp:
68         (WebCore::windowsCanHandleDrawTextShadow):
69         Modified method so that it does not assume a shadow is present, and
70         returns true if there is no shadow (GDI can draw 'no shadow')
71         (WebCore::windowsCanHandleTextDrawing):
72         Factored out into sub methods so that the the shadow and foregound
73         glyph properties can be tested separately independently.
74         (WebCore::windowsCanHandleTextDrawingWithoutShadow):
75         New method returns true if the foreground glyph only has effect
76         that can be draw with GDI
77         (WebCore::paintSkiaText):
78         * platform/graphics/skia/SkiaFontWin.h:
79
80 2011-04-11  Ryosuke Niwa  <rniwa@webkit.org>
81
82         Unreviewed, rolling out r83515.
83         http://trac.webkit.org/changeset/83515
84         https://bugs.webkit.org/show_bug.cgi?id=57178
85
86         Broke GTK builds. nextOnLineExists and prevOnLineExists are still used in AccessibilityObjectWrapperAtk.cpp.
87
88         * rendering/InlineBox.cpp:
89         (WebCore::InlineBox::nextOnLineExists):
90         (WebCore::InlineBox::prevOnLineExists):
91         * rendering/InlineBox.h:
92         (WebCore::InlineBox::InlineBox):
93
94 2011-04-11  Brady Eidson  <beidson@apple.com>
95
96         Reverting, seeing something else still broken.  Sorry.
97
98         * html/HTMLTrackElement.cpp:
99
100 2011-04-11  Brady Eidson  <beidson@apple.com>
101
102         Fix the build.
103
104         * html/HTMLTrackElement.cpp: Case-sensitive, please.
105
106 2011-04-11  Alexis Menard  <alexis.menard@openbossa.org>
107
108         Unreviewed build fix for Mac.
109
110         An idl file was added in the wrong place.
111
112         * WebCore.xcodeproj/project.pbxproj:
113
114 2011-04-11  Chris Marrin  <cmarrin@apple.com>
115
116         Rubberstamped by Dan Bernstein.
117
118         xhr.responseType = 'arraybuffer' works on Mac but not on Windows
119         https://bugs.webkit.org/show_bug.cgi?id=50334
120
121         Got rid of guards around arraybuffer logic in XHR. ArrayBuffer and friends
122         are always turned on now, so there's not need for the guard. I reenabled the
123         test that was Skipped on Windows and it works now.
124
125         * bindings/js/JSXMLHttpRequestCustom.cpp:
126         (WebCore::JSXMLHttpRequest::markChildren):
127         (WebCore::JSXMLHttpRequest::send):
128         (WebCore::JSXMLHttpRequest::response):
129         * xml/XMLHttpRequest.cpp:
130         (WebCore::XMLHttpRequest::responseArrayBuffer):
131         (WebCore::XMLHttpRequest::setResponseType):
132         (WebCore::XMLHttpRequest::send):
133         (WebCore::XMLHttpRequest::clearResponseBuffers):
134         (WebCore::XMLHttpRequest::didReceiveData):
135         * xml/XMLHttpRequest.h:
136         (WebCore::XMLHttpRequest::optionalResponseArrayBuffer):
137
138 2011-04-11  Anna Cavender  <annacc@chromium.org>
139
140         Reviewed by Eric Carlson.
141
142         Setup ENABLE(TRACK) feature define + initial HTMLTrackElement
143         https://bugs.webkit.org/show_bug.cgi?id=53556
144
145         No new tests. No real functionality added just yet.
146
147         * CMakeLists.txt:
148         * CodeGenerators.pri:
149         * Configurations/FeatureDefines.xcconfig:
150         * DerivedSources.make:
151         * GNUmakefile.am:
152         * GNUmakefile.list.am:
153         * WebCore.gypi:
154         * WebCore.xcodeproj/project.pbxproj:
155         * features.pri:
156         * html/HTMLAttributeNames.in:
157         * html/HTMLTagNames.in:
158         * html/HTMLTrackElement.cpp: Added.
159         (WebCore::HTMLTrackElement::HTMLTrackElement):
160         (WebCore::HTMLTrackElement::create):
161         (WebCore::HTMLTrackElement::insertedIntoTree):
162         (WebCore::HTMLTrackElement::willRemove):
163         (WebCore::HTMLTrackElement::src):
164         (WebCore::HTMLTrackElement::setSrc):
165         (WebCore::HTMLTrackElement::kind):
166         (WebCore::HTMLTrackElement::setKind):
167         (WebCore::HTMLTrackElement::srclang):
168         (WebCore::HTMLTrackElement::setSrclang):
169         (WebCore::HTMLTrackElement::label):
170         (WebCore::HTMLTrackElement::setLabel):
171         (WebCore::HTMLTrackElement::isDefault):
172         (WebCore::HTMLTrackElement::setIsDefault):
173         (WebCore::HTMLTrackElement::isURLAttribute):
174         * html/HTMLTrackElement.h: Added.
175         * html/HTMLTrackElement.idl: Added.
176
177 2011-04-11  Ben Taylor  <bentaylor.solx86@gmail.com>
178
179         Reviewed by David Levin.
180
181         https://bugs.webkit.org/show_bug.cgi?id=57535
182
183         Better compile fix for Solaris 10/Sun Studio 12 CC 
184         needing <sys/time.h>
185
186         * loader/icon/IconRecord.h:
187         * page/Page.h:
188         * platform/network/ResourceResponseBase.h:
189
190 2011-04-11  Alexey Proskuryakov  <ap@apple.com>
191
192         Reviewed by Maciej Stachowiak.
193
194         WebKit2: Cannot use Ctrl-Delete as a custom keyboard shortcut
195         https://bugs.webkit.org/show_bug.cgi?id=58265
196         <rdar://problem/9221468>
197
198         * page/EventHandler.cpp:
199         (WebCore::EventHandler::defaultKeyboardEventHandler): Handle Backspace.
200         (WebCore::EventHandler::defaultSpaceEventHandler): Enabled this on Mac, and added checks for
201         other modifiers - no one wants to scroll on Ctrl+Alt+Space and such.
202         (WebCore::EventHandler::defaultBackspaceEventHandler): Backspace goes back, Shift-backspace
203         goes forward. All browsers do it.
204         (WebCore::EventHandler::defaultArrowEventHandler): Assert that this function was called
205         for a correct event.
206         (WebCore::EventHandler::defaultTabEventHandler): Ditto.
207
208         * page/EventHandler.h: Added defaultBackspaceEventHandler.
209
210 2011-04-11  Matthew Delaney  <mdelaney@apple.com>
211
212         Reviewed by Dan Bernstein.
213
214         [CG] drawImage with a subimage bleeds pixel data at borders
215         https://bugs.webkit.org/show_bug.cgi?id=58267
216
217         Test: fast/canvas/DrawImageSinglePixelStretch.html
218
219         * platform/graphics/cg/ImageCG.cpp:
220         (WebCore::BitmapImage::draw): Any interpolation quality other than 'none' will graft out the subimage first now.
221
222 2011-04-11  Chris Marrin  <cmarrin@apple.com>
223
224         Reviewed by Simon Fraser.
225
226         iframe/compositing propagation should also work for <object> and framesets
227         https://bugs.webkit.org/show_bug.cgi?id=39037
228
229         Generalized the code that handles the parenting of composited <iframe> elements
230         to include <frame> and <object> elements. This includes forcing the parent
231         element to be composited and constructing the layer tree in the child document
232         and properly parenting it. Much of the change is giving the function calls more
233         generic names (from ...IFrame... to ...Frame...)
234         
235         Compositing tests that were done in RenderIFrame have been moved to RenderPart
236         since this is the highest base class common to all 3 elements.
237         
238         I also renamed several ...IFrame... functions to
239         ...Frame... and changed them so they work on a RenderPart for determining
240         if the renderer is composited. One other detail is that <iframe> and 
241         <object> never share style since they might be composited. I had to add
242         <frame> to that list.
243
244         Tests: compositing/framesets/composited-frame-alignment.html
245                compositing/objects/composited-object-alignment.html
246
247         * css/CSSStyleSelector.cpp: Add <frame> to list of element types that should never share style since it might be composited.
248         (WebCore::CSSStyleSelector::canShareStyleWithElement):
249         * page/FrameView.cpp:
250         (WebCore::FrameView::hasCompositedContentIncludingDescendants):
251         (WebCore::FrameView::setIsOverlapped):
252         * rendering/RenderIFrame.cpp: Moved methods to RenderPart
253         * rendering/RenderIFrame.h:
254         * rendering/RenderLayerBacking.cpp:
255         (WebCore::RenderLayerBacking::updateAfterWidgetResize):
256         (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration):
257         (WebCore::RenderLayerBacking::paintingGoesToWindow):
258         * rendering/RenderLayerCompositor.cpp:
259         (WebCore::RenderLayerCompositor::updateBacking):
260         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
261         (WebCore::RenderLayerCompositor::frameContentsCompositor):
262         (WebCore::RenderLayerCompositor::parentFrameContentLayers):
263         (WebCore::RenderLayerCompositor::didMoveOnscreen):
264         (WebCore::RenderLayerCompositor::allowsIndependentlyCompositedFrames):
265         (WebCore::RenderLayerCompositor::shouldPropagateCompositingToEnclosingFrame):
266         (WebCore::RenderLayerCompositor::enclosingFrameElement):
267         (WebCore::RenderLayerCompositor::requiresCompositingLayer):
268         (WebCore::RenderLayerCompositor::requiresCompositingForFrame):
269         (WebCore::RenderLayerCompositor::requiresScrollLayer):
270         (WebCore::RenderLayerCompositor::ensureRootPlatformLayer):
271         (WebCore::RenderLayerCompositor::attachRootPlatformLayer):
272         (WebCore::RenderLayerCompositor::detachRootPlatformLayer):
273         * rendering/RenderLayerCompositor.h:
274         * rendering/RenderPart.cpp: Functions moved from RenderIFrame
275         (WebCore::RenderPart::requiresLayer):
276         (WebCore::RenderPart::requiresAcceleratedCompositing):
277         * rendering/RenderPart.h:
278
279 2011-04-11  Yael Aharon  <yael.aharon@nokia.com>
280
281         Reviewed by Eric Seidel.
282
283         InlineBox::prevOnline and InlineBox::prevOnlineExists() are confusing and should be renamed
284         https://bugs.webkit.org/show_bug.cgi?id=57178
285
286         Remove prevOnLineExists() and nextOnLineExists() as they are not used anymore.
287         No new tests needed because this is cleanup only.
288
289         * rendering/InlineBox.cpp:
290         * rendering/InlineBox.h:
291         (WebCore::InlineBox::InlineBox):
292         (WebCore::InlineBox::setPrevOnLine):
293
294 2011-04-11  David Hyatt  <hyatt@apple.com>
295
296         Reviewed by Dan Bernstein.
297
298         https://bugs.webkit.org/show_bug.cgi?id=58261
299
300         Fix for layout regression on marketwatch.com. When I converted TrailingFloatsRootInlineBox over
301         to the new overflow model, I messed up the math and passed a bottom value where I should have
302         passed a height value. This patch fixes the code to be logically equivalent to the way it
303         was prior to my changes.
304
305         Added fast/overflow/trailing-float-linebox.html.
306
307         * rendering/RenderBlockLineLayout.cpp:
308         (WebCore::RenderBlock::layoutInlineChildren):
309
310 2011-04-11  Adrienne Walker  <enne@google.com>
311
312         Unreviewed, rolling out r83500.
313         http://trac.webkit.org/changeset/83500
314         https://bugs.webkit.org/show_bug.cgi?id=57113
315
316         Regresses huge-layer-rotated test
317
318         * platform/graphics/chromium/ContentLayerChromium.cpp:
319         (WebCore::ContentLayerChromium::ContentLayerChromium):
320         (WebCore::ContentLayerChromium::~ContentLayerChromium):
321         (WebCore::ContentLayerChromium::cleanupResources):
322         (WebCore::ContentLayerChromium::requiresClippedUpdateRect):
323         (WebCore::ContentLayerChromium::paintContentsIfDirty):
324         (WebCore::ContentLayerChromium::resizeUploadBuffer):
325         (WebCore::ContentLayerChromium::updateTextureIfNeeded):
326         (WebCore::ContentLayerChromium::updateTexture):
327         (WebCore::ContentLayerChromium::draw):
328         (WebCore::ContentLayerChromium::updateCompositorResources):
329         (WebCore::ContentLayerChromium::unreserveContentsTexture):
330         (WebCore::ContentLayerChromium::bindContentsTexture):
331         (WebCore::ContentLayerChromium::dumpLayerProperties):
332         * platform/graphics/chromium/ContentLayerChromium.h:
333         (WebCore::ContentLayerChromium::drawsContent):
334         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
335         (WebCore::GraphicsLayerChromium::setMaskLayer):
336         * platform/graphics/chromium/ImageLayerChromium.cpp:
337         (WebCore::ImageLayerChromium::paintContentsIfDirty):
338         (WebCore::ImageLayerChromium::updateTextureIfNeeded):
339         * platform/graphics/chromium/ImageLayerChromium.h:
340         * platform/graphics/chromium/LayerChromium.h:
341         (WebCore::LayerChromium::draw):
342         * platform/graphics/chromium/LayerRendererChromium.cpp:
343         (WebCore::LayerRendererChromium::drawRootLayer):
344         (WebCore::LayerRendererChromium::drawLayers):
345         (WebCore::LayerRendererChromium::paintContentsRecursive):
346         (WebCore::LayerRendererChromium::copyOffscreenTextureToDisplay):
347         (WebCore::LayerRendererChromium::drawLayer):
348         (WebCore::LayerRendererChromium::initializeSharedObjects):
349         (WebCore::LayerRendererChromium::cleanupSharedObjects):
350         * platform/graphics/chromium/LayerRendererChromium.h:
351         (WebCore::LayerRendererChromium::contentLayerProgram):
352         * platform/graphics/chromium/LayerTilerChromium.cpp:
353         (WebCore::LayerTilerChromium::invalidateRect):
354         (WebCore::LayerTilerChromium::update):
355         (WebCore::LayerTilerChromium::updateFromPixels):
356         (WebCore::LayerTilerChromium::draw):
357         * platform/graphics/chromium/LayerTilerChromium.h:
358         * platform/graphics/chromium/PlatformCanvas.cpp:
359         (WebCore::PlatformCanvas::AutoLocker::AutoLocker):
360         (WebCore::PlatformCanvas::Painter::Painter):
361         * platform/graphics/chromium/PlatformCanvas.h:
362         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
363         (WebCore::RenderSurfaceChromium::draw):
364         * platform/graphics/chromium/RenderSurfaceChromium.h:
365         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp:
366         (WebCore::CCCanvasLayerImpl::draw):
367         * platform/graphics/chromium/cc/CCCanvasLayerImpl.h:
368         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
369         (WebCore::CCHeadsUpDisplay::draw):
370         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
371         (WebCore::CCLayerImpl::draw):
372         * platform/graphics/chromium/cc/CCLayerImpl.h:
373         * platform/graphics/chromium/cc/CCPluginLayerImpl.cpp:
374         (WebCore::CCPluginLayerImpl::draw):
375         * platform/graphics/chromium/cc/CCPluginLayerImpl.h:
376         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
377         (WebCore::CCVideoLayerImpl::draw):
378         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
379
380 2011-04-11  Jon Honeycutt  <jhoneycutt@apple.com>
381
382         <rdar://problem/9267042> Assertion failure on launch in
383         LayerChangesFlusher::setHook().
384
385         https://bugs.webkit.org/show_bug.cgi?id=58270
386
387         Reviewed by Adam Roben.
388
389         * platform/graphics/ca/win/LayerChangesFlusher.cpp:
390         (WebCore::LayerChangesFlusher::setHook):
391         MSDN says that the HINSTANCE passed in must be null if the thread ID
392         passed is a thread created by this process and the hook procedure is
393         within this process.
394
395 2011-04-11  MORITA Hajime  <morrita@google.com>
396
397         Unreviewed build fix.
398
399         Changeset 83492 broke Leopard build.
400         https://bugs.webkit.org/show_bug.cgi?id=58268
401
402         * editing/Editor.cpp:
403         (WebCore::Editor::markMisspellingsAfterTypingToWord):
404
405 2011-03-25  Adrienne Walker  <enne@google.com>
406
407         Reviewed by James Robinson.
408
409         [chromium] Tile content and image layers
410         https://bugs.webkit.org/show_bug.cgi?id=57113
411
412         Layers tile by default if any dimension is larger than 512.  Smaller
413         layers are contained within a single texture but still use the tiler
414         infrastructure so that there's only one code path.
415
416         Remove large layer support from content layers.  Content layers no
417         longer own a platform canvas--they own a tiler.  Refactor tiler to
418         allow for better separation of update/upload/paint.  Add rect
419         parameter to update and draw functions on layers for the layer-space
420         rect of interest.  This is necessary to know which tiles need to be
421         drawn.
422
423         * platform/graphics/chromium/ContentLayerChromium.cpp:
424         (WebCore::ContentLayerChromium::ContentLayerChromium):
425         (WebCore::ContentLayerChromium::~ContentLayerChromium):
426         (WebCore::ContentLayerPainter::ContentLayerPainter):
427         (WebCore::ContentLayerPainter::paint):
428         (WebCore::ContentLayerChromium::paintContentsIfDirty):
429         (WebCore::ContentLayerChromium::setLayerRenderer):
430         (WebCore::ContentLayerChromium::tilingTransform):
431         (WebCore::ContentLayerChromium::visibleLayerRect):
432         (WebCore::ContentLayerChromium::layerBounds):
433         (WebCore::ContentLayerChromium::updateLayerSize):
434         (WebCore::ContentLayerChromium::draw):
435         (WebCore::ContentLayerChromium::createTilerIfNeeded):
436         (WebCore::ContentLayerChromium::updateCompositorResources):
437         (WebCore::ContentLayerChromium::setTilingOption):
438         (WebCore::ContentLayerChromium::bindContentsTexture):
439         (WebCore::ContentLayerChromium::unreserveContentsTexture):
440         (WebCore::ContentLayerChromium::setIsMask):
441         (WebCore::ContentLayerChromium::dumpLayerProperties):
442         * platform/graphics/chromium/ContentLayerChromium.h:
443         (WebCore::ContentLayerChromium::drawsContent):
444         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
445         (WebCore::GraphicsLayerChromium::setMaskLayer):
446         * platform/graphics/chromium/ImageLayerChromium.cpp:
447         (WebCore::ImageLayerChromium::paintContentsIfDirty):
448         (WebCore::ImageLayerChromium::updateCompositorResources):
449         (WebCore::ImageLayerChromium::layerBounds):
450         (WebCore::ImageLayerChromium::tilingTransform):
451         * platform/graphics/chromium/ImageLayerChromium.h:
452         * platform/graphics/chromium/LayerChromium.h:
453         (WebCore::LayerChromium::invalidateRect):
454         (WebCore::LayerChromium::paintContentsIfDirty):
455         (WebCore::LayerChromium::setIsMask):
456         (WebCore::LayerChromium::draw):
457         * platform/graphics/chromium/LayerRendererChromium.cpp:
458         (WebCore::LayerRendererChromium::drawRootLayer):
459         (WebCore::LayerRendererChromium::drawLayers):
460         (WebCore::LayerRendererChromium::paintContentsRecursive):
461         (WebCore::LayerRendererChromium::copyOffscreenTextureToDisplay):
462         (WebCore::LayerRendererChromium::drawLayer):
463         (WebCore::LayerRendererChromium::initializeSharedObjects):
464         (WebCore::LayerRendererChromium::cleanupSharedObjects):
465         * platform/graphics/chromium/LayerRendererChromium.h:
466         * platform/graphics/chromium/LayerTilerChromium.cpp:
467         (WebCore::LayerTilerChromium::getSingleTexture):
468         (WebCore::LayerTilerChromium::invalidateRect):
469         (WebCore::LayerTilerChromium::update):
470         (WebCore::LayerTilerChromium::uploadCanvas):
471         (WebCore::LayerTilerChromium::updateFromPixels):
472         (WebCore::LayerTilerChromium::draw):
473         (WebCore::LayerTilerChromium::unreserveTextures):
474         * platform/graphics/chromium/LayerTilerChromium.h:
475         (WebCore::LayerTilerChromium::setLayerRenderer):
476         (WebCore::LayerTilerChromium::skipsDraw):
477         * platform/graphics/chromium/PlatformCanvas.cpp:
478         (WebCore::PlatformCanvas::AutoLocker::AutoLocker):
479         (WebCore::PlatformCanvas::Painter::Painter):
480         * platform/graphics/chromium/PlatformCanvas.h:
481         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
482         (WebCore::RenderSurfaceChromium::draw):
483         * platform/graphics/chromium/RenderSurfaceChromium.h:
484         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp:
485         (WebCore::CCCanvasLayerImpl::draw):
486         * platform/graphics/chromium/cc/CCCanvasLayerImpl.h:
487         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
488         (WebCore::CCHeadsUpDisplay::draw):
489         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
490         (WebCore::CCLayerImpl::draw):
491         * platform/graphics/chromium/cc/CCLayerImpl.h:
492         * platform/graphics/chromium/cc/CCPluginLayerImpl.cpp:
493         (WebCore::CCPluginLayerImpl::draw):
494         * platform/graphics/chromium/cc/CCPluginLayerImpl.h:
495         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
496         (WebCore::CCVideoLayerImpl::draw):
497         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
498
499 2011-04-11  Eric Carlson  <eric.carlson@apple.com>
500
501         Reviewed by Simon Fraser.
502
503         Ignore context change callbacks when not on the main thread
504         https://bugs.webkit.org/show_bug.cgi?id=58256
505         <rdar://problem/9266090>
506
507         * platform/graphics/ca/win/WKCACFViewLayerTreeHost.cpp:
508         (WebCore::WKCACFViewLayerTreeHost::contextDidChange): Do nothing when not called
509             on the main thread. This should only happen when no changes have actually 
510             been committed to the context, eg. when a video frame has been added to an image
511             queue, so return without triggering animations etc.
512
513 2011-04-11  Daniel Cheng  <dcheng@chromium.org>
514
515         Reviewed by Dmitry Titov.
516
517         [chromium] Implement image/png support in DataTransferItems
518         https://bugs.webkit.org/show_bug.cgi?id=58106
519
520         This patch implements DataTransferItem::getAsFile() using Blobs. In
521         addition, plumbing for image/png has been added so image paste will be
522         supported as long as the renderer makes that data available.
523
524         Tests: editing/pasteboard/data-transfer-items-image-png.html
525
526         * dom/DataTransferItem.h:
527         * dom/DataTransferItem.idl:
528         * platform/chromium/ClipboardMimeTypes.cpp:
529         * platform/chromium/ClipboardMimeTypes.h:
530         * platform/chromium/DataTransferItemChromium.cpp:
531         (WebCore::DataTransferItemChromium::getAsString):
532         (WebCore::DataTransferItemChromium::getAsFile):
533         * platform/chromium/DataTransferItemChromium.h:
534         * platform/chromium/PlatformBridge.h:
535
536 2011-04-11  Mario Sanchez Prada  <msanchez@igalia.com>
537
538         Reviewed by Chris Fleizach.
539
540         [Gtk] Implement support for Embedded Objects
541         https://bugs.webkit.org/show_bug.cgi?id=52148
542
543         Expose special OBJECT character for replaced elements, implementing
544         AtkText and AtkHyperlink when required.
545
546         * accessibility/AccessibilityRenderObject.cpp:
547         (WebCore::textIteratorBehaviorForTextRange): New helper function,
548         to return the right behavior, depending on the platform, so it
549         ensures that object replacement characters get emitted for GTK.
550         (WebCore::AccessibilityRenderObject::textUnderElement): Use the
551         new helper function textIteratorBehaviorForTextRange.
552         (WebCore::AccessibilityRenderObject::stringValue): Ditto.
553         (WebCore::AccessibilityRenderObject::indexForVisiblePosition):
554         Consider replaced elements when calculating range length in GTK.
555
556         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
557         (textForRenderer): Ouput the 'object replacement character' for
558         replaced objects.
559         (getSelectionOffsetsForObject): Consider replaced elements when
560         calculating range length in GTK.
561         (webkitAccessibleHypertextGetLink): Remove wrong extra check that
562         were causing only links to be considered.
563         (webkitAccessibleHypertextGetNLinks): Replace wrong 'isLink()'
564         check with the right one, by checking that the right ATK interface
565         is being implemented by the AtkObject.
566         (getInterfaceMaskFromObject): Implement the Hyperlink interface
567         both for links and replaced objects.
568         (objectAndOffsetUnignored): Consider replaced elements when
569         calculating range length in GTK.
570
571         * accessibility/gtk/WebKitAccessibleHyperlink.cpp:
572         (getRangeLengthForObject): Ensure spaces are used for replaced
573         elements when calling to TextIterator::rangeLength().
574
575         * editing/TextIterator.h: New value in the TextIteratorBehavior
576         enumeration (TextIteratorEmitsObjectReplacementCharacters) and new
577         private variable to consider that new option internally.
578         * editing/TextIterator.cpp:
579         (WebCore::TextIterator::TextIterator): Initialize the new private
580         attribute m_emitsObjectReplacementCharacters in constructors.
581         (WebCore::TextIterator::handleReplacedElement): Emit the 'object
582         replacement character' when m_emitsObjectReplacementCharacters.
583
584 2011-04-11  Jia Pu  <jpu@apple.com>
585
586         Reviewed by Adele Peterson.
587
588         Shouldn't carry out autocorrection when start typing a new word
589         https://bugs.webkit.org/show_bug.cgi?id=58241
590         <rdar://problem/9264736>
591
592         Tests: platform/mac/editing/spelling/autocorrection-at-beginning-of-word-1.html
593                platform/mac/editing/spelling/autocorrection-at-beginning-of-word-2.html
594
595         In TypingCommand::markMisspellingsAfterTyping(), we want to call Editor::markMisspellingsAfterTypingToWord()
596         only when the typing command is an insertion command, and preceding word contains at least one non-whitespace
597         character.
598
599         * editing/Editor.cpp:
600         (WebCore::Editor::markMisspellingsAfterTypingToWord):
601         * editing/Editor.h:
602         * editing/TypingCommand.cpp:
603         (WebCore::TypingCommand::markMisspellingsAfterTyping):
604
605 2011-04-11  Vsevolod Vlasov  <vsevik@chromium.org>
606
607         Reviewed by Pavel Feldman.
608
609         PerformanceTiming returns inconsistent values when timing is null.
610         https://bugs.webkit.org/show_bug.cgi?id=58143
611
612         Made PerformanceTiming returned values consistent when there is no timing object.
613
614         * page/PerformanceTiming.cpp:
615         (WebCore::PerformanceTiming::domainLookupStart):
616         (WebCore::PerformanceTiming::domainLookupEnd):
617         (WebCore::PerformanceTiming::connectStart):
618         (WebCore::PerformanceTiming::connectEnd):
619         (WebCore::PerformanceTiming::requestStart):
620         (WebCore::PerformanceTiming::responseStart):
621         (WebCore::PerformanceTiming::domLoading):
622
623 2011-04-05  Stephen White  <senorblanco@chromium.org>
624
625         Fix for jittering when animating a rotated image.
626         https://bugs.webkit.org/show_bug.cgi?id=50775
627
628         Make GraphicsContext::roundToDevicePixels a no-op on Chrome/Mac.
629
630         * platform/graphics/cg/GraphicsContextCG.cpp:
631         (WebCore::GraphicsContext::roundToDevicePixels):
632
633 2011-04-06  Xiaomei Ji  <xji@chromium.org>
634
635         Reviewed by Ryosuke Niwa.
636
637         Continue experiment with moving caret by word in visual order.
638         https://bugs.webkit.org/show_bug.cgi?id=57806
639
640         This is the 2nd patch, which adds implementation when caret is inside box
641         (not at boundaries). If the word break is inside the same box and not at the boundaries
642         either, the word break will be returned. If need to search the adjacent boxes for word
643         breaks, then, only the cases implemented in bug 57336 work.
644
645         * editing/visible_units.cpp:
646         (WebCore::leftmostPositionInRTLBoxInLTRBlock):
647         (WebCore::rightmostPositionInLTRBoxInRTLBlock):
648         (WebCore::lastWordBreakInBox):
649         (WebCore::positionIsVisuallyOrderedInBoxInBlockWithDifferentDirectionality):
650         (WebCore::nextWordBreakInBoxInsideBlockWithDifferentDirectionality):
651         (WebCore::WordBoundaryEntry::WordBoundaryEntry):
652         (WebCore::collectWordBreaksInBoxInsideBlockWithSameDirectionality):
653         (WebCore::collectWordBreaksInBoxInsideBlockWithDifferntDirectionality):
654         (WebCore::greatestValueUnder):
655         (WebCore::smallestOffsetAbove):
656         (WebCore::positionIsInsideBox):
657         (WebCore::positionBeforeNextWord):
658         (WebCore::positionAfterPreviousWord):
659         (WebCore::leftWordPosition):
660         (WebCore::rightWordPosition):
661
662 2011-04-11  Mario Sanchez Prada  <msanchez@igalia.com>
663
664         Reviewed by Chris Fleizach.
665
666         [GTK] Unskip accessibility/input-slider.html and accessibility/media-element.html
667         https://bugs.webkit.org/show_bug.cgi?id=58040
668
669         Don't expose objects of role SliderThumbRoles in GTK.
670
671         * accessibility/AccessibilitySlider.cpp:
672         (WebCore::AccessibilitySlider::addChildren): Allow the platform
673         make a final decision before including children in the hierarchy.
674         (WebCore::AccessibilitySliderThumb::accessibilityIsIgnored):
675         Implemented by relying on accessibilityPlatformIncludesObject().
676
677         * accessibility/gtk/AccessibilityObjectAtk.cpp:
678         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
679         Ignore accessibility objects with role SliderThumbRole.
680
681 2011-04-11  Simon Fraser  <simon.fraser@apple.com>
682
683         Reviewed by Dan Bernstein.
684
685         Divide by zero in calcColumnWidth
686         https://bugs.webkit.org/show_bug.cgi?id=58230
687
688         Test: fast/multicol/huge-column-count.html
689         
690         Make sure we have at least one column, to avoid divide by zero.
691
692         * rendering/RenderBlock.cpp:
693         (WebCore::RenderBlock::calcColumnWidth):
694
695 2011-04-09  Gavin Barraclough  <barraclough@apple.com>
696
697         Reviewed by Sam Weinig.
698
699         Bug 58198 - Clean up JSValue implementation for JSVALUE64
700
701         JSNumberCell.h has been deprecated.
702
703         * ForwardingHeaders/runtime/JSNumberCell.h: Removed.
704         * bindings/scripts/CodeGeneratorJS.pm:
705         * bridge/c/c_instance.cpp:
706
707 2011-04-11  Dan Bernstein  <mitz@apple.com>
708
709         Build fix.
710
711         * html/canvas/CanvasRenderingContext2D.cpp:
712         (WebCore::CanvasRenderingContext2D::State::State):
713
714 2011-04-11  Antti Koivisto  <antti@apple.com>
715
716         Reviewed by Tony Gentilcore.
717
718         Document source preload scanned repeatedly
719         https://bugs.webkit.org/show_bug.cgi?id=58123
720         
721         Don't clear the preload scanner after execution resumes. This would lose the current
722         scanning point and lead to rescanning when the preload scanner would get reconstructed
723         due to main parser blocking again.
724
725         Instead clear the scanner only in the specific case of receiving new data while the main
726         parser has already reached the end of the current input.
727
728         Also switched to using isWaitingForScripts() instead of m_treeBuilder->isPaused() for consistency.
729
730         The case the clearing in resumeParsingAfterScriptExecution() was added for is covered by 
731         http/tests/loading/preload-slow-loading.php.
732
733         * html/parser/HTMLDocumentParser.cpp:
734         (WebCore::HTMLDocumentParser::insert):
735         (WebCore::HTMLDocumentParser::append):
736         (WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution):
737
738 2011-04-11  Dan Bernstein  <mitz@apple.com>
739
740         Build fix.
741
742         * html/canvas/CanvasRenderingContext2D.cpp:
743         (WebCore::CanvasRenderingContext2D::State::State):
744
745 2011-04-11  Dan Bernstein  <mitz@apple.com>
746
747         Reviewed by Alexey Proskuryakov.
748
749         Assertion failure in CanvasRenderingContext2D::State::fontsNeedUpdate when invalidating the font cache after opening canvas/philip/tests/initial.reset.2dstate.html (occurs on Qt debug test bot)
750         https://bugs.webkit.org/show_bug.cgi?id=58229
751
752         * html/canvas/CanvasRenderingContext2D.cpp:
753         (WebCore::CanvasRenderingContext2D::State::State): Added copy constructor, to register the copy with
754         the font selector if needed.
755         (WebCore::CanvasRenderingContext2D::State::operator=): Added assignment constructor, to handle
756         registration with the font selector as needed.
757         * html/canvas/CanvasRenderingContext2D.h:
758
759 2011-04-11  Mario Sanchez Prada  <msanchez@igalia.com>
760
761         Reviewed by Chris Fleizach.
762
763         [GTK] ARIA tables not exposing cells as HTML tables do
764         https://bugs.webkit.org/show_bug.cgi?id=57463
765
766         Expose cells for ARIA grids consistently with HTML tables in GTK,
767         keeping the same behaviour for the other platforms.
768
769         * accessibility/AccessibilityARIAGrid.cpp:
770         (WebCore::AccessibilityARIAGrid::addChild): Add the row's children
771         to the accessibility hierarchy when accessibility objects for rows
772         are ignoring accessibility, otherwise add the row.
773         (WebCore::AccessibilityARIAGrid::addChildren): Do not check at
774         this point whether every child of the table ignores or not
775         accessibility, letting addChild() make the proper decision later.
776
777         * accessibility/AccessibilityARIAGridCell.cpp:
778         (WebCore::AccessibilityARIAGridCell::parentTable): Consider that
779         rows could be ignoring accessibility, hence the parent could be
780         retrieved in the first call to parentObjectUnignored().
781         (WebCore::AccessibilityARIAGridCell::rowIndexRange): Ditto.
782         (WebCore::AccessibilityARIAGridCell::columnIndexRange): Ditto..
783
784         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
785         (atkRole): Map ColumnHeader and RowHeader to ATK_ROLE_TABLE_CELL.
786
787 2011-04-11  Sergio Villar Senin  <svillar@igalia.com>
788
789         Reviewed by Martin Robinson.
790
791         [GTK] Fix make distcheck
792         https://bugs.webkit.org/show_bug.cgi?id=58224
793
794         Removed a file that is no longer in the source tree.
795
796         * GNUmakefile.list.am:
797
798 2011-04-11  Dimitri Glazkov  <dglazkov@chromium.org>
799
800         Reviewed by Martin Robinson.
801
802         REGRESSION(r83397): Most GTK media controls are hidden when no valid source is specified
803         https://bugs.webkit.org/show_bug.cgi?id=58204
804
805         Covered by existing tests.
806
807         * platform/gtk/RenderThemeGtk.h:
808         (WebCore::RenderThemeGtk::hasOwnDisabledStateHandlingFor): Let GTK handle
809             the the state of media controls.
810
811 2011-04-11  Dimitri Glazkov  <dglazkov@chromium.org>
812
813         Remove obsolete comment, which was mistakenly landed in r83397.
814
815         Though potentially a work of art, the comment lost its functional meaning a long time ago.
816
817         * html/shadow/MediaControls.cpp:
818         (WebCore::MediaControls::create): Removed comment.
819
820 2011-04-05  Hans Wennborg  <hans@chromium.org>
821
822         Reviewed by Steve Block.
823
824         IndexedDB: Introduce skeleton for LevelDB backend
825         https://bugs.webkit.org/show_bug.cgi?id=57827
826
827         No new tests: no new functionality (yet).
828
829         * WebCore.gyp/WebCore.gyp:
830             Add dependency on leveldb when ENABLE_LEVELDB=1 in feature_defines.
831         * WebCore.gypi:
832             Add new files.
833         * storage/IDBBackingStore.h:
834         (WebCore::IDBBackingStore::ObjectStoreRecordIdentifier::~ObjectStoreRecordIdentifier):
835             Introduce abstract type ObjectStoreRecordIdentifier. The SQLite
836             backend uses integers to refer to a specific row in a table, but
837             the LevelDB backend will use something else.
838         * storage/IDBDatabaseBackendImpl.cpp:
839         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
840         (WebCore::IDBDatabaseBackendImpl::createObjectStoreInternal):
841         (WebCore::IDBDatabaseBackendImpl::deleteObjectStoreInternal):
842         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
843             Change functions to pass along the database id for operations that
844             concern object stores. We want to be able to group object stores
845             ids per database.
846         * storage/IDBFactoryBackendImpl.cpp:
847         (WebCore::IDBFactoryBackendImpl::open):
848             Decide which backend to use based on the backingStoreType
849             parameter.
850         * storage/IDBIndexBackendImpl.cpp:
851         (WebCore::IDBIndexBackendImpl::IDBIndexBackendImpl):
852         (WebCore::IDBIndexBackendImpl::openCursorInternal):
853         (WebCore::IDBIndexBackendImpl::getInternal):
854         (WebCore::IDBIndexBackendImpl::addingKeyAllowed):
855         * storage/IDBIndexBackendImpl.h:
856         (WebCore::IDBIndexBackendImpl::create):
857             Pass database and object store id to backend functions concerning
858             indexes.
859         * storage/IDBLevelDBBackingStore.cpp: Added.
860         (WebCore::IDBLevelDBBackingStore::IDBLevelDBBackingStore):
861         (WebCore::IDBLevelDBBackingStore::~IDBLevelDBBackingStore):
862         (WebCore::IDBLevelDBBackingStore::open):
863         (WebCore::IDBLevelDBBackingStore::extractIDBDatabaseMetaData):
864         (WebCore::IDBLevelDBBackingStore::setIDBDatabaseMetaData):
865         (WebCore::IDBLevelDBBackingStore::getObjectStores):
866         (WebCore::IDBLevelDBBackingStore::createObjectStore):
867         (WebCore::IDBLevelDBBackingStore::deleteObjectStore):
868         (WebCore::IDBLevelDBBackingStore::getObjectStoreRecord):
869         (WebCore::IDBLevelDBBackingStore::putObjectStoreRecord):
870         (WebCore::IDBLevelDBBackingStore::clearObjectStore):
871         (WebCore::IDBLevelDBBackingStore::deleteObjectStoreRecord):
872         (WebCore::IDBLevelDBBackingStore::nextAutoIncrementNumber):
873         (WebCore::IDBLevelDBBackingStore::keyExistsInObjectStore):
874         (WebCore::IDBLevelDBBackingStore::forEachObjectStoreRecord):
875         (WebCore::IDBLevelDBBackingStore::getIndexes):
876         (WebCore::IDBLevelDBBackingStore::createIndex):
877         (WebCore::IDBLevelDBBackingStore::deleteIndex):
878         (WebCore::IDBLevelDBBackingStore::putIndexDataForRecord):
879         (WebCore::IDBLevelDBBackingStore::deleteIndexDataForRecord):
880         (WebCore::IDBLevelDBBackingStore::getObjectViaIndex):
881         (WebCore::IDBLevelDBBackingStore::getPrimaryKeyViaIndex):
882         (WebCore::IDBLevelDBBackingStore::keyExistsInIndex):
883         (WebCore::IDBLevelDBBackingStore::openObjectStoreCursor):
884         (WebCore::IDBLevelDBBackingStore::openIndexKeyCursor):
885         (WebCore::IDBLevelDBBackingStore::openIndexCursor):
886         (WebCore::IDBLevelDBBackingStore::createTransaction):
887         * storage/IDBLevelDBBackingStore.h: Added.
888             Add an empty implementation of the LevelDB backend.
889         * storage/IDBObjectStoreBackendImpl.cpp:
890             Keep track of database id, use the new RecordIdentifier.
891         (WebCore::IDBObjectStoreBackendImpl::IDBObjectStoreBackendImpl):
892         (WebCore::IDBObjectStoreBackendImpl::getInternal):
893         (WebCore::IDBObjectStoreBackendImpl::putInternal):
894         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
895         (WebCore::IDBObjectStoreBackendImpl::clearInternal):
896         (WebCore::populateIndex):
897         (WebCore::IDBObjectStoreBackendImpl::createIndex):
898         (WebCore::IDBObjectStoreBackendImpl::createIndexInternal):
899         (WebCore::IDBObjectStoreBackendImpl::deleteIndexInternal):
900         (WebCore::IDBObjectStoreBackendImpl::openCursorInternal):
901         (WebCore::IDBObjectStoreBackendImpl::loadIndexes):
902         (WebCore::IDBObjectStoreBackendImpl::genAutoIncrementKey):
903         * storage/IDBObjectStoreBackendImpl.h:
904         (WebCore::IDBObjectStoreBackendImpl::create):
905         (WebCore::IDBObjectStoreBackendImpl::databaseId):
906         * storage/IDBSQLiteBackingStore.cpp:
907         (WebCore::IDBSQLiteBackingStore::open):
908         (WebCore::IDBSQLiteBackingStore::createObjectStore):
909         (WebCore::IDBSQLiteBackingStore::deleteObjectStore):
910         (WebCore::IDBSQLiteBackingStore::getObjectStoreRecord):
911         (WebCore::IDBSQLiteBackingStore::putObjectStoreRecord):
912         (WebCore::IDBSQLiteBackingStore::clearObjectStore):
913         (WebCore::IDBSQLiteBackingStore::deleteObjectStoreRecord):
914         (WebCore::IDBSQLiteBackingStore::nextAutoIncrementNumber):
915         (WebCore::IDBSQLiteBackingStore::keyExistsInObjectStore):
916         (WebCore::IDBSQLiteBackingStore::forEachObjectStoreRecord):
917         (WebCore::IDBSQLiteBackingStore::getIndexes):
918         (WebCore::IDBSQLiteBackingStore::createIndex):
919         (WebCore::IDBSQLiteBackingStore::deleteIndex):
920         (WebCore::IDBSQLiteBackingStore::putIndexDataForRecord):
921         (WebCore::IDBSQLiteBackingStore::deleteIndexDataForRecord):
922         (WebCore::IDBSQLiteBackingStore::getObjectViaIndex):
923         (WebCore::IDBSQLiteBackingStore::getPrimaryKeyViaIndex):
924         (WebCore::IDBSQLiteBackingStore::keyExistsInIndex):
925         (WebCore::IDBSQLiteBackingStore::openObjectStoreCursor):
926         (WebCore::IDBSQLiteBackingStore::openIndexKeyCursor):
927         (WebCore::IDBSQLiteBackingStore::openIndexCursor):
928         * storage/IDBSQLiteBackingStore.h:
929
930 2011-04-11  Alexander Pavlov  <apavlov@chromium.org>
931
932         Reviewed by Yury Semikhatsky.
933
934         Web Inspector: Duplicate CSS properties are reported for non-lowercase property names in the Styles sidebar
935         https://bugs.webkit.org/show_bug.cgi?id=58226
936
937         * inspector/InspectorStyleSheet.cpp:
938         (WebCore::InspectorStyle::populateAllProperties):
939
940 2011-04-07  Pavel Podivilov  <podivilov@chromium.org>
941
942         Reviewed by Pavel Feldman.
943
944         Web Inspector: get rid of source frame delegates for resources panel.
945         https://bugs.webkit.org/show_bug.cgi?id=58041
946
947         Use TextViewer configured with a domain-specific delegate to show/edit resource contents in resources panel.
948
949         * inspector/front-end/ResourceView.js:
950         (WebInspector.ResourceView.createResourceView):
951         (WebInspector.ResourceView.resourceViewTypeMatchesResource):
952         (WebInspector.ResourceSourceFrame):
953         (WebInspector.ResourceSourceFrame.prototype.get resource):
954         (WebInspector.ResourceSourceFrame.prototype.contentEditable):
955         (WebInspector.ResourceSourceFrame.prototype._requestContent):
956         (WebInspector.CSSSourceFrame):
957         (WebInspector.CSSSourceFrame.prototype.contentEditable):
958         (WebInspector.CSSSourceFrame.prototype._editContent):
959         (WebInspector.CSSSourceFrame.prototype._editContent.handleInfos):
960         (WebInspector.CSSSourceFrame.prototype._saveStyleSheet):
961         * inspector/front-end/SourceFrame.js:
962         (WebInspector.SourceFrame.prototype._ensureContentLoaded):
963         (WebInspector.SourceFrame.prototype._requestContent):
964         (WebInspector.SourceFrame.prototype._handleSave):
965         (WebInspector.SourceFrame.prototype._editContent):
966
967 2011-04-11  Alexis Menard  <alexis.menard@openbossa.org>
968
969         Reviewed by Andreas Kling.
970
971         [Qt] Regression : r83051 Oxygen's lineedits are not rendered properly
972         https://bugs.webkit.org/show_bug.cgi?id=58076
973
974         State_Sunken is more generic than pressed. It is used by items such as frames or
975         line edits because they are "sunken" frames (e.g. QLineEdit). It can be required
976         by some style like Oxygen. Therefore only in the mobile theme we check if the object
977         is pressed.
978
979         * platform/qt/RenderThemeQt.cpp:
980         (WebCore::RenderThemeQt::paintTextField):
981
982 2011-04-11  Pavel Feldman  <pfeldman@chromium.org>
983
984         Reviewed by Yury Semikhatsky.
985
986         Web Inspector: add support for optional output parameters.
987         https://bugs.webkit.org/show_bug.cgi?id=58207
988
989         Output parameters such as "redirectResponse" are optional, but
990         do not allow specifying them as such.
991
992         * inspector/CodeGeneratorInspector.pm:
993         * inspector/Inspector.json:
994         * inspector/InspectorResourceAgent.cpp:
995         (WebCore::buildObjectForResourceResponse):
996         (WebCore::buildObjectForCachedResource):
997         * inspector/front-end/NetworkManager.js:
998         (WebInspector.NetworkDispatcher.prototype._updateResourceWithResponse):
999         * inspector/generate-inspector-idl:
1000
1001 2011-04-11  Pavel Feldman  <pfeldman@chromium.org>
1002
1003         Reviewed by Yury Semikhatsky.
1004
1005         Web Inspector: refactor / document call frames in debugger domain.
1006         https://bugs.webkit.org/show_bug.cgi?id=58187
1007
1008         Note that we are not special casing with(element) and with(document) anymore
1009         and do not tell user that it is "Event target" and "Event document". Strictly speaking,
1010         we should not have done it for with(element) not necessarily being related to an event.
1011
1012         * English.lproj/localizedStrings.js:
1013         * inspector/InjectedScriptSource.js:
1014         * inspector/Inspector.json:
1015         * inspector/front-end/ScopeChainSidebarPane.js:
1016         (WebInspector.ScopeChainSidebarPane.prototype.update):
1017
1018 2011-04-10  ChangSeok Oh  <shivamidow@gmail.com>
1019
1020         Reviewed by Eric Seidel.
1021
1022         Make correspondence of file name related with event to other port.
1023         https://bugs.webkit.org/show_bug.cgi?id=57416
1024
1025         Some file names are changed to make correspondence naming rule.
1026         Keyboard, mouse and wheel event file names for GTK port have been different from other ports.
1027         This has made user hard to find a specific file related with event for GTK port. 
1028
1029         No test required. This patch just changes some file names.
1030
1031         * GNUmakefile.list.am:
1032         * platform/gtk/KeyEventGtk.cpp: Removed.
1033         * platform/gtk/MouseEventGtk.cpp: Removed.
1034         * platform/gtk/PlatformKeyboardEventGtk.cpp: Added.
1035         * platform/gtk/PlatformMouseEventGtk.cpp: Added.
1036         * platform/gtk/PlatformWheelEventGtk.cpp: Added.
1037         * platform/gtk/WheelEventGtk.cpp: Removed.
1038
1039 2011-04-10  Simon Fraser  <simon.fraser@apple.com>
1040
1041         Revert the FloatRect.cpp part of r83422, since
1042         clampToInteger() is broken for some inputs. I filed
1043         https://bugs.webkit.org/show_bug.cgi?id=58216
1044
1045         * platform/graphics/FloatRect.cpp:
1046         (WebCore::safeFloatToInt):
1047         (WebCore::enclosingIntRect):
1048
1049 2011-04-10  Simon Fraser  <simon.fraser@apple.com>
1050
1051         Reviewed by Maciej Stachowiak.
1052
1053         Car model dropdowns at audiusa.com lay out incorrectly with compositing enabled
1054         https://bugs.webkit.org/show_bug.cgi?id=56660
1055         
1056         When overflow on an element changes, we need to inform compositing
1057         layers which create and position an "ancestor clipping" layer based
1058         on that overflow. Do this by triggering a rebuild of compositing layers
1059         when overflow changes on a layer whose stacking context has compositing
1060         descendants. (We can't just check whether the layer itself has compositing
1061         descendants, because overflow follows the render tree, but compositing
1062         follows the z-order tree.)
1063
1064         Test: compositing/geometry/ancestor-overflow-change.html
1065
1066         * rendering/RenderLayer.cpp:
1067         (WebCore::RenderLayer::styleChanged):
1068         * rendering/RenderLayer.h:
1069         * rendering/RenderLayerBacking.cpp:
1070         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1071
1072 2011-04-10  Simon Fraser  <simon.fraser@apple.com>
1073
1074         Reviewed by Ariya Hidayat.
1075
1076         Allow ShadowBlur to re-use the last buffer if it already contains the correct shadow
1077         https://bugs.webkit.org/show_bug.cgi?id=58161
1078         
1079         ShadowBlur already has a singleton scratch buffer that is re-used
1080         between shadows. Enhance use of this scratch buffer to avoid drawing
1081         and blurring the shadow if the results will match what is already
1082         in the buffer.
1083         
1084         Cleaned up ShadowBlur code to remove beginShadowLayer() and endShadowLayer(),
1085         which ended up with little reusable code after adding the re-use logic.
1086
1087         * platform/graphics/FloatRect.cpp:
1088         (WebCore::enclosingIntRect): Replace safeFloatToInt() with the existing
1089         clampToInteger() from MathExtras.h
1090         
1091         * platform/graphics/FloatSize.h:
1092         (WebCore::expandedIntSize): New method to safely ceil() the size.
1093         
1094         * platform/graphics/RoundedIntRect.h:
1095         Add operator== for Radii and RoundedIntRect.
1096
1097         * platform/graphics/ShadowBlur.cpp:
1098         (WebCore::ScratchBuffer::ScratchBuffer):
1099         (WebCore::ScratchBuffer::setLastShadowValues):
1100         (WebCore::ScratchBuffer::setLastInsetShadowValues):
1101         (WebCore::ScratchBuffer::matchesLastShadow):
1102         (WebCore::ScratchBuffer::matchesLastInsetShadow):
1103         (WebCore::ScratchBuffer::clearScratchBuffer):
1104         Have the scratch buffer remember what shadow parameters were used
1105         to render the buffer contents.
1106         
1107         (WebCore::ShadowBlur::drawShadowBuffer):
1108         Renamed from endShadowLayer(), and only contains the drawing
1109         logic now.
1110         
1111         (WebCore::ShadowBlur::drawRectShadow):
1112         Promote some code from beginShadowLayer().
1113         
1114         (WebCore::ShadowBlur::drawInsetShadow):
1115         Promote some code from beginShadowLayer().
1116
1117         (WebCore::ShadowBlur::drawRectShadowWithoutTiling):
1118         (WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
1119         (WebCore::ShadowBlur::drawInsetShadowWithTiling):
1120         (WebCore::ShadowBlur::drawRectShadowWithTiling):
1121         These methods now check to see if the buffer already matches
1122         their required parameters, and avoid work if it does.
1123         
1124         (WebCore::ShadowBlur::blurShadowBuffer):
1125         Factored some code into this new method.
1126         
1127         (WebCore::ShadowBlur::blurAndColorShadowBuffer):
1128         Minor refactoring.
1129
1130         * platform/graphics/ShadowBlur.h:
1131
1132 2011-04-10  Geoffrey Garen  <ggaren@apple.com>
1133
1134         Build fix: Updated for file move.
1135
1136         * bindings/js/GCController.cpp:
1137         * bindings/js/ScriptGCEvent.cpp:
1138
1139 2011-04-10  Geoffrey Garen  <ggaren@apple.com>
1140
1141         Rubber-stamped by Beth Dakin.
1142
1143         Moved Heap.h and Heap.cpp to the heap folder, because anything less 
1144         would be uncivilized.
1145
1146         * ForwardingHeaders/heap/Heap.h: Copied from WebCore/ForwardingHeaders/runtime/Heap.h.
1147         * ForwardingHeaders/runtime/Heap.h: Removed.
1148
1149 2011-04-10  Luke Macpherson   <macpherson@chromium.org>
1150
1151         Reviewed by Simon Fraser.
1152
1153         Rename CSSStyleApplyProperty::inherit,initial,value applyInheritValue,applyInitialValue,applyValue
1154         https://bugs.webkit.org/show_bug.cgi?id=58212
1155
1156         No new tests - function renaming only / no functionality changes.
1157
1158         * css/CSSStyleApplyProperty.cpp:
1159         Rename all instances of inherit, initial and value.
1160         * css/CSSStyleApplyProperty.h:
1161         Rename all instances of inherit, initial and value.
1162         * css/CSSStyleSelector.cpp:
1163         Rename all instances of inherit, initial and value.
1164
1165 2011-04-10  Mike Lawther  <mikelawther@chromium.org>
1166
1167         Reviewed by Ojan Vafai.
1168
1169         flex/bison tokens and grammar for CSS calc
1170         https://bugs.webkit.org/show_bug.cgi?id=54412
1171
1172         Tests: css3/calc/calc-errors.html
1173                css3/calc/lexer-regression-57581-2.html
1174                css3/calc/lexer-regression-57581-3.html
1175                css3/calc/lexer-regression-57581.html
1176                css3/calc/minmax-errors.html
1177                css3/calc/nested-rounded-corners.html
1178                css3/calc/simple-calcs.html
1179                css3/calc/simple-minmax.html
1180
1181         * css/CSSGrammar.y:
1182         * css/CSSParserValues.cpp:
1183         (WebCore::CSSParserValueList::insertValueAt):
1184         (WebCore::CSSParserValueList::extend):
1185         * css/CSSParserValues.h:
1186         * css/tokenizer.flex:
1187
1188 2011-04-10  Alice Boxhall  <aboxhall@chromium.org>
1189
1190         Reviewed by Ryosuke Niwa.
1191
1192         Change EventHandler::updateSelectionForMouseDrag to take a HitTestResult only.
1193         https://bugs.webkit.org/show_bug.cgi?id=57923
1194
1195         Change EventHandler::updateSelectionForMouseDrag to take a HitTestResult
1196         rather than a Node* and an IntPoint&, as the selection may actually not
1197         extend into the Node found by the HitTest.
1198
1199         No new tests. Refactoring only.
1200
1201         * page/EventHandler.cpp:
1202         (WebCore::EventHandler::handleMouseDraggedEvent):
1203         (WebCore::EventHandler::updateSelectionForMouseDrag):
1204         * page/EventHandler.h:
1205
1206 2011-04-10  Kent Tamura  <tkent@chromium.org>
1207
1208         Unreviewed, rolling out r83353.
1209         http://trac.webkit.org/changeset/83353
1210         https://bugs.webkit.org/show_bug.cgi?id=58106
1211
1212         The new test doesn't pass on all Chromium platforms.
1213
1214         * dom/DataTransferItem.h:
1215         * dom/DataTransferItem.idl:
1216         * platform/chromium/ClipboardMimeTypes.cpp:
1217         * platform/chromium/ClipboardMimeTypes.h:
1218         * platform/chromium/DataTransferItemChromium.cpp:
1219         (WebCore::DataTransferItemChromium::getAsString):
1220         * platform/chromium/DataTransferItemChromium.h:
1221         * platform/chromium/PlatformBridge.h:
1222
1223 2011-04-10  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1224
1225         Reviewed by Eric Carlson.
1226
1227         [EFL] Add seek forward / backward buttons to MediaControl UI.
1228         https://bugs.webkit.org/show_bug.cgi?id=56810
1229
1230         Add seek forward / backward buttons to media control. And, change formType name
1231         for media control.
1232
1233         * platform/efl/RenderThemeEfl.cpp:
1234         (WebCore::RenderThemeEfl::edjeGroupFromFormType):
1235         (WebCore::RenderThemeEfl::emitMediaButtonSignal):
1236         (WebCore::RenderThemeEfl::paintMediaMuteButton):
1237         (WebCore::RenderThemeEfl::paintMediaPlayButton):
1238         (WebCore::RenderThemeEfl::paintMediaSeekBackButton):
1239         (WebCore::RenderThemeEfl::paintMediaSeekForwardButton):
1240         * platform/efl/RenderThemeEfl.h:
1241
1242 2011-04-10  Chris Guillory  <chris.guillory@google.com>
1243
1244         Reviewed by Eric Seidel.
1245
1246         Remove unused function declaration in PlatformContextSkia.h.
1247         https://bugs.webkit.org/show_bug.cgi?id=55983
1248
1249         * platform/graphics/skia/PlatformContextSkia.h:
1250
1251 2011-04-10  Patrick Gansterer  <paroga@webkit.org>
1252
1253         Unreviewed build fix for !ENABLE(XSLT) after r82562.
1254
1255         * dom/XMLDocumentParserLibxml2.cpp:
1256         (WebCore::XMLDocumentParser::doEnd):
1257
1258 2011-04-10  Patrick Gansterer  <paroga@webkit.org>
1259
1260         Unreviewed build fix for !ENABLE(XSLT) after r82562.
1261
1262         * xml/XMLTreeViewer.cpp: Readded #if ENABLE(XSLT).
1263
1264 2011-04-10  Dimitri Glazkov  <dglazkov@chromium.org>
1265
1266         Reviewed by Anders Carlsson.
1267
1268         REGRESSION(r83256): Text-decoration bleeds into shadow DOM
1269         https://bugs.webkit.org/show_bug.cgi?id=58205
1270
1271         Now that the shadow root is a never-styled element, we need to walk to
1272         parent to find out if we're inside of a shadow DOM subtree.
1273
1274         Test: media/controls-styling.html
1275
1276         * css/CSSStyleSelector.cpp:
1277         (WebCore::isAtShadowBoundary): Added helper function.
1278         (WebCore::CSSStyleSelector::adjustRenderStyle): Changed to use the helper.
1279
1280 2011-04-07  Dimitri Glazkov  <dglazkov@chromium.org>
1281
1282         Reviewed by Eric Carlson.
1283
1284         [Meta] Convert HTMLMediaElement to use the new shadow DOM
1285         https://bugs.webkit.org/show_bug.cgi?id=53020
1286
1287         This conversion is non-trivial, for several reasons:
1288
1289         1) Since HTMLMediaElement now hosts the shadow DOM for controls, hiding
1290         and showing controls does not result in destroying and re-creating the
1291         shadow DOM tree. Instead, the tree is created as needed and shown/hidden
1292         using inline styles.
1293         
1294         2) Instead of detaching/attaching on each style change, the control parts
1295         are now using a set of higher fidelity callbacks that notify MediaControls
1296         about changes to which it should react. Each reaction results in hiding,
1297         showing, or changing the state of the control parts using inline styles
1298         and DOM APIs.
1299
1300         3) Hiding and showing controls is accomplished using inline styles, rather
1301         than wiring rendererIsNeeded, because renderers are now re-created less
1302         frequently.
1303
1304         4) Instead of constantly querying RenderTheme about visibility of a particular
1305         control part, we let the theme determine which parts are supported and
1306         which parts are visible in certain conditions.
1307
1308         5) Custom hit-testing, event forwarding, and style updates are completely
1309         removed, since they are now unnecessary.
1310
1311         6) Fading controls in/out is now done as CSS animation, since shadow DOM
1312         supports it.
1313
1314         Test: manual-tests/media-controls.html
1315
1316 2011-04-09  Dan Bernstein  <mitz@apple.com>
1317
1318         Reviewed by Beth Dakin.
1319
1320         <rdar://problem/9215280> Detached canvas draws with incorrect font
1321
1322         Test: fast/canvas/font-update.html
1323
1324         The existing mechanism for updating the font in a canvas 2D context was lacking in at least
1325         two ways: it neglected to update fonts in all but the topmost state in the stack, and since it
1326         was based on HTMLCanvasElemen's attach() and recalcStyle(), it did not work when the element
1327         was not attached.
1328
1329         This change takes the responsibility for font updates away from the canvas element and gives it
1330         to the canvas context and its graphics state.
1331
1332         * css/CSSFontSelector.cpp:
1333         (WebCore::CSSFontSelector::registerForInvalidationCallbacks): Added. Adds to the set of registered
1334         font selector clients.
1335         (WebCore::CSSFontSelector::unregisterForInvalidationCallbacks): Added. Removes from the set of
1336         registered font selector clients.
1337         (WebCore::CSSFontSelector::dispatchInvalidationCallbacks): Calls fontsNeedUpdate() on all registered
1338         clients and forces a style recalc on the document.
1339         (WebCore::CSSFontSelector::fontLoaded): Changed to call dispatchInvalidationCallbacks().
1340         (WebCore::CSSFontSelector::fontCacheInvalidated): Ditto.
1341         * css/CSSFontSelector.h:
1342         * html/HTMLCanvasElement.cpp: Removed overrides of attach() and recalcStyle().
1343         * html/HTMLCanvasElement.h:
1344         * html/canvas/CanvasRenderingContext2D.cpp:
1345         (WebCore::CanvasRenderingContext2D::State::~State): Added. Unregisters with the font selector.
1346         (WebCore::CanvasRenderingContext2D::State::fontsNeedUpdate): Added. Called by the font selector
1347         when its fonts need to be updated. Updates the font.
1348         (WebCore::CanvasRenderingContext2D::setFont): Registers the state with the font selector.
1349         * html/canvas/CanvasRenderingContext2D.h:
1350         * platform/graphics/FontSelector.h:
1351         (WebCore::FontSelectorClient::~FontSelectorClient):
1352
1353 2011-04-09  Geoffrey Garen  <ggaren@apple.com>
1354
1355         Not reviewed.
1356
1357         Try recommitting some things svn left out of my last commit.
1358
1359         * bridge/qt/qt_runtime.h:
1360
1361 2011-04-09  Geoffrey Garen  <ggaren@apple.com>
1362
1363         Not reviewed.
1364
1365         Try recommitting some things svn left out of my last commit.
1366
1367         * ForwardingHeaders/collector: Removed.
1368         * ForwardingHeaders/collector/handles: Removed.
1369         * ForwardingHeaders/collector/handles/Global.h: Removed.
1370
1371 2011-04-08  Dimitri Glazkov  <dglazkov@chromium.org>
1372
1373         Reviewed by Ojan Vafai.
1374
1375         Implement proper handling of mouseover/mouseout events in regard to shadow DOM boundaries.
1376         https://bugs.webkit.org/show_bug.cgi?id=55515
1377
1378         This implements XBL 2.0's specified handling of mouseover/mouseout events:
1379         http://dev.w3.org/2006/xbl2/Overview.html#the-mouseover-and-mouseout-events
1380
1381         To do this, we:
1382         1) calculate lowest common ancestor between relatedTarget and target, and
1383            the nearest boundaries around them: the outer (common) boundary, and the
1384            inner (specific to relatedTarget) boundary. Then, we
1385         2) ensure that events only propagate up to the common boundary (or
1386            all the way if boundary is not found), while
1387         3) updating relatedTarget be the inner boundary.
1388
1389         We also detect the most common case when no common boundary could exist
1390         and provide a fast path to short-circuit most of the boundary detection
1391         logic.
1392
1393         Test: fast/events/shadow-boundary-crossing.html
1394
1395         * dom/EventDispatcher.cpp:
1396         (WebCore::EventDispatcher::adjustToShadowBoundaries): Added a helper to determine lowest
1397             common ancestor, the boundaries around it, and compute adjustments
1398             to relatedTarget and event target ancestor chain.
1399         (WebCore::ancestorsCrossShadowBoundaries): Added.
1400         (WebCore::EventDispatcher::adjustRelatedTarget): Changed to calculate
1401             inner/outer shadow DOM boundaries and adjust ancestors chain accordingly.
1402         (WebCore::EventDispatcher::EventDispatcher): Added flag initializer
1403         (WebCore::EventDispatcher::ensureEventAncestors): Renamed from getEventAncestors,
1404             converted to use initialization flag, rather than testing for empty.
1405         * dom/EventDispatcher.h: Adjusted decls.
1406         * dom/MouseEvent.cpp:
1407         (WebCore::MouseEventDispatchMediator::dispatchEvent): Changed to send event
1408             to adjustRelatedTarget.
1409
1410 2011-04-08  Geoffrey Garen  <ggaren@apple.com>
1411
1412         Reviewed by Oliver Hunt.
1413
1414         A few heap-related renames and file moves.
1415         
1416         WeakGCPtr<T> => Weak<T>
1417         Global<T> => Strong<T>
1418         collector/ => heap/
1419         collector/* => heap/*
1420         runtime/WeakGCPtr.h => heap/Weak.h
1421         
1422         (Eventually, even more files should move into the heap directory. Like
1423         Heap.h and Heap.cpp, for example.)
1424
1425         * CMakeLists.txt:
1426         * ForwardingHeaders/collector: Removed.
1427         * ForwardingHeaders/heap: Copied from ForwardingHeaders/collector.
1428         * ForwardingHeaders/heap/Strong.h: Copied from ForwardingHeaders/collector/handles/Global.h.
1429         * ForwardingHeaders/heap/Weak.h: Copied from ForwardingHeaders/runtime/WeakGCPtr.h.
1430         * ForwardingHeaders/runtime/WeakGCPtr.h: Removed.
1431         * WebCore.vcproj/WebCore.vcproj:
1432         * WebCore.vcproj/copyForwardingHeaders.cmd:
1433         * bindings/js/JSCallbackData.h:
1434         * bindings/js/JSCustomVoidCallback.h:
1435         * bindings/js/JSDOMWindowBase.h:
1436         * bindings/js/JSDOMWindowShell.cpp:
1437         (WebCore::JSDOMWindowShell::setWindow):
1438         * bindings/js/JSDataGridDataSource.h:
1439         * bindings/js/JSEventListener.h:
1440         * bindings/js/ScheduledAction.cpp:
1441         (WebCore::ScheduledAction::ScheduledAction):
1442         * bindings/js/ScheduledAction.h:
1443         * bindings/js/ScriptCachedFrameData.cpp:
1444         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
1445         * bindings/js/ScriptCachedFrameData.h:
1446         * bindings/js/ScriptController.cpp:
1447         (WebCore::ScriptController::createWindowShell):
1448         * bindings/js/ScriptController.h:
1449         * bindings/js/ScriptObject.h:
1450         * bindings/js/ScriptState.h:
1451         * bindings/js/ScriptValue.cpp:
1452         * bindings/js/ScriptValue.h:
1453         * bindings/js/ScriptWrappable.h:
1454         * bindings/js/WorkerScriptController.cpp:
1455         (WebCore::WorkerScriptController::initScript):
1456         * bindings/js/WorkerScriptController.h:
1457         * bridge/jsc/BridgeJSC.h:
1458         * bridge/qt/qt_runtime.h:
1459         * bridge/runtime_root.h:
1460         * xml/XMLHttpRequest.cpp:
1461
1462 2011-04-09  Keith Kyzivat  <keith.kyzivat@nokia.com>
1463
1464         Reviewed by Laszlo Gombos.
1465
1466         [Qt] Don't link against fontconfig or X11 if embedded
1467         https://bugs.webkit.org/show_bug.cgi?id=58104
1468
1469         No functional change so no new tests.
1470
1471         * WebCore.pri: qpa=>embedded should be done very early so all cases of embedded are uniform.
1472
1473 2011-04-09  Csaba Osztrogon√°c  <ossy@webkit.org>
1474
1475         [Qt] Unreviewed trivial fix after r83344.
1476
1477         * WebCore.pro: Update HEADERS list.
1478
1479 2011-04-09  Jon Lee  <jonlee@apple.com>
1480
1481         Reviewed by Beth Dakin.
1482
1483         Overlay scrollbar flashes in scrollable <textarea> with each keystroke (58180)
1484         https://bugs.webkit.org/show_bug.cgi?id=58180
1485         <rdar://problem/9047984>
1486
1487         * platform/mac/ScrollAnimatorMac.mm:
1488         (WebCore::ScrollAnimatorMac::immediateScrollToPoint): Check that there is a change before submitting
1489         (WebCore::ScrollAnimatorMac::immediateScrollByDeltaX):
1490         (WebCore::ScrollAnimatorMac::immediateScrollByDeltaY):
1491
1492 2011-04-09  Sreeram Ramachandran  <sreeram@google.com>
1493
1494         Reviewed by Ryosuke Niwa.
1495
1496         Gather data on modal dialogs shown during unload events
1497         https://bugs.webkit.org/show_bug.cgi?id=58115
1498
1499         Add a new method to the ChromeClient API to allow clients to receive
1500         notifications of modal dialogs dispatched during page dismissal events.
1501         The new method has a default empty definition; only chromium overrides
1502         it to keep track of histograms.
1503
1504         No tests because this is a no-op for all ports except chromium (and it's
1505         not clear how to test chromium histograms from webkit).
1506
1507         * page/Chrome.cpp:
1508         (WebCore::isDuringPageDismissal):
1509         (WebCore::willRunModalDialog):
1510         (WebCore::Chrome::runJavaScriptAlert):
1511         (WebCore::Chrome::runJavaScriptConfirm):
1512         (WebCore::Chrome::runJavaScriptPrompt):
1513         (WebCore::Chrome::willRunModalHTMLDialog):
1514         * page/Chrome.h:
1515         * page/ChromeClient.h:
1516         (WebCore::ChromeClient::willRunModalDialogDuringPageDismissal):
1517         * page/DOMWindow.cpp:
1518         (WebCore::DOMWindow::showModalDialog):
1519
1520 2011-04-08  David Humphrey  <david.humphrey@senecac.on.ca>
1521
1522         Reviewed by Eric Carlson.
1523
1524         Fix call order of media element muted and play(), such that setting muted before play() works.
1525         https://bugs.webkit.org/show_bug.cgi?id=57673
1526         https://code.google.com/p/chromium/issues/detail?id=70777
1527
1528         Manual test added: manual-tests/media-muted.html
1529
1530         * html/HTMLMediaElement.cpp:
1531         (WebCore::HTMLMediaElement::updatePlayState):
1532         * manual-tests/media-muted.html: Added.
1533
1534 2011-04-08  Nat Duca  <nduca@chromium.org>
1535
1536         Reviewed by David Levin.
1537
1538         [chromium] Fix windows assertion on ~CCThread
1539         https://bugs.webkit.org/show_bug.cgi?id=58153
1540
1541         Because ~CCThread uses waitForThreadCompletion,
1542         calling detachThread is not necessary.
1543
1544         * platform/graphics/chromium/cc/CCThread.cpp:
1545         (WebCore::CCThread::runLoop):
1546
1547 2011-04-08  Jian Li  <jianli@chromium.org>
1548
1549         Unreviewed, rolling out r83348.
1550         http://trac.webkit.org/changeset/83348
1551         https://bugs.webkit.org/show_bug.cgi?id=49508
1552
1553         Breaks layout tests in QT, Win7 and Chromium.
1554
1555         * rendering/RenderText.cpp:
1556         (WebCore::RenderText::localCaretRect):
1557
1558 2011-04-08  MORITA Hajime  <morrita@google.com>
1559
1560         Reviewed by Simon Fraser.
1561
1562         Negative spread should not make a sharp corner rounded
1563         https://bugs.webkit.org/show_bug.cgi?id=58162
1564
1565         Handled inset shadow path for rounded and non-rounded rect
1566         differently as normal shadow path is doing.
1567         
1568         * rendering/RenderBoxModelObject.cpp:
1569         (WebCore::RenderBoxModelObject::paintBoxShadow):
1570
1571 2011-04-07  Simon Fraser  <simon.fraser@apple.com>
1572
1573         Reviewed by Martin Robinson.
1574
1575         REGRESSION (r77034-r77220): CSS box-shadow no longer renders on PowerPC
1576         https://bugs.webkit.org/show_bug.cgi?id=55180
1577
1578         The endianness #ifdef in ShadowBlur was unnecessary and harmful. The
1579         data we get back from ImageBuffer::getImageData() do not vary in
1580         endianness.
1581
1582         * platform/graphics/ShadowBlur.cpp:
1583         (WebCore::ShadowBlur::blurLayerImage):
1584
1585 2011-04-08  Erik Arvidsson  <arv@chromium.org>
1586
1587         Reviewed by Dimitri Glazkov.
1588
1589         IFrame is getting the focus even though it is hidden
1590         https://bugs.webkit.org/show_bug.cgi?id=55861
1591
1592         Test: fast/dom/hidden-iframe-no-focus.html
1593
1594         * html/HTMLFrameOwnerElement.cpp:
1595         (WebCore::HTMLFrameOwnerElement::isKeyboardFocusable):
1596         * html/HTMLFrameOwnerElement.h:
1597
1598 2011-04-08  Jeff Timanus  <twiz@chromium.org>
1599
1600         Reviewed by Kenneth Russell.
1601
1602         Fall back to software rendering for Canvas2D when requesting a DrawingBuffer larger than supported by the GL environment.
1603         https://bugs.webkit.org/show_bug.cgi?id=57768
1604
1605         * html/canvas/CanvasRenderingContext2D.cpp:
1606         (WebCore::CanvasRenderingContext2D::CanvasRenderingContext2D):
1607         (WebCore::CanvasRenderingContext2D::reset):
1608         * platform/graphics/gpu/DrawingBuffer.cpp:
1609         (WebCore::DrawingBuffer::reset):
1610         * platform/graphics/gpu/DrawingBuffer.h:
1611
1612 2011-04-08  Daniel Cheng  <dcheng@chromium.org>
1613
1614         Reviewed by Dmitry Titov.
1615
1616         [chromium] Implement image/png support in DataTransferItems
1617         https://bugs.webkit.org/show_bug.cgi?id=58106
1618
1619         This patch implements DataTransferItem::getAsFile() using Blobs. In
1620         addition, plumbing for image/png has been added so image paste will be
1621         supported as long as the renderer makes that data available.
1622
1623         Tests: editing/pasteboard/data-transfer-items-image-png.html
1624
1625         * dom/DataTransferItem.h:
1626         * dom/DataTransferItem.idl:
1627         * platform/chromium/ClipboardMimeTypes.cpp:
1628         * platform/chromium/ClipboardMimeTypes.h:
1629         * platform/chromium/DataTransferItemChromium.cpp:
1630         (WebCore::DataTransferItemChromium::getAsString):
1631         (WebCore::DataTransferItemChromium::getAsFile):
1632         * platform/chromium/DataTransferItemChromium.h:
1633         * platform/chromium/PlatformBridge.h:
1634
1635 2011-04-08 MORITA Hajime  <morrita@google.com>
1636
1637         Unreviewed windows build fix.
1638         
1639         * editing/SpellingCorrectionController.h:
1640         (WebCore::SpellingCorrectionController::UNLESS_ENABLED):
1641
1642 2011-04-08  Enrica Casucci  <enrica@apple.com>
1643
1644         Reviewed by Maciej Stachowiak.
1645
1646         Improve lifetime management of nodes in ReplaceNodeWithSpanCommand.
1647         https://bugs.webkit.org/show_bug.cgi?id=57595
1648         <rdar://problem/9222122>
1649
1650         Test: editing/style/bold-with-dom-changes.html
1651
1652         * editing/ReplaceNodeWithSpanCommand.cpp:
1653         (WebCore::swapInNodePreservingAttributesAndChildren):
1654
1655 2011-04-07  Roland Steiner  <rolandsteiner@chromium.org>
1656
1657         Reviewed by Dimitri Glazkov.
1658
1659         Bug 58060 - Prepare access to TreeScope from Node, using NodeRareData
1660         https://bugs.webkit.org/show_bug.cgi?id=58060
1661
1662         Add a TreeScope pointer to NodeRareData to allow direct access to the containing tree scope.
1663         However, in case the containing scope is the document, this is not set, and the
1664         document pointer within Node is used instead.
1665
1666         In an object derived from TreeScope (currently Document), the tree scope pointer
1667         points to itself. Such objects also contain a parent tree scope pointer that
1668         points to the containing scope. For Document, this is 0.
1669
1670         Add new functions setTreeScope[Recursively] that replace setDocument[Recursively]
1671         in public usage. setDocument[Recursively] are now only used internally and are
1672         thererfore protected.
1673
1674         No new tests. (no new functionality)
1675
1676         * dom/ContainerNode.cpp: change DOM manipulation methods to update scope of inserted nodes
1677         (WebCore::ContainerNode::insertBefore):
1678         (WebCore::ContainerNode::replaceChild):
1679         (WebCore::ContainerNode::appendChild):
1680         * dom/Document.cpp:
1681         (WebCore::Document::~Document):
1682         (WebCore::Document::setDocType): Ditto
1683         (WebCore::Document::adoptNode): Ditto
1684         * dom/Document.h:
1685         * dom/Node.cpp:
1686         (WebCore::Node::treeScope): use NodeRareData to check if a non-Document scope is set
1687         (WebCore::Node::setTreeScope): update NodeRareData depending on whether scope is a document
1688         (WebCore::Node::setTreeScopeRecursively):
1689         (WebCore::Node::setDocumentRecursively):
1690         * dom/Node.h:
1691         * dom/NodeRareData.h: add scope pointer
1692         (WebCore::NodeRareData::NodeRareData):
1693         (WebCore::NodeRareData::treeScope):
1694         (WebCore::NodeRareData::setTreeScope):
1695         * dom/TreeScope.cpp: add parentTreeScope pointer
1696         (WebCore::TreeScope::TreeScope):
1697         (WebCore::TreeScope::setParentTreeScope):
1698         * dom/TreeScope.h:
1699         (WebCore::TreeScope::parentTreeScope):
1700
1701 2011-04-08  Xiaomei Ji  <xji@chromium.org>
1702
1703         Reviewed by David Hyatt.
1704
1705         Local caret rectangle calculation should be relative to its containing block.
1706         https://bugs.webkit.org/show_bug.cgi?id=49508.
1707
1708         InlineBox and caret rectangle are positioned relative to its containing block.
1709         So its left and right edge value should be relative to its containing block as well. 
1710
1711         Test: fast/forms/cursor-at-editable-content-boundary.html
1712
1713         * rendering/RenderText.cpp:
1714         (WebCore::RenderText::localCaretRect):
1715
1716 2011-04-08  MORITA Hajime  <morrita@google.com>
1717
1718         Unreviewed build fix.
1719
1720         * editing/Editor.cpp:
1721         (WebCore::Editor::markMisspellingsAfterTypingToWord):
1722
1723 2011-04-08  David Hyatt  <hyatt@apple.com>
1724
1725         Reviewed by Simon Fraser.
1726
1727         https://bugs.webkit.org/show_bug.cgi?id=57971
1728         
1729         Rework visited/unvisited links for before/after content. Propagate the bits earlier so that we don't lose
1730         them when we throw away the visited style. Don't throw away the visited link style for pseudo elements
1731         either, so that the styles are consistent.
1732
1733         Added fast/history/visited-generated-content-test.html
1734
1735         * css/CSSStyleSelector.cpp:
1736         (WebCore::CSSStyleSelector::styleForElement):
1737         (WebCore::CSSStyleSelector::pseudoStyleForElement):
1738
1739 2011-04-06  MORITA Hajime  <morrita@google.com>
1740
1741         Reviewed by Darin Adler.
1742
1743         [Refactoring] Auto correction panel should be handled by its own class.
1744         https://bugs.webkit.org/show_bug.cgi?id=55571
1745
1746         Extracted code inside SUPPORT_AUTOCORRECTION_PANEL into
1747         SpellingCorrectionController class.
1748         This change also remove some SUPPORT_AUTOCORRECTION_PANEL guard if
1749         code paths inside the never reached without autocorrection support.
1750         Removing guards reduces unintentional build breakage.
1751
1752         No new tests, no behavior chagne.
1753
1754         * CMakeLists.txt:
1755         * GNUmakefile.am:
1756         * WebCore.gypi:
1757         * WebCore.pro:
1758         * WebCore.vcproj/WebCore.vcproj:
1759         * WebCore.xcodeproj/project.pbxproj:
1760         * editing/CorrectionPanelInfo.h: Removed.
1761         * editing/EditingAllInOne.cpp:
1762         * editing/Editor.cpp:
1763         (WebCore::Editor::respondToChangedSelection):
1764         (WebCore::Editor::respondToChangedContents):
1765         (WebCore::Editor::appliedEditing):
1766         (WebCore::Editor::Editor):
1767         (WebCore::Editor::~Editor):
1768         (WebCore::Editor::insertTextWithoutSendingTextEvent):
1769         (WebCore::Editor::insertLineBreak):
1770         (WebCore::Editor::insertParagraphSeparator):
1771         (WebCore::Editor::cut):
1772         (WebCore::Editor::paste):
1773         (WebCore::Editor::pasteAsPlainText):
1774         (WebCore::Editor::isAutomaticSpellingCorrectionEnabled):
1775         (WebCore::Editor::markMisspellingsAfterTypingToWord):
1776         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
1777         (WebCore::Editor::changeBackToReplacedString):
1778         (WebCore::Editor::unappliedSpellCorrection):
1779         (WebCore::Editor::updateMarkersForWordsAffectedByEditing):
1780         (WebCore::Editor::startCorrectionPanelTimer):
1781         (WebCore::Editor::handleCorrectionPanelResult):
1782         (WebCore::Editor::dismissCorrectionPanelAsIgnored):
1783         * editing/Editor.h:
1784         * editing/SpellingCorrectionCommand.cpp:
1785         * editing/SpellingCorrectionController.cpp: Added.
1786         (WebCore::markerTypesForAutocorrection):
1787         (WebCore::markerTypesForReplacement):
1788         (WebCore::markersHaveIdenticalDescription):
1789         (WebCore::SpellingCorrectionController::SpellingCorrectionController):
1790         (WebCore::SpellingCorrectionController::~SpellingCorrectionController):
1791         (WebCore::SpellingCorrectionController::startCorrectionPanelTimer):
1792         (WebCore::SpellingCorrectionController::stopCorrectionPanelTimer):
1793         (WebCore::SpellingCorrectionController::stopPendingCorrection):
1794         (WebCore::SpellingCorrectionController::applyPendingCorrection):
1795         (WebCore::SpellingCorrectionController::hasPendingCorrection):
1796         (WebCore::SpellingCorrectionController::isSpellingMarkerAllowed):
1797         (WebCore::SpellingCorrectionController::show):
1798         (WebCore::SpellingCorrectionController::handleCancelOperation):
1799         (WebCore::SpellingCorrectionController::dismiss):
1800         (WebCore::SpellingCorrectionController::dismissSoon):
1801         (WebCore::SpellingCorrectionController::applyCorrectionPanelInfo):
1802         (WebCore::SpellingCorrectionController::applyAutocorrectionBeforeTypingIfAppropriate):
1803         (WebCore::SpellingCorrectionController::respondToUnappliedSpellCorrection):
1804         (WebCore::SpellingCorrectionController::correctionPanelTimerFired):
1805         (WebCore::SpellingCorrectionController::handleCorrectionPanelResult):
1806         (WebCore::SpellingCorrectionController::isAutomaticSpellingCorrectionEnabled):
1807         (WebCore::SpellingCorrectionController::windowRectForRange):
1808         (WebCore::SpellingCorrectionController::respondToChangedSelection):
1809         (WebCore::SpellingCorrectionController::respondToAppliedEditing):
1810         (WebCore::SpellingCorrectionController::client):
1811         (WebCore::SpellingCorrectionController::textChecker):
1812         (WebCore::SpellingCorrectionController::recordAutocorrectionResponseReversed):
1813         (WebCore::SpellingCorrectionController::markReversed):
1814         (WebCore::SpellingCorrectionController::markCorrection):
1815         (WebCore::SpellingCorrectionController::recordSpellcheckerResponseForModifiedCorrection):
1816         * editing/SpellingCorrectionController.h: Added.
1817         (WebCore::SpellingCorrectionController::UNLESS_ENABLED):
1818         (WebCore::SpellingCorrectionController::shouldStartTimeFor):
1819         (WebCore::SpellingCorrectionController::shouldRemoveMarkersUponEditing):        
1820         * editing/TypingCommand.cpp:
1821         (WebCore::TypingCommand::insertText):
1822         (WebCore::TypingCommand::markMisspellingsAfterTyping):
1823         (WebCore::TypingCommand::deleteKeyPressed):
1824         (WebCore::TypingCommand::forwardDeleteKeyPressed):
1825         * editing/htmlediting.h:
1826         (WebCore::isAmbiguousBoundaryCharacter):
1827         * page/EditorClient.h:
1828         * page/Frame.cpp:
1829         (WebCore::Frame::setPageAndTextZoomFactors):
1830
1831 2011-04-08  Alpha Lam  <hclam@chromium.org>
1832
1833         Unreviewed, rolling out r83335.
1834         http://trac.webkit.org/changeset/83335
1835         https://bugs.webkit.org/show_bug.cgi?id=53556
1836
1837         GTK and QT bots are broken
1838
1839         * CMakeLists.txt:
1840         * Configurations/FeatureDefines.xcconfig:
1841         * DerivedSources.make:
1842         * GNUmakefile.am:
1843         * WebCore.gypi:
1844         * WebCore.xcodeproj/project.pbxproj:
1845         * features.pri:
1846         * html/HTMLAttributeNames.in:
1847         * html/HTMLTagNames.in:
1848         * html/HTMLTrackElement.cpp: Removed.
1849         * html/HTMLTrackElement.h: Removed.
1850         * html/HTMLTrackElement.idl: Removed.
1851
1852 2011-04-08  Brady Eidson  <beidson@apple.com>
1853
1854         Reviewed by Adam Roben.
1855
1856         https://bugs.webkit.org/show_bug.cgi?id=58155 and part of <rdar://problem/9251767>
1857         BitmapImage::getFirstCGImageRefOfSize fails if the frameCount hasn't been initialized from the image source.
1858
1859         * platform/graphics/cg/ImageCG.cpp:
1860         (WebCore::BitmapImage::getFirstCGImageRefOfSize): Call frameCount() instead of accessing m_frames.size() to
1861           make sure the frames are properly tallied first.
1862
1863 2011-04-08  Benjamin Poulain  <benjamin.poulain@nokia.com>
1864
1865         Reviewed by Andreas Kling.
1866
1867         [Qt] Dragging and dropping an image in edit mode does not work
1868         https://bugs.webkit.org/show_bug.cgi?id=19385
1869
1870         When adding an image to the clipboard, we should also include the HTML code of that image so
1871         it can be used for internal drag and drop.
1872
1873         This HTML is expected by all clients of drop events so a fragment can be moved from one browser to
1874         another, or inside the same browser.
1875
1876         * platform/qt/ClipboardQt.cpp:
1877         (WebCore::ClipboardQt::declareAndWriteDragImage):
1878
1879 2011-04-07  Anna Cavender  <annacc@chromium.org>
1880
1881         Reviewed by Eric Carlson.
1882
1883         Setup ENABLE(TRACK) feature define + initial HTMLTrackElement
1884         https://bugs.webkit.org/show_bug.cgi?id=53556
1885
1886         No new tests. No real functionality added just yet.
1887
1888         * CMakeLists.txt:
1889         * Configurations/FeatureDefines.xcconfig:
1890         * DerivedSources.make:
1891         * GNUmakefile.am:
1892         * WebCore.gypi:
1893         * WebCore.xcodeproj/project.pbxproj:
1894         * features.pri:
1895         * html/HTMLAttributeNames.in:
1896         * html/HTMLTagNames.in:
1897         * html/HTMLTrackElement.cpp: Added.
1898         (WebCore::HTMLTrackElement::HTMLTrackElement):
1899         (WebCore::HTMLTrackElement::create):
1900         (WebCore::HTMLTrackElement::insertedIntoTree):
1901         (WebCore::HTMLTrackElement::willRemove):
1902         (WebCore::HTMLTrackElement::src):
1903         (WebCore::HTMLTrackElement::setSrc):
1904         (WebCore::HTMLTrackElement::kind):
1905         (WebCore::HTMLTrackElement::setKind):
1906         (WebCore::HTMLTrackElement::srclang):
1907         (WebCore::HTMLTrackElement::setSrclang):
1908         (WebCore::HTMLTrackElement::label):
1909         (WebCore::HTMLTrackElement::setLabel):
1910         (WebCore::HTMLTrackElement::isDefault):
1911         (WebCore::HTMLTrackElement::setIsDefault):
1912         (WebCore::HTMLTrackElement::isURLAttribute):
1913         * html/HTMLTrackElement.h: Added.
1914         * html/HTMLTrackElement.idl: Added.
1915
1916 2011-04-07  Jer Noble  <jer.noble@apple.com>
1917
1918         Reviewed by Eric Carlson.
1919
1920         Logic error in HTMLMediaElement::exitFullscreen()
1921         https://bugs.webkit.org/show_bug.cgi?id=58085
1922
1923         The new full screen API case could fall through to the legacy API case
1924         unintentionally if a script calls exitFullscreen on an element which is
1925         not the current full screen element.
1926
1927         * html/HTMLMediaElement.cpp:
1928         (WebCore::HTMLMediaElement::enterFullscreen):
1929         (WebCore::HTMLMediaElement::exitFullscreen):
1930
1931 2011-04-08  Mike Reed  <reed@google.com>
1932
1933         Reviewed by Eric Seidel.
1934
1935         Replace SKIA_TEXT with isNativeFontRenderingAllowed() for print-preview to work
1936         https://bugs.webkit.org/show_bug.cgi?id=57782
1937
1938         No new tests. This change only affects print-preview and build option SKIA_GPU 
1939
1940         * platform/graphics/skia/SkiaFontWin.cpp:
1941         (WebCore::paintSkiaText):
1942
1943 2011-04-08  Ryosuke Niwa  <rniwa@webkit.org>
1944
1945         Reviewed by Tony Chang, Darin Adler, and Enrica Casucci.
1946
1947         REGRESSION(r81887): Crash in SplitElement
1948         https://bugs.webkit.org/show_bug.cgi?id=57743
1949
1950         The crash was caused by ReplaceSelectionCommand::doApply's calling splitElement with computeNodeAfterPosition
1951         even when the position was after the last node in it container. Since all we are doing here is to splitting tree
1952         up until the highest ancestor with isInlineNodeWithStyle, replaced the while loop by calls to splitTreeToNode
1953         and highestEnclosingNodeOfType.
1954
1955         Also fixed a bug in splitTreeToNode not to check the difference in visible position when splitting the ancestor,
1956         which would have introduced unnecessary nodes when splitting tree and a bug in highestEnclosingNodeOfType that
1957         it incorrectly called deprecatedNode instead of containerNode.
1958
1959         Test: editing/inserting/insert-images-in-pre-x-crash.html
1960
1961         * editing/CompositeEditCommand.cpp:
1962         (WebCore::CompositeEditCommand::splitTreeToNode):
1963         * editing/ReplaceSelectionCommand.cpp:
1964         (WebCore::ReplaceSelectionCommand::doApply):
1965         * editing/htmlediting.cpp:
1966         (WebCore::highestEnclosingNodeOfType):
1967
1968 2011-04-08  Antti Koivisto  <antti@apple.com>
1969
1970         Reviewed by Tony Gentilcore.
1971
1972         Incoming source should be preload scanned when the parser is blocked 
1973         https://bugs.webkit.org/show_bug.cgi?id=58117
1974
1975         Scan the appended source if parser is blocked.
1976
1977         Test: http/tests/loading/preload-append-scan.php
1978
1979         * html/parser/HTMLDocumentParser.cpp:
1980         (WebCore::HTMLDocumentParser::append):
1981
1982 2011-04-08  Martin Robinson  <mrobinson@igalia.com>
1983
1984         Reviewed by Xan Lopez.
1985
1986         [GTK] Fix the WebKit2 build for older versions of GTK+
1987         https://bugs.webkit.org/show_bug.cgi?id=58095
1988
1989         No new tests. This is just a build fix.
1990
1991         * platform/gtk/GtkVersioning.c:
1992         (gdk_window_create_similar_surface): Reimplement this method for older versions of GDK.
1993         * platform/gtk/GtkVersioning.h: Add the new method to the header.
1994
1995 2011-04-08  Misha Tyutyunik  <michael.tyutyunik@nokia.com>
1996
1997         Reviewed by Laszlo Gombos.
1998
1999         [Qt] Plugin is not scrolled together with page content or jumping 
2000         when content is rendered using cache (backing store).
2001         https://bugs.webkit.org/show_bug.cgi?id=56130
2002         
2003         This is a Symbian portion of the fix. For Linux it looks like
2004         it's enough to call set geometry which should be addressed in
2005         https://bugs.webkit.org/show_bug.cgi?id=57179
2006
2007         No new tests required. This can be tested with manual tests from 
2008         WebCore/manual-tests/qt and WebCore/manual-tests/plugins
2009
2010         * plugins/symbian/PluginViewSymbian.cpp:
2011         (WebCore::PluginView::updatePluginWidget):
2012
2013 2011-04-08  Abhishek Arya  <inferno@chromium.org>
2014
2015         Unreviewed. Remove accidental printf added in r83306.
2016
2017         * page/EventHandler.cpp:
2018         (WebCore::EventHandler::sendContextMenuEvent):
2019
2020 2011-04-08  Enrica Casucci  <enrica@apple.com>
2021
2022         Reviewed by Darin Adler.
2023
2024         Dragging text in a WebKit2 window results in a copy instead of a move.
2025         https://bugs.webkit.org/show_bug.cgi?id=56772
2026         <rdar://problem/9165140>
2027
2028         cleanupAfterSystemDrag cannot call dragEnd in WebKit2, since
2029         the call to startDrag is asynchronous.
2030         
2031         * page/mac/DragControllerMac.mm:
2032         (WebCore::DragController::cleanupAfterSystemDrag):
2033
2034 2011-04-05  Dimitri Glazkov  <dglazkov@chromium.org>
2035
2036         Reviewed by Darin Adler.
2037
2038         Move WheelEvent-dispatching logic into WheelEventDispatchMediator.
2039         https://bugs.webkit.org/show_bug.cgi?id=57642
2040
2041         Covered by existing tests, no functional change.
2042
2043         * dom/Event.cpp:
2044         * dom/Event.h:
2045         (WebCore::EventDispatchMediator::EventDispatchMediator): Added default
2046             constructor.
2047         (WebCore::EventDispatchMediator::event): Inlined.
2048         (WebCore::EventDispatchMediator::setEvent): Added.
2049         * dom/EventDispatcher.cpp: Removed dispatchWheelEvent.
2050         * dom/EventDispatcher.h: Updated decls.
2051         * dom/Node.cpp:
2052         (WebCore::Node::dispatchWheelEvent): Changed to use the mediator and
2053             return a bool, like other dispatch event functions.
2054         * dom/Node.h: Changed decl.
2055         * dom/WheelEvent.cpp:
2056         (WebCore::granularity): Moved from EventDispatcher.
2057         (WebCore::WheelEventDispatchMediator::WheelEventDisatchMediator): Added.
2058         (WebCore::WheelEventDispatchMediator::event): Added.
2059         (WebCore::WheelEventDispatchMediator::dispatchEvent): Added.
2060         * dom/WheelEvent.h: Updated decls.
2061         * page/EventHandler.cpp:
2062         (WebCore::EventHandler::handleWheelEvent): Changed to receive and react
2063             to the return value.
2064
2065 2011-04-08  Jessie Berlin  <jberlin@apple.com>
2066
2067         Windows build warning fix.
2068
2069         * WebCore.vcproj/WebCore.vcproj:
2070         Since ShadowRoot.cpp is included in the DOMAllInOne.cpp file, it should be excluded from
2071         the build.
2072
2073 2011-04-07  Pavel Podivilov  <podivilov@chromium.org>
2074
2075         Reviewed by Pavel Feldman.
2076
2077         Web Inspector: update breakpoints according to source frame decorations after live edit.
2078         https://bugs.webkit.org/show_bug.cgi?id=58029
2079
2080         * inspector/front-end/DebuggerPresentationModel.js:
2081         (WebInspector.DebuggerPresentationModel.prototype.editScriptSource.didEditScriptSource):
2082         (WebInspector.DebuggerPresentationModel.prototype.editScriptSource):
2083         (WebInspector.DebuggerPresentationModel.prototype._updateResourceContent.didEditScriptSource):
2084         (WebInspector.DebuggerPresentationModel.prototype._updateResourceContent):
2085         * inspector/front-end/SourceFile.js:
2086         (WebInspector.SourceFile.prototype.set content):
2087         * inspector/front-end/SourceFrame.js:
2088         (WebInspector.SourceFrame.prototype._handleSave.didEditScriptSource):
2089         (WebInspector.SourceFrame.prototype._handleSave):
2090
2091 2011-04-08  Pavel Podivilov  <podivilov@chromium.org>
2092
2093         Reviewed by Pavel Feldman.
2094
2095         Web Inspector: fix scripts concatenation in scripts panel.
2096         https://bugs.webkit.org/show_bug.cgi?id=58138
2097
2098         When there is just one script starting at 0:0 it should not be surrounded by <script> framing.
2099
2100         * inspector/front-end/SourceFile.js:
2101         (WebInspector.SourceFile.prototype._loadResourceContent):
2102         (WebInspector.SourceFile.prototype._loadAndConcatenateScriptsContent):
2103
2104 2011-04-08  Pavel Feldman  <pfeldman@chromium.org>
2105
2106         Reviewed by Yury Semikhatsky.
2107
2108         Web Inspector: use "locations" for debugger scripts, "lineNumbers" for the UI elements.
2109         https://bugs.webkit.org/show_bug.cgi?id=58118
2110
2111         This change reuses location for call frames in the protocol + structures script
2112         location <-> source lines interaction better. When we need UI columns, we will add
2113         them, but we should distinguish between script and UI terms on the type level, not naming.
2114
2115         * English.lproj/localizedStrings.js:
2116         * bindings/v8/DebuggerScript.js:
2117         * inspector/InjectedScriptSource.js:
2118         * inspector/Inspector.json:
2119         * inspector/front-end/CallStackSidebarPane.js:
2120         (WebInspector.CallStackSidebarPane.prototype.update.didGetSourceLine):
2121         (WebInspector.CallStackSidebarPane.prototype.update):
2122         * inspector/front-end/DebuggerPresentationModel.js:
2123         (WebInspector.DebuggerPresentationModel.prototype.addConsoleMessage.didRequestSourceMapping):
2124         (WebInspector.DebuggerPresentationModel.prototype.addConsoleMessage):
2125         (WebInspector.DebuggerPresentationModel.prototype.continueToLine):
2126         (WebInspector.DebuggerPresentationModel.prototype._setBreakpointInDebugger.didRequestSourceMapping):
2127         (WebInspector.DebuggerPresentationModel.prototype._setBreakpointInDebugger):
2128         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded.didRequestSourceMapping):
2129         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded):
2130         (WebInspector.PresenationCallFrame):
2131         (WebInspector.PresenationCallFrame.prototype.sourceLine.didRequestSourceMapping):
2132         (WebInspector.PresenationCallFrame.prototype.sourceLine):
2133         * inspector/front-end/ScriptFormatter.js:
2134         (WebInspector.ScriptFormatter.locationToPosition):
2135         (WebInspector.ScriptFormatter.lineToPosition):
2136         * inspector/front-end/ScriptsPanel.js:
2137         (WebInspector.ScriptsPanel.prototype._debuggerPaused.else.didGetSourceLocation):
2138         (WebInspector.ScriptsPanel.prototype._debuggerPaused):
2139         (WebInspector.ScriptsPanel.prototype.showAnchorLocation):
2140         (WebInspector.ScriptsPanel.prototype._callFrameSelected.didGetSourceLocation):
2141         (WebInspector.ScriptsPanel.prototype._callFrameSelected):
2142         * inspector/front-end/SourceFile.js:
2143         (WebInspector.SourceMapping.prototype.scriptLocationToSourceLine):
2144         (WebInspector.SourceMapping.prototype.sourceLineToScriptLocation):
2145         (WebInspector.FormattedSourceMapping.prototype.scriptLocationToSourceLine):
2146         (WebInspector.FormattedSourceMapping.prototype.sourceLineToScriptLocation):
2147
2148 2011-04-08  Pavel Podivilov  <podivilov@chromium.org>
2149
2150         Reviewed by Pavel Feldman.
2151
2152         Web Inspector: distinguish breakpoints set on de-obfuscated sources from breakponts set on original sources.
2153         https://bugs.webkit.org/show_bug.cgi?id=58133
2154
2155         * inspector/front-end/DebuggerPresentationModel.js:
2156         (WebInspector.DebuggerPresentationModel.prototype.canEditScriptSource):
2157         (WebInspector.DebuggerPresentationModel.prototype.toggleFormatSourceFiles):
2158         (WebInspector.DebuggerPresentationModel.prototype._debuggerPaused):
2159         (WebInspector.DebuggerPresentationModel.prototype._sourceFileForScript):
2160         (WebInspector.DebuggerPresentationModel.prototype._scriptForSourceFileId):
2161         (WebInspector.DebuggerPresentationModel.prototype._createSourceFileId):
2162         (WebInspector.DebuggerPresentationModel.prototype._reset):
2163
2164 2011-04-07  Pavel Podivilov  <podivilov@chromium.org>
2165
2166         Reviewed by Pavel Feldman.
2167
2168         Web Inspector: make SourceFrame TextViewer's delegate for editing operations.
2169         https://bugs.webkit.org/show_bug.cgi?id=58026
2170
2171         This is the first step of decoupling TextViewer from SourceFrame.
2172
2173         * inspector/front-end/SourceFrame.js:
2174         (WebInspector.SourceFrame):
2175         (WebInspector.SourceFrame.prototype.show):
2176         (WebInspector.SourceFrame.prototype.hide):
2177         (WebInspector.SourceFrame.prototype._ensureContentLoaded):
2178         (WebInspector.SourceFrame.prototype.contentEditable):
2179         (WebInspector.SourceFrame.prototype.startEditing):
2180         (WebInspector.SourceFrame.prototype.endEditing):
2181         (WebInspector.SourceFrame.prototype._createTextViewer):
2182         (WebInspector.SourceFrame.prototype._handleSave):
2183         (WebInspector.SourceFrame.prototype._handleRevertEditing):
2184         * inspector/front-end/TextViewer.js:
2185         (WebInspector.TextViewer.prototype._enterInternalTextChangeMode):
2186         (WebInspector.TextViewer.prototype._exitInternalTextChangeMode):
2187         (WebInspector.TextViewer.prototype._syncDecorationsForLine):
2188         (WebInspector.TextViewer.prototype._doubleClick):
2189         (WebInspector.TextViewerDelegate):
2190         (WebInspector.TextViewerDelegate.prototype.contentEditable):
2191         (WebInspector.TextViewerDelegate.prototype.startEditing):
2192         (WebInspector.TextViewerDelegate.prototype.endEditing):
2193         (WebInspector.TextEditorMainPanel.prototype._paintScheduledLines):
2194         (WebInspector.TextEditorMainPanel.prototype._handleDOMUpdates):
2195         * inspector/front-end/inspector.html:
2196
2197 2011-04-08  Leandro Gracia Gil  <leandrogracia@chromium.org>
2198
2199         Reviewed by Steve Block.
2200
2201         Media Stream API: add the getUserMedia method and the Javascript bindings.
2202         https://bugs.webkit.org/show_bug.cgi?id=56586
2203
2204         Add the getUserMedia method to the navigator and its new Javascript types.
2205         Current specification: http://www.whatwg.org/specs/web-apps/current-work/multipage/dnd.html#video-conferencing-and-peer-to-peer-communication
2206
2207         Tests: fast/dom/MediaStream/argument-types.html
2208                fast/dom/MediaStream/enabled.html
2209                fast/dom/MediaStream/no-interface-object.html
2210
2211         * Android.derived.jscbindings.mk:
2212         * Android.derived.v8bindings.mk:
2213         * Android.v8bindings.mk:
2214         * CMakeLists.txt:
2215         * CodeGenerators.pri:
2216         * DerivedSources.cpp:
2217         * DerivedSources.make:
2218         * GNUmakefile.list.am:
2219         * WebCore.gypi:
2220         * WebCore.pro:
2221         * WebCore.vcproj/WebCore.vcproj:
2222         * WebCore.xcodeproj/project.pbxproj:
2223         * bindings/js/JSNavigatorCustom.cpp:
2224         (WebCore::JSNavigator::webkitGetUserMedia):
2225         * bindings/v8/custom/V8NavigatorCustom.cpp: Added.
2226         (WebCore::V8Navigator::webkitGetUserMediaCallback):
2227         * page/Navigator.cpp:
2228         (WebCore::Navigator::webkitGetUserMedia):
2229         * page/Navigator.h:
2230         * page/Navigator.idl:
2231         * page/NavigatorUserMediaError.h: Added.
2232         (WebCore::NavigatorUserMediaError::NavigatorUserMediaError):
2233         (WebCore::NavigatorUserMediaError::~NavigatorUserMediaError):
2234         (WebCore::NavigatorUserMediaError::code):
2235         * page/NavigatorUserMediaError.idl: Added.
2236         * page/NavigatorUserMediaErrorCallback.h: Added.
2237         (WebCore::NavigatorUserMediaErrorCallback::~NavigatorUserMediaErrorCallback):
2238         * page/NavigatorUserMediaErrorCallback.idl: Added.
2239         * page/NavigatorUserMediaSuccessCallback.h: Added.
2240         (WebCore::NavigatorUserMediaSuccessCallback::~NavigatorUserMediaSuccessCallback):
2241         * page/NavigatorUserMediaSuccessCallback.idl: Added.
2242
2243 2011-04-08  Mikhail Naganov  <mnaganov@chromium.org>
2244
2245         Reviewed by Pavel Feldman.
2246
2247         Web Inspector: [Chromium] Add more tests for detailed heap snapshots UI.
2248         https://bugs.webkit.org/show_bug.cgi?id=58010
2249         https://bugs.webkit.org/show_bug.cgi?id=58011
2250
2251         Added tests for "Containment" view. Minor refactorings, bugs fixed.
2252         Split one large tests into smaller ones to avoid timing out in debug mode.
2253
2254         Tests: inspector/profiler/detailed-heapshots-containment-expansion-preserved-when-sorting.html
2255                inspector/profiler/detailed-heapshots-containment-show-all.html
2256                inspector/profiler/detailed-heapshots-containment-show-next.html
2257                inspector/profiler/detailed-heapshots-containment-sorting.html
2258                inspector/profiler/detailed-heapshots-summary-expansion-preserved-when-sorting.html
2259                inspector/profiler/detailed-heapshots-summary-show-all.html
2260                inspector/profiler/detailed-heapshots-summary-show-next.html
2261                inspector/profiler/detailed-heapshots-summary-sorting.html
2262
2263         * inspector/front-end/DetailedHeapshotGridNodes.js:
2264         (WebInspector.HeapSnapshotGridNode):
2265         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren):
2266         (WebInspector.HeapSnapshotGridNode.prototype.sort.doSort):
2267         (WebInspector.HeapSnapshotGridNode.prototype.sort):
2268         (WebInspector.HeapSnapshotGenericObjectNode):
2269         (WebInspector.HeapSnapshotObjectNode):
2270         (WebInspector.HeapSnapshotInstanceNode):
2271         (WebInspector.HeapSnapshotConstructorNode):
2272         (WebInspector.HeapSnapshotDiffNode):
2273         (WebInspector.HeapSnapshotDominatorObjectNode):
2274         * inspector/front-end/DetailedHeapshotView.js:
2275         (WebInspector.HeapSnapshotContainmentDataGrid):
2276         (WebInspector.HeapSnapshotDominatorsDataGrid):
2277
2278 2011-04-08  Andrey Adaikin  <aandrey@google.com>
2279
2280         Reviewed by Pavel Feldman.
2281
2282         Web Inspector: Bugs in some corner cases in the text editor
2283         https://bugs.webkit.org/show_bug.cgi?id=58025
2284
2285         This solves the following bugs:
2286         1) The very last _empty_ line would not be deleted if you hit a Backspace on it, or the selection text to be deleted is extended to the very bottom of the editor.
2287         2) An odd corner case: delete all source code from the editor, hit backspace on the only empty line, then add a character. In this case the browser will insert a TEXT node instead of a DIV node for a lineRow.
2288
2289         * inspector/front-end/TextViewer.js:
2290         (WebInspector.TextEditorMainPanel.prototype._selectionToPosition):
2291         (WebInspector.TextEditorMainPanel.prototype._enclosingLineRowOrSelf):
2292         (WebInspector.TextEditorMainPanel.prototype._handleDOMUpdates):
2293         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
2294         (WebInspector.TextEditorMainPanel.prototype._collectLinesFromDiv):
2295
2296 2011-04-07  Pavel Podivilov  <podivilov@chromium.org>
2297
2298         Reviewed by Pavel Feldman.
2299
2300         Web Inspector: add test for script formatter worker.
2301         https://bugs.webkit.org/show_bug.cgi?id=57447
2302
2303         Test: inspector/debugger/script-formatter.html
2304
2305         * GNUmakefile.am:
2306         * WebCore.xcodeproj/project.pbxproj:
2307         * gyp/streamline-inspector-source.sh:
2308         * inspector/front-end/DebuggerPresentationModel.js:
2309         (WebInspector.DebuggerPresentationModel.prototype._addScript):
2310         (WebInspector.DebuggerPresentationModel.prototype.toggleFormatSourceFiles):
2311         (WebInspector.DebuggerPresentationModel.prototype._formatter):
2312         * inspector/front-end/ScriptFormatterWorker.js:
2313
2314 2011-04-08  Andrey Adaikin  <aandrey@google.com>
2315
2316         Reviewed by Pavel Feldman.
2317
2318         Web Inspector: Tweak dynamically constants for the async highlighting in text editor
2319         https://bugs.webkit.org/show_bug.cgi?id=58035
2320
2321         * inspector/front-end/TextViewer.js:
2322         (WebInspector.TextEditorMainPanel.prototype._expandChunks):
2323         (WebInspector.TextEditorMainPanel.prototype._schedulePaintLines):
2324         (WebInspector.TextEditorMainPanel.prototype._paintScheduledLines):
2325         (WebInspector.TextEditorMainPanel.prototype._restorePaintLinesOperationsCredit):
2326         (WebInspector.TextEditorMainPanel.prototype._adjustPaintLinesOperationsRefreshValue):
2327
2328 2011-04-08  Andrey Kosyakov  <caseq@chromium.org>
2329
2330         Reviewed by Yury Semikhatsky.
2331
2332         Web Inspector: HAR compliance fixes
2333         https://bugs.webkit.org/show_bug.cgi?id=58124
2334
2335         - Always provide some values for queryString and cookies, even though arrays may be empty
2336         - Always provide an empty cache object
2337         - Added entire HARLog to test
2338         - Workaround in test to avoid custom expectations (favicon.ico appears in log on certain platforms)
2339
2340         * inspector/front-end/HAREntry.js:
2341         (WebInspector.HAREntry.prototype.build):
2342         (WebInspector.HAREntry.prototype._buildRequest):
2343         (WebInspector.HAREntry.prototype._buildResponse):
2344
2345 2011-04-08  Adam Barth  <abarth@webkit.org>
2346
2347         Attempt to fix the Qt build.
2348
2349         * css/CSSStyleApplyProperty.cpp:
2350
2351 2011-04-07  Adam Barth  <abarth@webkit.org>
2352
2353         Reviewed by Eric Seidel.
2354
2355         Refactor WebCore/GNUMakefile.am to separate list of files
2356         https://bugs.webkit.org/show_bug.cgi?id=58116
2357
2358         This change is similar to the cooresponding to change to
2359         JavaScriptCore.  We hope to generate GNUmakefile.list.am automatically
2360         using GYP.
2361
2362         * GNUmakefile.am:
2363         * GNUmakefile.list.am: Added.
2364
2365 2011-04-07  Geoffrey Garen  <ggaren@apple.com>
2366
2367         Not reviewed.
2368
2369         Rolled out some accidentally-committed changes in my last commit.
2370
2371         * dom/EventTarget.cpp:
2372         (WebCore::EventTarget::addEventListener):
2373         (WebCore::EventTarget::removeEventListener):
2374         * dom/EventTarget.h:
2375
2376 2011-04-07  Julien Chaffraix  <jchaffraix@codeaurora.org>
2377
2378         Reviewed by Alexey Proskuryakov.
2379
2380         EventSource should only accept UTF-8 charset
2381         https://bugs.webkit.org/show_bug.cgi?id=56942
2382
2383         Following the discussion on bug 45372, this change implements the recommended
2384         way of handling "charset". We only accept UTF-8 but no other encoding. This matches
2385         the encoding of the EventSource and also may fix TomCat that automatically send this
2386         charset.
2387
2388         * page/EventSource.cpp:
2389         (WebCore::EventSource::didReceiveResponse): We now check the charset attribute and if it is
2390         not UTF-8, abort the connection and log the error to the console. Also we log if the MIME type
2391         is wrong to the console to help debugging (only in the case of an HTTP 200 response though).
2392
2393 2011-04-07  Geoffrey Garen  <ggaren@apple.com>
2394
2395         Reviewed by Maciej Stachowiak.
2396
2397         Some Handle<T> cleanup
2398         https://bugs.webkit.org/show_bug.cgi?id=58109
2399
2400         * bindings/js/ScriptValue.h:
2401         (WebCore::ScriptValue::ScriptValue): Updated for new null constructor.
2402         (WebCore::ScriptValue::hasNoValue): Updated for removal of isEmpty().
2403
2404 2011-04-07  Dominic Cooney  <dominicc@google.com>
2405
2406         Reviewed by Dimitri Glazkov.
2407
2408         Let shadow DOM have a list of nodes at the top level of a shadow.
2409         https://bugs.webkit.org/show_bug.cgi?id=57813
2410
2411         Adds ShadowRoot, a list of nodes, to be a parent for top-level
2412         shadow children. Forwards rendering through the root and into the
2413         host's renderer.
2414
2415         Covered by existing tests of elements that use this style of shadow.
2416
2417         * Android.mk: add ShadowRoot.h/cpp
2418         * CMakeLists.txt:
2419         * GNUmakefile.am:
2420         * WebCore.exp.in:
2421         * WebCore.gypi:
2422         * WebCore.pro:
2423         * WebCore.vcproj/WebCore.vcproj:
2424         * WebCore.xcodeproj/project.pbxproj:
2425         * css/CSSStyleSelector.cpp:
2426         (WebCore::CSSStyleSelector::initForStyleResolve): proxy style to host
2427         * dom/ContainerNode.cpp: parent nodes that are shadow roots are alive
2428         (WebCore::ContainerNode::insertBefore):
2429         (WebCore::ContainerNode::replaceChild):
2430         (WebCore::ContainerNode::removeChild):
2431         (WebCore::ContainerNode::appendChild):
2432         * dom/DocumentFragment.cpp:
2433         (WebCore::DocumentFragment::DocumentFragment):
2434         * dom/DocumentFragment.h:
2435         * dom/Element.cpp:
2436         (WebCore::Element::recalcStyle): look through ShadowRoots for host's style
2437         (WebCore::Element::shadowRoot): should be const
2438         (WebCore::Element::ensureShadowRoot): simpler than setShadowRoot
2439         * dom/Element.h:
2440         * dom/ElementRareData.h:
2441         * dom/Node.cpp:
2442         (WebCore::Node::parentNodeForRenderingAndStyle): indirection so
2443           ShadowRoot can forward to the host's renderer
2444         (WebCore::Node::createRendererAndStyle):
2445         (WebCore::Node::createRendererIfNeeded):
2446         * dom/Node.h:
2447         (WebCore::Node::isShadowBoundary): temporary, to differentiate
2448           old- and new-style, until all roots are ShadowRoot instances
2449         * dom/ShadowRoot.cpp: Added.
2450         (WebCore::ShadowRoot::ShadowRoot):
2451         (WebCore::ShadowRoot::recalcStyle): forward recalc to children
2452         * dom/ShadowRoot.h: Added.
2453         (WebCore::ShadowRoot::isShadowBoundary):
2454         (WebCore::ShadowRoot::create):
2455         * html/HTMLKeygenElement.cpp: use ensureShadowRoot
2456         (WebCore::HTMLKeygenElement::HTMLKeygenElement):
2457         (WebCore::HTMLKeygenElement::parseMappedAttribute):
2458         (WebCore::HTMLKeygenElement::appendFormData):
2459         (WebCore::HTMLKeygenElement::reset):
2460         (WebCore::HTMLKeygenElement::shadowSelect):
2461         * html/HTMLKeygenElement.h:
2462         * html/HTMLMeterElement.cpp: use ensureShadowRoot
2463         (WebCore::HTMLMeterElement::createShadowSubtree):
2464         * html/HTMLProgressElement.cpp: use ensureShadowRoot
2465         (WebCore::HTMLProgressElement::createShadowSubtree):
2466         * html/InputType.cpp: use ensureShadowRoot
2467         (WebCore::InputType::destroyShadowSubtree):
2468         * html/RangeInputType.cpp: use ensureShadowRoot
2469         (WebCore::RangeInputType::handleMouseDownEvent):
2470         (WebCore::RangeInputType::createShadowSubtree):
2471         (WebCore::RangeInputType::valueChanged):
2472         (WebCore::RangeInputType::shadowSliderThumb):
2473         * html/RangeInputType.h:
2474         * html/ValidationMessage.cpp: use ensureShadowRoot
2475         (WebCore::ValidationMessage::buildBubbleTree):
2476         (WebCore::ValidationMessage::deleteBubbleTree):
2477         * html/shadow/SliderThumbElement.cpp:
2478         (WebCore::SliderThumbElement::setPositionFromPoint):
2479         (WebCore::SliderThumbElement::hostInput):
2480         * html/shadow/SliderThumbElement.h:
2481         * rendering/MediaControlElements.cpp: use ensureShadowRoot
2482         (WebCore::MediaControlInputElement::attach):
2483         (WebCore::MediaControlInputElement::updateStyle):
2484         * rendering/RenderSlider.cpp: use ensureShadowRoot
2485         (WebCore::RenderSlider::thumbRect):
2486         (WebCore::RenderSlider::layout):
2487         (WebCore::RenderSlider::shadowSliderThumb):
2488         (WebCore::RenderSlider::inDragMode):
2489         * rendering/RenderSlider.h:
2490
2491 2011-04-07  Maciej Stachowiak  <mjs@apple.com>
2492
2493         Reviewed by Simon Fraser.
2494
2495         REGRESSION (r80871): Crash when visiting http://broadband.biglobe.ne.jp/
2496         https://bugs.webkit.org/show_bug.cgi?id=56297
2497         <rdar://problem/9131597>
2498
2499         Test: fast/css-generated-content/table-row-after-no-crash.html
2500
2501         * rendering/RenderTableRow.cpp:
2502         (WebCore::RenderTableRow::styleDidChange): Factor out generation of before/after
2503         content, and only do it if the row already has a parent. For construction of
2504         anonymous cells to work correctly, the row needs to already have a parent, so
2505         in that case wait a bit.
2506         (WebCore::RenderTableRow::updateBeforeAndAfterContent): Factored out to here.
2507         * rendering/RenderTableRow.h:
2508         * rendering/RenderTableSection.cpp:
2509         (WebCore::RenderTableSection::addChild): When adding a row, update its
2510         before/after content, in case it had any.
2511
2512 2011-04-07  Beth Dakin  <bdakin@apple.com>
2513
2514         Reviewed by Simon Fraser.
2515
2516         Probable fix for <rdar://problem/9251443>  Crashing on exception: -
2517         [ScrollAnimationHelperDelegate _pixelAlignProposedScrollPosition:]: unrecognized 
2518         selector sent to instance ADDRESS.
2519
2520        Need to implement new delegate method.
2521         * platform/mac/ScrollAnimatorMac.mm:
2522         (-[ScrollAnimationHelperDelegate _pixelAlignProposedScrollPosition:]):
2523
2524 2011-04-07  Ian Henderson  <ianh@apple.com>
2525
2526         Reviewed by Simon Fraser.
2527
2528         Optimize filling rounded rects that are actually ellipses
2529         https://bugs.webkit.org/show_bug.cgi?id=58098
2530
2531         In CG, drawing an ellipse directly is faster than constructing and
2532         filling a rounded rect path.  Detect when the given rounded rect is
2533         actually an ellipse and draw it directly in this case.
2534
2535         * platform/graphics/cg/GraphicsContextCG.cpp:
2536         (WebCore::GraphicsContext::fillRoundedRect):
2537
2538 2011-04-07  Ned Holbrook  <nholbrook@apple.com>
2539
2540         Reviewed by Dan Bernstein.
2541
2542         CTLine objects should outlive their CTRuns
2543         https://bugs.webkit.org/show_bug.cgi?id=58063
2544
2545         * platform/graphics/mac/ComplexTextController.h: Add m_coreTextLines, to be destroyed after m_complexTextRuns.
2546         * platform/graphics/mac/ComplexTextControllerCoreText.cpp:
2547         (WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun): Moot m_coreTextRun.
2548         (WebCore::ComplexTextController::collectComplexTextRunsForCharactersCoreText): Append line to m_coreTextLines.
2549
2550 2011-04-07  Nat Duca  <nduca@chromium.org>
2551
2552         Reviewed by David Levin.
2553
2554         [chromium] Compositor thread infrastructure
2555         https://bugs.webkit.org/show_bug.cgi?id=56131
2556
2557         Introduce chrome compositor thread and related
2558         infrastructure.
2559
2560         * WebCore.gypi:
2561         * platform/graphics/chromium/cc/CCMainThread.cpp: Added.
2562         (WebCore::CCMainThread::performTask):
2563         (WebCore::CCMainThread::postTask):
2564         * platform/graphics/chromium/cc/CCMainThread.h: Added.
2565         (WebCore::CCMainThread::Task::~Task):
2566         (WebCore::CCMainThread::Task::instance):
2567         (WebCore::CCMainThread::Task::Task):
2568         * platform/graphics/chromium/cc/CCMainThreadTask.h: Added.
2569         (WebCore::MainThreadTask0::create):
2570         (WebCore::MainThreadTask0::MainThreadTask0):
2571         (WebCore::MainThreadTask0::performTask):
2572         (WebCore::MainThreadTask1::create):
2573         (WebCore::MainThreadTask1::MainThreadTask1):
2574         (WebCore::MainThreadTask1::performTask):
2575         (WebCore::MainThreadTask2::create):
2576         (WebCore::MainThreadTask2::MainThreadTask2):
2577         (WebCore::MainThreadTask2::performTask):
2578         (WebCore::MainThreadTask3::create):
2579         (WebCore::MainThreadTask3::MainThreadTask3):
2580         (WebCore::MainThreadTask3::performTask):
2581         (WebCore::createMainThreadTask):
2582         * platform/graphics/chromium/cc/CCThread.cpp: Added.
2583         (WebCore::CCThread::create):
2584         (WebCore::CCThread::CCThread):
2585         (WebCore::CCThread::~CCThread):
2586         (WebCore::CCThread::postTask):
2587         (WebCore::CCThread::compositorThreadStart):
2588         (WebCore::CCThread::runLoop):
2589         * platform/graphics/chromium/cc/CCThread.h: Added.
2590         (WebCore::CCThread::Task::~Task):
2591         (WebCore::CCThread::Task::instance):
2592         (WebCore::CCThread::Task::Task):
2593         (WebCore::CCThread::threadID):
2594         (WebCore::CCCompletionEvent::CCCompletionEvent):
2595         (WebCore::CCCompletionEvent::~CCCompletionEvent):
2596         (WebCore::CCCompletionEvent::wait):
2597         (WebCore::CCCompletionEvent::signal):
2598         * platform/graphics/chromium/cc/CCThreadTask.h: Added.
2599         (WebCore::CCThreadTask0::create):
2600         (WebCore::CCThreadTask0::CCThreadTask0):
2601         (WebCore::CCThreadTask0::performTask):
2602         (WebCore::CCThreadTask1::create):
2603         (WebCore::CCThreadTask1::CCThreadTask1):
2604         (WebCore::CCThreadTask1::performTask):
2605         (WebCore::CCThreadTask2::create):
2606         (WebCore::CCThreadTask2::CCThreadTask2):
2607         (WebCore::CCThreadTask2::performTask):
2608         (WebCore::CCThreadTask3::create):
2609         (WebCore::CCThreadTask3::CCThreadTask3):
2610         (WebCore::CCThreadTask3::performTask):
2611         (WebCore::createCCThreadTask):
2612
2613 2011-04-07  Ryosuke Niwa  <rniwa@webkit.org>
2614
2615         Reviewed by Eric Seidel.
2616
2617         REGRESSION (r46914, r48764): When typing in Mail, line wrapping frequently occurs in the middle of words
2618         https://bugs.webkit.org/show_bug.cgi?id=57872
2619
2620         r46914 initially introduced a regression by replacing calls to styleAtPosition by editingStyleAtPosition
2621         because editingStyleAtPosition did not avoid tab span to obtain the computed style unlike styleAtPosition.
2622
2623         r46914 also introduced a regression by cloning hierarchy under new block at the insertion position without
2624         avoiding the tab span.
2625
2626         Fixed the both regressions by avoiding tab spans when computing the editing style and when cloning hierarchy.
2627         Also reverted r46914 for the general code path because re-creating node hierarchy duplicates nodes when
2628         we're moving nodes after the paragraph separator. Instead, we now split the tree up until the start block
2629         before moving the nodes.
2630
2631         Tests: editing/inserting/insert-paragraph-after-tab-span-and-text.html
2632                editing/inserting/insert-paragraph-separator-tab-span.html
2633
2634         * editing/DeleteSelectionCommand.cpp:
2635         (WebCore::DeleteSelectionCommand::saveTypingStyleState): Since EditingStyle's constructor avoids a tab span,
2636         no longer calls positionBeforeTabSpan on the position passed to EditingStyle's constructor.
2637         * editing/EditingStyle.cpp:
2638         (WebCore::EditingStyle::init): Always avoid a tab span when computing the editing style.
2639         * editing/InsertParagraphSeparatorCommand.cpp:
2640         (WebCore::InsertParagraphSeparatorCommand::doApply): Avoid cloning tab spans and inserting a paragraph
2641         separator into a paragraph separator.
2642         * editing/htmlediting.cpp:
2643         (WebCore::positionOutsideTabSpan): Renamed from positionBeforeTabSpan. Also returns the position in the parent
2644         node after the tab span if the position was at the end of the tab span.
2645         * editing/htmlediting.h:
2646
2647 2011-04-07  Jia Pu  <jpu@apple.com>
2648
2649         Reviewed by Darin Adler.
2650
2651         [Mac] Editor::setComposition() should not trigger correction panel timer.
2652         https://bugs.webkit.org/show_bug.cgi?id=58049
2653          <rdar://problem/9226305>
2654
2655         On Mac OS X that supports autocorrection panel, typing unconfirmed composition (i.e. unconfirmed Japanese or Chinese input)
2656         should not start autocorrection timer. We added a member variable, m_shouldPreventSpellChecking, to TypingCommand. 
2657         When this value is true, markMisspellingsAfterTyping() will not be called in TypingCommand::typingAddedToOpenCommand().
2658         m_shouldPreventSpellChecking is set to true in the TypingCommand objects created by Editor::setComposition().
2659
2660         No new tests. No deterministically reproducible test case. Patch is based on static code analysis. Testing this also requires firing
2661         autocorrection panel timer, which can not be easily done in automated fashion.
2662
2663         * editing/Editor.cpp:
2664         (WebCore::Editor::deleteWithDirection):
2665         (WebCore::Editor::insertTextWithoutSendingTextEvent):
2666         (WebCore::Editor::confirmComposition):
2667         (WebCore::Editor::setComposition):
2668         * editing/EditorCommand.cpp:
2669         (WebCore::executeDelete):
2670         * editing/TypingCommand.cpp:
2671         (WebCore::TypingCommand::TypingCommand):
2672         (WebCore::TypingCommand::deleteSelection):
2673         (WebCore::TypingCommand::deleteKeyPressed):
2674         (WebCore::TypingCommand::forwardDeleteKeyPressed):
2675         (WebCore::TypingCommand::insertText):
2676         (WebCore::TypingCommand::insertLineBreak):
2677         (WebCore::TypingCommand::insertParagraphSeparator):
2678         (WebCore::TypingCommand::typingAddedToOpenCommand):
2679         * editing/TypingCommand.h:
2680         (WebCore::TypingCommand::create):
2681         (WebCore::TypingCommand::setShouldPreventSpellChecking):
2682
2683 2011-04-07  John Bauman  <jbauman@chromium.org>
2684
2685         Reviewed by Kenneth Russell.
2686
2687         clearIfComposited call is really slow
2688         https://bugs.webkit.org/show_bug.cgi?id=57999
2689
2690         Move getContextAttributes call after the if, so it isn't called nearly as often.
2691
2692         No new tests.
2693
2694         * html/canvas/WebGLRenderingContext.cpp:
2695         (WebCore::WebGLRenderingContext::clearIfComposited):
2696
2697 2011-04-07  Luke Macpherson   <macpherson@chromium.org>
2698
2699         Reviewed by Dimitri Glazkov.
2700
2701         Implement Backgroun and Mask properties in CSSStyleApplyProperty
2702         https://bugs.webkit.org/show_bug.cgi?id=57922
2703
2704         No tests added as no behavioral changes.
2705
2706         * css/CSSStyleApplyProperty.cpp:
2707         Added ApplyPropertyFillLayer test to handle Background and Mask CSS Properties.
2708         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
2709         Added constructor calls to set up:
2710           CSSPropertyBackgroundAttachment
2711           CSSPropertyBackgroundClip
2712           CSSPropertyWebkitBackgroundClip
2713           CSSPropertyWebkitBackgroundComposite
2714           CSSPropertyBackgroundOrigin
2715           CSSPropertyWebkitBackgroundOrigin
2716           CSSPropertyBackgroundSize
2717           CSSPropertyWebkitBackgroundSize
2718           CSSPropertyWebkitMaskAttachment
2719           CSSPropertyWebkitMaskClip
2720           CSSPropertyWebkitMaskComposite
2721           CSSPropertyWebkitMaskOrigin
2722           CSSPropertyWebkitMaskSize
2723         * css/CSSStyleApplyProperty.h:
2724         (WebCore::CSSStyleApplyProperty::setPropertyValue):
2725         Add function to specify an equivalent property value in the lookup table.
2726         * css/CSSStyleSelector.cpp:
2727         (WebCore::CSSStyleSelector::applyProperty):
2728         Remove sections now implemented by CSSStyleApplyProperty.
2729         * css/CSSStyleSelector.h:
2730         Make CSSStyleApplyProperty a friend class so that the mapFill* functions are accessible.
2731
2732 2011-04-04  Eric Seidel  <eric@webkit.org>
2733
2734         Reviewed by Ryosuke Niwa.
2735
2736         Split run storage out from BidiResolver into a new BidiRunList class
2737         https://bugs.webkit.org/show_bug.cgi?id=57764
2738
2739         Part of what makes BidiResolver and InlineIterator so difficult to understand
2740         (and bug 50912 so difficult to fix) is that BidiResolver is both a state machine
2741         for the Unicode Bidi Algorithm (UBA) as well as storage for the resulting
2742         BidiRuns from the algorithm.  This patch breaks the storage aspect off
2743         into its own class BidiRunList.
2744
2745         This patch is only a start.  It does not actually fix the problematic ownership
2746         relationship, but it does make it possible to fix such in a second patch.
2747
2748         The run pointers and addRun/prependRun, etc. were already a tightly coupled
2749         logical subset of the BidiResolver class, so moving them into their own class
2750         was both obvious and easy.  The only piece of logic I had to move was that
2751         deleteRuns() had a side-effect of setting the m_emptyRun bit on the resolver.
2752
2753         I believe this deleteRuns side-effect was only ever used for one place
2754         (right after findNextLineBreak) and that it's only needed because
2755         findNextLineBreak can sometimes create bidi runs.  Run creation appears to be
2756         an unintentional side-effect of how InlineIterator calls through to BidiResolver
2757         as part of bidiNext and not a desired effect of the code.  I have added the call
2758         to markCurrentRunEmpty to both places deleteRuns was called (where the resolver
2759         could get re-used) as a safety precaution.  We could replace both with ASSERTs
2760         in a later patch.
2761
2762         I suspect there may be a small performance win from further refactoring so that
2763         findNextLineBreak does not need to create BidiRuns.
2764
2765         As I commented in the code, callers should own their own BidiRunList which they
2766         pass to BidiResolver::createBidiRunsForLine.  I attempted to implement that in
2767         an earlier version of this patch, but it was too complicated with the current
2768         twisted dependencies between InlineIterator/bidiNext and InlineBidiResolver.
2769         raise/lowerExplicitEmbeddingLevel are called unconditionally
2770         from commitExplicitEmbedding (which is called by bidiNext) and expect to have
2771         access to a runs list even in cases where we don't want any runs (findNextLineBreak).
2772
2773         I also cleaned up some of the callers to pass around BidiRunList objects instead
2774         of InlineBidiResolvers now that they're separate objects.
2775
2776         * GNUmakefile.am:
2777         * WebCore.gypi:
2778         * WebCore.pro:
2779         * WebCore.vcproj/WebCore.vcproj:
2780         * WebCore.xcodeproj/project.pbxproj:
2781         * platform/graphics/GraphicsContext.cpp:
2782         (WebCore::GraphicsContext::drawBidiText):
2783         * platform/text/BidiResolver.h:
2784         (WebCore::BidiResolver::BidiResolver):
2785         (WebCore::BidiResolver::runs):
2786         (WebCore::BidiResolver::markCurrentRunEmpty):
2787         (WebCore::::appendRun):
2788         (WebCore::::lowerExplicitEmbeddingLevel):
2789         (WebCore::::raiseExplicitEmbeddingLevel):
2790         (WebCore::::reorderRunsFromLevels):
2791         (WebCore::::createBidiRunsForLine):
2792         * rendering/InlineIterator.h:
2793         (WebCore::InlineBidiResolver::appendRun):
2794         * rendering/RenderBlock.h:
2795         * rendering/RenderBlockLineLayout.cpp:
2796         (WebCore::createRun):
2797         (WebCore::RenderBlock::appendRunsForObject):
2798         (WebCore::reachedEndOfTextRenderer):
2799         (WebCore::RenderBlock::handleTrailingSpaces):
2800         (WebCore::RenderBlock::layoutInlineChildren):
2801
2802 2011-04-07  Naoki Takano  <takano.naoki@gmail.com>
2803
2804         Reviewed by Adam Barth.
2805
2806         [Chromium] Fix relocation problem of popup window which introduces autofill popup sometimes moves to screen's top left corner.
2807         https://bugs.webkit.org/show_bug.cgi?id=57911
2808         http://code.google.com/p/chromium/issues/detail?id=78073
2809
2810         Manual test added: manual-tests/autofill-popup-location.html
2811
2812         Originally only height is checked so that it introduces the bug.
2813         So I changed it to check both width and height as size.
2814
2815         * manual-tests/autofill-popup-location.html: Added.
2816         * platform/chromium/PopupMenuChromium.cpp:
2817         (WebCore::PopupContainer::refresh): Check window size between original and new before calling setFrameRect().
2818
2819 2011-04-07  Adam Barth  <abarth@webkit.org>
2820
2821         Reviewed by Eric Seidel.
2822
2823         Implement img-src style-src and font-src
2824         https://bugs.webkit.org/show_bug.cgi?id=58018
2825
2826         These are pretty straight forward given the rest of the infrastructure
2827         we've built so far.
2828
2829         Tests: http/tests/security/contentSecurityPolicy/image-allowed.html
2830                http/tests/security/contentSecurityPolicy/image-blocked.html
2831                http/tests/security/contentSecurityPolicy/style-allowed.html
2832                http/tests/security/contentSecurityPolicy/style-blocked.html
2833                http/tests/security/contentSecurityPolicy/xsl-allowed.php
2834                http/tests/security/contentSecurityPolicy/xsl-blocked.php
2835
2836         * loader/cache/CachedResourceLoader.cpp:
2837         (WebCore::CachedResourceLoader::canRequest):
2838         * page/ContentSecurityPolicy.cpp:
2839         (WebCore::ContentSecurityPolicy::allowImageFromSource):
2840         (WebCore::ContentSecurityPolicy::allowStyleFromSource):
2841         (WebCore::ContentSecurityPolicy::allowFontFromSource):
2842         (WebCore::ContentSecurityPolicy::addDirective):
2843         * page/ContentSecurityPolicy.h:
2844
2845 2011-04-07  David Levin  <levin@chromium.org>
2846
2847         Reviewed by Darin Adler.
2848
2849         Make IconSnapshot and PageURLRecord member variables private.
2850         https://bugs.webkit.org/show_bug.cgi?id=58080
2851
2852         No change in functionality so no new tests.
2853
2854         * loader/icon/IconDatabase.cpp:
2855         (WebCore::IconDatabase::writeToDatabase): Changed to used the accessor functions.
2856         (WebCore::IconDatabase::writeIconSnapshotToSQLDatabase): Ditto.
2857         * loader/icon/IconRecord.h:
2858         (WebCore::IconSnapshot::IconSnapshot): Changed to use the new member variable names.
2859         (WebCore::IconSnapshot::iconURL): Expose the property.
2860         (WebCore::IconSnapshot::timestamp): Ditto.
2861         (WebCore::IconSnapshot::data): Ditto.
2862         * loader/icon/PageURLRecord.h:
2863         (WebCore::PageURLSnapshot::PageURLSnapshot): Changed to use the new member variable names.
2864         (WebCore::PageURLSnapshot::pageURL): Expose the property.
2865         (WebCore::PageURLSnapshot::iconURL): Ditto.
2866
2867 2011-04-07  Dan Bernstein  <mitz@apple.com>
2868
2869         Build fix.
2870
2871         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2872         (WebCore::GraphicsContext::roundToDevicePixels):
2873
2874 2011-04-07  Eric Seidel  <eric@webkit.org>
2875
2876         Reviewed by Adam Barth.
2877
2878         Add stub support for generating Gtk build system from gyp
2879         https://bugs.webkit.org/show_bug.cgi?id=58086
2880
2881         This does not produce a buildable WebCore, but it
2882         does allow running gyp/configure --port=gtk and having
2883         it generate a gtk.Makefile which we can use for testing
2884         the rest of the plumbing.
2885
2886         * gyp/gtk.gyp: Added.
2887
2888 2011-04-07  David Hyatt  <hyatt@apple.com>
2889
2890         Reviewed by Dan Bernstein.
2891
2892         https://bugs.webkit.org/show_bug.cgi?id=57736
2893         
2894         Crash on openstreetmap.org while using the map. Fix a bad interaction between the positioned movement layout
2895         optimization and the simplified layout optimization that could lead to blocks remaining marked as dirty when
2896         layout finished. This would eventually lead to an inability to properly determine the correct layout root and
2897         would cause a deleted root to be used later on.
2898
2899         Added fast/block/positioning/complex-positioned-movement.html.
2900
2901         * page/FrameView.cpp:
2902         (WebCore::FrameView::scheduleRelayoutOfSubtree):
2903         Add asserts to catch cases in the future where a layout root is set that has a dirty containing block.
2904     
2905         * rendering/RenderBlock.cpp:
2906         (WebCore::RenderBlock::simplifiedLayout):
2907         Change simplified layout so that the positioned movement optimization no longer clears the other layout
2908         flags. This will ensure that we still lay out our descendants if they need it.
2909         
2910         (WebCore::RenderBlock::layoutPositionedObjects):
2911         Changed to clear our layout flags now if the positioned movement is successful, since tryLayoutDoingPositionedMovementOnly
2912         no longer does the clear.
2913     
2914         * rendering/RenderBox.h:
2915         (WebCore::RenderBox::tryLayoutDoingPositionedMovementOnly):
2916         tryLayoutDoingPositionedMovementOnly now returns a boolean indicating success or failure.  On success it no longer
2917         does setNeedsLayout(false), but instead will let the caller take care of it. This way the caller can still look at
2918         the other flags in case other kinds of layout are still needed.
2919     
2920         * rendering/RenderObject.h:
2921         (WebCore::RenderObject::setNeedsPositionedMovementLayout):
2922         (WebCore::RenderObject::setNeedsSimplifiedNormalFlowLayout):
2923         Changed these methods to only set their respective flags and not to try to be clever about avoiding propagation.
2924
2925 2011-04-07  Andrew Scherkus  <scherkus@chromium.org>
2926
2927         Revert ENABLE_TRACK patch due to compile failures.
2928
2929         * CMakeLists.txt:
2930         * Configurations/FeatureDefines.xcconfig:
2931         * DerivedSources.make:
2932         * GNUmakefile.am:
2933         * WebCore.gypi:
2934         * WebCore.xcodeproj/project.pbxproj:
2935         * features.pri:
2936         * html/HTMLAttributeNames.in:
2937         * html/HTMLTagNames.in:
2938         * html/HTMLTrackElement.cpp: Removed.
2939         * html/HTMLTrackElement.h: Removed.
2940         * html/HTMLTrackElement.idl: Removed.
2941
2942 2011-04-07  Dan Bernstein  <mitz@apple.com>
2943
2944         Reviewed by Simon Fraser.
2945
2946         <rdar://problem/9018212> Underline thickness is not uniform under non-integral scale factor
2947         https://bugs.webkit.org/show_bug.cgi?id=58083
2948
2949         Test: fast/text/decorations-transformed.html
2950
2951         * platform/graphics/GraphicsContext.h: Added a RoundingMode enum with two values. RoundAllSides
2952         is the existing rounding mode, where each side of the rectangle snaps to the nearest pixel
2953         gridline. RoundOriginAndDimensions snaps the origin to the nearest pixel gridpoint and rounds
2954         the width and the height. In this new mode, translating a rectangle in user space never changes
2955         its dimensions in device pixels.
2956         * platform/graphics/cg/GraphicsContextCG.cpp:
2957         (WebCore::GraphicsContext::roundToDevicePixels): Implemented RoundOriginAndDimensions.
2958         (WebCore::GraphicsContext::drawLineForText): Use RoundOriginAndDimensions, thus ensuring that
2959         all underlines have the same thickness in device pixels.
2960         * platform/graphics/openvg/GraphicsContextOpenVG.cpp:
2961         (WebCore::GraphicsContext::roundToDevicePixels): Added RoundingMode parameter, but did not implement it.
2962         * platform/graphics/qt/GraphicsContextQt.cpp:
2963         (WebCore::GraphicsContext::roundToDevicePixels): Ditto.
2964         * platform/graphics/skia/GraphicsContextSkia.cpp:
2965         (WebCore::GraphicsContext::roundToDevicePixels): Ditto.
2966         * platform/graphics/wince/GraphicsContextWinCE.cpp:
2967         (WebCore::GraphicsContext::roundToDevicePixels): Ditto.
2968         * platform/graphics/wx/GraphicsContextWx.cpp:
2969         (WebCore::GraphicsContext::roundToDevicePixels): Ditto.
2970         * rendering/InlineTextBox.cpp:
2971         (WebCore::InlineTextBox::paintDecoration):
2972
2973 2011-04-06  Vitaly Repeshko  <vitalyr@chromium.org>
2974
2975         Reviewed by Nate Chapin.
2976
2977         [V8] Remove custom DOMImplementation getter on Document.
2978         https://bugs.webkit.org/show_bug.cgi?id=57991
2979
2980         The custom getter is no longer required because DOMImplementation
2981         objects are now created per document.
2982
2983         Test: fast/dom/DOMImplementation/implementation-identity.html
2984
2985         * bindings/scripts/CodeGeneratorV8.pm:
2986         * bindings/v8/custom/V8DocumentCustom.cpp:
2987         * dom/Document.idl:
2988
2989 2011-04-07  Sergey Glazunov  <serg.glazunov@gmail.com>
2990
2991         Reviewed by Dimitri Glazkov.
2992
2993         setHasID() is only called for styled elements
2994         https://bugs.webkit.org/show_bug.cgi?id=57267
2995
2996         Test: fast/dom/non-styled-element-id-crash.html
2997
2998         * dom/Element.cpp:
2999         (WebCore::Element::attributeChanged):
3000         (WebCore::Element::idAttributeChanged):
3001         * dom/Element.h:
3002         * dom/StyledElement.cpp:
3003         (WebCore::StyledElement::parseMappedAttribute):
3004
3005 2011-04-07  Jer Noble  <jer.noble@apple.com>
3006
3007         Reviewed by Eric Carlson.
3008
3009         HTMLVideoElement::webkitEnterFullscreen does not use new Full Screen API when available.
3010         https://bugs.webkit.org/show_bug.cgi?id=58070
3011
3012         Make the HTMLMediaElement full screen functions call into the new Full Screen API when
3013         FULLSCREEN_API is enabled.
3014
3015         * html/HTMLMediaElement.cpp:
3016         (WebCore::HTMLMediaElement::enterFullscreen):
3017         (WebCore::HTMLMediaElement::exitFullscreen):
3018
3019 2011-04-07  Adam Barth  <abarth@webkit.org>
3020
3021         Reviewed by Eric Seidel.
3022
3023         Implement CSP's options directive
3024         https://bugs.webkit.org/show_bug.cgi?id=58014
3025
3026         This patch contains the full options parser, but we only have enough of
3027         CSP implemented to see the effects of disable-xss-protection.  Will
3028         need to do some more work before we can see eval-script in action.
3029
3030         Tests: http/tests/security/contentSecurityPolicy/inline-script-allowed.html
3031                http/tests/security/contentSecurityPolicy/inline-script-blocked-goofy.html
3032
3033         * page/ContentSecurityPolicy.cpp:
3034         (WebCore::CSPOptions::CSPOptions):
3035         (WebCore::CSPOptions::disableXSSProtection):
3036         (WebCore::CSPOptions::evalScript):
3037         (WebCore::CSPOptions::parse):
3038         (WebCore::ContentSecurityPolicy::allowJavaScriptURLs):
3039         (WebCore::ContentSecurityPolicy::allowInlineEventHandlers):
3040         (WebCore::ContentSecurityPolicy::allowInlineScript):
3041         (WebCore::ContentSecurityPolicy::addDirective):
3042         * page/ContentSecurityPolicy.h:
3043
3044 2011-04-07  Alexey Proskuryakov  <ap@apple.com>
3045
3046         Reviewed by Anders Carlsson.
3047
3048         REGRESSION (WebKit2): Reverse conversion doesn't work in Kotoeri
3049         https://bugs.webkit.org/show_bug.cgi?id=58066
3050         <rdar://problem/8965302>
3051
3052         * platform/mac/HTMLConverter.h:
3053         * platform/mac/HTMLConverter.mm: (+[WebHTMLConverter editingAttributedStringFromRange:]):
3054         Changed editingAttributedStringFromRange: to use WebCore::Range instead of DOMRange, since
3055         it's now used in WebKit2.
3056
3057 2011-04-07  Andy Estes  <aestes@apple.com>
3058
3059         Reviewed by Darin Adler.
3060
3061         REGRESSION (r64712): Microsoft Outlook 2011: original message contents
3062         not included when replying to an email.
3063         https://bugs.webkit.org/show_bug.cgi?id=57794
3064         
3065         * WebCore.exp.in:
3066         * loader/FrameLoader.cpp:
3067         (WebCore::FrameLoader::finishedParsing): Call Frame::injectUserScripts()
3068         before checking if the FrameLoader is parsing the initial empty document.
3069         This allows user scripts to be injected at the end of document parsing
3070         (if the setting is enabled).
3071         * page/Frame.cpp:
3072         (WebCore::Frame::injectUserScripts): Do not inject scripts if this
3073         feature is disabled on the initial empty document.
3074         * page/Settings.cpp:
3075         (WebCore::Settings::Settings):
3076         * page/Settings.h: Add a setting for injecting user scripts into the
3077         initial empty document (defaults to false).
3078         (WebCore::Settings::setInjectUserScriptsInInitialEmptyDocument):
3079         (WebCore::Settings::injectUserScriptsInInitialEmptyDocument):
3080         * platform/mac/RuntimeApplicationChecks.h:
3081         * platform/mac/RuntimeApplicationChecks.mm:
3082         (WebCore::applicationIsMicrosoftOutlook): Check if the embedding
3083         application is Microsoft Outlook.
3084
3085 2011-04-06  Jer Noble  <jer.noble@apple.com>
3086
3087         Reviewed by Maciej Stachowiak.
3088
3089         AVF: MediaPlayerPrivateAVFoundation never reaches playable state.
3090         https://bugs.webkit.org/show_bug.cgi?id=57962
3091
3092         Add support for a new AVPlayerItem API which will notify clients when their
3093         seek completes.  This requires a new Notification type to be passed to the main
3094         thread in MediaPlayerPrivateAVFoundation.
3095
3096         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
3097         (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted): Added.
3098         (WebCore::MediaPlayerPrivateAVFoundation::scheduleMainThreadNotification): Added two new
3099             overloaded functions which take a Notification; and a Notification::Type and boolean.
3100         (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification): Support new SeekCompleted 
3101             Notification type.
3102         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
3103         (WebCore::MediaPlayerPrivateAVFoundation::Notification::Notification): Added one new constructor.
3104         (WebCore::MediaPlayerPrivateAVFoundation::Notification::finished): Added ivar and accessor.
3105         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
3106         (WebCore::MediaPlayerPrivateAVFoundationObjC::seekToTime): Call new AVPlayerItem API.
3107         (-[WebCoreAVFMovieObserver seekCompleted:]): Added.
3108
3109 2011-04-07  Nancy Piedra  <nancy.piedra@nokia.com>
3110
3111         Reviewed by Eric Carlson.
3112
3113         Parse quotes from content type parameters
3114         https://bugs.webkit.org/show_bug.cgi?id=53275
3115
3116         This functionality is tested in video-can-play-type.html layout test
3117         where I've added codecs parameter with good and bad formatting.
3118
3119         * platform/ContentType.cpp:
3120         (WebCore::ContentType::parameter):
3121
3122 2011-04-07  Pavel Feldman  <pfeldman@google.com>
3123
3124         Reviewed by Yury Semikhatsky.
3125
3126         Web Inspector: remove "enabled" from the setBreakpoint protocol.
3127         https://bugs.webkit.org/show_bug.cgi?id=58047
3128
3129         * bindings/js/ScriptDebugServer.cpp:
3130         (WebCore::ScriptDebugServer::hasBreakpoint):
3131         * bindings/v8/DebuggerScript.js:
3132         ():
3133         * bindings/v8/ScriptDebugServer.cpp:
3134         (WebCore::ScriptDebugServer::setBreakpoint):
3135         * inspector/Inspector.json:
3136         * inspector/InspectorDebuggerAgent.cpp:
3137         (WebCore::buildObjectForBreakpointCookie):
3138         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
3139         (WebCore::InspectorDebuggerAgent::setBreakpoint):
3140         (WebCore::InspectorDebuggerAgent::continueToLocation):
3141         (WebCore::InspectorDebuggerAgent::didParseSource):
3142         * inspector/InspectorDebuggerAgent.h:
3143         * inspector/ScriptBreakpoint.h:
3144         (WebCore::ScriptBreakpoint::ScriptBreakpoint):
3145         * inspector/front-end/DebuggerModel.js:
3146         (WebInspector.DebuggerModel.prototype.setBreakpoint):
3147         (WebInspector.DebuggerModel.prototype.setBreakpointBySourceId):
3148         * inspector/front-end/DebuggerPresentationModel.js:
3149         (WebInspector.DebuggerPresentationModel):
3150         (WebInspector.DebuggerPresentationModel.prototype._restoreBreakpoints):
3151         (WebInspector.DebuggerPresentationModel.prototype._updateBreakpointsAfterLiveEdit):
3152         (WebInspector.DebuggerPresentationModel.prototype.setBreakpoint.callback):
3153         (WebInspector.DebuggerPresentationModel.prototype.setBreakpoint):
3154         (WebInspector.DebuggerPresentationModel.prototype._setBreakpointInDebugger):
3155         (WebInspector.DebuggerPresentationModel.prototype._setBreakpointInDebugger.didRequestSourceMapping):
3156         (WebInspector.DebuggerPresentationModel.prototype._removeBreakpointFromDebugger):
3157         (WebInspector.DebuggerPresentationModel.prototype.setBreakpointEnabled.afterUpdate):
3158         (WebInspector.DebuggerPresentationModel.prototype.setBreakpointEnabled):
3159         (WebInspector.DebuggerPresentationModel.prototype.updateBreakpoint):
3160         (WebInspector.DebuggerPresentationModel.prototype.removeBreakpoint):
3161         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded.didRequestSourceMapping):
3162         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded):
3163         (WebInspector.DebuggerPresentationModel.prototype._breakpointRemoved):
3164         (WebInspector.DebuggerPresentationModel.prototype._breakpointResolved):
3165         (WebInspector.DebuggerPresentationModel.prototype._restoreBreakpointsFromSettings):
3166         (WebInspector.DebuggerPresentationModel.prototype._saveBreakpoints):
3167         (WebInspector.DebuggerPresentationModel.prototype._reset):
3168         (WebInspector.PresentationBreakpoint):
3169
3170 2011-04-07  Dan Bernstein  <mitz@apple.com>
3171
3172         Reviewed by Adam Roben.
3173
3174         Removed a redundant line of code.
3175
3176         * rendering/RenderInline.cpp:
3177         (WebCore::RenderInline::updateAlwaysCreateLineBoxes): No need to compare line gap values, as
3178         this is covered by the earlier hasIdenticalAscentDescentAndLineGap() check.
3179
3180 2011-04-07  Liang Qi  <liang.qi@nokia.com>
3181
3182         Reviewed by Laszlo Gombos.
3183
3184         [Qt][Symbian] Enable webkit build with GCCE on Symbian.
3185         https://bugs.webkit.org/show_bug.cgi?id=57841
3186
3187         * WebCore.pri: Thanks for Norbert Leser  <norbert.leser@nokia.com> who checked RVCT part.
3188         --rw-base value in QMAKE_LFLAGS.ARMCC and -Tdata value in QMAKE_LFLAGS.GCCE are updated
3189         to 0x1000000 together. They need to be updated in the future when WebKit grows.
3190
3191 2011-04-06  Pavel Feldman  <pfeldman@google.com>
3192
3193         Reviewed by Yury Semikhatsky.
3194
3195         Web Inspector: get rid of Breakpoint.js.
3196         https://bugs.webkit.org/show_bug.cgi?id=57949
3197
3198         * WebCore.gypi:
3199         * WebCore.vcproj/WebCore.vcproj:
3200         * inspector/front-end/Breakpoint.js: Removed.
3201         * inspector/front-end/BreakpointsSidebarPane.js:
3202         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.addBreakpoint):
3203         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.updateBreakpoint.didLoadSnippet):
3204         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.updateBreakpoint):
3205         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._compareBreakpoints):
3206         * inspector/front-end/DebuggerModel.js:
3207         (WebInspector.DebuggerModel):
3208         (WebInspector.DebuggerModel.prototype._debuggerWasDisabled):
3209         (WebInspector.DebuggerModel.prototype.setBreakpoint.didSetBreakpoint):
3210         (WebInspector.DebuggerModel.prototype.setBreakpoint):
3211         (WebInspector.DebuggerModel.prototype.setBreakpointBySourceId):
3212         (WebInspector.DebuggerModel.prototype.removeBreakpoint):
3213         (WebInspector.DebuggerModel.prototype._breakpointResolved):
3214         (WebInspector.DebuggerModel.prototype.reset):
3215         * inspector/front-end/DebuggerPresentationModel.js:
3216         (WebInspector.DebuggerPresentationModel):
3217         (WebInspector.DebuggerPresentationModel.prototype._refreshBreakpoints):
3218         (WebInspector.DebuggerPresentationModel.prototype._updateBreakpointsAfterLiveEdit):
3219         (WebInspector.DebuggerPresentationModel.prototype.toggleFormatSourceFiles):
3220         (WebInspector.DebuggerPresentationModel.prototype.setBreakpoint.didSetBreakpoint):
3221         (WebInspector.DebuggerPresentationModel.prototype.setBreakpoint):
3222         (WebInspector.DebuggerPresentationModel.prototype.setBreakpointEnabled):
3223         (WebInspector.DebuggerPresentationModel.prototype.updateBreakpoint):
3224         (WebInspector.DebuggerPresentationModel.prototype.removeBreakpoint):
3225         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded.didRequestSourceMapping):
3226         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded):
3227         (WebInspector.DebuggerPresentationModel.prototype._breakpointRemoved):
3228         (WebInspector.DebuggerPresentationModel.prototype._breakpointResolved):
3229         (WebInspector.DebuggerPresentationModel.prototype._restoreBreakpoints):
3230         (WebInspector.DebuggerPresentationModel.prototype._restoreBreakpoint):
3231         (WebInspector.DebuggerPresentationModel.prototype._saveBreakpoints):
3232         (WebInspector.DebuggerPresentationModel.prototype._reset):
3233         (WebInspector.PresentationBreakpoint):
3234         (WebInspector.PresentationBreakpoint.prototype.get sourceFile):
3235         (WebInspector.PresentationBreakpoint.prototype.get url):
3236         (WebInspector.PresentationBreakpoint.prototype.get resolved):
3237         (WebInspector.PresentationBreakpoint.prototype.loadSnippet):
3238         * inspector/front-end/ResourceTreeModel.js:
3239         (WebInspector.ResourceTreeModel):
3240         (WebInspector.ResourceTreeModel.prototype._onResourceStarted):
3241         (WebInspector.ResourceTreeModel.prototype._addResourceToFrame):
3242         * inspector/front-end/ScriptsPanel.js:
3243         (WebInspector.ScriptsPanel):
3244         (WebInspector.ScriptsPanel.prototype._breakpointUpdated):
3245         (WebInspector.ScriptsPanel.prototype.reset):
3246         * inspector/front-end/WebKit.qrc:
3247         * inspector/front-end/inspector.html:
3248
3249 2011-04-07  Yury Semikhatsky  <yurys@chromium.org>
3250
3251         Reviewed by Pavel Feldman.
3252
3253         Web Inspector: console messages names should adhere to the common naming style
3254         https://bugs.webkit.org/show_bug.cgi?id=58042
3255
3256         * inspector/ConsoleMessage.cpp:
3257         (WebCore::ConsoleMessage::addToFrontend):
3258         (WebCore::ConsoleMessage::updateRepeatCountInConsole):
3259         * inspector/Inspector.json:
3260         * inspector/InspectorConsoleAgent.cpp:
3261         (WebCore::InspectorConsoleAgent::clearConsoleMessages):
3262         * inspector/front-end/ConsoleView.js:
3263         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.messageAdded):
3264         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.messageRepeatCountUpdated):
3265         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.messagesCleared):
3266         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher):
3267
3268 2011-04-06  Ilya Tikhonovsky  <loislo@chromium.org>
3269
3270         Reviewed by Yury Semikhatsky.
3271
3272         Web Inspector: migrate Inspector protocol messages format to JSON-RPC.
3273         https://bugs.webkit.org/show_bug.cgi?id=57957
3274
3275         There is not a significant difference between  inspector messages spec and and JSON-RPC 2.0 messages spec.
3276         Also JSON-RPC has a pretty clear specification for error descriptions which we haven't.
3277         It was decided that we will use it.
3278
3279         the list of renames:
3280         1) type-> /dev/null
3281         2) domain + '.' + event => method // for events
3282         3) domain + '.' + command => method // for requests
3283         4) requestId => id // for responses
3284         5) arguments => params // for requests
3285         6) data => params // for events
3286         7) body => result // for responses
3287
3288         protocolErrors and error properties will be converted to JSON-RPC error format.
3289         The order of properties in messages also will be adjusted.
3290         The only thing that looks unnecessary is jsonrpc property.
3291
3292         * inspector/CodeGeneratorInspector.pm:
3293
3294 2011-04-07  Ryosuke Niwa  <rniwa@webkit.org>
3295
3296         Reviewed by Eric Seidel.
3297
3298         Add functions to update left and right offsets to LineOffsets
3299         https://bugs.webkit.org/show_bug.cgi?id=58028
3300
3301         Added update() and shrinkWidthForNewFloatIfNeeded(FloatingObject*) to LineOffsets,
3302         which are used to update m_left and m_right. Also added m_block and m_isFirstLine
3303         member variables to LineOffsets so that users of LineOffsets don't have to pass them around.
3304
3305         * rendering/RenderBlock.h:
3306         * rendering/RenderBlockLineLayout.cpp:
3307         (WebCore::RenderBlock::skipLeadingWhitespace): No longer passes firstLine to positionNewFloatOnLine.
3308         (WebCore::LineOffsets::LineOffsets): Takes RenderBlock* and isFirstLine instead of left and right offsets.
3309         (WebCore::LineOffsets::update): Extracted from findNextLineBreak and positionNewFloatOnLine.
3310         (WebCore::LineOffsets::shrinkWidthForNewFloatIfNeeded): Extracted from positionNewFloatOnLine.
3311         (WebCore::RenderBlock::findNextLineBreak): Calls skipLeadingWhitespace and positionNewFloatOnLine.
3312         (WebCore::RenderBlock::positionNewFloatOnLine): Calls shrinkWidthForNewFloatIfNeeded and update and
3313         no longer passes firstLine around.
3314
3315 2011-04-06  Pavel Feldman  <pfeldman@google.com>
3316
3317         Reviewed by Yury Semikhatsky.
3318
3319         Web Inspector: migrate debugger domain to the unified breakpoint location notion.
3320         https://bugs.webkit.org/show_bug.cgi?id=57928
3321
3322         * inspector/Inspector.json:
3323         * inspector/InspectorDebuggerAgent.cpp:
3324         (WebCore::buildObjectForBreakpointCookie):
3325         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
3326         (WebCore::InspectorDebuggerAgent::setBreakpoint):
3327         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
3328         (WebCore::InspectorDebuggerAgent::didParseSource):
3329         * inspector/InspectorDebuggerAgent.h:
3330         * inspector/front-end/Breakpoint.js:
3331         (WebInspector.Breakpoint):
3332         * inspector/front-end/DebuggerModel.js:
3333         (WebInspector.DebuggerModel.prototype.setBreakpointBySourceId):
3334         (WebInspector.DebuggerModel.prototype._breakpointResolved):
3335
3336 2011-04-07  Andreas Kling  <andreas.kling@nokia.com>
3337
3338         Reviewed by Benjamin Poulain.
3339
3340         [Qt] Mask the QStyle::State_Horizontal hint for vertical scrollbars.
3341
3342         When initializing a QStyleOptionSlider from a widget, the State_Horizontal
3343         hint may get set depending on how that widget is laid out in its parent.
3344         If this happens when drawing a vertical scrollbar, the hint is never
3345         cleared and we end up painting a vertical scrollbar with horizontal arrows.
3346
3347         Covered by pixel tests which should no longer paint silly scrollbars.
3348
3349         * platform/qt/ScrollbarThemeQt.cpp:
3350         (WebCore::styleOptionSlider):
3351
3352 2011-04-07  Adam Barth  <abarth@webkit.org>
3353
3354         Reviewed by Eric Seidel.
3355
3356         script-src should block inline script
3357         https://bugs.webkit.org/show_bug.cgi?id=58012
3358
3359         Block inline scripts at the ScriptElement layer.  This should catch
3360         exactly the scripts we want to catch.
3361
3362         Test: http/tests/security/contentSecurityPolicy/inline-script-blocked.html
3363
3364         * dom/Document.cpp:
3365         (WebCore::Document::processHttpEquiv):
3366             - This patch also adds the ability to supply a CSP policy via a
3367               <meta> tag.  We'll update the name of the header once we've
3368               finished implementing the spec.
3369         * dom/ScriptElement.cpp:
3370         (WebCore::ScriptElement::executeScript):
3371         * page/ContentSecurityPolicy.cpp:
3372         (WebCore::ContentSecurityPolicy::allowInlineScript):
3373         * page/ContentSecurityPolicy.h:
3374
3375 2011-04-07  Alice Boxhall  <aboxhall@chromium.org>
3376
3377         Reviewed by Ryosuke Niwa.
3378
3379         Move the MouseEventWithHitTestResults::targetNode() method on to EventHandler.
3380         https://bugs.webkit.org/show_bug.cgi?id=57921
3381
3382         Moves the MouseEventWithHitTestResults::targetNode() method on to EventHandler, so
3383         that the same logic can be used for a HitTestResult.
3384
3385         No visible changes, just cleanup, so no tests.
3386
3387         * page/EventHandler.cpp:
3388         (WebCore::EventHandler::selectClosestWordFromMouseEvent):
3389         (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent):
3390         (WebCore::EventHandler::handleMousePressEventTripleClick):
3391         (WebCore::EventHandler::handleMousePressEventSingleClick):
3392         (WebCore::EventHandler::handleMousePressEvent):
3393         (WebCore::EventHandler::handleMouseDraggedEvent):
3394         (WebCore::EventHandler::handleMouseReleaseEvent):
3395         (WebCore::EventHandler::subframeForHitTestResult):
3396         Made public static member, so that it can access targetNode(), and be accessed by
3397         webkitwebview in gtk.
3398         (WebCore::EventHandler::selectCursor):
3399         (WebCore::EventHandler::targetNode):
3400         (WebCore::EventHandler::handleMouseDoubleClickEvent):
3401         (WebCore::EventHandler::handleMouseMoveEvent):
3402         (WebCore::EventHandler::updateDragAndDrop):
3403         (WebCore::EventHandler::sendContextMenuEvent):
3404         * page/EventHandler.h:
3405         * page/MouseEventWithHitTestResults.cpp:
3406         (WebCore::MouseEventWithHitTestResults::MouseEventWithHitTestResults):
3407         * page/MouseEventWithHitTestResults.h:
3408         * page/android/EventHandlerAndroid.cpp:
3409         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3410         * page/brew/EventHandlerBrew.cpp:
3411         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3412         * page/chromium/EventHandlerChromium.cpp:
3413         (WebCore::EventHandler::passMousePressEventToSubframe):
3414         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3415         * page/efl/EventHandlerEfl.cpp:
3416         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3417         * page/gtk/EventHandlerGtk.cpp:
3418         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3419         * page/haiku/EventHandlerHaiku.cpp:
3420         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3421         * page/mac/EventHandlerMac.mm:
3422         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3423         (WebCore::EventHandler::passSubframeEventToSubframe):
3424         * page/wx/EventHandlerWx.cpp:
3425         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
3426
3427 2011-04-07  Pavel Podivilov  <podivilov@chromium.org>
3428
3429         Reviewed by Pavel Feldman.
3430
3431         Web Inspector: build mapping for formatted scripts based on keywords positions.
3432         https://bugs.webkit.org/show_bug.cgi?id=57936
3433
3434         Mapping based on [\$\.\w]+ was not accurate because string literals representation
3435         may be different in original and formatted scripts.
3436
3437         * inspector/front-end/ScriptFormatterWorker.js:
3438         (buildMapping.regexp.b):
3439         (buildMapping):
3440
3441 2011-04-07  Kent Tamura  <tkent@chromium.org>
3442
3443         Reviewed by Dimitri Glazkov.
3444
3445         Spinbuttons become unclickable if right padding is large.
3446         https://bugs.webkit.org/show_bug.cgi?id=56298
3447
3448         An inner-spin-button is put on the right border and ignores right
3449         padding in RenderTextControlSingleLine::layout(), but forwardEvent()
3450         checks if a point is in an area just right of an internal text block.
3451         This inconsistency caused a bug that an inner-spin-button with large
3452         padding didn't receive mouse events.
3453
3454         To fix this bug, we render spin buttons as layers, and remove manual