95150914e77bb62f04938569aee771fa85d437d8
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-05-23  Kentaro Hara  <haraken@chromium.org>
2
3         Unreviewed, rolling out r118120.
4         http://trac.webkit.org/changeset/118120
5         https://bugs.webkit.org/show_bug.cgi?id=87193
6
7         some LayoutTests crash since the patch passes a NULL to
8         Null(isolate)
9
10         * bindings/scripts/CodeGeneratorV8.pm:
11         (GenerateHeader):
12         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
13         (WebCore::toV8):
14         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
15         (WebCore::toV8):
16         * bindings/scripts/test/V8/V8TestEventConstructor.h:
17         (WebCore::toV8):
18         * bindings/scripts/test/V8/V8TestEventTarget.h:
19         (WebCore::toV8):
20         * bindings/scripts/test/V8/V8TestException.h:
21         (WebCore::toV8):
22         * bindings/scripts/test/V8/V8TestInterface.h:
23         (WebCore::toV8):
24         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
25         (WebCore::toV8):
26         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
27         (WebCore::toV8):
28         * bindings/scripts/test/V8/V8TestNode.h:
29         (WebCore::toV8):
30         * bindings/scripts/test/V8/V8TestObj.h:
31         (WebCore::toV8):
32         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
33         (WebCore::toV8):
34
35 2012-05-23  Kentaro Hara  <haraken@chromium.org>
36
37         Unreviewed, rolling out r118129.
38         http://trac.webkit.org/changeset/118129
39         https://bugs.webkit.org/show_bug.cgi?id=87202
40
41         some LayoutTests crash since the patch passes a NULL to
42         Null(isolate)
43
44         * bindings/scripts/CodeGeneratorV8.pm:
45         (GenerateNormalAttrGetter):
46         (GenerateFunctionCallback):
47         (NativeToJSValue):
48         * bindings/scripts/test/V8/V8TestObj.cpp:
49         (WebCore::TestObjV8Internal::contentDocumentAttrGetter):
50         (WebCore::TestObjV8Internal::getSVGDocumentCallback):
51         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
52         (WebCore::TestSerializedScriptValueInterfaceV8Internal::valueAttrGetter):
53         (WebCore::TestSerializedScriptValueInterfaceV8Internal::readonlyValueAttrGetter):
54         (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedValueAttrGetter):
55         (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedReadonlyValueAttrGetter):
56
57 2012-05-23  Kentaro Hara  <haraken@chromium.org>
58
59         Unreviewed, rolling out r118133.
60         http://trac.webkit.org/changeset/118133
61         https://bugs.webkit.org/show_bug.cgi?id=87207
62
63         some LayoutTests crash since the patch passes a NULL to
64         Null(isolate)
65
66         * bindings/v8/custom/V8BlobCustom.cpp:
67         (WebCore::toV8):
68         * bindings/v8/custom/V8CSSRuleCustom.cpp:
69         (WebCore::toV8):
70         * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
71         (WebCore::toV8):
72         * bindings/v8/custom/V8CSSValueCustom.cpp:
73         (WebCore::toV8):
74         * bindings/v8/custom/V8ClipboardCustom.cpp:
75         (WebCore::V8Clipboard::typesAccessorGetter):
76         * bindings/v8/custom/V8CoordinatesCustom.cpp:
77         (WebCore::V8Coordinates::altitudeAccessorGetter):
78         (WebCore::V8Coordinates::altitudeAccuracyAccessorGetter):
79         (WebCore::V8Coordinates::headingAccessorGetter):
80         (WebCore::V8Coordinates::speedAccessorGetter):
81         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
82         (WebCore::toV8):
83         * bindings/v8/custom/V8DOMTokenListCustom.cpp:
84         (WebCore::toV8):
85         * bindings/v8/custom/V8DOMWindowCustom.cpp:
86         (WebCore::toV8):
87         * bindings/v8/custom/V8DataViewCustom.cpp:
88         (WebCore::toV8):
89         * bindings/v8/custom/V8DeviceMotionEventCustom.cpp:
90         (WebCore::V8DeviceMotionEvent::accelerationAccessorGetter):
91         (WebCore::V8DeviceMotionEvent::accelerationIncludingGravityAccessorGetter):
92         (WebCore::V8DeviceMotionEvent::rotationRateAccessorGetter):
93         (WebCore::V8DeviceMotionEvent::intervalAccessorGetter):
94         * bindings/v8/custom/V8DeviceOrientationEventCustom.cpp:
95         (WebCore::V8DeviceOrientationEvent::alphaAccessorGetter):
96         (WebCore::V8DeviceOrientationEvent::betaAccessorGetter):
97         (WebCore::V8DeviceOrientationEvent::gammaAccessorGetter):
98         (WebCore::V8DeviceOrientationEvent::absoluteAccessorGetter):
99         * bindings/v8/custom/V8DocumentCustom.cpp:
100         (WebCore::toV8):
101         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
102         (WebCore::V8Document::locationAccessorGetter):
103         * bindings/v8/custom/V8EntryCustom.cpp:
104         (WebCore::toV8):
105         * bindings/v8/custom/V8EntrySyncCustom.cpp:
106         (WebCore::toV8):
107         * bindings/v8/custom/V8EventCustom.cpp:
108         (WebCore::toV8):
109         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
110         (WebCore::toV8):
111         * bindings/v8/custom/V8Float64ArrayCustom.cpp:
112         (WebCore::toV8):
113         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
114         (WebCore::V8HTMLCanvasElement::getContextCallback):
115         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
116         (WebCore::toV8):
117
118 2012-05-23  Kentaro Hara  <haraken@chromium.org>
119
120         Unreviewed, rolling out r118134.
121         http://trac.webkit.org/changeset/118134
122         https://bugs.webkit.org/show_bug.cgi?id=87209
123
124         some LayoutTests crash since the patch passes a NULL to
125         Null(isolate)
126
127         * bindings/v8/custom/V8HTMLElementCustom.cpp:
128         (WebCore::toV8Object):
129         (WebCore::toV8):
130         * bindings/v8/custom/V8HistoryCustom.cpp:
131         (WebCore::V8History::stateAccessorGetter):
132         * bindings/v8/custom/V8IDBAnyCustom.cpp:
133         (WebCore::toV8):
134         * bindings/v8/custom/V8IDBKeyCustom.cpp:
135         (WebCore::toV8):
136         * bindings/v8/custom/V8ImageDataCustom.cpp:
137         (WebCore::toV8):
138         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
139         (WebCore::toV8):
140         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
141         (WebCore::toV8):
142         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
143         (WebCore::toV8):
144         * bindings/v8/custom/V8LocationCustom.cpp:
145         (WebCore::toV8):
146         * bindings/v8/custom/V8MessageEventCustom.cpp:
147         (WebCore::V8MessageEvent::dataAccessorGetter):
148         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
149         (WebCore::toV8):
150         * bindings/v8/custom/V8NodeCustom.cpp:
151         (WebCore::V8Node::insertBeforeCallback):
152         (WebCore::V8Node::replaceChildCallback):
153         (WebCore::V8Node::removeChildCallback):
154         (WebCore::V8Node::appendChildCallback):
155         (WebCore::toV8Slow):
156         * bindings/v8/custom/V8PopStateEventCustom.cpp:
157         (WebCore::V8PopStateEvent::stateAccessorGetter):
158         * bindings/v8/custom/V8SQLResultSetRowListCustom.cpp:
159         (WebCore::V8SQLResultSetRowList::itemCallback):
160         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
161         (WebCore::toV8):
162         * bindings/v8/custom/V8SVGElementCustom.cpp:
163         (WebCore::toV8):
164         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
165         (WebCore::toV8):
166         * bindings/v8/custom/V8ScriptProfileCustom.cpp:
167         (WebCore::toV8):
168         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp:
169         (WebCore::toV8):
170         * bindings/v8/custom/V8StyleSheetCustom.cpp:
171         (WebCore::toV8):
172         * bindings/v8/custom/V8TrackEventCustom.cpp:
173         (WebCore::V8TrackEvent::trackAccessorGetter):
174         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
175         (WebCore::toV8):
176         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
177         (WebCore::toV8):
178         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
179         (WebCore::toV8):
180         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp:
181         (WebCore::toV8):
182         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
183         (WebCore::toV8Object):
184         (WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
185         (WebCore::V8WebGLRenderingContext::getSupportedExtensionsCallback):
186         * bindings/v8/custom/V8WorkerContextCustom.cpp:
187         (WebCore::toV8):
188
189 2012-05-23  James Robinson  <jamesr@chromium.org>
190
191         Add a Setting to make position:fixed form a new stacking context
192         https://bugs.webkit.org/show_bug.cgi?id=87186
193
194         Reviewed by Adam Barth.
195
196         position:fixed elements form a new stacking context in several mobile WebKit ports and in the Qt port always. To
197         be consistent across devices, we want to try turning it on everywhere. This will likely cause compatibility
198         issues, so we need a runtime setting in order to stage the change carefully.
199
200         Tests: fast/block/positioning/fixed-position-stacking-context.html
201                fast/block/positioning/fixed-position-stacking-context2.html
202
203         * css/StyleResolver.cpp:
204         (WebCore::StyleResolver::collectMatchingRulesForList):
205         * page/Settings.cpp:
206         (WebCore::Settings::Settings):
207         * page/Settings.h:
208         (WebCore::Settings::setFixedPositionCreatesStackingContext):
209         (WebCore::Settings::fixedPositionCreatesStackingContext):
210         (Settings):
211         * testing/InternalSettings.cpp:
212         (WebCore::InternalSettings::InternalSettings):
213         (WebCore::InternalSettings::restoreTo):
214         (WebCore::InternalSettings::setFixedPositionCreatesStackingContext):
215         (WebCore):
216         * testing/InternalSettings.h:
217         (InternalSettings):
218         * testing/InternalSettings.idl:
219
220 2012-05-23  Michael Nordman  <michaeln@google.com>
221
222         [chromium] DomStorage events handling needs TLC (3)
223         https://bugs.webkit.org/show_bug.cgi?id=87031
224         https://code.google.com/p/chromium/issues/detail?id=128482
225         Create WebCore::Storage instances as a side effect of attaching storage event handlers.
226         This allows storage events in chromium to be propagated with less IPC chatter.
227
228         Worth noting that in non-chromium ports, creation of the localStorage instance can have
229         an additional side effect of scheduling a background task to read the area's values
230         from disk, which given the interest in events is probably a beneficial side effect.
231
232         Reviewed by Adam Barth.
233
234         No new tests. Existing tests cover this.
235
236         * page/DOMWindow.cpp:
237         (WebCore::didAddStorageEventListener):
238         (WebCore::DOMWindow::addEventListener):
239
240 2012-05-23  Michael Saboff  <msaboff@apple.com>
241
242         Crash in fast/files/read tests during Garbage Collection
243         https://bugs.webkit.org/show_bug.cgi?id=87165
244
245         Reviewed by Alexey Proskuryakov.
246
247         Changed hasPendingActivity() processing to use ActiveDOMObject::hasPendingActivity()
248         and associated setPendingActivity() / unsetPendingActivity().
249
250         Fixed two existing tests with change.
251
252         * Modules/filesystem/FileWriter.cpp:
253         (WebCore::FileWriter::stop):
254         (WebCore::FileWriter::write):
255         (WebCore::FileWriter::truncate):
256         (WebCore::FileWriter::signalCompletion):
257         * Modules/filesystem/FileWriter.h:
258         * fileapi/FileReader.cpp:
259         (WebCore::FileReader::readInternal):
260         (WebCore::FileReader::doAbort):
261         (WebCore::FileReader::didFinishLoading):
262         (WebCore::FileReader::didFail):
263         * fileapi/FileReader.h:
264
265 2012-05-23  Abhishek Arya  <inferno@chromium.org>
266
267         Crash in run-ins with continuations while moving back to original position.
268         https://bugs.webkit.org/show_bug.cgi?id=87264
269
270         Reviewed by Julien Chaffraix.
271
272         Run-in that are now placed in sibling block can break up into continuation
273         chains when new children are added to it. We cannot easily send them back to their
274         original place since that requires writing integration logic with RenderInline::addChild
275         and all other places that might cause continuations to be created (without blowing away
276         |this|). Disabling this feature for now to prevent crashes.
277
278         Test: fast/runin/runin-continuations-crash.html
279
280         * rendering/RenderBlock.cpp:
281         (WebCore::RenderBlock::moveRunInToOriginalPosition):
282
283 2012-05-23  Abhishek Arya  <inferno@chromium.org>
284
285         Crash in RenderInline::linesVisualOverflowBoundingBox.
286         https://bugs.webkit.org/show_bug.cgi?id=85804
287
288         Reviewed by Dave Hyatt.
289
290         Defer layout of replaced elements to the next line break function.
291         We shouldn't do it while we are clearing our inline chilren
292         lineboxes in full layout mode.
293
294         Test: fast/block/inline-children-root-linebox-crash.html
295
296         * rendering/RenderBlockLineLayout.cpp:
297         (WebCore::RenderBlock::layoutInlineChildren):
298         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
299
300 2012-05-23  Chris Rogers  <crogers@google.com>
301
302         AudioParam must support fan-in (multiple audio connections) (take 2)
303         https://bugs.webkit.org/show_bug.cgi?id=83610
304
305         Reviewed by Kenneth Russell.
306         
307         This re-lands bug: https://bugs.webkit.org/show_bug.cgi?id=83610
308         Now that a fix has been landed: http://trac.webkit.org/changeset/118099
309
310         Test: webaudio/audioparam-summingjunction.html
311
312         * Modules/webaudio/AudioParam.cpp:
313         * Modules/webaudio/AudioParam.h:
314         (WebCore::AudioParam::calculateSampleAccurateValues):
315         (WebCore::AudioParam::calculateAudioRateSignalValues):
316         Sums intrinsic parameter value with all audio-rate connections.
317         
318         (WebCore::AudioParam::connect):
319         (WebCore::AudioParam::disconnect):
320         Support multiple connections.
321         
322         (WebCore::AudioParam::hasSampleAccurateValues):
323         If we have one or more audio-rate connections.
324         
325         (WebCore::AudioParam::AudioParam):
326         AudioParam now sub-classes AudioSummingJunction.
327
328 2012-05-23  Christophe Dumez  <christophe.dumez@intel.com>
329
330         [EFL] webintents/web-intents-delivery-reuse.html is failing on EFL port
331         https://bugs.webkit.org/show_bug.cgi?id=87092
332
333         Reviewed by Adam Barth.
334
335         Remove readonly keyword from the webkitIntent attribute. This is
336         needed otherwise the [Replaceable] extended attribute has not effect
337         with JSC. This is tested by webintents/web-intents-delivery-reuse.html
338         test case.
339
340         * Modules/intents/DOMWindowIntents.idl:
341
342 2012-05-23  Abhishek Arya  <inferno@chromium.org>
343
344         ASSERT failure toRenderProgress in HTMLProgressElement::didElementStateChange
345         https://bugs.webkit.org/show_bug.cgi?id=87274
346
347         Reviewed by Darin Adler.
348
349         Progress bar can't run-in. Prevent it from becoming a run-in, leading to an
350         unworkable RenderInline.
351
352         Test: fast/runin/progress-run-in-crash.html
353
354         * html/HTMLProgressElement.cpp:
355         (WebCore::HTMLProgressElement::didElementStateChange):
356         * rendering/RenderBlock.cpp:
357         (WebCore::RenderBlock::moveRunInUnderSiblingBlockIfNeeded):
358
359 2012-05-23  Andrew Lo  <anlo@rim.com>
360
361         [BlackBerry] UI thread unnecessarily blocks on WebKit thread when servicing requestAnimationFrames
362         https://bugs.webkit.org/show_bug.cgi?id=87289
363
364         Reviewed by Antonio Gomes.
365
366         requestAnimationFrame already covered by tests in LayoutTests/fast/animation.
367
368         If UI thread cannot acquire DisplayRefreshMonitor mutex immediately,
369         avoid blocking on the mutex, it can trigger the frame change on the next
370         animation tick instead.
371
372         * platform/graphics/blackberry/DisplayRefreshMonitorBlackBerry.cpp:
373         (WebCore::DisplayRefreshMonitor::displayLinkFired):
374
375 2012-05-23  Alec Flett  <alecflett@chromium.org>
376
377         Implement DOM4 DOMError
378         https://bugs.webkit.org/show_bug.cgi?id=87055
379
380         Reviewed by Adam Barth.
381
382         Implement the DOMError class and it's IDL interface.
383
384         No new tests. Not testable yet, as it's not used.
385
386         * WebCore.gypi:
387         * dom/DOMError.cpp: Added.
388         (WebCore):
389         (WebCore::DOMError::DOMError):
390         * dom/DOMError.h: Added.
391         (WebCore):
392         (DOMError):
393         (WebCore::DOMError::create):
394         (WebCore::DOMError::name):
395         * dom/DOMError.idl: Added.
396
397 2012-05-23  Kenneth Russell  <kbr@google.com>
398
399         REGRESSION(117918) - 4 webgl/tex-iomage-and-sub-image-2d-with-image tests failing on Mac bots.
400         https://bugs.webkit.org/show_bug.cgi?id=87136
401
402         Reviewed by Stephen White.
403
404         Fixed longstanding bug in GraphicsContext3D constructor in Mac
405         port, and logic error in tracking of texture bound to unit 0. Also
406         fixed up Cairo port's constructor by code inspection. This code is
407         ripe for cleanup; Bug 87198 filed for this.
408
409         Covered by existing tests.
410
411         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
412         (WebCore::GraphicsContext3D::GraphicsContext3D):
413             Initialize missing members.
414         * platform/graphics/mac/GraphicsContext3DMac.mm:
415         (WebCore::GraphicsContext3D::GraphicsContext3D):
416             Correctly initialize m_activeTexture.
417         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
418         (WebCore::GraphicsContext3D::bindTexture):
419             Fix logic error in tracking of texture bound to unit 0.
420
421 2012-05-23  Dana Jansens  <danakj@chromium.org>
422
423         [chromium] Layers on main thread should get a RenderSurface for animating transform only if masksToBounds is true also
424         https://bugs.webkit.org/show_bug.cgi?id=87184
425
426         Reviewed by James Robinson.
427
428         Layers on main thread get a RenderSurface if their impl counterpart may
429         have a RenderSurface due to its animating transform. We currently create
430         a RenderSurface for all layers with an animating transform and
431         a descendant that drawsContents. But a RenderSurface on impl also
432         implies that the layer masksToBounds. So only make a RenderSurface on
433         main thread when the layer also masksToBounds.
434
435         Modified unit test CCLayerTreeHostCommonTest.verifyAnimationsForRenderSurfaceHierarchy.
436
437         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
438         (WebCore::subtreeShouldRenderToSeparateSurface):
439
440 2012-05-23  Chris Fleizach  <cfleizach@apple.com>
441
442         Regression(r112694): Crash in WebCore::AXObjectCache::postNotification 
443         https://bugs.webkit.org/show_bug.cgi?id=86029
444
445         Reviewed by Abhishek Arya.
446
447         Test: accessibility/content-changed-notification-causes-crash.html
448
449         * accessibility/AccessibilityObject.h:
450         (WebCore::AccessibilityObject::isDetached):
451         (AccessibilityObject):
452         * accessibility/AccessibilityRenderObject.cpp:
453         (WebCore::AccessibilityRenderObject::contentChanged):
454
455 2012-05-23  Robin Dunn  <robin@alldunn.com>
456
457         [wx] Fix memory leak in FontHolder.
458         https://bugs.webkit.org/show_bug.cgi?id=87281
459
460         Reviewed by Kevin Ollivier.
461
462         * platform/graphics/wx/FontPlatformData.h:
463
464 2012-05-23  Robin Dunn  <robin@alldunn.com>
465
466         [wx] Make sure we do not create a substitute font if the facename is not found.
467         https://bugs.webkit.org/show_bug.cgi?id=87280
468
469         Reviewed by Kevin Ollivier.
470
471         * platform/graphics/wx/FontCacheWx.cpp:
472         (WebCore::FontCache::createFontPlatformData):
473
474 2012-05-23  Robin Dunn  <robin@alldunn.com>
475
476         [wx] Implement transparency layer support.
477         https://bugs.webkit.org/show_bug.cgi?id=87279
478
479         Reviewed by Kevin Ollivier.
480
481         * platform/graphics/wx/GraphicsContextWx.cpp:
482         (WebCore::GraphicsContext::beginPlatformTransparencyLayer):
483         (WebCore::GraphicsContext::endPlatformTransparencyLayer):
484         (WebCore::GraphicsContext::supportsTransparencyLayers):
485
486 2012-05-23  Jer Noble  <jer.noble@apple.com>
487
488         GenericClock loses precision due to float->double conversion.
489         https://bugs.webkit.org/show_bug.cgi?id=87227
490
491         Reviewed by Darin Adler.
492
493         No new tests; fixes media/media-controller-time.html on Chromium.
494
495         Only narrow to float after the entire calculation is complete. This requires now() and m_offset
496         to be double-precision.
497
498         * platform/ClockGeneric.cpp:
499         (ClockGeneric::currentTime): 
500         (ClockGeneric::now): Make double-precision.
501         * platform/ClockGeneric.h:
502         (ClockGeneric): Make m_offset double-precision.
503
504 2012-05-22  Jer Noble  <jer.noble@apple.com>
505
506         PlatformClockCM has uninitialized m_rate member.
507         https://bugs.webkit.org/show_bug.cgi?id=87217
508
509         Reviewed by Eric Carlson.
510
511         Test: media/media-controller-time.html
512
513         Initialize the m_rate member to a default of 1 (second-per-second), matching the implementation
514         of ClockGeneric.
515
516         * platform/mac/PlatformClockCM.mm:
517         (PlatformClockCM::PlatformClockCM):
518
519 2012-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
520
521         Unreviewed, rolling out r118096.
522         http://trac.webkit.org/changeset/118096
523         https://bugs.webkit.org/show_bug.cgi?id=87285
524
525         caused multiple crashes on the mac bots (Requested by
526         jessieberlin on #webkit).
527
528         * dom/ContainerNodeAlgorithms.h:
529
530 2012-05-23  Darin Adler  <darin@apple.com>
531
532         Speed up traverseNextNode when called on a ContainerNode or Element
533         https://bugs.webkit.org/show_bug.cgi?id=87224
534
535         Reviewed by Geoffrey Garen.
536
537         * dom/ContainerNode.h: Added overrides of traverseNextNode for ContainerNode.
538         That way, when we know at compile time something is ContainerNode, we can
539         skip a branch at the start of this hot function.
540
541 2012-05-23  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
542
543         Use PluginDataNone.cpp always when NETSCAPE_PLUGIN_API is OFF
544         https://bugs.webkit.org/show_bug.cgi?id=87096
545
546         Reviewed by Andy Estes.
547
548         Fix a build error by adding an extra check in PluginData.cpp to use
549         PluginStrategy only when NETSCAPE_PLUGIN_API is ON.
550
551         No new tests. This is only a build fix.
552
553         * plugins/PluginData.cpp:
554         (WebCore):
555
556 2012-05-23  Malcolm MacLeod  <malcolm.macleod@tshwanedje.com>
557
558         [wx] Fix scrollbar drawing under wxGTK.
559         https://bugs.webkit.org/show_bug.cgi?id=87150
560
561         Reviewed by Kevin Ollivier.
562
563         * platform/wx/wxcode/gtk/scrollbar_render.cpp:
564         (wxRenderer_DrawScrollbar):
565
566 2012-05-23  Antti Koivisto  <antti@apple.com>
567
568         Rename StyleSheetInternal to StyleSheetContents
569         https://bugs.webkit.org/show_bug.cgi?id=87272
570
571         Reviewed by Andreas Kling.
572
573         The name is more descriptive and the code reads better.
574         
575         Plain "StyleSheet" would be good too but that is a CSSOM type and the name can't be used without
576         changing idl code generation and resolving bunch of other issues.
577
578         * css/CSSFontFaceSrcValue.cpp:
579         (WebCore::CSSFontFaceSrcValue::addSubresourceStyleURLs):
580         * css/CSSFontFaceSrcValue.h:
581         (CSSFontFaceSrcValue):
582         * css/CSSImportRule.cpp:
583         (WebCore::StyleRuleImport::setCSSStyleSheet):
584         (WebCore::StyleRuleImport::requestStyleSheet):
585         * css/CSSImportRule.h:
586         (WebCore):
587         (WebCore::StyleRuleImport::parentStyleSheet):
588         (WebCore::StyleRuleImport::setParentStyleSheet):
589         (WebCore::StyleRuleImport::styleSheet):
590         (StyleRuleImport):
591         * css/CSSMediaRule.cpp:
592         (WebCore::CSSMediaRule::insertRule):
593         * css/CSSParser.cpp:
594         (WebCore::CSSParser::parseSheet):
595         (WebCore::CSSParser::parseRule):
596         (WebCore::CSSParser::parseKeyframeRule):
597         (WebCore::CSSParser::parseValue):
598         (WebCore::CSSParser::parseSelector):
599         (WebCore::CSSParser::parseDeclaration):
600         (WebCore::CSSParser::setStyleSheet):
601         (WebCore::CSSParser::parseFlowThread):
602         * css/CSSParser.h:
603         (WebCore):
604         (CSSParser):
605         * css/CSSPrimitiveValue.cpp:
606         (WebCore::CSSPrimitiveValue::addSubresourceStyleURLs):
607         * css/CSSPrimitiveValue.h:
608         (CSSPrimitiveValue):
609         * css/CSSReflectValue.cpp:
610         (WebCore::CSSReflectValue::addSubresourceStyleURLs):
611         * css/CSSReflectValue.h:
612         (CSSReflectValue):
613         * css/CSSRule.cpp:
614         (WebCore::CSSRule::parserContext):
615         * css/CSSStyleSheet.cpp:
616         (WebCore::StyleSheetContents::estimatedSizeInBytes):
617         (WebCore::StyleSheetContents::StyleSheetContents):
618         (WebCore::StyleSheetContents::~StyleSheetContents):
619         (WebCore::StyleSheetContents::isCacheable):
620         (WebCore::StyleSheetContents::parserAppendRule):
621         (WebCore::StyleSheetContents::ruleAt):
622         (WebCore::StyleSheetContents::ruleCount):
623         (WebCore::StyleSheetContents::clearCharsetRule):
624         (WebCore::StyleSheetContents::clearRules):
625         (WebCore::StyleSheetContents::parserSetEncodingFromCharsetRule):
626         (WebCore::StyleSheetContents::wrapperInsertRule):
627         (WebCore::StyleSheetContents::wrapperDeleteRule):
628         (WebCore::StyleSheetContents::parserAddNamespace):
629         (WebCore::StyleSheetContents::determineNamespace):
630         (WebCore::StyleSheetContents::parseAuthorStyleSheet):
631         (WebCore::StyleSheetContents::parseString):
632         (WebCore::StyleSheetContents::parseStringAtLine):
633         (WebCore::StyleSheetContents::isLoading):
634         (WebCore::StyleSheetContents::checkLoaded):
635         (WebCore::StyleSheetContents::notifyLoadedSheet):
636         (WebCore::StyleSheetContents::startLoadingDynamicSheet):
637         (WebCore::StyleSheetContents::rootStyleSheet):
638         (WebCore::StyleSheetContents::singleOwnerNode):
639         (WebCore::StyleSheetContents::singleOwnerDocument):
640         (WebCore::StyleSheetContents::completeURL):
641         (WebCore::StyleSheetContents::addSubresourceStyleURLs):
642         (WebCore::StyleSheetContents::parentStyleSheet):
643         (WebCore::StyleSheetContents::registerClient):
644         (WebCore::StyleSheetContents::unregisterClient):
645         (WebCore::StyleSheetContents::addedToMemoryCache):
646         (WebCore::StyleSheetContents::removedFromMemoryCache):
647         (WebCore::CSSStyleSheet::createInline):
648         (WebCore::CSSStyleSheet::CSSStyleSheet):
649         (WebCore::CSSStyleSheet::~CSSStyleSheet):
650         (WebCore::CSSStyleSheet::willMutateRules):
651         (WebCore::CSSStyleSheet::didMutateRules):
652         (WebCore::CSSStyleSheet::reattachChildRuleCSSOMWrappers):
653         (WebCore::CSSStyleSheet::length):
654         (WebCore::CSSStyleSheet::item):
655         (WebCore::CSSStyleSheet::rules):
656         (WebCore::CSSStyleSheet::insertRule):
657         (WebCore::CSSStyleSheet::deleteRule):
658         (WebCore::CSSStyleSheet::cssRules):
659         * css/CSSStyleSheet.h:
660         (WebCore::StyleSheetContents::create):
661         (StyleSheetContents):
662         (WebCore::StyleSheetContents::copy):
663         (WebCore::CSSStyleSheet::create):
664         (WebCore::CSSStyleSheet::contents):
665         (CSSStyleSheet):
666         * css/CSSValue.cpp:
667         (WebCore::CSSValue::addSubresourceStyleURLs):
668         * css/CSSValue.h:
669         (WebCore):
670         (CSSValue):
671         * css/CSSValueList.cpp:
672         (WebCore::CSSValueList::addSubresourceStyleURLs):
673         * css/CSSValueList.h:
674         (CSSValueList):
675         * css/PropertySetCSSStyleDeclaration.cpp:
676         (WebCore::PropertySetCSSStyleDeclaration::contextStyleSheet):
677         * css/PropertySetCSSStyleDeclaration.h:
678         (WebCore):
679         (PropertySetCSSStyleDeclaration):
680         * css/StylePropertySet.cpp:
681         (WebCore::StylePropertySet::setProperty):
682         (WebCore::StylePropertySet::parseDeclaration):
683         (WebCore::StylePropertySet::addSubresourceStyleURLs):
684         * css/StylePropertySet.h:
685         (WebCore):
686         (StylePropertySet):
687         * css/StyleResolver.cpp:
688         (RuleSet):
689         (WebCore):
690         (WebCore::StyleResolver::StyleResolver):
691         (WebCore::StyleResolver::addAuthorRulesAndCollectUserRulesFromSheets):
692         (WebCore::StyleResolver::appendAuthorStylesheets):
693         (WebCore::parseUASheet):
694         (WebCore::StyleResolver::collectMatchingRulesForList):
695         * css/StyleResolver.h:
696         (StyleResolver):
697         * css/WebKitCSSKeyframesRule.cpp:
698         (WebCore::WebKitCSSKeyframesRule::insertRule):
699         * dom/DOMImplementation.cpp:
700         (WebCore::DOMImplementation::createCSSStyleSheet):
701         * dom/Document.cpp:
702         (WebCore::Document::recalcStyle):
703         (WebCore::Document::updateBaseURL):
704         (WebCore::Document::pageUserSheet):
705         (WebCore::Document::pageGroupUserSheets):
706         (WebCore::Document::addUserSheet):
707         (WebCore::Document::testAddedStylesheetRequiresStyleRecalc):
708         (WebCore::Document::analyzeStylesheetChange):
709         (WebCore::styleSheetsUseRemUnits):
710         * dom/Document.h:
711         (WebCore):
712         (Document):
713         * dom/ElementAttributeData.cpp:
714         (WebCore::ElementAttributeData::updateInlineStyleAvoidingMutation):
715         * dom/ProcessingInstruction.cpp:
716         (WebCore::ProcessingInstruction::setCSSStyleSheet):
717         (WebCore::ProcessingInstruction::parseStyleSheet):
718         * dom/StyleElement.cpp:
719         (WebCore::StyleElement::createSheet):
720         * dom/StyledElement.cpp:
721         (WebCore::StyledElement::setInlineStyleProperty):
722         (WebCore::StyledElement::addSubresourceAttributeURLs):
723         (WebCore::StyledElement::addPropertyToAttributeStyle):
724         * html/HTMLLinkElement.cpp:
725         (WebCore::HTMLLinkElement::setCSSStyleSheet):
726         (WebCore::HTMLLinkElement::styleSheetIsLoading):
727         (WebCore::HTMLLinkElement::addSubresourceAttributeURLs):
728         * html/HTMLStyleElement.cpp:
729         (WebCore::HTMLStyleElement::addSubresourceAttributeURLs):
730         * inspector/InspectorStyleSheet.cpp:
731         (WebCore::fillMediaListChain):
732         (WebCore::InspectorStyle::setPropertyText):
733         (WebCore::InspectorStyleSheet::styleSheetURL):
734         (WebCore::InspectorStyleSheet::reparseStyleSheet):
735         (WebCore::InspectorStyleSheet::ensureSourceData):
736         (WebCore::InspectorStyleSheetForInlineStyle::getStyleAttributeRanges):
737         * loader/cache/CachedCSSStyleSheet.cpp:
738         (WebCore::CachedCSSStyleSheet::restoreParsedStyleSheet):
739         (WebCore::CachedCSSStyleSheet::saveParsedStyleSheet):
740         * loader/cache/CachedCSSStyleSheet.h:
741         (WebCore):
742         (CachedCSSStyleSheet):
743         * page/PageSerializer.cpp:
744         (WebCore::PageSerializer::serializeCSSStyleSheet):
745
746 2012-05-23  Darin Adler  <darin@apple.com>
747
748         Use ContainerNode instead of Node where possible
749         https://bugs.webkit.org/show_bug.cgi?id=87220
750
751         Reviewed by Geoffrey Garen.
752
753         It's better to use a more specific type; in some cases we even generate
754         more efficient code if we have a more specific type. Also, we want any
755         type casts to be as close as possible to the corresponding type checks,
756         so eliminating these uses of toContainerNode is a plus, also.
757
758         * dom/ContainerNodeAlgorithms.h: Changed insertionPoint to be a ContainerNode
759         instead of a Node. Fixed spelling error "inseretions". Changed
760         (WebCore::ChildFrameDisconnector::Target::Target): Changed type of frame owner
761         element to HTMLFrameOwnerElement from Node.
762
763         * dom/DocumentType.cpp:
764         (WebCore::DocumentType::insertedInto):
765         (WebCore::DocumentType::removedFrom):
766         * dom/DocumentType.h:
767         * dom/Element.cpp:
768         (WebCore::Element::insertedInto):
769         (WebCore::Element::removedFrom):
770         * dom/Element.h:
771         * dom/Node.cpp:
772         (WebCore::Node::insertedInto):
773         (WebCore::Node::removedFrom):
774         * dom/Node.h:
775         * dom/ProcessingInstruction.cpp:
776         (WebCore::ProcessingInstruction::insertedInto):
777         (WebCore::ProcessingInstruction::removedFrom):
778         * dom/ProcessingInstruction.h:
779         * dom/ScriptElement.cpp:
780         (WebCore::ScriptElement::insertedInto):
781         * dom/ScriptElement.h:
782         * html/FormAssociatedElement.cpp:
783         (WebCore::FormAssociatedElement::insertedInto):
784         (WebCore::FormAssociatedElement::removedFrom):
785         * html/FormAssociatedElement.h:
786         * html/HTMLBaseElement.cpp:
787         (WebCore::HTMLBaseElement::insertedInto):
788         (WebCore::HTMLBaseElement::removedFrom):
789         * html/HTMLBaseElement.h:
790         * html/HTMLBodyElement.cpp:
791         (WebCore::HTMLBodyElement::insertedInto):
792         (WebCore::HTMLBodyElement::didNotifyDescendantInsertions):
793         * html/HTMLBodyElement.h:
794         * html/HTMLFormControlElement.cpp:
795         (WebCore::HTMLFormControlElement::insertedInto):
796         (WebCore::HTMLFormControlElement::removedFrom):
797         * html/HTMLFormControlElement.h:
798         * html/HTMLFormElement.cpp:
799         (WebCore::HTMLFormElement::insertedInto):
800         (WebCore::HTMLFormElement::didNotifyDescendantInsertions):
801         (WebCore::HTMLFormElement::removedFrom):
802         * html/HTMLFormElement.h:
803         * html/HTMLFrameElementBase.cpp:
804         (WebCore::HTMLFrameElementBase::insertedInto):
805         (WebCore::HTMLFrameElementBase::didNotifyDescendantInsertions):
806         * html/HTMLFrameElementBase.h:
807         * html/HTMLFrameSetElement.cpp:
808         (WebCore::HTMLFrameSetElement::insertedInto):
809         (WebCore::HTMLFrameSetElement::removedFrom):
810         * html/HTMLFrameSetElement.h:
811         * html/HTMLIFrameElement.cpp:
812         (WebCore::HTMLIFrameElement::insertedInto):
813         (WebCore::HTMLIFrameElement::removedFrom):
814         * html/HTMLIFrameElement.h:
815         * html/HTMLImageElement.cpp:
816         (WebCore::HTMLImageElement::insertedInto):
817         (WebCore::HTMLImageElement::removedFrom):
818         * html/HTMLImageElement.h:
819         * html/HTMLInputElement.cpp:
820         (WebCore::HTMLInputElement::insertedInto):
821         (WebCore::HTMLInputElement::removedFrom):
822         * html/HTMLInputElement.h:
823         * html/HTMLLinkElement.cpp:
824         (WebCore::HTMLLinkElement::insertedInto):
825         (WebCore::HTMLLinkElement::removedFrom):
826         * html/HTMLLinkElement.h:
827         * html/HTMLMapElement.cpp:
828         (WebCore::HTMLMapElement::insertedInto):
829         (WebCore::HTMLMapElement::removedFrom):
830         * html/HTMLMapElement.h:
831         * html/HTMLMediaElement.cpp:
832         (WebCore::HTMLMediaElement::insertedInto):
833         (WebCore::HTMLMediaElement::removedFrom):
834         * html/HTMLMediaElement.h:
835         * html/HTMLMetaElement.cpp:
836         (WebCore::HTMLMetaElement::insertedInto):
837         * html/HTMLMetaElement.h:
838         * html/HTMLObjectElement.cpp:
839         (WebCore::HTMLObjectElement::insertedInto):
840         (WebCore::HTMLObjectElement::removedFrom):
841         * html/HTMLObjectElement.h:
842         * html/HTMLOptionElement.cpp:
843         (WebCore::HTMLOptionElement::insertedInto):
844         * html/HTMLOptionElement.h:
845         * html/HTMLQuoteElement.cpp:
846         (WebCore::HTMLQuoteElement::insertedInto):
847         * html/HTMLQuoteElement.h:
848         * html/HTMLScriptElement.cpp:
849         (WebCore::HTMLScriptElement::insertedInto):
850         * html/HTMLScriptElement.h:
851         * html/HTMLSelectElement.cpp:
852         (WebCore::HTMLSelectElement::insertedInto):
853         * html/HTMLSelectElement.h:
854         * html/HTMLSourceElement.cpp:
855         (WebCore::HTMLSourceElement::insertedInto):
856         (WebCore::HTMLSourceElement::removedFrom):
857         * html/HTMLSourceElement.h:
858         * html/HTMLStyleElement.cpp:
859         (WebCore::HTMLStyleElement::insertedInto):
860         (WebCore::HTMLStyleElement::removedFrom):
861         * html/HTMLStyleElement.h:
862         * html/HTMLTextFormControlElement.cpp:
863         (WebCore::HTMLTextFormControlElement::insertedInto):
864         * html/HTMLTextFormControlElement.h:
865         * html/HTMLTitleElement.cpp:
866         (WebCore::HTMLTitleElement::insertedInto):
867         (WebCore::HTMLTitleElement::removedFrom):
868         * html/HTMLTitleElement.h:
869         * html/HTMLTrackElement.cpp:
870         (WebCore::HTMLTrackElement::insertedInto):
871         (WebCore::HTMLTrackElement::removedFrom):
872         * html/HTMLTrackElement.h:
873         * mathml/MathMLMathElement.cpp:
874         (WebCore::MathMLMathElement::insertedInto):
875         * mathml/MathMLMathElement.h:
876         * svg/SVGElement.cpp:
877         (WebCore::SVGElement::removedFrom):
878         * svg/SVGElement.h:
879         * svg/SVGFEImageElement.cpp:
880         (WebCore::SVGFEImageElement::insertedInto):
881         (WebCore::SVGFEImageElement::removedFrom):
882         * svg/SVGFEImageElement.h:
883         * svg/SVGFontFaceElement.cpp:
884         (WebCore::SVGFontFaceElement::insertedInto):
885         (WebCore::SVGFontFaceElement::removedFrom):
886         * svg/SVGFontFaceElement.h:
887         * svg/SVGFontFaceUriElement.cpp:
888         (WebCore::SVGFontFaceUriElement::insertedInto):
889         * svg/SVGFontFaceUriElement.h:
890         * svg/SVGGlyphElement.cpp:
891         (WebCore::SVGGlyphElement::insertedInto):
892         (WebCore::SVGGlyphElement::removedFrom):
893         * svg/SVGGlyphElement.h:
894         * svg/SVGHKernElement.cpp:
895         (WebCore::SVGHKernElement::insertedInto):
896         (WebCore::SVGHKernElement::removedFrom):
897         * svg/SVGHKernElement.h:
898         * svg/SVGImageElement.cpp:
899         (WebCore::SVGImageElement::insertedInto):
900         * svg/SVGImageElement.h:
901         * svg/SVGSVGElement.cpp:
902         (WebCore::SVGSVGElement::insertedInto):
903         (WebCore::SVGSVGElement::removedFrom):
904         * svg/SVGSVGElement.h:
905         * svg/SVGScriptElement.cpp:
906         (WebCore::SVGScriptElement::insertedInto):
907         * svg/SVGScriptElement.h:
908         * svg/SVGStyleElement.cpp:
909         (WebCore::SVGStyleElement::insertedInto):
910         (WebCore::SVGStyleElement::removedFrom):
911         * svg/SVGStyleElement.h:
912         * svg/SVGStyledElement.cpp:
913         (WebCore::SVGStyledElement::insertedInto):
914         (WebCore::SVGStyledElement::removedFrom):
915         * svg/SVGStyledElement.h:
916         * svg/SVGTRefElement.cpp:
917         (WebCore::SVGTRefElement::insertedInto):
918         (WebCore::SVGTRefElement::removedFrom):
919         * svg/SVGTRefElement.h:
920         * svg/SVGTextPathElement.cpp:
921         (WebCore::SVGTextPathElement::insertedInto):
922         * svg/SVGTextPathElement.h:
923         * svg/SVGTitleElement.cpp:
924         (WebCore::SVGTitleElement::insertedInto):
925         (WebCore::SVGTitleElement::removedFrom):
926         * svg/SVGTitleElement.h:
927         * svg/SVGUseElement.cpp:
928         (WebCore::SVGUseElement::insertedInto):
929         (WebCore::SVGUseElement::removedFrom):
930         * svg/SVGUseElement.h:
931         * svg/SVGVKernElement.cpp:
932         (WebCore::SVGVKernElement::insertedInto):
933         (WebCore::SVGVKernElement::removedFrom):
934         * svg/SVGVKernElement.h:
935         * svg/animation/SVGSMILElement.cpp:
936         (WebCore::SVGSMILElement::insertedInto):
937         (WebCore::SVGSMILElement::removedFrom):
938         * svg/animation/SVGSMILElement.h:
939         Changed arguments of insertedInto and removedFrom to ContainerNode instead of Node.
940         Did the same with didNotifyDescendantInsertions, while fixing the typo in its name.
941
942         * editing/ReplaceSelectionCommand.cpp:
943         (WebCore::ReplaceSelectionCommand::doApply): Put a typecast toHTMLElement here.
944         The check for isListElement and isLegacyAppleStyleSpan takes care of the type checking.
945         (WebCore::ReplaceSelectionCommand::insertAsListItems): Changed this function to take
946         an HTMLElement instead of a Node, then we can drop use of the toContainerNode function.
947         * editing/ReplaceSelectionCommand.h:
948
949         * editing/TextIterator.cpp: Fixed a typo in a comment.
950
951 2012-05-23  Alexei Filippov  <alexeif@chromium.org>
952
953         Web Inspector: filter out debugging stuff from the heap class view
954         https://bugs.webkit.org/show_bug.cgi?id=86723
955
956         We mark objects that are accessible from user roots (e.g. Window)
957         with pageObject attribute. This fix filters out all non-pageObjects
958         from the classes view.
959
960         Reviewed by Yury Semikhatsky.
961
962         * inspector/front-end/HeapSnapshot.js:
963         (WebInspector.HeapSnapshotNode.prototype.isPageObject):
964         (WebInspector.HeapSnapshot.prototype._buildAggregates):
965         (WebInspector.HeapSnapshot.prototype._calculateClassesRetainedSize):
966         (WebInspector.HeapSnapshot.prototype._buildPostOrderIndex):
967         (WebInspector.HeapSnapshot.prototype._markPageOwnedNodes):
968         (WebInspector.HeapSnapshot.prototype.createNodesProviderForClass):
969
970 2012-05-23  Andrei Bucur  <abucur@adobe.com>
971
972         [CSSRegions]Implement NamedFlow::name attribute
973         https://bugs.webkit.org/show_bug.cgi?id=79645
974
975         Implementation for the NamedFlow::name attribute per the CSS Regions WD 3-May-2012 recommendation:
976         http://www.w3.org/TR/2012/WD-css3-regions-20120503/
977
978         Reviewed by Andreas Kling.
979
980         Test: fast/regions/webkit-named-flow-name.html
981
982         * dom/WebKitNamedFlow.cpp:
983         (WebCore::WebKitNamedFlow::name):
984         (WebCore):
985         * dom/WebKitNamedFlow.h:
986         (WebKitNamedFlow):
987         * dom/WebKitNamedFlow.idl:
988
989 2012-05-23  Andreas Kling  <kling@webkit.org>
990
991         Let the compiler generate FontFamily's copy ctor and assignment operator.
992
993         Blindly rubberstamped by the brave Antti Koivisto.
994
995         * platform/graphics/FontFamily.cpp:
996         * platform/graphics/FontFamily.h:
997
998 2012-05-23  Andreas Kling  <kling@webkit.org>
999
1000         CSSParser: Simplify StylePropertySet creation.
1001         <http://webkit.org/b/87259>
1002
1003         Reviewed by Alexis Menard.
1004
1005         Turn CSSParser's filteredProperties() into createStylePropertySet() which filters the parsed
1006         properties and creates a new StylePropertySet, adopting the vector to avoid the Vector copy we
1007         were previously incurring.
1008
1009         Added a StylePropertyVector typedef for Vector<CSSProperty, 4> since we need to pass this type
1010         to the constructor for Vector::swap() to work.
1011
1012         And thus StylePropertySet::create(const Vector<CSSProperty>&, CSSParserMode) became
1013         StylePropertySet::adopt(StylePropertyVector&, CSSParserMode).
1014
1015         * css/CSSComputedStyleDeclaration.cpp:
1016         (WebCore::CSSComputedStyleDeclaration::copyPropertiesInSet):
1017         * css/CSSParser.cpp:
1018         (WebCore::CSSParser::createStylePropertySet):
1019         (WebCore::CSSParser::createStyleRule):
1020         (WebCore::CSSParser::createFontFaceRule):
1021         (WebCore::CSSParser::createPageRule):
1022         (WebCore::CSSParser::createKeyframe):
1023         * css/CSSParser.h:
1024         * css/StylePropertySet.cpp:
1025         (WebCore::StylePropertySet::StylePropertySet):
1026         (WebCore::StylePropertySet::removePropertiesInSet):
1027         (WebCore::StylePropertySet::copyPropertiesInSet):
1028         (SameSizeAsStylePropertySet):
1029         * css/StylePropertySet.h:
1030         (WebCore::StylePropertySet::adopt):
1031         (StylePropertySet):
1032
1033 2012-05-23  Andreas Kling  <kling@webkit.org>
1034
1035         Kill some frivolous null-checking of Element::m_attributeData.
1036         <http://webkit.org/b/87248>
1037
1038         Reviewed by Antti Koivisto.
1039
1040         Replace unnecessary Element::m_attributeData with assertions where it makes sense.
1041         Others are flat out removed because it should be obvious from context that it's non-null.
1042         E.g if an attribute has changed, we're obviously storing it somewhere.
1043
1044         Also added a short-circuit to Element::normalize() if there are no Attr objects
1045         associated with the element.
1046
1047         * dom/Element.cpp:
1048         (WebCore::Element::~Element):
1049         (WebCore::Element::attributeChanged):
1050         (WebCore::Element::insertedInto):
1051         (WebCore::Element::removedFrom):
1052         (WebCore::Element::removeAttributeNode):
1053         (WebCore::Element::normalizeAttributes):
1054         * dom/StyledElement.cpp:
1055         (WebCore::StyledElement::classAttributeChanged):
1056
1057 2012-05-23  Andreas Kling  <kling@webkit.org>
1058
1059         Let Element::detachAttribute() handle removal of the attribute.
1060         <http://webkit.org/b/87242>
1061
1062         Reviewed by Antti Koivisto.
1063
1064         All the call sites were removing the attribute after detaching it, so move
1065         that into detachAttribute(). The function name already made it sound like it
1066         removes the attribute anyway.
1067
1068         Also sprinkle some assertions wrt being called with guaranteed presence of
1069         attributeData() and the provided index in the attribute vector.
1070
1071         * dom/Element.cpp:
1072         (WebCore::Element::detachAttribute):
1073         (WebCore::Element::removeAttributeNode):
1074         * dom/NamedNodeMap.cpp:
1075         (WebCore::NamedNodeMap::removeNamedItem):
1076         (WebCore::NamedNodeMap::removeNamedItemNS):
1077
1078 2012-05-23  Andreas Kling  <kling@webkit.org>
1079
1080         Streamline Element teardown for the no-Attr-objects case.
1081         <http://webkit.org/b/87228>
1082
1083         Reviewed by Antti Koivisto.
1084
1085         Dodge one function call in ~Element() if the element has no Attr objects
1086         associated (the typical case.)
1087
1088         Renamed detachAttributes to detachAttrObjectsFromElement to reduce ambiguity.
1089
1090         * dom/Element.cpp:
1091         (WebCore::Element::~Element):
1092         * dom/ElementAttributeData.cpp:
1093         (WebCore::ElementAttributeData::detachAttrObjectsFromElement):
1094         (WebCore::ElementAttributeData::clearAttributes):
1095         * dom/ElementAttributeData.h:
1096         (ElementAttributeData):
1097
1098 2012-05-23  Jochen Eisinger  <jochen@chromium.org>
1099
1100         Fix incomplete switch statement in CSSParser after r118082
1101         https://bugs.webkit.org/show_bug.cgi?id=87250
1102
1103         Reviewed by Alexis Menard.
1104
1105         * css/CSSParser.cpp:
1106         (WebCore::CSSParser::parseValue):
1107
1108 2012-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1109
1110         Unreviewed, rolling out r118105.
1111         http://trac.webkit.org/changeset/118105
1112         https://bugs.webkit.org/show_bug.cgi?id=87255
1113
1114         New LayoutTest is causing several cookie tests to fail on
1115         numerous bots (Requested by steveblock on #webkit).
1116
1117         * platform/blackberry/CookieJarBlackBerry.cpp:
1118         (WebCore::setCookies):
1119         * platform/blackberry/CookieManager.cpp:
1120         (WebCore::CookieManager::setCookies):
1121         (WebCore::CookieManager::checkAndTreatCookie):
1122         (WebCore::CookieManager::addCookieToMap):
1123         (WebCore::CookieManager::setPrivateMode):
1124         (WebCore):
1125         * platform/blackberry/CookieManager.h:
1126         * platform/blackberry/CookieMap.cpp:
1127         (WebCore::CookieMap::addOrReplaceCookie):
1128         (WebCore::CookieMap::removeCookie):
1129         * platform/blackberry/CookieMap.h:
1130         (CookieMap):
1131
1132 2012-05-23  Zan Dobersek  <zandobersek@gmail.com>
1133
1134         [Gtk] EventSender should properly handle (left|right)(control|shift|alt) after r118001
1135         https://bugs.webkit.org/show_bug.cgi?id=87221
1136
1137         Reviewed by Martin Robinson.
1138
1139         No new tests - covered by fast/events/keydown-leftright-keys.html.
1140
1141         Windows key code for shift, control and alt keys should respect the
1142         left or right position of that key. This way the DOM location code of
1143         a key event is properly determined for these keys.
1144
1145         * platform/gtk/PlatformKeyboardEventGtk.cpp:
1146         (WebCore::PlatformKeyboardEvent::windowsKeyCodeForGdkKeyCode):
1147
1148 2012-05-23  Ilya Tikhonovsky  <loislo@chromium.org>
1149
1150         Web Inspector: eliminate getters from HeapSnapshot.js
1151         https://bugs.webkit.org/show_bug.cgi?id=87241
1152
1153         getters can't be inlined by engine at the moment.
1154         I found that conversion getters into functions gives us about 600 ms
1155
1156         RESULT heap-snapshot: switch-to-containment-view= 1920 ms
1157         vs
1158         RESULT heap-snapshot: switch-to-containment-view= 1367 ms
1159
1160         Reviewed by Yury Semikhatsky.
1161
1162         * inspector/front-end/HeapSnapshot.js:
1163         (WebInspector.HeapSnapshotEdge.prototype.hasStringName):
1164         (WebInspector.HeapSnapshotEdge.prototype.isElement):
1165         (WebInspector.HeapSnapshotEdge.prototype.isHidden):
1166         (WebInspector.HeapSnapshotEdge.prototype.isWeak):
1167         (WebInspector.HeapSnapshotEdge.prototype.isInternal):
1168         (WebInspector.HeapSnapshotEdge.prototype.isInvisible):
1169         (WebInspector.HeapSnapshotEdge.prototype.isShortcut):
1170         (WebInspector.HeapSnapshotEdge.prototype.name):
1171         (WebInspector.HeapSnapshotEdge.prototype.node):
1172         (WebInspector.HeapSnapshotEdge.prototype.nodeIndex):
1173         (WebInspector.HeapSnapshotEdge.prototype.rawEdges):
1174         (WebInspector.HeapSnapshotEdge.prototype.toString):
1175         (WebInspector.HeapSnapshotEdge.prototype.type):
1176         (WebInspector.HeapSnapshotEdge.prototype._hasStringName):
1177         (WebInspector.HeapSnapshotEdge.prototype._name):
1178         (WebInspector.HeapSnapshotEdge.prototype._nameOrIndex):
1179         (WebInspector.HeapSnapshotEdgeIterator.prototype.index):
1180         (WebInspector.HeapSnapshotEdgeIterator.prototype.setIndex):
1181         (WebInspector.HeapSnapshotEdgeIterator.prototype.item):
1182         (WebInspector.HeapSnapshotRetainerEdge):
1183         (WebInspector.HeapSnapshotRetainerEdge.prototype.clone):
1184         (WebInspector.HeapSnapshotRetainerEdge.prototype.hasStringName):
1185         (WebInspector.HeapSnapshotRetainerEdge.prototype.isElement):
1186         (WebInspector.HeapSnapshotRetainerEdge.prototype.isHidden):
1187         (WebInspector.HeapSnapshotRetainerEdge.prototype.isInternal):
1188         (WebInspector.HeapSnapshotRetainerEdge.prototype.isInvisible):
1189         (WebInspector.HeapSnapshotRetainerEdge.prototype.isShortcut):
1190         (WebInspector.HeapSnapshotRetainerEdge.prototype.isWeak):
1191         (WebInspector.HeapSnapshotRetainerEdge.prototype.name):
1192         (WebInspector.HeapSnapshotRetainerEdge.prototype.node):
1193         (WebInspector.HeapSnapshotRetainerEdge.prototype.nodeIndex):
1194         (WebInspector.HeapSnapshotRetainerEdge.prototype.retainerIndex):
1195         (WebInspector.HeapSnapshotRetainerEdge.prototype.setRetainerIndex):
1196         (WebInspector.HeapSnapshotRetainerEdge.prototype._node):
1197         (WebInspector.HeapSnapshotRetainerEdge.prototype._edge):
1198         (WebInspector.HeapSnapshotRetainerEdge.prototype.toString):
1199         (WebInspector.HeapSnapshotRetainerEdge.prototype.type):
1200         (WebInspector.HeapSnapshotRetainerEdgeIterator.prototype.first):
1201         (WebInspector.HeapSnapshotRetainerEdgeIterator.prototype.hasNext):
1202         (WebInspector.HeapSnapshotRetainerEdgeIterator.prototype.index):
1203         (WebInspector.HeapSnapshotRetainerEdgeIterator.prototype.setIndex):
1204         (WebInspector.HeapSnapshotRetainerEdgeIterator.prototype.item):
1205         (WebInspector.HeapSnapshotRetainerEdgeIterator.prototype.next):
1206         (WebInspector.HeapSnapshotNode.prototype.canBeQueried):
1207         (WebInspector.HeapSnapshotNode.prototype.distanceToWindow):
1208         (WebInspector.HeapSnapshotNode.prototype.className):
1209         (WebInspector.HeapSnapshotNode.prototype.dominatorIndex):
1210         (WebInspector.HeapSnapshotNode.prototype.edges):
1211         (WebInspector.HeapSnapshotNode.prototype.edgesCount):
1212         (WebInspector.HeapSnapshotNode.prototype.flags):
1213         (WebInspector.HeapSnapshotNode.prototype.id):
1214         (WebInspector.HeapSnapshotNode.prototype.isHidden):
1215         (WebInspector.HeapSnapshotNode.prototype.isNative):
1216         (WebInspector.HeapSnapshotNode.prototype.isSynthetic):
1217         (WebInspector.HeapSnapshotNode.prototype.isWindow):
1218         (WebInspector.HeapSnapshotNode.prototype.isDetachedDOMTreesRoot):
1219         (WebInspector.HeapSnapshotNode.prototype.isDetachedDOMTree):
1220         (WebInspector.HeapSnapshotNode.prototype.isRoot):
1221         (WebInspector.HeapSnapshotNode.prototype.name):
1222         (WebInspector.HeapSnapshotNode.prototype.rawEdges):
1223         (WebInspector.HeapSnapshotNode.prototype.retainedSize):
1224         (WebInspector.HeapSnapshotNode.prototype.retainers):
1225         (WebInspector.HeapSnapshotNode.prototype.selfSize):
1226         (WebInspector.HeapSnapshotNode.prototype.type):
1227         (WebInspector.HeapSnapshotNode.prototype._name):
1228         (WebInspector.HeapSnapshotNode.prototype._edgeIndexesEnd):
1229         (WebInspector.HeapSnapshotNode.prototype._nextNodeIndex):
1230         (WebInspector.HeapSnapshotNode.prototype._type):
1231         (WebInspector.HeapSnapshotNodeIterator):
1232         (WebInspector.HeapSnapshotNodeIterator.prototype.hasNext):
1233         (WebInspector.HeapSnapshotNodeIterator.prototype.index):
1234         (WebInspector.HeapSnapshotNodeIterator.prototype.setIndex):
1235         (WebInspector.HeapSnapshotNodeIterator.prototype.item):
1236         (WebInspector.HeapSnapshotNodeIterator.prototype.next):
1237         (WebInspector.HeapSnapshot.prototype._allNodes):
1238         (WebInspector.HeapSnapshot.prototype.rootNode):
1239         (WebInspector.HeapSnapshot.prototype.get totalSize):
1240         (WebInspector.HeapSnapshot.prototype._dominatedNodesOfNode):
1241         (WebInspector.HeapSnapshot.prototype.aggregatesForDiff):
1242         (WebInspector.HeapSnapshot.prototype._calculateObjectToWindowDistance):
1243         (WebInspector.HeapSnapshot.prototype._buildAggregates):
1244         (WebInspector.HeapSnapshot.prototype._calculateClassesRetainedSize):
1245         (WebInspector.HeapSnapshot.prototype._sortAggregateIndexes):
1246         (WebInspector.HeapSnapshot.prototype._markInvisibleEdges):
1247         (WebInspector.HeapSnapshot.prototype._markDetachedDOMTreeNodes):
1248         (WebInspector.HeapSnapshot.prototype._markQueriableHeapObjects):
1249         (WebInspector.HeapSnapshot.prototype._calculateDiffForClass):
1250         (WebInspector.HeapSnapshot.prototype._nodeForSnapshotObjectId):
1251         (WebInspector.HeapSnapshot.prototype.nodeClassName):
1252         (WebInspector.HeapSnapshot.prototype.dominatorIdsForNode):
1253         (WebInspector.HeapSnapshot.prototype.createEdgesProvider):
1254         (WebInspector.HeapSnapshot.prototype.createRetainingEdgesProvider):
1255         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype._createIterationOrder):
1256         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.isEmpty):
1257         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.item):
1258         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.serializeItemsRange):
1259         (WebInspector.HeapSnapshotEdgesProvider.prototype.serializeItem):
1260         (WebInspector.HeapSnapshotEdgesProvider.prototype.sort.compareEdgeFieldName):
1261         (WebInspector.HeapSnapshotEdgesProvider.prototype.sort.compareNodeField):
1262         (WebInspector.HeapSnapshotNodesProvider):
1263         (WebInspector.HeapSnapshotNodesProvider.prototype.nodePosition):
1264         (WebInspector.HeapSnapshotNodesProvider.prototype.serializeItem):
1265         (WebInspector.HeapSnapshotNodesProvider.prototype.sort.sortByNodeField):
1266         * inspector/front-end/HeapSnapshotGridNodes.js:
1267         * inspector/front-end/HeapSnapshotProxy.js:
1268         (WebInspector.HeapSnapshotProviderProxy.prototype.isEmpty):
1269
1270 2012-05-22  Yury Semikhatsky  <yurys@chromium.org>
1271
1272         Web Inspector: Debugger should correctly show catch scope
1273         https://bugs.webkit.org/show_bug.cgi?id=87197
1274
1275         Reviewed by Vsevolod Vlasov.
1276
1277         * bindings/v8/DebuggerScript.js: In case of Catch scope the scope object
1278         is a synthetic one which means that it contains all standard object properties.
1279         When passing this object further we need to leave only properties available in
1280         the catch block(only variable thar stores the exception in fact).
1281
1282 2012-05-23  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1283
1284         [Qt] FloatSize Qt Support
1285         https://bugs.webkit.org/show_bug.cgi?id=87237
1286
1287         Reviewed by Andreas Kling.
1288
1289         No new functionality. No new tests.
1290
1291         * Target.pri:
1292         * platform/graphics/FloatSize.h:
1293         (FloatSize):
1294         * platform/graphics/qt/FloatSizeQt.cpp: Added.
1295         (WebCore::FloatSize::FloatSize):
1296         (WebCore::FloatSize::operator QSizeF):
1297
1298 2012-05-23  Alexei Filippov  <alexeif@chromium.org>
1299
1300         Web Inspector: Enable HeapSnapshotRealWorker in production mode.
1301         https://bugs.webkit.org/show_bug.cgi?id=87240
1302
1303         Reviewed by Yury Semikhatsky.
1304
1305         * inspector/front-end/HeapSnapshotProxy.js:
1306         (WebInspector.HeapSnapshotWorker):
1307
1308 2012-05-23  'Pavel Feldman'  <pfeldman@chromium.org>
1309
1310         Not reviewed: inspector's Find is not consuming event as of r117974.
1311
1312         * inspector/front-end/AdvancedSearchController.js:
1313         (WebInspector.AdvancedSearchController.prototype.handleShortcut):
1314         * inspector/front-end/SearchController.js:
1315         (WebInspector.SearchController.prototype.handleShortcut):
1316
1317 2012-05-23  Pavel Feldman  <pfeldman@chromium.org>
1318
1319         Web Inspector: enable drag-an-drop from the navigator panel.
1320         https://bugs.webkit.org/show_bug.cgi?id=87238
1321
1322         Reviewed by Vsevolod Vlasov.
1323
1324         Making tree item draggable.
1325
1326         * inspector/front-end/NavigatorView.js:
1327         (WebInspector.NavigatorSourceTreeElement.prototype.onattach):
1328         (WebInspector.NavigatorSourceTreeElement.prototype._onmousedown.callback):
1329         (WebInspector.NavigatorSourceTreeElement.prototype._onmousedown):
1330         (WebInspector.NavigatorSourceTreeElement.prototype._ondragstart):
1331
1332 2012-05-23  Ryosuke Niwa  <rniwa@webkit.org>
1333
1334         WebKit spends ~20% of time in HTMLTextAreaElement::defaultValue() when opening a review page
1335         https://bugs.webkit.org/show_bug.cgi?id=86813
1336
1337         Reviewed by Eric Seidel.
1338
1339         Replace String and calls to String::operator+= by StringBuilder and calls to append respectively.
1340         While there are other optimizations we can implement such as not replacing all nodes in the shadow DOM,
1341         or not serializing the value when detecting whether the value had changed, they require considerable
1342         amount of refactoring and this change alone seems to buy us a lot so let us defer those 'til later time.
1343
1344         Also avoid the redundant call to setValue in childrenChanged when the value is dirty.
1345         This should halve the time we spend in setting the value.
1346
1347         * html/HTMLTextAreaElement.cpp:
1348         (WebCore::HTMLTextAreaElement::childrenChanged):
1349         (WebCore::HTMLTextAreaElement::defaultValue):
1350
1351 2012-05-23  Alice Boxhall  <aboxhall@chromium.org>
1352
1353         AX: Contenteditable tables should always be exposed as data tables
1354         https://bugs.webkit.org/show_bug.cgi?id=87052
1355
1356         Reviewed by Chris Fleizach.
1357
1358         Tested in accessibility/table-detection.html.
1359
1360         * accessibility/AccessibilityTable.cpp:
1361         (WebCore::AccessibilityTable::isDataTable): Return true if the node is contenteditable.
1362
1363 2012-05-23  Ryosuke Niwa  <rniwa@webkit.org>
1364
1365         Fix a typo per Darin's comment.
1366
1367         * rendering/RenderBlockLineLayout.cpp:
1368         (WebCore::constructBidiRuns):
1369
1370 2012-05-23  Kentaro Hara  <haraken@chromium.org>
1371
1372         [V8] Pass Isolate to v8::Null() in custom bindings (Part 2)
1373         https://bugs.webkit.org/show_bug.cgi?id=87209
1374
1375         Reviewed by Adam Barth.
1376
1377         The objective is to pass Isolate around in V8 bindings.
1378         This patch passes Isolate to v8::Null() in custom bindings.
1379
1380         No tests. No change in behavior.
1381
1382         * bindings/v8/custom/V8HTMLElementCustom.cpp:
1383         (WebCore::toV8Object):
1384         (WebCore::toV8):
1385         * bindings/v8/custom/V8HistoryCustom.cpp:
1386         (WebCore::V8History::stateAccessorGetter):
1387         * bindings/v8/custom/V8IDBAnyCustom.cpp:
1388         (WebCore::toV8):
1389         * bindings/v8/custom/V8IDBKeyCustom.cpp:
1390         (WebCore::toV8):
1391         * bindings/v8/custom/V8ImageDataCustom.cpp:
1392         (WebCore::toV8):
1393         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
1394         (WebCore::toV8):
1395         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
1396         (WebCore::toV8):
1397         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
1398         (WebCore::toV8):
1399         * bindings/v8/custom/V8LocationCustom.cpp:
1400         (WebCore::toV8):
1401         * bindings/v8/custom/V8MessageEventCustom.cpp:
1402         (WebCore::V8MessageEvent::dataAccessorGetter):
1403         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
1404         (WebCore::toV8):
1405         * bindings/v8/custom/V8NodeCustom.cpp:
1406         (WebCore::V8Node::insertBeforeCallback):
1407         (WebCore::V8Node::replaceChildCallback):
1408         (WebCore::V8Node::removeChildCallback):
1409         (WebCore::V8Node::appendChildCallback):
1410         (WebCore::toV8Slow):
1411         * bindings/v8/custom/V8PopStateEventCustom.cpp:
1412         (WebCore::V8PopStateEvent::stateAccessorGetter):
1413         * bindings/v8/custom/V8SQLResultSetRowListCustom.cpp:
1414         (WebCore::V8SQLResultSetRowList::itemCallback):
1415         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
1416         (WebCore::toV8):
1417         * bindings/v8/custom/V8SVGElementCustom.cpp:
1418         (WebCore::toV8):
1419         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
1420         (WebCore::toV8):
1421         * bindings/v8/custom/V8ScriptProfileCustom.cpp:
1422         (WebCore::toV8):
1423         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp:
1424         (WebCore::toV8):
1425         * bindings/v8/custom/V8StyleSheetCustom.cpp:
1426         (WebCore::toV8):
1427         * bindings/v8/custom/V8TrackEventCustom.cpp:
1428         (WebCore::V8TrackEvent::trackAccessorGetter):
1429         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
1430         (WebCore::toV8):
1431         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
1432         (WebCore::toV8):
1433         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
1434         (WebCore::toV8):
1435         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp:
1436         (WebCore::toV8):
1437         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
1438         (WebCore::toV8Object):
1439         (WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
1440         (WebCore::V8WebGLRenderingContext::getSupportedExtensionsCallback):
1441         * bindings/v8/custom/V8WorkerContextCustom.cpp:
1442         (WebCore::toV8):
1443
1444 2012-05-23  Kentaro Hara  <haraken@chromium.org>
1445
1446         [V8] Pass Isolate to v8::Null() in custom bindings (Part 1)
1447         https://bugs.webkit.org/show_bug.cgi?id=87207
1448
1449         Reviewed by Adam Barth.
1450
1451         The objective is to pass Isolate around in V8 bindings.
1452         This patch passes Isolate to v8::Null() in custom bindings.
1453
1454         Also this patch makes V8DeviceMotionEventCustom::createAccelerationObject()
1455         and V8DeviceMotionEventCustom::createRotationRateObject() static.
1456
1457         No tests. No change in behavior.
1458
1459         * bindings/v8/custom/V8BlobCustom.cpp:
1460         (WebCore::toV8):
1461         * bindings/v8/custom/V8CSSRuleCustom.cpp:
1462         (WebCore::toV8):
1463         * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
1464         (WebCore::toV8):
1465         * bindings/v8/custom/V8CSSValueCustom.cpp:
1466         (WebCore::toV8):
1467         * bindings/v8/custom/V8ClipboardCustom.cpp:
1468         (WebCore::V8Clipboard::typesAccessorGetter):
1469         * bindings/v8/custom/V8CoordinatesCustom.cpp:
1470         (WebCore::V8Coordinates::altitudeAccessorGetter):
1471         (WebCore::V8Coordinates::altitudeAccuracyAccessorGetter):
1472         (WebCore::V8Coordinates::headingAccessorGetter):
1473         (WebCore::V8Coordinates::speedAccessorGetter):
1474         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
1475         (WebCore::toV8):
1476         * bindings/v8/custom/V8DOMTokenListCustom.cpp:
1477         (WebCore::toV8):
1478         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1479         (WebCore::toV8):
1480         * bindings/v8/custom/V8DataViewCustom.cpp:
1481         (WebCore::toV8):
1482         * bindings/v8/custom/V8DeviceMotionEventCustom.cpp:
1483         (WebCore::V8DeviceMotionEvent::accelerationAccessorGetter):
1484         (WebCore::V8DeviceMotionEvent::accelerationIncludingGravityAccessorGetter):
1485         (WebCore::V8DeviceMotionEvent::rotationRateAccessorGetter):
1486         (WebCore::V8DeviceMotionEvent::intervalAccessorGetter):
1487         * bindings/v8/custom/V8DeviceOrientationEventCustom.cpp:
1488         (WebCore::V8DeviceOrientationEvent::alphaAccessorGetter):
1489         (WebCore::V8DeviceOrientationEvent::betaAccessorGetter):
1490         (WebCore::V8DeviceOrientationEvent::gammaAccessorGetter):
1491         (WebCore::V8DeviceOrientationEvent::absoluteAccessorGetter):
1492         * bindings/v8/custom/V8DocumentCustom.cpp:
1493         (WebCore::toV8):
1494         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
1495         (WebCore::V8Document::locationAccessorGetter):
1496         * bindings/v8/custom/V8EntryCustom.cpp:
1497         (WebCore::toV8):
1498         * bindings/v8/custom/V8EntrySyncCustom.cpp:
1499         (WebCore::toV8):
1500         * bindings/v8/custom/V8EventCustom.cpp:
1501         (WebCore::toV8):
1502         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
1503         (WebCore::toV8):
1504         * bindings/v8/custom/V8Float64ArrayCustom.cpp:
1505         (WebCore::toV8):
1506         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
1507         (WebCore::V8HTMLCanvasElement::getContextCallback):
1508         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
1509         (WebCore::toV8):
1510
1511 2012-05-22  MORITA Hajime  <morrita@google.com>
1512
1513         [Refactoring] ElementShadow::m_needsRedistributing  should be on ContentDistributor
1514         https://bugs.webkit.org/show_bug.cgi?id=87216
1515
1516         Reviewed by Kentaro Hara.
1517
1518         Moved ElementShadow::m_needsRedistributing to ContentDistributor::m_needsRedistributing
1519
1520         No new tests. No behavior change.
1521
1522         * dom/ElementShadow.cpp:
1523         (WebCore::ElementShadow::recalcStyle):
1524         (WebCore::ElementShadow::needsRedistributing):
1525         (WebCore::ElementShadow::setNeedsRedistributing):
1526         * dom/ElementShadow.h:
1527         (ElementShadow):
1528         * dom/ShadowRoot.h: Removed outdated declarations.
1529         * html/shadow/ContentDistributor.cpp:
1530         (WebCore::ContentDistributor::ContentDistributor):
1531         * html/shadow/ContentDistributor.h:
1532         (WebCore::ContentDistributor::needsRedistributing):
1533         (WebCore::ContentDistributor::setNeedsRedistributing):
1534         (WebCore::ContentDistributor::clearNeedsRedistributing):
1535
1536 2012-05-22  Kentaro Hara  <haraken@chromium.org>
1537
1538         [V8] Pass Isolate to v8::Null() in CodeGeneratorV8.pm
1539         https://bugs.webkit.org/show_bug.cgi?id=87202
1540
1541         Reviewed by Adam Barth.
1542
1543         The objective is to pass Isolate around in V8 bindings.
1544         This patch passes Isolate to v8::Null() in CodeGeneratorV8.pm.
1545
1546         No tests. No change in behavior.
1547
1548         * bindings/scripts/CodeGeneratorV8.pm:
1549         (GenerateNormalAttrGetter):
1550         (GenerateFunctionCallback):
1551         (NativeToJSValue):
1552         * bindings/scripts/test/V8/V8TestObj.cpp:
1553         (WebCore::TestObjV8Internal::contentDocumentAttrGetter):
1554         (WebCore::TestObjV8Internal::getSVGDocumentCallback):
1555         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1556         (WebCore::TestSerializedScriptValueInterfaceV8Internal::valueAttrGetter):
1557         (WebCore::TestSerializedScriptValueInterfaceV8Internal::readonlyValueAttrGetter):
1558         (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedValueAttrGetter):
1559         (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedReadonlyValueAttrGetter):
1560
1561 2012-05-22  Andreas Kling  <kling@webkit.org>
1562
1563         Short-circuit Element::attrIfExists() when the Element has no Attr list.
1564         <http://webkit.org/b/87214>
1565
1566         Reviewed by Ryosuke Niwa.
1567
1568         This function was lukewarm on Dromaeo/dom-attr (0.4% of samples.)
1569         Added an early return if !hasAttrList() to avoid the function call overhead of
1570         ElementAttributeData::attrIfExists().
1571
1572         * dom/Element.cpp:
1573         (WebCore::Element::attrIfExists):
1574
1575 2012-05-22  Hayato Ito  <hayato@chromium.org>
1576
1577         Remove an assertion since an event's target might be a shadow root if a text node is clicked.
1578         https://bugs.webkit.org/show_bug.cgi?id=87072
1579
1580         Reviewed by Dimitri Glazkov.
1581
1582         Tests: fast/dom/shadow/shadow-dom-event-dispatching.html
1583
1584         * dom/ComposedShadowTreeWalker.cpp:
1585         (WebCore::ComposedShadowTreeWalker::ComposedShadowTreeWalker):
1586
1587 2012-05-22  Dongwoo Im  <dw.im@samsung.com>
1588
1589         [EFL] Implements the registerProtocolHandler method and option.
1590         https://bugs.webkit.org/show_bug.cgi?id=73638
1591
1592         Reviewed by Andreas Kling.
1593
1594         The registerProtocolHandler() method allows Web sites to register themselves
1595         as possible handlers for particular schemes.
1596
1597         http://dev.w3.org/html5/spec/Overview.html#dom-navigator-registerprotocolhandler
1598
1599         * CMakeLists.txt: Add page/NavigatorRegisterProtocolHandler.idl into WebCore_IDL_FILES.
1600
1601 2012-05-22  Kentaro Hara  <haraken@chromium.org>
1602
1603         [V8][Performance] Pass Isolate to v8::Null() in V8Node::toV8()
1604         https://bugs.webkit.org/show_bug.cgi?id=87193
1605
1606         Reviewed by Adam Barth.
1607
1608         This patch improves the performance of Bindings/undefined-first-child.html by 58.7%,
1609         Bindings/undefined-get-element-by-id.html by 26.8%,
1610         Dromaeo/dom-query.html(getElementById (not in document)) by 9.8%,
1611         and Dromaeo/dom-query.html(getElementsByName (not in document)) by 2.1%.
1612         These benchmarks test the performance of accessing an undefined Node object.
1613
1614         Performance test results in my Linux desktop:
1615
1616         [Bindings/undefined-first-child.html]
1617           - without my patch
1618           RESULT Bindings: undefined-first-child= 481.843775891 runs/s
1619           median= 474.934036939 runs/s, stdev= 17.7753278263 runs/s, min= 471.204188482 runs/s, max= 534.629404617 runs/s
1620
1621           - with my patch
1622           RESULT Bindings: undefined-first-child= 764.720531908 runs/s
1623           median= 803.515696424 runs/s, stdev= 54.7402312963 runs/s, min= 688.806888069 runs/s, max= 807.061790668 runs/s
1624
1625         [Bindings/undefined-get-element-by-id.html]
1626           - without my patch
1627           RESULT Bindings: undefined-get-element-by-id= 236.642705579 runs/s
1628           median= 234.527786832 runs/s, stdev= 5.77090297761 runs/s, min= 231.362467866 runs/s, max= 246.305418719 runs/s
1629
1630           - with my patch
1631           RESULT Bindings: undefined-get-element-by-id= 300.031032067 runs/s
1632           median= 303.797468354 runs/s, stdev= 6.99060409266 runs/s, min= 287.581699346 runs/s, max= 304.955527319 runs/s
1633
1634         [Dromaeo/dom-query.html(getElementById (not in document))]
1635           - without my patch
1636           2855.80runs/s ±0.30%
1637
1638           - with my patch
1639           3136.20runs/s ±0.22%
1640
1641         [Dromaeo/dom-query.html(getElementsByName (not in document))]
1642           - without my patch
1643           2198.00runs/s ±0.50%
1644
1645           - with my patch
1646           2243.40runs/s ±3.39%
1647
1648         Currently v8::Null() looks up Isolate, which is a bottleneck of
1649         V8Node::toV8() for undefined Nodes. This patch removes the Isolate
1650         look-up by passing Isolate to v8::Null(), like v8::Null(isolate).
1651
1652         * bindings/scripts/CodeGeneratorV8.pm: Modified as described above.
1653         (GenerateHeader):
1654
1655         * bindings/scripts/test/V8/V8TestActiveDOMObject.h: Updated run-bindings-tests results.
1656         (WebCore::toV8):
1657         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
1658         (WebCore::toV8):
1659         * bindings/scripts/test/V8/V8TestEventConstructor.h:
1660         (WebCore::toV8):
1661         * bindings/scripts/test/V8/V8TestEventTarget.h:
1662         (WebCore::toV8):
1663         * bindings/scripts/test/V8/V8TestException.h:
1664         (WebCore::toV8):
1665         * bindings/scripts/test/V8/V8TestInterface.h:
1666         (WebCore::toV8):
1667         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
1668         (WebCore::toV8):
1669         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
1670         (WebCore::toV8):
1671         * bindings/scripts/test/V8/V8TestNode.h:
1672         (WebCore::toV8):
1673         * bindings/scripts/test/V8/V8TestObj.h:
1674         (WebCore::toV8):
1675         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
1676         (WebCore::toV8):
1677
1678 2012-05-22  MORITA Hajime  <morrita@google.com>
1679
1680         REGRESSION(r116629) tests for <style scoped> is crashing
1681         https://bugs.webkit.org/show_bug.cgi?id=87191
1682
1683         Reviewed by Kent Tamura.
1684
1685         unregisterWithScopingNode() and registerWithScopingNode() doesn't follow
1686         refactoring around removedFrom(), insertedInto() and willRemove().
1687         This change aligns them to such recent changes.
1688
1689         No new tests. Covered by existing tests.
1690
1691         * html/HTMLStyleElement.cpp:
1692         (WebCore::HTMLStyleElement::unregisterWithScopingNode)
1693         (WebCore::HTMLStyleElement::insertedInto):
1694         - Allowed registerWithScopingNode() only for in-document traversal.
1695           That is how it originally did.
1696         (WebCore::HTMLStyleElement::removedFrom):
1697         - Gave ex-parent to unregisterWithScopingNode().
1698         * html/HTMLStyleElement.h:
1699         (WebCore::HTMLStyleElement::unregisterWithScopingNode):
1700         (HTMLStyleElement):
1701
1702 2012-05-21  Shawn Singh  <shawnsingh@chromium.org>
1703
1704         Improve W3C conformance of backface-visibility
1705         https://bugs.webkit.org/show_bug.cgi?id=84195
1706
1707         Reviewed by Adrienne Walker.
1708
1709         Tests: compositing/backface-visibility/backface-visibility-3d.html
1710                compositing/backface-visibility/backface-visibility-hierarchical-transform.html
1711                compositing/backface-visibility/backface-visibility-non3d.html
1712                compositing/backface-visibility/backface-visibility-simple.html
1713
1714         Unit Tests: CCLayerTreeHostCommonTest::verifyBackFaceCullingWithoutPreserves3d
1715                     CCLayerTreeHostCommonTest::verifyBackFaceCullingWithPreserves3d
1716
1717         Also updated a few other layout and unit tests.
1718
1719         This patch updates chromium to conform to the W3C spec on CSS
1720         transforms, Section 12 about backface visibility. This patch also
1721         updates layout tests to reflect the latest W3C spec. In
1722         particular, rule #1 on section 12, http://dev.w3.org/csswg/css3-transforms/#backface-visibility-property
1723         states which transforms should be used to determine backface-visibility.
1724
1725         Because chromium has an additional quirk of the concept of render
1726         surfaces, unit tests needed to be updated as well.
1727
1728         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
1729         (WebCore::layerIsRootOfNewRenderingContext):
1730         (WebCore):
1731         (WebCore::isLayerBackFaceVisible):
1732         (WebCore::isSurfaceBackFaceVisible):
1733         (WebCore::calculateVisibleLayerRect):
1734         (WebCore::layerShouldBeSkipped):
1735         (WebCore::calculateDrawTransformsAndVisibilityInternal):
1736
1737 2012-05-22  Sheriff Bot  <webkit.review.bot@gmail.com>
1738
1739         Unreviewed, rolling out r118095.
1740         http://trac.webkit.org/changeset/118095
1741         https://bugs.webkit.org/show_bug.cgi?id=87201
1742
1743         "Causing crashes on Mac in
1744         WebCore::StyleResolver::adjustRenderStyle (Requested by
1745         sundiamonde on #webkit).
1746
1747         * css/StyleResolver.cpp:
1748         (WebCore::StyleResolver::collectMatchingRulesForList):
1749         * page/Settings.cpp:
1750         (WebCore::Settings::Settings):
1751         * page/Settings.h:
1752         (Settings):
1753         * testing/InternalSettings.cpp:
1754         (WebCore::InternalSettings::InternalSettings):
1755         (WebCore::InternalSettings::restoreTo):
1756         * testing/InternalSettings.h:
1757         (InternalSettings):
1758         * testing/InternalSettings.idl:
1759
1760 2012-05-22  Levi Weintraub  <leviw@chromium.org>
1761
1762         NULL ptr in WebCore::RenderBlock::layoutRunsAndFloatsInRange
1763         https://bugs.webkit.org/show_bug.cgi?id=77786
1764
1765         Reviewed by Ryosuke Niwa.
1766
1767         InlineBidiResolver adds one fake TextRun for isolated inlines in the process of creating the
1768         list of TextRuns to send to the UBA. After the UBA has been run and the TextRuns reordered,
1769         we re-run InlineBidiResolver rooted in the isolate and replace the fake run with those
1770         generated by the subsequent pass by calling the method BidiRunList::replaceRunWithRuns.
1771         This method assumes there are runs to replace the fake run with.
1772
1773         Positioned inline children are ignored when creating TextRuns, so when an isolated inline
1774         has only positioned children we end up with an empty set of runs to pass to replaceRunWithRuns.
1775         Ideally, we'd remove the fake run and not replace it with anything, but BidiRunList keeps
1776         a pointer to the logically last run, which we're unable to easily re-determine after the UBA
1777         has been run. Instead, we leave the fake run in the list and simply avoid calling
1778         replaceRunWithRuns when we don't have any replacement runs.
1779
1780         Test: fast/block/line-layout/crash-in-isolate-with-positioned-child.html
1781
1782         * rendering/RenderBlockLineLayout.cpp:
1783         (WebCore::constructBidiRuns):
1784
1785 2012-05-22  Kent Tamura  <tkent@chromium.org>
1786
1787         [V8] Refactor generation code for non-standard functions
1788         https://bugs.webkit.org/show_bug.cgi?id=87185
1789
1790         Reviewed by Kentaro Hara.
1791
1792         No behavior change. Just a refactoring.
1793
1794         * bindings/scripts/CodeGeneratorV8.pm:
1795         (IsStandardFunction): Introduce a new function to check if a
1796         function can be in a batch registration.
1797         (GenerateNonStandardFunction): Factor out a code to generate
1798         non-standard functions.
1799         (GenerateImplementation):
1800         Use IsStandardFunction and GenerateNonStandardFunction.
1801
1802 2012-05-22  Hayato Ito  <hayato@chromium.org>
1803
1804         Make ComposedShadowTreeWalker traverse inactive insertion points correctly.
1805         https://bugs.webkit.org/show_bug.cgi?id=86830
1806
1807         Reviewed by Dimitri Glazkov.
1808
1809         Fixed InsertionPoint::isActive() issue, which may return true
1810         wrongly even if the insertion point is not in Shadow DOM subtree.
1811         Now ComposedShadowTreeWalker can traverse inactive insertion
1812         points correctly using InsertionPoint::isActive().
1813
1814         Test: fast/dom/shadow/composed-shadow-tree-walker.html
1815
1816         * dom/ComposedShadowTreeWalker.cpp:
1817         (WebCore::ComposedShadowTreeWalker::traverseNode):
1818         (WebCore::ComposedShadowTreeWalker::escapeFallbackContentElement):
1819         (WebCore::ComposedShadowTreeWalker::traverseNodeEscapingFallbackContents):
1820         * html/shadow/InsertionPoint.cpp:
1821         (WebCore::InsertionPoint::isActive):
1822         * html/shadow/InsertionPoint.h:
1823         (WebCore::isActiveInsertionPoint):
1824         (WebCore):
1825
1826 2012-05-22  Mark Pilgrim  <pilgrim@chromium.org>
1827
1828         [Chromium] Call canAccelerate2dCanvas directly
1829         https://bugs.webkit.org/show_bug.cgi?id=86893
1830
1831         Reviewed by James Robinson.
1832
1833         Part of a refactoring series. See tracking bug 82948.
1834
1835         * html/HTMLCanvasElement.cpp:
1836         (WebCore::HTMLCanvasElement::shouldAccelerate):
1837         * platform/chromium/PlatformSupport.h:
1838
1839 2012-05-22  Jason Liu  <jason.liu@torchmobile.com.cn>
1840
1841         [BlackBerry] Possible to clobber httponly cookie.
1842         https://bugs.webkit.org/show_bug.cgi?id=86067
1843
1844         Reviewed by Rob Buis.
1845
1846         If a cookie is set by javaScript and there is already a same httpOnly cookie in cookieManager,
1847         we should reject it. If it has a httpOnly property, we reject it, too.
1848
1849         Test: http/tests/cookies/js-get-and-set-http-only-cookie.php
1850
1851         * platform/blackberry/CookieJarBlackBerry.cpp:
1852         (WebCore::setCookies):
1853         * platform/blackberry/CookieManager.cpp:
1854         (WebCore::CookieManager::setCookies):
1855         (WebCore::CookieManager::shouldRejectNotHttpCookie):
1856         (WebCore):
1857         * platform/blackberry/CookieManager.h:
1858
1859 2012-05-22  Dana Jansens  <danakj@chromium.org>
1860
1861         [chromium] Don't drop children of a RenderSurface from the renderSurfaceLayerList when then position of the surface in its clipRect is not known
1862         https://bugs.webkit.org/show_bug.cgi?id=87181
1863
1864         Reviewed by Adrienne Walker.
1865
1866         We want to avoid dropping things from the renderSurfaceLayerList on main
1867         thread when they may be in the renderSurfaceLayerList on impl thread due
1868         to animation. A render surface would drop all its children if its
1869         contentRect was clipped to become empty by its parent. But when the
1870         surface is being animated, then we can't be sure how its parent will
1871         clip the surface's content, so we don't clip it at all.
1872
1873         Chromium bug: http://crbug.com/128739
1874
1875         Unit test: CCLayerTreeHostCommonTest.verifyClipRectCullsSurfaceWithoutVisibleContent
1876
1877         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
1878         (WebCore::calculateDrawTransformsAndVisibilityInternal):
1879
1880 2012-05-22  Kangil Han  <kangil.han@samsung.com>
1881
1882         [EFL][DRT] Implement touch event
1883         https://bugs.webkit.org/show_bug.cgi?id=86720
1884
1885         Reviewed by Hajime Morita.
1886
1887         Currently EFL DRT doesn't support touch event.
1888         Therefore, this patch enabled it and implemented some eventSender function callbacks.
1889
1890         * platform/PlatformTouchEvent.h:
1891         (PlatformTouchEvent): Implement meta state.
1892         * platform/efl/PlatformTouchEventEfl.cpp:
1893         (WebCore::PlatformTouchEvent::PlatformTouchEvent): Implement meta state.
1894
1895 2012-05-22  Chris Rogers  <crogers@google.com>
1896
1897         AudioNodeOutput::disconnectAllParams() must take care when iterating through its parameter list
1898         https://bugs.webkit.org/show_bug.cgi?id=87190
1899
1900         Reviewed by Kenneth Russell.
1901
1902         No new tests. Covered by existing tests.
1903
1904         * Modules/webaudio/AudioNodeOutput.cpp:
1905         (WebCore::AudioNodeOutput::disconnectAllParams):
1906
1907 2012-05-22  MORITA Hajime  <morrita@google.com>
1908
1909         <shadow> and <content> should be hidden behind ContextEnabledFeatures
1910         https://bugs.webkit.org/show_bug.cgi?id=87063
1911
1912         This change repalces "runtimeConditional" tag definition property
1913         with new "contextConditional" property, which refers
1914         ContextEnabledFeatures instead of RuntimeEnabledFeatures.
1915
1916         Reviewed by Dimitri Glazkov.
1917
1918         No new tests. DRT cannot test this. No behaviour change on DRT.
1919
1920         * dom/make_names.pl:
1921         (defaultTagPropertyHash):
1922         (printConstructorInterior):
1923         (printFactoryCppFile):
1924         (printWrapperFunctions):
1925         (printWrapperFactoryCppFile):
1926         * html/HTMLTagNames.in:
1927
1928 2012-05-22  Kent Tamura  <tkent@chromium.org>
1929
1930         Fix a crash in HTMLFormControlElement::disabled().
1931         https://bugs.webkit.org/show_bug.cgi?id=86534
1932
1933         Reviewed by Hajime Morita.
1934
1935         Node::removedFrom() was not called in some cases. This patch fixes it.
1936
1937         No new tests. It's almost impossible to make a reliable test.
1938
1939         * dom/ContainerNodeAlgorithms.h:
1940         Remove inDocument() check so that Node::removedFrom() is called even if
1941         a parent node in an orphan tree is deleted but a child node remains,
1942
1943 2012-05-22  James Robinson  <jamesr@chromium.org>
1944
1945         Add a Setting to make position:fixed form a new stacking context
1946         https://bugs.webkit.org/show_bug.cgi?id=87186
1947
1948         Reviewed by Adam Barth.
1949
1950         position:fixed elements form a new stacking context in several mobile WebKit ports and in the Qt port always. To
1951         be consistent across devices, we want to try turning it on everywhere. This will likely cause compatibility
1952         issues, so we need a runtime setting in order to stage the change carefully.
1953
1954         Tests: fast/block/positioning/fixed-position-stacking-context.html
1955                fast/block/positioning/fixed-position-stacking-context2.html
1956
1957         * css/StyleResolver.cpp:
1958         (WebCore::StyleResolver::collectMatchingRulesForList):
1959         * page/Settings.cpp:
1960         (WebCore::Settings::Settings):
1961         * page/Settings.h:
1962         (WebCore::Settings::setFixedPositionCreatesStackingContext):
1963         (WebCore::Settings::fixedPositionCreatesStackingContext):
1964         (Settings):
1965         * testing/InternalSettings.cpp:
1966         (WebCore::InternalSettings::InternalSettings):
1967         (WebCore::InternalSettings::restoreTo):
1968         (WebCore::InternalSettings::setFixedPositionCreatesStackingContext):
1969         (WebCore):
1970         * testing/InternalSettings.h:
1971         (InternalSettings):
1972         * testing/InternalSettings.idl:
1973
1974 2012-05-22  Adam Barth  <abarth@webkit.org>
1975
1976         RenderInline::absoluteRects does some incorrect layout math
1977         https://bugs.webkit.org/show_bug.cgi?id=87036
1978
1979         Reviewed by Eric Seidel.
1980
1981         http://trac.webkit.org/changeset/88297/trunk/Source/WebCore/rendering/RenderInline.cpp
1982         contained a typo.  We should accumulate offsets, not add sizes to
1983         offsets.
1984
1985         Test: fast/inline/boundingBox-with-continuation.html
1986
1987         * rendering/RenderInline.cpp:
1988         (WebCore::RenderInline::absoluteRects):
1989         (WebCore):
1990
1991 2012-05-22  Dana Jansens  <danakj@chromium.org>
1992
1993         [chromium] Don't force the visibleLayerRect to be empty for animating layers whose front face is not visible
1994         https://bugs.webkit.org/show_bug.cgi?id=86886
1995
1996         Reviewed by Adrienne Walker.
1997
1998         Previously we would force the visibleLayerRect to be empty for these
1999         animating layers, and then special case the pre-painting code to
2000         paint them if they were within some size limit, to avoid having the
2001         layer steal too much memory.
2002
2003         Instead, just use the visibleLayerRect given to the layer. Since the
2004         transform flips the layer such that its back face is visible, it will
2005         also compute a visibleLayerRect in the front face of the layer, and
2006         its size will be bounded by the viewport. This will cause the
2007         layer to be painted with visible priority instead of prepainted, but
2008         ensures the visible parts of the layer is painted and ready to go when
2009         the animation flips the layer around.
2010
2011         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
2012         (WebCore::calculateVisibleLayerRect):
2013
2014 2012-05-22  Jer Noble  <jer.noble@apple.com>
2015
2016         REGRESSION (r98359): Video does not render on http://panic.com/dietcoda/
2017         https://bugs.webkit.org/show_bug.cgi?id=87171
2018
2019         Reviewed by Maciej Stachowiak.
2020
2021         No new tests; behavior is very timing specific and only occurs on a subset of all platforms.
2022
2023         Instead of calling prepareForRendering() from metadataLoaded(), which may fail and cause subsequent
2024         calls to prepareForRendering() to short circuit, call createVideoLayer() directly, which achieves
2025         the original goals of the fix for http://webkit.org/b/70448, but without breaking subsequent calls
2026         to prepareForRendering() if called at the wrong time.
2027
2028         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2029         (WebCore::MediaPlayerPrivateAVFoundation::metadataLoaded):
2030
2031 2012-05-22  Tim Horton  <timothy_horton@apple.com>
2032
2033         Add a quirk for applications that depend on the relative ordering of progressCompleted/didFinishLoad
2034         https://bugs.webkit.org/show_bug.cgi?id=87178
2035         <rdar://problem/11468434>
2036
2037         Reviewed by Maciej Stachowiak.
2038
2039         Some applications depend on the relative ordering of progressCompleted/didFinishLoad, which was changed
2040         to be more correct in http://trac.webkit.org/changeset/94105. For applications built before 94105, we can
2041         provide the old behavior. For the time being, this will only apply to Mail.app.
2042
2043         No new tests, will not affect behavior for any application except Mail.
2044
2045         * loader/FrameLoader.cpp:
2046         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
2047         * page/Settings.cpp:
2048         (WebCore::Settings::Settings):
2049         * page/Settings.h:
2050         (WebCore::Settings::setNeedsDidFinishLoadOrderQuirk):
2051         (WebCore::Settings::needsDidFinishLoadOrderQuirk):
2052
2053 2012-05-22  Alexis Menard  <alexis.menard@openbossa.org>
2054
2055         Move some CSS regions properties to CSSParser::isValidKeywordPropertyAndValue.
2056         https://bugs.webkit.org/show_bug.cgi?id=87169
2057
2058         Reviewed by Tony Chang.
2059
2060         Move some CSS regions properties to the fast path implemented by
2061         CSSParser::isValidKeywordPropertyAndValue.
2062
2063         No new tests : Existing tests should cover.
2064
2065         * css/CSSParser.cpp:
2066         (WebCore::isValidKeywordPropertyAndValue):
2067         (WebCore::isKeywordPropertyID):
2068         (WebCore::CSSParser::parseValue):
2069
2070 2012-05-22  Emil A Eklund  <eae@chromium.org>
2071
2072         Represents margins as box and simplify writing mode logic
2073         https://bugs.webkit.org/show_bug.cgi?id=86952
2074
2075         Reviewed by Eric Seidel.
2076         
2077         Add a new class, FractionalLayoutBox, that represents the four sides of a
2078         box and change RenderBox to use it to represent margins.
2079
2080         The new box class is intended to be used to represent things like
2081         margins, paddings and borders where the current rect class isn't a good
2082         fit. It also encapsulated a lot of the horizontal/vertical writing mode
2083         and bidi logic allowing it to be reused.
2084
2085         No new tests, no change in functionality.
2086
2087         * CMakeLists.txt:
2088         * GNUmakefile.list.am:
2089         * Target.pri:
2090         * WebCore.gypi:
2091         * WebCore.vcproj/WebCore.vcproj:
2092         * WebCore.xcodeproj/project.pbxproj:
2093         * platform/graphics/FractionalLayoutBoxExtent.cpp: Added.
2094         * platform/graphics/FractionalLayoutBoxExtent.h: Added.
2095         * rendering/LayoutTypes.h:
2096         * rendering/RenderBlock.cpp:
2097         * rendering/RenderBox.cpp:
2098         * rendering/RenderBox.h:
2099         * rendering/RenderScrollbarPart.cpp:
2100         * rendering/RenderScrollbarPart.h:
2101
2102 2012-05-22  Kentaro Hara  <haraken@chromium.org>
2103
2104         [V8] Replace 'throwTypeError(); return Undefined();' with 'return throwTypeError();'
2105         https://bugs.webkit.org/show_bug.cgi?id=87106
2106
2107         Reviewed by Adam Barth.
2108
2109         This patch replaces
2110
2111             throwTypeError();
2112             return v8::Undefined();
2113
2114         with
2115
2116             return throwTypeError();
2117
2118         No tests. No change in behavior.
2119
2120         * bindings/scripts/CodeGeneratorV8.pm:
2121         (GenerateOverloadedFunctionCallback):
2122         (GenerateParametersCheck):
2123         * bindings/scripts/test/V8/V8TestObj.cpp:
2124         (WebCore::TestObjV8Internal::overloadedMethodCallback):
2125         (WebCore::TestObjV8Internal::overloadedMethod1Callback):
2126
2127 2012-05-22  Dan Bernstein  <mitz@apple.com>
2128
2129         REGRESSION (r105513): CSS max-width is not applied to SVG element
2130         https://bugs.webkit.org/show_bug.cgi?id=87050
2131
2132         Reviewed by Darin Adler.
2133
2134         Tests: svg/css/max-height.html
2135                svg/css/max-width.html
2136
2137         * rendering/svg/RenderSVGRoot.cpp:
2138         (WebCore::RenderSVGRoot::computeReplacedLogicalWidth): Changed to also call into the base
2139         class implementation of this function if max-width was specified.
2140         (WebCore::RenderSVGRoot::computeReplacedLogicalHeight): Changed to call into the bas class
2141         implementation of this function if either height or max-height were specified.
2142
2143 2012-05-22  Kentaro Hara  <haraken@chromium.org>
2144
2145         [V8] Pass Isolate to throwTypeError()
2146         https://bugs.webkit.org/show_bug.cgi?id=87111
2147
2148         Reviewed by Adam Barth.
2149
2150         The objective is to pass Isolate around in V8 bindings.
2151         This patch passes Isolate to throwTypeError() in custom bindings.
2152
2153         No tests. No change in behavior.
2154
2155         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
2156         (WebCore::V8ArrayBuffer::constructorCallback):
2157         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
2158         (WebCore::constructWebGLArrayWithArrayBufferArgument):
2159         (WebCore::constructWebGLArray):
2160         * bindings/v8/custom/V8AudioBufferSourceNodeCustom.cpp:
2161         (WebCore::V8AudioBufferSourceNode::bufferAccessorSetter):
2162         * bindings/v8/custom/V8AudioContextCustom.cpp:
2163         (WebCore::V8AudioContext::constructorCallback):
2164         * bindings/v8/custom/V8BlobCustom.cpp:
2165         (WebCore::V8Blob::constructorCallback):
2166         * bindings/v8/custom/V8ClipboardCustom.cpp:
2167         (WebCore::V8Clipboard::setDragImageCallback):
2168         * bindings/v8/custom/V8DOMFormDataCustom.cpp:
2169         (WebCore::V8DOMFormData::constructorCallback):
2170         * bindings/v8/custom/V8DataViewCustom.cpp:
2171         (WebCore::V8DataView::constructorCallback):
2172         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
2173         (WebCore::V8HTMLDocument::openCallback):
2174         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
2175         (WebCore::v8HTMLImageElementConstructorCallback):
2176         * bindings/v8/custom/V8HTMLInputElementCustom.cpp:
2177         (WebCore::V8HTMLInputElement::selectionStartAccessorGetter):
2178         (WebCore::V8HTMLInputElement::selectionStartAccessorSetter):
2179         (WebCore::V8HTMLInputElement::selectionEndAccessorGetter):
2180         (WebCore::V8HTMLInputElement::selectionEndAccessorSetter):
2181         (WebCore::V8HTMLInputElement::selectionDirectionAccessorGetter):
2182         (WebCore::V8HTMLInputElement::selectionDirectionAccessorSetter):
2183         (WebCore::V8HTMLInputElement::setSelectionRangeCallback):
2184         * bindings/v8/custom/V8HTMLMediaElementCustom.cpp:
2185         (WebCore::V8HTMLMediaElement::controllerAccessorSetter):
2186         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
2187         (WebCore::V8InjectedScriptHost::inspectedObjectCallback):
2188         * bindings/v8/custom/V8IntentConstructor.cpp:
2189         (WebCore::V8Intent::constructorCallback):
2190         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
2191         (WebCore::V8MessageChannel::constructorCallback):
2192         * bindings/v8/custom/V8NotificationCenterCustom.cpp:
2193         (WebCore::V8NotificationCenter::requestPermissionCallback):
2194         * bindings/v8/custom/V8SQLResultSetRowListCustom.cpp:
2195         (WebCore::V8SQLResultSetRowList::itemCallback):
2196         * bindings/v8/custom/V8WebKitMutationObserverCustom.cpp:
2197         (WebCore::V8WebKitMutationObserver::constructorCallback):
2198         * bindings/v8/custom/V8WebKitPointConstructor.cpp:
2199         (WebCore::V8WebKitPoint::constructorCallback):
2200         * bindings/v8/custom/V8WebSocketCustom.cpp:
2201         (WebCore::V8WebSocket::constructorCallback):
2202         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
2203         (WebCore::V8XMLHttpRequest::constructorCallback):
2204
2205 2012-05-22  Kentaro Hara  <haraken@chromium.org>
2206
2207         [V8] Replace 'setDOMException(); return Undefined();' with 'return setDOMException();'
2208         https://bugs.webkit.org/show_bug.cgi?id=87102
2209
2210         Reviewed by Adam Barth.
2211
2212         This patch replaces
2213
2214             setDOMException();
2215             return v8::Undefined();
2216
2217         with
2218
2219             return setDOMException();
2220
2221         In addition, just in case, this patch replaces
2222
2223             if (...)
2224                 setDOMException();
2225             return v8::Undefined();
2226
2227         with
2228
2229             if (...)
2230                 return setDOMException();
2231             return v8::Undefined();
2232
2233         because people might insert some code just above
2234         'return v8::Undefined()' in the future.
2235
2236         No tests. No change in behavior.
2237
2238         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
2239         (WebCore::constructWebGLArrayWithArrayBufferArgument):
2240         (WebCore::setWebGLArrayHelper):
2241         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2242         (WebCore::WindowSetTimeoutImpl):
2243         * bindings/v8/custom/V8DataViewCustom.cpp:
2244         (WebCore::V8DataView::getInt8Callback):
2245         (WebCore::V8DataView::getUint8Callback):
2246         (WebCore::V8DataView::setInt8Callback):
2247         (WebCore::V8DataView::setUint8Callback):
2248         * bindings/v8/custom/V8DirectoryEntrySyncCustom.cpp:
2249         (WebCore::V8DirectoryEntrySync::getDirectoryCallback):
2250         (WebCore::V8DirectoryEntrySync::getFileCallback):
2251         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
2252         (WebCore::V8HTMLOptionsCollection::addCallback):
2253         * bindings/v8/custom/V8NodeCustom.cpp:
2254         (WebCore::V8Node::insertBeforeCallback):
2255         (WebCore::V8Node::replaceChildCallback):
2256         (WebCore::V8Node::removeChildCallback):
2257         (WebCore::V8Node::appendChildCallback):
2258         * bindings/v8/custom/V8SVGLengthCustom.cpp:
2259         (WebCore::V8SVGLength::valueAccessorGetter):
2260         (WebCore::V8SVGLength::convertToSpecifiedUnitsCallback):
2261         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
2262         (WebCore::getObjectParameter):
2263         (WebCore::V8WebGLRenderingContext::getFramebufferAttachmentParameterCallback):
2264         (WebCore::V8WebGLRenderingContext::getParameterCallback):
2265         (WebCore::V8WebGLRenderingContext::getProgramParameterCallback):
2266         (WebCore::V8WebGLRenderingContext::getShaderParameterCallback):
2267         (WebCore::V8WebGLRenderingContext::getUniformCallback):
2268         (WebCore::vertexAttribAndUniformHelperf):
2269         (WebCore::uniformHelperi):
2270         (WebCore::uniformMatrixHelper):
2271         * bindings/v8/custom/V8WebKitMutationObserverCustom.cpp:
2272         (WebCore::V8WebKitMutationObserver::observeCallback):
2273         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
2274         (WebCore::V8XMLHttpRequest::responseAccessorGetter):
2275
2276 2012-05-22  Martin Robinson  <mrobinson@igalia.com>
2277
2278         [TextureMapper] [Cairo] Implement repaint counters
2279         https://bugs.webkit.org/show_bug.cgi?id=87062
2280
2281         Reviewed by Gustavo Noronha Silva.
2282
2283         No new tests. This just adds a debugging feature that shouldn't
2284         affect the normal drawing of a page.
2285
2286         * platform/graphics/texmap/TextureMapperLayer.cpp:
2287         (WebCore::TextureMapperLayer::updateBackingStore): Now, if repaint counters are
2288         enabled, increment the repaint count and call drawRepaintCounter.
2289         (WebCore::TextureMapperLayer::drawRepaintCounter): Added.
2290         * platform/graphics/texmap/TextureMapperLayer.h:
2291         (TextureMapperLayer): Added declaration for drawRepaintCounter.
2292
2293 2012-05-22  Simon Fraser  <simon.fraser@apple.com>
2294
2295         Use the same animation begin time while updating compositing layers
2296         https://bugs.webkit.org/show_bug.cgi?id=87080
2297
2298         Reviewed by Dean Jackson.
2299         
2300         Tidied up some beginAnimationUpdate/endAnimationUpdate logic,
2301         but further cleaning is required. We currently bracket some calls
2302         to recaclcStyle() with begin/endAnimationUpdate, but not all.
2303         We don't bracket layout, or compositing updates. This patch
2304         adds bracketing around compositing updates, in order to be
2305         able to add some assertions in a later patch that rely on
2306         RenderLayer::currentTransform() giving consistent results,
2307         since currentTransform() depends on the animation begin time.
2308         
2309         Made AnimationController::beginAnimationUpdate() and
2310         AnimationController::endAnimationUpdate() nestable by adding
2311         a counter.
2312         
2313         Added a stack-based class, AnimationUpdateBlock, which
2314         calls begin/endAnimationUpdate.
2315         
2316         Replaced calls to begin/endAnimationUpdate in Document::updateStyleIfNeeded()
2317         and Document::styleResolverChanged() with AnimationUpdateBlock. Filed a bug
2318         to cover other calls to recalcStyle which might need this (87159).
2319         
2320         Removed a call to beginAnimationUpdate() in Document::implicitOpen(),
2321         which was added in r42415. I believe that r57390 makes this unnecessary,
2322         and was not able to reproduce the original bug after removing it. It
2323         was the only unpaired beginAnimationUpdate call.
2324         
2325         Made AnimationControllerPrivate::getAnimatedStyleForRenderer() not 
2326         use a new beginTime each time it was called, so its beginTime now
2327         depends on some earlier beginAnimationUpdate.
2328         
2329         Fixed CSSComputedStyleDeclaration::getPropertyCSSValue() to use
2330         an AnimationUpdateBlock so that calls to computed style do
2331         use the current time to compute an animating value (as before).
2332
2333         Not testable.
2334
2335         * css/CSSComputedStyleDeclaration.cpp:
2336         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2337         * dom/Document.cpp:
2338         (WebCore::Document::updateStyleIfNeeded):
2339         (WebCore::Document::implicitOpen):
2340         (WebCore::Document::styleResolverChanged):
2341         * page/animation/AnimationController.cpp:
2342         (WebCore::AnimationControllerPrivate::getAnimatedStyleForRenderer):
2343         (WebCore::AnimationController::AnimationController):
2344         (WebCore::AnimationController::beginAnimationUpdate):
2345         (WebCore::AnimationController::endAnimationUpdate):
2346         * page/animation/AnimationController.h:
2347         (AnimationController):
2348         (WebCore):
2349         (AnimationUpdateBlock):
2350         (WebCore::AnimationUpdateBlock::AnimationUpdateBlock):
2351         (WebCore::AnimationUpdateBlock::~AnimationUpdateBlock):
2352         * rendering/RenderLayerCompositor.cpp:
2353         (WebCore::RenderLayerCompositor::updateCompositingLayers):
2354
2355 2012-05-22  Tony Chang  <tony@chromium.org>
2356
2357         REGRESSION(r117613): Dromaeo/jslib-style-prototype regressed by 20%
2358         https://bugs.webkit.org/show_bug.cgi?id=87142
2359
2360         Reviewed by Alexis Menard.
2361
2362         Move CSSPropertyDisplay back into isValidKeywordPropertyAndValue.
2363         Pass in the parser context so we can check whether we're grid or not.
2364
2365         No new tests. Covered by Dromaeo/jslib-style-prototype perf test.
2366
2367         * css/CSSParser.cpp:
2368         (WebCore::isValidKeywordPropertyAndValue):
2369         (WebCore::isKeywordPropertyID):
2370         (WebCore::parseKeywordValue):
2371         (WebCore::CSSParser::parseValue):
2372         (WebCore::CSSParser::parseFont):
2373
2374 == Rolled over to ChangeLog-2012-05-22 ==