ff6dc03c34d34eaf18bab1596c8d8e3685b93975
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-10-18  Chris Fleizach  <cfleizach@apple.com>
2
3         AX: buttons of number type <input> controls are not fully accessible
4         https://bugs.webkit.org/show_bug.cgi?id=70241
5
6         Staged commit, part 6.
7
8         Reviewed by Darin Adler.
9
10         Test: platform/mac/accessibility/html5-input-number.html
11
12         * accessibility/AccessibilityRenderObject.cpp:
13         (WebCore::AccessibilityRenderObject::addImageMapChildren):
14         (WebCore::AccessibilityRenderObject::addTextFieldChildren):
15         (WebCore::AccessibilityRenderObject::addChildren):
16         * accessibility/AccessibilityRenderObject.h:
17
18 2011-10-18  Nate Chapin  <japhet@chromium.org>
19
20         Make DocumentThreadableLoader a CachedResourceClient.
21         This will allow us to cache ThreadableLoaderClients as
22         appropriate in a later patch.
23         https://bugs.webkit.org/show_bug.cgi?id=61225
24
25         Reviewed by Antti Koivisto.
26
27         No new tests, no functionality change intended.
28
29         * WebCore.gypi:
30         * loader/DocumentThreadableLoader.cpp:
31         (WebCore::DocumentThreadableLoader::notifyFinished): CachedResourceClients don't send separate callbacks
32             for didFail() and didFinishLoading(), so we need to differentiate here.
33         (WebCore::DocumentThreadableLoader::loadRequest): Call CachedResourceLoader::requestRawResource()
34             instead of ResourceLoadScheduler::scheduleSubresourceLoad().
35         * loader/DocumentThreadableLoader.h:
36         * loader/cache/CachedRawResource.cpp:
37         (WebCore::CachedRawResource::data): Handle the complexity of some ThreadableLoaderClients setting
38             DoNotBufferData in ResoureLoaderOptions. If the DataBufferingPolicy is BufferData, then the
39             'data' input parameter will contain all data received so far, and we need to determine the
40             incremental data to forward to the clients. If the policy is DoNotBufferData, 'data' is just
41             the incremental data.
42         * loader/cache/CachedRawResource.h:
43         * loader/cache/CachedResource.cpp:
44         * loader/cache/CachedResource.h:
45         (WebCore::CachedResource::preloadResult):
46         (WebCore::CachedResource::didSendData):
47         (WebCore::CachedResource::didDownloadData):
48         (WebCore::CachedResource::setLoadFinishTime):
49         (WebCore::CachedResource::loadFinishTime):
50         * loader/cache/CachedResourceClient.h: Add several new callbacks needed by DocumentThreadableLoader.
51         * loader/cache/CachedResourceRequest.cpp:
52         (WebCore::CachedResourceRequest::didReceiveResponse): CachedResource::setResponse() can now cancel
53             the request, so protect appropriately.
54         * loader/cache/CachedResourceRequest.h:
55         * loader/chromium/CachedRawResourceChromium.cpp: Added (plumb didDownloadData() to DocumentThreadableLoader).
56         * loader/chromium/CachedResourceRequestChromium.cpp: Added (plumb didDownloadData() to DocumentThreadableLoader).
57         * loader/chromium/DocumentThreadableLoaderChromium.cpp:
58         * platform/network/BlobResourceHandle.cpp:
59         (WebCore::BlobResourceHandle::notifyResponse): Protect before setting response, since it might kill us.
60
61 2011-10-18  Sheriff Bot  <webkit.review.bot@gmail.com>
62
63         Unreviewed, rolling out r97752.
64         http://trac.webkit.org/changeset/97752
65         https://bugs.webkit.org/show_bug.cgi?id=70332
66
67         Caused assertion failures in MediaList::setParentStyleSheet()
68         on the apple bots. (Requested by kling on #webkit).
69
70         * WebCore.xcodeproj/project.pbxproj:
71         * bindings/js/JSDOMBinding.h:
72         * css/CSSImportRule.cpp:
73         (WebCore::CSSImportRule::CSSImportRule):
74         (WebCore::CSSImportRule::~CSSImportRule):
75         * css/CSSMediaRule.cpp:
76         (WebCore::CSSMediaRule::CSSMediaRule):
77         (WebCore::CSSMediaRule::~CSSMediaRule):
78         * css/CSSMediaRule.h:
79         * css/MediaList.cpp:
80         (WebCore::MediaList::MediaList):
81         (WebCore::MediaList::notifyChanged):
82         * css/MediaList.h:
83         * css/StyleSheet.cpp:
84         (WebCore::StyleSheet::~StyleSheet):
85         (WebCore::StyleSheet::setMedia):
86
87 2011-10-18  Anna Cavender  <annacc@chromium.org>
88
89         Change TextTrack to use the word DISABLED instead of OFF for mode
90         https://bugs.webkit.org/show_bug.cgi?id=70268
91
92         Reviewed by Daniel Bates.
93
94         No new tests. No new functionality.
95
96         * html/TextTrack.cpp:
97         (WebCore::TextTrack::setMode): use Disabled instead of Off
98         * html/TextTrack.h: update Mode enum to use Disabled instead of Off
99
100 2011-10-18  Chris Fleizach  <cfleizach@apple.com>
101
102         AX: buttons of number type <input> controls are not fully accessible
103         https://bugs.webkit.org/show_bug.cgi?id=70241
104
105         Staged commit, part 5.
106
107         Reviewed by Darin Adler.
108
109         * accessibility/AXObjectCache.cpp:
110         (WebCore::AXObjectCache::getOrCreate):
111         * accessibility/AccessibilityRenderObject.cpp:
112         (WebCore::AccessibilityRenderObject::boundingBoxRect):
113
114 2011-10-18  Antti Koivisto  <antti@apple.com>
115
116         Move default stylesheet loading to a separate function
117         https://bugs.webkit.org/show_bug.cgi?id=70331
118
119         Reviewed by Andreas Kling.
120         
121         - Move default stylesheet loading out from CSSStyleSelector::styleForElement()
122         - Rename e -> element
123         - Remove pointless reffing of the placeholder style.
124
125         * css/CSSStyleSelector.cpp:
126         (WebCore::ensureDefaultStyleSheetsForElement):
127         (WebCore::isAtShadowBoundary):
128         (WebCore::CSSStyleSelector::styleForElement):
129
130 2011-10-18  Chris Fleizach  <cfleizach@apple.com>
131
132         AX: buttons of number type <input> controls are not fully accessible
133         https://bugs.webkit.org/show_bug.cgi?id=70241
134
135         Staged commit part 4.
136
137         Reviewed by Darin Adler.
138
139         * accessibility/AccessibilityMockObject.h:
140         (WebCore::AccessibilityMockObject::isMockObject):
141         (WebCore::AccessibilityMockObject::detachFromParent):
142         * accessibility/AccessibilityObject.cpp:
143         (WebCore::AccessibilityObject::elementAccessibilityHitTest):
144         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
145         (-[WebAccessibilityObjectWrapper accessibilityActionNames]):
146         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
147         (-[WebAccessibilityObjectWrapper subrole]):
148         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
149
150 2011-10-18  Chris Fleizach  <cfleizach@apple.com>
151
152         AX: buttons of number type <input> controls are not fully accessible
153         https://bugs.webkit.org/show_bug.cgi?id=70241
154
155         Staged commit part 3. Committing the new spin button classes.
156
157         Reviewed by Darin Adler.
158
159         * CMakeLists.txt:
160         * GNUmakefile.list.am:
161         * WebCore.gypi:
162         * WebCore.pro:
163         * WebCore.vcproj/WebCore.vcproj:
164         * WebCore.xcodeproj/project.pbxproj:
165         * accessibility/AccessibilitySpinButton.cpp: Added.
166         (WebCore::AccessibilitySpinButton::create):
167         (WebCore::AccessibilitySpinButton::AccessibilitySpinButton):
168         (WebCore::AccessibilitySpinButton::~AccessibilitySpinButton):
169         (WebCore::AccessibilitySpinButton::incrementButton):
170         (WebCore::AccessibilitySpinButton::decrementButton):
171         (WebCore::AccessibilitySpinButton::elementRect):
172         (WebCore::AccessibilitySpinButton::addChildren):
173         (WebCore::AccessibilitySpinButton::step):
174         (WebCore::AccessibilitySpinButtonPart::AccessibilitySpinButtonPart):
175         (WebCore::AccessibilitySpinButtonPart::create):
176         (WebCore::AccessibilitySpinButtonPart::elementRect):
177         (WebCore::AccessibilitySpinButtonPart::press):
178         * accessibility/AccessibilitySpinButton.h: Added.
179         (WebCore::AccessibilitySpinButton::setSpinButtonElement):
180         (WebCore::AccessibilitySpinButton::roleValue):
181         (WebCore::AccessibilitySpinButton::accessibilityIsIgnored):
182         (WebCore::AccessibilitySpinButton::isSpinButton):
183         (WebCore::AccessibilitySpinButtonPart::~AccessibilitySpinButtonPart):
184         (WebCore::AccessibilitySpinButtonPart::isIncrementor):
185         (WebCore::AccessibilitySpinButtonPart::setIsIncrementor):
186         (WebCore::AccessibilitySpinButtonPart::roleValue):
187         (WebCore::AccessibilitySpinButtonPart::isSpinButtonPart):
188         (WebCore::AccessibilitySpinButtonPart::accessibilityIsIgnored):
189         (WebCore::toAccessibilitySpinButton):
190         (WebCore::toAccessibilitySpinButtonPart):
191
192 2011-10-18  Chris Fleizach  <cfleizach@apple.com>
193
194         AX: buttons of number type <input> controls are not fully accessible
195         https://bugs.webkit.org/show_bug.cgi?id=70241
196
197         Phase 2 of the staged commit.
198
199         Reviewed by Darin Adler.
200
201         * accessibility/AccessibilityObject.cpp:
202         (WebCore::AccessibilityObject::boundingBoxForQuads):
203         * accessibility/AccessibilityObject.h:
204         (WebCore::AccessibilityObject::isSpinButton):
205         (WebCore::AccessibilityObject::isSpinButtonPart):
206         (WebCore::AccessibilityObject::isMockObject):
207
208 2011-10-18  Chris Fleizach  <cfleizach@apple.com>
209
210         AX: buttons of number type <input> controls are not fully accessible
211         https://bugs.webkit.org/show_bug.cgi?id=70241
212
213         Expose the spin button object to the AX hierarchy. Since there is no distinct
214         render object that backs this object, a mock object needs to be created for the entire
215         spin button and the actual increment and decrement buttons inside.
216
217         This will be a staged commit since the first time around Windows layout tests started crashing for an undeterminable reason.
218
219         Reviewed by Darin Adler.
220
221         * html/shadow/TextControlInnerElements.cpp:
222         (WebCore::SpinButtonElement::step):
223         (WebCore::SpinButtonElement::repeatingTimerFired):
224         * html/shadow/TextControlInnerElements.h:
225
226 2011-10-18  Andreas Kling  <kling@webkit.org>
227
228         MediaList: Remove inheritance from StyleBase.
229         https://bugs.webkit.org/show_bug.cgi?id=70203
230
231         Reviewed by Darin Adler.
232
233         * css/MediaList.h:
234         (WebCore::MediaList::parentStyleSheet):
235         (WebCore::MediaList::setParentStyleSheet):
236         * css/MediaList.cpp:
237         (WebCore::MediaList::MediaList):
238         (WebCore::MediaList::notifyChanged):
239
240             Change MediaList to no longer inherit from StyleBase. The parent()/setParent()
241             mechanism was replaced by explicit parentStyleSheet()/setParentStyleSheet().
242
243         * css/CSSImportRule.cpp:
244         (WebCore::CSSImportRule::CSSImportRule):
245         (WebCore::CSSImportRule::~CSSImportRule):
246         * css/CSSMediaRule.cpp:
247         (WebCore::CSSMediaRule::CSSMediaRule):
248         (WebCore::CSSMediaRule::~CSSMediaRule):
249
250             Change StyleBase::setParent() calls to MediaList::setParentStyleSheet().
251             CSSRules are never moved between stylesheets, so the parent style sheet pointer
252             is valid for the MediaList's lifetime.
253
254         * css/StyleSheet.cpp:
255         (WebCore::StyleSheet::~StyleSheet):
256
257             Change StyleBase::setParent() calls to MediaList::setParentStyleSheet().
258
259         (WebCore::StyleSheet::setMedia):
260
261             Change StyleBase::setParent() calls to MediaList::setParentStyleSheet().
262             Assert that the parent sheet is either null, or this, as MediaLists should never
263             be reparented to other sheets.
264             Assert that the StyleSheet is indeed a CSSStyleSheet.  XSLStyleSheet inherits from
265             StyleSheet, but it shouldn't be using the MediaList.
266
267         * bindings/js/JSDOMBinding.h:
268         (WebCore::root):
269
270             Add MediaList* specific overload for root() since it can't fall back
271             to root(StyleBase*) anymore.
272
273         * WebCore.xcodeproj/project.pbxproj:
274
275             Add some PrivateHeaders to accomodate the JSDOMBinding.h changes.
276
277         * css/CSSMediaRule.h:
278
279             Remove unnecessary forward-declaration of MediaList.
280
281 2011-10-18  Andreas Kling  <kling@webkit.org>
282
283         XSLStyleSheet only needs to manage XSLImportRule children.
284         https://bugs.webkit.org/show_bug.cgi?id=70326
285
286         Reviewed by Antti Koivisto.
287
288         * css/StyleBase.h:
289         * xml/XSLImportRule.h:
290         * css/CSSRule.h:
291         (WebCore::CSSRule::isImportRule):
292
293             Move StyleBase::isImportRule() down to CSSRule. Since XSLImportRule no longer
294             implements it, it's now specific to CSSImportRule.
295
296         * xml/XSLStyleSheet.h:
297
298             Change m_children to be a vector of XSLImportRules. Also remove length(),
299             item() and append() since they were only used internally to modify m_children.
300
301         * xml/XSLStyleSheetQt.cpp:
302         (WebCore::XSLStyleSheet::~XSLStyleSheet):
303         * xml/XSLStyleSheetLibxslt.cpp:
304         (WebCore::XSLStyleSheet::~XSLStyleSheet):
305         (WebCore::XSLStyleSheet::isLoading):
306         (WebCore::XSLStyleSheet::clearDocuments):
307         (WebCore::XSLStyleSheet::loadChildSheet):
308         (WebCore::XSLStyleSheet::locateStylesheetSubResource):
309
310             Remove now-unnecessary isImportRule() checks and tidy up the code a bit.
311
312 2011-10-18  Zan Dobersek  <zandobersek@gmail.com>
313
314         [Gtk] Support for client-based geolocation
315         https://bugs.webkit.org/show_bug.cgi?id=64970
316
317         Reviewed by Martin Robinson.
318
319         Add feature defines for client-based geolocation when geolocation is enabled,
320         since this is the providing method that is now used by default. Remove
321         service-based providing method completely as it is not needed anymore.
322
323         * GNUmakefile.am: Add feature defines for client-based geolocation.
324         * GNUmakefile.list.am: Remove GeolocationServiceGtk.* files from compilation.
325         * platform/gtk/GeolocationServiceGtk.cpp: Removed.
326         * platform/gtk/GeolocationServiceGtk.h: Removed.
327
328 2011-10-18  Antti Koivisto  <antti@apple.com>
329
330         REGRESSION(r97248): :visited as descendant selector broken
331         https://bugs.webkit.org/show_bug.cgi?id=70122
332
333         Reviewed by Nikolas Zimmerman.
334         
335         Make ":visited foo" and similar selectors work correctly again. They can affect 
336         the visited style of an element inside a visited link.
337
338         Test: fast/selectors/visited-descendant.html
339
340         * css/CSSStyleSelector.cpp:
341         (WebCore::CSSStyleSelector::applyDeclarations): 
342         
343             Apply visited style to children of visited links too.
344             
345         * css/SelectorChecker.cpp:
346         (WebCore::SelectorChecker::checkSelector): 
347         
348             Don't disable visited matching until we run into first ancestor link or use combinator other than child/descendant.
349
350         (WebCore::SelectorChecker::determineLinkMatchType):
351         
352             Look into child/descendant component selectors too to determine the link match type.
353
354 2011-10-18  Andreas Kling  <kling@webkit.org>
355
356         Move CSSRule specific virtuals from StyleBase down into CSSRule.
357         https://bugs.webkit.org/show_bug.cgi?id=70240
358
359         Reviewed by Darin Adler.
360
361         Move all the isFooRule() virtuals except isImportRule() to CSSRule
362         since they only make sense for its subclasses. isRule() remains in
363         StyleBase since we still need it for the parent chain traversal.
364         isImportRule() remains because XSLImportRule implements it.
365
366         Also moved insertedIntoParent() and removed its usage in
367         XSLStyleSheet since it is only reimplemented by CSSImportRule.
368
369         * css/CSSRule.h:
370         (WebCore::CSSRule::isCharsetRule):
371         (WebCore::CSSRule::isFontFaceRule):
372         (WebCore::CSSRule::isKeyframeRule):
373         (WebCore::CSSRule::isKeyframesRule):
374         (WebCore::CSSRule::isMediaRule):
375         (WebCore::CSSRule::isPageRule):
376         (WebCore::CSSRule::isStyleRule):
377         (WebCore::CSSRule::isRegionStyleRule):
378         (WebCore::CSSRule::insertedIntoParent):
379         * css/StyleBase.h:
380         (WebCore::StyleBase::isImportRule):
381         (WebCore::StyleBase::isCSSStyleSheet):
382         * xml/XSLStyleSheet.h:
383         (WebCore::XSLStyleSheet::append):
384
385 2011-10-18  Sachin Puranik  <jcqt43@motorola.com>
386
387         Option.value should trim extra internal html spaces
388         https://bugs.webkit.org/show_bug.cgi?id=69455
389
390         Reviewed by Kent Tamura.
391
392         Currently option.value does not trim the internal white space as suggested by spec. This patch implements the same.
393
394         Test: fast/forms/option-value-trim-html-spaces.html
395
396         * dom/OptionElement.cpp: Removed a function as this implementation is moved to the HTMLOptionElement.cpp file.
397         * html/HTMLOptionElement.cpp:
398         (WebCore::HTMLOptionElement::value): Implementation of .value function which will now trim the html white spaces.
399
400 2011-10-18  Mihnea Ovidenie  <mihnea@adobe.com>
401
402         [CSS Regions]Parse @-webkit-region rule
403         https://bugs.webkit.org/show_bug.cgi?id=70021
404
405         Reviewed by David Hyatt.
406
407         Test: fast/regions/parsing-region-style-rule.html
408
409         * CMakeLists.txt:
410         * GNUmakefile.list.am:
411         * WebCore.gypi:
412         * WebCore.pro:
413         * WebCore.vcproj/WebCore.vcproj:
414         * WebCore.xcodeproj/project.pbxproj:
415         * bindings/objc/DOMCSS.mm:
416         (kitClass):
417         * bindings/v8/custom/V8CSSRuleCustom.cpp:
418         (WebCore::toV8):
419         * css/CSSGrammar.y:
420         * css/CSSMediaRule.cpp:
421         (WebCore::CSSMediaRule::cssText):
422         * css/CSSParser.cpp:
423         (WebCore::CSSParser::setReusableRegionSelectorVector):
424         (WebCore::CSSParser::createRegionStylingRule):
425         * css/CSSParser.h:
426         (WebCore::CSSParser::reusableRegionSelectorVector):
427         * css/CSSRegionStyleRule.cpp: Added.
428         (WebCore::CSSRegionStyleRule::CSSRegionStyleRule):
429         (WebCore::CSSRegionStyleRule::~CSSRegionStyleRule):
430         (WebCore::CSSRegionStyleRule::cssText):
431         * css/CSSRegionStyleRule.h: Added.
432         * css/CSSRule.h:
433         * css/CSSRule.idl:
434         * css/CSSRuleList.cpp:
435         (WebCore::CSSRuleList::item):
436         (WebCore::CSSRuleList::rulesText):
437         * css/CSSRuleList.h:
438         * css/CSSSelectorList.cpp:
439         (WebCore::CSSSelectorList::selectorsText):
440         * css/CSSSelectorList.h:
441         * css/CSSStyleSelector.cpp:
442         (WebCore::CSSStyleSelector::addRegionStyleRule):
443         (WebCore::RuleSet::addRulesFromSheet):
444         * css/CSSStyleSelector.h:
445         * css/StyleBase.h:
446         (WebCore::StyleBase::isRegionStyleRule):
447         * css/tokenizer.flex:
448
449 2011-10-11  Pavel Podivilov  <podivilov@chromium.org>
450
451         Web Inspector: support displaying multiple sources per single script in ScriptsPanel.
452         https://bugs.webkit.org/show_bug.cgi?id=69847
453
454         Reviewed by Pavel Feldman.
455
456         * inspector/front-end/ScriptsPanel.js:
457         (WebInspector.ScriptsPanel.prototype._removeSourceFrame):
458         (WebInspector.ScriptsPanel.prototype._uiSourceCodeReplaced):
459
460 2011-10-18  Nikolas Zimmermann  <nzimmermann@rim.com>
461
462         Prepare SVGImage intrinsic size negotiation: Add intrinsic size & ratio calculation functionality to Image
463         https://bugs.webkit.org/show_bug.cgi?id=70314
464
465         Reviewed by Antti Koivisto.
466
467         Add a "void computeIntrinsicDimension(Length& intrinsicWidth, Lengt& intrinsicHeight, FloatSize& intrinsicRatio)" helper method
468         to Image/GeneratedImage/SVGImage and make it accessible through StyleImage.
469
470         For a regular Image the intrinsicWidth/Height contains just a Length(size().width(), Fixed). In contrary SVGImages pass on the
471         style()->width()/height() values from the render style of the RenderSVGRoot renderer. These information are needed to implement
472         the size negotiation between embedded SVG images and the embedder.
473
474         No new tests, as this new functionality is not yet used.
475
476         * loader/cache/CachedImage.cpp:
477         (WebCore::CachedImage::computeIntrinsicDimensions):
478         * loader/cache/CachedImage.h:
479         * platform/graphics/GeneratedImage.cpp:
480         (WebCore::GeneratedImage::computeIntrinsicDimensions):
481         * platform/graphics/GeneratedImage.h:
482         * platform/graphics/Image.cpp:
483         (WebCore::Image::computeIntrinsicDimensions):
484         * platform/graphics/Image.h:
485         * platform/graphics/cg/PDFDocumentImage.cpp:
486         (WebCore::PDFDocumentImage::computeIntrinsicDimensions):
487         * platform/graphics/cg/PDFDocumentImage.h:
488         * rendering/style/StyleCachedImage.cpp:
489         (WebCore::StyleCachedImage::computeIntrinsicDimensions):
490         * rendering/style/StyleCachedImage.h:
491         * rendering/style/StyleGeneratedImage.cpp:
492         (WebCore::StyleGeneratedImage::computeIntrinsicDimensions):
493         * rendering/style/StyleGeneratedImage.h:
494         * rendering/style/StyleImage.h:
495         * rendering/style/StylePendingImage.h:
496         (WebCore::StylePendingImage::computeIntrinsicDimensions):
497         * svg/graphics/SVGImage.cpp:
498         (WebCore::SVGImage::computeIntrinsicDimensions):
499         * svg/graphics/SVGImage.h:
500
501 2011-10-17  Alexander Pavlov  <apavlov@chromium.org>
502
503         Web Inspector: [Chromium] Different dimensions are reported for elements onscreen and in the Metrics pane
504         https://bugs.webkit.org/show_bug.cgi?id=70242
505
506         Reviewed by Pavel Feldman.
507
508         * inspector/DOMNodeHighlighter.cpp:
509
510 2011-10-18  Kentaro Hara  <haraken@chromium.org>
511
512         Unreviewed, rolling out r97697.
513         http://trac.webkit.org/changeset/97697
514         https://bugs.webkit.org/show_bug.cgi?id=68978
515
516         some tests are broken
517
518         * bindings/js/JSMessageEventCustom.cpp:
519         (WebCore::JSMessageEvent::data):
520         * bindings/v8/custom/V8MessageEventCustom.cpp:
521         (WebCore::V8MessageEvent::dataAccessorGetter):
522         (WebCore::V8MessageEvent::portsAccessorGetter):
523         (WebCore::V8MessageEvent::initMessageEventCallback):
524         * dom/MessageEvent.cpp:
525         (WebCore::MessageEventInit::MessageEventInit):
526         (WebCore::MessageEvent::MessageEvent):
527         (WebCore::MessageEvent::isMessageEvent):
528         * dom/MessageEvent.h:
529         (WebCore::MessageEvent::create):
530         (WebCore::MessageEvent::dataAsSerializedScriptValue):
531         (WebCore::MessageEvent::dataAsString):
532         (WebCore::MessageEvent::dataAsBlob):
533         (WebCore::MessageEvent::dataAsArrayBuffer):
534         * dom/MessageEvent.idl:
535
536 2011-10-17  Antti Koivisto  <antti@apple.com>
537
538         r97638 caused 3 printing crashes
539         https://bugs.webkit.org/show_bug.cgi?id=70284
540
541         Reviewed by Kent Tamura.
542
543         Null check element.
544
545         * css/CSSStyleSelector.cpp:
546         (WebCore::CSSStyleSelector::applyDeclarations):
547
548 2011-10-17  Sheriff Bot  <webkit.review.bot@gmail.com>
549
550         Unreviewed, rolling out r97669.
551         http://trac.webkit.org/changeset/97669
552         https://bugs.webkit.org/show_bug.cgi?id=70305
553
554         Broke accessibility tests on Windows (Requested by rniwa on
555         #webkit).
556
557         * CMakeLists.txt:
558         * GNUmakefile.list.am:
559         * WebCore.gypi:
560         * WebCore.pro:
561         * WebCore.vcproj/WebCore.vcproj:
562         * WebCore.xcodeproj/project.pbxproj:
563         * accessibility/AXObjectCache.cpp:
564         (WebCore::AXObjectCache::getOrCreate):
565         * accessibility/AccessibilityMockObject.h:
566         * accessibility/AccessibilityObject.cpp:
567         (WebCore::AccessibilityObject::elementAccessibilityHitTest):
568         * accessibility/AccessibilityObject.h:
569         * accessibility/AccessibilityRenderObject.cpp:
570         (WebCore::AccessibilityRenderObject::boundingBoxRect):
571         (WebCore::AccessibilityRenderObject::clearChildren):
572         (WebCore::AccessibilityRenderObject::updateChildrenIfNecessary):
573         (WebCore::AccessibilityRenderObject::addChildren):
574         * accessibility/AccessibilityRenderObject.h:
575         * accessibility/AccessibilitySpinButton.cpp: Removed.
576         * accessibility/AccessibilitySpinButton.h: Removed.
577         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
578         (-[WebAccessibilityObjectWrapper accessibilityActionNames]):
579         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
580         (-[WebAccessibilityObjectWrapper subrole]):
581         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
582         * html/shadow/TextControlInnerElements.cpp:
583         (WebCore::SpinButtonElement::repeatingTimerFired):
584         * html/shadow/TextControlInnerElements.h:
585
586 2011-10-17  Kent Tamura  <tkent@chromium.org>
587
588         Remove OptionGroupElement
589         https://bugs.webkit.org/show_bug.cgi?id=70220
590
591         Reviewed by Darin Adler.
592
593         No new tests, just a refactoring.
594
595         * CMakeLists.txt: Remove OptionGroupElement.cpp and/or OptionGroupElement.h.
596         * GNUMakefile.am.list: ditto.
597         * WebCore.gypi: ditto.
598         * WebCore.pro: ditto.
599         * WebCore.vcproj/WebCore.vcproj: ditto.
600         * WebCore.xcodeproj/project.pbxproj: ditto.
601         * dom/DOMAllInOne.cpp: ditto.
602         * dom/OptionElement.cpp:
603         (WebCore::OptionElement::collectOptionTextRespectingGroupLabel):
604         Use hasTagName(optgroupTag) and static_cast<> instead of toOptionGroupElement().
605         * dom/OptionGroupElement.cpp: Removed.
606         * dom/OptionGroupElement.h: Removed.
607         * html/HTMLOptGroupElement.cpp:
608         (WebCore::isHTMLOptGroupElement): Added.
609         * html/HTMLOptGroupElement.h:
610          - Don't inherit OptionGroupElement.
611          - Make groupLabelText() non-virtual.
612         * html/HTMLSelectElement.cpp:
613         (WebCore::HTMLSelectElement::recalcListItems):
614         Use Use hasTagName(optgroupTag) instead of isOptionGroupElement().
615         * rendering/RenderListBox.cpp:
616         (WebCore::RenderListBox::updateFromElement):
617         Use hasTagName(optgroupTag) and static_cast<> instead of toOptionGroupElement().
618         (WebCore::RenderListBox::paintItemForeground):
619         Use hasTagName(optgroupTag) instead of isOptionGroupElement().
620         * rendering/RenderMenuList.cpp:
621         (WebCore::RenderMenuList::itemText):
622         Use hasTagName(optgroupTag) and static_cast<> instead of toOptionGroupElement().
623         (WebCore::RenderMenuList::itemIsEnabled):
624         Use Use hasTagName(optgroupTag) instead of isOptionGroupElement().
625         (WebCore::RenderMenuList::itemIsLabel): ditto.
626
627 2011-10-17  Huang Dongsung  <luxtella@company100.net>
628
629         [TexMap][QT] TexMapGL renders a strange one-pixel border of BitmapTexture.
630         https://bugs.webkit.org/show_bug.cgi?id=70293
631
632         TextureMapperGL renders the strange border in
633         http://www.webkit.org/blog-files/leaves/index.html
634         Bug occurs because BitmapTexture is larger than the content due to rounding to
635         NPOT, and its pixel data is never initialized.
636
637         Reviewed by Noam Rosenthal.
638
639         * platform/graphics/opengl/TextureMapperGL.cpp:
640         (WebCore::texImage2DResourceSafe):
641         (WebCore::BitmapTextureGL::reset):
642
643 2011-10-17  Jochen Eisinger  <jochen@chromium.org>
644
645         Make NavigationAction wrap a ResourceRequest instead of a KURL.
646         https://bugs.webkit.org/show_bug.cgi?id=68803
647
648         With this, FrameLoaderClient::dispatchCreatePage knows about the
649         request that will be used for the initial navigaion of the to be
650         created page.
651
652         Reviewed by Nate Chapin.
653
654         Test: platform/chromium/fast/loader/create-view-target-blank.html
655
656         * loader/FrameLoader.cpp:
657         (WebCore::FrameLoader::loadURL):
658         (WebCore::FrameLoader::load):
659         (WebCore::FrameLoader::loadWithDocumentLoader):
660         (WebCore::FrameLoader::reload):
661         (WebCore::FrameLoader::loadPostRequest):
662         (WebCore::FrameLoader::continueLoadAfterNewWindowPolicy):
663         (WebCore::FrameLoader::loadDifferentDocumentItem):
664         (WebCore::createWindow):
665         * loader/NavigationAction.cpp:
666         (WebCore::NavigationAction::NavigationAction):
667         * loader/NavigationAction.h:
668         (WebCore::NavigationAction::isEmpty):
669         (WebCore::NavigationAction::url):
670         (WebCore::NavigationAction::resourceRequest):
671         * loader/PolicyChecker.cpp:
672         (WebCore::PolicyChecker::checkNavigationPolicy):
673         * page/ContextMenuController.cpp:
674         (WebCore::openNewWindow):
675         * WebCore.exp: updated
676
677 2011-10-17  Tom Sepez  <tsepez@chromium.org>
678
679         XSSAuditor bypass with remote script ending in ? character
680         https://bugs.webkit.org/show_bug.cgi?id=70255
681
682         Reviewed by Daniel Bates.
683
684         Fix XSSAuditor bypass where unterminated src="" attribute could pick up
685         text from page causing failed XSS detection.  Constrain match to domain
686         portions of src attribute only.
687
688         Test: http/tests/security/xssAuditor/script-tag-with-source-unterminated.html
689
690         * html/parser/XSSAuditor.cpp:
691         (WebCore::XSSAuditor::filterScriptToken):
692         (WebCore::XSSAuditor::filterObjectToken):
693         (WebCore::XSSAuditor::filterParamToken):
694         (WebCore::XSSAuditor::filterEmbedToken):
695         (WebCore::XSSAuditor::filterAppletToken):
696         (WebCore::XSSAuditor::filterIframeToken):
697         (WebCore::XSSAuditor::eraseAttributeIfInjected):
698         (WebCore::XSSAuditor::decodedSnippetForAttribute):
699         * html/parser/XSSAuditor.h:
700
701 2011-10-17  Adam Klein  <adamk@chromium.org>
702
703         Parse MutationObserverOptions directly into a bitfield
704         https://bugs.webkit.org/show_bug.cgi?id=70287
705
706         Reviewed by Ryosuke Niwa.
707
708         Replaces the MutationObserverOptions class with a typedef,
709         used to pass a bitfield composed of enums defined in
710         WebKitMutationObserver.h.
711
712         No new tests because no behavior should change.
713
714         * GNUmakefile.list.am:
715         * WebCore.gypi:
716         * WebCore.pro:
717         * WebCore.xcodeproj/project.pbxproj:
718         * bindings/js/JSDictionary.h: Removed now-unused method.
719         * bindings/js/JSWebKitMutationObserverCustom.cpp:
720         (WebCore::JSWebKitMutationObserver::observe):
721         * bindings/v8/custom/V8WebKitMutationObserverCustom.cpp:
722         (WebCore::V8WebKitMutationObserver::observeCallback):
723         * dom/MutationObserverOptions.h: Removed.
724         * dom/Node.cpp:
725         (WebCore::Node::registerMutationObserver):
726         * dom/Node.h:
727         * dom/NodeRareData.h:
728         (WebCore::MutationObserverEntry::MutationObserverEntry):
729         (WebCore::MutationObserverEntry::matches):
730         * dom/WebKitMutationObserver.cpp:
731         (WebCore::WebKitMutationObserver::observe):
732         * dom/WebKitMutationObserver.h:
733
734 2011-10-17  Luke Macpherson   <macpherson@chromium.org>
735
736         Add compile-time asserts for RenderStyle::(Non)InheritedFlags size.
737         https://bugs.webkit.org/show_bug.cgi?id=69803
738
739         Reviewed by Darin Adler.
740
741         No new tests.
742
743         Adds COMPILE_ASSERTs for the size of RenderStyle::InheritedFlags and
744         RenderStyle::NonInheritedFlags to ensure that they are not accidentally
745         grown in future changes.
746         Change types of unsigned bitfields to unsigned char to ensure that the
747         above assertions remain true when building on windows.
748
749         * rendering/style/RenderStyle.cpp:
750         (WebCore::RenderStyle):
751         Adds assertions to ensure struct sizes do not change.
752         * rendering/style/RenderStyle.h:
753         Changes unsigned to unsigned char as outlined above.
754
755 2011-10-17  Ojan Vafai  <ojan@chromium.org>
756
757         Unreviewed, rolling out r97662.
758         http://trac.webkit.org/changeset/97662
759         https://bugs.webkit.org/show_bug.cgi?id=68497
760
761         Was not the cause of the test failures.
762
763         * rendering/RenderBox.cpp:
764         (WebCore::RenderBox::sizesToIntrinsicLogicalWidth):
765
766 2011-10-17  Ryosuke Niwa  <rniwa@webkit.org>
767
768         Rename deregister* to unregister*
769         https://bugs.webkit.org/show_bug.cgi?id=70272
770
771         Reviewed by Darin Adler.
772
773         Renamed deregisterHandler to unregisterHandler.
774
775         * inspector/front-end/ExtensionAPI.js:
776         (injectedExtensionAPI.ExtensionServerClient.prototype.unregisterHandler):
777         * inspector/front-end/ExtensionServer.js:
778         (WebInspector.ExtensionServer.prototype._onSetOpenResourceHandler):
779         * inspector/front-end/HandlerRegistry.js:
780         (get WebInspector.HandlerRegistry.prototype.unregisterHandler):
781
782 2011-10-17  Huang Dongsung  <luxtella@company100.net>
783
784         [TexMap][QT] The BGRA32PremultimpliedBuffer should not inherit the RefCounted class.
785         https://bugs.webkit.org/show_bug.cgi?id=70098
786
787         The BitmapTexture has a BGRA32PremultimpliedBuffer object using OwnPtr, not RefPtr.
788         It causes following assertion fail, RefCountedBase::m_deletionHasBegun.
789         It is better that the BGRA32PremultimpliedBuffer does not inherit the RefCounted
790         because the BitmapTexture only has and uses a BGRA32PremultimpliedBuffer object.
791
792         Reviewed by Noam Rosenthal.
793
794         * platform/graphics/opengl/TextureMapperGL.h:
795
796 2011-10-17  Vsevolod Vlasov  <vsevik@chromium.org>
797
798         Web Inspector: Search in resource crashes when there is no resource with given url.
799         https://bugs.webkit.org/show_bug.cgi?id=69767
800
801         Reviewed by Pavel Feldman.
802
803         Test: http/tests/inspector/search/search-in-non-existing-resource.html
804
805         * inspector/InspectorPageAgent.cpp:
806         (WebCore::InspectorPageAgent::searchInResource):
807
808 2011-10-17  Mihnea Ovidenie  <mihnea@adobe.com>
809
810         [CSS Regions]Change content:-webkit-from-flow to -webkit-flow-from
811         https://bugs.webkit.org/show_bug.cgi?id=70104
812
813         Reviewed by David Hyatt.
814
815         1. -webkit-flow-from is now a property instead of being an addition to content property.
816         2. -webkit-flow-from takes an identifier instead of string.
817
818         * css/CSSComputedStyleDeclaration.cpp:
819         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
820         * css/CSSParser.cpp:
821         (WebCore::CSSParser::parseValue):
822         (WebCore::CSSParser::parseContent):
823         (WebCore::CSSParser::parseRegionThread):
824         * css/CSSParser.h:
825         * css/CSSPrimitiveValue.cpp:
826         (WebCore::isValidCSSUnitTypeForDoubleConversion):
827         (WebCore::CSSPrimitiveValue::cleanup):
828         (WebCore::CSSPrimitiveValue::getStringValue):
829         (WebCore::CSSPrimitiveValue::cssText):
830         * css/CSSPrimitiveValue.h:
831         * css/CSSPropertyNames.in:
832         * css/CSSStyleSelector.cpp:
833         (WebCore::CSSStyleSelector::applyProperty):
834
835 2011-10-17  Kentaro Hara  <haraken@chromium.org>
836
837         MessageEvent.data can be stored as ScriptValue.
838         https://bugs.webkit.org/show_bug.cgi?id=68978
839
840         Reviewed by Hajime Morita.
841
842         Currently, the following test cases fail or crash:
843
844         - shouldBe("new MessageEvent('eventType', { data: test_object }).data", "test_object") -> FAIL
845         - new MessageEvent('eventType', { data: document }).data -> CRASH
846
847         This is because MessageEvent.data is implemented just as SerializedScriptValue
848         and it cannot keep ScriptValue passed by JavaScript. This patch makes the following changes:
849
850         - If MessageEvent is constructed with ScriptValue, it is stored as ScriptValue internally.
851         When MessageEvent.data is called, the ScriptValue is returned.
852         - If MessageEvent is constructed with SerializedScriptValue, it is stored as
853         SerializedScriptValue internally (since we cannot deserialize it into ScriptValue
854         at this point because of lack of ExecState). When MessageEvent.data is called,
855         the SerializedScriptValue is deserialized into the corresponding ScriptValue,
856         and the ScriptValue is returned.
857
858         This patch does not make a fix for ObjC bindings code, since we need to first fix
859         the bug 28774, as commented in dom/MessageEvent.h and dom/MessageEvent.cpp.
860
861         Test: fast/events/constructors/message-event-constructor.html
862
863         * bindings/js/JSMessageEventCustom.cpp:
864         (WebCore::JSMessageEvent::data): Custom getter for MessageEvent.data. Supported ScriptValue.
865         (WebCore::JSMessageEvent::initMessageEvent): Changed SerializedScriptValue to ScriptValue.
866         * bindings/v8/custom/V8MessageEventCustom.cpp:
867         (WebCore::V8MessageEvent::dataAccessorGetter): Custom getter for MessageEvent.data. Supported ScriptValue.
868         (WebCore::V8MessageEvent::portsAccessorGetter): Removed extra spaces.
869         (WebCore::V8MessageEvent::initMessageEventCallback): Changed SerializedScriptValue to ScriptValue.
870         * dom/MessageEvent.cpp:
871         (WebCore::MessageEvent::MessageEvent): Supported ScriptValue.
872         (WebCore::MessageEvent::initMessageEvent): Supported ScriptValue.
873         (WebCore::MessageEvent::isMessageEvent): Removed extra spaces.
874         * dom/MessageEvent.h: Added DataType::DataTypeScriptValue.
875         (WebCore::MessageEvent::create): Supported ScriptValue.
876         (WebCore::MessageEvent::dataAsScriptValue): Getter for data. Insert ASSERT() to guarantee that this accessor is not called for unintended type of data.
877         (WebCore::MessageEvent::dataAsSerializedScriptValue): Ditto.
878         (WebCore::MessageEvent::dataAsString): Ditto.
879         (WebCore::MessageEvent::dataAsBlob): Ditto.
880         (WebCore::MessageEvent::dataAsArrayBuffer): Ditto.
881         * dom/MessageEvent.idl: Changed SerializedScriptValue to DOMObject (i.e. ScriptValue). This patch does not touch an ObjC part.
882
883 2011-10-17  Shinya Kawanaka  <shinyak@google.com>
884
885         Unified spell-checking and legacy spell checking should be easy to switch
886         https://bugs.webkit.org/show_bug.cgi?id=69242
887
888         Reviewed by Hajime Morita.
889
890         WebCore has two different code paths for spell-checking:
891                   1) checkTextOfParagraph() for Snow Leopard or later
892                   2) checkSpellingOfString() for checkGrammarOfString() for other platforms.
893
894         This patch introduces a flag to change code paths dynamically.
895         This patch also includes build fix for QT, GTK, and Windows platforms.
896
897         No new tests because this patch does not change a behavior.
898
899         * CMakeLists.txt:
900         * GNUmakefile.list.am:
901         * WebCore.pro:
902         * WebCore.vcproj/WebCore.vcproj:
903         * accessibility/AccessibilityObject.cpp:
904         (WebCore::AccessibilityObject::hasMisspelling):
905           Changed static if-USE(UNIFIED_TEXT_CHECKING) statement to dynamic
906           condition branch to achieve easy code path change.
907         * accessibility/mac/WebAccessibilityObjectWrapper.mm: ditto.
908         (AXAttributeStringSetSpelling):
909         * editing/EditingAllInOne.cpp:
910         * editing/Editor.cpp:
911         (WebCore::Editor::advanceToNextMisspelling): ditto.
912         (WebCore::Editor::guessesForMisspelledOrUngrammaticalSelection): ditto.
913         (WebCore::Editor::markMisspellingsAfterTypingToWord): ditto.
914         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges): ditto.
915         (WebCore::Editor::changeBackToReplacedString): ditto.
916         (WebCore::Editor::markMisspellingsAndBadGrammar): ditto.
917         (WebCore::Editor::unifiedTextCheckerEnabled):
918           Utility method to check using unified text checking or not.
919         * editing/Editor.h:
920         * editing/TextCheckingHelper.cpp:
921         (WebCore::TextCheckingHelper::findFirstMisspellingOrBadGrammar):
922           Same as WebCore::AccessibilityObject::hasMisspelling.
923         (WebCore::TextCheckingHelper::guessesForMisspelledOrUngrammaticalRange): ditto.
924         (WebCore::TextCheckingHelper::unifiedTextCheckerEnabled):
925           Utility method to check using unified text checking or not.
926         (WebCore::unifiedTextCheckerEnabled): ditto.
927         * editing/TextCheckingHelper.h:
928         * page/Settings.cpp:
929         (WebCore::Settings::Settings):
930           Includes a flag to change the code path.
931         * page/Settings.h:
932         (WebCore::Settings::setUnifiedTextCheckerEnabled):
933           Sets a flag to change the code path.
934         (WebCore::Settings::unifiedTextCheckerEnabled):
935           A flag to change the code path.
936
937 2011-10-17  Julien Chaffraix  <jchaffraix@webkit.org>
938
939         Unreviewed build fix after 97691.
940
941         * html/HTMLTableCellElement.h:
942         (WebCore::toHTMLTableCellElement): Avoid declaring the same function twice.
943
944 2011-10-12  Ojan Vafai  <ojan@chromium.org>
945
946         Unreviewed, rolling out r97661.
947         http://trac.webkit.org/changeset/97661
948
949         Confirmed this patch was not the cause of the test failures.
950
951         display:inline-block elements don't correctly handle orthogonal writing-modes 
952         https://bugs.webkit.org/show_bug.cgi?id=69957 
953         
954         Reading min/maxPreferredLogicalWidth from a child uses the child's writing-mode. 
955         Instead, we need to grab the result based on the parent's writing-mode. 
956         In the case of orthogonal writing-modes, we need the child's logical height. 
957     
958         Tests: fast/writing-mode/borders-expected.html 
959                fast/writing-mode/borders.html 
960         
961         * rendering/RenderBlock.cpp: 
962         (WebCore::RenderBlock::computeBlockPreferredLogicalWidths): 
963
964 2011-10-17  James Robinson  <jamesr@chromium.org>
965
966         Unreviewed, rolling out r97690.
967         http://trac.webkit.org/changeset/97690
968         https://bugs.webkit.org/show_bug.cgi?id=70161
969
970         Hits assertion in CCLayerTreeHostTests
971
972         * WebCore.gypi:
973         * platform/graphics/chromium/cc/CCMainThread.h:
974         * platform/graphics/chromium/cc/CCMainThreadTask.h:
975         (WebCore::createMainThreadTask):
976         * platform/graphics/chromium/cc/CCScopedMainThreadProxy.h: Removed.
977         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
978         (WebCore::CCThreadProxySchedulerClient::scheduleBeginFrameAndCommit):
979         (WebCore::CCThreadProxy::CCThreadProxy):
980         (WebCore::CCThreadProxy::stop):
981         * platform/graphics/chromium/cc/CCThreadProxy.h:
982
983 2011-10-17  Julien Chaffraix  <jchaffraix@webkit.org>
984
985         Remove colSpan / rowSpan caching from RenderTableCell
986         https://bugs.webkit.org/show_bug.cgi?id=69569
987
988         Reviewed by Darin Adler.
989
990         Memory optimization, no change in behavior expected.
991
992         This change removes m_colSpan & m_rowSpan from RenderTableCell (inspired by
993         kling's memory shaving effort).
994
995         This makes us save 8 bytes per RenderTableCell on my machine (x86-64). No slowdown
996         on PageCycler Alexa-US.
997
998         This change refactored the way we handle updates from the DOM side to simplify
999         the code using the following: colspan / rowspan updates always go through
1000         parseMappedAttribute where we already check for the renderer type. Thus removed the
1001         generic updateFromElement and replaced it with colSpanOrRowSpanChanged. This removes
1002         a virtual dispatch.
1003
1004         As there is no way to know if an attribute has changed in the parseMappedAttribute code,
1005         we now unconditionally call colSpanOrRowSpanChanged. Looking at Chromium's page data,
1006         colSpan and rowSpan are never changed outside the HTML markup thus such a change should
1007         have a limited impact.
1008
1009         * html/HTMLTableCellElement.cpp:
1010         (WebCore::HTMLTableCellElement::parseMappedAttribute): Updated after updateFromElement
1011         removal.
1012
1013         * html/HTMLTableCellElement.h:
1014         (WebCore::toHTMLTableCellElement): Added the usual conversion functions.
1015
1016         * rendering/RenderTableCell.cpp:
1017         (WebCore::RenderTableCell::RenderTableCell): Added a boolean to know if we have
1018         the right type of associated DOM node to avoid the cost of checking that every
1019         time.
1020
1021         (WebCore::RenderTableCell::colSpan):
1022         (WebCore::RenderTableCell::rowSpan):
1023         Forwarded the calls to our object if we have the right type (normal case).
1024
1025         (WebCore::RenderTableCell::colSpanOrRowSpanChanged): Handles the
1026         updateFromElement calls but in a more streamlined way.
1027
1028         * rendering/RenderTableCell.h:
1029
1030 2011-10-17  James Robinson  <jamesr@chromium.org>
1031
1032         [chromium] Fix shutdown race when posting main thread task to CCThreadProxy and enable tests
1033         https://bugs.webkit.org/show_bug.cgi?id=70161
1034
1035         Reviewed by David Levin.
1036
1037         Adds a weak pointer mechanism to cancel main thread tasks posted to CCThreadProxy instances from the compositor
1038         thread. Previously there was a race condition where main thread tasks could run even after the CCThreadProxy was
1039         destroyed.
1040
1041         This race does not exist in the other direction because when tearing down a CCThreadProxy we first post a quit
1042         task to the compositor thread and then suspend execution of the main thread until all compositor tasks for the
1043         CCThreadProxy have been drained.
1044
1045         Covered by the now-enabled CCLayerTreeHostTest* unit tests.
1046
1047         * WebCore.gypi:
1048         * platform/graphics/chromium/cc/CCScopedMainThreadProxy.h: Added.
1049         (WebCore::CCScopedMainThreadProxy::create):
1050         (WebCore::CCScopedMainThreadProxy::postTask):
1051         (WebCore::CCScopedMainThreadProxy::shutdown):
1052         (WebCore::CCScopedMainThreadProxy::CCScopedMainThreadProxy):
1053         (WebCore::CCScopedMainThreadProxy::runTaskIfNotShutdown):
1054         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
1055         (WebCore::CCThreadProxy::CCThreadProxy):
1056         (WebCore::CCThreadProxy::~CCThreadProxy):
1057         (WebCore::CCThreadProxy::createBeginFrameAndCommitTaskOnCCThread):
1058         * platform/graphics/chromium/cc/CCThreadProxy.h:
1059
1060 2011-10-17  Sheriff Bot  <webkit.review.bot@gmail.com>
1061
1062         Unreviewed, rolling out r97641.
1063         http://trac.webkit.org/changeset/97641
1064         https://bugs.webkit.org/show_bug.cgi?id=70288
1065
1066         "This change may have broken mouse/hit-test coordinate tests."
1067         (Requested by jeffm7 on #webkit).
1068
1069         * platform/Widget.cpp:
1070         (WebCore::Widget::convertFromContainingWindow):
1071         (WebCore::Widget::convertToContainingWindow):
1072
1073 2011-10-17  Andreas Kling  <kling@webkit.org>
1074
1075         CSSParser: Remove unused variable 'propertyComponents'
1076         https://bugs.webkit.org/show_bug.cgi?id=70230
1077
1078         Reviewed by Darin Adler.
1079
1080         (WebCore::CSSParser::markPropertyEnd):
1081
1082 2011-10-17  Shawn Singh  <shawnsingh@chromium.org>
1083
1084         [chromium] Update comments about transform hierarchy in CCLayerTreeHostCommon
1085         https://bugs.webkit.org/show_bug.cgi?id=69765
1086
1087         Reviewed by James Robinson.
1088
1089         Only comments changed, no tests needed.
1090
1091         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
1092         (WebCore::calculateDrawTransformsAndVisibilityInternal):
1093
1094 2011-10-17  Dan Bernstein  <mitz@apple.com>
1095
1096         Remove unnecessary calls to columnRectAt()
1097         https://bugs.webkit.org/show_bug.cgi?id=70283
1098
1099         Reviewed by Darin Adler.
1100
1101         These call sites only needed one of the column dimensions, which are independent of the column
1102         index, and can be retrieved directly from the ColumnInfo.
1103
1104         * rendering/RenderBlock.cpp:
1105         (WebCore::RenderBlock::paintColumnRules):
1106         (WebCore::RenderBlock::hitTestColumns):
1107
1108 2011-10-17  Andreas Kling  <kling@webkit.org>
1109
1110         Protect against incorrect Element::fast*Attribute() usage.
1111         https://bugs.webkit.org/show_bug.cgi?id=67612
1112
1113         Reviewed by Darin Adler.
1114
1115         Add debug-only checks in Element's fastHasAttribute() and fastGetAttribute() to verify
1116         that we aren't looking up the "style" attribute or any of the SVG animatable attributes.
1117
1118         No new tests, erroneous behavior is covered by assertions.
1119
1120         * WebCore.exp.in: Export Element::fastAttributeLookupAllowed() for debug builds
1121         since it's used by the inline fast*Attribute() calls.
1122         * css/CSSStyleSelector.cpp:
1123         (WebCore::CSSStyleSelector::canShareStyleWithElement): Use getAttribute() for class.
1124         * css/SelectorChecker.cpp:
1125         (WebCore::linkAttribute): Use getAttribute() for xlink:href.
1126         * dom/Element.cpp:
1127         (WebCore::Element::getAttribute): Manually inline fastGetAttribute() in ideal case.
1128         (WebCore::Element::fastAttributeLookupAllowed): Checks if an attribute can be used
1129         with the fast lookup functions.
1130         * dom/Element.h:
1131         (WebCore::Element::fastHasAttribute): Add assertion.
1132         (WebCore::Element::fastGetAttribute): Ditto.
1133         * editing/ApplyStyleCommand.cpp:
1134         (WebCore::hasNoAttributeOrOnlyStyleAttribute): Use getAttribute() for class.
1135         * editing/ReplaceSelectionCommand.cpp:
1136         (WebCore::isInlineNodeWithStyle): Ditto.
1137         * html/ClassList.cpp:
1138         (WebCore::ClassList::ClassList): Ditto.
1139         (WebCore::ClassList::addInternal): Ditto.
1140         (WebCore::ClassList::removeInternal): Ditto.
1141         (WebCore::ClassList::toString): Ditto.
1142         * svg/SVGAltGlyphElement.cpp:
1143         (WebCore::SVGAltGlyphElement::hasValidGlyphElements): Use getAttribute() for xlink:href.
1144         * svg/SVGAnimateMotionElement.cpp:
1145         (WebCore::SVGAnimateMotionElement::rotateMode): Use getAttribute() for rotate.
1146         * svg/SVGAnimationElement.cpp:
1147         (WebCore::SVGAnimationElement::animationMode): Use getAttribute() for values.
1148         * svg/SVGElement.cpp:
1149         (WebCore::SVGElement::isAnimatableAttribute): Added, returns true if the given
1150         QualifiedName represents an animatable attribute.
1151         * svg/SVGElement.h:
1152         * svg/SVGFontFaceUriElement.cpp:
1153         (WebCore::SVGFontFaceUriElement::srcValue): Use getAttribute() for xlink:href.
1154         (WebCore::SVGFontFaceUriElement::loadFont): Ditto.
1155         * svg/animation/SVGSMILElement.cpp:
1156         (WebCore::SVGSMILElement::xlinkHref): Ditto.
1157         * svg/SVGGlyphRefElement.cpp:
1158         (WebCore::SVGGlyphRefElement::hasValidGlyphElement): Ditto.
1159         * svg/SVGStyleElement.cpp:
1160         (WebCore::SVGStyleElement::type): Use getAttribute() for type.
1161
1162 2011-10-17  Chris Fleizach  <cfleizach@apple.com>
1163
1164         AX: buttons of number type <input> controls are not fully accessible
1165         https://bugs.webkit.org/show_bug.cgi?id=70241
1166
1167         Expose the spin button object to the AX hierarchy. Since there is no distinct
1168         render object that backs this object, a mock object needs to be created for the entire
1169         spin button and the actual increment and decrement buttons inside.
1170
1171         Reviewed by Darin Adler.
1172
1173         Test: platform/mac/accessibility/html5-input-number.html
1174
1175         * CMakeLists.txt:
1176         * GNUmakefile.list.am:
1177         * WebCore.gypi:
1178         * WebCore.pro:
1179         * WebCore.vcproj/WebCore.vcproj:
1180         * WebCore.xcodeproj/project.pbxproj:
1181         * accessibility/AXObjectCache.cpp:
1182         (WebCore::AXObjectCache::getOrCreate):
1183         * accessibility/AccessibilityMockObject.cpp:
1184         (WebCore::AccessibilityMockObject::AccessibilityMockObject):
1185         * accessibility/AccessibilityMockObject.h:
1186         (WebCore::AccessibilityMockObject::isMockObject):
1187         * accessibility/AccessibilityObject.cpp:
1188         (WebCore::AccessibilityObject::boundingBoxForQuads):
1189         (WebCore::AccessibilityObject::elementAccessibilityHitTest):
1190         * accessibility/AccessibilityObject.h:
1191         (WebCore::AccessibilityObject::isSpinButton):
1192         (WebCore::AccessibilityObject::isSpinButtonPart):
1193         (WebCore::AccessibilityObject::isMockObject):
1194         * accessibility/AccessibilityRenderObject.cpp:
1195         (WebCore::AccessibilityRenderObject::boundingBoxRect):
1196         (WebCore::AccessibilityRenderObject::addImageMapChildren):
1197         (WebCore::AccessibilityRenderObject::addTextFieldChildren):
1198         (WebCore::AccessibilityRenderObject::addChildren):
1199         * accessibility/AccessibilityRenderObject.h:
1200         * accessibility/AccessibilitySpinButton.cpp: Added.
1201         (WebCore::AccessibilitySpinButton::create):
1202         (WebCore::AccessibilitySpinButton::AccessibilitySpinButton):
1203         (WebCore::AccessibilitySpinButton::~AccessibilitySpinButton):
1204         (WebCore::AccessibilitySpinButton::incrementButton):
1205         (WebCore::AccessibilitySpinButton::decrementButton):
1206         (WebCore::AccessibilitySpinButton::elementRect):
1207         (WebCore::AccessibilitySpinButton::addChildren):
1208         (WebCore::AccessibilitySpinButton::step):
1209         (WebCore::AccessibilitySpinButtonPart::AccessibilitySpinButtonPart):
1210         (WebCore::AccessibilitySpinButtonPart::create):
1211         (WebCore::AccessibilitySpinButtonPart::elementRect):
1212         (WebCore::AccessibilitySpinButtonPart::press):
1213         * accessibility/AccessibilitySpinButton.h: Added.
1214         (WebCore::AccessibilitySpinButton::setSpinButtonElement):
1215         (WebCore::AccessibilitySpinButton::roleValue):
1216         (WebCore::AccessibilitySpinButton::accessibilityIsIgnored):
1217         (WebCore::AccessibilitySpinButton::isSpinButton):
1218         (WebCore::AccessibilitySpinButtonPart::~AccessibilitySpinButtonPart):
1219         (WebCore::AccessibilitySpinButtonPart::isIncrementor):
1220         (WebCore::AccessibilitySpinButtonPart::setIsIncrementor):
1221         (WebCore::AccessibilitySpinButtonPart::roleValue):
1222         (WebCore::AccessibilitySpinButtonPart::isSpinButtonPart):
1223         (WebCore::AccessibilitySpinButtonPart::accessibilityIsIgnored):
1224         (WebCore::toAccessibilitySpinButton):
1225         (WebCore::toAccessibilitySpinButtonPart):
1226         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
1227         (-[WebAccessibilityObjectWrapper accessibilityActionNames]):
1228         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
1229         (-[WebAccessibilityObjectWrapper subrole]):
1230         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
1231         * html/shadow/TextControlInnerElements.cpp:
1232         (WebCore::SpinButtonElement::step):
1233         (WebCore::SpinButtonElement::repeatingTimerFired):
1234         * html/shadow/TextControlInnerElements.h:
1235
1236 2011-10-17  Dmitry Titov  <dimich@chromium.org>
1237
1238         Re-landing: window.webkitNotifications uses deallocated NotificationPresenter after live Iframe transfer.
1239         https://bugs.webkit.org/show_bug.cgi?id=70147
1240
1241         Reviewed by David Levin.
1242
1243         I only found a way to test this manually, since Chromium TestShell uses static instance
1244         of NotificationPresenter instead of per-page one so the issue does not reproduce.
1245         Adding manual test that works in full build of Chromium.
1246
1247         * manual-tests/iframe_notifications/iframe-reparenting-close-window-child.html: Added.
1248         * manual-tests/iframe_notifications/iframe-reparenting-close-window-iframe.html: Added.
1249         * manual-tests/iframe_notifications/iframe-reparenting-close-window.html: Added.
1250         * notifications/NotificationCenter.cpp:
1251         (WebCore::NotificationCenter::disconnectFrame):
1252         * page/DOMWindow.cpp:
1253         (WebCore::DOMWindow::resetNotifications):
1254         * page/DOMWindow.h:
1255         * page/Frame.cpp:
1256         (WebCore::Frame::transferChildFrameToNewDocument): reset webkitNotifications object.
1257
1258 2011-10-17  Arno Renevier  <arno@renevier.net>
1259
1260         quote "attributes" keyword in CodeGeneratorGObject.pm
1261         https://bugs.webkit.org/show_bug.cgi?id=64348
1262
1263         Reviewed by Darin Adler.
1264
1265         No change of functionality. No new tests.
1266
1267         * bindings/scripts/CodeGeneratorGObject.pm:
1268
1269 2011-10-17  Ojan Vafai  <ojan@chromium.org>
1270
1271         Unreviewed, rolling out r97654.
1272         http://trac.webkit.org/changeset/97654
1273         https://bugs.webkit.org/show_bug.cgi?id=68497
1274
1275         Caused a number of Chromium failures.
1276
1277         * rendering/RenderBox.cpp:
1278         (WebCore::RenderBox::sizesToIntrinsicLogicalWidth):
1279
1280 2011-10-17  Ojan Vafai  <ojan@chromium.org>
1281
1282         Unreviewed, rolling out r97653.
1283         http://trac.webkit.org/changeset/97653
1284         https://bugs.webkit.org/show_bug.cgi?id=69957
1285
1286         Caused a number of Chromium failures.
1287
1288         * rendering/RenderBlock.cpp:
1289         (WebCore::RenderBlock::computeBlockPreferredLogicalWidths):
1290
1291 2011-10-17  Rafael Weinstein  <rafaelw@chromium.org>
1292
1293         [MutationObservers] Implement WebKitMutationObserver.observe for attributes
1294         https://bugs.webkit.org/show_bug.cgi?id=68956
1295
1296         Reviewed by Ryosuke Niwa.
1297
1298         Test: fast/mutation/observe-attributes.html
1299
1300         This adds an initial implementation for registering mutation observers on nodes,
1301         delivering mutation records at the end of the outer-most script invokation and
1302         observing mutations to element attributes.
1303
1304         Note that the outer-most script invokation only works in V8.
1305
1306         Note also that support for observing changes to the style attribute when updated
1307         via the style property is not implemented here.
1308
1309         * bindings/v8/V8Proxy.cpp:
1310         (WebCore::V8Proxy::didLeaveScriptContext):
1311         * dom/Element.cpp:
1312         (WebCore::enqueueAttributesMutationRecord):
1313         (WebCore::Element::setAttribute):
1314         * dom/MutationRecord.cpp:
1315         (WebCore::MutationRecord::createAttributes):
1316         * dom/MutationRecord.h:
1317         * dom/MutationRecord.idl:
1318         * dom/Node.cpp:
1319         (WebCore::Node::clearRareData):
1320         (WebCore::Node::mutationObserverData):
1321         (WebCore::Node::ensureMutationObserverData):
1322         (WebCore::Node::registeredMutationObserversOfType):
1323         (WebCore::Node::registerMutationObserver):
1324         (WebCore::Node::deregisterMutationObserver):
1325         * dom/Node.h:
1326         * dom/NodeRareData.h:
1327         (WebCore::MutationObserverRegistration::MutationObserverRegistration):
1328         (WebCore::MutationObserverRegistration::operator==):
1329         (WebCore::MutationObserverData::MutationObserverData):
1330         (WebCore::MutationObserverData::~MutationObserverData):
1331         (WebCore::NodeRareData::mutationObserverData):
1332         (WebCore::NodeRareData::ensureMutationObserverData):
1333         * dom/WebKitMutationObserver.cpp:
1334         (WebCore::WebKitMutationObserver::observe):
1335         (WebCore::WebKitMutationObserver::disconnect):
1336         (WebCore::WebKitMutationObserver::wasDeregistered):
1337         (WebCore::activeMutationObservers):
1338         (WebCore::WebKitMutationObserver::enqueueMutationRecord):
1339         (WebCore::WebKitMutationObserver::deliverAllMutations):
1340         (WebCore::WebKitMutationObserver::deliver):
1341         * dom/WebKitMutationObserver.h:
1342
1343 2011-10-17  Andreas Kling  <kling@webkit.org>
1344
1345         HTMLKeygenElement: Don't cache keytype and challenge attributes.
1346         https://bugs.webkit.org/show_bug.cgi?id=68365
1347
1348         Reviewed by Darin Adler.
1349
1350         * html/HTMLKeygenElement.cpp:
1351         (WebCore::HTMLKeygenElement::parseMappedAttribute):
1352         (WebCore::HTMLKeygenElement::appendFormData):
1353         * html/HTMLKeygenElement.h:
1354
1355 2011-09-22  Ojan Vafai  <ojan@chromium.org>
1356
1357         incorrect height with height:auto and writing-mode:vertical-rl
1358         https://bugs.webkit.org/show_bug.cgi?id=68497
1359
1360         Reviewed by David Hyatt.
1361
1362         * rendering/RenderBox.cpp:
1363         (WebCore::RenderBox::sizesToIntrinsicLogicalWidth):
1364
1365 2011-10-12  Ojan Vafai  <ojan@chromium.org>
1366
1367         display:inline-block elements don't correctly handle orthogonal writing-modes
1368         https://bugs.webkit.org/show_bug.cgi?id=69957
1369
1370         Reviewed by David Hyatt.
1371
1372         Reading min/maxPreferredLogicalWidth from a child uses the child's writing-mode.
1373         Instead, we need to grab the result based on the parent's writing-mode.
1374         In the case of orthogonal writing-modes, we need the child's logical height.
1375
1376         Tests: fast/writing-mode/borders-expected.html
1377                fast/writing-mode/borders.html
1378
1379         * rendering/RenderBlock.cpp:
1380         (WebCore::RenderBlock::computeBlockPreferredLogicalWidths):
1381
1382 2011-10-17  Sheriff Bot  <webkit.review.bot@gmail.com>
1383
1384         Unreviewed, rolling out r97643.
1385         http://trac.webkit.org/changeset/97643
1386         https://bugs.webkit.org/show_bug.cgi?id=70270
1387
1388         Broke iframe reparenting tests (Requested by dimich on
1389         #webkit).
1390
1391         * manual-tests/iframe_notifications/iframe-reparenting-close-window-child.html: Removed.
1392         * manual-tests/iframe_notifications/iframe-reparenting-close-window-iframe.html: Removed.
1393         * manual-tests/iframe_notifications/iframe-reparenting-close-window.html: Removed.
1394         * notifications/NotificationCenter.cpp:
1395         (WebCore::NotificationCenter::disconnectFrame):
1396         * page/DOMWindow.cpp:
1397         (WebCore::DOMWindow::webkitNotifications):
1398         * page/DOMWindow.h:
1399         * page/Frame.cpp:
1400         (WebCore::Frame::transferChildFrameToNewDocument):
1401
1402 2011-10-17  Dmitry Titov  <dimich@chromium.org>
1403
1404         window.webkitNotifications uses deallocated NotificationPresenter after live Iframe transfer.
1405         https://bugs.webkit.org/show_bug.cgi?id=70147
1406
1407         Reviewed by David Levin.
1408
1409         I only found a way to test this manually, since Chromium TestShell uses static instance
1410         of NotificationPresenter instead of per-page one so the issue does not reproduce.
1411         Adding manual test that works in full build of Chromium.
1412
1413         * manual-tests/iframe_notifications/iframe-reparenting-close-window-child.html: Added.
1414         * manual-tests/iframe_notifications/iframe-reparenting-close-window-iframe.html: Added.
1415         * manual-tests/iframe_notifications/iframe-reparenting-close-window.html: Added.
1416         * notifications/NotificationCenter.cpp:
1417         (WebCore::NotificationCenter::disconnectFrame):
1418         * page/DOMWindow.cpp:
1419         (WebCore::DOMWindow::resetNotifications):
1420         * page/DOMWindow.h:
1421         * page/Frame.cpp:
1422         (WebCore::Frame::transferChildFrameToNewDocument): reset webkitNotifications object.
1423
1424 2011-10-17  Jeff Miller  <jeffm@apple.com>
1425
1426         Widget window coordinate functions should use root view coordinate functions
1427         https://bugs.webkit.org/show_bug.cgi?id=70152
1428
1429         Reviewed by Darin Adler.
1430
1431         No new tests, no changes to functionality.
1432
1433         * platform/Widget.cpp:
1434         (WebCore::Widget::convertFromContainingWindow): Use convertFromRootView().
1435         (WebCore::Widget::convertToContainingWindow): Use convertToRootView().
1436
1437 2011-10-14  Chris Marrin  <cmarrin@apple.com>
1438
1439         Throttle rate of requestAnimationFrame when page is not visible
1440         https://bugs.webkit.org/show_bug.cgi?id=67873
1441
1442         Reviewed by Anders Carlsson.
1443
1444         Add logic to suspend and resume scripted animations when page is hidden,
1445         minimized or the tab is not visible. The hide/minimize notification comes
1446         in from WebKit/WebKit2 to a new set of functions.
1447
1448         * WebCore.exp.in:
1449         * page/Page.cpp:
1450         (WebCore::Page::didMoveOnscreen):
1451         (WebCore::Page::willMoveOffscreen):
1452         (WebCore::Page::suspendScriptedAnimations):
1453         (WebCore::Page::resumeScriptedAnimations):
1454         * page/Page.h:
1455
1456 2011-10-17  Antti Koivisto  <antti@apple.com>
1457
1458         https://bugs.webkit.org/show_bug.cgi?id=69966
1459         Eliminate separate RenderStyle for visited link style
1460
1461         Reviewed by Dave Hyatt and Nikolas Zimmermann.
1462
1463         There are only a few properties that can apply to visited links and they can
1464         be part of the regular style. Many things will get simpler when the separate 
1465         RenderStyle for visited links is eliminated.
1466         
1467         - Add valid visited link properties as separate fields to RenderStyle. The  
1468           visitedLinkColor goes to inherited, everything else goes to rare data structures.
1469         - Make RenderStyle::visitedDependentColor() get the visited style from the new fields.
1470         - As VISITED_LINK pseudo style doesn't exists anymore, remove all code dealing with it.
1471         - Make CSSStyleSelector and ApplyPropertyColor apply the visited link style to the
1472           newly added fields instead of a separate RenderStyle.
1473         - Same thing with SVGRenderStyle, SVGCSSStyleSelector.
1474         - Fixup the SVG visited link style code to use the new fields.
1475
1476         This is ~15% progression in styleForElement performance over the HTML5 spec load.
1477
1478         * css/CSSStyleApplyProperty.cpp:
1479         (WebCore::ApplyPropertyColor::ApplyPropertyColor):
1480         (WebCore::ApplyPropertyColor::applyInheritValue):
1481         (WebCore::ApplyPropertyColor::applyInitialValue):
1482         (WebCore::ApplyPropertyColor::applyValue):
1483         (WebCore::ApplyPropertyColor::applyColorValue):
1484         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
1485         * css/CSSStyleSelector.cpp:
1486         (WebCore::CSSStyleSelector::CSSStyleSelector):
1487         (WebCore::CSSStyleSelector::styleForElement):
1488         (WebCore::CSSStyleSelector::pseudoStyleForElement):
1489         (WebCore::CSSStyleSelector::updateFont):
1490         (WebCore::CSSStyleSelector::applyDeclaration):
1491         (WebCore::CSSStyleSelector::applyDeclarations):
1492         (WebCore::CSSStyleSelector::applyProperty):
1493         (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
1494         * css/CSSStyleSelector.h:
1495         (WebCore::CSSStyleSelector::applyPropertyToRegularStyle):
1496         (WebCore::CSSStyleSelector::applyPropertyToVisitedLinkStyle):
1497         * css/SVGCSSStyleSelector.cpp:
1498         (WebCore::CSSStyleSelector::applySVGProperty):
1499         * dom/Element.cpp:
1500         (WebCore::Element::pseudoStyleCacheIsInvalid):
1501         * rendering/style/RenderStyle.cpp:
1502         (WebCore::RenderStyle::getCachedPseudoStyle):
1503         (WebCore::RenderStyle::colorIncludingFallback):
1504         (WebCore::RenderStyle::visitedDependentColor):
1505         * rendering/style/RenderStyle.h:
1506         (WebCore::InheritedFlags::setVisitedLinkColor):
1507         (WebCore::InheritedFlags::setVisitedLinkBackgroundColor):
1508         (WebCore::InheritedFlags::setVisitedLinkBorderLeftColor):
1509         (WebCore::InheritedFlags::setVisitedLinkBorderRightColor):
1510         (WebCore::InheritedFlags::setVisitedLinkBorderBottomColor):
1511         (WebCore::InheritedFlags::setVisitedLinkBorderTopColor):
1512         (WebCore::InheritedFlags::setVisitedLinkOutlineColor):
1513         (WebCore::InheritedFlags::setVisitedLinkColumnRuleColor):
1514         (WebCore::InheritedFlags::setVisitedLinkTextEmphasisColor):
1515         (WebCore::InheritedFlags::setVisitedLinkTextFillColor):
1516         (WebCore::InheritedFlags::setVisitedLinkTextStrokeColor):
1517         * rendering/style/RenderStyleConstants.h:
1518         * rendering/style/SVGRenderStyle.h:
1519         (WebCore::SVGRenderStyle::setVisitedLinkFillPaint):
1520         (WebCore::SVGRenderStyle::setVisitedLinkStrokePaint):
1521         (WebCore::SVGRenderStyle::visitedLinkFillPaintType):
1522         (WebCore::SVGRenderStyle::visitedLinkFillPaintColor):
1523         (WebCore::SVGRenderStyle::visitedLinkStrokePaintType):
1524         (WebCore::SVGRenderStyle::visitedLinkStrokePaintColor):
1525         * rendering/style/SVGRenderStyleDefs.cpp:
1526         (WebCore::StyleFillData::StyleFillData):
1527         (WebCore::StyleFillData::operator==):
1528         (WebCore::StyleStrokeData::StyleStrokeData):
1529         (WebCore::StyleStrokeData::operator==):
1530         * rendering/style/SVGRenderStyleDefs.h:
1531         * rendering/style/StyleInheritedData.cpp:
1532         (WebCore::StyleInheritedData::StyleInheritedData):
1533         (WebCore::StyleInheritedData::operator==):
1534         * rendering/style/StyleInheritedData.h:
1535         * rendering/style/StyleMultiColData.cpp:
1536         (WebCore::StyleMultiColData::StyleMultiColData):
1537         (WebCore::StyleMultiColData::operator==):
1538         * rendering/style/StyleMultiColData.h:
1539         * rendering/style/StyleRareInheritedData.cpp:
1540         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
1541         (WebCore::StyleRareInheritedData::operator==):
1542         * rendering/style/StyleRareInheritedData.h:
1543         * rendering/style/StyleRareNonInheritedData.cpp:
1544         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1545         (WebCore::StyleRareNonInheritedData::operator==):
1546         * rendering/style/StyleRareNonInheritedData.h:
1547         * rendering/svg/RenderSVGResource.cpp:
1548         (WebCore::requestPaintingResource):
1549
1550 2011-10-17  Eric Carlson  <eric.carlson@apple.com>
1551
1552         Cues should be loaded by the cached resource loader
1553         https://bugs.webkit.org/show_bug.cgi?id=70134
1554
1555         Reviewed by Darin Adler.
1556
1557         No new tests, changes covered by existing tests.
1558
1559         * CMakeLists.txt: Add CachedCues.cpp/h.
1560         * GNUmakefile.list.am: Ditto.
1561         * WebCore.gypi: Ditto.
1562         * WebCore.xcodeproj/project.pbxproj: Ditto.
1563
1564         * loader/cache/CachedCues.cpp: Added.
1565         (WebCore::CachedCues::CachedCues):
1566         (WebCore::CachedCues::~CachedCues):
1567         (WebCore::CachedCues::data): Called when new data has been loaded, pass it to all registered
1568             clients.
1569         * loader/cache/CachedCues.h: Added.
1570
1571         * loader/cache/CachedResource.cpp:
1572         (WebCore::defaultPriorityForResourceType): Cues have low loader priority.
1573         * loader/cache/CachedResource.h:
1574
1575         * loader/cache/CachedResourceClient.h:
1576         (WebCore::CachedResourceClient::didReceiveData): New client interface.
1577
1578         * loader/cache/CachedResourceLoader.cpp:
1579         (WebCore::createResource): Create and return a new cue loader.
1580         (WebCore::CachedResourceLoader::requestCues):
1581         (WebCore::CachedResourceLoader::checkInsecureContent): Cues aren't mentioned in the CPS spec
1582             yet, but they only work with a media element so use the mdia policy.
1583         (WebCore::CachedResourceLoader::canRequest): Allow cues to be loaded from any origin like media.
1584         * loader/cache/CachedResourceLoader.h:
1585
1586         * loader/cache/CachedResourceRequest.cpp:
1587         (WebCore::cachedResourceTypeToTargetType):
1588         * platform/network/chromium/ResourceRequest.h:
1589
1590 2011-10-17  Dan Bernstein  <mitz@apple.com>
1591
1592         <rdar://problem/10293929> REGRESSION (r97525): iChat transcript has horizontal scroll bar when the conversation includes a wide image
1593         https://bugs.webkit.org/show_bug.cgi?id=70204
1594
1595         Reviewed by Darin Adler.
1596
1597         Reverted r97525, which was supposed to fix <http://webkit.org/b/29447>.
1598
1599         * rendering/RenderBox.cpp:
1600         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
1601         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
1602         * rendering/RenderBox.h:
1603
1604 2011-10-17  Ada Chan  <adachan@apple.com>
1605
1606         Export KURL::baseAsString() so it can be called in WebProcessProxy::assumeReadAccessToBaseURL() in WebKit2.
1607         https://bugs.webkit.org/show_bug.cgi?id=70168
1608
1609         Reviewed by Alexey Proskuryakov.
1610
1611         No new tests. There is no change in functionality.
1612
1613         * WebCore.exp.in: Export KURL::baseAsString().
1614
1615 2011-10-17  Ryosuke Niwa  <rniwa@webkit.org>
1616
1617         Touch Internals.cpp to make 64-bit GTK+ build happy.
1618
1619         * testing/Internals.cpp:
1620
1621 2011-10-17  Chris Fleizach  <cfleizach@apple.com>
1622
1623         AX: children() method should be consolidated in AccessibilityObject
1624         https://bugs.webkit.org/show_bug.cgi?id=70243
1625
1626         Code cleanup, no new tests.
1627
1628         Reviewed by Darin Adler.
1629
1630         * accessibility/AccessibilityObject.cpp:
1631         (WebCore::AccessibilityObject::children):
1632         * accessibility/AccessibilityObject.h:
1633         * accessibility/AccessibilityRenderObject.cpp:
1634         (WebCore::AccessibilityRenderObject::updateChildrenIfNecessary):
1635         * accessibility/AccessibilityRenderObject.h:
1636         * accessibility/AccessibilityScrollView.cpp:
1637         (WebCore::AccessibilityScrollView::updateChildrenIfNecessary):
1638         (WebCore::AccessibilityScrollView::updateScrollbars):
1639         (WebCore::AccessibilityScrollView::addChildren):
1640         * accessibility/AccessibilityScrollView.h:
1641         * accessibility/AccessibilitySlider.cpp:
1642         * accessibility/AccessibilitySlider.h:
1643         * accessibility/AccessibilityTableColumn.cpp:
1644         * accessibility/AccessibilityTableColumn.h:
1645         * accessibility/AccessibilityTableHeaderContainer.cpp:
1646         * accessibility/AccessibilityTableHeaderContainer.h:
1647
1648 2011-10-17  Vsevolod Vlasov  <vsevik@chromium.org>
1649
1650         Web Inspector: Search matches highlighting in text does not work correctly.
1651         https://bugs.webkit.org/show_bug.cgi?id=70244
1652
1653         Reviewed by Pavel Feldman.
1654
1655         Test: inspector/utilities-highlight-results.html
1656
1657         * inspector/front-end/utilities.js:
1658         ():
1659
1660 2011-10-17  Chris Fleizach  <cfleizach@apple.com>
1661
1662         AX: webkit won't always send live region notifications
1663         https://bugs.webkit.org/show_bug.cgi?id=70030
1664
1665         Webkit purposefully does not send live region notifications if some AT client has not accessed the AX tree in between 
1666         the last live region update (ostensibly to improve performance).
1667         However, this is problematic if a screen reader misses one notification... it has no idea what happened and the only 
1668         recourse is to rescan the page for changes. The correct thing to do is to always send notifications.
1669
1670         Reviewed by Darin Adler.
1671
1672         Test: platform/mac/accessibility/aria-liveregions-notifications-always-sent.html
1673
1674         * accessibility/AccessibilityRenderObject.cpp:
1675         (WebCore::AccessibilityRenderObject::childrenChanged):
1676
1677 2011-10-12  Pavel Podivilov  <podivilov@chromium.org>
1678
1679         Web Inspector: fix handling of source mapping entries with no mapping.
1680         https://bugs.webkit.org/show_bug.cgi?id=69941
1681
1682         Reviewed by Pavel Feldman.
1683
1684         * inspector/front-end/CompilerSourceMapping.js:
1685         (WebInspector.ClosureCompilerSourceMapping.prototype._parseMappings):
1686
1687 2011-10-17  Mikhail Naganov  <mnaganov@chromium.org>
1688
1689         Web Inspector: [Chromium] Add an ability to look up and explore an object from a heap profile.
1690         https://bugs.webkit.org/show_bug.cgi?id=61179
1691
1692         This is exteremely helpful when dealing with DOM wrappers, as
1693         their properties are mostly implemented with getters and thus not
1694         stored in heap snapshots.
1695
1696         Reviewed by Pavel Feldman.
1697
1698         * English.lproj/localizedStrings.js:
1699         * bindings/js/ScriptProfiler.cpp:
1700         (WebCore::ScriptProfiler::objectByHeapObjectId):
1701         * bindings/js/ScriptProfiler.h:
1702         * bindings/v8/ScriptProfiler.cpp:
1703         (WebCore::ScriptProfiler::objectByHeapObjectId):
1704         * bindings/v8/ScriptProfiler.h:
1705         * inspector/Inspector.json:
1706         * inspector/InspectorController.cpp:
1707         (WebCore::InspectorController::InspectorController):
1708         * inspector/InspectorProfilerAgent.cpp:
1709         (WebCore::InspectorProfilerAgent::create):
1710         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
1711         (WebCore::InspectorProfilerAgent::getObjectByHeapObjectId):
1712         * inspector/InspectorProfilerAgent.h:
1713         * inspector/front-end/DetailedHeapshotGridNodes.js:
1714         (WebInspector.HeapSnapshotGridNode.prototype.hasHoverMessage.false.queryObjectContent):
1715         (WebInspector.HeapSnapshotGenericObjectNode):
1716         (WebInspector.HeapSnapshotGenericObjectNode.prototype.get data):
1717         (WebInspector.HeapSnapshotGenericObjectNode.prototype.queryObjectContent.else.formatResult):
1718         (WebInspector.HeapSnapshotGenericObjectNode.prototype.queryObjectContent):
1719         (WebInspector.HeapSnapshotGenericObjectNode.prototype.shortenWindowURL):
1720         * inspector/front-end/DetailedHeapshotView.js:
1721         (WebInspector.DetailedHeapshotView.prototype._showObjectPopover):
1722         * inspector/front-end/HeapSnapshot.js:
1723         (WebInspector.HeapSnapshotNode.prototype.get canBeQueried):
1724         (WebInspector.HeapSnapshotNode.prototype.get flags):
1725         (WebInspector.HeapSnapshotNode.prototype.get isDOMWindow):
1726         (WebInspector.HeapSnapshot.prototype._init):
1727         (WebInspector.HeapSnapshot.prototype.dispose):
1728         (WebInspector.HeapSnapshot.prototype._flagsOfNode):
1729         (WebInspector.HeapSnapshot.prototype._calculateFlags):
1730         (WebInspector.HeapSnapshot.prototype.updateStaticData):
1731         (WebInspector.HeapSnapshotNodesProvider.prototype._serialize):
1732         * inspector/front-end/HeapSnapshotProxy.js:
1733         (WebInspector.HeapSnapshotProxy.prototype.get nodeFlags):
1734         * inspector/front-end/RemoteObject.js:
1735         (WebInspector.RemoteObject.fromError):
1736         * inspector/front-end/heapProfiler.css:
1737         (.detailed-heapshot-view tr:not(.selected) td.object-column span.highlight):
1738
1739 2011-10-17  Alexander Pavlov  <apavlov@chromium.org>
1740
1741         Web Inspector: Editing CSS selector doesn't fire onResourceContentCommitted
1742         https://bugs.webkit.org/show_bug.cgi?id=70018
1743
1744         Reviewed by Yury Semikhatsky.
1745
1746         Test: inspector/styles/commit-selector.html
1747
1748         * inspector/front-end/CSSStyleModel.js:
1749         (WebInspector.CSSStyleModel.prototype.setRuleSelector.callback):
1750         (WebInspector.CSSStyleModel.prototype.setRuleSelector):
1751
1752 2011-10-17  Andreas Kling  <kling@webkit.org>
1753
1754         CSS/XSLStyleSheet: Remove insert() and remove().
1755         https://bugs.webkit.org/show_bug.cgi?id=70226
1756
1757         Reviewed by Antti Koivisto.
1758
1759         Remove insert() and remove() from XSLStyleSheet. CSSStyleSheet retains remove()
1760         since it's used by InspectorStyleSheet as well as SVGFontFaceElement.
1761
1762         * css/CSSStyleSheet.cpp:
1763         (WebCore::CSSStyleSheet::remove):
1764
1765             Remove range check. This method is internal to WebKit and the call sites
1766             already take care of it.
1767
1768         (WebCore::CSSStyleSheet::insertRule):
1769         (WebCore::CSSStyleSheet::deleteRule):
1770         * css/CSSStyleSheet.h:
1771         * xml/XSLStyleSheet.h:
1772
1773 2011-10-17  Rosen Dash  <rosen.dash@motorola.com>
1774
1775         when CSS pseudo selectors are applied (:before and :after) the *-of-line keyboard navigation does not work
1776         https://bugs.webkit.org/show_bug.cgi?id=10123
1777
1778         Reviewed by Ryosuke Niwa.
1779
1780         This patch addresses folllowing two issues:
1781         1. When CSS pseudo elements are before or after is used with content attribute containing single character
1782            at the start/end of text and we try to move cursor by right navigation key, the page freezes falling
1783            into an infinite loop.
1784         2. When these elements try to insert some text between a text line, navigation by right/left arrow key is prohibited.
1785
1786         Tests: editing/selection/css-pseudo-element-hang.html
1787                editing/selection/css-pseudo-element.html
1788
1789         * editing/VisiblePosition.cpp:
1790         (WebCore::VisiblePosition::leftVisuallyDistinctCandidate):
1791         (WebCore::VisiblePosition::rightVisuallyDistinctCandidate):
1792
1793 2011-10-15  Antti Koivisto  <antti@apple.com>
1794
1795         Test :visited pseudo class
1796         https://bugs.webkit.org/show_bug.cgi?id=70219
1797
1798         Reviewed by Andreas Kling.
1799         
1800         Currently DRT doesn't support :visited. All tests where it should match have wrong checked in results.
1801         
1802         - Make <a href=""> to match :visited in DRT. It already does on browsers. A number of existing tests 
1803           for :visited use it already, the rest can be modified to use it.
1804         - Make render tree dumps correctly dump the visited state dependent color.
1805
1806         * css/SelectorChecker.cpp:
1807         (WebCore::SelectorChecker::determineLinkStateSlowCase):
1808         * rendering/RenderTreeAsText.cpp:
1809         (WebCore::RenderTreeAsText::writeRenderObject):
1810
1811 2011-10-17  Satish Sampath  <satish@chromium.org>
1812
1813         Avoid leaking document when leaving google.com due to geolocation
1814         permission request.
1815         https://bugs.webkit.org/show_bug.cgi?id=58027
1816
1817         Reviewed by Kenneth Rohde Christiansen.
1818
1819         * page/Geolocation.cpp:
1820         (WebCore::Geolocation::Watchers::find): added
1821         (WebCore::Geolocation::reset): cleared all pending notifiers.
1822         (WebCore::Geolocation::clearWatch): removed from pending notifier set.
1823         * page/Geolocation.h:
1824         (WebCore::Geolocation::Watchers::find): added
1825
1826 2011-10-17  Andrei Lavreniyuk  <andy.lavr@gmail.com>
1827
1828         Fix clang WebKitGTK+ build.
1829
1830         Reviewed by Martin Robinson.
1831
1832         * plugins/gtk/PluginViewGtk.cpp:
1833
1834 2011-10-16  Adam Barth  <abarth@webkit.org>
1835
1836         Always disable ENABLE(ON_FIRST_TEXTAREA_FOCUS_SELECT_ALL) and delete associated code
1837         https://bugs.webkit.org/show_bug.cgi?id=70216
1838
1839         Reviewed by Eric Seidel.
1840
1841         No port enables this feature.  It was added for the previous Android
1842         port (and should have been an editing behavior in any case).
1843
1844         * html/HTMLTextAreaElement.cpp:
1845         (WebCore::HTMLTextAreaElement::updateFocusAppearance):
1846
1847 2011-10-16  Ryosuke Niwa  <rniwa@webkit.org>
1848
1849         Expose rangeFromLocationAndLength and locationAndLengthFromRange via internals object
1850         https://bugs.webkit.org/show_bug.cgi?id=68330
1851
1852         Reviewed by Hajime Morita.
1853
1854         Add rangeFromLocationAndLength, locationFromRange, and lengthFromRange to window.internals.
1855
1856         Test: editing/text-iterator/range-to-from-location-and-length.html
1857
1858         * WebCore.exp.in:
1859         * testing/Internals.cpp:
1860         (WebCore::Internals::scrollElementToRect):
1861         (WebCore::Internals::rangeFromLocationAndLength):
1862         (WebCore::Internals::locationFromRange):
1863         (WebCore::Internals::lengthFromRange):
1864         * testing/Internals.h:
1865         * testing/Internals.idl:
1866
1867 2011-10-16  Kentaro Hara  <haraken@chromium.org>
1868
1869         Generate MessageChannel constructor by [Constructor] IDL
1870         https://bugs.webkit.org/show_bug.cgi?id=70214
1871
1872         Reviewed by Adam Barth.
1873
1874         This patch generates an MessageChannel constructor for JSC by [Constructor] IDL,
1875         but V8 is still using a custom constructor since the V8 constructor requires special logic.
1876
1877         Tests: fast/dom/global-constructors.html
1878                fast/events/message-port.html
1879                fast/events/message-port-no-wrapper.html
1880                fast/dom/Window/window-postmessage-args.html
1881
1882         * bindings/js/JSMessageChannelCustom.cpp: Removed the MessageChannel constructor.
1883         * dom/MessageChannel.idl: Generates the MessageChannel constructor for JSC.
1884
1885 2011-10-16  Ryosuke Niwa  <rniwa@webkit.org>
1886
1887         [Mac] fontForSelection and styleForSelectionStart should be moved to EditorMac
1888         https://bugs.webkit.org/show_bug.cgi?id=70114
1889
1890         Reviewed by Hajime Morita.
1891
1892         Moved fontForSelection and styleForSelectionStart from Editor to EditorMac
1893         and made styleForSelectionStart static local.
1894
1895         * editing/Editor.cpp:
1896         * editing/Editor.h:
1897         * editing/mac/EditorMac.mm:
1898         (WebCore::styleForSelectionStart):
1899         (WebCore::Editor::fontForSelection):
1900         (WebCore::Editor::fontAttributesForSelectionStart):
1901
1902 2011-10-16  Kentaro Hara  <haraken@chromium.org>
1903
1904         Generate EventSource constructor for JSC by [Constructor] IDL
1905         https://bugs.webkit.org/show_bug.cgi?id=70212
1906
1907         Reviewed by Adam Barth.
1908
1909         Removed JSEventSourceCustom.cpp.
1910
1911         Tests: fast/dom/global-constructors.html
1912                fast/eventsource/eventsource-constructor.html
1913                fast/eventsource/eventsource-attribute-listeners.html
1914
1915         * GNUmakefile.list.am: Removed JSEventSourceCustom.cpp.
1916         * UseJSC.cmake: Ditto.
1917         * WebCore.gypi: Ditto.
1918         * WebCore.pro: Ditto.
1919         * WebCore.xcodeproj/project.pbxproj: Ditto.
1920         * bindings/js/JSBindingsAllInOne.cpp: Ditto.
1921         * bindings/js/JSEventSourceCustom.cpp: Removed this file.
1922         * page/EventSource.idl: Removed 'JSCustomConstructor' IDL.
1923
1924 2011-10-16  David Barr  <davidbarr@chromium.org>
1925
1926         Inline CSSPrimitiveValue::isQuirkValue() as non-virtual function
1927         https://bugs.webkit.org/show_bug.cgi?id=64865
1928
1929         Reviewed by Darin Adler.
1930
1931         Based on profiling and patch from:
1932         Tamas Czene <Czene.Tamas@stud.u-szeged.hu>
1933
1934         This is expected to produce a small performance progression.
1935         Additional memory overhead is avoided by using spare bits.
1936         CSSQuirkPrimitiveValue is removed as it becomes just a factory.
1937
1938         * GNUmakefile.list.am:
1939         * WebCore.gypi:
1940         * WebCore.order:
1941         * WebCore.vcproj/WebCore.vcproj:
1942         * WebCore.xcodeproj/project.pbxproj:
1943         * css/CSSParser.cpp:
1944         (WebCore::CSSParser::parseValidPrimitive):
1945         * css/CSSParserValues.cpp:
1946         (WebCore::CSSParserValue::createCSSValue):
1947         * css/CSSPrimitiveValue.cpp:
1948         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1949         * css/CSSPrimitiveValue.h:
1950         (WebCore::CSSPrimitiveValue::createAllowingMarginQuirk):
1951         Moved from CSSQuirkPrimitiveValue::create.
1952         (WebCore::CSSPrimitiveValue::isQuirkValue):
1953         * css/CSSQuirkPrimitiveValue.h: Removed.
1954         * css/SVGCSSParser.cpp:
1955         (WebCore::CSSParser::parseSVGValue):
1956
1957 2011-10-16  Kentaro Hara  <haraken@chromium.org>
1958
1959         Generate XMLHttpRequest constructor for JSC by [Constructor] IDL
1960         https://bugs.webkit.org/show_bug.cgi?id=70208
1961
1962         Reviewed by Adam Barth.
1963
1964         This patch generates an XMLHttpRequest constructor for JSC by [Constructor] IDL,
1965         but V8 is still using a custom constructor since the V8 constructor requires a special logic.
1966
1967         Tests: fast/dom/global-constructors.html
1968                fast/dom/XMLHttpRequest-constants.html
1969                fast/dom/xmlhttprequest-constructor-in-detached-document.html
1970                http/tests/security/cookies/xmlhttprequest.html
1971
1972         * bindings/js/JSXMLHttpRequestCustom.cpp: Removed an XMLHttpRequest custom constructor.
1973         * bindings/scripts/CodeGeneratorV8.pm: Currently, CodeGeneratorV8.pm generates constructor code whenever [Constructor] is specified, even if [V8CustomConstructor] is specified. This is wrong. This patch fixes the condition where the constructor code is generated.
1974         * bindings/scripts/test/V8/V8TestObj.cpp: Updated a run-binding-tests result.
1975         * xml/XMLHttpRequest.h: Added a necessary header.
1976         * xml/XMLHttpRequest.idl: V8 is still using a custom constructor.
1977
1978 2011-10-16  Kentaro Hara  <haraken@chromium.org>
1979
1980         Generate XSLTProcessor constructor for JSC by [Constructor] IDL.
1981         https://bugs.webkit.org/show_bug.cgi?id=70206
1982
1983         Reviewed by Adam Barth.
1984
1985         Tests: fast/xsl/xslt-processor.html
1986                fast/xsl/default-html.html
1987                fast/dom/global-constructors.html
1988
1989         * bindings/js/JSXSLTProcessorCustom.cpp: Removed a custom constructor.
1990         * xml/XSLTProcessor.idl: Removed 'JSCustomConstructor'.
1991
1992 2011-10-16  Kentaro Hara  <haraken@chromium.org>
1993
1994         Support [Constructor] IDL for JSC.
1995         https://bugs.webkit.org/show_bug.cgi?id=70101
1996
1997         Reviewed by Adam Barth.
1998
1999         The spec for [Constructor] IDL is here: http://www.w3.org/TR/WebIDL/#Constructor
2000         This patch introduced [Constructor] IDL for JSC. This patch also added
2001         [ConstructorRaisesException] for JSC. If [ConstructorRaisesException] is specified,
2002         a placeholder for ExceptionCode is passed to XXX::create(), like XXX::create(..., ec).
2003
2004         Notes:
2005         - We do not yet support constructor overloading.
2006         - We do not yet support [Optional] without CallWithDefaultValue for constructor arguments.
2007
2008         Tests: Source/WebCore/bindings/scripts/test/TestInterface.idl
2009                Source/WebCore/bindings/scripts/test/TestObj.idl
2010
2011         * bindings/scripts/CodeGeneratorJS.pm:
2012         (GenerateHeader): Generates constructor declaration code to a header file, if a given DOM object has constructor.
2013         (GenerateImplementation): Uses GenerateArgumentsCountCheck() and GenerateParametersCheck().
2014         (GenerateArgumentsCountCheck): Splits out of GenerateImplementation() for reuse.
2015         (GenerateParametersCheck): Splits out of GenerateImplementation() for reuse.
2016         (GenerateConstructorDefinition): Generates constructor definition code.
2017         * bindings/scripts/test/JS/JSTestInterface.cpp: Updated the run-binding-tests results.
2018         (WebCore::JSTestInterfaceConstructor::constructJSTestInterface):
2019         * bindings/scripts/test/JS/JSTestInterface.h: Ditto.
2020         (WebCore::JSTestInterfaceConstructor::create):
2021         (WebCore::JSTestInterfaceConstructor::createStructure):
2022         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp: Ditto.
2023         (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
2024         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h: Ditto.
2025         (WebCore::JSTestMediaQueryListListenerConstructor::create):
2026         (WebCore::JSTestMediaQueryListListenerConstructor::createStructure):
2027         * bindings/scripts/test/JS/JSTestObj.cpp: Ditto.
2028         (WebCore::jsTestObjPrototypeFunctionVoidMethod):
2029         (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
2030         (WebCore::jsTestObjPrototypeFunctionIntMethod):
2031         (WebCore::jsTestObjPrototypeFunctionIntMethodWithArgs):
2032         (WebCore::jsTestObjPrototypeFunctionObjMethod):
2033         (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
2034         (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgs):
2035         (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
2036         (WebCore::jsTestObjPrototypeFunctionSerializedValue):
2037         (WebCore::jsTestObjPrototypeFunctionIdbKey):
2038         (WebCore::jsTestObjPrototypeFunctionOptionsObject):
2039         (WebCore::jsTestObjPrototypeFunctionMethodWithException):
2040         (WebCore::jsTestObjPrototypeFunctionCustomArgsAndException):
2041         (WebCore::jsTestObjPrototypeFunctionAddEventListener):
2042         (WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
2043         (WebCore::jsTestObjPrototypeFunctionWithDynamicFrame):
2044         (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndArg):
2045         (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndOptionalArg):
2046         (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndUserGesture):
2047         (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndUserGestureASAD):
2048         (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoid):
2049         (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
2050         (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoidException):
2051         (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
2052         (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContext):
2053         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
2054         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
2055         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
2056         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
2057         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
2058         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
2059         (WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
2060         (WebCore::jsTestObjPrototypeFunctionConditionalMethod2):
2061         (WebCore::jsTestObjPrototypeFunctionConditionalMethod3):
2062         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
2063         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
2064         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
2065         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
2066         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
2067         (WebCore::jsTestObjPrototypeFunctionClassMethod):
2068         (WebCore::jsTestObjPrototypeFunctionClassMethodWithOptional):
2069         * bindings/scripts/test/JS/JSTestObj.h: Ditto.
2070         (WebCore::JSTestObjConstructor::create):
2071         (WebCore::JSTestObjConstructor::createStructure):
2072         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp: Ditto.
2073         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h: Ditto.
2074         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::create):
2075         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::createStructure):
2076
2077 2011-10-16  Dmitry Lomov  <dslomov@google.com>
2078
2079         https://bugs.webkit.org/show_bug.cgi?id=70186
2080         Pass MessagePortArray to JSC's SerializedScriptValue::serialize/deserialize.
2081
2082         Reviewed by Oliver Hunt.
2083
2084         * bindings/js/JSDOMWindowCustom.cpp:
2085         (WebCore::handlePostMessage):
2086         (WebCore::JSDOMWindow::postMessage):
2087         (WebCore::JSDOMWindow::webkitPostMessage):
2088         * bindings/js/JSDictionary.cpp:
2089         (WebCore::JSDictionary::convertValue):
2090         * bindings/js/JSHistoryCustom.cpp:
2091         (WebCore::JSHistory::pushState):
2092         (WebCore::JSHistory::replaceState):
2093         * bindings/js/JSMessageEventCustom.cpp:
2094         (WebCore::JSMessageEvent::data):
2095         (WebCore::handleInitMessageEvent):
2096         (WebCore::JSMessageEvent::initMessageEvent):
2097         (WebCore::JSMessageEvent::webkitInitMessageEvent):
2098         * bindings/js/JSMessagePortCustom.h:
2099         (WebCore::handlePostMessage):
2100         * bindings/js/JSPopStateEventCustom.cpp:
2101         (WebCore::JSPopStateEvent::state):
2102         * bindings/js/ScriptValue.cpp:
2103         (WebCore::ScriptValue::serialize):
2104         (WebCore::ScriptValue::deserialize):
2105         * bindings/js/SerializedScriptValue.cpp:
2106         (WebCore::SerializedScriptValue::create):
2107         (WebCore::SerializedScriptValue::deserialize):
2108         * bindings/js/SerializedScriptValue.h:
2109
2110 2011-10-16  Dan Bernstein  <mitz@apple.com>
2111
2112         REGRESSION (r96620): Float-avoiding block positioned incorrectly in right-to-left block
2113         https://bugs.webkit.org/show_bug.cgi?id=70197
2114
2115         Reviewed by Dave Kilzer.
2116
2117         Test: fast/block/float/avoidance-rtl.html
2118
2119         * rendering/RenderBlock.cpp:
2120         (WebCore::RenderBlock::computeStartPositionDeltaForChildAvoidingFloats): Changed
2121         logicalLeftOffsetForContent() to startOffsetForContent() to get the right value in the
2122         right-to-left case.
2123
2124 2011-10-16  Adam Barth  <abarth@webkit.org>
2125
2126         Always enable ENABLE(DOM_STORAGE)
2127         https://bugs.webkit.org/show_bug.cgi?id=70189
2128
2129         Reviewed by Eric Seidel.
2130
2131         As discussed on webkit-dev, we are reducing the complexity of WebKit by
2132         removing unnecessary configuration options.  DOMStorage is not a core
2133         part of the web platform.  It should always be enabled.
2134
2135         * CMakeLists.txt:
2136         * Configurations/FeatureDefines.xcconfig:
2137         * GNUmakefile.am:
2138         * GNUmakefile.list.am:
2139         * UseJSC.cmake:
2140         * WebCore.exp.in:
2141         * WebCore.pro:
2142         * bindings/js/JSEventCustom.cpp:
2143         * bindings/js/JSInjectedScriptHostCustom.cpp:
2144         * bindings/js/JSStorageCustom.cpp:
2145         * bindings/v8/custom/V8EventCustom.cpp:
2146         (WebCore::toV8):
2147         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
2148         (WebCore::V8InjectedScriptHost::storageIdCallback):
2149         * bindings/v8/custom/V8StorageCustom.cpp:
2150         * dom/Document.cpp:
2151         (WebCore::Document::createEvent):
2152         * dom/Event.cpp:
2153         (WebCore::Event::isStorageEvent):
2154         * dom/Event.h:
2155         * dom/Node.cpp:
2156         * features.pri:
2157         * inspector/InjectedScriptHost.cpp:
2158         (WebCore::InjectedScriptHost::InjectedScriptHost):
2159         (WebCore::InjectedScriptHost::disconnect):
2160         (WebCore::InjectedScriptHost::storageIdImpl):
2161         * inspector/InjectedScriptHost.h:
2162         (WebCore::InjectedScriptHost::init):
2163         * inspector/InspectorController.cpp:
2164         (WebCore::InspectorController::InspectorController):
2165         (WebCore::InspectorController::connectFrontend):
2166         (WebCore::InspectorController::disconnectFrontend):
2167         (WebCore::InspectorController::restoreInspectorStateFromCookie):
2168         * inspector/InspectorController.h:
2169         * inspector/InspectorDOMStorageAgent.cpp:
2170         * inspector/InspectorDOMStorageResource.cpp:
2171         * inspector/InspectorDOMStorageResource.h:
2172         * inspector/InspectorInstrumentation.cpp:
2173         (WebCore::InspectorInstrumentation::didCommitLoadImpl):
2174         (WebCore::InspectorInstrumentation::didUseDOMStorageImpl):
2175         * inspector/InspectorInstrumentation.h:
2176         (WebCore::InspectorInstrumentation::didUseDOMStorage):
2177         * inspector/InstrumentingAgents.h:
2178         (WebCore::InstrumentingAgents::InstrumentingAgents):
2179         * inspector/WorkerInspectorController.cpp:
2180         (WebCore::WorkerInspectorController::WorkerInspectorController):
2181         (WebCore::WorkerInspectorController::connectFrontend):
2182         * inspector/generate-inspector-idl:
2183         * page/Chrome.cpp:
2184         * page/DOMWindow.cpp:
2185         (WebCore::DOMWindow::~DOMWindow):
2186         (WebCore::DOMWindow::clear):
2187         (WebCore::DOMWindow::localStorage):
2188         * page/DOMWindow.h:
2189         * page/DOMWindow.idl:
2190         * page/Navigator.cpp:
2191         (WebCore::Navigator::getStorageUpdates):
2192         * page/Navigator.h:
2193         * page/Navigator.idl:
2194         * page/Page.cpp:
2195         * page/Page.h:
2196         * page/PageGroup.cpp:
2197         (WebCore::PageGroup::closeLocalStorage):
2198         * page/PageGroup.h:
2199         * page/Settings.cpp:
2200         (WebCore::Settings::Settings):
2201         (WebCore::Settings::setSessionStorageQuota):
2202         * page/Settings.h:
2203         (WebCore::Settings::sessionStorageQuota):
2204         * storage/LocalStorageTask.cpp:
2205         * storage/LocalStorageTask.h:
2206         * storage/LocalStorageThread.cpp:
2207         * storage/LocalStorageThread.h:
2208         * storage/Storage.cpp:
2209         * storage/Storage.h:
2210         * storage/Storage.idl:
2211         * storage/StorageArea.h:
2212         * storage/StorageAreaImpl.cpp:
2213         * storage/StorageAreaImpl.h:
2214         * storage/StorageAreaSync.cpp:
2215         (WebCore::StorageAreaSync::scheduleSync):
2216         * storage/StorageAreaSync.h:
2217         * storage/StorageEvent.cpp:
2218         * storage/StorageEvent.h:
2219         * storage/StorageEvent.idl:
2220         * storage/StorageEventDispatcher.cpp:
2221         * storage/StorageEventDispatcher.h:
2222         * storage/StorageMap.cpp:
2223         * storage/StorageMap.h:
2224         * storage/StorageNamespace.cpp:
2225         * storage/StorageNamespace.h:
2226         * storage/StorageNamespaceImpl.cpp:
2227         * storage/StorageNamespaceImpl.h:
2228         * storage/StorageSyncManager.cpp:
2229         (WebCore::StorageSyncManager::scheduleDeleteEmptyDatabase):
2230         * storage/StorageSyncManager.h:
2231         * storage/StorageTracker.cpp:
2232         * storage/StorageTracker.h:
2233
2234 2011-10-15  Adam Barth  <abarth@webkit.org>
2235
2236         Rename ENABLE(SKIA_TEXT) to USE(SKIA_TEXT)
2237         https://bugs.webkit.org/show_bug.cgi?id=70191
2238
2239         Reviewed by Daniel Bates.
2240
2241         SKIA_TEXT is not a WebKit feature.  It's a macro that determines
2242         whether we use a feature of the underly library (Skia).
2243
2244         * platform/graphics/chromium/FontChromiumWin.cpp:
2245         (WebCore::Font::drawComplexText):
2246         * platform/graphics/chromium/UniscribeHelper.cpp:
2247         (WebCore::UniscribeHelper::draw):
2248         * platform/graphics/skia/PlatformContextSkia.cpp:
2249         (WebCore::PlatformContextSkia::isNativeFontRenderingAllowed):
2250         * platform/graphics/skia/PlatformContextSkia.h:
2251         * platform/graphics/skia/SkiaFontWin.cpp:
2252         * platform/graphics/skia/SkiaFontWin.h:
2253
2254 2011-10-15  Eric Carlson  <eric.carlson@apple.com>
2255
2256         Make VIDEO_TRACK compile with warnings as errors enabled
2257         https://bugs.webkit.org/show_bug.cgi?id=70188
2258
2259         Reviewed by Filip Pizlo.
2260
2261         No new tests, no functionality changed.
2262
2263         * html/TextTrackCueList.h: Fix an include.
2264         * html/track/CueParser.cpp:
2265         (WebCore::CueParser::supportsType): Remove unused param.
2266         * html/track/CueParser.h:
2267         (WebCore::CueParserClient::~CueParserClient): Add virtual destructor.
2268         * html/track/CueParserPrivate.h:
2269         (WebCore::CueParserPrivateClient::~CueParserPrivateClient): Ditto.
2270         * loader/CueLoader.h:
2271         (WebCore::CueLoaderClient::~CueLoaderClient): Ditto.
2272         (WebCore::CueLoader::~CueLoader): Ditto.
2273
2274 2011-10-15  Adam Barth  <abarth@webkit.org>
2275
2276         Rename ENABLE(TILED_BACKING_STORE) to USE(TILED_BACKING_STORE)
2277         https://bugs.webkit.org/show_bug.cgi?id=70194
2278
2279         Reviewed by Daniel Bates.
2280
2281         TILED_BACKING_STORE isn't a web platform feature.  It's an
2282         implementation strategy for WebKit that's used by some ports
2283         and not by others.
2284
2285         * features.pri:
2286         * loader/EmptyClients.h:
2287         * page/Chrome.cpp:
2288         * page/Chrome.h:
2289         * page/ChromeClient.h:
2290         * page/Frame.cpp:
2291         (WebCore::Frame::Frame):
2292         (WebCore::Frame::setView):
2293         * page/Frame.h:
2294         * page/FrameView.cpp:
2295         (WebCore::FrameView::repaintContentRectangle):
2296         (WebCore::FrameView::doDeferredRepaints):
2297         * page/Settings.cpp:
2298         (WebCore::Settings::setTiledBackingStoreEnabled):
2299         * platform/HostWindow.h:
2300         * platform/ScrollView.cpp:
2301         (WebCore::ScrollView::setScrollPosition):
2302         * platform/graphics/Tile.h:
2303         * platform/graphics/TiledBackingStore.cpp:
2304         * platform/graphics/TiledBackingStore.h:
2305         * platform/graphics/TiledBackingStoreBackend.h:
2306         * platform/graphics/TiledBackingStoreClient.h:
2307         * platform/graphics/qt/GraphicsLayerQt.cpp:
2308         (WebCore::GraphicsLayerQtImpl::GraphicsLayerQtImpl):
2309         (WebCore::GraphicsLayerQtImpl::~GraphicsLayerQtImpl):
2310         (WebCore::GraphicsLayerQtImpl::recache):
2311         (WebCore::GraphicsLayerQtImpl::paint):
2312         * platform/graphics/qt/TileQt.cpp:
2313         * platform/graphics/qt/TileQt.h:
2314         * platform/graphics/texmap/TextureMapperNode.cpp:
2315         (WebCore::TextureMapperNode::computeTiles):
2316         (WebCore::TextureMapperNode::renderContent):
2317         (WebCore::TextureMapperNode::paintSelf):
2318         (WebCore::TextureMapperNode::syncCompositingStateSelf):
2319         * platform/graphics/texmap/TextureMapperNode.h:
2320         (WebCore::TextureMapperNode::State::State):
2321
2322 2011-10-15  Adam Barth  <abarth@webkit.org>
2323
2324         Remove the last remnant of WBXML
2325         https://bugs.webkit.org/show_bug.cgi?id=70187
2326
2327         Reviewed by Daniel Bates.
2328
2329         The bulk of the WBXML code was removed in 2009, but we missed one block.
2330
2331         * platform/wince/MIMETypeRegistryWinCE.cpp:
2332         (WebCore::initMIMETypeEntensionMap):
2333
2334 2011-10-15  Darin Adler  <darin@apple.com>
2335
2336         REGRESSION(r97533): fast/forms/select-script-onchange.html failed after
2337         https://bugs.webkit.org/show_bug.cgi?id=70173
2338
2339         Reviewed by Ryosuke Niwa.
2340
2341         * html/HTMLSelectElement.cpp:
2342         (WebCore::HTMLSelectElement::setValue): Removed unneeded boolean argument
2343         [true for deselect].
2344         (WebCore::HTMLSelectElement::menuListDefaultEventHandler): Added explicit
2345         boolean arguments for all calls to setSelectedIndex to restore pre-r97533
2346         behavior.
2347         (WebCore::HTMLSelectElement::typeAheadFind): Ditto.
2348         (WebCore::HTMLSelectElement::accessKeySetSelectedIndex): Ditto.
2349
2350         * html/HTMLSelectElement.h:
2351         Removed default of true for userDrivenChange. Each caller should pass it
2352         explicitly. Longer term we should use an enum instead of a boolean or find
2353         some other way of avoiding the argument.
2354         (WebCore::HTMLSelectElement::setSelectedIndex):
2355         Pass false for userDrivenChange as the old code did pre-r97533.
2356
2357 2011-10-15  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
2358
2359         [Qt] [Symbian] Remove support for the Symbian platform for the QtWebKit port
2360         https://bugs.webkit.org/show_bug.cgi?id=69920
2361
2362         Reviewed by Kenneth Rohde Christiansen.
2363
2364         No new tests as there is no new functionality.
2365
2366         * WebCore.gypi:
2367         * WebCore.pri:
2368         * WebCore.pro:
2369         * bindings/v8/V8GCController.cpp:
2370         (WebCore::V8GCController::checkMemoryUsage):
2371         * config.h:
2372         * css/CSSPrimitiveValueMappings.h:
2373         (WebCore::CSSPrimitiveValue::operator int):
2374         * features.pri:
2375         * page/NavigatorBase.cpp:
2376         * platform/graphics/qt/GraphicsContextQt.cpp:
2377         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
2378         * platform/network/qt/ResourceRequestQt.cpp:
2379         (WebCore::initializeMaximumHTTPConnectionCountPerHost):
2380         * platform/text/qt/TextCodecQt.cpp:
2381         (WebCore::TextCodecQt::decode):
2382         * plugins/PluginDatabase.cpp:
2383         * plugins/PluginPackage.cpp:
2384         (WebCore::PluginPackage::unload):
2385         * plugins/PluginPackage.h:
2386         (WebCore::PluginPackage::version):
2387         * plugins/PluginView.cpp:
2388         (WebCore::PluginView::setFrameRect):
2389         * plugins/PluginView.h:
2390         * plugins/npapi.h:
2391         * plugins/symbian: Removed.
2392         * plugins/symbian/PluginContainerSymbian.cpp: Removed.
2393         * plugins/symbian/PluginContainerSymbian.h: Removed.
2394         * plugins/symbian/PluginDatabaseSymbian.cpp: Removed.
2395         * plugins/symbian/PluginPackageSymbian.cpp: Removed.
2396         * plugins/symbian/PluginViewSymbian.cpp: Removed.
2397         * plugins/symbian/npinterface.h: Removed.
2398
2399 2011-10-08  Robert Hogan  <robert@webkit.org>
2400
2401         CSS 2.1 failure: height-width-table-001.htm
2402         https://bugs.webkit.org/show_bug.cgi?id=69709
2403
2404         Reviewed by Simon Fraser.
2405
2406         CSS 2.1 expects CSS table elements to treat fixed height/width as
2407         excluding table borders, but HTML table elements to treat fixed height/width as
2408         including them.
2409         
2410         See http://lists.w3.org/Archives/Public/www-style/2011Jan/0178.html
2411             http://lists.w3.org/Archives/Public/public-css-testsuite/2011Oct/0005.html
2412             
2413         It looks like some clarification is pending in the specs, but the new behaviour
2414         lets WebKit pass the following tests in the suite CSS and also match FF:
2415           height-width-table-001.htm
2416           height-width-inline-table-001.htm
2417           abspos-containing-block-initial-004d.htm
2418
2419         * rendering/RenderTable.cpp:
2420         (WebCore::RenderTable::computeLogicalWidth):
2421         (WebCore::RenderTable::layout):
2422
2423 2011-10-15  Darin Adler  <darin@apple.com>
2424
2425         Make toHTMLElement fail to compile if you try to use it on an HTMLElement*
2426         https://bugs.webkit.org/show_bug.cgi?id=70164
2427
2428         Reviewed by Adam Barth.
2429
2430         Refactoring covered by existing tests.
2431
2432         * bindings/js/JSHTMLFrameSetElementCustom.cpp:
2433         (WebCore::JSHTMLFrameSetElement::nameGetter): Removed unneeded casts and
2434         some unneeded local variables as well. Changed the name of the local variable
2435         for the HTMLFrameElement to frameElement to avoid confusion with the Frame.
2436         * dom/Document.cpp:
2437         (WebCore::Document::openSearchDescriptionURL): Removed unneeded HTMLElement
2438         check; we can call hasTagName directly on a Node and that takes care of
2439         checking both that it's an HTMLElement and checking the tag name.
2440         * dom/MicroDataItemList.cpp:
2441         (WebCore::MicroDataItemList::nodeMatches): Use toHTMLElement instead of
2442         a cast. Also changed hasAttribute calls to fastHasAttribute and getAttribute
2443         calls to fastGetAttribute since these are neither style attributes nor SVG
2444         animatables.
2445         * editing/ApplyStyleCommand.cpp:
2446         (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown): Use toHTMLElement.
2447         (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded): Ditto.
2448         * editing/DeleteButtonController.cpp:
2449         (WebCore::DeleteButtonController::show): Removed unneeded toHTMLElement call.
2450         * html/HTMLElement.cpp:
2451         (WebCore::HTMLElement::setOuterHTML): Use toHTMLElement.
2452         * html/HTMLElement.h: Added toHTMLElement overload to catch calls when the
2453         pointer is already HTMLElement* or a pointer to a class derived from it.
2454         * html/HTMLSelectElement.cpp:
2455         (WebCore::HTMLSelectElement::recalcListItems): Use toHTMLElement.
2456         * html/HTMLTextAreaElement.cpp:
2457         (WebCore::HTMLTextAreaElement::innerTextElement): Use toHTMLElement.
2458
2459 2011-10-15  Antoine Labour  <piman@chromium.org>
2460
2461         Add WebAcceleratedContentLayer backed by a texture to support accelerated content hosting
2462         https://bugs.webkit.org/show_bug.cgi?id=70084
2463
2464         Reviewed by James Robinson.
2465
2466         Covered by existing compositing/ tests
2467
2468         * platform/graphics/chromium/LayerChromium.h:
2469         * platform/graphics/chromium/LayerRendererChromium.cpp:
2470         (WebCore::LayerRendererChromium::pluginLayerProgramFlip):
2471         (WebCore::LayerRendererChromium::cleanupSharedObjects):
2472         * platform/graphics/chromium/LayerRendererChromium.h:
2473         * platform/graphics/chromium/PluginLayerChromium.cpp:
2474         (WebCore::PluginLayerChromium::PluginLayerChromium):
2475         (WebCore::PluginLayerChromium::setTextureId):
2476         (WebCore::PluginLayerChromium::setFlipped):
2477         (WebCore::PluginLayerChromium::pushPropertiesTo):
2478         * platform/graphics/chromium/PluginLayerChromium.h:
2479         (WebCore::PluginLayerChromium::flipped):
2480         * platform/graphics/chromium/cc/CCPluginLayerImpl.cpp:
2481         (WebCore::CCPluginLayerImpl::CCPluginLayerImpl):
2482         (WebCore::CCPluginLayerImpl::draw):
2483         * platform/graphics/chromium/cc/CCPluginLayerImpl.h:
2484         (WebCore::CCPluginLayerImpl::setFlipped):
2485
2486 2011-10-15  Michael Nordman  <michaeln@google.com>
2487
2488         [Chromium] Some WebSQLDatabase in worker bug fixes.
2489         https://bugs.webkit.org/show_bug.cgi?id=70071
2490
2491         - Test for a NULL webView WebWorkerClientImpl.
2492         - Avoid altering Database instance lifetimes during WorkerThread::stop().
2493
2494         Existing tests coverage applies.
2495
2496         Reviewed by David Levin.
2497
2498         * storage/chromium/DatabaseTrackerChromium.cpp:
2499         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
2500
2501 2011-10-14  Adam Barth  <abarth@webkit.org>
2502
2503         Update expected results.
2504
2505         * bindings/scripts/test/V8/V8TestObj.cpp:
2506         (WebCore::TestObjInternal::serializedValueCallback):
2507
2508 2011-10-14  Ryosuke Niwa  <rniwa@webkit.org>
2509
2510         GTK build fix after r97533.
2511
2512         * accessibility/gtk/AXObjectCacheAtk.cpp:
2513         (WebCore::notifyChildrenSelectionChange):
2514         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
2515         (optionFromSelection):
2516         (webkit_accessible_selection_get_selection_count):
2517
2518 2011-10-14  David Kilzer  <ddkilzer@apple.com>
2519
2520         <http://webkit.org/b/70158> Fix clang compiler warnings
2521
2522         Reviewed by Darin Adler.
2523
2524         * dom/ViewportArguments.cpp:
2525         (WebCore::computeViewportAttributes): Use std::max<float>()
2526         instead of std::max().
2527
2528 2011-10-14  Mark Hahnenberg  <mhahnenberg@apple.com>
2529
2530         Rename getOwnPropertySlot to getOwnPropertySlotVirtual
2531         https://bugs.webkit.org/show_bug.cgi?id=69810
2532
2533         Reviewed by Geoffrey Garen.
2534
2535         No new tests.
2536
2537         Renamed the virtual version of getOwnPropertySlot to getOwnPropertySlotVirtual
2538         in preparation for when we add the static getOwnPropertySlot to the MethodTable 
2539         in ClassInfo.
2540
2541         Also added a few static getOwnPropertySlot functions where they had been overlooked 
2542         before (especially in CodeGeneratorJS.pm).
2543
2544         * WebCore.exp.in:
2545         * bindings/js/JSDOMWindowCustom.cpp:
2546         (WebCore::JSDOMWindow::getOwnPropertySlotVirtual):
2547         (WebCore::JSDOMWindow::getOwnPropertySlot):
2548         (WebCore::DialogHandler::returnValue):
2549         * bindings/js/JSDOMWindowShell.cpp:
2550         (WebCore::JSDOMWindowShell::getOwnPropertySlotVirtual):
2551         (WebCore::JSDOMWindowShell::getOwnPropertySlot):
2552         * bindings/js/JSDOMWindowShell.h:
2553         * bindings/js/JSWorkerContextCustom.cpp:
2554         (WebCore::JSWorkerContext::getOwnPropertySlotDelegate):
2555         * bindings/js/SerializedScriptValue.cpp:
2556         (WebCore::CloneSerializer::getSparseIndex):
2557         (WebCore::CloneSerializer::getProperty):
2558         * bindings/scripts/CodeGeneratorJS.pm:
2559         (GenerateGetOwnPropertySlotBody):
2560         (GenerateHeader):
2561         (GenerateImplementation):
2562         (GenerateConstructorDeclaration):
2563         (GenerateConstructorDefinition):
2564         * bindings/scripts/test/JS/JSTestInterface.cpp:
2565         (WebCore::JSTestInterfaceConstructor::getOwnPropertySlotVirtual):
2566         (WebCore::JSTestInterfaceConstructor::getOwnPropertySlot):
2567         (WebCore::JSTestInterface::getOwnPropertySlotVirtual):
2568         (WebCore::JSTestInterface::getOwnPropertySlot):
2569         * bindings/scripts/test/JS/JSTestInterface.h:
2570         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
2571         (WebCore::JSTestMediaQueryListListenerConstructor::getOwnPropertySlotVirtual):
2572         (WebCore::JSTestMediaQueryListListenerConstructor::getOwnPropertySlot):
2573         (WebCore::JSTestMediaQueryListListenerPrototype::getOwnPropertySlotVirtual):
2574         (WebCore::JSTestMediaQueryListListenerPrototype::getOwnPropertySlot):
2575         (WebCore::JSTestMediaQueryListListener::getOwnPropertySlotVirtual):
2576         (WebCore::JSTestMediaQueryListListener::getOwnPropertySlot):
2577         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
2578         * bindings/scripts/test/JS/JSTestObj.cpp:
2579         (WebCore::JSTestObjConstructor::getOwnPropertySlotVirtual):
2580         (WebCore::JSTestObjConstructor::getOwnPropertySlot):
2581         (WebCore::JSTestObjPrototype::getOwnPropertySlotVirtual):
2582         (WebCore::JSTestObjPrototype::getOwnPropertySlot):
2583         (WebCore::JSTestObj::getOwnPropertySlotVirtual):
2584         (WebCore::JSTestObj::getOwnPropertySlot):
2585         * bindings/scripts/test/JS/JSTestObj.h:
2586         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
2587         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::getOwnPropertySlotVirtual):
2588         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::getOwnPropertySlot):
2589         (WebCore::JSTestSerializedScriptValueInterface::getOwnPropertySlotVirtual):
2590         (WebCore::JSTestSerializedScriptValueInterface::getOwnPropertySlot):
2591         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
2592         * bridge/objc/objc_runtime.h:
2593         * bridge/objc/objc_runtime.mm:
2594         (JSC::Bindings::ObjcFallbackObjectImp::getOwnPropertySlotVirtual):
2595         * bridge/qt/qt_instance.cpp:
2596         (JSC::Bindings::QtInstance::getOwnPropertySlot):
2597         * bridge/qt/qt_runtime.cpp:
2598         (JSC::Bindings::QtRuntimeMetaMethod::getOwnPropertySlotVirtual):
2599         (JSC::Bindings::QtRuntimeConnectionMethod::getOwnPropertySlotVirtual):
2600         * bridge/qt/qt_runtime.h:
2601         * bridge/runtime_array.cpp:
2602         (JSC::RuntimeArray::getOwnPropertySlotVirtual):
2603         * bridge/runtime_array.h:
2604         * bridge/runtime_method.cpp:
2605         (JSC::RuntimeMethod::getOwnPropertySlotVirtual):
2606         * bridge/runtime_method.h:
2607         * bridge/runtime_object.cpp:
2608         (JSC::Bindings::RuntimeObject::getOwnPropertySlotVirtual):
2609         * bridge/runtime_object.h:
2610
2611 2011-10-14  Ryosuke Niwa  <rniwa@webkit.org>
2612
2613         Windows build fix attempt after r97533.
2614
2615         * html/HTMLSelectElementWin.cpp:
2616         (WebCore::HTMLSelectElement::platformHandleKeydownEvent):
2617
2618 2011-10-14  Darin Adler  <darin@apple.com>
2619
2620         Follow up the recent HTMLSelectElement improvements with a little bit more
2621         https://bugs.webkit.org/show_bug.cgi?id=70139
2622
2623         Reviewed by Ryosuke Niwa.
2624
2625         Refactoring, covered by existing tests.
2626
2627         Mostly, this adds a toHTMLSelectElement and uses it wherever possible.
2628
2629         * accessibility/AccessibilityListBox.cpp:
2630         (WebCore::AccessibilityListBox::canSetSelectedChildrenAttribute): Use toHTMLSelectElement.
2631         (WebCore::AccessibilityListBox::addChildren): Ditto. Also removed unneeded toHTMLElement.
2632         * accessibility/AccessibilityMenuListPopup.cpp:
2633         (WebCore::AccessibilityMenuListPopup::addChildren): Ditto.
2634         * accessibility/AccessibilityRenderObject.cpp:
2635         (WebCore::AccessibilityRenderObject::isMultiSelectable): Ditto.
2636         (WebCore::AccessibilityRenderObject::stringValue): Removed checks on the type of the
2637         underlying node, since other code already assumes that a menu list renderer is only
2638         created for a select element. Streamlined the code a bit and removed some unneeded
2639         local variables.
2640         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
2641         (WebCore::JSHTMLOptionsCollection::indexSetter): Use toHTMLSelectElement.
2642         * bindings/js/JSHTMLSelectElementCustom.cpp:
2643         (WebCore::JSHTMLSelectElement::remove): Ditto.
2644         (WebCore::JSHTMLSelectElement::indexSetter): Ditto.
2645         * editing/FrameSelection.cpp:
2646         (WebCore::FrameSelection::selectAll): Ditto.
2647         * html/HTMLKeygenElement.cpp:
2648         (WebCore::HTMLKeygenElement::shadowSelect): Ditto.
2649         * html/HTMLOptGroupElement.cpp:
2650         (WebCore::HTMLOptGroupElement::recalcSelectOptions): Ditto.
2651         (WebCore::HTMLOptGroupElement::ownerSelectElement): Ditto.
2652         * html/HTMLOptionElement.cpp:
2653         (WebCore::HTMLOptionElement::selected): Changed code to call renamed
2654         updateListItemSelectedStates rather than the confusing old name
2655         recalcListItemsIfNeeded.
2656         (WebCore::HTMLOptionElement::childrenChanged): Changed to call
2657         optionElementChildrenChanged rather than calling childrenChanged,
2658         because the children of the select element did not change!
2659         (WebCore::HTMLOptionElement::ownerSelectElement): Use toHTMLSelectElement.
2660         * html/HTMLOptionsCollection.cpp:
2661         (WebCore::HTMLOptionsCollection::add): Use toHTMLSelectElement.
2662         (WebCore::HTMLOptionsCollection::remove): Use toHTMLSelectElement.
2663         (WebCore::HTMLOptionsCollection::selectedIndex): Use toHTMLSelectElement.
2664         (WebCore::HTMLOptionsCollection::setSelectedIndex): Use toHTMLSelectElement.
2665         (WebCore::HTMLOptionsCollection::setLength): Use toHTMLSelectElement.
2666         * html/HTMLSelectElement.cpp:
2667         (WebCore::HTMLSelectElement::setSelectedIndexByUser): Call setSelectedIndex
2668         without the now-unneeded internal suffix.
2669         (WebCore::HTMLSelectElement::parseMappedAttribute): When the code says that
2670         we should "determine selectedness of the items", call updateListItemSelectedStates
2671         rather than the confusingly named recalcListItemsIfNeeded.
2672         (WebCore::HTMLSelectElement::updateListItemSelectedStates): Renamed
2673         recalcListItemsIfNeeded to this, since that's what this function is for.
2674         (WebCore::HTMLSelectElement::optionElementChildrenChanged): Added. Does
2675         the same work as childrenChanged, although it does not call up to the
2676         base class childrenChanged function. Later we might find we can remove
2677         some of the work here, for example it's not clear we should call the
2678         accessibility childrenChanged function.
2679         (WebCore::HTMLSelectElement::nextValidIndex): Changed this to a member function
2680         and made it get the list items itself rather than requiring they be passed in.
2681         (WebCore::HTMLSelectElement::nextSelectableListIndex): Updated for change to
2682         nextValidIndex.
2683         (WebCore::HTMLSelectElement::previousSelectableListIndex): Ditto.
2684         (WebCore::HTMLSelectElement::firstSelectableListIndex): Ditto.
2685         (WebCore::HTMLSelectElement::lastSelectableListIndex): Ditto.
2686         (WebCore::HTMLSelectElement::nextSelectableListIndexPageAway): Ditto.
2687         (WebCore::HTMLSelectElement::listItems): Removed unneeded const_cast, since
2688         recalcListItems is now a const member function. Call recalcListItems by that
2689         name instead of recalcListItemsInternal.
2690         (WebCore::HTMLSelectElement::recalcListItems): Renamed from recalcListItemsInternal
2691         and made this a const member function. The data members that this needs to modify
2692         are now mutable.
2693         (WebCore::HTMLSelectElement::setSelectedIndex): Renamed from setSelectedIndexInternal.
2694         Changed call to updateValidity to instead call setNeedsValidityCheck, since both
2695         do the same thing.
2696         (WebCore::HTMLSelectElement::parseMultipleAttribute): Ditto.
2697         (WebCore::HTMLSelectElement::menuListDefaultEventHandler): Updated for change to
2698         nextValidIndex, removed unneeded comparison with zero that's already handled by
2699         casting to an unsigned type, and use setSelectedIndex instead of using
2700         setSelectedIndexInternal since they are both the same thing.
2701         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler): Removed another unneeded
2702         comparision with zero that's handled by casting to an unsigned type.
2703         (WebCore::HTMLSelectElement::lastSelectedListIndex): Use size_t instead of unsigned
2704         for a vector index.
2705         (WebCore::HTMLSelectElement::typeAheadFind): Use setSelectedIndex instead of
2706         setSelectedIndexInternal.
2707         (WebCore::HTMLSelectElement::insertedIntoTree): Removed unneeded explicit boolean
2708         when calling a function that already has a default value of true.
2709         (WebCore::HTMLSelectElement::accessKeySetSelectedIndex): Use setSelectedIndex
2710         instead of setSelectedIndexInternal.
2711
2712         * html/HTMLSelectElement.h: Made childrenChanged private. Added
2713         optionElementChildrenChanged. Renamed recalcListItemsIfNeeded to the clearer
2714         updateListItemSelectedStates. Removed unused listBoxSelectItem. Removed
2715         updateValidity after changing all callers to instead call setNeedsValidityCheck.
2716         Made canSelectAll and selectAll non-virtual. Removed recalcListItemsInternal
2717         since it's the same thing as recalcListItems now. Renamed setSelectedIndexInternal
2718         to setSelectedIndex since it's the same function, just with a few arguments we
2719         don't want to allow outside callers to pass. Changed nextValidIndex into a
2720         non-static member function. Made m_listItems and m_shouldRecalcListItems mutable.
2721         Added a toHTMLSelectElement function, modeled on the toElement function.
2722
2723         * html/ValidityState.cpp:
2724         (WebCore::ValidityState::valueMissing): Use toHTMLSelectElement.
2725         * rendering/RenderListBox.cpp:
2726         (WebCore::RenderListBox::updateFromElement): Ditto.
2727         (WebCore::RenderListBox::scrollToRevealSelection): Ditto.
2728         (WebCore::RenderListBox::size): Ditto.
2729         (WebCore::RenderListBox::numItems): Ditto.
2730         (WebCore::RenderListBox::addFocusRingRects): Ditto.
2731         (WebCore::RenderListBox::paintItemForeground): Ditto.
2732         (WebCore::RenderListBox::paintItemBackground): Ditto.
2733         (WebCore::RenderListBox::panScroll): Ditto.
2734         (WebCore::RenderListBox::autoscroll): Ditto.
2735         (WebCore::RenderListBox::stopAutoscroll): Ditto.
2736         (WebCore::RenderListBox::valueChanged): Ditto.
2737         (WebCore::RenderListBox::nodeAtPoint): Ditto.
2738         * rendering/RenderMenuList.cpp:
2739         (WebCore::RenderMenuList::updateOptionsWidth): Ditto.
2740         (WebCore::RenderMenuList::updateFromElement): Ditto.
2741         (WebCore::RenderMenuList::setTextFromOption): Ditto.
2742         (WebCore::RenderMenuList::showPopup): Ditto.
2743         (WebCore::RenderMenuList::valueChanged): Ditto.
2744         (WebCore::RenderMenuList::listBoxSelectItem): Ditto.
2745         (WebCore::RenderMenuList::multiple): Ditto.
2746         (WebCore::RenderMenuList::didSetSelectedIndex): Ditto.
2747         (WebCore::RenderMenuList::didUpdateActiveOption): Ditto.
2748         (WebCore::RenderMenuList::itemText): Ditto.
2749         (WebCore::RenderMenuList::itemAccessibilityText): Ditto.
2750         (WebCore::RenderMenuList::itemToolTip): Ditto.
2751         (WebCore::RenderMenuList::itemIsEnabled): Ditto. Also use the
2752         disabled function instead of the virtual isEnabledFormControl
2753         function to check if the optgroup is enabled.
2754         (WebCore::RenderMenuList::itemStyle): Ditto.
2755         (WebCore::RenderMenuList::itemBackgroundColor): Ditto.
2756         (WebCore::RenderMenuList::listSize): Ditto.
2757         (WebCore::RenderMenuList::selectedIndex): Ditto.
2758         (WebCore::RenderMenuList::itemIsSeparator): Ditto.
2759         (WebCore::RenderMenuList::itemIsLabel): Ditto.
2760         (WebCore::RenderMenuList::itemIsSelected): Ditto.
2761         (WebCore::RenderMenuList::setTextFromItem): Ditto.
2762
2763 2011-10-14  Mark Hahnenberg  <mhahnenberg@apple.com>
2764
2765         Rename virtual put to putVirtual
2766         https://bugs.webkit.org/show_bug.cgi?id=69851
2767
2768         Reviewed by Darin Adler.
2769
2770         No new tests.
2771
2772         Renamed virtual versions of put to putVirtual in prepration for 
2773         adding the static put to the MethodTable in ClassInfo since the 
2774         compiler gets mad if the virtual and static versions have the same 
2775         name.
2776
2777         * WebCore.exp.in:
2778         * bindings/js/JSDOMWindowCustom.cpp:
2779         (WebCore::JSDOMWindow::putVirtual):
2780         * bindings/js/JSDOMWindowShell.cpp:
2781         (WebCore::JSDOMWindowShell::putVirtual):
2782         * bindings/js/JSDOMWindowShell.h:
2783         * bindings/js/JSLocationCustom.cpp:
2784         (WebCore::JSLocation::putDelegate):
2785         * bindings/js/JSPluginElementFunctions.cpp:
2786         (WebCore::runtimeObjectCustomPut):
2787         * bindings/js/SerializedScriptValue.cpp:
2788         (WebCore::CloneDeserializer::putProperty):
2789         * bindings/objc/WebScriptObject.mm:
2790         (-[WebScriptObject setValue:forKey:]):
2791         (-[WebScriptObject setWebScriptValueAtIndex:value:]):
2792         * bindings/scripts/CodeGeneratorJS.pm:
2793         (GenerateHeader):
2794         (GenerateImplementation):
2795         * bindings/scripts/test/JS/JSTestObj.cpp:
2796         (WebCore::JSTestObj::putVirtual):
2797         * bindings/scripts/test/JS/JSTestObj.h:
2798         * bridge/NP_jsobject.cpp:
2799         (_NPN_SetProperty):
2800         * bridge/jni/jni_jsobject.mm:
2801         (JavaJSObject::setMember):
2802         (JavaJSObject::setSlot):
2803         * bridge/objc/objc_runtime.h:
2804         * bridge/objc/objc_runtime.mm:
2805         (JSC::Bindings::ObjcFallbackObjectImp::putVirtual):
2806         * bridge/qt/qt_instance.cpp:
2807         (JSC::Bindings::QtInstance::put):
2808         * bridge/qt/qt_runtime.cpp:
2809         (JSC::Bindings::convertQVariantToValue):
2810         * bridge/runtime_array.cpp:
2811         (JSC::RuntimeArray::putVirtual):
2812         * bridge/runtime_array.h:
2813         * bridge/runtime_object.cpp:
2814         (JSC::Bindings::RuntimeObject::putVirtual):
2815         * bridge/runtime_object.h:
2816         * bridge/testqtbindings.cpp:
2817         (main):
2818
2819 2011-10-14  Sheriff Bot  <webkit.review.bot@gmail.com>
2820
2821         Unreviewed, rolling out r97519.
2822         http://trac.webkit.org/changeset/97519
2823         https://bugs.webkit.org/show_bug.cgi?id=70156
2824
2825         Broke 79+ tests on bots (Requested by dglazkov on #webkit).
2826
2827         * platform/graphics/skia/GraphicsContextSkia.cpp:
2828         (WebCore::getFocusRingOutset):
2829         (WebCore::GraphicsContext::drawFocusRing):
2830
2831 2011-09-28  Robert Hogan  <robert@webkit.org>
2832
2833         Replaced elements squeezed when width is specified as percentage inside a table with Auto layout
2834         https://bugs.webkit.org/show_bug.cgi?id=29447
2835
2836         If inserting a 'replaced' element (e.g. image, plugin) in a table cell that is not descendant from
2837         a block with fixed layout then do not squeeze the element, let it use its intrinsic width and height.
2838
2839         Reviewed by David Hyatt.
2840
2841         Test: fast/replaced/table-percent-width.html
2842
2843         * rendering/RenderBox.cpp:
2844         (WebCore::shouldExpandToIntrinsicDimension):
2845         (WebCore::RenderBox::containingBlockReplacedLogicalWidthForContent):
2846         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
2847         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
2848         * rendering/RenderBox.h:
2849
2850 2011-10-14  Cary Clark  <caryclark@google.com>
2851
2852         [Chromium Skia on Mac] Improve focus ring
2853         https://bugs.webkit.org/show_bug.cgi?id=70124
2854
2855         Reviewed by Eric Seidel.
2856         
2857         The focus ring code formerly outset the bounds of
2858         the component rectangles by fractional amounts. Because
2859         the rectangles are SkIRect (integer based), the fractional
2860         outset had no effect.
2861
2862         The equivalent code in GraphicsContextMac.mm computes
2863         the curve radius and rectangle outset with integers, so
2864         the use of floats in Skia's case, besides not working,
2865         is unnecessary.
2866
2867         The Skia code also failed to take the offset into account.
2868         In LayoutTests, the focus rings either have an offset of
2869         0 or 2. The CoreGraphics code increases the ring's rectangles
2870         by the offset, then passes the result to wkDrawFocusRing.
2871
2872         I did not find any documentation about how wkDrawFocusRing
2873         further inflates the focus ring, but empirically I determined
2874         that adding 2 to the offset generated rings with identical
2875         outer diameters.
2876  
2877         With these adjustments, the layout tests generate focus rings
2878         in the Skia on Mac case that match the coverage of the
2879         Chromium CG-based platform, in particular, matching:
2880         
2881         editing/inserting/editable-inline-element.html
2882         editing/selection/3690703-2.html
2883
2884         * platform/graphics/skia/GraphicsContextSkia.cpp:
2885         (WebCore::getFocusRingOutset):
2886         (WebCore::GraphicsContext::drawFocusRing):
2887
2888 2011-10-14  Chang Shu  <cshu@webkit.org>
2889
2890         [Qt] Enable fullscreen api on Qt
2891         https://bugs.webkit.org/show_bug.cgi?id=70131
2892
2893         As a result, we have 3 passed tests.
2894
2895         Reviewed by Noam Rosenthal.
2896
2897         * features.pri:
2898
2899 2011-10-14  Beth Dakin  <bdakin@apple.com>
2900
2901         https://bugs.webkit.org/show_bug.cgi?id=70148
2902         Should switch to CoreUI version of CorrectionDot, GrammarDot, and SpellingDot
2903         -and corresponding-
2904         <rdar://problem/10208281>
2905
2906         Reviewed by Anders Carlsson.
2907
2908         Use NS*Dot whenever it's available, and fallback to *Dot only when it is not.
2909         * platform/graphics/mac/GraphicsContextMac.mm:
2910         (WebCore::createPatternColor):
2911         (WebCore::GraphicsContext::drawLineForTextChecking):
2912
2913 2011-10-14  Dmitry Lomov  <dslomov@google.com>
2914
2915         https://bugs.webkit.org/show_bug.cgi?id=70120
2916         [Chromium] Pass MessagePortArray to SerializedScriptValue::serialize/deserialize.
2917         This patch augments SerializedScriptValue with MessagePortArray* parameter to implement MessagePort 
2918         transfer within the message in the future.
2919
2920         Reviewed by David Levin.
2921
2922         * bindings/scripts/CodeGeneratorV8.pm:
2923         (GenerateParametersCheck):
2924         * bindings/v8/SerializedScriptValue.cpp:
2925         (WebCore::SerializedScriptValue::create):
2926         (WebCore::SerializedScriptValue::SerializedScriptValue):
2927         (WebCore::SerializedScriptValue::deserialize):
2928         * bindings/v8/SerializedScriptValue.h:
2929         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2930         (WebCore::handlePostMessageCallback):
2931         (WebCore::V8DOMWindow::postMessageCallback):
2932         (WebCore::V8DOMWindow::webkitPostMessageCallback):
2933         * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
2934         (WebCore::handlePostMessageCallback):
2935         (WebCore::V8DedicatedWorkerContext::postMessageCallback):
2936         (WebCore::V8DedicatedWorkerContext::webkitPostMessageCallback):
2937         * bindings/v8/custom/V8HistoryCustom.cpp:
2938         (WebCore::V8History::pushStateCallback):
2939         (WebCore::V8History::replaceStateCallback):
2940         * bindings/v8/custom/V8MessageEventCustom.cpp:
2941         (WebCore::V8MessageEvent::dataAccessorGetter):
2942         * bindings/v8/custom/V8MessagePortCustom.cpp:
2943         (WebCore::handlePostMessageCallback):
2944         (WebCore::V8MessagePort::postMessageCallback):
2945         (WebCore::V8MessagePort::webkitPostMessageCallback):
2946         * bindings/v8/custom/V8WorkerCustom.cpp:
2947         (WebCore::handlePostMessageCallback):
2948         (WebCore::V8Worker::postMessageCallback):
2949         (WebCore::V8Worker::webkitPostMessageCallback):
2950         * workers/Worker.idl:
2951
2952 2011-10-14  Jeff Miller  <jeffm@apple.com>
2953
2954         InjectedBundleHitTestResult::imageRect() should return rect in WKView coordinates
2955         https://bugs.webkit.org/show_bug.cgi?id=69963
2956         
2957         Add infrastructure to convert from any frame view's coordinate system to the
2958         root view's coordinate system.
2959
2960         Reviewed by Simon Fraser.
2961
2962         No new tests (yet), this is covered by <https://bugs.webkit.org/show_bug.cgi?id=70136>.
2963
2964         * WebCore.exp.in: Exported WebCore::ScrollView::contentsToRootView(), used by InjectedBundleHitTestResult.cpp.
2965         
2966         * platform/ScrollView.cpp:
2967         (WebCore::ScrollView::rootViewToContents): Added (both point and rect versions).
2968         (WebCore::ScrollView::contentsToRootView): Ditto.
2969         
2970         * platform/ScrollView.h: Added member functions to convert to/from root view coordinates.
2971         
2972         * platform/Widget.cpp:
2973         (WebCore::Widget::convertFromRootView): Added (both point and rect versions).
2974         (WebCore::Widget::convertToRootView): Ditto.
2975         
2976         * platform/Widget.h: Added member functions to convert to/from root view coordinates.
2977
2978 2011-10-14  Andreas Kling  <kling@webkit.org>
2979
2980         CSSParser: Remove StyleBase usage.
2981         https://bugs.webkit.org/show_bug.cgi?id=70150
2982
2983         Reviewed by Darin Adler.
2984
2985         Split CSSParser::m_parsedStyleObjects into two vectors of
2986         CSSRules and MediaLists.
2987
2988         * css/CSSParser.cpp:
2989         (WebCore::CSSParser::createMediaList):
2990         (WebCore::CSSParser::createCharsetRule):
2991         (WebCore::CSSParser::createImportRule):
2992         (WebCore::CSSParser::createMediaRule):
2993         (WebCore::CSSParser::createKeyframesRule):
2994         (WebCore::CSSParser::createStyleRule):
2995         (WebCore::CSSParser::createFontFaceRule):
2996         (WebCore::CSSParser::createPageRule):
2997         (WebCore::CSSParser::createKeyframeRule):
2998         * css/CSSParser.h:
2999
3000 2011-10-14  Adam Barth  <abarth@webkit.org>
3001
3002         canvas getImageData should explain why it throws SECURITY_ERR
3003         https://bugs.webkit.org/show_bug.cgi?id=70088
3004
3005         Reviewed by Darin Adler.
3006
3007         Log as message to the console when getImageData fails because the
3008         canvas is tainted.
3009
3010         * html/canvas/CanvasRenderingContext2D.cpp:
3011         (WebCore::CanvasRenderingContext2D::getImageData):
3012
3013 2011-10-14  Andreas Kling  <kling@webkit.org>
3014
3015         Inspector: Remove StyleBase usage.
3016         https://bugs.webkit.org/show_bug.cgi?id=70138
3017
3018         Reviewed by Antti Koivisto.
3019
3020         Be fully specific about whether we're operating on a CSSRule or
3021         a CSSStyleSheet.
3022
3023         No behavior change expected, this merely is a cleanup.
3024
3025         * inspector/InspectorCSSAgent.cpp:
3026         (WebCore::InspectorCSSAgent::parentStyleSheet):
3027         (WebCore::InspectorCSSAgent::asCSSStyleRule):
3028         * inspector/InspectorCSSAgent.h:
3029         * inspector/InspectorStyleSheet.cpp:
3030         (WebCore::asCSSRuleList):
3031
3032 2011-10-14  Mark Hahnenberg  <mhahnenberg@apple.com>
3033
3034         Rename virtual deleteProperty to deletePropertyVirtual
3035         https://bugs.webkit.org/show_bug.cgi?id=69884
3036
3037         Reviewed by Darin Adler.
3038
3039         No new tests.
3040
3041         Renamed virtual versions of deleteProperty to deletePropertyVirtual in prepration for 
3042         adding the static deleteProperty to the MethodTable in ClassInfo since the 
3043         compiler gets mad if the virtual and static versions have the same name.
3044
3045         * WebCore.exp.in:
3046         * bindings/js/JSDOMStringMapCustom.cpp:
3047         (WebCore::JSDOMStringMap::deletePropertyVirtual):
3048         * bindings/js/JSDOMWindowCustom.cpp:
3049         (WebCore::JSDOMWindow::deletePropertyVirtual):
3050         * bindings/js/JSDOMWindowShell.cpp:
3051         (WebCore::JSDOMWindowShell::deletePropertyVirtual):
3052         * bindings/js/JSDOMWindowShell.h:
3053         * bindings/js/JSHistoryCustom.cpp:
3054         (WebCore::JSHistory::deletePropertyVirtual):
3055         * bindings/js/JSLocationCustom.cpp:
3056         (WebCore::JSLocation::deletePropertyVirtual):
3057         * bindings/js/JSStorageCustom.cpp:
3058         (WebCore::JSStorage::deletePropertyVirtual):
3059         * bindings/js/ScriptObject.cpp:
3060         (WebCore::ScriptGlobalObject::remove):
3061         * bindings/objc/WebScriptObject.mm:
3062         (-[WebScriptObject removeWebScriptKey:]):
3063         * bindings/scripts/CodeGeneratorJS.pm:
3064         (GenerateHeader):
3065         * bridge/NP_jsobject.cpp:
3066         (_NPN_RemoveProperty):
3067         * bridge/jni/jni_jsobject.mm:
3068         (JavaJSObject::removeMember):
3069         * bridge/objc/objc_runtime.h:
3070         * bridge/objc/objc_runtime.mm:
3071         (JSC::Bindings::ObjcFallbackObjectImp::deletePropertyVirtual):
3072         * bridge/runtime_array.cpp:
3073         (JSC::RuntimeArray::deletePropertyVirtual):
3074         * bridge/runtime_array.h:
3075         * bridge/runtime_object.cpp:
3076         (JSC::Bindings::RuntimeObject::deletePropertyVirtual):
3077         * bridge/runtime_object.h:
3078
3079 2011-10-14  Simon Fraser  <simon.fraser@apple.com>
3080
3081         Web Inspector: WebProcess crashes hard when inspecting elements with border-images applied
3082         https://bugs.webkit.org/show_bug.cgi?id=70105
3083
3084         Reviewed by Dave Hyatt.
3085         
3086         Fix three different crashes related to getting computed style for border-image.
3087         In both valueForNinePieceImageSlice() and valueForNinePieceImageQuad(),
3088         assign 'right' to 'left' because we've computed a value for 'right' already.
3089         Otherwise this would leave 'right' as null, causing later crashes in cssText().
3090         
3091         In mapNinePieceImage(), borderImage->imageValue() can be null for a border-image
3092         shorthand that is missing the image value.
3093
3094         Test: fast/css/getComputedStyle/computed-style-border-image.html
3095
3096         * css/CSSComputedStyleDeclaration.cpp:
3097         (WebCore::valueForNinePieceImageSlice):
3098         (WebCore::valueForNinePieceImageQuad):
3099         * css/CSSStyleSelector.cpp:
3100         (WebCore::CSSStyleSelector::mapNinePieceImage):
3101
3102 2011-10-14  Ryosuke Niwa  <rniwa@webkit.org>
3103
3104         Mac build fix after r97497.
3105
3106         * editing/markup.cpp:
3107         (WebCore::isNonTableCellHTMLBlockElement):
3108
3109 2011-10-14  Daniel Cheng  <dcheng@chromium.org>
3110
3111         Context-aware HTML paste for Chromium
3112         https://bugs.webkit.org/show_bug.cgi?id=62112
3113
3114         Reviewed by Ryosuke Niwa.
3115
3116         Add createFragmentFromMarkupWithContext which understands enough about DOM structure to
3117         retain necessary elements to preserve structure and appearance when extracting a subset of
3118         a DOM tree.
3119
3120         Covered by existing layout tests.
3121
3122         * editing/MarkupAccumulator.h:
3123         * editing/markup.cpp:
3124         (WebCore::isNonTableCellHTMLBlockElement):
3125         (WebCore::isHTMLBlockElement):
3126         (WebCore::ancestorToRetainStructureAndAppearanceForBlock):
3127         (WebCore::ancestorToRetainStructureAndAppearance):
3128         (WebCore::ancestorToRetainStructureAndAppearanceWithNoRenderer):
3129         (WebCore::findNodesSurroundingContext):
3130         (WebCore::trimFragment):
3131         (WebCore::createFragmentFromMarkupWithContext):
3132         * editing/markup.h:
3133         * platform/chromium/ChromiumDataObject.cpp:
3134         (WebCore::ChromiumDataObject::getData):
3135         * platform/chromium/DataTransferItemChromium.cpp:
3136         (WebCore::DataTransferItemChromium::getAsString):
3137         * platform/chromium/PasteboardChromium.cpp:
3138         (WebCore::Pasteboard::documentFragment):
3139         * platform/chromium/PlatformSupport.h:
3140
3141 2011-10-14  Peter Beverloo  <peter@chromium.org>
3142
3143         [Chromium] Inherit settings from Chromium's envsetup.sh, address a NDK todo
3144         https://bugs.webkit.org/show_bug.cgi?id=70028
3145
3146         Reviewed by Adam Barth.
3147
3148         * WebCore.gyp/WebCore.gyp:
3149
3150 2011-10-14  Nate Chapin  <japhet@chromium.org>
3151
3152         Check CachedResourceClient types with ASSERTs rather
3153         than if statements.
3154         https://bugs.webkit.org/show_bug.cgi?id=70113
3155
3156         Reviewed by Adam Barth.
3157
3158         No new tests, no functionality change.
3159
3160         * loader/cache/CachedCSSStyleSheet.cpp:
3161         * loader/cache/CachedFont.cpp:
3162         * loader/cache/CachedImage.cpp:
3163         * loader/cache/CachedResourceClientWalker.h:
3164         * loader/cache/CachedXSLStyleSheet.cpp:
3165
3166 2011-10-14  Andreas Kling  <kling@webkit.org>
3167
3168         Don't assert that CSSRules are CSSRules.
3169
3170         Rubber-stamped by Antti Koivisto.
3171
3172         * css/CSSRule.h:
3173         (WebCore::CSSRule::isRule):
3174         * css/CSSStyleSheet.cpp:
3175         (WebCore::CSSStyleSheet::append):
3176         (WebCore::CSSStyleSheet::insert):
3177
3178 2011-10-14  Beth Dakin  <bdakin@apple.com>
3179
3180         Attempted Leopard build fix.
3181
3182         * platform/graphics/GraphicsContext.cpp:
3183         (WebCore::GraphicsContext::createCompatibleBuffer):
3184
3185 2011-10-14  Andreas Kling  <kling@webkit.org>
3186
3187         CSSStyleSheet should only ever contain CSSRules.
3188         https://bugs.webkit.org/show_bug.cgi?id=70116
3189
3190         Reviewed by Antti Koivisto.
3191
3192         Move child management from the StyleSheet class down into
3193         CSSStyleSheet and XSLStyleSheet. XSLStyleSheet continues to
3194         manage StyleBase objects, while CSSStyleSheet now only contains
3195         CSSRule.
3196
3197         This is enforced at both compile time and runtime with explicit
3198         types and assertions.
3199
3200         * css/CSSRule.h:
3201         (WebCore::CSSRule::isRule):
3202
3203             Promoted to a public method so we can use it in assertions.
3204
3205         * css/CSSRuleList.h:
3206         (WebCore::CSSRuleList::create):
3207         (WebCore::CSSRuleList::styleSheet):
3208         * css/CSSRuleList.cpp:
3209         (WebCore::CSSRuleList::CSSRuleList):
3210         * bindings/js/JSCSSRuleListCustom.cpp:
3211         (WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
3212
3213             Change backing to a CSSStyleSheet instead of a StyleSheet.
3214
3215         * css/CSSRuleList.cpp:
3216         (WebCore::CSSRuleList::item):
3217
3218             Remove redundant assertions.
3219
3220         * css/CSSStyleSheet.cpp:
3221         (WebCore::CSSStyleSheet::isLoading):
3222         (WebCore::CSSStyleSheet::addSubresourceStyleURLs):
3223         * css/CSSStyleSelector.cpp:
3224         (WebCore::RuleSet::addRulesFromSheet):
3225         * inspector/InspectorCSSAgent.cpp:
3226         (WebCore::InspectorCSSAgent::collectStyleSheets):
3227         * page/PageSerializer.cpp:
3228         (WebCore::PageSerializer::serializeCSSStyleSheet):
3229
3230             Use more specific CSSRule* since that's what we get from
3231             CSSStyleSheet::item() now.
3232
3233         * css/StyleSheet.cpp:
3234         (WebCore::StyleSheet::~StyleSheet):
3235         * css/CSSStyleSheet.cpp:
3236         (WebCore::CSSStyleSheet::~CSSStyleSheet):
3237         * xml/XSLStyleSheetLibxslt.cpp:
3238         (WebCore::XSLStyleSheet::~XSLStyleSheet):
3239         * xml/XSLStyleSheetQt.cpp:
3240         (WebCore::XSLStyleSheet::~XSLStyleSheet):
3241
3242             Orphaning logic from ~StyleSheet() moved to subclass dtors.
3243
3244         * css/StyleSheet.h:
3245         * css/CSSStyleSheet.h:
3246         (WebCore::CSSStyleSheet::length):
3247         (WebCore::CSSStyleSheet::item):
3248         * css/CSSStyleSheet.cpp:
3249         (WebCore::CSSStyleSheet::append):
3250         (WebCore::CSSStyleSheet::insert):
3251         (WebCore::CSSStyleSheet::remove):
3252
3253             Moved from StyleSheet and changed to only accept CSSRules.
3254
3255         * css/StyleSheet.h:
3256         * xml/XSLStyleSheet.h:
3257         (WebCore::XSLStyleSheet::length):
3258         (WebCore::XSLStyleSheet::item):
3259         (WebCore::XSLStyleSheet::append):
3260         (WebCore::XSLStyleSheet::insert):
3261         (WebCore::XSLStyleSheet::remove):
3262
3263             Moved from StyleSheet though still uses StyleBase.
3264
3265 2011-10-14 Yuji Sanachan <sanachan.y@gmail.com>
3266
3267         Include dom/ExceptionCode.h instead of Filesystem APIs headers
3268         to fix compile error when ENABLE_WORKERS=1 and ENABLE_FILE_SYSTEM=0
3269         https://bugs.webkit.org/show_bug.cgi?id=70036
3270
3271         Reviewed by Darin Adler.
3272
3273         * workers/WorkerContext.cpp:
3274         (WebCore::WorkerContext::importScript):
3275
3276 2011-10-14  Darin Adler  <darin@apple.com>
3277
3278         Text drawn via -webkit-background-clip:text should be non-blurry with all scaling 
3279         techniques
3280         https://bugs.webkit.org/show_bug.cgi?id=68641
3281
3282         Reviewed by Simon Fraser. Committed by Beth Dakin.
3283
3284         * platform/graphics/GraphicsContext.cpp:
3285         (WebCore::GraphicsContext::createCompatibleBuffer): Allocate a buffer based on the 
3286         scale
3287         factor of the context.
3288         * platform/graphics/GraphicsContext.h: Added createCompatibleBuffer.
3289
3290         * rendering/RenderBoxModelObject.cpp:
3291         (WebCore::RenderBoxModelObject::paintFillLayerExtended): Use 
3292         createCompatibleBuffer.
3293
3294 2011-10-14  Ryosuke Niwa  <rniwa@webkit.org>
3295
3296         Move selectionStartStyle and selectionHasStyle to EditingStyle
3297         https://bugs.webkit.org/show_bug.cgi?id=69882
3298
3299         Reviewed by Enrica Casucci.
3300
3301         Moved selectionHasStyle and selectionStartStyle from Editor to EditingStyle.
3302         Also moved much of code in Editor::selectionStartCSSPropertyValue to method of EditingStyle.
3303
3304         In addition, moved Range::editingStartPosition to htmlediting where it belongs
3305         and renamed it to adjustedSelectionStartForStyleComputation.
3306
3307         * dom/Range.cpp:
3308         * dom/Range.h:
3309         * editing/EditingStyle.cpp:
3310         (WebCore::EditingStyle::triStateOfStyle): Extracted from selectionHasStyle.
3311         (WebCore::EditingStyle::legacyFontSize): Extracted from selectionStartCSSPropertyValue.
3312         (WebCore::EditingStyle::styleAtSelectionStart): Moved from Editor::selectionStartStyle.
3313         * editing/EditingStyle.h:
3314         * editing/Editor.cpp:
3315         (WebCore::Editor::fontForSelection):
3316         (WebCore::Editor::selectionStartHasStyle):
3317         (WebCore::Editor::selectionHasStyle):
3318         (WebCore::Editor::selectionStartCSSPropertyValue):
3319         * editing/Editor.h:
3320         * editing/EditorCommand.cpp:
3321         (WebCore::executeToggleStyleInList):
3322         * editing/htmlediting.cpp:
3323         (WebCore::adjustedSelectionStartForStyleComputation): Moved from Range::editingStartPosition.
3324         * editing/htmlediting.h:
3325
3326 2011-10-14  Ryosuke Niwa  <rniwa@webkit.org>
3327
3328         Redundant comparison in AccessibilityObject.cpp updateAXLineStartForVisiblePosition
3329         https://bugs.webkit.org/show_bug.cgi?id=70074
3330
3331         Reviewed by Chris Fleizach.
3332
3333         Removed redundant code.
3334
3335         * accessibility/AccessibilityObject.cpp:
3336         (WebCore::updateAXLineStartForVisiblePosition):
3337
3338 2011-10-12  Ryosuke Niwa  <rniwa@webkit.org>
3339
3340         Make the interface of locationAndLengthFromRange and rangeFromLocationAndLength consistent
3341         https://bugs.webkit.org/show_bug.cgi?id=69964
3342
3343         Reviewed by Enrica Casucci.
3344
3345         Extracted the logic to determine the scope element as FrameSelection::rootEditableElementOrDocumentElement
3346         and deployed it in WebKit layer. Made locationAndLengthFromRange take a scope element and renamed it to
3347         getLocationAndLengthFromRange.
3348
3349         * WebCore.exp.in:
3350         * editing/FrameSelection.cpp:
3351         (WebCore::FrameSelection::rootEditableElementOrDocumentElement):
3352         * editing/FrameSelection.h:
3353         * editing/TextIterator.cpp:
3354         (WebCore::TextIterator::getLocationAndLengthFromRange):
3355         * editing/TextIterator.h:
3356
3357 2011-10-13  Arko Saha  <arko@motorola.com>
3358
3359         Microdata: Basic implementation of document.getItems() method.
3360         https://bugs.webkit.org/show_bug.cgi?id=68610
3361
3362         Reviewed by Ryosuke Niwa.
3363
3364         Added ENABLE(MICRODATA) feature flag. Implement document.getItems() DOM API.
3365         Spec: http://www.whatwg.org/specs/web-apps/current-work/complete/microdata.html
3366
3367         Tests: fast/dom/MicroData/001.html
3368                fast/dom/MicroData/002.html
3369                fast/dom/MicroData/003.html
3370                fast/dom/MicroData/004.html
3371                fast/dom/MicroData/005.html
3372                fast/dom/MicroData/006.html
3373                fast/dom/MicroData/007.html
3374                fast/dom/MicroData/008.html
3375                fast/dom/MicroData/009.html
3376
3377         * CMakeLists.txt:
3378         * DerivedSources.make:
3379         * GNUmakefile.am:
3380         * GNUmakefile.list.am:
3381         * WebCore.gypi:
3382         * WebCore.pro:
3383         * WebCore.vcproj/WebCore.vcproj:
3384         * dom/Document.cpp:
3385         (WebCore::Document::getItems): Returns NodeList of the element in the Document that
3386         create items, that are not part of other items, and that are of one of the types
3387         given in the argument. If no tokens specified/undefined in the argument, then
3388         return a NodeList containing all top level microdata items.
3389         (WebCore::Document::removeCachedMicroDataItemList): Remove Microdata item node list
3390         from cache.
3391         * dom/Document.h:
3392         * dom/Document.idl: Added getItems() microdata DOM API.
3393         * dom/MicroDataItemList.cpp: Added.
3394         (WebCore::MicroDataItemList::MicroDataItemList):
3395         (WebCore::MicroDataItemList::~MicroDataItemList):
3396         (WebCore::MicroDataItemList::nodeMatches):
3397         * dom/MicroDataItemList.h: Added.
3398         (WebCore::MicroDataItemList::create):
3399         * dom/Node.cpp:
3400         (WebCore::Node::itemTypeAttributeChanged): It is responsible to invalidate the Microdata
3401         item node cache when itemType attribute changes.
3402         (WebCore::NodeListsNodeData::invalidateCachesThatDependOnAttributes):
3403         (WebCore::NodeListsNodeData::invalidateMicrodataItemListCaches): Invalidate Microdata item
3404         list cache.
3405         (WebCore::NodeListsNodeData::isEmpty):
3406         * dom/Node.h:
3407         * dom/NodeRareData.h:
3408         * features.pri:
3409         * html/HTMLAttributeNames.in: Added itemid, itemprop, itemscope, itemtype attributes.
3410         * html/HTMLElement.cpp:
3411         (WebCore::HTMLElement::parseMappedAttribute): Handle itemtype attribute change.
3412         * html/HTMLElement.idl: Added itemid, itemprop, itemscope, itemtypes microdata attributes.
3413
3414 2011-10-14  Andreas Kling  <kling@webkit.org>
3415
3416         Stricter management of WebKitCSSKeyframeRules.
3417         https://bugs.webkit.org/show_bug.cgi?id=70109
3418
3419         Reviewed by Antti Koivisto.
3420
3421         Covered by existing tests.
3422
3423         * css/CSSParser.h:
3424         * css/CSSParser.cpp:
3425         (WebCore::CSSParser::parseKeyframeRule):
3426
3427             Return a WebKitCSSKeyframeRule instead of a CSSRule.
3428
3429         * css/CSSRuleList.cpp:
3430         (WebCore::CSSRuleList::deleteRule):
3431         * css/WebKitCSSKeyframesRule.cpp:
3432         (WebCore::WebKitCSSKeyframesRule::deleteRule):
3433
3434             Moved style sheet orphaning logic for @-webkit-keyframe
3435             from CSSRuleList into WebKitCSSKeyframesRule::deleteRule()
3436             since that's the only caller operating on those rules.
3437
3438         * css/WebKitCSSKeyframesRule.cpp:
3439         (WebCore::WebKitCSSKeyframesRule::~WebKitCSSKeyframesRule):
3440         (WebCore::WebKitCSSKeyframesRule::length):
3441         (WebCore::WebKitCSSKeyframesRule::item):
3442         (WebCore::WebKitCSSKeyframesRule::insertRule):
3443
3444             Change isKeyframeRule() checks to assertions since we know
3445             our rules are always WebKitCSSKeyframeRules. Also tidied up.
3446
3447 2011-10-14  Andreas Kling  <kling@webkit.org>
3448
3449         Unreviewed, actually remove StyleList.* after r97640.
3450
3451         * css/StyleList.cpp: Removed.
3452         * css/StyleList.h: Removed.
3453
3454 2011-10-14  Andreas Kling  <kling@webkit.org>
3455
3456         Merge StyleList into StyleSheet.
3457         https://bugs.webkit.org/show_bug.cgi?id=70100
3458
3459         Reviewed by Antti "printf" Koivisto.
3460
3461         Merge all functionality from StyleList into StyleSheet,
3462         since StyleSheet was the only subclass of StyleList anyway.
3463
3464         Also removed FIXME's about throwing exceptions in CSSRuleList
3465         since they were incorrect. The call sites already handle the
3466         relevant cases.
3467
3468         * CMakeLists.txt:
3469         * GNUmakefile.list.am:
3470         * WebCore.gypi:
3471         * WebCore.pro:
3472         * WebCore.vcproj/WebCore.vcproj:
3473         * WebCore.xcodeproj/project.pbxproj:
3474         * bindings/js/JSCSSRuleListCustom.cpp:
3475         (WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
3476         * css/CSSRuleList.cpp:
3477         (WebCore::CSSRuleList::CSSRuleList):
3478         (WebCore::CSSRuleList::length):
3479         (WebCore::CSSRuleList::item):
3480         (WebCore::CSSRuleList::deleteRule):
3481         (WebCore::CSSRuleList::append):
3482         (WebCore::CSSRuleList::insertRule):
3483         * css/CSSRuleList.h:
3484         (WebCore::CSSRuleList::create):
3485         (WebCore::CSSRuleList::styleSheet):
3486         * css/StyleList.cpp: Removed.
3487         * css/StyleList.h: Removed.
3488         * css/StyleSheet.cpp:
3489         (WebCore::StyleSheet::StyleSheet):
3490         (WebCore::StyleSheet::append):
3491         (WebCore::StyleSheet::insert):
3492         (WebCore::StyleSheet::remove):
3493         * css/StyleSheet.h:
3494         (WebCore::StyleSheet::length):
3495         (WebCore::StyleSheet::item):
3496
3497 2011-10-14  Mihnea Ovidenie  <mihnea@adobe.com>
3498
3499         [CSS Regions] Change -webkit-flow to -webkit-flow-into
3500         https://bugs.webkit.org/show_bug.cgi?id=70014
3501
3502         Reviewed by David Hyatt.
3503
3504         1. -webkit-flow is renamed to -webkit-flow-into
3505         2. -webkit-flow-into takes <ident> instead of strings
3506
3507         * css/CSSComputedStyleDeclaration.cpp:
3508         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3509         * css/CSSParser.cpp:
3510         (WebCore::CSSParser::parseValue):
3511         (WebCore::validFlowName):
3512         (WebCore::CSSParser::parseFlowThread):
3513         * css/CSSPropertyNames.in:
3514         * css/CSSStyleSelector.cpp:
3515         (WebCore::CSSStyleSelector::applyProperty):
3516
3517 2011-10-12  Hans Wennborg  <hans@chromium.org>
3518
3519         IndexedDB: Remove SQLite backing store
3520         https://bugs.webkit.org/show_bug.cgi?id=69620
3521
3522         Reviewed by Darin Fisher.
3523
3524         Remove the SQLite backing store implementation; it is not used anymore.
3525         Also remove the maximumSize parameter, it is not used either.
3526
3527         No new functionality, so no new tests.
3528
3529         * GNUmakefile.list.am:
3530         * WebCore.gypi:
3531         * storage/IDBBackingStore.h:
3532         * storage/IDBFactory.cpp:
3533         (WebCore::IDBFactory::getDatabaseNames):
3534         (WebCore::IDBFactory::open):
3535         * storage/IDBFactoryBackendImpl.cpp:
3536         (WebCore::computeFileIdentifier):
3537         (WebCore::computeUniqueIdentifier):
3538         (WebCore::IDBFactoryBackendImpl::getDatabaseNames):
3539         (WebCore::IDBFactoryBackendImpl::open):
3540         (WebCore::IDBFactoryBackendImpl::openBackingStore):
3541         * storage/IDBFactoryBackendImpl.h:
3542         * storage/IDBFactoryBackendInterface.h:
3543         * storage/IDBLevelDBBackingStore.cpp:
3544         (WebCore::IDBLevelDBBackingStore::open):
3545         * storage/IDBLevelDBBackingStore.h:
3546         * storage/IDBSQLiteBackingStore.cpp: Removed.
3547         * storage/IDBSQLiteBackingStore.h: Removed.
3548
3549 2011-10-14  Nikolas Zimmermann  <nzimmermann@rim.com>
3550
3551         Not reviewed. Fix mac builds. r97448 broke them.
3552
3553         * WebCore.xcodeproj/project.pbxproj: Set ImageBySizeCache.h role to private.
3554
3555 2011-10-14  Justin Schuh  <jschuh@chromium.org>
3556
3557         Clear WebMediaPlayerClientImpl back pointer on destruction
3558         https://bugs.webkit.org/show_bug.cgi?id=69973
3559
3560         Reviewed by James Robinson.
3561
3562         Clear the backpointer and remove the unused m_currentFrame
3563
3564         * platform/graphics/chromium/VideoLayerChromium.cpp:
3565         (WebCore::VideoLayerChromium::VideoLayerChromium):
3566         (WebCore::VideoLayerChromium::cleanupResources):
3567         (WebCore::VideoLayerChromium::updateCompositorResources):
3568         (WebCore::VideoLayerChromium::releaseProvider):
3569         * platform/graphics/chromium/VideoLayerChromium.h:
3570
3571 2011-10-13  Hans Wennborg  <hans@chromium.org>
3572
3573         IndexedDB: Make IDBCursor.value() return an IDBAny object
3574         https://bugs.webkit.org/show_bug.cgi?id=70024
3575
3576         Reviewed by Tony Chang.
3577
3578         This is to work around the fact that the V8 bindings mechanism does
3579         eager deserialization of SerializedScriptValue attributes. This means
3580         that the value is fetched from the back-end only once, when the
3581         IDBCursor is first wrapped. When the cursor's value changes, this is
3582         not reflected.
3583
3584         We work around this by making IDBCursor.value() return the
3585         SerializedScriptValue wrapped in an IDBAny object.
3586
3587         * storage/IDBCursor.cpp:
3588         (WebCore::IDBCursor::value):
3589         * storage/IDBCursor.h:
3590         * storage/IDBCursorWithValue.idl:
3591
3592 2011-10-14  Rémi Duraffort  <remi.duraffort@st.com>
3593
3594         Fix compilation when the JS Debugger is disabled.
3595         https://bugs.webkit.org/show_bug.cgi?id=70007
3596
3597         Reviewed by Antti Koivisto.
3598
3599         * inspector/InspectorInstrumentation.cpp:
3600         (WebCore::InspectorInstrumentation::willEvaluateWorkerScript):
3601         * inspector/InspectorRuntimeAgent.cpp:
3602         * inspector/InspectorRuntimeAgent.h:
3603         * inspector/WorkerInspectorController.cpp:
3604         * inspector/WorkerInspectorController.h:
3605         * workers/WorkerMessagingProxy.cpp:
3606         (WebCore::WorkerMessagingProxy::disconnectFromInspector):
3607         (WebCore::WorkerMessagingProxy::sendMessageToInspector):
3608
3609 2011-10-13  Nikolas Zimmermann  <nzimmermann@rim.com>
3610
3611         Prepare SVGImage intrinsic size negotiation: Introduce an IntSize <-> SVGImage cache in CachedImage
3612         https://bugs.webkit.org/show_bug.cgi?id=69416
3613
3614         Reviewed by Antti Koivisto.
3615
3616         Refactor ImageBySizeCache out of CSSImageGeneratorValue as CachedImage wants to use the same type of cache for its purposes.
3617         When introducing the SVGImage intrinsic size negotiation the container size of an SVGImage is dependant on the place where
3618         it gets embedded (eg width/height attributes of host documents <img> force a certain size).
3619
3620         Currently CachedImage only contains a single RefPtr<Image>, which it constructs out of the decoded data.
3621         Multiple RenderObjects share the same CachedImages, when embedding eg. a SVG document in a <html:img> or using it in a background-image for a <div>.
3622         Consider the case where two RenderObjects use the same CachedImage, each with a different container size (200x100 vs 100x200) and the embedded
3623         document contains a viewBox and some arbitary preserveAspectRatio settings. To honour these we have to relayout the document with the desired
3624         size (percentual unit resolving etc, all depend on the RenderSVGRoots size).
3625
3626         With the current design this is hard to realize, w/o requring to relayout the embedded document for each embedder that uses an SVGImage.
3627         This patch introduces a cache right within CachedImage, which manages a map of images to certain sizes, by utilizing the new ImageBySizeCache.
3628
3629         CachedImage::imageForRenderer() takes a RenderObject* parameter, which it uses to look up the last set image container size for a renderer.
3630         Using that size it queries the cache whether it already has an SVGImage for that size, if not it gets created, by creating a whole
3631         new instance of SVGImage, filling it with the already decoded data, and passing on a fixed image container size, which overrides the
3632         size that RenderSVGRoot reports, when computeReplacedLogicalWidth/Height is called and thus laying out the document at the desired size.
3633         This image is then put in the cache for further reusability.
3634
3635         Likewise CachedImage::setContainerSizeForRenderer() now takes a RenderObject* parameter and stores that in the cache with an associated container size.
3636         It requires to touch several files which use CachedImage throughout WebCore/WebKit/WebKit2.
3637
3638         The actual cache is not yet turned on yet, so this is not a functional change so far, as it needs some other changes to SVGImage,
3639         which will come with the master patch in bug 47156.
3640
3641         No new tests yet, as the new cache isn't turned on yet.
3642
3643         * CMakeLists.txt: Add rendering/ImageBySizeCache.* to build.
3644         * GNUmakefile.list.am: Ditto.
3645         * WebCore.gypi: Ditto.
3646         * WebCore.pro: Ditto.
3647         * WebCore.vcproj/WebCore.vcproj: Ditto.
3648         * WebCore.xcodeproj/project.pbxproj: Ditto.
3649         * accessibility/AccessibilityRenderObject.cpp:
3650         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored): Use new CachedImage::imageSizeForRenderer(RenderObject*) method.
3651         * bindings/objc/DOM.mm: Ditto (for CachedImage::image()).
3652         (-[DOMElement image]):
3653         (-[DOMElement _imageTIFFRepresentation]):
3654         * bridge/qt/qt_pixmapruntime.cpp:
3655         (JSC::Bindings::QtPixmapInstance::variantFromObject): Ditto (for CachedImage::image()).
3656         * css/CSSCanvasValue.cpp: s/m_clients/clients()/, which now live in the ImageBySizeCache instead of CSSImageGeneratorValue.
3657         (WebCore::CSSCanvasValue::canvasChanged):
3658         (WebCore::CSSCanvasValue::canvasResized):
3659         (WebCore::CSSCanvasValue::image):
3660         * css/CSSGradientValue.cpp: Ditto.
3661         (WebCore::CSSGradientValue::image):
3662         * css/CSSImageGeneratorValue.cpp: Move the sizes/clients/images cache into a new ImageBySizeCache class, to make it usable for CachedImage as well.
3663         (WebCore::CSSImageGeneratorValue::addClient): Adapt to move.
3664         (WebCore::CSSImageGeneratorValue::removeClient): Ditto.
3665         (WebCore::CSSImageGeneratorValue::getImage): Ditto.
3666         (WebCore::CSSImageGeneratorValue::putImage): Ditto.
3667         * css/CSSImageGeneratorValue.h:
3668         (WebCore::CSSImageGeneratorValue::clients): Forwarded to the ImageBySizeCache.
3669         * editing/DeleteButtonController.cpp: 
3670         (WebCore::isDeletableElement): CachedImage::canRender() now takes a RenderObject* parameter.
3671         * html/HTMLImageElement.cpp:
3672         (WebCore::HTMLImageElement::width): Use new CachedImage::imageSizeForRenderer(RenderObject*) method.
3673         (WebCore::HTMLImageElement::height): Ditto.
3674         (WebCore::HTMLImageElement::naturalWidth): Ditto.
3675         (WebCore::HTMLImageElement::naturalHeight): Ditto.
3676         * html/ImageDocument.cpp:
3677         (WebCore::ImageDocumentParser::finish): Ditto.
3678         (WebCore::ImageDocument::scale): Ditto.
3679         (WebCore::ImageDocument::resizeImageToFit): Ditto.
3680         (WebCore::ImageDocument::imageUpdated): Ditto.
3681         (WebCore::ImageDocument::restoreImageSize): Ditto.
3682         (WebCore::ImageDocument::imageFitsInWindow): Ditto.
3683         * html/canvas/CanvasRenderingContext.cpp:
3684         (WebCore::CanvasRenderingContext::wouldTaintOrigin): Use new CachedImage::imageForRenderer(RenderObject*) method.
3685         * html/canvas/CanvasRenderingContext2D.cpp:
3686         (WebCore::isOriginClean): Ditto.
3687         (WebCore::size): Ditto (for CachedImage::imageSizeForRenderer()).
3688         (WebCore::CanvasRenderingContext2D::drawImage): Ditto.
3689         (WebCore::CanvasRenderingContext2D::createPattern): Ditto.
3690         * html/canvas/WebGLRenderingContext.cpp:
3691         (WebCore::WebGLRenderingContext::texImage2D): Ditto.
3692         (WebCore::WebGLRenderingContext::texSubImage2D): Ditto.
3693         * loader/cache/CachedImage.cpp: Add currently _disabled_ cache for SVGImages. The intrinsic size negotiation will need to use multiple SVGImages
3694         for each requested size (equal to the size of the embedding place for the image) - make it possible to cache these SVGImages, and maintain a cache
3695         for them. The hash code is a 1:1 refactoring from the already present code in CSSImageGeneratorValue, now named 'ImageBySizeCache'.
3696         (WebCore::CachedImage::lookupImageForSize): Looks up an Image from the cache for a given IntSize. Currently turned off.
3697         (WebCore::CachedImage::lookupImageForRenderer): Looks up an Image from the cache for a given renderer. Currently turned off.
3698         (WebCore::CachedImage::lookupOrCreateImageForRenderer): Looks up an Image from the cache or creates a new SVGImage for a given size and caches it, if possible. Currently turned off.
3699         All following changes share this: Don't operate on m_image directly, instead always look up one from the cache for a given size or renderer - if that's not present fallback to m_image.
3700         When an SVGImage is first created by CachedImage::createImage() and stored in m_image, the cache remains empty.
3701
3702         If eg. <img width="30" height="70" src="foo.svg"> is used which implies a container size of 30x70 a new SVGImage is created with the additional information of a 30x70 container size
3703         which is immediately passed to the SVGImage after its creation. This SVGImage is put in the ImageBySizeCache associated with a container size of 30x70.
3704         We now have two SVGImage objects present, one living in CachedImage::m_image, created by createImage() during data decoding, and one living in the ImageBySizeCache
3705         created by lookupOrCreateImageForRenderer() associated with the 30x70 container. The first SVGImage::size() will return a value as defined in the referenced foo.svg,
3706         whereas the SVGImage::size() call of the new SVGImage living in the cache reports 30x70 and renders according to that.
3707
3708         Whenever any method of CachedImage is called with a RenderObject* or IntSize, we can't just operate on m_image anymore but instead have to lookup the right
3709         images for a certain renderer/size from the cache and operate on these. When calling eg. CachedImage::image() with a null renderer, m_image is returned.
3710         When passing with a valid renderer only cache lookups are done if the m_image is actually a SVGImage, otherwhise lookupImageForSize/Renderer will just return the m_image.
3711         There is no logical change induced for non-SVGImage derived images.
3712
3713         CachedImage::image() of course needs a RenderObject* parameter now, to identify which of the images from the cache to use, if the underlying image is a SVGImage.
3714         Luckily these information are already present in StyleCachedImage/StyleImage & friends and only need to be added for some additional methods.
3715         (WebCore::CachedImage::image): FIXME
3716         (WebCore::CachedImage::imageForRenderer): Call lookupOrCreateImageForRenderer() instead of returning m_image, if it's not null. Its a no-op for non SVGImage derived objects.
3717         (WebCore::CachedImage::setContainerSizeForRenderer): For non-SVGImages, just pass on the size to the m_image. For SVGImages, associate the passed in renderer with the IntSize in the cache.
3718                                                              This does NOT create the SVGImage yet, this is delayed until imageForRenderer() is called for a given renderer that wants this size.
3719         (WebCore::CachedImage::imageSize): Don't operate on m_image, ask lookupImageForRenderer() with the incoming renderer.
3720         (WebCore::CachedImage::imageRect): Ditto.
3721         (WebCore::CachedImage::clear): Force clearing the m_svgImageCache.
3722         (WebCore::CachedImage::data): Call m_image->size() instead of imageSize(), to avoid having to pass a null renderer to imageSize() as here no renderer is available yet.
3723         (WebCore::CachedImage::destroyDecodedData): Don't destroy decoded data for SVG images, as m_data needs to be accessable at any time to construct a cloned SVGImage.
3724                                                     In future we don't need this anymore if we make sure multiple SVGImages share the same trees, but that's for a follow-up patch.
3725         (WebCore::CachedImage::decodedSizeChanged): Don't operate on m_image, ask lookupImageForRenderer() with the incoming renderer.
3726         (WebCore::CachedImage::didDraw): Ditto.
3727         (WebCore::CachedImage::shouldPauseAnimation): Ditto.
3728         (WebCore::CachedImage::animationAdvanced): Ditto.
3729         (WebCore::CachedImage::changedInRect): Ditto. (eg. when leaving out this change animated SVG images wouldn't update anymore, as the animation didn't happen on m_image!)
3730         * loader/cache/CachedImage.h: imageForRenderer/canRender/setContainerSizeForRenderer/imageSizeForRenderer now all take a RenderObject* parameter to identifiy the current user of the image.
3731         (WebCore::CachedImage::canRender): Pass on the incoming renderer to imageSizeForRenderer().
3732         * page/DragController.cpp:
3733         (WebCore::getImage): Use new CachedImage::imageForRenderer(RenderObject*) method.
3734         * page/EventHandler.cpp:
3735         (WebCore::EventHandler::selectCursor): Ditto.
3736         * page/PageSerializer.cpp:
3737         (WebCore::PageSerializer::serializeFrame): Ditto.
3738         (WebCore::PageSerializer::addImageToResources): Ditto.
3739         (WebCore::PageSerializer::retrieveResourcesForCSSDeclaration): Ditto.
3740         * page/PageSerializer.h:
3741         * platform/chromium/ClipboardChromium.cpp:
3742         (WebCore::writeImageToDataObject): Ditto.
3743         * platform/chromium/PasteboardChromium.cpp:
3744         (WebCore::Pasteboard::writeImage): Ditto.
3745         * platform/graphics/Image.h:
3746         (WebCore::Image::isSVGImage): Add boolean helper to identify SVGImages, just like isBitmapImage().
3747         * platform/gtk/ClipboardGtk.cpp:
3748         (WebCore::ClipboardGtk::declareAndWriteDragImage): Use new CachedImage::imageForRenderer(RenderObject*) method.
3749         * platform/gtk/PasteboardGtk.cpp:
3750         (WebCore::Pasteboard::writeImage): Ditto.
3751         * platform/mac/HTMLConverter.mm:
3752         (fileWrapperForElement): Ditto.
3753         * platform/mac/PasteboardMac.mm:
3754         (WebCore::Pasteboard::writeImage): Ditto.
3755         * platform/qt/ClipboardQt.cpp:
3756         (WebCore::ClipboardQt::declareAndWriteDragImage): Ditto.
3757         * platform/qt/PasteboardQt.cpp:
3758         (WebCore::Pasteboard::writeImage): Ditto.
3759         * platform/win/ClipboardWin.cpp:
3760         (WebCore::writeImageToDataObject): Ditto.
3761         * platform/win/PasteboardWin.cpp:
3762         (WebCore::Pasteboard::writeImage): Ditto.
3763         * platform/wince/PasteboardWinCE.cpp:
3764         (WebCore::Pasteboard::writeImage): Ditto.
3765         * rendering/HitTestResult.cpp:
3766         (WebCore::HitTestResult::image): Ditto.
3767         * rendering/ImageBySizeCache.cpp: Copied from WebCore/css/CSSImageGeneratorValue.cpp, to preserve history for the original cache code.
3768         (WebCore::ImageBySizeCache::ImageBySizeCache): Straight copy from CSSImageGeneratorValue, renamed to ImageBySizeCache, removing all but the cache relevant code.
3769         (WebCore::ImageBySizeCache::addClient): Ditto.
3770         (WebCore::ImageBySizeCache::removeClient): Ditto.
3771         (WebCore::ImageBySizeCache::getImage): Ditto.
3772         (WebCore::ImageBySizeCache::putImage): Ditto.
3773         (WebCore::ImageBySizeCache::clear): New function, that clears the cache, introduced for the needs of CachedImage.
3774         (WebCore::ImageBySizeCache::imageForSize): New function to query an Image* for a given IntSize, introduced for the needs of CachedImage.
3775         (WebCore::ImageBySizeCache::sizeForClient): New function to query an IntSize for a given renderer.
3776         * rendering/ImageBySizeCache.h: Copied from WebCore/css/CSSImageGeneratorValue.h.
3777         (WebCore::ImageBySizeCache::clients):
3778         * rendering/InlineFlowBox.cpp:
3779         (WebCore::InlineFlowBox::paintFillLayer): CachedImage::canRender() now takes a RenderObject* parameter.
3780         (WebCore::InlineFlowBox::paintBoxDecorations): Ditto.
3781         (WebCore::InlineFlowBox::paintMask): Ditto.
3782         * rendering/RenderBox.cpp:
3783         (WebCore::RenderBox::paintMaskImages): Ditto.
3784         (WebCore::RenderBox::repaintLayerRectsForImage): Ditto.
3785         * rendering/RenderBoxModelObject.cpp:
3786         (WebCore::RenderBoxModelObject::paintFillLayerExtended): Ditto.
3787         (WebCore::RenderBoxModelObject::calculateFillTileSize): Ditto (for CachedImage::setContainerSizeForRenderer()).
3788         (WebCore::RenderBoxModelObject::paintNinePieceImage): Ditto.
3789         * rendering/RenderImage.cpp:
3790         (WebCore::RenderImage::imageSizeForError): Use new CachedImage::imageForRenderer(RenderObject*) method.
3791         (WebCore::RenderImage::setImageSizeForAltText): Ditto.
3792         (WebCore::RenderImage::computeReplacedLogicalWidth): FIXME
3793         * rendering/RenderImageResource.cpp:
3794         (WebCore::RenderImageResource::setContainerSizeForRenderer): Pass on m_renderer to CachedImage::setContainerSizeForRenderer().
3795         * rendering/RenderImageResource.h: Remove constness from setContainerSizeForRenderer.
3796         (WebCore::RenderImageResource::image): Pass on m_renderer to CachedImage::image().
3797         (WebCore::RenderImageResource::imageSize): Pass on m_renderer to CachedImage::imageSizeForRenderer().
3798         * rendering/RenderImageResourceStyleImage.h:
3799         (WebCore::RenderImageResourceStyleImage::setContainerSizeForRenderer): Remove constness, pass on m_renderer to StyleImage::setContainerSizeForRenderer().
3800         * rendering/RenderLayerBacking.cpp:
3801         (WebCore::RenderLayerBacking::isDirectlyCompositedImage): Use new CachedImage::imageForRenderer(RenderObject*) method.
3802         (WebCore::RenderLayerBacking::updateImageContents): Ditto.
3803         * rendering/RenderListMarker.cpp:
3804         (WebCore::RenderListMarker::computePreferredLogicalWidths): CachedImage::setContainerSizeForRenderer() now takes a RenderObject* parameter.
3805         * rendering/RenderObject.cpp:
3806         (WebCore::mustRepaintFillLayers): CachedImage::canRender() now takes a RenderObject* parameter.
3807         (WebCore::RenderObject::borderImageIsLoadedAndCanBeRendered): Ditto.
3808         * rendering/style/StyleCachedImage.cpp:
3809         (WebCore::StyleCachedImage::canRender): Pass on incoming renderer to CachedImage::canRender().
3810         (WebCore::StyleCachedImage::imageSize): Pass on incoming renderer to CachedImage::imageSizeForRenderer().
3811         (WebCore::StyleCachedImage::setContainerSizeForRenderer): Pass on incoming renderer to CachedImage::setContainerSizeForRenderer().
3812         (WebCore::StyleCachedImage::addClient): Remove unneeded return statment in void method.
3813         (WebCore::StyleCachedImage::removeClient): Ditto.
3814         (WebCore::StyleCachedImage::image): Pass on incoming renderer to CachedImage::image().
3815         * rendering/style/StyleCachedImage.h: Add RenderObject* parameter to canRender()/setContainerSizeForRenderer(). image() already has one, that was unused so far.
3816         * rendering/style/StyleGeneratedImage.cpp: Inlined setContainerSizeForRenderer.
3817         * rendering/style/StyleGeneratedImage.h: 
3818         (WebCore::StyleGeneratedImage::setContainerSizeForRenderer): Add RenderObject* parameter.
3819         * rendering/style/StyleImage.h:
3820         (WebCore::StyleImage::canRender): Ditto.
3821         * rendering/style/StylePendingImage.h:
3822         (WebCore::StylePendingImage::setContainerSizeForRenderer): Ditto.
3823         * svg/SVGFEImageElement.cpp:
3824         (WebCore::SVGFEImageElement::build): Use new CachedImage::imageForRenderer(RenderObject*) method.
3825         * svg/graphics/SVGImage.cpp: Cleanup file, the include hack seems not needed anymore.
3826         (WebCore::SVGImage::setContainerSize): s/LayoutSize/IntSize/ to match the code in platform/.
3827         * svg/graphics/SVGImage.h: Ditto.
3828         (WebCore::SVGImage::isSVGImage): Return true.
3829
3830 2011-10-13  Kenichi Ishibashi  <bashi@chromium.org>
3831
3832         [Chromium] Uninitialized read in WebCore::*Font* / HB_GSUB_Select_Feature
3833         https://bugs.webkit.org/show_bug.cgi?id=70087
3834
3835         Reviewed by Kent Tamura.
3836
3837         Initialize local variables in ComplexTextControllerLinux::setupfontFeatures.
3838
3839         No new tests because there is no behavior change. Manually tested with valgrind.
3840
3841         * platform/graphics/chromium/ComplexTextControllerLinux.cpp:
3842         (WebCore::setupFontFeatures):
3843
3844 2011-10-13  Csaba Osztrogonác  <ossy@webkit.org>
3845
3846         [Qt][Win] Unreviewed buildfix after r97433.
3847
3848         * platform/MemoryPressureHandler.h: Add a missing include.
3849
3850 2011-10-13  Adam Barth  <abarth@webkit.org>
3851
3852         Spelling error in v8WebSocket::constructorCallback error
3853         https://bugs.webkit.org/show_bug.cgi?id=63943
3854
3855         Reviewed by Kent Tamura.
3856
3857         Fix typo.
3858
3859         * bindings/v8/custom/V8WebSocketCustom.cpp:
3860         (WebCore::V8WebSocket::constructorCallback):
3861
3862 2011-10-13  Mark Hahnenberg  <mhahnenberg@apple.com>
3863
3864         Rename virtual getConstructData to getConstructDataVirtual
3865         https://bugs.webkit.org/show_bug.cgi?id=69872
3866
3867         Reviewed by Geoffrey Garen.
3868
3869         No new tests.
3870
3871         Renamed virtual getConstructData functions to getConstructDataVirtual to 
3872         avoid conflicts when we add static getConstructData to the MethodTable.
3873
3874         * WebCore.exp.in:
3875         * bindings/js/JSAudioConstructor.cpp:
3876         (WebCore::JSAudioConstructor::getConstructDataVirtual):
3877         * bindings/js/JSAudioConstructor.h:
3878         * bindings/js/JSImageConstructor.cpp:
3879         (WebCore::JSImageConstructor::getConstructDataVirtual):
3880         * bindings/js/JSImageConstructor.h:
3881         * bindings/js/JSOptionConstructor.cpp:
3882         (WebCore::JSOptionConstructor::getConstructDataVirtual):
3883         * bindings/js/JSOptionConstructor.h:
3884         * bindings/js/ScriptFunctionCall.cpp:
3885         (WebCore::ScriptFunctionCall::construct):
3886         * bindings/scripts/CodeGeneratorJS.pm:
3887         (GenerateConstructorDeclaration):
3888         (GenerateConstructorDefinition):
3889         * bindings/scripts/test/JS/JSTestInterface.cpp:
3890         (WebCore::JSTestInterfaceConstructor::getConstructDataVirtual):
3891         * bridge/runtime_object.cpp:
3892         (JSC::Bindings::RuntimeObject::getConstructDataVirtual):
3893         * bridge/runtime_object.h:
3894
3895 2011-10-13  Simon Fraser  <simon.fraser@apple.com>
3896
3897         Remove #include of <QuartzCore/QuartzCore.h> in a widely-used header.
3898
3899         Reviewed by Sam Weinig.
3900
3901         * platform/PlatformScreen.h: Typedef PlatformDisplayID to a uint32_t.
3902         * platform/graphics/DisplayRefreshMonitor.h: Typedef CVDisplayLinkRef as
3903         an opaque type to avoid bringing in QuartzCore.h, and move displayLinkCallback
3904         to the .cpp file since it uses Core Video types.
3905         * platform/graphics/mac/DisplayRefreshMonitorMac.cpp:
3906         (WebCore::displayLinkCallback): Make this a local static function, that
3907         calls a member fuction on the object.
3908         (WebCore::DisplayRefreshMonitor::requestRefreshCallback):
3909         (WebCore::DisplayRefreshMonitor::displayLinkFired):
3910
3911 2011-10-13  Michael Saboff  <msaboff@apple.com>
3912
3913         REGRESSION: High frequency memory warnings cause Safari to hog the CPU doing useless garbage collection
3914         https://bugs.webkit.org/show_bug.cgi?id=69774
3915
3916         Throttle the processing of memory pressure events to no more often than once every 5 seconds.
3917
3918         Reviewed by Geoffrey Garen.
3919
3920         No new tests.
3921
3922         * platform/MemoryPressureHandler.cpp:
3923         (WebCore::MemoryPressureHandler::MemoryPressureHandler):
3924         * platform/MemoryPressureHandler.h:
3925         * platform/mac/MemoryPressureHandlerMac.mm:
3926         (WebCore::MemoryPressureHandler::respondToMemoryPressure):
3927
3928 2011-10-13  Kentaro Hara  <haraken@chromium.org>
3929
3930         Implement an OverflowEvent constructor for V8
3931         https://bugs.webkit.org/show_bug.cgi?id=70017
3932
3933         Reviewed by Adam Barth.
3934
3935         Test: fast/events/constructors/overflow-event-constructor.html
3936
3937         * bindings/v8/custom/V8EventConstructors.cpp: Added an OverflowEvent constructor.
3938         * dom/OverflowEvent.idl: Replaced 'JSCustomConstructor' with 'CustomConstructor'.
3939
3940 2011-10-13  Anantanarayanan G Iyengar  <ananta@chromium.org>
3941
3942         https://bugs.webkit.org/show_bug.cgi?id=70064
3943         
3944         The NPObjectWrapper class used by V8 bindings in Chromium to wrap the window
3945         script object was allocating an instance of itself in the NPAllocate
3946         implementation and returning this pointer. It should be returning a pointer
3947         to the wrapped NPObject structure (NPProxyObject). The member function
3948         getUnderlyingNPObject should return 0 if we fail to find the underlying NPObject
3949         for the call. It was incorrectly returning a pointer to the same NPObject in
3950         this case which could cause recursion. 
3951
3952         Reviewed by Nate Chapin.
3953
3954         No new tests as there is no change in functionality.
3955
3956         * bindings/v8/NPObjectWrapper.cpp:
3957         (WebCore::NPObjectWrapper::getObjectForCall):
3958         (WebCore::NPObjectWrapper::NPAllocate):
3959         * bindings/v8/NPObjectWrapper.h:
3960
3961 2011-10-13  Arthur Hsu  <arthurhsu@chromium.org>
3962
3963         Ensure font loaded before calling Skia to drawPosText in Chrome sandbox
3964         https://bugs.webkit.org/show_bug.cgi?id=69370
3965
3966         Reviewed by James Robinson.
3967
3968         * platform/graphics/chromium/FontChromiumWin.cpp:
3969         (WebCore::Font::drawGlyphs):
3970
3971 2011-10-13  Kentaro Hara  <haraken@chromium.org>
3972
3973         Regarding constructor, replace [ConstructorWith=...] IDL with [CallWith=...] IDL
3974         https://bugs.webkit.org/show_bug.cgi?id=69801
3975
3976         As for constructors, [ConstructorWith=...] has the same meaning as [CallWith=...].
3977         We should deprecate [ConstructorWith=...]. This is a clean-up bug for the bug 65839.
3978
3979         Reviewed by Adam Barth.
3980
3981         No new tests, since no change in behavior.
3982
3983         * bindings/scripts/CodeGeneratorV8.pm: Replaced [ConstructorWith=...] IDL with [CallWith=...] IDL.
3984         (GenerateConstructorCallback):
3985         * bindings/scripts/test/TestInterface.idl: Ditto.
3986         * fileapi/FileReader.idl: Ditto.
3987         * p2p/PeerConnection.idl: Ditto.
3988         * page/EventSource.idl: Ditto.
3989         * workers/Worker.idl: Ditto.
3990
3991 2011-10-13  Kentaro Hara  <haraken@chromium.org>
3992
3993         Constructor should not be called if the object is being constructed inside WebCore
3994         https://bugs.webkit.org/show_bug.cgi?id=70015
3995
3996         Reviewed by Adam Barth.
3997
3998         Summary: A DOM object can be created from the JS context and from the WebCore context.
3999         Constructor should be called if the object is created from the JS context,
4000         but should not be called if the object is created from the WebCore context.
4001
4002         Details:
4003         - Expected behavior when the object is created from the JS context (e.g. "new Event()"):
4004         (1) V8XXXX::constructorCallback() is called.
4005         (2) V8XXXX::constructorCallback() calls XXXX::create().
4006         (3) XXXX::create() creates a C++ object.
4007         (4) V8XXXX::constructorCallback() calls toV8() for the C++ object.
4008         (5) toV8() wraps the C++ object and returns the wrapped JS object.
4009
4010         - Actual behavior when the object is created from the JS context (e.g. "new Event()"):
4011         As described above (1) - (5). That's fine!!
4012
4013         - Expected behavior when the object is created from the WebCore context.
4014         (e.g. "window.addEventListener("load", function (event) { ... });". In this case,
4015         the Event object is created inside the WebCore context):
4016         (1) WebCore calls XXXX::create().
4017         (2) XXXX::create() creates a C++ object.
4018         (3) WebCore calls toV8() for the C++ object.
4019         (4) toV8() wraps the C++ object and returns the wrapped JS object.
4020
4021         - Actual behavior when the object is created from the WebCore context.
4022         (e.g. "window.addEventListener("load", function (event) { ... });"):
4023         (1) WebCore calls XXXX::create().
4024         (2) XXXX::create() creates a C++ object.
4025         (3) WebCore calls toV8() for the C++ object.
4026         (4) toV8() can call XXXX::constructorCallback(). (Whether or not toV8() calls