[V8] Pass Isolate around in SerializedScriptValue.cpp (Part1)
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-04-24  Kentaro Hara  <haraken@chromium.org>
2
3         [V8] Pass Isolate around in SerializedScriptValue.cpp (Part1)
4         https://bugs.webkit.org/show_bug.cgi?id=84663
5
6         Reviewed by Nate Chapin.
7
8         The objective is to pass Isolate to toV8() in SerializedScriptValue.cpp.
9
10         Part1: Add an Isolate argument to SerializedScriptValue::create(),
11         SerializedScriptValue::deserialize(), etc.
12         Part2: Add an m_isolate member to SerializedScriptValue::Writer()
13         and SerializedScriptValue::Reader().
14         Part3: Pass Isolate to toV8().
15
16         This patch fixes Part1.
17
18         No tests. No change in behavior.
19
20         * bindings/v8/SerializedScriptValue.cpp:
21         (WebCore::SerializedScriptValue::create):
22         (WebCore::SerializedScriptValue::undefinedValue):
23         (WebCore::SerializedScriptValue::booleanValue):
24         (WebCore::SerializedScriptValue::numberValue):
25         (WebCore::SerializedScriptValue::SerializedScriptValue):
26         (WebCore::SerializedScriptValue::deserialize):
27         (WebCore::SerializedScriptValue::deserializeForInspector):
28         * bindings/v8/SerializedScriptValue.h:
29         (SerializedScriptValue):
30
31 2012-04-24  Kentaro Hara  <haraken@chromium.org>
32
33         [V8][Refactoring] Remove deserializeAndSetProperty()
34         from SerializedScriptValue.cpp
35         https://bugs.webkit.org/show_bug.cgi?id=84662
36
37         Reviewed by Nate Chapin.
38
39         SerializedScriptValue::deserializeAndSetProperty() is no
40         longer used. This patch removes it.
41
42         No tests. No change in behavior.
43
44         * bindings/v8/SerializedScriptValue.cpp:
45         * bindings/v8/SerializedScriptValue.h:
46
47 2012-04-24  Kentaro Hara  <haraken@chromium.org>
48
49         [V8] Pass Isolate to setDOMException() in CodeGeneratorV8.pm
50         https://bugs.webkit.org/show_bug.cgi?id=84660
51
52         Reviewed by Nate Chapin.
53
54         The objective is to pass Isolate around in V8 bindings.
55         This patch passes Isolate to setDOMException() in CodeGeneratorV8.pm.
56
57         Test: bindings/scripts/test/TestEventTarget.idl
58               bindings/scripts/test/TestObj.idl
59               bindings/scripts/test/TestInterface.idl
60
61         * bindings/scripts/CodeGeneratorV8.pm: Modified as described above.
62         (GenerateSetDOMException):
63         (GenerateNormalAttrGetter):
64         (GenerateNormalAttrSetter):
65         (GenerateFunctionCallback):
66         (GenerateParametersCheck):
67         (GenerateFunctionCallString):
68
69         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
70         Updated run-bindings-tests results.
71         (WebCore::TestEventTargetV8Internal::itemCallback):
72         (WebCore::TestEventTargetV8Internal::dispatchEventCallback):
73         * bindings/scripts/test/V8/V8TestInterface.cpp: Ditto.
74         (WebCore::TestInterfaceV8Internal::supplementalMethod2Callback):
75         * bindings/scripts/test/V8/V8TestObj.cpp: Ditto.
76         (WebCore::TestObjV8Internal::attrWithGetterExceptionAttrGetter):
77         (WebCore::TestObjV8Internal::attrWithGetterExceptionAttrSetter):
78         (WebCore::TestObjV8Internal::attrWithSetterExceptionAttrSetter):
79         (WebCore::TestObjV8Internal::stringAttrWithGetterExceptionAttrGetter):
80         (WebCore::TestObjV8Internal::stringAttrWithGetterExceptionAttrSetter):
81         (WebCore::TestObjV8Internal::stringAttrWithSetterExceptionAttrSetter):
82         (WebCore::TestObjV8Internal::withScriptStateAttributeRaisesAttrGetter):
83         (WebCore::TestObjV8Internal::withScriptStateAttributeRaisesAttrSetter):
84         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeRaisesAttrGetter):
85         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeRaisesAttrSetter):
86         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeRaisesAttrGetter):
87         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeRaisesAttrSetter):
88         (WebCore::TestObjV8Internal::methodThatRequiresAllArgsAndThrowsCallback):
89         (WebCore::TestObjV8Internal::methodWithExceptionCallback):
90         (WebCore::TestObjV8Internal::withScriptStateVoidExceptionCallback):
91         (WebCore::TestObjV8Internal::withScriptStateObjExceptionCallback):
92         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateObjExceptionCallback):
93         (WebCore::TestObjV8Internal::getSVGDocumentCallback):
94         (WebCore::TestObjV8Internal::strictFunctionCallback):
95
96 2012-04-24  Kentaro Hara  <haraken@chromium.org>
97
98         [V8] Pass Isolate to setDOMException() (Part2)
99         https://bugs.webkit.org/show_bug.cgi?id=84658
100
101         Reviewed by Nate Chapin.
102
103         The objective is to pass Isolate around in V8 bindings.
104         This patch passes Isolate to setDOMException() in custom
105         binding code.
106
107         No tests. No change in behavior.
108
109         * bindings/v8/V8Collection.cpp:
110         (WebCore::toOptionsCollectionSetter):
111         * bindings/v8/V8Collection.h:
112         (WebCore):
113         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
114         (WebCore::constructWebGLArrayWithArrayBufferArgument):
115         (WebCore::setWebGLArrayHelper):
116         * bindings/v8/custom/V8DOMWindowCustom.cpp:
117         (WebCore::WindowSetTimeoutImpl):
118         * bindings/v8/custom/V8DataViewCustom.cpp:
119         (WebCore::V8DataView::getInt8Callback):
120         (WebCore::V8DataView::getUint8Callback):
121         (WebCore::V8DataView::setInt8Callback):
122         (WebCore::V8DataView::setUint8Callback):
123         * bindings/v8/custom/V8DirectoryEntrySyncCustom.cpp:
124         (WebCore::V8DirectoryEntrySync::getDirectoryCallback):
125         (WebCore::V8DirectoryEntrySync::getFileCallback):
126         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
127         (WebCore::V8HTMLCanvasElement::toDataURLCallback):
128         * bindings/v8/custom/V8HTMLElementCustom.cpp:
129         (WebCore::V8HTMLElement::itemValueAccessorSetter):
130         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
131         (WebCore::V8HTMLOptionsCollection::addCallback):
132         (WebCore::V8HTMLOptionsCollection::lengthAccessorSetter):
133         (WebCore::V8HTMLOptionsCollection::indexedPropertySetter):
134         * bindings/v8/custom/V8HTMLSelectElementCustom.cpp:
135         (WebCore::V8HTMLSelectElement::indexedPropertySetter):
136         * bindings/v8/custom/V8NodeCustom.cpp:
137         (WebCore::V8Node::insertBeforeCallback):
138         (WebCore::V8Node::replaceChildCallback):
139         (WebCore::V8Node::removeChildCallback):
140         (WebCore::V8Node::appendChildCallback):
141         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
142         (WebCore::V8SQLTransaction::executeSqlCallback):
143         * bindings/v8/custom/V8WebKitMutationObserverCustom.cpp:
144         (WebCore::V8WebKitMutationObserver::observeCallback):
145         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
146         (WebCore::V8XMLHttpRequest::responseAccessorGetter):
147
148 2012-04-24  Kentaro Hara  <haraken@chromium.org>
149
150         [V8] Pass Isolate to setDOMException() (Part1)
151         https://bugs.webkit.org/show_bug.cgi?id=84656
152
153         Reviewed by Nate Chapin.
154
155         The objective is to pass Isolate around in V8 bindings.
156         This patch passes Isolate to setDOMException() in custom binding code.
157
158         No tests. No change in behavior.
159
160         * bindings/v8/custom/V8LocationCustom.cpp:
161         (WebCore::V8Location::protocolAccessorSetter):
162         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
163         (WebCore::V8SQLTransactionSync::executeSqlCallback):
164         * bindings/v8/custom/V8SVGLengthCustom.cpp:
165         (WebCore::V8SVGLength::valueAccessorGetter):
166         (WebCore::V8SVGLength::valueAccessorSetter):
167         (WebCore::V8SVGLength::convertToSpecifiedUnitsCallback):
168         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
169         (WebCore::getObjectParameter):
170         (WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
171         (WebCore::V8WebGLRenderingContext::getExtensionCallback):
172         (WebCore::V8WebGLRenderingContext::getFramebufferAttachmentParameterCallback):
173         (WebCore::V8WebGLRenderingContext::getParameterCallback):
174         (WebCore::V8WebGLRenderingContext::getProgramParameterCallback):
175         (WebCore::V8WebGLRenderingContext::getShaderParameterCallback):
176         (WebCore::V8WebGLRenderingContext::getUniformCallback):
177         (WebCore::vertexAttribAndUniformHelperf):
178         (WebCore::uniformHelperi):
179         (WebCore::uniformMatrixHelper):
180
181 2012-04-24  Pavel Feldman  <pfeldman@chromium.org>
182
183         Web Inspector: encapsulate live location into the Script.
184         https://bugs.webkit.org/show_bug.cgi?id=84722
185
186         Reviewed by Yury Semikhatsky.
187
188         Live location is just a location on the script. The way it is implemented today involves too many indirections.
189
190         * inspector/front-end/CompilerScriptMapping.js:
191         * inspector/front-end/DebuggerModel.js:
192         (WebInspector.DebuggerModel.prototype.setBreakpointByScriptLocation):
193         (WebInspector.DebuggerModel.prototype.scriptForId):
194         * inspector/front-end/DebuggerPresentationModel.js:
195         (WebInspector.DebuggerPresentationModel.prototype.createLiveLocation):
196         (WebInspector.DebuggerPresentationModel.prototype._addConsoleMessageToScript):
197         (WebInspector.DebuggerPresentationModel.prototype._debuggerPaused):
198         (WebInspector.DebuggerPresentationModel.prototype.set selectedCallFrame):
199         (WebInspector.PresentationCallFrame.prototype.uiLocation):
200         (WebInspector.DebuggerPresentationModel.CallFramePlacard):
201         (WebInspector.DebuggerPresentationModel.Linkifier.prototype.linkifyRawLocation):
202         * inspector/front-end/RawSourceCode.js:
203         * inspector/front-end/ResourceScriptMapping.js:
204         (WebInspector.ResourceScriptMapping.prototype.addScript):
205         (WebInspector.ResourceScriptMapping.prototype._uiSourceCodeChanged):
206         (WebInspector.ResourceScriptMapping.prototype._bindScriptToRawSourceCode):
207         * inspector/front-end/Script.js:
208         (WebInspector.Script):
209         (WebInspector.Script.prototype.isInlineScript):
210         (WebInspector.Script.prototype.setSourceMapping):
211         (WebInspector.Script.prototype.createLocation):
212         (WebInspector.Script.Location):
213         (WebInspector.Script.Location.prototype.dispose):
214         (WebInspector.Script.Location.prototype._update):
215         * inspector/front-end/ScriptMapping.js:
216         (WebInspector.UILocation):
217         (WebInspector.SourceMapping):
218         (WebInspector.SourceMapping.prototype.rawLocationToUILocation):
219         (WebInspector.SourceMapping.prototype.uiLocationToRawLocation):
220         (WebInspector.MainScriptMapping):
221         (WebInspector.MainScriptMapping.prototype.addScript):
222         (WebInspector.MainScriptMapping.prototype.reset):
223         * inspector/front-end/SnippetsModel.js:
224         (WebInspector.SnippetsScriptMapping.prototype._createUISourceCodeForScript):
225
226 2012-04-24  Yury Semikhatsky  <yurys@chromium.org>
227
228         Web Inspector: a bunch of heap profiler cleanups
229         https://bugs.webkit.org/show_bug.cgi?id=84730
230
231         - HeapSnapshotProviderProxy passed explicitely as a parameter to HeapSnapshotGridNode
232         constructor
233         - Removed dead code
234         - Removed unused parameters
235         - Added more closure compiler annotations
236         - Extracted code finding cycled among node ancestors into a separate method
237
238         Reviewed by Pavel Feldman.
239
240         * inspector/front-end/HeapSnapshot.js:
241         (WebInspector.HeapSnapshot.prototype.createEdgesProvider):
242         (WebInspector.HeapSnapshot.prototype.createRetainingEdgesProvider):
243         (WebInspector.HeapSnapshot.prototype.createNodesProviderForDominator):
244         (WebInspector.HeapSnapshotEdgesProvider):
245         * inspector/front-end/HeapSnapshotDataGrids.js:
246         * inspector/front-end/HeapSnapshotGridNodes.js:
247         (WebInspector.HeapSnapshotGridNode):
248         (WebInspector.HeapSnapshotGenericObjectNode):
249         (WebInspector.HeapSnapshotObjectNode):
250         (WebInspector.HeapSnapshotObjectNode.prototype._findAncestorWithSameSnapshotNodeId):
251         (WebInspector.HeapSnapshotInstanceNode):
252         (WebInspector.HeapSnapshotConstructorNode):
253         (WebInspector.HeapSnapshotDiffNode):
254         (WebInspector.HeapSnapshotDiffNode._createProvider):
255         (WebInspector.HeapSnapshotDominatorObjectNode):
256         * inspector/front-end/HeapSnapshotProxy.js:
257         (WebInspector.HeapSnapshotWorker):
258         (WebInspector.HeapSnapshotProxy.prototype.createNodesProviderForDominator):
259         * inspector/front-end/utilities.js:
260
261 2012-04-24  Adam Klein  <adamk@chromium.org>
262
263         Fix includes in StrongInlines.h and ScriptValue.h
264         https://bugs.webkit.org/show_bug.cgi?id=84659
265
266         Reviewed by Geoffrey Garen.
267
268         This change was prompted by an attempt to use ScriptValue.h from a
269         WebCore header file and running into trouble with the (as it turns out
270         unnecessary) include of JSDOMBinding.h.
271
272         * bindings/js/ScriptValue.cpp: Add include of JSDOMBinding.h, now that
273         it's not included by the header.
274         * bindings/js/ScriptValue.h: Remove unnecessary include of JSDOMBinding.h.
275
276 2012-04-24  Antti Koivisto  <antti@apple.com>
277
278         Move MediaList CSSOM wrapper ownership to parent rule or stylesheet
279         https://bugs.webkit.org/show_bug.cgi?id=84716
280
281         Reviewed by Anders Carlsson.
282
283         MediaList CSSOM wrapper should be owned by a rule or a stylesheet, not by the underlying 
284         MediaQuerySet.
285         
286         Remove the ref forwarding from MediaList in favor of regular refcounting. Use the usual
287         pattern where the parent wrapper refs the child wrapper and zeroes the backpointer
288         on destruction. 
289
290         * bindings/js/JSDOMBinding.h:
291         (WebCore::root):
292         * css/CSSImportRule.cpp:
293         (WebCore::CSSImportRule::~CSSImportRule):
294         (WebCore::CSSImportRule::media):
295         * css/CSSImportRule.h:
296         (StyleRuleImport):
297         (CSSImportRule):
298         * css/CSSMediaRule.cpp:
299         (WebCore::CSSMediaRule::~CSSMediaRule):
300         (WebCore::CSSMediaRule::media):
301         * css/CSSMediaRule.h:
302         (CSSMediaRule):
303         * css/CSSStyleSheet.cpp:
304         (WebCore::CSSStyleSheet::~CSSStyleSheet):
305         (WebCore::CSSStyleSheet::media):
306         * css/CSSStyleSheet.h:
307         (CSSStyleSheet):
308         * css/MediaList.cpp:
309         (WebCore::MediaQuerySet::mediaText):
310         (WebCore::MediaList::MediaList):
311         (WebCore):
312         (WebCore::MediaList::notifyChanged):
313         * css/MediaList.h:
314         (MediaQuerySet):
315         (WebCore::MediaList::create):
316         (WebCore::MediaList::parentRule):
317         (WebCore::MediaList::clearParentStyleSheet):
318         (WebCore::MediaList::clearParentRule):
319         (WebCore::MediaList::queries):
320         (MediaList):
321         * css/StyleRule.h:
322         (WebCore::StyleRuleMedia::mediaQueries):
323
324 2012-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
325
326         [GTK] Should pass canvas/philip/tests/toDataURL.jpeg.alpha.html
327         https://bugs.webkit.org/show_bug.cgi?id=83973
328
329         Reviewed by Philippe Normand.
330
331         Test: canvas/philip/tests/toDataURL.jpeg.alpha.html
332
333         * platform/graphics/gtk/ImageBufferGtk.cpp:
334         (WebCore::encodeImage): Convert ARGB32 cairo surface into RGB24
335         when encoding JPEG images since JPEG encoder doesn't support alpha
336         channel.
337
338 2012-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
339
340         [GTK] Add WebKitCookieManager::changed signal to WebKit2 GTK+ API
341         https://bugs.webkit.org/show_bug.cgi?id=82598
342
343         Reviewed by Philippe Normand.
344
345         * GNUmakefile.list.am: Add new files to compilation.
346         * platform/gtk/TemporaryLinkStubs.cpp: Remove stubs for
347         setCookieStoragePrivateBrowsingEnabled,
348         startObservingCookieChanges and stopObservingCookieChanges.
349         * platform/network/soup/CookieStorageSoup.cpp: Added.
350         (WebCore::setCookieStoragePrivateBrowsingEnabled):
351         (WebCore::soupCookiesChanged): Notify cookies changes using
352         platform strategies.
353         (WebCore::startObservingCookieChanges): Connect to changed signal
354         of the soup cookie jar.
355         (WebCore::stopObservingCookieChanges): Disconnect signals handlers
356         for changed signals of the soup cookie jar.
357
358 2012-04-24  Alexis Menard  <alexis.menard@openbossa.org>
359
360         Rename CSSStyleApplyProperty files to StyleBuilder.
361         https://bugs.webkit.org/show_bug.cgi?id=84721
362
363         Reviewed by Antti Koivisto.
364
365         r115043 renamed CSSStyleApplyProperty class to StyleBuilder. This
366         patch rename the files to match the new class name.
367
368         No new tests : renaming of files, no behavior changes expected.
369
370         * CMakeLists.txt:
371         * GNUmakefile.list.am:
372         * Target.pri:
373         * WebCore.gypi:
374         * WebCore.vcproj/WebCore.vcproj:
375         * WebCore.xcodeproj/project.pbxproj:
376         * css/CSSAllInOne.cpp:
377         * css/CSSStyleSelector.cpp:
378         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
379         * css/StyleBuilder.cpp: Renamed from Source/WebCore/css/CSSStyleApplyProperty.cpp.
380         (WebCore):
381         (ApplyPropertyExpanding):
382         (WebCore::ApplyPropertyExpanding::applyInheritValue):
383         (WebCore::ApplyPropertyExpanding::applyInitialValue):
384         (WebCore::ApplyPropertyExpanding::applyValue):
385         (WebCore::ApplyPropertyExpanding::createHandler):
386         (ApplyPropertyDefaultBase):
387         (WebCore::ApplyPropertyDefaultBase::setValue):
388         (WebCore::ApplyPropertyDefaultBase::value):
389         (WebCore::ApplyPropertyDefaultBase::initial):
390         (WebCore::ApplyPropertyDefaultBase::applyInheritValue):
391         (WebCore::ApplyPropertyDefaultBase::applyInitialValue):
392         (WebCore::ApplyPropertyDefaultBase::applyValue):
393         (WebCore::ApplyPropertyDefaultBase::createHandler):
394         (ApplyPropertyDefault):
395         (WebCore::ApplyPropertyDefault::setValue):
396         (WebCore::ApplyPropertyDefault::applyValue):
397         (WebCore::ApplyPropertyDefault::createHandler):
398         (ApplyPropertyNumber):
399         (WebCore::ApplyPropertyNumber::setValue):
400         (WebCore::ApplyPropertyNumber::applyValue):
401         (WebCore::ApplyPropertyNumber::createHandler):
402         (ApplyPropertyStyleImage):
403         (WebCore::ApplyPropertyStyleImage::applyValue):
404         (WebCore::ApplyPropertyStyleImage::createHandler):
405         (ApplyPropertyAuto):
406         (WebCore::ApplyPropertyAuto::setValue):
407         (WebCore::ApplyPropertyAuto::value):
408         (WebCore::ApplyPropertyAuto::hasAuto):
409         (WebCore::ApplyPropertyAuto::setAuto):
410         (WebCore::ApplyPropertyAuto::applyInheritValue):
411         (WebCore::ApplyPropertyAuto::applyInitialValue):
412         (WebCore::ApplyPropertyAuto::applyValue):
413         (WebCore::ApplyPropertyAuto::createHandler):
414         (ApplyPropertyClip):
415         (WebCore::ApplyPropertyClip::convertToLength):
416         (WebCore::ApplyPropertyClip::applyInheritValue):
417         (WebCore::ApplyPropertyClip::applyInitialValue):
418         (WebCore::ApplyPropertyClip::applyValue):
419         (WebCore::ApplyPropertyClip::createHandler):
420         (WebCore::defaultInitialColor):
421         (ApplyPropertyColor):
422         (WebCore::ApplyPropertyColor::applyInheritValue):
423         (WebCore::ApplyPropertyColor::applyInitialValue):
424         (WebCore::ApplyPropertyColor::applyValue):
425         (WebCore::ApplyPropertyColor::applyColorValue):
426         (WebCore::ApplyPropertyColor::createHandler):
427         (ApplyPropertyDirection):
428         (WebCore::ApplyPropertyDirection::applyValue):
429         (WebCore::ApplyPropertyDirection::createHandler):
430         (ApplyPropertyLength):
431         (WebCore::ApplyPropertyLength::setValue):
432         (WebCore::ApplyPropertyLength::applyValue):
433         (WebCore::ApplyPropertyLength::createHandler):
434         (ApplyPropertyString):
435         (WebCore::ApplyPropertyString::setValue):
436         (WebCore::ApplyPropertyString::applyValue):
437         (WebCore::ApplyPropertyString::createHandler):
438         (ApplyPropertyBorderRadius):
439         (WebCore::ApplyPropertyBorderRadius::setValue):
440         (WebCore::ApplyPropertyBorderRadius::applyValue):
441         (WebCore::ApplyPropertyBorderRadius::createHandler):
442         (FillLayerAccessorTypes):
443         (ApplyPropertyFillLayer):
444         (WebCore::ApplyPropertyFillLayer::applyInheritValue):
445         (WebCore::ApplyPropertyFillLayer::applyInitialValue):
446         (WebCore::ApplyPropertyFillLayer::applyValue):
447         (WebCore::ApplyPropertyFillLayer::createHandler):
448         (ApplyPropertyComputeLength):
449         (WebCore::ApplyPropertyComputeLength::setValue):
450         (WebCore::ApplyPropertyComputeLength::applyValue):
451         (WebCore::ApplyPropertyComputeLength::createHandler):
452         (ApplyPropertyFont):
453         (WebCore::ApplyPropertyFont::applyInheritValue):
454         (WebCore::ApplyPropertyFont::applyInitialValue):
455         (WebCore::ApplyPropertyFont::applyValue):
456         (WebCore::ApplyPropertyFont::createHandler):
457         (ApplyPropertyFontSize):
458         (WebCore::ApplyPropertyFontSize::largerFontSize):
459         (WebCore::ApplyPropertyFontSize::smallerFontSize):
460         (WebCore::ApplyPropertyFontSize::applyInheritValue):
461         (WebCore::ApplyPropertyFontSize::applyInitialValue):
462         (WebCore::ApplyPropertyFontSize::applyValue):
463         (WebCore::ApplyPropertyFontSize::createHandler):
464         (ApplyPropertyFontWeight):
465         (WebCore::ApplyPropertyFontWeight::applyValue):
466         (WebCore::ApplyPropertyFontWeight::createHandler):
467         (ApplyPropertyFontVariantLigatures):
468         (WebCore::ApplyPropertyFontVariantLigatures::applyInheritValue):
469         (WebCore::ApplyPropertyFontVariantLigatures::applyInitialValue):
470         (WebCore::ApplyPropertyFontVariantLigatures::applyValue):
471         (WebCore::ApplyPropertyFontVariantLigatures::createHandler):
472         (ApplyPropertyBorderImage):
473         (WebCore::ApplyPropertyBorderImage::applyValue):
474         (WebCore::ApplyPropertyBorderImage::createHandler):
475         (ApplyPropertyBorderImageModifier):
476         (WebCore::ApplyPropertyBorderImageModifier::getValue):
477         (WebCore::ApplyPropertyBorderImageModifier::setValue):
478         (WebCore::ApplyPropertyBorderImageModifier::applyInheritValue):
479         (WebCore::ApplyPropertyBorderImageModifier::applyInitialValue):
480         (WebCore::ApplyPropertyBorderImageModifier::applyValue):
481         (WebCore::ApplyPropertyBorderImageModifier::createHandler):
482         (ApplyPropertyBorderImageSource):
483         (WebCore::ApplyPropertyBorderImageSource::applyValue):
484         (WebCore::ApplyPropertyBorderImageSource::createHandler):
485         (ApplyPropertyCounter):
486         (WebCore::ApplyPropertyCounter::emptyFunction):
487         (WebCore::ApplyPropertyCounter::applyInheritValue):
488         (WebCore::ApplyPropertyCounter::applyValue):
489         (WebCore::ApplyPropertyCounter::createHandler):
490         (ApplyPropertyCursor):
491         (WebCore::ApplyPropertyCursor::applyInheritValue):
492         (WebCore::ApplyPropertyCursor::applyInitialValue):
493         (WebCore::ApplyPropertyCursor::applyValue):
494         (WebCore::ApplyPropertyCursor::createHandler):
495         (ApplyPropertyTextAlign):
496         (WebCore::ApplyPropertyTextAlign::applyValue):
497         (WebCore::ApplyPropertyTextAlign::createHandler):
498         (ApplyPropertyTextDecoration):
499         (WebCore::ApplyPropertyTextDecoration::applyValue):
500         (WebCore::ApplyPropertyTextDecoration::createHandler):
501         (ApplyPropertyUnicodeBidi):
502         (WebCore::ApplyPropertyUnicodeBidi::applyValue):
503         (WebCore::ApplyPropertyUnicodeBidi::createHandler):
504         (ApplyPropertyLineHeight):
505         (WebCore::ApplyPropertyLineHeight::applyValue):
506         (WebCore::ApplyPropertyLineHeight::createHandler):
507         (ApplyPropertyPageSize):
508         (WebCore::ApplyPropertyPageSize::mmLength):
509         (WebCore::ApplyPropertyPageSize::inchLength):
510         (WebCore::ApplyPropertyPageSize::getPageSizeFromName):
511         (WebCore::ApplyPropertyPageSize::applyInheritValue):
512         (WebCore::ApplyPropertyPageSize::applyInitialValue):
513         (WebCore::ApplyPropertyPageSize::applyValue):
514         (WebCore::ApplyPropertyPageSize::createHandler):
515         (ApplyPropertyTextEmphasisStyle):
516         (WebCore::ApplyPropertyTextEmphasisStyle::applyInheritValue):
517         (WebCore::ApplyPropertyTextEmphasisStyle::applyInitialValue):
518         (WebCore::ApplyPropertyTextEmphasisStyle::applyValue):
519         (WebCore::ApplyPropertyTextEmphasisStyle::createHandler):
520         (ApplyPropertyAnimation):
521         (WebCore::ApplyPropertyAnimation::setValue):
522         (WebCore::ApplyPropertyAnimation::value):
523         (WebCore::ApplyPropertyAnimation::test):
524         (WebCore::ApplyPropertyAnimation::clear):
525         (WebCore::ApplyPropertyAnimation::initial):
526         (WebCore::ApplyPropertyAnimation::map):
527         (WebCore::ApplyPropertyAnimation::accessAnimations):
528         (WebCore::ApplyPropertyAnimation::animations):
529         (WebCore::ApplyPropertyAnimation::applyInheritValue):
530         (WebCore::ApplyPropertyAnimation::applyInitialValue):
531         (WebCore::ApplyPropertyAnimation::applyValue):
532         (WebCore::ApplyPropertyAnimation::createHandler):
533         (ApplyPropertyOutlineStyle):
534         (WebCore::ApplyPropertyOutlineStyle::applyInheritValue):
535         (WebCore::ApplyPropertyOutlineStyle::applyInitialValue):
536         (WebCore::ApplyPropertyOutlineStyle::applyValue):
537         (WebCore::ApplyPropertyOutlineStyle::createHandler):
538         (ApplyPropertyResize):
539         (WebCore::ApplyPropertyResize::applyValue):
540         (WebCore::ApplyPropertyResize::createHandler):
541         (ApplyPropertyVerticalAlign):
542         (WebCore::ApplyPropertyVerticalAlign::applyValue):
543         (WebCore::ApplyPropertyVerticalAlign::createHandler):
544         (ApplyPropertyAspectRatio):
545         (WebCore::ApplyPropertyAspectRatio::applyInheritValue):
546         (WebCore::ApplyPropertyAspectRatio::applyInitialValue):
547         (WebCore::ApplyPropertyAspectRatio::applyValue):
548         (WebCore::ApplyPropertyAspectRatio::createHandler):
549         (ApplyPropertyZoom):
550         (WebCore::ApplyPropertyZoom::resetEffectiveZoom):
551         (WebCore::ApplyPropertyZoom::applyInheritValue):
552         (WebCore::ApplyPropertyZoom::applyInitialValue):
553         (WebCore::ApplyPropertyZoom::applyValue):
554         (WebCore::ApplyPropertyZoom::createHandler):
555         (ApplyPropertyDisplay):
556         (WebCore::ApplyPropertyDisplay::isValidDisplayValue):
557         (WebCore::ApplyPropertyDisplay::applyInheritValue):
558         (WebCore::ApplyPropertyDisplay::applyInitialValue):
559         (WebCore::ApplyPropertyDisplay::applyValue):
560         (WebCore::ApplyPropertyDisplay::createHandler):
561         (ApplyPropertyFlex):
562         (WebCore::ApplyPropertyFlex::applyInheritValue):
563         (WebCore::ApplyPropertyFlex::applyInitialValue):
564         (WebCore::ApplyPropertyFlex::applyValue):
565         (WebCore::ApplyPropertyFlex::createHandler):
566         (WebCore::ApplyPropertyFlex::getFlexValue):
567         (WebCore::StyleBuilder::sharedStyleBuilder):
568         (WebCore::StyleBuilder::StyleBuilder):
569         * css/StyleBuilder.h: Renamed from Source/WebCore/css/CSSStyleApplyProperty.h.
570         (WebCore):
571         (PropertyHandler):
572         (WebCore::PropertyHandler::PropertyHandler):
573         (WebCore::PropertyHandler::applyInheritValue):
574         (WebCore::PropertyHandler::applyInitialValue):
575         (WebCore::PropertyHandler::applyValue):
576         (WebCore::PropertyHandler::isValid):
577         (WebCore::PropertyHandler::inheritFunction):
578         (WebCore::PropertyHandler::initialFunction):
579         (WebCore::PropertyHandler::applyFunction):
580         (StyleBuilder):
581         (WebCore::StyleBuilder::propertyHandler):
582         (WebCore::StyleBuilder::index):
583         (WebCore::StyleBuilder::valid):
584         (WebCore::StyleBuilder::setPropertyHandler):
585
586 2012-04-24  Florin Malita  <fmalita@chromium.org>
587
588         WebCore::EventTarget::addEventListener crash
589         https://bugs.webkit.org/show_bug.cgi?id=84171
590
591         Reviewed by Nikolas Zimmermann.
592
593         Test: svg/custom/use-tref-crash.svg
594
595         Adding tref target event listeners while building the shadow tree is
596         problematic, because SVGUseElement::buildShadowAndInstanceTree() only
597         sets the element instance<->shadow element association at a later time.
598
599         Fortunately, buildShadowAndInstanceTree() also propagates the event
600         handlers (transferEventListenersToShadowTree) - so we can simply skip
601         them in SVGTRefElement::buildPendingResource() for shadow elements.
602
603         * svg/SVGTRefElement.cpp:
604         (WebCore::SVGTRefElement::buildPendingResource):
605
606 2012-04-24  Kent Tamura  <tkent@chromium.org>
607
608         Clickable area of a calendar picker indicator is too small.
609         https://bugs.webkit.org/show_bug.cgi?id=84677
610
611         Reviewed by Kentaro Hara.
612
613         Test: fast/forms/date/date-appearance.html is affected.
614
615         * css/html.css:
616         (input::-webkit-calendar-picker-indicator):
617         - Remove unnecessary disaplay:inline-block.
618         - Add paddings instead of the margin.
619         (input::-webkit-calendar-picker-indicator:hover):
620         Add hover style.
621
622 2012-04-24  Alexis Menard  <alexis.menard@openbossa.org>
623
624         Another unreviewed build fix for Mac.
625
626         * css/CSSStyleSelector.h:
627         (CSSStyleSelector):
628
629 2012-04-24  Alexis Menard  <alexis.menard@openbossa.org>
630
631         Unreviewed build fix attempt for Mac.
632
633         * rendering/style/RenderStyle.h:
634
635 2012-04-24  Alexis Menard  <alexis.menard@openbossa.org>
636
637         Rename CSSStyleApplyProperty class to StyleBuilder.
638         https://bugs.webkit.org/show_bug.cgi?id=84711
639
640         Reviewed by Antti Koivisto.
641
642         As per discussion on bug https://bugs.webkit.org/show_bug.cgi?id=42764
643         the name is a bit confusing. This first patch rename the class and a
644         following one will rename the files. We also drop the CSS prefix of the
645         class to keep CSS prefixed classes for CSSOM types.
646
647         No new tests : renaming, no behavior changes should appear.
648
649         * css/CSSStyleApplyProperty.cpp:
650         (WebCore::ApplyPropertyExpanding::applyInheritValue):
651         (WebCore::ApplyPropertyExpanding::applyInitialValue):
652         (WebCore::ApplyPropertyExpanding::applyValue):
653         (WebCore::StyleBuilder::sharedStyleBuilder):
654         (WebCore::StyleBuilder::StyleBuilder):
655         * css/CSSStyleApplyProperty.h:
656         (WebCore):
657         (StyleBuilder):
658         * css/CSSStyleSelector.cpp:
659         (WebCore::CSSStyleSelector::CSSStyleSelector):
660         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
661         * css/CSSStyleSelector.h:
662         (CSSStyleSelector):
663
664 2012-04-24  Kent Tamura  <tkent@chromium.org>
665
666         Merge LocalizedCalendar into LocalizedDate
667         https://bugs.webkit.org/show_bug.cgi?id=84685
668
669         Reviewed by Kentaro Hara.
670
671         The functionality of LocalizedCalendar is very related to
672         LocalizedDate. We should merge them.
673
674         No new tests. Just refactoring.
675
676         * WebCore.gypi: Remove LocalizedCalendar.h and LocalizedCalenderICU.cpp.
677         * html/shadow/CalendarPickerElement.cpp:
678         Include LocalizedDate.h instead of LocalizedCalendar.h.
679         * platform/text/LocalizedCalendar.h:
680         Removed. Merged into LocalizedDate.h.
681         * platform/text/LocalizedCalendarICU.cpp:
682         Removed. Merged into LocalizedDateICU.h.
683         * platform/text/LocalizedDate.h:
684         (WebCore): Move some functions from LocalizedCalendar.h.
685         * platform/text/LocalizedDateICU.cpp:
686         Move some functions from LocalizedCalendarICU.cpp.
687
688 2012-04-24  Pavel Feldman  <pfeldman@chromium.org>
689
690         Web Inspector: remove pure delegation code from DebuggerPresentationModel
691         https://bugs.webkit.org/show_bug.cgi?id=84704
692
693         Reviewed by Yury Semikhatsky.
694
695         This change removes the code that delegates calls to breakpoint manager and exposes the breakpoint
696         manager in debugger presentation model itself. It allows narrowing dpm dependencies.
697
698         * inspector/front-end/BreakpointsSidebarPane.js:
699         (WebInspector.JavaScriptBreakpointsSidebarPane):
700         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointCheckboxClicked):
701         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointContextMenu):
702         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._contextMenu):
703         * inspector/front-end/DebuggerModel.js:
704         (WebInspector.DebuggerModel.prototype.debuggerPausedDetails):
705         (WebInspector.DebuggerModel.prototype.createRawLocationByURL):
706         (WebInspector.DebuggerModel.prototype.isPaused):
707         * inspector/front-end/DebuggerPresentationModel.js:
708         (WebInspector.DebuggerPresentationModel.prototype.get breakpointManager):
709         (WebInspector.DebuggerPresentationModel.prototype._debuggerPaused):
710         (WebInspector.DebuggerPresentationModelResourceBinding.prototype._setContentWithInitialContent):
711         * inspector/front-end/JavaScriptSource.js:
712         (WebInspector.JavaScriptSource):
713         (WebInspector.JavaScriptSource.prototype.consoleMessagesCleared):
714         (WebInspector.JavaScriptSource.prototype.findBreakpoint):
715         (WebInspector.JavaScriptSource.prototype.setBreakpoint):
716         (WebInspector.JavaScriptSource.prototype.setBreakpointEnabled):
717         (WebInspector.JavaScriptSource.prototype.removeBreakpoint):
718         (WebInspector.JavaScriptSource.prototype.updateBreakpoint):
719         (WebInspector.JavaScriptSource.prototype.continueToLine):
720         (WebInspector.JavaScriptSource.prototype.canSetContent):
721         (WebInspector.JavaScriptSource.prototype.setContent):
722         (WebInspector.JavaScriptSource.prototype.updateBreakpointsAfterLiveEdit):
723         * inspector/front-end/JavaScriptSourceFrame.js:
724         (WebInspector.JavaScriptSourceFrame.prototype.canEditSource):
725         (WebInspector.JavaScriptSourceFrame.prototype.editContent):
726         (WebInspector.JavaScriptSourceFrame.prototype._onContentChanged):
727         (WebInspector.JavaScriptSourceFrame.prototype.populateLineGutterContextMenu.else.editBreakpointCondition.didEditBreakpointCondition):
728         (WebInspector.JavaScriptSourceFrame.prototype.populateLineGutterContextMenu.else):
729         (WebInspector.JavaScriptSourceFrame.prototype.populateLineGutterContextMenu):
730         (WebInspector.JavaScriptSourceFrame.prototype.beforeTextChanged):
731         (WebInspector.JavaScriptSourceFrame.prototype._getPopoverAnchor):
732         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover.showObjectPopover):
733         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover):
734         (WebInspector.JavaScriptSourceFrame.prototype._setBreakpoint):
735         (WebInspector.JavaScriptSourceFrame.prototype._onMouseDown):
736         * inspector/front-end/ScopeChainSidebarPane.js:
737         (WebInspector.ScopeChainSidebarPane.prototype.update):
738         * inspector/front-end/ScriptsPanel.js:
739         (WebInspector.ScriptsPanel.prototype._debuggerPaused.else.didGetUILocation):
740         (WebInspector.ScriptsPanel.prototype._debuggerPaused):
741
742 2012-04-24  Yury Semikhatsky  <yurys@chromium.org>
743
744         Web Inspector: native nodes may have snapshot id less than base snapshot max JS object id
745         https://bugs.webkit.org/show_bug.cgi?id=84681
746
747         Make sure new nodes whose IDs less than base snapshot max JS object id will
748         get into snapshot delta.
749
750         Reviewed by Pavel Feldman.
751
752         Test: inspector/profiler/heap-snapshot-comparison-dom-groups-change.html
753
754         * inspector/front-end/HeapSnapshot.js:
755         (WebInspector.HeapSnapshot.prototype._calculateDiffForClass):
756         * inspector/front-end/HeapSnapshotDataGrids.js:
757         (WebInspector.HeapSnapshotSortableDataGrid): Drive-by fix, made recursion counter
758         a normal field on HeapSnapshotSortableDataGrid.
759         (WebInspector.HeapSnapshotSortableDataGrid.prototype.recursiveSortingEnter):
760         (WebInspector.HeapSnapshotSortableDataGrid.prototype.recursiveSortingLeave):
761
762 2012-04-24  Sheriff Bot  <webkit.review.bot@gmail.com>
763
764         Unreviewed, rolling out r115000.
765         http://trac.webkit.org/changeset/115000
766         https://bugs.webkit.org/show_bug.cgi?id=84703
767
768         Breaks webkit_unit_tests on Mac in Chromium:
769         http://build.chromium.org/p/chromium.webkit/builders/Webkit%20Mac10.6/builds/15157
770         (Requested by mnaganov on #webkit).
771
772         * platform/graphics/skia/OpaqueRegionSkia.cpp:
773         (WebCore::paintIsOpaque):
774         (WebCore::OpaqueRegionSkia::popCanvasLayer):
775         (WebCore::OpaqueRegionSkia::didDraw):
776         (WebCore::OpaqueRegionSkia::didDrawUnbounded):
777         (WebCore::OpaqueRegionSkia::markRectAsOpaque):
778         (WebCore::OpaqueRegionSkia::markRectAsNonOpaque):
779         * platform/graphics/skia/OpaqueRegionSkia.h:
780         (OpaqueRegionSkia):
781         (WebCore::OpaqueRegionSkia::CanvasLayerState::CanvasLayerState):
782         (CanvasLayerState):
783         * platform/graphics/skia/PlatformContextSkia.cpp:
784         (WebCore::PlatformContextSkia::restoreLayer):
785
786 2012-04-23  Antti Koivisto  <antti@apple.com>
787
788         Consolidate external stylesheet quirks handling to StyleSheetInternal
789         https://bugs.webkit.org/show_bug.cgi?id=84632
790
791         Reviewed by Andreas Kling.
792
793         Move the repeated code from StyleImportRule and HTMLLinkElement to StyleSheetInternal::parseUserStyleSheet.
794         
795         Remove a BUILDING_ON_LEOPARD-only quirk.
796
797         * css/CSSImportRule.cpp:
798         (WebCore::StyleRuleImport::setCSSStyleSheet):
799         * css/CSSParser.cpp:
800         (WebCore):
801         (WebCore::CSSParserContext::CSSParserContext):
802         
803             Add new settings bits to the CSSParserContext. These are used for external stylesheet parsing quirks.
804
805         * css/CSSParserMode.h:
806         (CSSParserContext):
807         * css/CSSStyleSheet.cpp:
808         (WebCore::StyleSheetInternal::parseUserStyleSheet):
809         (WebCore::StyleSheetInternal::parseString):
810         (WebCore):
811         (WebCore::StyleSheetInternal::parseStringAtLine):
812         * css/CSSStyleSheet.h:
813         (WebCore):
814         (StyleSheetInternal):
815         * html/HTMLLinkElement.cpp:
816         (WebCore::HTMLLinkElement::setCSSStyleSheet):
817
818 2012-04-24  Yael Aharon  <yael.aharon@nokia.com>
819
820         [Qt] Move notification icon download out of WebCore
821         https://bugs.webkit.org/show_bug.cgi?id=80700
822
823         Reviewed by Simon Hausmann.
824
825         Remove the code that downloads the notification's icon out of WebCore.
826         Other ports let the client decide if to download the icon or not.
827         No new tests. This patch is only removing code.
828
829         * notifications/Notification.cpp:
830         (WebCore::Notification::~Notification):
831         (WebCore::Notification::show):
832         (WebCore::Notification::close):
833         (WebCore::Notification::contextDestroyed):
834         * notifications/Notification.h:
835         (Notification):
836
837 2012-04-24  Rakesh KN  <rakesh.kn@motorola.com>
838
839         RadioNodeList support in HTMLFormElement::elements
840         https://bugs.webkit.org/show_bug.cgi?id=81854
841
842         Implement RadioNodeList support spec'ed at
843         http://www.whatwg.org/specs/web-apps/current-work/multipage/common-dom-interfaces.html#radionodelist
844
845         Reviewed by Ryosuke Niwa.
846
847         Test: fast/forms/form-collection-radio-node-list.html
848
849         * CMakeLists.txt:
850         Added entries for new files.
851         * DerivedSources.cpp: Ditto.
852         * DerivedSources.make: Ditto.
853         * DerivedSources.pri: Ditto.
854         * GNUmakefile.list.am: Ditto.
855         * Target.pri: Ditto.
856         * WebCore.gypi: Ditto.
857         * WebCore.vcproj/WebCore.vcproj: Ditto.
858         * WebCore.xcodeproj/project.pbxproj: Ditto.
859         * bindings/js/JSHTMLCollectionCustom.cpp:
860         (WebCore::getNamedItems):
861         Modified to create RadioNodeList object when FormControlCollection has more than
862         one element of same name/id.
863         * bindings/scripts/CodeGeneratorJS.pm:
864         (GenerateImplementation):
865         Added code to include Node.h and JSNode.h in JSRadioNodeElement.cpp.
866         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
867         (WebCore::getNamedItems):
868         Modified to create RadioNodeList object when FormControlCollection has more than
869         one element of same name/id.
870         * html/CollectionType.h:
871         Added new FormControls type.
872         * html/HTMLCollection.cpp:
873         (WebCore::HTMLCollection::shouldIncludeChildren):
874         (WebCore::HTMLCollection::isAcceptableElement):
875         Handle FormControls collection type.
876         * html/HTMLFormCollection.cpp:
877         (WebCore::HTMLFormCollection::HTMLFormCollection):
878         Contruct collection of FormControls type.
879         * html/RadioNodeList.cpp: Added.
880         (WebCore):
881         (WebCore::RadioNodeList::RadioNodeList):
882         (WebCore::RadioNodeList::~RadioNodeList):
883         (WebCore::toRadioButtonInputElement):
884         (WebCore::RadioNodeList::value):
885         (WebCore::RadioNodeList::setValue):
886         (WebCore::RadioNodeList::nodeMatches):
887         * html/RadioNodeList.h: Added.
888         (WebCore):
889         (RadioNodeList):
890         (WebCore::RadioNodeList::create):
891         RadioNodeList implementation.
892         * html/RadioNodeList.idl: Added.
893         Idl for generating RadioNodeList JS/V8 bindings.
894
895 2012-04-24  Benjamin Poulain  <bpoulain@apple.com>
896
897         Implement the field cache of ObjcClass in WebKit types
898         https://bugs.webkit.org/show_bug.cgi?id=84667
899
900         Reviewed by Geoffrey Garen.
901
902         Every time we get a field through the Objective-C bridge, we waste some time converting
903         the incoming string to an CFString.
904
905         This patch implement the field cache based on WTF types so that we can return directly
906         in case of a positive match.
907
908         When we do not have a match on the Identifier, we allocate the memory and find the valid field
909         as before.
910
911         * bridge/objc/objc_class.h:
912         (ObjcClass):
913         * bridge/objc/objc_class.mm:
914         (JSC::Bindings::deleteMethod):
915         (Bindings):
916         (JSC::Bindings::ObjcClass::ObjcClass):
917         (JSC::Bindings::ObjcClass::fieldNamed):
918
919 2012-04-23  Andy Estes  <aestes@apple.com>
920
921         Incremental rendering should be unsuppressed after the load event or a configurable timeout, whichever occurs first.
922         https://bugs.webkit.org/show_bug.cgi?id=84583
923
924         Reviewed by Anders Carlsson.
925
926         In high-latency situations, having incremental rendering suppression
927         enabled makes for a worse experience due to the excessively long time
928         it takes for the load event to fire. So that clients that opt in to
929         incremental rendering suppression can mitigate this, add a configurable
930         timeout in which rendering is re-enabled if the load event has yet to
931         fire.
932
933         * dom/Document.cpp:
934         (WebCore::Document::Document):
935         (WebCore::Document::setReadyState): When the document transitions to
936         the loading state, start a timer; when it transitions to the completed
937         state, allow visual updates.
938         (WebCore::Document::setVisualUpdatesAllowed): If visual updates are
939         allowed, force a repaint. Otherwise, set a flag that suppresses
940         rendering.
941         (WebCore::Document::visualUpdatesSuppressionTimerFired): When the timer
942         fires, allow visual updates.
943         (WebCore::Document::implicitClose): Remove code that is now called in
944         setVisualUpdatesAllowed().
945         * dom/Document.h:
946         (WebCore::Document::visualUpdatesAllowed):
947         * page/Settings.cpp:
948         (WebCore::Settings::Settings):
949         * page/Settings.h:
950         (WebCore::Settings::setIncrementalRenderingSuppressionTimeoutInSeconds):
951         (WebCore::Settings::incrementalRenderingSuppressionTimeoutInSeconds):
952
953 2012-04-23  Dana Jansens  <danakj@chromium.org>
954
955         [chromium] Image masks are considered opaque incorrectly
956         https://bugs.webkit.org/show_bug.cgi?id=84275
957
958         Reviewed by Adrienne Walker.
959
960         Match the behaviour of SkCanvas layers more closely while tracking
961         opaque paints. SkCanvas layers actually act as a separate device
962         (ie. pixels) and when the layer is popped off, the pixels are copied
963         down to the layer below.
964
965         While we can use the total clip to decide what pixels the the
966         drawing operation will affect in the final device, the blending
967         down through layers needs to consider each layer carefully.
968
969         In this case the image mask is drawn into a layer which is copied
970         down using the DestinationIn operation. Since the layer contains
971         non-opaque pixels, the DestinationIn copy can destroy opaque
972         areas in the next layer. We add OpaqueRegionSkia::FillByCopy to
973         distinguish the case where we are copying a block of pixels, and the
974         alpha values are essentially unknown.
975
976         Unit test: PlatformContextSkiaTest.trackImageMask
977                    PlatformContextSkiaTest.trackImageMaskWithOpaqueRect
978
979         * platform/graphics/skia/OpaqueRegionSkia.cpp:
980         (WebCore::paintIsOpaque):
981         (WebCore::OpaqueRegionSkia::applyOpaqueRegionFromLayer):
982         (WebCore::OpaqueRegionSkia::pushCanvasLayer):
983         (WebCore::OpaqueRegionSkia::popCanvasLayer):
984         (WebCore::OpaqueRegionSkia::didDrawRect):
985         (WebCore::OpaqueRegionSkia::didDrawPath):
986         (WebCore::OpaqueRegionSkia::didDrawPoints):
987         (WebCore::OpaqueRegionSkia::didDrawBounded):
988         (WebCore::OpaqueRegionSkia::didDraw):
989         (WebCore::OpaqueRegionSkia::didDrawUnbounded):
990         (WebCore::OpaqueRegionSkia::markRectAsOpaque):
991         (WebCore::OpaqueRegionSkia::markRectAsNonOpaque):
992         (WebCore::OpaqueRegionSkia::markAllAsNonOpaque):
993         * platform/graphics/skia/OpaqueRegionSkia.h:
994         (OpaqueRegionSkia):
995         (CanvasLayerState):
996         * platform/graphics/skia/PlatformContextSkia.cpp:
997         (WebCore::PlatformContextSkia::restoreLayer):
998
999 2012-04-23  Kent Tamura  <tkent@chromium.org>
1000
1001         Show the format indicator in a date field
1002         https://bugs.webkit.org/show_bug.cgi?id=83872
1003
1004         Reviewed by Hajime Morita.
1005
1006         Enable the fixed placeholder feature for the date type, and show
1007         the editable date format as the fixed placeholder.
1008         The format string is created by the following steps.
1009         1. Obtain a pattern string from ICU
1010           http://icu-project.org/apiref/icu4c/classSimpleDateFormat.html#details
1011         2. Replace a sequence of 'y', 'Y', 'M', or 'd' in the pattern with
1012           a natural language string such as "year", "month", or "day".
1013
1014         Test: fast/forms/date/date-fixed-placeholder.html
1015
1016         * html/DateInputType.cpp:
1017         (WebCore::DateInputType::supportsPlaceholder): Added. Returns true.
1018         (WebCore::DateInputType::usesFixedPlaceholder): Added. Returns true.
1019         (WebCore::DateInputType::fixedPlaceholder):
1020         Added. Calls localizedDateFormatText() provided by LocalizedDate.h.
1021         * html/DateInputType.h:
1022         (DateInputType): Add declarations of new override functions.
1023         * platform/LocalizedStrings.h:
1024         (WebCore): Add dateFormat{Year,Month,DayInMonth}Text()
1025         * platform/text/ICULocale.cpp:
1026         (WebCore::isICUYearSymbol): A function to improve redability.
1027         (WebCore::isICUMonthSymbol): ditto.
1028         (WebCore::isICUDayInMonthSymbol): ditto.
1029         (WebCore::localizeFormat): Step 2 of the above description.
1030         (WebCore::ICULocale::initializeLocalizedDateFormatText):
1031         Step 1 of the above description.
1032         (WebCore::ICULocale::localizedDateFormatText):
1033         * platform/text/ICULocale.h:
1034         (ICULocale): Add new functions and a data member.
1035         * platform/text/LocalizedDate.h:
1036         (WebCore): Add localizedDateFormatText().
1037         * platform/text/LocalizedDateICU.cpp:
1038         (WebCore::localizedDateFormatText):
1039         Just call ICULocale::localizedDateFormatText().
1040
1041 2012-04-23  Kentaro Hara  <haraken@chromium.org>
1042
1043         [V8] Pass Isolate to v8Array()
1044         https://bugs.webkit.org/show_bug.cgi?id=84295
1045
1046         Reviewed by Nate Chapin.
1047
1048         The final objective is to pass Isolate around in V8 bindings.
1049         This patch passes the Isolate to v8Array().
1050
1051         (GenerateNormalAttrGetter):
1052         (NativeToJSValue):
1053         * bindings/scripts/test/V8/V8TestObj.cpp:
1054         (WebCore::TestObjV8Internal::sequenceAttrAttrGetter):
1055         (WebCore::TestObjV8Internal::methodReturningSequenceCallback):
1056         * bindings/v8/V8Binding.h:
1057         (WebCore::v8Array):
1058
1059 2012-04-23  Kentaro Hara  <haraken@chromium.org>
1060
1061         [V8] Pass Isolate to GetNamedProperty()
1062         https://bugs.webkit.org/show_bug.cgi?id=84277
1063
1064         Reviewed by Nate Chapin.
1065
1066         The objective is to pass Isolate around in V8 bindings.
1067         This patch passes Isolate to GetNamedProperty().
1068
1069         (GenerateHeader):
1070         * bindings/v8/V8DOMWindowShell.cpp:
1071         (WebCore::getter):
1072         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
1073         (WebCore::V8HTMLDocument::GetNamedProperty):
1074         (WebCore::V8HTMLDocument::allAccessorGetter):
1075
1076 2012-04-23  Michael Nordman  <michaeln@google.com>
1077
1078         [chromium] DomStorage event handling mods.
1079         https://bugs.webkit.org/show_bug.cgi?id=84387
1080
1081         Add a few simple inline getters to allow the source Document of a storage
1082         event to be identified given a pointer to the source StorageArea so those
1083         Documents can be excluded by the event dispatching logic.
1084
1085         Reviewed by Dimitri Glazkov.
1086
1087         No new tests. No new functionality or change in behavior.
1088
1089         * page/DOMWindow.h:
1090         (WebCore::DOMWindow::optionalSessionStorage): simple inline getter to avoid construction where possible
1091         (WebCore::DOMWindow::optionalLocalStorage): ditto
1092         * storage/Storage.h:
1093         (WebCore::Storage::area): simple inline getter
1094
1095 2012-04-23  Kenneth Russell  <kbr@google.com>
1096
1097         Change ImageData to reference Uint8ClampedArray rather than CanvasPixelArray
1098         https://bugs.webkit.org/show_bug.cgi?id=73011
1099
1100         Reviewed by Oliver Hunt.
1101
1102         Changed ImageData to contain Uint8ClampedArray instead of ByteArray
1103         per current HTML5 spec.
1104
1105         In order to avoid introducing large data copies, it was necessary to
1106         switch a few other places in WebKit to use Uint8ClampedArray at the
1107         same time, most notably the FilterEffect implementation, portions of
1108         ImageBuffer, and a couple of places in the image encoders.
1109
1110         Note that the change in method name from "get" to "item" occurred
1111         because JSC's autogenerated indexed getters reference a method
1112         called "item". If desired, a convenience method could be
1113         introduced to avoid the renamings in the FilterEffect classes.
1114
1115         With these changes, ByteArray and some custom code in JavaScriptCore
1116         actually become unreferenced, and can be deleted. This deletion will
1117         be done separately in Bug 83655, to keep the size of this patch
1118         manageable.
1119
1120         Test: fast/canvas/imagedata-contains-uint8clampedarray.html
1121
1122         * bindings/js/JSImageDataCustom.cpp:
1123         (WebCore::toJS):
1124         * bindings/js/SerializedScriptValue.cpp:
1125         (WebCore::CloneSerializer::dumpIfTerminal):
1126         (WebCore::CloneDeserializer::readTerminal):
1127         * bindings/v8/SerializedScriptValue.cpp:
1128         * bindings/v8/custom/V8ImageDataCustom.cpp:
1129         (WebCore::toV8):
1130         * bridge/qt/qt_pixmapruntime.cpp:
1131         (JSC::Bindings::QtPixmapToImageDataMethod::invoke):
1132         * html/ImageData.cpp:
1133         (WebCore::ImageData::create):
1134         (WebCore::ImageData::ImageData):
1135         * html/ImageData.h:
1136         (ImageData):
1137         (WebCore::ImageData::data):
1138         * html/ImageData.idl:
1139         * html/canvas/CanvasRenderingContext2D.cpp:
1140         (WebCore::createEmptyImageData):
1141         (WebCore::CanvasRenderingContext2D::getImageData):
1142         (WebCore::CanvasRenderingContext2D::putImageData):
1143         * platform/graphics/GraphicsContext3D.cpp:
1144         (WebCore::GraphicsContext3D::extractImageData):
1145         * platform/graphics/ImageBuffer.cpp:
1146         (WebCore::ImageBuffer::genericConvertToLuminanceMask):
1147         * platform/graphics/ImageBuffer.h:
1148         * platform/graphics/ShadowBlur.cpp:
1149         (WebCore::ShadowBlur::blurShadowBuffer):
1150         * platform/graphics/cairo/ImageBufferCairo.cpp:
1151         (WebCore::getImageData):
1152         (WebCore::ImageBuffer::getUnmultipliedImageData):
1153         (WebCore::ImageBuffer::getPremultipliedImageData):
1154         (WebCore::ImageBuffer::putByteArray):
1155         * platform/graphics/cg/ImageBufferCG.cpp:
1156         (WebCore::ImageBuffer::getUnmultipliedImageData):
1157         (WebCore::ImageBuffer::getPremultipliedImageData):
1158         (WebCore::ImageBuffer::putByteArray):
1159         (WebCore::ImageBuffer::toDataURL):
1160         (WebCore::ImageDataToDataURL):
1161         * platform/graphics/cg/ImageBufferDataCG.cpp:
1162         (WebCore::ImageBufferData::getData):
1163         (WebCore::ImageBufferData::putData):
1164         * platform/graphics/cg/ImageBufferDataCG.h:
1165         (ImageBufferData):
1166         * platform/graphics/filters/FEBlend.cpp:
1167         (WebCore::FEBlend::platformApplySoftware):
1168         * platform/graphics/filters/FEColorMatrix.cpp:
1169         (WebCore::effectType):
1170         (WebCore::FEColorMatrix::platformApplySoftware):
1171         * platform/graphics/filters/FEComponentTransfer.cpp:
1172         (WebCore::FEComponentTransfer::platformApplySoftware):
1173         * platform/graphics/filters/FEComposite.cpp:
1174         (WebCore::FEComposite::platformArithmeticSoftware):
1175         (WebCore::FEComposite::platformApplySoftware):
1176         * platform/graphics/filters/FEComposite.h:
1177         * platform/graphics/filters/FEConvolveMatrix.cpp:
1178         (WebCore::setDestinationPixels):
1179         (WebCore::FEConvolveMatrix::fastSetInteriorPixels):
1180         (WebCore::FEConvolveMatrix::fastSetOuterPixels):
1181         (WebCore::FEConvolveMatrix::platformApplySoftware):
1182         * platform/graphics/filters/FEConvolveMatrix.h:
1183         (PaintingData):
1184         * platform/graphics/filters/FECustomFilter.cpp:
1185         (WebCore::FECustomFilter::platformApplySoftware):
1186         (WebCore::FECustomFilter::bindProgramAndBuffers):
1187         * platform/graphics/filters/FECustomFilter.h:
1188         (JSC):
1189         (FECustomFilter):
1190         * platform/graphics/filters/FEDisplacementMap.cpp:
1191         (WebCore::FEDisplacementMap::platformApplySoftware):
1192         * platform/graphics/filters/FEDropShadow.cpp:
1193         (WebCore::FEDropShadow::platformApplySoftware):
1194         * platform/graphics/filters/FEGaussianBlur.cpp:
1195         (WebCore::boxBlur):
1196         (WebCore::FEGaussianBlur::platformApplyGeneric):
1197         (WebCore::FEGaussianBlur::platformApply):
1198         (WebCore::FEGaussianBlur::platformApplySoftware):
1199         * platform/graphics/filters/FEGaussianBlur.h:
1200         (PlatformApplyParameters):
1201         (FEGaussianBlur):
1202         * platform/graphics/filters/FELighting.cpp:
1203         (WebCore::FELighting::LightingData::topLeft):
1204         (WebCore::FELighting::LightingData::topRow):
1205         (WebCore::FELighting::LightingData::topRight):
1206         (WebCore::FELighting::LightingData::leftColumn):
1207         (WebCore::FELighting::LightingData::interior):
1208         (WebCore::FELighting::LightingData::rightColumn):
1209         (WebCore::FELighting::LightingData::bottomLeft):
1210         (WebCore::FELighting::LightingData::bottomRow):
1211         (WebCore::FELighting::LightingData::bottomRight):
1212         (WebCore::FELighting::inlineSetPixel):
1213         (WebCore::FELighting::drawLighting):
1214         (WebCore::FELighting::platformApplySoftware):
1215         * platform/graphics/filters/FELighting.h:
1216         (LightingData):
1217         (FELighting):
1218         * platform/graphics/filters/FEMorphology.cpp:
1219         (WebCore::FEMorphology::platformApplyGeneric):
1220         (WebCore::FEMorphology::platformApplySoftware):
1221         * platform/graphics/filters/FEMorphology.h:
1222         (PaintingData):
1223         * platform/graphics/filters/FETurbulence.cpp:
1224         (WebCore::FETurbulence::fillRegion):
1225         (WebCore::FETurbulence::platformApplySoftware):
1226         * platform/graphics/filters/FETurbulence.h:
1227         (FillRegionParameters):
1228         (FETurbulence):
1229         * platform/graphics/filters/FilterEffect.cpp:
1230         (WebCore::FilterEffect::forceValidPreMultipliedPixels):
1231         (WebCore::FilterEffect::asUnmultipliedImage):
1232         (WebCore::FilterEffect::asPremultipliedImage):
1233         (WebCore::FilterEffect::copyImageBytes):
1234         (WebCore::FilterEffect::copyUnmultipliedImage):
1235         (WebCore::FilterEffect::copyPremultipliedImage):
1236         (WebCore::FilterEffect::createUnmultipliedImageResult):
1237         (WebCore::FilterEffect::createPremultipliedImageResult):
1238         * platform/graphics/filters/FilterEffect.h:
1239         (FilterEffect):
1240         * platform/graphics/filters/arm/FEGaussianBlurNEON.h:
1241         (WebCore::FEGaussianBlur::platformApplyNeon):
1242         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
1243         (WebCore::GraphicsContext3D::paintRenderingResultsToImageData):
1244         * platform/graphics/qt/ImageBufferQt.cpp:
1245         (WebCore::getImageData):
1246         (WebCore::ImageBuffer::getUnmultipliedImageData):
1247         (WebCore::ImageBuffer::getPremultipliedImageData):
1248         (WebCore::ImageBuffer::putByteArray):
1249         * platform/graphics/skia/ImageBufferSkia.cpp:
1250         (WebCore::getImageData):
1251         (WebCore::ImageBuffer::getUnmultipliedImageData):
1252         (WebCore::ImageBuffer::getPremultipliedImageData):
1253         (WebCore::ImageBuffer::putByteArray):
1254         * platform/graphics/texmap/TextureMapperGL.cpp:
1255         * platform/graphics/wince/ImageBufferWinCE.cpp:
1256         (WebCore::getImageData):
1257         (WebCore::ImageBuffer::getUnmultipliedImageData):
1258         (WebCore::ImageBuffer::getPremultipliedImageData):
1259         (WebCore::ImageBuffer::putByteArray):
1260         * platform/graphics/wx/ImageBufferWx.cpp:
1261         (WebCore::ImageBuffer::getUnmultipliedImageData):
1262         (WebCore::ImageBuffer::getPremultipliedImageData):
1263         (WebCore::ImageBuffer::putByteArray):
1264         * platform/image-encoders/skia/JPEGImageEncoder.cpp:
1265         (WebCore::JPEGImageEncoder::encode):
1266         * platform/image-encoders/skia/PNGImageEncoder.cpp:
1267         (WebCore::PNGImageEncoder::encode):
1268         * platform/image-encoders/skia/WEBPImageEncoder.cpp:
1269         (WebCore::WEBPImageEncoder::encode):
1270
1271 2012-04-23  Ryan Sleevi  <rsleevi@chromium.org>
1272
1273         [chromium] Remove deleted files from WebCore.gypi and fix typo
1274         https://bugs.webkit.org/show_bug.cgi?id=84651
1275
1276         Reviewed by Ryosuke Niwa.
1277
1278         No new tests. No behavior change.
1279
1280         * WebCore.gypi:
1281         Remove references to PlatformMouseEventQt.cpp and WheelEventQt.cpp. Add a missing comma.
1282
1283 2012-04-23  Erik Arvidsson  <arv@chromium.org>
1284
1285         [V8] Fix issue with trying to access a constructor in a frame that has been removed
1286         https://bugs.webkit.org/show_bug.cgi?id=84640
1287
1288         Reviewed by Kentaro Hara.
1289
1290         This regressed in r113250. Now we do what we did before and return undefined if the frame
1291         does not have a context.
1292
1293         Test: fast/dom/constructor-in-removed-frame.html
1294
1295         * bindings/v8/V8DOMWrapper.cpp:
1296         (WebCore::V8DOMWrapper::constructorForType):
1297
1298 2012-04-23  Chris Rogers  <crogers@google.com>
1299
1300         Oscillator::setWaveTable() should not reset oscillator phase
1301         https://bugs.webkit.org/show_bug.cgi?id=84647
1302         
1303         Reviewed by Kenneth Russell.
1304
1305         * Modules/webaudio/Oscillator.cpp:
1306         (WebCore::Oscillator::setWaveTable):
1307
1308 2012-04-23  Kentaro Hara  <haraken@chromium.org>
1309
1310         [V8][Refactoring] Remove V8Proxy::throwSyntaxError()
1311         https://bugs.webkit.org/show_bug.cgi?id=84627
1312
1313         Reviewed by Nate Chapin.
1314
1315         This patch removes V8Proxy::throwSyntaxError()
1316         since it is no longer used.
1317
1318         No tests. No change in behavior.
1319
1320         * bindings/v8/V8Proxy.cpp:
1321         * bindings/v8/V8Proxy.h:
1322         (V8Proxy):
1323
1324 2012-04-18  James Robinson  <jamesr@chromium.org>
1325
1326         [chromium] Use TextureLayerChromium for WebGL content instead of a dedicated layer type
1327         https://bugs.webkit.org/show_bug.cgi?id=84311
1328
1329         Reviewed by Adrienne Walker.
1330
1331         WebGL content's interface with the compositor can be expressed in terms of two basic operations:
1332         1.) Do some stuff
1333         2.) Provide a texture ID for the compositor to use
1334
1335         This implements (1) in DrawingBufferChromium and uses the already-existing TextureLayerChromium to handle (2).
1336         This cuts down the compositor interface significantly and allows for more code reuse in exchange for more code
1337         in TextureLayerChromium to handle the features WebGL needs.
1338
1339         * WebCore.gypi:
1340         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1341         (WebCore::DrawingBuffer::~DrawingBuffer):
1342         (DrawingBufferPrivate):
1343         (WebCore::DrawingBufferPrivate::DrawingBufferPrivate):
1344         (WebCore::DrawingBufferPrivate::~DrawingBufferPrivate):
1345         (WebCore::DrawingBufferPrivate::layer):
1346         (WebCore):
1347         (WebCore::DrawingBuffer::platformLayer):
1348         * platform/graphics/chromium/LayerRendererChromium.cpp:
1349         * platform/graphics/chromium/TextureLayerChromium.h:
1350         (TextureLayerChromiumClient):
1351         (WebCore::TextureLayerChromiumClient::~TextureLayerChromiumClient):
1352         (WebCore):
1353         (TextureLayerChromium):
1354         (WebCore::TextureLayerChromium::clearClient):
1355         * platform/graphics/chromium/WebGLLayerChromium.cpp: Removed.
1356         * platform/graphics/chromium/WebGLLayerChromium.h: Removed.
1357         * platform/graphics/gpu/DrawingBuffer.h:
1358         (WebCore):
1359         (WebCore::DrawingBuffer::graphicsContext3D):
1360         (DrawingBuffer):
1361
1362 2012-04-23  Alec Flett  <alecflett@chromium.org>
1363
1364         IndexedDB: remove IDB(Index|ObjectStore)BackendImpl::get/getKey for IDBKey
1365         https://bugs.webkit.org/show_bug.cgi?id=84285
1366
1367         Reviewed by Dimitri Glazkov.
1368
1369         No new tests required, this code is no longer called.
1370
1371         This is old code supporting IDBKey-based lookup, supplanted by
1372         IDBKeyRange. Now that chromium IPC/proxy code has landed,
1373         these functions can be removed.
1374
1375         * Modules/indexeddb/IDBIndexBackendInterface.h:
1376         (IDBIndexBackendInterface):
1377         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
1378         (IDBObjectStoreBackendInterface):
1379
1380 2012-04-22  Martin Robinson  <mrobinson@igalia.com>
1381
1382         REGRESSION(113604): [Soup] Some pages that use synchronous XMLHttpRequests freeze the browser
1383         https://bugs.webkit.org/show_bug.cgi?id=84560
1384
1385         Reviewed by Xan Lopez.
1386
1387         When kicking off a synchronous XMLHttpRequest, add one to the connection
1388         limit. This ensures that when a page starts a synchronous request, while
1389         already at the connection limit the request will not deadlock.
1390
1391         * platform/network/soup/ResourceHandleSoup.cpp:
1392         (WebCore::WebCoreSynchronousLoader::WebCoreSynchronousLoader): Accept a new SoupSession
1393         argument so that we can get the correct SoupSession for the networking context. Bump
1394         the connection limit.
1395         (WebCore::WebCoreSynchronousLoader::~WebCoreSynchronousLoader): Decrement the connection limit.
1396         (WebCore::WebCoreSynchronousLoader::adjustMaxConnections): Added this helper.
1397         (WebCoreSynchronousLoader): Added a new SoupSession member.
1398         (WebCore::sessionFromContext): Added this helper.
1399         (WebCore::ResourceHandleInternal::soupSession): Use the new sessionFromContext helper.
1400         (WebCore::ResourceHandle::loadResourceSynchronously): Pass the SoupSession from the NetworkingContext
1401         to the synchronous loader.
1402
1403 2012-04-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1404
1405         Unreviewed, rolling out r114965.
1406         http://trac.webkit.org/changeset/114965
1407         https://bugs.webkit.org/show_bug.cgi?id=84665
1408
1409         Four new resource load delegate test failures (Requested by
1410         jernoble on #webkit).
1411
1412         * loader/SubresourceLoader.cpp:
1413         (WebCore::SubresourceLoader::didFinishLoading):
1414         (WebCore::SubresourceLoader::didFail):
1415         (WebCore::SubresourceLoader::willCancel):
1416         (WebCore::SubresourceLoader::releaseResources):
1417
1418 2012-04-23  Beth Dakin  <bdakin@apple.com>
1419
1420         https://bugs.webkit.org/show_bug.cgi?id=84649
1421         RenderMathMLOperator currently ignores font families, fails 
1422         to use Stix
1423
1424         Reviewed by Dan Bernstein.
1425
1426         This patch makes RenderMathMLOperator honor the font-family 
1427         list. This means that by default, Stix glyphs will now be 
1428         used for operators just like for other MathML content. 
1429         Unfortunately, just doing that resulted in a bug because of 
1430         the fragile hardcoded glyph sizes. The Stix vertical bar 
1431         glyph is much smaller than the code assumed any glyphs would 
1432         be. That code should be re-written, but in the meantime, I 
1433         put a fix in place to try to make it work for small glyphs.
1434
1435         These new functions should be used instead of accessing
1436         gGlyphHeight or gGlyphLineHeight directly. If the glyph is
1437         smaller than the expected hardcoded value, then the actual
1438         glyph height is used, and a new line height based on the
1439         glyph height is used.
1440         (WebCore::RenderMathMLOperator::glyphHeightForCharacter):
1441         (WebCore::RenderMathMLOperator::lineHeightForCharacter):
1442
1443         Use the style's FontDescription to honor the font family
1444         list and the style's FontSelector to honor @font-face.
1445         Also use glyphHeightForCharacter() instead of gGlyphHeight. 
1446         And now that createGlyph() takes a lineHeight, use 
1447         lineHeightForCharacter() to determine the right value. 
1448         (WebCore::RenderMathMLOperator::updateFromElement):
1449
1450         size was an ambiguous variable name, so I renamed it to the 
1451         more accurate maxHeightForRenderer. This function also now
1452         takes a lineHeight instead of using gGlyphLineHeight. And
1453         again, use the style's FontDescription and FontSelector.
1454         (WebCore::RenderMathMLOperator::createStackableStyle):
1455
1456         Re-name size to maxHeightForRenderer, and take lineHeight as 
1457         a parameter.
1458         (WebCore::RenderMathMLOperator::createGlyph):
1459         * rendering/mathml/RenderMathMLOperator.h:
1460         (RenderMathMLOperator):
1461
1462 2012-04-23  Eriq Augustine  <eaugusti@chromium.org>
1463
1464         Return value from executed script in Chromium.
1465         https://bugs.webkit.org/show_bug.cgi?id=79851
1466
1467         Reviewed by Adam Barth.
1468
1469         Providing a varaiant of evaluateScriptInIsolatedWorld that
1470         returns the value of the evaluated script.
1471
1472         Test: platform/chromium/http/tests/misc/execute-and-return-value.html
1473
1474         * bindings/v8/ScriptController.cpp:
1475         (WebCore::ScriptController::evaluateInIsolatedWorld):
1476         * bindings/v8/ScriptController.h:
1477         (ScriptController):
1478         * bindings/v8/V8Proxy.cpp:
1479         (WebCore::V8Proxy::evaluateInIsolatedWorld):
1480         * bindings/v8/V8Proxy.h:
1481         (V8Proxy):
1482
1483 2012-04-23  Kent Tamura  <tkent@chromium.org>
1484
1485         RenderDetailsMarker should draw the triangle inside the content box
1486         https://bugs.webkit.org/show_bug.cgi?id=84557
1487
1488         Reviewed by Hajime Morita.
1489
1490         RenderDetailsMarker didn't support cases in which a marker has
1491         borders and/or padings, or non-square size.
1492
1493         Test: fast/html/details-marker-style.html
1494
1495         * rendering/RenderDetailsMarker.cpp:
1496         (WebCore::RenderDetailsMarker::getPath):
1497         Scale by contentWidth() and contentHeight().
1498         (WebCore::RenderDetailsMarker::paint):
1499         Move the trianle origin by the ammount of left/top borders and paddings.
1500
1501 2012-04-23  Kentaro Hara  <haraken@chromium.org>
1502
1503         [V8] Pass Isolate to toV8() (Part6)
1504         https://bugs.webkit.org/show_bug.cgi?id=84273
1505
1506         Reviewed by Nate Chapin.
1507
1508         The objective is to pass Isolate to all toV8()s.
1509         Since there are a lot of toV8()s, I'll make the change
1510         step by step. This patch passes Isolate to toV8() in
1511         several custom bindings.
1512
1513         No tests. No change in behavior.
1514
1515         * bindings/v8/custom/V8HTMLAllCollectionCustom.cpp:
1516         (WebCore::getNamedItems):
1517         (WebCore::getItem):
1518         (WebCore::V8HTMLAllCollection::namedPropertyGetter):
1519         (WebCore::V8HTMLAllCollection::itemCallback):
1520         (WebCore::V8HTMLAllCollection::namedItemCallback):
1521         (WebCore::V8HTMLAllCollection::callAsFunctionCallback):
1522         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
1523         (WebCore::getNamedItems):
1524         (WebCore::V8HTMLCollection::namedPropertyGetter):
1525         (WebCore::V8HTMLCollection::namedItemCallback):
1526         (WebCore::toV8):
1527         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
1528         (WebCore::toV8):
1529         * bindings/v8/custom/V8StyleSheetCustom.cpp:
1530         (WebCore::toV8):
1531         * bindings/v8/custom/V8StyleSheetListCustom.cpp:
1532         (WebCore::V8StyleSheetList::namedPropertyGetter):
1533         * bindings/v8/custom/V8TrackEventCustom.cpp:
1534         (WebCore::V8TrackEvent::trackAccessorGetter):
1535         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
1536         (WebCore::toV8Object):
1537         (WebCore::getObjectParameter):
1538         (WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
1539         (WebCore::V8WebGLRenderingContext::getExtensionCallback):
1540         (WebCore::V8WebGLRenderingContext::getFramebufferAttachmentParameterCallback):
1541         (WebCore::V8WebGLRenderingContext::getParameterCallback):
1542         (WebCore::V8WebGLRenderingContext::getProgramParameterCallback):
1543         (WebCore::V8WebGLRenderingContext::getShaderParameterCallback):
1544         (WebCore::V8WebGLRenderingContext::getUniformCallback):
1545         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
1546         (WebCore::V8XMLHttpRequest::responseAccessorGetter):
1547         * bindings/v8/custom/V8XSLTProcessorCustom.cpp:
1548         (WebCore::V8XSLTProcessor::transformToFragmentCallback):
1549         (WebCore::V8XSLTProcessor::transformToDocumentCallback):
1550
1551 2012-04-23  Kent Tamura  <tkent@chromium.org>
1552
1553         Move the content of LocalizedCalendarICU.cpp and LocalizedDateICU.cpp to ICULocale.cpp.
1554         https://bugs.webkit.org/show_bug.cgi?id=84568
1555
1556         Reviewed by Hajime Morita.
1557
1558         Move it to ICULocal.cpp because we want to share UDateFormat
1559         object in LocalizedDate functions and LocalizedCalendar functions,
1560         and it becomes easier to cache the UDateFormat object, and making
1561         unit tests for these functions easier.
1562
1563         No new tests because of no bahevior changes.
1564
1565         * platform/text/ICULocale.cpp:
1566         (WebCore::ICULocale::ICULocale): Initialize new members.
1567         (WebCore::ICULocale::~ICULocale): Delete m_shortDateFormat.
1568         (WebCore::ICULocale::initializeShortDateFormat):
1569         Moved from creteShortDateFormatter of LocalizedDateICU.cpp.
1570         (WebCore::ICULocale::parseLocalizedDate):
1571         Moved from LocalizedDate.cpp, use m_shortDateFormat.
1572         (WebCore::ICULocale::formatLocalizedDate): ditto.
1573         (WebCore::ICULocale::createLabelVector):
1574         Moved from LocalizedCalendarICU.cpp, use m_shortDateFormat.
1575         (WebCore::createFallbackMonthLabels): Moved from LocalizedCalendarICU.cpp.
1576         (WebCore::createFallbackWeekDayShortLabels): ditto.
1577         (WebCore::ICULocale::initializeCalendar):
1578         lazy initialization of m_monthLabels, m_weekDayShortLabels, and m_firstDayOfWeek.
1579         (WebCore::ICULocale::monthLabels):
1580         (WebCore::ICULocale::weekDayShortLabels):
1581         (WebCore::ICULocale::firstDayOfWeek):
1582         * platform/text/ICULocale.h:
1583         (ICULocale): Add declarations.
1584         * platform/text/LocalizedCalendarICU.cpp:
1585         (WebCore::monthLabels): Use ICULocale::currentLocale().
1586         (WebCore::weekDayShortLabels): ditto.
1587         (WebCore::firstDayOfWeek): ditto.
1588         * platform/text/LocalizedDateICU.cpp:
1589         (WebCore::parseLocalizedDate): ditto.
1590         (WebCore::formatLocalizedDate): ditto.
1591
1592 2012-04-23  Raymond Toy  <rtoy@google.com>
1593
1594         Move AudioDestinationChromium FIFO class to its own class.
1595         https://bugs.webkit.org/show_bug.cgi?id=84058
1596
1597         Reviewed by Chris Rogers.
1598
1599         Current tests cover the changes.
1600
1601         * WebCore.gypi: Update with new files.
1602         * platform/audio/AudioPullFIFO.cpp: Copied from Source/WebKit/chromium/src/AudioDestinationChromium.cpp.
1603         (WebCore): Renamed old class the AudioPullFIFO.
1604         (WebCore::AudioPullFIFO::AudioPullFIFO):
1605         (WebCore::AudioPullFIFO::consume):
1606         (WebCore::AudioPullFIFO::findWrapLengths):
1607         (WebCore::AudioPullFIFO::fillBuffer):
1608         * platform/audio/AudioPullFIFO.h: Added.
1609         (WebCore):
1610         (AudioPullFIFO):
1611         (WebCore::AudioPullFIFO::updateIndex):
1612
1613 2012-04-23  Nate Chapin  <japhet@chromium.org>
1614
1615         REGRESSION (r100311): YummySoup app crashes when trying to print
1616         https://bugs.webkit.org/show_bug.cgi?id=83918
1617
1618         Reviewed by Alexey Proskuryakov.
1619
1620         Test: http/tests/xmlhttprequest/cancel-during-failure-crash.html
1621
1622         * loader/SubresourceLoader.cpp:
1623         (WebCore::SubresourceLoader::didFinishLoading):
1624         (WebCore::SubresourceLoader::didFail):
1625         (WebCore::SubresourceLoader::willCancel): Now that we might enter the function if we're already Finishing,
1626             some cleanup needs to be done in the Initialized state only.
1627         (WebCore::SubresourceLoader::releaseResources): Move requesting counting decrement and laodDone() to
1628             the finishing functions.
1629
1630 2012-04-23  Shawn Singh  <shawnsingh@chromium.org>
1631
1632         [chromium] Visualize accelerated compositor rects.
1633         https://bugs.webkit.org/show_bug.cgi?id=79400
1634
1635         Reviewed by Adrienne Walker.
1636
1637         No tests, all the code added is only debugging code.
1638
1639         This patch adds support for visualizing three different types of
1640         rects on the chromium heads-up display:
1641         1. updateRects that indicate what was painted/uploaded to a resource
1642         2. propertyChangedRects that indicate layers that has property changes
1643         3. surfaceDamageRects that are the accumulation of updateRects and
1644            propertyChangedRects, indicating what pixels on the screen have
1645            actually changed.  (Surface damage also accounts for newly exposed
1646            areas but that is not explicitly visualized.)
1647
1648         In addition to adding support for visualizing this, the
1649         CCHeadsUpDisplay was significantly refactored, separating the FPS
1650         Counter functionality into a different class, so that the heads-up
1651         display is all about visualizing annotations, and those
1652         annotations (frame rate, debug rects) are logged separately.
1653
1654         * WebCore.gypi:
1655         * platform/graphics/chromium/cc/CCDebugRectHistory.cpp: Added.
1656         (WebCore):
1657         (WebCore::CCDebugRectHistory::CCDebugRectHistory):
1658         (WebCore::CCDebugRectHistory::enabled):
1659         (WebCore::CCDebugRectHistory::saveDebugRectsForCurrentFrame):
1660         (WebCore::CCDebugRectHistory::savePaintRects):
1661         (WebCore::CCDebugRectHistory::savePropertyChangedRects):
1662         (WebCore::CCDebugRectHistory::saveSurfaceDamageRects):
1663         * platform/graphics/chromium/cc/CCDebugRectHistory.h: Added.
1664         (WebCore):
1665         (WebCore::CCDebugRect::CCDebugRect):
1666         (CCDebugRect):
1667         (CCDebugRectHistory):
1668         (WebCore::CCDebugRectHistory::create):
1669         (WebCore::CCDebugRectHistory::debugRects):
1670         * platform/graphics/chromium/cc/CCFrameRateCounter.cpp: Added.
1671         (WebCore):
1672         (WebCore::safeMod):
1673         (WebCore::CCFrameRateCounter::frameIndex):
1674         (WebCore::CCFrameRateCounter::CCFrameRateCounter):
1675         (WebCore::CCFrameRateCounter::markBeginningOfFrame):
1676         (WebCore::CCFrameRateCounter::markEndOfFrame):
1677         (WebCore::CCFrameRateCounter::isBadFrameInterval):
1678         (WebCore::CCFrameRateCounter::isBadFrame):
1679         (WebCore::CCFrameRateCounter::getAverageFPSAndStandardDeviation):
1680         (WebCore::CCFrameRateCounter::timeStampOfRecentFrame):
1681         * platform/graphics/chromium/cc/CCFrameRateCounter.h: Added.
1682         (WebCore):
1683         (CCFrameRateCounter):
1684         (WebCore::CCFrameRateCounter::create):
1685         (WebCore::CCFrameRateCounter::currentFrameNumber):
1686         (WebCore::CCFrameRateCounter::timeStampHistorySize):
1687         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
1688         (WebCore):
1689         (WebCore::CCHeadsUpDisplay::enabled):
1690         (WebCore::CCHeadsUpDisplay::showDebugRects):
1691         (WebCore::CCHeadsUpDisplay::draw):
1692         (WebCore::CCHeadsUpDisplay::drawHudContents):
1693         (WebCore::CCHeadsUpDisplay::drawFPSCounter):
1694         (WebCore::CCHeadsUpDisplay::drawFPSCounterText):
1695         (WebCore::CCHeadsUpDisplay::drawDebugRects):
1696         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
1697         (WebCore):
1698         (CCHeadsUpDisplay):
1699         (WebCore::CCHeadsUpDisplay::CCHeadsUpDisplay):
1700         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
1701         (WebCore::CCSettings::CCSettings):
1702         (CCSettings):
1703         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1704         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
1705         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
1706         (WebCore::CCLayerTreeHostImpl::drawLayers):
1707         (WebCore::CCLayerTreeHostImpl::swapBuffers):
1708         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
1709         (WebCore):
1710         (WebCore::CCLayerTreeHostImpl::fpsCounter):
1711         (WebCore::CCLayerTreeHostImpl::debugRectHistory):
1712         (CCLayerTreeHostImpl):
1713
1714 2012-04-23  Julien Chaffraix  <jchaffraix@webkit.org>
1715
1716         Cut dependency on RenderLayer::scrollRectToVisible outside rendering
1717         https://bugs.webkit.org/show_bug.cgi?id=84607
1718
1719         Reviewed by Simon Fraser.
1720
1721         Layering fix only, there should be no change behavior.
1722
1723         Because we don't have an accessor on RenderObject, a lot of the code needs
1724         to know about RenderLayer. This is not necessary and exposes RenderLayer to
1725         objects that shouldn't know about it.
1726
1727         This patch adds a RenderObject::scrollRectToVisible with the ad-hoc explanation
1728         as to why it isn't on RenderBox (scrolling is a RenderBox concept).
1729
1730         * WebCore.exp.in:
1731         * WebCore.order:
1732         Updated to expose the new method.
1733
1734         * dom/Element.cpp:
1735         (WebCore::Element::scrollIntoView):
1736         (WebCore::Element::scrollIntoViewIfNeeded):
1737         (WebCore::Element::updateFocusAppearance):
1738         * editing/Editor.cpp:
1739         (WebCore::Editor::findStringAndScrollToVisible):
1740         * editing/FrameSelection.cpp:
1741         (WebCore::FrameSelection::revealSelection):
1742         * page/FrameView.cpp:
1743         (WebCore::FrameView::scrollToAnchor):
1744         Updated those call sites to use the new function.
1745
1746         * rendering/RenderLayer.h:
1747         Removed ScrollBehavior.h #include and default argument values
1748         as we are always called through RenderObject now.
1749
1750         * rendering/RenderObject.cpp:
1751         (WebCore::RenderObject::scrollRectToVisible):
1752         * rendering/RenderObject.h:
1753         Added a new function that just forwards to the enclosing layer
1754         if any. We return whether we actually tried to scroll to match
1755         some call sites expectations.
1756
1757 2012-04-23  Zhenyao Mo  <zmo@google.com>
1758
1759         framebuffer binding should not be changed after canvas resize or compositing
1760         https://bugs.webkit.org/show_bug.cgi?id=84609
1761
1762         Reviewed by Kenneth Russell.
1763
1764         Test: fast/canvas/webgl/framebuffer-bindings-unaffected-on-resize.html
1765
1766         * html/canvas/WebGLRenderingContext.cpp: set framebuffer binding to DrawingBuffer.
1767         (WebCore):
1768         (WebCore::WebGLRenderingContext::bindFramebuffer):
1769         (WebCore::WebGLRenderingContext::deleteFramebuffer):
1770         (WebCore::WebGLRenderingContext::loseContextImpl):
1771         * platform/graphics/cairo/DrawingBufferCairo.cpp: initialize m_framebufferBinding.
1772         (WebCore::DrawingBuffer::DrawingBuffer):
1773         * platform/graphics/chromium/DrawingBufferChromium.cpp: Ditto.
1774         (WebCore::DrawingBuffer::DrawingBuffer):
1775         * platform/graphics/chromium/WebGLLayerChromium.cpp: Recover framebuffer binding after update().
1776         (WebCore::WebGLLayerChromium::update):
1777         * platform/graphics/gpu/DrawingBuffer.cpp: Add a function to restore framebuffer binding.
1778         (WebCore::DrawingBuffer::restoreFramebufferBinding):
1779         (WebCore):
1780         * platform/graphics/gpu/DrawingBuffer.h: Ditto.
1781         (WebCore::DrawingBuffer::setTexture2DBinding):
1782         (DrawingBuffer):
1783         (WebCore::DrawingBuffer::setFramebufferBinding):
1784         * platform/graphics/gpu/mac/DrawingBufferMac.mm: initialize m_framebufferBinding.
1785         (WebCore::DrawingBuffer::DrawingBuffer):
1786         * platform/graphics/gpu/qt/DrawingBufferQt.cpp: initialize m_framebufferBinding.
1787         (WebCore::DrawingBuffer::DrawingBuffer):
1788
1789 2012-04-23  Victor Carbune  <vcarbune@adobe.com>
1790
1791         Simplify volume slider rendering
1792         https://bugs.webkit.org/show_bug.cgi?id=82150
1793
1794         Reviewed by Eric Carlson.
1795
1796         Test: media/video-controls-rendering-toggle-display-none.html
1797
1798         * css/mediaControlsChromium.css: Update controls css for Chromium.
1799         (audio::-webkit-media-controls-panel, video::-webkit-media-controls-panel):
1800         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
1801         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
1802         * css/mediaControlsGtk.css: Update controls css for GTK.
1803         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
1804         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
1805         * css/mediaControlsQuickTime.css: Update controls css for Safari.
1806         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
1807         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
1808         (audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider):
1809         * html/shadow/MediaControlElements.cpp: Removed particular renderer.
1810         (WebCore):
1811         * html/shadow/MediaControlElements.h:
1812         (MediaControlVolumeSliderContainerElement): Remoed particular renderer.
1813         * html/shadow/MediaControlRootElement.cpp:
1814         (WebCore::MediaControlRootElement::create): Added a div element as a container. Removed extra unused mute button.
1815         * html/shadow/MediaControlRootElementChromium.cpp: Added an extra div
1816         element as a container for the mute button and the volume slider to
1817         easily position them relative to each other.
1818         (WebCore::MediaControlRootElementChromium::create):
1819
1820 2012-04-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1821
1822         Unreviewed, rolling out r109981.
1823         http://trac.webkit.org/changeset/109981
1824         https://bugs.webkit.org/show_bug.cgi?id=84630
1825
1826         Broke Twitter map buddy icon (see
1827         https://bugs.webkit.org/show_bug.cgi?id=84558) (Requested by
1828         thorton on #webkit).
1829
1830         * rendering/RenderLayerCompositor.cpp:
1831         (WebCore::RenderLayerCompositor::addToOverlapMap):
1832         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
1833
1834 2012-04-23  Emil A Eklund  <eae@chromium.org>
1835
1836         Crash in RenderInline::clippedOverflowRectForRepaint for PrintPreview
1837         https://bugs.webkit.org/show_bug.cgi?id=84300
1838
1839         Reviewed by Simon Fraser.
1840
1841         No new tests, have not been able to come up with a reliable reduction.
1842
1843         * rendering/RenderInline.cpp:
1844         (WebCore::RenderInline::clippedOverflowRectForRepaint):
1845         Add NULL check for containingBlock() as it can return NULL when detached
1846         from the tree.
1847
1848 2012-04-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1849
1850         Unreviewed, rolling out r114929.
1851         http://trac.webkit.org/changeset/114929
1852         https://bugs.webkit.org/show_bug.cgi?id=84623
1853
1854         Broke 35 canvas/webgl tests (Requested by jernoble on
1855         #webkit).
1856
1857         * html/canvas/WebGLRenderingContext.cpp:
1858         (WebCore):
1859         (WebCore::WebGLRenderingContext::bindFramebuffer):
1860         (WebCore::WebGLRenderingContext::deleteFramebuffer):
1861         (WebCore::WebGLRenderingContext::loseContextImpl):
1862         * platform/graphics/cairo/DrawingBufferCairo.cpp:
1863         (WebCore::DrawingBuffer::DrawingBuffer):
1864         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1865         (WebCore::DrawingBuffer::DrawingBuffer):
1866         * platform/graphics/chromium/WebGLLayerChromium.cpp:
1867         (WebCore::WebGLLayerChromium::update):
1868         * platform/graphics/gpu/DrawingBuffer.cpp:
1869         * platform/graphics/gpu/DrawingBuffer.h:
1870         (WebCore::DrawingBuffer::setTexture2DBinding):
1871         (DrawingBuffer):
1872         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
1873         (WebCore::DrawingBuffer::DrawingBuffer):
1874         * platform/graphics/gpu/qt/DrawingBufferQt.cpp:
1875         (WebCore::DrawingBuffer::DrawingBuffer):
1876
1877 2012-04-23  Kentaro Hara  <haraken@chromium.org>
1878
1879         [V8] Pass Isolate around in V8Collection.h
1880         https://bugs.webkit.org/show_bug.cgi?id=84299
1881
1882         Reviewed by Nate Chapin.
1883
1884         The objective is to pass Isolate around in V8 bindings.
1885         This patch passes Isolate around in V8Collection.h.
1886
1887         No tests. No change in behavior.
1888
1889         * bindings/v8/V8Collection.h:
1890         (WebCore::getV8Object):
1891         (WebCore::getNamedPropertyOfCollection):
1892         (WebCore::collectionNamedPropertyGetter):
1893         (WebCore::getIndexedPropertyOfCollection):
1894         (WebCore::collectionIndexedPropertyGetter):
1895
1896 2012-04-23  Kentaro Hara  <haraken@chromium.org>
1897
1898         [V8] Pass Isolate to toV8() (Part5)
1899         https://bugs.webkit.org/show_bug.cgi?id=84271
1900
1901         Reviewed by Nate Chapin.
1902
1903         The objective is to pass Isolate to all toV8()s.
1904         Since there are a lot of toV8(), I'll make the change
1905         step by step. This patch passes Isolate to toV8()
1906         in several custom bindings.
1907
1908         No tests. No change in behavior.
1909
1910         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
1911         (WebCore::V8MessageChannel::constructorCallback):
1912         * bindings/v8/custom/V8MessageEventCustom.cpp:
1913         (WebCore::V8MessageEvent::dataAccessorGetter):
1914         (WebCore::V8MessageEvent::portsAccessorGetter):
1915         * bindings/v8/custom/V8MutationCallbackCustom.cpp:
1916         (WebCore::V8MutationCallback::handleEvent):
1917         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
1918         (WebCore::V8NamedNodeMap::indexedPropertyGetter):
1919         (WebCore::V8NamedNodeMap::namedPropertyGetter):
1920         (WebCore::toV8):
1921         * bindings/v8/custom/V8NodeListCustom.cpp:
1922         (WebCore::V8NodeList::namedPropertyGetter):
1923         * bindings/v8/custom/V8NotificationCenterCustom.cpp:
1924         (WebCore::V8NotificationCenter::createHTMLNotificationCallback):
1925         (WebCore::V8NotificationCenter::createNotificationCallback):
1926         * bindings/v8/custom/V8PerformanceCustom.cpp:
1927         (WebCore::V8Performance::memoryAccessorGetter):
1928         * bindings/v8/custom/V8PopStateEventCustom.cpp:
1929         (WebCore::V8PopStateEvent::stateAccessorGetter):
1930         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
1931         (WebCore::V8SQLTransactionSync::executeSqlCallback):
1932         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
1933         (WebCore::toV8):
1934
1935 2012-04-23  Zhenyao Mo  <zmo@google.com>
1936
1937         framebuffer binding should not be changed after canvas resize or compositing
1938         https://bugs.webkit.org/show_bug.cgi?id=84609
1939
1940         Reviewed by Kenneth Russell.
1941
1942         Test: fast/canvas/webgl/framebuffer-bindings-unaffected-on-resize.html
1943
1944         * html/canvas/WebGLRenderingContext.cpp: set framebuffer binding to DrawingBuffer.
1945         (WebCore):
1946         (WebCore::WebGLRenderingContext::bindFramebuffer):
1947         (WebCore::WebGLRenderingContext::deleteFramebuffer):
1948         (WebCore::WebGLRenderingContext::loseContextImpl):
1949         * platform/graphics/cairo/DrawingBufferCairo.cpp: initialize m_framebufferBinding.
1950         (WebCore::DrawingBuffer::DrawingBuffer):
1951         * platform/graphics/chromium/DrawingBufferChromium.cpp: Ditto.
1952         (WebCore::DrawingBuffer::DrawingBuffer):
1953         * platform/graphics/chromium/WebGLLayerChromium.cpp: Recover framebuffer binding after update().
1954         (WebCore::WebGLLayerChromium::update):
1955         * platform/graphics/gpu/DrawingBuffer.cpp: Add a function to restore framebuffer binding.
1956         (WebCore::DrawingBuffer::restoreFramebufferBinding):
1957         (WebCore):
1958         * platform/graphics/gpu/DrawingBuffer.h: Ditto.
1959         (WebCore::DrawingBuffer::setTexture2DBinding):
1960         (DrawingBuffer):
1961         (WebCore::DrawingBuffer::setFramebufferBinding):
1962         * platform/graphics/gpu/mac/DrawingBufferMac.mm: initialize m_framebufferBinding.
1963         (WebCore::DrawingBuffer::DrawingBuffer):
1964         * platform/graphics/gpu/qt/DrawingBufferQt.cpp: initialize m_framebufferBinding.
1965         (WebCore::DrawingBuffer::DrawingBuffer):
1966
1967 2012-04-23  Kentaro Hara  <haraken@chromium.org>
1968
1969         [V8] Pass Isolate to toV8() (Part4)
1970         https://bugs.webkit.org/show_bug.cgi?id=84269
1971
1972         Reviewed by Nate Chapin.
1973
1974         The objective is to pass Isolate to all toV8()s.
1975         Since there are a lot of toV8()s, I'll make the change
1976         step by step. This patch passes Isolate to toV8() in
1977         several custom bindings.
1978
1979         No tests. No change in behavior.
1980
1981         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
1982         (WebCore::V8HTMLCanvasElement::getContextCallback):
1983         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
1984         (WebCore::toV8):
1985         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
1986         (WebCore::V8HTMLDocument::allAccessorGetter):
1987         * bindings/v8/custom/V8HTMLElementCustom.cpp:
1988         (WebCore::toV8Object):
1989         (WebCore::V8HTMLElement::itemValueAccessorGetter):
1990         * bindings/v8/custom/V8HTMLFormElementCustom.cpp:
1991         (WebCore::V8HTMLFormElement::indexedPropertyGetter):
1992         (WebCore::V8HTMLFormElement::namedPropertyGetter):
1993         * bindings/v8/custom/V8HTMLFrameSetElementCustom.cpp:
1994         (WebCore::V8HTMLFrameSetElement::namedPropertyGetter):
1995         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
1996         (WebCore::v8HTMLImageElementConstructorCallback):
1997         * bindings/v8/custom/V8HTMLLinkElementCustom.cpp:
1998         (WebCore::V8HTMLLinkElement::sizesAccessorGetter):
1999         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
2000         (WebCore::V8HTMLOptionsCollection::indexedPropertyGetter):
2001         * bindings/v8/custom/V8HTMLOutputElementCustom.cpp:
2002         (WebCore::V8HTMLOutputElement::htmlForAccessorGetter):
2003         * bindings/v8/custom/V8HTMLSelectElementCustom.cpp:
2004         (WebCore::V8HTMLSelectElement::indexedPropertyGetter):
2005         * bindings/v8/custom/V8ImageDataCustom.cpp:
2006         (WebCore::toV8):
2007
2008 2012-04-23  Emil A Eklund  <eae@chromium.org>
2009
2010         Clean up subpixel unit handling in hit testing code
2011         https://bugs.webkit.org/show_bug.cgi?id=84496
2012
2013         Reviewed by Eric Seidel.
2014
2015         Fix use of IntRect and LayoutRect in hit testing code in preparation for
2016         subpixel layout.
2017
2018         No new tests, no change in functionality.
2019
2020         * rendering/HitTestResult.cpp:
2021         (WebCore::HitTestResult::rectForPoint):
2022         Revert rectForPoint to IntRect as all call sites converted it to an
2023         IntRect anyway to compare it with an IntPoint or another IntRect.
2024
2025         * rendering/HitTestingTransformState.cpp:
2026         (WebCore::HitTestingTransformState::boundsOfMappedQuad):
2027         * rendering/HitTestingTransformState.h:
2028         Convert boundsOfMappedQuad to LayoutRect as the TransformationMatrix now
2029         has subpixel precision.
2030
2031 2012-04-23  Kentaro Hara  <haraken@chromium.org>
2032
2033         [V8] Pass Isolate to toV8() (Part3)
2034         https://bugs.webkit.org/show_bug.cgi?id=84261
2035
2036         Reviewed by Nate Chapin.
2037
2038         The objective is to pass Isolate to all toV8()s.
2039         Since there are a lot of toV8(), I'll make the change
2040         step by step. This patch passes Isolate to toV8()
2041         in several custom bindings.
2042
2043         No tests. No change in behavior.
2044
2045         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2046         (WebCore::V8DOMWindow::openCallback):
2047         (WebCore::V8DOMWindow::indexedPropertyGetter):
2048         (WebCore::V8DOMWindow::namedPropertyGetter):
2049         * bindings/v8/custom/V8DirectoryEntrySyncCustom.cpp:
2050         (WebCore::V8DirectoryEntrySync::getDirectoryCallback):
2051         (WebCore::V8DirectoryEntrySync::getFileCallback):
2052         * bindings/v8/custom/V8DocumentCustom.cpp:
2053         (WebCore::V8Document::evaluateCallback):
2054         (WebCore::V8Document::getCSSCanvasContextCallback):
2055         (WebCore::V8Document::createTouchListCallback):
2056         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
2057         (WebCore::V8Document::locationAccessorGetter):
2058         * bindings/v8/custom/V8EntryCustom.cpp:
2059         (WebCore::toV8):
2060         * bindings/v8/custom/V8EntrySyncCustom.cpp:
2061         (WebCore::toV8):
2062         * bindings/v8/custom/V8EventCustom.cpp:
2063         (WebCore::V8Event::dataTransferAccessorGetter):
2064         (WebCore::V8Event::clipboardDataAccessorGetter):
2065         (WebCore):
2066         * bindings/v8/custom/V8FileReaderCustom.cpp:
2067         (WebCore::V8FileReader::resultAccessorGetter):
2068         * bindings/v8/custom/V8HTMLAllCollectionCustom.cpp:
2069         (WebCore::getItem):
2070         (WebCore::V8HTMLAllCollection::callAsFunctionCallback):
2071
2072 2012-04-23  Kentaro Hara  <haraken@chromium.org>
2073
2074         [V8] Pass Isolate to toV8() (Part2)
2075         https://bugs.webkit.org/show_bug.cgi?id=84259
2076
2077         Reviewed by Nate Chapin.
2078
2079         The objective is to pass Isolate to all toV8()s.
2080         Since there are a lot of toV8(), I'll make the change
2081         step by step. This patch passes Isolate to toV8() in
2082         several custom bindings.
2083
2084         No tests. No change in behavior.
2085
2086         * bindings/v8/custom/V8BlobCustom.cpp:
2087         (WebCore::toV8):
2088         * bindings/v8/custom/V8CSSRuleCustom.cpp:
2089         (WebCore::toV8):
2090         * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
2091         (WebCore::toV8):
2092         * bindings/v8/custom/V8CSSValueCustom.cpp:
2093         (WebCore::toV8):
2094         * bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp:
2095         (WebCore::toV8Object):
2096         (WebCore::V8CanvasRenderingContext2D::strokeStyleAccessorGetter):
2097         (WebCore::V8CanvasRenderingContext2D::fillStyleAccessorGetter):
2098         * bindings/v8/custom/V8ConsoleCustom.cpp:
2099         (WebCore::V8Console::memoryAccessorGetter):
2100         * bindings/v8/custom/V8CustomSQLStatementErrorCallback.cpp:
2101         (WebCore::V8SQLStatementErrorCallback::handleEvent):
2102         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
2103         (WebCore::toV8):
2104         * bindings/v8/custom/V8DOMTokenListCustom.cpp:
2105         (WebCore::toV8):
2106
2107 2012-04-23  Kentaro Hara  <haraken@chromium.org>
2108
2109         [V8][Refactoring] Remove V8Proxy::toV8()
2110         https://bugs.webkit.org/show_bug.cgi?id=84257
2111
2112         Reviewed by Nate Chapin.
2113
2114         Some constructorCallback()s are using V8Proxy::toV8(),
2115         other constructorCallback()s are directly using setJSWrapperForXXX()
2116         (XXX can be DOMObject, ActiveDOMObject, Node or ActiveNode).
2117         We should unify them.
2118
2119         Considering the fact that V8Proxy::toV8() just supports
2120         XXX=DOMObject and thus is not flexible, replacing V8Proxy::toV8()
2121         with setJSWrapperForDOMObject() would make sense.
2122
2123         No tests. No change in behavior.
2124
2125         * bindings/v8/V8Proxy.h: Removed toV8().
2126
2127         * bindings/scripts/CodeGeneratorV8.pm: Replaced toV8() with setJSWrapperForDOMObject().
2128         (GenerateEventConstructorCallback):
2129         * bindings/v8/custom/V8ArrayBufferCustom.cpp: Ditto.
2130         (WebCore::V8ArrayBuffer::constructorCallback):
2131         * bindings/v8/custom/V8ArrayBufferViewCustom.h: Ditto.
2132         (WebCore::constructWebGLArrayWithArrayBufferArgument):
2133         (WebCore::constructWebGLArray):
2134         * bindings/v8/custom/V8DOMFormDataCustom.cpp: Ditto.
2135         (WebCore::V8DOMFormData::constructorCallback):
2136         * bindings/v8/custom/V8DataViewCustom.cpp: Ditto.
2137         (WebCore::V8DataView::constructorCallback):
2138         * bindings/v8/custom/V8MessageChannelConstructor.cpp: Ditto.
2139         (WebCore::V8MessageChannel::constructorCallback):
2140         * bindings/v8/custom/V8WebKitPointConstructor.cpp: Ditto.
2141         (WebCore::V8WebKitPoint::constructorCallback):
2142
2143         * bindings/scripts/test/V8/V8TestEventConstructor.cpp: Updated run-bindings-tests results.
2144         (WebCore::V8TestEventConstructor::constructorCallback):
2145
2146 2012-04-23  Kentaro Hara  <haraken@chromium.org>
2147
2148         [V8] Pass Isolate to toV8() (Part1)
2149         https://bugs.webkit.org/show_bug.cgi?id=84250
2150
2151         Reviewed by Nate Chapin.
2152
2153         The final objective is to pass Isolate around in V8 bindings.
2154         This patch makes a change in CodeGeneratorV8.pm so that the
2155         generated code passes Isolate to toV8().
2156
2157         No tests. No change in behavior.
2158
2159         * bindings/scripts/CodeGeneratorV8.pm: Modified as described above.
2160         (GenerateNormalAttrGetter):
2161         (GenerateNamedConstructorCallback):
2162         (GenerateCallbackImplementation):
2163         (GenerateFunctionCallString):
2164         (NativeToJSValue):
2165
2166         * bindings/scripts/test/V8/V8Float64Array.cpp: Updated run-bindings-tests results.
2167         (WebCore::Float64ArrayV8Internal::fooCallback):
2168         * bindings/scripts/test/V8/V8TestCallback.cpp:
2169         (WebCore::V8TestCallback::callbackWithClass1Param):
2170         (WebCore::V8TestCallback::callbackWithClass2Param):
2171         (WebCore::V8TestCallback::callbackWithStringList):
2172         (WebCore::V8TestCallback::callbackRequiresThisToPass):
2173         * bindings/scripts/test/V8/V8TestInterface.cpp:
2174         (WebCore::TestInterfaceV8Internal::supplementalMethod2Callback):
2175         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2176         (WebCore::V8TestNamedConstructorConstructorCallback):
2177         * bindings/scripts/test/V8/V8TestObj.cpp:
2178         (WebCore::TestObjV8Internal::readOnlyTestObjAttrAttrGetter):
2179         (WebCore::TestObjV8Internal::testObjAttrAttrGetter):
2180         (WebCore::TestObjV8Internal::XMLObjAttrAttrGetter):
2181         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeAttrGetter):
2182         (WebCore::TestObjV8Internal::withScriptStateAttributeRaisesAttrGetter):
2183         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeRaisesAttrGetter):
2184         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeAttrGetter):
2185         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeRaisesAttrGetter):
2186         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateWithSpacesAttributeAttrGetter):
2187         (WebCore::TestObjV8Internal::withScriptArgumentsAndCallStackAttributeAttrGetter):
2188         (WebCore::TestObjV8Internal::cachedAttribute1AttrGetter):
2189         (WebCore::TestObjV8Internal::cachedAttribute2AttrGetter):
2190         (WebCore::TestObjV8Internal::mutablePointAttrGetter):
2191         (WebCore::TestObjV8Internal::immutablePointAttrGetter):
2192         (WebCore::TestObjV8Internal::objMethodCallback):
2193         (WebCore::TestObjV8Internal::objMethodWithArgsCallback):
2194         (WebCore::TestObjV8Internal::methodThatRequiresAllArgsAndThrowsCallback):
2195         (WebCore::TestObjV8Internal::withScriptStateObjCallback):
2196         (WebCore::TestObjV8Internal::withScriptStateObjExceptionCallback):
2197         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateObjExceptionCallback):
2198         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateWithSpacesCallback):
2199         (WebCore::TestObjV8Internal::mutablePointFunctionCallback):
2200         (WebCore::TestObjV8Internal::immutablePointFunctionCallback):
2201         (WebCore::TestObjV8Internal::strictFunctionCallback):
2202         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2203         (WebCore::TestSerializedScriptValueInterfaceV8Internal::portsAttrGetter):
2204
2205 2012-04-23  Kentaro Hara  <haraken@chromium.org>
2206
2207         [V8] Add an optional Isolate argument to setDOMException() and throwError()
2208         https://bugs.webkit.org/show_bug.cgi?id=84310
2209
2210         Reviewed by Nate Chapin.
2211
2212         The objective is to pass Isolate to setDOMException()
2213         and throwError(). This patch adds an optional Isolate argument
2214         to setDOMException() and throwError(). I'll pass the Isolate
2215         to these methods in the following patches.
2216
2217         No tests. No change in behavior.
2218
2219         * bindings/v8/V8Proxy.cpp:
2220         (WebCore):
2221         (WebCore::V8Proxy::setDOMException):
2222         (WebCore::V8Proxy::throwError):
2223         * bindings/v8/V8Proxy.h:
2224         (V8Proxy):
2225         (WebCore):
2226         (WebCore::throwError):
2227
2228 2012-04-23  Ian Vollick  <vollick@chromium.org>
2229
2230         [chromium] Properly ignore unsupported animation directions.
2231         https://bugs.webkit.org/show_bug.cgi?id=84599
2232
2233         Reviewed by Adrienne Walker.
2234
2235         Tested in CCLayerAnimationControllerTest.ignoreUnsupportedAnimationDirections.
2236
2237         * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
2238
2239 2012-04-17  Kentaro Hara  <haraken@chromium.org>
2240
2241         [Performance][V8] Skip Isolate look-up to find StringCache
2242         https://bugs.webkit.org/show_bug.cgi?id=84103
2243
2244         Reviewed by Nate Chapin.
2245
2246         This patch improves the performance of a lot of DOM attribute
2247         getters that return a string.
2248
2249         - Improves the performance of Dromaeo/dom-attr.html(element.property)
2250           by 27.7%.
2251         - Improves the performance of Dromaeo/dom-attr.html(getAttribute)
2252           by 10.6%.
2253         - Improves the performance of div.id, div.className,
2254           div.nodeName, text.nodeValue, text.textContent by 12% -- 21%.
2255
2256         The followings are the test results in my Linux desktop.
2257
2258         Performance test: Dromaeo/dom-attr.html
2259         Total:                     674.64runs/s ->  707.03runs/s (+ 4.8%)
2260         getAttribute:             1537.60runs/s -> 1700.20runs/s (+10.6%)
2261         element.property:         1389.00runs/s -> 1774.20runs/s (+27.7%)
2262         setAttribute:              538.88runs/s ->  548.87runs/s (+ 1.9%)
2263         element.property = value:  644.07runs/s ->  656.67runs/s (+ 2.0%)
2264         element.expando = value:   219.76runs/s ->  207.14runs/s (- 6.8%)
2265         element.expando:           578.77runs/s ->  554.67runs/s (- 4.2%)
2266
2267         Performance test: https://bugs.webkit.org/attachment.cgi?id=137440
2268         div.id:           30.70ns -> 26.70ns (+15%)
2269         div.className:    31.10ns -> 26.40ns (+18%)
2270         div.nodeName:     37.70ns -> 33.00ns (+14%)
2271         text.nodeValue:   31.40ns -> 25.90ns (+21%)
2272         text.textContent: 51.50ns -> 45.90ns (+12%)
2273
2274         Previously V8 bindings need to look up an Isolate to find
2275         an Isolate-local StringCache. This patch skips the look-up
2276         by getting the Isolate from AccessorInfo.GetIsolate()
2277         or Arguments.GetIsolate().
2278
2279         No tests. No change in behavior.
2280
2281         * bindings/scripts/CodeGeneratorV8.pm:
2282         (GenerateNormalAttrGetter):
2283         (GenerateFunctionCallString):
2284         (NativeToJSValue):
2285         * bindings/v8/V8Binding.cpp:
2286         (WebCore::getElementStringAttr):
2287         * bindings/v8/V8Binding.h:
2288         (WebCore::v8ExternalString): Make 'isolate' an optional argument.
2289         Ideally we want to make 'isolate' a non-optional argument,
2290         but it is difficult to rewrite all v8ExternalString() callers
2291         at a breath. We can rewrite them incrementally.
2292         (WebCore::v8String): Ditto.
2293         (WebCore::v8StringOrNull): Ditto.
2294         (WebCore::v8StringOrUndefined): Ditto.
2295         (WebCore::v8StringOrFalse): Ditto.
2296
2297         * bindings/scripts/test/V8/V8TestEventConstructor.cpp: Updated run-bindings-tests results.
2298         (WebCore::TestEventConstructorV8Internal::attr1AttrGetter):
2299         (WebCore::TestEventConstructorV8Internal::attr2AttrGetter):
2300         * bindings/scripts/test/V8/V8TestInterface.cpp:
2301         (WebCore::TestInterfaceV8Internal::supplementalStr1AttrGetter):
2302         (WebCore::TestInterfaceV8Internal::supplementalStr2AttrGetter):
2303         * bindings/scripts/test/V8/V8TestObj.cpp:
2304         (WebCore::TestObjV8Internal::readOnlyStringAttrAttrGetter):
2305         (WebCore::TestObjV8Internal::stringAttrAttrGetter):
2306         (WebCore::TestObjV8Internal::reflectedStringAttrAttrGetter):
2307         (WebCore::TestObjV8Internal::reflectedURLAttrAttrGetter):
2308         (WebCore::TestObjV8Internal::reflectedCustomURLAttrAttrGetter):
2309         (WebCore::TestObjV8Internal::stringAttrWithGetterExceptionAttrGetter):
2310         (WebCore::TestObjV8Internal::stringAttrWithSetterExceptionAttrGetter):
2311         (WebCore::TestObjV8Internal::hashAttrGetter):
2312         (WebCore::TestObjV8Internal::conditionalMethod1Callback):
2313
2314 2012-04-17  Kentaro Hara  <haraken@chromium.org>
2315
2316         [V8] Add an optional Isolate argument to wrap()
2317         https://bugs.webkit.org/show_bug.cgi?id=84202
2318
2319         Reviewed by Nate Chapin.
2320
2321         The final objective is to pass Isolate around in V8 bindings.
2322         This patch adds an optional Isolate argument to wrap().
2323         After rewriting all wrap() callers so that they pass Isolate
2324         to wrap(), I'll make the Isolate argument non-optional.
2325
2326         No tests. No change in behavior.
2327
2328         * bindings/scripts/CodeGeneratorV8.pm: Modified as described above.
2329         (GenerateHeader):
2330         * bindings/v8/custom/V8DocumentCustom.cpp: Ditto.
2331         (WebCore::toV8):
2332         * bindings/v8/custom/V8HTMLDocumentCustom.cpp: Ditto.
2333         (WebCore::toV8):
2334         * bindings/v8/custom/V8NodeCustom.cpp: Ditto.
2335         (WebCore::toV8Slow):
2336         * bindings/v8/custom/V8SVGDocumentCustom.cpp: Ditto.
2337         (WebCore::toV8):
2338         * dom/make_names.pl: Ditto.
2339         (printWrapperFactoryCppFile):
2340
2341         * bindings/scripts/test/V8/V8Float64Array.h:
2342         Updated run-bindings-tests results.
2343         (V8Float64Array):
2344         (WebCore::V8Float64Array::wrap):
2345         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
2346         (V8TestActiveDOMObject):
2347         (WebCore::V8TestActiveDOMObject::wrap):
2348         (WebCore::toV8):
2349         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
2350         (V8TestCustomNamedGetter):
2351         (WebCore::V8TestCustomNamedGetter::wrap):
2352         (WebCore::toV8):
2353         * bindings/scripts/test/V8/V8TestEventConstructor.h:
2354         (V8TestEventConstructor):
2355         (WebCore::V8TestEventConstructor::wrap):
2356         (WebCore::toV8):
2357         * bindings/scripts/test/V8/V8TestEventTarget.h:
2358         (V8TestEventTarget):
2359         (WebCore::V8TestEventTarget::wrap):
2360         (WebCore::toV8):
2361         * bindings/scripts/test/V8/V8TestInterface.h:
2362         (V8TestInterface):
2363         (WebCore::V8TestInterface::wrap):
2364         (WebCore::toV8):
2365         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
2366         (V8TestMediaQueryListListener):
2367         (WebCore::V8TestMediaQueryListListener::wrap):
2368         (WebCore::toV8):
2369         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
2370         (V8TestNamedConstructor):
2371         (WebCore::V8TestNamedConstructor::wrap):
2372         (WebCore::toV8):
2373         * bindings/scripts/test/V8/V8TestNode.h:
2374         (V8TestNode):
2375         (WebCore::V8TestNode::wrap):
2376         (WebCore::toV8):
2377         * bindings/scripts/test/V8/V8TestObj.h:
2378         (V8TestObj):
2379         (WebCore::V8TestObj::wrap):
2380         (WebCore::toV8):
2381         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2382         (V8TestSerializedScriptValueInterface):
2383         (WebCore::V8TestSerializedScriptValueInterface::wrap):
2384         (WebCore::toV8):
2385
2386 2012-04-17  Kentaro Hara  <haraken@chromium.org>
2387
2388         [V8] Pass Isolate to toV8Slow()
2389         https://bugs.webkit.org/show_bug.cgi?id=84173
2390
2391         Reviewed by Nate Chapin.
2392
2393         The final objective is to pass Isolate around in V8 bindings.
2394         This patch passes the Isolate to toV8Slow().
2395
2396         No tests. No change in behavior.
2397
2398         * bindings/scripts/CodeGeneratorV8.pm:
2399         (GenerateHeader):
2400         * bindings/v8/custom/V8NodeCustom.cpp:
2401         (WebCore::toV8Slow):
2402
2403 2012-04-17  Kentaro Hara  <haraken@chromium.org>
2404
2405         [V8] Add an optional Isolate argument to toV8().
2406         https://bugs.webkit.org/show_bug.cgi?id=84161
2407
2408         Reviewed by Nate Chapin.
2409
2410         The final objective is to pass Isolate around in V8 bindings.
2411         This patch adds an optional Isolate argument to toV8().
2412         After rewriting all toV8() callers so that they pass Isolate,
2413         I will make the Isolate argument non-optional.
2414
2415         No tests. No change in behavior.
2416
2417         * bindings/scripts/CodeGeneratorV8.pm:
2418         Modified as described above.
2419         (GenerateHeader):
2420         (NativeToJSValue):
2421         * bindings/v8/custom/V8BlobCustom.cpp:
2422         (WebCore::toV8):
2423         * bindings/v8/custom/V8CSSRuleCustom.cpp:
2424         (WebCore::toV8):
2425         * bindings/v8/custom/V8CSSStyleSheetCustom.cpp:
2426         (WebCore::toV8):
2427         * bindings/v8/custom/V8CSSValueCustom.cpp:
2428         (WebCore::toV8):
2429         * bindings/v8/custom/V8CanvasPixelArrayCustom.cpp:
2430         (WebCore::toV8):
2431         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
2432         (WebCore::toV8):
2433         * bindings/v8/custom/V8DOMTokenListCustom.cpp:
2434         (WebCore::toV8):
2435         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2436         (WebCore::toV8):
2437         * bindings/v8/custom/V8DataViewCustom.cpp:
2438         (WebCore::toV8):
2439         * bindings/v8/custom/V8DocumentCustom.cpp:
2440         (WebCore::toV8):
2441         * bindings/v8/custom/V8EntryCustom.cpp:
2442         (WebCore::toV8):
2443         * bindings/v8/custom/V8EntrySyncCustom.cpp:
2444         (WebCore::toV8):
2445         * bindings/v8/custom/V8EventCustom.cpp:
2446         (WebCore::toV8):
2447         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
2448         (WebCore::toV8):
2449         * bindings/v8/custom/V8Float64ArrayCustom.cpp:
2450         (WebCore::toV8):
2451         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
2452         (WebCore::toV8):
2453         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
2454         (WebCore::toV8):
2455         * bindings/v8/custom/V8HTMLElementCustom.cpp:
2456         (WebCore::toV8):
2457         * bindings/v8/custom/V8IDBAnyCustom.cpp:
2458         (WebCore::toV8):
2459         * bindings/v8/custom/V8IDBKeyCustom.cpp:
2460         (WebCore::toV8):
2461         * bindings/v8/custom/V8ImageDataCustom.cpp:
2462         (WebCore::toV8):
2463         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
2464         (WebCore::toV8):
2465         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
2466         (WebCore::toV8):
2467         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
2468         (WebCore::toV8):
2469         * bindings/v8/custom/V8LocationCustom.cpp:
2470         (WebCore::toV8):
2471         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
2472         (WebCore::toV8):
2473         * bindings/v8/custom/V8NodeCustom.cpp:
2474         (WebCore::toV8Slow):
2475         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
2476         (WebCore::toV8):
2477         * bindings/v8/custom/V8SVGElementCustom.cpp:
2478         (WebCore::toV8):
2479         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
2480         (WebCore::toV8):
2481         * bindings/v8/custom/V8ScriptProfileCustom.cpp:
2482         (WebCore::toV8):
2483         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp:
2484         (WebCore::toV8):
2485         * bindings/v8/custom/V8StyleSheetCustom.cpp:
2486         (WebCore::toV8):
2487         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
2488         (WebCore::toV8):
2489         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
2490         (WebCore::toV8):
2491         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
2492         (WebCore::toV8):
2493         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp:
2494         (WebCore::toV8):
2495         * bindings/v8/custom/V8WorkerContextCustom.cpp:
2496         (WebCore::toV8):
2497
2498         * bindings/scripts/test/V8/V8Float64Array.h:
2499         Updated run-bindings-tests results.
2500         (WebCore):
2501         (WebCore::toV8):
2502         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
2503         (WebCore::toV8):
2504         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
2505         (WebCore::toV8):
2506         * bindings/scripts/test/V8/V8TestEventConstructor.h:
2507         (WebCore::toV8):
2508         * bindings/scripts/test/V8/V8TestEventTarget.h:
2509         (WebCore::toV8):
2510         * bindings/scripts/test/V8/V8TestInterface.h:
2511         (WebCore::toV8):
2512         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
2513         (WebCore::toV8):
2514         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
2515         (WebCore::toV8):
2516         * bindings/scripts/test/V8/V8TestNode.h:
2517         (WebCore::toV8):
2518         * bindings/scripts/test/V8/V8TestObj.h:
2519         (WebCore::toV8):
2520         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2521         (WebCore::toV8):
2522
2523 2012-04-23  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
2524         [EFL][WK2] Fix build break when non-cross platform CONTEXT_MENUS are enabled.
2525         https://bugs.webkit.org/show_bug.cgi?id=84136
2526
2527         Reviewed by Andreas Kling.
2528
2529         There was a mismatch between contextMenuItemVector declaration and definition.
2530         Fixed by changing PlatformMenuDescription for EFL port by adding a const modifier.
2531
2532         No new tests required.
2533
2534         * platform/PlatformMenuDescription.h:
2535         (WebCore): Added const modifier to PlatformMenuDescription definition.
2536
2537 2012-04-23  Pierre Rossi  <pierre.rossi@gmail.com>
2538
2539         [Qt] Ensure zero-width space effectively accounts for a width of zero.
2540         https://bugs.webkit.org/show_bug.cgi?id=84595
2541
2542         Reviewed by Simon Hausmann.
2543
2544         The logic so far relies on FontCache::getFontDataForCharacters to
2545         return a valid fontData in the case where the fonts specified don't
2546         have a glyph for the zero-width space character.
2547         QTextLayout::glyphRuns simply ignores characters that don't render in
2548         the glyph runs it returns, so we need to ensure that the subsequent
2549         call to platformWidthForGlyph doesn't lead to a non-zero width.
2550
2551         Covered by tests containing control characters such as
2552         a soft-hyphen like it's the case in:
2553         svg/as-image/img-preserveAspectRatio-support-1.html
2554
2555         * platform/graphics/qt/SimpleFontDataQt.cpp:
2556         (WebCore::SimpleFontData::platformWidthForGlyph):
2557
2558 2012-04-23  Ian Vollick  <vollick@chromium.org>
2559
2560         [chromium] When prepareToDraw fails due to animation checkerboard, we need to call setNeedsCommit
2561         https://bugs.webkit.org/show_bug.cgi?id=84520
2562
2563         Reviewed by Adrienne Walker.
2564
2565         Tested in CCLayerTreeHostImplTest.prepareToDrawFailsWhenAnimationUsesCheckerboard
2566
2567         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2568         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
2569
2570 2012-04-23  Alexis Menard  <alexis.menard@openbossa.org>
2571
2572         Simplify CSSParser::parseFont.
2573         https://bugs.webkit.org/show_bug.cgi?id=78698
2574
2575         Reviewed by Antti Koivisto.
2576
2577         Simplify parseFont by sharing the code we have for
2578         the longhands of the font property.
2579
2580         No new tests : Extend the existing font shorthand test and modify expected files
2581         as now the order of the longhands added in the property list of the style
2582         has changed. It's very unlikely that some code is relying on this order though. It will
2583         also match the way the spec order them http://www.w3.org/TR/css3-fonts/#font-prop
2584         even though the order is arbitrary for some values.
2585
2586         * css/CSSParser.cpp:
2587         (WebCore::CSSParser::parseValue):
2588         (WebCore::CSSParser::parseFont):
2589         (WebCore::CSSParser::parseLineHeight):
2590         (WebCore):
2591         (WebCore::CSSParser::parseFontSize):
2592         (WebCore::CSSParser::parseFontWeight):  Fix a bug discovered while using parseFontWeight from
2593         the parseFont (case font: 0/0, Arial, sans-serif; in a layout test), we should return true only
2594         when we add something in the property list.
2595         * css/CSSParser.h:
2596
2597 2012-04-23  Yury Semikhatsky  <yurys@chromium.org>
2598
2599         Web Inspector: improve the way heap snapshot diff is calculated
2600         https://bugs.webkit.org/show_bug.cgi?id=84590
2601
2602         Diff calculation now consists of the following steps:
2603         1. Collect data about nodes in the base heap snapshot
2604         2. Pass it to the second snapshot.
2605         3. Calculate delta for each class.
2606
2607         Reviewed by Pavel Feldman.
2608
2609         * inspector/front-end/HeapSnapshot.js:
2610         (WebInspector.HeapSnapshot):
2611         (WebInspector.HeapSnapshot.prototype.dispose):
2612         (WebInspector.HeapSnapshot.prototype.aggregatesForDiff):
2613         (WebInspector.HeapSnapshot.prototype.calculateSnapshotDiff):
2614         (WebInspector.HeapSnapshot.prototype._calculateDiffForClass):
2615         (WebInspector.HeapSnapshot.prototype.createAddedNodesProvider):
2616         (WebInspector.HeapSnapshot.prototype.createDeletedNodesProvider):
2617         * inspector/front-end/HeapSnapshotDataGrids.js:
2618         (WebInspector.HeapSnapshotDiffDataGrid.prototype._populateChildren.aggregatesForDiffReceived.didCalculateSnapshotDiff):
2619         (WebInspector.HeapSnapshotDiffDataGrid.prototype._populateChildren):
2620         * inspector/front-end/HeapSnapshotGridNodes.js:
2621         (WebInspector.HeapSnapshotIteratorsTuple):
2622         (WebInspector.HeapSnapshotDiffNode):
2623         (WebInspector.HeapSnapshotDiffNode.prototype._createChildNode):
2624         (WebInspector.HeapSnapshotDiffNode.prototype._createNodesProvider):
2625         * inspector/front-end/HeapSnapshotProxy.js:
2626         (WebInspector.HeapSnapshotProxy.prototype.aggregatesForDiff):
2627         (WebInspector.HeapSnapshotProxy.prototype.calculateSnapshotDiff):
2628         (WebInspector.HeapSnapshotProxy.prototype.createAddedNodesProvider):
2629         (WebInspector.HeapSnapshotProxy.prototype.createDeletedNodesProvider):
2630         * inspector/front-end/HeapSnapshotView.js:
2631         (WebInspector.HeapSnapshotView.prototype._changeBase):
2632
2633 2012-04-23  Pavel Feldman  <pfeldman@chromium.org>
2634
2635         Web Inspector: Rename and extract UISourceCodeImpl into JavaScriptSource
2636         https://bugs.webkit.org/show_bug.cgi?id=84587
2637
2638         Reviewed by Yury Semikhatsky.
2639
2640         No changes other than extraction here. This is the first step in the Resource
2641         hierarchy refactoring described in bug 84586.
2642
2643         * WebCore.gypi:
2644         * WebCore.vcproj/WebCore.vcproj:
2645         * inspector/compile-front-end.py:
2646         * inspector/front-end/CompilerScriptMapping.js:
2647         (WebInspector.CompilerScriptMapping.prototype.addScript):
2648         * inspector/front-end/DebuggerPresentationModel.js:
2649         * inspector/front-end/JavaScriptSource.js: Added.
2650         (WebInspector.JavaScriptSource):
2651         (WebInspector.JavaScriptSource.prototype.breakpoints):
2652         (WebInspector.JavaScriptSource.prototype.breakpointAdded):
2653         (WebInspector.JavaScriptSource.prototype.breakpointRemoved):
2654         (WebInspector.JavaScriptSource.prototype.consoleMessages):
2655         (WebInspector.JavaScriptSource.prototype.consoleMessageAdded):
2656         (WebInspector.JavaScriptSource.prototype.consoleMessagesCleared):
2657         * inspector/front-end/RawSourceCode.js:
2658         (WebInspector.RawSourceCode.prototype._createUISourceCode):
2659         * inspector/front-end/SnippetsModel.js:
2660         (WebInspector.SnippetsScriptMapping.prototype._snippetAdded):
2661         (WebInspector.SnippetsScriptMapping.prototype._createUISourceCodeForScript):
2662         * inspector/front-end/WebKit.qrc:
2663         * inspector/front-end/inspector.html:
2664
2665 2012-04-23  Gavin Peters  <gavinp@chromium.org>
2666
2667         Move ReferrerPolicy out of SecurityPolicy class into its own header in platform.
2668         https://bugs.webkit.org/show_bug.cgi?id=84516
2669
2670         Reviewed by Adam Barth.
2671
2672         No change in behaviour; same enum, different class.
2673
2674         * GNUmakefile.list.am:
2675         * Target.pri:
2676         * WebCore.exp.in:
2677         * WebCore.gypi:
2678         * WebCore.vcproj/WebCore.vcproj:
2679         * WebCore.xcodeproj/project.pbxproj:
2680         * dom/Document.cpp:
2681         (WebCore::Document::Document):
2682         (WebCore::Document::processReferrerPolicy):
2683         * dom/Document.h:
2684         (WebCore::Document::referrerPolicy):
2685         (Document):
2686         * page/SecurityPolicy.h:
2687         * platform/ReferrerPolicy.h: Added.
2688         (WebCore):
2689
2690 2012-04-23  Vineet Chaudhary  <rgf748@motorola.com>
2691
2692         JS binding code generator doesn't handle "attribute unsigned long[]" well
2693         https://bugs.webkit.org/show_bug.cgi?id=84540
2694
2695         Reviewed by Kentaro Hara.
2696
2697         Codegenerator should handle spaces with the sequence<> to support
2698         numeric types like "unsigned long", "int" .. etc. and primitive types
2699         like "boolean", "Date" etc.
2700
2701         Tests: bindings/scripts/test/TestObj.idl
2702
2703         * bindings/scripts/CodeGenerator.pm:
2704         (SkipIncludeHeader): Rename AvoidInclusionOfType to SkipIncludeHeader.
2705         (GetArrayType):
2706         * bindings/scripts/CodeGeneratorJS.pm:
2707         (AddIncludesForType):
2708         (NativeToJSValue):
2709         * bindings/scripts/CodeGeneratorObjC.pm:
2710         (AddIncludesForType):
2711         (GenerateImplementation):
2712         * bindings/scripts/CodeGeneratorV8.pm:
2713         (AddIncludesForType):
2714         (GetHeaderClassInclude):
2715         (GenerateNormalAttrGetter):
2716         (NativeToJSValue):
2717         * bindings/scripts/IDLStructure.pm:
2718         * bindings/scripts/test/JS/JSTestObj.cpp:
2719         (WebCore):
2720         (WebCore::jsTestObjIntSequenceAttr):
2721         (WebCore::jsTestObjShortSequenceAttr):
2722         (WebCore::jsTestObjLongSequenceAttr):
2723         (WebCore::jsTestObjLongLongSequenceAttr):
2724         (WebCore::jsTestObjUnsignedIntSequenceAttr):
2725         (WebCore::jsTestObjUnsignedShortSequenceAttr):
2726         (WebCore::jsTestObjUnsignedLongSequenceAttr):
2727         (WebCore::jsTestObjUnsignedLongLongSequenceAttr):
2728         (WebCore::jsTestObjFloatSequenceAttr):
2729         (WebCore::jsTestObjDoubleSequenceAttr):
2730         (WebCore::jsTestObjBooleanSequenceAttr):
2731         (WebCore::jsTestObjVoidSequenceAttr):
2732         (WebCore::jsTestObjDateSequenceAttr):
2733         (WebCore::setJSTestObjSequenceAttr):
2734         (WebCore::setJSTestObjIntSequenceAttr):
2735         (WebCore::setJSTestObjShortSequenceAttr):
2736         (WebCore::setJSTestObjLongSequenceAttr):
2737         (WebCore::setJSTestObjLongLongSequenceAttr):
2738         (WebCore::setJSTestObjUnsignedIntSequenceAttr):
2739         (WebCore::setJSTestObjUnsignedShortSequenceAttr):
2740         (WebCore::setJSTestObjUnsignedLongSequenceAttr):
2741         (WebCore::setJSTestObjUnsignedLongLongSequenceAttr):
2742         (WebCore::setJSTestObjFloatSequenceAttr):
2743         (WebCore::setJSTestObjDoubleSequenceAttr):
2744         (WebCore::setJSTestObjBooleanSequenceAttr):
2745         (WebCore::setJSTestObjVoidSequenceAttr):
2746         (WebCore::setJSTestObjDateSequenceAttr):
2747         * bindings/scripts/test/JS/JSTestObj.h:
2748         (WebCore):
2749         * bindings/scripts/test/ObjC/DOMTestObj.h:
2750         * bindings/scripts/test/TestObj.idl:
2751         * bindings/scripts/test/V8/V8TestObj.cpp:
2752         (WebCore::TestObjV8Internal::intSequenceAttrAttrGetter):
2753         (TestObjV8Internal):
2754         (WebCore::TestObjV8Internal::intSequenceAttrAttrSetter):
2755         (WebCore::TestObjV8Internal::shortSequenceAttrAttrGetter):
2756         (WebCore::TestObjV8Internal::shortSequenceAttrAttrSetter):
2757         (WebCore::TestObjV8Internal::longSequenceAttrAttrGetter):
2758         (WebCore::TestObjV8Internal::longSequenceAttrAttrSetter):
2759         (WebCore::TestObjV8Internal::longLongSequenceAttrAttrGetter):
2760         (WebCore::TestObjV8Internal::longLongSequenceAttrAttrSetter):
2761         (WebCore::TestObjV8Internal::unsignedIntSequenceAttrAttrGetter):
2762         (WebCore::TestObjV8Internal::unsignedIntSequenceAttrAttrSetter):
2763         (WebCore::TestObjV8Internal::unsignedShortSequenceAttrAttrGetter):
2764         (WebCore::TestObjV8Internal::unsignedShortSequenceAttrAttrSetter):
2765         (WebCore::TestObjV8Internal::unsignedLongSequenceAttrAttrGetter):
2766         (WebCore::TestObjV8Internal::unsignedLongSequenceAttrAttrSetter):
2767         (WebCore::TestObjV8Internal::unsignedLongLongSequenceAttrAttrGetter):
2768         (WebCore::TestObjV8Internal::unsignedLongLongSequenceAttrAttrSetter):
2769         (WebCore::TestObjV8Internal::floatSequenceAttrAttrGetter):
2770         (WebCore::TestObjV8Internal::floatSequenceAttrAttrSetter):
2771         (WebCore::TestObjV8Internal::doubleSequenceAttrAttrGetter):
2772         (WebCore::TestObjV8Internal::doubleSequenceAttrAttrSetter):
2773         (WebCore::TestObjV8Internal::booleanSequenceAttrAttrGetter):
2774         (WebCore::TestObjV8Internal::booleanSequenceAttrAttrSetter):
2775         (WebCore::TestObjV8Internal::voidSequenceAttrAttrGetter):
2776         (WebCore::TestObjV8Internal::voidSequenceAttrAttrSetter):
2777         (WebCore::TestObjV8Internal::dateSequenceAttrAttrGetter):
2778         (WebCore::TestObjV8Internal::dateSequenceAttrAttrSetter):
2779         (WebCore):
2780
2781 2012-04-23  Andreas Kling  <kling@webkit.org>
2782
2783         Unreviewed assertion fix for Chromium bots.
2784
2785         Skip unnecessary Attr::attachToElement() after constructing an Attr using the
2786         constructor that attaches to an Element.
2787
2788         * dom/ElementAttributeData.cpp:
2789         (WebCore::ElementAttributeData::ensureAttr):
2790
2791 2012-04-23  Andreas Kling  <kling@webkit.org>
2792
2793         REGRESSION(r114870): Assertion failure in ElementAttributeData::setAttr().
2794         <http://webkit.org/b/84581>
2795
2796         Reviewed by Antti Koivisto.
2797
2798         Attach the Attr and bump m_attrCount manually in ensureAttr() instead of calling
2799         setAttr(). The latter asserts that the Attr isn't present in the map, which
2800         obviously isn't true after we've just added it.
2801
2802         This has the added effect of removing one unnecessary hash lookup.
2803
2804         * dom/ElementAttributeData.cpp:
2805         (WebCore::ElementAttributeData::ensureAttr):
2806
2807 2012-04-23  Pavel Feldman  <pfeldman@chromium.org>
2808
2809         Web Inspector: make ParsedURL.prototype.displayName data url friendly.
2810         https://bugs.webkit.org/show_bug.cgi?id=84578
2811
2812         Reviewed by Yury Semikhatsky.
2813
2814         We'd like to define valid URL as the one that has scheme, host and path.
2815         We can append to this URL and manipulate its content. We still want 
2816         possibly invalid specs (such as data or about) to exist and have nice
2817         display names.
2818
2819         * inspector/front-end/ResourceUtils.js:
2820         (WebInspector.ParsedURL):
2821         (WebInspector.ParsedURL.prototype.get displayName):
2822
2823 2012-04-23  Pavel Feldman  <pfeldman@chromium.org>
2824
2825         Web Inspector: introduce String.prototype.starts/endsWith and use it all over the place.
2826         https://bugs.webkit.org/show_bug.cgi?id=84574
2827
2828         Reviewed by Yury Semikhatsky.
2829
2830         * inspector/front-end/AuditRules.js:
2831         (WebInspector.AuditRules.VendorPrefixedCSSProperties.prototype.visitProperty):
2832         * inspector/front-end/BreakpointsSidebarPane.js:
2833         (WebInspector.EventListenerBreakpointsSidebarPane.prototype._setBreakpoint):
2834         (WebInspector.EventListenerBreakpointsSidebarPane.prototype._removeBreakpoint):
2835         * inspector/front-end/CSSCompletions.js:
2836         (WebInspector.CSSCompletions.prototype.startsWith):
2837         (WebInspector.CSSCompletions.prototype._firstIndexOfPrefix):
2838         * inspector/front-end/ConsoleView.js:
2839         (WebInspector.ConsoleView.prototype._reportCompletions):
2840         * inspector/front-end/CookieItemsView.js:
2841         (WebInspector.Cookies.cookieMatchesResourceURL):
2842         * inspector/front-end/DatabaseQueryView.js:
2843         (WebInspector.DatabaseQueryView.prototype.completions):
2844         * inspector/front-end/ElementsTreeOutline.js:
2845         (WebInspector.ElementsTreeElement.prototype._buildAttributeDOM):
2846         * inspector/front-end/ProfileView.js:
2847         * inspector/front-end/ProfilesPanel.js:
2848         (WebInspector.ProfilesPanel.prototype.addProfileHeader):
2849         (WebInspector.ProfilesPanel.prototype.displayTitleForProfileLink):
2850         (WebInspector.ProfileSidebarTreeElement):
2851         (WebInspector.ProfileSidebarTreeElement.prototype.get mainTitle):
2852         * inspector/front-end/ResourceUtils.js:
2853         (WebInspector.ParsedURL):
2854         (WebInspector.displayNameForURL):
2855         (WebInspector.linkifyStringAsFragmentWithCustomLinkifier):
2856         (WebInspector.completeURL):
2857         * inspector/front-end/SnippetsModel.js:
2858         (WebInspector.SnippetsModel.prototype.snippetIdForSourceURL):
2859         * inspector/front-end/SourceCSSTokenizer.js:
2860         (WebInspector.SourceCSSTokenizer.prototype.nextToken):
2861         * inspector/front-end/SourceCSSTokenizer.re2js:
2862         * inspector/front-end/TextPrompt.js:
2863         (WebInspector.TextPrompt.prototype._completeCommonPrefix):
2864         * inspector/front-end/UIUtils.js:
2865         (WebInspector.startEditing):
2866         * inspector/front-end/utilities.js:
2867
2868 2012-04-23  Andreas Kling  <kling@webkit.org>
2869
2870         REGRESSION(r114870): Performance hit on DOM/CloneNodes and DOM/CreateNodes.
2871         <http://webkit.org/b/84575>
2872
2873         Reviewed by Antti Koivisto.
2874
2875         Simplify the cloning of Attributes from one Element to another by simply
2876         assigning to m_attributes. This avoids default-constructing a bunch of
2877         Attribute objects that we overwrite immediately anyway (this used to be
2878         fine because they were RefPtr<Attribute> but now that a default-constructed
2879         Attribute contains a QualifiedName, we were doing a bunch of extra hash
2880         lookups, etc.)
2881
2882         * dom/ElementAttributeData.cpp:
2883         (WebCore::ElementAttributeData::setAttributes):
2884
2885 2012-04-20  Pavel Feldman  <pfeldman@chromium.org>
2886
2887         Web Inspector: implement "open stylesheet" dialog.
2888         https://bugs.webkit.org/show_bug.cgi?id=84466
2889
2890         Reviewed by Yury Semikhatsky.
2891
2892         This change introduces abstract OpenResourceDialog and re-uses it in OpenScriptDialog and OpenStylesheetDialog.
2893         Drive-by fix for data: url representation in the navigator and open resource dialogs.
2894
2895         * inspector/front-end/FilteredItemSelectionDialog.js:
2896         (WebInspector.FilteredItemSelectionDialog.prototype.position):
2897         (WebInspector.OpenResourceDialog.filterOutEmptyURLs):
2898         (WebInspector.OpenResourceDialog.compareFunction):
2899         (WebInspector.OpenResourceDialog):
2900         (WebInspector.OpenResourceDialog.prototype.itemTitleAt):
2901         (WebInspector.OpenResourceDialog.prototype.itemKeyAt):
2902         (WebInspector.OpenResourceDialog.prototype.itemsCount):
2903         (WebInspector.OpenResourceDialog.prototype.requestItems):
2904         (WebInspector.OpenResourceDialog.prototype.selectItem):
2905         (WebInspector.OpenScriptDialog):
2906         (WebInspector.OpenScriptDialog.install):
2907         (WebInspector.OpenScriptDialog._show):
2908         (WebInspector.OpenScriptDialog.prototype.selectItem):
2909         * inspector/front-end/ResourceUtils.js:
2910         (WebInspector.ParsedURL):
2911         * inspector/front-end/ScriptsPanel.js:
2912         * inspector/front-end/StylesPanel.js:
2913         (WebInspector.StylesPanel):
2914         (WebInspector.StylesPanel.prototype._showOpenStylesheetDialog):
2915         (WebInspector.OpenStylesheetDialog):
2916         (WebInspector.OpenStylesheetDialog.prototype.selectItem):
2917         * inspector/front-end/inspector.html:
2918
2919 2012-04-23  Kent Tamura  <tkent@chromium.org>
2920
2921         Add test function to get placeholder string
2922         https://bugs.webkit.org/show_bug.cgi?id=84536
2923
2924         Reviewed by Ryosuke Niwa.
2925
2926         Add window.internals.visiblePlaceholder(element), which returns a
2927         placeholder string only when it's visible.
2928
2929         * WebCore.exp.in: Expose HTMLTextFormControlElement::placeholderShouldBeVisible().
2930         * testing/Internals.cpp:
2931         (WebCore::Internals::visiblePlaceholder): Added.
2932         (WebCore::Internals::selectColorInColorChooser): Omit HTMLNames::.
2933         * testing/Internals.h:
2934         (Internals): Add visiblePlaceholder().
2935         * testing/Internals.idl: ditto.
2936
2937 2012-04-23  Szilard Ledan  <szledan@inf.u-szeged.hu>
2938
2939         Incorrect handling of CSS escape sequences that encode surrogates
2940         https://bugs.webkit.org/show_bug.cgi?id=76152
2941
2942         Reviewed by Kent Tamura.
2943
2944         Test: fast/css/parsing-css-surrogate-pairs.html
2945
2946         * css/CSSParser.cpp:
2947         (WebCore::CSSParser::parseEscape):
2948
2949 2012-04-22  Yury Semikhatsky  <yurys@chromium.org>
2950
2951         Web Inspector: make populateChildren methods private in heap profiler front-end
2952         https://bugs.webkit.org/show_bug.cgi?id=84562
2953
2954         - populateChildren method on HeapSnapshotConstructorsDataGrid and
2955         HeapSnapshotDiffDataGrid now is private.
2956         - Made _defaultPopulateCount a public method on HeapSnapshotSortableDataGrid which
2957         is overriden in some descendants
2958         - Removed unused HeapSnapshotPathFinderProxy
2959         - added closure compiler annotations
2960
2961         Reviewed by Pavel Feldman.
2962
2963         * inspector/front-end/HeapSnapshotDataGrids.js:
2964         (WebInspector.HeapSnapshotSortableDataGrid.prototype.defaultPopulateCount):
2965         (WebInspector.HeapSnapshotConstructorsDataGrid.prototype.setDataSource):
2966         (WebInspector.HeapSnapshotConstructorsDataGrid.prototype._filterSelectIndexChanged):
2967         (WebInspector.HeapSnapshotDiffDataGrid.prototype.defaultPopulateCount):
2968         (WebInspector.HeapSnapshotDiffDataGrid.prototype.setBaseDataSource):
2969         (WebInspector.HeapSnapshotDominatorsDataGrid.prototype.defaultPopulateCount):
2970         * inspector/front-end/HeapSnapshotGridNodes.js:
2971         (WebInspector.HeapSnapshotGridNode):
2972         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren.callSerialize):
2973         (WebInspector.HeapSnapshotDiffNode):
2974         (WebInspector.HeapSnapshotDiffNode.prototype.populateChildren.firstProviderPopulated):
2975         * inspector/front-end/HeapSnapshotProxy.js:
2976
2977 2012-04-22  Andreas Kling  <kling@webkit.org>
2978
2979         Unreviewed build fix, remove Attribute.cpp from DOMAllInOne.cpp.
2980
2981         * dom/DOMAllInOne.cpp: My nemesis.
2982
2983 2012-04-22  Andreas Kling  <kling@webkit.org>
2984
2985         Optimize Element attribute storage for the common case (no Attr objects.)
2986         <http://webkit.org/b/83440>
2987
2988         Reviewed by Antti Koivisto.
2989
2990         Reduce Attribute to its smallest possible size; a qname/value pair.
2991         They are no-longer ref-counted, which allows us to store them in Vectors.
2992
2993         Refactored the DOM Attr object to go with the new Attribute:
2994         Attr now wraps either {element, qname} or {qname, value}. The latter is for
2995         the case where a standalone Attr object is instantiated via DOM APIs.
2996
2997         ElementAttributeData.cpp manages a map of pair<element, qname> => Attr.
2998         Each Element (well, ElementAttributeData) keeps track of how many Attr
2999         objects are pointing to it. This is so we can avoid hash lookups during
3000         common operations in the typical case where you have zero Attrs.
3001
3002         Also removed the inline capacity (was 4) from AttributeVector as that
3003         would significantly increase bloat now that we store Attribute (2 pointers)
3004         rather than RefPtr<Attribute>. We trade this one piece of indirection
3005         for the removal of per-Attribute indirection.
3006
3007         * CMakeLists.txt:
3008         * GNUmakefile.list.am:
3009         * Target.pri:
3010         * WebCore.gypi:
3011         * WebCore.vcproj/WebCore.vcproj:
3012         * WebCore.xcodeproj/project.pbxproj:
3013         * dom/Attr.cpp:
3014         (WebCore::Attr::Attr):
3015         (WebCore):
3016         (WebCore::Attr::create):
3017         (WebCore::Attr::~Attr):
3018         (WebCore::Attr::createTextChild):
3019         (WebCore::Attr::setPrefix):
3020         (WebCore::Attr::setValue):
3021         (WebCore::Attr::cloneNode):
3022         (WebCore::Attr::childrenChanged):
3023         (WebCore::Attr::style):
3024         (WebCore::Attr::value):
3025         (WebCore::Attr::elementAttribute):
3026         (WebCore::Attr::detachFromElementWithValue):
3027         (WebCore::Attr::attachToElement):
3028         * dom/Attr.h:
3029         (WebCore):
3030         (Attr):
3031         (WebCore::Attr::qualifiedName):
3032         (WebCore::Attr::localName):
3033         (WebCore::Attr::namespaceURI):
3034         (WebCore::Attr::prefix):
3035         * dom/Attribute.cpp: Removed.
3036         * dom/Attribute.h:
3037         (WebCore::Attribute::Attribute):
3038         (Attribute):
3039         * dom/Document.cpp:
3040         (WebCore::Document::importNode):
3041         (WebCore::Document::createAttributeNS):
3042         * dom/Element.cpp:
3043         (WebCore::Element::~Element):
3044         (WebCore::Element::detachAttribute):
3045         (WebCore):
3046         (WebCore::Element::removeAttribute):
3047         (WebCore::Element::setAttributeInternal):
3048         (WebCore::Element::parserSetAttributes):
3049         (WebCore::Element::setAttributeNode):
3050         (WebCore::Element::removeAttributeNode):
3051         (WebCore::Element::normalizeAttributes):
3052         (WebCore::Element::didRemoveAttribute):
3053         (WebCore::Element::attrIfExists):
3054         (WebCore::Element::ensureAttr):
3055         * dom/Element.h:
3056         (Element):
3057         (WebCore::Element::getAttributeItemIndex):
3058         * dom/ElementAttributeData.cpp:
3059         (WebCore):
3060         (WebCore::attrMap):
3061         (WebCore::ElementAttributeData::attrIfExists):
3062         (WebCore::ElementAttributeData::ensureAttr):
3063         (WebCore::ElementAttributeData::setAttr):
3064         (WebCore::ElementAttributeData::removeAttr):
3065         (WebCore::AttributeVector::removeAttribute):
3066         (WebCore::ElementAttributeData::~ElementAttributeData):
3067         (WebCore::ElementAttributeData::addAttribute):
3068         (WebCore::ElementAttributeData::removeAttribute):
3069         (WebCore::ElementAttributeData::isEquivalent):
3070         (WebCore::ElementAttributeData::detachAttributesFromElement):
3071         (WebCore::ElementAttributeData::getAttributeItemIndexSlowCase):
3072         (WebCore::ElementAttributeData::setAttributes):
3073         (WebCore::ElementAttributeData::clearAttributes):
3074         (WebCore::ElementAttributeData::replaceAttribute):
3075         (WebCore::ElementAttributeData::getAttributeNode):
3076         * dom/ElementAttributeData.h:
3077         (WebCore):
3078         (WebCore::AttributeVector::AttributeVector):
3079         (AttributeVector):
3080         (WebCore::AttributeVector::getAttributeItem):
3081         (WebCore::AttributeVector::getAttributeItemIndex):
3082         (WebCore::AttributeVector::insertAttribute):
3083         (WebCore::ElementAttributeData::attributeItem):
3084         (ElementAttributeData):
3085         (WebCore::ElementAttributeData::ElementAttributeData):
3086         (WebCore::ElementAttributeData::attributeVector):
3087         (WebCore::ElementAttributeData::clonedAttributeVector):
3088         (WebCore::ElementAttributeData::removeAttribute):
3089         (WebCore::ElementAttributeData::getAttributeItem):
3090         (WebCore::ElementAttributeData::getAttributeItemIndex):
3091         * dom/NamedNodeMap.cpp:
3092         (WebCore::NamedNodeMap::getNamedItem):
3093         (WebCore::NamedNodeMap::getNamedItemNS):
3094         (WebCore::NamedNodeMap::removeNamedItem):
3095         (WebCore::NamedNodeMap::removeNamedItemNS):
3096         (WebCore::NamedNodeMap::item):
3097         * dom/Node.cpp:
3098         (WebCore::Node::compareDocumentPosition):
3099         * html/HTMLAnchorElement.cpp:
3100         (WebCore::HTMLAnchorElement::parseAttribute):
3101         * html/HTMLSelectElement.cpp:
3102         (WebCore::HTMLSelectElement::parseAttribute):
3103         * html/parser/HTMLConstructionSite.cpp:
3104         (WebCore::HTMLConstructionSite::insertHTMLHtmlStartTagBeforeHTML):
3105         (WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement):
3106         (WebCore::HTMLConstructionSite::insertScriptElement):
3107         (WebCore::HTMLConstructionSite::createElement):
3108         (WebCore::HTMLConstructionSite::createHTMLElement):
3109         (WebCore::HTMLConstructionSite::createHTMLElementFromSavedElement):
3110         * html/parser/HTMLToken.h:
3111         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
3112         * html/parser/HTMLTreeBuilder.cpp:
3113         (WebCore::HTMLTreeBuilder::processFakeStartTag):
3114         (WebCore::HTMLTreeBuilder::attributesForIsindexInput):
3115         (WebCore::HTMLTreeBuilder::processIsindexStartTagForInBody):
3116         (WebCore):
3117         (WebCore::HTMLTreeBuilder::processStartTagForInBody):
3118         * html/parser/HTMLTreeBuilder.h:
3119         * html/parser/TextDocumentParser.cpp:
3120         (WebCore::TextDocumentParser::insertFakePreElement):
3121         * page/PageSerializer.cpp:
3122         (WebCore::SerializerMarkupAccumulator::appendCustomAttributes):
3123         * svg/SVGFitToViewBox.cpp:
3124         * svg/properties/SVGAnimatedPropertySynchronizer.h:
3125         * xml/XMLErrors.cpp:
3126         (WebCore::createXHTMLParserErrorHeader):
3127         (WebCore::XMLErrors::insertErrorMessageBlock):
3128         * xml/XPathNodeSet.cpp:
3129         (WebCore::XPath::NodeSet::traversalSort):
3130         * xml/XPathStep.cpp:
3131         (WebCore::XPath::Step::nodesInAxis):
3132         * xml/parser/MarkupTokenBase.h:
3133         (WebCore::AtomicMarkupTokenBase::AtomicMarkupTokenBase):
3134         (WebCore::AtomicMarkupTokenBase::getAttributeItem):
3135         (WebCore::AtomicMarkupTokenBase::attributes):
3136         (AtomicMarkupTokenBase):
3137         (WebCore::::initializeAttributes):
3138         * xml/parser/XMLToken.h:
3139         (WebCore::AtomicXMLToken::AtomicXMLToken):
3140         * xml/parser/XMLTreeBuilder.cpp:
3141         (WebCore::XMLTreeBuilder::processNamespaces):
3142         (WebCore::XMLTreeBuilder::processAttributes):
3143
3144 2012-04-22  Sriram Neelakandan  <sriram.neelakandan@gmail.com>
3145
3146         Sync the MOZ_X11 changes from r14 of http://code.google.com/p/npapi-sdk/
3147         also, modified required build flags for Qt,Gtk and CMake
3148         [Qt]  Added MOZ_X11 build flag for !embedded
3149         https://bugs.webkit.org/show_bug.cgi?id=40785
3150
3151         Reviewed by Anders Carlsson.
3152
3153         No new tests. This does not change functionality. Affects all X11 Ports. Build should break if MOZ_X11 is not passed where required
3154
3155         * WebCore.pri:
3156         * plugins/npapi.h:
3157
3158 2012-04-22  Pablo Flouret  <pablof@motorola.com>
3159
3160         Reset event propagation and canceled flags in Event.initEvent
3161         https://bugs.webkit.org/show_bug.cgi?id=83964
3162
3163         Reviewed by Ryosuke Niwa.
3164
3165         Step 3 in http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#dom-event-initevent
3166         Useful for re-configuring an event before dispatching.
3167
3168         Test: fast/events/flags-unset-on-init-event.html
3169
3170         * dom/Event.cpp:
3171         (WebCore::Event::initEvent):
3172
3173 2012-04-22  Martin Robinson  <mrobinson@igalia.com>
3174
3175         [Cairo] Implement CompositeDifference
3176         https://bugs.webkit.org/show_bug.cgi?id=77354
3177
3178         Reviewed by Alejandro G. Castro.
3179
3180         No new tests. The difference compositing operator are not exposed
3181         to web content, so this change is simply in preparation for a time
3182         in which it is used.
3183
3184         Properly map the difference compositing blend modes to a Cairo operator.
3185
3186         * platform/graphics/cairo/CairoUtilities.cpp:
3187         (WebCore::toCairoOperator): Add a mapping for difference. Remove
3188         code supporting versions of Cairo before 1.10, since the Cairo backend
3189         requires 1.10 or greater already.
3190
3191 2012-04-22  Jon Lee  <jonlee@apple.com>
3192
3193         Remove notifications support on Mac Lion.
3194         https://bugs.webkit.org/show_bug.cgi?id=84554
3195         <rdar://problem/11297128>
3196
3197         Reviewed by Sam Weinig.
3198
3199         * Configurations/FeatureDefines.xcconfig:
3200
3201 2012-04-22  Shawn Singh  <shawnsingh@chromium.org>
3202
3203         [chromium] Damage Tracker needs to use CCMathUtil transforms
3204         https://bugs.webkit.org/show_bug.cgi?id=84070
3205
3206         Reviewed by Adrienne Walker.
3207
3208         Unit test added to CCDamageTracker.cpp.
3209
3210         This patch makes CCDamageTracker use CCMathUtil transforms, so
3211         that perspective w < 0 problem is correctly handled.
3212
3213         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
3214         (WebCore::CCDamageTracker::extendDamageForLayer):
3215         (WebCore::CCDamageTracker::extendDamageForRenderSurface):
3216
3217 2012-04-20  Jon Lee  <jonlee@apple.com>
3218
3219         Add Notification constructor
3220         https://bugs.webkit.org/show_bug.cgi?id=80477
3221         <rdar://problem/10912431>
3222
3223         Reviewed by Jian Li.
3224
3225         Tests will be added once there is support for web notifications on the Mac ports.
3226
3227         * WebCore.exp.in: Export finalize() function.
3228
3229         Modify Dictionary to support creation of event listeners.
3230         * bindings/js/Dictionary.h:
3231         (WebCore::Dictionary::isObject): Return true if the JSDictionary is valid.
3232         (WebCore::Dictionary::isUndefinedOrNull): Return true if the JSDictionary is not valid.
3233         (WebCore::Dictionary::get): Add convenience function to take const char* for
3234         property name, to prevent having to do implicit conversion to WTF::String.
3235         (WebCore::Dictionary::getEventListener): Add function to create event listener
3236         from the dictionary.
3237         (WebCore::Dictionary::asJSObject): Helper to convert WebCore objects to JS wrapper.
3238         * bindings/js/Dictionary.cpp:
3239         (WebCore::Notification): Implement asJSObject() for Notification.
3240         * bindings/js/JSDictionary.h:
3241         (WebCore::JSDictionary::execState): Expose the exec state so that the Dictionary
3242         can obtain its world for creating the event listener.
3243
3244         * bindings/v8/Dictionary.h:
3245         (WebCore::Dictionary::getEventListener): Stub implementation.
3246
3247         Add new constructor to idl definitions.
3248         * notifications/DOMWindowNotifications.idl: Add Notification constructor, if
3249         ENABLE(NOTIFICATIONS) is on.
3250         * notifications/Notification.idl: If ENABLE(NOTIFICATIONS) is turned on, define
3251         the constructor. Otherwise, use OmitConstructor.
3252         * notifications/NotificationCenter.idl: Wrap creation functions in
3253         ENABLE(LEGACY_NOTIFICATIONS).
3254         * notifications/NotificationCenter.h: Ditto.
3255         (NotificationCenter):
3256
3257         * notifications/Notification.h:
3258         (Notification): Wrap legacy constructors in ENABLE(LEGACY_NOTIFICATIONS).
3259         (WebCore::Notification::create): New creation function based on discussions in WG.
3260         * notifications/Notification.cpp:
3261         (WebCore::getAndAddEventListener): Helper function to get the listener from the
3262         dictionary, and attach to the notification.
3263         (WebCore::Notification::create): Create the notification, then apply whatever
3264         properties can be found in the dictionary to the notification. In order to
3265         attach the event listeners, the notification has to have been created, which is
3266         why this all happens in the factory method and not in the constructor.
3267         (WebCore::Notification::setBody): Added so that it can be set if we find it in the
3268         dictionary.
3269
3270         The new constructor queues a task to show when it is created. To support this, we
3271         use a one-shot timer that calls show() in the next iteration of the run loop.
3272         (WebCore::Notification::Notification): Start the timer.
3273         (WebCore::Notification::showTaskTimerFired): Call show().
3274
3275         Notifications, not being attached to the DOM, could be GC'ed by the JS engine
3276         before its life cycle has completed. We add calls to setPendingActivity() when the
3277         notification has been shown, and when it is closed, we unsetPendingActivity().
3278         To guarantee that we only call this once, we add a new state to the Notification
3279         state machine, called NotificationState::Closed.
3280         (WebCore::Notification::show): Call setPendingActivity() for all ports. Remove conditional on Mac.
3281         (WebCore::Notification::close): Include Closed state to machine; do nothing.
3282         (WebCore::Notification::dispatchCloseEvent): Call finalize().
3283         (WebCore::Notification::finalize): If the state is not Closed, we unsetPendingActivity()
3284         to make it available for GC.
3285         (WebCore::Notification::finishLoading): Remove the unsetPendingActivity(). That call
3286         was to balance the setPendingActivity() called for loading the icon. Instead of wrapping
3287         around the icon load, we wrap around the show() -> finalize() loop.
3288
3289         In Notification, rename some of the stages and functions to more clearly communicate
3290         that they mostly deal with the icon of the notification, instead of general loading.
3291         (WebCore::Notification::show): Refactored to use LoadingIcon and CancelledIcon.
3292         (WebCore::Notification::close): Refactored to use LoadingIcon and CancelledIcon.
3293         (WebCore::Notification::~Notification): Refactor to use LoadingIcon.
3294         (WebCore::Notification::startLoadingIcon): Renamed from startLoading().
3295         (WebCore::Notification::stopLoadingIcon): Renamed from stopLoading().
3296         (WebCore::Notification::finishLoadingIcon): Renamed from finishLoading().
3297         (WebCore::Notification::didFinishLoading):
3298         (WebCore::Notification::didFail):
3299         (WebCore::Notification::didFailRedirectCheck):
3300         (WebCore::Notification::didReceiveResponse):
3301         (WebCore::Notification::finishLoading):
3302
3303         Add Dictionary.cpp.
3304         * GNUmakefile.list.am:
3305         * Target.pri:
3306         * UseJSC.cmake:
3307         * WebCore.gypi:
3308
3309         Fix bug in V8 bindings generation code. If the constructor doesn't raise an exception,
3310         don't use an exception code.
3311         * bindings/scripts/CodeGeneratorV8.pm:
3312         (GenerateParametersCheck):
3313         * bindings/scripts/test/V8/V8TestObj.cpp: Reset results.
3314         (WebCore::TestObjV8Internal::optionsObjectCallback):
3315
3316 2012-04-21  Benjamin C Meyer  <bmeyer@rim.com>
3317
3318         Support loading the same plugin in multiple locations in the Blackberry port.
3319         https://bugs.webkit.org/show_bug.cgi?id=84537
3320
3321         The hash for the plugin is only based upon the plugin meta information
3322         which will be the same for the same plugin in the system and user's
3323         plugin folders.
3324
3325         It looks like this code was copied/based on the windows port
3326         which doesn't allow the same plugin to be loaded more than once.
3327
3328         Because we want to support multiple copies of the same plugin
3329         in the blackberry port we want to incorperate the path of the plugin
3330         into the hash.
3331
3332         PR 150404
3333
3334         Reviewed by Adam Treat.
3335
3336         * plugins/blackberry/PluginPackageBlackBerry.cpp:
3337         (WebCore::PluginPackage::hash):
3338
3339 2012-04-21  Benjamin C Meyer  <bmeyer@rim.com>
3340
3341         System plugins are preferred over application plugins
3342         https://bugs.webkit.org/show_bug.cgi?id=84538
3343
3344         Set the preferred paths for plugins so that plugins that reside
3345         inside of the bar will be preferred over plugins that are in the
3346         system folder.
3347
3348         PR 150404
3349
3350         Reviewed by Adam Treat.
3351
3352         * plugins/PluginDatabase.cpp:
3353         (WebCore::PluginDatabase::isPreferredPluginDirectory):
3354
3355 2012-04-21  Darin Adler  <darin@apple.com>
3356
3357         Improve performance of removing user and password from URLs
3358         https://bugs.webkit.org/show_bug.cgi?id=84525
3359
3360         Reviewed by Dan Bernstein.
3361
3362         Performance improvement only. Correctness covered by existing regression tests.
3363
3364         The most common use of KURL::setUser and KURL::setPass, by far, is to remove
3365         the user and password from a URL that already has neither. Optimize this by
3366         not re-parsing the URL in that case.
3367
3368         * platform/KURL.cpp:
3369         (WebCore::KURL::setUser): Restructure code so that the code path that removes
3370         the user does no work when there is nothing to remove. Otherwise, leave the
3371         logic of the function untouched.
3372         (WebCore::KURL::setPass): Same thing, only for password rather than user.
3373
3374 2012-04-20  Sheriff Bot  <webkit.review.bot@gmail.com>
3375
3376         Unreviewed, rolling out r114768.
3377         http://trac.webkit.org/changeset/114768
3378         https://bugs.webkit.org/show_bug.cgi?id=84521
3379
3380         Original patch was not the problem, re-applying (Requested by
3381         pfeldman_ on #webkit).
3382
3383         * bindings/v8/V8IsolatedContext.cpp:
3384         (WebCore::setInjectedScriptContextDebugId):
3385         (WebCore):
3386         (WebCore::V8IsolatedContext::V8IsolatedContext):
3387         * bindings/v8/V8Proxy.cpp:
3388         (WebCore::V8Proxy::evaluateInIsolatedWorld):
3389         * bindings/v8/V8Proxy.h:
3390         (V8Proxy):
3391
3392 2012-04-20  Adrienne Walker  <enne@google.com>
3393
3394         [chromium] Refactor opaque content transform out of Skia context
3395         https://bugs.webkit.org/show_bug.cgi?id=83608
3396
3397         Reviewed by James Robinson.
3398
3399         Having PlatformContextSkia know about the transform into content space
3400         for a layer is a layering violation. This change lets the
3401         PlatformContextSkia deal with opaque rects in its own space and lets
3402         the caller handle transforming it into its own space. This also
3403         prevents a matrix multiply per draw into the Skia canvas and does it
3404         just once at the end to transform the final rect.
3405
3406         This is an incremental refactoring so that additional tracking for
3407         text rects can be added and use the same space as opaque rects.
3408
3409         Tests: LayerTextureUpdaterTest.testPartialOpaqueRectNoTransform
3410                LayerTextureUpdaterTest.testPartialOpaqueRectTranslation
3411                LayerTextureUpdaterTest.testPartialOpaqueRectScale
3412
3413         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.cpp:
3414         (WebCore::BitmapCanvasLayerTextureUpdater::prepareToUpdate):
3415         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.h:
3416         (BitmapCanvasLayerTextureUpdater):
3417         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp:
3418         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::prepareToUpdate):
3419         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h:
3420         (BitmapSkPictureCanvasLayerTextureUpdater):
3421         * platform/graphics/chromium/CanvasLayerTextureUpdater.cpp:
3422         (WebCore::CanvasLayerTextureUpdater::paintContents):
3423         * platform/graphics/chromium/CanvasLayerTextureUpdater.h:
3424         (CanvasLayerTextureUpdater):
3425         * platform/graphics/chromium/LayerTextureUpdater.h:
3426         (WebCore::LayerTextureUpdater::prepareToUpdate):
3427         * platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.cpp:
3428         (WebCore::SkPictureCanvasLayerTextureUpdater::prepareToUpdate):
3429         * platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.h:
3430         (SkPictureCanvasLayerTextureUpdater):
3431         * platform/graphics/chromium/TiledLayerChromium.cpp:
3432         (WebCore::TiledLayerChromium::updateTiles):
3433         * platform/graphics/skia/OpaqueRegionSkia.cpp:
3434         (WebCore::OpaqueRegionSkia::didDrawRect):
3435         (WebCore::OpaqueRegionSkia::didDrawPath):
3436         (WebCore::OpaqueRegionSkia::didDrawPoints):
3437         (WebCore::OpaqueRegionSkia::didDrawBounded):
3438         (WebCore::OpaqueRegionSkia::didDraw):
3439         * platform/graphics/skia/OpaqueRegionSkia.h:
3440         (OpaqueRegionSkia):
3441         * platform/graphics/skia/PlatformContextSkia.cpp:
3442         (WebCore::PlatformContextSkia::didDrawRect):
3443         (WebCore::PlatformContextSkia::didDrawPath):
3444         (WebCore::PlatformContextSkia::didDrawPoints):
3445         (WebCore::PlatformContextSkia::didDrawBounded):
3446         * platform/graphics/skia/PlatformContextSkia.h:
3447         (PlatformContextSkia):
3448
3449 2012-04-20  Enrica Casucci  <enrica@apple.com>
3450
3451         CRASH at WebCore::ReplaceSelectionCommand::removeRedundantMarkup
3452         https://bugs.webkit.org/show_bug.cgi?id=84518
3453         <rdar://problem/10714790>
3454
3455         Reviewed by Simon Fraser.
3456