REGGRESSION (r142112): It made compositing tests fail on EFL, Qt.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-03-06  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2
3         REGGRESSION (r142112): It made compositing tests fail on EFL, Qt.
4         https://bugs.webkit.org/show_bug.cgi?id=109291
5
6         Reviewed by Kenneth Rohde Christiansen.
7
8         Report we support fixed layers.
9
10         * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h:
11         (WebCore::ScrollingCoordinatorCoordinatedGraphics::supportsFixedPositionLayers):
12         (ScrollingCoordinatorCoordinatedGraphics):
13
14 2013-03-06  Sheriff Bot  <webkit.review.bot@gmail.com>
15
16         Unreviewed, rolling out r144859.
17         http://trac.webkit.org/changeset/144859
18         https://bugs.webkit.org/show_bug.cgi?id=111519
19
20         Introduced a test that calls non-exist function on non-
21         Chromium ports and crash on Chromium (Requested by rniwa on
22         #webkit).
23
24         * html/HTMLAudioElement.h:
25         (WebCore::HTMLAudioElement::hasPendingActivity):
26         (HTMLAudioElement):
27         * html/HTMLAudioElement.idl:
28         * html/HTMLMediaElement.cpp:
29         (WebCore::HTMLMediaElement::hasPendingActivity):
30         * html/HTMLMediaElement.idl:
31
32 2013-03-06  Ilya Tikhonovsky  <loislo@chromium.org>
33
34         Web Inspector: Could not open Profiles panel.
35         https://bugs.webkit.org/show_bug.cgi?id=111535
36
37         Reviewed by Alexander Pavlov.
38
39         * inspector/front-end/CPUProfileView.js:
40         * inspector/front-end/ProfilesPanel.js:
41
42 2013-03-06  Tony Chang  <tony@chromium.org>
43
44         Crash during middle mouse click when page is removed
45         https://bugs.webkit.org/show_bug.cgi?id=111489
46
47         Reviewed by Hajime Morrita.
48
49         Check for a null page that can happen if we remove the document from the DOM.
50         The other methods in EventHandler also check for a null page.
51
52         Test: editing/pasteboard/selection-paste-crash.html
53
54         * page/EventHandler.cpp:
55         (WebCore::EventHandler::handlePasteGlobalSelection):
56
57 2013-03-05  Eric Seidel  <eric@webkit.org>
58
59         Replace shouldLazyAttach bool with an enum for readability
60         https://bugs.webkit.org/show_bug.cgi?id=111503
61
62         Reviewed by Dimitri Glazkov.
63
64         No behavioral change.
65
66         * bindings/cpp/WebDOMNodeCustom.cpp:
67         (WebDOMNode::insertBefore):
68         (WebDOMNode::replaceChild):
69         (WebDOMNode::appendChild):
70         * bindings/js/JSNodeCustom.cpp:
71         (WebCore::JSNode::insertBefore):
72         (WebCore::JSNode::replaceChild):
73         (WebCore::JSNode::appendChild):
74         * bindings/v8/custom/V8NodeCustom.cpp:
75         (WebCore):
76         (WebCore::V8Node::insertBeforeMethodCustom):
77         (WebCore::V8Node::replaceChildMethodCustom):
78         (WebCore::V8Node::appendChildMethodCustom):
79         * dom/ContainerNode.cpp:
80         (WebCore):
81         (WebCore::ContainerNode::insertBefore):
82         (WebCore::ContainerNode::replaceChild):
83         (WebCore::ContainerNode::appendChild):
84         (WebCore::updateTreeAfterInsertion):
85         * dom/ContainerNode.h:
86         (ContainerNode):
87         * dom/Node.cpp:
88         (WebCore::Node::insertBefore):
89         (WebCore::Node::replaceChild):
90         (WebCore::Node::appendChild):
91         * dom/Node.h:
92         (Node):
93         * editing/AppendNodeCommand.cpp:
94         (WebCore::AppendNodeCommand::doApply):
95         * editing/InsertNodeBeforeCommand.cpp:
96         (WebCore::InsertNodeBeforeCommand::doApply):
97         * html/shadow/MediaControlsApple.cpp:
98         (WebCore::MediaControlsApple::createControls):
99         * html/shadow/MediaControlsBlackBerry.cpp:
100         (WebCore::MediaControlsBlackBerry::createControls):
101         * html/shadow/MediaControlsChromium.cpp:
102         (WebCore::MediaControlsChromium::initializeControls):
103         * html/shadow/MediaControlsChromiumAndroid.cpp:
104         (WebCore::MediaControlsChromiumAndroid::createControls):
105
106 2013-03-05  Hajime Morrita  <morrita@google.com>
107
108         Custom Elements: CustomElementConstructor::m_name doesn't have any good use.
109         https://bugs.webkit.org/show_bug.cgi?id=111523
110
111         Reviewed by Kentaro Hara.
112
113         This change removes CustomElementConstructor::m_name and renames
114         m_tagName to m_name. Now generated function name is same as interface name.
115
116         Originally, m_name was added to specify the generated constructor
117         name. An early version of custom element allows to give the name,
118         but it no longer says anything about that.
119
120         The rename is to align the semantics of type extension mechanism
121         of Custom Elements, where the name of a custom element isn't
122         necessarily a tag name.
123
124         No new tests. Just removing old code.
125
126         * bindings/scripts/CodeGeneratorV8.pm:
127         (GenerateHeader):
128         * dom/CustomElementConstructor.cpp:
129         (WebCore::CustomElementConstructor::create):
130         (WebCore::CustomElementConstructor::CustomElementConstructor):
131         (WebCore::CustomElementConstructor::createElement):
132         * dom/CustomElementConstructor.h:
133         (CustomElementConstructor):
134         (WebCore::CustomElementConstructor::name):
135         * dom/CustomElementRegistry.cpp:
136         (WebCore::CustomElementRegistry::registerElement):
137
138 2013-03-05  Ilya Tikhonovsky  <loislo@chromium.org>
139
140         Web Inspector: Flame Chart. Provide node context info in a popover when mouse hovers over a flame chart item.
141         https://bugs.webkit.org/show_bug.cgi?id=111442
142
143         Reviewed by Yury Semikhatsky.
144
145         FlameChart is a canvas so it is not possible to attach the popover to the items on it.
146         It would be a bit tricky to support an offset due to complex behaviour of the popover.
147         The simplest solution is to create a fake anchor element and move it to the right position.
148
149         * inspector/front-end/FlameChart.js:
150         (WebInspector.FlameChart):
151         (WebInspector.FlameChart.prototype._getPopoverAnchor):
152         (WebInspector.FlameChart.prototype._showPopover):
153         (WebInspector.FlameChart.prototype._onMouseMove):
154         (WebInspector.FlameChart.prototype.findNodeCallback):
155         (WebInspector.FlameChart.prototype._coordinatesToNode):
156         (WebInspector.FlameChart.prototype.onResize):
157         * inspector/front-end/flameChart.css:
158         (.flame-chart .item-anchor):
159
160 2013-03-05  Csaba Osztrogon√°c  <ossy@webkit.org>
161
162         Unreviewed buildfix after r144787. Add missing USE(GRAPHICS_SURFACE) guards.
163
164         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
165         (WebCore::CoordinatedGraphicsScene::setLayerState):
166         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
167         (WebCore::CoordinatedGraphicsLayerState::CoordinatedGraphicsLayerState):
168
169 2013-03-05  Geoffrey Garen  <ggaren@apple.com>
170
171         Autoreleased cached pages slow down the PLT by 2%
172         https://bugs.webkit.org/show_bug.cgi?id=111522
173
174         Reviewed by Filip Pizlo.
175
176         Let's stop doing that.
177
178         2% PLT speedup.
179
180         * history/PageCache.cpp:
181         (WebCore::PageCache::remove):
182
183 2013-03-05  Hayato Ito  <hayato@chromium.org>
184
185         [Shadow] Implements event re-targeting for Touch Events.
186         https://bugs.webkit.org/show_bug.cgi?id=107800
187
188         Reviewed by Dimitri Glazkov.
189
190         So far, Touch Events have been intentionally disabled in shadow
191         tree since it allows users to access internal nodes in shadow tree
192         by accessing Touch Event's information.
193
194         This patch re-targets all individual touch point's target in
195         TouchList (touches, targetTouches and changedTouches) owned by a Touch Event
196         before the Touch Event is dispatched so that we won't break an
197         upper boundary of shadow DOM.
198
199         Touch Events re-targeting is similar to that of Mouse Events
200         re-targeting. The difference is that a Touch Event can have more
201         than one related target because of multiple touches. We must
202         re-target all individual touch points which can be referred from
203         the Touch Event.
204
205         Now, Touch Events can be fired in shadow tree. I've removed the
206         existing limitation.
207
208         Test: fast/dom/shadow/touch-event-retargeting.html
209
210         * dom/EventContext.cpp:
211         (WebCore::EventContext::isTouchEventContext):
212         (WebCore):
213         (WebCore::TouchEventContext::TouchEventContext):
214         (WebCore::TouchEventContext::~TouchEventContext):
215         (WebCore::TouchEventContext::handleLocalEvents):
216         (WebCore::TouchEventContext::isTouchEventContext):
217         (WebCore::TouchEventContext::checkReachability):  Used for assertion of reachability for each Touch point.
218         * dom/EventContext.h:
219         (WebCore):
220         (EventContext):
221         (TouchEventContext): Introduced to hold necessary information for re-targeting Touch event.
222         (WebCore::TouchEventContext::touches):
223         (WebCore::TouchEventContext::targetTouches):
224         (WebCore::TouchEventContext::changedTouches):
225         (WebCore::EventContext::isReachable):
226         * dom/EventRetargeter.cpp:
227         (WebCore::EventRetargeter::calculateEventPath):
228         (WebCore::EventRetargeter::adjustForTouchEvent):
229         (WebCore):
230         (WebCore::EventRetargeter::adjustTouchList):
231         (WebCore::EventRetargeter::adjustForRelatedTarget):
232         (WebCore::EventRetargeter::calculateAdjustedNodes): Updated so that this can be used for Touch point re-targeting.
233         (WebCore::EventRetargeter::buildRelatedNodeMap):
234         * dom/EventRetargeter.h:
235         (WebCore):
236         (EventRetargeter):
237         * dom/Node.cpp:
238         (WebCore::Node::dispatchEvent):
239         (WebCore):
240         (WebCore::Node::dispatchTouchEvent):
241         * dom/Node.h:
242         (WebCore):
243         (Node):
244         * dom/Touch.cpp:
245         (WebCore::Touch::Touch):
246         (WebCore):
247         (WebCore::Touch::cloneWithNewTarget):
248         * dom/Touch.h:
249         (Touch):
250         * dom/TouchEvent.cpp:
251         (WebCore::TouchEventDispatchMediator::create):
252         (WebCore):
253         (WebCore::TouchEventDispatchMediator::TouchEventDispatchMediator):
254         (WebCore::TouchEventDispatchMediator::event):
255         (WebCore::TouchEventDispatchMediator::dispatchEvent):
256         * dom/TouchEvent.h:
257         (TouchEvent):
258         (WebCore::TouchEvent::setTouches):
259         (WebCore::TouchEvent::setTargetTouches):
260         (WebCore::TouchEvent::setChangedTouches):
261         (TouchEventDispatchMediator):
262         (WebCore):
263         (WebCore::toTouchEvent):
264         * dom/TouchList.cpp:
265         (WebCore::TouchList::item):
266         (WebCore):
267         * dom/TouchList.h:
268         (TouchList):
269         * page/EventHandler.cpp:
270         (WebCore::EventHandler::hitTestResultInFrame): Removed the limitation. Adjusting is no longer done here.
271         (WebCore::EventHandler::handleTouchEvent):
272
273 2013-03-05  Hajime Morrita  <morrita@google.com>
274
275         [Custom Elements][V8] Custom Element doesn't need its own WrapperTypeInfo
276         https://bugs.webkit.org/show_bug.cgi?id=111411
277
278         Reviewed by Kentaro Hara.
279
280         No new tests. No observable change yet.
281
282         This is a preparation for Bug 110436, where WebKit is going to
283         allow any HTML element to be a superclass of custom elements.
284
285         This change eliminates WrapperTypeInfo for custom element. Instead
286         of that, the wrapper of a custom element picks WrapperTypeInfo
287         from most descendant built-in HTML element. For example, think about
288         following hierarchy:
289
290         - ... <- HTMLElement <- HTMLDivElememnt <- ExistingCustomElement <- NewCustomElement
291
292         In this case, both ExistingCustomElement and NewCustomElement has
293         HTMLDivElememnt's type info. This is because HTMLDivElememnt is
294         the most descendant (or "the nearest") built-in HTML
295         element. (HTMLElement isn't the most descendant.
296         ExistingCustomElement isn't a built-in.)
297
298         Using such WrapperTypeInfos, created custom element wrappers can
299         get appropriate set of method and properties regardless of its
300         super-elements.
301
302         This change tells the prototype object of each built-in object
303         which WrapperTypeInfo the native backing wants:
304         HTMLDivElememnt.prototype knows V8HTMLDivElement::info for
305         example. The pointer to the type info is stored into an internal
306         field. On wrapper construction, createWrapper() walks up the
307         prototype chain and pick the first one.
308
309         * bindings/v8/V8DOMConfiguration.cpp:
310         (WebCore::V8DOMConfiguration::configureTemplate):
311         * bindings/v8/V8HTMLCustomElement.cpp:
312         (WebCore::findWrapperTypeOf):
313         (WebCore::V8HTMLCustomElement::createWrapper):
314         * bindings/v8/V8HTMLCustomElement.h:
315         * bindings/v8/V8PerContextData.cpp:
316         (WebCore::V8PerContextData::constructorForTypeSlowCase):
317         * bindings/v8/WrapperTypeInfo.h:
318         (WebCore):
319
320 2013-03-05  Aaron Colwell  <acolwell@chromium.org>
321
322         Heap-use-after-free in WebCore::HTMLMediaElement::~HTMLMediaElement
323         https://bugs.webkit.org/show_bug.cgi?id=110623
324
325         Reviewed by Eric Seidel.
326
327         Test: http/tests/misc/delete-frame-during-readystatechange-with-gc-after-video-removal.html
328
329         * html/HTMLAudioElement.h:
330         (HTMLAudioElement):
331         * html/HTMLAudioElement.idl:
332         * html/HTMLMediaElement.cpp:
333         (WebCore::HTMLMediaElement::hasPendingActivity):
334         * html/HTMLMediaElement.idl:
335
336 2013-03-05  Chris Fleizach  <cfleizach@apple.com>
337  
338         AX: Support aria-posinset/setsize
339         https://bugs.webkit.org/show_bug.cgi?id=109725
340
341         Reviewed by Tim Horton.
342
343         Expose aria-setsize and aria-posinset through accessibility.
344         Right now only the Mac platform exposes them.
345
346         Test: platform/mac/accessibility/aria-setsize-posinset.html
347
348         * accessibility/AccessibilityObject.cpp:
349         (WebCore::AccessibilityObject::supportsARIASetSize):
350         (WebCore):
351         (WebCore::AccessibilityObject::supportsARIAPosInset):
352         (WebCore::AccessibilityObject::ariaSetSize):
353         (WebCore::AccessibilityObject::ariaPosInset):
354         * accessibility/AccessibilityObject.h:
355         (AccessibilityObject):
356         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
357         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
358         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
359         * html/HTMLAttributeNames.in:
360
361
362 2013-03-05  Peter Nelson  <peter@peterdn.com>
363
364         [WinCairo] Support for cookies is incomplete
365         https://bugs.webkit.org/show_bug.cgi?id=110147
366         
367         Expired and HttpOnly cookies no longer accessible from JavaScript.
368         Cookies set in JavaScript now have correct domain/path.
369
370         Reviewed by Brent Fulgham.
371
372         Test: http/tests/cookies/http-get-cookie-set-in-js.html
373
374         * platform/network/curl/CookieJarCurl.cpp:
375         (WebCore):
376         (WebCore::addMatchingCurlCookie):
377         (WebCore::getNetscapeCookieFormat):
378         (WebCore::setCookiesFromDOM):
379         (WebCore::cookieRequestHeaderFieldValue):
380
381 2013-03-05  Alec Flett  <alecflett@chromium.org>
382
383         Fix mac clang build with long long
384         https://bugs.webkit.org/show_bug.cgi?id=111495
385
386         Unreviewed fix for mac build.
387
388         * Modules/indexeddb/IDBBackingStore.cpp:
389         (WebCore::IDBBackingStore::IDBBackingStore):
390
391 2013-03-05  Alec Flett  <alecflett@chromium.org>
392
393         Fix mac clang build with long long
394         https://bugs.webkit.org/show_bug.cgi?id=111495
395
396         Unreviewed fix for mac build.
397
398         * Modules/indexeddb/IDBBackingStore.cpp:
399         (WebCore::IDBBackingStore::IDBBackingStore):
400
401 2013-03-05  Aaron Colwell  <acolwell@chromium.org>
402
403         Add V8Document.h include when the V8 code generator creates a toV8(Document*) call.
404         https://bugs.webkit.org/show_bug.cgi?id=111486
405
406         Reviewed by Adam Barth.
407
408         No new tests. This doesn't change user visible behavior.
409
410         * bindings/scripts/CodeGeneratorV8.pm:
411         (GenerateNamedConstructor):
412         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
413
414 2013-03-05  Shawn Singh  <shawnsingh@chromium.org>
415
416         Fix default background of a dragged image.
417         https://bugs.webkit.org/show_bug.cgi?id=110512
418
419         Reviewed by Tony Chang.
420
421         Transparent background color (particularly visible in the padding
422         of an element) was not being respected. The solution is to
423         initially fill the drag image with transparent instead of white,
424         so that any color background works correctly. This patch does not
425         affect Apple Mac or Win platforms, given that this part of the
426         code is #if guarded from those platforms.
427
428         Manual test added:
429           ManualTests/drag-background-with-padding.html
430
431         Infrastructure for retrieving the drag image for pixel testing
432         does not yet exist.
433
434         * page/Frame.cpp:
435         (WebCore::Frame::nodeImage):
436
437 2013-03-05  Emil A Eklund  <eae@chromium.org>
438
439         ASSERTION FAILED: i < size(), UNKNOWN in WebCore::RenderTableSection::layout
440         https://bugs.webkit.org/show_bug.cgi?id=108838
441
442         Reviewed by Levi Weintraub.
443         
444         Ensure that RenderTable::recalcSections is called when moving a
445         TableSection by calling setNeedsSectionRecalc in addChild for
446         TableSections.
447
448         Test: fullscreen/full-screen-table-section.html
449
450         * rendering/RenderTable.cpp:
451         (WebCore::RenderTable::addChild):
452
453 2013-03-05  Kenneth Russell  <kbr@google.com>
454
455         Upgrade ANGLE to r1987
456         https://bugs.webkit.org/show_bug.cgi?id=111381
457
458         Reviewed by Dean Jackson.
459
460         Covered by existing tests. Ran WebGL conformance tests in Safari
461         to ensure correct operation of patch.
462
463         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
464         (WebCore::GraphicsContext3D::GraphicsContext3D):
465         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
466         (WebCore::GraphicsContext3D::GraphicsContext3D):
467         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
468         (WebCore::GraphicsContext3D::GraphicsContext3D):
469         * platform/graphics/mac/GraphicsContext3DMac.mm:
470         (WebCore::GraphicsContext3D::GraphicsContext3D):
471         * platform/graphics/qt/GraphicsContext3DQt.cpp:
472         (WebCore::GraphicsContext3DPrivate::initializeANGLE):
473             Changed all ports to query for highp support in fragment
474             shaders and conditionally enable it in ANGLE shader translator.
475
476 2013-03-05  Alec Flett  <alecflett@chromium.org>
477
478         IndexedDB: Add IDBBackingStoreTest
479         https://bugs.webkit.org/show_bug.cgi?id=111233
480
481         Reviewed by Adam Barth.
482
483         These are tweaks to make IDBBackingStore more easily testable.
484
485         * Modules/indexeddb/IDBBackingStore.cpp:
486         (WebCore::IDBBackingStore::IDBBackingStore): Allow use without a backing store.
487
488 2013-03-04  James Robinson  <jamesr@chromium.org>
489
490         [chromium] Move check for threaded compositing from WebCompositorSupport to Platform
491         https://bugs.webkit.org/show_bug.cgi?id=111386
492
493         Reviewed by Adrienne Walker.
494
495         This moves checks for whether threaded compositing is enabled from WebCompositorSupport
496         to Platform. In the case of Canvas2DLayerBridge, the check is moved completely out of
497         the class to make it easier for tests to specify the threaded configuration to use in the test.
498
499         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
500         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
501         * platform/graphics/chromium/Canvas2DLayerBridge.h:
502         (WebCore::Canvas2DLayerBridge::create):
503         (Canvas2DLayerBridge):
504         * platform/graphics/chromium/DrawingBufferChromium.cpp:
505         (WebCore::DrawingBuffer::DrawingBuffer):
506         * platform/graphics/skia/ImageBufferSkia.cpp:
507         (WebCore::createAcceleratedCanvas):
508
509 2013-03-05  Anders Carlsson  <andersca@apple.com>
510
511         Split up the storage event dispatch functions further
512         https://bugs.webkit.org/show_bug.cgi?id=111482
513
514         Reviewed by Beth Dakin.
515
516         Add new functions for dispatching storage events to a set of frames.
517
518         * storage/StorageAreaImpl.cpp:
519         (WebCore::StorageAreaImpl::dispatchStorageEvent):
520         * storage/StorageEventDispatcher.cpp:
521         (WebCore::StorageEventDispatcher::dispatchSessionStorageEvents):
522         (WebCore::StorageEventDispatcher::dispatchLocalStorageEvents):
523         (WebCore):
524         (WebCore::StorageEventDispatcher::dispatchSessionStorageEventsToFrames):
525         (WebCore::StorageEventDispatcher::dispatchLocalStorageEventsToFrames):
526         * storage/StorageEventDispatcher.h:
527         (WebCore):
528         (StorageEventDispatcher):
529
530 2013-03-05  Stephen Chenney  <schenney@chromium.org>
531
532         Crash when ImageLoader deletes Element inside SVGImageElement
533         https://bugs.webkit.org/show_bug.cgi?id=111085
534
535         Reviewed by Abhishek Arya.
536
537         Elements with ImageLoader objects associated with them may have their
538         final reference held by the ImageLoader (to allow events to be sent
539         and handled). Any call on Element that causes the ImageLoader to
540         dispatch events might then result in the final deref of the Element
541         itself, thus leaving all the Element's "this" pointers up the stack
542         pointing to invalid memory.
543
544         This change puts the deref of the Element on a timer so that, if the
545         deref is called via a method on Element, the call stack will unwind
546         before the deref occurs.
547
548         Test: svg/custom/image-with-attr-change-after-delete-crash.html
549
550         * loader/ImageLoader.cpp:
551         (WebCore::ImageLoader::ImageLoader): Initialize a timer
552         (WebCore::ImageLoader::updatedHasPendingEvent): Put deref of the
553           element on a oneShotTimer, with appropriate assertions and checks to
554           ensure we only ref/deref once.
555         (WebCore::ImageLoader::timerFired): Deref the element when the timer fires.
556         * loader/ImageLoader.h:
557         (ImageLoader): Define a timer for controlling deref of the element.
558
559 2013-03-05  Antoine Quint  <graouts@apple.com>
560
561         Web Inspector: identify reflection layers in LayerTreeAgent
562         https://bugs.webkit.org/show_bug.cgi?id=111419
563
564         We add a new property "isReflection" to the Layer objects returned
565         to the front-end to indicate whether the layer was created to host
566         the reflection for an element. When this new property is true, the
567         "nodeId" property is set to point to the reflected element's node
568         id, since there is no node per-se directly associated with this layer.
569         We also change the "bounds" property to return absolute page coordinates
570         such that the front-end can use this information to highlight that
571         region in the page since metrics would otherwise be unavailable.
572
573         Reviewed by Dean Jackson.
574
575         Test: inspector-protocol/layers/layers-reflected-content.html
576
577         * inspector/Inspector.json:
578         * inspector/InspectorLayerTreeAgent.cpp:
579         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
580
581 2013-03-05  peavo@outlook.com  <peavo@outlook.com>
582
583         [WinCairo] Compile fix after r144024.
584         https://bugs.webkit.org/show_bug.cgi?id=111306
585
586         Reviewed by James Robinson.
587
588         * page/scrolling/ScrollingCoordinator.cpp: Added guard for USE(ACCELERATED_COMPOSITING).
589         * page/scrolling/ScrollingCoordinator.h: Added guard for USE(ACCELERATED_COMPOSITING).
590
591 2013-03-05  James Weatherall  <wez@chromium.org>
592
593         keydown and keyup events have zero keycode for some numeric pad keys under Chromium on Linux
594         https://bugs.webkit.org/show_bug.cgi?id=85642
595
596         Add missing key mappings for GDK_KP_Begin, GDK_KP_Insert, GDK_KP_Delete and GDK_ISO_Level3_Shift.
597
598         Reviewed by Ojan Vafai.
599
600         * platform/chromium/KeyCodeConversionGtk.cpp:
601         (WebCore::windowsKeyCodeForKeyEvent):
602
603 2013-03-05  Alec Flett  <alecflett@chromium.org>
604
605         IndexedDB: Properly refactor frontend/backend code by #includes
606         https://bugs.webkit.org/show_bug.cgi?id=110653
607
608         Reviewed by Dimitri Glazkov.
609
610         IndexedDB has a distinct backend and frontend, with well defined
611         *Interface / *Callbacks classes distinguishing them, respectively.
612         
613         This makes sure that the frontend and backend do not include each
614         other and fixes build problems that occurred as a result.
615
616         Specifically this moves enums out of IDBCursor and IDBTransaction
617         into IndexedDB.h in a new WebCore::IndexedDB namespace.
618
619         No new tests, as this is just a refactor.
620
621 2013-03-05  Jeffrey Pfau  <jpfau@apple.com>
622
623         Clear associated cache partitions when deleting origins' cache
624         https://bugs.webkit.org/show_bug.cgi?id=111383
625
626         Reviewed by Maciej Stachowiak.
627
628         Clear the cache partitions associated with the origin being cleared.
629
630         Not possible to test with current automated test tools, must be tested manually.
631
632         * loader/cache/MemoryCache.cpp:
633         (WebCore::MemoryCache::removeResourcesWithOrigin):
634
635 2013-03-04  Ojan Vafai  <ojan@chromium.org>
636
637         Inline min/maxInstrinsicLogicalWidth functions
638         https://bugs.webkit.org/show_bug.cgi?id=111399
639
640         Reviewed by Tony Chang.
641
642         Turns out these functions don't need to be public and only
643         have one caller. This patch is in preparation for supporting
644         intrinsic widths on tables, which will need to pass in the
645         border and padding width as an argument.
646
647         * rendering/RenderBox.cpp:
648         (WebCore::RenderBox::fillAvailableMeasure):
649         (WebCore::RenderBox::computeIntrinsicLogicalWidthUsing):
650         (WebCore::RenderBox::computeLogicalWidthInRegionUsing):
651         * rendering/RenderBox.h:
652
653 2013-03-05  Victor Carbune  <vcarbune@chromium.org>
654
655         Cue line-height property shouldn't be inherited from the video element
656         https://bugs.webkit.org/show_bug.cgi?id=111262
657
658         Reviewed by Eric Carlson.
659
660         Test: media/track/track-cue-rendering-on-resize.html
661
662         * css/mediaControls.css:
663         (video::-webkit-media-text-track-container): Set the default font size
664         and family using the "font" property to also reset the line-height property.
665
666 2013-03-05  Joshua Bell  <jsbell@chromium.org>
667
668         IndexedDB: Remove some unused binding code
669         https://bugs.webkit.org/show_bug.cgi?id=111463
670
671         Reviewed by Adam Barth.
672
673         IDBRequest got a custom V8 getter for |request| to help diagnose an issue, but the
674         root cause was found/fixed (http://wkbug.com/110916 and http://wkbug.com/110206) so
675         remove it. Also, IDBKey was marked ScriptWrappable but it is now explicitly converted
676         to a ScriptValue before it gets anywhere near the binding code, so remove that too.
677         Finally, createIDBKeyFromValue doesn't need to be exposed from IDBBindingUtilities.
678
679         No new tests - just removing dead code.
680
681         * Modules/indexeddb/IDBKey.h: No need for ScriptWrappable.
682         * Modules/indexeddb/IDBRequest.idl: Remove custom binding (root cause of bug found).
683         * WebCore.gypi: Ditto.
684         * bindings/js/IDBBindingUtilities.h: Don't expose internal createIDBKeyFromValue().
685         * bindings/v8/IDBBindingUtilities.h: Ditto.
686         * bindings/v8/custom/V8IDBRequestCustom.cpp: Removed.
687
688 2013-03-05  Sheriff Bot  <webkit.review.bot@gmail.com>
689
690         Unreviewed, rolling out r144798.
691         http://trac.webkit.org/changeset/144798
692         https://bugs.webkit.org/show_bug.cgi?id=111478
693
694         "broke chromium windows build" (Requested by dpranke on
695         #webkit).
696
697         * GNUmakefile.list.am:
698         * Modules/indexeddb/IDBBackingStore.cpp:
699         (WebCore::IDBBackingStore::Cursor::continueFunction):
700         (WebCore::objectStoreCursorOptions):
701         (WebCore::indexCursorOptions):
702         (WebCore::IDBBackingStore::openObjectStoreCursor):
703         (WebCore::IDBBackingStore::openObjectStoreKeyCursor):
704         (WebCore::IDBBackingStore::openIndexKeyCursor):
705         (WebCore::IDBBackingStore::openIndexCursor):
706         * Modules/indexeddb/IDBBackingStore.h:
707         (IDBBackingStore):
708         * Modules/indexeddb/IDBCursor.cpp:
709         (WebCore::IDBCursor::create):
710         (WebCore::IDBCursor::IDBCursor):
711         (WebCore::IDBCursor::continueFunction):
712         (WebCore::IDBCursor::stringToDirection):
713         (WebCore::IDBCursor::directionToString):
714         * Modules/indexeddb/IDBCursor.h:
715         (IDBCursor):
716         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
717         (WebCore::IDBCursorBackendImpl::IDBCursorBackendImpl):
718         (WebCore::IDBCursorBackendImpl::deleteFunction):
719         (WebCore::IDBCursorBackendImpl::CursorPrefetchIterationOperation::perform):
720         * Modules/indexeddb/IDBCursorBackendImpl.h:
721         (WebCore::IDBCursorBackendImpl::create):
722         (WebCore::IDBCursorBackendImpl::value):
723         (IDBCursorBackendImpl):
724         * Modules/indexeddb/IDBCursorBackendInterface.h:
725         (WebCore):
726         * Modules/indexeddb/IDBCursorWithValue.cpp:
727         (WebCore::IDBCursorWithValue::create):
728         (WebCore::IDBCursorWithValue::IDBCursorWithValue):
729         * Modules/indexeddb/IDBCursorWithValue.h:
730         (IDBCursorWithValue):
731         * Modules/indexeddb/IDBDatabase.cpp:
732         (WebCore::IDBDatabase::transaction):
733         * Modules/indexeddb/IDBDatabase.h:
734         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
735         (WebCore::GetOperation::create):
736         (WebCore::GetOperation::GetOperation):
737         (GetOperation):
738         (WebCore::OpenCursorOperation::create):
739         (WebCore::OpenCursorOperation::OpenCursorOperation):
740         (OpenCursorOperation):
741         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
742         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
743         (WebCore::IDBDatabaseBackendImpl::createIndex):
744         (WebCore::IDBDatabaseBackendImpl::deleteIndex):
745         (WebCore::IDBDatabaseBackendImpl::get):
746         (WebCore::GetOperation::perform):
747         (WebCore::IDBDatabaseBackendImpl::put):
748         (WebCore::PutOperation::perform):
749         (WebCore::IDBDatabaseBackendImpl::setIndexKeys):
750         (WebCore::IDBDatabaseBackendImpl::openCursor):
751         (WebCore::OpenCursorOperation::perform):
752         (WebCore::CountOperation::perform):
753         (WebCore::IDBDatabaseBackendImpl::deleteRange):
754         (WebCore::DeleteRangeOperation::perform):
755         (WebCore::IDBDatabaseBackendImpl::clear):
756         (WebCore::IDBDatabaseBackendImpl::transactionStarted):
757         (WebCore::IDBDatabaseBackendImpl::transactionFinished):
758         (WebCore::IDBDatabaseBackendImpl::transactionFinishedAndAbortFired):
759         (WebCore::IDBDatabaseBackendImpl::transactionFinishedAndCompleteFired):
760         (WebCore::IDBDatabaseBackendImpl::createTransaction):
761         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
762         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
763         (IDBDatabaseBackendImpl):
764         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
765         * Modules/indexeddb/IDBFactory.h:
766         * Modules/indexeddb/IDBIndex.cpp:
767         (WebCore):
768         (WebCore::IDBIndex::openCursor):
769         (WebCore::IDBIndex::openKeyCursor):
770         * Modules/indexeddb/IDBObjectStore.cpp:
771         (WebCore):
772         (WebCore::IDBObjectStore::openCursor):
773         * Modules/indexeddb/IDBRequest.cpp:
774         (WebCore::IDBRequest::IDBRequest):
775         (WebCore::IDBRequest::setCursorDetails):
776         (WebCore::IDBRequest::setResultCursor):
777         (WebCore::IDBRequest::onSuccess):
778         * Modules/indexeddb/IDBRequest.h:
779         (IDBRequest):
780         * Modules/indexeddb/IDBTransaction.cpp:
781         (WebCore::IDBTransaction::create):
782         (WebCore::IDBTransaction::IDBTransaction):
783         (WebCore::IDBTransaction::stringToMode):
784         (WebCore::IDBTransaction::modeToString):
785         * Modules/indexeddb/IDBTransaction.h:
786         (WebCore::IDBTransaction::isReadOnly):
787         (WebCore::IDBTransaction::isVersionChange):
788         (IDBTransaction):
789         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
790         (WebCore::IDBTransactionBackendImpl::create):
791         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
792         * Modules/indexeddb/IDBTransactionBackendImpl.h:
793         (IDBTransactionBackendImpl):
794         (WebCore::IDBTransactionBackendImpl::mode):
795         * Modules/indexeddb/IDBTransactionCoordinator.cpp:
796         (WebCore::IDBTransactionCoordinator::processStartedTransactions):
797         (WebCore::IDBTransactionCoordinator::canRunTransaction):
798         * Modules/indexeddb/IndexedDB.h: Removed.
799         * Target.pri:
800         * WebCore.gypi:
801
802 2013-03-05  Tommy Widenflycht  <tommyw@google.com>
803
804         MediaStream API: Allow local and remote descriptions to be accessed after close
805         https://bugs.webkit.org/show_bug.cgi?id=111437
806
807         Reviewed by Adam Barth.
808
809         It's quite clear in the standard that the getters should still return the old value.
810         Also overhauling the state setters a bit to check if the new state is different.
811
812         Existing tests expanded to cover patch.
813
814         * Modules/mediastream/RTCPeerConnection.cpp:
815         (WebCore::RTCPeerConnection::localDescription):
816         (WebCore::RTCPeerConnection::remoteDescription):
817         (WebCore::RTCPeerConnection::changeSignalingState):
818         (WebCore::RTCPeerConnection::changeIceGatheringState):
819         (WebCore::RTCPeerConnection::changeIceConnectionState):
820
821 2013-03-05  Charlie Reis  <creis@chromium.org>
822
823         Add FrameLoaderClient::didAccessInitialDocument
824         https://bugs.webkit.org/show_bug.cgi?id=107963
825
826         Notifies the FrameLoaderClient if another page accesses the
827         initial empty document of a main frame.  In this case, it is
828         no longer safe to display the provisional URL.
829
830         Only takes effect for PLATFORM(CHROMIUM), since no other platforms
831         listen to the notification.
832
833         Reviewed by Adam Barth.
834
835         * bindings/v8/V8DOMWindowShell.cpp:
836         (WebCore::V8DOMWindowShell::setSecurityToken):
837             Use default token for initial document.
838         * bindings/v8/custom/V8DOMWindowCustom.cpp:
839             Notify loader if initial document is accessed.
840         (WebCore::V8DOMWindow::namedSecurityCheck):
841         (WebCore::V8DOMWindow::indexedSecurityCheck):
842         * loader/FrameLoader.cpp:
843         (WebCore::FrameLoader::FrameLoader):
844         (WebCore::FrameLoader::didAccessInitialDocument):
845         (WebCore):
846         * loader/FrameLoader.h:
847         (FrameLoader):
848         * loader/FrameLoaderClient.h:
849         (FrameLoaderClient):
850         (WebCore::FrameLoaderClient::didAccessInitialDocument):
851
852 2013-03-05  Otto Derek Cheung  <otcheung@rim.com>
853
854         [BlackBerry] Fix assertion in CookieManager::getBackingStoreCookies
855         https://bugs.webkit.org/show_bug.cgi?id=111468
856
857         Reviewed by Rob Buis.
858         Internally reviewed by Konrad Piascik.
859
860         The assert in getBackingStoreCookies could be giving out false positives now
861         that we have our fixes for cookie loading in PR 286189. The cookie store could
862         be half loaded if the first cookie get/set call happens before the db is fully loaded.
863         A full webkit sync call to reload the database will cause the assert to be hit.
864
865         Safer to flush everything out and try again.
866
867         * platform/blackberry/CookieManager.cpp:
868         (WebCore::CookieManager::getBackingStoreCookies):
869
870 2013-03-05  Tony Gentilcore  <tonyg@chromium.org>
871
872         CompactHTMLToken does not need an XSSInfo pointer
873         https://bugs.webkit.org/show_bug.cgi?id=111423
874
875         Reviewed by Eric Seidel.
876
877         The CompactHTMLToken should remain as small as possible because it is copied. This shrinks the size by one pointer
878         by moving a relatively uncommon attribute out to its own Vector.
879
880         No new tests because no new functionality.
881
882         * html/parser/BackgroundHTMLParser.cpp:
883         (WebCore::checkThatXSSInfosAreSafeToSendToAnotherThread):
884         (WebCore):
885         (WebCore::BackgroundHTMLParser::pumpTokenizer):
886         (WebCore::BackgroundHTMLParser::sendTokensToMainThread):
887         * html/parser/BackgroundHTMLParser.h:
888         (BackgroundHTMLParser):
889         * html/parser/CompactHTMLToken.cpp:
890         (SameSizeAsCompactHTMLToken):
891         (WebCore::CompactHTMLToken::isSafeToSendToAnotherThread):
892         * html/parser/CompactHTMLToken.h:
893         (WebCore):
894         (CompactHTMLToken):
895         * html/parser/HTMLDocumentParser.cpp:
896         (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser):
897         * html/parser/HTMLDocumentParser.h:
898         (ParsedChunk):
899         * html/parser/XSSAuditorDelegate.h:
900         (XSSInfo):
901         (WebCore):
902
903 2013-03-05  Anders Carlsson  <andersca@apple.com>
904
905         Split StorageEventDispatcher::dispatch into two functions
906         https://bugs.webkit.org/show_bug.cgi?id=111464
907
908         Reviewed by Beth Dakin.
909
910         Split StorageEventDispatcher::dispatch into dispatchSessionStorageEvent and
911         dispatchLocalStorageEvent and make StorageAreaImpl::dispatchStorageEvent call
912         the right function based on the storage area type.
913
914         * storage/StorageAreaImpl.cpp:
915         (WebCore::StorageAreaImpl::dispatchStorageEvent):
916         * storage/StorageEventDispatcher.cpp:
917         (WebCore::StorageEventDispatcher::dispatchSessionStorageEvent):
918         (WebCore):
919         (WebCore::StorageEventDispatcher::dispatchLocalStorageEvent):
920         * storage/StorageEventDispatcher.h:
921         (StorageEventDispatcher):
922
923 2013-03-05  Brent Fulgham  <bfulgham@webkit.org>
924
925         [WinCairo] Unreviewed build fix after r144024.
926
927         * page/scrolling/ScrollingCoordinator.cpp:
928         (WebCore::ScrollingCoordinator::scrollLayerForScrollableArea): Handle
929         case of not using Accelerated Compositing
930         (WebCore::ScrollingCoordinator::horizontalScrollbarLayerForScrollableArea):
931         (WebCore::ScrollingCoordinator::verticalScrollbarLayerForScrollableArea): Ditto.
932
933 2013-03-05  Alec Flett  <alecflett@chromium.org>
934
935         IndexedDB: Properly refactor frontend/backend code by #includes
936         https://bugs.webkit.org/show_bug.cgi?id=110653
937
938         Reviewed by Dimitri Glazkov.
939
940         IndexedDB has a distinct backend and frontend, with well defined
941         *Interface / *Callbacks classes distinguishing them, respectively.
942         
943         This makes sure that the frontend and backend do not include each
944         other and fixes build problems that occurred as a result.
945
946         Specifically this moves enums out of IDBCursor and IDBTransaction
947         into IndexedDB.h in a new WebCore::IndexedDB namespace.
948
949         No new tests, as this is just a refactor.
950
951 2013-03-05  James Robinson  <jamesr@chromium.org>
952
953         ContainerNode::setActive should not sleep for 100ms on platforms that do not implement synchronous repaint(true) semantics
954         https://bugs.webkit.org/show_bug.cgi?id=87054
955
956         Reviewed by Darin Adler.
957
958         Adds a new ChromeClient function to query if the platform supports the immediate parameter
959         to the invalidation APIs and guards the synchronous repaint logic in ContainerNode::setActive()
960         with it.
961
962         * dom/ContainerNode.cpp:
963         (WebCore::ContainerNode::setActive):
964         * page/ChromeClient.h:
965         (WebCore::ChromeClient::supportsImmediateInvalidation):
966
967 2013-03-05  Anders Carlsson  <andersca@apple.com>
968
969         Simplify storage event dispatch somewhat
970         https://bugs.webkit.org/show_bug.cgi?id=111461
971
972         Reviewed by Beth Dakin.
973
974         Add a StorageAreaImpl::dispatchStorageEvent to avoid replicating the calls to
975         StorageEventDispatcher::dispatch there times. This is in preparation for changing the
976         interface of StorageEventDispatcher so it can be used by WebKit2.
977
978         * storage/StorageAreaImpl.cpp:
979         (WebCore::StorageAreaImpl::setItem):
980         (WebCore::StorageAreaImpl::removeItem):
981         (WebCore::StorageAreaImpl::clear):
982         (WebCore::StorageAreaImpl::dispatchStorageEvent):
983
984         * storage/StorageAreaImpl.h:
985         Reindent.
986
987 2013-03-05  Tony Chang  <tony@chromium.org>
988
989         Fix some crashes in render sliders
990         https://bugs.webkit.org/show_bug.cgi?id=111458
991
992         Reviewed by Ojan Vafai.
993
994         Fix some cases where we assumed the renderer is a renderBox.
995
996         Test: fast/forms/range/slider-inline-crash.html
997
998         * html/shadow/SliderThumbElement.cpp:
999         (WebCore::RenderSliderContainer::layout): Use renderBox() which will return 0 if the renderer is not a RenderBox.
1000         (WebCore::SliderThumbElement::setPositionFromPoint): Bail out early if renderBox() is 0.
1001
1002 2013-03-04  Andrew Scherkus  <scherkus@chromium.org>
1003
1004         REGRESSION(r142191): Fix closed caption buttons for ports still using the painting path.
1005         https://bugs.webkit.org/show_bug.cgi?id=111109
1006
1007         Reviewed by Eric Carlson.
1008
1009         Covered by following tests:
1010         media/track/track-cue-rendering-horizontal.html
1011         media/track/track-cue-rendering-vertical.html
1012
1013         * rendering/RenderTheme.cpp:
1014         (WebCore::RenderTheme::paint):
1015         * rendering/RenderTheme.h:
1016         (WebCore::RenderTheme::paintMediaToggleClosedCaptionsButton):
1017
1018 2013-03-05  Gwang Yoon Hwang  <ryumiel@company100.net>
1019
1020         Coordinated Graphics: CoordinatedGraphicsLayer makes CoordinatedGraphicsScene perform via CoordinatedGraphicsState.
1021         https://bugs.webkit.org/show_bug.cgi?id=108294
1022
1023         Reviewed by Anders Carlsson.
1024
1025         CoordinatedLayerTreeHostProxy has too many IPC messages (e.g. SyncCanvas and
1026         CreateTile), and there is a long function chain from CoordinatedGraphicsLayer to
1027         CoordinatedGraphicsScene (4 classes).
1028         If we want to add a new message, we need to add similar functions into 4 classes.
1029
1030         Now CoordinatedLayerTreeHost has only one IPC message for CoordinatedGraphicsLayer:
1031         CommitCoordinatedGraphicsState.
1032         CoordinatedGraphicsLayer makes CoordinatedGraphicsScene run as follows:
1033         1. CoordinatedGraphicsLayer makes a CoordinatedGraphicsLayerState.
1034         2. CoordinatedLayerTreeHost stores all LayerStates.
1035         3. CoordinatedLayerTreeHost sends GraphicsState includes LayerStates to CoordinatedLayerTreeHostProxy
1036         at the moment of flushing via CommitCoordinatedGraphicsState message.
1037         4. CoordinatedGraphicsScene applies all state changes to layers.
1038
1039         There is one big behavior change. All states changes (e.g.
1040         UpdateTiles, SetLayerChildren, and etc..) are performed at the same time, when
1041         CoordinatedGraphicsScene::commitCoordinatedGraphicsState is called.
1042
1043         This patch is based on Dongsung Huang, and Noam's work in
1044         https://bugs.webkit.org/show_bug.cgi?id=108294
1045
1046         No new tests, covered by existing tests.
1047
1048         * Target.pri:
1049         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
1050         (WebCore::CoordinatedGraphicsLayer::setPosition):
1051         (WebCore::CoordinatedGraphicsLayer::setAnchorPoint):
1052         (WebCore::CoordinatedGraphicsLayer::setSize):
1053         (WebCore::CoordinatedGraphicsLayer::setTransform):
1054         (WebCore::CoordinatedGraphicsLayer::setChildrenTransform):
1055         (WebCore::CoordinatedGraphicsLayer::setPreserves3D):
1056         (WebCore::CoordinatedGraphicsLayer::setMasksToBounds):
1057         (WebCore::CoordinatedGraphicsLayer::setDrawsContent):
1058         (WebCore::CoordinatedGraphicsLayer::setContentsVisible):
1059         (WebCore::CoordinatedGraphicsLayer::setContentsOpaque):
1060         (WebCore::CoordinatedGraphicsLayer::setBackfaceVisibility):
1061         (WebCore::CoordinatedGraphicsLayer::setOpacity):
1062         (WebCore::CoordinatedGraphicsLayer::setContentsRect):
1063         (WebCore::CoordinatedGraphicsLayer::setFilters):
1064         (WebCore::CoordinatedGraphicsLayer::setContentsToSolidColor):
1065         (WebCore::CoordinatedGraphicsLayer::setShowDebugBorder):
1066         (WebCore::CoordinatedGraphicsLayer::setShowRepaintCounter):
1067         (WebCore::CoordinatedGraphicsLayer::setMaskLayer):
1068         (WebCore::CoordinatedGraphicsLayer::setReplicatedByLayer):
1069         (WebCore::CoordinatedGraphicsLayer::setFixedToViewport):
1070         (WebCore::CoordinatedGraphicsLayer::syncChildren):
1071         (WebCore::CoordinatedGraphicsLayer::syncFilters):
1072         (WebCore::CoordinatedGraphicsLayer::syncImageBacking):
1073         (WebCore::CoordinatedGraphicsLayer::syncLayerState):
1074         (WebCore::CoordinatedGraphicsLayer::setDebugBorder):
1075         (WebCore::CoordinatedGraphicsLayer::syncAnimations):
1076         (WebCore::CoordinatedGraphicsLayer::syncCanvas):
1077         (WebCore::CoordinatedGraphicsLayer::destroyCanvasIfNeeded):
1078         (WebCore::CoordinatedGraphicsLayer::createCanvasIfNeeded):
1079         (WebCore::CoordinatedGraphicsLayer::flushCompositingStateForThisLayerOnly):
1080         (WebCore::CoordinatedGraphicsLayer::resetLayerState):
1081         (WebCore):
1082         (WebCore::CoordinatedGraphicsLayer::releaseImageBackingIfNeeded):
1083         (WebCore::CoordinatedGraphicsLayer::setRootLayer):
1084         (WebCore::CoordinatedGraphicsLayer::tiledBackingStorePaintEnd):
1085         (WebCore::CoordinatedGraphicsLayer::createTile):
1086         (WebCore::CoordinatedGraphicsLayer::updateTile):
1087         (WebCore::CoordinatedGraphicsLayer::removeTile):
1088         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
1089         (CoordinatedGraphicsLayerClient):
1090         (CoordinatedGraphicsLayer):
1091         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
1092         (WebCore::CoordinatedGraphicsScene::createCanvasIfNeeded):
1093         (WebCore::CoordinatedGraphicsScene::syncCanvasIfNeeded):
1094         (WebCore::CoordinatedGraphicsScene::destroyCanvasIfNeeded):
1095         (WebCore::CoordinatedGraphicsScene::setLayerRepaintCountIfNeeded):
1096         (WebCore::CoordinatedGraphicsScene::setLayerChildrenIfNeeded):
1097         (WebCore::CoordinatedGraphicsScene::setLayerFiltersIfNeeded):
1098         (WebCore::CoordinatedGraphicsScene::setLayerState):
1099         (WebCore::CoordinatedGraphicsScene::deleteLayer):
1100         (WebCore::CoordinatedGraphicsScene::createTilesIfNeeded):
1101         (WebCore::CoordinatedGraphicsScene::removeTilesIfNeeded):
1102         (WebCore::CoordinatedGraphicsScene::updateTilesIfNeeded):
1103         (WebCore::CoordinatedGraphicsScene::assignImageBackingToLayer):
1104         (WebCore::CoordinatedGraphicsScene::commitSceneState):
1105         (WebCore::CoordinatedGraphicsScene::setLayerAnimationsIfNeeded):
1106         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
1107         (WebCore):
1108         (CoordinatedGraphicsScene):
1109         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h: Added.
1110         (WebCore):
1111         (TileUpdateInfo):
1112         (TileCreationInfo):
1113         (WebCore::CoordinatedGraphicsLayerState::CoordinatedGraphicsLayerState):
1114         (CoordinatedGraphicsLayerState):
1115         (CoordinatedGraphicsState):
1116         * platform/graphics/texmap/coordinated/CoordinatedImageBacking.h:
1117         * platform/graphics/texmap/coordinated/CoordinatedLayerInfo.h: Removed.
1118         * platform/graphics/texmap/coordinated/SurfaceUpdateInfo.h:
1119
1120 2013-03-05  Roger Fong  <roger_fong@apple.com>
1121
1122         Unreviewed. AppleWin VS2010 build fix.
1123
1124         * WebCore.vcxproj/WebCore.vcxproj:
1125         * WebCore.vcxproj/WebCore.vcxproj.filters:
1126         * rendering/RenderingAllInOne.cpp:
1127
1128 2013-03-05  Bem Jones-Bey  <bjonesbe@adobe.com>
1129
1130         [CSS Exclusions] shape-outside on floats for polygon shapes
1131         https://bugs.webkit.org/show_bug.cgi?id=98676
1132
1133         Reviewed by David Hyatt.
1134
1135         Implement support for polygonal shape-outside on floats. The basic
1136         tack taken here is to keep using the bounding box of the shape to
1137         position the float, but to compute the offset (caused by the shape)
1138         from the bounding box for each line when creating and positioning
1139         other inline content.
1140
1141         Test: fast/exclusions/shape-outside-floats/shape-outside-floats-simple-polygon.html
1142
1143         * rendering/ExclusionShapeInfo.cpp:
1144         (WebCore):
1145         (WebCore::::computedShape): Add new template parameter.
1146         (WebCore::::logicalTopOffset): Add new template parameter.
1147         (WebCore::::computeSegmentsForLine): Move here from
1148             ExclusionShapeInsideInfo, since ExclusionShapeOutsideInfo needs it
1149             as well. Make virtual since there is slightly different behavior
1150             between each class even though the vast majority of the code is
1151             common.
1152         * rendering/ExclusionShapeInfo.h:
1153         (WebCore):
1154         (WebCore::ExclusionShapeInfo::~ExclusionShapeInfo): Since
1155             computeSegmentsForLine is virtual, the destructor must be virtual
1156             as well.
1157         (ExclusionShapeInfo): Add new data members to support
1158             computeSegmentsForLine.
1159         (WebCore::ExclusionShapeInfo::shapeLogicalRight): Fix bug, the logical
1160             right is based off of maxX, not y. (it's a logical bounding box!)
1161         (WebCore::ExclusionShapeInfo::logicalLineTop): Moved from
1162             ExclusionShapeInsideInfo for use by computeSegmentsForLine and
1163             lineOverlapsShapeBounds.
1164         (WebCore::ExclusionShapeInfo::logicalLineBottom): Moved from
1165             ExclusionShapeInsideInfo for use by computeSegmentsForLine and
1166             lineOverlapsShapeBounds.
1167         (WebCore::ExclusionShapeInfo::lineOverlapsShapeBounds): Moved from
1168             ExclusionShapeInsideInfo for use by computeSegmentsForLine.
1169         * rendering/ExclusionShapeInsideInfo.cpp: Moved common code from
1170             computeSegmentsForLine into ExclusionShapeInfo.
1171         * rendering/ExclusionShapeInsideInfo.h:
1172         (WebCore): Moved some methods to ExclusionShapeInfo.
1173         (ExclusionShapeInsideInfo): Update for new template parameter.
1174         (WebCore::ExclusionShapeInsideInfo::compyteSegmentsForLine): Override
1175             superclass method to clear the segment ranges. Segement ranges
1176             aren't used by shape outside, and have some complex dependencies
1177             that make it very hard to try and move up into ExclusionShapeInfo.
1178         (WebCore::ExclusionShapeInsideInfo::ExclusionShapeInsideInfo): Update
1179             for new template parameter.
1180         * rendering/ExclusionShapeOutsideInfo.cpp:
1181         (WebCore::ExclusionShapeOutsideInfo::isEnabledFor): Add polygons as a
1182             supported shape.
1183         (WebCore::ExclusionShapeOutsideInfo::computeSegmentsForLine): Override
1184             superclass method to not recompute if it isn't needed (this isn't
1185             straightfoward for shape inside, which is why it isn't common),
1186             and to save the left and right offsets caused by the shape
1187             outside, since that's all that is needed to properly do layout in
1188             the case of floats.
1189         * rendering/ExclusionShapeOutsideInfo.h:
1190         (WebCore::ExclusionShapeOutsideInfo::shapeLogicalOffset): Reformat to
1191             be on a single line, like most other methods of it's type in
1192             WebKit headers.
1193         (ExclusionShapeOutsideInfo): Update for new template parameter.
1194         (WebCore::ExclusionShapeOutsideInfo::logicalLeftOffsetForLine):
1195             Accessor method to get the left offset between the shape and the
1196             shape's bounding box.
1197         (WebCore::ExclusionShapeOutsideInfo::logicalRightOffsetForLine):
1198             Accessor method to get the left offset between the shape and the
1199             shape's bounding box.
1200         (WebCore::ExclusionShapeOutsideInfo::ExclusionShapeOutsideInfo):
1201             Update for new template parameter.
1202         * rendering/RenderBlock.cpp:
1203         (WebCore::::collectIfNeeded): Save the last float encountered so that
1204             the shape outside offset can be accounted for.
1205         (WebCore::RenderBlock::logicalLeftOffsetForLine): Account for the
1206             shape outside offset on the outermost float.
1207         (WebCore::RenderBlock::logicalRightOffsetForLine): Account for the
1208             shape outside offset on the outermost float.
1209         * rendering/RenderBlock.h:
1210         (WebCore::RenderBlock::FloatIntervalSearchAdapter::FloatIntervalSearchAdapter):
1211             Initialize the lastFloat member.
1212         (WebCore::RenderBlock::FloatIntervalSearchAdapter::lastFloat): Get the
1213             last float encountered.
1214         (FloatIntervalSearchAdapter): Add a pointer to the last float
1215             encountered. Note that the variable is mutable because
1216             collectIfNeeded is declared as a const method even though it isn't
1217             (it uses loopholes to update m_offset and m_heightRemaining).
1218             Instead of trying to come up with a hack to stick with the
1219             loopholes, I decided to be explicit about it.
1220         * rendering/RenderBlockLineLayout.cpp:
1221         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded): Take
1222             into account the offset from any polygonal shape outside.
1223         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak): Add a FIXME
1224             because the current code will not work properly with stacked
1225             floats that have polygonal shape outside.
1226
1227 2013-03-04  David Hyatt  <hyatt@apple.com>
1228
1229         [New Multicolumn] Autogenerate regions for columns.
1230         https://bugs.webkit.org/show_bug.cgi?id=111363
1231
1232         Reviewed by Dean Jackson.
1233
1234         In CSS Regions, we lay out the regions first, and then
1235         we put the flow thread into the regions. This model doesn't
1236         really work for multicolumn layout, which needs to be able
1237         to auto-generate new regions lazily in response to the flow
1238         thread asking for regions at particular offsets.
1239
1240         With the multi-column model, where the regions can't just occur
1241         anywhere, its ok not to lay them out before the flow thread, as
1242         long as we have at least given them the correct size.
1243         
1244         This patch changes the layout algorithm for columns to:
1245         (1) Size any existing regions (without worrying about placement).
1246         (2) Lay out the flow thread (generating and sizing regions lazily
1247         that need to be created).
1248         (3) Lay out the regions (to give them correct placement and to
1249         compute overflow correctly for the multi-column block that contains
1250         the regions).
1251
1252         There are no new tests, since there are no behavioral changes. This
1253         is just groundwork for being able to add new sets in response to
1254         spans, balancing, and nested pagination contexts.
1255
1256         * rendering/RenderBlock.cpp:
1257         (WebCore::RenderBlock::determineLogicalLeftPositionForChild):
1258         (WebCore::RenderBlock::layoutBlockChild):
1259         * rendering/RenderBlock.h:
1260         (RenderBlock):
1261         Since we want to be able to call determineLogicalLeftPositionForChild
1262         to place the flow thread properly, and we don't want to apply a layout
1263         delta (flow threads repaint themselves), we parameterize the method
1264         here so that it can be called without applying a layout delta.
1265         
1266         * rendering/RenderFlowThread.cpp:
1267         (WebCore::RenderFlowThread::addRegionToThread):
1268         (WebCore::RenderFlowThread::removeRegionFromThread):
1269         These methods are only used by RenderMultiColumnFlowThread, since
1270         RenderNamedFlowThread overrides them. Remove the code that invalidates
1271         the flow threads region set as regions come and go, since that is now
1272         going to be expected with auto-generation.
1273
1274         (WebCore::RenderFlowThread::validateRegions):
1275         Refactor the code in RenderFlowThread::layout that validates the regions
1276         into its own method, so that we can re-validate regions at any time
1277         after generating new ones.
1278         
1279         (WebCore::RenderFlowThread::layout):
1280         Changed to move the region validation code into its own function that is
1281         now called from here.
1282
1283         (WebCore::RenderFlowThread::updateLogicalWidth):
1284         Don't assert if a region set needs layout.
1285
1286         (WebCore::RenderFlowThread::computeLogicalHeight):
1287         Ditto. Don't assert if a region set needs layout. That's expected now.
1288
1289         (WebCore::RenderFlowThread::regionAtBlockOffset):
1290         Add code to regionAtBlockOffset to auto-generate regions up to
1291         the offset. This ensures the region that is being asked for
1292         exists.
1293
1294         (WebCore::RenderFlowThread::pageLogicalTopForOffset):
1295         (WebCore::RenderFlowThread::pageLogicalWidthForOffset):
1296         (WebCore::RenderFlowThread::pageLogicalHeightForOffset):
1297         (WebCore::RenderFlowThread::pageRemainingLogicalHeightForOffset):
1298         These functions are no longer const, since the act of asking for
1299         pagination offsets can cause us to generate new regions.
1300
1301         (WebCore::RenderFlowThread::mapFromFlowToRegion):
1302         Modified to turn auto-generation off, since this is not really
1303         a "layout-time" function.
1304
1305         (WebCore::RenderFlowThread::logicalWidthChangedInRegions):
1306         Modified to not assert if a region set needs layout, since that is
1307         expected now.
1308
1309         * rendering/RenderFlowThread.h:
1310         Changes to remove const from the methods that can trigger region
1311         auto-generation.
1312
1313         * rendering/RenderMultiColumnBlock.cpp:
1314         (WebCore::RenderMultiColumnBlock::styleDidChange):
1315         Make sure to propagate style changes down into the regions. I don't know
1316         of any correctness bugs around this, but I figured I'd be thorough.
1317
1318         (WebCore::RenderMultiColumnBlock::checkForPaginationLogicalHeightChange):
1319         We no longer build a column set aggressively. We wait for the flow thread
1320         to ask us for a region at a particular offset, and only then do we
1321         build the set.
1322         
1323         (WebCore::RenderMultiColumnBlock::addChild):
1324         Now that we lay out the flow thread as a special excluded child, we don't
1325         care about the ordering of it relative to the region children.
1326
1327         (WebCore::RenderMultiColumnBlock::layoutSpecialExcludedChild):
1328         We now lay out the flow thread as a special excluded child (like the legend
1329         of a fieldset).
1330
1331         * rendering/RenderMultiColumnBlock.h:
1332         (RenderMultiColumnBlock):
1333         Add new overrides like layoutSpecialExcludedChild.
1334         
1335         * rendering/RenderMultiColumnFlowThread.cpp:
1336         (WebCore::RenderMultiColumnFlowThread::initialLogicalWidth):
1337         Set the flow thread to the initial column width even when no regions exist
1338         yet. This way we ensure the width is right even when we don't have any
1339         regions yet.
1340
1341         (WebCore::RenderMultiColumnFlowThread::autoGenerateRegionsToBlockOffset):
1342         This method handles autogenerating the new region for a given offset.
1343         Right now it's simplistic, since we only have one column set. This method
1344         will be enhanced in future patches when we start supporting multiple column
1345         sets.
1346
1347         * rendering/RenderMultiColumnFlowThread.h:
1348         (RenderMultiColumnFlowThread):
1349         Adding new method declarations like autoGenerateRegionsToBlockOffset.
1350
1351         * rendering/RenderMultiColumnSet.cpp:
1352         (WebCore::RenderMultiColumnSet::updateLogicalWidth):
1353         Since regions lay out after flow threads, we don't need to make 
1354         setFlowThreadPortionRect virtual any longer. We can just get our column set's
1355         width correct immediately. This is the same logic, just moved into updateLogicalWidth().
1356
1357         * rendering/RenderMultiColumnSet.h:
1358         Remove setFlowThreadPortionRect override, since the function can just be simple
1359         and non-virtual in RenderRegion now.
1360
1361         * rendering/RenderRegion.cpp:
1362         (WebCore::RenderRegion::layoutBlock):
1363         Don't ever invalidate region sets in response to our size changing during layout. Since
1364         our size is always determined outside of layout now, we don't need to do any of
1365         these checks.
1366
1367         * rendering/RenderRegion.h:
1368         (WebCore::RenderRegion::setFlowThreadPortionRect):
1369         Changed to be non-virtual now that RenderMultiColumnSet doesn't need to override.
1370
1371 2013-03-04  Alexey Proskuryakov  <ap@apple.com>
1372
1373         Make AsyncFileReader work without ScriptExecutionContext
1374         https://bugs.webkit.org/show_bug.cgi?id=111376
1375
1376         Reviewed by Anders Carlsson.
1377
1378         * WebCore.xcodeproj/project.pbxproj: Added MainThreadTask.h.
1379
1380         * dom/ScriptExecutionContext.cpp:
1381         * dom/ScriptExecutionContext.h:
1382         Removed fileThread(). Creating a thread for every context that acesses files appears
1383         wasteful and unnecessary.
1384
1385         * fileapi/AsyncFileStream.h:
1386         * fileapi/AsyncFileStream.cpp:
1387         (WebCore::createFileThread): FileThread is now a singleton.
1388         (WebCore::fileThread): Ditto.
1389         (WebCore::AsyncFileStream::AsyncFileStream):
1390         (WebCore::AsyncFileStream::create):
1391         (WebCore::didStart):
1392         (WebCore::AsyncFileStream::startOnFileThread):
1393         (WebCore::AsyncFileStream::stop):
1394         (WebCore::derefProxyOnMainThread):
1395         (WebCore::AsyncFileStream::stopOnFileThread):
1396         (WebCore::didGetSize):
1397         (WebCore::AsyncFileStream::getSizeOnFileThread):
1398         (WebCore::didOpen):
1399         (WebCore::AsyncFileStream::openForReadOnFileThread):
1400         (WebCore::AsyncFileStream::openForWriteOnFileThread):
1401         (WebCore::didRead):
1402         (WebCore::AsyncFileStream::readOnFileThread):
1403         (WebCore::didWrite):
1404         (WebCore::AsyncFileStream::writeOnFileThread):
1405         (WebCore::didTruncate):
1406         (WebCore::AsyncFileStream::truncateOnFileThread):
1407         Use callOnMainThread() instead of posting messages through a context. We never used
1408         other threads, and don't plan to.
1409
1410         * loader/ResourceLoader.cpp:
1411         * loader/ResourceLoader.h:
1412         We no longer need this pseudo-client call to create an AsyncFileStream, now that
1413         we don't need to get a ScriptExecutionContext somewhere.
1414
1415         * platform/MainThreadTask.h: Added. This implements callOnMainThread with multiple
1416         strongly typed arguments. Closely based on CrossThreadTask.h.
1417
1418         * platform/network/BlobResourceHandle.cpp:
1419         (WebCore::BlobResourceHandle::BlobResourceHandle): Create AsyncFileStream directly.
1420
1421         * platform/network/ResourceHandleClient.h: Removed createAsyncFileStream().
1422
1423 2013-03-05  Jessie Berlin  <jberlin@apple.com>
1424
1425         Update the localizable strings file.
1426
1427         Rubber-stamped by Anders Carlsson.
1428
1429         * English.lproj/Localizable.strings:
1430
1431 2013-03-05  Chris Fleizach  <cfleizach@apple.com>
1432
1433         AX: aria-label does not override text content on iOS
1434         https://bugs.webkit.org/show_bug.cgi?id=111222
1435
1436         Reviewed by David Kilzer.
1437
1438         Make iOS use the same text alternative computation that Mac is using. The main difference
1439         is that description and title need to be concatenated, because iOS doesn't have two attributes
1440         to return those values.
1441
1442         Test: platform/iphone-simulator/accessibility/aria-label-with-internal-text.html
1443
1444         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1445         (-[WebAccessibilityObjectWrapper stringValueShouldBeUsedInLabel]):
1446         (-[WebAccessibilityObjectWrapper accessibilityLabel]):
1447         (-[WebAccessibilityObjectWrapper accessibilityHint]):
1448         * accessibility/mac/WebAccessibilityObjectWrapperBase.h:
1449
1450 2013-03-05  David Kilzer  <ddkilzer@apple.com>
1451
1452         BUILD FIX (r144698): Only enable SPEECH_SYNTHESIS for Mac
1453         <http://webkit.org/b/106742>
1454
1455         Fixes the following build failures:
1456
1457             Undefined symbols for architecture i386:
1458               "__ZTVN7WebCore25PlatformSpeechSynthesizerE", referenced from:
1459                   __ZN7WebCore25PlatformSpeechSynthesizerC2EPNS_31PlatformSpeechSynthesizerClientE in PlatformSpeechSynthesizer.o
1460               NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
1461               "__ZN7WebCore25PlatformSpeechSynthesizer19initializeVoiceListEv", referenced from:
1462                   __ZN7WebCore25PlatformSpeechSynthesizerC2EPNS_31PlatformSpeechSynthesizerClientE in PlatformSpeechSynthesizer.o
1463             ld: symbol(s) not found for architecture i386
1464
1465         * Configurations/FeatureDefines.xcconfig:
1466         - Only set ENABLE_SPEECH_SYNTHESIS for the macosx platform.
1467
1468 2013-03-05  Dmitry Zvorygin  <zvorygin@chromium.org>
1469
1470         Web Inspector: registered new MIME type application/font-woff for WOFF fonts.
1471         https://bugs.webkit.org/show_bug.cgi?id=111418
1472
1473         The WOFF MIME Type was formally registered as application/font-woff (FINALLY):
1474         http://www.iana.org/assignments/media-types/application/font-woff
1475
1476         Reviewed by Pavel Feldman.
1477
1478         * inspector/front-end/NetworkManager.js:
1479         (WebInspector.NetworkManager):
1480         (WebInspector.NetworkDispatcher.prototype._updateNetworkRequestWithResponse):
1481
1482 2013-03-05  Julien Chaffraix  <jchaffraix@webkit.org>
1483
1484         [CSS Grid Layout] Add parsing for grid-{end|after}
1485         https://bugs.webkit.org/show_bug.cgi?id=111372
1486
1487         Reviewed by Tony Chang.
1488
1489         Test: fast/css-grid-layout/grid-item-end-after-get-set.html
1490
1491         This change adds the proper support for grid-{end|after}. It doesn't update
1492         grid-{row|column} to be a shorthand for both grid-{before|start} and grid-{after|end}
1493         though.
1494
1495         * css/CSSComputedStyleDeclaration.cpp:
1496         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1497         Added the new properties to our known properties. Also added
1498         support for getComputedStyle.
1499
1500         * css/CSSParser.cpp:
1501         (WebCore::CSSParser::parseValue):
1502         Added parsing for the new properties.
1503
1504         * css/CSSProperty.cpp:
1505         (WebCore::CSSProperty::isInheritedProperty):
1506         The new properties are not inherited.
1507
1508         * css/CSSPropertyNames.in:
1509         Added the new properties.
1510
1511         * css/StyleResolver.cpp:
1512         (WebCore::StyleResolver::applyProperty):
1513         Added code to handle applying them to our style.
1514
1515         * rendering/style/RenderStyle.h:
1516         * rendering/style/StyleGridItemData.cpp:
1517         (WebCore::StyleGridItemData::StyleGridItemData):
1518         * rendering/style/StyleGridItemData.h:
1519         (WebCore::StyleGridItemData::operator==):
1520         (StyleGridItemData):
1521         Updated our representation to store the new properties.
1522
1523 2013-03-05  Andrey Kosyakov  <caseq@chromium.org>
1524
1525         Unreviewed follow-up to r144756, fix broken inspector-less build.
1526
1527         * inspector/InspectorInstrumentation.h:
1528         (WebCore::InspectorInstrumentation::willWriteHTML):
1529
1530 2013-03-05  Mark Lam  <mark.lam@apple.com>
1531
1532         Improve robustness of WebSQL quota management.
1533         https://bugs.webkit.org/show_bug.cgi?id=110600.
1534
1535         Reviewed by Geoffrey Garen.
1536
1537         1. Introduced the OriginLock for synchronizing write access to the
1538            database origin directory. This allows us to more accurately
1539            compute the disk usage.
1540
1541            The OriginLock uses a mutex to provide mutual exclusion between
1542            threads and a file lock for mutual exclusion between processes.
1543            The file lock part is conditional on USE(FILE_LOCK).
1544
1545            The mutex mutual exclusion also serves to ensure that only 1 thread
1546            can write to a sqlite database at one time.
1547
1548         2. Change the SQLTransactionCoordinator to only allow one write
1549            transaction to an origin instead of one write transaction per
1550            database. This is needed in order to accurately compute the
1551            disk usage. It is also necessary so that the OriginLock does not
1552            deadlock itself (as would be the case if concurrent write transactions
1553            to different databases in the same origin are allowed).
1554
1555         3. Fix DatabaseTracker::getMaxSizeForDatabase() to check for when
1556            disk usage may exceed the quota, and ensure that we will return
1557            an appropriate max database size.
1558
1559            Disk usage can exceed the usage if it is already near the quota limit
1560            but have not exceeded it yet. If a new database is opened in that
1561            origin, it may bump the usage above the quota, but should not
1562            continually repeat this. Subsequent attempts to open a database
1563            will find that the quota is already exhausted and fail.
1564
1565            There is still a race condition pertaining to the tracker database
1566            getting out of sync that may still enable runaway growth in the
1567            database sizes. That issue only manifest in a multi-process
1568            environment, and will be fixed in another changeset.
1569
1570         4. Fixed a bug in SQLStatement to check if the errorCallback exists
1571            before invoking it.
1572
1573         No new layout tests. A quota-test.html was attached to bugzilla for manual
1574         testing of multi-tab concurrent consumption of storage resource, and also
1575         to test handling situations when the user deletes the database files while
1576         the script is still using the database.
1577
1578         * CMakeLists.txt:
1579         * GNUmakefile.list.am:
1580         * Modules/webdatabase/DatabaseTracker.cpp:
1581         (WebCore::DatabaseTracker::getMaxSizeForDatabase):
1582         (WebCore::DatabaseTracker::originLockFor):
1583         (WebCore::DatabaseTracker::deleteOriginLockFor):
1584         (WebCore::DatabaseTracker::deleteOrigin):
1585         * Modules/webdatabase/DatabaseTracker.h:
1586         * Modules/webdatabase/OriginLock.cpp: Added.
1587         (WebCore::OriginLock::lockFileNameForPath):
1588         (WebCore::OriginLock::OriginLock):
1589         (WebCore::OriginLock::~OriginLock):
1590         (WebCore::OriginLock::lock):
1591         (WebCore::OriginLock::unlock):
1592         * Modules/webdatabase/OriginLock.h: Added.
1593         * Modules/webdatabase/SQLStatement.cpp:
1594         (WebCore::SQLStatement::performCallback):
1595         * Modules/webdatabase/SQLTransactionBackend.cpp:
1596         (WebCore::SQLTransactionBackend::doCleanup):
1597         (WebCore::SQLTransactionBackend::computeNextStateAndCleanupIfNeeded):
1598         (WebCore::SQLTransactionBackend::openTransactionAndPreflight):
1599         (WebCore::SQLTransactionBackend::postflightAndCommit):
1600         (WebCore::SQLTransactionBackend::cleanupAfterTransactionErrorCallback):
1601         (WebCore::SQLTransactionBackend::acquireOriginLock):
1602         (WebCore::SQLTransactionBackend::releaseOriginLockIfNeeded):
1603         * Modules/webdatabase/SQLTransactionBackend.h:
1604         (SQLTransactionBackend):
1605         * Modules/webdatabase/SQLTransactionCoordinator.cpp:
1606         (WebCore::getDatabaseIdentifier):
1607         * Target.pri:
1608         * WebCore.gypi:
1609         * WebCore.vcproj/WebCore.vcproj:
1610         * WebCore.vcxproj/WebCore.vcxproj:
1611         * WebCore.vcxproj/WebCore.vcxproj.filters:
1612         * WebCore.xcodeproj/project.pbxproj:
1613         * config.h:
1614         * platform/FileSystem.h:
1615         * platform/posix/FileSystemPOSIX.cpp:
1616         (WebCore::lockFile):
1617         (WebCore::unlockFile):
1618
1619 2013-03-05  Ilya Tikhonovsky  <loislo@chromium.org>
1620
1621         Web Inspector: move PopoverContentHelper from TimelinePresentationModel.js to Popover.js.
1622         https://bugs.webkit.org/show_bug.cgi?id=111431
1623
1624         Reviewed by Yury Semikhatsky.
1625
1626         class WebInspector.TimelinePresentationModel.PopoverContentHelper was renamed to WebInspector.PopoverContentHelper.
1627         Style names were changed accordingly.
1628
1629         * inspector/front-end/Popover.js:
1630         (WebInspector.PopoverContentHelper):
1631         (WebInspector.PopoverContentHelper.prototype.contentTable):
1632         (WebInspector.PopoverContentHelper.prototype._createCell):
1633         (WebInspector.PopoverContentHelper.prototype.appendTextRow):
1634         (WebInspector.PopoverContentHelper.prototype.appendElementRow):
1635         (WebInspector.PopoverContentHelper.prototype.appendStackTrace):
1636         * inspector/front-end/TimelinePresentationModel.js:
1637         (WebInspector.TimelinePresentationModel.prototype.generateMainThreadBarPopupContent):
1638         (WebInspector.TimelinePresentationModel.Record.prototype._generatePopupContentWithImagePreview):
1639         (WebInspector.TimelinePresentationModel.generatePopupContentForFrame):
1640         (WebInspector.TimelinePresentationModel.generatePopupContentForFrameStatistics):
1641         * inspector/front-end/popover.css:
1642         (.popover-details):
1643         (.popover-function-name):
1644         (.popover-stacktrace-title):
1645         (.popover-details-row-title):
1646         (.popover-details-row-data):
1647         (.popover-details-title):
1648         * inspector/front-end/timelinePanel.css:
1649
1650 2013-03-05  Yury Semikhatsky  <yurys@chromium.org>
1651
1652         Web Inspector: remove "Live native memory chart" experiment
1653         https://bugs.webkit.org/show_bug.cgi?id=111432
1654
1655         Reviewed by Alexander Pavlov.
1656
1657         Removed support for live native memory chart.
1658
1659         * English.lproj/localizedStrings.js:
1660         * inspector/front-end/NativeMemorySnapshotView.js:
1661         * inspector/front-end/ProfileLauncherView.js:
1662         (WebInspector.ProfileLauncherView):
1663         * inspector/front-end/ProfilesPanel.js:
1664         (WebInspector.ProfilesPanel):
1665         * inspector/front-end/Settings.js:
1666         (WebInspector.ExperimentsSettings):
1667         * inspector/front-end/nativeMemoryProfiler.css:
1668
1669 2013-03-05  Andrey Kosyakov  <caseq@chromium.org>
1670
1671         Web Inspector: remove length parameter from Parse HTML timeline event
1672         https://bugs.webkit.org/show_bug.cgi?id=111421
1673
1674         Reviewed by Yury Semikhatsky.
1675
1676         - remove length parameter in all instrumentation methods used to emit ParseHTML timeline event;
1677         - drive-by style fixes.
1678
1679         * html/parser/HTMLDocumentParser.cpp:
1680         (WebCore::HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser):
1681         (WebCore::HTMLDocumentParser::pumpPendingSpeculations):
1682         (WebCore::HTMLDocumentParser::pumpTokenizer):
1683         * inspector/InspectorInstrumentation.cpp:
1684         (WebCore):
1685         (WebCore::InspectorInstrumentation::willWriteHTMLImpl):
1686         (WebCore::InspectorInstrumentation::didWriteHTMLImpl):
1687         * inspector/InspectorInstrumentation.h:
1688         (InspectorInstrumentation):
1689         (WebCore::InspectorInstrumentation::willWriteHTML):
1690         (WebCore::InspectorInstrumentation::didWriteHTML):
1691         * inspector/InspectorTimelineAgent.cpp:
1692         (WebCore::InspectorTimelineAgent::willWriteHTML):
1693         (WebCore::InspectorTimelineAgent::didWriteHTML):
1694         * inspector/InspectorTimelineAgent.h:
1695         (InspectorTimelineAgent):
1696         * inspector/TimelineRecordFactory.cpp:
1697         (WebCore::TimelineRecordFactory::createParseHTMLData):
1698         * inspector/TimelineRecordFactory.h:
1699         (TimelineRecordFactory):
1700
1701 2013-03-05  Alexei Filippov  <alph@chromium.org>
1702
1703         Web Inspector: allow each profiler panel to have own landing page
1704         https://bugs.webkit.org/show_bug.cgi?id=111298
1705
1706         Reviewed by Yury Semikhatsky.
1707
1708         Refactor profiler landing page to allow different profiler panels to have own landing pages.
1709           - MultiProfileLauncherView is inherited from ProfileLauncherView
1710           - Native memory distribution profiler has got a custom page.
1711
1712         No new tests: code refactoring.
1713
1714         * inspector/front-end/HeapSnapshotView.js:
1715         (WebInspector.HeapSnapshotView.prototype.get profile):
1716         (WebInspector.HeapSnapshotView.prototype.get baseProfile):
1717         (WebInspector.HeapSnapshotView.prototype._profiles):
1718         * inspector/front-end/NativeMemorySnapshotView.js:
1719         * inspector/front-end/ProfileLauncherView.js:
1720         (WebInspector.ProfileLauncherView):
1721         (WebInspector.ProfileLauncherView.prototype.addProfileType):
1722         (WebInspector.ProfileLauncherView.prototype._controlButtonClicked):
1723         (WebInspector.ProfileLauncherView.prototype._updateControls):
1724         (WebInspector.ProfileLauncherView.prototype.profileStarted):
1725         (WebInspector.ProfileLauncherView.prototype.profileFinished):
1726         (WebInspector.MultiProfileLauncherView):
1727         (WebInspector.MultiProfileLauncherView.prototype.addProfileType):
1728         (WebInspector.MultiProfileLauncherView.prototype._profileTypeChanged):
1729         (WebInspector.NativeProfileLauncherView):
1730         * inspector/front-end/ProfilesPanel.js:
1731         (WebInspector.ProfilesPanel):
1732         (WebInspector.ProfilesPanel.prototype._createLauncherView):
1733         (WebInspector.CPUProfilerPanel):
1734         (WebInspector.CSSSelectorProfilerPanel):
1735         (WebInspector.HeapProfilerPanel):
1736         (WebInspector.CanvasProfilerPanel):
1737         (WebInspector.MemoryChartProfilerPanel):
1738         (WebInspector.MemoryChartProfilerPanel.prototype._createLauncherView):
1739         (WebInspector.NativeMemoryProfilerPanel):
1740         * inspector/front-end/profilesPanel.css:
1741         (.panel-enabler-view.profile-launcher-view button:not(.status-bar-item)):
1742
1743 2013-03-05  Eugene Klyuchnikov  <eustas@chromium.org>
1744
1745         Web Inspector: Clarify some StylesSidebarPanel and CSSMetadata JSDocs.
1746         https://bugs.webkit.org/show_bug.cgi?id=111427
1747
1748         Reviewed by Alexander Pavlov.
1749
1750         Goal: reflect in JSDoc that non-null array is passed to completionsReady callback.
1751
1752         * inspector/front-end/CSSMetadata.js:
1753         Added JSDocs, avoided possible NPEs.
1754         * inspector/front-end/StylesSidebarPane.js:
1755         Fixed JSDocs, removed unused assignment.
1756
1757 2013-03-05  David Kilzer  <ddkilzer@apple.com>
1758
1759         BUILD FIX (r144727): Change type of columnRange and rowRange to pair<unsigned, unsigned>
1760         <http://webkit.org/b/110050>
1761
1762         Fixes the following build failures:
1763
1764             Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:741:30: error: non-const lvalue reference to type 'pair<unsigned int, unsigned int>' cannot bind to a value of unrelated type 'pair<int, int>'
1765                 tableCell->rowIndexRange(rowRange);
1766                                          ^~~~~~~~
1767             In file included from Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:33:
1768             Source/WebCore/accessibility/AccessibilityTableCell.h:47:58: note: passing argument to parameter 'rowRange' here
1769                 virtual void rowIndexRange(pair<unsigned, unsigned>& rowRange);
1770                                                                      ^
1771             Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:742:33: error: non-const lvalue reference to type 'pair<unsigned int, unsigned int>' cannot bind to a value of unrelated type 'pair<int, int>'
1772                 tableCell->columnIndexRange(columnRange);
1773                                             ^~~~~~~~~~~
1774             In file included from Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:33:
1775             Source/WebCore/accessibility/AccessibilityTableCell.h:49:61: note: passing argument to parameter 'columnRange' here
1776                 virtual void columnIndexRange(pair<unsigned, unsigned>& columnRange);
1777                                                                         ^
1778             Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:804:30: error: non-const lvalue reference to type 'pair<unsigned int, unsigned int>' cannot bind to a value of unrelated type 'pair<int, int>'
1779                 tableCell->rowIndexRange(rowRange);
1780                                          ^~~~~~~~
1781             In file included from Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:33:
1782             Source/WebCore/accessibility/AccessibilityTableCell.h:47:58: note: passing argument to parameter 'rowRange' here
1783                 virtual void rowIndexRange(pair<unsigned, unsigned>& rowRange);
1784                                                                      ^
1785             Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:818:33: error: non-const lvalue reference to type 'pair<unsigned int, unsigned int>' cannot bind to a value of unrelated type 'pair<int, int>'
1786                 tableCell->columnIndexRange(columnRange);
1787                                             ^~~~~~~~~~~
1788             In file included from Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:33:
1789             Source/WebCore/accessibility/AccessibilityTableCell.h:49:61: note: passing argument to parameter 'columnRange' here
1790                 virtual void columnIndexRange(pair<unsigned, unsigned>& columnRange);
1791                                                             ^
1792             4 errors generated.
1793
1794         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1795         (-[WebAccessibilityObjectWrapper accessibilityHeaderElements]):
1796         (-[WebAccessibilityObjectWrapper accessibilityRowRange]):
1797         (-[WebAccessibilityObjectWrapper accessibilityColumnRange]):
1798
1799 2013-03-04  Andrey Kosyakov  <caseq@chromium.org>
1800
1801         Web Inspector: [refactoring] set frame identifiers in timeline records early, do not keep them in event stack
1802         https://bugs.webkit.org/show_bug.cgi?id=111345
1803
1804         Reviewed by Pavel Feldman.
1805
1806         * inspector/InspectorTimelineAgent.cpp:
1807         (WebCore::InspectorTimelineAgent::pushGCEventRecords):
1808         (WebCore::InspectorTimelineAgent::addRecordToTimeline):
1809         (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline):
1810         (WebCore::InspectorTimelineAgent::setFrameIdentifier):
1811         (WebCore):
1812         (WebCore::InspectorTimelineAgent::didCompleteCurrentRecord):
1813         (WebCore::InspectorTimelineAgent::appendRecord):
1814         (WebCore::InspectorTimelineAgent::pushCurrentRecord):
1815         (WebCore::InspectorTimelineAgent::commitFrameRecord):
1816         * inspector/InspectorTimelineAgent.h:
1817         (WebCore::InspectorTimelineAgent::TimelineRecordEntry::TimelineRecordEntry):
1818         (TimelineRecordEntry):
1819         (InspectorTimelineAgent):
1820
1821 2013-03-05  Tommy Widenflycht  <tommyw@google.com>
1822
1823         MediaStream API: Add the getStreamById method on RTCPeerConnection
1824         https://bugs.webkit.org/show_bug.cgi?id=111311
1825
1826         Reviewed by Adam Barth.
1827
1828         Adding the missing method on RTCPeerConnection defined here:
1829         http://dev.w3.org/2011/webrtc/editor/webrtc.html#widl-RTCPeerConnection-getStreamById-MediaStream-DOMString-streamId
1830
1831         Existing tests have been extended to cover patch.
1832
1833         * Modules/mediastream/RTCPeerConnection.cpp:
1834         (WebCore::RTCPeerConnection::getStreamById):
1835         (WebCore):
1836         * Modules/mediastream/RTCPeerConnection.h:
1837         (RTCPeerConnection):
1838         * Modules/mediastream/RTCPeerConnection.idl:
1839         * platform/chromium/support/WebMediaStream.cpp:
1840         (WebKit::WebMediaStream::initialize):
1841         (WebKit):
1842         * platform/mediastream/MediaStreamSource.cpp:
1843         (WebCore::MediaStreamSource::setReadyState):
1844
1845 2013-03-05  Antoine Quint  <graouts@apple.com>
1846
1847         Web Inspector: allow retrieval of composited layers in a given DOM subtree
1848         https://bugs.webkit.org/show_bug.cgi?id=111312
1849
1850         Introduce the LayerTreeAgent.layersForNode(node) method allowing the front-end
1851         to gather all composited layers associated with nodes in the subtree of which
1852         the provided node is the root.
1853
1854         In order to gather the layers in the subtree, we first traverse the node's
1855         renderer's RenderObject hierarchy and whenever we encounter a RenderObject
1856         that has a RenderLayer, we then traverse that renderLayer's RenderLayer
1857         hierarchy. This allows for a quick path through the relevant objects we're
1858         gathering.
1859
1860         Layers gathered will push the node to which they're associated, allowing a
1861         nodeId for this layer to be listed in the Layer object sent to the front-end.
1862         It is crucial to be able to provide a nodeId as well as a layerId for a Layer
1863         object in order to be able to correctly assess mutations in the layer tree.
1864         For instance, it is expected that a node's layer be replaced by a new layer
1865         to represent a slightly different rendering of its content, but the front-end
1866         should be able to represent this layer as an object for which only certain
1867         attributes have changed (like the "paintCount" property).
1868
1869         Layer objects also indicate whether they're associated to a node hosted in a
1870         shadow tree (the optional "isInShadowTree" property) in order for the front-end
1871         to be able to only show this layer if the option to show nodes hosted in shadow
1872         tree is enabled.
1873
1874         Finally, since we're only gathering composited layers, we're removing the
1875         "isLayerComposited" property and removing the optional flag on the "paintCount",
1876         "memory" and "compositedBounds" properties.
1877
1878         Reviewed by Simon Fraser.
1879
1880         Test: inspector-protocol/layers/layers-for-node.html
1881
1882         * inspector/Inspector.json:
1883         * inspector/InspectorLayerTreeAgent.cpp:
1884         (WebCore::InspectorLayerTreeAgent::layersForNode):
1885         (WebCore):
1886         (WebCore::InspectorLayerTreeAgent::gatherLayersUsingRenderObjectHierarchy):
1887         (WebCore::InspectorLayerTreeAgent::gatherLayersUsingRenderLayerHierarchy):
1888         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
1889         (WebCore::InspectorLayerTreeAgent::idForNode):
1890         * inspector/InspectorLayerTreeAgent.h:
1891         (InspectorLayerTreeAgent):
1892
1893 2013-03-04  Andrey Kosyakov  <caseq@chromium.org>
1894
1895         Web Inspector: use timestamps consistent with rest of Timeline in WebSocket events.
1896         https://bugs.webkit.org/show_bug.cgi?id=111344
1897
1898         - create web socket related records in a manner consistent with the rest of timeline.
1899
1900         Reviewed by Pavel Feldman.
1901
1902         * inspector/InspectorTimelineAgent.cpp:
1903         (WebCore::InspectorTimelineAgent::didCreateWebSocket):
1904         (WebCore::InspectorTimelineAgent::willSendWebSocketHandshakeRequest):
1905         (WebCore::InspectorTimelineAgent::didReceiveWebSocketHandshakeResponse):
1906         (WebCore::InspectorTimelineAgent::didDestroyWebSocket):
1907         * inspector/InspectorTimelineAgent.h:
1908         (InspectorTimelineAgent):
1909
1910 2013-03-05  Andrei Bucur  <abucur@adobe.com>
1911
1912         [CSS Regions] Crash when MathML used in CSS Regions
1913         https://bugs.webkit.org/show_bug.cgi?id=110686
1914
1915         Reviewed by David Hyatt.
1916
1917         The MathML blocks trigger a children layout when computing the preferred widths. This happens to determine the preferred
1918         logical heights of the children. When the layout reaches the line boxes computation the preferred width of the containing block
1919         is requested. Because it wasn't computed, the layout of the children is started again to determine the preferred logical heights.
1920         This causes an infinite recursion and triggers a stack overflow.
1921
1922         The patch introduces a new RAII utility class that disables fragmentation when the constructor is called and restores it
1923         on the destructor. This class is used when computing the preferred height for the children of a MathML block.
1924
1925         Test: fast/regions/mathml-crash.html
1926
1927         * rendering/RenderObject.cpp:
1928         (WebCore::RenderObject::setFlowThreadStateIncludingDescendants): Do not cross RenderFlowThread boundaries when updating the flow thread
1929         state flag. The innermost flow threads need to manage their descendants flag values.
1930         * rendering/RenderView.cpp:
1931         (WebCore::FragmentationDisabler::FragmentationDisabler):
1932         (WebCore):
1933         (WebCore::FragmentationDisabler::~FragmentationDisabler):
1934         * rendering/RenderView.h:
1935         (FragmentationDisabler):
1936         (WebCore):
1937         * rendering/mathml/RenderMathMLBlock.cpp:
1938         (WebCore::RenderMathMLBlock::computeChildrenPreferredLogicalHeights):
1939
1940 2013-03-05  Mike West  <mkwst@chromium.org>
1941
1942         Cleanup: Move HitTestLocation and HitTestResult into separate files.
1943         https://bugs.webkit.org/show_bug.cgi?id=111294
1944
1945         Reviewed by Allan Sandfeld Jensen.
1946
1947         HitTestLocation and HitTestResult currently both live in
1948         HitTestResult.h. That makes things more difficult to understand than
1949         they should be, and violates the one-class-one-file principle that
1950         WebKit generally follows. Happily, it's fairly trivial to fix.
1951
1952         This should have no visible change; it's strictly an internal
1953         refactoring. It doesn't even touch any implementation code: we're
1954         just moving bits from one place to another.
1955
1956         * CMakeLists.txt:
1957         * GNUmakefile.list.am:
1958         * Target.pri:
1959         * WebCore.gypi:
1960         * WebCore.vcproj/WebCore.vcproj:
1961         * WebCore.xcodeproj/project.pbxproj:
1962             Hey, look: a new file! Let's add it to six different build systems! :)
1963         * rendering/HitTestLocation.cpp: Added.
1964         (WebCore):
1965         (WebCore::HitTestLocation::HitTestLocation):
1966         (WebCore::HitTestLocation::~HitTestLocation):
1967         (WebCore::HitTestLocation::operator=):
1968         (WebCore::HitTestLocation::move):
1969         (WebCore::HitTestLocation::intersectsRect):
1970         (WebCore::HitTestLocation::intersects):
1971         (WebCore::HitTestLocation::rectForPoint):
1972         * rendering/HitTestLocation.h: Added.
1973         (WebCore):
1974         (HitTestLocation):
1975         (WebCore::HitTestLocation::point):
1976         (WebCore::HitTestLocation::roundedPoint):
1977         (WebCore::HitTestLocation::region):
1978         (WebCore::HitTestLocation::isRectBasedTest):
1979         (WebCore::HitTestLocation::isRectilinear):
1980         (WebCore::HitTestLocation::boundingBox):
1981         (WebCore::HitTestLocation::topPadding):
1982         (WebCore::HitTestLocation::rightPadding):
1983         (WebCore::HitTestLocation::bottomPadding):
1984         (WebCore::HitTestLocation::leftPadding):
1985         (WebCore::HitTestLocation::transformedPoint):
1986         (WebCore::HitTestLocation::transformedRect):
1987         * rendering/HitTestResult.cpp:
1988         * rendering/HitTestResult.h:
1989             Move all this code from HitTestResult.* to HitTestLocation.*.
1990         * rendering/RenderBlock.cpp:
1991             Include HitTestLocation.h.
1992
1993 2013-03-05  Jochen Eisinger  <jochen@chromium.org>
1994
1995         Refactor UserGestureIndicator::Token to be a top-level class
1996         https://bugs.webkit.org/show_bug.cgi?id=111412
1997
1998         Reviewed by Nico Weber.
1999
2000         This will allow for forward declaring the class in a public WebKit
2001         API header. The goal is to enable the embedder to hold on to a
2002         UserGestureToken.
2003
2004         * dom/UserGestureIndicator.cpp:
2005         (WebCore::UserGestureIndicator::UserGestureIndicator):
2006         (WebCore::UserGestureIndicator::currentToken):
2007         * dom/UserGestureIndicator.h:
2008         (UserGestureToken):
2009         (WebCore::UserGestureToken::~UserGestureToken):
2010         (WebCore):
2011         (UserGestureIndicator):
2012         * page/DOMTimer.h:
2013         (DOMTimer):
2014         * page/EventHandler.h:
2015
2016 2013-03-05  Mike West  <mkwst@chromium.org>
2017
2018         Remove redundant code in Document::updateHoverActiveState.
2019         https://bugs.webkit.org/show_bug.cgi?id=111303
2020
2021         Reviewed by Darin Adler.
2022
2023         Document::updateHoverActiveState currently looks for touchrelease events
2024         and explictly clears out the hover state for all nodes between the
2025         currently hovered node and the top of the hover chain. This is actually
2026         redundant with the logic in the rest of the function; we can simplify by
2027         setting the Element* we're working with to 0, which causes the later
2028         loops to do the necessary work.
2029
2030         There should be no web-visible effect from this change; it should simply
2031         make this function less complex.
2032
2033         Extracted from Allan Sandfeld Jensen's original patch to wkbug.com/98168
2034
2035         * dom/Document.cpp:
2036         (WebCore::Document::updateHoverActiveState):
2037             Set innerElementInDocument to 0 rather than walking the hover chain
2038             and clearing it when we see a touchrelease event. The rest of the
2039             code in this function will have the same effect.
2040
2041 2013-03-05  Koji Hara  <kojih@chromium.org>
2042
2043         [V8] Remove unused custom indexedPropertyGetter
2044         https://bugs.webkit.org/show_bug.cgi?id=111409
2045
2046         Reviewed by Kentaro Hara.
2047
2048         Remove unused custom indexedPropertyGetter.
2049         There are 9 custom indexedPropertyGetter, including an unused one(NamedNodeMap).
2050         This commit assures all existing custom indexedPropertyGetter(for V8) are used.
2051
2052         No new tests. Simple refactoring.
2053
2054         * bindings/v8/custom/V8NamedNodeMapCustom.cpp: Remove indexedPropertyGetter
2055
2056 2013-03-05  Hajime Morrita  <morrita@google.com>
2057
2058         ShadowRoot needs guardRef() and guardDeref()
2059         https://bugs.webkit.org/show_bug.cgi?id=109777
2060
2061         Reviewed by Dimitri Glazkov.
2062
2063         This change moves m_guardRefCount from Document to TreeScope,
2064         which allows ShadowRoot to be guarded by guardRef() mechanism as
2065         Document. After r137524, Node referes TreeScope instead of
2066         Document. This is natural consequence of the change: It no longer
2067         makes sense to guardRef() Document pointer from Node.
2068
2069         Detail:
2070
2071         - Document::m_guardRefCount and related funcdtions are moved to TreeScope
2072         - Document::removedLastRef is factored out into TreeScope::removedLastRefToScope(),
2073           TreeScope::dispose() and Docuent::dispose(). ShadowRoot also got its own dispose() implementation.
2074         - Moved guardRef() and guardDeref() calls to TreeScope and Node.
2075           Note that there are two "guarded" TreeScope references. One is
2076           Node::m_treeScope and another is TreeScope::m_parentTreeScope.
2077           The guarded-ref management is now encapsulated in these two classes.
2078
2079         No new tests. Covered by existing tests.
2080
2081         * WebCore.exp.in:
2082         * dom/Document.cpp:
2083         (WebCore::Document::Document):
2084         (WebCore::Document::~Document):
2085         (WebCore::Document::dispose): Extracted from removedLastRef()
2086         * dom/Document.h:
2087         (WebCore::Node::isTreeScope):
2088         (WebCore::Node::Node):
2089         * dom/DocumentFragment.cpp:
2090         (WebCore::DocumentFragment::DocumentFragment): Remove ASSERT() and move it to ...
2091         (WebCore::DocumentFragment::create): ... here, to allow NULL document from ShadowRoot.
2092         * dom/Node.cpp:
2093         (WebCore::Node::~Node):
2094         (WebCore::Node::removedLastRef):
2095         * dom/Node.h:
2096         (WebCore::Node::setTreeScope):
2097         * dom/Element.cpp:
2098         (WebCore::Element::ensureAttr): This has been wrong and is fixed in this revision since the incorrectness is unveiled by this change.
2099         * dom/ShadowRoot.cpp:
2100         (WebCore::ShadowRoot::ShadowRoot): Passed NULL document to superclass. This aligns what Document is doing.
2101         (WebCore::ShadowRoot::dispose): Added.
2102         * dom/ShadowRoot.h:
2103         (ShadowRoot):
2104         * dom/TreeScope.cpp:
2105         (SameSizeAsTreeScope):
2106         (WebCore::TreeScope::TreeScope):
2107         (WebCore::TreeScope::~TreeScope):
2108         (WebCore::TreeScope::dispose): Added.
2109         (WebCore::TreeScope::setParentTreeScope):
2110         (WebCore::TreeScope::deletionHasBegun):
2111         (WebCore::TreeScope::beginDeletion):
2112         (WebCore::TreeScope::refCount): Added.
2113         * dom/TreeScope.h: Turned m_rootNode to Node* from ContainerNode* for Node::isTreeScope to be inlined.
2114         (WebCore::TreeScope::guardRef): Pulled up from Document.
2115         (WebCore::TreeScope::guardDeref): Ditto.
2116         (WebCore::TreeScope::hasGuardRefCount): Added to hide m_guardRefCount.
2117         (WebCore::TreeScope::deletionHasBegun): Added.
2118         (WebCore::TreeScope::beginDeletion): Added.
2119         (WebCore::TreeScope::removedLastRefToScope): Pulled up from Document.
2120         * dom/TreeScopeAdopter.cpp:
2121         (WebCore::TreeScopeAdopter::moveTreeToNewScope):
2122         (WebCore::TreeScopeAdopter::moveNodeToNewDocument):
2123
2124 2013-03-04  Uday Kiran  <udaykiran@motorola.com>
2125
2126         getPropertyValue for -webkit-text-stroke returns null, should compute the shorthand value
2127         https://bugs.webkit.org/show_bug.cgi?id=111018
2128
2129         Reviewed by Alexander Pavlov.
2130
2131         Test: fast/css/getPropertyValue-webkit-text-stroke.html
2132
2133         * css/StylePropertySet.cpp:
2134         (WebCore::StylePropertySet::getPropertyValue):
2135
2136 2013-03-04  Uday Kiran  <udaykiran@motorola.com>
2137
2138         getPropertyValue for -webkit-columns returns null, should compute the shorthand value
2139         https://bugs.webkit.org/show_bug.cgi?id=111011
2140
2141         Reviewed by Alexander Pavlov.
2142
2143         Test: fast/css/getPropertyValue-columns.html
2144
2145         * css/StylePropertySet.cpp:
2146         (WebCore::StylePropertySet::getPropertyValue):
2147
2148 2013-03-04  Vsevolod Vlasov  <vsevik@chromium.org>
2149
2150         Web Inspector: Do not accumulate file system files, add them to workspace immediately
2151         https://bugs.webkit.org/show_bug.cgi?id=111325
2152
2153         Reviewed by Pavel Feldman.
2154
2155         * inspector/front-end/FileSystemProjectDelegate.js:
2156         (WebInspector.FileSystemProjectDelegate.prototype.populate.fileLoaded):
2157         (WebInspector.FileSystemProjectDelegate.prototype.populate):
2158         * inspector/front-end/IsolatedFileSystem.js:
2159         (WebInspector.IsolatedFileSystem.prototype.innerCallback):
2160         (WebInspector.IsolatedFileSystem.prototype.requestFilesRecursive):
2161
2162 2013-03-04  Kinuko Yasuda  <kinuko@chromium.org>
2163
2164         Unreviewed Windows build fix attempt.
2165
2166         floor method is ambigious so explicitly specify the type.
2167
2168         * html/canvas/WebGLRenderingContext.cpp:
2169         (WebCore::WebGLRenderingContext::validateCompressedTexFuncData):
2170
2171 2013-03-04  Chris Fleizach  <cfleizach@apple.com>
2172
2173         AX: cellForColumnAndRow fails for tables with hidden table cells
2174         https://bugs.webkit.org/show_bug.cgi?id=110050
2175
2176         Reviewed by Tim Horton.
2177
2178         If a table had hidden cells, then accessibility code was being confused in a few ways.
2179         1) The cellForColumnAndRow method would return the wrong information since that was
2180            using the RenderTableSection to retrieve a cell, which did not have the same data as the AXTable
2181         2) The way we were adding children made it impossible to determine column and row range because we 
2182            would skip rows that had hidden children
2183         3) AccessibilityARIAGrid and AccessibilityTable were using different methods for cellForColumnAndRow
2184
2185         The fix does a few things to make things right:
2186         1) Always add an accessibility row, even if there are no visible cells in that row.
2187         2) Have one method for AXTable and AXARIAGrid for cellForColumnAndRow.
2188         3) Change cellForColumnAndRow to query the accessibility children rather than the RenderTableSection in determining the row, col info.
2189         4) cellForColumnAndRow should use unsigned values instead of int values.
2190
2191         Test: accessibility/table-with-hidden-head-section.html
2192
2193         * accessibility/AccessibilityARIAGrid.cpp:
2194         (WebCore):
2195         * accessibility/AccessibilityARIAGrid.h:
2196         (AccessibilityARIAGrid):
2197         * accessibility/AccessibilityARIAGridCell.cpp:
2198         (WebCore::AccessibilityARIAGridCell::rowIndexRange):
2199         (WebCore::AccessibilityARIAGridCell::columnIndexRange):
2200         * accessibility/AccessibilityARIAGridCell.h:
2201         (AccessibilityARIAGridCell):
2202         * accessibility/AccessibilityTable.cpp:
2203         (WebCore::AccessibilityTable::addChildren):
2204         (WebCore::AccessibilityTable::cellForColumnAndRow):
2205         * accessibility/AccessibilityTable.h:
2206         (WebCore):
2207         (AccessibilityTable):
2208         * accessibility/AccessibilityTableCell.cpp:
2209         (WebCore::AccessibilityTableCell::rowIndexRange):
2210         (WebCore::AccessibilityTableCell::columnIndexRange):
2211         * accessibility/AccessibilityTableCell.h:
2212         (AccessibilityTableCell):
2213         * accessibility/atk/WebKitAccessibleInterfaceTable.cpp:
2214         (webkitAccessibleTableGetColumnAtIndex):
2215         (webkitAccessibleTableGetRowAtIndex):
2216         (webkitAccessibleTableGetColumnExtentAt):
2217         (webkitAccessibleTableGetRowExtentAt):
2218         (webkitAccessibleTableGetColumnHeader):
2219         (webkitAccessibleTableGetRowHeader):
2220         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2221         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
2222         * rendering/RenderTableSection.h:
2223         (RenderTableSection):
2224         (WebCore::RenderTableSection::rowRendererAt):
2225
2226 2013-03-04  Arpita Bahuguna  <a.bah@samsung.com>
2227
2228         getAttribute does not behave correctly for mixed-case attributes on HTML elements
2229         https://bugs.webkit.org/show_bug.cgi?id=105713
2230
2231         Reviewed by Andreas Kling.
2232
2233         getAttribute() and getAttributeNode() APIs do not convert the
2234         passed attribute name to lowercase before comparing against the
2235         existing attributes.
2236         The specification however states that the passed name should
2237         be converted to ASCII lowercase before checking for the existence
2238         of the given attribute. [www.w3.org/TR/domcore/#dom-element-getattribute]
2239
2240         Test: fast/dom/Element/getAttribute-case-insensitivity.html
2241
2242         * dom/Element.h:
2243         (WebCore::ElementData::getAttributeItemIndex):
2244         getAttributeItemIndex() accepts a bool param 'shouldIgnoreAttributeCase'
2245         which specifies whether the attribute's case should be ignored
2246         before comparison. But inspite of this param's value we still carry
2247         out a case sensitive search.
2248         Have modified the same to convert the passed attribute's name to
2249         lowercase if 'shouldIgnoreAttributeCase' is true.
2250
2251 2013-03-04  Kunihiko Sakamoto  <ksakamoto@chromium.org>
2252
2253         [Chromium] Add runtime flag for font load events
2254         https://bugs.webkit.org/show_bug.cgi?id=111296
2255
2256         Reviewed by Kent Tamura.
2257
2258         Add a runtime feature flag for FontLoader interface (disabled by default),
2259         and enable ENABLE_FONT_LOAD_EVENTS build flag for chromium.
2260
2261         * bindings/generic/RuntimeEnabledFeatures.cpp:
2262         (WebCore):
2263         * bindings/generic/RuntimeEnabledFeatures.h:
2264         (RuntimeEnabledFeatures):
2265         (WebCore::RuntimeEnabledFeatures::setFontLoadEventsEnabled):
2266         (WebCore::RuntimeEnabledFeatures::fontLoadEventsEnabled):
2267
2268 2013-03-04  Brandon Jones  <bajones@google.com>
2269
2270         WEBGL_compressed_texture_atc implementation
2271         https://bugs.webkit.org/show_bug.cgi?id=110496
2272
2273         Reviewed by Kenneth Russell.
2274
2275         Test: webgl/conformance/extensions/webgl-compressed-texture-atc.html
2276
2277         Exposes the WEBGL_compressed_texture_atc extension, but is unverified since no desktop hardware supports
2278         the format that I am aware of. Should enable mobile ports to expose the format, however.
2279
2280         * CMakeLists.txt:
2281         * DerivedSources.make:
2282         * DerivedSources.pri:
2283         * GNUmakefile.list.am:
2284         * Target.pri:
2285         * WebCore.gypi:
2286         * WebCore.xcodeproj/project.pbxproj:
2287         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2288         (WebCore::toJS):
2289         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
2290         (WebCore::toV8Object):
2291         * html/canvas/WebGLCompressedTextureATC.cpp: Copied from Source/WebCore/html/canvas/WebGLExtension.h.
2292         (WebCore):
2293         (WebCore::WebGLCompressedTextureATC::WebGLCompressedTextureATC):
2294         (WebCore::WebGLCompressedTextureATC::~WebGLCompressedTextureATC):
2295         (WebCore::WebGLCompressedTextureATC::getName):
2296         (WebCore::WebGLCompressedTextureATC::create):
2297         (WebCore::WebGLCompressedTextureATC::supported):
2298         * html/canvas/WebGLCompressedTextureATC.h: Copied from Source/WebCore/html/canvas/WebGLExtension.h.
2299         (WebCore):
2300         (WebGLCompressedTextureATC):
2301         * html/canvas/WebGLCompressedTextureATC.idl: Copied from Source/WebCore/html/canvas/WebGLExtension.h.
2302         * html/canvas/WebGLExtension.h:
2303         * html/canvas/WebGLRenderingContext.cpp:
2304         (WebCore):
2305         (WebCore::WebGLRenderingContext::paintRenderingResultsToCanvas):
2306         (WebCore::WebGLRenderingContext::getExtension):
2307         (WebCore::WebGLRenderingContext::getSupportedExtensions):
2308         (WebCore::WebGLRenderingContext::validateCompressedTexFuncData):
2309         * html/canvas/WebGLRenderingContext.h:
2310         (WebCore):
2311         (WebGLRenderingContext):
2312         * platform/graphics/Extensions3D.h:
2313
2314
2315 2013-03-04  Eugene Klyuchnikov  <eustas@chromium.org>
2316
2317         Web Inspector: Exceptions when WebInspector run in hosted mode.
2318         https://bugs.webkit.org/show_bug.cgi?id=111326
2319
2320         Reviewed by Pavel Feldman.
2321
2322         There is bug in commands code generation in InspectorBackend.js
2323         As a consequence all protocol enums have wrong names and cause
2324         exception when refererenced.
2325
2326         Currently protocol enums are referenced only from NetworkManager.
2327
2328         Test: inspector/inspector-backend-commands-generation.html
2329
2330         * inspector/front-end/InspectorBackend.js:
2331         (InspectorBackendClass.prototype.loadFromJSONIfNeeded):
2332         Use static method to generate code.
2333         (InspectorBackendClass._generateCommands):
2334         Extracted from loadFromJSONIfNeeded. Typo fixed.
2335
2336 2013-03-04  Chris Rogers  <crogers@google.com>
2337
2338         Add audio hardware support for multi-channel output by implementing AudioDestinationNode.maxChannelCount
2339         https://bugs.webkit.org/show_bug.cgi?id=111385
2340
2341         Reviewed by James Robinson.
2342         
2343         See specification details for .maxChannelCount:
2344         https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html#AudioDestinationNode
2345         
2346         * Modules/webaudio/AudioDestinationNode.h:
2347         (WebCore::AudioDestinationNode::maxChannelCount):
2348         * Modules/webaudio/AudioDestinationNode.idl:
2349         * Modules/webaudio/AudioNode.h:
2350         Implement .maxChannelCount attribute.
2351         
2352         (AudioNode):
2353         * Modules/webaudio/DefaultAudioDestinationNode.h:
2354         * Modules/webaudio/DefaultAudioDestinationNode.cpp:
2355         (WebCore::DefaultAudioDestinationNode::initialize):
2356         (WebCore::DefaultAudioDestinationNode::createDestination):
2357         (WebCore::DefaultAudioDestinationNode::enableInput):
2358         Call to createDestination() now takes no argument.
2359         Instead we maintain a member variable for the input device ID.
2360         (WebCore::DefaultAudioDestinationNode::maxChannelCount):
2361         (WebCore::DefaultAudioDestinationNode::setChannelCount):
2362         Check port-specific hardware support for maxChannelCount(),
2363         and allow setting the channel count based on what the hardware
2364         supports.
2365         
2366         * platform/audio/AudioDestination.h:
2367         (AudioDestination):
2368         * platform/audio/chromium/AudioDestinationChromium.cpp:
2369         (WebCore::AudioDestination::maxChannelCount):
2370         (WebCore::AudioDestinationChromium::render):
2371         Call into chromium WebKit API: audioHardwareOutputChannels().
2372
2373         * platform/audio/gstreamer/AudioDestinationGStreamer.cpp:
2374         (WebCore::AudioDestination::maxChannelCount):
2375         Add basic implementation for maxChannelCount() only supporting stereo output.
2376
2377         * platform/audio/mac/AudioDestinationMac.cpp:
2378         (WebCore::AudioDestination::maxChannelCount):
2379         Add basic implementation for maxChannelCount() only supporting stereo output.
2380         Later, the mac port can support more than this with some small improvements to AudioDestinationMac.
2381
2382 2013-03-04  Adam Barth  <abarth@webkit.org>
2383
2384         Background HTML parser can rewind the tokenizer after end-of-file
2385         https://bugs.webkit.org/show_bug.cgi?id=111365
2386
2387         Reviewed by Eric Seidel.
2388
2389         Prior to this patch, it was possible to call didFailSpeculation after
2390         processing the end-of-file token because checkForSpeculationFailure
2391         didn't zero out m_tokenizer in some control paths.
2392
2393         This patch renames checkForSpeculationFailure to validateSpeculations
2394         and ensures that it always takes ownership of the main thread's
2395         HTMLTokenizer.
2396
2397         This patch also adds a number of ASSERTs to make sure the parser state
2398         machine stays in the correct configuration (e.g., that we don't have a
2399         main thread tokenizer while we're supposed to be tokenizing on the
2400         background thread).
2401
2402         Test: fast/parser/document-write-fighting-eof.html
2403
2404         * html/parser/BackgroundHTMLInputStream.cpp:
2405         (WebCore::BackgroundHTMLInputStream::rewindTo):
2406         * html/parser/BackgroundHTMLParser.cpp:
2407         (WebCore::BackgroundHTMLParser::append):
2408         * html/parser/HTMLDocumentParser.cpp:
2409         (WebCore::HTMLDocumentParser::validateSpeculations):
2410         (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser):
2411         (WebCore::HTMLDocumentParser::pumpPendingSpeculations):
2412         (WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution):
2413         * html/parser/HTMLDocumentParser.h:
2414         (HTMLDocumentParser):
2415
2416 2013-03-04  Tim 'mithro' Ansell  <mithro@mithis.com>
2417
2418         Make sure that clearOwnerNode also clears StyleResolver references (via didMutate).
2419         https://bugs.webkit.org/show_bug.cgi?id=109446
2420
2421         Reviewed by Eric Seidel.
2422
2423         Test: fast/css/stylesheet.innerHTML-calls-didmutate.html
2424
2425         * css/CSSStyleSheet.h:
2426
2427 2013-03-04  Kentaro Hara  <haraken@chromium.org>
2428
2429         Unreviewd build fix after r144701.
2430
2431         * platform/EventTracer.cpp:
2432         (WebCore::EventTracer::initialize):
2433
2434 2013-03-04  Min Qin  <qinmin@chromium.org>
2435
2436         Fix some style issues in RenderLayerCompositor
2437         https://bugs.webkit.org/show_bug.cgi?id=111369
2438
2439         Reviewed by Simon Fraser.
2440
2441         Just style fix, no test needed
2442
2443         * rendering/RenderLayerCompositor.cpp:
2444         (WebCore::RenderLayerCompositor::frameViewDidScroll):
2445         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
2446
2447 2013-03-04  Terry Anderson  <tdanderson@chromium.org>
2448
2449         Revert changes to RenderLayer::scrollByRecursively() that were added for gesture-scrolling
2450         https://bugs.webkit.org/show_bug.cgi?id=111007
2451
2452         Reviewed by Simon Fraser.
2453
2454         Due to http://trac.webkit.org/changeset/144519 landing, the changes made to RenderLayer in
2455         http://trac.webkit.org/changeset/142057,
2456         http://trac.webkit.org/changeset/140177, and  
2457         http://trac.webkit.org/changeset/142195
2458         are no longer necessary (as RenderLayer::scrollByRecursively() is not used for
2459         gesture-scrolling) and should be reverted.
2460
2461         No change in behavior, so no new tests needed.
2462
2463         * rendering/RenderLayer.cpp:
2464         (WebCore::RenderLayer::scrollByRecursively):
2465         * rendering/RenderLayer.h:
2466
2467 2013-03-04  Kentaro Hara  <haraken@chromium.org>
2468
2469         Unreviewed build fix after r144701.
2470
2471         * platform/EventTracer.cpp:
2472         (WebCore::EventTracer::initialize):
2473
2474 2013-03-04  Christian Biesinger  <cbiesinger@chromium.org>
2475
2476         REGRESSION (r143643): Buttons containing floats render differently
2477         https://bugs.webkit.org/show_bug.cgi?id=110933
2478
2479         Reviewed by Ojan Vafai.
2480
2481         Test: fast/forms/button-with-float.html
2482
2483         * rendering/RenderBlock.cpp:
2484         (WebCore::RenderBlock::expandsToEncloseOverhangingFloats):
2485         Also include new flexbox as a renderer that needs to enclose
2486         overhanging floats. Flex boxes establish a block formatting context,
2487         so they need to contain floats:
2488         http://dev.w3.org/csswg/css3-flexbox/#flex-items
2489
2490 2013-03-04  Chris Fleizach  <cfleizach@apple.com>
2491
2492         Support WebSpeech - Speech Synthesis
2493         https://bugs.webkit.org/show_bug.cgi?id=106742
2494
2495         Build fix.
2496
2497         * Modules/speech/SpeechSynthesis.cpp:
2498
2499 2013-03-04  Rafael Weinstein  <rafaelw@chromium.org>
2500
2501         Unreviewed, rolling out r144595.
2502         http://trac.webkit.org/changeset/144595
2503         https://bugs.webkit.org/show_bug.cgi?id=90341
2504
2505         Causing multiple crashes in fast/dom/Element/* tests (hits
2506         assert in Attr.cp:215)
2507
2508         * dom/Element.cpp:
2509         (WebCore::Element::setAttributeNode):
2510
2511 2013-02-26  Kentaro Hara  <haraken@chromium.org>
2512
2513         [chromium] Implement TRACE_EVENT macros for sampling profiling
2514         https://bugs.webkit.org/show_bug.cgi?id=110932
2515
2516         Reviewed by Adam Barth.
2517
2518         We are implementing TRACE_EVENT macros for sampling profiling.
2519         It works in the following mechanism:
2520
2521         - Chromium defines global state variables for sampling profiling.
2522         (i.e. g_trace_state0, g_trace_state1, g_trace_state2 in trace_event.h)
2523
2524         - WebKit gets the addresses of the global state variables at the
2525         initialization step. (i.e. EventTracer::initialize())
2526
2527         - WebKit updates the global states by using TRACE_EVENT_SAMPLING_STATE()
2528         macros every time WebKit changes its state. (e.g. DOM attribute
2529         getters/setters/methods)
2530
2531         - A sampling thread running in Chrome reads the global states
2532         periodically and visualizes the profiling results into about://tracing.
2533
2534         This patch implements (1) a WebKit API to get the addresses of
2535         the global states and (2) the TRACE_EVENT_SAMPLING_STATE() macro.
2536
2537         No tests. The sampling profiler is not enabled in Chrome by default.
2538         I manually inserted TRACE_EVENT_SAMPLING_STATE() macros and
2539         confirmed that the sampling profiling is working as expected.
2540
2541         * platform/EventTracer.cpp:
2542         (WebCore::EventTracer::initialize):
2543         (WebCore::EventTracer::getTraceCategoryEnabledFlag):
2544         (WebCore):
2545         * platform/EventTracer.h:
2546         (WebCore):
2547         (EventTracer):
2548         * platform/chromium/EventTracerChromium.cpp:
2549         (WebCore):
2550         (WebCore::EventTracer::initialize):
2551         * platform/chromium/TraceEvent.h:
2552
2553 2013-03-04  Chris Fleizach  <cfleizach@apple.com>
2554
2555         Support WebSpeech - Speech Synthesis
2556         https://bugs.webkit.org/show_bug.cgi?id=106742
2557
2558         Reviewed by Simon Fraser.
2559
2560         Enable speech synthesis for the Mac.
2561
2562         * Configurations/FeatureDefines.xcconfig:
2563
2564 2013-03-04  Ruslan Abdikeev  <aruslan@chromium.org>
2565
2566         <link rel="apple-touch-icon"> tag is not honored on CNN.com, workflowy.com etc
2567         https://bugs.webkit.org/show_bug.cgi?id=109061
2568
2569         Reviewed by Adam Barth.
2570
2571         Test: fast/dom/icon-url-list-apple-touch.html
2572
2573         Added iconTypes parameter to Document::iconURLs().
2574         Added Document::shortcutIconURLs() with original semantics of iconURLs().
2575         Fixed IconController.cpp to provide iconTypesMask to iconURLs().
2576         Renamed iconTypes to iconTypesMask to make the meaning clearer.
2577
2578         * WebCore.exp.in:
2579         * dom/Document.cpp:
2580         (WebCore::Document::shortcutIconURLs):
2581         (WebCore):
2582         (WebCore::Document::iconURLs):
2583         * dom/Document.h:
2584         (Document):
2585         * loader/icon/IconController.cpp:
2586         (WebCore::IconController::iconURL):
2587         (WebCore::IconController::urlsForTypes):
2588         * testing/Internals.cpp:
2589         (WebCore::Internals::iconURLs):
2590         (WebCore::Internals::shortcutIconURLs):
2591         (WebCore):
2592         (WebCore::Internals::allIconURLs):
2593         * testing/Internals.h:
2594         * testing/Internals.idl:
2595
2596 2013-02-27  Jeffrey Pfau  <jpfau@apple.com>
2597
2598         Cache partitioning does not affect iframe MainResources
2599         https://bugs.webkit.org/show_bug.cgi?id=111022
2600
2601         Reviewed by David Kilzer.
2602
2603         Set the partition of a main resource request if in a subframe.
2604
2605         Test: http/tests/cache/partitioned-cache-iframe.html
2606
2607         * loader/FrameLoader.cpp:
2608         (WebCore::FrameLoader::loadURL):
2609
2610 2013-03-04  Chris Fleizach  <cfleizach@apple.com>
2611
2612         AX: user agent shadow roots for plugins should be 'accessible'
2613         https://bugs.webkit.org/show_bug.cgi?id=111339
2614
2615         Reviewed by Tim Horton.
2616
2617         If a plugin element uses a user agent shadow element, we should make that shadow element
2618         into a button with the title and subtitle put together, and use that as the label. This 
2619         will probably be the best accessibility experience.
2620
2621         * html/HTMLPlugInImageElement.cpp:
2622         (WebCore::HTMLPlugInImageElement::didAddUserAgentShadowRoot):
2623
2624 2013-03-04  Alok Priyadarshi  <alokp@chromium.org>
2625
2626         [chromium] Form controls on composited layers are not painted properly
2627         https://bugs.webkit.org/show_bug.cgi?id=111366
2628
2629         Reviewed by James Robinson.
2630
2631         Set PlatformContextSkia::m_drawingToImageBuffer which is used as a hint to properly blend GDI-painted bitmap.
2632
2633         * platform/graphics/chromium/OpaqueRectTrackingContentLayerDelegate.cpp:
2634         (WebCore::OpaqueRectTrackingContentLayerDelegate::paintContents):
2635
2636 2013-03-04  Simon Fraser  <simon.fraser@apple.com>
2637
2638         Give ViewportConstraints classes copy constructors
2639         https://bugs.webkit.org/show_bug.cgi?id=111367
2640
2641         Reviewed by Beth Dakin.
2642         
2643         Downstream code requires that ViewportConstraints objects have
2644         copy constructors, so add them.
2645         
2646         Also clean up some redundant initialization of stack objects
2647         in RenderLayerCompositor.
2648
2649         No behavior change.
2650
2651         * page/scrolling/ScrollingConstraints.h:
2652         (WebCore::ViewportConstraints::ViewportConstraints):
2653         (ViewportConstraints):
2654         (WebCore::FixedPositionViewportConstraints::FixedPositionViewportConstraints):
2655         (FixedPositionViewportConstraints):
2656         (WebCore::StickyPositionViewportConstraints::StickyPositionViewportConstraints):
2657         (StickyPositionViewportConstraints):
2658         * rendering/RenderLayerCompositor.cpp:
2659         (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
2660         (WebCore::RenderLayerCompositor::computeStickyViewportConstraints):
2661
2662 2013-03-04  Roger Fong  <roger_fong@apple.com>
2663
2664         Unreviewed. AppleWin build fix.
2665
2666         * html/parser/XSSAuditor.cpp:
2667         (WebCore::isSemicolonSeparatedAttribute):
2668
2669 2013-03-04  Andreas Kling  <akling@apple.com>
2670
2671         CSSParser: Avoid temporary String when parsing hex colors.
2672         <http://webkit.org/b/111341>
2673
2674         Reviewed by Anders Carlsson.
2675
2676         Templatize CSSParser::fastParseColor() so we can pass a CSSParserString as the color name.
2677         This avoids creating a temporary WTF::String from the parser string.
2678
2679         * css/CSSParser.cpp:
2680         (WebCore::CSSParser::fastParseColor):
2681         * css/CSSParser.h:
2682         * css/CSSParserValues.h:
2683         (CSSParserString):
2684
2685 2013-03-04  Julien Chaffraix  <jchaffraix@webkit.org>
2686
2687         [CSS Grid Layout] Add parsing for grid-{start|before}
2688         https://bugs.webkit.org/show_bug.cgi?id=110988
2689
2690         Reviewed by Tony Chang.
2691
2692         Test: fast/css-grid-layout/grid-item-start-before-get-set.html
2693
2694         Refactored how we store internally grid-{row|column} to be based on grid-{before|start}.
2695         This is required as grid-{row|column} are shorthands for resp. grid-{before|after} and grid-{start|end}
2696         in the specification and will also be in the code. That means a lot of methods were renamed to be more
2697         aligned with the new design.
2698
2699         * css/CSSComputedStyleDeclaration.cpp:
2700         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2701         * css/CSSParser.cpp:
2702         (WebCore::CSSParser::parseValue):
2703         * css/CSSProperty.cpp:
2704         (WebCore::CSSProperty::isInheritedProperty):
2705         * css/CSSPropertyNames.in:
2706         * css/StyleResolver.cpp:
2707         (WebCore::StyleResolver::applyProperty):
2708         Added the code to parse, apply and get back the new properties. Also
2709         some renaming after the internal naming change below.
2710
2711         * rendering/RenderGrid.cpp:
2712         (WebCore::RenderGrid::maximumIndexInDirection):
2713         (WebCore::RenderGrid::placeItemsOnGrid):
2714         (WebCore::RenderGrid::autoPlacementMajorAxisPositionForChild):
2715         (WebCore::RenderGrid::autoPlacementMinorAxisPositionForChild):
2716         * rendering/style/RenderStyle.h:
2717         * rendering/style/StyleGridItemData.cpp:
2718         (WebCore::StyleGridItemData::StyleGridItemData):
2719         * rendering/style/StyleGridItemData.h:
2720         (WebCore::StyleGridItemData::operator==):
2721         Updated the naming now that we manipulate grid-{before|start} instead of grid-{row|column}.
2722
2723 2013-03-04  Chris Fleizach  <cfleizach@apple.com>
2724
2725         WebSpeech: change voiceURI to voice
2726         https://bugs.webkit.org/show_bug.cgi?id=110773
2727
2728         Reviewed by Tim Horton.
2729
2730         Change the voiceURI property to a voice property that takes a SpeechSynthesisVoice.
2731         This was recently added to the errata of the WebSpeech spec.
2732
2733         Test: platform/mac/fast/speechsynthesis/speech-synthesis-utterance-uses-voice.html
2734
2735         * Modules/speech/SpeechSynthesisUtterance.cpp:
2736         (WebCore):
2737         (WebCore::SpeechSynthesisUtterance::voice):
2738         (WebCore::SpeechSynthesisUtterance::setVoice):
2739         * Modules/speech/SpeechSynthesisUtterance.h:
2740         (SpeechSynthesisUtterance):
2741         * Modules/speech/SpeechSynthesisUtterance.idl:
2742         * Modules/speech/SpeechSynthesisVoice.h:
2743         (WebCore::SpeechSynthesisVoice::platformVoice):
2744         (SpeechSynthesisVoice):
2745         * platform/PlatformSpeechSynthesisUtterance.cpp:
2746         (WebCore::PlatformSpeechSynthesisUtterance::PlatformSpeechSynthesisUtterance):
2747         * platform/PlatformSpeechSynthesisUtterance.h:
2748         (WebCore::PlatformSpeechSynthesisUtterance::voice):
2749         (WebCore::PlatformSpeechSynthesisUtterance::setVoice):
2750         (PlatformSpeechSynthesisUtterance):
2751         * platform/mac/PlatformSpeechSynthesizerMac.mm:
2752         (-[WebSpeechSynthesisWrapper speakUtterance:WebCore::]):
2753
2754 2013-03-04  Victor Costan <costan@gmail.com>
2755
2756         Filename passed to FormData.append() takes precedence over filename in
2757         File.
2758         https://bugs.webkit.org/show_bug.cgi?id=111255
2759
2760         Reviewed by Alexey Proskuryakov.
2761
2762         Test: http/tests/local/formdata/send-form-data-with-filename.html
2763
2764         * platform/network/FormData.cpp:
2765         (WebCore::FormData::appendKeyValuePairItems): changed to implement the
2766         behavior in the XMLHttpRequest W3C spec.
2767
2768 2013-03-04  Alexis Hetu  <sugoi@chromium.org>
2769
2770         Canvas and DOM go out of sync
2771         https://bugs.webkit.org/show_bug.cgi?id=107701
2772
2773         Reviewed by Simon Fraser.
2774
2775         Test: fast/canvas/canvas-overflow-hidden-animation.html
2776
2777         Added an update of the current compositor from the layer's stacking
2778         container when the layer itself isn't a stacking container.
2779
2780         * rendering/RenderLayerBacking.cpp:
2781         (WebCore::RenderLayerBacking::updateAfterLayout):
2782         Added an update of the stacking container of the owning layer of the
2783         layer backing when the owning layer isn't a stacking container itself.
2784
2785 2013-03-04  Alexey Proskuryakov  <ap@apple.com>
2786
2787         Small BlobResourceHandle cleanup
2788         https://bugs.webkit.org/show_bug.cgi?id=111352
2789
2790         Reviewed by Sam Weinig.
2791
2792         1. Don't use PassRefPtr<BlobStorageData> when ownership is not being passed.
2793         2. Added OVERRIDE to some functions.
2794         3. Added const to ResourceHandle::firstRequest().
2795
2796         * platform/network/BlobRegistryImpl.cpp:
2797         (WebCore::loadResourceSynchronously):
2798         (WebCore::BlobRegistryImpl::createResourceHandle):
2799         (WebCore::BlobRegistryImpl::getBlobDataFromURL):
2800         * platform/network/BlobRegistryImpl.h:
2801         (BlobRegistryImpl):
2802         * platform/network/BlobResourceHandle.cpp:
2803         (WebCore::BlobResourceHandle::createAsync):
2804         (WebCore::BlobResourceHandle::loadResourceSynchronously):
2805         * platform/network/BlobResourceHandle.h:
2806         (BlobResourceHandle):
2807         * platform/network/FormData.cpp:
2808         (WebCore::appendBlobResolved):
2809         * platform/network/ResourceHandle.cpp:
2810         (WebCore::ResourceHandle::firstRequest):
2811         * platform/network/ResourceHandle.h:
2812         (ResourceHandle):
2813
2814 2013-03-04  Vsevolod Vlasov  <vsevik@chromium.org>
2815
2816         Web Inspector: Introduce WebInspector.EventTarget interface for interfaces that dispatch events.
2817         https://bugs.webkit.org/show_bug.cgi?id=111320
2818
2819         Reviewed by Pavel Feldman.
2820
2821         * inspector/front-end/Object.js:
2822         (WebInspector.EventTarget):
2823         (WebInspector.EventTarget.prototype.addEventListener):
2824         (WebInspector.EventTarget.prototype.removeEventListener):
2825         (WebInspector.EventTarget.prototype.removeAllListeners):
2826         (WebInspector.EventTarget.prototype.hasEventListeners):
2827         (WebInspector.EventTarget.prototype.dispatchEventToListeners):
2828         * inspector/front-end/ResourceScriptMapping.js:
2829         * inspector/front-end/UISourceCode.js:
2830         * inspector/front-end/Workspace.js:
2831         (WebInspector.ProjectDelegate.prototype.searchInFileContent):
2832
2833 2013-03-04  Tom Sepez  <tsepez@chromium.org>
2834
2835         XSSAuditor bypass with --> comment syntax.
2836         https://bugs.webkit.org/show_bug.cgi?id=111349
2837
2838         Reviewed by Adam Barth.
2839
2840         Test: http/tests/security/xssAuditor/open-iframe-src-03.html
2841
2842         * html/parser/XSSAuditor.cpp:
2843         (WebCore::isTerminatingCharacter):
2844         Adds ">" to the list of terminating characters, so that comments of
2845         the form --> end the snippet we seek to match.
2846
2847 2013-03-04  Vsevolod Vlasov  <vsevik@chromium.org>
2848
2849         Web Inspector: Modal dialogs sometimes lose focus.
2850         https://bugs.webkit.org/show_bug.cgi?id=111317
2851
2852         Reviewed by Pavel Feldman.
2853
2854         setCurrentFocusElement doesn't give focus to an element anymore
2855         if modal glass pane is shown and element is not inside it.
2856
2857         * inspector/front-end/Dialog.js:
2858         (WebInspector.Dialog):
2859         (WebInspector.Dialog.prototype._hide):
2860         * inspector/front-end/InspectorView.js:
2861         (WebInspector.InspectorView.prototype.defaultFocusedElement):
2862         * inspector/front-end/ScriptsPanel.js:
2863         (WebInspector.ScriptsPanel.prototype.defaultFocusedElement):
2864         * inspector/front-end/UIUtils.js:
2865         (WebInspector.GlassPane):
2866         (WebInspector.GlassPane.prototype.dispose):
2867         (WebInspector.setCurrentFocusElement):
2868         * inspector/front-end/dialog.css:
2869
2870 2013-03-04  Roger Fong  <roger_fong@apple.com>
2871
2872         Unreviewed. AppleWin build fix.
2873
2874         * WebCore.vcxproj/WebCore.vcxproj:
2875
2876 2013-03-04  Dan Carney  <dcarney@google.com>
2877
2878         [v8] add isolate parameter to heap statistics calls
2879         https://bugs.webkit.org/show_bug.cgi?id=111308
2880
2881         Reviewed by Jochen Eisinger.
2882
2883         No new tests.
2884
2885         * bindings/v8/ScriptGCEvent.cpp:
2886         (WebCore::ScriptGCEvent::getHeapSize):
2887         (WebCore::ScriptGCEvent::getUsedHeapSize):
2888         * bindings/v8/V8AdaptorFunction.cpp:
2889         (WebCore::V8AdaptorFunction::getTemplate):
2890         * bindings/v8/V8GCController.cpp:
2891         (WebCore::V8GCController::checkMemoryUsage):
2892
2893 2013-03-04  Jochen Eisinger  <jochen@chromium.org>
2894
2895         [chromium] remove deprecated hyphenation methods from Platform
2896         https://bugs.webkit.org/show_bug.cgi?id=111101
2897
2898         Reviewed by Adam Barth.
2899
2900         * platform/text/chromium/Hyphenation.cpp:
2901         (WebCore::canHyphenate):
2902         (WebCore::lastHyphenLocation):
2903
2904 2013-03-04  Benjamin Poulain  <benjamin@webkit.org>
2905
2906         Use initialization from literal for MediaFeatureNames
2907         https://bugs.webkit.org/show_bug.cgi?id=111283
2908
2909         Reviewed by Andreas Kling.
2910
2911         * css/MediaFeatureNames.cpp:
2912         (WebCore::MediaFeatureNames::init):
2913         Initialization from literal is faster and use less memory. The names are
2914         defined statically in MediaFeatureNames.h.
2915
2916         Also use the NotNull placement new to avoid a branch on silly allocators.
2917
2918 2013-03-04  Joshua Bell  <jsbell@chromium.org>
2919
2920         [V8] Unreviewed. Rebaselined run-bindings-tests following r144617
2921
2922         * bindings/scripts/test/V8/V8Float64Array.cpp:
2923         (WebCore::ConfigureV8Float64ArrayTemplate):
2924         (WebCore::V8Float64Array::GetTemplate):
2925         * bindings/scripts/test/V8/V8Float64Array.h:
2926         (V8Float64Array):
2927         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
2928         (WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
2929         (WebCore::TestActiveDOMObjectV8Internal::TestActiveDOMObjectDomainSafeFunctionSetter):
2930         (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
2931         (WebCore::V8TestActiveDOMObject::GetTemplate):
2932         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
2933         (V8TestActiveDOMObject):
2934         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
2935         (WebCore::ConfigureV8TestCustomNamedGetterTemplate):
2936         (WebCore::V8TestCustomNamedGetter::GetTemplate):
2937         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
2938         (V8TestCustomNamedGetter):
2939         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
2940         (WebCore::ConfigureV8TestEventConstructorTemplate):
2941         (WebCore::V8TestEventConstructor::GetTemplate):
2942         * bindings/scripts/test/V8/V8TestEventConstructor.h:
2943         (V8TestEventConstructor):
2944         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2945         (WebCore::ConfigureV8TestEventTargetTemplate):
2946         (WebCore::V8TestEventTarget::GetTemplate):
2947         * bindings/scripts/test/V8/V8TestEventTarget.h:
2948         (V8TestEventTarget):
2949         * bindings/scripts/test/V8/V8TestException.cpp:
2950         (WebCore::ConfigureV8TestExceptionTemplate):
2951         (WebCore::V8TestException::GetTemplate):
2952         * bindings/scripts/test/V8/V8TestException.h:
2953         (V8TestException):
2954         * bindings/scripts/test/V8/V8TestInterface.cpp:
2955         (WebCore::ConfigureV8TestInterfaceTemplate):
2956         (WebCore::V8TestInterface::GetTemplate):
2957         * bindings/scripts/test/V8/V8TestInterface.h:
2958         (V8TestInterface):
2959         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
2960         (WebCore::ConfigureV8TestMediaQueryListListenerTemplate):
2961         (WebCore::V8TestMediaQueryListListener::GetTemplate):
2962         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
2963         (V8TestMediaQueryListListener):
2964         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2965         (WebCore::V8TestNamedConstructorConstructor::GetTemplate):
2966         (WebCore::ConfigureV8TestNamedConstructorTemplate):
2967         (WebCore::V8TestNamedConstructor::GetTemplate):
2968         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
2969         (V8TestNamedConstructorConstructor):
2970         (V8TestNamedConstructor):
2971         * bindings/scripts/test/V8/V8TestNode.cpp:
2972         (WebCore::ConfigureV8TestNodeTemplate):
2973         (WebCore::V8TestNode::GetTemplate):
2974         * bindings/scripts/test/V8/V8TestNode.h:
2975         (V8TestNode):
2976         * bindings/scripts/test/V8/V8TestObj.cpp:
2977         (WebCore::ConfigureV8TestObjTemplate):
2978         (WebCore::V8TestObj::GetTemplate):
2979         (WebCore::V8TestObj::installPerContextPrototypeProperties):
2980         * bindings/scripts/test/V8/V8TestObj.h:
2981         (V8TestObj):
2982         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
2983         (WebCore::ConfigureV8TestOverloadedConstructorsTemplate):
2984         (WebCore::V8TestOverloadedConstructors::GetTemplate):
2985         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
2986         (V8TestOverloadedConstructors):
2987         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2988         (WebCore::ConfigureV8TestSerializedScriptValueInterfaceTemplate):
2989         (WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
2990         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2991         (V8TestSerializedScriptValueInterface):
2992         * bindings/scripts/test/V8/V8TestTypedefs.cpp:
2993         (WebCore::ConfigureV8TestTypedefsTemplate):
2994         (WebCore::V8TestTypedefs::GetTemplate):
2995         * bindings/scripts/test/V8/V8TestTypedefs.h:
2996         (V8TestTypedefs):
2997
2998 2013-03-04  Tony Chang  <tony@chromium.org>
2999
3000         Unreviewed, rolling out r144562.
3001         http://trac.webkit.org/changeset/144562
3002         https://bugs.webkit.org/show_bug.cgi?id=85642
3003
3004         Caused KeyPadInsert faluires in webkit_unittests
3005
3006         * platform/chromium/KeyCodeConversionGtk.cpp:
3007         (WebCore::windowsKeyCodeForKeyEvent):
3008
3009 2013-03-04  Uday Kiran  <udaykiran@motorola.com>
3010
3011         getComputedStyle not implemented for -webkit-columns shorthand
3012         https://bugs.webkit.org/show_bug.cgi?id=111236
3013
3014         Reviewed by Alexis Menard.
3015
3016         Implement getComputedStyle for -webkit-columns shorthand.
3017
3018         Test: fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html
3019
3020         * css/CSSComputedStyleDeclaration.cpp:
3021         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3022
3023 2013-03-04  Levi Weintraub  <leviw@chromium.org>
3024
3025         Add support for 8 bit TextRuns on Chromium Linux & Mac
3026         https://bugs.webkit.org/show_bug.cgi?id=99393
3027
3028         Reviewed by Eric Seidel.
3029
3030         Adding support for 8 bit TextRuns for Mac and Linux Chromium. To accomplish this,
3031         8 bit text runs are upconverted to 16 bit in the complex text path during string
3032         normalization, as HarfBuzz operates on UChars.
3033
3034         Windows has platfom assumptions that TextRuns are 16 bit that need to be addressed
3035         before enabling this optimization.
3036
3037         No new tests. No change in behavior.
3038
3039         (WebCore::HarfBuzzShaperBase::setNormalizedBuffer):
3040         * platform/graphics/harfbuzz/HarfBuzzShaperBase.h:
3041         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
3042         (WebCore::normalizeCharacters):
3043         (WebCore::HarfBuzzShaper::HarfBuzzShaper):
3044
3045 2013-03-04  Alexis Menard  <alexis@webkit.org>
3046
3047         transition-property property and transition shorthand property doesn't accept "all, all".
3048         https://bugs.webkit.org/show_bug.cgi?id=111201
3049
3050         Reviewed by Simon Fraser.
3051
3052         Relax the parsing of transition-property to allow all, all as a value.
3053         It is not very useful per say but it is possible by the spec and we
3054         align with Firefox, IE and Opera.
3055
3056         Test: LayoutTests/transitions/transitions-parsing.html
3057
3058         * css/CSSParser.cpp:
3059         (WebCore::CSSParser::parseAnimationProperty):
3060
3061 2013-03-04  Min Qin  <qinmin@chromium.org>
3062
3063         Don't apply page scale to clipRect if applyPageScaleFactorInCompositor is set to true
3064         https://bugs.webkit.org/show_bug.cgi?id=111229
3065
3066         Reviewed by Simon Fraser.
3067
3068         If applyPageScaleFactorInCompositor is set to true, webcore should use css coordinates.
3069         As a result, we shouldn't apply page scale to clipRect in RenderLayerCompositor.
3070         Layout tests set the flag to false, so we don't have anything to test against.
3071
3072         * rendering/RenderLayerCompositor.cpp:
3073         (WebCore::RenderLayerCompositor::addToOverlapMap):
3074
3075 2013-03-04  Ian Vollick  <vollick@chromium.org>
3076
3077         ASSERTION FAILED: m_clipRectsCache->m_respectingOverflowClip[clipRectsType] == (clipRectsContext.respectOverflowClip == RespectOverflowClip) in RenderLayer.
3078         https://bugs.webkit.org/show_bug.cgi?id=108257
3079
3080         Reviewed by David Hyatt.
3081
3082         With composited scrolling we paint both with and without respecting
3083         overflow clip. To prevent collisions in the clip cache, and to prevent
3084         throwing away cached clips unnecessarily, we keep two copies of the
3085         clip cache -- one for when overflow clip is respected, and one for
3086         when it isn't.
3087
3088         No new tests. Covered by existing tests (in debug):
3089           compositing/overflow/automatically-opt-into-composited-scrolling.html
3090           compositing/overflow/composited-scrolling-creates-a-stacking-container.html
3091
3092         * rendering/RenderLayer.cpp:
3093         (WebCore::RenderLayer::updateClipRects):
3094           No longer asserts that our 'respect overflow clip' status is
3095           consistent. It also gets and sets the clip cache using the clip rect
3096           context rather than just the clip rect type.
3097         (WebCore::RenderLayer::calculateClipRects):
3098         (WebCore::RenderLayer::parentClipRects):
3099         (WebCore::RenderLayer::clearClipRects):
3100         (WebCore::ClipRectsCache::ClipRectsCache):
3101         (WebCore::ClipRectsCache::getClipRects):
3102         (WebCore::ClipRectsCache::setClipRects):
3103         (WebCore::ClipRectsCache::getIndex):
3104           Get and set the cached clip rects using the context rather than
3105           type.
3106         (WebCore::RenderLayer::clipRects):
3107           We now cache twice as many clip rects.
3108         * rendering/RenderLayerBacking.cpp:
3109         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
3110           ShouldRespectOverflowClip was moved out of RenderLayer.
3111
3112         * rendering/RenderLayer.cpp:
3113         (WebCore::RenderLayer::updateClipRects):
3114         (WebCore::RenderLayer::calculateClipRects):
3115         (WebCore::RenderLayer::parentClipRects):
3116         (WebCore::RenderLayer::clearClipRects):
3117         * rendering/RenderLayer.h:
3118         (WebCore::ClipRectsCache::ClipRectsCache):
3119         (WebCore::ClipRectsCache::getClipRects):
3120         (WebCore::ClipRectsCache::setClipRects):
3121         (ClipRectsCache):
3122         (WebCore::ClipRectsCache::getIndex):
3123         (WebCore::RenderLayer::clipRects):
3124         * rendering/RenderLayerBacking.cpp:
3125         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
3126
3127 2013-03-04  Aaron Colwell  <acolwell@chromium.org>
3128
3129         Remove unused return value from SourceBufferPrivate::abort() and WebSourceBuffer::abort().
3130         https://bugs.webkit.org/show_bug.cgi?id=111195
3131
3132         Reviewed by Adam Barth.
3133
3134         No new tests. No user visible behavior changed.
3135
3136         * platform/graphics/SourceBufferPrivate.h:
3137         (SourceBufferPrivate):
3138
3139 2013-03-04  David Hyatt  <hyatt@apple.com>
3140
3141         [New Multicolumn] Eliminate the unique multicolumn flow thread style creation function
3142         https://bugs.webkit.org/show_bug.cgi?id=111338
3143
3144         Reviewed by Allan Jensen.
3145
3146         There is nothing special about a multi-column flow thread style now, so we can just
3147         use the existing anonymous style creation function.
3148
3149         * rendering/RenderMultiColumnBlock.cpp:
3150         (WebCore):
3151         (WebCore::RenderMultiColumnBlock::addChild):
3152
3153 2013-03-04  Mario Sanchez Prada  <mario.prada@samsung.com>
3154
3155         [GTK] WebCore::returnString is unsafe and should be removed!
3156         https://bugs.webkit.org/show_bug.cgi?id=110423
3157
3158         Reviewed by Martin Robinson.
3159
3160         Remove returnString() and replace it in callers with a new
3161         function that will cache and return the values of string
3162         properties for ATK interfaces in the private section of the
3163         wrapper AtkObject WebKitAccessible.
3164
3165         * accessibility/atk/WebKitAccessibleUtil.cpp: Remove returnString().
3166         * accessibility/atk/WebKitAccessibleUtil.h: Ditto.
3167
3168         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
3169         (_WebKitAccessiblePrivate): New private structure to store cached
3170         values of string property for the different ATK interfaces.
3171         (cacheAndReturnAtkProperty): New helper function to make sure the
3172         returned const gchar* value is previously cached in the private
3173         section of the wrapper AtkObject.
3174         (webkitAccessibleGetName): Use the new helper function.
3175         (webkitAccessibleGetDescription): Ditto.
3176         (webkitAccessibleInit): Initialize pointer to private structure.
3177         (webkitAccessibleFinalize): Remove unneeded code.
3178         (webkitAccessibleClassInit): Add private struct to class type/
3179         * accessibility/atk/WebKitAccessibleWrapperAtk.h:
3180         (_WebKitAccessible): New member pointing to the private structure,
3181         made the new helper function cacheAndReturnAtkProperty() available
3182         to external callers (implementation files for ATK interfaces).
3183         (AtkCachedProperty): New enum to allow reusing code when calling
3184         cacheAndReturnAtkProperty() to cache and return different properties.
3185
3186         * accessibility/atk/WebKitAccessibleInterfaceAction.cpp:
3187         (webkitAccessibleActionGetKeybinding): Replace calls to returnString()
3188         with calls to the new helper function cacheAndReturnAtkProperty().
3189         (webkitAccessibleActionGetName): Ditto.
3190         * accessibility/atk/WebKitAccessibleInterfaceDocument.cpp:
3191         (documentAttributeValue): Ditto.
3192         (webkitAccessibleDocumentGetLocale): Ditto.
3193         * accessibility/atk/WebKitAccessibleInterfaceImage.cpp:
3194         (webkitAccessibleImageGetImageDescription): Ditto.
3195
3196         Remove returnString() from WebKitAccessibleHyperlink (which is not
3197         an AtkObject, but a GObject) as well, replacing it in callers with
3198         simple code that will cache and return the required values in the
3199         private section of these kind of objects.
3200
3201         * accessibility/atk/WebKitAccessibleHyperlink.cpp:
3202         (_WebKitAccessibleHyperlinkPrivate): Added two new fields to cache
3203         string values for the key binding and name properties from the
3204         AtkAction interface, which is implemented by AtkHyperlink.
3205         (webkitAccessibleHyperlinkActionGetKeybinding): Cache the string
3206         value for the key binding before returning a const gchar* pointer.
3207         (webkitAccessibleHyperlinkActionGetName): Ditto.
3208         (webkitAccessibleHyperlinkGetURI): Do not cache the URI here, as
3209         this function returns a gchar* that will be owned by the caller.
3210
3211 2013-03-04  peavo@outlook.com  <peavo@outlook.com>
3212
3213         [Curl] Compile fix after r144216
3214         https://bugs.webkit.org/show_bug.cgi?id=111305
3215
3216         Reviewed by Brent Fulgham.
3217
3218         * platform/network/curl/ResourceRequest.h:
3219         (WebCore::ResourceRequest::cfURLRequest): Added new parameter.
3220
3221 2013-03-03  David Hyatt  <hyatt@apple.com>
3222
3223         [New Multicolumn] Make sure region styling works for columns inside regions.
3224         https://bugs.webkit.org/show_bug.cgi?id=111276
3225
3226         Reviewed by Sam Weinig.
3227
3228         Test: fast/regions/region-styling-in-columns.html
3229
3230         * rendering/RenderFlowThread.cpp:
3231         (WebCore::CurrentRenderFlowThreadMaintainer::CurrentRenderFlowThreadMaintainer):
3232         (WebCore::CurrentRenderFlowThreadMaintainer::~CurrentRenderFlowThreadMaintainer):
3233         * rendering/RenderFlowThread.h:
3234         (CurrentRenderFlowThreadMaintainer):
3235         Fix the CurrentRenderFlowThreadMaintainer so that it saves off the old render flow thread
3236         and restores it when done. This effectively makes flow thread layout a push/pop stack,
3237         since with in-flow threads, this is allowed. We assert that a nested flow thread is
3238         in-flow to preserve the invariant that you can't nest CSS Regions flow thread.
3239
3240         * rendering/RenderRegion.cpp:
3241         (WebCore::RenderRegion::computeChildrenStyleInRegion):
3242         Add isInFlowRenderFlowThread() to the anonymous check to make sure a style gets made
3243         for the nested flow thread.
3244
3245 2013-03-04  Andrey Lushnikov  <lushnikov@chromium.org>
3246
3247         Web Inspector: WebInspector.AceTextEditor throws a warning
3248         https://bugs.webkit.org/show_bug.cgi?id=111315
3249
3250         Reviewed by Pavel Feldman.
3251
3252         Add WebInspector.AceTextEditor to externs.js to suppress closure
3253         compilation warning.
3254
3255         No new tests: no change in behaviour.
3256
3257         * inspector/front-end/externs.js:
3258         (WebInspector.AceTextEditor):
3259
3260 2013-03-04  Antoine Quint  <graouts@apple.com>
3261
3262         Fix debug build under certain configurations, cause was
3263         http://trac.webkit.org/changeset/144624.
3264
3265         * inspector/InspectorController.cpp:
3266         (WebCore::InspectorController::InspectorController):
3267         * inspector/InspectorLayerTreeAgent.cpp:
3268         (WebCore::InspectorLayerTreeAgent::InspectorLayerTreeAgent):
3269         * inspector/InspectorLayerTreeAgent.h:
3270         (WebCore):
3271         (WebCore::InspectorLayerTreeAgent::create):
3272         (InspectorLayerTreeAgent):
3273
3274 2013-03-04  Allan Sandfeld Jensen  <allan.jensen@digia.com>
3275
3276         [Qt] REGRESSION(r141240) Crash in PluginPackage::fetchInfo
3277         https://bugs.webkit.org/show_bug.cgi?id=111322
3278
3279         Reviewed by Simon Hausmann.
3280
3281         Do not try to load blacklisted plugins.
3282
3283         * plugins/qt/PluginPackageQt.cpp:
3284         (WebCore::PluginPackage::fetchInfo):
3285
3286 2013-03-04  Alexis Menard  <alexis@webkit.org>
3287
3288         transition properties can't be found in CSSStyleDeclaration
3289         https://bugs.webkit.org/show_bug.cgi?id=110011
3290
3291         Reviewed by Antti Koivisto.
3292
3293         The previous approach for handling the unprefixing was to alias the
3294         unprefixed properties with the prefixed ones in CSSPropertyNames.in.
3295         Unfortunately it will alias the properties in the parsing code which will just
3296         identically parse the two versions. This means that when we populate StylePropertySet
3297         we do not have information whether we just parsed the prefixed, the
3298         unprefixed properties or we parsed both. The patch takes another
3299         approach by creating two distinct sets of properties (unprefixed and
3300         prefixed). Each properties have their own id and we now handle them in
3301         the parsing code as disctints properties and add both versions to the
3302         declared style. In order to avoid properties getting out of sync, 
3303         this patch adds few facilities to StylePropertySet to update the
3304         prefixed and the unprefixed entries. Finally the style resolution
3305         happens only for the prefixed version (to limit the size of this patch)
3306         and the unprefixed versions are not resolved. This is to avoid creating
3307         the animation objects twice for the resolved style.
3308
3309         Test : transitions/transitions-parsing.html
3310
3311         * css/CSSComputedStyleDeclaration.cpp:
3312         (WebCore):
3313         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3314         * css/CSSParser.cpp:
3315         (WebCore::CSSParser::addPropertyWithPrefixingVariant): Always add the
3316         prefixed and the unprefixed property even if only one is specified.
3317         (WebCore):
3318         (WebCore::CSSParser::parseValue):
3319         (WebCore::CSSParser::parseTransitionShorthand): Add both prefixed and
3320         unprefixed longhands to the declarated style.
3321         (WebCore::CSSParser::parseAnimationProperty):
3322         * css/CSSParser.h:
3323         (CSSParser):
3324         * css/CSSProperty.cpp:
3325         (WebCore::CSSProperty::isInheritedProperty):
3326         * css/CSSProperty.h:
3327         (WebCore:: prefixingVariantForPropertyId): This function takes a given
3328         property id and returns its prefixed or unprefixed id if it exists. If
3329         not it returns the same id.
3330         (WebCore):
3331         * css/CSSPropertyNames.in:
3332         * css/StylePropertySet.cpp:
3333         (WebCore::StylePropertySet::getPropertyValue):
3334         (WebCore::StylePropertySet::removeShorthandProperty):
3335         (WebCore::StylePropertySet::removeProperty):
3336         (WebCore::StylePropertySet::removeProperty): Remove
3337         also the prefixed or unprefixed shorthand if it exists.
3338         (WebCore):
3339         (WebCore::StylePropertySet::setProperty):
3340         (WebCore::StylePropertySet:: appendPrefixingVariantProperty):
3341         (WebCore::StylePropertySet::setPrefixingVariantProperty): If it
3342         exists a unprefixed or prefixed counterpart of the property we're
3343         trying to set, then we update the other one.
3344         (WebCore::StylePropertySet::asText):
3345         (WebCore::StylePropertySet::mergeAndOverrideOnConflict):
3346         * css/StylePropertySet.h:
3347         (StylePropertySet):
3348         * css/StylePropertyShorthand.cpp:
3349         (WebCore::transitionShorthand):
3350         (WebCore):
3351         (WebCore::shorthandForProperty): Define the transitions unprefixed
3352         longhands.
3353         * css/StylePropertyShorthand.h:
3354         (WebCore):
3355         * css/StyleResolver.cpp:
3356         (WebCore::StyleResolver::applyProperty): StyleBuilder will handle the
3357         resolution and the creation of the animations for the style. As the
3358         declarated style now contains declarations for the prefixed and
3359         unprefixed property we do not want to resolve two times and create duplicate animations.
3360         Therefore when we try to resolve the unprefixed version we just bail out.
3361
3362 2013-03-04  Ilya Tikhonovsky  <loislo@chromium.org>
3363
3364         Web Inspector: CPU Flame Chart: reveal profiler DataGrid node when user clicks on a FlameChart item.
3365         https://bugs.webkit.org/show_bug.cgi?id=111309
3366
3367         Reviewed by Yury Semikhatsky.
3368
3369         * inspector/front-end/CPUProfileView.js:
3370         (WebInspector.CPUProfileView.prototype._revealProfilerNode):
3371         * inspector/front-end/FlameChart.js:
3372         (WebInspector.FlameChart):
3373         (WebInspector.FlameChart.prototype._onClick):
3374
3375 2013-03-04  Antoine Quint  <graouts@apple.com>
3376
3377         Web Inspector: remove existing LayerTreeAgent protocol APIs
3378         https://bugs.webkit.org/show_bug.cgi?id=111251
3379
3380         In order to eventually provide a more useful API for the LayerTreeAgent
3381         that will be done in followup bugs, we remove the current API exposed by
3382         the agent providing a clean slate that will make future patches easier
3383         to read. Additionally, we remove the "childLayers" property on the Layer
3384         object since we will no longer be providing a hierarchy of layers, but
3385         rather a flat list of layers attached to a node and its descendants.
3386
3387         No new tests since we're removing the APIs exposed by the LayerTreeAgent.
3388         Subsequent patches will add tests as new APIs are added.
3389
3390         Reviewed by Timothy Hatcher.
3391
3392         * inspector/Inspector.json:
3393         * inspector/InspectorDOMAgent.cpp:
3394         * inspector/InspectorDOMAgent.h:
3395         * inspector/InspectorLayerTreeAgent.cpp:
3396         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
3397         * inspector/InspectorLayerTreeAgent.h:
3398         (InspectorLayerTreeAgent):
3399
3400 2013-03-04  Li Yin  <li.yin@intel.com>
3401
3402         MediaStream.ended must return true when it is created with ended tracks.
3403         https://bugs.webkit.org/show_bug.cgi?id=111293
3404
3405         Reviewed by Kentaro Hara.
3406
3407         Spec: http://dev.w3.org/2011/webrtc/editor/getusermedia.html#MediaStream-ended
3408         When a MediaStream object is created, its ended attribute must be set to false,
3409         unless it is being created using the MediaStream() constructor whose arguments
3410         are lists of MediaStreamTrack objects that are all ended, in which case the
3411         MediaStream object must be created with its ended attribute set to true.
3412
3413         Test: fast/mediastream/MediaStreamConstructor.html
3414
3415         * platform/mediastream/MediaStreamDescriptor.h:
3416         (WebCore::MediaStreamDescriptor::MediaStreamDescriptor):
3417
3418 2013-03-04  Alexander Pavlov  <apavlov@chromium.org>
3419
3420         Web Inspector: Adding new rules broken if a <style> tag is added to document dynamically
3421         https://bugs.webkit.org/show_bug.cgi?id=111299
3422
3423         Reviewed by Pavel Feldman.
3424
3425         The CSSStyleSheet instance should be retrieved directly from the HTMLStyleElement just created,
3426         not from the document.styleSheets list.
3427
3428         Test: inspector/styles/add-new-rule-with-style-after-body.html
3429
3430         * inspector/InspectorCSSAgent.cpp:
3431         (WebCore::InspectorCSSAgent::viaInspectorStyleSheet):
3432
3433 2013-03-04  Ilya Tikhonovsky  <loislo@chromium.org>
3434
3435         Web Inspector: Unreviewed. Fix for closure type annotations.
3436
3437         * inspector/front-end/FlameChart.js:
3438
3439 2013-03-04  Kondapally Kalyan  <kalyan.kondapally@intel.com>
3440
3441         [EFL] Build fix when compiling with GLES2 support enabled.
3442         https://bugs.webkit.org/show_bug.cgi?id=111291
3443
3444         Reviewed by Kenneth Rohde Christiansen.
3445
3446         This patch fixes build issues whe