c39ea5007bb36667e8a095eff795fb8c2537ced8
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-04-23  Kentaro Hara  <haraken@chromium.org>
2
3         [V8] Pass Isolate to toV8() (Part6)
4         https://bugs.webkit.org/show_bug.cgi?id=84273
5
6         Reviewed by Nate Chapin.
7
8         The objective is to pass Isolate to all toV8()s.
9         Since there are a lot of toV8()s, I'll make the change
10         step by step. This patch passes Isolate to toV8() in
11         several custom bindings.
12
13         No tests. No change in behavior.
14
15         * bindings/v8/custom/V8HTMLAllCollectionCustom.cpp:
16         (WebCore::getNamedItems):
17         (WebCore::getItem):
18         (WebCore::V8HTMLAllCollection::namedPropertyGetter):
19         (WebCore::V8HTMLAllCollection::itemCallback):
20         (WebCore::V8HTMLAllCollection::namedItemCallback):
21         (WebCore::V8HTMLAllCollection::callAsFunctionCallback):
22         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
23         (WebCore::getNamedItems):
24         (WebCore::V8HTMLCollection::namedPropertyGetter):
25         (WebCore::V8HTMLCollection::namedItemCallback):
26         (WebCore::toV8):
27         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
28         (WebCore::toV8):
29         * bindings/v8/custom/V8StyleSheetCustom.cpp:
30         (WebCore::toV8):
31         * bindings/v8/custom/V8StyleSheetListCustom.cpp:
32         (WebCore::V8StyleSheetList::namedPropertyGetter):
33         * bindings/v8/custom/V8TrackEventCustom.cpp:
34         (WebCore::V8TrackEvent::trackAccessorGetter):
35         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
36         (WebCore::toV8Object):
37         (WebCore::getObjectParameter):
38         (WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
39         (WebCore::V8WebGLRenderingContext::getExtensionCallback):
40         (WebCore::V8WebGLRenderingContext::getFramebufferAttachmentParameterCallback):
41         (WebCore::V8WebGLRenderingContext::getParameterCallback):
42         (WebCore::V8WebGLRenderingContext::getProgramParameterCallback):
43         (WebCore::V8WebGLRenderingContext::getShaderParameterCallback):
44         (WebCore::V8WebGLRenderingContext::getUniformCallback):
45         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
46         (WebCore::V8XMLHttpRequest::responseAccessorGetter):
47         * bindings/v8/custom/V8XSLTProcessorCustom.cpp:
48         (WebCore::V8XSLTProcessor::transformToFragmentCallback):
49         (WebCore::V8XSLTProcessor::transformToDocumentCallback):
50
51 2012-04-23  Kent Tamura  <tkent@chromium.org>
52
53         Move the content of LocalizedCalendarICU.cpp and LocalizedDateICU.cpp to ICULocale.cpp.
54         https://bugs.webkit.org/show_bug.cgi?id=84568
55
56         Reviewed by Hajime Morita.
57
58         Move it to ICULocal.cpp because we want to share UDateFormat
59         object in LocalizedDate functions and LocalizedCalendar functions,
60         and it becomes easier to cache the UDateFormat object, and making
61         unit tests for these functions easier.
62
63         No new tests because of no bahevior changes.
64
65         * platform/text/ICULocale.cpp:
66         (WebCore::ICULocale::ICULocale): Initialize new members.
67         (WebCore::ICULocale::~ICULocale): Delete m_shortDateFormat.
68         (WebCore::ICULocale::initializeShortDateFormat):
69         Moved from creteShortDateFormatter of LocalizedDateICU.cpp.
70         (WebCore::ICULocale::parseLocalizedDate):
71         Moved from LocalizedDate.cpp, use m_shortDateFormat.
72         (WebCore::ICULocale::formatLocalizedDate): ditto.
73         (WebCore::ICULocale::createLabelVector):
74         Moved from LocalizedCalendarICU.cpp, use m_shortDateFormat.
75         (WebCore::createFallbackMonthLabels): Moved from LocalizedCalendarICU.cpp.
76         (WebCore::createFallbackWeekDayShortLabels): ditto.
77         (WebCore::ICULocale::initializeCalendar):
78         lazy initialization of m_monthLabels, m_weekDayShortLabels, and m_firstDayOfWeek.
79         (WebCore::ICULocale::monthLabels):
80         (WebCore::ICULocale::weekDayShortLabels):
81         (WebCore::ICULocale::firstDayOfWeek):
82         * platform/text/ICULocale.h:
83         (ICULocale): Add declarations.
84         * platform/text/LocalizedCalendarICU.cpp:
85         (WebCore::monthLabels): Use ICULocale::currentLocale().
86         (WebCore::weekDayShortLabels): ditto.
87         (WebCore::firstDayOfWeek): ditto.
88         * platform/text/LocalizedDateICU.cpp:
89         (WebCore::parseLocalizedDate): ditto.
90         (WebCore::formatLocalizedDate): ditto.
91
92 2012-04-23  Raymond Toy  <rtoy@google.com>
93
94         Move AudioDestinationChromium FIFO class to its own class.
95         https://bugs.webkit.org/show_bug.cgi?id=84058
96
97         Reviewed by Chris Rogers.
98
99         Current tests cover the changes.
100
101         * WebCore.gypi: Update with new files.
102         * platform/audio/AudioPullFIFO.cpp: Copied from Source/WebKit/chromium/src/AudioDestinationChromium.cpp.
103         (WebCore): Renamed old class the AudioPullFIFO.
104         (WebCore::AudioPullFIFO::AudioPullFIFO):
105         (WebCore::AudioPullFIFO::consume):
106         (WebCore::AudioPullFIFO::findWrapLengths):
107         (WebCore::AudioPullFIFO::fillBuffer):
108         * platform/audio/AudioPullFIFO.h: Added.
109         (WebCore):
110         (AudioPullFIFO):
111         (WebCore::AudioPullFIFO::updateIndex):
112
113 2012-04-23  Nate Chapin  <japhet@chromium.org>
114
115         REGRESSION (r100311): YummySoup app crashes when trying to print
116         https://bugs.webkit.org/show_bug.cgi?id=83918
117
118         Reviewed by Alexey Proskuryakov.
119
120         Test: http/tests/xmlhttprequest/cancel-during-failure-crash.html
121
122         * loader/SubresourceLoader.cpp:
123         (WebCore::SubresourceLoader::didFinishLoading):
124         (WebCore::SubresourceLoader::didFail):
125         (WebCore::SubresourceLoader::willCancel): Now that we might enter the function if we're already Finishing,
126             some cleanup needs to be done in the Initialized state only.
127         (WebCore::SubresourceLoader::releaseResources): Move requesting counting decrement and laodDone() to
128             the finishing functions.
129
130 2012-04-23  Shawn Singh  <shawnsingh@chromium.org>
131
132         [chromium] Visualize accelerated compositor rects.
133         https://bugs.webkit.org/show_bug.cgi?id=79400
134
135         Reviewed by Adrienne Walker.
136
137         No tests, all the code added is only debugging code.
138
139         This patch adds support for visualizing three different types of
140         rects on the chromium heads-up display:
141         1. updateRects that indicate what was painted/uploaded to a resource
142         2. propertyChangedRects that indicate layers that has property changes
143         3. surfaceDamageRects that are the accumulation of updateRects and
144            propertyChangedRects, indicating what pixels on the screen have
145            actually changed.  (Surface damage also accounts for newly exposed
146            areas but that is not explicitly visualized.)
147
148         In addition to adding support for visualizing this, the
149         CCHeadsUpDisplay was significantly refactored, separating the FPS
150         Counter functionality into a different class, so that the heads-up
151         display is all about visualizing annotations, and those
152         annotations (frame rate, debug rects) are logged separately.
153
154         * WebCore.gypi:
155         * platform/graphics/chromium/cc/CCDebugRectHistory.cpp: Added.
156         (WebCore):
157         (WebCore::CCDebugRectHistory::CCDebugRectHistory):
158         (WebCore::CCDebugRectHistory::enabled):
159         (WebCore::CCDebugRectHistory::saveDebugRectsForCurrentFrame):
160         (WebCore::CCDebugRectHistory::savePaintRects):
161         (WebCore::CCDebugRectHistory::savePropertyChangedRects):
162         (WebCore::CCDebugRectHistory::saveSurfaceDamageRects):
163         * platform/graphics/chromium/cc/CCDebugRectHistory.h: Added.
164         (WebCore):
165         (WebCore::CCDebugRect::CCDebugRect):
166         (CCDebugRect):
167         (CCDebugRectHistory):
168         (WebCore::CCDebugRectHistory::create):
169         (WebCore::CCDebugRectHistory::debugRects):
170         * platform/graphics/chromium/cc/CCFrameRateCounter.cpp: Added.
171         (WebCore):
172         (WebCore::safeMod):
173         (WebCore::CCFrameRateCounter::frameIndex):
174         (WebCore::CCFrameRateCounter::CCFrameRateCounter):
175         (WebCore::CCFrameRateCounter::markBeginningOfFrame):
176         (WebCore::CCFrameRateCounter::markEndOfFrame):
177         (WebCore::CCFrameRateCounter::isBadFrameInterval):
178         (WebCore::CCFrameRateCounter::isBadFrame):
179         (WebCore::CCFrameRateCounter::getAverageFPSAndStandardDeviation):
180         (WebCore::CCFrameRateCounter::timeStampOfRecentFrame):
181         * platform/graphics/chromium/cc/CCFrameRateCounter.h: Added.
182         (WebCore):
183         (CCFrameRateCounter):
184         (WebCore::CCFrameRateCounter::create):
185         (WebCore::CCFrameRateCounter::currentFrameNumber):
186         (WebCore::CCFrameRateCounter::timeStampHistorySize):
187         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
188         (WebCore):
189         (WebCore::CCHeadsUpDisplay::enabled):
190         (WebCore::CCHeadsUpDisplay::showDebugRects):
191         (WebCore::CCHeadsUpDisplay::draw):
192         (WebCore::CCHeadsUpDisplay::drawHudContents):
193         (WebCore::CCHeadsUpDisplay::drawFPSCounter):
194         (WebCore::CCHeadsUpDisplay::drawFPSCounterText):
195         (WebCore::CCHeadsUpDisplay::drawDebugRects):
196         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
197         (WebCore):
198         (CCHeadsUpDisplay):
199         (WebCore::CCHeadsUpDisplay::CCHeadsUpDisplay):
200         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
201         (WebCore::CCSettings::CCSettings):
202         (CCSettings):
203         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
204         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
205         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
206         (WebCore::CCLayerTreeHostImpl::drawLayers):
207         (WebCore::CCLayerTreeHostImpl::swapBuffers):
208         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
209         (WebCore):
210         (WebCore::CCLayerTreeHostImpl::fpsCounter):
211         (WebCore::CCLayerTreeHostImpl::debugRectHistory):
212         (CCLayerTreeHostImpl):
213
214 2012-04-23  Julien Chaffraix  <jchaffraix@webkit.org>
215
216         Cut dependency on RenderLayer::scrollRectToVisible outside rendering
217         https://bugs.webkit.org/show_bug.cgi?id=84607
218
219         Reviewed by Simon Fraser.
220
221         Layering fix only, there should be no change behavior.
222
223         Because we don't have an accessor on RenderObject, a lot of the code needs
224         to know about RenderLayer. This is not necessary and exposes RenderLayer to
225         objects that shouldn't know about it.
226
227         This patch adds a RenderObject::scrollRectToVisible with the ad-hoc explanation
228         as to why it isn't on RenderBox (scrolling is a RenderBox concept).
229
230         * WebCore.exp.in:
231         * WebCore.order:
232         Updated to expose the new method.
233
234         * dom/Element.cpp:
235         (WebCore::Element::scrollIntoView):
236         (WebCore::Element::scrollIntoViewIfNeeded):
237         (WebCore::Element::updateFocusAppearance):
238         * editing/Editor.cpp:
239         (WebCore::Editor::findStringAndScrollToVisible):
240         * editing/FrameSelection.cpp:
241         (WebCore::FrameSelection::revealSelection):
242         * page/FrameView.cpp:
243         (WebCore::FrameView::scrollToAnchor):
244         Updated those call sites to use the new function.
245
246         * rendering/RenderLayer.h:
247         Removed ScrollBehavior.h #include and default argument values
248         as we are always called through RenderObject now.
249
250         * rendering/RenderObject.cpp:
251         (WebCore::RenderObject::scrollRectToVisible):
252         * rendering/RenderObject.h:
253         Added a new function that just forwards to the enclosing layer
254         if any. We return whether we actually tried to scroll to match
255         some call sites expectations.
256
257 2012-04-23  Zhenyao Mo  <zmo@google.com>
258
259         framebuffer binding should not be changed after canvas resize or compositing
260         https://bugs.webkit.org/show_bug.cgi?id=84609
261
262         Reviewed by Kenneth Russell.
263
264         Test: fast/canvas/webgl/framebuffer-bindings-unaffected-on-resize.html
265
266         * html/canvas/WebGLRenderingContext.cpp: set framebuffer binding to DrawingBuffer.
267         (WebCore):
268         (WebCore::WebGLRenderingContext::bindFramebuffer):
269         (WebCore::WebGLRenderingContext::deleteFramebuffer):
270         (WebCore::WebGLRenderingContext::loseContextImpl):
271         * platform/graphics/cairo/DrawingBufferCairo.cpp: initialize m_framebufferBinding.
272         (WebCore::DrawingBuffer::DrawingBuffer):
273         * platform/graphics/chromium/DrawingBufferChromium.cpp: Ditto.
274         (WebCore::DrawingBuffer::DrawingBuffer):
275         * platform/graphics/chromium/WebGLLayerChromium.cpp: Recover framebuffer binding after update().
276         (WebCore::WebGLLayerChromium::update):
277         * platform/graphics/gpu/DrawingBuffer.cpp: Add a function to restore framebuffer binding.
278         (WebCore::DrawingBuffer::restoreFramebufferBinding):
279         (WebCore):
280         * platform/graphics/gpu/DrawingBuffer.h: Ditto.
281         (WebCore::DrawingBuffer::setTexture2DBinding):
282         (DrawingBuffer):
283         (WebCore::DrawingBuffer::setFramebufferBinding):
284         * platform/graphics/gpu/mac/DrawingBufferMac.mm: initialize m_framebufferBinding.
285         (WebCore::DrawingBuffer::DrawingBuffer):
286         * platform/graphics/gpu/qt/DrawingBufferQt.cpp: initialize m_framebufferBinding.
287         (WebCore::DrawingBuffer::DrawingBuffer):
288
289 2012-04-23  Victor Carbune  <vcarbune@adobe.com>
290
291         Simplify volume slider rendering
292         https://bugs.webkit.org/show_bug.cgi?id=82150
293
294         Reviewed by Eric Carlson.
295
296         Test: media/video-controls-rendering-toggle-display-none.html
297
298         * css/mediaControlsChromium.css: Update controls css for Chromium.
299         (audio::-webkit-media-controls-panel, video::-webkit-media-controls-panel):
300         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
301         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
302         * css/mediaControlsGtk.css: Update controls css for GTK.
303         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
304         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
305         * css/mediaControlsQuickTime.css: Update controls css for Safari.
306         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
307         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
308         (audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider):
309         * html/shadow/MediaControlElements.cpp: Removed particular renderer.
310         (WebCore):
311         * html/shadow/MediaControlElements.h:
312         (MediaControlVolumeSliderContainerElement): Remoed particular renderer.
313         * html/shadow/MediaControlRootElement.cpp:
314         (WebCore::MediaControlRootElement::create): Added a div element as a container. Removed extra unused mute button.
315         * html/shadow/MediaControlRootElementChromium.cpp: Added an extra div
316         element as a container for the mute button and the volume slider to
317         easily position them relative to each other.
318         (WebCore::MediaControlRootElementChromium::create):
319
320 2012-04-23  Sheriff Bot  <webkit.review.bot@gmail.com>
321
322         Unreviewed, rolling out r109981.
323         http://trac.webkit.org/changeset/109981
324         https://bugs.webkit.org/show_bug.cgi?id=84630
325
326         Broke Twitter map buddy icon (see
327         https://bugs.webkit.org/show_bug.cgi?id=84558) (Requested by
328         thorton on #webkit).
329
330         * rendering/RenderLayerCompositor.cpp:
331         (WebCore::RenderLayerCompositor::addToOverlapMap):
332         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
333
334 2012-04-23  Emil A Eklund  <eae@chromium.org>
335
336         Crash in RenderInline::clippedOverflowRectForRepaint for PrintPreview
337         https://bugs.webkit.org/show_bug.cgi?id=84300
338
339         Reviewed by Simon Fraser.
340
341         No new tests, have not been able to come up with a reliable reduction.
342
343         * rendering/RenderInline.cpp:
344         (WebCore::RenderInline::clippedOverflowRectForRepaint):
345         Add NULL check for containingBlock() as it can return NULL when detached
346         from the tree.
347
348 2012-04-23  Sheriff Bot  <webkit.review.bot@gmail.com>
349
350         Unreviewed, rolling out r114929.
351         http://trac.webkit.org/changeset/114929
352         https://bugs.webkit.org/show_bug.cgi?id=84623
353
354         Broke 35 canvas/webgl tests (Requested by jernoble on
355         #webkit).
356
357         * html/canvas/WebGLRenderingContext.cpp:
358         (WebCore):
359         (WebCore::WebGLRenderingContext::bindFramebuffer):
360         (WebCore::WebGLRenderingContext::deleteFramebuffer):
361         (WebCore::WebGLRenderingContext::loseContextImpl):
362         * platform/graphics/cairo/DrawingBufferCairo.cpp:
363         (WebCore::DrawingBuffer::DrawingBuffer):
364         * platform/graphics/chromium/DrawingBufferChromium.cpp:
365         (WebCore::DrawingBuffer::DrawingBuffer):
366         * platform/graphics/chromium/WebGLLayerChromium.cpp:
367         (WebCore::WebGLLayerChromium::update):
368         * platform/graphics/gpu/DrawingBuffer.cpp:
369         * platform/graphics/gpu/DrawingBuffer.h:
370         (WebCore::DrawingBuffer::setTexture2DBinding):
371         (DrawingBuffer):
372         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
373         (WebCore::DrawingBuffer::DrawingBuffer):
374         * platform/graphics/gpu/qt/DrawingBufferQt.cpp:
375         (WebCore::DrawingBuffer::DrawingBuffer):
376
377 2012-04-23  Kentaro Hara  <haraken@chromium.org>
378
379         [V8] Pass Isolate around in V8Collection.h
380         https://bugs.webkit.org/show_bug.cgi?id=84299
381
382         Reviewed by Nate Chapin.
383
384         The objective is to pass Isolate around in V8 bindings.
385         This patch passes Isolate around in V8Collection.h.
386
387         No tests. No change in behavior.
388
389         * bindings/v8/V8Collection.h:
390         (WebCore::getV8Object):
391         (WebCore::getNamedPropertyOfCollection):
392         (WebCore::collectionNamedPropertyGetter):
393         (WebCore::getIndexedPropertyOfCollection):
394         (WebCore::collectionIndexedPropertyGetter):
395
396 2012-04-23  Kentaro Hara  <haraken@chromium.org>
397
398         [V8] Pass Isolate to toV8() (Part5)
399         https://bugs.webkit.org/show_bug.cgi?id=84271
400
401         Reviewed by Nate Chapin.
402
403         The objective is to pass Isolate to all toV8()s.
404         Since there are a lot of toV8(), I'll make the change
405         step by step. This patch passes Isolate to toV8()
406         in several custom bindings.
407
408         No tests. No change in behavior.
409
410         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
411         (WebCore::V8MessageChannel::constructorCallback):
412         * bindings/v8/custom/V8MessageEventCustom.cpp:
413         (WebCore::V8MessageEvent::dataAccessorGetter):
414         (WebCore::V8MessageEvent::portsAccessorGetter):
415         * bindings/v8/custom/V8MutationCallbackCustom.cpp:
416         (WebCore::V8MutationCallback::handleEvent):
417         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
418         (WebCore::V8NamedNodeMap::indexedPropertyGetter):
419         (WebCore::V8NamedNodeMap::namedPropertyGetter):
420         (WebCore::toV8):
421         * bindings/v8/custom/V8NodeListCustom.cpp:
422         (WebCore::V8NodeList::namedPropertyGetter):
423         * bindings/v8/custom/V8NotificationCenterCustom.cpp:
424         (WebCore::V8NotificationCenter::createHTMLNotificationCallback):
425         (WebCore::V8NotificationCenter::createNotificationCallback):
426         * bindings/v8/custom/V8PerformanceCustom.cpp:
427         (WebCore::V8Performance::memoryAccessorGetter):
428         * bindings/v8/custom/V8PopStateEventCustom.cpp:
429         (WebCore::V8PopStateEvent::stateAccessorGetter):
430         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
431         (WebCore::V8SQLTransactionSync::executeSqlCallback):
432         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
433         (WebCore::toV8):
434
435 2012-04-23  Zhenyao Mo  <zmo@google.com>
436
437         framebuffer binding should not be changed after canvas resize or compositing
438         https://bugs.webkit.org/show_bug.cgi?id=84609
439
440         Reviewed by Kenneth Russell.
441
442         Test: fast/canvas/webgl/framebuffer-bindings-unaffected-on-resize.html
443
444         * html/canvas/WebGLRenderingContext.cpp: set framebuffer binding to DrawingBuffer.
445         (WebCore):
446         (WebCore::WebGLRenderingContext::bindFramebuffer):
447         (WebCore::WebGLRenderingContext::deleteFramebuffer):
448         (WebCore::WebGLRenderingContext::loseContextImpl):
449         * platform/graphics/cairo/DrawingBufferCairo.cpp: initialize m_framebufferBinding.
450         (WebCore::DrawingBuffer::DrawingBuffer):
451         * platform/graphics/chromium/DrawingBufferChromium.cpp: Ditto.
452         (WebCore::DrawingBuffer::DrawingBuffer):
453         * platform/graphics/chromium/WebGLLayerChromium.cpp: Recover framebuffer binding after update().
454         (WebCore::WebGLLayerChromium::update):
455         * platform/graphics/gpu/DrawingBuffer.cpp: Add a function to restore framebuffer binding.
456         (WebCore::DrawingBuffer::restoreFramebufferBinding):
457         (WebCore):
458         * platform/graphics/gpu/DrawingBuffer.h: Ditto.
459         (WebCore::DrawingBuffer::setTexture2DBinding):
460         (DrawingBuffer):
461         (WebCore::DrawingBuffer::setFramebufferBinding):
462         * platform/graphics/gpu/mac/DrawingBufferMac.mm: initialize m_framebufferBinding.
463         (WebCore::DrawingBuffer::DrawingBuffer):
464         * platform/graphics/gpu/qt/DrawingBufferQt.cpp: initialize m_framebufferBinding.
465         (WebCore::DrawingBuffer::DrawingBuffer):
466
467 2012-04-23  Kentaro Hara  <haraken@chromium.org>
468
469         [V8] Pass Isolate to toV8() (Part4)
470         https://bugs.webkit.org/show_bug.cgi?id=84269
471
472         Reviewed by Nate Chapin.
473
474         The objective is to pass Isolate to all toV8()s.
475         Since there are a lot of toV8()s, I'll make the change
476         step by step. This patch passes Isolate to toV8() in
477         several custom bindings.
478
479         No tests. No change in behavior.
480
481         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
482         (WebCore::V8HTMLCanvasElement::getContextCallback):
483         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
484         (WebCore::toV8):
485         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
486         (WebCore::V8HTMLDocument::allAccessorGetter):
487         * bindings/v8/custom/V8HTMLElementCustom.cpp:
488         (WebCore::toV8Object):
489         (WebCore::V8HTMLElement::itemValueAccessorGetter):
490         * bindings/v8/custom/V8HTMLFormElementCustom.cpp:
491         (WebCore::V8HTMLFormElement::indexedPropertyGetter):
492         (WebCore::V8HTMLFormElement::namedPropertyGetter):
493         * bindings/v8/custom/V8HTMLFrameSetElementCustom.cpp:
494         (WebCore::V8HTMLFrameSetElement::namedPropertyGetter):
495         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
496         (WebCore::v8HTMLImageElementConstructorCallback):
497         * bindings/v8/custom/V8HTMLLinkElementCustom.cpp:
498         (WebCore::V8HTMLLinkElement::sizesAccessorGetter):
499         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
500         (WebCore::V8HTMLOptionsCollection::indexedPropertyGetter):
501         * bindings/v8/custom/V8HTMLOutputElementCustom.cpp:
502         (WebCore::V8HTMLOutputElement::htmlForAccessorGetter):
503         * bindings/v8/custom/V8HTMLSelectElementCustom.cpp:
504         (WebCore::V8HTMLSelectElement::indexedPropertyGetter):
505         * bindings/v8/custom/V8ImageDataCustom.cpp:
506         (WebCore::toV8):
507
508 2012-04-23  Emil A Eklund  <eae@chromium.org>
509
510         Clean up subpixel unit handling in hit testing code
511         https://bugs.webkit.org/show_bug.cgi?id=84496
512
513         Reviewed by Eric Seidel.
514
515         Fix use of IntRect and LayoutRect in hit testing code in preparation for
516         subpixel layout.
517
518         No new tests, no change in functionality.
519
520         * rendering/HitTestResult.cpp:
521         (WebCore::HitTestResult::rectForPoint):
522         Revert rectForPoint to IntRect as all call sites converted it to an
523         IntRect anyway to compare it with an IntPoint or another IntRect.
524
525         * rendering/HitTestingTransformState.cpp:
526         (WebCore::HitTestingTransformState::boundsOfMappedQuad):
527         * rendering/HitTestingTransformState.h:
528         Convert boundsOfMappedQuad to LayoutRect as the TransformationMatrix now
529         has subpixel precision.
530
531 2012-04-23  Kentaro Hara  <haraken@chromium.org>
532
533         [V8] Pass Isolate to toV8() (Part3)
534         https://bugs.webkit.org/show_bug.cgi?id=84261
535
536         Reviewed by Nate Chapin.
537
538         The objective is to pass Isolate to all toV8()s.
539         Since there are a lot of toV8(), I'll make the change
540         step by step. This patch passes Isolate to toV8()
541         in several custom bindings.
542
543         No tests. No change in behavior.
544
545         * bindings/v8/custom/V8DOMWindowCustom.cpp:
546         (WebCore::V8DOMWindow::openCallback):
547         (WebCore::V8DOMWindow::indexedPropertyGetter):
548         (WebCore::V8DOMWindow::namedPropertyGetter):
549         * bindings/v8/custom/V8DirectoryEntrySyncCustom.cpp:
550         (WebCore::V8DirectoryEntrySync::getDirectoryCallback):
551         (WebCore::V8DirectoryEntrySync::getFileCallback):
552         * bindings/v8/custom/V8DocumentCustom.cpp:
553         (WebCore::V8Document::evaluateCallback):
554         (WebCore::V8Document::getCSSCanvasContextCallback):
555         (WebCore::V8Document::createTouchListCallback):
556         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
557         (WebCore::V8Document::locationAccessorGetter):
558         * bindings/v8/custom/V8EntryCustom.cpp:
559         (WebCore::toV8):
560         * bindings/v8/custom/V8EntrySyncCustom.cpp:
561         (WebCore::toV8):
562         * bindings/v8/custom/V8EventCustom.cpp:
563         (WebCore::V8Event::dataTransferAccessorGetter):
564         (WebCore::V8Event::clipboardDataAccessorGetter):
565         (WebCore):
566         * bindings/v8/custom/V8FileReaderCustom.cpp:
567         (WebCore::V8FileReader::resultAccessorGetter):
568         * bindings/v8/custom/V8HTMLAllCollectionCustom.cpp:
569         (WebCore::getItem):
570         (WebCore::V8HTMLAllCollection::callAsFunctionCallback):
571
572 2012-04-23  Kentaro Hara  <haraken@chromium.org>
573
574         [V8] Pass Isolate to toV8() (Part2)
575         https://bugs.webkit.org/show_bug.cgi?id=84259
576
577         Reviewed by Nate Chapin.
578
579         The objective is to pass Isolate to all toV8()s.
580         Since there are a lot of toV8(), I'll make the change
581         step by step. This patch passes Isolate to toV8() in
582         several custom bindings.
583
584         No tests. No change in behavior.
585
586         * bindings/v8/custom/V8BlobCustom.cpp:
587         (WebCore::toV8):
588         * bindings/v8/custom/V8CSSRuleCustom.cpp:
589         (WebCore::toV8):
590         * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
591         (WebCore::toV8):
592         * bindings/v8/custom/V8CSSValueCustom.cpp:
593         (WebCore::toV8):
594         * bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp:
595         (WebCore::toV8Object):
596         (WebCore::V8CanvasRenderingContext2D::strokeStyleAccessorGetter):
597         (WebCore::V8CanvasRenderingContext2D::fillStyleAccessorGetter):
598         * bindings/v8/custom/V8ConsoleCustom.cpp:
599         (WebCore::V8Console::memoryAccessorGetter):
600         * bindings/v8/custom/V8CustomSQLStatementErrorCallback.cpp:
601         (WebCore::V8SQLStatementErrorCallback::handleEvent):
602         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
603         (WebCore::toV8):
604         * bindings/v8/custom/V8DOMTokenListCustom.cpp:
605         (WebCore::toV8):
606
607 2012-04-23  Kentaro Hara  <haraken@chromium.org>
608
609         [V8][Refactoring] Remove V8Proxy::toV8()
610         https://bugs.webkit.org/show_bug.cgi?id=84257
611
612         Reviewed by Nate Chapin.
613
614         Some constructorCallback()s are using V8Proxy::toV8(),
615         other constructorCallback()s are directly using setJSWrapperForXXX()
616         (XXX can be DOMObject, ActiveDOMObject, Node or ActiveNode).
617         We should unify them.
618
619         Considering the fact that V8Proxy::toV8() just supports
620         XXX=DOMObject and thus is not flexible, replacing V8Proxy::toV8()
621         with setJSWrapperForDOMObject() would make sense.
622
623         No tests. No change in behavior.
624
625         * bindings/v8/V8Proxy.h: Removed toV8().
626
627         * bindings/scripts/CodeGeneratorV8.pm: Replaced toV8() with setJSWrapperForDOMObject().
628         (GenerateEventConstructorCallback):
629         * bindings/v8/custom/V8ArrayBufferCustom.cpp: Ditto.
630         (WebCore::V8ArrayBuffer::constructorCallback):
631         * bindings/v8/custom/V8ArrayBufferViewCustom.h: Ditto.
632         (WebCore::constructWebGLArrayWithArrayBufferArgument):
633         (WebCore::constructWebGLArray):
634         * bindings/v8/custom/V8DOMFormDataCustom.cpp: Ditto.
635         (WebCore::V8DOMFormData::constructorCallback):
636         * bindings/v8/custom/V8DataViewCustom.cpp: Ditto.
637         (WebCore::V8DataView::constructorCallback):
638         * bindings/v8/custom/V8MessageChannelConstructor.cpp: Ditto.
639         (WebCore::V8MessageChannel::constructorCallback):
640         * bindings/v8/custom/V8WebKitPointConstructor.cpp: Ditto.
641         (WebCore::V8WebKitPoint::constructorCallback):
642
643         * bindings/scripts/test/V8/V8TestEventConstructor.cpp: Updated run-bindings-tests results.
644         (WebCore::V8TestEventConstructor::constructorCallback):
645
646 2012-04-23  Kentaro Hara  <haraken@chromium.org>
647
648         [V8] Pass Isolate to toV8() (Part1)
649         https://bugs.webkit.org/show_bug.cgi?id=84250
650
651         Reviewed by Nate Chapin.
652
653         The final objective is to pass Isolate around in V8 bindings.
654         This patch makes a change in CodeGeneratorV8.pm so that the
655         generated code passes Isolate to toV8().
656
657         No tests. No change in behavior.
658
659         * bindings/scripts/CodeGeneratorV8.pm: Modified as described above.
660         (GenerateNormalAttrGetter):
661         (GenerateNamedConstructorCallback):
662         (GenerateCallbackImplementation):
663         (GenerateFunctionCallString):
664         (NativeToJSValue):
665
666         * bindings/scripts/test/V8/V8Float64Array.cpp: Updated run-bindings-tests results.
667         (WebCore::Float64ArrayV8Internal::fooCallback):
668         * bindings/scripts/test/V8/V8TestCallback.cpp:
669         (WebCore::V8TestCallback::callbackWithClass1Param):
670         (WebCore::V8TestCallback::callbackWithClass2Param):
671         (WebCore::V8TestCallback::callbackWithStringList):
672         (WebCore::V8TestCallback::callbackRequiresThisToPass):
673         * bindings/scripts/test/V8/V8TestInterface.cpp:
674         (WebCore::TestInterfaceV8Internal::supplementalMethod2Callback):
675         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
676         (WebCore::V8TestNamedConstructorConstructorCallback):
677         * bindings/scripts/test/V8/V8TestObj.cpp:
678         (WebCore::TestObjV8Internal::readOnlyTestObjAttrAttrGetter):
679         (WebCore::TestObjV8Internal::testObjAttrAttrGetter):
680         (WebCore::TestObjV8Internal::XMLObjAttrAttrGetter):
681         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeAttrGetter):
682         (WebCore::TestObjV8Internal::withScriptStateAttributeRaisesAttrGetter):
683         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeRaisesAttrGetter):
684         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeAttrGetter):
685         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeRaisesAttrGetter):
686         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateWithSpacesAttributeAttrGetter):
687         (WebCore::TestObjV8Internal::withScriptArgumentsAndCallStackAttributeAttrGetter):
688         (WebCore::TestObjV8Internal::cachedAttribute1AttrGetter):
689         (WebCore::TestObjV8Internal::cachedAttribute2AttrGetter):
690         (WebCore::TestObjV8Internal::mutablePointAttrGetter):
691         (WebCore::TestObjV8Internal::immutablePointAttrGetter):
692         (WebCore::TestObjV8Internal::objMethodCallback):
693         (WebCore::TestObjV8Internal::objMethodWithArgsCallback):
694         (WebCore::TestObjV8Internal::methodThatRequiresAllArgsAndThrowsCallback):
695         (WebCore::TestObjV8Internal::withScriptStateObjCallback):
696         (WebCore::TestObjV8Internal::withScriptStateObjExceptionCallback):
697         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateObjExceptionCallback):
698         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateWithSpacesCallback):
699         (WebCore::TestObjV8Internal::mutablePointFunctionCallback):
700         (WebCore::TestObjV8Internal::immutablePointFunctionCallback):
701         (WebCore::TestObjV8Internal::strictFunctionCallback):
702         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
703         (WebCore::TestSerializedScriptValueInterfaceV8Internal::portsAttrGetter):
704
705 2012-04-23  Kentaro Hara  <haraken@chromium.org>
706
707         [V8] Add an optional Isolate argument to setDOMException() and throwError()
708         https://bugs.webkit.org/show_bug.cgi?id=84310
709
710         Reviewed by Nate Chapin.
711
712         The objective is to pass Isolate to setDOMException()
713         and throwError(). This patch adds an optional Isolate argument
714         to setDOMException() and throwError(). I'll pass the Isolate
715         to these methods in the following patches.
716
717         No tests. No change in behavior.
718
719         * bindings/v8/V8Proxy.cpp:
720         (WebCore):
721         (WebCore::V8Proxy::setDOMException):
722         (WebCore::V8Proxy::throwError):
723         * bindings/v8/V8Proxy.h:
724         (V8Proxy):
725         (WebCore):
726         (WebCore::throwError):
727
728 2012-04-23  Ian Vollick  <vollick@chromium.org>
729
730         [chromium] Properly ignore unsupported animation directions.
731         https://bugs.webkit.org/show_bug.cgi?id=84599
732
733         Reviewed by Adrienne Walker.
734
735         Tested in CCLayerAnimationControllerTest.ignoreUnsupportedAnimationDirections.
736
737         * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
738
739 2012-04-17  Kentaro Hara  <haraken@chromium.org>
740
741         [Performance][V8] Skip Isolate look-up to find StringCache
742         https://bugs.webkit.org/show_bug.cgi?id=84103
743
744         Reviewed by Nate Chapin.
745
746         This patch improves the performance of a lot of DOM attribute
747         getters that return a string.
748
749         - Improves the performance of Dromaeo/dom-attr.html(element.property)
750           by 27.7%.
751         - Improves the performance of Dromaeo/dom-attr.html(getAttribute)
752           by 10.6%.
753         - Improves the performance of div.id, div.className,
754           div.nodeName, text.nodeValue, text.textContent by 12% -- 21%.
755
756         The followings are the test results in my Linux desktop.
757
758         Performance test: Dromaeo/dom-attr.html
759         Total:                     674.64runs/s ->  707.03runs/s (+ 4.8%)
760         getAttribute:             1537.60runs/s -> 1700.20runs/s (+10.6%)
761         element.property:         1389.00runs/s -> 1774.20runs/s (+27.7%)
762         setAttribute:              538.88runs/s ->  548.87runs/s (+ 1.9%)
763         element.property = value:  644.07runs/s ->  656.67runs/s (+ 2.0%)
764         element.expando = value:   219.76runs/s ->  207.14runs/s (- 6.8%)
765         element.expando:           578.77runs/s ->  554.67runs/s (- 4.2%)
766
767         Performance test: https://bugs.webkit.org/attachment.cgi?id=137440
768         div.id:           30.70ns -> 26.70ns (+15%)
769         div.className:    31.10ns -> 26.40ns (+18%)
770         div.nodeName:     37.70ns -> 33.00ns (+14%)
771         text.nodeValue:   31.40ns -> 25.90ns (+21%)
772         text.textContent: 51.50ns -> 45.90ns (+12%)
773
774         Previously V8 bindings need to look up an Isolate to find
775         an Isolate-local StringCache. This patch skips the look-up
776         by getting the Isolate from AccessorInfo.GetIsolate()
777         or Arguments.GetIsolate().
778
779         No tests. No change in behavior.
780
781         * bindings/scripts/CodeGeneratorV8.pm:
782         (GenerateNormalAttrGetter):
783         (GenerateFunctionCallString):
784         (NativeToJSValue):
785         * bindings/v8/V8Binding.cpp:
786         (WebCore::getElementStringAttr):
787         * bindings/v8/V8Binding.h:
788         (WebCore::v8ExternalString): Make 'isolate' an optional argument.
789         Ideally we want to make 'isolate' a non-optional argument,
790         but it is difficult to rewrite all v8ExternalString() callers
791         at a breath. We can rewrite them incrementally.
792         (WebCore::v8String): Ditto.
793         (WebCore::v8StringOrNull): Ditto.
794         (WebCore::v8StringOrUndefined): Ditto.
795         (WebCore::v8StringOrFalse): Ditto.
796
797         * bindings/scripts/test/V8/V8TestEventConstructor.cpp: Updated run-bindings-tests results.
798         (WebCore::TestEventConstructorV8Internal::attr1AttrGetter):
799         (WebCore::TestEventConstructorV8Internal::attr2AttrGetter):
800         * bindings/scripts/test/V8/V8TestInterface.cpp:
801         (WebCore::TestInterfaceV8Internal::supplementalStr1AttrGetter):
802         (WebCore::TestInterfaceV8Internal::supplementalStr2AttrGetter):
803         * bindings/scripts/test/V8/V8TestObj.cpp:
804         (WebCore::TestObjV8Internal::readOnlyStringAttrAttrGetter):
805         (WebCore::TestObjV8Internal::stringAttrAttrGetter):
806         (WebCore::TestObjV8Internal::reflectedStringAttrAttrGetter):
807         (WebCore::TestObjV8Internal::reflectedURLAttrAttrGetter):
808         (WebCore::TestObjV8Internal::reflectedCustomURLAttrAttrGetter):
809         (WebCore::TestObjV8Internal::stringAttrWithGetterExceptionAttrGetter):
810         (WebCore::TestObjV8Internal::stringAttrWithSetterExceptionAttrGetter):
811         (WebCore::TestObjV8Internal::hashAttrGetter):
812         (WebCore::TestObjV8Internal::conditionalMethod1Callback):
813
814 2012-04-17  Kentaro Hara  <haraken@chromium.org>
815
816         [V8] Add an optional Isolate argument to wrap()
817         https://bugs.webkit.org/show_bug.cgi?id=84202
818
819         Reviewed by Nate Chapin.
820
821         The final objective is to pass Isolate around in V8 bindings.
822         This patch adds an optional Isolate argument to wrap().
823         After rewriting all wrap() callers so that they pass Isolate
824         to wrap(), I'll make the Isolate argument non-optional.
825
826         No tests. No change in behavior.
827
828         * bindings/scripts/CodeGeneratorV8.pm: Modified as described above.
829         (GenerateHeader):
830         * bindings/v8/custom/V8DocumentCustom.cpp: Ditto.
831         (WebCore::toV8):
832         * bindings/v8/custom/V8HTMLDocumentCustom.cpp: Ditto.
833         (WebCore::toV8):
834         * bindings/v8/custom/V8NodeCustom.cpp: Ditto.
835         (WebCore::toV8Slow):
836         * bindings/v8/custom/V8SVGDocumentCustom.cpp: Ditto.
837         (WebCore::toV8):
838         * dom/make_names.pl: Ditto.
839         (printWrapperFactoryCppFile):
840
841         * bindings/scripts/test/V8/V8Float64Array.h:
842         Updated run-bindings-tests results.
843         (V8Float64Array):
844         (WebCore::V8Float64Array::wrap):
845         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
846         (V8TestActiveDOMObject):
847         (WebCore::V8TestActiveDOMObject::wrap):
848         (WebCore::toV8):
849         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
850         (V8TestCustomNamedGetter):
851         (WebCore::V8TestCustomNamedGetter::wrap):
852         (WebCore::toV8):
853         * bindings/scripts/test/V8/V8TestEventConstructor.h:
854         (V8TestEventConstructor):
855         (WebCore::V8TestEventConstructor::wrap):
856         (WebCore::toV8):
857         * bindings/scripts/test/V8/V8TestEventTarget.h:
858         (V8TestEventTarget):
859         (WebCore::V8TestEventTarget::wrap):
860         (WebCore::toV8):
861         * bindings/scripts/test/V8/V8TestInterface.h:
862         (V8TestInterface):
863         (WebCore::V8TestInterface::wrap):
864         (WebCore::toV8):
865         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
866         (V8TestMediaQueryListListener):
867         (WebCore::V8TestMediaQueryListListener::wrap):
868         (WebCore::toV8):
869         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
870         (V8TestNamedConstructor):
871         (WebCore::V8TestNamedConstructor::wrap):
872         (WebCore::toV8):
873         * bindings/scripts/test/V8/V8TestNode.h:
874         (V8TestNode):
875         (WebCore::V8TestNode::wrap):
876         (WebCore::toV8):
877         * bindings/scripts/test/V8/V8TestObj.h:
878         (V8TestObj):
879         (WebCore::V8TestObj::wrap):
880         (WebCore::toV8):
881         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
882         (V8TestSerializedScriptValueInterface):
883         (WebCore::V8TestSerializedScriptValueInterface::wrap):
884         (WebCore::toV8):
885
886 2012-04-17  Kentaro Hara  <haraken@chromium.org>
887
888         [V8] Pass Isolate to toV8Slow()
889         https://bugs.webkit.org/show_bug.cgi?id=84173
890
891         Reviewed by Nate Chapin.
892
893         The final objective is to pass Isolate around in V8 bindings.
894         This patch passes the Isolate to toV8Slow().
895
896         No tests. No change in behavior.
897
898         * bindings/scripts/CodeGeneratorV8.pm:
899         (GenerateHeader):
900         * bindings/v8/custom/V8NodeCustom.cpp:
901         (WebCore::toV8Slow):
902
903 2012-04-17  Kentaro Hara  <haraken@chromium.org>
904
905         [V8] Add an optional Isolate argument to toV8().
906         https://bugs.webkit.org/show_bug.cgi?id=84161
907
908         Reviewed by Nate Chapin.
909
910         The final objective is to pass Isolate around in V8 bindings.
911         This patch adds an optional Isolate argument to toV8().
912         After rewriting all toV8() callers so that they pass Isolate,
913         I will make the Isolate argument non-optional.
914
915         No tests. No change in behavior.
916
917         * bindings/scripts/CodeGeneratorV8.pm:
918         Modified as described above.
919         (GenerateHeader):
920         (NativeToJSValue):
921         * bindings/v8/custom/V8BlobCustom.cpp:
922         (WebCore::toV8):
923         * bindings/v8/custom/V8CSSRuleCustom.cpp:
924         (WebCore::toV8):
925         * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
926         (WebCore::toV8):
927         * bindings/v8/custom/V8CSSValueCustom.cpp:
928         (WebCore::toV8):
929         * bindings/v8/custom/V8CanvasPixelArrayCustom.cpp:
930         (WebCore::toV8):
931         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
932         (WebCore::toV8):
933         * bindings/v8/custom/V8DOMTokenListCustom.cpp:
934         (WebCore::toV8):
935         * bindings/v8/custom/V8DOMWindowCustom.cpp:
936         (WebCore::toV8):
937         * bindings/v8/custom/V8DataViewCustom.cpp:
938         (WebCore::toV8):
939         * bindings/v8/custom/V8DocumentCustom.cpp:
940         (WebCore::toV8):
941         * bindings/v8/custom/V8EntryCustom.cpp:
942         (WebCore::toV8):
943         * bindings/v8/custom/V8EntrySyncCustom.cpp:
944         (WebCore::toV8):
945         * bindings/v8/custom/V8EventCustom.cpp:
946         (WebCore::toV8):
947         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
948         (WebCore::toV8):
949         * bindings/v8/custom/V8Float64ArrayCustom.cpp:
950         (WebCore::toV8):
951         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
952         (WebCore::toV8):
953         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
954         (WebCore::toV8):
955         * bindings/v8/custom/V8HTMLElementCustom.cpp:
956         (WebCore::toV8):
957         * bindings/v8/custom/V8IDBAnyCustom.cpp:
958         (WebCore::toV8):
959         * bindings/v8/custom/V8IDBKeyCustom.cpp:
960         (WebCore::toV8):
961         * bindings/v8/custom/V8ImageDataCustom.cpp:
962         (WebCore::toV8):
963         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
964         (WebCore::toV8):
965         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
966         (WebCore::toV8):
967         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
968         (WebCore::toV8):
969         * bindings/v8/custom/V8LocationCustom.cpp:
970         (WebCore::toV8):
971         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
972         (WebCore::toV8):
973         * bindings/v8/custom/V8NodeCustom.cpp:
974         (WebCore::toV8Slow):
975         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
976         (WebCore::toV8):
977         * bindings/v8/custom/V8SVGElementCustom.cpp:
978         (WebCore::toV8):
979         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
980         (WebCore::toV8):
981         * bindings/v8/custom/V8ScriptProfileCustom.cpp:
982         (WebCore::toV8):
983         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp:
984         (WebCore::toV8):
985         * bindings/v8/custom/V8StyleSheetCustom.cpp:
986         (WebCore::toV8):
987         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
988         (WebCore::toV8):
989         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
990         (WebCore::toV8):
991         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
992         (WebCore::toV8):
993         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp:
994         (WebCore::toV8):
995         * bindings/v8/custom/V8WorkerContextCustom.cpp:
996         (WebCore::toV8):
997
998         * bindings/scripts/test/V8/V8Float64Array.h:
999         Updated run-bindings-tests results.
1000         (WebCore):
1001         (WebCore::toV8):
1002         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
1003         (WebCore::toV8):
1004         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
1005         (WebCore::toV8):
1006         * bindings/scripts/test/V8/V8TestEventConstructor.h:
1007         (WebCore::toV8):
1008         * bindings/scripts/test/V8/V8TestEventTarget.h:
1009         (WebCore::toV8):
1010         * bindings/scripts/test/V8/V8TestInterface.h:
1011         (WebCore::toV8):
1012         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
1013         (WebCore::toV8):
1014         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
1015         (WebCore::toV8):
1016         * bindings/scripts/test/V8/V8TestNode.h:
1017         (WebCore::toV8):
1018         * bindings/scripts/test/V8/V8TestObj.h:
1019         (WebCore::toV8):
1020         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
1021         (WebCore::toV8):
1022
1023 2012-04-23  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
1024         [EFL][WK2] Fix build break when non-cross platform CONTEXT_MENUS are enabled.
1025         https://bugs.webkit.org/show_bug.cgi?id=84136
1026
1027         Reviewed by Andreas Kling.
1028
1029         There was a mismatch between contextMenuItemVector declaration and definition.
1030         Fixed by changing PlatformMenuDescription for EFL port by adding a const modifier.
1031
1032         No new tests required.
1033
1034         * platform/PlatformMenuDescription.h:
1035         (WebCore): Added const modifier to PlatformMenuDescription definition.
1036
1037 2012-04-23  Pierre Rossi  <pierre.rossi@gmail.com>
1038
1039         [Qt] Ensure zero-width space effectively accounts for a width of zero.
1040         https://bugs.webkit.org/show_bug.cgi?id=84595
1041
1042         Reviewed by Simon Hausmann.
1043
1044         The logic so far relies on FontCache::getFontDataForCharacters to
1045         return a valid fontData in the case where the fonts specified don't
1046         have a glyph for the zero-width space character.
1047         QTextLayout::glyphRuns simply ignores characters that don't render in
1048         the glyph runs it returns, so we need to ensure that the subsequent
1049         call to platformWidthForGlyph doesn't lead to a non-zero width.
1050
1051         Covered by tests containing control characters such as
1052         a soft-hyphen like it's the case in:
1053         svg/as-image/img-preserveAspectRatio-support-1.html
1054
1055         * platform/graphics/qt/SimpleFontDataQt.cpp:
1056         (WebCore::SimpleFontData::platformWidthForGlyph):
1057
1058 2012-04-23  Ian Vollick  <vollick@chromium.org>
1059
1060         [chromium] When prepareToDraw fails due to animation checkerboard, we need to call setNeedsCommit
1061         https://bugs.webkit.org/show_bug.cgi?id=84520
1062
1063         Reviewed by Adrienne Walker.
1064
1065         Tested in CCLayerTreeHostImplTest.prepareToDrawFailsWhenAnimationUsesCheckerboard
1066
1067         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1068         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
1069
1070 2012-04-23  Alexis Menard  <alexis.menard@openbossa.org>
1071
1072         Simplify CSSParser::parseFont.
1073         https://bugs.webkit.org/show_bug.cgi?id=78698
1074
1075         Reviewed by Antti Koivisto.
1076
1077         Simplify parseFont by sharing the code we have for
1078         the longhands of the font property.
1079
1080         No new tests : Extend the existing font shorthand test and modify expected files
1081         as now the order of the longhands added in the property list of the style
1082         has changed. It's very unlikely that some code is relying on this order though. It will
1083         also match the way the spec order them http://www.w3.org/TR/css3-fonts/#font-prop
1084         even though the order is arbitrary for some values.
1085
1086         * css/CSSParser.cpp:
1087         (WebCore::CSSParser::parseValue):
1088         (WebCore::CSSParser::parseFont):
1089         (WebCore::CSSParser::parseLineHeight):
1090         (WebCore):
1091         (WebCore::CSSParser::parseFontSize):
1092         (WebCore::CSSParser::parseFontWeight):  Fix a bug discovered while using parseFontWeight from
1093         the parseFont (case font: 0/0, Arial, sans-serif; in a layout test), we should return true only
1094         when we add something in the property list.
1095         * css/CSSParser.h:
1096
1097 2012-04-23  Yury Semikhatsky  <yurys@chromium.org>
1098
1099         Web Inspector: improve the way heap snapshot diff is calculated
1100         https://bugs.webkit.org/show_bug.cgi?id=84590
1101
1102         Diff calculation now consists of the following steps:
1103         1. Collect data about nodes in the base heap snapshot
1104         2. Pass it to the second snapshot.
1105         3. Calculate delta for each class.
1106
1107         Reviewed by Pavel Feldman.
1108
1109         * inspector/front-end/HeapSnapshot.js:
1110         (WebInspector.HeapSnapshot):
1111         (WebInspector.HeapSnapshot.prototype.dispose):
1112         (WebInspector.HeapSnapshot.prototype.aggregatesForDiff):
1113         (WebInspector.HeapSnapshot.prototype.calculateSnapshotDiff):
1114         (WebInspector.HeapSnapshot.prototype._calculateDiffForClass):
1115         (WebInspector.HeapSnapshot.prototype.createAddedNodesProvider):
1116         (WebInspector.HeapSnapshot.prototype.createDeletedNodesProvider):
1117         * inspector/front-end/HeapSnapshotDataGrids.js:
1118         (WebInspector.HeapSnapshotDiffDataGrid.prototype._populateChildren.aggregatesForDiffReceived.didCalculateSnapshotDiff):
1119         (WebInspector.HeapSnapshotDiffDataGrid.prototype._populateChildren):
1120         * inspector/front-end/HeapSnapshotGridNodes.js:
1121         (WebInspector.HeapSnapshotIteratorsTuple):
1122         (WebInspector.HeapSnapshotDiffNode):
1123         (WebInspector.HeapSnapshotDiffNode.prototype._createChildNode):
1124         (WebInspector.HeapSnapshotDiffNode.prototype._createNodesProvider):
1125         * inspector/front-end/HeapSnapshotProxy.js:
1126         (WebInspector.HeapSnapshotProxy.prototype.aggregatesForDiff):
1127         (WebInspector.HeapSnapshotProxy.prototype.calculateSnapshotDiff):
1128         (WebInspector.HeapSnapshotProxy.prototype.createAddedNodesProvider):
1129         (WebInspector.HeapSnapshotProxy.prototype.createDeletedNodesProvider):
1130         * inspector/front-end/HeapSnapshotView.js:
1131         (WebInspector.HeapSnapshotView.prototype._changeBase):
1132
1133 2012-04-23  Pavel Feldman  <pfeldman@chromium.org>
1134
1135         Web Inspector: Rename and extract UISourceCodeImpl into JavaScriptSource
1136         https://bugs.webkit.org/show_bug.cgi?id=84587
1137
1138         Reviewed by Yury Semikhatsky.
1139
1140         No changes other than extraction here. This is the first step in the Resource
1141         hierarchy refactoring described in bug 84586.
1142
1143         * WebCore.gypi:
1144         * WebCore.vcproj/WebCore.vcproj:
1145         * inspector/compile-front-end.py:
1146         * inspector/front-end/CompilerScriptMapping.js:
1147         (WebInspector.CompilerScriptMapping.prototype.addScript):
1148         * inspector/front-end/DebuggerPresentationModel.js:
1149         * inspector/front-end/JavaScriptSource.js: Added.
1150         (WebInspector.JavaScriptSource):
1151         (WebInspector.JavaScriptSource.prototype.breakpoints):
1152         (WebInspector.JavaScriptSource.prototype.breakpointAdded):
1153         (WebInspector.JavaScriptSource.prototype.breakpointRemoved):
1154         (WebInspector.JavaScriptSource.prototype.consoleMessages):
1155         (WebInspector.JavaScriptSource.prototype.consoleMessageAdded):
1156         (WebInspector.JavaScriptSource.prototype.consoleMessagesCleared):
1157         * inspector/front-end/RawSourceCode.js:
1158         (WebInspector.RawSourceCode.prototype._createUISourceCode):
1159         * inspector/front-end/SnippetsModel.js:
1160         (WebInspector.SnippetsScriptMapping.prototype._snippetAdded):
1161         (WebInspector.SnippetsScriptMapping.prototype._createUISourceCodeForScript):
1162         * inspector/front-end/WebKit.qrc:
1163         * inspector/front-end/inspector.html:
1164
1165 2012-04-23  Gavin Peters  <gavinp@chromium.org>
1166
1167         Move ReferrerPolicy out of SecurityPolicy class into its own header in platform.
1168         https://bugs.webkit.org/show_bug.cgi?id=84516
1169
1170         Reviewed by Adam Barth.
1171
1172         No change in behaviour; same enum, different class.
1173
1174         * GNUmakefile.list.am:
1175         * Target.pri:
1176         * WebCore.exp.in:
1177         * WebCore.gypi:
1178         * WebCore.vcproj/WebCore.vcproj:
1179         * WebCore.xcodeproj/project.pbxproj:
1180         * dom/Document.cpp:
1181         (WebCore::Document::Document):
1182         (WebCore::Document::processReferrerPolicy):
1183         * dom/Document.h:
1184         (WebCore::Document::referrerPolicy):
1185         (Document):
1186         * page/SecurityPolicy.h:
1187         * platform/ReferrerPolicy.h: Added.
1188         (WebCore):
1189
1190 2012-04-23  Vineet Chaudhary  <rgf748@motorola.com>
1191
1192         JS binding code generator doesn't handle "attribute unsigned long[]" well
1193         https://bugs.webkit.org/show_bug.cgi?id=84540
1194
1195         Reviewed by Kentaro Hara.
1196
1197         Codegenerator should handle spaces with the sequence<> to support
1198         numeric types like "unsigned long", "int" .. etc. and primitive types
1199         like "boolean", "Date" etc.
1200
1201         Tests: bindings/scripts/test/TestObj.idl
1202
1203         * bindings/scripts/CodeGenerator.pm:
1204         (SkipIncludeHeader): Rename AvoidInclusionOfType to SkipIncludeHeader.
1205         (GetArrayType):
1206         * bindings/scripts/CodeGeneratorJS.pm:
1207         (AddIncludesForType):
1208         (NativeToJSValue):
1209         * bindings/scripts/CodeGeneratorObjC.pm:
1210         (AddIncludesForType):
1211         (GenerateImplementation):
1212         * bindings/scripts/CodeGeneratorV8.pm:
1213         (AddIncludesForType):
1214         (GetHeaderClassInclude):
1215         (GenerateNormalAttrGetter):
1216         (NativeToJSValue):
1217         * bindings/scripts/IDLStructure.pm:
1218         * bindings/scripts/test/JS/JSTestObj.cpp:
1219         (WebCore):
1220         (WebCore::jsTestObjIntSequenceAttr):
1221         (WebCore::jsTestObjShortSequenceAttr):
1222         (WebCore::jsTestObjLongSequenceAttr):
1223         (WebCore::jsTestObjLongLongSequenceAttr):
1224         (WebCore::jsTestObjUnsignedIntSequenceAttr):
1225         (WebCore::jsTestObjUnsignedShortSequenceAttr):
1226         (WebCore::jsTestObjUnsignedLongSequenceAttr):
1227         (WebCore::jsTestObjUnsignedLongLongSequenceAttr):
1228         (WebCore::jsTestObjFloatSequenceAttr):
1229         (WebCore::jsTestObjDoubleSequenceAttr):
1230         (WebCore::jsTestObjBooleanSequenceAttr):
1231         (WebCore::jsTestObjVoidSequenceAttr):
1232         (WebCore::jsTestObjDateSequenceAttr):
1233         (WebCore::setJSTestObjSequenceAttr):
1234         (WebCore::setJSTestObjIntSequenceAttr):
1235         (WebCore::setJSTestObjShortSequenceAttr):
1236         (WebCore::setJSTestObjLongSequenceAttr):
1237         (WebCore::setJSTestObjLongLongSequenceAttr):
1238         (WebCore::setJSTestObjUnsignedIntSequenceAttr):
1239         (WebCore::setJSTestObjUnsignedShortSequenceAttr):
1240         (WebCore::setJSTestObjUnsignedLongSequenceAttr):
1241         (WebCore::setJSTestObjUnsignedLongLongSequenceAttr):
1242         (WebCore::setJSTestObjFloatSequenceAttr):
1243         (WebCore::setJSTestObjDoubleSequenceAttr):
1244         (WebCore::setJSTestObjBooleanSequenceAttr):
1245         (WebCore::setJSTestObjVoidSequenceAttr):
1246         (WebCore::setJSTestObjDateSequenceAttr):
1247         * bindings/scripts/test/JS/JSTestObj.h:
1248         (WebCore):
1249         * bindings/scripts/test/ObjC/DOMTestObj.h:
1250         * bindings/scripts/test/TestObj.idl:
1251         * bindings/scripts/test/V8/V8TestObj.cpp:
1252         (WebCore::TestObjV8Internal::intSequenceAttrAttrGetter):
1253         (TestObjV8Internal):
1254         (WebCore::TestObjV8Internal::intSequenceAttrAttrSetter):
1255         (WebCore::TestObjV8Internal::shortSequenceAttrAttrGetter):
1256         (WebCore::TestObjV8Internal::shortSequenceAttrAttrSetter):
1257         (WebCore::TestObjV8Internal::longSequenceAttrAttrGetter):
1258         (WebCore::TestObjV8Internal::longSequenceAttrAttrSetter):
1259         (WebCore::TestObjV8Internal::longLongSequenceAttrAttrGetter):
1260         (WebCore::TestObjV8Internal::longLongSequenceAttrAttrSetter):
1261         (WebCore::TestObjV8Internal::unsignedIntSequenceAttrAttrGetter):
1262         (WebCore::TestObjV8Internal::unsignedIntSequenceAttrAttrSetter):
1263         (WebCore::TestObjV8Internal::unsignedShortSequenceAttrAttrGetter):
1264         (WebCore::TestObjV8Internal::unsignedShortSequenceAttrAttrSetter):
1265         (WebCore::TestObjV8Internal::unsignedLongSequenceAttrAttrGetter):
1266         (WebCore::TestObjV8Internal::unsignedLongSequenceAttrAttrSetter):
1267         (WebCore::TestObjV8Internal::unsignedLongLongSequenceAttrAttrGetter):
1268         (WebCore::TestObjV8Internal::unsignedLongLongSequenceAttrAttrSetter):
1269         (WebCore::TestObjV8Internal::floatSequenceAttrAttrGetter):
1270         (WebCore::TestObjV8Internal::floatSequenceAttrAttrSetter):
1271         (WebCore::TestObjV8Internal::doubleSequenceAttrAttrGetter):
1272         (WebCore::TestObjV8Internal::doubleSequenceAttrAttrSetter):
1273         (WebCore::TestObjV8Internal::booleanSequenceAttrAttrGetter):
1274         (WebCore::TestObjV8Internal::booleanSequenceAttrAttrSetter):
1275         (WebCore::TestObjV8Internal::voidSequenceAttrAttrGetter):
1276         (WebCore::TestObjV8Internal::voidSequenceAttrAttrSetter):
1277         (WebCore::TestObjV8Internal::dateSequenceAttrAttrGetter):
1278         (WebCore::TestObjV8Internal::dateSequenceAttrAttrSetter):
1279         (WebCore):
1280
1281 2012-04-23  Andreas Kling  <kling@webkit.org>
1282
1283         Unreviewed assertion fix for Chromium bots.
1284
1285         Skip unnecessary Attr::attachToElement() after constructing an Attr using the
1286         constructor that attaches to an Element.
1287
1288         * dom/ElementAttributeData.cpp:
1289         (WebCore::ElementAttributeData::ensureAttr):
1290
1291 2012-04-23  Andreas Kling  <kling@webkit.org>
1292
1293         REGRESSION(r114870): Assertion failure in ElementAttributeData::setAttr().
1294         <http://webkit.org/b/84581>
1295
1296         Reviewed by Antti Koivisto.
1297
1298         Attach the Attr and bump m_attrCount manually in ensureAttr() instead of calling
1299         setAttr(). The latter asserts that the Attr isn't present in the map, which
1300         obviously isn't true after we've just added it.
1301
1302         This has the added effect of removing one unnecessary hash lookup.
1303
1304         * dom/ElementAttributeData.cpp:
1305         (WebCore::ElementAttributeData::ensureAttr):
1306
1307 2012-04-23  Pavel Feldman  <pfeldman@chromium.org>
1308
1309         Web Inspector: make ParsedURL.prototype.displayName data url friendly.
1310         https://bugs.webkit.org/show_bug.cgi?id=84578
1311
1312         Reviewed by Yury Semikhatsky.
1313
1314         We'd like to define valid URL as the one that has scheme, host and path.
1315         We can append to this URL and manipulate its content. We still want 
1316         possibly invalid specs (such as data or about) to exist and have nice
1317         display names.
1318
1319         * inspector/front-end/ResourceUtils.js:
1320         (WebInspector.ParsedURL):
1321         (WebInspector.ParsedURL.prototype.get displayName):
1322
1323 2012-04-23  Pavel Feldman  <pfeldman@chromium.org>
1324
1325         Web Inspector: introduce String.prototype.starts/endsWith and use it all over the place.
1326         https://bugs.webkit.org/show_bug.cgi?id=84574
1327
1328         Reviewed by Yury Semikhatsky.
1329
1330         * inspector/front-end/AuditRules.js:
1331         (WebInspector.AuditRules.VendorPrefixedCSSProperties.prototype.visitProperty):
1332         * inspector/front-end/BreakpointsSidebarPane.js:
1333         (WebInspector.EventListenerBreakpointsSidebarPane.prototype._setBreakpoint):
1334         (WebInspector.EventListenerBreakpointsSidebarPane.prototype._removeBreakpoint):
1335         * inspector/front-end/CSSCompletions.js:
1336         (WebInspector.CSSCompletions.prototype.startsWith):
1337         (WebInspector.CSSCompletions.prototype._firstIndexOfPrefix):
1338         * inspector/front-end/ConsoleView.js:
1339         (WebInspector.ConsoleView.prototype._reportCompletions):
1340         * inspector/front-end/CookieItemsView.js:
1341         (WebInspector.Cookies.cookieMatchesResourceURL):
1342         * inspector/front-end/DatabaseQueryView.js:
1343         (WebInspector.DatabaseQueryView.prototype.completions):
1344         * inspector/front-end/ElementsTreeOutline.js:
1345         (WebInspector.ElementsTreeElement.prototype._buildAttributeDOM):
1346         * inspector/front-end/ProfileView.js:
1347         * inspector/front-end/ProfilesPanel.js:
1348         (WebInspector.ProfilesPanel.prototype.addProfileHeader):
1349         (WebInspector.ProfilesPanel.prototype.displayTitleForProfileLink):
1350         (WebInspector.ProfileSidebarTreeElement):
1351         (WebInspector.ProfileSidebarTreeElement.prototype.get mainTitle):
1352         * inspector/front-end/ResourceUtils.js:
1353         (WebInspector.ParsedURL):
1354         (WebInspector.displayNameForURL):
1355         (WebInspector.linkifyStringAsFragmentWithCustomLinkifier):
1356         (WebInspector.completeURL):
1357         * inspector/front-end/SnippetsModel.js:
1358         (WebInspector.SnippetsModel.prototype.snippetIdForSourceURL):
1359         * inspector/front-end/SourceCSSTokenizer.js:
1360         (WebInspector.SourceCSSTokenizer.prototype.nextToken):
1361         * inspector/front-end/SourceCSSTokenizer.re2js:
1362         * inspector/front-end/TextPrompt.js:
1363         (WebInspector.TextPrompt.prototype._completeCommonPrefix):
1364         * inspector/front-end/UIUtils.js:
1365         (WebInspector.startEditing):
1366         * inspector/front-end/utilities.js:
1367
1368 2012-04-23  Andreas Kling  <kling@webkit.org>
1369
1370         REGRESSION(r114870): Performance hit on DOM/CloneNodes and DOM/CreateNodes.
1371         <http://webkit.org/b/84575>
1372
1373         Reviewed by Antti Koivisto.
1374
1375         Simplify the cloning of Attributes from one Element to another by simply
1376         assigning to m_attributes. This avoids default-constructing a bunch of
1377         Attribute objects that we overwrite immediately anyway (this used to be
1378         fine because they were RefPtr<Attribute> but now that a default-constructed
1379         Attribute contains a QualifiedName, we were doing a bunch of extra hash
1380         lookups, etc.)
1381
1382         * dom/ElementAttributeData.cpp:
1383         (WebCore::ElementAttributeData::setAttributes):
1384
1385 2012-04-20  Pavel Feldman  <pfeldman@chromium.org>
1386
1387         Web Inspector: implement "open stylesheet" dialog.
1388         https://bugs.webkit.org/show_bug.cgi?id=84466
1389
1390         Reviewed by Yury Semikhatsky.
1391
1392         This change introduces abstract OpenResourceDialog and re-uses it in OpenScriptDialog and OpenStylesheetDialog.
1393         Drive-by fix for data: url representation in the navigator and open resource dialogs.
1394
1395         * inspector/front-end/FilteredItemSelectionDialog.js:
1396         (WebInspector.FilteredItemSelectionDialog.prototype.position):
1397         (WebInspector.OpenResourceDialog.filterOutEmptyURLs):
1398         (WebInspector.OpenResourceDialog.compareFunction):
1399         (WebInspector.OpenResourceDialog):
1400         (WebInspector.OpenResourceDialog.prototype.itemTitleAt):
1401         (WebInspector.OpenResourceDialog.prototype.itemKeyAt):
1402         (WebInspector.OpenResourceDialog.prototype.itemsCount):
1403         (WebInspector.OpenResourceDialog.prototype.requestItems):
1404         (WebInspector.OpenResourceDialog.prototype.selectItem):
1405         (WebInspector.OpenScriptDialog):
1406         (WebInspector.OpenScriptDialog.install):
1407         (WebInspector.OpenScriptDialog._show):
1408         (WebInspector.OpenScriptDialog.prototype.selectItem):
1409         * inspector/front-end/ResourceUtils.js:
1410         (WebInspector.ParsedURL):
1411         * inspector/front-end/ScriptsPanel.js:
1412         * inspector/front-end/StylesPanel.js:
1413         (WebInspector.StylesPanel):
1414         (WebInspector.StylesPanel.prototype._showOpenStylesheetDialog):
1415         (WebInspector.OpenStylesheetDialog):
1416         (WebInspector.OpenStylesheetDialog.prototype.selectItem):
1417         * inspector/front-end/inspector.html:
1418
1419 2012-04-23  Kent Tamura  <tkent@chromium.org>
1420
1421         Add test function to get placeholder string
1422         https://bugs.webkit.org/show_bug.cgi?id=84536
1423
1424         Reviewed by Ryosuke Niwa.
1425
1426         Add window.internals.visiblePlaceholder(element), which returns a
1427         placeholder string only when it's visible.
1428
1429         * WebCore.exp.in: Expose HTMLTextFormControlElement::placeholderShouldBeVisible().
1430         * testing/Internals.cpp:
1431         (WebCore::Internals::visiblePlaceholder): Added.
1432         (WebCore::Internals::selectColorInColorChooser): Omit HTMLNames::.
1433         * testing/Internals.h:
1434         (Internals): Add visiblePlaceholder().
1435         * testing/Internals.idl: ditto.
1436
1437 2012-04-23  Szilard Ledan  <szledan@inf.u-szeged.hu>
1438
1439         Incorrect handling of CSS escape sequences that encode surrogates
1440         https://bugs.webkit.org/show_bug.cgi?id=76152
1441
1442         Reviewed by Kent Tamura.
1443
1444         Test: fast/css/parsing-css-surrogate-pairs.html
1445
1446         * css/CSSParser.cpp:
1447         (WebCore::CSSParser::parseEscape):
1448
1449 2012-04-22  Yury Semikhatsky  <yurys@chromium.org>
1450
1451         Web Inspector: make populateChildren methods private in heap profiler front-end
1452         https://bugs.webkit.org/show_bug.cgi?id=84562
1453
1454         - populateChildren method on HeapSnapshotConstructorsDataGrid and
1455         HeapSnapshotDiffDataGrid now is private.
1456         - Made _defaultPopulateCount a public method on HeapSnapshotSortableDataGrid which
1457         is overriden in some descendants
1458         - Removed unused HeapSnapshotPathFinderProxy
1459         - added closure compiler annotations
1460
1461         Reviewed by Pavel Feldman.
1462
1463         * inspector/front-end/HeapSnapshotDataGrids.js:
1464         (WebInspector.HeapSnapshotSortableDataGrid.prototype.defaultPopulateCount):
1465         (WebInspector.HeapSnapshotConstructorsDataGrid.prototype.setDataSource):
1466         (WebInspector.HeapSnapshotConstructorsDataGrid.prototype._filterSelectIndexChanged):
1467         (WebInspector.HeapSnapshotDiffDataGrid.prototype.defaultPopulateCount):
1468         (WebInspector.HeapSnapshotDiffDataGrid.prototype.setBaseDataSource):
1469         (WebInspector.HeapSnapshotDominatorsDataGrid.prototype.defaultPopulateCount):
1470         * inspector/front-end/HeapSnapshotGridNodes.js:
1471         (WebInspector.HeapSnapshotGridNode):
1472         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren.callSerialize):
1473         (WebInspector.HeapSnapshotDiffNode):
1474         (WebInspector.HeapSnapshotDiffNode.prototype.populateChildren.firstProviderPopulated):
1475         * inspector/front-end/HeapSnapshotProxy.js:
1476
1477 2012-04-22  Andreas Kling  <kling@webkit.org>
1478
1479         Unreviewed build fix, remove Attribute.cpp from DOMAllInOne.cpp.
1480
1481         * dom/DOMAllInOne.cpp: My nemesis.
1482
1483 2012-04-22  Andreas Kling  <kling@webkit.org>
1484
1485         Optimize Element attribute storage for the common case (no Attr objects.)
1486         <http://webkit.org/b/83440>
1487
1488         Reviewed by Antti Koivisto.
1489
1490         Reduce Attribute to its smallest possible size; a qname/value pair.
1491         They are no-longer ref-counted, which allows us to store them in Vectors.
1492
1493         Refactored the DOM Attr object to go with the new Attribute:
1494         Attr now wraps either {element, qname} or {qname, value}. The latter is for
1495         the case where a standalone Attr object is instantiated via DOM APIs.
1496
1497         ElementAttributeData.cpp manages a map of pair<element, qname> => Attr.
1498         Each Element (well, ElementAttributeData) keeps track of how many Attr
1499         objects are pointing to it. This is so we can avoid hash lookups during
1500         common operations in the typical case where you have zero Attrs.
1501
1502         Also removed the inline capacity (was 4) from AttributeVector as that
1503         would significantly increase bloat now that we store Attribute (2 pointers)
1504         rather than RefPtr<Attribute>. We trade this one piece of indirection
1505         for the removal of per-Attribute indirection.
1506
1507         * CMakeLists.txt:
1508         * GNUmakefile.list.am:
1509         * Target.pri:
1510         * WebCore.gypi:
1511         * WebCore.vcproj/WebCore.vcproj:
1512         * WebCore.xcodeproj/project.pbxproj:
1513         * dom/Attr.cpp:
1514         (WebCore::Attr::Attr):
1515         (WebCore):
1516         (WebCore::Attr::create):
1517         (WebCore::Attr::~Attr):
1518         (WebCore::Attr::createTextChild):
1519         (WebCore::Attr::setPrefix):
1520         (WebCore::Attr::setValue):
1521         (WebCore::Attr::cloneNode):
1522         (WebCore::Attr::childrenChanged):
1523         (WebCore::Attr::style):
1524         (WebCore::Attr::value):
1525         (WebCore::Attr::elementAttribute):
1526         (WebCore::Attr::detachFromElementWithValue):
1527         (WebCore::Attr::attachToElement):
1528         * dom/Attr.h:
1529         (WebCore):
1530         (Attr):
1531         (WebCore::Attr::qualifiedName):
1532         (WebCore::Attr::localName):
1533         (WebCore::Attr::namespaceURI):
1534         (WebCore::Attr::prefix):
1535         * dom/Attribute.cpp: Removed.
1536         * dom/Attribute.h:
1537         (WebCore::Attribute::Attribute):
1538         (Attribute):
1539         * dom/Document.cpp:
1540         (WebCore::Document::importNode):
1541         (WebCore::Document::createAttributeNS):
1542         * dom/Element.cpp:
1543         (WebCore::Element::~Element):
1544         (WebCore::Element::detachAttribute):
1545         (WebCore):
1546         (WebCore::Element::removeAttribute):
1547         (WebCore::Element::setAttributeInternal):
1548         (WebCore::Element::parserSetAttributes):
1549         (WebCore::Element::setAttributeNode):
1550         (WebCore::Element::removeAttributeNode):
1551         (WebCore::Element::normalizeAttributes):
1552         (WebCore::Element::didRemoveAttribute):
1553         (WebCore::Element::attrIfExists):
1554         (WebCore::Element::ensureAttr):
1555         * dom/Element.h:
1556         (Element):
1557         (WebCore::Element::getAttributeItemIndex):
1558         * dom/ElementAttributeData.cpp:
1559         (WebCore):
1560         (WebCore::attrMap):
1561         (WebCore::ElementAttributeData::attrIfExists):
1562         (WebCore::ElementAttributeData::ensureAttr):
1563         (WebCore::ElementAttributeData::setAttr):
1564         (WebCore::ElementAttributeData::removeAttr):
1565         (WebCore::AttributeVector::removeAttribute):
1566         (WebCore::ElementAttributeData::~ElementAttributeData):
1567         (WebCore::ElementAttributeData::addAttribute):
1568         (WebCore::ElementAttributeData::removeAttribute):
1569         (WebCore::ElementAttributeData::isEquivalent):
1570         (WebCore::ElementAttributeData::detachAttributesFromElement):
1571         (WebCore::ElementAttributeData::getAttributeItemIndexSlowCase):
1572         (WebCore::ElementAttributeData::setAttributes):
1573         (WebCore::ElementAttributeData::clearAttributes):
1574         (WebCore::ElementAttributeData::replaceAttribute):
1575         (WebCore::ElementAttributeData::getAttributeNode):
1576         * dom/ElementAttributeData.h:
1577         (WebCore):
1578         (WebCore::AttributeVector::AttributeVector):
1579         (AttributeVector):
1580         (WebCore::AttributeVector::getAttributeItem):
1581         (WebCore::AttributeVector::getAttributeItemIndex):
1582         (WebCore::AttributeVector::insertAttribute):
1583         (WebCore::ElementAttributeData::attributeItem):
1584         (ElementAttributeData):
1585         (WebCore::ElementAttributeData::ElementAttributeData):
1586         (WebCore::ElementAttributeData::attributeVector):
1587         (WebCore::ElementAttributeData::clonedAttributeVector):
1588         (WebCore::ElementAttributeData::removeAttribute):
1589         (WebCore::ElementAttributeData::getAttributeItem):
1590         (WebCore::ElementAttributeData::getAttributeItemIndex):
1591         * dom/NamedNodeMap.cpp:
1592         (WebCore::NamedNodeMap::getNamedItem):
1593         (WebCore::NamedNodeMap::getNamedItemNS):
1594         (WebCore::NamedNodeMap::removeNamedItem):
1595         (WebCore::NamedNodeMap::removeNamedItemNS):
1596         (WebCore::NamedNodeMap::item):
1597         * dom/Node.cpp:
1598         (WebCore::Node::compareDocumentPosition):
1599         * html/HTMLAnchorElement.cpp:
1600         (WebCore::HTMLAnchorElement::parseAttribute):
1601         * html/HTMLSelectElement.cpp:
1602         (WebCore::HTMLSelectElement::parseAttribute):
1603         * html/parser/HTMLConstructionSite.cpp:
1604         (WebCore::HTMLConstructionSite::insertHTMLHtmlStartTagBeforeHTML):
1605         (WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement):
1606         (WebCore::HTMLConstructionSite::insertScriptElement):
1607         (WebCore::HTMLConstructionSite::createElement):
1608         (WebCore::HTMLConstructionSite::createHTMLElement):
1609         (WebCore::HTMLConstructionSite::createHTMLElementFromSavedElement):
1610         * html/parser/HTMLToken.h:
1611         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
1612         * html/parser/HTMLTreeBuilder.cpp:
1613         (WebCore::HTMLTreeBuilder::processFakeStartTag):
1614         (WebCore::HTMLTreeBuilder::attributesForIsindexInput):
1615         (WebCore::HTMLTreeBuilder::processIsindexStartTagForInBody):
1616         (WebCore):
1617         (WebCore::HTMLTreeBuilder::processStartTagForInBody):
1618         * html/parser/HTMLTreeBuilder.h:
1619         * html/parser/TextDocumentParser.cpp:
1620         (WebCore::TextDocumentParser::insertFakePreElement):
1621         * page/PageSerializer.cpp:
1622         (WebCore::SerializerMarkupAccumulator::appendCustomAttributes):
1623         * svg/SVGFitToViewBox.cpp:
1624         * svg/properties/SVGAnimatedPropertySynchronizer.h:
1625         * xml/XMLErrors.cpp:
1626         (WebCore::createXHTMLParserErrorHeader):
1627         (WebCore::XMLErrors::insertErrorMessageBlock):
1628         * xml/XPathNodeSet.cpp:
1629         (WebCore::XPath::NodeSet::traversalSort):
1630         * xml/XPathStep.cpp:
1631         (WebCore::XPath::Step::nodesInAxis):
1632         * xml/parser/MarkupTokenBase.h:
1633         (WebCore::AtomicMarkupTokenBase::AtomicMarkupTokenBase):
1634         (WebCore::AtomicMarkupTokenBase::getAttributeItem):
1635         (WebCore::AtomicMarkupTokenBase::attributes):
1636         (AtomicMarkupTokenBase):
1637         (WebCore::::initializeAttributes):
1638         * xml/parser/XMLToken.h:
1639         (WebCore::AtomicXMLToken::AtomicXMLToken):
1640         * xml/parser/XMLTreeBuilder.cpp:
1641         (WebCore::XMLTreeBuilder::processNamespaces):
1642         (WebCore::XMLTreeBuilder::processAttributes):
1643
1644 2012-04-22  Sriram Neelakandan  <sriram.neelakandan@gmail.com>
1645
1646         Sync the MOZ_X11 changes from r14 of http://code.google.com/p/npapi-sdk/
1647         also, modified required build flags for Qt,Gtk and CMake
1648         [Qt]  Added MOZ_X11 build flag for !embedded
1649         https://bugs.webkit.org/show_bug.cgi?id=40785
1650
1651         Reviewed by Anders Carlsson.
1652
1653         No new tests. This does not change functionality. Affects all X11 Ports. Build should break if MOZ_X11 is not passed where required
1654
1655         * WebCore.pri:
1656         * plugins/npapi.h:
1657
1658 2012-04-22  Pablo Flouret  <pablof@motorola.com>
1659
1660         Reset event propagation and canceled flags in Event.initEvent
1661         https://bugs.webkit.org/show_bug.cgi?id=83964
1662
1663         Reviewed by Ryosuke Niwa.
1664
1665         Step 3 in http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-event-initevent
1666         Useful for re-configuring an event before dispatching.
1667
1668         Test: fast/events/flags-unset-on-init-event.html
1669
1670         * dom/Event.cpp:
1671         (WebCore::Event::initEvent):
1672
1673 2012-04-22  Martin Robinson  <mrobinson@igalia.com>
1674
1675         [Cairo] Implement CompositeDifference
1676         https://bugs.webkit.org/show_bug.cgi?id=77354
1677
1678         Reviewed by Alejandro G. Castro.
1679
1680         No new tests. The difference compositing operator are not exposed
1681         to web content, so this change is simply in preparation for a time
1682         in which it is used.
1683
1684         Properly map the difference compositing blend modes to a Cairo operator.
1685
1686         * platform/graphics/cairo/CairoUtilities.cpp:
1687         (WebCore::toCairoOperator): Add a mapping for difference. Remove
1688         code supporting versions of Cairo before 1.10, since the Cairo backend
1689         requires 1.10 or greater already.
1690
1691 2012-04-22  Jon Lee  <jonlee@apple.com>
1692
1693         Remove notifications support on Mac Lion.
1694         https://bugs.webkit.org/show_bug.cgi?id=84554
1695         <rdar://problem/11297128>
1696
1697         Reviewed by Sam Weinig.
1698
1699         * Configurations/FeatureDefines.xcconfig:
1700
1701 2012-04-22  Shawn Singh  <shawnsingh@chromium.org>
1702
1703         [chromium] Damage Tracker needs to use CCMathUtil transforms
1704         https://bugs.webkit.org/show_bug.cgi?id=84070
1705
1706         Reviewed by Adrienne Walker.
1707
1708         Unit test added to CCDamageTracker.cpp.
1709
1710         This patch makes CCDamageTracker use CCMathUtil transforms, so
1711         that perspective w < 0 problem is correctly handled.
1712
1713         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
1714         (WebCore::CCDamageTracker::extendDamageForLayer):
1715         (WebCore::CCDamageTracker::extendDamageForRenderSurface):
1716
1717 2012-04-20  Jon Lee  <jonlee@apple.com>
1718
1719         Add Notification constructor
1720         https://bugs.webkit.org/show_bug.cgi?id=80477
1721         <rdar://problem/10912431>
1722
1723         Reviewed by Jian Li.
1724
1725         Tests will be added once there is support for web notifications on the Mac ports.
1726
1727         * WebCore.exp.in: Export finalize() function.
1728
1729         Modify Dictionary to support creation of event listeners.
1730         * bindings/js/Dictionary.h:
1731         (WebCore::Dictionary::isObject): Return true if the JSDictionary is valid.
1732         (WebCore::Dictionary::isUndefinedOrNull): Return true if the JSDictionary is not valid.
1733         (WebCore::Dictionary::get): Add convenience function to take const char* for
1734         property name, to prevent having to do implicit conversion to WTF::String.
1735         (WebCore::Dictionary::getEventListener): Add function to create event listener
1736         from the dictionary.
1737         (WebCore::Dictionary::asJSObject): Helper to convert WebCore objects to JS wrapper.
1738         * bindings/js/Dictionary.cpp:
1739         (WebCore::Notification): Implement asJSObject() for Notification.
1740         * bindings/js/JSDictionary.h:
1741         (WebCore::JSDictionary::execState): Expose the exec state so that the Dictionary
1742         can obtain its world for creating the event listener.
1743
1744         * bindings/v8/Dictionary.h:
1745         (WebCore::Dictionary::getEventListener): Stub implementation.
1746
1747         Add new constructor to idl definitions.
1748         * notifications/DOMWindowNotifications.idl: Add Notification constructor, if
1749         ENABLE(NOTIFICATIONS) is on.
1750         * notifications/Notification.idl: If ENABLE(NOTIFICATIONS) is turned on, define
1751         the constructor. Otherwise, use OmitConstructor.
1752         * notifications/NotificationCenter.idl: Wrap creation functions in
1753         ENABLE(LEGACY_NOTIFICATIONS).
1754         * notifications/NotificationCenter.h: Ditto.
1755         (NotificationCenter):
1756
1757         * notifications/Notification.h:
1758         (Notification): Wrap legacy constructors in ENABLE(LEGACY_NOTIFICATIONS).
1759         (WebCore::Notification::create): New creation function based on discussions in WG.
1760         * notifications/Notification.cpp:
1761         (WebCore::getAndAddEventListener): Helper function to get the listener from the
1762         dictionary, and attach to the notification.
1763         (WebCore::Notification::create): Create the notification, then apply whatever
1764         properties can be found in the dictionary to the notification. In order to
1765         attach the event listeners, the notification has to have been created, which is
1766         why this all happens in the factory method and not in the constructor.
1767         (WebCore::Notification::setBody): Added so that it can be set if we find it in the
1768         dictionary.
1769
1770         The new constructor queues a task to show when it is created. To support this, we
1771         use a one-shot timer that calls show() in the next iteration of the run loop.
1772         (WebCore::Notification::Notification): Start the timer.
1773         (WebCore::Notification::showTaskTimerFired): Call show().
1774
1775         Notifications, not being attached to the DOM, could be GC'ed by the JS engine
1776         before its life cycle has completed. We add calls to setPendingActivity() when the
1777         notification has been shown, and when it is closed, we unsetPendingActivity().
1778         To guarantee that we only call this once, we add a new state to the Notification
1779         state machine, called NotificationState::Closed.
1780         (WebCore::Notification::show): Call setPendingActivity() for all ports. Remove conditional on Mac.
1781         (WebCore::Notification::close): Include Closed state to machine; do nothing.
1782         (WebCore::Notification::dispatchCloseEvent): Call finalize().
1783         (WebCore::Notification::finalize): If the state is not Closed, we unsetPendingActivity()
1784         to make it available for GC.
1785         (WebCore::Notification::finishLoading): Remove the unsetPendingActivity(). That call
1786         was to balance the setPendingActivity() called for loading the icon. Instead of wrapping
1787         around the icon load, we wrap around the show() -> finalize() loop.
1788
1789         In Notification, rename some of the stages and functions to more clearly communicate
1790         that they mostly deal with the icon of the notification, instead of general loading.
1791         (WebCore::Notification::show): Refactored to use LoadingIcon and CancelledIcon.
1792         (WebCore::Notification::close): Refactored to use LoadingIcon and CancelledIcon.
1793         (WebCore::Notification::~Notification): Refactor to use LoadingIcon.
1794         (WebCore::Notification::startLoadingIcon): Renamed from startLoading().
1795         (WebCore::Notification::stopLoadingIcon): Renamed from stopLoading().
1796         (WebCore::Notification::finishLoadingIcon): Renamed from finishLoading().
1797         (WebCore::Notification::didFinishLoading):
1798         (WebCore::Notification::didFail):
1799         (WebCore::Notification::didFailRedirectCheck):
1800         (WebCore::Notification::didReceiveResponse):
1801         (WebCore::Notification::finishLoading):
1802
1803         Add Dictionary.cpp.
1804         * GNUmakefile.list.am:
1805         * Target.pri:
1806         * UseJSC.cmake:
1807         * WebCore.gypi:
1808
1809         Fix bug in V8 bindings generation code. If the constructor doesn't raise an exception,
1810         don't use an exception code.
1811         * bindings/scripts/CodeGeneratorV8.pm:
1812         (GenerateParametersCheck):
1813         * bindings/scripts/test/V8/V8TestObj.cpp: Reset results.
1814         (WebCore::TestObjV8Internal::optionsObjectCallback):
1815
1816 2012-04-21  Benjamin C Meyer  <bmeyer@rim.com>
1817
1818         Support loading the same plugin in multiple locations in the Blackberry port.
1819         https://bugs.webkit.org/show_bug.cgi?id=84537
1820
1821         The hash for the plugin is only based upon the plugin meta information
1822         which will be the same for the same plugin in the system and user's
1823         plugin folders.
1824
1825         It looks like this code was copied/based on the windows port
1826         which doesn't allow the same plugin to be loaded more than once.
1827
1828         Because we want to support multiple copies of the same plugin
1829         in the blackberry port we want to incorperate the path of the plugin
1830         into the hash.
1831
1832         PR 150404
1833
1834         Reviewed by Adam Treat.
1835
1836         * plugins/blackberry/PluginPackageBlackBerry.cpp:
1837         (WebCore::PluginPackage::hash):
1838
1839 2012-04-21  Benjamin C Meyer  <bmeyer@rim.com>
1840
1841         System plugins are preferred over application plugins
1842         https://bugs.webkit.org/show_bug.cgi?id=84538
1843
1844         Set the preferred paths for plugins so that plugins that reside
1845         inside of the bar will be preferred over plugins that are in the
1846         system folder.
1847
1848         PR 150404
1849
1850         Reviewed by Adam Treat.
1851
1852         * plugins/PluginDatabase.cpp:
1853         (WebCore::PluginDatabase::isPreferredPluginDirectory):
1854
1855 2012-04-21  Darin Adler  <darin@apple.com>
1856
1857         Improve performance of removing user and password from URLs
1858         https://bugs.webkit.org/show_bug.cgi?id=84525
1859
1860         Reviewed by Dan Bernstein.
1861
1862         Performance improvement only. Correctness covered by existing regression tests.
1863
1864         The most common use of KURL::setUser and KURL::setPass, by far, is to remove
1865         the user and password from a URL that already has neither. Optimize this by
1866         not re-parsing the URL in that case.
1867
1868         * platform/KURL.cpp:
1869         (WebCore::KURL::setUser): Restructure code so that the code path that removes
1870         the user does no work when there is nothing to remove. Otherwise, leave the
1871         logic of the function untouched.
1872         (WebCore::KURL::setPass): Same thing, only for password rather than user.
1873
1874 2012-04-20  Sheriff Bot  <webkit.review.bot@gmail.com>
1875
1876         Unreviewed, rolling out r114768.
1877         http://trac.webkit.org/changeset/114768
1878         https://bugs.webkit.org/show_bug.cgi?id=84521
1879
1880         Original patch was not the problem, re-applying (Requested by
1881         pfeldman_ on #webkit).
1882
1883         * bindings/v8/V8IsolatedContext.cpp:
1884         (WebCore::setInjectedScriptContextDebugId):
1885         (WebCore):
1886         (WebCore::V8IsolatedContext::V8IsolatedContext):
1887         * bindings/v8/V8Proxy.cpp:
1888         (WebCore::V8Proxy::evaluateInIsolatedWorld):
1889         * bindings/v8/V8Proxy.h:
1890         (V8Proxy):
1891
1892 2012-04-20  Adrienne Walker  <enne@google.com>
1893
1894         [chromium] Refactor opaque content transform out of Skia context
1895         https://bugs.webkit.org/show_bug.cgi?id=83608
1896
1897         Reviewed by James Robinson.
1898
1899         Having PlatformContextSkia know about the transform into content space
1900         for a layer is a layering violation. This change lets the
1901         PlatformContextSkia deal with opaque rects in its own space and lets
1902         the caller handle transforming it into its own space. This also
1903         prevents a matrix multiply per draw into the Skia canvas and does it
1904         just once at the end to transform the final rect.
1905
1906         This is an incremental refactoring so that additional tracking for
1907         text rects can be added and use the same space as opaque rects.
1908
1909         Tests: LayerTextureUpdaterTest.testPartialOpaqueRectNoTransform
1910                LayerTextureUpdaterTest.testPartialOpaqueRectTranslation
1911                LayerTextureUpdaterTest.testPartialOpaqueRectScale
1912
1913         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.cpp:
1914         (WebCore::BitmapCanvasLayerTextureUpdater::prepareToUpdate):
1915         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.h:
1916         (BitmapCanvasLayerTextureUpdater):
1917         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp:
1918         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::prepareToUpdate):
1919         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h:
1920         (BitmapSkPictureCanvasLayerTextureUpdater):
1921         * platform/graphics/chromium/CanvasLayerTextureUpdater.cpp:
1922         (WebCore::CanvasLayerTextureUpdater::paintContents):
1923         * platform/graphics/chromium/CanvasLayerTextureUpdater.h:
1924         (CanvasLayerTextureUpdater):
1925         * platform/graphics/chromium/LayerTextureUpdater.h:
1926         (WebCore::LayerTextureUpdater::prepareToUpdate):
1927         * platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.cpp:
1928         (WebCore::SkPictureCanvasLayerTextureUpdater::prepareToUpdate):
1929         * platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.h:
1930         (SkPictureCanvasLayerTextureUpdater):
1931         * platform/graphics/chromium/TiledLayerChromium.cpp:
1932         (WebCore::TiledLayerChromium::updateTiles):
1933         * platform/graphics/skia/OpaqueRegionSkia.cpp:
1934         (WebCore::OpaqueRegionSkia::didDrawRect):
1935         (WebCore::OpaqueRegionSkia::didDrawPath):
1936         (WebCore::OpaqueRegionSkia::didDrawPoints):
1937         (WebCore::OpaqueRegionSkia::didDrawBounded):
1938         (WebCore::OpaqueRegionSkia::didDraw):
1939         * platform/graphics/skia/OpaqueRegionSkia.h:
1940         (OpaqueRegionSkia):
1941         * platform/graphics/skia/PlatformContextSkia.cpp:
1942         (WebCore::PlatformContextSkia::didDrawRect):
1943         (WebCore::PlatformContextSkia::didDrawPath):
1944         (WebCore::PlatformContextSkia::didDrawPoints):
1945         (WebCore::PlatformContextSkia::didDrawBounded):
1946         * platform/graphics/skia/PlatformContextSkia.h:
1947         (PlatformContextSkia):
1948
1949 2012-04-20  Enrica Casucci  <enrica@apple.com>
1950
1951         CRASH at WebCore::ReplaceSelectionCommand::removeRedundantMarkup
1952         https://bugs.webkit.org/show_bug.cgi?id=84518
1953         <rdar://problem/10714790>
1954
1955         Reviewed by Simon Fraser.
1956
1957         There are cases where the m_lastNodeInserted is NULL to begin with or
1958         gets deleted by removeRedundantStylesAndKeepStyleSpanInline.
1959         This change handles those cases properly.
1960         
1961         Tests: editing/pasteboard/paste-sanitize-crash-1.html
1962                editing/pasteboard/paste-sanitize-crash-2.html
1963
1964         * editing/ReplaceSelectionCommand.h:
1965         (WebCore::ReplaceSelectionCommand::InsertedNodes::pastLastLeaf):
1966         * editing/SimplifyMarkupCommand.cpp:
1967         (WebCore::SimplifyMarkupCommand::doApply):
1968
1969 2012-04-20  Michael Nordman  <michaeln@google.com>
1970
1971         [chromium] Tiny change to DomStorage v8 bindings to avoid a relatively expensive test in a couple
1972         of places by reordering the expressions in compound conditions, if (fastTest && moreExpensiveTest)
1973         https://bugs.webkit.org/show_bug.cgi?id=84500
1974
1975         Reviewed by Kentaro Hara.
1976
1977         No new tests, no new functionality.
1978
1979         * bindings/v8/custom/V8StorageCustom.cpp:
1980         (WebCore::storageGetter):
1981         (WebCore::V8Storage::namedPropertyQuery):
1982
1983 2012-04-20  Dan Bernstein  <mitz@apple.com>
1984
1985         REGRESSION (r114784): svg/text/foreignObject-text-clipping-bug.xml failing on Mountain Lion Debug Tests
1986         https://bugs.webkit.org/show_bug.cgi?id=84505
1987
1988         Reviewed by Anders Carlsson.
1989
1990         * rendering/RenderBlock.cpp:
1991         (WebCore::RenderBlock::blockBeforeWithinSelectionRoot): Changed to not assume that boxes only
1992         have boxes as siblings.
1993
1994 2012-04-20  Dana Jansens  <danakj@chromium.org>
1995
1996         [chromium] Remove special case for recreating layers during sync
1997         https://bugs.webkit.org/show_bug.cgi?id=84458
1998
1999         Reviewed by James Robinson.
2000
2001         We no longer delete layers on the impl side, unless it is due to
2002         deleting the layer on webkit side. So we will no longer have a
2003         situation where we need to push properties from an old
2004         LayerChromium to a new CCLayerImpl.
2005
2006         * platform/graphics/chromium/TreeSynchronizer.cpp:
2007         (WebCore::TreeSynchronizer::reuseOrCreateCCLayerImpl):
2008
2009 2012-04-20  Dana Jansens  <danakj@chromium.org>
2010
2011         [chromium] WebFilterOperations API does not compile or dynamically link
2012         https://bugs.webkit.org/show_bug.cgi?id=84506
2013
2014         Reviewed by James Robinson.
2015
2016         Non-inline functions need WEBKIT_EXPORT in their declarations,
2017         and the type used in the WebPrivateOwnPtr needs to be forward-
2018         declared even when WEBKIT_IMPLEMENTATION is not defined.
2019
2020         * platform/chromium/support/WebFilterOperations.cpp:
2021         (WebKit::WebFilterOperations::initialize):
2022
2023 2012-04-20  Sheriff Bot  <webkit.review.bot@gmail.com>
2024
2025         Unreviewed, rolling out r114333.
2026         http://trac.webkit.org/changeset/114333
2027         https://bugs.webkit.org/show_bug.cgi?id=84511
2028
2029         perf regression (Requested by morrita on #webkit).
2030
2031         * dom/Node.cpp:
2032         * dom/Node.h:
2033         (WebCore):
2034         (Node):
2035         (WebCore::Node::isElementNode):
2036         (WebCore::Node::isContainerNode):
2037         (WebCore::Node::isTextNode):
2038         (WebCore::Node::isHTMLElement):
2039         (WebCore::Node::isSVGElement):
2040         (WebCore::Node::isStyledElement):
2041         (WebCore::Node::isShadowRoot):
2042         (WebCore::Node::parentNode):
2043         (WebCore::Node::parentNodeGuaranteedHostFree):
2044
2045 2012-04-20  Alec Flett  <alecflett@chromium.org>
2046
2047         IndexedDB: Support get/getKey(keyRange)
2048         https://bugs.webkit.org/show_bug.cgi?id=83638
2049
2050         Reviewed by Ojan Vafai.
2051
2052         Support IDBKeyRange as a parameter to all the various get/getKey 
2053         combinations. Switches the existing get/getKey versions that use 
2054         IDBKey directly to start using IDBKeyRange.only(). 
2055
2056         Test: storage/indexeddb/get-keyrange.html
2057
2058         * Modules/indexeddb/IDBIndex.cpp:
2059         (WebCore::IDBIndex::get):
2060         (WebCore):
2061         (WebCore::IDBIndex::getKey):
2062         * Modules/indexeddb/IDBIndex.h:
2063         (IDBIndex):
2064         * Modules/indexeddb/IDBIndex.idl:
2065         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
2066         (WebCore::IDBIndexBackendImpl::getInternal):
2067         (WebCore):
2068         (WebCore::IDBIndexBackendImpl::getByRangeInternal):
2069         (WebCore::IDBIndexBackendImpl::getKeyInternal):
2070         (WebCore::IDBIndexBackendImpl::getKeyByRangeInternal):
2071         (WebCore::IDBIndexBackendImpl::get):
2072         (WebCore::IDBIndexBackendImpl::getKey):
2073         * Modules/indexeddb/IDBIndexBackendImpl.h:
2074         (IDBIndexBackendImpl):
2075         * Modules/indexeddb/IDBIndexBackendInterface.h:
2076         (IDBIndexBackendInterface):
2077         * Modules/indexeddb/IDBObjectStore.cpp:
2078         (WebCore::IDBObjectStore::get):
2079         (WebCore):
2080         * Modules/indexeddb/IDBObjectStore.h:
2081         (IDBObjectStore):
2082         * Modules/indexeddb/IDBObjectStore.idl:
2083         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
2084         (WebCore):
2085         (WebCore::IDBObjectStoreBackendImpl::get):
2086         (WebCore::IDBObjectStoreBackendImpl::getByRangeInternal):
2087         (WebCore::IDBObjectStoreBackendImpl::getInternal):
2088         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
2089         (IDBObjectStoreBackendImpl):
2090         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
2091         (IDBObjectStoreBackendInterface):
2092
2093 2012-04-20  Sheriff Bot  <webkit.review.bot@gmail.com>
2094
2095         Unreviewed, rolling out r114789.
2096         http://trac.webkit.org/changeset/114789
2097         https://bugs.webkit.org/show_bug.cgi?id=84515
2098
2099         Caused 5 tests to fail on mac/ (Requested by jernoble on
2100         #webkit).
2101
2102         * css/CSSPrimitiveValueMappings.h:
2103         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2104         * css/CSSValueKeywords.in:
2105         * platform/ThemeTypes.h:
2106         * rendering/RenderTheme.cpp:
2107         (WebCore::RenderTheme::paint):
2108
2109 2012-04-20  Brady Eidson  <beidson@apple.com>
2110
2111         https://bugs.webkit.org/show_bug.cgi?id=84512
2112         Repurpose ActiveDOMObject::WillShowDialog to WillDeferLoading
2113
2114         Reviewed by Eric Carlson.
2115
2116         No new tests. (Refactor, no behavior change)
2117
2118         Rename WillShowDialog to WillDeferLoading:
2119         * dom/ActiveDOMObject.h:
2120         * html/HTMLMediaElement.cpp:
2121         (WebCore::HTMLMediaElement::suspend):
2122
2123         Don't take a ReasonForSuspension argument anymore, just use WillDeferLoading:
2124         * page/PageGroupLoadDeferrer.cpp:
2125         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
2126         * page/PageGroupLoadDeferrer.h:
2127
2128         Don't pass a Reason anymore as WillDeferLoading is used by default:
2129         * page/Chrome.cpp:
2130         (WebCore::Chrome::runModal):
2131         (WebCore::Chrome::runBeforeUnloadConfirmPanel):
2132         (WebCore::Chrome::runJavaScriptAlert):
2133         (WebCore::Chrome::runJavaScriptConfirm):
2134         (WebCore::Chrome::runJavaScriptPrompt):
2135         (WebCore::Chrome::shouldInterruptJavaScript):
2136
2137 2012-04-20  James Robinson  <jamesr@chromium.org>
2138
2139         [chromium] Plumb a compositor surface ready notification through to the threaded compositor
2140         https://bugs.webkit.org/show_bug.cgi?id=84305
2141
2142         Reviewed by Adrienne Walker.
2143
2144         Plumb setSurfaceReady through to the scheduler.
2145
2146         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2147         (WebCore::CCLayerTreeHost::setSurfaceReady):
2148         (WebCore):
2149         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2150         (CCLayerTreeHost):
2151         * platform/graphics/chromium/cc/CCProxy.h:
2152         (CCProxy):
2153         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
2154         (WebCore::CCSingleThreadProxy::setSurfaceReady):
2155         (WebCore):
2156         * platform/graphics/chromium/cc/CCSingleThreadProxy.h:
2157         (CCSingleThreadProxy):
2158         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
2159         (WebCore::CCThreadProxy::setSurfaceReady):
2160         (WebCore):
2161         (WebCore::CCThreadProxy::setSurfaceReadyOnImplThread):
2162         (WebCore::CCThreadProxy::initializeImplOnImplThread):
2163         * platform/graphics/chromium/cc/CCThreadProxy.h:
2164         (CCThreadProxy):
2165
2166 2012-04-20  Mark Pilgrim  <pilgrim@chromium.org>
2167
2168         [Chromium] Call memoryUsageMB directly
2169         https://bugs.webkit.org/show_bug.cgi?id=84376
2170
2171         Reviewed by Kentaro Hara.
2172
2173         Now that memoryUsageMB has been moved from PlatformSupport.h to
2174         Platform.h, we need to be able to call it directly
2175         from WebCore/bindings/v8/V8GCController.cpp.
2176         That means we need a new MemoryUsageSupport class in
2177         WebCore/platform/ and an implementation in
2178         WebCore/platform/chromium/MemoryUsageSupportChromium.cpp.
2179         Other ports are welcome to implement their memory usage
2180         functions if they wish. This pattern was based on the
2181         HistogramSupport/HistogramSupportChromium classes.
2182
2183         Part of a refactoring series. See tracking bug 82948.
2184
2185         * CMakeLists.txt:
2186         * GNUmakefile.list.am:
2187         * Target.pri:
2188         * WebCore.gypi:
2189         * WebCore.vcproj/WebCore.vcproj:
2190         * WebCore.xcodeproj/project.pbxproj:
2191         * bindings/v8/V8GCController.cpp:
2192         (WebCore):
2193         * platform/MemoryUsageSupport.cpp: Added.
2194         (WebCore):
2195         (WebCore::MemoryUsageSupport::memoryUsageMB):
2196         * platform/MemoryUsageSupport.h: Added.
2197         (WebCore):
2198         (MemoryUsageSupport):
2199         * platform/chromium/MemoryUsageSupportChromium.cpp: Added.
2200         (WebCore):
2201         (WebCore::MemoryUsageSupport::memoryUsageMB):
2202         * platform/chromium/PlatformSupport.h:
2203         (PlatformSupport):
2204
2205 2012-04-20  Anders Carlsson  <andersca@apple.com>
2206
2207         Re-land. The non-fast scrollable region is now always updated after layout, and frameViewScrollableAreasDidChange has been removed.
2208
2209         computeNonFastScrollableRegion needs to traverse the entire frame tree
2210         https://bugs.webkit.org/show_bug.cgi?id=84409
2211         <rdar://problem/11285741>
2212
2213         Reviewed by Dan Bernstein.
2214
2215         Now that scrollable areas won't be in the set of scrollable areas unless they are actually scrollable, we need to look for scrollable
2216         areas in the entire frame tree since there can be a scrollable frame that's a subframe of a non-scrollable frame for example.
2217
2218         * page/scrolling/ScrollingCoordinator.cpp:
2219         (WebCore::computeNonFastScrollableRegion):
2220         (WebCore::ScrollingCoordinator::frameViewLayoutUpdated):
2221
2222 2012-04-20  Adrienne Walker  <enne@google.com>
2223
2224         [chromium] Clip TransparencyWin to prevent OOM from large Skia canvas
2225         https://bugs.webkit.org/show_bug.cgi?id=84289
2226
2227         Reviewed by James Robinson.
2228
2229         TransparencyWin will create a Skia canvas of whatever size is passed
2230         in, even if the result will ultimately be clipped. Handle the clip
2231         implicitly and try (in some cases) to create a smaller canvas. This
2232         can happen due to RenderBox::paintBoxDecorations passing a paint rect
2233         down of the entire element's size.
2234
2235         Modes with more complicated transforms (ScaleTransform, UnTransform)
2236         are not handled yet.
2237
2238         Tests: TransparencyWin.ClippedKeepTransformNoLayer
2239                TransparencyWin.ClippedKeepTransformOpaqueCompositeLayer
2240                TransparencyWin.ClippedKeepTransformOpaqueWhiteLayer
2241
2242         * platform/graphics/chromium/TransparencyWin.cpp:
2243         (WebCore::TransparencyWin::computeLayerSize):
2244
2245 2012-04-04  Jer Noble  <jer.noble@apple.com>
2246
2247         apple.com top navigation bar appears inside video during full screen exit animation
2248         https://bugs.webkit.org/show_bug.cgi?id=83095
2249
2250         Reviewed by Eric Carlson.
2251
2252         Test: fullscreen/full-screen-exit-animation-stacking-context.html
2253
2254         Only tell ancestors of the full screen element that they are no longer ancestors once
2255         the full screen animation is complete:
2256         * dom/Document.cpp:
2257         (WebCore::Document::webkitWillExitFullScreenForElement):
2258         (WebCore::Document::webkitDidExitFullScreenForElement):
2259
2260         To facilitate writing reproducible LayoutTests, expose webkitWill/Did/Enter/ExitFullScreen
2261         from the Internals object, so scripts can call them explicitly:
2262         * testing/Internals.cpp:
2263         (WebCore::Internals::webkitWillEnterFullScreenForElement): Call the Document equivalent.
2264         (WebCore::Internals::webkitDidEnterFullScreenForElement): Ditto.
2265         (WebCore::Internals::webkitWillExitFullScreenForElement): Ditto.
2266         (WebCore::Internals::webkitDidExitFullScreenForElement): Ditto.
2267         * testing/Internals.h:
2268         * testing/Internals.idl:
2269
2270 2012-04-17  Jer Noble  <jer.noble@apple.com>
2271
2272         media-exit-fullscreen-button (and related enums) is unnecessary and should be removed.
2273         https://bugs.webkit.org/show_bug.cgi?id=84162
2274
2275         Reviewed by Eric Carlson.
2276
2277         No new tests; no change in functionality so covered by existing tests.
2278
2279         Remove the media-exit-fullscreen-button keyword, and rename media-enter-fullscreen-button to
2280         media-fullscreen-button.
2281
2282         * css/CSSPrimitiveValueMappings.h:
2283         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2284         * css/CSSValueKeywords.in:
2285         * css/mediaControls.css:
2286         (audio::-webkit-media-controls-fullscreen-button, video::-webkit-media-controls-fullscreen-button):
2287         * platform/ThemeTypes.h:
2288         * rendering/RenderTheme.cpp:
2289         (WebCore::RenderTheme::paint):
2290
2291 2012-04-20  Alexandre Elias  <aelias@google.com>
2292
2293         [chromium] Fix compile errors when DEBUG_GL_CALLS is enabled
2294         https://bugs.webkit.org/show_bug.cgi?id=84491
2295
2296         Reviewed by Ojan Vafai.
2297
2298         DEBUG_GL_CALLS had not been used in a while and the mode no longer
2299         compiled when I tried it.  I improved the GLC macro to support either
2300         raw pointers or RefPtrs, and to be a single expression in order to
2301         interact properly with if/else blocks.  I fixed the cases where we
2302         were passing in the "context" method pointer by mistake, and removed the
2303         now-unnecessary "get()" calls for the RefPtrs.
2304
2305         No new tests. (No-op change in release builds.)
2306
2307         * platform/graphics/chromium/LayerRendererChromium.cpp:
2308         (WebCore::LayerRendererChromium::initialize):
2309         (WebCore::LayerRendererChromium::clearRenderSurface):
2310         (WebCore::LayerRendererChromium::beginDrawingFrame):
2311         (WebCore::LayerRendererChromium::doNoOp):
2312         (WebCore::LayerRendererChromium::drawQuad):
2313         (WebCore::LayerRendererChromium::drawTextureQuad):
2314         (WebCore::LayerRendererChromium::drawHeadsUpDisplay):
2315         (WebCore::LayerRendererChromium::finishDrawingFrame):
2316         (WebCore::LayerRendererChromium::useRenderSurface):
2317         (WebCore::LayerRendererChromium::bindFramebufferToTexture):
2318         (WebCore::LayerRendererChromium::setScissorToRect):
2319         (WebCore::LayerRendererChromium::setDrawViewportRect):
2320         (WebCore::LayerRendererChromium::initializeSharedObjects):
2321         (WebCore::LayerRendererChromium::cleanupSharedObjects):
2322         * platform/graphics/chromium/LayerRendererChromium.h:
2323         (WebCore):
2324
2325 2012-04-20  Anders Carlsson  <andersca@apple.com>
2326
2327         Fix build.
2328
2329         * page/scrolling/ScrollingCoordinator.cpp:
2330         (WebCore::ScrollingCoordinator::updateMainFrameScrollPositionAndScrollLayerPosition):
2331
2332 2012-04-19  Simon Fraser  <simon.fraser@apple.com>
2333
2334         Set m_compositingDependsOnGeometry to false if possible
2335         https://bugs.webkit.org/show_bug.cgi?id=84391
2336
2337         Reviewed by James Robinson.
2338         
2339         For some kinds of elements, RenderLayerCompositor has to delay decisions about
2340         compositing until the element's size and/or position are known. This was previsouly
2341         based on the confusingly named m_compositingDependsOnGeometry flag, but another
2342         variant of the same technique, with an additional flag m_compositingNeedsUpdate,
2343         was added in r98627.
2344         
2345         Also, once the m_compositingDependsOnGeometry flag was set to true, nothing
2346         set it to false, so every compositing layer update resulted in a computeCompositingRequirements()
2347         pass over the layers.
2348         
2349         Rename the m_compositingDependsOnGeometry flag to m_reevaluateCompositingAfterLayout,
2350         and clear the flag when we do a layout-related compositing layer update.
2351         Use the same flag for position:fixed compositing.
2352         
2353         This requires RenderLayerCompositor to distinguish between style- and layout-
2354         related updates, requiring some minor refactoring in FrameView.
2355
2356         Should not change behavior.
2357         
2358         * dom/Document.cpp:
2359         (WebCore::Document::recalcStyle):
2360         (WebCore::Document::implicitClose):
2361         * page/FrameView.cpp:
2362         (WebCore::FrameView::updateCompositingLayersAfterStyleChange):
2363         (WebCore::FrameView::updateCompositingLayersAfterLayout):
2364         (WebCore::FrameView::restoreBackingStores):
2365         (WebCore::FrameView::layout):
2366         * page/FrameView.h:
2367         (FrameView):
2368         * rendering/RenderLayerCompositor.cpp:
2369         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
2370         (WebCore::RenderLayerCompositor::updateCompositingLayersTimerFired):
2371         (WebCore::RenderLayerCompositor::updateCompositingLayers):
2372         (WebCore::RenderLayerCompositor::layerTreeAsText):
2373         (WebCore::RenderLayerCompositor::requiresCompositingForPlugin):
2374         (WebCore::RenderLayerCompositor::requiresCompositingForFrame):
2375         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
2376         * rendering/RenderLayerCompositor.h:
2377         (RenderLayerCompositor):
2378
2379 2012-04-20  Dan Bernstein  <mitz@apple.com>
2380
2381         <rdar://problem/10786000> Selection highlights of lines in adjoining blocks can overlap
2382         https://bugs.webkit.org/show_bug.cgi?id=84489
2383
2384         Reviewed by Anders Carlsson.
2385
2386         Test: fast/block/line-layout/selection-highlight-overlap.html
2387
2388         * rendering/EllipsisBox.cpp:
2389         (WebCore::EllipsisBox::selectionRect): Changed to use
2390         selection{Top,Height}AdjustedForPrecedingBlock().
2391         * rendering/InlineTextBox.cpp:
2392         (WebCore::InlineTextBox::paintSelection): Ditto.
2393         * rendering/RenderBlock.cpp:
2394         (WebCore::RenderBlock::inlineSelectionGaps): Ditto.
2395         (WebCore::RenderBlock::blockBeforeWithinSelectionRoot): Added. Returns the block which is
2396         likely to contain the selected line just before the first line in this block, if it is
2397         within the same selection root.
2398         * rendering/RenderBlock.h:
2399         * rendering/RootInlineBox.cpp:
2400         (WebCore::RootInlineBox::selectionTopAdjustedForPrecedingBlock): Added. If the selection
2401         starts before our block, finds the last line in the preceding block and adjusts the selection
2402         top to avoid overlap with that line’s selection bottom.
2403         * rendering/RootInlineBox.h:
2404         (WebCore::RootInlineBox::selectionHeightAdjustedForPrecedingBlock): Added. Like
2405         selectionHeight(), but uses selectionTopAdjustedForPrecedingBlock().
2406
2407 2012-04-20  Xianzhu Wang  <wangxianzhu@chromium.org>
2408
2409         Crash in getOrDrawNodeHighlight after r114659
2410         https://bugs.webkit.org/show_bug.cgi?id=84486
2411
2412         Reviewed by Daniel Bates.
2413
2414         No new tests. Fixes a crash in test: inspector/elements/elements-panel-selection-on-refresh.html.
2415
2416         * inspector/DOMNodeHighlighter.cpp:
2417
2418 2012-04-20  Brady Eidson  <beidson@apple.com>
2419
2420         https://bugs.webkit.org/show_bug.cgi?id=84490
2421         PageGroupLoadDeferrer needs to take a ReasonForSuspension argument
2422
2423         Reviewed by Anders Carlsson.
2424
2425         No new tests. (Refactor, no change in behavior)
2426
2427         - Make PageGroupLoadDeferrer take a ReasonForSuspension argument so it can pass it along.
2428         * page/PageGroupLoadDeferrer.cpp:
2429         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
2430         * page/PageGroupLoadDeferrer.h:
2431
2432         - Change suspendScheduledTasks to take a ReasonForSuspension.
2433         - As long as we're changing Document.h, add a m_suspendedScheduledTasks flag and some
2434           ASSERTs to catch what would be epically wrong behavior in the future.
2435         * dom/Document.cpp:
2436         (WebCore::Document::Document):
2437         (WebCore::Document::suspendScheduledTasks):
2438         (WebCore::Document::resumeScheduledTasks):
2439         * dom/Document.h:
2440
2441         - Pass ActiveDOMObject::WillShowDialog along to all PageGroupLoadDeferrers, as it used
2442           to be the default behavior
2443         * page/Chrome.cpp:
2444         (WebCore::Chrome::runModal):
2445         (WebCore::Chrome::runBeforeUnloadConfirmPanel):
2446         (WebCore::Chrome::runJavaScriptAlert):
2447         (WebCore::Chrome::runJavaScriptConfirm):
2448         (WebCore::Chrome::runJavaScriptPrompt):
2449         (WebCore::Chrome::shouldInterruptJavaScript):
2450
2451 2012-04-20  Anders Carlsson  <andersca@apple.com>
2452
2453         Scrolling after going to a find-in-page result jumps to the top of the page
2454         https://bugs.webkit.org/show_bug.cgi?id=84485
2455         <rdar://problem/11273734>
2456
2457         Reviewed by Beth Dakin.
2458
2459         If we're both updating the requested scroll position and entering slow mode in the same commit, the
2460         probable main thread scroll position should be the requested scroll position.
2461
2462         * page/scrolling/mac/ScrollingTreeNodeMac.mm:
2463         (WebCore::ScrollingTreeNodeMac::update):
2464
2465 2012-04-20  James Robinson  <jamesr@chromium.org>
2466
2467         Avoid synchronously recalculating the nonFastScrollableRegion when the ScrollableArea set changes
2468         https://bugs.webkit.org/show_bug.cgi?id=84470
2469
2470         Reviewed by Anders Carlsson.
2471
2472         When a scrollable area is added or removed, we shouldn't recalculate the nonFastScrollableRegion synchronously
2473         since this is slow, the RenderObject tree might not be in an up-to-date state, and we'll typically do layout
2474         soon anyway.
2475
2476         * page/FrameView.cpp:
2477         (WebCore::FrameView::addScrollableArea):
2478         (WebCore::FrameView::removeScrollableArea):
2479         * page/scrolling/ScrollingCoordinator.cpp:
2480         * page/scrolling/ScrollingCoordinator.h:
2481         (ScrollingCoordinator):
2482
2483 2012-04-20  Emil A Eklund  <eae@chromium.org>
2484
2485         Fix use of LayoutUnits in DOMNodeHighlighter
2486         https://bugs.webkit.org/show_bug.cgi?id=84472
2487
2488         Reviewed by Eric Seidel.
2489
2490         Fix use of subpixel units and rounding in new code introduced in r114659.
2491
2492         No new tests, no change in functionality.
2493
2494         * inspector/DOMNodeHighlighter.cpp:
2495
2496 2012-04-17  Antonio Gomes  <agomes@rim.com>
2497
2498         Relax ScrollView::adjustScrollPositionWithinRange in case constrainsScrollingToContentEdge is false
2499         https://bugs.webkit.org/show_bug.cgi?id=84178
2500
2501         Reviewed by Adam Treat.
2502
2503         No new tests since it is not easily testable.
2504
2505         When a port has both delegatesScrolling and constrainsScrollingToContentEdge set to FALSE
2506         (i.e. it accepts overscrolled position), calling ScrollView::setScrollPosition with an overscrolled
2507         position still gets the position clamped to the content size edges.
2508
2509         Patch relaxes ::adjustScrollPositionWithinRange in that sense in order to track the actual scroll
2510         position.
2511
2512         Note: ScrollView::setScrollOffset already does something similar.
2513
2514         * platform/ScrollView.cpp:
2515         (WebCore::ScrollView::adjustScrollPositionWithinRange):
2516
2517 2012-04-20  Sheriff Bot  <webkit.review.bot@gmail.com>
2518
2519         Unreviewed, rolling out r114535.
2520         http://trac.webkit.org/changeset/114535
2521         https://bugs.webkit.org/show_bug.cgi?id=84475
2522
2523         It might have caused V8 crashes. (Requested by pfeldman_ on
2524         #webkit).
2525
2526         * bindings/v8/V8IsolatedContext.cpp:
2527         (WebCore::V8IsolatedContext::V8IsolatedContext):
2528         * bindings/v8/V8Proxy.cpp:
2529         (WebCore::V8Proxy::evaluateInIsolatedWorld):
2530         (WebCore::V8Proxy::setInjectedScriptContextDebugId):
2531         (WebCore):
2532         * bindings/v8/V8Proxy.h:
2533         (V8Proxy):
2534
2535 2012-04-20  Dean Jackson  <dino@apple.com>
2536
2537         -webkit-filter missing from computed style enumeration
2538         https://bugs.webkit.org/show_bug.cgi?id=84468
2539
2540         Reviewed by Timothy Hatcher.
2541         
2542         CSSComputedStyleDeclaration has a list of properties that it exposes.
2543         While the computed style for filter was available, the property wasn't
2544         listed and hence missing in clients like the Web Inspector.
2545
2546         Covered by existing tests.
2547
2548         * css/CSSComputedStyleDeclaration.cpp:
2549         (WebCore): add CSSPropertyWebkitFilter
2550
2551 2012-04-20  Emil A Eklund  <eae@chromium.org>
2552
2553         [win] Update windows platform code to use pixel snapped values
2554         https://bugs.webkit.org/show_bug.cgi?id=84283
2555
2556         Reviewed by Eric Seidel.
2557
2558         No new tests, no change in functionality.
2559
2560         * accessibility/AccessibilityObject.h:
2561         (WebCore::AccessibilityObject::pixelSnappedElementRect):
2562         Use pixel snapped values when computing screenRect.
2563         
2564         * platform/win/PopupMenuWin.cpp:
2565         (WebCore::PopupMenuWin::calculatePositionAndSize):
2566         (WebCore::PopupMenuWin::paint):
2567         Cast client padding to ints as they are guaranteed to align with device pixels.
2568
2569 2012-04-20  Dana Jansens  <danakj@chromium.org>
2570
2571         [chromium] Some filters require inflating damage rect in CCDamageTracker
2572         https://bugs.webkit.org/show_bug.cgi?id=84373
2573
2574         Reviewed by James Robinson.
2575
2576         When a layer is blurred, damaged pixels are blurred out into a radius
2577         and their damage should be expanded to include total blurred region.
2578
2579         Unit test: CCDamageTrackerTest.verifyDamageForBlurredSurface
2580
2581         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
2582         (WebCore::CCDamageTracker::updateDamageTrackingState):
2583         (WebCore::CCDamageTracker::expandDamageRectWithForegroundFilters):
2584         (WebCore):
2585         * platform/graphics/chromium/cc/CCDamageTracker.h:
2586         (WebCore):
2587         (CCDamageTracker):
2588         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2589         (WebCore::CCLayerTreeHostImpl::trackDamageForAllSurfaces):
2590
2591 2012-04-20  Sami Kyostila  <skyostil@chromium.org>
2592
2593         [chromium] Don't crash when scrolling empty layer tree
2594         https://bugs.webkit.org/show_bug.cgi?id=84455
2595
2596         Reviewed by James Robinson.
2597
2598         Do not try to calculate render passes when there are no layers in the
2599         layer tree.
2600
2601         Added new unit test.
2602
2603         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2604         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
2605
2606 2012-04-20  Victor Carbune  <vcarbune@adobe.com>
2607
2608         Ensure text is centered for default captions
2609         https://bugs.webkit.org/show_bug.cgi?id=84450
2610
2611         Reviewed by Eric Carlson.
2612
2613         Updated existing test.
2614
2615         * html/track/TextTrackCue.cpp:
2616         (WebCore::TextTrackCue::getDisplayTree): Added default width.
2617
2618 2012-04-20  Pavel Feldman  <pfeldman@chromium.org>
2619
2620         Web Inspector: open file dialog is not centered.
2621         https://bugs.webkit.org/show_bug.cgi?id=84464
2622
2623         Reviewed by Yury Semikhatsky.
2624
2625         There was an error in the positioning logic.
2626
2627         * inspector/front-end/FilteredItemSelectionDialog.js:
2628         (WebInspector.FilteredItemSelectionDialog.prototype.position):
2629
2630 2012-04-20  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2631
2632         [Qt] PlatformMouseEventQt.cpp should be deleted.
2633         https://bugs.webkit.org/show_bug.cgi?id=84437
2634
2635         Reviewed by Kenneth Rohde Christiansen.
2636
2637         * platform/qt/PlatformMouseEventQt.cpp: Removed.
2638
2639 2012-04-20  Pavel Feldman  <pfeldman@chromium.org>
2640
2641         Web Inspector: follow up to r114729: more @return annotations added.
2642         https://bugs.webkit.org/show_bug.cgi?id=84447
2643
2644         Reviewed by Yury Semikhatsky.
2645
2646         * inspector/front-end/Resource.js:
2647         (WebInspector.Resource):
2648         (WebInspector.ResourceRevision.prototype.get content):
2649         * inspector/front-end/ResourceTreeModel.js:
2650         (WebInspector.ResourceTreeFrame.prototype._addRequest):
2651         * inspector/front-end/ResourceUtils.js:
2652         (String.prototype.asParsedURL):
2653
2654 2012-04-20  Pavel Feldman  <pfeldman@chromium.org>
2655
2656         Web Inspector: migrate from ScriptsNavigator to NavigatorView in the Styles panel
2657         https://bugs.webkit.org/show_bug.cgi?id=84459
2658
2659         Reviewed by Yury Semikhatsky.
2660
2661         Now that NavigatorView has all the functionality we need, we can use it.
2662
2663         * inspector/front-end/NavigatorView.js:
2664         (WebInspector.NavigatorScriptTreeElement.prototype.ondblclick):
2665         * inspector/front-end/ScriptsNavigator.js:
2666         (WebInspector.ScriptsNavigator):
2667         * inspector/front-end/StylesPanel.js:
2668         (WebInspector.StylesPanel):
2669         (WebInspector.StylesPanel.prototype._resourceAdded):
2670         (WebInspector.StylesPanel.prototype._reset):
2671         (WebInspector.StylesPanel.prototype._itemSelected):
2672         (WebInspector.StylesPanel.prototype._showFile):
2673         * inspector/front-end/navigatorView.css:
2674         (.navigator-tabbed-pane .tabbed-pane-content):
2675         (.navigator-tabbed-pane .navigator-container):
2676         (.navigator-tabbed-pane .navigator):
2677         (.navigator-tabbed-pane .tabbed-pane-header):
2678         (.navigator-tabbed-pane .tabbed-pane-header-contents):
2679         * inspector/front-end/scriptsPanel.css:
2680
2681 2012-04-20  Sam D  <dsam2912@gmail.com>
2682
2683         Web Inspector: Does not have search navigation button for going through matches in either direction (prev, next)
2684         https://bugs.webkit.org/show_bug.cgi?id=84235
2685
2686         Added buttons for navigating on seiarch matches in inspector panel
2687         through button clicks as well. 
2688
2689         Reviewed by Pavel Feldman.
2690
2691         No new tests / ux enhanced for search functionality
2692
2693         * English.lproj/localizedStrings.js:
2694         * WebCore.gypi:
2695         * inspector/front-end/Images/searchNext.png: Added.
2696         * inspector/front-end/Images/searchPrev.png: Added.
2697         * inspector/front-end/SearchController.js:
2698         (WebInspector.SearchController):
2699         (WebInspector.SearchController.prototype._updateSearchNavigationButtonState):
2700         (WebInspector.SearchController.prototype._updateSearchMatchesCountAndCurrentMatchIndex):
2701         (WebInspector.SearchController.prototype._onNextButtonSearch):
2702         (WebInspector.SearchController.prototype._onPrevButtonSearch):
2703         (WebInspector.SearchController.prototype._performSearch):
2704         (WebInspector.SearchController.prototype._createSearchNavigationButton):
2705         (WebInspector.SearchController.prototype._populateSearchNavigationButtons):
2706         * inspector/front-end/WebKit.qrc:
2707         * inspector/front-end/inspector.css:
2708         (.toolbar-search-item):
2709         (#search):
2710         (#toolbar-search-navigation-control):
2711         (.toolbar-search-navigation-label):
2712         (.toolbar-search-navigation-label:hover):
2713         (.toolbar-search-navigation-icon-prev , .toolbar-search-navigation-icon-next):
2714         (.toolbar-search-navigation-icon-prev):
2715         (.toolbar-search-navigation-icon-next):
2716         * inspector/front-end/inspector.html:
2717
2718 2012-04-20  Pavel Feldman  <pfeldman@chromium.org>
2719
2720         Web Inspector: extract NavigatorView and NavigatorOverlayController from ScriptsNavigator.
2721         https://bugs.webkit.org/show_bug.cgi?id=84441
2722
2723         Reviewed by Yury Semikhatsky.
2724
2725         - Moves NavigatorOverlayController out of ScriptsNavigator
2726         - Extracts NavigatorView from ScriptsNavigator and makes ScriptsNavigator contain 3 NavigatorView instances (one per tab)
2727         - Subclasses SnippetsNavigatorView and leaves it within ScriptsNavigator.
2728
2729         * WebCore.gypi:
2730         * WebCore.vcproj/WebCore.vcproj:
2731         * inspector/compile-front-end.py:
2732         * inspector/front-end/NavigatorOverlayController.js: Added.
2733         (WebInspector.NavigatorOverlayController.prototype.wasShown):
2734         (WebInspector.NavigatorOverlayController.prototype._createNavigatorControlButton):
2735         (WebInspector.NavigatorOverlayController.prototype._escDownWhileNavigatorOverlayOpen):
2736         (WebInspector.NavigatorOverlayController.prototype._toggleNavigator):
2737         (WebInspector.NavigatorOverlayController.prototype._hidePinnedNavigator):
2738         (WebInspector.NavigatorOverlayController.prototype.set _pinNavigator):
2739         (WebInspector.NavigatorOverlayController.prototype.set showNavigatorOverlay):
2740         (WebInspector.NavigatorOverlayController.prototype.hideNavigatorOverlay):
2741         (WebInspector.NavigatorOverlayController.prototype._navigatorOverlayWasShown):
2742         * inspector/front-end/NavigatorView.js: Added.
2743         (WebInspector.NavigatorView):
2744         (WebInspector.NavigatorView.prototype._updateScriptTitle.get if):
2745         (WebInspector.NavigatorView.prototype._updateScriptTitle):
2746         (WebInspector.NavigatorView.prototype._scriptSelected):
2747         (WebInspector.NavigatorView.prototype._removeUISourceCode.get while):
2748         (WebInspector.NavigatorView.prototype._removeUISourceCode):
2749         (WebInspector.NavigatorView.prototype._showScriptFoldersSettingChanged):
2750         (WebInspector.NavigatorView.prototype._fileRenamed):
2751         (WebInspector.NavigatorView.prototype.rename.commitHandler):
2752         (WebInspector.NavigatorView.prototype.rename.cancelHandler):
2753         (WebInspector.NavigatorView.prototype.rename.afterEditing):
2754         (WebInspector.NavigatorView.prototype.reset):
2755         (WebInspector.NavigatorView.prototype.createFolderTreeElement):
2756         (WebInspector.NavigatorView.prototype.getOrCreateFolderTreeElement):
2757         (WebInspector.NavigatorView.prototype.handleContextMenu):
2758         (WebInspector.NavigatorTreeOutline):
2759         (WebInspector.NavigatorTreeOutline._treeElementsCompare.compare.typeWeight):
2760         (WebInspector.NavigatorTreeOutline._treeElementsCompare):
2761         (WebInspector.NavigatorTreeOutline.prototype.scriptTreeElements):
2762         (WebInspector.NavigatorTreeOutline.prototype.searchStarted):
2763         (WebInspector.NavigatorTreeOutline.prototype.searchFinished):
2764         (WebInspector.BaseNavigatorTreeElement):
2765         (WebInspector.BaseNavigatorTreeElement.prototype.onattach):
2766         (WebInspector.BaseNavigatorTreeElement.prototype.onreveal):
2767         (WebInspector.BaseNavigatorTreeElement.prototype.get titleText):
2768         (WebInspector.BaseNavigatorTreeElement.prototype.set titleText):
2769         (WebInspector.BaseNavigatorTreeElement.prototype.matchesSearchText):
2770         (WebInspector.NavigatorFolderTreeElement):
2771         (WebInspector.NavigatorFolderTreeElement.prototype.get folderIdentifier):
2772         (WebInspector.NavigatorFolderTreeElement.prototype.get isDomain):
2773         (WebInspector.NavigatorFolderTreeElement.prototype.onattach):
2774         (WebInspector.NavigatorScriptTreeElement):
2775         (WebInspector.NavigatorScriptTreeElement.prototype.get uiSourceCode):
2776         (WebInspector.NavigatorScriptTreeElement.prototype.onattach):
2777         (WebInspector.NavigatorScriptTreeElement.prototype.onspace):
2778         (WebInspector.NavigatorScriptTreeElement.prototype._onclick):
2779         (WebInspector.NavigatorScriptTreeElement.prototype.onenter):
2780         (WebInspector.NavigatorScriptTreeElement.prototype._handleContextMenuEvent):
2781         * inspector/front-end/ScriptsNavigator.js:
2782         (WebInspector.ScriptsNavigator):
2783         (WebInspector.ScriptsNavigator.prototype.addUISourceCode):
2784         (WebInspector.ScriptsNavigator.prototype.isScriptSourceAdded):
2785         (WebInspector.ScriptsNavigator.prototype.revealUISourceCode):
2786         (WebInspector.ScriptsNavigator.prototype.replaceUISourceCodes):
2787         (WebInspector.ScriptsNavigator.prototype._scriptSelected):
2788         (WebInspector.ScriptsNavigator.prototype.reset):
2789         (WebInspector.SnippetsNavigatorView):
2790         (WebInspector.SnippetsNavigatorView.prototype.getOrCreateFolderTreeElement):
2791         (WebInspector.SnippetsNavigatorView.prototype._getOrCreateSnippetEvaluationsFolderTreeElement):
2792         (WebInspector.SnippetsNavigatorView.prototype.handleContextMenu):
2793         (WebInspector.SnippetsNavigatorView.prototype._fileRenamed):
2794         * inspector/front-end/WebKit.qrc:
2795         * inspector/front-end/inspector.html:
2796         * inspector/front-end/navigatorView.css: Added.
2797         (.navigator-domain-tree-item .icon):
2798         (.navigator-folder-tree-item .icon):
2799         (.navigator-script-tree-item .icon):
2800         (.navigator li):
2801         (.navigator :focus li.selected):
2802         (.navigator li.selected .selection):
2803         (.navigator :focus li.selected .selection):
2804         (.navigator .search-match-found li.selected .selection):
2805         (.navigator .search-match-not-found li.selected .selection):
2806         (.navigator .searching li.selected .selection):
2807         (.navigator .icon):
2808         (.navigator .base-navigator-tree-element-title):
2809         (.navigator .base-navigator-tree-element-title.editing):
2810         (.navigator-tree-search-box):
2811         (.navigator-tree-search-box.visible):
2812         (.navigator-tree-search-box > input):
2813         * inspector/front-end/scriptsPanel.css:
2814
2815 2012-04-19  Pavel Feldman  <pfeldman@chromium.org>
2816
2817         Web Inspector: make ScriptNavigatorController use views only, rename to NavigatorOverlayController.
2818         https://bugs.webkit.org/show_bug.cgi?id=84352
2819
2820         Reviewed by Vsevolod Vlasov.
2821
2822         This change makes navigator controller use view interfaces only. Focus machinery has been refactored in order
2823         to make it possible: now all view ancestors can either override "focus" or "defaultFocusedElement" method
2824         with latter method being preferred.
2825
2826         * inspector/front-end/ElementsPanel.js:
2827         (WebInspector.ElementsPanel.prototype.defaultFocusedElement):
2828         * inspector/front-end/ExtensionPanel.js:
2829         (WebInspector.ExtensionPanel.prototype.defaultFocusedElement):
2830         * inspector/front-end/Panel.js:
2831         (WebInspector.Panel.prototype.wasShown):
2832         (WebInspector.Panel.prototype.defaultFocusedElement):
2833         * inspector/front-end/ScriptsNavigator.js:
2834         (WebInspector.ScriptsNavigator):
2835         (WebInspector.NavigatorOverlayController.prototype._hidePinnedNavigator):
2836         (WebInspector.NavigatorOverlayController.prototype.set _pinNavigator):
2837         (WebInspector.NavigatorOverlayController.prototype.set showNavigatorOverlay):
2838         (WebInspector.NavigatorOverlayController.prototype.hideNavigatorOverlay):
2839         (WebInspector.NavigatorOverlayController.prototype._navigatorOverlayWasShown):
2840         * inspector/front-end/ScriptsPanel.js:
2841         (WebInspector.ScriptsPanel.prototype.defaultFocusedElement):
2842         * inspector/front-end/SidebarOverlay.js:
2843         (WebInspector.SidebarOverlay.prototype.show):
2844         (WebInspector.SidebarOverlay.prototype.hide):
2845         * inspector/front-end/SourceFrame.js:
2846         (WebInspector.SourceFrame.prototype.defaultFocusedElement):
2847         * inspector/front-end/StylesPanel.js:
2848         (WebInspector.StylesPanel):
2849         * inspector/front-end/TabbedEditorContainer.js:
2850         (WebInspector.TabbedEditorContainer.prototype.get view):
2851         (WebInspector.TabbedEditorContainer.prototype.get visibleView):
2852         * inspector/front-end/TabbedPane.js:
2853         (WebInspector.TabbedPane):
2854         (WebInspector.TabbedPane.prototype.defaultFocusedElement):
2855         * inspector/front-end/TextViewer.js:
2856         (WebInspector.TextViewer.prototype.defaultFocusedElement):
2857         (WebInspector.TextEditorMainPanel.prototype.defaultFocusedElement):
2858         * inspector/front-end/TimelinePanel.js:
2859         (WebInspector.TimelinePanel.prototype.defaultFocusedElement):
2860         * inspector/front-end/View.js:
2861         (WebInspector.View.prototype._collectViewHierarchy):
2862         (WebInspector.View.prototype.defaultFocusedElement):
2863         (WebInspector.View.prototype.setDefaultFocusedElement):
2864         (WebInspector.View.prototype.focus):
2865
2866 2012-04-20  Sergio Villar Senin  <svillar@igalia.com>
2867
2868         [GTK] Enable Web Timing
2869         https://bugs.webkit.org/show_bug.cgi?id=42432
2870
2871         Reviewed by Gustavo Noronha Silva.
2872
2873         Added WebTiming support to the GTK+ port. WebTiming allows
2874         developers to collect detailed network timing information per
2875         resource. It requires the new SoupMessage's "network-event"
2876         signal.
2877
2878         * GNUmakefile.am:
2879         * bindings/gobject/GNUmakefile.am:
2880         * platform/network/soup/ResourceHandleSoup.cpp:
2881         (WebCore):
2882         (WebCore::restartedCallback):
2883         (WebCore::sendRequestCallback):
2884         (WebCore::milisecondsSinceRequest):
2885         (WebCore::wroteBodyCallback):
2886         (WebCore::requestStartedCallback):
2887         (WebCore::networkEventCallback):
2888         (WebCore::startHTTPRequest):
2889         (WebCore::ResourceHandle::platformSetDefersLoading):
2890         (WebCore::ResourceHandle::defaultSession):
2891
2892 2012-04-20  'Pavel Feldman'  <pfeldman@chromium.org>
2893
2894         Not reviewed: fixed chromium sanity tests for inspector via assigning last path component
2895         to entire url for parsed urls with invalid specs.
2896
2897         * inspector/front-end/ResourceUtils.js:
2898         (WebInspector.ParsedURL):
2899
2900 2012-04-20  Kentaro Hara  <haraken@chromium.org>
2901
2902         Unreviewed, rolling out r114401.
2903         http://trac.webkit.org/changeset/114401
2904         https://bugs.webkit.org/show_bug.cgi?id=84161
2905
2906         Chromium crash
2907
2908         * bindings/scripts/CodeGeneratorV8.pm:
2909         (GenerateHeader):
2910         (NativeToJSValue):
2911         * bindings/scripts/test/V8/V8Float64Array.h:
2912         (WebCore):
2913         (WebCore::toV8):
2914         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
2915         (WebCore::toV8):
2916         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
2917         (WebCore::toV8):
2918         * bindings/scripts/test/V8/V8TestEventConstructor.h:
2919         (WebCore::toV8):
2920         * bindings/scripts/test/V8/V8TestEventTarget.h:
2921         (WebCore::toV8):
2922         * bindings/scripts/test/V8/V8TestInterface.h:
2923         (WebCore::toV8):
2924         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
2925         (WebCore::toV8):
2926         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
2927         (WebCore::toV8):
2928         * bindings/scripts/test/V8/V8TestNode.h:
2929         (WebCore::toV8):
2930         * bindings/scripts/test/V8/V8TestObj.h:
2931         (WebCore::toV8):
2932         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2933         (WebCore::toV8):
2934         * bindings/v8/custom/V8BlobCustom.cpp:
2935         (WebCore::toV8):
2936         * bindings/v8/custom/V8CSSRuleCustom.cpp:
2937         (WebCore::toV8):
2938         * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
2939         (WebCore::toV8):
2940         * bindings/v8/custom/V8CSSValueCustom.cpp:
2941         (WebCore::toV8):
2942         * bindings/v8/custom/V8CanvasPixelArrayCustom.cpp:
2943         (WebCore::toV8):
2944         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
2945         (WebCore::toV8):
2946         * bindings/v8/custom/V8DOMTokenListCustom.cpp:
2947         (WebCore::toV8):
2948         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2949         (WebCore::toV8):
2950         * bindings/v8/custom/V8DataViewCustom.cpp:
2951         (WebCore::toV8):
2952         * bindings/v8/custom/V8DocumentCustom.cpp:
2953         (WebCore::toV8):
2954         * bindings/v8/custom/V8EntryCustom.cpp:
2955         (WebCore::toV8):
2956         * bindings/v8/custom/V8EntrySyncCustom.cpp:
2957         (WebCore::toV8):
2958         * bindings/v8/custom/V8EventCustom.cpp:
2959         (WebCore::toV8):
2960         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
2961         (WebCore::toV8):
2962         * bindings/v8/custom/V8Float64ArrayCustom.cpp:
2963         (WebCore::toV8):
2964         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
2965         (WebCore::toV8):
2966         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
2967         (WebCore::toV8):
2968         * bindings/v8/custom/V8HTMLElementCustom.cpp:
2969         (WebCore::toV8):
2970         * bindings/v8/custom/V8IDBAnyCustom.cpp:
2971         (WebCore::toV8):
2972         * bindings/v8/custom/V8IDBKeyCustom.cpp:
2973         (WebCore::toV8):
2974         * bindings/v8/custom/V8ImageDataCustom.cpp:
2975         (WebCore::toV8):
2976         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
2977         (WebCore::toV8):
2978         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
2979         (WebCore::toV8):
2980         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
2981         (WebCore::toV8):
2982         * bindings/v8/custom/V8LocationCustom.cpp:
2983         (WebCore::toV8):
2984         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
2985         (WebCore::toV8):
2986         * bindings/v8/custom/V8NodeCustom.cpp:
2987         (WebCore::toV8Slow):
2988         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
2989         (WebCore::toV8):
2990         * bindings/v8/custom/V8SVGElementCustom.cpp:
2991         (WebCore::toV8):
2992         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
2993         (WebCore::toV8):
2994         * bindings/v8/custom/V8ScriptProfileCustom.cpp:
2995         (WebCore::toV8):
2996         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp:
2997         (WebCore::toV8):
2998         * bindings/v8/custom/V8StyleSheetCustom.cpp:
2999         (WebCore::toV8):
3000         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
3001         (WebCore::toV8):
3002         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
3003         (WebCore::toV8):
3004         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
3005         (WebCore::toV8):
3006         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp:
3007         (WebCore::toV8):
3008         * bindings/v8/custom/V8WorkerContextCustom.cpp:
3009         (WebCore::toV8):
3010
3011 2012-04-20  Kentaro Hara  <haraken@chromium.org>
3012
3013         Unreviewed, rolling out r114440.
3014         http://trac.webkit.org/changeset/114440
3015         https://bugs.webkit.org/show_bug.cgi?id=84173
3016
3017         Chromium crash
3018
3019         * bindings/scripts/CodeGeneratorV8.pm:
3020         (GenerateHeader):
3021         * bindings/v8/custom/V8NodeCustom.cpp:
3022         (WebCore::toV8Slow):
3023
3024 2012-04-20  Kentaro Hara  <haraken@chromium.org>
3025
3026         Unreviewed, rolling out r114519.
3027         http://trac.webkit.org/changeset/114519
3028         https://bugs.webkit.org/show_bug.cgi?id=84202
3029
3030         Chromium crash
3031
3032         * bindings/scripts/CodeGeneratorV8.pm:
3033         (GenerateHeader):
3034         * bindings/scripts/test/V8/V8Float64Array.h:
3035         (V8Float64Array):
3036         (WebCore::V8Float64Array::wrap):
3037         (WebCore):
3038         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
3039         (V8TestActiveDOMObject):
3040         (WebCore::V8TestActiveDOMObject::wrap):
3041         (WebCore::toV8):
3042         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
3043         (V8TestCustomNamedGetter):
3044         (WebCore::V8TestCustomNamedGetter::wrap):
3045         (WebCore::toV8):
3046         * bindings/scripts/test/V8/V8TestEventConstructor.h:
3047         (V8TestEventConstructor):
3048         (WebCore::V8TestEventConstructor::wrap):
3049         (WebCore::toV8):
3050         * bindings/scripts/test/V8/V8TestEventTarget.h:
3051         (V8TestEventTarget):
3052         (WebCore::V8TestEventTarget::wrap):
3053         (WebCore::toV8):
3054         * bindings/scripts/test/V8/V8TestInterface.h:
3055         (V8TestInterface):
3056         (WebCore::V8TestInterface::wrap):
3057         (WebCore::toV8):
3058         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
3059         (V8TestMediaQueryListListener):
3060         (WebCore::V8TestMediaQueryListListener::wrap):
3061         (WebCore::toV8):
3062         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
3063         (V8TestNamedConstructor):
3064         (WebCore::V8TestNamedConstructor::wrap):
3065         (WebCore::toV8):
3066         * bindings/scripts/test/V8/V8TestNode.h:
3067         (V8TestNode):
3068         (WebCore::V8TestNode::wrap):
3069         (WebCore::toV8):
3070         * bindings/scripts/test/V8/V8TestObj.h:
3071         (V8TestObj):
3072         (WebCore::V8TestObj::wrap):
3073         (WebCore::toV8):
3074         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
3075         (V8TestSerializedScriptValueInterface):
3076         (WebCore::V8TestSerializedScriptValueInterface::wrap):
3077         (WebCore::toV8):
3078         * bindings/v8/custom/V8DocumentCustom.cpp:
3079         (WebCore::toV8):
3080         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
3081         (WebCore::toV8):
3082         * bindings/v8/custom/V8NodeCustom.cpp:
3083         (WebCore::toV8Slow):
3084         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
3085         (WebCore::toV8):
3086         * dom/make_names.pl:
3087         (printWrapperFactoryCppFile):
3088
3089 2012-04-19  Pavel Feldman  <pfeldman@chromium.org>
3090
3091         Web Inspector: replace @type annotation with @return annotation for getters
3092         https://bugs.webkit.org/show_bug.cgi?id=84362
3093
3094         Reviewed by Yury Semikhatsky.
3095
3096         Otherwise, compiler does not check for errors.
3097
3098         * inspector/front-end/AdvancedSearchController.js:
3099         (WebInspector.SearchView.prototype.get searchConfig):
3100         * inspector/front-end/BreakpointManager.js:
3101         * inspector/front-end/NetworkRequest.js:
3102         (WebInspector.NetworkRequest.prototype.requestContent):
3103         * inspector/front-end/ResourceTreeModel.js:
3104         (WebInspector.ResourceTreeFrame):
3105         (WebInspector.ResourceTreeFrame.prototype._navigate):
3106         * inspector/front-end/ScriptsNavigator.js:
3107         * inspector/front-end/Settings.js:
3108         * inspector/front-end/SnippetsModel.js:
3109         * inspector/front-end/SplitView.js:
3110         * inspector/front-end/TabbedEditorContainer.js:
3111         * inspector/front-end/TabbedPane.js:
3112         (WebInspector.TabbedPaneTab):
3113         * inspector/front-end/TextEditorModel.js:
3114         * inspector/front-end/TimelinePresentationModel.js:
3115
3116 2012-04-20  Mark Pilgrim  <pilgrim@chromium.org>
3117
3118         [Chromium] Call cacheMetadata directly
3119         https://bugs.webkit.org/show_bug.cgi?id=84415
3120
3121         Reviewed by Kentaro Hara.
3122
3123         Part of a refactoring series. See tracking bug 82948.
3124
3125         * platform/chromium/PlatformSupport.h:
3126         (PlatformSupport):
3127         * platform/network/chromium/ResourceHandle.cpp:
3128         (WebCore::ResourceHandle::cacheMetadata):
3129
3130 2012-04-20  Mark Pilgrim  <pilgrim@chromium.org>
3131
3132         [Chromium] Call stopSharedTimer directly
3133         https://bugs.webkit.org/show_bug.cgi?id=84418
3134
3135         Reviewed by Kentaro Hara.
3136
3137         Part of a refactoring series. See tracking bug 82948.
3138
3139         * platform/chromium/PlatformSupport.h:
3140         (PlatformSupport):
3141         * platform/chromium/SharedTimerChromium.cpp:
3142         (WebCore::stopSharedTimer):
3143
3144 2012-04-20  Taiju Tsuiki  <tzik@chromium.org>
3145
3146         DOMFileSystem::scheduleCallback() crashes on file() call after reload.
3147         https://bugs.webkit.org/show_bug.cgi?id=76461
3148
3149         DOMFileSystem::scheduleCallback() is unavailable when the page in unloading, so we should
3150         avoid using it in callback.
3151
3152         Reviewed by David Levin.
3153
3154         Test: fast/filesystem/file-after-reload-crash.html
3155
3156         * Modules/filesystem/DOMFileSystem.cpp:
3157         (WebCore):
3158
3159 2012-04-19  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
3160
3161         [EFL] Missing keycode translation for space key
3162         https://bugs.webkit.org/show_bug.cgi?id=84153
3163
3164         Reviewed by Antonio Gomes.
3165
3166         Map space key to Unicode value in createKeyMap(), and also set
3167         correct keyname 'space' for space key in createWindowsKeyMap().
3168
3169         Tests: fast/html/details-keyboard-show-hide.html
3170                fast/forms/button-spacebar-click.html
3171
3172         * platform/efl/EflKeyboardUtilities.cpp:
3173         (WebCore::createKeyMap):
3174
3175 2012-04-19  Antaryami Pandia  <antaryami.pandia@motorola.com>
3176
3177         Inserting empty html moves caret.
3178         https://bugs.webkit.org/show_bug.cgi?id=71771
3179
3180         Reviewed by Ryosuke Niwa.
3181
3182         When we place the cursor in the middle of a text node and try to insert some text
3183         between, then we split text node. But in this case we have nothing to insert since
3184         the string to be inserted is empty. So the check for fragments should precedes the
3185         call to code block containing splitTextNode.
3186
3187         Test: editing/inserting/insert-empty-html.html
3188
3189         * editing/ReplaceSelectionCommand.cpp:
3190         (WebCore::ReplaceSelectionCommand::doApply):
3191
3192 2012-04-19  Tay Grigg  <tgrigg@rim.com>
3193
3194         [BlackBerry] Update HTTP connection per host limit in ResourceRequestBlackBerry
3195         https://bugs.webkit.org/show_bug.cgi?id=84380
3196
3197         Reviewed by George Staikos.
3198
3199         Reviewed Internally by: George Rizkalla, Lyon Chen
3200
3201         Set the limit on the http connection count per host to the default
3202         of 10000, queue the requests in the networking layer instead,
3203         this should increase parallelism at the WebKit layer to remove
3204         any potential bottlenecks.
3205
3206         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
3207         (WebCore::initializeMaximumHTTPConnectionCountPerHost):
3208
3209 2012-04-19  Sheriff Bot  <webkit.review.bot@gmail.com>
3210
3211         Unreviewed, rolling out r114711.
3212         http://trac.webkit.org/changeset/114711
3213         https://bugs.webkit.org/show_bug.cgi?id=84412
3214
3215         Many tests crash in RenderObject::container() (Requested by
3216         dimich on #webkit).
3217
3218         * page/scrolling/ScrollingCoordinator.cpp:
3219         (WebCore::computeNonFastScrollableRegion):
3220         (WebCore::ScrollingCoordinator::frameViewLayoutUpdated):
3221         (WebCore::ScrollingCoordinator::frameViewScrollableAreasDidChange):
3222
3223 2012-04-19  Anders Carlsson  <andersca@apple.com>
3224
3225         computeNonFastScrollableRegion needs to traverse the entire frame tree
3226         https://bugs.webkit.org/show_bug.cgi?id=84409
3227         <rdar://problem/11285741>
3228
3229         Reviewed by Dan Bernstein.
3230
3231         Now that scrollable areas won't be in the set of scrollable areas unless they are actually scrollable, we need to look for scrollable
3232         areas in the entire frame tree since there can be a scrollable frame that's a subframe of a non-scrollable frame for example.
3233
3234         * page/scrolling/ScrollingCoordinator.cpp:
3235         (WebCore::computeNonFastScrollableRegion):
3236         Traverse the entire frame tree looking for scrollable areas. Also, remove the scrollability checks because scrollable areas will only be
3237         in the set if they have scrollbars that are enabled.
3238
3239         (WebCore::ScrollingCoordinator::frameViewLayoutUpdated):
3240         (WebCore::ScrollingCoordinator::frameViewScrollableAreasDidChange):
3241         computeNonFastScrollableRegion now takes the main frame.
3242
3243 2012-04-19  Anders Carlsson  <andersca@apple.com>
3244
3245         Focus ring on wikipedia gets blobs when you type
3246         https://bugs.webkit.org/show_bug.cgi?id=84407
3247         <rdar://problem/11011847>
3248
3249         Reviewed by Dan Bernstein.
3250
3251         Make it possible to override the focus ring visible rect from layer drawing code.
3252
3253         * platform/graphics/mac/WebLayer.mm:
3254         (drawLayerContents):
3255         Call ThemeMac::setFocusRingClipRect to set the focus ring clip rect while drawing.
3256
3257         * platform/mac/ThemeMac.h:
3258         * platform/mac/ThemeMac.mm:
3259         (-[WebCoreFlippedView _focusRingVisibleRect]):
3260         If there's an active focus ring visible rect, use it. Otherwise, fall back to the previous behavior
3261         and just return the view's visible rect.
3262
3263         (WebCore::ThemeMac::setFocusRingClipRect):
3264         Update the focus clip rect.
3265
3266 2012-04-19  Sheriff Bot  <webkit.review.bot@gmail.com>
3267
3268         Unreviewed, rolling out r114690.
3269         http://trac.webkit.org/changeset/114690
3270         https://bugs.webkit.org/show_bug.cgi?id=84408
3271
3272         Broke GlueSerializeTest.BackwardsCompatibleTest in Chromium
3273         test_shell_tests (Requested by dimich on #webkit).
3274
3275         * history/HistoryItem.cpp:
3276         (WebCore::HistoryItem::HistoryItem):
3277         * loader/HistoryController.cpp:
3278         (WebCore::HistoryController::restoreScrollPositionAndViewState):
3279
3280 2012-04-19  Andreas Kling  <kling@webkit.org>
3281
3282         ElementAttributeData should be fast-malloc'd.
3283         <http://webkit.org/b/84405>
3284
3285         Reviewed by Antti Koivisto.
3286
3287         Sprinkle missing WTF_MAKE_FAST_ALLOCATED.
3288
3289         * dom/ElementAttributeData.h:
3290         (ElementAttributeData):
3291
3292 2012-04-19  David Barr  <davidbarr@chromium.org>
3293
3294         REGRESSION(r112177): Numbered list item rendered bulleted
3295         https://bugs.webkit.org/show_bug.cgi?id=84216
3296
3297         Reviewed by Ryosuke Niwa.
3298
3299         Shorthands that imply omitted values cannot be derived from
3300         an incomplete set of longhand rules.
3301
3302         No new tests; updated existing tests that should have caught this.
3303
3304         * css/CSSParser.cpp:
3305         (WebCore::CSSParser::parseTransformOriginShorthand):
3306         Set implicit initial for Z when omitted.
3307         * css/StylePropertySet.cpp:
3308         (WebCore::StylePropertySet::getShorthandValue):
3309
3310 2012-04-19  Peter Beverloo  <peter@chromium.org>
3311
3312         [Chromium] Don't compile FontCacheSkia for Android
3313         https://bugs.webkit.org/show_bug.cgi?id=84392
3314
3315         Reviewed by Kent Tamura.
3316
3317         Chromium for the Android platform uses its own FontCacheAndroid
3318         implementation. Compile errors show up when trying to build the
3319         content shell.
3320
3321         * WebCore.gyp/WebCore.gyp:
3322
3323 2012-04-19  Martin Robinson  <mrobinson@igalia.com>
3324
3325         [Cairo] Remove rgb24-hacks.txt and scale-removal.txt
3326         https://bugs.webkit.org/show_bug.cgi?id=83475
3327
3328         Reviewed by Daniel Bates.
3329
3330         No new tests. This does not change functionality.
3331
3332         Remove some obsolete patch files for Cairo that were used in some
3333         very old versions of Safari for Windows.
3334
3335         * platform/graphics/cairo/rgb24-hacks.txt: Removed.
3336         * platform/graphics/cairo/scale-removal.txt: Removed.
3337
3338 2012-04-19  Peter Beverloo  <peter@chromium.org>
3339
3340         Use sqrtf instead of sqrt in CanvasRenderingContext2D.cpp
3341         https://bugs.webkit.org/show_bug.cgi?id=84403
3342
3343         Reviewed by Andreas Kling.
3344
3345         r114679 broke Chromium Win and Android bots due to call
3346         ambiguity between a double and float argument.
3347
3348         * html/canvas/CanvasRenderingContext2D.cpp:
3349         (WebCore::CanvasRenderingContext2D::inflateStrokeRect):
3350
3351 2012-04-19  Alexandre Elias  <aelias@google.com>
3352
3353         Default to null value for HistoryItem::m_pageScaleFactor
3354         https://bugs.webkit.org/show_bug.cgi?id=84385
3355
3356         Reviewed by Nate Chapin.
3357
3358         Previously, HistoryItem::m_pageScaleFactor defaulted to a value
3359         of 1, making it impossible to determine whether this value was never
3360         set, or intentionally set to 1.  This patch introduces a default value
3361         of 0 and makes restoreScrollPositionAndViewState not touch the page
3362         scale factor if this value is still present at time of reload.
3363
3364         This is a no-op change for common navigation scenarios.  The
3365         motivation for this change is the corner case of syncing history items
3366         from a desktop browser to a mobile device.  In that case, we need a
3367         way to specify that the history item does not contain a
3368         pageScaleFactor so that the mobile device does not display the page
3369         overly zoomed in.
3370
3371         No new tests.
3372
3373         * history/HistoryItem.cpp:
3374         (WebCore::HistoryItem::HistoryItem):
3375         * loader/HistoryController.cpp:
3376         (WebCore::HistoryController::restoreScrollPositionAndViewState):
3377
3378 2012-04-19  Alexis Menard  <alexis.menard@openbossa.org>
3379
3380         Unreviewed Qt build warning fix.
3381
3382         The file editing/StringHelper.h does not exist.
3383
3384         * Target.pri:
3385
3386 2012-04-19  Daniel Bates  <dbates@webkit.org>
3387
3388         Remove empty directory Source/WebCore/webaudio
3389
3390         Changeset 111474 <http://trac.webkit.org/changeset/111474> moved all the files in
3391         Source/WebCore/webaudio to Source/WebCore/Modules/webaudio. We should remove the
3392         empty directory Source/WebCore/webaudio.
3393
3394         * webaudio: Removed.
3395
3396 2012-04-19  Pratik Solanki  <psolanki@apple.com>
3397
3398         Incorrect inter-caps in “ShouldSkipMetaData” etc.
3399         https://bugs.webkit.org/show_bug.cgi?id=72159
3400
3401         Reviewed by Dan Bernstein.
3402
3403         No new tests since no change in functionality.
3404
3405         * platform/graphics/ImageSource.h:
3406         * platform/graphics/cg/ImageSourceCG.cpp:
3407         (WebCore::imageSourceOptions):
3408         (WebCore::ImageSource::isSizeAvailable):
3409         (WebCore::ImageSource::frameSizeAtIndex):
3410         (WebCore::ImageSource::orientationAtIndex):
3411         (WebCore::ImageSource::getHotSpot):
3412         (WebCore::ImageSource::repetitionCount):
3413         (WebCore::ImageSource::createFrameAtIndex):
3414         (WebCore::ImageSource::frameDurationAtIndex):
3415
3416 2012-04-19  Huang Dongsung  <luxtella@company100.net>
3417
3418         Canvas more precisely makes the bounding rect for stroke rendering.
3419         https://bugs.webkit.org/show_bug.cgi?id=75792
3420
3421         Reviewed by Simon Fraser.
3422
3423         * html/canvas/CanvasRenderingContext2D.cpp:
3424         (WebCore::CanvasRenderingContext2D::stroke):
3425         (WebCore::CanvasRenderingContext2D::drawTextInternal):
3426         (WebCore::CanvasRenderingContext2D::inflateStrokeRect):
3427         (WebCore):
3428         * html/canvas/CanvasRenderingContext2D.h:
3429         (CanvasRenderingContext2D):
3430
3431 2012-04-19  Luke Macpherson  <macpherson@chromium.org>
3432
3433         Eliminate potential null pointer dereference in CSSStyleSelector::containsUncommonAttributeSelector().
3434         https://bugs.webkit.org/show_bug.cgi?id=84366
3435
3436         Reviewed by Kentaro Hara.
3437
3438         No new tests / code cleanup only.
3439
3440         * css/CSSStyleSelector.cpp:
3441         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3442
3443 2012-04-19  Luke Macpherson  <macpherson@chromium.org>
3444
3445         Fix null-pointer dereference in ApplyPropertyZoom::applyValue().
3446         https://bugs.webkit.org/show_bug.cgi?id=84279
3447
3448         Reviewed by Simon Fraser.
3449
3450         Test: fast/css/zoom-on-unattached.html
3451
3452         * css/CSSStyleApplyProperty.cpp:
3453         (WebCore::ApplyPropertyZoom::applyValue):
3454
3455 2012-04-19  Luke Macpherson  <macpherson@chromium.org>
3456
3457         Clean up list iteration in MediaQueryExp constructor (avoid unnecessary calls to current()).
3458         https://bugs.webkit.org/show_bug.cgi?id=84369
3459
3460         Reviewed by Simon Fraser.
3461
3462         No new tests / code cleanup only.
3463
3464         * css/MediaQueryExp.cpp:
3465         (WebCore::MediaQueryExp::MediaQueryExp):
3466
3467 2012-04-19  Mark Pilgrim  <pilgrim@chromium.org>
3468
3469         [Chromium] Call signedPublicKeyAndChallengeString directly
3470         https://bugs.webkit.org/show_bug.cgi?id=84372
3471
3472         Reviewed by Kentaro Hara.
3473
3474         Part of a refactoring series. See tracking bug 82948.
3475
3476         * platform/chromium/PlatformSupport.h:
3477         (PlatformSupport):
3478         * platform/chromium/SSLKeyGeneratorChromium.cpp:
3479         (WebCore::signedPublicKeyAndChallengeString):
3480
3481 2012-04-19  Luke Macpherson  <macpherson@chromium.org>
3482
3483         Remove unnecessary assignment in CSSParser::parseCubicBezierTimingFunctionValue().
3484         https://bugs.webkit.org/show_bug.cgi?id=84368
3485
3486         Reviewed by Simon Fraser.
3487
3488         No new tests / code cleanup only.
3489
3490         * css/CSSParser.cpp:
3491         (WebCore::CSSParser::parseCubicBezierTimingFunctionValue):
3492
3493 2012-04-19  Luke Macpherson  <macpherson@chromium.org>
3494
3495         Initialize all member variables in CSSImageSetValue's copy constructor.
3496         https://bugs.webkit.org/show_bug.cgi?id=84379
3497
3498         Reviewed by Simon Fraser.
3499
3500         No new tests / code cleanup only.
3501
3502         * css/CSSImageSetValue.cpp:
3503         (WebCore::CSSImageSetValue::CSSImageSetValue):
3504
3505 2012-04-19  Ken Buchanan  <kenrb@chromium.org>
3506
3507         Positioned children of ruby runs not handled correctly during layout
3508         https://bugs.webkit.org/show_bug.cgi?id=84157
3509
3510         Reviewed by Julien Chaffraix.
3511
3512         A positioned ruby text causes a problem because it is excluded from
3513         normal layout by its parent and instead gets layout from
3514         RenderRubyRun::layoutSpecialExcludedChild; however this means it gets
3515         skipped over during the loop in RenderBlock::layoutBlockChildren,
3516         which is where positioned RenderBlocks get added to the appropriate
3517         positioned object lists. As a result, a dirty positioned ruby text
3518         will not get layout again unless the RenderRubyRun also needs layout
3519         which is not guaranteed.
3520
3521         This patch disqualifies ruby text elements from being positioned.
3522         If it is necessary to support this in future, ruby text layout will
3523         have to be modified to ensure the renderers are added to the
3524         appropriate block lists.
3525
3526         * css/CSSStyleSelector.cpp:
3527         (WebCore::CSSStyleSelector::adjustRenderStyle):
3528         * rendering/RenderRubyRun.cpp:
3529         (WebCore::RenderRubyRun::rubyText):
3530
3531 2012-04-19  vsevik@chromium.org  <vsevik@chromium.org>
3532
3533         Web Inspector: No response body available for cached resource requests with error status codes.
3534         https://bugs.webkit.org/show_bug.cgi?id=84265
3535
3536         Reviewed by Pavel Feldman.
3537
3538         InspectorResourceAgent now saves failed subresource request response body in its cache.
3539         Saved data is shown on front-end.
3540
3541         Test: http/tests/inspector/network/network-image-404.html
3542
3543         * inspector/InspectorResourceAgent.cpp:
3544         (WebCore::isErrorStatusCode):
3545         (WebCore):
3546         (WebCore::InspectorResourceAgent::didReceiveData):
3547         * inspector/NetworkResourcesData.cpp:
3548         (WebCore::NetworkResourcesData::ResourceData::removeContent):
3549         (WebCore::NetworkResourcesData::ResourceData::purgeContent):
3550         (WebCore):
3551         (WebCore::NetworkResourcesData::responseReceived):
3552         (WebCore::NetworkResourcesData::setResourceContent):
3553         * inspector/NetworkResourcesData.h:
3554         (ResourceData):
3555         (WebCore::NetworkResourcesData::ResourceData::httpStatusCode):
3556         (WebCore::NetworkResourcesData::ResourceData::setHTTPStatusCode):
3557         * inspector/front-end/RequestView.js:
3558         (WebInspector.RequestView.hasTextContent):
3559
3560 2012-04-19  Yury Semikhatsky  <yurys@chromium.org>
3561
3562         Web Inspector / Heap snapshots: "Object's retaining tree" view doesn't get cleared when navigating between objects
3563         https://bugs.webkit.org/show_bug.cgi?id=84337
3564
3565         When DataGrid root node is reset, make sure all existing rows are removed.
3566
3567         Reviewed by Vsevolod Vlasov.
3568
3569         * inspector/front-end/DataGrid.js:
3570         (WebInspector.DataGrid.prototype.setRootNode):
3571
3572 2012-04-19  Beth Dakin  <bdakin@apple.com>
3573
3574         https://bugs.webkit.org/show_bug.cgi?id=80536
3575         REGRESSION: When Safari is not frontmost, pages should not get mouse moves or 
3576         hover
3577
3578         Reviewed by Adele Peterson.
3579
3580         This patch just adds some code back that was removed by 
3581         http://trac.webkit.org/changeset/102632 This particular code was unrelated to that 
3582         bug and should not have been removed.
3583         * page/EventHandler.cpp:
3584         (WebCore::EventHandler::handleMouseMoveEvent):
3585
3586 2012-04-19  Xianzhu Wang  <wangxianzhu@chromium.org>
3587
3588         DevTools highlights elements in frames at un-scaled positions
3589         https://bugs.webkit.org/show_bug.cgi?id=84181
3590
3591         On mobile platforms (e.g. chromium-android), normally pages are scaled,
3592         thus the coordinations of highlight rect inside of a frame needs to
3593         consider not only the offset, but also the scale. The change uses
3594         FrameView::contentsToRootView() to map the coordinates of a node in
3595         a frame to the coordinates in the main frame, instead of calculating
3596         by only the offset.
3597
3598         Reviewed by Pavel Feldman.
3599
3600         Test: inspector/elements/highlight-node-scaled.html
3601
3602         * inspector/DOMNodeHighlighter.cpp:
3603
3604 2012-04-19  Yury Semikhatsky  <yurys@chromium.org>
3605
3606         Web Inspector / Heap snapshots: "Objects allocated ..." views are empty
3607         https://bugs.webkit.org/show_bug.cgi?id=84347
3608
3609         Pass parsed maxJSObjectId value to the profile header constructor.
3610
3611         Reviewed by Pavel Feldman.
3612
3613         * inspector/front-end/ProfilesPanel.js:
3614         (WebInspector.ProfileHeader):
3615         (WebInspector.ProfilesPanel.prototype.setRecordingProfile):
3616         (WebInspector.ProfilesPanel.prototype.takeHeapSnapshot):
3617         (WebInspector.ProfilerDispatcher.prototype.addProfileHeader):
3618
3619 2012-04-19  Brady Eidson  <beidson@apple.com>
3620
3621         <rdar://problem/10664148> and https://bugs.webkit.org/show_bug.cgi?id=84360 
3622         StorageThread should have an autorelease pool in place for Cocoa clients
3623         
3624         Reviewed by Eric Carlson.
3625
3626         No new tests. (Not practical to test this with current tools)
3627
3628         * storage/StorageThread.cpp:
3629         (WebCore::StorageThread::threadEntryPoint): Include an AutodrainedPool and cycle it after each message.
3630
3631 2012-04-19  Luke Macpherson  <macpherson@chromium.org>
3632
3633         Fix potential null pointer dereference in RuleSet::addRulesFromSheet().
3634         https://bugs.webkit.org/show_bug.cgi?id=84258
3635
3636         Reviewed by Andreas Kling.
3637
3638         Fix variable that is dereferenced without null check here, but checked in code above and below.
3639
3640         No new test / code cleanup from coverity analysis.
3641
3642         * css/CSSStyleSelector.cpp:
3643         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3644
3645 2012-04-19  Yury Semikhatsky  <yurys@chromium.org>
3646
3647         Web Inspector: exception when hovering object while paused
3648         https://bugs.webkit.org/show_bug.cgi?id=84358
3649
3650         Added missing boolean parameter to the call site of evaluate method
3651         on call frame.
3652
3653         Reviewed by Vsevolod Vlasov.
3654
3655         * inspector/front-end/AdvancedSearchController.js:
3656         * inspector/front-end/DebuggerPresentationModel.js: annotated slectedCallFrame
3657         method so that closure compiler catches errors like in the bug report.
3658         (WebInspector.DebuggerPresentationModel.prototype.evaluateInSelectedCallFrame):
3659         * inspector/front-end/JavaScriptSourceFrame.js:
3660         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover):
3661
3662 2012-04-19  Yury Semikhatsky  <yurys@chromium.org>
3663
3664         Web Inspector: nodes are not removed from the summary view when switching between allocation ranges
3665         https://bugs.webkit.org/show_bug.cgi?id=84354
3666
3667         Clear all top level nodes not only those visible in the viewport when populating
3668         the constructors view with new content.
3669
3670         Reviewed by Pavel Feldman.
3671
3672         * inspector/front-end/HeapSnapshotDataGrids.js:
3673         (WebInspector.HeapSnapshotSortableDataGrid.prototype.dispose):
3674         (WebInspector.HeapSnapshotSortableDataGrid.prototype.topLevelNodes):
3675         (WebInspector.HeapSnapshotSortableDataGrid.prototype.changeNameFilter):
3676         (WebInspector.HeapSnapshotViewportDataGrid.prototype.topLevelNodes):
3677         (WebInspector.HeapSnapshotViewportDataGrid.prototype.removeTopLevelNodes):
3678         (WebInspector.HeapSnapshotConstructorsDataGrid.prototype.populateChildren):
3679         (WebInspector.HeapSnapshotDiffDataGrid.prototype.setBaseDataSource):
3680
3681 2012-04-19  Sami Kyostila  <skyostil@chromium.org>
3682
3683         [chromium] Allow scrolling non-root layers in the compositor thread
3684         https://bugs.webkit.org/show_bug.cgi?id=73350
3685
3686         Reviewed by James Robinson.
3687
3688         This patch enables scrolling child layers in the compositor thread.
3689         Scroll deltas are accumulated for each scrolled CCLayerImpl and
3690         synchronized to the main thread.
3691
3692         If a layer has no room to scroll in a given direction, one of its
3693         ancestor layers is scrolled instead if possible.
3694
3695         Added new webkit_unit_tests to verify scrolling behavior.
3696
3697         * platform/graphics/chromium/ContentLayerChromium.cpp:
3698         (WebCore::ContentLayerChromium::scrollBy):
3699         (WebCore):
3700         * platform/graphics/chromium/ContentLayerChromium.h:
3701         (ContentLayerDelegate):
3702         (ContentLayerChromium):
3703         * platform/graphics/chromium/GraphicsLayerChromium.h:
3704         (WebCore::GraphicsLayerChromium::didScroll):
3705         * platform/graphics/chromium/LayerChromium.cpp:
3706         (WebCore::LayerChromium::setMaxScrollPosition):
3707         (WebCore):
3708         (WebCore::LayerChromium::pushPropertiesTo):
3709         * platform/graphics/chromium/LayerChromium.h:
3710         (LayerChromium):
3711         (WebCore::LayerChromium::maxScrollPosition):
3712         (WebCore::LayerChromium::scrollable):
3713         (WebCore::LayerChromium::scrollBy):
3714         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
3715         (WebCore::CCLayerImpl::findLayerInSubtree):
3716         (WebCore):
3717         (WebCore::CCLayerImpl::tryScroll):
3718         * platform/graphics/chromium/cc/CCLayerImpl.h:
3719         (CCLayerImpl):
3720         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3721         (WebCore::findLayerById):
3722         (WebCore):
3723         (WebCore::findFirstScrollableLayer):
3724         (WebCore::CCLayerTreeHost::applyScrollAndScale):
3725         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3726         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
3727         (WebCore::CCLayerTreeHostImpl::startPageScaleAnimation):
3728         (WebCore::CCLayerTreeHostImpl::contentSize):
3729         (WebCore):
3730         (WebCore::CCLayerTreeHostImpl::calculateVisibleLayers):
3731         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
3732         (WebCore::findRootScrollLayer):
3733         (WebCore::findScrollLayerForContentLayer):
3734         (WebCore::CCLayerTreeHostImpl::setRootLayer):
3735         (WebCore::adjustScrollsForPageScaleChange):
3736         (WebCore::applyPageScaleDeltaToScrollLayers):
3737         (WebCore::CCLayerTreeHostImpl::setPageScaleFactorAndLimits):
3738         (WebCore::CCLayerTreeHostImpl::setPageScaleDelta):
3739         (WebCore::CCLayerTreeHostImpl::updateMaxScrollPosition):
3740         (WebCore::CCLayerTreeHostImpl::scrollBegin):
3741         (WebCore::CCLayerTreeHostImpl::scrollBy):
3742         (WebCore::CCLayerTreeHostImpl::scrollEnd):
3743         (WebCore::CCLayerTreeHostImpl::pinchGestureUpdate):
3744         (WebCore::CCLayerTreeHostImpl::computePinchZoomDeltas):
3745         (WebCore::CCLayerTreeHostImpl::makeScrollAndScaleSet):
3746         (WebCore::collectScrollDeltas):
3747         (WebCore::CCLayerTreeHostImpl::processScrollDeltas):
3748         (WebCore::CCLayerTreeHostImpl::animatePageScale):
3749         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3750         (WebCore::CCLayerTreeHostImpl::rootScrollLayer):
3751         (CCLayerTreeHostImpl):
3752         (LayerGeometry):
3753
3754 2012-04-19  Yury Semikhatsky  <yurys@chromium.org>
3755
3756         Web Inspector: make constructors and diff heap snapshot data grids use viewport
3757         https://bugs.webkit.org/show_bug.cgi?id=84348
3758
3759         HeapSnapshotViewportDataGrid is introduced which allows to add to the tbody only
3760         visible rows. HeapSnapshotConstructorsDataGrid and HeapSnapshotDiffDataGrid are
3761         inherited from this class which makes them operate well on large amounts of nodes.
3762
3763         Reviewed by Pavel Feldman.
3764
3765         * inspector/front-end/DataGrid.js:
3766         (WebInspector.DataGridNode.prototype.nodeHeight):
3767         (WebInspector.DataGridNode.prototype._attach):
3768         * inspector/front-end/HeapSnapshotDataGrids.js:
3769         (WebInspector.HeapSnapshotSortableDataGrid):
3770         (WebInspector.HeapSnapshotSortableDataGrid.prototype.nodesForNameFilter):
3771         (WebInspector.HeapSnapshotSortableDataGrid.prototype.changeNameFilter):
3772         (WebInspector.HeapSnapshotSortableDataGrid.prototype._performSorting):
3773         (WebInspector.HeapSnapshotSortableDataGrid.prototype.appendChildAfterSorting):
3774         (WebInspector.HeapSnapshotSortableDataGrid.prototype.updateVisibleNodes):
3775         (WebInspector.HeapSnapshotSortableDataGrid.prototype.recursiveSortingEnter):
3776         (WebInspector.HeapSnapshotSortableDataGrid.prototype.recursiveSortingLeave):
3777         (WebInspector.HeapSnapshotViewportDataGrid):
3778         (WebInspector.HeapSnapshotViewportDataGrid.prototype.nodesForNameFilter):
3779         (WebInspector.HeapSnapshotViewportDataGrid.prototype.appendChildAfterSorting):
3780         (WebInspector.HeapSnapshotViewportDataGrid.prototype.updateVisibleNodes):
3781         (WebInspector.HeapSnapshotViewportDataGrid.prototype.appendTopLevelNode):
3782         (WebInspector.HeapSnapshotViewportDataGrid.prototype._addPaddingRows):
3783         (WebInspector.HeapSnapshotViewportDataGrid.prototype._removePaddingRows):
3784         (WebInspector.HeapSnapshotViewportDataGrid.prototype.onResize):
3785         (WebInspector.HeapSnapshotViewportDataGrid.prototype._onScroll):
3786         (WebInspector.HeapSnapshotPaddingNode):
3787         (WebInspector.HeapSnapshotPaddingNode.prototype.setHeight):
3788         (WebInspector.HeapSnapshotPaddingNode.prototype.removeFromTable):
3789         (WebInspector.HeapSnapshotConstructorsDataGrid):
3790         (WebInspector.HeapSnapshotConstructorsDataGrid.prototype.populateChildren):
3791         (WebInspector.HeapSnapshotDiffDataGrid):
3792         (WebInspector.HeapSnapshotDiffDataGrid.prototype.populateChildren.baseAggregatesReceived.aggregatesReceived.addNodeIfNonZeroDiff):
3793         (WebInspector.HeapSnapshotDiffDataGrid.prototype.populateChildren.baseAggregatesReceived.aggregatesReceived):
3794         (WebInspector.HeapSnapshotDiffDataGrid.prototype.populateChildren):
3795         * inspector/front-end/HeapSnapshotGridNodes.js:
3796         (WebInspector.HeapSnapshotGridNode):
3797         (WebInspector.HeapSnapshotGridNode.prototype.collapse):
3798         (WebInspector.HeapSnapshotGridNode.prototype.sort.afterSort.afterPopulate):
3799         (WebInspector.HeapSnapshotGridNode.prototype.sort.afterSort):
3800         (WebInspector.HeapSnapshotGridNode.prototype.sort):
3801         (WebInspector.HeapSnapshotObjectNode.prototype._createChildNode):
3802         (WebInspector.HeapSnapshotObjectNode.prototype.comparator):
3803         (WebInspector.HeapSnapshotInstanceNode.prototype._createChildNode):
3804         (WebInspector.HeapSnapshotInstanceNode.prototype.comparator):
3805         (WebInspector.HeapSnapshotConstructorNode):
3806         (WebInspector.HeapSnapshotConstructorNode.prototype._createChildNode):
3807         (WebInspector.HeapSnapshotConstructorNode.prototype.comparator):
3808         (WebInspector.HeapSnapshotDiffNode):
3809         (WebInspector.HeapSnapshotDiffNode.prototype._createChildNode):
3810         (WebInspector.HeapSnapshotDiffNode.prototype.comparator):
3811         (WebInspector.HeapSnapshotDominatorObjectNode.prototype._createChildNode):
3812         (WebInspector.HeapSnapshotDominatorObjectNode.prototype.comparator):
3813         * inspector/front-end/ShowMoreDataGridNode.js:
3814         (WebInspector.ShowMoreDataGridNode.prototype.createCells):
3815         (WebInspector.ShowMoreDataGridNode.prototype.nodeHeight):
3816
3817 2012-04-19  Kentaro Hara  <haraken@chromium.org>
3818
3819         Unreviewed, rolling out r114421.
3820         http://trac.webkit.org/changeset/114421
3821         https://bugs.webkit.org/show_bug.cgi?id=84103
3822
3823         Chromium crash
3824
3825         * bindings/scripts/CodeGeneratorV8.pm:
3826         (GenerateNormalAttrGetter):
3827         (GenerateFunctionCallString):
3828         (NativeToJSValue):
3829         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
3830         (WebCore::TestEventConstructorV8Internal::attr1AttrGetter):
3831         (WebCore::TestEventConstructorV8Internal::attr2AttrGetter):
3832         * bindings/scripts/test/V8/V8TestInterface.cpp:
3833         (WebCore::TestInterfaceV8Internal::supplementalStr1AttrGetter):
3834         (WebCore::TestInterfaceV8Internal::supplementalStr2AttrGetter):
3835         * bindings/scripts/test/V8/V8TestObj.cpp:
3836         (WebCore::TestObjV8Internal::readOnlyStringAttrAttrGetter):
3837         (WebCore::TestObjV8Internal::stringAttrAttrGetter):
3838         (WebCore::TestObjV8Internal::reflectedStringAttrAttrGetter):
3839         (WebCore::TestObjV8Internal::reflectedURLAttrAttrGetter):
3840         (WebCore::TestObjV8Internal::reflectedCustomURLAttrAttrGetter):
3841         (WebCore::TestObjV8Internal::stringAttrWithGetterExceptionAttrGetter):
3842         (WebCore::TestObjV8Internal::stringAttrWithSetterExceptionAttrGetter):
3843         (WebCore::TestObjV8Internal::hashAttrGetter):
3844         (WebCore::TestObjV8Internal::conditionalMethod1Callback):
3845         * bindings/v8/V8Binding.cpp:
3846         (WebCore::getElementStringAttr):
3847         * bindings/v8/V8Binding.h:
3848         (WebCore::v8ExternalString):
3849         (WebCore::v8String):
3850         (WebCore::v8StringOrNull):
3851         (WebCore::v8StringOrUndefined):
3852         (WebCore::v8StringOrFalse):
3853
3854 2012-04-19  Sheriff Bot  <webkit.review.bot@gmail.com>
3855
3856         Unreviewed, rolling out r114626.
3857         http://trac.webkit.org/changeset/114626
3858         https://bugs.webkit.org/show_bug.cgi?id=84349
3859
3860         caused new assertions in debug builds (Requested by smfr_ on
3861         #webkit).
3862
3863         * inspector/InspectorResourceAgent.cpp:
3864         (WebCore::InspectorResourceAgent::didReceiveData):
3865         * inspector/NetworkResourcesData.cpp:
3866         (WebCore::NetworkResourcesData::responseReceived):
3867         * inspector/NetworkResourcesData.h:
3868         (ResourceData):
3869         (NetworkResourcesData):
3870         * inspector/front-end/RequestView.js:
3871         (WebInspector.RequestView.hasTextContent):
3872
3873 2012-04-19  Mark Pilgrim  <pilgrim@chromium.org>
3874
3875         [Chromium] Call mimeRegistry directly
3876         https://bugs.webkit.org/show_bug.cgi?id=84334
3877
3878         Reviewed by Kentaro Hara.
3879
3880         Part of a refactoring series. See tracking bug 82948.
3881
3882         * platform/chromium/MIMETypeRegistryChromium.cpp:
3883         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
3884         (WebCore::MIMETypeRegistry::getWellKnownMIMETypeForExtension):
3885         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
3886         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
3887         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
3888         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
3889         * platform/chromium/PlatformSupport.h:
3890         (PlatformSupport):
3891
3892 2012-04-19  Victor Carbune  <vcarbune@adobe.com>
3893
3894         Display a TextTrackCue when snap-to-lines flag is not set
3895         https://bugs.webkit.org/show_bug.cgi?id=79750
3896
3897         Reviewed by Eric Carlson.
3898
3899         Support for positioning of a cue on top of the video element when snap-to-lines is not set.
3900
3901         Test: media/track/track-cue-rendering-snap-to-lines-not-set.html
3902
3903         * css/mediaControls.css:
3904         (video::-webkit-media-text-track-container): Marked the container as
3905         flexible box in order to use all the available space on top of the controls.
3906         (video::-webkit-media-text-track-background): Added background default settings.
3907         (video::-webkit-media-text-track-display): Added default position.
3908         * html/shadow/MediaControlElements.cpp:
3909         (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Updated comments.
3910         * html/track/TextTrackCue.cpp:
3911         (WebCore):
3912         (WebCore::TextTrackCue::TextTrackCue): Updated constructor to calculate
3913         the computed line position.
3914         (WebCore::TextTrackCue::setLine): Updated call to calculate the computed line
3915         position.
3916         (WebCore::TextTrackCue::setPosition):
3917         (WebCore::TextTrackCue::calculateComputedLinePosition): Partial calculation of the
3918         computated line position.
3919         (WebCore::TextTrackCue::calculateDisplayParameters): Updated display parameter computations
3920         required by the spec.
3921         (WebCore::TextTrackCue::getDisplayTree): Updated positioning attributes when snap-to-lines
3922         is not set. Added extra anonymous box for background, because setting position:absolute
3923         on the display tree determines the background to cover the whole block, not just inline.
3924         (WebCore::TextTrackCue::getPositionCoordinates): Determine coordinates as required by the spec.
3925         * html/track/TextTrackCue.h:
3926         (TextTrackCue):
3927
3928 2012-04-19  Pavel Feldman  <pfeldman@chromium.org>
3929
3930         Web Inspector: introduce styles panel as an experiment
3931         https://bugs.webkit.org/show_bug.cgi?id=84331
3932
3933         Reviewed by Vsevolod Vlasov.
3934
3935         This change introduces new "Styles" panel that looks like the "Scripts" one,
3936         but operates stylesheets. This is happening under the experimental flag.
3937
3938         * English.lproj/localizedStrings.js:
3939         * WebCore.gypi:
3940         * WebCore.vcproj/WebCore.vcproj:
3941         * inspector/compile-front-end.py:
3942         * inspector/front-end/Panel.js:
3943         (WebInspector.Panel.prototype.showAnchorLocation):
3944         * inspector/front-end/ResourceView.js:
3945         (WebInspector.EditableResourceSourceFrame.prototype.didEditContent):
3946         * inspector/front-end/ScriptsNavigator.js:
3947         (WebInspector.ScriptsNavigatorController.prototype._navigatorOverlayWasShown):
3948         * inspector/front-end/ScriptsPanel.js:
3949         * inspector/front-end/Settings.js:
3950         (WebInspector.ExperimentsSettings):
3951         * inspector/front-end/SourceFrame.js:
3952         (WebInspector.SourceFrame.prototype._clearLineHighlight):
3953         * inspector/front-end/StylesPanel.js: Added.
3954         (WebInspector.StylesPanel):
3955         (WebInspector.StylesPanel.prototype.wasShown):
3956         (WebInspector.StylesPanel.prototype._initialize):
3957         (WebInspector.StylesPanel.prototype._populateResourceTree.populateFrame):
3958         (WebInspector.StylesPanel.prototype._populateResourceTree):
3959         (WebInspector.StylesPanel.prototype._resourceAdded):
3960         (WebInspector.StylesPanel.prototype._reset):
3961         (WebInspector.StylesPanel.prototype._cachedResourcesLoaded):
3962         (WebInspector.StylesPanel.prototype.get toolbarItemLabel):
3963         (WebInspector.StylesPanel.prototype.viewForFile.get if):
3964         (WebInspector.StylesPanel.prototype.viewForFile):
3965         (WebInspector.StylesPanel.prototype._textEdited):
3966         (WebInspector.StylesPanel.prototype._scriptSelected):
3967         (WebInspector.StylesPanel.prototype._showFile):
3968         (WebInspector.StylesPanel.prototype.canShowAnchorLocation):
3969         * inspector/front-end/StylesSidebarPane.js:
3970         (WebInspector.StylePropertiesSection):
3971         (WebInspector.StylePropertiesSection.prototype._createRuleOriginNode):
3972         * inspector/front-end/TabbedEditorContainer.js:
3973         (WebInspector.TabbedEditorContainer):
3974         * inspector/front-end/WebKit.qrc:
3975         * inspector/front-end/inspector.html:
3976         * inspector/front-end/inspector.js:
3977         (WebInspector._createPanels):
3978         (WebInspector._showAnchorLocationInPanel):
3979         * inspector/front-end/scriptsPanel.css:
3980         * inspector/front-end/splitView.css:
3981         (.sidebar-overlay):
3982
3983 2012-04-19  Vsevolod Vlasov  <vsevik@chromium.org>
3984
3985         Follow up to r114632: build fix.
3986
3987         * inspector/InspectorDebuggerAgent.cpp:
3988         (WebCore):
3989         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
3990
3991 2012-04-19  Mark Pilgrim  <pilgrim@chromium.org>
3992
3993         [Chromium] Call sampleGamepads directly
3994         https://bugs.webkit.org/show_bug.cgi?id=84339
3995
3996         Reviewed by Kentaro Hara.
3997
3998         Part of a refactoring series. See tracking bug 82948.
3999
4000         * platform/chromium/GamepadsChromium.cpp:
4001         (WebCore::sampleGamepads):
4002         * platform/chromium/PlatformSupport.h:
4003         (WebCore):
4004         (PlatformSupport):
4005
4006 2012-04-19  Vsevolod Vlasov  <vsevik@chromium.org>
4007
4008         Web Inspector: x-frame security errors logged when typing in the console are annoying.
4009         https://bugs.webkit.org/show_bug.cgi?id=81970
4010
4011         Reviewed by Pavel Feldman.
4012
4013         Parameter DoNotPauseOnExceptions in Runtime.evaluate() renamed to DoNotPauseOnExceptionsAndMuteConsole.
4014         Added this parameter to Runtime.callFunctionOn() and passed true in all call sites.
4015         Added this parameter to Debugger.evaluateOnCallFrame().
4016         Added a flag to console that mutes all messages unless they have ConsoleAPI message source.
4017         This flag is now temporarily set from InspectorRuntimeAgent and InspectorDebuggerAgent for certain injected source calls.
4018
4019         * inspector/Inspector.json:
4020         * inspector/InspectorDebuggerAgent.cpp:
4021         (WebCore::asBool):
4022         (WebCore):
4023         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
4024         * inspector/InspectorDebuggerAgent.h:
4025         (InspectorDebuggerAgent):
4026         * inspector/InspectorRuntimeAgent.cpp:
4027         (WebCore):
4028         (WebCore::setPauseOnExceptionsState):
4029         (WebCore::InspectorRuntimeAgent::evaluate):
4030         (WebCore::InspectorRuntimeAgent::callFunctionOn):
4031         (WebCore::InspectorRuntimeAgent::getProperties):
4032         * inspector/InspectorRuntimeAgent.h:
4033         (InspectorRuntimeAgent):
4034         * inspector/PageDebuggerAgent.cpp:
4035         (WebCore::PageDebuggerAgent::muteConsole):
4036         (WebCore):
4037         (WebCore::PageDebuggerAgent::unmuteConsole):
4038         * inspector/PageDebuggerAgent.h:
4039         (PageDebuggerAgent):
4040         * inspector/PageRuntimeAgent.cpp:
4041         (WebCore::PageRuntimeAgent::muteConsole):
4042         (WebCore):
4043         (WebCore::PageRuntimeAgent::unmuteConsole):
4044         * inspector/PageRuntimeAgent.h:
4045         (PageRuntimeAgent):
4046         * inspector/WorkerDebuggerAgent.cpp:
4047         (WebCore::WorkerDebuggerAgent::muteConsole):
4048         (WebCore):
4049         (WebCore::WorkerDebuggerAgent::unmuteConsole):
4050         * inspector/WorkerDebuggerAgent.h:
4051         (WorkerDebuggerAgent):
4052         * inspector/WorkerRuntimeAgent.cpp:
4053         (WebCore::WorkerRuntimeAgent::muteConsole):
4054         (WebCore):
4055         (WebCore::WorkerRuntimeAgent::unmuteConsole):
4056         * inspector/WorkerRuntimeAgent.h:
4057         (WorkerRuntimeAgent):
4058         * inspector/front-end/ConsoleView.js:
4059         (WebInspector.ConsoleView.prototype.evalInInspectedWindow):
4060         * inspector/front-end/DebuggerPresentationModel.js:
4061         (WebInspector.DebuggerPresentationModel.prototype.evaluateInSelectedCallFrame):
4062         (WebInspector.PresentationCallFrame.prototype.evaluate):
4063         * inspector/front-end/RemoteObject.js:
4064         (WebInspector.RemoteObject.prototype.setPropertyValue):
4065         (WebInspector.RemoteObject.prototype.callFunction):
4066         (WebInspector.RemoteObject.prototype.callFunctionJSON):
4067         * inspector/front-end/WorkerManager.js:
4068         * page/Console.cpp:
4069         (WebCore::Console::addMessage):
4070         (WebCore::Console::warn):
4071         (WebCore):
4072         (WebCore::Console::mute):
4073         (WebCore::Console::unmute):
4074         * page/Console.h:
4075         (Console):
4076
4077 2012-04-19  Sheriff Bot  <webkit.review.bot@gmail.com>
4078
4079         Unreviewed, rolling out r114628.
4080         http://trac.webkit.org/changeset/114628
4081         https://bugs.webkit.org/show_bug.cgi?id=84341
4082
4083         Breaks EFL and GTK builds (Requested by pfeldman on #webkit).
4084
4085         * inspector/Inspector.json:
4086         * inspector/InspectorDebuggerAgent.cpp:
4087         (WebCore):
4088         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
4089         * inspector/InspectorDebuggerAgent.h: