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