e45ca5ca135e7c79ea34d0bb4fb88ff83ee0e4ba
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-03-24  Florin Malita  <fmalita@google.com>
2
3         ForeignObject content is zoomed two times
4         https://bugs.webkit.org/show_bug.cgi?id=76282
5
6         Reviewed by Nikolas Zimmermann.
7
8         Test: svg/zoom/page/zoom-foreign-content.svg
9
10         Reset the effective zoom property for FO-nested content to avoid
11         having the zoom factor applied multiple times (zooming is handled by
12         the top level SVG root element).
13
14         * css/CSSStyleSelector.cpp:
15         (WebCore::CSSStyleSelector::adjustRenderStyle):
16
17 2012-03-24  Chris Fleizach  <cfleizach@apple.com>
18
19         AX: Support solution to handle invalid ax text marker
20         https://bugs.webkit.org/show_bug.cgi?id=82023
21
22         Reviewed by Oliver Hunt.
23
24         This provides methods to better use text markers so that assistive technologies
25         can know when they are valid, and can convert them to and from absolute positions.
26
27         Test: platform/mac/accessibility/textmarker-routines.html
28
29         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
30         (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
31         (-[WebAccessibilityObjectWrapper _convertToNSRange:]):
32         (-[WebAccessibilityObjectWrapper _indexForTextMarker:]):
33         (-[WebAccessibilityObjectWrapper _textMarkerForIndex:]):
34         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
35
36 2012-03-24  Victor Carbune  <vcarbune@adobe.com>
37
38         Quick fix for rendering controls regression.
39         https://bugs.webkit.org/show_bug.cgi?id=82125
40
41         Reviewed by Eric Carlson.
42
43         Only temporary fix. Tests to cover the problem should be added
44
45         * html/shadow/MediaControlElements.cpp:
46         (WebCore::MediaControlPanelElement::makeOpaque): The display:none
47         property should be toggled only by the media element now.
48         (WebCore::MediaControlPanelElement::makeTransparent): The timer
49         that toggles the dispalay:none shouldn't be used now.
50
51 2012-03-24  Kevin Ollivier  <kevino@theolliviers.com>
52
53         [wx] Unreviewed. Add header needed for compilation.
54
55         * html/shadow/TextFieldDecorationElement.cpp:
56
57 2012-03-24  Abhishek Arya  <inferno@chromium.org>
58
59         Crash in ApplyStyleCommand::applyInlineStyleToNodeRange.
60         https://bugs.webkit.org/show_bug.cgi?id=81959
61
62         Reviewed by Ryosuke Niwa.
63
64         Test: editing/execCommand/apply-style-command-crash.html
65
66         * editing/ApplyStyleCommand.cpp:
67         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange): RefPtr the weak
68         node iterator |node|.
69         * editing/ApplyStyleCommand.h:
70         (ApplyStyleCommand): convert |startNode| and |pastEndNode| into PassRefPtr.
71
72 2012-03-24  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
73
74         Unreviewed, build fix since we use "-Werror=unused-but-set-variable".
75
76         The variable 'it' was set at TextureMapperShaderManager.h:110 but never used.
77
78         * platform/graphics/texmap/TextureMapperShaderManager.h:
79         (WebCore::TextureMapperShaderManager::getShaderProgram):
80
81 2012-03-24  Zeno Albisser  <zeno@webkit.org>
82
83         [Qt][WK2] Make TextureMapperShaderManager::getShaderProgram() not be a template.
84         https://bugs.webkit.org/show_bug.cgi?id=82049
85
86         Change the getShaderProgram() function to not be a template.
87         This is a workaround for a compiler bug that leads to an assert
88         when compiling in debug mode on mac.
89
90         Reviewed by Noam Rosenthal.
91
92         * platform/graphics/texmap/TextureMapperGL.cpp:
93         (WebCore::TextureMapperGL::drawTexture):
94         (WebCore::TextureMapperGL::beginClip):
95         * platform/graphics/texmap/TextureMapperShaderManager.h:
96         (TextureMapperShaderProgram):
97         (WebCore::TextureMapperShaderManager::getShaderProgram):
98         (TextureMapperShaderManager):
99
100 2012-03-23  Shawn Singh  <shawnsingh@chromium.org>
101
102         [chromium] Incorrect replica originTransform used in CCDamageTracker
103         https://bugs.webkit.org/show_bug.cgi?id=82118
104
105         Reviewed by Adrienne Walker.
106
107         Unit test added to CCDamageTrackerTest.cpp
108
109         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
110         (WebCore::CCDamageTracker::extendDamageForRenderSurface):
111
112 2012-03-23  Dana Jansens  <danakj@chromium.org>
113
114         [chromium] When prepainting fails, tiles dirty rects may be cleared
115         https://bugs.webkit.org/show_bug.cgi?id=82107
116
117         Reviewed by Adrienne Walker.
118
119         When prepainting, if a tile is unable to be reserved due to memory
120         limits, we bail out of prepareToUpdateTiles. But we would have
121         cleared the dirty rect of any previous tiles. This leaves them
122         in a bad state where their textures are reserved, but their textureIds
123         are set to 0, and they are not marked dirty. This means that they will
124         not be updated and displayed if they become visible, since it is
125         assumed that valid textures with zero textureId must have a dirty
126         region.
127
128         We fix this by not clearing the dirty rects until we know we are
129         going to update the layer.
130
131         Unit test: TiledLayerChromiumTest.pushTilesAfterIdlePaintFailed
132
133         * platform/graphics/chromium/TiledLayerChromium.cpp:
134         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
135         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
136         (WebCore::CCTiledLayerImpl::hasTextureIdForTileAt):
137         (WebCore):
138         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
139         (CCTiledLayerImpl):
140
141 2012-03-23  Stephanie Lewis  <slewis@apple.com>
142
143         https://bugs.webkit.org/show_bug.cgi?id=81963 WebProcess can get stuck in GC during many low memory signals.
144         <rdar://problem/11094830> WebProcess appears to get stuck in its GC handler (81963).
145         Remove the call to garbage collect  in low memory signal handler.  Did some testing with hitting the low memory handler
146         during Membuster and we would get back at most 100k - 200k.  That isn't enough to help the system, and in 
147         that state the GC collection can take a substantial amount of time.
148
149         Reviewed by Geoff Garen.
150
151         Performance Change, no change in behavior.
152
153         * platform/mac/MemoryPressureHandlerMac.mm:
154         (WebCore::MemoryPressureHandler::releaseMemory):
155
156 2012-03-23  W. James MacLean  <wjmaclean@chromium.org>
157
158         [chromium] CCLayerTreeHostImpl::scrollBegin() should return ScrollFailed for CCInputHandlerClient::Gesture type when wheel handlers found.
159         https://bugs.webkit.org/show_bug.cgi?id=82106
160
161         Reviewed by Adrienne Walker.
162
163         Existing unit tests updated.
164
165         With gesture scroll events now being handled as mouse wheel events, we should not start a gesture scroll when
166         wheel handlers are present.
167
168         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
169         (WebCore::CCLayerTreeHostImpl::scrollBegin):
170
171 2012-03-23  Adam Barth  <abarth@webkit.org>
172
173         Move Notifications APIs from WorkerContext.idl to WorkerContextNotifications.idl
174         https://bugs.webkit.org/show_bug.cgi?id=79635
175
176         Reviewed by Kentaro Hara.
177
178         This patch moves the NotificationCenter from WorkerContext to
179         WorkerContextNotificiations, reducing clutter in WorkerContext.  After
180         this patch, Notifications are almost entirely contained in the
181         notifications directory.
182
183         * CMakeLists.txt:
184         * DerivedSources.make:
185         * DerivedSources.pri:
186         * GNUmakefile.list.am:
187         * Target.pri:
188         * WebCore.gypi:
189         * WebCore.vcproj/WebCore.vcproj:
190         * WebCore.xcodeproj/project.pbxproj:
191         * workers/WorkerContext.cpp:
192         (WebCore::WorkerContext::~WorkerContext):
193         * workers/WorkerContext.h:
194         (WebCore):
195         (WorkerContext):
196         * workers/WorkerContext.idl:
197
198 2012-03-23  Michal Mocny  <mmocny@google.com>
199
200         [chromium] RootLayer was not being checked for null causing segfaults very rarely.
201         https://bugs.webkit.org/show_bug.cgi?id=82111
202
203         Reviewed by Adrienne Walker.
204
205         * platform/graphics/chromium/LayerRendererChromium.cpp:
206         (WebCore::LayerRendererChromium::beginDrawingFrame):
207         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
208         (WebCore::CCLayerTreeHostImpl::drawLayers):
209
210 2012-03-23  Shawn Singh  <shawnsingh@chromium.org>
211
212         [chromium] Fix race bug that clobbers CCLayerImpl updateRect
213         https://bugs.webkit.org/show_bug.cgi?id=82109
214
215         Reviewed by Dirk Pranke.
216
217         If the main thread commits twice before the impl thread actually
218         draws, then the updateRect of the first frame gets lost forever,
219         and not propagated to the damage tracker.
220
221         The solution is to accumulate the updateRect. The CCLayerImpl
222         updateRect is already being correctly cleared at the appropriate
223         time after drawing.
224
225         Unit test added to LayerChromiumTest.cpp.
226
227         * platform/graphics/chromium/LayerChromium.cpp:
228         (WebCore::LayerChromium::pushPropertiesTo):
229
230 2012-03-23  Rafael Weinstein  <rafaelw@chromium.org>
231
232         [MutationObservers] attributeFilter should be case sensitive at all times
233         https://bugs.webkit.org/show_bug.cgi?id=81822
234
235         Reviewed by Ryosuke Niwa.
236
237         This removes the behavior in MutationObserverRegistration which treats
238         attributeFilter as case insensitive for HTML elements in HTML documents.
239
240         Relevant tests have been updated.
241
242         * dom/MutationObserverRegistration.cpp:
243         (WebCore::MutationObserverRegistration::resetObservation):
244         (WebCore::MutationObserverRegistration::shouldReceiveMutationFrom):
245         * dom/MutationObserverRegistration.h:
246         (MutationObserverRegistration):
247
248 2012-03-23  Kentaro Hara  <haraken@chromium.org>
249
250         Move WebSocket APIs from WorkerContext.idl to WorkerContextWebSocket.idl
251         https://bugs.webkit.org/show_bug.cgi?id=79663
252
253         Reviewed by Adam Barth.
254
255         For WebKit modularization, this patch moves WebSocket APIs from WorkerContext.idl
256         to WorkerContextWebSocket.idl.
257
258         Tests: http/tests/websocket/tests/hybi/workers/* (No change in test results)
259
260         * CMakeLists.txt:
261         * DerivedSources.make:
262         * DerivedSources.pri:
263         * GNUmakefile.list.am:
264         * Modules/websockets/WorkerContextWebSocket.idl: Added.
265         * WebCore.gypi:
266         * WebCore.xcodeproj/project.xcodeproj:
267         * workers/WorkerContext.idl:
268
269 2012-03-23  Parag Radke  <parag@motorola.com>
270
271         REGRESSION: can select text of an input button
272         https://bugs.webkit.org/show_bug.cgi?id=13624
273
274         Reviewed by Ryosuke Niwa.
275
276         Text in a button should never have a selection background of its own painted
277         but if the button is inside an editable area, then the whole button should
278         have it's selection background painted.
279
280         Test: editing/selection/selection-button-text.html
281
282         * rendering/RenderButton.h:
283         Added implementation for the virtual function canBeSelectionLeaf()
284         which returns true if the button renderer is editable, false other wise.
285         * rendering/RenderTextFragment.h:
286         Added implementation for the virtual function canBeSelectionLeaf()
287         which returns true if the text fragment renderer is editable, false other wise.
288
289 2012-03-23  Eric Carlson  <eric.carlson@apple.com>
290
291         Remove unnecessary ASSERT from LoadableTextTrack::trackElementIndex
292         https://bugs.webkit.org/show_bug.cgi?id=82095
293
294         Reviewed by Dan Bernstein.
295
296         No new tests, removed a bogus ASSERT that was sometimes triggered by tests.
297
298         * html/track/LoadableTextTrack.cpp:
299         (WebCore::LoadableTextTrack::trackElementIndex): Remove ASSERT.
300
301 2012-03-23  Eric Carlson  <eric.carlson@apple.com>
302
303         Layout Test media/video-source-load.html is failing
304         https://bugs.webkit.org/show_bug.cgi?id=82094
305
306         Reviewed by Alexey Proskuryakov.
307
308         No new tests, tested by media/video-source-load.html.
309
310         * html/HTMLMediaElement.cpp:
311         (WebCore::HTMLMediaElement::sourceWasAdded): Set m_nextChildNodeToConsider when called 
312             with networkState == NETWORK_EMPTY because the resource selection algorithm has
313             not started yet.
314
315 2012-03-23  Alexey Proskuryakov  <ap@apple.com>
316
317         [Mac] No need for platform-specific ENABLE_BLOB values
318         https://bugs.webkit.org/show_bug.cgi?id=82102
319
320         Reviewed by David Kilzer.
321
322         * Configurations/FeatureDefines.xcconfig:
323
324 2012-03-23  Kent Tamura  <tkent@chromium.org>
325
326         Add TextFieldDecorator and TextFieldDecorationElement
327         https://bugs.webkit.org/show_bug.cgi?id=80580
328
329         Reviewed by Dimitri Glazkov.
330
331         These classes will be used to add a decoration icon to a text field
332         <input> from outside of WebCore. We have a plan to use them in Chromium
333         port. So this patch doesn't add TextFieldDecorationElement.{cpp,h} to
334         non-Chromium build files.
335
336         How it works:
337         When a shadow subtree for a text field is created, we ask ChromeClient
338         to decorate it. ChromeClient appends a TextFieldDecorationElement to the
339         existing shadow subtree or another shadow tree. A TextFieldDecorator is
340         associated to a TextFieldDecorationElement, and it provides decoration
341         icon images and a click handler.
342
343         No new tests. This patch won't make any behavior change for now.
344
345         * WebCore.gypi: Add TextFieldDecorationElement.cpp and TextFieldDecorationElement.h
346         * dom/Element.h:
347         (WebCore::Element::isTextFieldDecoration):
348         * html/TextFieldInputType.cpp:
349         (WebCore::TextFieldInputType::createShadowSubtree):
350         Calls ChromeClient::willAddTextFieldDecorationsTo() and addTextFieldDecorationsTo().
351         * html/shadow/TextFieldDecorationElement.cpp: Added.
352         (WebCore::TextFieldDecorator::~TextFieldDecorator):
353         (WebCore::TextFieldDecorationElement::TextFieldDecorationElement):
354         (WebCore::TextFieldDecorationElement::create):
355         (WebCore::TextFieldDecorationElement::isTextFieldDecoration):
356         (WebCore::TextFieldDecorationElement::updateImage):
357         (WebCore::TextFieldDecorationElement::customStyleForRenderer):
358         Sets the size to a square of the font-size.
359         (WebCore::TextFieldDecorationElement::createRenderer):
360         Always creates a RenderImage.
361         (WebCore::TextFieldDecorationElement::attach):
362         Sets an image for appropriate state.
363         (WebCore::TextFieldDecorationElement::isMouseFocusable):
364         (WebCore::TextFieldDecorationElement::defaultEventHandler):
365         Delegate a click event to the corresponding function of TextFieldDecorator.
366         * html/shadow/TextFieldDecorationElement.h: Added.
367         (TextFieldDecorator): Added.
368         (TextFieldDecorationElement): Added.
369         (WebCore::toTextFieldDecorationElement): Added.
370         * page/ChromeClient.h:
371         (WebCore::ChromeClient::willAddTextFieldDecorationsTo): Add an empty implementation.
372         (WebCore::ChromeClient::addTextFieldDecorationsTo): ditto.
373
374 2012-03-23  Adam Klein  <adamk@chromium.org>
375
376         Match DOM4 spec with respect to DocumentFragment insertion
377         https://bugs.webkit.org/show_bug.cgi?id=82089
378
379         Reviewed by Ryosuke Niwa.
380
381         DOM4 specifies the behavior of appendChild, insertBefore, and replaceChild
382         in terms of "mutation algorithms":
383
384         http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#mutation-algorithms
385
386         This change updates WebKit to match, in particular with regard to DocumentFragments.
387         Previously, ContainerNode would remove nodes one at a time, then add them to the new parent.
388         When combined with MutationObservers, this results in overly-verbose mutation records.
389         Now we create as few records as possible, matching the spec as well as Gecko's implementation
390         of MutationObservers.
391
392         Note that we still need to check validity each time through the loop,
393         since inserting a node may dispatch events. In a future change, I hope
394         to move these events so that they fire only after all nodes are inserted,
395         but that's too much to tackle all in one.
396
397         Tests: fast/mutation/document-fragment-insertion.html
398
399         * dom/ContainerNode.cpp:
400         (WebCore::collectChildrenAndRemoveFromOldParent): New helper method
401         combining collectTargetNodes() with the removal of the collected nodes from
402         their old parent, if any.
403         (WebCore::ContainerNode::insertBefore): Use new helper method instead
404         of removing nodes one at a time from the fragment.
405         (WebCore::ContainerNode::replaceChild): ditto. Also removed some redundant asserts
406         and moved the "do nothing" check out of the loop.
407         (WebCore::ContainerNode::appendChild): Use new helper method.
408
409 2012-03-23  Stephen White  <senorblanco@chromium.org>
410
411         [skia] Switch to Skia's implementation of the feMorphology filter.
412         https://bugs.webkit.org/show_bug.cgi?id=82085
413
414         Reviewed by Dirk Schulze.
415
416         Covered by existing tests in svg/filters/.
417
418         * WebCore.gypi:
419         * platform/graphics/filters/FEMorphology.h:
420         (FEMorphology):
421         * platform/graphics/filters/skia/FEMorphologySkia.cpp: Added.
422         (WebCore):
423         (WebCore::FEMorphology::platformApplySkia):
424
425 2012-03-23  Adam Barth  <abarth@webkit.org>
426
427         Move Notifications APIs from DOMWindow.idl to DOMWindowNotifications.idl (Part 3)
428         https://bugs.webkit.org/show_bug.cgi?id=82027
429
430         Reviewed by Kentaro Hara.
431
432         Rather than watching for willDetachPage, NotificationCenter can just
433         override ActiveDOMObject::stop directly to be notified when it needs to
434         stop.
435
436         Switching NotificationCenter over to using ActiveDOMObject callbacks
437         frees DOMWindowNotification to implement reconnectFrame.  However, this
438         is only really a victory in princple because NotificationCenter always
439         returns false for canSuspend(), which means we'll never actually use
440         the reconnectFrame functionality.  However, this patch does move us
441         closer to the time when NotificationCenter can implement
442         ActiveDOMObject::suspend/resume to play nice with the PageCache.
443
444         * notifications/DOMWindowNotifications.cpp:
445         (WebCore::DOMWindowNotifications::disconnectFrame):
446         (WebCore::DOMWindowNotifications::reconnectFrame):
447         * notifications/DOMWindowNotifications.h:
448         (DOMWindowNotifications):
449         * notifications/NotificationCenter.cpp:
450         (WebCore::NotificationCenter::NotificationCenter):
451         (WebCore::NotificationCenter::stop):
452         * notifications/NotificationCenter.h:
453         (NotificationCenter):
454
455 2012-03-23  Daniel Cheng  <dcheng@chromium.org>
456
457         [chromium] Support file drag out using DataTransferItemList::add(File)
458         https://bugs.webkit.org/show_bug.cgi?id=81261
459
460         Reviewed by Tony Chang.
461
462         Original patch by Varun Jain <varunjain@chromium.org>.
463         I've updated the original patch to remove 'downloadurl' handling since it's not tested, nor
464         is it necessary for File objects, since File objects correspond to a native filesystem path.
465
466         Test: fast/events/drag-dataTransferItemList-file-handling.html
467
468         * platform/chromium/DataTransferItemListChromium.cpp:
469         (WebCore::DataTransferItemListChromium::add):
470
471 2012-03-23  Zan Dobersek  <zandobersek@gmail.com>
472
473         [GObject bindings] Supplemental interfaces are not disabled with the "Conditional" attribute
474         https://bugs.webkit.org/show_bug.cgi?id=80030
475
476         Reviewed by Martin Robinson.
477
478         Changes in CodeGeneratorGObject.pm:
479         - group implementation of private helpers and guard them inside
480         an ifdef if a root conditional attribute is present.
481         - always define the type of a GObject binding, even if the root
482         conditional feature is not enabled
483         - the methods are generated as well, but are simply stubs if the
484         feature is not enabled, throwing a warning upon interaction.
485         - if the method itself is guarded by a conditional attribute,
486         the stub implementation gains one more level of depth, throwing
487         a warning if the method's conditional feature is not enabled
488         but the root conditional feature is.
489         - small style fixes in random places.
490
491         Also changed are GObject baselines for binding tests.
492
493         No new tests - no new testable functionality.
494
495         * bindings/gobject/GNUmakefile.am:
496         * bindings/scripts/CodeGeneratorGObject.pm:
497         (HumanReadableConditional):
498         (GenerateConditionalWarn):
499         (GenerateProperty):
500         (GenerateProperties):
501         (GenerateFunction):
502         (GenerateFunctions):
503         (GenerateCFile):
504         (GenerateEventTargetIface):
505         (Generate):
506         (WriteData):
507         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
508         (WebKit):
509         (WebKit::kit):
510         (WebKit::wrapFloat64Array):
511         (webkit_dom_float64array_finalize):
512         (webkit_dom_float64array_foo):
513         * bindings/scripts/test/GObject/WebKitDOMFloat64ArrayPrivate.h:
514         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
515         (WebKit):
516         (WebKit::kit):
517         (WebKit::wrapTestActiveDOMObject):
518         (webkit_dom_test_active_dom_object_finalize):
519         (webkit_dom_test_active_dom_object_exciting_function):
520         (webkit_dom_test_active_dom_object_post_message):
521         (webkit_dom_test_active_dom_object_get_exciting_attr):
522         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObjectPrivate.h:
523         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
524         (WebKit):
525         (WebKit::kit):
526         (WebKit::core):
527         (WebKit::wrapTestCallback):
528         (webkit_dom_test_callback_finalize):
529         (webkit_dom_test_callback_callback_with_no_param):
530         (webkit_dom_test_callback_callback_with_class1param):
531         (webkit_dom_test_callback_callback_with_class2param):
532         (webkit_dom_test_callback_callback_with_non_bool_return_type):
533         (webkit_dom_test_callback_callback_with_string_list):
534         * bindings/scripts/test/GObject/WebKitDOMTestCallbackPrivate.h:
535         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
536         (WebKit):
537         (WebKit::kit):
538         (WebKit::wrapTestCustomNamedGetter):
539         (webkit_dom_test_custom_named_getter_finalize):
540         (webkit_dom_test_custom_named_getter_another_function):
541         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetterPrivate.h:
542         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
543         (WebKit):
544         (WebKit::kit):
545         (WebKit::wrapTestEventConstructor):
546         (webkit_dom_test_event_constructor_finalize):
547         (webkit_dom_test_event_constructor_get_attr1):
548         (webkit_dom_test_event_constructor_get_attr2):
549         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructorPrivate.h:
550         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
551         (WebKit):
552         (WebKit::core):
553         (WebKit::wrapTestEventTarget):
554         (webkit_dom_test_event_target_finalize):
555         (webkit_dom_test_event_target_item):
556         (webkit_dom_test_event_target_dispatch_event):
557         * bindings/scripts/test/GObject/WebKitDOMTestEventTargetPrivate.h:
558         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
559         (WebKit):
560         (WebKit::kit):
561         (WebKit::core):
562         (WebKit::wrapTestInterface):
563         (webkit_dom_test_interface_finalize):
564         (webkit_dom_test_interface_supplemental_method1):
565         (webkit_dom_test_interface_supplemental_method2):
566         (webkit_dom_test_interface_supplemental_method4):
567         (webkit_dom_test_interface_get_supplemental_str1):
568         (webkit_dom_test_interface_get_supplemental_str2):
569         (webkit_dom_test_interface_set_supplemental_str2):
570         (webkit_dom_test_interface_get_supplemental_node):
571         (webkit_dom_test_interface_set_supplemental_node):
572         * bindings/scripts/test/GObject/WebKitDOMTestInterfacePrivate.h:
573         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
574         (WebKit):
575         (WebKit::kit):
576         (WebKit::wrapTestMediaQueryListListener):
577         (webkit_dom_test_media_query_list_listener_finalize):
578         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListenerPrivate.h:
579         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
580         (WebKit):
581         (WebKit::kit):
582         (WebKit::wrapTestNamedConstructor):
583         (webkit_dom_test_named_constructor_finalize):
584         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructorPrivate.h:
585         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
586         (WebKit):
587         (WebKit::kit):
588         (WebKit::core):
589         (WebKit::wrapTestObj):
590         (webkit_dom_test_obj_finalize):
591         (webkit_dom_test_obj_set_property):
592         (webkit_dom_test_obj_get_property):
593         (webkit_dom_test_obj_constructed):
594         (webkit_dom_test_obj_class_init):
595         (webkit_dom_test_obj_init):
596         (webkit_dom_test_obj_void_method):
597         (webkit_dom_test_obj_void_method_with_args):
598         (webkit_dom_test_obj_int_method):
599         (webkit_dom_test_obj_int_method_with_args):
600         (webkit_dom_test_obj_obj_method):
601         (webkit_dom_test_obj_obj_method_with_args):
602         (webkit_dom_test_obj_method_with_sequence_arg):
603         (webkit_dom_test_obj_method_that_requires_all_args_and_throws):
604         (webkit_dom_test_obj_serialized_value):
605         (webkit_dom_test_obj_idb_key):
606         (webkit_dom_test_obj_options_object):
607         (webkit_dom_test_obj_method_with_exception):
608         (webkit_dom_test_obj_with_script_state_void):
609         (webkit_dom_test_obj_with_script_state_obj):
610         (webkit_dom_test_obj_with_script_state_void_exception):
611         (webkit_dom_test_obj_with_script_state_obj_exception):
612         (webkit_dom_test_obj_with_script_execution_context):
613         (webkit_dom_test_obj_with_script_execution_context_and_script_state):
614         (webkit_dom_test_obj_with_script_execution_context_and_script_state_obj_exception):
615         (webkit_dom_test_obj_with_script_execution_context_and_script_state_with_spaces):
616         (webkit_dom_test_obj_method_with_optional_arg):
617         (webkit_dom_test_obj_method_with_non_optional_arg_and_optional_arg):
618         (webkit_dom_test_obj_method_with_non_optional_arg_and_two_optional_args):
619         (webkit_dom_test_obj_method_with_optional_string):
620         (webkit_dom_test_obj_method_with_optional_string_is_undefined):
621         (webkit_dom_test_obj_method_with_optional_string_is_null_string):
622         (webkit_dom_test_obj_conditional_method1):
623         (webkit_dom_test_obj_conditional_method2):
624         (webkit_dom_test_obj_conditional_method3):
625         (webkit_dom_test_obj_class_method):
626         (webkit_dom_test_obj_class_method_with_optional):
627         (webkit_dom_test_obj_overloaded_method1):
628         (webkit_dom_test_obj_convert1):
629         (webkit_dom_test_obj_convert2):
630         (webkit_dom_test_obj_convert3):
631         (webkit_dom_test_obj_convert4):
632         (webkit_dom_test_obj_convert5):
633         (webkit_dom_test_obj_mutable_point_function):
634         (webkit_dom_test_obj_immutable_point_function):
635         (webkit_dom_test_obj_orange):
636         (webkit_dom_test_obj_strict_function):
637         (webkit_dom_test_obj_get_read_only_int_attr):
638         (webkit_dom_test_obj_get_read_only_string_attr):
639         (webkit_dom_test_obj_get_read_only_test_obj_attr):
640         (webkit_dom_test_obj_get_short_attr):
641         (webkit_dom_test_obj_set_short_attr):
642         (webkit_dom_test_obj_get_unsigned_short_attr):
643         (webkit_dom_test_obj_set_unsigned_short_attr):
644         (webkit_dom_test_obj_get_int_attr):
645         (webkit_dom_test_obj_set_int_attr):
646         (webkit_dom_test_obj_get_long_long_attr):
647         (webkit_dom_test_obj_set_long_long_attr):
648         (webkit_dom_test_obj_get_unsigned_long_long_attr):
649         (webkit_dom_test_obj_set_unsigned_long_long_attr):
650         (webkit_dom_test_obj_get_string_attr):
651         (webkit_dom_test_obj_set_string_attr):
652         (webkit_dom_test_obj_get_test_obj_attr):
653         (webkit_dom_test_obj_set_test_obj_attr):
654         (webkit_dom_test_obj_get_xml_obj_attr):
655         (webkit_dom_test_obj_set_xml_obj_attr):
656         (webkit_dom_test_obj_get_create):
657         (webkit_dom_test_obj_set_create):
658         (webkit_dom_test_obj_get_reflected_string_attr):
659         (webkit_dom_test_obj_set_reflected_string_attr):
660         (webkit_dom_test_obj_get_reflected_integral_attr):
661         (webkit_dom_test_obj_set_reflected_integral_attr):
662         (webkit_dom_test_obj_get_reflected_unsigned_integral_attr):
663         (webkit_dom_test_obj_set_reflected_unsigned_integral_attr):
664         (webkit_dom_test_obj_get_reflected_boolean_attr):
665         (webkit_dom_test_obj_set_reflected_boolean_attr):
666         (webkit_dom_test_obj_get_reflected_url_attr):
667         (webkit_dom_test_obj_set_reflected_url_attr):
668         (webkit_dom_test_obj_get_reflected_custom_integral_attr):
669         (webkit_dom_test_obj_set_reflected_custom_integral_attr):
670         (webkit_dom_test_obj_get_reflected_custom_boolean_attr):
671         (webkit_dom_test_obj_set_reflected_custom_boolean_attr):
672         (webkit_dom_test_obj_get_reflected_custom_url_attr):
673         (webkit_dom_test_obj_set_reflected_custom_url_attr):
674         (webkit_dom_test_obj_get_attr_with_getter_exception):
675         (webkit_dom_test_obj_set_attr_with_getter_exception):
676         (webkit_dom_test_obj_get_attr_with_setter_exception):
677         (webkit_dom_test_obj_set_attr_with_setter_exception):
678         (webkit_dom_test_obj_get_string_attr_with_getter_exception):
679         (webkit_dom_test_obj_set_string_attr_with_getter_exception):
680         (webkit_dom_test_obj_get_string_attr_with_setter_exception):
681         (webkit_dom_test_obj_set_string_attr_with_setter_exception):
682         (webkit_dom_test_obj_get_with_script_state_attribute):
683         (webkit_dom_test_obj_set_with_script_state_attribute):
684         (webkit_dom_test_obj_get_with_script_execution_context_attribute):
685         (webkit_dom_test_obj_set_with_script_execution_context_attribute):
686         (webkit_dom_test_obj_get_with_script_state_attribute_raises):
687         (webkit_dom_test_obj_set_with_script_state_attribute_raises):
688         (webkit_dom_test_obj_get_with_script_execution_context_attribute_raises):
689         (webkit_dom_test_obj_set_with_script_execution_context_attribute_raises):
690         (webkit_dom_test_obj_get_with_script_execution_context_and_script_state_attribute):
691         (webkit_dom_test_obj_set_with_script_execution_context_and_script_state_attribute):
692         (webkit_dom_test_obj_get_with_script_execution_context_and_script_state_attribute_raises):
693         (webkit_dom_test_obj_set_with_script_execution_context_and_script_state_attribute_raises):
694         (webkit_dom_test_obj_get_with_script_execution_context_and_script_state_with_spaces_attribute):
695         (webkit_dom_test_obj_set_with_script_execution_context_and_script_state_with_spaces_attribute):
696         (webkit_dom_test_obj_get_conditional_attr1):
697         (webkit_dom_test_obj_set_conditional_attr1):
698         (webkit_dom_test_obj_get_conditional_attr2):
699         (webkit_dom_test_obj_set_conditional_attr2):
700         (webkit_dom_test_obj_get_conditional_attr3):
701         (webkit_dom_test_obj_set_conditional_attr3):
702         (webkit_dom_test_obj_get_content_document):
703         (webkit_dom_test_obj_get_mutable_point):
704         (webkit_dom_test_obj_set_mutable_point):
705         (webkit_dom_test_obj_get_immutable_point):
706         (webkit_dom_test_obj_set_immutable_point):
707         (webkit_dom_test_obj_get_strict_float):
708         (webkit_dom_test_obj_set_strict_float):
709         (webkit_dom_test_obj_get_description):
710         (webkit_dom_test_obj_get_id):
711         (webkit_dom_test_obj_set_id):
712         (webkit_dom_test_obj_get_hash):
713         * bindings/scripts/test/GObject/WebKitDOMTestObjPrivate.h:
714         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
715         (WebKit):
716         (WebKit::kit):
717         (WebKit::core):
718         (WebKit::wrapTestSerializedScriptValueInterface):
719         (webkit_dom_test_serialized_script_value_interface_finalize):
720         (webkit_dom_test_serialized_script_value_interface_accept_transfer_list):
721         (webkit_dom_test_serialized_script_value_interface_multi_transfer_list):
722         (webkit_dom_test_serialized_script_value_interface_get_value):
723         (webkit_dom_test_serialized_script_value_interface_set_value):
724         (webkit_dom_test_serialized_script_value_interface_get_readonly_value):
725         (webkit_dom_test_serialized_script_value_interface_get_cached_value):
726         (webkit_dom_test_serialized_script_value_interface_set_cached_value):
727         (webkit_dom_test_serialized_script_value_interface_get_cached_readonly_value):
728         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterfacePrivate.h:
729
730 2012-03-23  Dana Jansens  <danakj@chromium.org>
731
732         [chromium] Record painted pixel counts for measuring effectiveness of per-tile painting
733         https://bugs.webkit.org/show_bug.cgi?id=82057
734
735         Reviewed by Adrienne Walker.
736
737         Adds painted pixel metrics to CCOverdrawMetrics class, and calls in
738         to report painted areas when updating tiles in the TiledLayerChromium
739         class.
740
741         Unit test: TiledLayerChromiumTest.opaqueContentsRegion
742                    TiledLayerChromiumTest.pixelsPaintedMetrics
743
744         * platform/graphics/chromium/TiledLayerChromium.cpp:
745         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
746         * platform/graphics/chromium/cc/CCOverdrawMetrics.cpp:
747         (WebCore::CCOverdrawMetrics::CCOverdrawMetrics):
748         (WebCore::CCOverdrawMetrics::didPaint):
749         (WebCore):
750         (WebCore::CCOverdrawMetrics::recordMetricsInternal):
751         * platform/graphics/chromium/cc/CCOverdrawMetrics.h:
752         (CCOverdrawMetrics):
753         (WebCore::CCOverdrawMetrics::pixelsPainted):
754
755 2012-03-23  Abhishek Arya  <inferno@chromium.org>
756
757         Crash in RenderBlock::splitBlocks.
758         https://bugs.webkit.org/show_bug.cgi?id=81926
759
760         Reviewed by Julien Chaffraix.
761
762         We are updating the :after content before calling splitFlow. The :after content
763         gets blown away since it will go to the continuation. beforeChild was earlier
764         set to the first child. Being the last anonymous block, its children gets pulled
765         up in collapseAnonymousBoxChild and it gets destroyed. So, we need to update
766         beforeChild value. 
767
768         Test: fast/multicol/span/update-after-content-before-child-crash.html
769
770         * rendering/RenderBlock.cpp:
771         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
772
773 2012-03-23  Dana Jansens  <danakj@chromium.org>
774
775         [chromium] Improved composited debug borders
776         https://bugs.webkit.org/show_bug.cgi?id=82071
777
778         Reviewed by Adrienne Walker.
779
780         Fix the problem with missing debug borders. Since we append quads
781         to the list front to back now, we draw the quads in the list from
782         back to front of the list. Which means if the debug quad is added
783         after the layer it is drawing around, the layer can draw over top
784         of its debug quad. Reverse the ordering when appending to fix it.
785
786         Make the border red around tiles that are checkerboarded. Missing
787         tiles in non-root layers are drawn clear, so this makes them more
788         visible.
789
790         Put a blue border around each render surface, and a purple border
791         on their replicas.
792
793         No new tests.
794
795         * platform/graphics/chromium/cc/CCRenderPass.cpp:
796         (WebCore):
797         (WebCore::CCRenderPass::appendQuadsForLayer):
798         (WebCore::CCRenderPass::appendQuadsForRenderSurfaceLayer):
799         * platform/graphics/chromium/cc/CCRenderSurface.cpp:
800         (WebCore::CCRenderSurface::hasReplica):
801         (WebCore):
802         (WebCore::CCRenderSurface::createReplicaSharedQuadState):
803         * platform/graphics/chromium/cc/CCRenderSurface.h:
804         (CCRenderSurface):
805         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
806         (WebCore):
807         (WebCore::CCTiledLayerImpl::appendQuads):
808
809 2012-03-23  Simon Fraser  <simon.fraser@apple.com>
810
811         Move code that calls setAcceleratesDrawing() on GraphicsLayers into RenderLayerBacking
812         https://bugs.webkit.org/show_bug.cgi?id=82092
813
814         Reviewed by Dean Jackson.
815
816         A RenderLayerBacking manages several GraphicsLayers, but RenderLayerCompositor
817         was only calling setAcceleratesDrawing() on the one it knows about. Fix by moving
818         this setting code down into RenderLayerBacking.
819         
820         RenderLayerCompositor now caches the setAcceleratesDrawing setting, as it does
821         for other compositing-related settings, so that RenderLayerBacking doesn't have
822         to grovel for Settings every time.
823
824         * rendering/RenderLayerBacking.cpp:
825         (WebCore::RenderLayerBacking::createGraphicsLayer):
826         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
827         * rendering/RenderLayerCompositor.cpp:
828         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
829         (WebCore::RenderLayerCompositor::cacheAcceleratedCompositingFlags):
830         (WebCore::RenderLayerCompositor::updateBacking):
831         * rendering/RenderLayerCompositor.h:
832         (WebCore::RenderLayerCompositor::acceleratedDrawingEnabled):
833         (RenderLayerCompositor):
834
835 2012-03-23  Beth Dakin  <bdakin@apple.com>
836
837         https://bugs.webkit.org/show_bug.cgi?id=82083
838
839         Rubber-stamped by Simon Fraser.
840
841         This patch is just a name change. getExistingScrollAnimator() (which was 
842         added earlier today) is now existingScrollAnimator().
843         * loader/FrameLoader.cpp:
844         (WebCore::FrameLoader::transitionToCommitted):
845         * page/EventHandler.cpp:
846         (WebCore::EventHandler::handleGestureTapDown):
847         * page/FrameView.cpp:
848         (WebCore::FrameView::setAnimatorsAreActive):
849         * platform/ScrollView.cpp:
850         (WebCore::ScrollView::updateScrollbars):
851         * platform/ScrollableArea.cpp:
852         (WebCore::ScrollableArea::willStartLiveResize):
853         (WebCore::ScrollableArea::willEndLiveResize):
854         (WebCore::ScrollableArea::contentAreaWillPaint):
855         (WebCore::ScrollableArea::mouseEnteredContentArea):
856         (WebCore::ScrollableArea::mouseExitedContentArea):
857         (WebCore::ScrollableArea::mouseMovedInContentArea):
858         (WebCore::ScrollableArea::contentAreaDidShow):
859         (WebCore::ScrollableArea::contentAreaDidHide):
860         (WebCore::ScrollableArea::contentsResized):
861         (WebCore::ScrollableArea::serviceScrollAnimations):
862         * platform/ScrollableArea.h:
863         (WebCore::ScrollableArea::existingScrollAnimator):
864
865 2012-03-23  Abhishek Arya  <inferno@chromium.org>
866
867         Crash due to accessing removed parent lineboxes when clearing selection.
868         https://bugs.webkit.org/show_bug.cgi?id=81359
869
870         Reviewed by Eric Seidel.
871
872         Similar to r110323, adds the canUpdateSelectionOnRootLineBoxes
873         check to more places.
874
875         Test: editing/selection/clear-selection-crash.html
876
877         * rendering/RenderObject.cpp:
878         (WebCore::RenderObject::canUpdateSelectionOnRootLineBoxes):
879         * rendering/RenderSelectionInfo.h:
880         (WebCore::RenderSelectionInfo::RenderSelectionInfo):
881         (WebCore::RenderBlockSelectionInfo::RenderBlockSelectionInfo):
882
883 2012-03-23  Beth Dakin  <bdakin@apple.com>
884
885         https://bugs.webkit.org/show_bug.cgi?id=82083
886         Too many ScrollAnimators are allocated on pages with frames
887
888         Reviewed by Geoffrey Garen.
889
890         This patch adds a new getter to ScrollableArea called 
891         getExistingScrollAnimator() unlike scrollAnimator() this new function will 
892         just return null if there is not already a ScrollAnimator. Callers should use 
893         this new function when they have business with ScrollAnimator that does not 
894         need to do anything when there are no scrollbars.
895         * loader/FrameLoader.cpp:
896         (WebCore::FrameLoader::transitionToCommitted):
897         * page/EventHandler.cpp:
898         (WebCore::EventHandler::handleGestureTapDown):
899         * page/FrameView.cpp:
900         (WebCore::FrameView::setAnimatorsAreActive):
901         * platform/ScrollView.cpp:
902         (WebCore::ScrollView::updateScrollbars):
903         * platform/ScrollableArea.cpp:
904         (WebCore::ScrollableArea::willStartLiveResize):
905         (WebCore::ScrollableArea::willEndLiveResize):
906         (WebCore::ScrollableArea::contentAreaWillPaint):
907         (WebCore::ScrollableArea::mouseEnteredContentArea):
908         (WebCore::ScrollableArea::mouseExitedContentArea):
909         (WebCore::ScrollableArea::mouseMovedInContentArea):
910         (WebCore::ScrollableArea::contentAreaDidShow):
911         (WebCore::ScrollableArea::contentAreaDidHide):
912         (WebCore::ScrollableArea::willRemoveHorizontalScrollbar):
913         (WebCore::ScrollableArea::contentsResized):
914         (WebCore::ScrollableArea::serviceScrollAnimations):
915         * platform/ScrollableArea.h:
916         (ScrollableArea):
917         (WebCore::ScrollableArea::getExistingScrollAnimator):
918
919 2012-03-23  Eric Carlson  <eric.carlson@apple.com>
920
921         Deal with DOM modifications when evaluating source elements.
922         https://bugs.webkit.org/show_bug.cgi?id=81163
923
924         Reviewed by Alexey Proskuryakov.
925
926         Test: media/video-beforeload-remove-source.html
927
928         * dom/ContainerNode.cpp: Make NodeVector and collectNodes public, renamed as getChildNodes.
929         (WebCore::ContainerNode::takeAllChildrenFrom): collectNodes -> getChildNodes.
930         (WebCore::ContainerNode::willRemove): collectNodes -> getChildNodes.
931         (WebCore::ContainerNode::willRemoveChildren): collectNodes -> getChildNodes.
932         (WebCore::ContainerNode::insertedIntoDocument): collectNodes -> getChildNodes.
933         (WebCore::ContainerNode::removedFromDocument): collectNodes -> getChildNodes.
934         * dom/ContainerNode.h:
935         (WebCore::getChildNodes):
936
937         * editing/ReplaceSelectionCommand.cpp: Remove unused NodeVector declaration.
938
939         * html/HTMLMediaElement.cpp:
940         (WebCore::HTMLMediaElement::HTMLMediaElement): m_nextChildNodeToConsider and m_currentSourceNode
941             are now RefPtrs.
942         (WebCore::HTMLMediaElement::loadTimerFired): Protect HTMLMediaElement from being deleted during
943             a DOM modification during an event callback.
944         (WebCore::HTMLMediaElement::load): Ditto.
945         (WebCore::HTMLMediaElement::selectMediaResource): Set m_nextChildNodeToConsider to the first
946             child node, it will be the first node considered.
947         (WebCore::HTMLMediaElement::havePotentialSourceChild): m_nextChildNodeToConsider and m_currentSourceNode
948             are now RefPtrs.
949         (WebCore::HTMLMediaElement::selectNextSourceChild): Collect all child nodes in a vector before
950             looking for <source> nodes because 'beforeload' event handlers can mutate the DOM. Don't
951             use a <source> that is no longer a child node after 'beforeload'. Use 0 to represent the end
952             of the child node list because m_nextChildNodeToConsider is now a RefPtr so using the previous 
953             sentinel, "this", would cause a retain cycle.
954         (WebCore::HTMLMediaElement::sourceWasAdded):  m_nextChildNodeToConsider and m_currentSourceNode
955             are now RefPtrs.
956         (WebCore::HTMLMediaElement::sourceWillBeRemoved): Ditto.
957         (WebCore::HTMLMediaElement::getPluginProxyParams): Protect HTMLMediaElement from being deleted during
958             a DOM modification during an event callback.
959         * html/HTMLMediaElement.h:
960
961 2012-03-23  Dean Jackson  <dino@apple.com>
962
963         Disable CSS_SHADERS in Apple builds
964         https://bugs.webkit.org/show_bug.cgi?id=81996
965
966         Reviewed by Simon Fraser.
967
968         Remove ENABLE_CSS_SHADERS from FeatureDefines. It's now in Platform.h.
969
970         * Configurations/FeatureDefines.xcconfig:
971
972 2012-03-23  Dave Michael  <dmichael@chromium.org>
973
974         Relanding(r111754): HTMLPluginElement is not destroyed on reload or navigation if getNPObject is called
975         https://bugs.webkit.org/show_bug.cgi?id=80428
976
977         Reviewed by Eric Seidel and Ryosuke Niwa.
978
979         Make HTMLPluginElement release its m_NPObject in detach() to break a
980         reference-counting cycle that happens on reload or navigation. With this
981         change, HTMLPlugInElement::removedFromDocument is unnecessary, so it
982         was removed. Note that Releasing m_NPObject does not result in a call to
983         the plugin; it simply releases a reference count on the wrapper object
984         for this HTMLPlugInElement. (The plugin's NPP_Deallocate is invoked
985         when the render tree is destroyed, when PluginView calls
986         PluginPackage::unload.) Thus, it is safe to release m_NPObject in
987         detach, because it can not result in layout or style changes.
988
989         Also added numberOfLiveNodes() and numberOfLiveDocuments() to
990         window.internals to enable testing.
991
992         Test: plugins/netscape-dom-access-and-reload.html
993
994         * WebCore.exp.in:
995         * html/HTMLPlugInElement.cpp:
996         (WebCore::HTMLPlugInElement::detach):
997         * html/HTMLPlugInElement.h:
998         (HTMLPlugInElement):
999         * testing/Internals.cpp:
1000         (WebCore):
1001         (WebCore::Internals::numberOfLiveNodes):
1002         (WebCore::Internals::numberOfLiveDocuments):
1003         * testing/Internals.h:
1004         (Internals):
1005         * testing/Internals.idl:
1006
1007 2012-03-23  Ryosuke Niwa  <rniwa@webkit.org>
1008
1009         CSSParser doesn't set border-*-width/style/color to initial by border shorthand property
1010         https://bugs.webkit.org/show_bug.cgi?id=82040
1011
1012         Reviewed by Antti Koivisto.
1013
1014         The border shorthand property sets values for border-width, border-style, and border-color shorthand properties.
1015         While CSSParser::parseValue can process these shorthand properties properly and set the longhand properties
1016         such as border-top-width, border-right-width, ... border-left-color, CSSParser::addProperty can't and the
1017         initialization in parseShorthand fails for the border property.
1018
1019         Fixed the bug by explicitly initializing longhand properties.
1020
1021         Changing the behavior here is unlikely to break the Web since our behavior already differs from that of Firefox
1022         and Internet Explorer. Both of those browsers return the actual initial values such as "medium" and "currentColor".
1023         This discrepancy is tracked by https://bugs.webkit.org/show_bug.cgi?id=82078.
1024
1025         Test: fast/css/border-shorthand-initialize-longhands.html
1026
1027         * css/CSSParser.cpp:
1028         (WebCore::CSSParser::parseValue): Uses borderAbridgedLonghand.
1029         (WebCore::CSSParser::parseShorthand): Uses longhand properties for initialization if one is available.
1030         This allows us to initialize multiple properties (e.g. border-*-color) for a single property missing in the set.
1031         * css/CSSPropertyLonghand.cpp:
1032         (WebCore::borderAbridgedLonghand): Added. The longhand here (border-width, border-style, border-color) is
1033         "abridged" in the sense that they're still shorthands.
1034         * css/CSSPropertyLonghand.h:
1035         (WebCore::CSSPropertyLonghand::CSSPropertyLonghand):
1036         (CSSPropertyLonghand): Added the version that takes longhand instances for initialization purposes.
1037         (WebCore::CSSPropertyLonghand::longhandsForInitialization):
1038
1039 2012-03-23  Tony Chang  <tony@chromium.org>
1040
1041         [chromium] rename newwtf target back to wtf
1042         https://bugs.webkit.org/show_bug.cgi?id=82064
1043
1044         Reviewed by Adam Barth.
1045
1046         No new tests, only renaming a build target.
1047
1048         * WebCore.gyp/WebCore.gyp:
1049
1050 2012-03-23  Adrienne Walker  <enne@google.com>
1051
1052         [chromium] Turn off painting of scrollbars on compositor thread for unsupported platforms
1053         https://bugs.webkit.org/show_bug.cgi?id=82066
1054
1055         Reviewed by James Robinson.
1056
1057         With threaded compositing, OSX will crash and Windows will have black
1058         scrollbars. Fix that by reverting to the previosu behavior of updating
1059         scrollbars on the main thread instead.
1060
1061         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
1062         (WebCore::scrollbarLayerDidChange):
1063
1064 2012-03-23  Dan Bernstein  <mitz@apple.com>
1065
1066         <rdar://problem/7883987> ASSERTION FAILED: ASSERT(input == AnimationStateInputEndTimerFired || input == AnimationStateInputPlayStatePaused) in AnimationBase::updateStateMachine causing multiple "crashes" on Lion Intel Debug WebKit testers
1067         https://bugs.webkit.org/show_bug.cgi?id=81351
1068
1069         Rubber-stamped by Jessie Berlin.
1070
1071         * page/animation/AnimationBase.cpp:
1072         (WebCore::AnimationBase::updateStateMachine): Replaced the assertion with a LOG_ERROR so that
1073         the issue is still noticeable, but it does not automatically make the debug bots red.
1074
1075 2012-03-23  Mike Lawther  <mikelawther@chromium.org>
1076
1077         CSS3 calc: image sizing works with mixed percentage/absolute
1078         https://bugs.webkit.org/show_bug.cgi?id=82017
1079
1080         Reviewed by Ojan Vafai.
1081
1082         Test: css3/calc/img-size-expected.html
1083
1084         * rendering/RenderBox.cpp:
1085         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
1086         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
1087
1088 2012-03-23  Julien Chaffraix  <jchaffraix@webkit.org>
1089
1090         REGRESSION(107971): Google Voice contact list is broken in WebKit due to badly allocating the extra height
1091         https://bugs.webkit.org/show_bug.cgi?id=81826
1092
1093         Reviewed by Tony Chang.
1094
1095         Covered by tables/mozilla/bugs/bug27038-{1|2}.html.
1096
1097         This partly reverts r107971: the extra logical height distribution change was not needed
1098         to fix the bug (it is needed by the test though). We revert to giving all the extra height
1099         to the first tbody and not the first section.
1100
1101         This is broken but unfortunately some websites are relying on that. Getting a real
1102         distribution algorithm is covered by bug 81824. However this is super tricky to get
1103         right and I did not want to add more compatibility risks until I have something solid.
1104
1105         * rendering/RenderTable.cpp:
1106         (WebCore::RenderTable::distributeExtraLogicalHeight):
1107
1108 2012-03-23  Xingnan Wang  <xingnan.wang@intel.com>
1109
1110         Optimize for IPP in DirectConvolver::process()
1111         https://bugs.webkit.org/show_bug.cgi?id=80255
1112
1113         Reviewed by Chris Rogers.
1114
1115         Increase ~2X performance by conv() in IPP.
1116
1117         * platform/audio/DirectConvolver.cpp:
1118         (WebCore::DirectConvolver::DirectConvolver):
1119         (WebCore::DirectConvolver::process):
1120         * platform/audio/DirectConvolver.h:
1121         (DirectConvolver):
1122
1123 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
1124
1125         MediaStream API (JSEP): Introducing PeerConnection00 and IceCallback
1126         https://bugs.webkit.org/show_bug.cgi?id=81657
1127
1128         Reviewed by Adam Barth.
1129
1130         Last major WebCore patch for the JSEP PeerConnection, together with the associated
1131         IceCallback (they both depend on each other and IceCallback has very few lines of real code).
1132
1133         My next patch after this one will do a major overhaul of the existing layout tests
1134         and add a few new ones.
1135
1136         * GNUmakefile.list.am:
1137         * Modules/mediastream/DOMWindowMediaStream.idl:
1138         * Modules/mediastream/IceCallback.h: Added.
1139         (WebCore):
1140         (IceCallback):
1141         (WebCore::IceCallback::~IceCallback):
1142         * Modules/mediastream/IceCallback.idl: Added.
1143         * Modules/mediastream/PeerConnection00.cpp: Added.
1144         (WebCore):
1145         (WebCore::PeerConnection00::create):
1146         (WebCore::PeerConnection00::PeerConnection00):
1147         (WebCore::PeerConnection00::~PeerConnection00):
1148         (WebCore::PeerConnection00::hasLocalAudioTrack):
1149         (WebCore::PeerConnection00::hasLocalVideoTrack):
1150         (WebCore::PeerConnection00::parseMediaHints):
1151         (WebCore::PeerConnection00::createOffer):
1152         (WebCore::PeerConnection00::createAnswer):
1153         (WebCore::PeerConnection00::setLocalDescription):
1154         (WebCore::PeerConnection00::setRemoteDescription):
1155         (WebCore::PeerConnection00::localDescription):
1156         (WebCore::PeerConnection00::remoteDescription):
1157         (WebCore::PeerConnection00::startIce):
1158         (WebCore::PeerConnection00::processIceMessage):
1159         (WebCore::PeerConnection00::readyState):
1160         (WebCore::PeerConnection00::iceState):
1161         (WebCore::PeerConnection00::addStream):
1162         (WebCore::PeerConnection00::removeStream):
1163         (WebCore::PeerConnection00::localStreams):
1164         (WebCore::PeerConnection00::remoteStreams):
1165         (WebCore::PeerConnection00::close):
1166         (WebCore::PeerConnection00::didGenerateIceCandidate):
1167         (WebCore::PeerConnection00::didChangeReadyState):
1168         (WebCore::PeerConnection00::didChangeIceState):
1169         (WebCore::PeerConnection00::didAddRemoteStream):
1170         (WebCore::PeerConnection00::didRemoveRemoteStream):
1171         (WebCore::PeerConnection00::interfaceName):
1172         (WebCore::PeerConnection00::scriptExecutionContext):
1173         (WebCore::PeerConnection00::stop):
1174         (WebCore::PeerConnection00::eventTargetData):
1175         (WebCore::PeerConnection00::ensureEventTargetData):
1176         (WebCore::PeerConnection00::changeReadyState):
1177         (WebCore::PeerConnection00::changeIceState):
1178         * Modules/mediastream/PeerConnection00.h: Added.
1179         (WebCore):
1180         (PeerConnection00):
1181         (WebCore::PeerConnection00::refEventTarget):
1182         (WebCore::PeerConnection00::derefEventTarget):
1183         * Modules/mediastream/PeerConnection00.idl: Added.
1184         * WebCore.gypi:
1185         * bindings/generic/RuntimeEnabledFeatures.h:
1186         (WebCore::RuntimeEnabledFeatures::webkitPeerConnection00Enabled):
1187         * bindings/js/JSPeerConnection00Custom.cpp: Added.
1188         (WebCore):
1189         (WebCore::JSPeerConnection00Constructor::constructJSPeerConnection00):
1190         * dom/EventTargetFactory.in:
1191
1192 2012-03-23  Adrienne Walker  <enne@google.com>
1193
1194         [chromium] Fix scrollbarLayerLostContext flaky test crash on 10.6
1195         https://bugs.webkit.org/show_bug.cgi?id=82062
1196
1197         Reviewed by James Robinson.
1198
1199         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
1200         (CCScrollbarLayerImpl):
1201
1202 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
1203
1204         [chromium] MediaStream API (JSEP): Extending WebMediaStreamCenter
1205         https://bugs.webkit.org/show_bug.cgi?id=81924
1206
1207         Reviewed by Adam Barth.
1208
1209         Nothing to test, just moving methods.
1210
1211         * platform/mediastream/MediaStreamCenter.cpp:
1212         (WebCore::MediaStreamCenter::constructSDP):
1213         (WebCore):
1214
1215 2012-03-23  Sami Kyostila  <skyostil@chromium.org>
1216
1217         Reuse buffer allocation if canvas size does not change
1218         https://bugs.webkit.org/show_bug.cgi?id=80871
1219
1220         Reviewed by Stephen White.
1221
1222         If the user changes the width or height attributes of a canvas element,
1223         the contents of the canvas should be cleared and the context state
1224         should be reset. This has become a common idiom to clear the canvas
1225         "efficiently" at the start of a frame.
1226
1227         Previously, this code path triggered a full reallocation of the image
1228         buffer backing the canvas, leading to reduced performance. This patch
1229         implements an optimization where we reuse the previous image buffer
1230         allocation if the size of the canvas did not change. Also, instead of
1231         clearing the canvas every time its dimensions are touched, we only clear
1232         if anything has been drawn into the canvas since it was previously
1233         cleared.
1234
1235         Note that for now this optimization only applies for 2D canvases,
1236         since it is not entirely clear how touching the dimensions of a WebGL
1237         canvas should work.
1238
1239         Test: fast/canvas/canvas-resize-after-paint-without-layout.html +
1240               existing layout tests for canvas resetting.
1241
1242         * html/HTMLCanvasElement.cpp:
1243         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
1244         (WebCore::HTMLCanvasElement::reset):
1245         (WebCore::HTMLCanvasElement::createImageBuffer): Save the initial
1246         graphics context state so we can restore it without creating a new
1247         context.
1248         (WebCore::HTMLCanvasElement::clearImageBuffer):
1249         (WebCore):
1250         (WebCore::HTMLCanvasElement::clearCopiedImage):
1251         * html/HTMLCanvasElement.h:
1252         (HTMLCanvasElement):
1253         * html/canvas/CanvasRenderingContext2D.cpp:
1254         (WebCore::CanvasRenderingContext2D::reset): No need to notify the
1255         compositor when the context is reset, because clearing the image buffer
1256         does the same thing. We can also skip the notification if we did not
1257         have an image buffer at the time of the reset, because the reset will
1258         not have any visual impact in this case. Finally, if the canvas size
1259         did change, the notification is also unnecessary because of the call
1260         to RenderObject::repaint() from HTMLCanvasElement::reset().
1261
1262 2012-03-22  Martin Robinson  <mrobinson@igalia.com>
1263
1264         Fix some code generation warnings on GTK+.
1265
1266         Reviewed by Gustavo Noronha Silva.
1267
1268         No new tests. This just fixes warnings.
1269
1270         * GNUmakefile.am: Remove nonexistent directories from the list IDL directories.
1271
1272 2012-03-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1273
1274         Unreviewed, rolling out r111751.
1275         http://trac.webkit.org/changeset/111751
1276         https://bugs.webkit.org/show_bug.cgi?id=82060
1277
1278         caused 15% page cycler regression for chromium-linux
1279         (Requested by eae on #webkit).
1280
1281         * css/CSSStyleSelector.cpp:
1282         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
1283
1284 2012-03-23  Kentaro Hara  <haraken@chromium.org>
1285
1286         Support [ImplementedAs] for attributes
1287         https://bugs.webkit.org/show_bug.cgi?id=81605
1288
1289         Reviewed by Adam Barth.
1290
1291         [ImplementedAs] just supports methods. [ImplementedAs] should support
1292         attributes too.
1293
1294         Explained here: https://trac.webkit.org/wiki/WebKitIDL#ImplementedAs
1295
1296         Test: bindings/scripts/test/TestObj.idl
1297
1298         * bindings/scripts/CodeGenerator.pm: Modified to support [ImplementedAs] for attributes.
1299         (AttributeNameForGetterAndSetter):
1300
1301         * bindings/scripts/test/TestObj.idl: Added a test case.
1302
1303         * bindings/scripts/test/CPP/WebDOMTestObj.cpp: Updated run-bindings-tests results.
1304         (WebDOMTestObj::strawberry):
1305         (WebDOMTestObj::setStrawberry):
1306         * bindings/scripts/test/CPP/WebDOMTestObj.h:
1307         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
1308         (webkit_dom_test_obj_get_strawberry):
1309         (webkit_dom_test_obj_set_strawberry):
1310         (webkit_dom_test_obj_get_property):
1311         (webkit_dom_test_obj_class_init):
1312         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
1313         * bindings/scripts/test/JS/JSTestObj.cpp:
1314         (WebCore):
1315         (WebCore::jsTestObjStrawberry):
1316         (WebCore::setJSTestObjStrawberry):
1317         * bindings/scripts/test/JS/JSTestObj.h:
1318         (WebCore):
1319         * bindings/scripts/test/ObjC/DOMTestObj.h:
1320         * bindings/scripts/test/ObjC/DOMTestObj.mm:
1321         (-[DOMTestObj strawberry]):
1322         (-[DOMTestObj setStrawberry:]):
1323         * bindings/scripts/test/V8/V8TestObj.cpp:
1324         (WebCore::TestObjInternal::strawberryAttrGetter):
1325         (TestObjInternal):
1326         (WebCore::TestObjInternal::strawberryAttrSetter):
1327         (WebCore):
1328
1329 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
1330
1331         The JSC code generator doesn't generate correct code for Constructors
1332         https://bugs.webkit.org/show_bug.cgi?id=82046
1333
1334         Reviewed by Kentaro Hara.
1335
1336         The main bulk of generated code for constructors uses the name jsConstructor
1337         for the created object, and then calls GenerateParametersCheck which generates
1338         code that uses the name castedThis.
1339
1340         * bindings/scripts/CodeGeneratorJS.pm:
1341         (GenerateConstructorDefinition):
1342         * bindings/scripts/test/JS/JSTestInterface.cpp:
1343         (WebCore::JSTestInterfaceConstructor::constructJSTestInterface):
1344         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
1345         (WebCore::JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor):
1346         * bindings/scripts/test/JS/JSTestObj.cpp:
1347         (WebCore::JSTestObjConstructor::finishCreation):
1348         (WebCore::JSTestObjConstructor::constructJSTestObj):
1349         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
1350         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::constructJSTestSerializedScriptValueInterface):
1351         * bindings/scripts/test/TestObj.idl:
1352         * bindings/scripts/test/V8/V8TestObj.cpp:
1353         (WebCore::V8TestObj::constructorCallback):
1354
1355 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
1356
1357         The JSC code generator can't handle boolean arguments for Callbacks
1358         https://bugs.webkit.org/show_bug.cgi?id=82045
1359
1360         Reviewed by Kentaro Hara.
1361
1362         CodeGeneratorJS.pm only handles DOMStrings and objects as arguments
1363         for a Callback, so I added support for boolean values as well.
1364
1365         * bindings/scripts/CodeGeneratorJS.pm:
1366         (GenerateCallbackImplementation):
1367         * bindings/scripts/test/CPP/WebDOMTestCallback.cpp:
1368         (WebDOMTestCallback::callbackWithBoolean):
1369         * bindings/scripts/test/CPP/WebDOMTestCallback.h:
1370         (WebDOMTestCallback):
1371         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
1372         (webkit_dom_test_callback_callback_with_boolean):
1373         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
1374         * bindings/scripts/test/JS/JSTestCallback.cpp:
1375         (WebCore::JSTestCallback::callbackWithBoolean):
1376         (WebCore):
1377         * bindings/scripts/test/JS/JSTestCallback.h:
1378         (JSTestCallback):
1379         * bindings/scripts/test/ObjC/DOMTestCallback.h:
1380         * bindings/scripts/test/ObjC/DOMTestCallback.mm:
1381         (-[DOMTestCallback callbackWithBoolean:]):
1382         * bindings/scripts/test/TestCallback.idl:
1383         * bindings/scripts/test/V8/V8TestCallback.cpp:
1384         (WebCore::V8TestCallback::callbackWithBoolean):
1385         (WebCore):
1386         * bindings/scripts/test/V8/V8TestCallback.h:
1387         (V8TestCallback):
1388
1389 2012-03-23  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1390
1391         Touch adjustment forgets some subtarget quads.
1392         https://bugs.webkit.org/show_bug.cgi?id=82044
1393
1394         Reviewed by Kenneth Rohde Christiansen.
1395
1396         Do not uncritically skip all nodes that are ancestors to other test results.
1397         Instead return the inner-most element if multiple nodes have the same distance.
1398
1399         Test: touchadjustment/block-testing.html
1400
1401         * page/TouchAdjustment.cpp:
1402         (WebCore::TouchAdjustment::compileSubtargetList):
1403         (WebCore::TouchAdjustment::findNodeWithLowestDistanceMetric):
1404
1405 2012-03-23  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1406
1407         TouchAdjustment does not correct for frame position
1408         https://bugs.webkit.org/show_bug.cgi?id=82043
1409
1410         Reviewed by Kenneth Rohde Christiansen.
1411
1412         Convert geometry to window coordinates before calculating distance.
1413
1414         Test: touchadjustment/iframe.html
1415
1416         * page/TouchAdjustment.cpp:
1417         (WebCore::TouchAdjustment::distanceSquaredToTargetCenterLine):
1418
1419 2012-03-23  Vlad Voicu  <vladv@rosedu.org>
1420
1421         Fixed minor WebInspector display issue
1422         Clicking on disabled sections in Styles Sidebar Pane creates new elements.
1423         https://bugs.webkit.org/show_bug.cgi?id=81925
1424
1425         Reviewed by Timothy Hatcher
1426
1427         No new tests should be required.
1428
1429         * inspector/front-end/StylesSidebarPane.js:
1430         (WebInspector.StylePropertiesSection.prototype._handleEmptySpaceClick):
1431         (WebInspector.StylePropertyTreeElement.prototype):
1432
1433 2012-03-23  Kentaro Hara  <haraken@chromium.org>
1434
1435         Unreviewed, rebaselined run-bindings-tests results.
1436
1437         * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
1438         * bindings/scripts/test/CPP/WebDOMTestObj.h:
1439         * bindings/scripts/test/JS/JSTestObj.cpp:
1440         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
1441         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
1442         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
1443         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
1444         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
1445         * bindings/scripts/test/V8/V8TestObj.cpp:
1446         (WebCore::TestObjInternal::methodWithCallbackArgCallback):
1447         (WebCore::TestObjInternal::methodWithNonCallbackArgAndCallbackArgCallback):
1448         (WebCore::TestObjInternal::methodWithCallbackAndOptionalArgCallback):
1449         (WebCore::TestObjInternal::overloadedMethod5Callback):
1450         (WebCore::TestObjInternal::overloadedMethodCallback):
1451
1452 2012-03-23  Ryosuke Niwa  <rniwa@webkit.org>
1453
1454         cssText should use StringBuilder
1455         https://bugs.webkit.org/show_bug.cgi?id=82028
1456
1457         Reviewed by Hajime Morita.
1458
1459         Make StylePropertySet::asText more efficient by deploying StringBuilder;
1460         avoids heap churn by String::operator+ and String::operator+=.
1461
1462         * css/StylePropertySet.cpp:
1463         (WebCore::StylePropertySet::asText):
1464
1465 2012-03-23  Ryosuke Niwa  <rniwa@webkit.org>
1466
1467         REGRESSION(r111754): plugins/reloadplugins-and-pages.html fails on all platforms
1468         https://bugs.webkit.org/show_bug.cgi?id=82035
1469
1470         Rollout r111754 since it caused a test to fail and the test added by the patch
1471         is failing on Mac WebKit 2.
1472
1473         * WebCore.exp.in:
1474         * html/HTMLPlugInElement.cpp:
1475         (WebCore::HTMLPlugInElement::detach):
1476         (WebCore):
1477         (WebCore::HTMLPlugInElement::removedFromDocument):
1478         * html/HTMLPlugInElement.h:
1479         (HTMLPlugInElement):
1480         * testing/Internals.cpp:
1481         * testing/Internals.h:
1482         (Internals):
1483         * testing/Internals.idl:
1484
1485 2012-03-23  Adam Barth  <abarth@webkit.org>
1486
1487         Move Notifications APIs from DOMWindow.idl to DOMWindowNotifications.idl (Part 2)
1488         https://bugs.webkit.org/show_bug.cgi?id=82026
1489
1490         Reviewed by Kentaro Hara.
1491
1492         This patch removes DOMWindow::resetNotifications, which was unneeded
1493         special-case logic for clearing the notifications center.  The previous
1494         patch that tried to accomplish the same thing did not override
1495         willDetachPage, which is why it caused crashes.
1496
1497         There's actually a cleaner way to handle these cases, which will let us
1498         implement reconnectFrame, but that will need to wait for the next
1499         patch.
1500
1501         * notifications/DOMWindowNotifications.cpp:
1502         (WebCore::DOMWindowNotifications::DOMWindowNotifications):
1503         (WebCore::DOMWindowNotifications::from):
1504         (WebCore::DOMWindowNotifications::webkitNotifications):
1505         (WebCore):
1506         (WebCore::DOMWindowNotifications::disconnectFrame):
1507         (WebCore::DOMWindowNotifications::willDetachPage):
1508         (WebCore::DOMWindowNotifications::reset):
1509         * notifications/DOMWindowNotifications.h:
1510         (DOMWindowNotifications):
1511         * page/DOMWindow.cpp:
1512         (WebCore::DOMWindow::willDetachPage):
1513         (WebCore::DOMWindow::disconnectDOMWindowProperties):
1514         (WebCore::DOMWindow::clearDOMWindowProperties):
1515         * page/DOMWindow.h:
1516         (DOMWindow):
1517         * page/Frame.cpp:
1518         (WebCore::Frame::willDetachPage):
1519
1520 2012-03-22  Adam Barth  <abarth@webkit.org>
1521
1522         Move Notifications APIs from DOMWindow.idl to DOMWindowNotifications.idl (Part 1)
1523         https://bugs.webkit.org/show_bug.cgi?id=82015
1524
1525         Reviewed by Kentaro Hara.
1526
1527         This patch moves DOMWindow.webkitNotifications from DOMWindow.idl to
1528         DOMWindowNotificiations.idl in preparation for moving notificiations
1529         into Modules.
1530
1531         A future patch will remove DOMWindow::resetNotificaitions in favor of
1532         more general mechanisms.
1533
1534         * CMakeLists.txt:
1535         * DerivedSources.make:
1536         * DerivedSources.pri:
1537         * GNUmakefile.list.am:
1538         * Target.pri:
1539         * WebCore.gypi:
1540         * WebCore.vcproj/WebCore.vcproj:
1541         * WebCore.xcodeproj/project.pbxproj:
1542         * notifications/DOMWindowNotifications.cpp: Added.
1543         (WebCore):
1544         (WebCore::DOMWindowNotifications::DOMWindowNotifications):
1545         (WebCore::DOMWindowNotifications::~DOMWindowNotifications):
1546         (WebCore::DOMWindowNotifications::from):
1547         (WebCore::DOMWindowNotifications::webkitNotifications):
1548         (WebCore::DOMWindowNotifications::reset):
1549         (WebCore::DOMWindowNotifications::supplementName):
1550         * notifications/DOMWindowNotifications.h: Added.
1551         (WebCore):
1552         (DOMWindowNotifications):
1553         * notifications/DOMWindowNotifications.idl: Added.
1554         * page/DOMWindow.cpp:
1555         (WebCore::DOMWindow::~DOMWindow):
1556         (WebCore):
1557         (WebCore::DOMWindow::resetNotifications):
1558         * page/DOMWindow.h:
1559         (WebCore):
1560         (DOMWindow):
1561         * page/DOMWindow.idl:
1562
1563 2012-03-22  Li Yin  <li.yin@intel.com>
1564
1565         A client MUST close a connection if it detects a masked frame
1566         https://bugs.webkit.org/show_bug.cgi?id=81361
1567
1568         Reviewed by Kent Tamura.
1569
1570         A server must not mask any frames that it sends to the client.
1571         Change the test case, not mask the frames from server to client.
1572         
1573         Test: http/tests/websocket/tests/hybi/invalid-masked-frames-from-server.html
1574
1575         * Modules/websockets/WebSocketChannel.cpp:
1576         (WebCore::WebSocketChannel::processFrame):
1577
1578 2012-03-22  Li Yin  <li.yin@intel.com>
1579
1580         [WebSocket]The minimal number of bytes MUST be used to encode the length
1581         https://bugs.webkit.org/show_bug.cgi?id=81443
1582
1583         Reviewed by Kent Tamura.
1584
1585         From RFC 6455 http://tools.ietf.org/html/rfc6455#section-5.2
1586         the minimal number of bytes MUST be used to encode the length
1587         
1588         New test case : http/tests/websocket/tests/hybi/invalid-encode-length.html
1589
1590         * Modules/websockets/WebSocketChannel.cpp:
1591         (WebCore::WebSocketChannel::parseFrame):
1592
1593 2012-03-22  Adam Barth  <abarth@webkit.org>
1594
1595         Unreviewed.  Sort xcodeproj file.
1596
1597         * WebCore.xcodeproj/project.pbxproj:
1598
1599 2012-03-22  Mao Yujie  <yujie.mao@intel.com>
1600
1601         Implement strict testing criterion for callback function definition
1602         https://bugs.webkit.org/show_bug.cgi?id=80005
1603
1604         Reviewed by Adam Barth.
1605
1606         Callback function should be defined as the function type instead of
1607         the object type.
1608
1609         LayoutTest: fast/dom/MediaStream/argument-types.html
1610
1611         * bindings/scripts/CodeGeneratorJS.pm:
1612         (GenerateParametersCheckExpression):
1613         (GenerateParametersCheck):
1614         * bindings/scripts/CodeGeneratorV8.pm:
1615         (GenerateParametersCheckExpression):
1616         (GenerateParametersCheck):
1617
1618 2012-03-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1619
1620         Convert hasGrammarMarker to use Internals interface
1621         https://bugs.webkit.org/show_bug.cgi?id=82004
1622
1623         Reviewed by Ryosuke Niwa.
1624
1625         Remove hasGrammarMarker functions, because it is able to work in the
1626         cross-port way through the Internals interface.
1627
1628         No new tests, since we are improving here the infra-structure
1629         for testing a specific method.
1630
1631         * testing/Internals.cpp:
1632         (WebCore::Internals::hasGrammarMarker):
1633         (WebCore):
1634         * testing/Internals.h:
1635         (Internals):
1636         * testing/Internals.idl:
1637
1638 2012-03-22  Xingnan Wang  <xingnan.wang@intel.com>
1639
1640         Add exception for the setter of "fftSize" in RealtimeAnalyserNode
1641         https://bugs.webkit.org/show_bug.cgi?id=81748
1642
1643         Reviewed by Chris Rogers.
1644
1645         * Modules/webaudio/RealtimeAnalyser.cpp:
1646         (WebCore::RealtimeAnalyser::setFftSize):
1647         * Modules/webaudio/RealtimeAnalyser.h:
1648         (RealtimeAnalyser):
1649         * Modules/webaudio/RealtimeAnalyserNode.cpp:
1650         (WebCore::RealtimeAnalyserNode::setFftSize):
1651         (WebCore):
1652         * Modules/webaudio/RealtimeAnalyserNode.h:
1653         (RealtimeAnalyserNode):
1654         * Modules/webaudio/RealtimeAnalyserNode.idl:
1655
1656 2012-03-22  Leo Yang  <leo.yang@torchmobile.com.cn>
1657
1658         [BlackBerry] Add HistoryItemViewState for BlackBerry port
1659         https://bugs.webkit.org/show_bug.cgi?id=81867
1660
1661         Reviewed by Rob Buis.
1662
1663         HistoryItemViewState is the blackberry specific field of HistoryItem.
1664         It's used to maintain the porting specific view state.
1665
1666         No new test because the port can't be built yet.
1667
1668         * history/HistoryItem.h:
1669         (HistoryItem):
1670         (WebCore::HistoryItem::viewState):
1671
1672 2012-03-22  SravanKumar Sandela  <ssandela@innominds.com>
1673
1674         Fieldset unexpectedly stretches to minimum intrinsic width
1675         https://bugs.webkit.org/show_bug.cgi?id=79128
1676
1677         Reviewed by Julien Chaffraix.
1678
1679         Fieldset element width will now check if css width is specified explicitly
1680         before stretching to minimum intrinsic width. The reference
1681         can be taken from IE9, instead of FF(FF acknowledged the broken behavior). 
1682
1683         Tests: fast/forms/fieldset-width-nostretch-ifspecified-expected.html
1684                fast/forms/fieldset-width-nostretch-ifspecified.html
1685
1686         * rendering/RenderFieldset.cpp:
1687         (WebCore::RenderFieldset::stretchesToMinIntrinsicLogicalWidth):
1688         (WebCore):
1689         * rendering/RenderFieldset.h:
1690         (RenderFieldset):
1691
1692 2012-03-22  Shawn Singh  <shawnsingh@chromium.org>
1693
1694         [chromium] Target surface should be damaged for a new layers even when layer had no changes
1695         https://bugs.webkit.org/show_bug.cgi?id=81879
1696
1697         Reviewed by Adrienne Walker.
1698
1699         Unit test added to CCDamageTrackerTest.
1700
1701         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
1702         (WebCore::CCDamageTracker::removeRectFromCurrentFrame): added a
1703         boolean arg to detect if the layer is new on this update.
1704
1705         (WebCore::CCDamageTracker::extendDamageForLayer): added logic that
1706         damages the target surface if the layer is new.
1707
1708         (WebCore::CCDamageTracker::extendDamageForRenderSurface): added
1709         logic that damages the target surface if the descendant surface is
1710         new; similar logic for the surface's replica if the replica is new.
1711
1712         * platform/graphics/chromium/cc/CCDamageTracker.h:
1713         (CCDamageTracker):
1714
1715 2012-03-22  Charles Wei  <charles.wei@torchmobile.com.cn>
1716
1717         [BlackBerry] Need to store the meta info of a page in the ViewState of the history
1718         https://bugs.webkit.org/show_bug.cgi?id=82000
1719
1720         Reviewed by Rob Buis.
1721
1722         Internally reviewed by George Staikos.
1723
1724         No new tests, BlackBerry porting doesn't build yet upstreaming.
1725
1726         * history/blackberry/HistoryItemViewState.h:
1727         (WebCore::HistoryItemViewState::HistoryItemViewState):
1728         (HistoryItemViewState):
1729
1730 2012-03-22  Adam Klein  <adamk@chromium.org>
1731
1732         [v8] wrapSlow methods should ref underlying object before creating wrapper
1733         https://bugs.webkit.org/show_bug.cgi?id=81919
1734
1735         Reviewed by Adam Barth.
1736
1737         Because instatiating the wrapper can trigger GC, it's important that
1738         wrapSlow() hold a reference to an object when creating a wrapper for
1739         that object. Once the V8 wrapper exists and is associated with the object,
1740         the reference can be handed off (via leakRef) to be handled by the normal
1741         binding code logic (where derefObject is called if the handle is GCed).
1742
1743         Binding tests have been updated to reflect this change.
1744
1745         Testing the change directly is hard. Any test landed today would only
1746         be a valid test until V8's logic about when to GC changes, at which point
1747         it would become dead weight. So I don't think it's worth landing a
1748         layout test along with this.
1749
1750         * bindings/scripts/CodeGeneratorV8.pm:
1751         (GenerateHeader): Make wrapSlow take a PassRefPtr for RefCounted objects.
1752         (GenerateToV8Converters): Get rid of the explicit call to ref() and
1753         instead call leakRef() when adding a RefCounted object to the DOM map.
1754         (GetPassRefPtrType): Helper to generate "PassRefPtr<T>", or "PassRefPtr<T<U> >" as appropriate.
1755         * bindings/scripts/test/V8/V8Float64Array.cpp:
1756         (WebCore::V8Float64Array::wrapSlow):
1757         * bindings/scripts/test/V8/V8Float64Array.h:
1758         (V8Float64Array):
1759         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1760         (WebCore::V8TestActiveDOMObject::wrapSlow):
1761         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
1762         (V8TestActiveDOMObject):
1763         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1764         (WebCore::V8TestCustomNamedGetter::wrapSlow):
1765         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
1766         (V8TestCustomNamedGetter):
1767         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1768         (WebCore::V8TestEventConstructor::wrapSlow):
1769         * bindings/scripts/test/V8/V8TestEventConstructor.h:
1770         (V8TestEventConstructor):
1771         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1772         (WebCore::V8TestEventTarget::wrapSlow):
1773         * bindings/scripts/test/V8/V8TestEventTarget.h:
1774         (V8TestEventTarget):
1775         * bindings/scripts/test/V8/V8TestInterface.cpp:
1776         (WebCore::V8TestInterface::wrapSlow):
1777         * bindings/scripts/test/V8/V8TestInterface.h:
1778         (V8TestInterface):
1779         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1780         (WebCore::V8TestMediaQueryListListener::wrapSlow):
1781         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
1782         (V8TestMediaQueryListListener):
1783         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1784         (WebCore::V8TestNamedConstructor::wrapSlow):
1785         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
1786         (V8TestNamedConstructor):
1787         * bindings/scripts/test/V8/V8TestObj.cpp:
1788         (WebCore::V8TestObj::wrapSlow):
1789         * bindings/scripts/test/V8/V8TestObj.h:
1790         (V8TestObj):
1791         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1792         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
1793         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
1794         (V8TestSerializedScriptValueInterface):
1795
1796 2012-03-22  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
1797
1798         [BlackBerry] add interface clearCredentials() and clearNeverRememberSites()
1799         https://bugs.webkit.org/show_bug.cgi?id=81887
1800
1801         Reviewed by Rob Buis.
1802
1803         Fixed SQL issue when clearing table logins and table never_remember.
1804
1805         No new tests.
1806
1807         * platform/network/blackberry/CredentialBackingStore.cpp:
1808         (WebCore::CredentialBackingStore::clearLogins):
1809         (WebCore::CredentialBackingStore::clearNeverRemember):
1810
1811 2012-03-22  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
1812
1813         [BlackBerry] http authenticate dialog popup only once no matter authentication pass or fail
1814         https://bugs.webkit.org/show_bug.cgi?id=80135
1815
1816         Reviewed by Rob Buis.
1817
1818         Modified the interface function authenticationChallenge() in class
1819         PageClientBlackBerry, moved Credential from return value to the
1820         function's reference parameter, and returned a bool to indicate if
1821         user pressed Ok button or not.
1822         Removed the logic which checks m_currentWebChallenge not null,
1823         because we should challenge user again if the last provided credential
1824         is not valid; also added the logic that will popup challenge
1825         dialog again immediately if user press Ok buttton directly without
1826         inputting anything.
1827
1828         No new tests.
1829
1830         * platform/blackberry/PageClientBlackBerry.h:
1831         * platform/network/blackberry/NetworkJob.cpp:
1832         (WebCore::NetworkJob::handleAuthHeader):
1833         (WebCore::NetworkJob::sendRequestWithCredentials):
1834
1835 2012-03-22  Jason Liu  <jason.liu@torchmobile.com.cn>
1836
1837         [BlackBerry] Synchronize platform/network/blackberry
1838         https://bugs.webkit.org/show_bug.cgi?id=81874
1839
1840         We changed a lot in these files locally. But the changes are not upstreamed.
1841         It is not convenient to do the other upstreaming work based on these differences.
1842         So upstream these changes.
1843
1844         Reviewed by Rob Buis.
1845
1846         No new tests. Just synchronize codes.
1847
1848         * platform/network/blackberry/NetworkJob.cpp:
1849         (WebCore::NetworkJob::NetworkJob):
1850         (WebCore::NetworkJob::initialize):
1851         (WebCore::NetworkJob::handleNotifyHeaderReceived):
1852         (WebCore::NetworkJob::handleNotifyDataReceived):
1853         (WebCore::NetworkJob::sendResponseIfNeeded):
1854         (WebCore::NetworkJob::sendRequestWithCredentials):
1855         (WebCore::NetworkJob::handleAbout):
1856         * platform/network/blackberry/NetworkJob.h:
1857         (WebCore::NetworkJob::isError):
1858         (NetworkJob):
1859         * platform/network/blackberry/NetworkManager.cpp:
1860         (WebCore::NetworkManager::startJob):
1861         * platform/network/blackberry/ResourceRequest.h:
1862         (WebCore::ResourceRequest::ResourceRequest):
1863         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
1864         (WebCore::platformTargetTypeForRequest):
1865
1866 2012-03-22  Tom Sepez  <tsepez@chromium.org>
1867
1868         XSS Auditor bypass via script tag src=data:, URLS.
1869         https://bugs.webkit.org/show_bug.cgi?id=81948
1870
1871         Reviewed by Adam Barth.
1872
1873         This change fixes an XSSAuditor bypass wherby a script with a data: URL src
1874         attribute could evade detection by using characters from the page to create
1875         a snippet for matching not found in the URL's reflected vector.  This change 
1876         terminates the snippet for matching earlier in these cases.
1877         
1878         Test: http/tests/security/xssAuditor/script-tag-with-source-data-url2.html
1879
1880         * html/parser/XSSAuditor.cpp:
1881         (WebCore::XSSAuditor::decodedSnippetForAttribute):
1882
1883 2012-03-22  Dana Jansens  <danakj@chromium.org>
1884
1885         [chromium] Incorrect assert on animating opacity for a surface
1886         https://bugs.webkit.org/show_bug.cgi?id=81994
1887
1888         Reviewed by Adrienne Walker.
1889
1890         Draw opacity and animation state match on the surface itself. A
1891         surface with animating opacity always has an owning layer without
1892         animation, as the surface does the animation for it.
1893
1894         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
1895         (WebCore::CCLayerTreeHost::paintLayerContents):
1896
1897 2012-03-22  Dana Jansens  <danakj@chromium.org>
1898
1899         [chromium] Skip frames when checkerboarding an animation
1900         https://bugs.webkit.org/show_bug.cgi?id=81716
1901
1902         Reviewed by Adrienne Walker.
1903
1904         This will stop drawing frames when prepareToDraw fails, if the draw is
1905         not forced. The expected behaviour is outlined below by the unit tests.
1906
1907         When a draw fails, we:
1908         1. Set m_needsRedraw to try again next vsync
1909         2. Set m_needsCommit because we need more data from webkit to succeed
1910         3. Set m_drawIfPossibleFailed. This allows us to try draw again within
1911         the same vsync *if* a commit finishes during this time.
1912
1913         Unit test: CCSchedulerTest.RequestRedrawInsideFailedDraw
1914                    CCSchedulerTest.RequestCommitInsideFailedDraw
1915                    CCSchedulerTest.NoBeginFrameWhenDrawFails
1916                    CCSchedulerStateMachineTest.TestFailedDrawSetsNeedsCommitAndDoesNotDrawAgain
1917                    CCSchedulerStateMachineTest.TestSetNeedsRedrawDuringFailedDrawDoesNotRemoveNeedsRedraw
1918                    CCSchedulerStateMachineTest.TestCommitAfterFailedDrawAllowsDrawInSameFrame
1919                    CCSchedulerStateMachineTest.TestCommitAfterFailedAndSuccessfulDrawDoesNotAllowDrawInSameFrame
1920                    CCSchedulerStateMachineTest.TestFailedDrawIsRetriedNextVSync
1921
1922         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1923         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
1924         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
1925         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
1926         (CCLayerTreeHostImpl):
1927         * platform/graphics/chromium/cc/CCScheduler.cpp:
1928         (WebCore::CCScheduler::processScheduledActions):
1929         * platform/graphics/chromium/cc/CCScheduler.h:
1930         (CCSchedulerClient):
1931         * platform/graphics/chromium/cc/CCSchedulerStateMachine.cpp:
1932         (WebCore::CCSchedulerStateMachine::CCSchedulerStateMachine):
1933         (WebCore::CCSchedulerStateMachine::nextAction):
1934         (WebCore::CCSchedulerStateMachine::updateState):
1935         (WebCore::CCSchedulerStateMachine::didDrawIfPossibleCompleted):
1936         (WebCore):
1937         * platform/graphics/chromium/cc/CCSchedulerStateMachine.h:
1938         (CCSchedulerStateMachine):
1939         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
1940         (WebCore::CCThreadProxy::scheduledActionDrawAndSwapInternal):
1941         (WebCore):
1942         (WebCore::CCThreadProxy::scheduledActionDrawAndSwapIfPossible):
1943         (WebCore::CCThreadProxy::scheduledActionDrawAndSwapForced):
1944         * platform/graphics/chromium/cc/CCThreadProxy.h:
1945         (CCThreadProxy):
1946
1947 2012-03-22  W. James MacLean  <wjmaclean@chromium.org>
1948
1949         [chromium] Force update of nonFastScrollableRegion if target CCLayerImpl has been freshly created.
1950         https://bugs.webkit.org/show_bug.cgi?id=81968
1951
1952         Reviewed by Adrienne Walker.
1953
1954         Added unit test to existing tests for TreeSynchronizer.
1955
1956         When creating a new CCLayerImpl during tree synchronization, make sure we transfer the nonFastScrollableRegion as
1957         the new CCLayerImpl will default to an empty region.
1958
1959         * platform/graphics/chromium/LayerChromium.h:
1960         (WebCore::LayerChromium::nonFastScrollableRegion):
1961         (WebCore::LayerChromium::setNonFastScrollableRegionChanged):
1962         * platform/graphics/chromium/TreeSynchronizer.cpp:
1963         (WebCore::TreeSynchronizer::reuseOrCreateCCLayerImpl):
1964
1965 2012-03-22  Raphael Kubo da Costa  <rakuco@FreeBSD.org>
1966
1967         [CMake] Unreviewed build fix after r111778.
1968
1969         * CMakeLists.txt: Replace ${JAVASCRIPTCORE_DIR}/wtf includes with
1970         ${WTF_DIR}/wtf ones.
1971
1972 2012-03-22  Tony Chang  <tony@chromium.org>
1973
1974         Unreviewed, fix chromium build after wtf move.
1975
1976         Only use newwtf, remove references to wtf.
1977
1978         * WebCore.gyp/WebCore.gyp:
1979
1980 2012-03-22  Benjamin Poulain  <bpoulain@apple.com>
1981
1982         Remove an obsolete comment regarding magic frames from Geolocation
1983         https://bugs.webkit.org/show_bug.cgi?id=81871
1984
1985         Reviewed by Alexey Proskuryakov.
1986
1987         Moving a frame into another document is no longer possible after r111361. The comment
1988         is now irrelevant.
1989
1990         * Modules/geolocation/Geolocation.cpp:
1991         (WebCore::Geolocation::stop):
1992
1993 2012-03-22  Csaba Osztrogonác  <ossy@webkit.org>
1994
1995         Actually move WTF files to their new home
1996         https://bugs.webkit.org/show_bug.cgi?id=81844
1997
1998         [Qt] Unreviewed buildfix after r111778.
1999
2000         * Target.pri:
2001
2002 2012-03-22  Kentaro Hara  <haraken@chromium.org>
2003
2004         run-bindings-tests output a lot of errors in TestSerializedScriptValueInterface.idl
2005         https://bugs.webkit.org/show_bug.cgi?id=81852
2006
2007         Reviewed by Adam Barth.
2008
2009         run-bindings-tests output a lot of errors in TestSerializedScriptValueInterface.idl:
2010
2011         Use of uninitialized value in string eq at WebCore/bindings/scripts/CodeGeneratorJS.pm line 2743.
2012         Use of uninitialized value $name in substitution (s///) at WebCore/bindings/scripts/CodeGenerator.pm line 119.
2013         Use of uninitialized value $type in string eq at WebCore/bindings/scripts/CodeGeneratorJS.pm line 2969.
2014         Use of uninitialized value $type in string eq at WebCore/bindings/scripts/CodeGeneratorJS.pm line 2972.
2015         Use of uninitialized value $type in hash element at WebCore/bindings/scripts/CodeGenerator.pm line 367.
2016         Use of uninitialized value $type in hash element at WebCore/bindings/scripts/CodeGenerator.pm line 368.
2017         ...
2018
2019         This is because [Constructor(...)] does not yet support [Optional] arguments.
2020         It just supports [Optional=DefaultIsUndefined] and [Optional=DefaultIsNullString] arguments:
2021         https://trac.webkit.org/wiki/WebKitIDL#Constructor
2022
2023         This patch replaces [Optional] with [Optional=DefaultIsUndefined]
2024         in TestSerializedScriptValueInterface.idl.
2025
2026         Test: bindings/scripts/test/TestSerializedScriptValueInterface.idl
2027
2028         * bindings/scripts/CodeGeneratorJS.pm:
2029         (GenerateConstructorDefinition):
2030         * bindings/scripts/CodeGeneratorV8.pm:
2031         (GenerateConstructorCallback):
2032         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
2033         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::constructJSTestSerializedScriptValueInterface):
2034         * bindings/scripts/test/TestSerializedScriptValueInterface.idl:
2035         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2036         (WebCore::V8TestSerializedScriptValueInterface::constructorCallback):
2037
2038 2012-03-22  Michal Mocny  <mmocny@google.com>
2039
2040         [chromium] LayerRendererChromium should use GpuMemoryAllocationChanged callback to explicitly manage framebuffer.
2041         https://bugs.webkit.org/show_bug.cgi?id=81823
2042
2043         Reviewed by Adrienne Walker.
2044
2045         New UnitTests: LayerRendererChromiumTest
2046
2047         * platform/graphics/chromium/LayerRendererChromium.cpp:
2048         (LayerRendererGpuMemoryAllocationChangedCallbackAdapter):
2049         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::create):
2050         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::~LayerRendererGpuMemoryAllocationChangedCallbackAdapter):
2051         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::onGpuMemoryAllocationChanged):
2052         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::LayerRendererGpuMemoryAllocationChangedCallbackAdapter):
2053         (WebCore):
2054         (WebCore::LayerRendererChromium::LayerRendererChromium):
2055         (WebCore::LayerRendererChromium::initialize):
2056         (WebCore::LayerRendererChromium::~LayerRendererChromium):
2057         (WebCore::LayerRendererChromium::setVisible):
2058         (WebCore::LayerRendererChromium::swapBuffers):
2059         (WebCore::LayerRendererChromium::discardFramebuffer):
2060         (WebCore::LayerRendererChromium::ensureFramebuffer):
2061         * platform/graphics/chromium/LayerRendererChromium.h:
2062         (WebCore):
2063         (LayerRendererChromiumClient):
2064         (LayerRendererChromium):
2065         (WebCore::LayerRendererChromium::isFramebufferDiscarded):
2066         (ScopedEnsureFramebufferAllocation):
2067         (WebCore::ScopedEnsureFramebufferAllocation::ScopedEnsureFramebufferAllocation):
2068         (WebCore::ScopedEnsureFramebufferAllocation::~ScopedEnsureFramebufferAllocation):
2069         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2070         (WebCore::LayerRendererCapabilities::LayerRendererCapabilities):
2071         (LayerRendererCapabilities):
2072         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2073         (WebCore::CCLayerTreeHostImpl::setVisible):
2074         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
2075         (CCLayerTreeHostImpl):
2076         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
2077         (WebCore::CCSingleThreadProxy::compositeAndReadback):
2078         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
2079         (WebCore::CCThreadProxy::compositeAndReadback):
2080
2081 2012-03-22  Adam Barth  <abarth@webkit.org>
2082
2083         ContainerNode::insertedIntoTree and removedFromTree use weak iteration patterns
2084         https://bugs.webkit.org/show_bug.cgi?id=80570
2085
2086         Reviewed by Ryosuke Niwa.
2087
2088         These functions use weak iteration patterns, but as far as I can tell,
2089         we never execute script below these functions.  This patch adds ASSERTs
2090         to help us avoid adding events in the future.
2091
2092         * dom/ContainerNode.cpp:
2093         (WebCore::ContainerNode::insertedIntoTree):
2094         (WebCore::ContainerNode::removedFromTree):
2095         * html/HTMLMediaElement.cpp:
2096         (WebCore::HTMLMediaElement::loadInternal):
2097             - There's a somewhat complex call chain from insertedIntoTree into
2098               HTMLMediaElement, and somewhat complex control flow below
2099               loadInternal that eventually leads to the BeforeLoad event being
2100               fired.  In studying this code, I don't see a way for the
2101               BeforeLoad event to be fired during insertedIntoTree, but I've
2102               added this assert here to make sure we don't call loadInternal
2103               when we're not supposed to dispatch events.  This ASSERT should
2104               help us catch these BeforeLoad errors more quickly.
2105
2106 2012-03-22  Raphael Kubo da Costa  <rakuco@FreeBSD.org>
2107
2108         Crash in fast/dom/navigator-detached-nocrash.html
2109         https://bugs.webkit.org/show_bug.cgi?id=81773
2110
2111         Reviewed by Adam Barth.
2112
2113         BatteryManager::create() blindly assumes the Navigator* it
2114         receives has a valid Frame, which is not always the case, as made
2115         evident by the crashing test.
2116
2117         Follow abarth's suggestion and just stop
2118         NavigatorBattery::webkitBattery() before it reaches the call to
2119         BatteryManager::create() if that's the case.
2120
2121         No new tests, covered by fast/dom/navigator-detached-nocrash.html.
2122
2123         * Modules/battery/NavigatorBattery.cpp:
2124         (WebCore::NavigatorBattery::webkitBattery):
2125
2126 2012-03-22  Emil A Eklund  <eae@chromium.org>
2127
2128         Unreviewed, add missing include statement for CSSValueList.h.
2129
2130         * css/CSSStyleSelector.h:
2131
2132 2012-03-22  Tony Chang  <tony@chromium.org>
2133
2134         flexbox flexing implementation should match the spec
2135         https://bugs.webkit.org/show_bug.cgi?id=70796
2136
2137         Reviewed by Ojan Vafai.
2138
2139         Match the algorithm in the spec. Handling min/max constraints are slightly improved.
2140         http://dev.w3.org/csswg/css3-flexbox/#resolve-the-flexible-lengths
2141
2142         New test cases in css3/flexbox/flex-algorithm-min-max.html.
2143
2144         * rendering/RenderFlexibleBox.cpp:
2145         (WebCore::adjustFlexSizeForMinAndMax): Step 5 of resolving flexible lengths.
2146         (WebCore):
2147         (WebCore::RenderFlexibleBox::Violation::Violation):
2148         (RenderFlexibleBox::Violation):
2149         (WebCore::RenderFlexibleBox::freezeViolations): Used by step 6.
2150         (WebCore::RenderFlexibleBox::resolveFlexibleLengths):
2151         * rendering/RenderFlexibleBox.h:
2152
2153 2012-03-22  Emil A Eklund  <eae@chromium.org>
2154
2155         Unreviewed, add missing import.
2156
2157         * rendering/RenderThemeMac.mm:
2158
2159 2012-03-22  Anders Carlsson  <andersca@apple.com>
2160
2161         ASSERT(!needsLayout) in RenderView.cpp when visiting http://www.panic.com/blog/
2162         https://bugs.webkit.org/show_bug.cgi?id=81953
2163         <rdar://problem/11086998>
2164
2165         Reviewed by Sam Weinig.
2166
2167         If a page ends up creating CATiledLayers, CA transactions can be committed outside of the normal
2168         CA run loop observer, so we can't call setNeedsDisplay on tile cache layers directly because then
2169         we'll end up calling into painting code before all the layers have been flushed.
2170
2171         Fix this by adding a list of dirty rects to platformCALayerDidCreateTiles and change GraphicsLayerCA to
2172         mark them as dirty. This ensures that any CA transaction commits won't cause newly added layers to be painted.
2173
2174         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
2175         (WebCore::LayerClient::platformCALayerDidCreateTiles):
2176         * platform/graphics/ca/GraphicsLayerCA.cpp:
2177         (WebCore::GraphicsLayerCA::platformCALayerDidCreateTiles):
2178         * platform/graphics/ca/GraphicsLayerCA.h:
2179         (GraphicsLayerCA):
2180         * platform/graphics/ca/PlatformCALayerClient.h:
2181         (PlatformCALayerClient):
2182         * platform/graphics/ca/mac/TileCache.mm:
2183         (WebCore::TileCache::setScale):
2184         (WebCore::TileCache::revalidateTiles):
2185         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
2186         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerDidCreateTiles):
2187
2188 2012-03-19  Robert Hogan  <robert@webkit.org>
2189
2190         Text should overflow when list item height set to 0
2191         https://bugs.webkit.org/show_bug.cgi?id=78726
2192
2193         Reviewed by Julien Chaffraix.
2194
2195         Tests: css2.1/20110323/height-applies-to-010a-expected.html
2196                fast/css/heightless-list-item-expected.html
2197                fast/css/heightless-list-item.html
2198
2199         * rendering/RenderListItem.cpp:
2200         (WebCore::RenderListItem::paint):
2201            If the list item has height:0, only paint it if the list item allows any block or inline content 
2202            to overflow unclipped. The zero-height check is a shortcut to avoid unnecessary painting and 
2203            this seems to be the only case where there's something to do.
2204
2205 2012-03-22  Dave Michael  <dmichael@chromium.org>
2206
2207         HTMLPluginElement is not destroyed on reload or navigation if getNPObject is called
2208         https://bugs.webkit.org/show_bug.cgi?id=80428
2209
2210         Reviewed by Eric Seidel.
2211
2212         Make HTMLPluginElement release its m_NPObject in detach() to break a
2213         reference-counting cycle that happens on reload or navigation. With this
2214         change, HTMLPlugInElement::removedFromDocument is unnecessary, so it
2215         was removed. Note that Releasing m_NPObject does not result in a call to
2216         the plugin; it simply releases a reference count on the wrapper object
2217         for this HTMLPlugInElement. (The plugin's NPP_Deallocate is invoked
2218         when the render tree is destroyed, when PluginView calls
2219         PluginPackage::unload.) Thus, it is safe to release m_NPObject in
2220         detach, because it can not result in layout or style changes.
2221
2222         Also added numberOfLiveNodes() and numberOfLiveDocuments() to
2223         window.internals to enable testing.
2224
2225         Test: plugins/netscape-dom-access-and-reload.html
2226
2227         * WebCore.exp.in:
2228         * html/HTMLPlugInElement.cpp:
2229         (WebCore::HTMLPlugInElement::detach):
2230         * html/HTMLPlugInElement.h:
2231         (HTMLPlugInElement):
2232         * testing/Internals.cpp:
2233         (WebCore::Internals::numberOfLiveDocuments):
2234         (WebCore::Internals::numberOfLiveNodes):
2235         (WebCore):
2236         * testing/Internals.h:
2237         (Internals):
2238         * testing/Internals.idl:
2239
2240 2012-03-22  Shawn Singh  <shawnsingh@chromium.org>
2241
2242         [chromium] Make CCDamageTracker robust to empty layer lists
2243         https://bugs.webkit.org/show_bug.cgi?id=81831
2244
2245         Reviewed by Adrienne Walker.
2246
2247         Added a unit test in CCDamageTrackerTest that causes a crash in
2248         the old code. With this patch applied, the crash will not occur.
2249         In theory, that crash should never occur anyway, unless there is a
2250         bug outside the damage tracker, but for robustness it's
2251         appropriate to handle it properly.
2252
2253         In addition to this fix, performed some trivial maintenance on the
2254         damage tracker code.
2255
2256         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
2257         (WebCore::CCDamageTracker::updateDamageTrackingState): removed
2258         unclean code that accessed the targetSurface to get necessary
2259         information. Instead, we now pass those args through the damage
2260         tracker's API.
2261
2262         * platform/graphics/chromium/cc/CCDamageTracker.h:
2263         (CCDamageTracker): modified args passed to damage tracker on update.
2264
2265         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2266         (WebCore::CCLayerTreeHostImpl::trackDamageForAllSurfaces):
2267         modified args passed to damage tracker on update.
2268
2269 2012-03-22  Julien Chaffraix  <jchaffraix@webkit.org>
2270
2271         Enable style sharing for elements with a style attribute
2272         https://bugs.webkit.org/show_bug.cgi?id=81523
2273
2274         Reviewed by Antti Koivisto.
2275
2276         Memory improvement change only.
2277
2278         Overall, this is a performance wash (some benchmarks may regress a bit due to the increase in time taken
2279         by CSSStyleSelector::locateSharedStyle as we try more nodes, others increase their performance due to style sharing).
2280
2281         Instrumenting our style sharing, this should give us some nice memory shavings on some benchmarks:
2282         - HTML5 isn't impacted as it doesn't use much inline style
2283         - page cyclers' intl1 showed a 6% increase in style sharing.
2284
2285         * css/CSSStyleSelector.cpp:
2286         (WebCore::CSSStyleSelector::canShareStyleWithElement):
2287         This method now handles inline style like presentation attributes on the element.
2288
2289         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
2290         (WebCore::CSSStyleSelector::locateSharedStyle):
2291         Don't bail out for an element with an inline style declaration.
2292
2293         (WebCore::CSSStyleSelector::stylesEqual):
2294         Generalized attributeStylesEqual to share the logic between attribute and
2295         inline style property set. This means that attribute checks are actually
2296         doing a little extra more work but that didn't impact our benchmarks.
2297
2298 2012-03-22  Kevin Ollivier  <kevino@theolliviers.com>
2299
2300         [wx] Unreviewed. WebDOM build fix after array type changes.
2301
2302         * bindings/scripts/CodeGeneratorCPP.pm:
2303         (ShouldSkipType):
2304
2305 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
2306
2307         Web Inspector: text gutter decorations should move upon edits.
2308         https://bugs.webkit.org/show_bug.cgi?id=81932
2309
2310         Reviewed by Vsevolod Vlasov.
2311
2312         Decorations set by the line number now shift as editing inserts / removes lines.
2313
2314         * inspector/front-end/TextViewer.js:
2315         (WebInspector.TextViewer.prototype._syncLineHeight):
2316         (WebInspector.TextEditorGutterPanel):
2317         (WebInspector.TextEditorGutterPanel.prototype.textChanged):
2318         (WebInspector.TextEditorGutterPanel.prototype.syncClientHeight):
2319         (WebInspector.TextEditorGutterPanel.prototype.addDecoration):
2320         (WebInspector.TextEditorGutterPanel.prototype.removeDecoration):
2321
2322 2012-03-21  Robert Hogan  <robert@webkit.org>
2323
2324         CSS 2.1 failure: fixed-table-layout-006 fails
2325         https://bugs.webkit.org/show_bug.cgi?id=78412
2326
2327         Reviewed by Julien Chaffraix.
2328
2329         Tests: css2.1/20110323/fixed-table-layout-006.htm
2330                fast/css/fixed-table-layout-cell-padding.htm
2331
2332         In fixed tables, positive width specified on a column should include borders and padding.
2333         See the thread at http://lists.w3.org/Archives/Public/www-style/2011Oct/0502.html. The discussion
2334         there resulted in a whole new set of tests for section 17.5.2.1 in the CSS 2.1 spec. See 
2335         http://test.csswg.org/harness/test/CSS21_DEV/section/17.5.2.1/. This patch allows WebKit
2336         to pass all of them, and all tests for the 17.5.2.1 section as a whole. I'll land them all separately.
2337     
2338         * rendering/FixedTableLayout.cpp:
2339         (WebCore::FixedTableLayout::calcWidthArray): Include border width and cell padding in the width of the column.
2340          Note that borderAndPaddingLogicalWidth() returns the border width for separate and collapsed borders as appropriate.
2341
2342 2012-03-22  Simon Fraser  <simon.fraser@apple.com>
2343
2344         Factor compositing layer updates after scroll into a new method
2345         https://bugs.webkit.org/show_bug.cgi?id=81943
2346
2347         Reviewed by Dean Jackson.
2348
2349         Move some code that updates compositing layers after scrolling
2350         into its own method, for cleanliness.
2351
2352         * rendering/RenderLayer.cpp:
2353         (WebCore::RenderLayer::scrollTo):
2354         (WebCore::RenderLayer::updateCompositingLayersAfterScroll):
2355         (WebCore):
2356         * rendering/RenderLayer.h:
2357         (RenderLayer):
2358
2359 2012-03-22  Gavin Barraclough  <barraclough@apple.com>
2360
2361         Add JSValue::isFunction
2362         https://bugs.webkit.org/show_bug.cgi?id=81935
2363
2364         Reviewed by Geoff Garen.
2365
2366         This would be useful in the WebCore bindings code.
2367         Also, remove asFunction, replace with jsCast<JSFunction*>.
2368
2369         * bindings/js/JSInjectedScriptHostCustom.cpp:
2370         (WebCore::JSInjectedScriptHost::functionDetails):
2371         * bindings/js/ScriptCallStackFactory.cpp:
2372         (WebCore::createScriptCallStack):
2373
2374 2012-03-22  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
2375
2376         TiledBackingStore: Fix test regressions that appeared with r111560.
2377         https://bugs.webkit.org/show_bug.cgi?id=81519
2378
2379         Reviewed by Kenneth Rohde Christiansen.
2380
2381         The visible rect wasn't intersected with the contents rect anymore which
2382         could lead to an astronomical layer size to check for intersecting tiles.
2383
2384         Add a visibleContentsRect that doesn't do the conversion and use it
2385         in visibleAreaIsCovered.
2386
2387         * platform/graphics/TiledBackingStore.cpp:
2388         (WebCore::TiledBackingStore::visibleContentsRect):
2389         (WebCore):
2390         (WebCore::TiledBackingStore::visibleRect):
2391         (WebCore::TiledBackingStore::visibleAreaIsCovered):
2392         * platform/graphics/TiledBackingStore.h:
2393         (TiledBackingStore):
2394
2395 2012-03-22  Joe Thomas  <joethomas@motorola.com>
2396
2397         Make Length Calculation functions non-inline
2398         https://bugs.webkit.org/show_bug.cgi?id=81733
2399
2400         Currently length calculation functions in LengthFunctions.h are inline. These functions are pretty big to be inline.
2401         And these functions are expected to grow again when new length units will be introduced in bug 27160.
2402
2403         A decent rule of thumb is to not inline a function if it is more than 10 lines long. Also it's typically not cost effective to inline
2404         functions with loops or switch statements. (Reference: http://google-styleguide.googlecode.com/svn/trunk/cppguide.xml#Inline_Functions).
2405
2406         Ran PerformanceTests/Parser/html5-full-render.html on Mac Snow-Leopard with and without the patch and did not see much performance difference.
2407
2408         Reviewed by Antti Koivisto.
2409
2410         * CMakeLists.txt:
2411         * GNUmakefile.list.am:
2412         * Target.pri:
2413         * WebCore.gypi:
2414         * WebCore.vcproj/WebCore.vcproj:
2415         * WebCore.xcodeproj/project.pbxproj:
2416         * css/LengthFunctions.cpp: Added.
2417         (WebCore):
2418         (WebCore::miminumValueForLength):
2419         (WebCore::valueForLength):
2420         (WebCore::floatValueForLength):
2421         * css/LengthFunctions.h:
2422         (WebCore):
2423
2424 2012-03-22  Alexis Menard  <alexis.menard@openbossa.org>
2425
2426         Increase code sharing between CSSParser and CSSPropertyLonghand.
2427         https://bugs.webkit.org/show_bug.cgi?id=81587
2428
2429         Reviewed by Antti Koivisto.
2430
2431         Expose the longhands declaration for a given shorthand in CSSPropertyLonghand and
2432         make CSSParser use them. It will make the declaration of longhands in one place only.
2433         Remove the map of CSSPropertyLonghand and replace it by a regular switch/case.
2434         The map doesn't bring much here and it's cleaner and faster to use the switch.
2435         It also shows a little performance improvement in CSS/CSSPropertySetterGetter.html.
2436
2437         No new tests : no behavior change.
2438
2439         * css/CSSParser.cpp:
2440         (WebCore::CSSParser::parseValue):
2441         (WebCore::CSSParser::parseAnimationShorthand):
2442         (WebCore::CSSParser::parseTransitionShorthand):
2443         (WebCore::CSSParser::parseShorthand):
2444         Modify the prototype of this function to directly use the CSSPropertyLonghand.
2445         * css/CSSParser.h:
2446         (WebCore):
2447         (CSSParser):
2448         * css/CSSPropertyLonghand.cpp:
2449         (WebCore):
2450         (WebCore::backgroundLonghand):
2451         (WebCore::backgroundPositionLonghand):
2452         (WebCore::backgroundRepeatLonghand):
2453         (WebCore::borderLonghand):
2454         (WebCore::borderBottomLonghand):
2455         (WebCore::borderColorLonghand):
2456         (WebCore::borderImageLonghand):
2457         (WebCore::borderLeftLonghand):
2458         (WebCore::borderRadiusLonghand):
2459         (WebCore::borderRightLonghand):
2460         (WebCore::borderSpacingLonghand):
2461         (WebCore::borderStyleLonghand):
2462         (WebCore::borderTopLonghand):
2463         (WebCore::borderWidthLonghand):
2464         (WebCore::listStyleLonghand):
2465         (WebCore::fontLonghand):
2466         (WebCore::marginLonghand):
2467         (WebCore::outlineLonghand):
2468         (WebCore::overflowLonghand):
2469         (WebCore::paddingLonghand):
2470         (WebCore::webkitAnimationLonghand):
2471         (WebCore::webkitBorderAfterLonghand):
2472         (WebCore::webkitBorderBeforeLonghand):
2473         (WebCore::webkitBorderEndLonghand):
2474         (WebCore::webkitBorderStartLonghand):
2475         (WebCore::webkitColumnsLonghand):
2476         (WebCore::webkitColumnRuleLonghand):
2477         (WebCore::webkitFlexFlowLonghand):
2478         (WebCore::webkitMarginCollapseLonghand):
2479         (WebCore::webkitMarqueeLonghand):
2480         (WebCore::webkitMaskLonghand):
2481         (WebCore::webkitMaskPositionLonghand):
2482         (WebCore::webkitMaskRepeatLonghand):
2483         (WebCore::webkitTextEmphasisLonghand):
2484         (WebCore::webkitTextStrokeLonghand):
2485         (WebCore::webkitTransitionLonghand):
2486         (WebCore::webkitTransformOriginLonghand):
2487         (WebCore::webkitWrapLonghand):
2488         (WebCore::longhandForProperty):
2489         * css/CSSPropertyLonghand.h:
2490         (WebCore):
2491
2492 2012-03-22  Emil A Eklund  <eae@chromium.org>
2493
2494         Unreviewed, touching file to force bots to pick up CSS_SHADERS flag change. 
2495
2496         * css/CSSStyleSelector.h:
2497         (CSSStyleSelector):
2498
2499 2012-03-22  Xingnan Wang  <xingnan.wang@intel.com>
2500
2501         ReverbConvolver::latencyFrames() should return 0.
2502         https://bugs.webkit.org/show_bug.cgi?id=81806
2503
2504         Reviewed by Chris Rogers.
2505
2506         * platform/audio/ReverbConvolver.cpp:
2507         (WebCore::ReverbConvolver::latencyFrames):
2508
2509 2012-03-22  Tony Chang  <tony@chromium.org>
2510
2511         refactor flexbox in preparation for flex-line-pack
2512         https://bugs.webkit.org/show_bug.cgi?id=81843
2513
2514         Reviewed by Ojan Vafai.
2515
2516         Replace WrapReverseContext with a vector of LineContexts that contain
2517         the same information, plus values needed for flex-align.
2518
2519         alignChildren has been moved to after all the lines have been
2520         positioned. We want to align children after flex-line-pack has changed
2521         the size of each line to avoid unnecessary layouts.
2522
2523         Take 2: Remove the assert. If there are no children, then there are no
2524         flex lines. Instead, assert that child is not null.
2525
2526         No new tests, just refactoring.
2527
2528         * rendering/RenderFlexibleBox.cpp:
2529         (WebCore::RenderFlexibleBox::LineContext::LineContext): New struct,
2530         holds information needed for wrap-reverse and aligning children.
2531         (RenderFlexibleBox::LineContext):
2532         (WebCore::RenderFlexibleBox::layoutFlexItems): alignChildren after layout out all the lines rather than after each line.
2533         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): don't alignChildren
2534         (WebCore::RenderFlexibleBox::alignChildren): align all flex items, not just a line at a time.
2535         (WebCore::RenderFlexibleBox::flipForWrapReverse): Update to use LineContext
2536         * rendering/RenderFlexibleBox.h:
2537
2538 2012-03-22  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2539
2540         Event dispatching in XMLHttpRequestProgressEventThrottle should go through XMLHttpRequestProgressEventThrottle::dispatchEvent
2541         https://bugs.webkit.org/show_bug.cgi?id=46743
2542
2543         Reviewed by Julien Chaffraix
2544         Based on original patch by Anton D'Auria
2545
2546         In preparation for platform-specific queuing of XMLHttpRequest events,
2547         this patch changes all calls to m_target->dispatchEvent to
2548         XMLHttpRequestProgressEventThrottle::dispatchEvent.
2549         Currently, we queue only one progress event on suspend() if we have
2550         throttled progress events. We should be able to queue all XHR events
2551         that can be generated after suspend(), if the platform network layer
2552         continues to receive data.
2553         XMLHttpRequest uses XMLHttpRequestProgressEventThrottle to dispatch only
2554         download events, so this doesn't change behavior of upload events, which
2555         aren't throttled or queued.
2556
2557         * xml/XMLHttpRequest.cpp:
2558         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
2559         * xml/XMLHttpRequestProgressEventThrottle.cpp:
2560         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchReadyStateChangeEvent):
2561         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchEvent):
2562         (WebCore::XMLHttpRequestProgressEventThrottle::flushProgressEvent):
2563         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchPausedEvent):
2564         (WebCore::XMLHttpRequestProgressEventThrottle::fired):
2565         * xml/XMLHttpRequestProgressEventThrottle.h:
2566         (XMLHttpRequestProgressEventThrottle):
2567
2568 2012-03-22  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
2569
2570         [EFL] Map BackSpace key code to Unicode value
2571         https://bugs.webkit.org/show_bug.cgi?id=81130
2572
2573         Reviewed by Gustavo Noronha Silva.
2574
2575         Test: fast/events/backspace-navigates-back.html
2576
2577         * platform/efl/EflKeyboardUtilities.cpp:
2578         (WebCore::createKeyMap): Map BackSpace to Unicode value
2579
2580 2012-03-22  Abhishek Arya  <inferno@chromium.org>
2581
2582         Incorrect beforeChild parent calculation in RenderRubyBase::moveChildren.
2583         https://bugs.webkit.org/show_bug.cgi?id=80297
2584
2585         Reviewed by Julien Chaffraix.
2586
2587         beforeChild might share the same anonymous block parent with other previous
2588         siblings. Before moving the children across ruby bases, we need to make sure
2589         to split the tree across the beforeChild correctly.
2590
2591         Test: fast/ruby/ruby-text-before-child-split.html
2592
2593         * rendering/RenderRubyBase.cpp:
2594         (WebCore::RenderRubyBase::moveChildren):
2595
2596 2012-03-22  Kristóf Kosztyó  <kkristof@inf.u-szeged.hu>
2597
2598         [Qt] Fix Qt minimal build after r111692
2599
2600         Reviewed by Csaba Osztrogonác.
2601
2602         * bindings/js/JSScriptProfileNodeCustom.cpp:
2603
2604 2012-03-22  Adrienne Walker  <enne@google.com>
2605
2606         [chromium] Fix scrollbar layers holding onto invalid textures after lost context
2607         https://bugs.webkit.org/show_bug.cgi?id=81841
2608
2609         Reviewed by James Robinson.
2610
2611         Unit test: CCLayerTreeHostImplTest.scrollbarLayerLostContext
2612
2613         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
2614         (WebCore::CCScrollbarLayerImpl::willDraw):
2615
2616 2012-03-22  Philippe Normand  <pnormand@igalia.com>
2617
2618         [GTK] ASSERT bug in WebAudio (AudioFileReader)
2619         https://bugs.webkit.org/show_bug.cgi?id=81777
2620
2621         Reviewed by Martin Robinson.
2622
2623         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
2624         (WebCore::AudioFileReader::decodeAudioForBusCreation): Don't steal
2625         the GstBus floating reference.
2626         (WebCore::AudioFileReader::createBus): Ditto.
2627
2628 2012-03-22  Ilya Tikhonovsky  <loislo@chromium.org>
2629
2630         Unreviewed: Web Inspector: fix syntax error in text.
2631
2632         * English.lproj/localizedStrings.js:
2633         * inspector/front-end/HeapSnapshotProxy.js:
2634         (WebInspector.HeapSnapshotWorker.prototype._messageReceived):
2635
2636 2012-03-22  Sheriff Bot  <webkit.review.bot@gmail.com>
2637
2638         Unreviewed, rolling out r111688.
2639         http://trac.webkit.org/changeset/111688
2640         https://bugs.webkit.org/show_bug.cgi?id=81912
2641
2642         "Heap profiler test fails" (Requested by yurys on #webkit).
2643
2644         * inspector/front-end/HeapSnapshot.js:
2645         (WebInspector.HeapSnapshot.prototype._buildRetainers):
2646
2647 2012-03-22  Dana Jansens  <danakj@chromium.org>
2648
2649         [chromium] Early out in a new prepareToDraw() step if checkerboarding an accelerated animation in order to skip the frame
2650         https://bugs.webkit.org/show_bug.cgi?id=81437
2651
2652         Reviewed by Adrienne Walker.
2653
2654         Split CCLayerTreeHostImpl::drawLayers() into two phases:
2655         prepareToDraw() and drawLayers().
2656
2657         When calculating a RenderPass, and we checkerboard a quad on a
2658         layer, bubble this info back up to CCLayerTreeHostImpl. If the
2659         layer is transforming in an animation, then abort the prepareToDraw()
2660         phase and cause it to return false back to the thread proxy.
2661
2662         Unit test: CCLayerTreeHostImplTest.prepareToDrawFailsWhenAnimationUsesCheckerboard
2663
2664         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
2665         (WebCore::CCLayerImpl::appendQuads):
2666         * platform/graphics/chromium/cc/CCLayerImpl.h:
2667         (CCLayerImpl):
2668         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2669         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
2670         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
2671         (WebCore):
2672         (WebCore::CCLayerTreeHostImpl::drawLayers):
2673         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
2674         (CCLayerTreeHostImpl):
2675         (FrameData):
2676         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
2677         (WebCore::CCQuadCuller::append):
2678         * platform/graphics/chromium/cc/CCQuadCuller.h:
2679         (CCQuadCuller):
2680         * platform/graphics/chromium/cc/CCRenderPass.cpp:
2681         (WebCore::CCRenderPass::appendQuadsForLayer):
2682         * platform/graphics/chromium/cc/CCRenderPass.h:
2683         (CCRenderPass):
2684         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
2685         (WebCore::CCScrollbarLayerImpl::appendQuads):
2686         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
2687         (CCScrollbarLayerImpl):
2688         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
2689         (WebCore::CCSingleThreadProxy::doComposite):
2690         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp:
2691         (WebCore::CCSolidColorLayerImpl::appendQuads):
2692         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h:
2693         (CCSolidColorLayerImpl):
2694         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
2695         (WebCore::CCTextureLayerImpl::appendQuads):
2696         * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
2697         (CCTextureLayerImpl):
2698         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
2699         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
2700         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
2701         (WebCore::CCTiledLayerImpl::appendQuads):
2702         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
2703         (CCTiledLayerImpl):
2704         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
2705         (WebCore::CCVideoLayerImpl::appendQuads):
2706         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
2707         (CCVideoLayerImpl):
2708
2709 2012-03-22  Levi Weintraub  <leviw@chromium.org>
2710
2711         Correct LayoutUnit usage in Accessibility code
2712         https://bugs.webkit.org/show_bug.cgi?id=81789
2713
2714         Reviewed by Eric Seidel.
2715
2716         Reverting Accessibility hit testing code back to integers. Accessibility hit tests originate from
2717         the embedder and don't accumulate offsets, so we get nothing from using LayoutUnits, and needlessly
2718         expose them to the embedder.
2719
2720         No new tests. No change in behavior.
2721
2722         * accessibility/AccessibilityListBox.cpp:
2723         (WebCore::AccessibilityListBox::elementAccessibilityHitTest): See above.
2724         * accessibility/AccessibilityListBox.h:
2725         (AccessibilityListBox):
2726         * accessibility/AccessibilityObject.cpp:
2727         (WebCore::AccessibilityObject::clickPoint): This value is only ever used to display a context menu,
2728         which is always done with integer coordinates.
2729         (WebCore::AccessibilityObject::boundingBoxForQuads): This is a bounding box built from floats. We
2730         don't pixel snap floats, so we return an integer bounding box.
2731         (WebCore::AccessibilityObject::elementAccessibilityHitTest): See above.
2732         (WebCore::AccessibilityObject::scrollToMakeVisible): Pixel snapping the bounding box and simplifying
2733         up the code to position it at (0,0).
2734         * accessibility/AccessibilityObject.h:
2735         (WebCore::AccessibilityObject::accessibilityHitTest): See above.
2736         (AccessibilityObject):
2737         (WebCore::AccessibilityObject::pixelSnappedBoundingBoxRect): Convenience method for embedder callers.
2738         * accessibility/AccessibilityRenderObject.cpp:
2739         (WebCore::AccessibilityRenderObject::visiblePositionForPoint): The point passed in here is comes from
2740         screen coordinates and originates in embedder code. Reverting it to take an integer.
2741         (WebCore::AccessibilityRenderObject::accessibilityImageMapHitTest): See above.
2742         (WebCore::AccessibilityRenderObject::accessibilityHitTest): See above.
2743         * accessibility/AccessibilityRenderObject.h:
2744         (AccessibilityRenderObject):
2745         * accessibility/AccessibilityScrollView.cpp:
2746         (WebCore::AccessibilityScrollView::accessibilityHitTest): See above.
2747         * accessibility/AccessibilityScrollView.h:
2748         (AccessibilityScrollView):
2749         * accessibility/AccessibilitySlider.cpp:
2750         (WebCore::AccessibilitySlider::elementAccessibilityHitTest): See above.
2751         * accessibility/AccessibilitySlider.h:
2752         (AccessibilitySlider):
2753
2754 2012-03-21  Ilya Tikhonovsky  <loislo@chromium.org>
2755
2756         Web Inspector: HeapProfiler: Heap snapshot worker has to report the errors to the front-end
2757         https://bugs.webkit.org/show_bug.cgi?id=81804
2758
2759         Sometimes the worker process of HeapSnapshot does some wrong thing and throw an Exception.
2760         At this momemnt we have no way to see the error in the front-end.
2761
2762         Reviewed by Yury Semikhatsky.
2763
2764         * English.lproj/localizedStrings.js:
2765         * inspector/front-end/HeapSnapshotProxy.js: check the exception field and dump it into front-end's console.
2766         (WebInspector.HeapSnapshotWorker.prototype._messageReceived):
2767         * inspector/front-end/HeapSnapshotWorkerDispatcher.js: catch the exception and transfer it's text to requester's side.
2768         (WebInspector.HeapSnapshotWorkerDispatcher.prototype.dispatchMessage):
2769
2770 2012-03-22  Carlos Garcia Campos  <cgarcia@bb-webkit-rel-64.local.igalia.com>
2771
2772         [GTK] Use the angle-bracket form to include wtf headers
2773         https://bugs.webkit.org/show_bug.cgi?id=81884
2774
2775         Reviewed by Eric Seidel.
2776
2777         Use #include <wtf/foo> instead of #include "foo".
2778
2779         * platform/graphics/freetype/FontPlatformData.h:
2780         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2781         * platform/gtk/DataObjectGtk.h:
2782         * platform/network/ResourceHandleInternal.h:
2783         * platform/network/soup/SocketStreamHandleSoup.cpp:
2784
2785 2012-03-22  Alexander Pavlov  <apavlov@chromium.org>
2786
2787         Web Inspector: Case of the elements of the xml document should be shown as it is in the console
2788         https://bugs.webkit.org/show_bug.cgi?id=81902
2789
2790         When registering a detached root, DOMAgent always presumes it is a node,
2791         while it can also be a document.
2792
2793         Reviewed by Vsevolod Vlasov.
2794
2795         Test: inspector/console/console-xml-document.html
2796
2797         * inspector/front-end/ConsoleMessage.js:
2798         (WebInspector.ConsoleMessageImpl.prototype._formatParameterAsNode):
2799         * inspector/front-end/DOMAgent.js:
2800         (WebInspector.DOMAgent.prototype._setDetachedRoot):
2801
2802 2012-03-22  Vsevolod Vlasov  <vsevik@chromium.org>
2803
2804         Web Inspector: Introduce ScriptBound/ScriptUnbound events in ScriptMapping.
2805         https://bugs.webkit.org/show_bug.cgi?id=81904
2806
2807         Reviewed by Pavel Feldman.
2808
2809         This is another step on the way to cleaner BreakpointManager logic.
2810         Here we extract ScriptBound/ScriptUnbound events from UISourceCodeListChanged event.
2811         This allows us to handle script-uiSourceCode binding separately from
2812         uiSourceCode creation/deletion and to handle unbinding that was not
2813         possible at all before.
2814
2815         * inspector/front-end/CompilerScriptMapping.js:
2816         (WebInspector.CompilerScriptMapping.prototype._uiSourceCodesForSourceMap):
2817         (WebInspector.CompilerScriptMapping.prototype.addScript.get this):
2818         (WebInspector.CompilerScriptMapping.prototype.addScript):
2819         (WebInspector.CompilerScriptMapping.prototype.reset):
2820         * inspector/front-end/ResourceScriptMapping.js:
2821         (WebInspector.ResourceScriptMapping.prototype._uiSourceCodeChanged):
2822         * inspector/front-end/ScriptMapping.js:
2823         (WebInspector.MainScriptMapping):
2824         (WebInspector.MainScriptMapping.prototype._updateLiveLocation):
2825         (WebInspector.MainScriptMapping.prototype._handleUISourceCodeListChanged):
2826         (WebInspector.MainScriptMapping.prototype._handleScriptBound):
2827         (WebInspector.MainScriptMapping.prototype._handleScriptUnbound):
2828         * inspector/front-end/SnippetsModel.js:
2829         (WebInspector.SnippetsScriptMapping.prototype.addScript.get this):
2830         (WebInspector.SnippetsScriptMapping.prototype._snippetAdded):
2831         (WebInspector.SnippetsScriptMapping.prototype._createUISourceCodeForScript):
2832         (WebInspector.SnippetsScriptMapping.prototype._snippetRemoved.get this):
2833         (WebInspector.SnippetsScriptMapping.prototype._snippetRemoved):
2834         (WebInspector.SnippetsScriptMapping.prototype.reset):
2835
2836 2012-03-22  Vineet Chaudhary  <rgf748@motorola.com>
2837
2838         https://bugs.webkit.org/show_bug.cgi?id=81893
2839         Remove custom bindings form ScriptProfileNode.idl of attribute type Array.
2840
2841         Reviewed by Kentaro Hara.
2842
2843         Replace [CustomGetter] Array with sequence<ScriptProfileNode>.
2844         To remove the custom bindings code.
2845
2846         Test: No new tests. LayoutTests/fast/profiler/* test are enough for this.
2847
2848         * bindings/js/JSScriptProfileNodeCustom.cpp: Removed custom function.
2849         (WebCore::JSScriptProfileNode::callUID):
2850         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp: Removed custom function.
2851         (WebCore):
2852         * inspector/ScriptProfileNode.idl: Replaced Array with sequence<ScriptProfileNode>.
2853
2854 2012-03-22  Andrey Kosyakov  <caseq@chromium.org>
2855
2856         Web Inspector: only update timeline overview categories strips when these are visible
2857         https://bugs.webkit.org/show_bug.cgi?id=81903
2858
2859         Reviewed by Pavel Feldman.
2860
2861         - factor out category strips update into a separate method;
2862         - only invoke it when "Timeline" overview mode is selected.
2863
2864         * inspector/front-end/TimelineOverviewPane.js:
2865         (WebInspector.TimelineOverviewPane.prototype._showTimelines):
2866         (WebInspector.TimelineOverviewPane.prototype.update):
2867         (WebInspector.TimelineOverviewPane.prototype._updateCategoryStrips):
2868
2869 2012-03-22  Levi Weintraub  <leviw@chromium.org>
2870
2871         Update LayoutUnit usage in FrameSelection
2872         https://bugs.webkit.org/show_bug.cgi?id=81754
2873
2874         Reviewed by Eric Seidel.
2875
2876         FrameSelection stores its caret and repaint bounds in absolute coordinates. Absolute coordinates
2877         we treat as pixel values, so this patch changes these values to integers. Sub-pixel precision
2878         will still be used when these coordinates are passed down and used locally.
2879
2880         No new tests. No change in behavior.
2881
2882         * editing/FrameSelection.cpp:
2883         (WebCore::absoluteCaretY): Uses absolute coordinates, which are ints.
2884         (WebCore::FrameSelection::modify): Uses absolute coordinates to handle vertical selection
2885         modification. Sub-pixel precision will be used when these values are converted to local ones.
2886         (WebCore::CaretBase::absoluteBoundsForLocalRect): Absolute coordinates -> ints.
2887         (WebCore::FrameSelection::absoluteCaretBounds): Ditto.
2888         (WebCore::CaretBase::caretRepaintRect): The caret repaint rect is stored in absolute coordinates.
2889         Reverting the values to ints.
2890         (WebCore::FrameSelection::recomputeCaretRect): Ditto.
2891         * editing/FrameSelection.h:
2892         (FrameSelection):
2893         * editing/mac/FrameSelectionMac.mm:
2894         (WebCore::FrameSelection::notifyAccessibilityForSelectionChange): Switching to store absolute
2895         coordinates as integers.
2896
2897 2012-03-22  Alexei Filippov  <alexeif@chromium.org>
2898
2899         Web Inspector: Speed up the build retainers phase.
2900         https://bugs.webkit.org/show_bug.cgi?id=81763
2901
2902         Replacing the edge iterator with a raw loop makes it
2903         faster by more than 10 times.
2904
2905         Reviewed by Yury Semikhatsky.
2906
2907         * inspector/front-end/HeapSnapshot.js:
2908         (WebInspector.HeapSnapshot.prototype._buildRetainers):
2909
2910 2012-03-22  No'am Rosenthal  <noam.rosenthal@nokia.com>
2911
2912         [Qt][WK2] The background appears to have one extra pixel from the contents
2913         https://bugs.webkit.org/show_bug.cgi?id=81830
2914
2915         Reviewed by Kenneth Rohde Christiansen.
2916
2917         TextureMapperGL applied a 1-offset that was covering for another bug,
2918         which was already fixed.
2919
2920         No new tests, this would be tested once we test GL rendering results.
2921
2922         * platform/graphics/texmap/TextureMapperGL.cpp:
2923         (WebCore::TextureMapperGLData::SharedGLData::scissorClip):
2924
2925 2012-03-22  W. James MacLean  <wjmaclean@chromium.org>
2926
2927         Rename touchpad fling curve, add curve parameters to constructor.
2928         https://bugs.webkit.org/show_bug.cgi?id=81820
2929
2930         Reviewed by Adrienne Walker.
2931
2932         Covered by existing unit tests.
2933
2934         * GNUmakefile.list.am:
2935         * WebCore.gypi:
2936         * platform/ScrollAnimatorNone.cpp:
2937         (WebCore::ScrollAnimatorNone::fireUpAnAnimation):
2938         * platform/TouchpadFlingPlatformGestureCurve.cpp: Renamed from Source/WebCore/platform/TouchFlingPlatformGestureCurve.cpp.
2939         (WebCore):
2940         (WebCore::TouchpadFlingPlatformGestureCurve::create):
2941         (WebCore::TouchpadFlingPlatformGestureCurve::TouchpadFlingPlatformGestureCurve):
2942         (WebCore::TouchpadFlingPlatformGestureCurve::~TouchpadFlingPlatformGestureCurve):
2943         (WebCore::TouchpadFlingPlatformGestureCurve::apply):
2944         * platform/TouchpadFlingPlatformGestureCurve.h: Renamed from Source/WebCore/platform/TouchFlingPlatformGestureCurve.h.
2945         (WebCore):
2946         (TouchpadFlingPlatformGestureCurve):
2947
2948 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
2949
2950         Web Inspector: make CSS and JavaScript files editable by default.
2951         https://bugs.webkit.org/show_bug.cgi?id=81787
2952
2953         Reviewed by Vsevolod Vlasov.
2954
2955         This change removes cancelEditing and setReadOnly capabilities from source frame.
2956         It removes dblclick handler as well since one does not need to enter editing mode.
2957         It also establishes proper content dispatching so that views are updated with the
2958         resource content. All these are inter-dependent, need to be landed simultaneously.
2959         Drive-by follow up to the r111675 where range is modified prior to the exiting
2960         edit mode.
2961
2962         * inspector/front-end/JavaScriptSourceFrame.js:
2963         (WebInspector.JavaScriptSourceFrame):
2964         (WebInspector.JavaScriptSourceFrame.prototype.requestContent):
2965         (WebInspector.JavaScriptSourceFrame.prototype.afterTextChanged):
2966         (WebInspector.JavaScriptSourceFrame.prototype.beforeTextChanged):
2967         (WebInspector.JavaScriptSourceFrame.prototype.didEditContent):
2968         (WebInspector.JavaScriptSourceFrame.prototype._lineNumberAfterEditing):
2969         * inspector/front-end/ResourceView.js:
2970         (WebInspector.ResourceSourceFrame):
2971         (WebInspector.ResourceSourceFrame.prototype.suggestedFileName):
2972         (WebInspector.ResourceSourceFrame.prototype._contentChanged):
2973         (WebInspector.EditableResourceSourceFrame.prototype.canEditSource):
2974         (WebInspector.EditableResourceSourceFrame.prototype.editContent.callbackWrapper):
2975         (WebInspector.EditableResourceSourceFrame.prototype.editContent):
2976         (WebInspector.EditableResourceSourceFrame.prototype._contentChanged):
2977         * inspector/front-end/ResourcesPanel.js:
2978         (WebInspector.ResourcesPanel.prototype._innerShowView):
2979         (WebInspector.FrameResourceTreeElement.prototype._appendRevision):
2980         * inspector/front-end/ScriptsPanel.js:
2981         (WebInspector.ScriptsPanel.prototype.setScriptSourceIsDirty):
2982         * inspector/front-end/Settings.js:
2983         (WebInspector.ExperimentsSettings):
2984         * inspector/front-end/SourceFrame.js:
2985         (WebInspector.SourceFrame):
2986         (WebInspector.SourceFrame.prototype.wasShown):
2987         (WebInspector.SourceFrame.prototype.willHide):
2988         (WebInspector.SourceFrame.prototype.beforeTextChanged):
2989         (WebInspector.SourceFrame.prototype.setContent):
2990         (WebInspector.SourceFrame.prototype.commitEditing):
2991         (WebInspector.SourceFrame.prototype.didEditContent):
2992         (WebInspector.SourceFrame.prototype.editContent):
2993         * inspector/front-end/TextPrompt.js:
2994         (WebInspector.TextPrompt.prototype._startEditing):
2995         (WebInspector.TextPrompt.prototype._stopEditing):
2996         * inspector/front-end/TextViewer.js:
2997         (WebInspector.TextViewer):
2998         (WebInspector.TextViewer.prototype._registerShortcuts):
2999         (WebInspector.TextEditorMainPanel.prototype.handleEnterKey):
3000
3001 2012-03-22  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
3002
3003         [Qt] Enable FAST_MOBILE_SCROLLING when scrolling is delegated.
3004         https://bugs.webkit.org/show_bug.cgi?id=81889
3005
3006         Reviewed by Kenneth Rohde Christiansen.
3007
3008         On the Qt platform only enable the fast mobile scroll feature when scrolling is delegated.
3009
3010         * rendering/RenderObject.cpp:
3011         (WebCore::RenderObject::styleWillChange):
3012
3013 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
3014
3015         Web Inspector: dispatch styleSheetChanged event synchronously.
3016         https://bugs.webkit.org/show_bug.cgi?id=81892
3017
3018         Reviewed by Vsevolod Vlasov.
3019
3020         Today, backend generates stylesheet change event synchronously from within set* command.
3021         But CSSStyleModel defers its dispatching until the stylesheet content is available. This
3022         prevents us from ignoring update events from within commands that initiated those updates.
3023
3024         This change makes stylesheet change event dispatch synchronously and delegates stylesheet
3025         content fetching to the event client.
3026
3027         * inspector/front-end/CSSStyleModel.js:
3028         (WebInspector.CSSStyleModel.prototype._fireStyleSheetChanged):
3029         (WebInspector.CSSStyleDeclaration.prototype.insertPropertyAt):
3030         (WebInspector.CSSStyleModelResourceBinding.prototype.setContent):
3031         (WebInspector.CSSStyleModelResourceBinding.prototype._innerSetContent.callbackWrapper):
3032         (WebInspector.CSSStyleModelResourceBinding.prototype._innerSetContent):
3033         (WebInspector.CSSStyleModelResourceBinding.prototype._styleSheetChanged.callback):
3034         (WebInspector.CSSStyleModelResourceBinding.prototype._styleSheetChanged):
3035         (WebInspector.CSSStyleModelResourceBinding.prototype._innerStyleSheetChanged):
3036
3037 2012-03-21  Ian Vollick  <vollick@chromium.org>
3038
3039         [chromium] timing functions are getting incorrectly applied for accelerated css transitions
3040         https://bugs.webkit.org/show_bug.cgi?id=81692
3041
3042         Reviewed by Adrienne Walker.
3043
3044         Tested in CCLayerTreeHostTestAddAnimationWithTimingFunction
3045
3046         * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
3047
3048 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
3049
3050         Web Inspector: allow on-hover popover while in edit mode.
3051         https://bugs.webkit.org/show_bug.cgi?id=81898
3052
3053         Reviewed by Vsevolod Vlasov.
3054
3055         This change allows popover while in-edit mode, hides it upon Esc. It also introduces anchorOverride
3056         concept in ObjectPopoverHelper that allows dynamically switching the anchor (say if we want to highlight anchor itself).
3057
3058         * inspector/front-end/DetailedHeapshotView.js:
3059         * inspector/front-end/ElementsPanel.js:
3060         * inspector/front-end/JavaScriptSourceFrame.js:
3061         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover.showObjectPopover):
3062         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover):
3063         (WebInspector.JavaScriptSourceFrame.prototype._onKeyDown):
3064         * inspector/front-end/NetworkPanel.js:
3065         * inspector/front-end/ObjectPopoverHelper.js:
3066         (WebInspector.ObjectPopoverHelper.prototype._showObjectPopover.showObjectPopover.):
3067         (WebInspector.ObjectPopoverHelper.prototype._showObjectPopover):
3068         * inspector/front-end/Popover.js:
3069         (WebInspector.PopoverHelper.prototype.isPopoverVisible):
3070         * inspector/front-end/TimelinePanel.js:
3071
3072 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
3073
3074         Web Inspector: breakpoints should shift when line break is inserted in the middle of the line.
3075         https://bugs.webkit.org/show_bug.cgi?id=81896
3076
3077         Reviewed by Vsevolod Vlasov.
3078
3079         There is a bug that collapses selection prior to exiting change mode, we should never
3080         collapse edit area prior committing.
3081
3082         * inspector/front-end/TextEditorModel.js:
3083         (WebInspector.TextEditorModel.endsWithBracketRegex.):
3084         * inspector/front-end/TextViewer.js:
3085         (WebInspector.TextViewer):
3086         (WebInspector.TextEditorMainPanel.prototype.highlightLine):
3087         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo.callback):
3088         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo):
3089
3090 2012-03-22  Zoltan Herczeg  <zherczeg@webkit.org>
3091
3092         Merge SVGImageBufferTools to SVGRenderingContext
3093         https://bugs.webkit.org/show_bug.cgi?id=81890
3094
3095         Reviewed by Nikolas Zimmermann.
3096
3097         Copy the code to SVGRenderingContext and delete
3098         SVGImageBufferTools[.cpp.h]. Update build systems,
3099         no functionality change. This is the first step
3100         towards making SVGImageBufferTools stageful.
3101
3102         Existing tests cover this issue.
3103
3104         * CMakeLists.txt:
3105         * GNUmakefile.list.am:
3106         * Target.pri:
3107         * WebCore.gypi:
3108         * WebCore.xcodeproj/project.pbxproj:
3109         * platform/graphics/filters/FETile.cpp:
3110         (WebCore::FETile::platformApplySoftware):
3111         * rendering/svg/RenderSVGAllInOne.cpp:
3112         * rendering/svg/RenderSVGInlineText.cpp:
3113         (WebCore::RenderSVGInlineText::computeNewScaledFontForStyle):
3114         * rendering/svg/RenderSVGResourceClipper.cpp:
3115         (WebCore::RenderSVGResourceClipper::applyClippingToContext):
3116         (WebCore::RenderSVGResourceClipper::drawContentIntoMaskImage):
3117         * rendering/svg/RenderSVGResourceFilter.cpp:
3118         (WebCore::RenderSVGResourceFilter::applyResource):
3119         * rendering/svg/RenderSVGResourceGradient.cpp:
3120         (WebCore::createMaskAndSwapContextForTextGradient):
3121         (WebCore::clipToTextMask):
3122         * rendering/svg/RenderSVGResourceMasker.cpp:
3123         (WebCore::RenderSVGResourceMasker::applyResource):
3124         (WebCore::RenderSVGResourceMasker::drawContentIntoMaskImage):
3125         * rendering/svg/RenderSVGResourcePattern.cpp:
3126         (WebCore::RenderSVGResourcePattern::applyResource):
3127         (WebCore::RenderSVGResourcePattern::createTileImage):
3128         * rendering/svg/SVGImageBufferTools.cpp: Removed.
3129         * rendering/svg/SVGImageBufferTools.h: Removed.
3130         * rendering/svg/SVGInlineTextBox.cpp:
3131         * rendering/svg/SVGRenderingContext.cpp:
3132         (WebCore::currentContentTransformation):
3133         (WebCore):
3134         (WebCore::SVGRenderingContext::calculateTransformationToOutermostSVGCoordinateSystem):
3135         (WebCore::SVGRenderingContext::createImageBuffer):
3136         (WebCore::SVGRenderingContext::createImageBufferForPattern):
3137         (WebCore::SVGRenderingContext::renderSubtreeToImageBuffer):
3138         (WebCore::SVGRenderingContext::clipToImageBuffer):
3139         (WebCore::SVGRenderingContext::clampedAbsoluteTargetRect):
3140         (WebCore::SVGRenderingContext::clampedAbsoluteSize):
3141         (WebCore::SVGRenderingContext::clear2DRotation):
3142         * rendering/svg/SVGRenderingContext.h:
3143         (SVGRenderingContext):
3144         (WebCore::SVGRenderingContext::calculateImageBufferRect):
3145         * svg/graphics/filters/SVGFEImage.cpp:
3146         (WebCore::FEImage::platformApplySoftware):
3147
3148 2012-03-22  Hyowon Kim  <hw1008.kim@samsung.com>
3149
3150         [EFL] Add PageClientEfl to WebCoreSupport.
3151         https://bugs.webkit.org/show_bug.cgi?id=80748
3152
3153         Reviewed by Noam Rosenthal.
3154
3155         * platform/Widget.h: Use PageClientEfl as type for PlatformPageClient.
3156         (WebCore):
3157         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
3158         (WebCore::GraphicsContext3DPrivate::createSurface): Change the argument type.
3159         * plugins/efl/PluginViewEfl.cpp:
3160         (WebCore::PluginView::platformGetValue): Use PageClientEfl.
3161
3162 2012-03-22  Kaustubh Atrawalkar  <kaustubh@motorola.com>
3163
3164         blur() on shadow host should work when a shadow host contains a focused element in its shadow DOM subtrees
3165         https://bugs.webkit.org/show_bug.cgi?id=81102
3166
3167         Reviewed by Hajime Morita.
3168
3169         This implementation will support blur for a focused element when its shadowHost's blur() is called.
3170         To achieve this Element::blur() function is modified to blur the focused node in it's treeScope.
3171
3172         Test: fast/dom/shadow/shadow-root-blur.html
3173
3174         * dom/Element.cpp:
3175         (WebCore::Element::blur): Modified to blur current treeScope's focused node.
3176         * dom/ShadowRoot.h:
3177         (WebCore::ShadowRoot::activeElement): Rework for code sharing.
3178         * dom/TreeScope.cpp:
3179         (WebCore::TreeScope::focusedNode): Added new function to share code for getting focused node.
3180         * dom/TreeScope.h:
3181         (TreeScope): New function declartion.
3182         * html/HTMLDocument.cpp:
3183         (WebCore::HTMLDocument::activeElement): Rework for code sharing.
3184
3185 2012-03-22  Vsevolod Vlasov  <vsevik@chromium.org>
3186
3187         Web Inspector: RawSourceCode does not need uiSourceCode lists because it never has more than one.
3188         https://bugs.webkit.org/show_bug.cgi?id=81894
3189
3190         RawSourceCode never has more than one uiSourceCode, uiSourceCodeList
3191         are just remains of older implementation. This patch switches RawSourceCode
3192         and SourceMappings from uiSourceCodeList to uiSourceCode.
3193
3194         Reviewed by Pavel Feldman.
3195
3196         * inspector/front-end/RawSourceCode.js:
3197         (WebInspector.RawSourceCode.prototype.uiSourceCode):
3198         (WebInspector.RawSourceCode.prototype._saveSourceMapping):
3199         (WebInspector.RawSourceCode.SourceMapping.prototype.uiLocationToRawLocation):
3200         (WebInspector.RawSourceCode.SourceMapping.prototype.uiSourceCode):
3201         (WebInspector.RawSourceCode.PlainSourceMapping):
3202         (WebInspector.RawSourceCode.PlainSourceMapping.prototype.rawLocationToUILocation):
3203         (WebInspector.RawSourceCode.PlainSourceMapping.prototype.uiLocationToRawLocation):
3204         (WebInspector.RawSourceCode.PlainSourceMapping.prototype.uiSourceCode):
3205         (WebInspector.RawSourceCode.FormattedSourceMapping):
3206         (WebInspector.RawSourceCode.FormattedSourceMapping.prototype.rawLocationToUILocation):
3207         (WebInspector.RawSourceCode.FormattedSourceMapping.prototype.uiLocationToRawLocation):
3208         (WebInspector.RawSourceCode.FormattedSourceMapping.prototype.uiSourceCode):
3209         * inspector/front-end/ResourceScriptMapping.js:
3210         (WebInspector.ResourceScriptMapping.prototype.uiSourceCodeList):
3211         (WebInspector.ResourceScriptMapping.prototype.addScript):
3212         (WebInspector.ResourceScriptMapping.prototype._handleUISourceCodeChanged):
3213         (WebInspector.ResourceScriptMapping.prototype._uiSourceCodeChanged):
3214         (WebInspector.ResourceScriptMapping.prototype.reset):
3215
3216 2012-03-22  Mario Sanchez Prada  <msanchez@igalia.com>
3217
3218         [GTK] Fix the only remaining coding style issue in GTK accessibility code
3219         https://bugs.webkit.org/show_bug.cgi?id=81885
3220
3221         Reviewed by Xan Lopez.
3222
3223         Add needed extra line and remove an unneeded one.
3224
3225         * accessibility/gtk/AccessibilityObjectAtk.cpp:
3226
3227 2012-03-22  Kent Tamura  <tkent@chromium.org>
3228
3229         Expand RenderTextControlSingleLine::controlClipRect() to contain contentRect().
3230         https://bugs.webkit.org/show_bug.cgi?id=81866
3231
3232         Reviewed by Hajime Morita.
3233
3234         We need to expand the controlClipRect because the existing shadow
3235         tree of a text field can be wrapped by another shadow tree. e.g.
3236
3237         A current situation:
3238
3239         <input>
3240           ┗ ShadowRoot
3241              ┗ container element
3242         ┌────────────┐<input>'s border box
3243         │┌──────────┐│
3244         ││container box       ││
3245         │└──────────┘│
3246         └────────────┘
3247
3248         Wrapped by another ShadowRoot:
3249
3250         <input>
3251           ┗ New ShadowRoot
3252              ┣ <shadow> represents the existing shadow tree
3253              ┃  ┗ container element
3254              ┗ D: an additional decoration element
3255         ┌────────────┐<input>'s border box
3256         │┌───────┬──┐│
3257         ││container box │ D  ││
3258         │└───────┴──┘│
3259         └────────────┘
3260         In this case, if we clip child renderers by container box, D is not
3261         drawn. We should clip by the content box of the <input>.
3262
3263         A search field has an exceptional behavior. It can have the container
3264         box of which height is taller than the content box height. The
3265         controlClipRect should contain both of the container box and the content
3266         box in this case. In other cases, the container box is equivalent to the
3267         content box. So the code always unites them.
3268
3269         No new tests. This won't make any behavior change for now.
3270
3271         * rendering/RenderTextControlSingleLine.cpp:
3272         (WebCore::RenderTextControlSingleLine::controlClipRect):
3273
3274 2012-03-22  Yoshifumi Inoue  <yosin@chromium.org>
3275
3276         [Forms] The option element should not be form associated element.
3277         https://bugs.webkit.org/show_bug.cgi?id=79764
3278
3279         Reviewed by Kent Tamura.
3280
3281         This patch changes base class of HTMLOptionELement to HTMLElement
3282         from HTMLFormControlElement for saving memory space and iteration
3283         time of extra "option" elements in HTMLFormElement::m_formAssociatedElements
3284         and matching the HTML5 specification for ease of maintenance.
3285
3286         This patch changes behavior of handling of CSS pseudo classes "invalid"
3287         and "valid". The "option" elements no longer use these CSS pseudo classes
3288         as HTML5 specification. This bug was filed in https://bugs.webkit.org/show_bug.cgi?id=80088
3289
3290         Changes of TextIterator is lead by usage of isFormControlElement. This
3291         changes will be replaced with more meaningful predicate as part of
3292         https://bugs.webkit.org/show_bug.cgi?id=80381
3293
3294         No new tests but updated select-live-pseudo-selectors.html test.
3295
3296         * css/CSSStyleSelector.cpp:
3297         (WebCore::CSSStyleSelector::canShareStyleWithElement): Added checking of the "option" element and returns false as HTMLFormControlElement.
3298         * css/SelectorChecker.cpp:
3299         (WebCore::SelectorChecker::checkOneSelector): Removed isFormControlElement for PseudoDisabled and PseudoChecked.
3300         * html/HTMLKeygenElement.cpp:
3301         (WebCore::HTMLKeygenElement::HTMLKeygenElement): Removed form parameter of call site of HTMLOptionElement::create.
3302         * html/HTMLOptionElement.cpp:
3303         (WebCore::HTMLOptionElement::HTMLOptionElement): Removed form parameter which no longer needed. Changed base class in initialization list. Added m_disabled initialization.
3304         (WebCore::HTMLOptionElement::create): Removed form parameter which no longer needed.
3305         (WebCore::HTMLOptionElement::attach): Changeid base class.
3306         (WebCore::HTMLOptionElement::detach): Changed base class.
3307         (WebCore::HTMLOptionElement::parseAttribute): Changed base class. Added "disabled" attribute handling.
3308         (WebCore::HTMLOptionElement::childrenChanged): Changed base class.
3309         (WebCore::HTMLOptionElement::insertedIntoTree): Changed base class.
3310         * html/HTMLOptionElement.h:
3311         (HTMLOptionElement): Added new member variable m_disabled which was in HTMLFormControlElement.
3312         (WebCore::HTMLOptionElement::ownElementDisabled): Changed for using m_disabled.
3313         * html/HTMLTagNames.in: Removed constructorNeedsFormElement for the "option" element, which was used for passing form parameter to create function.
3314
3315 2012-03-21  Pavel Podivilov  <podivilov@chromium.org>
3316
3317         Web Inspector: rename ClosureCompilerSourceMapping to SourceMapParser and move it to CompilerScriptMapping.js.
3318         https://bugs.webkit.org/show_bug.cgi?id=81780
3319
3320         Reviewed by Pavel Feldman.
3321
3322         * WebCore.gypi:
3323         * WebCore.vcproj/WebCore.vcproj:
3324         * inspector/compile-front-end.py:
3325         * inspector/front-end/CompilerScriptMapping.js:
3326         (WebInspector.CompilerScriptMapping.prototype.loadSourceMapForScript):
3327         (WebInspector.SourceMapParserPayload):
3328         (WebInspector.SourceMapParser):
3329         (WebInspector.SourceMapParser.prototype.load):
3330         (WebInspector.SourceMapParser.prototype.compiledLocationToSourceLocation):
3331         (WebInspector.SourceMapParser.prototype.sourceLocationToCompiledLocation):
3332         (WebInspector.SourceMapParser.prototype.sources):
3333         (WebInspector.SourceMapParser.prototype.loadSourceCode):
3334         (WebInspector.SourceMapParser.prototype._findMapping):
3335         (WebInspector.SourceMapParser.prototype._parseMappingPayload):
3336         (WebInspector.SourceMapParser.prototype._parseSections):
3337         (WebInspector.SourceMapParser.prototype._parseMap):
3338         (WebInspector.SourceMapParser.prototype._isSeparator):
3339         (WebInspector.SourceMapParser.prototype._decodeVLQ):
3340         (WebInspector.SourceMapParser.prototype._canonicalizeURL):
3341         (WebInspector.SourceMapParser.StringCharIterator):
3342         (WebInspector.SourceMapParser.StringCharIterator.prototype.next):
3343         (WebInspector.SourceMapParser.StringCharIterator.prototype.peek):
3344         (WebInspector.SourceMapParser.StringCharIterator.prototype.hasNext):
3345         * inspector/front-end/CompilerSourceMapping.js: Removed.
3346         * inspector/front-end/WebKit.qrc:
3347         * inspector/front-end/inspector.html:
3348
3349 2012-03-21  Vsevolod Vlasov  <vsevik@chromium.org>
3350
3351         Web Inspector: IndexedDB transaction is not closed when requesting data.
3352         https://bugs.webkit.org/show_bug.cgi?id=81837
3353
3354         Reviewed by Pavel Feldman.
3355
3356         * inspector/InspectorIndexedDBAgent.cpp: Added missing IDBCursorBackendInterface::postSuccessHandlerCallback() call.
3357         (WebCore):
3358
3359 2012-03-21  Yury Semikhatsky  <yurys@chromium.org>
3360
3361         Web Inspector: event listeners section is broken for about:blank page
3362         https://bugs.webkit.org/show_bug.cgi?id=81795
3363
3364         Parse about:blank as a valid URL.
3365
3366         Reviewed by Pavel Feldman.
3367
3368         Test: inspector/elements/event-listeners-about-blank.html
3369
3370         * inspector/front-end/utilities.js:
3371         (String.prototype.asParsedURL):
3372
3373 2012-03-21  Dan Bernstein  <mitz@apple.com>
3374
3375         REGRESSION (r111635): Assertion failure in RenderFlexibleBox::layoutFlexItems() (!lineContexts.size()) in many flexbox tests
3376         https://bugs.webkit.org/show_bug.cgi?id=81870
3377
3378         Reverted r111635, the fix for bug 81843.
3379
3380         * rendering/RenderFlexibleBox.cpp:
3381         (WebCore::RenderFlexibleBox::WrapReverseContext::WrapReverseContext):
3382         (WebCore::RenderFlexibleBox::WrapReverseContext::addCrossAxisOffset):
3383         (RenderFlexibleBox::WrapReverseContext):
3384         (WebCore::RenderFlexibleBox::WrapReverseContext::addNumberOfChildrenOnLine):
3385         (WebCore::RenderFlexibleBox::WrapReverseContext::lineCrossAxisDelta):
3386         (WebCore::RenderFlexibleBox::layoutFlexItems):
3387         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
3388         (WebCore::RenderFlexibleBox::alignChildren):
3389         (WebCore::RenderFlexibleBox::flipForWrapReverse):
3390         * rendering/RenderFlexibleBox.h:
3391
3392 2012-03-21  Emil A Eklund  <eae@chromium.org>
3393
3394         Unreviewed change touching CustomFilterProgram.h to try
3395         to force the chromium-win bots to rebuilt it and pick up
3396         on the fact that CSS_SHADERS is not set (since r111610). 
3397
3398         * platform/graphics/filters/CustomFilterProgram.h:
3399
3400 2012-03-21  Vangelis Kokkevis  <vangelis@chromium.org>
3401
3402         [chromium] FPS counter causes garbage to be displayed at top left corner
3403         https://bugs.webkit.org/show_bug.cgi?id=81851
3404
3405         The HUD expects the PlatformCanvas it paints on to be cleared on creation which is
3406         no longer true after http://src.chromium.org/viewvc/chrome?view=rev&revision=127196 .
3407         This patch does an explicit clearRect before the HUD contents are painted.
3408
3409         Reviewed by Adrienne Walker.
3410
3411         TEST=Manually verified that --show-fps-counter and --show-composited-layer-tree work correctly.
3412
3413         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
3414         (WebCore::CCHeadsUpDisplay::draw):
3415
3416 2012-03-21  Ryosuke Niwa  <rniwa@webkit.org>
3417
3418         Touch a file to make Chromium Windows bots happy.
3419
3420         * css/CSSValueKeywords.in:
3421
3422 2012-03-19  Igor Oliveira  <igor.o@sisa.samsung.com>
3423
3424         Every call to RenderObject::setAnimatableStyle() iterates through all m_compositeAnimations: potentially O(N^2)
3425         https://bugs.webkit.org/show_bug.cgi?id=38025
3426
3427         Implement updateAnimationTimerForRender. This reduces unnecessary animation
3428         steps on the current RenderObject by checking the value of timeToNextService
3429         before starting a new timer.
3430
3431         Reviewed by Dean Jackson.
3432
3433         Test: animations/animation-welcome-safari.html
3434
3435         * page/animation/AnimationController.cpp:
3436         (WebCore::AnimationControllerPrivate::updateAnimationTimerForRenderer):
3437         (WebCore):
3438         (WebCore::AnimationController::updateAnimations):
3439         * page/animation/AnimationControllerPrivate.h:
3440         (AnimationControllerPrivate):
3441
3442 2012-03-21  Sheriff Bot  <webkit.review.bot@gmail.com>
3443
3444         Unreviewed, rolling out r111616.
3445         http://trac.webkit.org/changeset/111616
3446         https://bugs.webkit.org/show_bug.cgi?id=81862
3447
3448         broke chromium mac (Requested by eae on #webkit).
3449
3450         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
3451         (WebCore::CCLayerImpl::appendQuads):
3452         * platform/graphics/chromium/cc/CCLayerImpl.h:
3453         (CCLayerImpl):
3454         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3455         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
3456         (WebCore::CCLayerTreeHostImpl::drawLayers):
3457         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3458         (CCLayerTreeHostImpl):
3459         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
3460         (WebCore::CCQuadCuller::append):
3461         * platform/graphics/chromium/cc/CCQuadCuller.h:
3462         (CCQuadCuller):
3463         * platform/graphics/chromium/cc/CCRenderPass.cpp:
3464         (WebCore::CCRenderPass::appendQuadsForLayer):
3465         * platform/graphics/chromium/cc/CCRenderPass.h:
3466         (CCRenderPass):
3467         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
3468         (WebCore::CCScrollbarLayerImpl::appendQuads):
3469         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
3470         (CCScrollbarLayerImpl):
3471         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
3472         (WebCore::CCSingleThreadProxy::doComposite):
3473         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp:
3474         (WebCore::CCSolidColorLayerImpl::appendQuads):
3475         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h:
3476         (CCSolidColorLayerImpl):
3477         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
3478         (WebCore::CCTextureLayerImpl::appendQuads):
3479         * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
3480         (CCTextureLayerImpl):
3481         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3482         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
3483         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
3484         (WebCore::CCTiledLayerImpl::appendQuads):
3485         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
3486         (CCTiledLayerImpl):
3487         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
3488         (WebCore::CCVideoLayerImpl::appendQuads):
3489         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
3490         (CCVideoLayerImpl):
3491
3492 2012-03-21  Beth Dakin  <bdakin@apple.com>
3493
3494         https://bugs.webkit.org/show_bug.cgi?id=80322
3495         Implement image-set
3496
3497         Reviewed by Dean Jackson.
3498
3499         This initial implementation of -webkit-image-set. 
3500         http://lists.w3.org/Archives/Public/www-style/2012Feb/1103.html
3501         The idea behind the feature is to allow authors to provide multiple variants 
3502         of the same image at differing resolutions, and to allow the User Agent to 
3503         choose the resource that is most appropriate at the time. This patch will 
3504         choose the most appropriate image based on device scale factor.
3505
3506         CSSImageSetValue inherits from CSSValueList and behaves a lot like 
3507         CSSImageValue.
3508         * WebCore.xcodeproj/project.pbxproj:
3509         * css/CSSImageSetValue.h: Added.
3510         (WebCore):
3511         (CSSImageSetValue):
3512         (WebCore::CSSImageSetValue::create):
3513         (WebCore::CSSImageSetValue::isPending):
3514         (ImageWithScale):
3515         (WebCore::CSSImageSetValue::compareByScaleFactor):
3516         * css/CSSImageSetValue.cpp: Added.
3517         (WebCore):
3518         (WebCore::CSSImageSetValue::CSSImageSetValue):
3519         (WebCore::CSSImageSetValue::~CSSImageSetValue):
3520         (WebCore::CSSImageSetValue::cachedOrPendingImageSet):
3521         (WebCore::CSSImageSetValue::customCssText):
3522
3523         fillImageSet() iterates through the value list and turns the information into 
3524         a sorted Vector of ImageWithScales (which is a struct containing image URLs 
3525         and scale factors).
3526         (WebCore::CSSImageSetValue::fillImageSet):
3527
3528         cachedImageSet() finds which image is most appropriate based on the device 
3529         scale factor, and it loads only that image. In the future, additional scale 
3530         factors will be taken into account.
3531         (WebCore::CSSImageSetValue::bestImageForScaleFactor):
3532         (WebCore::CSSImageSetValue::cachedImageSet):
3533
3534         parseImageSet() is called everywhere in the CSSParser that a regular image or 
3535         generated image can be found.
3536         * css/CSSParser.cpp:
3537         (WebCore::CSSParser::parseValue):
3538         (WebCore::CSSParser::parseContent):
3539         (WebCore::CSSParser::parseFillImage):
3540         (WebCore::CSSParser::parseBorderImage):
3541         (WebCore):
3542         (WebCore::CSSParser::parseImageSet):
3543         * css/CSSParser.h:
3544
3545         Since CSSImageSetValue is implemented as a value list, 
3546         ApplyPropertyFillLayer::applyValue() needs to be more specific when it's 
3547         looking for a list of multiple URLs.
3548         * css/CSSStyleApplyProperty.cpp:
3549         (WebCore::ApplyPropertyFillLayer::applyValue):
3550
3551         Handle image-set as a valid image value.
3552         * css/CSSStyleSelector.cpp:
3553         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3554         * css/CSSStyleSelector.h:
3555         (CSSStyleSelector):
3556         * css/CSSValue.cpp:
3557         (WebCore::CSSValue::cssText):
3558         (WebCore::CSSValue::destroy):
3559         * css/CSSValue.h:
3560         (CSSValue):
3561         (WebCore::CSSValue::isImageSetValue):
3562
3563         computeIntrinsicDimensions() now takes an optional scaleFactor parameter that represents the author-enforced "intrinsic" scale factor of the image.
3564         * loader/cache/CachedImage.cpp:
3565         (WebCore::CachedImage::computeIntrinsicDimensions):
3566         * loader/cache/CachedImage.h:
3567         (CachedImage):
3568         * platform/graphics/GeneratedImage.h:
3569         (GeneratedImage):
3570         * platform/graphics/GeneratorGeneratedImage.cpp:
3571         (WebCore::GeneratedImage::computeIntrinsicDimensions):
3572         * platform/graphics/Image.cpp:
3573         (WebCore::Image::computeIntrinsicDimensions):
3574         * platform/graphics/Image.h:
3575         (Image):
3576         * platform/graphics/cg/PDFDocumentImage.cpp:
3577         (WebCore::PDFDocumentImage::computeIntrinsicDimensions):
3578         * platform/graphics/cg/PDFDocumentImage.h:
3579         (PDFDocumentImage):
3580         * svg/graphics/SVGImage.cpp:
3581         (WebCore::SVGImage::computeIntrinsicDimensions):
3582         * svg/graphics/SVGImage.h:
3583         (SVGImage):
3584
3585         Inherits from StyleImage and returns a scaled size for imageSize() and 
3586         computeIntrinsicDimensions().
3587         * rendering/style/StyleCachedImageSet.cpp: Added.
3588         (WebCore):
3589         (WebCore::StyleCachedImageSet::StyleCachedImageSet):
3590         (WebCore::StyleCachedImageSet::cssValue):
3591         (WebCore::StyleCachedImageSet::canRender):
3592         (WebCore::StyleCachedImageSet::isLoaded):
3593         (WebCore::StyleCachedImageSet::errorOccurred):
3594         (WebCore::StyleCachedImageSet::imageSize):
3595         (WebCore::StyleCachedImageSet::imageHasRelativeWidth):
3596         (WebCore::StyleCachedImageSet::imageHasRelativeHeight):
3597         (WebCore::StyleCachedImageSet::computeIntrinsicDimensions):
3598         (WebCore::StyleCachedImageSet::usesImageContainerSize):
3599         (WebCore::StyleCachedImageSet::setContainerSizeForRenderer):
3600         (WebCore::StyleCachedImageSet::addClient):
3601         (WebCore::StyleCachedImageSet::removeClient):
3602         (WebCore::StyleCachedImageSet::image):
3603         * rendering/style/StyleCachedImageSet.h: Added.
3604         (WebCore):
3605         (StyleCachedImageSet):
3606         (WebCore::StyleCachedImageSet::create):
3607         (WebCore::StyleCachedImageSet::data):
3608         (WebCore::StyleCachedImageSet::cachedImage):
3609
3610         Handle image-set.
3611         * rendering/style/StyleImage.h:
3612         (WebCore::StyleImage::isCachedImageSet):
3613         (WebCore::StyleImage::StyleImage):
3614         (StyleImage):
3615         * rendering/style/StylePendingImage.h:
3616         (StylePendingImage):
3617         (WebCore::StylePendingImage::cssImageSetValue):
3618
3619 2012-03-21  David Barton  <dbarton@mathscribe.com>
3620
3621         MathML internals - improve naming in RenderMathMLSquareRoot.cpp and RenderMathMLRoot.cpp
3622         https://bugs.webkit.org/show_bug.cgi?id=81850
3623
3624         Reviewed by Eric Seidel.
3625
3626         This prepares these files for bug fixes, and eventually combining their common code. To
3627         understand this patch, I suggest you start with RenderMathMLSquareRoot.cpp, as it's
3628         simpler than RenderMathMLRoot.cpp.
3629
3630         No new tests. LayoutTests/mathml/presentation/roots.xhtml is thorough enough for this.
3631
3632         * rendering/mathml/RenderMathMLRoot.cpp:
3633         (WebCore):
3634         (WebCore::RenderMathMLRoot::addChild):
3635         (WebCore::RenderMathMLRoot::paint):
3636         (WebCore::RenderMathMLRoot::layout):
3637         * rendering/mathml/RenderMathMLRoot.h:
3638         (WebCore):
3639         (RenderMathMLRoot):
3640         * rendering/mathml/RenderMathMLSquareRoot.cpp:
3641         (WebCore):
3642         (WebCore::RenderMathMLSquareRoot::paint):
3643         (WebCore::RenderMathMLSquareRoot::layout):
3644         * rendering/mathml/RenderMathMLSquareRoot.h:
3645         (WebCore):
3646         (RenderMathMLSquareRoot):
3647         * rendering/mathml/RenderMathMLSubSup.h:
3648         (WebCore):
3649
3650 2012-03-21  Tony Chang  <tony@chromium.org>
3651
3652         refactor flexbox in preparation for flex-line-pack
3653         https://bugs.webkit.org/show_bug.cgi?id=81843
3654
3655         Reviewed by Ojan Vafai.
3656
3657         Replace WrapReverseContext with a vector of LineContexts that contain
3658         the same information, plus values needed for flex-align.
3659
3660         alignChildren has been moved to after all the lines have been
3661         positioned. We want to align children after flex-line-pack has changed
3662         the size of each line to avoid unnecessary layouts.
3663
3664         No new tests, just refactoring.
3665
3666         * rendering/RenderFlexibleBox.cpp:
3667         (WebCore::RenderFlexibleBox::LineContext::LineContext): New struct,
3668         holds information needed for wrap-reverse and aligning children.
3669         (RenderFlexibleBox::LineContext):
3670         (WebCore::RenderFlexibleBox::layoutFlexItems): alignChildren after layout out all the lines rather than after each line.
3671         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): don't alignChildren
3672         (WebCore::RenderFlexibleBox::alignChildren): align all flex items, not just a line at a time.
3673         (WebCore::RenderFlexibleBox::flipForWrapReverse): Update to use LineContext
3674         * rendering/RenderFlexibleBox.h:
3675
3676 2012-03-21  Ryosuke Niwa  <rniwa@webkit.org>
3677
3678         BDI element should have dir=auto by default
3679         https://bugs.webkit.org/show_bug.cgi?id=68773
3680
3681         Reviewed by Daniel Bates.
3682
3683         Treat bdi elements without dir content attribute as if they have dir=auto per spec:
3684         http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-bdi-element
3685
3686         The patch tries to encapsulate the logic to look for dir content attribute and dir=auto.
3687
3688         It also adds HTMLBDIElement interface (binding remains to use HTMLElement) to set
3689         selfOrAncestorHasDirAutoAttribute flag true by default, which is used by functions like
3690         directionalityIfhasDirAutoAttribute to look for elements with dir=auto. Since dir=auto-ness of bdi
3691         elements can be overridden by dir content attribute, we must change and only change the default value.
3692
3693         Tests: fast/text/international/bdi-dir-default-to-auto-expected.html
3694                fast/text/international/bdi-dir-default-to-auto.html
3695
3696         * GNUmakefile.list.am:
3697         * Target.pri:
3698         * WebCore.gypi:
3699         * WebCore.vcproj/WebCore.vcproj:
3700         * WebCore.xcodeproj/project.pbxproj:
3701         * css/CSSStyleSelector.cpp:
3702         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3703         * html/HTMLBDIElement.h: Added.
3704         (WebCore):
3705         (HTMLBDIElement):
3706         (WebCore::HTMLBDIElement::create):
3707         (WebCore::HTMLBDIElement::HTMLBDIElement): Sets selfOrAncestorHasDirAutoAttribute to true because
3708         bdi elements are treated as if it has dir=auto by default.
3709         * html/HTMLElement.cpp:
3710         (WebCore::elementAffectsDirectionality): Added. Checks if the specified element is bdi or
3711         has dir content attribute.
3712         (WebCore):
3713         (WebCore::setHasDirAutoFlagRecursively):
3714         (WebCore::HTMLElement::hasDirectionAuto): Added. Checks if the specified element should be treated
3715         as if it has dir=auto (bdi or element with dir=auto).
3716         (WebCore::HTMLElement::directionalityIfhasDirAutoAttribute):
3717         (WebCore::HTMLElement::adjustDirectionalityIfNeededAfterChildAttributeChanged):
3718         (WebCore::HTMLElement::adjustDirectionalityIfNeededAfterChildrenChanged):
3719         * html/HTMLElement.h:
3720         (HTMLElement):
3721         * html/HTMLTagNames.in: Use HTMLBDIElement instead of HTMLElement for constructing bdi element
3722         to set selfOrAncestorHasDirAutoAttribute true but still use HTMLElement for binding.
3723
3724 2012-03-21  Luke Macpherson  <macpherson@chromium.org>
3725
3726         Use CSSPrimitiveValue::convertToLength() in a few places.
3727         https://bugs.webkit.org/show_bug.cgi?id=81492
3728
3729         Reviewed by Eric Seidel.
3730
3731         No new tests - refactoring only.
3732
3733         CSSPrimitiveValue::convertToLength() provides the same functionality that is duplicated
3734         in many places in CSSStyleSelector. This patch removes some of that code duplication.
3735
3736         * css/CSSStyleApplyProperty.cpp:
3737         (WebCore::ApplyPropertyVerticalAlign::applyValue):
3738         * css/CSSStyleSelector.cpp:
3739         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3740
3741 2012-03-21  Patrick Gansterer  <paroga@webkit.org>
3742
3743         Build fix for ENABLE(SVG) && !ENABLE(FILTERS) after r111601.
3744
3745         * rendering/svg/RenderSVGRoot.cpp:
3746
3747 2012-03-21  Patrick Gansterer  <paroga@webkit.org>
3748
3749         Build fix for !ENABLE(INSPECTOR) after r104831.
3750
3751         * bindings/js/ScriptDebugServer.cpp:
3752         (WebCore::ScriptDebugServer::dispatchDidParseSource):
3753
3754 2012-03-21  Xiaomei Ji  <xji@chromium.org>
3755
3756         visual word movement: using cache to decrease the number of collectLeafBoxesInLogicalOrder on RootInlineBox
3757         https://bugs.webkit.org/show_bug.cgi?id=81408
3758
3759         Reviewed by Ryosuke Niwa.
3760
3761         Cache logically ordered leaf boxes under a particular root box.
3762         Also, move 'Vector<UChar, 1024> string' declared in visualWordPosition() to outside of loop (it is always
3763         clear-ed before use).
3764
3765         * editing/visible_units.cpp:
3766         (CachedLogicallyOrderedLeafBoxes): Add class to cache logically ordered leaf boxes under a particular root box.
3767         (WebCore::CachedLogicallyOrderedLeafBoxes::size):
3768         (WebCore::CachedLogicallyOrderedLeafBoxes::firstBox):
3769         (WebCore):
3770         (WebCore::CachedLogicallyOrderedLeafBoxes::CachedLogicallyOrderedLeafBoxes):
3771         (WebCore::CachedLogicallyOrderedLeafBoxes::previousTextBox):
3772         (WebCore::CachedLogicallyOrderedLeafBoxes::nextTextBox):
3773         (WebCore::CachedLogicallyOrderedLeafBoxes::collectBoxes):
3774         (WebCore::CachedLogicallyOrderedLeafBoxes::boxIndexInLeaves):
3775         (WebCore::logicallyPreviousBox): Pass CachedLogicallyOrderedLeafBoxes object around.
3776         (WebCore::logicallyNextBox):
3777         (WebCore::wordBreakIteratorForMinOffsetBoundary):
3778         (WebCore::wordBreakIteratorForMaxOffsetBoundary):
3779         (WebCore::visualWordPosition):
3780
3781 2012-03-21  Dana Jansens  <danakj@chromium.org>
3782
3783         [chromium] Early out in a new prepareToDraw() step if checkerboarding an accelerated animation in order to skip the frame
3784         https://bugs.webkit.org/show_bug.cgi?id=81437
3785
3786         Reviewed by Adrienne Walker.
3787
3788         Split CCLayerTreeHostImpl::drawLayers() into two phases:
3789         prepareToDraw() and drawLayers().
3790
3791         When calculating a RenderPass, and we checkerboard a quad on a
3792         layer, bubble this info back up to CCLayerTreeHostImpl. If the
3793         layer is transforming in an animation, then abort the prepareToDraw()
3794         phase and cause it to return false back to the thread proxy.
3795
3796         Unit test: CCLayerTreeHostImplTest.prepareToDrawFailsWhenAnimationUsesCheckerboard
3797
3798         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
3799         (WebCore::CCLayerImpl::appendQuads):
3800         * platform/graphics/chromium/cc/CCLayerImpl.h:
3801         (CCLayerImpl):
3802         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3803         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
3804         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
3805         (WebCore):
3806         (WebCore::CCLayerTreeHostImpl::drawLayers):
3807         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3808         (CCLayerTreeHostImpl):
3809         (FrameData):
3810         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
3811         (WebCore::CCQuadCuller::append):
3812         * platform/graphics/chromium/cc/CCQuadCuller.h:
3813         (CCQuadCuller):
3814         * platform/graphics/chromium/cc/CCRenderPass.cpp:
3815         (WebCore::CCRenderPass::appendQuadsForLayer):
3816         * platform/graphics/chromium/cc/CCRenderPass.h:
3817         (CCRenderPass):
3818         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
3819         (WebCore::CCScrollbarLayerImpl::appendQuads):
3820         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
3821         (CCScrollbarLayerImpl):
3822         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
3823         (WebCore::CCSingleThreadProxy::doComposite):
3824         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp:
3825         (WebCore::CCSolidColorLayerImpl::appendQuads):
3826         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h:
3827         (CCSolidColorLayerImpl):
3828         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
3829         (WebCore::CCTextureLayerImpl::appendQuads):
3830         * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
3831         (CCTextureLayerImpl):
3832         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3833         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
3834         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
3835         (WebCore::CCTiledLayerImpl::appendQuads):
3836         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
3837         (CCTiledLayerImpl):
3838         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
3839         (WebCore::CCVideoLayerImpl::appendQuads):
3840         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
3841         (CCVideoLayerImpl):
3842
3843 2012-03-21  Enrica Casucci  <enrica@apple.com>
3844
3845         WebKitURLWithTitles pasteboard format should support URLs containing Emoji characters.
3846         https://bugs.webkit.org/show_bug.cgi?id=81835
3847         <rdar://problem/11082749>
3848
3849         Reviewed by Brady Eidson.
3850
3851         When writing the URL in the pasteboard for the WebURLWithTitles format,
3852         we use the user visible string instead of the original URL.
3853         In case of URL with Unicode characters, we lose the encoding.
3854         
3855         Added TestWebKitAPI test.
3856
3857         * platform/mac/PasteboardMac.mm:
3858         (WebCore::writeURLForTypes): Writes to the pasteboard the original URL.
3859
3860 2012-03-21  Levi Weintraub  <leviw@chromium.org>
3861
3862         Correct LayoutUnit usage in VisiblePosition.cpp
3863         https://bugs.webkit.org/show_bug.cgi?id=81775
3864
3865         Reviewed by Eric Seidel.
3866
3867         Correcting a mismatch between the .h and .cpp for the definition of localCaretRect,
3868         and properly using LayoutUnits for local coordinates.
3869
3870         No new tests. No change in behavior.
3871
3872         * editing/VisiblePosition.cpp:
3873         (WebCore::VisiblePosition::localCaretRect): Switching to return a LayoutRect, as in the
3874         header. Local coordinates are in LayoutUnits.
3875         (WebCore::VisiblePosition::absoluteCaretBounds): Using LayoutRect for the localCaretRect.
3876         (WebCore::VisiblePosition::lineDirectionPointForBlockDirectionNavigation): Ditto.
3877
3878 2012-03-21  Adam Klein  <adamk@chromium.org>
3879
3880         "this" argument for MutationCallbacks should be the MutationObserver
3881         https://bugs.webkit.org/show_bug.cgi?id=81712
3882
3883         Reviewed by Adam Barth.
3884
3885         Test: fast/mutation/callback-arguments.html
3886
3887         * bindings/js/JSCallbackData.cpp:
3888         (WebCore::JSCallbackData::invokeCallback): Add an overload that takes
3889         an explicit this argument and have the old method call the new one.
3890         * bindings/js/JSCallbackData.h:
3891         (JSCallbackData):
3892         * bindings/js/JSMutationCallbackCustom.cpp:
3893         (WebCore::JSMutationCallback::handleEvent): Call the new overload.
3894         * bindings/v8/custom/V8CustomVoidCallback.cpp:
3895         (WebCore::invokeCallback): Add an overload that takes an explicit this
3896         argument and have the old method call the new one.
3897         * bindings/v8/custom/V8CustomVoidCallback.h:
3898         (WebCore):
3899         * bindings/v8/custom/V8MutationCallbackCustom.cpp:
3900         (WebCore::V8MutationCallback::handleEvent): Call the new overload.
3901
3902 2012-03-21  Alexandru Chiculita  <achicu@adobe.com>
3903
3904         [CSS Shaders] Make CSS Shaders compile on Chromium
3905         https://bugs.webkit.org/show_bug.cgi?id=81435
3906
3907         Reviewed by Stephen White.
3908
3909         This patch enables the CSS Shaders compile time flag, but keeps the runtime flag disabled.
3910         The only way to test the functionality now is to use the overridePreference from dump render tree.
3911
3912         Also part of this patch I fix a layering violation: I removed the "Document" reference from the FECustomFilter.cpp and passed the
3913         HostWindow directly. There should be no problem when the HostWindow changes, because the RenderLayer and the FECustomFilter
3914         get recreated anyway.
3915
3916         No new tests. I've updated the existing custom filter tests to run under Chromium and added the expected results.
3917         I've just added window.layoutTestController.overridePreference("WebKitCSSCustomFilterEnabled", "1") to force 
3918         enable the feature at runtime. 
3919
3920         * loader/cache/CachedResource.cpp: Made CachedResource::ShaderResource report as ResourceRequest::TargetIsSubresource for Chromium.
3921         (WebCore::cachedResourceTypeToTargetType):
3922
3923         * platform/graphics/filters/FECustomFilter.cpp:
3924         (WebCore::FECustomFilter::FECustomFilter): Removed Document and just used the HostWindow directly.
3925         (WebCore::FECustomFilter::create):
3926         (WebCore::FECustomFilter::initializeContext):
3927         (WebCore::FECustomFilter::bindVertexAttribute): There was a typo and instead of using the "size" parameter it always used 4 component attribute.
3928         Other drivers didn't complain about it, but it was clearly a bug.
3929         (WebCore::FECustomFilter::bindProgramAndBuffers): Reading the image back from GPU will flip vertically the framebuffer in Chromium. I've flipped the
3930         projection matrix only on Chromium, so that we get the correct result.
3931
3932         * rendering/FilterEffectRenderer.cpp:
3933         (WebCore::FilterEffectRenderer::build): Passing the HostWindow instead of the Document.
3934
3935 2012-03-21  Mark Pilgrim  <pilgrim@chromium.org>
3936
3937         Realphabetize about webaudio move
3938         https://bugs.webkit.org/show_bug.cgi?id=81825
3939
3940         Reviewed by Adam Barth.
3941
3942         No new tests, all existing tests pass.
3943
3944         * CMakeLists.txt:
3945
3946 2012-03-21  Anders Carlsson  <andersca@apple.com>
3947
3948         Evict tiles from pages in background tabs
3949         https://bugs.webkit.org/show_bug.cgi?id=81829
3950         <rdar://problem/10866152>
3951
3952         Reviewed by Andreas Kling.
3953
3954         When the tile cache for a page is no longer in a window (which happens when it's moved to 
3955         a background tab), schedule a tile revalidation after 4 seconds. This tile revalidation 
3956         will ensure that tiles outside of the visible rect will be dropped.
3957
3958         * platform/graphics/ca/mac/TileCache.h:
3959         (TileCache):
3960         * platform/graphics/ca/mac/TileCache.mm:
3961         (WebCore::TileCache::tileCacheLayerBoundsChanged):
3962         (WebCore::TileCache::setIsInWindow):
3963         (WebCore::TileCache::tileCoverageRect):
3964         (WebCore):
3965         (WebCore::TileCache::scheduleTileRevalidation):
3966         (WebCore::TileCache::revalidateTiles):
3967
3968 2012-03-21  Stephen Chenney  <schenney@chromium.org>
3969
3970         SVG layout leaves objects still needing layout
3971         https://bugs.webkit.org/show_bug.cgi?id=81006
3972
3973         Reviewed by Nikolas Zimmermann.
3974
3975         Change the layout of SVG objects such that resources that trigger
3976         layout of other objects are handled in a distinct pass, and then
3977         objects still requiring layout are laid out again.
3978
3979         Test: svg/custom/delete-text-innerText-crash.html
3980
3981         * rendering/svg/RenderSVGResourceContainer.cpp:
3982         (WebCore::RenderSVGResourceContainer::layout):
3983         * rendering/svg/RenderSVGResourceMarker.cpp:
3984         (WebCore::RenderSVGResourceMarker::layout):
3985         * rendering/svg/RenderSVGRoot.cpp:
3986         (WebCore::RenderSVGRoot::layout):
3987         (WebCore::RenderSVGRoot::addResourceForClientInvalidation):
3988         (WebCore):
3989         * rendering/svg/RenderSVGRoot.h:
3990         (RenderSVGRoot):
3991
3992 2012-03-21  Tim Horton  <timothy_horton@apple.com>
3993
3994         Make use of CG rounded-rect primitives
3995         https://bugs.webkit.org/show_bug.cgi?id=79932
3996         <rdar://problem/9274953>
3997
3998         Reviewed by Simon Fraser.
3999
4000         Portions of patch by Nikolas Zimmermann and Mustafizur Rahaman.
4001
4002         Dispatch to potentially platform-specific rounded rectangle path
4003         construction from addPathForRoundedRect. Make use of this to call
4004         wkCGPathAddRoundedRect on Lion and above, as long as the rounded
4005         corners are all equivalent.
4006
4007         The origin of the stroke dash differs between the bezier approach
4008         and the path added by wkCGPathAddRoundedRect, so Path::addRoundedRect()
4009         takes a new parameter allowing code which is sensitive to stroke dash
4010         origin (i.e. SVG) to fall back to the old behavior if need be.
4011
4012         Make use of the new Path::addRoundedRect() parameter to fall back to
4013         the old (bezier) rounded-rect behavior when constructing a dashed SVG path,
4014         in order to continue complying with the spec.
4015
4016         No new tests, as this is covered by many that use rounded corners,
4017         and is only a performance improvement.
4018
4019         * WebCore.exp.in:
4020         * platform/graphics/Path.cpp:
4021         (WebCore::Path::addRoundedRect):
4022         (WebCore):
4023         (WebCore::Path::addPathForRoundedRect):
4024         * platform/graphics/Path.h:
4025         (Path):
4026         * platform/graphics/cg/PathCG.cpp:
4027         (WebCore::Path::platformAddPathForRoundedRect):
4028         (WebCore):
4029         * platform/mac/WebCoreSystemInterface.h:
4030         * platform/mac/WebCoreSystemInterface.mm:
4031         * rendering/svg/SVGPathData.cpp:
4032         (WebCore::updatePathFromRectElement):
4033
4034 2012-03-21  David Reveman  <reveman@chromium.org>
4035
4036         [Chromium] GL_EXT_occlusion_query_boolean and GL_CHROMIUM_command_buffer_query support.
4037         https://bugs.webkit.org/show_bug.cgi?id=80988
4038
4039         Reviewed by Adrienne Walker.
4040
4041         Expose EXT_occlusion_query API to WebKit compositor. Add
4042         GL_EXT_occlusion_query_boolean and GL_CHROMIUM_command_buffer_query
4043         enums.
4044
4045         * platform/graphics/chromium/Extensions3DChromium.h:
4046         (Extensions3DChromium):
4047
4048 2012-03-21  Tony Chang  <tony@chromium.org>
4049
4050         compute the sign of flexibility for new flexbox
4051         https://bugs.webkit.org/show_bug.cgi?id=81722