[chromium] Move deferral-related logic out of Canvas2DLayerChromium
[WebKit.git] / Source / WebCore / ChangeLog
1 2012-06-05  James Robinson  <jamesr@chromium.org>
2
3         [chromium] Move deferral-related logic out of Canvas2DLayerChromium
4         https://bugs.webkit.org/show_bug.cgi?id=86050
5
6         Reviewed by Stephen White.
7
8         This removes Canvas2DLayerChromium and puts the deferral and double-buffering related logic in a new class,
9         Canvas2DLayerBridge, that uses TextureLayerChromium for compositing.  The bridge is responsible for managing the
10         front texture when double buffering is active, inserting the correct makeContextCurrent() and flush() calls on
11         the GraphicsContext3D and SkCanvas when appropriate, and owning the lifetime of the layer.
12
13         * WebCore.gypi:
14         * platform/graphics/chromium/Canvas2DLayerBridge.cpp: Added.
15         (WebCore):
16         (AcceleratedDeviceContext):
17         (WebCore::AcceleratedDeviceContext::AcceleratedDeviceContext):
18         (WebCore::AcceleratedDeviceContext::prepareForDraw):
19         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
20         (WebCore::Canvas2DLayerBridge::~Canvas2DLayerBridge):
21         (WebCore::Canvas2DLayerBridge::skCanvas):
22         (WebCore::Canvas2DLayerBridge::prepareTexture):
23         (WebCore::Canvas2DLayerBridge::context):
24         (WebCore::Canvas2DLayerBridge::layer):
25         (WebCore::Canvas2DLayerBridge::contextAcquired):
26         * platform/graphics/chromium/Canvas2DLayerBridge.h: Added.
27         (WebCore):
28         (Canvas2DLayerBridge):
29         (WebCore::Canvas2DLayerBridge::create):
30         * platform/graphics/chromium/Canvas2DLayerChromium.cpp: Removed.
31         * platform/graphics/chromium/Canvas2DLayerChromium.h: Removed.
32         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
33         * platform/graphics/chromium/ImageBufferDataSkia.h:
34         (WebCore):
35         (ImageBufferData):
36         * platform/graphics/chromium/TextureLayerChromium.cpp:
37         (WebCore::TextureLayerChromium::willModifyTexture):
38             willModifyTexture() is called whenever the texture currently owned by the TextureLayerChromium will be
39             modified by a system out of the compositor's control. It makes sure that the compositor does not attempt to
40             draw with the potentially-modified texture until the next commit. For canvas, this is used when threading is
41             enabled and a non-deferrable drawing command is invoked from JS.
42         (WebCore):
43         * platform/graphics/chromium/TextureLayerChromium.h:
44         (TextureLayerChromium):
45         * platform/graphics/chromium/cc/CCTextureUpdater.cpp:
46         (WebCore::CCTextureUpdater::hasMoreUpdates):
47         (WebCore::CCTextureUpdater::update):
48         (WebCore::CCTextureUpdater::clear):
49         * platform/graphics/chromium/cc/CCTextureUpdater.h:
50         (CCTextureUpdater):
51         * platform/graphics/skia/ImageBufferSkia.cpp:
52         (WebCore::createAcceleratedCanvas):
53         (WebCore::ImageBuffer::~ImageBuffer):
54         (WebCore::ImageBuffer::context):
55         (WebCore::ImageBuffer::platformLayer):
56
57 2012-06-07  Patrick Gansterer  <paroga@webkit.org>
58
59         Remove HAVE(PATH_BASED_BORDER_RADIUS_DRAWING)
60         https://bugs.webkit.org/show_bug.cgi?id=87931
61
62         Reviewed by Beth Dakin.
63
64         r62035 added HAVE(PATH_BASED_BORDER_RADIUS_DRAWING) until all ports implement
65         GraphicsContext::clipConvexPolygon(). All major ports define HAVE_PATH_BASED_BORDER_RADIUS_DRAWING in the
66         meantime and the alternative path has unnecessary maintainace costs and even don't compile at the moment.
67
68         * rendering/RenderBoxModelObject.cpp:
69         (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
70         * rendering/RenderObject.cpp:
71         (WebCore::RenderObject::paintFocusRing):
72         * rendering/RenderObject.h:
73         (RenderObject):
74
75 2012-06-06  Vincent Scheib  <scheib@chromium.org>
76
77         Add new Pointer Lock spec events webkitpointerlockchange and webkitpointerlockerror
78         https://bugs.webkit.org/show_bug.cgi?id=88377
79
80         Reviewed by Dimitri Glazkov.
81
82         Part of a series of refactoring changes to update pointer lock API to
83         the fullscreen locking style. https://bugs.webkit.org/show_bug.cgi?id=84402
84
85         New change and error events added. Follow up patches will remove
86         the previous callbacks and pointerlocklost event. Tests updated
87         to include the new events, and a new test added specifically for
88         the new events, pointerlockchange-pointerlockerror-events.html.
89
90         Test: pointer-lock/pointerlockchange-pointerlockerror-events.html
91
92         * dom/Document.h:
93         (Document):
94         * dom/Document.idl:
95         * dom/EventNames.h:
96         (WebCore):
97         * page/PointerLockController.cpp:
98         (WebCore::PointerLockController::requestPointerLock):
99         (WebCore::PointerLockController::didAcquirePointerLock):
100         (WebCore::PointerLockController::didNotAcquirePointerLock):
101         (WebCore::PointerLockController::didLosePointerLock):
102         (WebCore::PointerLockController::enqueueEvent):
103         (WebCore):
104         * page/PointerLockController.h:
105         (PointerLockController):
106
107 2012-06-07  Sheriff Bot  <webkit.review.bot@gmail.com>
108
109         Unreviewed, rolling out r119744.
110         http://trac.webkit.org/changeset/119744
111         https://bugs.webkit.org/show_bug.cgi?id=88584
112
113         Fails assertions in debug builds (Requested by jamesr_ on
114         #webkit).
115
116         * platform/graphics/chromium/cc/CCIOSurfaceLayerImpl.cpp:
117         (WebCore::CCIOSurfaceLayerImpl::~CCIOSurfaceLayerImpl):
118         (WebCore::CCIOSurfaceLayerImpl::willDraw):
119
120 2012-06-07  Julien Chaffraix  <jchaffraix@webkit.org>
121
122         Cache RenderLayer::isRootLayer for better performance
123         https://bugs.webkit.org/show_bug.cgi?id=88570
124
125         Reviewed by Ojan Vafai.
126
127         Caching covered by existing tests.
128
129         RenderLayer::isRootLayer()'s answer will be the same during the RenderLayer's
130         lifetime as a RenderLayer is tied to a RenderBoxModelObject. This change caches
131         isRootLayer value in the constructor.
132
133         On http://dglazkov.github.com/performance-tests/biggrid.html with a 100,000 rows
134         by 100 columns table, it saves about 10% on the paint time during scrolling on
135         my machine (going from 50ms to 45ms). It would expect all code paths to see some
136         improvement as checking renderer()->isRenderView() was pretty common.
137
138         * rendering/RenderLayer.cpp:
139         (WebCore::RenderLayer::RenderLayer):
140         Added code to cache the result of renderer()->isRenderView() here.
141
142         (WebCore::RenderLayer::stackingContext):
143         (WebCore::isPositionedContainer):
144         (WebCore::isFixedPositionedContainer):
145         (WebCore::RenderLayer::enclosingTransformedAncestor):
146         (WebCore::RenderLayer::clippingRootForPainting):
147         (WebCore::shouldSuppressPaintingLayer):
148         (WebCore::RenderLayer::hitTest):
149         (WebCore::RenderLayer::intersectsDamageRect):
150         * rendering/RenderLayer.h:
151         (WebCore::RenderLayer::isStackingContext):
152         Updated all the call sites to use isRootLayer() instead of renderer()->isRenderView()
153         as it is faster.
154
155         (WebCore::RenderLayer::isRootLayer):
156         Added our caching here. Also made m_canSkipRepaintRectsUpdateOnScroll to follow
157         m_isRootLayer example.
158
159 2012-06-07  Takashi Sakamoto  <tasak@google.com>
160
161         Incorrect border rendering when border radius is above 2px.
162         https://bugs.webkit.org/show_bug.cgi?id=88046
163
164         Fixing findInnerVertex's logic to decide which is the better line
165         to find an inner vertex, x=center point's x of a rendering box or
166         y=center point's y of a rendering box.
167
168         Reviewed by Simon Fraser.
169
170         Test: fast/borders/border-radius-valid-border-clipping.html
171
172         * rendering/RenderBoxModelObject.cpp:
173         (WebCore::findInnerVertex):
174
175 2012-06-07  Edaena Salinas Jasso  <edaena@apple.com>
176
177         Should fire error event for empty 404 script
178         https://bugs.webkit.org/show_bug.cgi?id=50589
179         
180         Reviewed by Brady Eidson.
181
182         Tests: 
183         http/tests/loading/fire-error-event-empty-404-script.html
184         http/tests/loading/fire-error-script-no-content-type.html
185
186         * loader/SubresourceLoader.cpp:
187         (WebCore::SubresourceLoader::didReceiveResponse): We should check for http status 
188         codes here to stop depending on the response being non-empty.
189         (WebCore::SubresourceLoader::didReceiveData): Moved the http status check but
190         avoid messing with multipart responses.
191         (WebCore::SubresourceLoader::checkForHTTPStatusCodeError): Renamed from 
192         errorLoadingResource for clarity.
193
194         * loader/SubresourceLoader.h:
195         * loader/cf/SubresourceLoaderCF.cpp:
196         (WebCore::SubresourceLoader::didReceiveDataArray):
197         Updated for errorLoadingResource renaming.
198
199 2012-06-07  Konrad Piascik  <kpiascik@rim.com>
200
201         [BlackBerry] Update PlayBook's User Agent String for Web Inspector
202         https://bugs.webkit.org/show_bug.cgi?id=88543
203
204         Reviewed by Antonio Gomes.
205
206         We expect users to upgrade their devices so developers only need the latest UA String.
207
208         No tests needed.
209
210         * inspector/front-end/SettingsScreen.js:
211         (WebInspector.SettingsScreen.prototype._createUserAgentSelectRowElement.get const):
212
213 2012-06-07  Shawn Singh  <shawnsingh@chromium.org>
214
215         [chromium] Remove obsolete FIXME comment about a layer sorting bug.
216         https://bugs.webkit.org/show_bug.cgi?id=88546
217
218         Reviewed by James Robinson.
219
220         No tests needed, only comment changed. The comment referred to a
221         potential bug that actually will not occur. The W3C spec on CSS 3d
222         transforms indicates that layers that do not share the same "3d
223         rendering context" do not sort together, and our existing code
224         sorts this way already.
225
226         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
227         (WebCore::subtreeShouldRenderToSeparateSurface):
228
229 2012-06-07  Adam Barth  <abarth@webkit.org>
230
231         Settings::defaultDeviceScaleFactor is redundant with Page::deviceScaleFactor
232         https://bugs.webkit.org/show_bug.cgi?id=88375
233
234         Reviewed by James Robinson.
235
236         This patch removes Settings::defaultDeviceScaleFactor because it is
237         redundant with Page::deviceScaleFactor now that we no longer support
238         target-densitydpi.  Page::deviceScaleFactor is the canonical place to
239         store the device scale factor.
240
241         * WebCore.exp.in:
242         * page/Settings.cpp:
243         (WebCore::Settings::Settings):
244         (WebCore):
245         * page/Settings.h:
246         (Settings):
247         * testing/InternalSettings.cpp:
248         (WebCore::InternalSettings::setDeviceScaleFactor):
249
250 2012-06-07  Alec Flett  <alecflett@chromium.org>
251
252         IndexedDB: Error codes, phase one
253         https://bugs.webkit.org/show_bug.cgi?id=88459
254
255         Reviewed by Tony Chang.
256
257         This phase gets rid of the now-deprecated NOT_ALLOWED_ERR and
258         NON_TRANSIENT_ERR from earlier versions of the spec, and
259         normalizes the place where TypeError should be thrown so that it's
260         easier to update when the bindings change.
261
262         No new tests: existing tests cover these changes and have been updated.
263
264         * Modules/indexeddb/IDBCursor.cpp:
265         (WebCore::IDBCursor::advance):
266         (WebCore::IDBCursor::continueFunction):
267         (WebCore::IDBCursor::stringToDirection):
268         (WebCore::IDBCursor::directionToString):
269         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
270         (WebCore::IDBCursorBackendImpl::update):
271         (WebCore::IDBCursorBackendImpl::deleteFunction):
272         * Modules/indexeddb/IDBDatabase.cpp:
273         (WebCore::IDBDatabase::createObjectStore):
274         (WebCore::IDBDatabase::deleteObjectStore):
275         (WebCore::IDBDatabase::setVersion):
276         (WebCore::IDBDatabase::transaction):
277         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
278         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
279         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
280         (WebCore::IDBDatabaseBackendImpl::setVersion):
281         * Modules/indexeddb/IDBDatabaseException.cpp:
282         (WebCore):
283         * Modules/indexeddb/IDBDatabaseException.h:
284         * Modules/indexeddb/IDBDatabaseException.idl:
285         * Modules/indexeddb/IDBFactory.cpp:
286         (WebCore::IDBFactory::open):
287         (WebCore::IDBFactory::deleteDatabase):
288         * Modules/indexeddb/IDBObjectStore.cpp:
289         (WebCore::IDBObjectStore::index):
290         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
291         (WebCore::IDBObjectStoreBackendImpl::createIndex):
292         (WebCore::IDBObjectStoreBackendImpl::deleteIndex):
293         * Modules/indexeddb/IDBRequest.cpp:
294         (WebCore::IDBRequest::result):
295         (WebCore::IDBRequest::errorCode):
296         (WebCore::IDBRequest::webkitErrorMessage):
297         * Modules/indexeddb/IDBTransaction.cpp:
298         (WebCore::IDBTransaction::objectStore):
299         (WebCore::IDBTransaction::stringToMode):
300         (WebCore::IDBTransaction::modeToString):
301         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
302         (WebCore::IDBTransactionBackendImpl::objectStore):
303
304 2012-06-07  Dana Jansens  <danakj@chromium.org>
305
306         [chromium] Free texture from CCIOSurfaceLayerImpl when it is destroyed
307         https://bugs.webkit.org/show_bug.cgi?id=88371
308
309         Reviewed by James Robinson.
310
311         Unit test: CCLayerTreeHostImplTest.layersFreeTextures
312
313         * platform/graphics/chromium/cc/CCIOSurfaceLayerImpl.cpp:
314         (WebCore::CCIOSurfaceLayerImpl::~CCIOSurfaceLayerImpl):
315         (WebCore::CCIOSurfaceLayerImpl::willDraw):
316
317 2012-06-07  Peter Beverloo  <peter@chromium.org>
318
319         Buildfix for ENABLE_OVERFLOW_SCROLLING=0 (though defined)
320         https://bugs.webkit.org/show_bug.cgi?id=88564
321
322         Reviewed by Adam Barth.
323
324         Where ENABLE(X) mandates that X both has to be defined and evaluates to
325         true as a lone preprocessor statement, there were two places in the CSS
326         property and value input files where only was checked whether is has
327         been defined. This also goes against other #ifdefs in those files.
328
329         * css/CSSPropertyNames.in:
330         * css/CSSValueKeywords.in:
331
332 2012-06-07  Ami Fischman  <fischman@chromium.org>
333
334         Plumb CORS attribute information from HTMLMediaElement to media players so it can be used
335         https://bugs.webkit.org/show_bug.cgi?id=88349
336
337         Reviewed by Adam Barth.
338
339         Test: http/tests/security/video-cross-origin-readback.html
340
341         * html/HTMLMediaElement.cpp:
342         (WebCore::HTMLMediaElement::mediaPlayerCORSMode):
343         (WebCore):
344         * html/HTMLMediaElement.h:
345         (HTMLMediaElement):
346         * html/canvas/CanvasRenderingContext.cpp:
347         (WebCore::CanvasRenderingContext::wouldTaintOrigin):
348         * platform/graphics/MediaPlayer.cpp:
349         (WebCore::MediaPlayer::didPassCORSAccessCheck):
350         (WebCore):
351         * platform/graphics/MediaPlayer.h:
352         (WebCore::MediaPlayerClient::mediaPlayerCORSMode):
353         (MediaPlayer):
354         * platform/graphics/MediaPlayerPrivate.h:
355         (WebCore::MediaPlayerPrivateInterface::didPassCORSAccessCheck):
356         (MediaPlayerPrivateInterface):
357
358 2012-06-07  Mark Hahnenberg  <mhahnenberg@apple.com>
359
360         Worker tear-down can re-enter JSC during GC finalization
361         https://bugs.webkit.org/show_bug.cgi?id=88449
362
363         Reviewed by Geoffrey Garen.
364
365         No new tests. 
366
367         This is the first of two patches to fix this issue with Workers.
368
369         * workers/AbstractWorker.cpp:
370         (WebCore::AbstractWorker::~AbstractWorker): We don't need to call onDestroyWorker() here, it 
371         will be called elsewhere in contextDestroyed().
372
373 2012-06-07  Jer Noble  <jer.noble@apple.com>
374
375         sometimes all slaved videos don't start playing
376         https://bugs.webkit.org/show_bug.cgi?id=88553
377
378         Reviewed by Darin Adler.
379
380         Test: media/media-controller-time-clamp.html
381
382         Some PlatformClock classes will occasionally return times < 0 and will
383         always return times slightly > duration() when playback has ended.  Clamp
384         the value of currentTime() to the specified [0..duration] range.
385
386         * html/MediaController.cpp:
387         (MediaController::currentTime):
388
389 2012-06-07  Simon Fraser  <simon.fraser@apple.com>
390
391         Optimize FrameView::scrollXForFixedPosition() / scrollYForFixedPosition()
392         https://bugs.webkit.org/show_bug.cgi?id=88475
393
394         Reviewed by Sam Weinig.
395         
396         FrameView's scrollXForFixedPosition() and scrollYForFixedPosition()
397         methods were often called together, but they do duplicate work,
398         including calling into platform widget code which might be slow.
399         
400         Fix by converting scrollOffsetForFixedPosition() from being a wrapper
401         that just calls scrollXForFixedPosition() and scrollYForFixedPosition()
402         to the method that does all the work, calling just once into platform
403         widget code.
404         
405         Changed callers to use scrollOffsetForFixedPosition() rather than make
406         two separate method calls.
407         
408         Added ScrollView::layoutSize() and visibleSize() methods for
409         convenience.
410         
411         Removed FrameView::scrollXForFixedPosition and FrameView::scrollYForFixedPosition
412         to avoid inefficient callers in future.
413
414         No new tests; refactoring only.
415
416         * page/FrameView.cpp:
417         (WebCore::fixedPositionScrollOffset):
418         (WebCore::FrameView::scrollOffsetForFixedPosition):
419         * page/FrameView.h: Removed scrollXForFixedPosition and scrollYForFixedPosition.
420         * platform/ScrollView.cpp:
421         (WebCore::ScrollView::layoutSize):
422         * platform/ScrollView.h:
423         (WebCore::ScrollView::visibleSize):
424         * rendering/RenderLayer.cpp:
425         (WebCore::RenderLayer::backgroundClipRect):
426         * rendering/RenderLayer.h:
427         (WebCore::ClipRect::move):
428         * rendering/RenderLayerCompositor.cpp:
429         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
430         * rendering/RenderView.cpp:
431         (WebCore::RenderView::computeRectForRepaint):
432
433 2012-06-07  Raymes Khoury  <raymes@chromium.org>
434
435         Incorrect rect-based hit-test result for culled-inline elements
436         https://bugs.webkit.org/show_bug.cgi?id=85849
437
438         Reviewed by Levi Weintraub.
439
440         Modified code which blindly adds culled inlines to rect-based hit-test
441         results so that it only does so if the child node does not fully cover
442         the hit-test region.
443
444         Test: fast/dom/nodesFromRect-culled-inline.html
445
446         * rendering/HitTestResult.cpp:
447         (WebCore::HitTestResult::addNodeToRectBasedTestResult):
448
449 2012-06-07  Daniel Erat  <derat@chromium.org>
450
451         Make Skia backend honor requests for subpixel-positioned text.
452         https://bugs.webkit.org/show_bug.cgi?id=88263
453
454         Reviewed by Tony Chang.
455
456         Add subpixel positioning field to FontRenderStyle and rename
457         subpixel rendering field.
458
459         Pass setting to SkPaint in FontPlatformDataHarfBuzz and remove
460         round() call when computing glyph widths in SimpleFontDataSkia.
461
462         Test: platform/chromium-linux/fast/text/chromium-linux-text-subpixel-positioning.html
463
464         * platform/graphics/blackberry/skia/PlatformSupport.cpp:
465         (WebCore::setFontRenderStyleDefaults):
466         (WebCore::PlatformSupport::getRenderStyleForStrike):
467         * platform/graphics/chromium/FontRenderStyle.h:
468         (WebCore::FontRenderStyle::FontRenderStyle):
469         (WebCore::FontRenderStyle::operator==):
470         (FontRenderStyle):
471         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.cpp:
472         (WebCore):
473         (WebCore::FontPlatformData::setSubpixelRendering):
474         (WebCore::FontPlatformData::setSubpixelPositioning):
475         (WebCore::FontPlatformData::setupPaint):
476         (WebCore::FontPlatformData::querySystemForRenderStyle):
477         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.h:
478         (FontPlatformData):
479         * platform/graphics/skia/SimpleFontDataSkia.cpp:
480         (WebCore::SimpleFontData::platformWidthForGlyph):
481
482 2012-06-06  Dana Jansens  <danakj@chromium.org>
483
484         [chromium] In each composited frame, didDraw() should only be called on layers for which willDraw() was called
485         https://bugs.webkit.org/show_bug.cgi?id=88469
486
487         Reviewed by James Robinson.
488
489         Unit test: CCLayerTreeHostImplTest.didDrawNotCalledOnScissoredLayer
490
491         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
492         (WebCore::shouldDrawLayer):
493         (WebCore):
494         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
495         (WebCore::CCLayerTreeHostImpl::didDrawAllLayers):
496
497 2012-06-07  Alexei Filippov  <alexeif@chromium.org>
498
499         Web Inspector: sorting of object fields is broken in heap profiler
500         https://bugs.webkit.org/show_bug.cgi?id=88532
501
502         A recent change to heap profiler has replaced getters with functions.
503         Function calls were missing in couple places after that change.
504
505         Reviewed by Vsevolod Vlasov.
506
507         Tests: inspector/profiler/heap-snapshot-summary-sorting-fields.html
508                inspector/profiler/heap-snapshot-summary-sorting-instances.html
509
510         * inspector/front-end/HeapSnapshot.js:
511         (WebInspector.HeapSnapshotEdgesProvider.prototype.sort.compareNodeField):
512
513 2012-06-07  Alexander Pavlov  <apavlov@chromium.org>
514
515         Web Inspector: Consider Ctrl+Shift+key as valid zoom change combinations
516         https://bugs.webkit.org/show_bug.cgi?id=88520
517
518         Reviewed by Vsevolod Vlasov.
519
520         * inspector/front-end/inspector.js:
521         (WebInspector.documentKeyDown):
522
523 2012-06-07  Arvid Nilsson  <anilsson@rim.com>
524
525         [BlackBerry] Allow WebPageCompositor to blend a transparent web page
526         https://bugs.webkit.org/show_bug.cgi?id=88233
527
528         Reviewed by Rob Buis.
529
530         RIM PR #159998
531
532         Add a parameter to LayerRenderer::compositeBuffer() indicating whether
533         the buffer contents are opaque, and set the GL blend mode accordingly.
534
535         This is not currently testable using BlackBerry testing infrastructure.
536
537         Reviewed internally by Jakob Petsovits.
538
539         * platform/graphics/blackberry/LayerRenderer.cpp:
540         (WebCore::LayerRenderer::compositeBuffer):
541         * platform/graphics/blackberry/LayerRenderer.h:
542         (LayerRenderer):
543
544 2012-06-07  Alexei Filippov  <alexeif@chromium.org>
545
546         Web Inspector: reuse edge_count field of heap snapshot to store retained size
547         https://bugs.webkit.org/show_bug.cgi?id=88416
548
549         The edge_count field is unused after node first edge indexes have been built.
550         Store node retained size in there instead of allocating an extra array for it.
551
552         Reviewed by Vsevolod Vlasov.
553
554         * inspector/front-end/HeapSnapshot.js:
555         (WebInspector.HeapSnapshotNode.prototype.retainedSize):
556         (WebInspector.HeapSnapshot.prototype._calculateRetainedSizes):
557
558 2012-06-07  Sheriff Bot  <webkit.review.bot@gmail.com>
559
560         Unreviewed, rolling out r119694.
561         http://trac.webkit.org/changeset/119694
562         https://bugs.webkit.org/show_bug.cgi?id=88529
563
564         it broke PrerenderBrowserTest.PrerenderHTML5VideoNetwork
565         (Requested by loislo on #webkit).
566
567         * html/HTMLMediaElement.cpp:
568         * html/HTMLMediaElement.h:
569         (HTMLMediaElement):
570         * html/canvas/CanvasRenderingContext.cpp:
571         (WebCore::CanvasRenderingContext::wouldTaintOrigin):
572         * platform/graphics/MediaPlayer.cpp:
573         * platform/graphics/MediaPlayer.h:
574         (MediaPlayer):
575         * platform/graphics/MediaPlayerPrivate.h:
576
577 2012-06-07  Shinya Kawanaka  <shinyak@chromium.org>
578
579         Delete a contenteditable element having a Shadow DOM causes a crash.
580         https://bugs.webkit.org/show_bug.cgi?id=86345
581
582         Reviewed by Ryosuke Niwa.
583
584         In VisibleSelection::validate(), m_start.downstream() or m_end.upstream() might cross
585         editing boundaries. So we adjust selection after calling them again.
586
587         Test: editing/shadow/select-contenteditable-shadowhost.html
588
589         * editing/VisibleSelection.cpp:
590         (WebCore::VisibleSelection::validate):
591
592 2012-06-07  Vivek Galatage  <vivekgalatage@gmail.com>
593
594         No new line at the end for SVGCSSPropertyNames.in causes compilation warning
595         https://bugs.webkit.org/show_bug.cgi?id=88503
596
597         Reviewed by Ryosuke Niwa.
598
599         Added new line at the end of the file.
600
601         No new tests required.
602
603         * css/SVGCSSPropertyNames.in:
604
605 2012-06-07  Csaba Osztrogonác  <ossy@webkit.org>
606
607         [Qt][Win] Use OS(WINDOWS) instead of Q_WS_WIN in WebCore/platform/graphics/GraphicsContext.h
608         https://bugs.webkit.org/show_bug.cgi?id=88305
609
610         Reviewed by Simon Hausmann.
611
612         * platform/graphics/GraphicsContext.h: Buildfix.
613         (GraphicsContext):
614
615 2012-06-07  Shinya Kawanaka  <shinyak@chromium.org>
616
617         Incorrect data retrieved in calls to get selection data in client->textWillBeReplaced from CharacterData::setDataAndUpdate
618         https://bugs.webkit.org/show_bug.cgi?id=66120
619
620         Reviewed by Ryosuke Niwa.
621
622         Since FrameSelection::textWillBeReplaced was called before replacing text, updated Selection became
623         temporarily invalid. The invalid selection was set to updateSelection(), so client will have
624         invalid selection.
625
626         This patch makes calling updateSelection() after updating selection.
627
628         No new tests, it's too hard to create a correct test cases in DRT.
629
630         * dom/CharacterData.cpp:
631         (WebCore::CharacterData::setDataAndUpdate):
632         * editing/FrameSelection.cpp:
633         (WebCore::updatePositionAfterAdoptingTextReplacement):
634         (WebCore::FrameSelection::textWasReplaced):
635         * editing/FrameSelection.h:
636         (FrameSelection):
637
638 2012-06-07  Li Yin  <li.yin@intel.com>
639
640         FileAPI: If type consists of non-ASCII characters in Blob constructor, it should throw a SyntaxError.
641         https://bugs.webkit.org/show_bug.cgi?id=88411
642
643         Reviewed by Kentaro Hara.
644
645         From spec: http://dev.w3.org/2006/webapi/FileAPI/#constructorBlob
646         If type consists of any non-ASCII characters, throw a SyntaxError and
647         return from this algorithm.
648         This patch checks the String is ASCii or not, if not, throw SyntaxError.
649
650         Test: fast/files/blob-constructor.html
651
652         * bindings/js/JSBlobCustom.cpp:
653         (WebCore::JSBlobConstructor::constructJSBlob):
654         * bindings/v8/custom/V8BlobCustom.cpp:
655         (WebCore::V8Blob::constructorCallback):
656
657 2012-06-07  Arpita Bahuguna  <arpitabahuguna@gmail.com>
658
659         InsertUnorderedList and InsertOrderedList (execCommand) do not remove bullets
660         https://bugs.webkit.org/show_bug.cgi?id=84597
661
662         Reviewed by Ryosuke Niwa.
663
664         Comparison between start and end VisiblePositions will fail when a position inside
665         a paragraph is compared with one at the start of the paragraph.
666         
667         This fix thus converts the end VisiblePosition (which could be inside the paragraph)
668         to the start of the paragraph thereby enabling a proper comparison of start and end
669         positions.
670
671         Test: editing/execCommand/remove-list-from-multi-list-items.html
672
673         * editing/InsertListCommand.cpp:
674         (WebCore::InsertListCommand::selectionHasListOfType):
675
676 2012-06-07  Li Yin  <li.yin@intel.com>
677
678         [FileAPI] FileReader should throw an InvalidStateError exception when readyState is LOADING
679         https://bugs.webkit.org/show_bug.cgi?id=88212
680
681         Reviewed by Jian Li.
682
683         From Spec: http://www.w3.org/TR/FileAPI/#readAsBinaryString
684         FileReader should throw an InvalidStateError exception instead of NOT_ALLOWED_ERR
685         when the readyState is LOADING.
686         Also delete OperationNotAllowedException related code, because it is not longer needed.
687
688         Tests: fast/files/read-file-async.html
689                fast/files/workers/worker-read-file-async.html
690
691         * CMakeLists.txt:
692         * DerivedSources.cpp:
693         * DerivedSources.make:
694         * DerivedSources.pri:
695         * GNUmakefile.list.am:
696         * Target.pri:
697         * WebCore.gypi:
698         * WebCore.vcproj/WebCore.vcproj:
699         * WebCore.xcodeproj/project.pbxproj:
700         * dom/DOMExceptions.in:
701         * fileapi/FileReader.cpp:
702         (WebCore::FileReader::readInternal): Changed it to throw INVALID_STATE_ERR.
703         * fileapi/FileReader.idl: Changed it to raise DOMException for all read methods.
704         * fileapi/OperationNotAllowedException.cpp: Removed.
705         * fileapi/OperationNotAllowedException.h: Removed.
706         * fileapi/OperationNotAllowedException.idl: Removed.
707
708 2012-06-07  Sheriff Bot  <webkit.review.bot@gmail.com>
709
710         Unreviewed, rolling out r119689.
711         http://trac.webkit.org/changeset/119689
712         https://bugs.webkit.org/show_bug.cgi?id=88516
713
714         it broke didDrawNotCalledOnScissoredLayer webkit_unit_test
715         (Requested by loislo on #webkit).
716
717         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
718         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
719         (WebCore::CCLayerTreeHostImpl::didDrawAllLayers):
720
721 2012-06-07  Ami Fischman  <fischman@chromium.org>
722
723         Plumb CORS attribute information from HTMLMediaElement to media players so it can be used
724         https://bugs.webkit.org/show_bug.cgi?id=88349
725
726         Reviewed by Adam Barth.
727
728         Test: http/tests/security/video-cross-origin-readback.html
729
730         * html/HTMLMediaElement.cpp:
731         (WebCore::HTMLMediaElement::mediaPlayerCORSMode):
732         (WebCore):
733         * html/HTMLMediaElement.h:
734         (HTMLMediaElement):
735         * platform/graphics/MediaPlayer.h:
736         (WebCore::MediaPlayerClient::mediaPlayerCORSMode):
737
738 2012-06-07  Hironori Bono  <hbono@chromium.org>
739
740         Use light gray for grammar markers on Windows and Linux
741         https://bugs.webkit.org/show_bug.cgi?id=88398
742
743         Reviewed by Ryosuke Niwa.
744
745         This change changes the color of grammar markers from dark gray to light gray
746         and rebaselines a couple of pixel tests affected by this change.
747
748         No new tests because it changes the marker color of an existing test 'grammar-markers.html'.
749
750         * platform/graphics/skia/GraphicsContextSkia.cpp: Change dark gray to light gray.
751
752 2012-06-07  Yoshifumi Inoue  <yosin@chromium.org>
753
754         [Platform] Introduce conversion from/to Deciaml to/from double
755         https://bugs.webkit.org/show_bug.cgi?id=88480
756
757         Reviewed by Kent Tamura.
758
759         This patch added functions for Decimal/Double conversion and isInfinity
760         for reducing patch size of introducing Decimal arithmetic, bug 88383.
761
762         Tests: WebKit/chromium/tests/DecimalTest.cpp
763
764         * platform/Decimal.cpp:
765         (WebCore::Decimal::fromDouble): Added.
766         (WebCore::Decimal::toDouble): Added.
767         * platform/Decimal.h:
768         (WebCore::Decimal::EncodedData::isInfinity): Added for isinf()
769         (WebCore::Decimal::isInfinity): Added.
770
771 2012-06-06  Xianzhu Wang  <wangxianzhu@chromium.org>
772
773         Element.getBoundingClientRect() and Element.getClientRects() return incorrect values in frames in a scaled page
774         https://bugs.webkit.org/show_bug.cgi?id=88430
775
776         Element.getBoudingClientRect() and Element.getClientRects() should not scale back the rects
777         if the element is in a frame because page scale only apply to elements in the main frame.
778
779         Reviewed by James Robinson.
780
781         Tests: fast/dom/Element/scale-page-bounding-client-rect-in-frame.html
782                fast/dom/Element/scale-page-client-rects-in-frame.html
783
784         * dom/Document.cpp:
785         (WebCore):
786         (WebCore::Document::adjustFloatQuadsForScrollAndAbsoluteZoomAndFrameScale): Extracted from Element.cpp and Range.cpp and fixed issue of pageScale in frames.
787         (WebCore::Document::adjustFloatRectForScrollAndAbsoluteZoomAndFrameScale): Extracted from Element.cpp and fixed issue of pageScale in frames.
788         * dom/Document.h:
789         (WebCore):
790         (Document):
791         * dom/Element.cpp:
792         (WebCore::Element::getClientRects):
793         (WebCore::Element::getBoundingClientRect):
794         * dom/Range.cpp:
795         (WebCore):
796         (WebCore::adjustFloatQuadsForScrollAndAbsoluteZoomAndPageScale): Moved into Document and fixed issue of pageScale in frames.
797         (WebCore::Range::getBorderAndTextQuads):
798         * rendering/RenderObject.h: Removed adjustFloatQuadForPageScale and adjustFloatRectForPageScale because they seem unrelated to RenderObject.
799         (WebCore):
800
801 2012-06-06  Dana Jansens  <danakj@chromium.org>
802
803         [chromium] In each composited frame, didDraw() should only be called on layers for which willDraw() was called
804         https://bugs.webkit.org/show_bug.cgi?id=88469
805
806         Reviewed by James Robinson.
807
808         Unit test: CCLayerTreeHostImplTest.didDrawNotCalledOnScissoredLayer
809
810         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
811         (WebCore::shouldDrawLayer):
812         (WebCore):
813         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
814         (WebCore::CCLayerTreeHostImpl::didDrawAllLayers):
815
816 2012-06-06  Andy Estes  <aestes@apple.com>
817
818         Wrap uppercaseWord, lowercaseWord, and capitalizeWord with USE(APPKIT)
819         https://bugs.webkit.org/show_bug.cgi?id=88504
820
821         Reviewed by Dan Bernstein.
822
823         uppercaseWord, lowercaseWord, and capitalizeWord are methods declared
824         by NSResponder that subclasses are expected to implement. WebKit should
825         only support these implementations on platforms that use AppKit.
826
827         * WebCore.exp.in:
828         * editing/Editor.cpp:
829         * editing/Editor.h:
830         * loader/EmptyClients.h:
831         * page/ContextMenuController.cpp:
832         * page/EditorClient.h:
833
834 2012-06-06  Sheriff Bot  <webkit.review.bot@gmail.com>
835
836         Unreviewed, rolling out r119683.
837         http://trac.webkit.org/changeset/119683
838         https://bugs.webkit.org/show_bug.cgi?id=88505
839
840         it broke webkit-unit-test
841         WebLayerTreeViewThreadedTest.InstrumentationCallbacks on mac
842         (Requested by loislo on #webkit).
843
844         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
845         (WebCore::CCLayerTreeHost::initializeLayerRenderer):
846         (WebCore::CCLayerTreeHost::setVisible):
847
848 2012-06-06  Robert Kroeger  <rjkroege@chromium.org>
849
850         [Chromium] Re-enable handling of smooth scrolling on Chromium Linux/Windows
851         https://bugs.webkit.org/show_bug.cgi?id=87535 by adding support for
852         m_hasPreciseScrollingDelta on all Chromium platforms and adjusting ScrollAnimator
853         and ScrollAnimatorNone accordingly to let m_hasPreciseScrollingDelta == true
854         force exact (non-animated) scrolling.
855
856         Reviewed by James Robinson.
857
858         Updated WebKit unit tests to validate change.
859
860         * platform/PlatformWheelEvent.h:
861         (WebCore::PlatformWheelEvent::PlatformWheelEvent): Adjusted #ifdefs to
862         make m_hasPreciseScrollingDelta available on all Chromium platforms.
863         (PlatformWheelEvent):
864         * platform/ScrollAnimator.cpp:
865         (WebCore::ScrollAnimator::handleWheelEvent): Default scroll type is set based on 
866         m_hasPreciseScrollingDelta value.
867         * platform/ScrollAnimatorNone.cpp:
868         (WebCore::ScrollAnimatorNone::scroll): Scroll precisely when necessary.
869         * platform/ScrollTypes.h: Added additional pixel scrolling subtype.
870         * platform/ScrollableArea.cpp:
871         (WebCore::ScrollableArea::scroll): Updated for additional pixel scroll subtype.
872
873 2012-06-06  Michal Mocny  <mmocny@google.com>
874
875         [chromium] Stop dropping texture limits when the layer tree host becomes invisible, and initialize with 0 allocation.
876         https://bugs.webkit.org/show_bug.cgi?id=87747
877
878         Reviewed by Adrienne Walker.
879
880         GpuMemoryManager manages texture memory allocation limits. It will send a 0 allocation when a renderer becomes
881         invisible, and an appropriate allocation after a renderer is initialized.  These numbers will change
882         depending on the state of memory across devices and other renderers, so we would like to remove all explicit
883         management by the renderers themselves.
884
885         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
886         (WebCore::CCLayerTreeHost::initializeLayerRenderer):
887         (WebCore::CCLayerTreeHost::setVisible):
888
889 2012-06-06  Sheriff Bot  <webkit.review.bot@gmail.com>
890
891         Unreviewed, rolling out r119680.
892         http://trac.webkit.org/changeset/119680
893         https://bugs.webkit.org/show_bug.cgi?id=88498
894
895         It broke mac build (Requested by kinuko on #webkit).
896
897         * fileapi/File.cpp:
898         (WebCore::File::File):
899         (WebCore::File::lastModifiedDate):
900         (WebCore::File::lastModifiedDateForBinding):
901         (WebCore):
902         (WebCore::File::captureSnapshot):
903         * fileapi/File.h:
904         (File):
905         * fileapi/File.idl:
906         * platform/FileMetadata.h:
907         (WebCore::FileMetadata::FileMetadata):
908         * platform/FileSystem.h:
909         * platform/chromium/support/WebHTTPBody.cpp:
910         (WebKit::WebHTTPBody::elementAt):
911         * platform/network/BlobData.cpp:
912         (WebCore):
913
914 2012-06-06  Kinuko Yasuda  <kinuko@chromium.org>
915
916         File::lastModifiedDate should use NaN or separate boolean flag for null Date value
917         https://bugs.webkit.org/show_bug.cgi?id=87826
918
919         Reviewed by Kent Tamura.
920
921         Test: http/tests/local/fileapi/file-last-modified-after-delete.html
922
923         * fileapi/File.cpp:
924         (WebCore::File::File):
925         (WebCore::File::captureSnapshot):
926         (WebCore::File::lastModifiedDate):
927         (WebCore::File::lastModifiedDateForBinding): Removed.
928         * fileapi/File.h:
929         (File):
930         * fileapi/File.idl:
931         * platform/FileMetadata.h:
932         (WebCore::FileMetadata::FileMetadata):
933         * platform/FileSystem.h:
934         * platform/chromium/support/WebHTTPBody.cpp:
935         (WebKit::WebHTTPBody::elementAt):
936         * platform/network/BlobData.cpp:
937         (WebCore):
938
939 2012-06-06  Sheriff Bot  <webkit.review.bot@gmail.com>
940
941         Unreviewed, rolling out r119668.
942         http://trac.webkit.org/changeset/119668
943         https://bugs.webkit.org/show_bug.cgi?id=88493
944
945         Hitting assertions in debug builds (Requested by rniwa on
946         #webkit).
947
948         * rendering/RenderBlock.cpp:
949         (WebCore::RenderBlock::localCaretRect):
950         * rendering/RenderBoxModelObject.cpp:
951         * rendering/RenderBoxModelObject.h:
952         (RenderBoxModelObject):
953         * rendering/RenderInline.cpp:
954         * rendering/RenderInline.h:
955         (RenderInline):
956
957 2012-06-06  Julien Chaffraix  <jchaffraix@webkit.org>
958
959         Cache isSelfPaintingLayer() for better performance
960         https://bugs.webkit.org/show_bug.cgi?id=88464
961
962         Reviewed by Simon Fraser.
963
964         Covered by existing tests (repaint tests among them).
965
966         isSelfPaintingLayer() has shown up several times on some scrolling benchmarks due
967         to the function being called several time per paint phase. This change caches the
968         boolean at style change time.
969         
970         On http://dglazkov.github.com/performance-tests/biggrid.html, this nearly speed-up
971         painting by 2 (lowering the time taken to paint the newly exposed area when scrolling
972         on a 10,000 * 100 table from 95ms to 50ms).
973
974         * rendering/RenderLayer.cpp:
975         (WebCore::RenderLayer::RenderLayer):
976         Initialized m_isSelfPaintingLayer here.
977
978         (WebCore::RenderLayer::paintLayer):
979         Changed the order of the checks to get the more likely check first.
980
981         (WebCore::RenderLayer::shouldBeSelfPaintingLayer):
982         Renamed from isSelfPaintingLayer to make m_isNormalFlowOnly.
983
984         (WebCore::RenderLayer::styleChanged):
985         Added code to update our cached m_isSelfPaintingLayer.
986
987         * rendering/RenderLayer.h:
988         (WebCore::RenderLayer::isSelfPaintingLayer):
989         Changed to return m_isSelfPaintingLayer.
990
991 2012-06-06  Yoshifumi Inoue  <yosin@chromium.org>
992
993         REGRESSION(r109729) [Form] Rendering of select/optgroup/option combination is too slow.
994         https://bugs.webkit.org/show_bug.cgi?id=88059
995
996         Reviewed by Kent Tamura.
997
998         This patch changes not to share RenderStyle object for option and
999         optgroup element regardless attributes.
1000
1001         When we tried to shared RenderStyle object, rendering performance was
1002         good but we had issue in selected option and text transform, see
1003         https://bugs.webkit.org/show_bug.cgi?id=88405 for details.
1004
1005         No new tests. This patch doesn't change behavior but rendering performance.
1006
1007         * css/StyleResolver.cpp:
1008         (WebCore::StyleResolver::canShareStyleWithElement): Changed to always
1009         return false for option and optgroup.
1010
1011 2012-06-06  Alec Flett  <alecflett@chromium.org>
1012
1013         IndexedDB: Optimize single-key get()
1014         https://bugs.webkit.org/show_bug.cgi?id=85288
1015
1016         Reviewed by Tony Chang.
1017
1018         No new tests, this is just an optimization.
1019
1020         After a recent refactoring, we started creating
1021         an internal cursor with every call to get(). The
1022         most common use of get() is with a single key,
1023         so provide a fast-path to avoid creating the cursor.
1024
1025         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
1026         (WebCore::IDBIndexBackendImpl::getByRangeInternal):
1027         * Modules/indexeddb/IDBKeyRange.h:
1028         (WebCore::IDBKeyRange::isOnlyKey):
1029         (IDBKeyRange):
1030         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
1031         (WebCore::IDBObjectStoreBackendImpl::getByRangeInternal):
1032
1033 2012-06-06  Shezan Baig  <shezbaig.wk@gmail.com>
1034
1035         Caret is not rendered in empty inline contenteditable elements
1036         https://bugs.webkit.org/show_bug.cgi?id=85793
1037
1038         Reviewed by Ryosuke Niwa.
1039
1040         Override localCaretRect in RenderInline. The implementation was almost
1041         identical to localCaretRect in RenderBlock for empty block elements, so
1042         I refactored RenderBlock::localCaretRect and moved the logic to a new
1043         method 'localCaretRectForEmptyElement' in RenderBoxModelObject. The
1044         implementation of 'localCaretRect' in RenderBlock and RenderInline both
1045         use this helper method in RenderBoxModelObject.
1046
1047         Tests: editing/selection/caret-in-empty-inline-1.html
1048                editing/selection/caret-in-empty-inline-2.html
1049
1050         * rendering/RenderBlock.cpp:
1051         (WebCore::RenderBlock::localCaretRect):
1052         Modified to use RenderBoxModelObject::localCaretRectForEmptyElement.
1053         * rendering/RenderBoxModelObject.cpp:
1054         (WebCore::RenderBoxModelObject::localCaretRectForEmptyElement):
1055         (WebCore):
1056         * rendering/RenderBoxModelObject.h:
1057         (RenderBoxModelObject):
1058         Add localCaretRectForEmptyElement helper method.
1059         * rendering/RenderInline.cpp:
1060         (WebCore::RenderInline::localCaretRect):
1061         (WebCore):
1062         * rendering/RenderInline.h:
1063         (RenderInline):
1064         Override localCaretRect using localCaretRectForEmptyElement.
1065
1066 2012-06-06  Alexis Menard  <alexis.menard@openbossa.org>
1067
1068         Fix border-image-slice failures on http://css3test.com.
1069         https://bugs.webkit.org/show_bug.cgi?id=88328
1070
1071         Reviewed by Tony Chang.
1072
1073         The old parsing code was assuming that the fill keyword comes after the
1074         numbers or the percentage values. http://www.w3.org/TR/css3-background/#the-border-image-slice
1075         defines the property like this : [<number> | <percentage>]{1,4} && fill? where the fill
1076         keyword is not mandatory. But according to http://www.w3.org/TR/CSS2/about.html "&&" 
1077         separates two or more components, all of which must occur, in any order. So the previous
1078         code was wrong the fill can come first following by the percentages or the numbers. http://css3test.com
1079         was covering this particular case. I took the opportunity to extend our coverage 
1080         by adding tests on many different values the boder-image-slice property could take. I
1081         also did a small cleanup by removing unused functions in BorderImageSliceParseContext.
1082
1083         Test: fast/css/getComputedStyle/getComputedStyle-border-image-slice.html
1084
1085         * css/CSSParser.cpp:
1086         (WebCore::BorderImageSliceParseContext::BorderImageSliceParseContext):
1087         (WebCore::BorderImageSliceParseContext::commitNumber):
1088         (WebCore::BorderImageSliceParseContext::commitFill):
1089
1090 2012-06-06  Levi Weintraub  <leviw@chromium.org>
1091
1092         Use enclosingIntRect instead of pixelSnappedIntRect in RenderFileUploadControl
1093         https://bugs.webkit.org/show_bug.cgi?id=88454
1094
1095         Reviewed by Kent Tamura.
1096
1097         Properly clipping the file upload control to avoid clipping out the top of the file upload button
1098         when the control is positioned at a sub-pixel offset that rounds up.
1099
1100         Test: fast/sub-pixel/file-upload-control-at-fractional-offset.html
1101
1102         * rendering/RenderFileUploadControl.cpp:
1103         (WebCore::RenderFileUploadControl::paintObject):
1104
1105 2012-06-06  Filip Pizlo  <fpizlo@apple.com>
1106
1107         Global object variable accesses should not require an extra load
1108         https://bugs.webkit.org/show_bug.cgi?id=88385
1109
1110         Reviewed by Gavin Barraclough and Geoffrey Garen.
1111
1112         Updated JSDOMWindowBase.cpp to use the new symbol table API. this->symbolTableFoo(...)
1113         becomes symbolTableFoo(this, ...).
1114                 
1115         No new tests because no change in behavior.
1116
1117         * bindings/js/JSDOMWindowBase.cpp:
1118         (WebCore::JSDOMWindowBase::updateDocument):
1119
1120 2012-06-06  James Robinson  <jamesr@chromium.org>
1121
1122         [chromium] Move implementation of WebCore::GraphicsContext3D and related from WebKit/chromium/src to WebCore/platform/chromium/support
1123         https://bugs.webkit.org/show_bug.cgi?id=86257
1124
1125         Reviewed by Kenneth Russell.
1126
1127         The WebCore platform interfaces GraphicsContext3D and Extensions3DChromium are implemented in chromium
1128         on top of the Platform interface WebGraphicsContext3D. This moves the implementation support code from
1129         WebKit/chromium/src to WebCore/platform/chromium/support, which avoids having code in WebKit/ implementing WebCore
1130         interfaces and allows code in WebCore/platform to use this support code directly where appropriate.
1131
1132         Refactor only, no new functionality or tests.
1133
1134         * WebCore.gypi:
1135         * platform/chromium/support/Extensions3DChromium.cpp: Renamed from Source/WebKit/chromium/src/Extensions3DChromium.cpp.
1136         (WebCore):
1137         (WebCore::Extensions3DChromium::Extensions3DChromium):
1138         (WebCore::Extensions3DChromium::~Extensions3DChromium):
1139         (WebCore::Extensions3DChromium::supports):
1140         (WebCore::Extensions3DChromium::ensureEnabled):
1141         (WebCore::Extensions3DChromium::isEnabled):
1142         (WebCore::Extensions3DChromium::getGraphicsResetStatusARB):
1143         (WebCore::Extensions3DChromium::blitFramebuffer):
1144         (WebCore::Extensions3DChromium::renderbufferStorageMultisample):
1145         (WebCore::Extensions3DChromium::postSubBufferCHROMIUM):
1146         (WebCore::Extensions3DChromium::mapBufferSubDataCHROMIUM):
1147         (WebCore::Extensions3DChromium::unmapBufferSubDataCHROMIUM):
1148         (WebCore::Extensions3DChromium::mapTexSubImage2DCHROMIUM):
1149         (WebCore::Extensions3DChromium::unmapTexSubImage2DCHROMIUM):
1150         (WebCore::Extensions3DChromium::setVisibilityCHROMIUM):
1151         (WebCore::Extensions3DChromium::discardFramebufferEXT):
1152         (WebCore::Extensions3DChromium::ensureFramebufferCHROMIUM):
1153         (WebCore::Extensions3DChromium::setGpuMemoryAllocationChangedCallbackCHROMIUM):
1154         (WebCore::Extensions3DChromium::createVertexArrayOES):
1155         (WebCore::Extensions3DChromium::deleteVertexArrayOES):
1156         (WebCore::Extensions3DChromium::isVertexArrayOES):
1157         (WebCore::Extensions3DChromium::bindVertexArrayOES):
1158         (WebCore::Extensions3DChromium::getTranslatedShaderSourceANGLE):
1159         (WebCore::Extensions3DChromium::setSwapBuffersCompleteCallbackCHROMIUM):
1160         (WebCore::Extensions3DChromium::rateLimitOffscreenContextCHROMIUM):
1161         (WebCore::Extensions3DChromium::paintFramebufferToCanvas):
1162         (WebCore::Extensions3DChromium::texImageIOSurface2DCHROMIUM):
1163         (WebCore::Extensions3DChromium::texStorage2DEXT):
1164         (WebCore::Extensions3DChromium::createQueryEXT):
1165         (WebCore::Extensions3DChromium::deleteQueryEXT):
1166         (WebCore::Extensions3DChromium::isQueryEXT):
1167         (WebCore::Extensions3DChromium::beginQueryEXT):
1168         (WebCore::Extensions3DChromium::endQueryEXT):
1169         (WebCore::Extensions3DChromium::getQueryivEXT):
1170         (WebCore::Extensions3DChromium::getQueryObjectuivEXT):
1171         * platform/chromium/support/GraphicsContext3DChromium.cpp: Renamed from Source/WebKit/chromium/src/GraphicsContext3DChromium.cpp.
1172         (WebCore):
1173         (WebCore::GraphicsContext3D::GraphicsContext3D):
1174         (WebCore::GraphicsContext3D::~GraphicsContext3D):
1175         (WebCore::GraphicsContext3D::setContextLostCallback):
1176         (WebCore::GraphicsContext3D::setErrorMessageCallback):
1177         (WebCore::GraphicsContext3D::create):
1178         (WebCore::GraphicsContext3D::platformGraphicsContext3D):
1179         (WebCore::GraphicsContext3D::platformTexture):
1180         (WebCore::GraphicsContext3D::grContext):
1181         (WebCore::GraphicsContext3D::platformLayer):
1182         (WebCore::GraphicsContext3D::isGLES2Compliant):
1183         (WebCore::GraphicsContext3D::isResourceSafe):
1184         (WebCore::GraphicsContext3D::bindAttribLocation):
1185         (WebCore::GraphicsContext3D::bufferData):
1186         (WebCore::GraphicsContext3D::getActiveAttrib):
1187         (WebCore::GraphicsContext3D::getActiveUniform):
1188         (WebCore::GraphicsContext3D::getAttribLocation):
1189         (WebCore::GraphicsContext3D::getContextAttributes):
1190         (WebCore::GraphicsContext3D::getProgramInfoLog):
1191         (WebCore::GraphicsContext3D::getShaderInfoLog):
1192         (WebCore::GraphicsContext3D::getShaderSource):
1193         (WebCore::GraphicsContext3D::getString):
1194         (WebCore::GraphicsContext3D::getUniformLocation):
1195         (WebCore::GraphicsContext3D::shaderSource):
1196         (WebCore::GraphicsContext3D::texImage2D):
1197         (WebCore::GraphicsContext3D::texSubImage2D):
1198         (WebCore::GraphicsContext3D::reshape):
1199         (WebCore::GraphicsContext3D::markContextChanged):
1200         (WebCore::GraphicsContext3D::layerComposited):
1201         (WebCore::GraphicsContext3D::markLayerComposited):
1202         (WebCore::GraphicsContext3D::paintRenderingResultsToCanvas):
1203         (WebCore::GraphicsContext3D::paintRenderingResultsToImageData):
1204         (WebCore::GraphicsContext3D::paintCompositedResultsToCanvas):
1205         (WebCore::GraphicsContext3D::getExtensions):
1206         (WebCore::GraphicsContext3D::getInternalFramebufferSize):
1207         * platform/chromium/support/GraphicsContext3DPrivate.cpp: Renamed from Source/WebKit/chromium/src/GraphicsContext3DPrivate.cpp.
1208         (WebCore):
1209         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
1210         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
1211         (WebCore::GraphicsContext3DPrivate::createGraphicsContextFromWebContext):
1212         (WebCore::GraphicsContext3DPrivate::extractWebGraphicsContext3D):
1213         (GrMemoryAllocationChangedCallback):
1214         (WebCore::GrMemoryAllocationChangedCallback::GrMemoryAllocationChangedCallback):
1215         (WebCore::GrMemoryAllocationChangedCallback::onGpuMemoryAllocationChanged):
1216         (WebCore::GraphicsContext3DPrivate::grContext):
1217         (WebCore::GraphicsContext3DPrivate::markContextChanged):
1218         (WebCore::GraphicsContext3DPrivate::layerComposited):
1219         (WebCore::GraphicsContext3DPrivate::markLayerComposited):
1220         (WebCore::GraphicsContext3DPrivate::paintFramebufferToCanvas):
1221         (GraphicsContext3DContextLostCallbackAdapter):
1222         (WebCore::GraphicsContext3DContextLostCallbackAdapter::GraphicsContext3DContextLostCallbackAdapter):
1223         (WebCore::GraphicsContext3DContextLostCallbackAdapter::~GraphicsContext3DContextLostCallbackAdapter):
1224         (WebCore::GraphicsContext3DContextLostCallbackAdapter::onContextLost):
1225         (WebCore::GraphicsContext3DPrivate::setContextLostCallback):
1226         (GraphicsContext3DErrorMessageCallbackAdapter):
1227         (WebCore::GraphicsContext3DErrorMessageCallbackAdapter::GraphicsContext3DErrorMessageCallbackAdapter):
1228         (WebCore::GraphicsContext3DErrorMessageCallbackAdapter::~GraphicsContext3DErrorMessageCallbackAdapter):
1229         (WebCore::GraphicsContext3DErrorMessageCallbackAdapter::onErrorMessage):
1230         (WebCore::GraphicsContext3DPrivate::setErrorMessageCallback):
1231         (WebCore::GraphicsContext3DPrivate::getExtensions):
1232         (WebCore::GraphicsContext3DPrivate::initializeExtensions):
1233         (WebCore::GraphicsContext3DPrivate::supportsExtension):
1234         (WebCore::GraphicsContext3DPrivate::ensureExtensionEnabled):
1235         (WebCore::GraphicsContext3DPrivate::isExtensionEnabled):
1236         (WebCore::GraphicsContext3DPrivate::isResourceSafe):
1237         (GraphicsContext3DMemoryAllocationChangedCallbackAdapter):
1238         (WebCore::GraphicsContext3DMemoryAllocationChangedCallbackAdapter::GraphicsContext3DMemoryAllocationChangedCallbackAdapter):
1239         (WebCore::GraphicsContext3DMemoryAllocationChangedCallbackAdapter::~GraphicsContext3DMemoryAllocationChangedCallbackAdapter):
1240         (WebCore::GraphicsContext3DMemoryAllocationChangedCallbackAdapter::onMemoryAllocationChanged):
1241         (WebCore::GraphicsContext3DPrivate::setGpuMemoryAllocationChangedCallbackCHROMIUM):
1242         (GraphicsContext3DSwapBuffersCompleteCallbackAdapter):
1243         (WebCore::GraphicsContext3DSwapBuffersCompleteCallbackAdapter::GraphicsContext3DSwapBuffersCompleteCallbackAdapter):
1244         (WebCore::GraphicsContext3DSwapBuffersCompleteCallbackAdapter::~GraphicsContext3DSwapBuffersCompleteCallbackAdapter):
1245         (WebCore::GraphicsContext3DSwapBuffersCompleteCallbackAdapter::onSwapBuffersComplete):
1246         (WebCore::GraphicsContext3DPrivate::setSwapBuffersCompleteCallbackCHROMIUM):
1247         * platform/chromium/support/GraphicsContext3DPrivate.h: Renamed from Source/WebKit/chromium/src/GraphicsContext3DPrivate.h.
1248         (WebKit):
1249         (WebCore):
1250         (GraphicsContext3DPrivate):
1251         (WebCore::GraphicsContext3DPrivate::webContext):
1252         (WebCore::GraphicsContext3DPrivate::preserveDrawingBuffer):
1253
1254 2012-06-06  Sheriff Bot  <webkit.review.bot@gmail.com>
1255
1256         Unreviewed, rolling out r119624.
1257         http://trac.webkit.org/changeset/119624
1258         https://bugs.webkit.org/show_bug.cgi?id=88472
1259
1260         Caused worker tests to become flaky (Requested by mhahnenberg
1261         on #webkit).
1262
1263         * workers/AbstractWorker.cpp:
1264         (WebCore::AbstractWorker::~AbstractWorker):
1265         * workers/WorkerMessagingProxy.cpp:
1266         (WebCore::WorkerMessagingProxy::workerObjectDestroyed):
1267
1268 2012-06-06  Brady Eidson  <beidson@apple.com>
1269
1270         <rdar://problem/11575112> and https://bugs.webkit.org/show_bug.cgi?id=88428
1271         REGRESSION (r115654): Opening many non-English WebArchives shows obvious encoding issues
1272
1273         Reviewed by Nate Chapin.
1274
1275         Test: fast/loader/webarchive-encoding-respected.html
1276
1277         * loader/DocumentLoader.cpp:
1278         (WebCore::DocumentLoader::commitData): Properly set the main resource encoding from the webarchive.
1279
1280 2012-06-06  Mark Hahnenberg  <mhahnenberg@apple.com>
1281
1282         Worker tear-down can re-enter JSC during GC finalization
1283         https://bugs.webkit.org/show_bug.cgi?id=88449
1284
1285         Reviewed by Geoffrey Garen.
1286
1287         No new tests. Current regression tests cover these changes.
1288
1289         * workers/AbstractWorker.cpp: 
1290         (WebCore::AbstractWorker::~AbstractWorker): We don't need to call onDestroyWorker() here, it 
1291         will be called elsewhere in contextDestroyed().
1292         * workers/WorkerMessagingProxy.cpp:
1293         (WebCore::WorkerMessagingProxy::workerObjectDestroyed): We make the call to terminateWorkerContext()
1294         and workerContextDestroyed() asynchronous to avoid entering JSC during GC finalization.
1295
1296 2012-06-06  Tony Chang  <tony@chromium.org>
1297
1298         webkit crashes on debug builds when running IETC flexbox-ordinal-group-001.htm
1299         https://bugs.webkit.org/show_bug.cgi?id=85832
1300
1301         Reviewed by Ojan Vafai.
1302
1303         We were using a HashSet<unsigned>, which can't hold the value of 0.
1304         According to the spec, 0 isn't a valid value, so at CSS parse time,
1305         reject the value 0. This lets us pass the test, although that's kind
1306         of by accident.
1307
1308         We could allow 0 for box-ordinal-group, but there are some perf implications
1309         to having allowing a value below the initial value (1 in this case).
1310
1311         We still allow 0 for box-flex-group, because that's what the existing code
1312         does and there are tests expecting this behavior.
1313
1314         No new tests, covered by ietestcenter/css3/flexbox/flexbox-ordinal-group-001.htm
1315         which was crashing.
1316
1317         * css/CSSParser.cpp:
1318         (WebCore::CSSParser::parseValue): Reject 0 for -webkit-box-ordinal-group.
1319
1320 2012-06-06  Ojan Vafai  <ojan@chromium.org>
1321
1322         Remove some magic from the -webkit-flex shorthand parsing to match the changes in the spec
1323         https://bugs.webkit.org/show_bug.cgi?id=88444
1324
1325         Reviewed by Tony Chang.
1326
1327         -Unset positive flex defaults to 0.
1328         -Unset negative flex defaults to 1. No magic of doing something different if positive flex was set.
1329
1330         * css/CSSParser.cpp:
1331         (WebCore::CSSParser::parseFlex):
1332
1333 2012-06-06  Ryosuke Niwa  <rniwa@webkit.org>
1334
1335         Revert r119440 now that I have a time to rebaseline them all!
1336
1337         * platform/ScrollbarThemeComposite.cpp:
1338         (WebCore::ScrollbarThemeComposite::thumbLength):
1339
1340 2012-06-06  Joshua Bell  <jsbell@chromium.org>
1341
1342         IndexedDB: Infinite recursion in IDBObjectStore.openCursor(key, legacy_constant)
1343         https://bugs.webkit.org/show_bug.cgi?id=88431
1344
1345         Reviewed by Tony Chang.
1346
1347         Function was calling itself, rather than delegating to the correct (IDBKeyRange) overload.
1348
1349         Test: storage/indexeddb/legacy-constants.html
1350
1351         * Modules/indexeddb/IDBObjectStore.cpp:
1352         (WebCore::IDBObjectStore::openCursor):
1353
1354 2012-06-06  Joshua Bell  <jsbell@chromium.org>
1355
1356         IndexedDB: Rename IDBFactory.getDatabaseNames() to webkitGetDatabaseNames()
1357         https://bugs.webkit.org/show_bug.cgi?id=86874
1358
1359         Reviewed by Ojan Vafai.
1360
1361         The function is non-standard, and should be prefixed.
1362
1363         Test: storage/indexeddb/factory-basics.html
1364
1365         * Modules/indexeddb/IDBFactory.idl:
1366
1367 2012-06-06  Julien Chaffraix  <jchaffraix@webkit.org>
1368
1369         Add support for direction on table row group with collapsing borders
1370         https://bugs.webkit.org/show_bug.cgi?id=87900
1371
1372         Reviewed by Ojan Vafai.
1373
1374         Tests: fast/table/border-collapsing/first-cell-left-border-hidden-table-ltr-section-rtl.html
1375                fast/table/border-collapsing/last-cell-left-border-hidden-table-ltr-section-rtl.html
1376                fast/table/border-collapsing/left-border-table-ltr-section-rtl.html
1377                fast/table/border-collapsing/left-border-table-rtl-section-ltr.html
1378                fast/table/border-collapsing/left-border-table-rtl-section-rtl.html
1379                fast/table/border-collapsing/left-border-vertical-lr-table-ltr-section-rtl.html
1380                fast/table/border-collapsing/left-border-vertical-lr-table-rtl-section-ltr.html
1381                fast/table/border-collapsing/left-border-vertical-lr-table-rtl-section-rtl.html
1382                fast/table/border-collapsing/rtl-table-left-border-hidden.html
1383                fast/table/border-collapsing/top-border-vertical-rl-table-ltr-section-rtl.html
1384                fast/table/border-collapsing/top-border-vertical-rl-table-rtl-section-ltr.html
1385                fast/table/border-collapsing/top-border-vertical-rl-table-rtl-section-rtl.html
1386                fast/table/table-ltr-section-rtl.html
1387                fast/table/table-rtl-section-ltr.html
1388                fast/table/table-rtl-section-rtl.html
1389
1390         This change enables proper support for direction on table row group.
1391         The current code would allow people to set direction on the row group but would still
1392         use the table's code for directionality checks (with surprising consequences).
1393
1394         The main change involve swapping end / start borders in case of mixed directionality
1395         as those 2 are not in sync.
1396         
1397         Example: <table dir="ltr"><tbody dir="rtl"><td id="cell0"></td><td id="cell1"></td></tbody></table>
1398
1399         Visually:
1400         Table: Start ---------------------> End
1401         Tbody: End <---------------------- Start
1402         Cell:  | #cell0        |           #cell1 |
1403
1404         In this example, the end table border should be compared with the tbody's start border
1405         and the last cell's (in DOM order) start border.
1406
1407         * rendering/RenderTable.cpp:
1408         (WebCore::RenderTable::tableStartBorderAdjoiningCell):
1409         (WebCore::RenderTable::tableEndBorderAdjoiningCell):
1410         Same as the other adjoining functions.
1411
1412         * rendering/RenderTable.h:
1413         (WebCore::RenderTable::lastColumnIndex):
1414         Helper function to get the last column index.
1415
1416         * rendering/RenderTableCell.cpp:
1417         (WebCore::RenderTableCell::computeCollapsedStartBorder):
1418         (WebCore::RenderTableCell::computeCollapsedEndBorder):
1419         Updated to call the table's adjoining border helpers.
1420
1421         * rendering/RenderTableCell.h:
1422         (WebCore::RenderTableCell::styleForCellFlow):
1423         Updated to use the table row group's style now that we properly support it.
1424
1425         (WebCore::RenderTableCell::isFirstOrLastCellInRow):
1426         Debug only helper to make sure we don't call the border adjoining function
1427         on non-terminal cells.
1428
1429         (WebCore::RenderTableCell::borderAdjoiningTableStart):
1430         (WebCore::RenderTableCell::borderAdjoiningTableEnd):
1431         * rendering/RenderTableRow.h:
1432         (WebCore::RenderTableRow::borderAdjoiningTableStart):
1433         (WebCore::RenderTableRow::borderAdjoiningTableEnd):
1434         * rendering/RenderTableSection.cpp:
1435         (WebCore::RenderTableSection::firstRowCellAdjoiningTableStart):
1436         (WebCore::RenderTableSection::firstRowCellAdjoiningTableEnd):
1437         Updated the previous function to account for mixed directionality.
1438
1439         (WebCore::RenderTableSection::layoutRows):
1440         Move some of the code to setLogicalPositionForCell to match RenderBlock.
1441
1442         (WebCore::RenderTableSection::setLogicalPositionForCell):
1443         Switched direction checks to styleForCellFlow (this doesn't change anything as we
1444         were already properly flipping already but ensure better).
1445
1446         * rendering/RenderTableSection.h:
1447         (WebCore::RenderTableSection::hasSameDirectionAsTable):
1448         Added this helper to know if we have a mixed direction.
1449
1450         (WebCore::RenderTableSection::borderAdjoiningTableStart):
1451         (WebCore::RenderTableSection::borderAdjoiningTableEnd):
1452         Updated to account for mixed directionality.
1453
1454 2012-06-06  Keyar Hood  <keyar@chromium.org>
1455
1456         [Chromium] imageSmoothingEnabled should apply to patterns
1457         https://bugs.webkit.org/show_bug.cgi?id=88103
1458
1459         Reviewed by Stephen White.
1460
1461         Test: fast/canvas/canvas-imageSmoothingEnabled-patterns.html
1462
1463         When drawing patterns on a Canvas, the imageSmoothingEnabled flag is
1464         respected.
1465         * platform/graphics/skia/PlatformContextSkia.cpp:
1466         (WebCore::PlatformContextSkia::setupShader):
1467
1468 2012-06-06  Andrey Adaikin  <aandrey@chromium.org>
1469
1470         Web Inspector: [JSC] Add WebGL instrumentation support
1471         https://bugs.webkit.org/show_bug.cgi?id=87975
1472
1473         Reviewed by Vsevolod Vlasov.
1474
1475         * bindings/js/JSInjectedScriptManager.cpp:
1476         (WebCore::injectAndExecuteFunction):
1477         (WebCore::InjectedScriptManager::createInjectedScript):
1478         (WebCore):
1479         (WebCore::InjectedScriptManager::injectWebGLScript):
1480         * bindings/v8/custom/V8InjectedScriptManager.cpp:
1481         (WebCore::InjectedScriptManager::injectWebGLScript):
1482         * inspector/InjectedScriptManager.cpp:
1483         (WebCore::InjectedScriptManager::wrapWebGLRenderingContextForInstrumentation):
1484         * inspector/InjectedScriptManager.h:
1485         (InjectedScriptManager):
1486         * inspector/InspectorInstrumentation.h:
1487         (InspectorInstrumentation):
1488         * inspector/InspectorWebGLAgent.cpp:
1489         (WebCore::InspectorWebGLAgent::wrapWebGLRenderingContextForInstrumentation):
1490         * inspector/InspectorWebGLAgent.h:
1491         (InspectorWebGLAgent):
1492         * inspector/InspectorWebGLInstrumentation.h:
1493         (WebCore::InspectorInstrumentation::wrapWebGLRenderingContextForInstrumentation):
1494
1495 2012-06-06  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
1496
1497         Fix a few spelling mistakes in IconDatabase logging
1498
1499         Makes debugging harder if the logging is confusing.
1500
1501         Reviewed by Jocelyn Turcotte.
1502
1503         * loader/icon/IconDatabase.cpp:
1504         (WebCore::IconDatabase::notifyPendingLoadDecisions):
1505         (WebCore::IconDatabase::readFromDatabase):
1506
1507 2012-05-25  Vsevolod Vlasov  <vsevik@chromium.org>
1508
1509         Web Inspector: [Compiler] Remove compile-front-end.sh and fix InjectedScriptSource errors.
1510         https://bugs.webkit.org/show_bug.cgi?id=87512
1511
1512         Reviewed by Yury Semikhatsky.
1513
1514         Removed compile-front-end.sh, compile-front-end.py should be used instead now.
1515         Made generate_protocol_externs a python module to call it from compile-front-end.py.
1516         Temporary copy of InjectedScriptSource.js is created and modified to
1517         avoid "This code lacks side effects" warning.
1518
1519         * inspector/compile-front-end.py:
1520         * inspector/compile-front-end.sh: Removed.
1521         * inspector/generate-protocol-externs: Removed.
1522         * inspector/generate_protocol_externs.py: Added.
1523         (full_qualified_type_id):
1524         (param_type):
1525         (generate_protocol_externs):
1526
1527 2012-06-06  Zoltan Herczeg  <zherczeg@webkit.org>
1528
1529         [Qt] REGRESSION(r118616): It made all tests crash in debug mode
1530         https://bugs.webkit.org/show_bug.cgi?id=87701
1531
1532         Reviewed by Csaba Osztrogonác.
1533
1534         Replace WriteBarrier<JSObject> to Weak<JSObject> by introducing a new
1535         QtWeakObjectReference sub class. Rewrite all affected type definitions.
1536
1537         All existing test in debug mode cover this issue.
1538
1539         * bridge/qt/qt_class.cpp:
1540         (JSC::Bindings::QtClass::fallbackObject):
1541         * bridge/qt/qt_instance.cpp:
1542         (QtRuntimeObject):
1543         (JSC::Bindings::QtInstance::removeUnusedMethods):
1544         * bridge/qt/qt_instance.h:
1545         (QtInstance):
1546         (QtWeakObjectReference):
1547         (JSC::Bindings::QtInstance::QtWeakObjectReference::QtWeakObjectReference):
1548         (JSC::Bindings::QtInstance::QtWeakObjectReference::operator=):
1549         (JSC::Bindings::QtInstance::QtWeakObjectReference::get):
1550         * bridge/qt/qt_runtime.cpp:
1551         (JSC::Bindings::QtRuntimeMethodData::finalize):
1552         * bridge/qt/qt_runtime_qt4.cpp:
1553         (JSC::Bindings::QtRuntimeMethodData::finalize):
1554
1555 2012-06-06  Eugene Klyuchnikov  <eustas.bug@gmail.com>
1556
1557         Web Inspector: help/settings screen does not overlay console in split screen mode
1558         https://bugs.webkit.org/show_bug.cgi?id=88352
1559
1560         Reviewed by Pavel Feldman.
1561
1562         * inspector/front-end/HelpScreen.js:
1563         (WebInspector.HelpScreen): Mark view as root.
1564         (WebInspector.HelpScreen.prototype.showModal): Change view parent.
1565         * inspector/front-end/helpScreen.css:
1566         (.help-window-outer): Add panel and status bar indent.
1567         (body.compact .help-window-outer): Ditto.
1568
1569 2012-06-06  Yoshifumi Inoue  <yosin@chromium.org>
1570
1571         [Form] Changes for InputNumber type
1572         https://bugs.webkit.org/show_bug.cgi?id=88394
1573
1574         Reviewed by Kent Tamura.
1575
1576         This patch changes codes for consitency of InputNumber usage for
1577         reducing size of patch when we change InputNumber type alias from
1578         double to Decimal.
1579
1580         No new tests. This patch doesn't change behavior.
1581
1582         * html/BaseDateAndTimeInputType.cpp:
1583         (WebCore::BaseDateAndTimeInputType::serializeWithComponents): Fixed parameter type for getAllowedValueStep.
1584         * html/InputType.cpp:
1585         (WebCore::InputType::minimum): Fixed return value type to InputNumber.
1586         (WebCore::InputType::maximum): ditto.
1587         * html/MonthInputType.cpp:
1588         (WebCore::MonthInputType::defaultValueForStepUp): Fix return value type to InputNumber.
1589         (WebCore::MonthInputType::parseToNumber): ditto.
1590         * html/NumberInputType.cpp:
1591         (WebCore::NumberInputType::setValueAsDouble): Removed extra convertDoubleToInputNumber.
1592         * html/StepRange.cpp:
1593         (WebCore::StepRange::alignValueForStep): Use roundByStep for code sharing.
1594         (WebCore::StepRange::clampValue): ditto.
1595         (WebCore::StepRange::roundByStep): Added.
1596         * html/StepRange.h:
1597         (StepRange): Added a declaration of roundByStep.
1598
1599 2012-06-06  Michael Brüning  <michael.bruning@nokia.com>
1600
1601         [Qt] Fix harmattan builds broken by r119247.
1602         https://bugs.webkit.org/show_bug.cgi?id=88330
1603
1604         Reviewed by Jocelyn Turcotte.
1605
1606         Fix Harmattan build break caused by undefined constant
1607         GL_TEXTURE_RECTANGLE_ARB by adding defined(GL_ARB_texture_rectangle)
1608         guards around TextureMapperGL::drawTextureRectangleARB.
1609
1610         * platform/graphics/texmap/TextureMapperGL.cpp: Added defined(GL_ARB_texture_rectangle) guards around drawTextureRectangleARB.
1611         (WebCore):
1612         * platform/graphics/texmap/TextureMapperGL.h: Added definded(GL_ARB_texture_rectangle) guards around drawTextureRectangleARB.
1613
1614 2012-06-06  Shinya Kawanaka  <shinyak@chromium.org>
1615
1616         PositionIterator:;setOffsetInLeafNode() is not used anywhere.
1617         https://bugs.webkit.org/show_bug.cgi?id=88397
1618
1619         Reviewed by Ryosuke Niwa.
1620
1621         It's not used anywhere. We can remove it safely.
1622
1623         No new tests, no change in behavior.
1624
1625         * WebCore.order:
1626         * dom/PositionIterator.cpp:
1627         * dom/PositionIterator.h:
1628
1629 2012-06-06  Andrey Adaikin  <aandrey@chromium.org>
1630
1631         Web Inspector: [WebGL] Add WebGL instrumentation support on the backend
1632         https://bugs.webkit.org/show_bug.cgi?id=87960
1633
1634         Adds a WebGLAgent, injects a WebGL script upon calling the getContext
1635         method of a HTMLCanvasElement that will wrap the WebGL rendering context
1636         for instrumentation purposes.
1637
1638         Reviewed by Yury Semikhatsky.
1639
1640         * CMakeLists.txt:
1641         * DerivedSources.make:
1642         * DerivedSources.pri:
1643         * GNUmakefile.am:
1644         * GNUmakefile.list.am:
1645         * Target.pri:
1646         * WebCore.gyp/WebCore.gyp:
1647         * WebCore.gypi:
1648         * WebCore.vcproj/WebCore.vcproj:
1649         * WebCore.xcodeproj/project.pbxproj:
1650         * bindings/js/JSHTMLCanvasElementCustom.cpp:
1651         (WebCore::JSHTMLCanvasElement::getContext):
1652         (WebCore::JSHTMLCanvasElement::toDataURL):
1653         * bindings/js/JSInjectedScriptManager.cpp:
1654         (WebCore):
1655         (WebCore::InjectedScriptManager::injectWebGLScript):
1656         * bindings/v8/ScriptState.cpp:
1657         (WebCore::ScriptState::forContext):
1658         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
1659         (WebCore::V8HTMLCanvasElement::getContextCallback):
1660         * bindings/v8/custom/V8InjectedScriptManager.cpp:
1661         (WebCore::InjectedScriptManager::createInjectedScript):
1662         (WebCore):
1663         (WebCore::InjectedScriptManager::injectWebGLScript):
1664         (WebCore::InjectedScriptManager::discardInjectedScript):
1665         (WebCore::InjectedScriptManager::injectedScriptFor):
1666         * inspector/CodeGeneratorInspector.py:
1667         * inspector/InjectedScriptManager.cpp:
1668         (WebCore):
1669         (WebCore::InjectedScriptManager::wrapWebGLRenderingContextForInstrumentation):
1670         (WebCore::InjectedScriptManager::injectedWebGLScriptSource):
1671         * inspector/InjectedScriptManager.h:
1672         (InjectedScriptManager):
1673         * inspector/InjectedWebGLScriptSource.js: Added.
1674         * inspector/Inspector.json:
1675         * inspector/InspectorAllInOne.cpp:
1676         * inspector/InspectorController.cpp:
1677         (WebCore::InspectorController::InspectorController):
1678         * inspector/InspectorInstrumentation.h:
1679         (WebCore):
1680         (InspectorInstrumentation):
1681         (WebCore::InspectorInstrumentation::markResourceAsCached):
1682         * inspector/InspectorWebGLAgent.cpp: Added.
1683         (WebCore):
1684         (WebGLAgentState):
1685         (WebCore::InspectorWebGLAgent::InspectorWebGLAgent):
1686         (WebCore::InspectorWebGLAgent::~InspectorWebGLAgent):
1687         (WebCore::InspectorWebGLAgent::setFrontend):
1688         (WebCore::InspectorWebGLAgent::clearFrontend):
1689         (WebCore::InspectorWebGLAgent::restore):
1690         (WebCore::InspectorWebGLAgent::enable):
1691         (WebCore::InspectorWebGLAgent::disable):
1692         (WebCore::InspectorWebGLAgent::wrapWebGLRenderingContextForInstrumentation):
1693         * inspector/InspectorWebGLAgent.h: Added.
1694         (WebCore):
1695         (InspectorWebGLAgent):
1696         (WebCore::InspectorWebGLAgent::create):
1697         (WebCore::InspectorWebGLAgent::enabled):
1698         * inspector/InspectorWebGLInstrumentation.h: Added.
1699         (WebCore):
1700         (WebCore::InspectorInstrumentation::wrapWebGLRenderingContextForInstrumentation):
1701         * inspector/InstrumentingAgents.h:
1702         (WebCore):
1703         (WebCore::InstrumentingAgents::InstrumentingAgents):
1704         (InstrumentingAgents):
1705         (WebCore::InstrumentingAgents::inspectorWebGLAgent):
1706         (WebCore::InstrumentingAgents::setInspectorWebGLAgent):
1707
1708 2012-06-06  Joone Hur  <joone.hur@intel.com>
1709
1710         [GTK] Build fix for Accelerated Compositing with OpenGL
1711         https://bugs.webkit.org/show_bug.cgi?id=88292
1712
1713         Reviewed by Martin Robinson.
1714
1715         Build fix after r119247.
1716         Do not include GraphicsSurface.h when not building
1717         with GRAPHICS_SURFACE.
1718
1719         No new tests. This is only a build fix.
1720
1721         * platform/graphics/texmap/TextureMapperBackingStore.cpp:
1722         * platform/graphics/texmap/TextureMapperBackingStore.h:
1723         * platform/graphics/texmap/TextureMapperGL.cpp:
1724
1725 2012-06-05  Joe Thomas  <joethomas@motorola.com>
1726
1727         ASSERTION FAILED: ASSERT(!isPercentageIntrinsicSize) in RenderReplaced::computeIntrinsicRatioInformationForRenderBox
1728         https://bugs.webkit.org/show_bug.cgi?id=88197
1729
1730         Reviewed by Daniel Bates.
1731
1732         RenderSVGRoot extends RenderReplaced and it overrides the computeIntrinsicRatioInformation() 
1733         method of RenderReplaced. RenderSVGRoot::computeIntrinsicRatioInformation
1734         sets isPercentageIntrinsicSize to true while it handles width and height of percentage types.
1735         So this assertion should be fired only if intrinsicRatio is non-zero.
1736
1737         Test: svg/in-html/svg-assert-failure-percentage.html
1738
1739         * rendering/RenderReplaced.cpp:
1740         (WebCore::RenderReplaced::computeIntrinsicRatioInformationForRenderBox):
1741
1742 2012-06-05  Tony Chang  <tony@chromium.org>
1743
1744         Changing flexbox justify/alignment doesn't update their positioning
1745         https://bugs.webkit.org/show_bug.cgi?id=88366
1746
1747         Reviewed by Ojan Vafai.
1748
1749         Test: css3/flexbox/style-change.html
1750
1751         * rendering/style/RenderStyle.cpp:
1752         (WebCore::RenderStyle::diff): Since these member variables were moved
1753         out of StyleFlexibleBoxData, we have to compare them in RenderStyle::diff.
1754
1755 2012-06-05  Charles Wei  <charles.wei@torchmobile.com.cn>
1756
1757         JSC implementation of SerializedScriptValue for IndexedDB
1758         https://bugs.webkit.org/show_bug.cgi?id=88048
1759
1760         Reviewed by George Staikos.
1761
1762         No new tests. All the current indexeddb test cases apply when indexeddb works for JSC.
1763
1764         * bindings/js/SerializedScriptValue.cpp:
1765         (WebCore::CloneSerializer::serializeNumber):
1766         (CloneSerializer):
1767         (WebCore::CloneDeserializer::toWireString):
1768         (CloneDeserializer):
1769         (WebCore::SerializedScriptValue::create):
1770         (WebCore::SerializedScriptValue::toWireString):
1771         (WebCore):
1772         (WebCore::SerializedScriptValue::createFromWire):
1773         (WebCore::SerializedScriptValue::numberValue):
1774         (WebCore::SerializedScriptValue::deserialize):
1775
1776 2012-06-05  Ojan Vafai  <ojan@chromium.org>
1777
1778         Nested CSS flexbox renders incorrectly
1779         https://bugs.webkit.org/show_bug.cgi?id=87679
1780
1781         Reviewed by Julien Chaffraix.
1782
1783         If the containing block with a perpendicular writing mode has an overrideHeight,
1784         then its logical height should be based off that instead of its RenderStyle.
1785
1786         Test: css3/flexbox/perpendicular-writing-modes-inside-flex-item.html
1787
1788         * rendering/RenderBox.cpp:
1789         (WebCore::RenderBox::perpendicularContainingBlockLogicalHeight):
1790
1791 2012-06-05  Charles Wei  <charles.wei@torchmobile.com.cn>
1792
1793         Need special-case toJS(IDBAny) for IDBCursorWithValue
1794         https://bugs.webkit.org/show_bug.cgi?id=87963
1795
1796         Reviewed by George Staikos.
1797
1798         No new tests, this is for indexedDB, which is not working for JSC binding.
1799         When indexedDB working for JSC, all the indexdb test cases should apply.
1800
1801         * bindings/js/JSIDBAnyCustom.cpp:
1802         (WebCore::toJS):
1803
1804 2012-06-05  Michal Mocny  <mmocny@google.com>
1805
1806         [chromium] Set default memory allocation limit bytes when GL_CHROMIUM_gpu_memory_manager is not supported by graphics context.
1807         https://bugs.webkit.org/show_bug.cgi?id=87996
1808
1809         Reviewed by James Robinson.
1810
1811         Soon we hope to have renderers not manage there own memory allocation limits, and rely exclusively on the
1812         allocation given by GpuMemoryManager.  However, when the graphics context does not support the
1813         GL_CHROMIUM_gpu_memory_manager extension, such as the one used by DumpRenderTree, we must default the
1814         memory allocation limit to some non-0 value.
1815
1816         * platform/graphics/chromium/LayerRendererChromium.cpp:
1817         (WebCore::LayerRendererChromium::initialize):
1818         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
1819         (WebCore::CCSingleThreadProxy::postSetContentsMemoryAllocationLimitBytesToMainThreadOnImplThread):
1820         * platform/graphics/chromium/cc/CCSingleThreadProxy.h:
1821         (WebCore):
1822         (DebugScopedSetMainThreadFromEither):
1823         (WebCore::DebugScopedSetMainThreadFromEither::DebugScopedSetMainThreadFromEither):
1824         (WebCore::DebugScopedSetMainThreadFromEither::~DebugScopedSetMainThreadFromEither):
1825
1826 2012-06-05  Roland Takacs  <takacs.roland@stud.u-szeged.hu>
1827
1828         [Qt] Use GraphicsContext3DOpenGLES.cpp when using OpenGL ES
1829         https://bugs.webkit.org/show_bug.cgi?id=78720
1830
1831         Reviewed by Noam Rosenthal.
1832
1833         Functions are removed from GraphicsContext3DQt that already implemented
1834         in GraphicsContext3DCommon. Macros that not supported at GLES have been
1835         changed to their appropriate pair that found in GraphicsContext3D
1836         (e.g. GL_FRAMEBUFFER_EXT to GraphicsContext3D::FRAMEBUFFER).
1837         It was needed because OpenGLES does not support these macros.
1838         Extensions3DQt is removed beceause it has never been used.
1839         Some functions have been moved fron GraphicsContext3DCommon to *OpenGL
1840         and *OpenGLES to provide specialization.
1841         The "m_depthStencilBuffer" member is added to Qt port because it uses
1842         "m_depthStencilBuffer" like the other platforms.
1843
1844         * Target.pri:
1845         * platform/graphics/GraphicsContext3D.h:
1846         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
1847         (WebCore::GraphicsContext3D::depthRange):
1848         (WebCore):
1849         (WebCore::GraphicsContext3D::clearDepth):
1850         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
1851         (WebCore::GraphicsContext3D::prepareTexture):
1852         (WebCore::GraphicsContext3D::readRenderingResults):
1853         (WebCore::GraphicsContext3D::reshape):
1854         (WebCore::GraphicsContext3D::copyTexImage2D):
1855         (WebCore::GraphicsContext3D::copyTexSubImage2D):
1856         (WebCore::GraphicsContext3D::readPixels):
1857         * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
1858         (WebCore::GraphicsContext3D::reshapeFBOs):
1859         (WebCore::GraphicsContext3D::depthRange):
1860         (WebCore):
1861         (WebCore::GraphicsContext3D::clearDepth):
1862         * platform/graphics/qt/GraphicsContext3DQt.cpp:
1863         (WebCore::GraphicsContext3D::isGLES2Compliant):
1864         (WebCore::GraphicsContext3DPrivate::blitMultisampleFramebuffer):
1865         (WebCore::GraphicsContext3D::GraphicsContext3D):
1866         (WebCore::GraphicsContext3D::~GraphicsContext3D):
1867         (WebCore):
1868
1869 2012-06-05  Vitaly Buka  <vitalybuka@chromium.org>
1870
1871         Special layout handler should be done on top frame being printed.
1872         https://bugs.webkit.org/show_bug.cgi?id=88201
1873
1874         Reviewed by Brady Eidson.
1875
1876         No new tests. Root case is already covered by tests.
1877         Case described in the issue can be reproduced only by direct call
1878         to Frame::setPrinting of subframe. Probably it's not possible with
1879         layout tests.
1880
1881         * page/Frame.cpp:
1882         (WebCore::Frame::setPrinting):
1883         Use shouldUsePrintingLayout to choose proper version of forceLayout().
1884         (WebCore::Frame::shouldUsePrintingLayout):
1885         Checks if current frame is the top frame being printed.
1886         * rendering/RenderView.cpp:
1887         (WebCore::RenderView::shouldUsePrintingLayout): Forward to Frame.
1888
1889 2012-06-05  Max Feil  <mfeil@rim.com>
1890
1891         [BlackBerry] Conditionally enlarge HTML5 video controls in fullscreen mode
1892         https://bugs.webkit.org/show_bug.cgi?id=87551
1893
1894         Reviewed by Antonio Gomes.
1895
1896         Changes to make media controls larger in fullscreen mode. The
1897         BlackBerry media controls used to be sized by a combination
1898         of CSS styles specified in mediaControlsBlackBerry.css and
1899         hard coded constants in RenderThemeBlackBerry.cpp. This patch
1900         moves all the dimensional sizes to a common location, i.e.
1901         RenderThemeBlackBerry.cpp. Having all the logic in C++ code allows
1902         more complex decision making for when and how much to enlarge the
1903         media controls. Currently the controls are enlarged by a factor
1904         of 2 if the document is in fullscreen mode, the video element
1905         is the current fullscreen element, and the deviceScaleFactor of
1906         the page is less than 2.0. This avoids overly large controls
1907         on pages which are already at least doubling the size of the
1908         controls via viewport meta tag device-width settings. In other
1909         words, if the CSS pixels are already enlarged compared to device
1910         pixels by a factor of at least 2 in length and width.
1911
1912         In order to accomplish this, I had to add a new Element* parameter
1913         to RenderTheme::adjustSliderThumbSize(). This is needed so
1914         that fullscreen mode can be checked and the deviceScaleFactor
1915         retrieved. I feel that this does not have a big impact on the
1916         code and the other ports, for which I will simply be adding the
1917         additional parameter in their platform code.
1918
1919         Tests:
1920         video-controls-enlarged-fullscreen-meta.html
1921         video-controls-enlarged-fullscreen-nometa.html
1922
1923         * css/mediaControlsBlackBerry.css:
1924         (audio::-webkit-media-controls-panel, video::-webkit-media-controls-panel):
1925         (audio::-webkit-media-controls-play-button, video::-webkit-media-controls-play-button):
1926         (audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
1927         (audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
1928         (audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display):
1929         (audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline):
1930         (audio::-webkit-media-controls-fullscreen-button, video::-webkit-media-controls-fullscreen-button):
1931         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
1932         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
1933         (audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider):
1934         * html/shadow/SliderThumbElement.cpp:
1935         (WebCore::RenderSliderThumb::updateAppearance):
1936         * platform/blackberry/RenderThemeBlackBerry.cpp:
1937         (WebCore):
1938         (WebCore::determineRenderSlider):
1939         (WebCore::determineFullScreenMultiplier):
1940         (WebCore::RenderThemeBlackBerry::adjustSliderThumbSize):
1941         (WebCore::RenderThemeBlackBerry::adjustMediaControlStyle):
1942         (WebCore::RenderThemeBlackBerry::adjustSliderTrackStyle):
1943         (WebCore::RenderThemeBlackBerry::paintMediaSliderTrack):
1944         (WebCore::RenderThemeBlackBerry::paintMediaSliderThumb):
1945         * platform/blackberry/RenderThemeBlackBerry.h:
1946         (RenderThemeBlackBerry):
1947         * platform/efl/RenderThemeEfl.cpp:
1948         (WebCore::RenderThemeEfl::adjustSliderThumbSize):
1949         * platform/efl/RenderThemeEfl.h:
1950         (RenderThemeEfl):
1951         * platform/gtk/RenderThemeGtk.h:
1952         * platform/gtk/RenderThemeGtk2.cpp:
1953         (WebCore::RenderThemeGtk::adjustSliderThumbSize):
1954         * platform/gtk/RenderThemeGtk3.cpp:
1955         (WebCore::RenderThemeGtk::adjustSliderThumbSize):
1956         * platform/qt/RenderThemeQt.cpp:
1957         (WebCore::RenderThemeQt::adjustSliderThumbSize):
1958         * platform/qt/RenderThemeQt.h:
1959         (RenderThemeQt):
1960         * platform/qt/RenderThemeQtMobile.cpp:
1961         (WebCore::RenderThemeQtMobile::adjustSliderThumbSize):
1962         * platform/qt/RenderThemeQtMobile.h:
1963         (RenderThemeQtMobile):
1964         * rendering/RenderThemeChromiumLinux.cpp:
1965         (WebCore::RenderThemeChromiumLinux::adjustSliderThumbSize):
1966         * rendering/RenderThemeChromiumLinux.h:
1967         (RenderThemeChromiumLinux):
1968         * rendering/RenderThemeChromiumSkia.cpp:
1969         (WebCore::RenderThemeChromiumSkia::adjustSliderThumbSize):
1970         * rendering/RenderThemeChromiumSkia.h:
1971         (RenderThemeChromiumSkia):
1972         * rendering/RenderThemeChromiumWin.cpp:
1973         (WebCore):
1974         (WebCore::RenderThemeChromiumWin::adjustSliderThumbSize):
1975         * rendering/RenderThemeChromiumWin.h:
1976         (RenderThemeChromiumWin):
1977         * rendering/RenderThemeMac.h:
1978         (RenderThemeMac):
1979         * rendering/RenderThemeSafari.cpp:
1980         (WebCore::RenderThemeSafari::adjustSliderThumbSize):
1981         * rendering/RenderThemeSafari.h:
1982         (RenderThemeSafari):
1983         * rendering/RenderThemeWin.cpp:
1984         (WebCore::RenderThemeWin::adjustSliderThumbSize):
1985         * rendering/RenderThemeWin.h:
1986         (RenderThemeWin):
1987         * rendering/RenderThemeWinCE.cpp:
1988         (WebCore::RenderThemeWinCE::adjustSliderThumbSize):
1989         * rendering/RenderThemeWinCE.h:
1990         (RenderThemeWinCE):
1991         * rendering/RenderTheme.cpp:
1992         (WebCore::RenderTheme::adjustStyle):
1993         (WebCore::RenderTheme::adjustMediaControlStyle):
1994         (WebCore):
1995         (WebCore::RenderTheme::adjustSliderThumbStyle):
1996         (WebCore::RenderTheme::adjustSliderThumbSize):
1997         * rendering/RenderTheme.h:
1998         (RenderTheme):
1999
2000 2012-06-05  Stephanie Lewis  <slewis@apple.com>
2001
2002         https://bugs.webkit.org/show_bug.cgi?id=88370
2003         Memory sampler should trigger low memory signal
2004
2005         Reviewed by Geoff Garen.
2006
2007         No new tests. Verify by running stress test which crashes 
2008         in a few minutes without the fix.
2009
2010         Fix assumption in block code.  We could get in a state where timer_event_source
2011         had already been released before the block ran.
2012
2013         * platform/mac/MemoryPressureHandlerMac.mm:
2014         (WebCore::MemoryPressureHandler::holdOff):
2015
2016 2012-06-05  Yoshifumi Inoue  <yosin@chromium.org>
2017
2018         [Forms] Introduce InputNumber type as an alias of double for replacing it to Decimal
2019         https://bugs.webkit.org/show_bug.cgi?id=88275
2020
2021         Reviewed by Kent Tamura.
2022
2023         This patch introduced InputNumber type as alias of double to be
2024         replaced to Decimal and convertDoubleToInputNumber and 
2025         convertToInputNumberToDouble for reducing size of patch when we
2026         introduce Decimal type.
2027
2028         This patch added new vairables to use const variable to reduce
2029         copy operation when introducing Decimal type.
2030
2031         In the implementation, we use InputNumber, will be Decimal, however some methods in IDL
2032         use double. To clarify internal usage of value and external usage, thit patch renamed
2033         following functions:
2034
2035         - parseToDouble => parseNumber
2036         - setValueAsNumber => setValueAsDouble and setValueAsInputNumber
2037         - valueAsNumber => valueAsDouble
2038
2039         This patch is a part of introducing Decimal, https://bugs.webkit.org/show_bug.cgi?id=80009
2040
2041         No new tests. This patch doesn't change behavior.
2042
2043         * html/BaseDateAndTimeInputType.cpp:
2044         (WebCore::BaseDateAndTimeInputType::valueAsDate): Replaced parseToNumber() to valueAsDouble()
2045         (WebCore::BaseDateAndTimeInputType::setValueAsDate): Inserted convertDoubleToInputNumber.
2046         (WebCore::BaseDateAndTimeInputType::valueAsDouble): Use new function parseToDouble().
2047         (WebCore::BaseDateAndTimeInputType::setValueAsInputNumber): Added.
2048         (WebCore::BaseDateAndTimeInputType::defaultValueForStepUp): Changed return type to InputNumber.
2049         (WebCore::BaseDateAndTimeInputType::parseToNumber): This is replacement of parseToDouble().
2050         (WebCore::BaseDateAndTimeInputType::parseToDouble): Added for valueAsDate and valueAsDouble.
2051         (WebCore::BaseDateAndTimeInputType::serialize): Changed parameter type to InputNumber.
2052         (WebCore::BaseDateAndTimeInputType::serializeWithComponents): Replace double to InputNumber for getAllowdStep.
2053         * html/BaseDateAndTimeInputType.h:
2054         (BaseDateAndTimeInputType):
2055         * html/DateInputType.cpp:
2056         (WebCore::DateInputType::createStepRange): Replaced double to InputNumber.
2057         * html/DateInputType.h:
2058         (DateInputType):
2059         * html/DateTimeInputType.cpp:
2060         (WebCore::DateTimeInputType::defaultValueForStepUp): Changed return type to InputNumber.
2061         (WebCore::DateTimeInputType::createStepRange): Replaced double to InputNumber.
2062         * html/DateTimeInputType.h:
2063         (DateTimeInputType):
2064         * html/DateTimeLocalInputType.cpp:
2065         (WebCore::DateTimeLocalInputType::createStepRange): Replaced double to InputNumber.
2066         * html/DateTimeLocalInputType.h:
2067         (DateTimeLocalInputType):
2068         * html/HTMLInputElement.cpp:
2069         (WebCore::HTMLInputElement::getAllowedValueStep): Changed parameter type to InputNumber.
2070         (WebCore::HTMLInputElement::valueAsNumber): Use InputType::valueAsDouble.
2071         (WebCore::HTMLInputElement::setValueAsNumber): Use InputType::valueAsDouble.
2072         * html/HTMLInputElement.h:
2073         (HTMLInputElement):
2074         * html/InputType.cpp:
2075         (WebCore::InputType::valueAsDouble): Replacement of valueAsNumber.
2076         (WebCore::InputType::setValueAsDouble): Replacement of valueAsNumber.
2077         (WebCore::InputType::setValueAsInputNumber): Replacement of valueAsNumber.
2078         (WebCore::InputType::rangeUnderflow): Replaced double to InputNumber.
2079         (WebCore::InputType::rangeOverflow): Replaced double to InputNumber.
2080         (WebCore::InputType::defaultValueForStepUp): Changed return type to InputNumber.
2081         (WebCore::InputType::isInRange): Replaced double to InputNumber.
2082         (WebCore::InputType::isOutOfRange): Replaced double to InputNumber.
2083         (WebCore::InputType::stepMismatch): Replaced double to InputNumber.
2084         (WebCore::InputType::validationMessage): Replaced double to InputNumber.
2085         (WebCore::InputType::parseToNumber): Replacement of parseToDouble.
2086         (WebCore::InputType::parseToNumberOrNaN): Added for reducing number of std::numeric_limits<double>::quiet_NaN().
2087         (WebCore::InputType::parseToNumberWithDecimalPlaces): Replaced double to InputNumber.
2088         (WebCore::InputType::serialize): Changed parameter type to InputNumber.
2089         (WebCore::InputType::applyStep): Replaced double to InputNumber.
2090         (WebCore::InputType::getAllowedValueStep): Changed parameter type to InputNumber.
2091         (WebCore::InputType::stepUpFromRenderer): Replaced double to InputNumber.
2092         * html/InputType.h:
2093         (InputType):
2094         * html/MonthInputType.cpp:
2095         (WebCore::MonthInputType::defaultValueForStepUp): Changed return type to InputNumber.
2096         (WebCore::MonthInputType::createStepRange): Replaced double to InputNumber.
2097         (WebCore::MonthInputType::parseToNumber): Replacement of parseToDouble.
2098         * html/MonthInputType.h:
2099         (MonthInputType):
2100         * html/NumberInputType.cpp:
2101         (WebCore::NumberInputType::valueAsDouble): Replacement of valueAsNumber. Changed to use parseToDoubleForNumberType.
2102         (WebCore::NumberInputType::setValueAsDouble):  Replacement of setValueAsNumber.  Changed to use serializeForNumberType.
2103         (WebCore::NumberInputType::setValueAsInputNumber): Replacement of setValueAsNumber.
2104         (WebCore::NumberInputType::createStepRange): Replaced double to InputNumber.
2105         (WebCore::NumberInputType::parseToNumber): Replacement of parseToDouble.
2106         (WebCore::NumberInputType::parseToNumberWithDecimalPlaces): Replaced double to InputNumber.
2107         (WebCore::NumberInputType::serialize):
2108         * html/NumberInputType.h:
2109         (NumberInputType):
2110         * html/RangeInputType.cpp:
2111         (WebCore::ensureMaximum): Replaced double to InputNumber.
2112         (WebCore::RangeInputType::valueAsDouble): Replacement of valueAsNumber.
2113         (WebCore::RangeInputType::setValueAsInputNumber):  Replacement of setValueAsNumber.
2114         (WebCore::RangeInputType::createStepRange): Replaced double to InputNumber.
2115         (WebCore::RangeInputType::handleKeydownEvent): Replaced double to InputNumber.
2116         (WebCore::RangeInputType::parseToNumber): Replacement of parseToDouble.
2117         (WebCore::RangeInputType::serialize): Changed parameter type to InputNumber.
2118         (WebCore::RangeInputType::sanitizeValue): Replaced double to InputNumber.
2119         * html/RangeInputType.h:
2120         (RangeInputType):
2121         * html/StepRange.cpp:
2122         (WebCore::StepRange::StepRange): Replaced double to InputNumber.
2123         (WebCore::StepRange::acceptableError): Replaced double to InputNumber.
2124         (WebCore::StepRange::alignValueForStep): Replaced double to InputNumber.
2125         (WebCore):
2126         (WebCore::StepRange::clampValue): Replaced double to InputNumber.
2127         (WebCore::StepRange::stepMismatch): Replaced double to InputNumber.
2128         * html/StepRange.h:
2129         (WebCore::convertDoubleToInputNumber): Added.
2130         (WebCore::convertInputNumberToDouble): Added.
2131         (WebCore::StepRange::NumberWithDecimalPlaces::NumberWithDecimalPlaces): Replaced double to InputNumber.
2132         (WebCore::StepRange::StepDescription::defaultValue): Replaced double to InputNumber.
2133         (StepRange):
2134         (WebCore::StepRange::maximum): Replaced double to InputNumber.
2135         (WebCore::StepRange::minimum): Replaced double to InputNumber.
2136         (WebCore::StepRange::step): Replaced double to InputNumber.
2137         (WebCore::StepRange::stepBase): Replaced double to InputNumber.
2138         (WebCore::StepRange::defaultValue): Replaced double to InputNumber.
2139         (WebCore::StepRange::proportionFromValue): Replaced double to InputNumber.
2140         (WebCore::StepRange::valueFromProportion): Replaced double to InputNumber.
2141         * html/TimeInputType.cpp:
2142         (WebCore::TimeInputType::defaultValueForStepUp): Replaced double to InputNumber.
2143         (WebCore::TimeInputType::createStepRange): Replaced double to InputNumber.
2144         * html/TimeInputType.h:
2145         (TimeInputType):
2146         * html/WeekInputType.cpp:
2147         (WebCore::WeekInputType::createStepRange): Replaced double to InputNumber.
2148         * html/WeekInputType.h:
2149         (WeekInputType):
2150         * html/shadow/CalendarPickerElement.cpp:
2151         (WebCore::CalendarPickerElement::writeDocument): Replaced double to InputNumber.
2152         * html/shadow/SliderThumbElement.cpp:
2153         (WebCore::sliderPosition): Replaced double to InputNumber.
2154         (WebCore::RenderSliderThumb::layout): Replaced double to InputNumber.
2155         (WebCore::SliderThumbElement::setPositionFromPoint): Replaced double to InputNumber.
2156
2157 2012-06-05  Ryosuke Niwa  <rniwa@webkit.org>
2158
2159         Build fix after r119527.
2160
2161         * dom/ViewportArguments.cpp:
2162         (WebCore::computeViewportAttributes):
2163
2164 2012-06-05  Martin Robinson  <mrobinson@igalia.com>
2165
2166         [Cairo] [OpenGL] Enable GL_OES_standard_derivatives
2167         https://bugs.webkit.org/show_bug.cgi?id=87583
2168
2169         Reviewed by Alejandro G. Castro.
2170
2171         No new tests. This is covered by oes-standard-derivatives.html
2172         in the Khronos WebGL conformance tests, which may one day be part
2173         of the WebKit test suite.
2174
2175         Activate the GL_OES_standard_derivatives on Cairo along with
2176         Qt and Mac.
2177
2178         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
2179         (WebCore::Extensions3DOpenGL::ensureEnabled):
2180         (WebCore::Extensions3DOpenGL::isEnabled):
2181
2182 2012-06-05  Simon Fraser  <simon.fraser@apple.com>
2183
2184         Avoid creating compositing layers for preserve-3d without transformed descendants
2185         https://bugs.webkit.org/show_bug.cgi?id=88115
2186
2187         Reviewed by Antti Koivisto.
2188         
2189         Avoid creating compositing layers, and therefore using excess backing store,
2190         for elements that have -webkit-transform-style: preserve-3d, but no 3D-transformed
2191         descendants that would be affected by that preserve-3d.
2192         
2193         Test: compositing/layer-creation/no-compositing-for-preserve-3d.html
2194
2195         * rendering/RenderLayer.h: Replace the "mustOverlap" flag with a enum
2196         that describes the different reasons for indirect compositing, so that
2197         we can use that information to decide whether to allocate backing store.
2198         (WebCore::RenderLayer::setIndirectCompositingReason):
2199         (WebCore::RenderLayer::indirectCompositingReason):
2200         (WebCore::RenderLayer::mustCompositeForIndirectReasons):
2201         * rendering/RenderLayer.cpp:
2202         (WebCore::RenderLayer::RenderLayer): Initialize m_indirectCompositingReason
2203
2204         * rendering/RenderLayerCompositor.h: New out param for computeCompositingRequirements()
2205         that is uses to indicate that a 3d-transformed descendant has been encountered.
2206         Rename requiresCompositingWhenDescendantsAreCompositing() to requiresCompositingForIndirectReason(),
2207         and return the reason as an out param.
2208         
2209         * rendering/RenderLayerCompositor.cpp:
2210         (WebCore::RenderLayerCompositor::updateCompositingLayers): Pass in the saw3DTransform
2211         param to computeCompositingRequirements().
2212         (WebCore::RenderLayerCompositor::computeCompositingRequirements): Return a flag
2213         from computeCompositingRequirements() that is set to true if we've seen descendants
2214         that have 3d transforms. This is later used to decide whether to composite for
2215         perspective or preserve-3d.
2216         Change the "mustOverlapCompositedLayers" code to use the new "indirect compositing"
2217         enum flags.
2218         After enumerating children, call requiresCompositingForIndirectReason() and 
2219         record the reason in the layer.
2220         (WebCore::RenderLayerCompositor::needsToBeComposited): Use mustCompositeForIndirectReasons() now.
2221         (WebCore::RenderLayerCompositor::requiresOwnBackingStore): Consult the indirect compositing
2222         reason rather than just looking for the overlap flag.
2223         (WebCore::RenderLayerCompositor::reasonForCompositing): Now that we have more information
2224         about indirect compositing reasons, the logging can be more detailed.
2225         (WebCore::RenderLayerCompositor::requiresCompositingForTransform): This now only looks
2226         for 3d transforms. We now treat perspective and perserve-3d as "indirect" reasons, because
2227         whether they composite depends on descendants having non-affine transforms.
2228         (WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason): Includes the logic
2229         previously in requiresCompositingWhenDescendantsAreCompositing(), and now determines
2230         whether to composite for preserve-3d and perspective, based on whether we have transformed descendants.
2231
2232 2012-06-05  Levi Weintraub  <leviw@chromium.org>
2233
2234         Block selection gaps painted not properly pixel snapped
2235         https://bugs.webkit.org/show_bug.cgi?id=88000
2236
2237         Reviewed by Ryosuke Niwa.
2238
2239         Fixes for selection painting in both inline line heights and block gaps. We were unintentionally
2240         flooring inline and block offsets in RenderBlock, but actually need to intentionally floor the
2241         logical left and right values in logical(Left|Right)SelectionGap to properly align our block
2242         selection gaps. This is to properly mirror the behavior in pixelSnappedLogicalRightOffsetForLine.
2243
2244         We were also unintentionally upcasting LayoutUnits to floats in InlineTextBox's selection painting
2245         routine. Now we're properly rounding.
2246
2247         Test: fast/sub-pixel/selection/selection-gaps-at-fractional-offsets.html
2248
2249         * rendering/InlineTextBox.cpp:
2250         (WebCore::InlineTextBox::paintSelection): Move paint values to integers and do proper rounding.
2251         * rendering/RenderBlock.cpp:
2252         (WebCore::blockDirectionOffset): Fix incorrect flooring in return value.
2253         (WebCore::inlineDirectionOffset): Ditto.
2254         (WebCore): Removing previous attempt to properly mirror inline box selection pixel alignment. This
2255         implementation rounded the final x value instead of properly rounding our block offset then flooring
2256         the offset that corresponds to the behavior in InlineTextBox. It also didn't properly pixel snap
2257         the y offset and height.
2258         (WebCore::RenderBlock::blockSelectionGap): Properly pixel snapping the gap rect before painting.
2259         (WebCore::RenderBlock::logicalLeftSelectionGap): Correctly match InlineTextBox's selection pixel
2260         alignment by flooring the logicalLeft and pixel snapping the subsequent rect. We do this in order
2261         to maintain proper render tree pixel snapping while simultaneously mirroring the flooring in the
2262         inline direction that occurs in InlineTextBox.cpp's alignSelectionRectToDevicePixels method.
2263         (WebCore::RenderBlock::logicalRightSelectionGap): Ditto with the right.
2264
2265 2012-06-05  Adam Barth  <abarth@webkit.org>
2266
2267         Remove support for target-densitydpi in the viewport meta tag
2268         https://bugs.webkit.org/show_bug.cgi?id=88047
2269
2270         Reviewed by Kenneth Rohde Christiansen.
2271
2272         The target-densitydpi parameter was originally implemented on Android,
2273         but it does not appear to be widely used and introduces significant
2274         implementation complexity because it forces us to track three scale
2275         factors (defaultDeviceScaleFactor, deviceScaleFactor, and
2276         pageScaleFactor) rather than just two (deviceScaleFactor and
2277         pageScaleFactor).
2278
2279         There don't appear to be many web sites that use target-densitydpi
2280         because it is not supported on iOS.  There are also concerns from the
2281         standards community about the design of the feature.  It seems our best
2282         course of action is to remove target-densitydpi and address these use
2283         cases via other mechanisms, such as responsive images and device units
2284         in CSS because those approaches are likely to be implemented broadly.
2285
2286         * dom/ViewportArguments.cpp:
2287         (WebCore::computeViewportAttributes):
2288         (WebCore):
2289         (WebCore::setViewportFeature):
2290         (WebCore::viewportErrorMessageTemplate):
2291         (WebCore::viewportErrorMessageLevel):
2292         * dom/ViewportArguments.h:
2293         (WebCore::ViewportArguments::ViewportArguments):
2294         (ViewportArguments):
2295         (WebCore::ViewportArguments::operator==):
2296
2297 2012-06-05  Erik Arvidsson  <arv@chromium.org>
2298
2299         [V8] Improve variable resolution order on window
2300         https://bugs.webkit.org/show_bug.cgi?id=84247
2301
2302         Reviewed by Ojan Vafai.
2303
2304         This changes the V8 flag to turn on es52_globals and updates the layout tests to reflect the fixed behavior.
2305
2306         Test: fast/dom/Window/window-property-shadowing-onclick.html
2307
2308         * bindings/v8/V8DOMWindowShell.cpp:
2309         (WebCore::V8DOMWindowShell::initContextIfNeeded): Set the flag as we initialize V8.
2310         * bindings/v8/WorkerContextExecutionProxy.cpp:
2311         (WebCore::WorkerContextExecutionProxy::initIsolate): Ditto.
2312
2313 2012-06-05  Ojan Vafai  <ojan@chromium.org>
2314
2315         Delete dead code from RenderBox::computeLogicalWidthInRegion
2316         https://bugs.webkit.org/show_bug.cgi?id=88353
2317
2318         Reviewed by Tony Chang.
2319
2320         No new tests obviously since this is dead code.
2321
2322         * rendering/RenderBox.cpp:
2323         (WebCore::RenderBox::computeLogicalWidthInRegion):
2324
2325 2012-06-05  Greg Billock  <gbillock@google.com>
2326
2327         New constructor for WebIntent to be used for delivery
2328         https://bugs.webkit.org/show_bug.cgi?id=87143
2329
2330         Reviewed by Darin Fisher.
2331
2332         * Modules/intents/Intent.cpp:
2333         (WebCore::Intent::setExtras):
2334         (WebCore):
2335         * Modules/intents/Intent.h:
2336         (Intent):
2337
2338 2012-06-01  Ojan Vafai  <ojan@chromium.org>
2339
2340         Change overrideSizes to be content-box instead of border-box
2341         https://bugs.webkit.org/show_bug.cgi?id=88116
2342
2343         Reviewed by Tony Chang.
2344
2345         Previously, the code used border-box everywhere except for one place
2346         where it used content-box when setting the override size. Conversely,
2347         it subtracted the borderAndPaddingSize everywhere it grabbed the override
2348         size except for one.
2349
2350         Instead, make the override size override the content-box size.
2351         Converging on using the border-box size would be tricky given RenderTableCell's
2352         tricky management of intrinsic padding.
2353
2354         There is no behavior change except in RenderBox::availableLogicalHeightUsing,
2355         which fixes a table test.
2356
2357         * rendering/RenderBox.cpp:
2358         (WebCore::RenderBox::setOverrideLogicalContentHeight):
2359         (WebCore::RenderBox::setOverrideLogicalContentWidth):
2360         (WebCore::RenderBox::overrideLogicalContentWidth):
2361         (WebCore::RenderBox::overrideLogicalContentHeight):
2362         (WebCore::RenderBox::computeLogicalWidthInRegion):
2363         (WebCore::RenderBox::computeLogicalHeight):
2364         (WebCore::RenderBox::computePercentageLogicalHeight):
2365         (WebCore::RenderBox::availableLogicalHeightUsing):
2366         We were incorrectly subtracting the borderAndPaddingLogicalWidth instead
2367         of the borderAndPaddingLogicalHeight.
2368
2369         * rendering/RenderBox.h:
2370         (RenderBox):
2371         * rendering/RenderDeprecatedFlexibleBox.cpp:
2372         (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox):
2373         (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):
2374         (WebCore::RenderDeprecatedFlexibleBox::applyLineClamp):
2375         (WebCore::RenderDeprecatedFlexibleBox::allowedChildFlex):
2376         * rendering/RenderFlexibleBox.cpp:
2377         (WebCore::RenderFlexibleBox::computeAvailableFreeSpace):
2378         (WebCore::RenderFlexibleBox::setLogicalOverrideSize):
2379         (WebCore::RenderFlexibleBox::applyStretchAlignmentToChild):
2380         * rendering/RenderTableCell.cpp:
2381         (WebCore::RenderTableCell::setOverrideHeightFromRowHeight):
2382
2383 2012-06-05  Andy Estes  <aestes@apple.com>
2384
2385         REGRESSION (r118197): PluginStrategy should be used even if ENABLE(NETSCAPE_PLUGIN_API) is false
2386         https://bugs.webkit.org/show_bug.cgi?id=88296
2387
2388         Reviewed by Dan Bernstein.
2389
2390         refresh() and initPlugins() should call into PluginStrategy even if
2391         ENABLE(NETSCAPE_PLUGIN_API) is false. Some ports support non-Netscape
2392         plug-ins, so PluginStrategy should be consulted even if Netscape
2393         plug-ins specifically are disabled.
2394
2395         Ports that support platform strategies but not Netscape plug-ins should
2396         handle this inside their PluginStrategy rather than modifying generic
2397         plug-in code.
2398
2399         * plugins/PluginData.cpp:
2400         (WebCore::PluginData::refresh):
2401         (WebCore::PluginData::initPlugins):
2402
2403 2012-06-05  Douglas Stockwell  <dstockwell@chromium.org>
2404
2405         Crash when modifying fixed-position elements in a detached frame
2406         https://bugs.webkit.org/show_bug.cgi?id=88288
2407
2408         Reviewed by James Robinson.
2409
2410         Test: fast/block/positioning/fixed-position-detached-frame.html
2411
2412         * css/StyleResolver.cpp:
2413         (WebCore::StyleResolver::collectMatchingRulesForList):
2414
2415 2012-06-05  Andrey Kosyakov  <caseq@chromium.org>
2416
2417         Web Inspector: render timeline paint category dark green
2418         https://bugs.webkit.org/show_bug.cgi?id=88333
2419
2420         Reviewed by Pavel Feldman.
2421
2422         - Added a new, dark-green color for timeline events.
2423
2424         * WebCore.gypi: Added timelineBarDarkGreen.png
2425         * inspector/front-end/Images/timelineBarDarkGreen.png: Added.
2426         * inspector/front-end/Images/timelineCheckmarks.png: Added a dark-green checkbox.
2427         * inspector/front-end/Images/timelineDots.png: Added a dark-green dot.
2428         * inspector/front-end/TimelinePresentationModel.js:
2429         (WebInspector.TimelinePresentationModel.categories):
2430         * inspector/front-end/WebKit.qrc: Added timelineBarDarkGreen.png.
2431         * inspector/front-end/timelinePanel.css:
2432         (.timeline-category-statusbar-item.timeline-category-painting .timeline-category-checkbox):
2433         (.timeline-category-painting .timeline-graph-bar):
2434         (.popover .timeline-painting):
2435         (.timeline-category-painting .timeline-tree-icon):
2436
2437 2012-06-05  Alexei Filippov  <alexeif@chromium.org>
2438
2439         Web Inspector: serialize edge counts instead of indexes in heap snapshot
2440         https://bugs.webkit.org/show_bug.cgi?id=88324
2441
2442         The serialized node structure currently holds an index
2443         of its first containment edge in the edges array.
2444         The index can be quite big (up to 7 digits for large snapshots).
2445         The patch changes the serialization format to pass
2446         node containment edge count instead. For most nodes the count
2447         is just a single digit number.
2448         This reduces serialized snapshot size and therefore its transfer time.
2449
2450         Reviewed by Yury Semikhatsky.
2451
2452         * inspector/front-end/HeapSnapshot.js:
2453         (WebInspector.HeapSnapshotNode.prototype._edgeIndexesStart):
2454         (WebInspector.HeapSnapshotNode.prototype._edgeIndexesEnd):
2455         (WebInspector.HeapSnapshotNode.prototype._ordinal):
2456         (WebInspector.HeapSnapshotNodeIterator):
2457         (WebInspector.HeapSnapshot.prototype._init):
2458         (WebInspector.HeapSnapshot.prototype._buildEdgeIndexes):
2459         (WebInspector.HeapSnapshot.prototype._buildRetainers):
2460         (WebInspector.HeapSnapshot.prototype._bfs):
2461         (WebInspector.HeapSnapshot.prototype._buildAggregates):
2462         (WebInspector.HeapSnapshot.prototype._buildPostOrderIndex):
2463         (WebInspector.HeapSnapshot.prototype._buildDominatorTree):
2464         (WebInspector.HeapSnapshot.prototype._markPageOwnedNodes):
2465         (WebInspector.HeapSnapshot.prototype._markQueriableHeapObjects):
2466
2467 2012-06-05  Arpita Bahuguna  <arpitabahuguna@gmail.com>
2468
2469         CSS 2.1 failure: border-conflict-element-021a
2470         https://bugs.webkit.org/show_bug.cgi?id=86885
2471
2472         Reviewed by Julien Chaffraix.
2473
2474         When two adjacent table row groups (thead, tbody, tfoot) have the same border-width
2475         and the same border-style in a 'border-collapse: collapse' table the color of the border
2476         from the top-most table row wins.
2477
2478         Tests: fast/table/border-collapsing/adjacent-row-groups-multi.html
2479                fast/table/border-collapsing/adjacent-row-groups.html
2480
2481         * rendering/RenderTable.cpp:
2482         (WebCore::RenderTable::paintObject):
2483         Currently each row group is sent for paint from top (firstChild) to bottom thereby causing
2484         the borders of the bottom-most row group (which is painted last) to overlap over the
2485         previous row-group. This breaks the precedence for collapsed borders between adjacent cells.
2486
2487         This fix thus reverses the order in which the row-groups/sections are passed for painting.
2488         Additional change has been done to iterate over the RenderTableSections directly.
2489
2490         (WebCore):
2491         (WebCore::RenderTable::bottomSection):
2492         * rendering/RenderTable.h:
2493         New function has been added to obtain the last section of the table.
2494
2495         (RenderTable):
2496         * rendering/RenderTableSection.h:
2497         (RenderTableSection):
2498         RenderTableSection's paint() method has now been made public so as to make it accessible
2499         from RenderTable.
2500
2501 2012-06-05  Csaba Osztrogonác  <ossy@webkit.org>
2502
2503         [Qt][Win] Fix IDL dependency generation
2504         https://bugs.webkit.org/show_bug.cgi?id=88304
2505
2506         Reviewed by Tor Arne Vestbø.
2507
2508         * DerivedSources.pri:
2509
2510 2012-06-05  Sheriff Bot  <webkit.review.bot@gmail.com>
2511
2512         Unreviewed, rolling out r119467, r119471, and r119476.
2513         http://trac.webkit.org/changeset/119467
2514         http://trac.webkit.org/changeset/119471
2515         http://trac.webkit.org/changeset/119476
2516         https://bugs.webkit.org/show_bug.cgi?id=88332
2517
2518         it broke chromium-mac static initializers test.\ (Requested by
2519         loislo on #webkit).
2520
2521         * WebCore.gyp/WebCore.gyp:
2522         * WebCore.gypi:
2523         * platform/graphics/FontPlatformData.h:
2524         (FontPlatformData):
2525         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
2526         (WebCore::FontPlatformData::platformDataInit):
2527         (WebCore::FontPlatformData::platformDataAssign):
2528         * platform/graphics/harfbuzz/ng/HarfBuzzFace.cpp: Removed.
2529         * platform/graphics/harfbuzz/ng/HarfBuzzFace.h: Removed.
2530         * platform/graphics/harfbuzz/ng/HarfBuzzFaceCoreText.cpp: Removed.
2531         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp: Removed.
2532         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.h: Removed.
2533         * platform/graphics/mac/FontComplexTextMac.cpp:
2534         (WebCore::Font::selectionRectForComplexText):
2535         (WebCore::Font::drawComplexText):
2536         (WebCore::Font::floatWidthForComplexText):
2537         (WebCore::Font::offsetForPositionForComplexText):
2538
2539 2012-06-05  Alexander Pavlov  <apavlov@chromium.org>
2540
2541         Web Inspector: SHIFT key as helper to color adjustment in color picker
2542         https://bugs.webkit.org/show_bug.cgi?id=88319
2543
2544         Reviewed by Pavel Feldman.
2545
2546         With Shift depressed, the dragger in the color picker will snap to the horizontal
2547         or vertical axis while dragging, depending on which axis offset is greater.
2548
2549         * inspector/front-end/Spectrum.js:
2550         (WebInspector.Spectrum.colorDragStart):
2551         (WebInspector.Spectrum.colorDrag):
2552         (WebInspector.Spectrum.draggable.move):
2553         (WebInspector.Spectrum.draggable.start):
2554
2555 2012-06-05  Andrey Kosyakov  <caseq@chromium.org>
2556
2557         Web Inspector: aggregate all events before first frame into a fake frame
2558         https://bugs.webkit.org/show_bug.cgi?id=88229
2559
2560         - in Timeline's frame mode, start aggregating events by frame even before we get first frame marker.
2561
2562         * inspector/front-end/TimelineFrameController.js:
2563         (WebInspector.TimelineFrameController.prototype._addRecord):
2564         (WebInspector.TimelineFrameController.prototype._flushFrame):
2565         (WebInspector.TimelineFrameController.prototype._createFrame):
2566
2567 2012-06-05  Charles Wei  <charles.wei@torchmobile.com.cn>
2568
2569         JSC:need to implement Dictionary::getWithUndefinedOrNullCheck for IDB
2570         https://bugs.webkit.org/show_bug.cgi?id=88283
2571
2572         Reviewed by Kentaro Hara.
2573
2574         No new tests, idb not working for JSC yet.
2575
2576         * bindings/js/Dictionary.cpp:
2577         (WebCore::Dictionary::getWithUndefinedOrNullCheck):
2578         * bindings/js/Dictionary.h:
2579         (Dictionary):
2580         * bindings/js/JSDictionary.cpp:
2581         (WebCore::JSDictionary::getWithUndefinedOrNullCheck):
2582         (WebCore):
2583         * bindings/js/JSDictionary.h:
2584         (JSDictionary):
2585
2586 2012-06-05  Dongwoo Im  <dw.im@samsung.com>
2587
2588         Add 'isProtocolHandlerRegistered' and 'unregisterProtocolHandler'.
2589         https://bugs.webkit.org/show_bug.cgi?id=73176
2590
2591         Reviewed by Adam Barth.
2592
2593         Two more APIs are added in Custom Scheme Handler specification.
2594         http://dev.w3.org/html5/spec/Overview.html#custom-handlers
2595         One is 'isProtocolHandlerRegistered' to query whether the specific URL
2596         is registered or not.
2597         The other is 'unregisterProtocolHandler' to remove the registered URL.
2598
2599         Test: fast/dom/unregister-protocol-handler.html
2600
2601         * Configurations/FeatureDefines.xcconfig: Add a macro 'ENABLE_CUSTOM_SCHEME_HANDLER'.
2602         * loader/EmptyClients.h: Add prototypes.
2603         (EmptyChromeClient):
2604         (WebCore::EmptyChromeClient::isProtocolHandlerRegistered):
2605         (WebCore::EmptyChromeClient::unregisterProtocolHandler):
2606         * page/ChromeClient.h:
2607         (ChromeClient):
2608         * page/NavigatorRegisterProtocolHandler.cpp:
2609         (WebCore):
2610         (WebCore::customHandlersStateString):
2611         (WebCore::NavigatorRegisterProtocolHandler::isProtocolHandlerRegistered): Query if the handler is registered.
2612         (WebCore::NavigatorRegisterProtocolHandler::unregisterProtocolHandler): Unregister the registered handler.
2613         * page/NavigatorRegisterProtocolHandler.h:
2614         (NavigatorRegisterProtocolHandler):
2615         * page/NavigatorRegisterProtocolHandler.idl:
2616
2617 2012-06-04  Kinuko Yasuda  <kinuko@chromium.org>
2618
2619         Chromium tests: "Add support for the Blob constructor" [r115582] regressed blob layout tests
2620         https://bugs.webkit.org/show_bug.cgi?id=85174
2621
2622         Reviewed by Kentaro Hara.
2623
2624         This fixes a crash problem which could happen when the constructor is
2625         given an array which contains String-type item(s).
2626
2627         There're still some Text mismatches between v8 results and
2628         JSC results, most of them are v8 not throwing exception
2629         when it is given an object whose toString() method throws
2630         exception.  (The issue will be addresse in a separate patch.)
2631
2632         Test: fast/files/blob-constructor.html
2633
2634         * bindings/v8/custom/V8BlobCustom.cpp:
2635         (WebCore::V8Blob::constructorCallback):
2636
2637 2012-06-05  Kentaro Hara  <haraken@chromium.org>
2638
2639         Remove unnecessary constructor of SelectorQueryCache
2640         https://bugs.webkit.org/show_bug.cgi?id=87942
2641
2642         Reviewed by Ryosuke Niwa.
2643
2644         Per the comment from darin@ (https://bugs.webkit.org/show_bug.cgi?id=87942#c27),
2645         this patch removes an inline constructor that has no arguments.
2646         To have the compiler generate the constructor,
2647         this patch also removes WTF_MAKE_NONCOPYABLE().
2648
2649         No tests. No change in behavior.
2650
2651         * dom/SelectorQuery.h:
2652         (SelectorQueryCache):
2653
2654 2012-06-05  Kentaro Hara  <haraken@chromium.org>
2655
2656         Remove unused methods from SelectorQuery.h
2657         https://bugs.webkit.org/show_bug.cgi?id=88289
2658
2659         Reviewed by Antti Koivisto.
2660
2661         This patch removes SelectorDataList::size() and
2662         SelectorDataList::SelectorDataList().
2663         SelectorDataList::size() is not used by anybody.
2664         SelectorDataList::SelectorDataList() can be auto-generated
2665         by a compiler.
2666
2667         No tests. No change in behavior.
2668
2669         * dom/SelectorQuery.cpp:
2670         * dom/SelectorQuery.h:
2671         (SelectorDataList):
2672
2673 2012-06-05  Kent Tamura  <tkent@chromium.org>
2674
2675         Build fix for r119470.
2676
2677         * loader/EmptyClients.cpp: Add #include "IntentRequest.h".
2678
2679 2012-06-05  Kent Tamura  <tkent@chromium.org>
2680
2681         Remove unused function: Document::formElements
2682         https://bugs.webkit.org/show_bug.cgi?id=88272
2683
2684         Reviewed by Kentaro Hara.
2685
2686         No new tests. No behavior change.
2687
2688         * dom/Document.h:
2689         (Document): remove formElements(). It was used for radio group
2690         validation, but the current code doesn't use it any more.
2691
2692 2012-06-05  Kenichi Ishibashi  <bashi@chromium.org>
2693
2694         Unreviewed build fix on Chromium mac
2695
2696         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
2697         (WebCore::isAATFont):
2698
2699 2012-06-05  Kent Tamura  <tkent@chromium.org>
2700
2701         Move some function definitions in EmptyClients.h to EmptyClients.cpp
2702         https://bugs.webkit.org/show_bug.cgi?id=88285
2703
2704         Reviewed by Ryosuke Niwa.
2705
2706         If we have definitions of functions with RefPtr<> in EmptyClients.h like
2707
2708             virtual void runOpenPanel(Frame*, PassRefPtr<FileChooser>) { }
2709
2710         and a source file includes EmptyClient.h, the source file needs to
2711         include FileChooser.h though the source file doesn't use FileChooser
2712         class explicitly because the definition of runOpenPanel() needs to call
2713         FileChooser::deref().
2714         To avoid this, we had better move such functions to EmptyClients.cpp.
2715
2716         No new tests. No behavior changes.
2717
2718         * loader/EmptyClients.cpp: Move such functions from EmptyClients.h to
2719         here, and move EmptyPopupMenu and EmptySearchPopupMenu too because
2720         they're used only by EmptyChromeClient.
2721         (WebCore):
2722         (EmptyPopupMenu):
2723         (WebCore::EmptyPopupMenu::show):
2724         (WebCore::EmptyPopupMenu::hide):
2725         (WebCore::EmptyPopupMenu::updateFromElement):
2726         (WebCore::EmptyPopupMenu::disconnectClient):
2727         (EmptySearchPopupMenu):
2728         (WebCore::EmptySearchPopupMenu::popupMenu):
2729         (WebCore::EmptySearchPopupMenu::saveRecentSearches):
2730         (WebCore::EmptySearchPopupMenu::loadRecentSearches):
2731         (WebCore::EmptySearchPopupMenu::enabled):
2732         (WebCore::EmptyChromeClient::createPopupMenu):
2733         (WebCore::EmptyChromeClient::createSearchPopupMenu):
2734         (WebCore::EmptyChromeClient::createColorChooser):
2735         (WebCore::EmptyChromeClient::runOpenPanel):
2736         (WebCore::EmptyFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
2737         (WebCore::EmptyFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
2738         (WebCore::EmptyFrameLoaderClient::dispatchWillSendSubmitEvent):
2739         (WebCore::EmptyFrameLoaderClient::dispatchWillSubmitForm):
2740         (WebCore::EmptyFrameLoaderClient::createDocumentLoader):
2741         (WebCore::EmptyFrameLoaderClient::createFrame):
2742         (WebCore::EmptyFrameLoaderClient::createPlugin):
2743         (WebCore::EmptyFrameLoaderClient::createJavaAppletWidget):
2744         (WebCore::EmptyFrameLoaderClient::createMediaPlayerProxyPlugin):
2745         (WebCore::EmptyFrameLoaderClient::createNetworkingContext):
2746         (WebCore::EmptyFrameLoaderClient::dispatchIntent):
2747         (WebCore::EmptyTextCheckerClient::requestCheckingOfString):
2748         (WebCore::EmptyEditorClient::registerUndoStep):
2749         (WebCore::EmptyEditorClient::registerRedoStep):
2750         (WebCore::EmptyContextMenuClient::customizeMenu):
2751         * loader/EmptyClients.h: Move such function definitions to
2752         EmptyClient.cpp, and append OVERRIDE.
2753         (EmptyChromeClient):
2754         (EmptyFrameLoaderClient):
2755         (EmptyTextCheckerClient):
2756         (EmptyEditorClient):
2757         (EmptyContextMenuClient):
2758         * svg/graphics/SVGImage.cpp: Remove unnecessary #includes.
2759
2760 2012-06-05  Alexander Pavlov  <apavlov@chromium.org>
2761
2762         Web Inspector: "-webkit"-prefixed properties are considered inherited in the Computed Style pane
2763         https://bugs.webkit.org/show_bug.cgi?id=88257
2764
2765         Reviewed by Pavel Feldman.
2766
2767         Canonical names for properties should be used when checking if they are inherited (since only canonical names
2768         are put into the usedProperties set).
2769
2770         * inspector/front-end/StylesSidebarPane.js:
2771         (WebInspector.ComputedStylePropertiesSection.prototype._isPropertyInherited):
2772
2773 2012-06-05  Kenichi Ishibashi  <bashi@chromium.org>
2774
2775         [Chromium] Implement font shaping with font-feature-settings on Mac
2776         https://bugs.webkit.org/show_bug.cgi?id=69826
2777
2778         Reviewed by Tony Chang.
2779
2780         Add HarfBuzz-ng text shaper.
2781         Chromium mac port uses it as secondary text shaper to support OpenType features.
2782         HarfBuzz-ng is only used when -webkit-font-feature-settings is specified and
2783         corresponding font is not an AAT font.
2784
2785         No new tests. css3/font-feature-settings-rendering.html should pass on Chromium mac port.
2786
2787         * WebCore.gyp/WebCore.gyp: Added harfbuzz-ng dependencies.
2788         * WebCore.gypi: Added harfbuzz-ng files.
2789         * platform/graphics/FontPlatformData.h:
2790         (FontPlatformData): Added m_harfbuzzFace.
2791         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
2792         (WebCore::FontPlatformData::platformDataInit): Copy m_harfbuzzFace.
2793         (WebCore::FontPlatformData::platformDataAssign): Ditto.
2794         (WebCore):
2795         (WebCore::isAATFont):
2796         (WebCore::FontPlatformData::harfbuzzFace):
2797         * platform/graphics/harfbuzz/ng/HarfBuzzFace.cpp: Added.
2798         (WebCore):
2799         (WebCore::harfbuzzFaceCache):
2800         (WebCore::HarfBuzzFace::HarfBuzzFace):
2801         (WebCore::HarfBuzzFace::~HarfBuzzFace):
2802         * platform/graphics/harfbuzz/ng/HarfBuzzFace.h: Added.
2803         (WebCore):
2804         (HarfBuzzFace):
2805         (WebCore::HarfBuzzFace::create):
2806         * platform/graphics/harfbuzz/ng/HarfBuzzFaceCoreText.cpp: Added.
2807         (WebCore):
2808         (WebCore::floatToHarfBuzzPosition):
2809         (WebCore::getGlyph):
2810         (WebCore::getGlyphHorizontalAdvance):
2811         (WebCore::getGlyphHorizontalOrigin):
2812         (WebCore::getGlyphExtents):
2813         (WebCore::harfbuzzCoreTextGetFontFuncs):
2814         (WebCore::releaseTableData):
2815         (WebCore::harfbuzzCoreTextGetTable):
2816         (WebCore::HarfBuzzFace::createFace):
2817         (WebCore::HarfBuzzFace::createFont):
2818         (WebCore::HarfBuzzShaper::createGlyphBufferAdvance):
2819         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp: Added.
2820         (WebCore):
2821         (WebCore::harfbuzzPositionToFloat):
2822         (WebCore::HarfBuzzShaper::HarfBuzzRun::HarfBuzzRun):
2823         (WebCore::HarfBuzzShaper::HarfBuzzRun::setGlyphAndPositions):
2824         (WebCore::HarfBuzzShaper::HarfBuzzRun::characterIndexForXPosition):
2825         (WebCore::HarfBuzzShaper::HarfBuzzRun::xPositionForOffset):
2826         (WebCore::HarfBuzzShaper::HarfBuzzShaper):
2827         (WebCore::HarfBuzzShaper::~HarfBuzzShaper):
2828         (WebCore::HarfBuzzShaper::setFontFeatures):
2829         (WebCore::HarfBuzzShaper::shape):
2830         (WebCore::HarfBuzzShaper::setupHarfBuzzRun):
2831         (WebCore::HarfBuzzShaper::shapeHarfBuzzRun):
2832         (WebCore::HarfBuzzShaper::setGlyphPositionsForHarfBuzzRun):
2833         (WebCore::HarfBuzzShaper::offsetForPosition):
2834         (WebCore::HarfBuzzShaper::selectionRect):
2835         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.h: Added.
2836         (WebCore):
2837         (HarfBuzzShaper):
2838         (WebCore::HarfBuzzShaper::totalWidth):
2839         (HarfBuzzRun):
2840         (WebCore::HarfBuzzShaper::HarfBuzzRun::create):
2841         (WebCore::HarfBuzzShaper::HarfBuzzRun::setWidth):
2842         (WebCore::HarfBuzzShaper::HarfBuzzRun::numCharacters):
2843         (WebCore::HarfBuzzShaper::HarfBuzzRun::numGlyphs):
2844         (WebCore::HarfBuzzShaper::HarfBuzzRun::width):
2845         (WebCore::HarfBuzzShaper::HarfBuzzRun::rtl):
2846         * platform/graphics/mac/FontComplexTextMac.cpp:
2847         (WebCore):
2848         (WebCore::preferHarfBuzz): Added.
2849         (WebCore::Font::selectionRectForComplexText): Use HarfBuzzShaper if font-feature-settings exists.
2850         (WebCore::Font::drawComplexText): Ditto.
2851         (WebCore::Font::floatWidthForComplexText): Ditto.
2852         (WebCore::Font::offsetForPositionForComplexText): Ditto.
2853
2854 2012-06-05  Li Yin  <li.yin@intel.com>
2855
2856         IETC: FileList.item(-1) should return null instead of raising
2857         https://bugs.webkit.org/show_bug.cgi?id=77899
2858
2859         Reviewed by Kentaro Hara.
2860
2861         IETC: http://samples.msdn.microsoft.com/ietestcenter/fileapi/filelist.htm
2862         Accroding to http://es5.github.com/#x9.6
2863         When the index is negative, it should not raise exception.
2864         Firefox and IE returns null when there is not indexth File object.
2865
2866         Test: fast/files/file-list-test.html
2867
2868         * fileapi/FileList.idl:
2869
2870 2012-06-05  Adam Barth  <abarth@webkit.org>
2871
2872         EventHandler shouldn't dispatch fake mousemove events when scrolling on devices that don't have a mouse
2873         https://bugs.webkit.org/show_bug.cgi?id=88270
2874
2875         Reviewed by James Robinson.
2876
2877         This patch adds a setting analogous to deviceSupportsTouch to determine
2878         whether the device supports mouse. We then don't dispatch fake mouse
2879         events on devices that don't have a mouse in the first place.
2880
2881         Test: fast/events/touch/scroll-without-mouse-lacks-mousemove-events.html
2882
2883         * page/EventHandler.cpp:
2884         (WebCore::EventHandler::fakeMouseMoveEventTimerFired):
2885         * page/Settings.cpp:
2886         (WebCore::Settings::Settings):
2887         * page/Settings.h:
2888         (WebCore::Settings::setDeviceSupportsMouse):
2889         (WebCore::Settings::deviceSupportsMouse):
2890         (Settings):
2891         * testing/InternalSettings.cpp:
2892         (WebCore::InternalSettings::InternalSettings):
2893         (WebCore::InternalSettings::restoreTo):
2894         (WebCore::InternalSettings::setDeviceSupportsMouse):
2895         (WebCore):
2896         * testing/InternalSettings.h:
2897         (InternalSettings):
2898         * testing/InternalSettings.idl:
2899
2900 2012-06-04  Simon Fraser  <simon.fraser@apple.com>
2901
2902         Leaking ClipRects
2903         https://bugs.webkit.org/show_bug.cgi?id=88282
2904
2905         Reviewed by Dan Bernstein.
2906
2907         In r118562 I made the ClipRectsCache use RefPtr<ClipRects>. However, ClipRects
2908         was initialized with m_refCnt=0, not 1 as adoptRef() and friends expect. Also,
2909         there was a manual ref() in RenderLayer::updateClipRects() which this patch removes.
2910
2911         * rendering/RenderLayer.cpp:
2912         (WebCore::RenderLayer::updateClipRects):
2913         * rendering/RenderLayer.h:
2914         (WebCore::ClipRects::ClipRects):
2915
2916 2012-06-04  Emil A Eklund  <eae@chromium.org> and Levi Weintraub  <leviw@chromium.org>
2917
2918         Add missing FractionalLayoutUnit += operator and move LineWidth to use all floats
2919         https://bugs.webkit.org/show_bug.cgi?id=88259
2920
2921         Reviewed by Ryosuke Niwa.
2922
2923         Fix two rounding bugs in LineLayout and RenderBlock that caused inlines
2924         and floats to wrap incorrectly.
2925
2926         Tests: fast/sub-pixel/float-containing-block-with-margin.html
2927                fast/sub-pixel/float-with-right-margin-zoom.html
2928                fast/sub-pixel/inline-block-with-padding.html
2929
2930         * platform/FractionalLayoutUnit.h:
2931         (WebCore::operator+=):
2932         Add missing float version of += operator thus avoiding a silent cast to
2933         int loosing precision.
2934         
2935         * rendering/RenderBlockLineLayout.cpp:
2936         (WebCore::LineWidth::computeAvailableWidthFromLeftAndRight):
2937         (WebCore::LineWidth::updateAvailableWidth):
2938         Change LineWidth left/right to floating point and instead of rounding the
2939         left and right edge separately.
2940         
2941         * rendering/RenderFlexibleBox.cpp:
2942         (WebCore::RenderFlexibleBox::resolveFlexibleLengths):
2943         Use explicit cast to avoid compiler ambiguity warning.
2944
2945 2012-06-04  Tony Chang  <tony@chromium.org>
2946
2947         CSS property 'order' should be a number rather than an int
2948         https://bugs.webkit.org/show_bug.cgi?id=88111
2949
2950         Reviewed by Ojan Vafai.
2951
2952         This changed in the spec:
2953         http://dev.w3.org/csswg/css3-flexbox/#order
2954
2955         I also fixed the compile with CSS3_FLEXBOX disabled.
2956
2957         No new tests, covered by existing tests.
2958
2959         * css/CSSComputedStyleDeclaration.cpp:
2960         (WebCore):
2961         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2962         * css/CSSParser.cpp:
2963         (WebCore::CSSParser::parseValue):
2964         * css/CSSProperty.cpp: Parse as float, remove clamping for HashMap<int>.
2965         (WebCore::CSSProperty::isInheritedProperty):
2966         * css/StyleBuilder.cpp:
2967         (WebCore::StyleBuilder::StyleBuilder):
2968         * css/StyleResolver.cpp:
2969         (WebCore::StyleResolver::collectMatchingRulesForList):
2970         * rendering/RenderFlexibleBox.cpp: Remove traits for HashMap<int>.
2971         (RenderFlexibleBox::OrderIterator):
2972         * rendering/RenderFlexibleBox.h:
2973         * rendering/style/RenderStyle.h:
2974         * rendering/style/StyleRareNonInheritedData.h:
2975         (StyleRareNonInheritedData):
2976
2977 2012-06-04  Hugo Parente Lima  <hugo.lima@openbossa.org>
2978
2979         Turn LEGACY_VIEWPORT_ADAPTION USE flag into an ENABLE flag.
2980         https://bugs.webkit.org/show_bug.cgi?id=88243
2981
2982         Reviewed by Adam Barth.
2983
2984         No new tests needed, this just rename a compiler flag.
2985
2986         * dom/Document.cpp:
2987         (WebCore::Document::setDocType):
2988         * dom/ViewportArguments.h:
2989         * html/HTMLMetaElement.cpp:
2990         (WebCore::HTMLMetaElement::process):
2991
2992 2012-06-04  Dana Jansens  <danakj@chromium.org>
2993
2994         [chromium] Remove redundant setNeedsCommit when prepareToDraw fails
2995         https://bugs.webkit.org/show_bug.cgi?id=88246
2996
2997         Reviewed by James Robinson.
2998
2999         When prepareToDraw fails it explicitly calls setNeedsCommit, but the
3000         scheduler already takes care of this for it. When a frame is not
3001         successfully drawn, the scheduler state machine sets the needsCommit
3002         bit itself.
3003
3004         This behaviour is covered by CCSchedulerStateMachineTest.TestFailedDrawSetsNeedsCommitAndDoesNotDrawAgain
3005
3006         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3007         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
3008
3009 2012-06-04  Takashi Toyoshima  <toyoshim@chromium.org>
3010
3011         [WebSocket] Send requires super linear time against data size
3012         https://bugs.webkit.org/show_bug.cgi?id=87383
3013
3014         Reviewed by Kent Tamura.
3015
3016         WebSocket send operation requires super linear time to send data
3017         against data size. This is because removing sent data in Vector<char>
3018         always requires data copy.
3019         Introduced wtf/StreamBuffer realizes O(n) buffer operations.
3020         This patch is only for optimization. No new tests are needed.
3021
3022         * platform/network/SocketStreamHandleBase.cpp:
3023         (WebCore::SocketStreamHandleBase::sendPendingData):
3024         * platform/network/SocketStreamHandleBase.h:
3025         (SocketStreamHandleBase):
3026
3027 2012-06-04  Tim Horton  <timothy_horton@apple.com>
3028
3029         Mock scrollbars differ by 1px in DRT vs. WKTR
3030         https://bugs.webkit.org/show_bug.cgi?id=80879
3031
3032         Rubber-stamped by Ryosuke Niwa.
3033
3034         Disable r119431 except for Apple Mac port.
3035
3036         * platform/ScrollbarThemeComposite.cpp:
3037         (WebCore::ScrollbarThemeComposite::thumbLength):
3038
3039 2012-06-04  Jeffrey Pfau  <jpfau@apple.com>
3040
3041         Document cleanup can get confused if parser still exists
3042         https://bugs.webkit.org/show_bug.cgi?id=88250
3043
3044         Reviewed by Geoffrey Garen.
3045
3046         No new tests; no behavior changes.
3047
3048         * dom/Document.cpp:
3049         (WebCore::Document::removedLastRef): Detach parser earlier
3050
3051 2012-06-04  Andrew Lo  <anlo@rim.com>
3052
3053         [BlackBerry] Split AnimationFrameRateController into its own file
3054         https://bugs.webkit.org/show_bug.cgi?id=88242
3055
3056         Reviewed by Antonio Gomes.
3057
3058         Include new header file to reflect re-organization of platform animation
3059         header files.
3060
3061         * platform/graphics/DisplayRefreshMonitor.h:
3062
3063 2012-06-04  Dana Jansens  <danakj@chromium.org>
3064
3065         [chromium] Allow CCLayerImpl to find its layer tree host, and use this for CCVideoLayerImpl instead of always-null pointer.
3066         https://bugs.webkit.org/show_bug.cgi?id=88252
3067
3068         Reviewed by James Robinson.
3069
3070         CCVideoLayerImpl has a pointer to its CCLayerTreeHostImpl which is never
3071         set to be non-null currently. Instead of making this a special case, we
3072         move the CCLayerTreeHostImpl* up to the CCLayerImpl base class, and set
3073         the pointer on every layer during commit via the TreeSynchronizer's walk
3074         through the layer tree.
3075
3076         Unit tests: Tested by TreeSynchronizer tests.
3077
3078         * platform/graphics/chromium/TreeSynchronizer.cpp:
3079         (WebCore::TreeSynchronizer::synchronizeTrees):
3080         (WebCore::TreeSynchronizer::synchronizeTreeRecursive):
3081         * platform/graphics/chromium/TreeSynchronizer.h:
3082         (WebCore):
3083         (TreeSynchronizer):
3084         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
3085         (WebCore::CCLayerImpl::CCLayerImpl):
3086         * platform/graphics/chromium/cc/CCLayerImpl.h:
3087         (WebCore):
3088         (WebCore::CCLayerImpl::layerTreeHostImpl):
3089         (WebCore::CCLayerImpl::setLayerTreeHostImpl):
3090         (CCLayerImpl):
3091         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3092         (WebCore::CCLayerTreeHost::finishCommitOnImplThread):
3093         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
3094         (WebCore::CCVideoLayerImpl::CCVideoLayerImpl):
3095         (WebCore::CCVideoLayerImpl::setNeedsRedraw):
3096         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
3097
3098 2012-06-04  Tim Horton  <timothy_horton@apple.com>
3099
3100         Mock scrollbars differ by 1px in DRT vs. WKTR
3101         https://bugs.webkit.org/show_bug.cgi?id=80879
3102
3103         Reviewed by Simon Fraser.
3104
3105         Round the length of the scrollbar thumb instead of truncating it.
3106
3107         No new tests, fixes a mismatch between pixel results from DRT and WKTR.
3108         Change is covered by all existing tests with scrollbars run with low tolerance.
3109
3110         * platform/ScrollbarThemeComposite.cpp:
3111         (WebCore::ScrollbarThemeComposite::thumbLength):
3112
3113 2012-06-04  Anders Carlsson  <andersca@apple.com>
3114
3115         Fix an unused result warning when building with clang.
3116
3117         * platform/cf/BinaryPropertyList.cpp:
3118         (WebCore::BinaryPropertyListWriter::writePropertyList):
3119
3120 2012-06-04  Ami Fischman  <fischman@chromium.org>
3121
3122         Don't crash when re-parenting a removed HTMLMediaElement
3123         https://bugs.webkit.org/show_bug.cgi?id=88058
3124
3125         Reviewed by Eric Carlson.
3126
3127         Test: media/media-reparent.html
3128
3129         * html/HTMLMediaElement.cpp:
3130         (WebCore::HTMLMediaElement::userCancelledLoad): Clear the pending load flags because any pending load has been cancelled.
3131
3132 2012-06-04  Sheriff Bot  <webkit.review.bot@gmail.com>
3133
3134         Unreviewed, rolling out r119421 and r119425.
3135         http://trac.webkit.org/changeset/119421
3136         http://trac.webkit.org/changeset/119425
3137         https://bugs.webkit.org/show_bug.cgi?id=88256
3138
3139         not reliable, let's have a do-over (Requested by kling on
3140         #webkit).
3141
3142         * dom/Element.cpp:
3143         (WebCore::Element::detachAttribute):
3144         (WebCore::Element::removeAttribute):
3145         (WebCore::Element::attributes):
3146         (WebCore::Element::setAttributeInternal):
3147         (WebCore::Element::parserSetAttributes):
3148         (WebCore::Element::hasEquivalentAttributes):
3149         (WebCore::Element::createAttributeData):
3150         (WebCore):
3151         (WebCore::Element::setAttributeNode):
3152         (WebCore::Element::removeAttributeNode):
3153         (WebCore::Element::getAttributeNode):
3154         (WebCore::Element::getAttributeNodeNS):
3155         (WebCore::Element::hasAttribute):
3156         (WebCore::Element::hasAttributeNS):
3157         (WebCore::Element::normalizeAttributes):
3158         (WebCore::Element::cloneAttributesFromElement):
3159         * dom/Element.h:
3160         (WebCore::Element::attributeData):
3161         (Element):
3162         (WebCore::Element::ensureAttributeData):
3163         (WebCore::Element::updatedAttributeData):
3164         (WebCore::Element::ensureUpdatedAttributeData):
3165         * dom/ElementAttributeData.cpp:
3166         (WebCore::ElementAttributeData::attrIfExists):
3167         (WebCore::ElementAttributeData::ensureAttr):
3168         (WebCore::ElementAttributeData::setAttr):
3169         (WebCore::ElementAttributeData::removeAttr):
3170         (WebCore::ElementAttributeData::setClass):
3171         (WebCore):
3172         (WebCore::ElementAttributeData::ensureInlineStyle):
3173         (WebCore::ElementAttributeData::ensureMutableInlineStyle):
3174         (WebCore::ElementAttributeData::destroyInlineStyle):
3175         (WebCore::ElementAttributeData::addAttribute):
3176         (WebCore::ElementAttributeData::removeAttribute):
3177         (WebCore::ElementAttributeData::isEquivalent):
3178         (WebCore::ElementAttributeData::detachAttrObjectsFromElement):
3179         (WebCore::ElementAttributeData::getAttributeItemIndexSlowCase):
3180         (WebCore::ElementAttributeData::cloneDataFrom):
3181         (WebCore::ElementAttributeData::clearAttributes):
3182         (WebCore::ElementAttributeData::replaceAttribute):
3183         (WebCore::ElementAttributeData::getAttributeNode):
3184         * dom/ElementAttributeData.h:
3185         (WebCore::ElementAttributeData::create):
3186         (ElementAttributeData):
3187         (WebCore::ElementAttributeData::setIdForStyleResolution):
3188         (WebCore::ElementAttributeData::setAttributeStyle):
3189         (WebCore::ElementAttributeData::length):
3190         (WebCore::ElementAttributeData::isEmpty):
3191         (WebCore::ElementAttributeData::attributeItem):
3192         (WebCore::ElementAttributeData::getAttributeItem):
3193         (WebCore::ElementAttributeData::ElementAttributeData):
3194         (WebCore::ElementAttributeData::attributeVector):
3195         (WebCore::ElementAttributeData::clonedAttributeVector):
3196         (WebCore::ElementAttributeData::getAttributeItemIndex):
3197         * dom/StyledElement.cpp:
3198         (WebCore::StyledElement::style):
3199         (WebCore::StyledElement::classAttributeChanged):
3200         (WebCore::StyledElement::removeInlineStyleProperty):
3201         (WebCore::StyledElement::addSubresourceAttributeURLs):
3202         * html/parser/HTMLConstructionSite.cpp:
3203         (WebCore::HTMLConstructionSite::createHTMLElementFromSavedElement):
3204         * xml/parser/XMLDocumentParserQt.cpp:
3205         (WebCore::XMLDocumentParser::XMLDocumentParser):
3206
3207 2012-06-04  Andreas Kling  <kling@webkit.org>
3208
3209         Unreviewed build fixes for cr-android and Qt.
3210
3211         * dom/ElementAttributeData.h:
3212         (WebCore::ElementAttributeData::setClass):
3213         Change ElementAttributeData::setClass() to take an AtomicString instead of a String.
3214         The only call site has an AtomicString anyway.
3215         * xml/parser/XMLDocumentParserQt.cpp:
3216         (WebCore::XMLDocumentParser::XMLDocumentParser): Add missing const.
3217
3218 2012-06-04  Sadrul Habib Chowdhury  <sadrul@chromium.org>
3219
3220         [chromium] Fix software rendering for device-scale-factor > 1
3221         https://bugs.webkit.org/show_bug.cgi?id=88136
3222
3223         Reviewed by Darin Fisher.
3224
3225         Test: fast/hidpi/device-scale-factor-paint.html
3226
3227         * WebCore.exp.in:
3228         * testing/InternalSettings.cpp:
3229         (WebCore::InternalSettings::setDeviceScaleFactor):
3230         (WebCore):
3231         * testing/InternalSettings.h:
3232         (InternalSettings):
3233         * testing/InternalSettings.idl:
3234
3235 2012-06-04  Andreas Kling  <kling@webkit.org>
3236
3237         Make ElementAttributeData a variable-sized object to reduce memory use.
3238         <http://webkit.org/b/88240>
3239
3240         Reviewed by Antti Koivisto.
3241
3242         Take advantage of the fact that we know at ElementAttributeData construction time how many attributes
3243         it needs to accomodate and allocate exactly as much space as needed instead of using a Vector.
3244         For elements that never have their attribute list mutated (the vast majority), this saves a lot of
3245         memory and removes the indirection to Vector<Attribute>'s heap-allocated storage.
3246
3247         Introduced a mutability flag to ElementAttributeData and sprinkled assertions all over to make sure
3248         that nothing tries to mutate an element with a raw attribute array.
3249
3250         When an Element's attribute(s) are mutated, we reconstruct the ElementAttributeData, this time using
3251         a Vector as backing instead. This is triggered when calling Element::mutableAttributeData().
3252
3253         This reduces memory consumption by 3.2MB when viewing the full HTML5 spec at <http://whatwg.org/c/>.
3254         This is a 35% reduction in DOM attribute memory use.
3255
3256         Furthermore, that page ends up promoting 27% of the elements to mutable attribute storage due to dynamic
3257         adding of "class" attributes. For more static pages, savings are even greater.
3258
3259         * dom/Element.cpp:
3260         (WebCore::Element::detachAttribute):
3261         (WebCore::Element::removeAttribute):
3262         (WebCore::Element::attributes):
3263         (WebCore::Element::setAttributeInternal):
3264         (WebCore::Element::parserSetAttributes):
3265         (WebCore::Element::hasEquivalentAttributes):
3266         (WebCore::Element::setAttributeNode):
3267         (WebCore::Element::removeAttributeNode):
3268         (WebCore::Element::getAttributeNode):
3269         (WebCore::Element::getAttributeNodeNS):
3270         (WebCore::Element::hasAttribute):
3271         (WebCore::Element::hasAttributeNS):
3272         (WebCore::Element::normalizeAttributes):
3273         (WebCore::Element::cloneAttributesFromElement):
3274         (WebCore::Element::createMutableAttributeData):
3275         * dom/Element.h:
3276         (WebCore::Element::attributeData):
3277         (Element):
3278         (WebCore::Element::updatedAttributeData):
3279         (WebCore::Element::ensureAttributeData):
3280         (WebCore::Element::ensureUpdatedAttributeData):
3281         (WebCore::Element::mutableAttributeData):
3282         * dom/ElementAttributeData.cpp:
3283         (WebCore::ElementAttributeData::createImmutable):
3284         (WebCore::ElementAttributeData::ElementAttributeData):
3285         (WebCore::ElementAttributeData::~ElementAttributeData):
3286         (WebCore::ElementAttributeData::attrIfExists):
3287         (WebCore::ElementAttributeData::ensureAttr):
3288         (WebCore::ElementAttributeData::setAttr):
3289         (WebCore::ElementAttributeData::removeAttr):
3290         (WebCore::ElementAttributeData::ensureInlineStyle):
3291         (WebCore::ElementAttributeData::ensureMutableInlineStyle):
3292         (WebCore::ElementAttributeData::destroyInlineStyle):
3293         (WebCore::ElementAttributeData::addAttribute):
3294         (WebCore::ElementAttributeData::removeAttribute):
3295         (WebCore::ElementAttributeData::isEquivalent):
3296         (WebCore::ElementAttributeData::detachAttrObjectsFromElement):
3297         (WebCore::ElementAttributeData::getAttributeItemIndexSlowCase):
3298         (WebCore::ElementAttributeData::cloneDataFrom):
3299         (WebCore::ElementAttributeData::clearAttributes):
3300         (WebCore::ElementAttributeData::replaceAttribute):
3301         (WebCore::ElementAttributeData::getAttributeNode):
3302         * dom/ElementAttributeData.h:
3303         (ElementAttributeData):
3304         (WebCore::ElementAttributeData::setClass):
3305         (WebCore::ElementAttributeData::setIdForStyleResolution):
3306         (WebCore::ElementAttributeData::inlineStyle):
3307         (WebCore::ElementAttributeData::setAttributeStyle):
3308         (WebCore::ElementAttributeData::isMutable):
3309         (WebCore::ElementAttributeData::makeMutable):
3310         (WebCore::ElementAttributeData::length):
3311         (WebCore::ElementAttributeData::isEmpty):
3312         (WebCore::ElementAttributeData::array):
3313         (WebCore::ElementAttributeData::attributeItem):
3314         (WebCore::ElementAttributeData::getAttributeItem):
3315         (WebCore::ElementAttributeData::getAttributeItemIndex):
3316         * dom/StyledElement.cpp:
3317         (WebCore::StyledElement::style):
3318         (WebCore::StyledElement::classAttributeChanged):
3319         (WebCore::StyledElement::removeInlineStyleProperty):
3320         (WebCore::StyledElement::addSubresourceAttributeURLs):
3321         * html/parser/HTMLConstructionSite.cpp:
3322         (WebCore::HTMLConstructionSite::createHTMLElementFromSavedElement):
3323         * xml/parser/XMLDocumentParserQt.cpp:
3324         (WebCore::XMLDocumentParser::XMLDocumentParser):
3325
3326 2012-06-04  Sadrul Habib Chowdhury  <sadrul@chromium.org>
3327
3328         [chromium] Combobox options and autofill options should not be scaled for device-scale factor
3329         https://bugs.webkit.org/show_bug.cgi?id=87921
3330
3331         Reviewed by Darin Fisher.
3332
3333         Chrome takes care of scaling the combobox/autofill lists in the browser side. So it is not
3334         necessary to scale here. This change reverts parts of changes in r111539.
3335
3336         Manually tested with different scale factors.
3337
3338         * platform/chromium/PopupListBox.cpp:
3339         (WebCore::PopupListBox::paint):
3340         (WebCore::PopupListBox::paintRow):
3341         (WebCore::PopupListBox::getRowHeight):
3342         * platform/chromium/PopupListBox.h:
3343         (PopupContainerSettings):
3344         * platform/chromium/PopupMenuChromium.cpp:
3345         (WebCore::PopupMenuChromium::show):
3346         * rendering/RenderMenuList.cpp:
3347         (WebCore::RenderMenuList::showPopup):
3348
3349 2012-06-04  Dana Jansens  <danakj@chromium.org>
3350
3351         [chromium] Make LayerRendererChromium use RenderPasses instead of RenderSurfaces
3352         https://bugs.webkit.org/show_bug.cgi?id=88132
3353
3354         Reviewed by Adrienne Walker.
3355
3356         This patch is partly renaming, partly moving data into CCRenderPass
3357         and CCRenderPassDrawQuad. LayerRendererChromium should accept as input
3358         a set of RenderPasses and this should be sufficient for drawing. It
3359         should have no notion of RenderSurfaces at all.
3360
3361         First, what isn't done: RenderSurfaces still hold the textures
3362         where RenderPasses are drawn to/from, so that these textures can
3363         persist across frames. This will be addressed separately.
3364
3365         Otherwise, this completely removes the concept of RenderSurface from
3366         LayerRenderChromium and the CCDrawQuad, replacing it with RenderPass.
3367         The "renderSurfaceTextureManager" is renamed to the "implTextureManager"
3368         and like-wise for the TextureAllocator, as these are not used
3369         exclusively for render surfaces (passes), and a texture manager for
3370         render passes that does not require a RenderSurface* will be the focus
3371         of future changes.
3372
3373         Covered by existing tests.
3374
3375         * WebCore.gypi:
3376         * platform/graphics/chromium/LayerRendererChromium.cpp:
3377         (WebCore::LayerRendererChromium::LayerRendererChromium):
3378         (WebCore::LayerRendererChromium::setVisible):
3379         (WebCore::LayerRendererChromium::releaseRenderPassTextures):
3380         (WebCore::LayerRendererChromium::viewportChanged):
3381         (WebCore::LayerRendererChromium::clearRenderPass):
3382         (WebCore::LayerRendererChromium::beginDrawingFrame):
3383         (WebCore::LayerRendererChromium::drawRenderPass):
3384         (WebCore::LayerRendererChromium::drawQuad):
3385         (WebCore::LayerRendererChromium::drawBackgroundFilters):
3386         (WebCore::LayerRendererChromium::drawRenderPassQuad):
3387         (WebCore::LayerRendererChromium::copyPlaneToTexture):
3388         (WebCore::LayerRendererChromium::drawHeadsUpDisplay):
3389         (WebCore::LayerRendererChromium::finishDrawingFrame):
3390         (WebCore::LayerRendererChromium::copyTextureToFramebuffer):
3391         (WebCore::LayerRendererChromium::getFramebufferTexture):
3392         (WebCore::LayerRendererChromium::isCurrentRenderPass):
3393         (WebCore::LayerRendererChromium::useRenderPass):
3394         (WebCore::LayerRendererChromium::useManagedTexture):
3395         (WebCore::LayerRendererChromium::bindFramebufferToTexture):
3396         (WebCore::LayerRendererChromium::setScissorToRect):
3397         (WebCore::LayerRendererChromium::setDrawFramebufferRect):
3398         (WebCore::LayerRendererChromium::initializeSharedObjects):
3399         (WebCore::LayerRendererChromium::renderPassProgram):
3400         (WebCore::LayerRendererChromium::renderPassProgramAA):
3401         (WebCore::LayerRendererChromium::renderPassMaskProgram):
3402         (WebCore::LayerRendererChromium::renderPassMaskProgramAA):
3403         (WebCore::LayerRendererChromium::cleanupSharedObjects):
3404         * platform/graphics/chromium/LayerRendererChromium.h:
3405         (WebCore):
3406         (LayerRendererChromium):
3407         * platform/graphics/chromium/cc/CCDrawQuad.cpp:
3408         (WebCore::CCDrawQuad::toRenderPassDrawQuad):
3409         * platform/graphics/chromium/cc/CCDrawQuad.h:
3410         (WebCore):
3411         (CCDrawQuad):
3412         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
3413         (WebCore::CCHeadsUpDisplay::draw):
3414         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3415         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
3416         (WebCore::CCLayerTreeHostImpl::drawLayers):
3417         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
3418         * platform/graphics/chromium/cc/CCRenderPass.cpp:
3419         (WebCore::CCRenderPass::CCRenderPass):
3420         (WebCore::CCRenderPass::appendQuadsForRenderSurfaceLayer):
3421         * platform/graphics/chromium/cc/CCRenderPass.h:
3422         (CCRenderPass):
3423         (WebCore::CCRenderPass::framebufferOutputRect):
3424         * platform/graphics/chromium/cc/CCRenderPassDrawQuad.cpp: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCRenderSurfaceDrawQuad.cpp.
3425         (WebCore):
3426         (WebCore::CCRenderPassDrawQuad::create):
3427         (WebCore::CCRenderPassDrawQuad::CCRenderPassDrawQuad):
3428         * platform/graphics/chromium/cc/CCRenderPassDrawQuad.h: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCRenderSurfaceDrawQuad.h.
3429         (WebCore):
3430         (CCRenderPassDrawQuad):
3431         (WebCore::CCRenderPassDrawQuad::renderPass):
3432         (WebCore::CCRenderPassDrawQuad::isReplica):
3433         (WebCore::CCRenderPassDrawQuad::maskTextureId):
3434         (WebCore::CCRenderPassDrawQuad::filters):
3435         (WebCore::CCRenderPassDrawQuad::backgroundFilters):
3436         * platform/graphics/chromium/cc/CCRenderSurface.cpp:
3437         (WebCore::CCRenderSurface::prepareContentsTexture):
3438         (WebCore::CCRenderSurface::prepareBackgroundTexture):
3439         (WebCore::CCRenderSurface::appendQuads):
3440         * platform/graphics/chromium/cc/CCRenderSurface.h:
3441         (WebCore):
3442         (CCRenderSurface):
3443         * platform/graphics/chromium/cc/CCRenderer.h:
3444         (CCRenderer):
3445         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
3446         (WebCore::CCScrollbarLayerImpl::willDraw):
3447         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
3448         (WebCore::CCVideoLayerImpl::reserveTextures):
3449
3450 2012-06-04  Abhishek Arya  <inferno@chromium.org>
3451
3452         Crash in multi-column layout.
3453         https://bugs.webkit.org/show_bug.cgi?id=88022
3454
3455         Reviewed by Ojan Vafai.
3456
3457         The patch addresses two problems::
3458         1. |this| in RenderBlock::splitBlocks can get destroyed when we
3459         move its children to the clone and later call updateBeforeAfterContent
3460         on the parent. So, we stop accessing its member variables and cache
3461         it in a local.
3462         2. Positioned objects were not getting cleared from our grand parents.
3463         This will happen if our immediate children got moved to a clone tree,
3464         however at our parent nothing was moved. So, we make sure to remove
3465         the positioned objects at every level while we are doing the cloning.
3466
3467         Tests: fast/multicol/span/empty-anonymous-block-split-crash.html
3468                fast/multicol/span/positioned-objects-not-removed-crash.html
3469
3470         * rendering/RenderBlock.cpp:
3471         (WebCore::RenderBlock::splitBlocks):
3472
3473 2012-06-04  Tim Horton  <timothy_horton@apple.com>
3474
3475         Mac build fails with SVG disabled
3476         https://bugs.webkit.org/show_bug.cgi?id=88165
3477
3478         Reviewed by Dirk Schulze.
3479
3480         Wrap all of SVGCSSPropertyNames in #if ENABLE(SVG),
3481         and mark an unused argument in collectMatchingRulesForList.
3482
3483         * css/SVGCSSPropertyNames.in:
3484         * css/StyleResolver.cpp:
3485         (WebCore::StyleResolver::collectMatchingRulesForList):
3486
3487 2012-06-04  David Kilzer  <ddkilzer@apple.com>
3488
3489         BUILD FIX: Unused variable with ENABLE(CONTEXT_MENUS) off
3490
3491         This broke in r118374.
3492
3493         * bindings/js/JSInspectorFrontendHostCustom.cpp:
3494         (WebCore::JSInspectorFrontendHost::showContextMenu): Add
3495         UNUSED_PARAM(exec) when ENABLE(CONTEXT_MENUS) is off.
3496
3497 2012-06-04  Sheriff Bot  <webkit.review.bot@gmail.com>
3498
3499         Unreviewed, rolling out r119393.
3500         http://trac.webkit.org/changeset/119393
3501         https://bugs.webkit.org/show_bug.cgi?id=88236
3502
3503         Test is incorrect (duplicate content) and is causing Chromium
3504         failures (Requested by schenney on #webkit).
3505
3506         * html/canvas/CanvasRenderingContext2D.cpp:
3507         (WebCore::CanvasRenderingContext2D::drawImage):
3508
3509 2012-06-04  Zeev Lieber  <zlieber@chromium.org>
3510
3511         [chromium] Cleanup scissor rect computation/use with damage
3512         https://bugs.webkit.org/show_bug.cgi?id=87167
3513
3514         Reviewed by Adrienne Walker.
3515
3516         Performing scissorRect computation during
3517         calculateRenderPasses. Storing scissorRect in shared quad state
3518         instead of computing it during drawQuad. Added scissorRect fields
3519         into layers and render surfaces.
3520
3521         Covered by existing layout tests. Introduced more unit tests to
3522         test end-to-end drawing using mock graphic context, and added more
3523         test cases to CCLayerTreeHostCommon to verify scissorRect computation.
3524
3525         * platform/graphics/chromium/LayerChromium.h:
3526         (WebCore::LayerChromium::scissorRect):
3527         (WebCore::LayerChromium::setScissorRect):
3528         (LayerChromium):
3529         * platform/graphics/chromium/LayerRendererChromium.cpp:
3530         (WebCore::LayerRendererChromium::clearRenderSurface):
3531         (WebCore::LayerRendererChromium::drawRenderPass):
3532         (WebCore::LayerRendererChromium::drawQuad):
3533         (WebCore::LayerRendererChromium::drawRenderSurfaceQuad):