[chromium] Convert uses of GetDC to HWndDC.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-01-13  David Levin  <levin@chromium.org>
2
3         [chromium] Convert uses of GetDC to HWndDC.
4         https://bugs.webkit.org/show_bug.cgi?id=76290
5
6         Reviewed by Dmitry Titov.
7
8         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
9         (WebCore::createFontIndirectAndGetWinName):
10         (WebCore::fontContainsCharacter):
11         (WebCore::FontCache::getLastResortFallbackFont):
12         (WebCore::FontCache::getTraitsInFamily):
13         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
14         (WebCore::FontPlatformData::scriptFontProperties):
15         * platform/graphics/chromium/FontUtilsChromiumWin.cpp:
16         (WebCore::FontMap::getAscent):
17         (WebCore::FontMap::getSpaceGlyph):
18         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
19         (WebCore::fillBMPGlyphs):
20         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
21         (WebCore::SimpleFontData::platformInit):
22         (WebCore::SimpleFontData::determinePitch):
23         (WebCore::SimpleFontData::platformWidthForGlyph):
24         * platform/graphics/chromium/UniscribeHelper.cpp:
25         (WebCore::UniscribeHelper::EnsureCachedDCCreated):
26         * rendering/RenderThemeChromiumWin.cpp:
27         (WebCore::systemFontSize):
28         (WebCore::pointsToPixels):
29
30 2012-01-23  Joe Thomas  <joethomas@motorola.com>
31
32         https://bugs.webkit.org/show_bug.cgi?id=75799
33         Calling intersectsNode on a detached range should throw.
34
35         INVALID_STATE_ERR exception should be thrown if intersectsNode is called on a detached Range.
36
37         Reviewed by Darin Adler.
38
39         Test: fast/dom/Range/range-intersectsNode-exception.html
40
41         * dom/Range.cpp:
42         (WebCore::Range::intersectsNode): Throwing INVALID_STATE_ERR exception if the range is detached.
43
44 2012-01-23  Daniel Cheng  <dcheng@chromium.org>
45
46         Convert DataTransferItem/DataTransferItemList back into an interface class
47         https://bugs.webkit.org/show_bug.cgi?id=76856
48
49         When Qt implemented the DataTransferItemList, a lot of logic was moved into the shared
50         classes since Chromium/Qt happened to implement it the same way. Now that I want to do some
51         refactoring/cleanup work to better implement DataTransferItemList in Chromium, we won't
52         share the same data anymore so it doesn't make sense to keep that code in a common location.
53
54         Reviewed by David Levin.
55
56         Covered by existing tests.
57
58         * CMakeLists.txt:
59         * GNUmakefile.list.am:
60         * Target.pri:
61         * WebCore.gypi:
62         * WebCore.vcproj/WebCore.vcproj:
63         * WebCore.xcodeproj/project.pbxproj:
64         * dom/DataTransferItem.cpp:
65         * dom/DataTransferItem.h:
66         * dom/DataTransferItemList.cpp: Removed.
67         * dom/DataTransferItemList.h:
68         * platform/chromium/ClipboardChromium.cpp:
69         (WebCore::ClipboardChromium::mayUpdateItems):
70         * platform/chromium/DataTransferItemChromium.cpp:
71         (WebCore::DataTransferItemChromium::create):
72         (WebCore::DataTransferItemChromium::DataTransferItemChromium):
73         (WebCore::DataTransferItemChromium::getAsString):
74         (WebCore::DataTransferItemChromium::getAsFile):
75         (WebCore::DataTransferItemChromium::clipboardChromium):
76         * platform/chromium/DataTransferItemChromium.h:
77         (WebCore::DataTransferItemChromium::kind):
78         (WebCore::DataTransferItemChromium::type):
79         * platform/chromium/DataTransferItemListChromium.cpp:
80         (WebCore::DataTransferItemListChromium::DataTransferItemListChromium):
81         * platform/chromium/DataTransferItemListChromium.h:
82         * platform/qt/DataTransferItemListQt.cpp:
83         (WebCore::DataTransferItemListQt::DataTransferItemListQt):
84         (WebCore::DataTransferItemListQt::length):
85         (WebCore::DataTransferItemListQt::item):
86         (WebCore::DataTransferItemListQt::deleteItem):
87         (WebCore::DataTransferItemListQt::clear):
88         (WebCore::DataTransferItemListQt::add):
89         * platform/qt/DataTransferItemListQt.h:
90         * platform/qt/DataTransferItemQt.cpp:
91         (WebCore::DataTransferItemQt::create):
92         (WebCore::DataTransferItemQt::DataTransferItemQt):
93         (WebCore::DataTransferItemQt::getAsString):
94         (WebCore::DataTransferItemQt::getAsFile):
95         * platform/qt/DataTransferItemQt.h:
96         (WebCore::DataTransferItemQt::kind):
97         (WebCore::DataTransferItemQt::type):
98
99 2012-01-23  Andreas Kling  <awesomekling@apple.com>
100
101         Unreviewed buildfix for ENABLE(MUTATION_OBSERVERS) following r105642.
102
103         * css/CSSMutableStyleDeclaration.cpp:
104
105 2012-01-23  Philip Rogers  <pdr@google.com>
106
107         Update uniteIfNonZero to use isZero.
108         https://bugs.webkit.org/show_bug.cgi?id=76637
109
110         Reviewed by Darin Adler.
111
112         No new tests. (I found no existing codepath that would be affected by
113         this change but I think this change is still valuable in preventing
114         future bugs.)
115
116         * platform/graphics/FloatRect.cpp:
117         (WebCore::FloatRect::uniteIfNonZero):
118
119         The following change is a minor followup to
120         https://bugs.webkit.org/show_bug.cgi?id=76177#c12 and is not directly
121         related to the rest of this patch.
122         * rendering/svg/SVGRenderSupport.cpp:
123         (WebCore::SVGRenderSupport::computeContainerBoundingBoxes):
124
125 2012-01-23  Antti Koivisto  <antti@apple.com>
126
127         Eliminate CSSElementStyleDeclaration
128         https://bugs.webkit.org/show_bug.cgi?id=76848
129
130         Reviewed by Andreas Kling.
131
132         CSSElementStyleDeclaration has little functionality. It can merge with CSSMutableStyleDeclaration simplifying the code.
133         
134         Having an element parent is mutually exclusive with having a css rule parent. We can keep them in a union. This also
135         shrinks all inline style declarations by one pointer.
136
137         * CMakeLists.txt:
138         * GNUmakefile.list.am:
139         * Target.pri:
140         * WebCore.gypi:
141         * WebCore.vcproj/WebCore.vcproj:
142         * WebCore.xcodeproj/project.pbxproj:
143         * bindings/js/JSDOMBinding.h:
144         (WebCore::root):
145         * css/CSSAllInOne.cpp:
146         * css/CSSElementStyleDeclaration.cpp: Removed.
147         * css/CSSElementStyleDeclaration.h: Removed.
148         * css/CSSMutableStyleDeclaration.cpp:
149         (WebCore::CSSMutableStyleDeclaration::setNeedsStyleRecalc):
150         * css/CSSMutableStyleDeclaration.h:
151         (WebCore::CSSMutableStyleDeclaration::createInline):
152         (WebCore::CSSMutableStyleDeclaration::createForSVGFontFaceElement):
153         (WebCore::CSSMutableStyleDeclaration::CSSMutableStyleDeclaration):
154         * css/CSSStyleDeclaration.cpp:
155         (WebCore::CSSStyleDeclaration::CSSStyleDeclaration):
156         (WebCore::CSSStyleDeclaration::parentStyleSheet):
157         
158             Merge the CSSElementStyleDeclaration::styleSheet() logic here.
159         
160         * css/CSSStyleDeclaration.h:
161         (WebCore::CSSStyleDeclaration::parentRule):
162         (WebCore::CSSStyleDeclaration::clearParentRule):
163         (WebCore::CSSStyleDeclaration::parentElement):
164         (WebCore::CSSStyleDeclaration::clearParentElement):
165         * css/CSSStyleRule.cpp:
166         (WebCore::CSSStyleRule::setSelectorText):
167         
168             CSSStyleRule's style declaration can't have isElementStyleDeclaration set, the dead code can be removed.
169             This is asserted in setDeclaration() and again implicitly in the destructor (by clearParentRule()).
170         
171         * dom/StyledElement.cpp:
172         (WebCore::StyledElement::createInlineStyleDecl):
173         (WebCore::StyledElement::destroyInlineStyleDecl):
174         (WebCore::StyledElement::ensureInlineStyleDecl):
175         (WebCore::StyledElement::copyNonAttributeProperties):
176         * dom/StyledElement.h:
177         (WebCore::StyledElement::inlineStyleDecl):
178         * editing/ApplyStyleCommand.cpp:
179         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
180         (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded):
181         * editing/DeleteButtonController.cpp:
182         (WebCore::DeleteButtonController::createDeletionUI):
183         * html/ValidationMessage.cpp:
184         (WebCore::adjustBubblePosition):
185         * html/shadow/MediaControlElements.cpp:
186         (WebCore::MediaControlPanelElement::setPosition):
187         (WebCore::MediaControlPanelElement::resetPosition):
188         (WebCore::MediaControlPanelElement::makeOpaque):
189         (WebCore::MediaControlPanelElement::makeTransparent):
190         * html/shadow/SliderThumbElement.cpp:
191         (WebCore::TrackLimiterElement::create):
192         * svg/SVGFontFaceElement.cpp:
193         (WebCore::SVGFontFaceElement::SVGFontFaceElement):
194
195 2012-01-23  Benjamin Poulain  <bpoulain@apple.com>
196
197         Use OVERRIDE for PopupMenuClient's implementations
198         https://bugs.webkit.org/show_bug.cgi?id=76774
199
200         Reviewed by Darin Adler.
201
202         * rendering/RenderMenuList.h: Also sort the methods to the same
203         order as PopupMenuClient.
204         * rendering/RenderTextControlSingleLine.h:
205
206 2012-01-23  Xianzhu Wang  <wangxianzhu@chromium.org>
207
208         Basic enhancements to StringBuilder
209         https://bugs.webkit.org/show_bug.cgi?id=67081
210
211         These changes are because we explicitly disallowed StringBuilder's
212         copy constructor and assignment operator, and the change of return
213         type of StringBuilder::toString().
214
215         Reviewed by Darin Adler.
216
217         No new tests. All layout tests and unit tests should run as before.
218
219         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
220         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::setUpCookiesForQuickTime):
221         * svg/SVGPathStringBuilder.h:
222         (WebCore::SVGPathStringBuilder::cleanup):
223
224 2012-01-23  W. James MacLean  <wjmaclean@chromium.org>
225
226         [chromium] Add WebSolidColorLayer interface to draw non-textured color layers from Aura.
227         https://bugs.webkit.org/show_bug.cgi?id=75732
228
229         Reviewed by James Robinson.
230
231         Add WebSolidColorLayer to paint solid-color layers without a backing texture.
232
233         Test: unit test for CCSolidColorLayerImpl.
234
235         * WebCore.gypi:
236         * platform/graphics/chromium/SolidColorLayerChromium.cpp: Added.
237         (WebCore::SolidColorLayerChromium::createCCLayerImpl):
238         (WebCore::SolidColorLayerChromium::create):
239         (WebCore::SolidColorLayerChromium::SolidColorLayerChromium):
240         (WebCore::SolidColorLayerChromium::~SolidColorLayerChromium):
241         * platform/graphics/chromium/SolidColorLayerChromium.h: Added.
242         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp: Added.
243         (WebCore::CCSolidColorLayerImpl::CCSolidColorLayerImpl):
244         (WebCore::CCSolidColorLayerImpl::~CCSolidColorLayerImpl):
245         (WebCore::CCSolidColorLayerImpl::quadTransform):
246         (WebCore::CCSolidColorLayerImpl::appendQuads):
247         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h: Added.
248         (WebCore::CCSolidColorLayerImpl::create):
249         (WebCore::CCSolidColorLayerImpl::layerTypeAsString):
250
251 2012-01-23  Antti Koivisto  <antti@apple.com>
252
253         Attempt to fix Qt build.
254     
255         Not reviewed.
256
257         * css/CSSElementStyleDeclaration.cpp:
258         * css/CSSElementStyleDeclaration.h:
259         (WebCore::CSSElementStyleDeclaration::createForSVGFontFaceElement):
260
261 2012-01-23  Andreas Kling  <awesomekling@apple.com>
262
263         Move m_rootEditableElementForSelectionOnMouseDown off of HTMLAnchorElement.
264         <http://webkit.org/b/76833>
265
266         Reviewed by Antti Koivisto.
267
268         Move HTMLAnchorElement::m_rootEditableElementForSelectionOnMouseDown to a rare
269         data-style hashmap, effectively shrinking HTMLAnchorElement by one CPU word.
270
271         The pointer is only used during interactive event handling, so it shouldn't have
272         any noticeable effects on web performance.
273
274         This reduces memory consumption by 256 kB (on 64-bit) when viewing the full
275         HTML5 spec at <http://whatwg.org/c>.
276
277         * html/HTMLAnchorElement.cpp:
278         (WebCore::HTMLAnchorElement::HTMLAnchorElement):
279         (WebCore::HTMLAnchorElement::~HTMLAnchorElement):
280         (WebCore::HTMLAnchorElement::defaultEventHandler):
281         (WebCore::HTMLAnchorElement::treatLinkAsLiveForEventType):
282         (WebCore::rootEditableElementMap):
283         (WebCore::HTMLAnchorElement::rootEditableElementForSelectionOnMouseDown):
284         (WebCore::HTMLAnchorElement::setRootEditableElementForSelectionOnMouseDown):
285         * html/HTMLAnchorElement.h:
286
287 2012-01-23  Antti Koivisto  <antti@apple.com>
288
289         Eliminate CSSElementStyleDeclaration subclasses
290         https://bugs.webkit.org/show_bug.cgi?id=76827
291
292         Reviewed by Andreas Kling.
293
294         CSSInlineStyleDeclaration and FontFaceStyleDeclaration serve no real purpose.
295
296         * GNUmakefile.list.am:
297         * Target.pri:
298         * WebCore.gypi:
299         * WebCore.vcproj/WebCore.vcproj:
300         * WebCore.xcodeproj/project.pbxproj:
301         * css/CSSElementStyleDeclaration.cpp:
302         (WebCore::CSSElementStyleDeclaration::createForSVGFontFaceElement):
303         (WebCore::CSSElementStyleDeclaration::styleSheet):
304         * css/CSSElementStyleDeclaration.h:
305         (WebCore::CSSElementStyleDeclaration::createInline):
306         (WebCore::toCSSElementStyleDeclaration):
307         * css/CSSInlineStyleDeclaration.h: Removed.
308         * css/CSSMutableStyleDeclaration.cpp:
309         * dom/StyledElement.cpp:
310         (WebCore::StyledElement::createInlineStyleDecl):
311         (WebCore::StyledElement::ensureInlineStyleDecl):
312         (WebCore::StyledElement::copyNonAttributeProperties):
313         * dom/StyledElement.h:
314         (WebCore::StyledElement::inlineStyleDecl):
315         * editing/ApplyStyleCommand.cpp:
316         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
317         (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded):
318         * editing/DeleteButtonController.cpp:
319         (WebCore::DeleteButtonController::createDeletionUI):
320         * html/ValidationMessage.cpp:
321         (WebCore::adjustBubblePosition):
322         * html/shadow/MediaControlElements.cpp:
323         (WebCore::MediaControlPanelElement::setPosition):
324         (WebCore::MediaControlPanelElement::resetPosition):
325         (WebCore::MediaControlPanelElement::makeOpaque):
326         (WebCore::MediaControlPanelElement::makeTransparent):
327         * html/shadow/SliderThumbElement.cpp:
328         (WebCore::TrackLimiterElement::create):
329         * svg/SVGFontFaceElement.cpp:
330         (WebCore::SVGFontFaceElement::SVGFontFaceElement):
331
332 2012-01-23  Pavel Feldman  <pfeldman@google.com>
333
334         Not reviewed: annotate inspector's js so that it compiled.
335
336         * inspector/front-end/ElementsTreeOutline.js:
337         * inspector/front-end/TextPrompt.js:
338         (WebInspector.TextPrompt.SuggestBox.prototype.upKeyPressed):
339         (WebInspector.TextPrompt.SuggestBox.prototype.downKeyPressed):
340
341 2012-01-23  Philippe Normand  <pnormand@igalia.com>
342
343         [GStreamer] fix WebAudio build after r105431
344         https://bugs.webkit.org/show_bug.cgi?id=76819
345
346         Reviewed by Martin Robinson.
347
348         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
349         (WebCore::copyGstreamerBuffersToAudioChannel): Use mutableData()
350         when copying.
351         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
352         (webKitWebAudioSrcLoop): Drop constness when setting the buffer
353         data pointer.
354
355 2012-01-23  Pavel Feldman  <pfeldman@google.com>
356
357         Web Inspector: add touch events to the event listeners list.
358         https://bugs.webkit.org/show_bug.cgi?id=76830
359
360         Reviewed by Yury Semikhatsky.
361
362         * English.lproj/localizedStrings.js:
363         * inspector/InjectedScriptSource.js:
364         (.):
365         * inspector/front-end/BreakpointsSidebarPane.js:
366         (WebInspector.EventListenerBreakpointsSidebarPane):
367
368 2012-01-23  Pavel Feldman  <pfeldman@google.com>
369
370         Web Inspector: inspector close button is missing in the dock-to-right mode.
371         https://bugs.webkit.org/show_bug.cgi?id=76829
372
373         Reviewed by Timothy Hatcher.
374
375         * inspector/front-end/inspector.js:
376         (WebInspector.set attached):
377         (WebInspector.get _setCompactMode):
378
379 2012-01-23  Vsevolod Vlasov  <vsevik@chromium.org>
380
381         Web Inspector: IndexedDBModel should keep track of requests sent to the backend.
382         https://bugs.webkit.org/show_bug.cgi?id=76705
383
384         Reviewed by Pavel Feldman.
385
386         * inspector/Inspector.json:
387         * inspector/InspectorIndexedDBAgent.cpp:
388         (WebCore::InspectorIndexedDBAgent::requestDatabaseNamesForFrame):
389         * inspector/InspectorIndexedDBAgent.h:
390         * inspector/front-end/IndexedDBModel.js:
391         (WebInspector.IndexedDBModel):
392         (WebInspector.IndexedDBModel.prototype._frameDetached):
393         (WebInspector.IndexedDBModel.prototype._reset):
394         (WebInspector.IndexedDBModel.prototype._loadDatabaseNamesForFrame):
395         (WebInspector.IndexedDBRequestManager):
396         (WebInspector.IndexedDBRequestManager.prototype.requestDatabaseNamesForFrame.innerCallback):
397         (WebInspector.IndexedDBRequestManager.prototype.requestDatabaseNamesForFrame):
398         (WebInspector.IndexedDBRequestManager.prototype._databaseNamesLoaded):
399         (WebInspector.IndexedDBRequestManager.prototype._requestId):
400         (WebInspector.IndexedDBRequestManager.prototype._frameDetached):
401         (WebInspector.IndexedDBRequestManager.prototype._reset):
402         (WebInspector.IndexedDBRequestManager.DatabasesForFrameRequest):
403         (WebInspector.IndexedDBDispatcher):
404         (WebInspector.IndexedDBDispatcher.prototype.databaseNamesLoaded):
405
406 2012-01-23  Pavel Feldman  <pfeldman@google.com>
407
408         Web Inspector: Inspecting an element inside an iframe no longer works
409         https://bugs.webkit.org/show_bug.cgi?id=76808
410
411         Reviewed by Timothy Hatcher.
412
413         Test: http/tests/inspector/inspect-element.html
414
415         * inspector/InspectorDOMAgent.cpp:
416         (WebCore::InspectorDOMAgent::innerParentNode):
417         * inspector/front-end/DOMAgent.js:
418         (WebInspector.DOMNode.prototype.getChildNodes.mycallback):
419         (WebInspector.DOMNode.prototype.getChildNodes):
420         (WebInspector.DOMNode.prototype._setChildrenPayload):
421         * inspector/front-end/ElementsTreeOutline.js:
422         (WebInspector.ElementsTreeOutline.prototype._selectedNodeChanged):
423
424 2012-01-23  Andrey Kosyakov  <caseq@chromium.org>
425
426         Web Inspector: response.bodySize in HAR is invalid (negative) for cached resources
427         https://bugs.webkit.org/show_bug.cgi?id=76823
428
429         Reviewed by Yury Semikhatsky.
430
431         - fix response.bodySize for cached resources;
432         Also some drive-by fixes:
433         - pretty-print HAR when exported
434         - proper annotation for JSON.stringify()
435         - de-obfuscate a piece of code in TimelinePanel
436
437         * inspector/front-end/HAREntry.js:
438         (WebInspector.HAREntry.prototype.get responseBodySize):
439         * inspector/front-end/NetworkPanel.js:
440         (WebInspector.NetworkLogView.prototype._exportAll):
441         (WebInspector.NetworkLogView.prototype._exportResource):
442
443 2012-01-23  Mario Sanchez Prada  <msanchez@igalia.com>
444
445         [GTK] Refactor GTK's accessibilitity code to be more modular
446         https://bugs.webkit.org/show_bug.cgi?id=76783
447
448         Reviewed by Martin Robinson.
449
450         New files for the implementation of the AtkAction interface,
451         containing the related code from WebKitAccessibleWrapperAtk.cpp.
452
453         * accessibility/gtk/WebKitAccessibleInterfaceAction.cpp: Added.
454         (core):
455         (webkitAccessibleActionInterfaceInit):
456         (webkitAccessibleActionDoAction):
457         (webkitAccessibleActionGetNActions):
458         (webkitAccessibleActionGetDescription):
459         (webkitAccessibleActionGetKeybinding):
460         (webkitAccessibleActionGetName):
461         * accessibility/gtk/WebKitAccessibleInterfaceAction.h: Added.
462
463         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp: Remove code
464         related to the implementation of the AtkAction interface.
465
466         Add new files to build files.
467
468         * GNUmakefile.list.am: Add WebKitAccessibleInterfaceAction.[h|cpp].
469         * WebCore.gypi: Ditto.
470
471 2012-01-23  Nikolas Zimmermann  <nzimmermann@rim.com>
472
473         SVG animation repaint issue with image and dynamic clipPath
474         https://bugs.webkit.org/show_bug.cgi?id=76559
475
476         Reviewed by Zoltan Herczeg.
477
478         Based on patch by Kelly Norton <knorton@google.com>. I extended the patch
479         to correctly handle relative length resolution as well.
480
481         RenderSVGImage doesn't react on setNeedsBoundariesUpdate() calls
482         and thus fails to update its boundaries in some cases.
483
484         The logic is also inconsistent, compared to the other renderers.
485         Fix that properly, by reusing the method used in RenderSVGViewportContainer.
486         Call calculateImageViewport() immediately, after initializing the LayoutRepainter.
487         Previously we resolved the image viewport in RenderSVGImage::updateFromElement. This is
488         wrong, as it queries the frameRect() of the RenderSVGRoot in a state, where the renderer
489         still needs layout, leading to wrong results.
490
491         I turned Kellys manual testcase into a predictable test, see svg/repaint/image-with-clip-path.svg
492         Relative sized image handling is tested in svg/custom/relative-sized-image.xhtml now.
493
494         Tests: svg/custom/relative-sized-image.xhtml
495                svg/repaint/image-with-clip-path.svg
496
497         * rendering/svg/RenderSVGImage.cpp:
498         (WebCore::RenderSVGImage::RenderSVGImage):
499         (WebCore::RenderSVGImage::updateImageViewport):
500         (WebCore::RenderSVGImage::layout):
501         * rendering/svg/RenderSVGImage.h:
502         (WebCore::RenderSVGImage::setNeedsBoundariesUpdate):
503         * svg/SVGImageElement.cpp:
504         (WebCore::SVGImageElement::svgAttributeChanged):
505
506 2012-01-23  Nikolas Zimmermann  <nzimmermann@rim.com>
507
508         <feImage> has problems referencing local elements
509         https://bugs.webkit.org/show_bug.cgi?id=76800
510
511         Reviewed by Zoltan Herczeg.
512
513         <feImage> referencing local elements are currently rendered into an ImageBuffer
514         by SVGFEImageElement, using the local coordinates of the referenced renderer.
515
516         This approach is buggy and should be avoided, by moving the rendering fully
517         into SVGFEImage, which takes care of respecting the correct transformations.
518
519         This fixes <feImage> + local references, which currently breaks two tests in trunk.
520         Covered by existing tests.
521
522         * rendering/svg/RenderSVGResourceFilterPrimitive.cpp:
523         (WebCore::RenderSVGResourceFilterPrimitive::determineFilterPrimitiveSubregion):
524         * svg/SVGFEImageElement.cpp:
525         (WebCore::SVGFEImageElement::build):
526         * svg/graphics/filters/SVGFEImage.cpp:
527         (WebCore::FEImage::FEImage):
528         (WebCore::FEImage::createWithImage):
529         (WebCore::FEImage::createWithIRIReference):
530         (WebCore::FEImage::determineAbsolutePaintRect):
531         (WebCore::FEImage::referencedRenderer):
532         (WebCore::FEImage::platformApplySoftware):
533         (WebCore::FEImage::externalRepresentation):
534         * svg/graphics/filters/SVGFEImage.h:
535         (WebCore::FEImage::~FEImage):
536         * svg/graphics/filters/SVGFilter.h:
537         (WebCore::SVGFilter::absoluteTransform):
538
539 2012-01-23  Nikolas Zimmermann  <nzimmermann@rim.com>
540
541         Not reviewed. Fix Mac build, by exporting a new symbol.
542
543         * WebCore.exp.in:
544
545 2012-01-23  Mario Sanchez Prada  <msanchez@igalia.com>
546
547         [GTK] Refactor GTK's accessibilitity code to be more modular
548         https://bugs.webkit.org/show_bug.cgi?id=76783
549
550         Reviewed by Martin Robinson.
551
552         Move common function returnString() from the wrapper and
553         hyperlink implementations to a new utility file.
554
555         * accessibility/gtk/WebKitAccessibleUtil.cpp: Added.
556         (returnString): Taken from WebKitAccessibleWrapperAtk.cpp and
557         WebKitAccessibleHyperlink.cpp
558         * accessibility/gtk/WebKitAccessibleUtil.h: Added.
559
560         * accessibility/gtk/WebKitAccessibleHyperlink.cpp: Remove local
561         implementation of returnString.
562         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp: Ditto.
563
564         Add new files to build files.
565
566         * GNUmakefile.list.am: Add WebKitAccessibleUtil.[h|cpp].
567         * WebCore.gypi: Ditto.
568
569 2012-01-23  Mario Sanchez Prada  <msanchez@igalia.com>
570
571         [GTK] Refactor GTK's accessibilitity code to be more modular
572         https://bugs.webkit.org/show_bug.cgi?id=76783
573
574         Reviewed by Martin Robinson.
575
576         Fix typo in class struct (parent class field had the wrong type),
577         fix coding style issues and update date in headers.
578
579         * accessibility/gtk/WebKitAccessibleHyperlink.cpp:
580         * accessibility/gtk/WebKitAccessibleHyperlink.h:
581
582 2012-01-23  Mario Sanchez Prada  <msanchez@igalia.com>
583
584         [GTK] Refactor GTK's accessibilitity code to be more modular
585         https://bugs.webkit.org/show_bug.cgi?id=76783
586
587         Reviewed by Martin Robinson.
588
589         Rename WebKitAccessible's public functions to follow WebKit's
590         coding style and update callers.
591
592         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp:
593         (webkitAccessibleNew): Renamed from webkit_accessible_new.
594         (webkitAccessibleGetAccessibilityObject): Likewise.
595         (webkitAccessibleDetach):Likewise.
596         (webkitAccessibleGetFocusedElement): Likewise.
597         * accessibility/gtk/WebKitAccessibleWrapperAtk.h:
598
599         Update calls to WebKitAccessible's public functions.
600
601         * accessibility/gtk/AXObjectCacheAtk.cpp:
602         (WebCore::AXObjectCache::detachWrapper): Update call.
603         (WebCore::AXObjectCache::attachWrapper): Ditto.
604         * accessibility/gtk/WebKitAccessibleHyperlink.cpp:
605         (core): Update call.
606
607 2012-01-19  Kenichi Ishibashi  <bashi@chromium.org>
608
609         WebKit fails IETC composition event types
610         https://bugs.webkit.org/show_bug.cgi?id=76690
611
612         Reviewed by Ryosuke Niwa.
613
614         Dispatches at least one compositionupdate event.
615         The spec(*) says that a composition session includes one or more
616         compositionupdate event(s).
617         Other major browsers (Firefox and IE) don't populate the data attribute
618         of the compositionstart event, but we set the given text in the data
619         attribute to minimize the effect of this change.
620
621         (*) http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#events-compositionevents
622
623         Updated existing test: fast/fast/events/ime-composition-events-001.html.
624
625         * editing/Editor.cpp:
626         (WebCore::Editor::setComposition):
627
628 2012-01-22  Mario Sanchez Prada  <msanchez@igalia.com>
629
630         [GTK] Refactor GTK's accessibilitity code to be more modular
631         https://bugs.webkit.org/show_bug.cgi?id=76783
632
633         Reviewed by Martin Robinson.
634
635         Rename the file for the ATK AccessibilityObject wrapper to be more
636         coherent with the rest of the files in the same directory.
637
638         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp: Renamed from
639         Source/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp.
640         (fallbackObject):
641         (returnString):
642         (core):
643         (webkit_accessible_get_name):
644         (webkit_accessible_get_description):
645         (setAtkRelationSetFromCoreObject):
646         (isRootObject):
647         (atkParentOfRootObject):
648         (webkit_accessible_get_parent):
649         (getNChildrenForTable):
650         (webkit_accessible_get_n_children):
651         (getChildForTable):
652         (webkit_accessible_ref_child):
653         (getIndexInParentForCellInRow):
654         (webkit_accessible_get_index_in_parent):
655         (addAttributeToSet):
656         (webkit_accessible_get_attributes):
657         (atkRole):
658         (webkit_accessible_get_role):
659         (selectionBelongsToObject):
660         (isTextWithCaret):
661         (setAtkStateSetFromCoreObject):
662         (webkit_accessible_ref_state_set):
663         (webkit_accessible_ref_relation_set):
664         (webkit_accessible_init):
665         (webkit_accessible_finalize):
666         (webkit_accessible_class_init):
667         (webkit_accessible_get_type):
668         (webkit_accessible_action_do_action):
669         (webkit_accessible_action_get_n_actions):
670         (webkit_accessible_action_get_description):
671         (webkit_accessible_action_get_keybinding):
672         (webkit_accessible_action_get_name):
673         (atk_action_interface_init):
674         (listObjectForSelection):
675         (optionFromList):
676         (optionFromSelection):
677         (webkit_accessible_selection_add_selection):
678         (webkit_accessible_selection_clear_selection):
679         (webkit_accessible_selection_ref_selection):
680         (webkit_accessible_selection_get_selection_count):
681         (webkit_accessible_selection_is_child_selected):
682         (webkit_accessible_selection_remove_selection):
683         (webkit_accessible_selection_select_all_selection):
684         (atk_selection_interface_init):
685         (utf8Substr):
686         (convertUniCharToUTF8):
687         (textForRenderer):
688         (textForObject):
689         (webkit_accessible_text_get_text):
690         (getGailTextUtilForAtk):
691         (getPangoLayoutForAtk):
692         (webkit_accessible_text_get_text_after_offset):
693         (webkit_accessible_text_get_text_at_offset):
694         (webkit_accessible_text_get_text_before_offset):
695         (webkit_accessible_text_get_character_at_offset):
696         (webkit_accessible_text_get_caret_offset):
697         (baselinePositionForRenderObject):
698         (getAttributeSetForAccessibilityObject):
699         (compareAttribute):
700         (attributeSetDifference):
701         (accessibilityObjectLength):
702         (getAccessibilityObjectForOffset):
703         (getRunAttributesFromAccesibilityObject):
704         (webkit_accessible_text_get_run_attributes):
705         (webkit_accessible_text_get_default_attributes):
706         (textExtents):
707         (webkit_accessible_text_get_character_extents):
708         (webkit_accessible_text_get_range_extents):
709         (webkit_accessible_text_get_character_count):
710         (webkit_accessible_text_get_offset_at_point):
711         (getSelectionOffsetsForObject):
712         (webkit_accessible_text_get_n_selections):
713         (webkit_accessible_text_get_selection):
714         (webkit_accessible_text_add_selection):
715         (webkit_accessible_text_set_selection):
716         (webkit_accessible_text_remove_selection):
717         (webkit_accessible_text_set_caret_offset):
718         (atk_text_interface_init):
719         (webkit_accessible_editable_text_set_run_attributes):
720         (webkit_accessible_editable_text_set_text_contents):
721         (webkit_accessible_editable_text_insert_text):
722         (webkit_accessible_editable_text_copy_text):
723         (webkit_accessible_editable_text_cut_text):
724         (webkit_accessible_editable_text_delete_text):
725         (webkit_accessible_editable_text_paste_text):
726         (atk_editable_text_interface_init):
727         (contentsToAtk):
728         (atkToContents):
729         (webkit_accessible_component_ref_accessible_at_point):
730         (webkit_accessible_component_get_extents):
731         (webkit_accessible_component_grab_focus):
732         (atk_component_interface_init):
733         (webkit_accessible_image_get_image_position):
734         (webkit_accessible_image_get_image_description):
735         (webkit_accessible_image_get_image_size):
736         (atk_image_interface_init):
737         (cell):
738         (cellIndex):
739         (cellAtIndex):
740         (webkit_accessible_table_ref_at):
741         (webkit_accessible_table_get_index_at):
742         (webkit_accessible_table_get_column_at_index):
743         (webkit_accessible_table_get_row_at_index):
744         (webkit_accessible_table_get_n_columns):
745         (webkit_accessible_table_get_n_rows):
746         (webkit_accessible_table_get_column_extent_at):
747         (webkit_accessible_table_get_row_extent_at):
748         (webkit_accessible_table_get_column_header):
749         (webkit_accessible_table_get_row_header):
750         (webkit_accessible_table_get_caption):
751         (webkit_accessible_table_get_column_description):
752         (webkit_accessible_table_get_row_description):
753         (atk_table_interface_init):
754         (webkitAccessibleHypertextGetLink):
755         (webkitAccessibleHypertextGetNLinks):
756         (webkitAccessibleHypertextGetLinkIndex):
757         (atkHypertextInterfaceInit):
758         (webkitAccessibleHyperlinkImplGetHyperlink):
759         (atkHyperlinkImplInterfaceInit):
760         (documentAttributeValue):
761         (webkit_accessible_document_get_attribute_value):
762         (webkit_accessible_document_get_attributes):
763         (webkit_accessible_document_get_locale):
764         (atk_document_interface_init):
765         (webkitAccessibleValueGetCurrentValue):
766         (webkitAccessibleValueGetMaximumValue):
767         (webkitAccessibleValueGetMinimumValue):
768         (webkitAccessibleValueSetCurrentValue):
769         (webkitAccessibleValueGetMinimumIncrement):
770         (atkValueInterfaceInit):
771         (GetAtkInterfaceTypeFromWAIType):
772         (getInterfaceMaskFromObject):
773         (getUniqueAccessibilityTypeName):
774         (getAccessibilityTypeFromObject):
775         (webkit_accessible_new):
776         (webkit_accessible_get_accessibility_object):
777         (webkit_accessible_detach):
778         (webkit_accessible_get_focused_element):
779         (objectFocusedAndCaretOffsetUnignored):
780         * accessibility/gtk/WebKitAccessibleWrapperAtk.h: Renamed from
781         Source/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.h.
782
783         Update the include for the AccessibilityObject wrapper header.
784
785         * accessibility/gtk/AXObjectCacheAtk.cpp: Update include.
786         * accessibility/gtk/WebKitAccessibleHyperlink.cpp: Ditto.
787         * accessibility/gtk/WebKitAccessibleHyperlink.h: Ditto.
788         * editing/gtk/FrameSelectionGtk.cpp:
789
790         Update filename for the ATK wrapper in build files.
791
792         * GNUmakefile.list.am: Updated.
793         * WebCore.gypi: Updated.
794
795 2012-01-20  Pavel Feldman  <pfeldman@google.com>
796
797         Web Inspector: PageAgent.open() dosen't belong to the protocol.
798         https://bugs.webkit.org/show_bug.cgi?id=74790
799
800         Reviewed by Yury Semikhatsky.
801
802         * inspector/Inspector.json:
803         * inspector/InspectorFrontendClient.h:
804         * inspector/InspectorFrontendClientLocal.cpp:
805         (WebCore::InspectorFrontendClientLocal::openInNewTab):
806         * inspector/InspectorFrontendClientLocal.h:
807         * inspector/InspectorFrontendHost.cpp:
808         (WebCore::InspectorFrontendHost::openInNewTab):
809         * inspector/InspectorFrontendHost.h:
810         * inspector/InspectorFrontendHost.idl:
811         * inspector/InspectorPageAgent.cpp:
812         (WebCore::InspectorPageAgent::navigate):
813         * inspector/InspectorPageAgent.h:
814         * inspector/front-end/ImageView.js:
815         (WebInspector.ImageView.prototype._openInNewTab):
816         * inspector/front-end/InspectorFrontendHostStub.js:
817         (.WebInspector.InspectorFrontendHostStub.prototype.openInNewTab):
818         * inspector/front-end/NetworkPanel.js:
819         (WebInspector.NetworkDataGridNode.prototype._openInNewTab):
820         * inspector/front-end/ResourcesPanel.js:
821         (WebInspector.FrameResourceTreeElement.prototype.ondblclick):
822         * inspector/front-end/inspector.js:
823         (WebInspector.openResource):
824
825 2012-01-23  Ilya Tikhonovsky  <loislo@chromium.org>
826
827         Web Inspector: DetailedHeapSnapshot: Replace the list of retainers with the expandable tree (to get rid of cycles)
828         https://bugs.webkit.org/show_bug.cgi?id=76813
829
830         Reviewed by Pavel Feldman.
831
832         * English.lproj/localizedStrings.js:
833         * inspector/front-end/DetailedHeapshotGridNodes.js:
834         (WebInspector.HeapSnapshotObjectNode):
835         * inspector/front-end/DetailedHeapshotView.js:
836         (WebInspector.HeapSnapshotContainmentDataGrid.prototype.setDataSource):
837         (WebInspector.HeapSnapshotRetainmentDataGrid):
838         (WebInspector.HeapSnapshotRetainmentDataGrid.prototype.reset):
839         (WebInspector.DetailedHeapshotView.prototype._startRetainersHeaderDragging):
840         * inspector/front-end/HeapSnapshot.js:
841         (WebInspector.HeapSnapshot.prototype.createRetainingEdgesProvider):
842         (WebInspector.HeapSnapshotEdgesProvider):
843         * inspector/front-end/HeapSnapshotProxy.js:
844         (WebInspector.HeapSnapshotProxy.prototype.createEdgesProvider):
845         (WebInspector.HeapSnapshotProxy.prototype.createRetainingEdgesProvider):
846
847 2012-01-20  Andrey Kosyakov  <caseq@chromium.org>
848
849         Web Inspector: HAR pageref attributes are wrong and inconsistent with pages array
850         https://bugs.webkit.org/show_bug.cgi?id=76398
851
852         Reviewed by Pavel Feldman.
853
854         - introduce a notion of LoadPage;
855         - move page load times to LoadPage;
856         - associate network resources with LoadPage;
857         - export pages for all available resoruces to HAR, not just the last page;
858         - use page ids, not document URLs in HAR entries to refer to pages;
859         - use page URL as a title field of a HAR page;
860
861         * inspector/front-end/AuditsPanel.js:
862         (WebInspector.AuditsPanel):
863         * inspector/front-end/HAREntry.js:
864         (WebInspector.HAREntry.prototype.build):
865         (WebInspector.HAREntry.prototype.get responseCompression):
866         (WebInspector.HARLog.prototype._buildPages):
867         (WebInspector.HARLog.prototype._convertPage):
868         (WebInspector.HARLog.prototype._pageEventTime):
869         * inspector/front-end/NetworkLog.js:
870         (WebInspector.NetworkLog):
871         (WebInspector.NetworkLog.prototype._mainFrameNavigated):
872         (WebInspector.NetworkLog.prototype._onResourceStarted):
873         (WebInspector.Page):
874         (WebInspector.Page.prototype.get id):
875         (WebInspector.Page.prototype.get url):
876         (WebInspector.Page.prototype.get contentLoadTime):
877         (WebInspector.Page.prototype.set contentLoadTime):
878         (WebInspector.Page.prototype.get loadTime):
879         (WebInspector.Page.prototype.set loadTime):
880         (WebInspector.Page.prototype.get startTime):
881         (WebInspector.Page.prototype._bindResource):
882         * inspector/front-end/NetworkManager.js:
883         (WebInspector.NetworkDispatcher.prototype.requestServedFromMemoryCache):
884         * inspector/front-end/Resource.js:
885         (WebInspector.Resource.prototype.get page):
886         (WebInspector.Resource.prototype.set page):
887         * inspector/front-end/ResourceTreeModel.js:
888         (WebInspector.ResourceTreeFrame):
889         (WebInspector.ResourceTreeFrame.prototype.get page):
890         (WebInspector.PageDispatcher.prototype.domContentEventFired):
891         (WebInspector.PageDispatcher.prototype.loadEventFired):
892
893 2012-01-22  Mario Sanchez Prada  <msanchez@igalia.com>
894
895         [GTK] ATK text-caret-moved and text-selection-changed events not being emitted
896         https://bugs.webkit.org/show_bug.cgi?id=76069
897
898         Reviewed by Martin Robinson.
899
900         Fix bug introduced with patch for Bug 72830.
901
902         * accessibility/AccessibilityObject.cpp:
903         (WebCore::AccessibilityObject::isDescendantOfObject): New function,
904         to check if an accessibility object is a descendant of other object.
905         (WebCore::AccessibilityObject::isAncestorOfObject): New function,
906         to check if an accessibility object is an ancestor of other object.
907         * accessibility/AccessibilityObject.h:
908
909         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
910         (webkit_accessible_text_get_caret_offset): Make sure to pass the
911         right reference object to objectFocusedAndCaretOffsetUnignored.
912         (objectFocusedAndCaretOffsetUnignored): Use positionBeforeNode
913         instead of firstPositionInNode for calculating the begining of the
914         range used to calculate the offsets. Ensure that the reference
915         object is never a descendant of the actual object being returned.
916
917         * editing/gtk/FrameSelectionGtk.cpp:
918         (WebCore::FrameSelection::notifyAccessibilityForSelectionChange):
919         Pass the right accessibility object associated with the current
920         selection to objectFocusedAndCaretOffsetUnignored.
921
922 2012-01-21  David Reveman  <reveman@chromium.org>
923
924         [Chromium] Incremental texture updates are not atomic.
925         https://bugs.webkit.org/show_bug.cgi?id=72672
926
927         Reviewed by Adam Barth.
928
929         Use a new set of textures for each commit when incremental
930         texture updates are enabled.
931
932         This patch is tested by the following unit test:
933         - CCLayerTreeHostTestAtomicCommit.runMultiThread
934
935         * platform/graphics/chromium/ManagedTexture.cpp:
936         (WebCore::ManagedTexture::ManagedTexture):
937         (WebCore::ManagedTexture::steal):
938         * platform/graphics/chromium/ManagedTexture.h:
939         * platform/graphics/chromium/TiledLayerChromium.cpp:
940         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
941         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
942         (WebCore::CCLayerTreeHost::initialize):
943         (WebCore::CCLayerTreeHost::commitComplete):
944         (WebCore::CCLayerTreeHost::deleteTextureAfterCommit):
945         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
946         (WebCore::CCSettings::CCSettings):
947         * platform/graphics/chromium/cc/CCProxy.h:
948         * platform/graphics/chromium/cc/CCSingleThreadProxy.h:
949         (WebCore::CCSingleThreadProxy::partialTextureUpdateCapability):
950         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
951         (WebCore::CCThreadProxy::scheduledActionUpdateMoreResources):
952         (WebCore::CCThreadProxy::partialTextureUpdateCapability):
953         * platform/graphics/chromium/cc/CCThreadProxy.h:
954
955 2012-01-21  Pablo Flouret  <pablof@motorola.com>
956
957         Add .url attribute alongside .URL in EventSource and WebSocket to comply with the specs but not break existing usage.
958         https://bugs.webkit.org/show_bug.cgi?id=40899
959
960         Reviewed by Adam Barth.
961
962         Tests: fast/eventsource/eventsource-url-attribute.html
963                http/tests/websocket/tests/hixie76/url-attribute.html
964                http/tests/websocket/tests/hybi/url-attribute.html
965
966         * page/EventSource.idl:
967         * websockets/WebSocket.idl:
968
969 2012-01-21  Sheriff Bot  <webkit.review.bot@gmail.com>
970
971         Unreviewed, rolling out r105564.
972         http://trac.webkit.org/changeset/105564
973         https://bugs.webkit.org/show_bug.cgi?id=76792
974
975         Does not compile on Chromium Mac (Requested by abarth on
976         #webkit).
977
978         * platform/graphics/chromium/ManagedTexture.cpp:
979         * platform/graphics/chromium/ManagedTexture.h:
980         * platform/graphics/chromium/TiledLayerChromium.cpp:
981         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
982         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
983         (WebCore::CCLayerTreeHost::initialize):
984         (WebCore::CCLayerTreeHost::commitComplete):
985         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
986         (WebCore::CCSettings::CCSettings):
987         * platform/graphics/chromium/cc/CCProxy.h:
988         * platform/graphics/chromium/cc/CCSingleThreadProxy.h:
989         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
990         (WebCore::CCThreadProxy::scheduledActionUpdateMoreResources):
991         * platform/graphics/chromium/cc/CCThreadProxy.h:
992
993 2012-01-20  Chris Marrin  <cmarrin@apple.com>
994
995         Implement hardware accelerated Brightness and contrast filters
996         https://bugs.webkit.org/show_bug.cgi?id=75521
997         https://bugs.webkit.org/show_bug.cgi?id=76719
998
999         Reviewed by Simon Fraser.
1000
1001         Implemented hardware accelerated brightness and contrast filters. This also fixes
1002         the bug where grayscale filter was accidentally never getting hardware accelerated.
1003         It also complies with proposed spec changes for the brightness filter to be additive 
1004         rather than multiplicative, according to https://bugs.webkit.org/show_bug.cgi?id=76719. 
1005         Had to make both fixes in the same patch because I had to change the allowed brightness
1006         values for the hardware version, so I had to change the software version as well.
1007
1008         Tests: css3/filters/effect-brightness-hw.html
1009                css3/filters/effect-contrast-hw.html
1010
1011         * css/CSSParser.cpp:
1012         (WebCore::CSSParser::parseBuiltinFilterArguments):
1013         * css/CSSStyleSelector.cpp:
1014         (WebCore::CSSStyleSelector::createFilterOperations):
1015         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1016         (PlatformCALayer::setFilters):
1017         (PlatformCALayer::filtersCanBeComposited):
1018         * rendering/FilterEffectRenderer.cpp:
1019         (WebCore::FilterEffectRenderer::build):
1020
1021 2012-01-21  Nikolas Zimmermann  <nzimmermann@rim.com>
1022
1023         <feImage> ignores preserveAspectRatio="none"
1024         https://bugs.webkit.org/show_bug.cgi?id=76780
1025
1026         Reviewed by Antti Koivisto.
1027
1028         preserveAspectRatio="none" was ignored in SVGFEImage. It always called transformRect() w/o checking
1029         whether it was supposed to transform the rect or not - move code from RenderSVGImage right into
1030         transformRect(), to do nothing if preserveAspectRatio="none" was given.
1031
1032         Test: svg/filters/feImage-preserveAspectratio.svg
1033
1034         * rendering/svg/RenderSVGImage.cpp:
1035         (WebCore::RenderSVGImage::paint):
1036         * svg/SVGPreserveAspectRatio.cpp:
1037         (WebCore::SVGPreserveAspectRatio::transformRect):
1038
1039 2012-01-21  Jochen Eisinger  <jochen@chromium.org>
1040
1041         history.replaceState should update the HistoryItem to use a GET method if previously non-GET (POST)
1042         https://bugs.webkit.org/show_bug.cgi?id=76721
1043
1044         Reviewed by Mihai Parparita.
1045
1046         Tests: http/tests/history/replacestate-post-to-get-2.html
1047                http/tests/history/replacestate-post-to-get.html
1048
1049         * loader/HistoryController.cpp:
1050         (WebCore::HistoryController::replaceState):
1051
1052 2012-01-21  Florin Malita  <fmalita@google.com>
1053
1054         Null dereference in SVGDocumentExtensions::removePendingResource when updating <use>'s href
1055         https://bugs.webkit.org/show_bug.cgi?id=69284
1056
1057         Reviewed by Nikolas Zimmermann.
1058
1059         Test: svg/custom/use-crash-pending-resource.svg
1060
1061         The crash is caused by assumptions in SVGUseElement that xlink:href is the only
1062         pending resource. This patch adds support for dealing with multiple pending resources.
1063
1064         * rendering/svg/RenderSVGResourceContainer.cpp:
1065         (WebCore::RenderSVGResourceContainer::registerResource):
1066         * svg/SVGDocumentExtensions.cpp:
1067         (WebCore::SVGDocumentExtensions::hasPendingResource):
1068         (WebCore::SVGDocumentExtensions::isElementPendingResources):
1069         (WebCore::SVGDocumentExtensions::isElementPendingResource):
1070         (WebCore::SVGDocumentExtensions::removePendingResourceForElement):
1071         * svg/SVGDocumentExtensions.h:
1072         * svg/SVGStyledElement.cpp:
1073         (WebCore::SVGStyledElement::buildPendingResourcesIfNeeded):
1074         (WebCore::SVGStyledElement::clearHasPendingResourcesIfPossible):
1075         Renamed SVGDocumentExtensions::hasPendingResources -> Renamed SVGDocumentExtensions::hasPendingResource.
1076         Renamed SVGDocumentExtensions::isElementInPendingResources -> SVGDocumentExtensions::isElementPendingResources.
1077         Added support for querying and removing pending resources for a specific element.
1078
1079         * svg/SVGUseElement.cpp:
1080         (WebCore::SVGUseElement::svgAttributeChanged):
1081         (WebCore::SVGUseElement::buildPendingResource):
1082         Refactored to support multiple pending resources.
1083
1084 2012-01-21  Stephen Chenney  <schenney@chromium.org>
1085
1086         REGRESSION (Safari 5.0.5 - ToT): crash in SVG test http://dev.w3.org/SVG/profiles/1.1F2/test/harness/htmlObjectApproved/animate-elem-39-t.html
1087         https://bugs.webkit.org/show_bug.cgi?id=64671
1088
1089         Reviewed by Nikolas Zimmermann.
1090
1091         No new tests. This change is to fix crashes in existing tests.
1092
1093         * svg/animation/SVGSMILElement.cpp:
1094         (WebCore::SVGSMILElement::beginListChanged): If the new begin time is
1095         later than the current end time, and the event time is also after then
1096         end time (but we have not yet updated to that time) and the animation
1097         is active, we need to make the animation inactive explicitly.
1098
1099 2012-01-21  Benjamin Poulain  <bpoulain@apple.com>
1100
1101         PopupMenuClient::multiple() should be const
1102         https://bugs.webkit.org/show_bug.cgi?id=76771
1103
1104         Reviewed by Kent Tamura.
1105
1106         * platform/PopupMenuClient.h:
1107         (WebCore::PopupMenuClient::multiple):
1108         * rendering/RenderMenuList.cpp:
1109         (WebCore::RenderMenuList::multiple):
1110         * rendering/RenderMenuList.h:
1111
1112 2012-01-20  Mark Pilgrim  <pilgrim@chromium.org>
1113
1114         Switch indexeddb to use supplemental IDL for DOMWindow
1115         https://bugs.webkit.org/show_bug.cgi?id=76723
1116
1117         Reviewed by Adam Barth.
1118
1119         No new tests required, all existing tests pass.
1120
1121         * Modules/indexeddb: Added.
1122         * Modules/indexeddb/DOMWindowIndexedDatabase.cpp: Added. webkitIndexedDB() method previously in DOMWindow.cpp
1123         (WebCore::DOMWindowIndexedDatabase::DOMWindowIndexedDatabase):
1124         (WebCore::DOMWindowIndexedDatabase::~DOMWindowIndexedDatabase):
1125         (WebCore::DOMWindowIndexedDatabase::webkitIndexedDB):
1126         * Modules/indexeddb/DOMWindowIndexedDatabase.h: Added.
1127         * Modules/indexeddb/DOMWindowIndexedDatabase.idl: Added. attributes previously in DOMWindow.idl
1128         * WebCore.gyp/WebCore.gyp: add Modules/indexeddb/ directory
1129         * WebCore.gypi: add Modules/indexeddb/*
1130         * page/DOMWindow.cpp: remove webkitIndexedDB() method, add accessor methods for m_idbFactory
1131         (WebCore::DOMWindow::getIDBFactory):
1132         (WebCore::DOMWindow::setIDBFactory):
1133         * page/DOMWindow.h:
1134         * page/DOMWindow.idl:
1135
1136 2012-01-20  David Levin  <levin@chromium.org>
1137
1138         Allow isContextThread to be called while in ~ScriptExecutionContext.
1139         https://bugs.webkit.org/show_bug.cgi?id=76756
1140
1141         Reviewed by Adam Barth.
1142
1143         It is possible for objects to get torn down or get called from ~ScriptExecutionContext
1144         and in turn call isContextThread. The resulting behavior is undefined. This change defines
1145         the behavior. I don't know of any places that do this but I have a test that is rarely
1146         failing due to isContextThread being false. This is my best guess as to why, and I
1147         don't see a reason to try to avoid calling isContextThread at this point.
1148
1149         No new functionality exposed so no new tests.
1150
1151         * dom/ScriptExecutionContext.h:
1152         (WebCore::ScriptExecutionContext::isContextThread):
1153
1154 2012-01-20  Alexandre Elias  <aelias@google.com>
1155
1156         [chromium] Write unit tests for compositor-thread zooming
1157         https://bugs.webkit.org/show_bug.cgi?id=71529
1158
1159         Reviewed by James Robinson.
1160
1161         Add unit tests for pinch zoom and page scale animation.  Includes
1162         small cleanups in CCLayerTreeHostImpl for testability.
1163
1164         * platform/graphics/chromium/cc/CCInputHandler.h:
1165         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1166         (WebCore::CCLayerTreeHostImpl::startPageScaleAnimation):
1167         (WebCore::CCLayerTreeHostImpl::setViewportSize):
1168         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
1169
1170 2012-01-20  David Reveman  <reveman@chromium.org>
1171
1172         [Chromium] Incremental texture updates are not atomic.
1173         https://bugs.webkit.org/show_bug.cgi?id=72672
1174
1175         Reviewed by James Robinson.
1176
1177         Use a new set of textures for each commit when incremental
1178         texture updates are enabled.
1179
1180         This patch is tested by the following unit test:
1181         - CCLayerTreeHostTestAtomicCommit.runMultiThread
1182
1183         * platform/graphics/chromium/ManagedTexture.cpp:
1184         (WebCore::ManagedTexture::ManagedTexture):
1185         (WebCore::ManagedTexture::steal):
1186         * platform/graphics/chromium/ManagedTexture.h:
1187         * platform/graphics/chromium/TiledLayerChromium.cpp:
1188         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
1189         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
1190         (WebCore::CCLayerTreeHost::initialize):
1191         (WebCore::CCLayerTreeHost::commitComplete):
1192         (WebCore::CCLayerTreeHost::deleteTextureAfterCommit):
1193         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
1194         (WebCore::CCSettings::CCSettings):
1195         * platform/graphics/chromium/cc/CCProxy.h:
1196         * platform/graphics/chromium/cc/CCSingleThreadProxy.h:
1197         (WebCore::CCSingleThreadProxy::partialTextureUpdateCapability):
1198         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
1199         (WebCore::CCThreadProxy::scheduledActionUpdateMoreResources):
1200         (WebCore::CCThreadProxy::partialTextureUpdateCapability):
1201         * platform/graphics/chromium/cc/CCThreadProxy.h:
1202
1203 2012-01-20  Chris Rogers  <crogers@google.com>
1204
1205         De-zippering incorrectly snaps to target gain
1206         https://bugs.webkit.org/show_bug.cgi?id=76741
1207
1208         Reviewed by Kenneth Russell.
1209
1210         * platform/audio/AudioBus.cpp:
1211
1212 2012-01-20  Dana Jansens  <danakj@chromium.org>
1213
1214         [chromium] Partially filled pixels do not occlude pixels below them.
1215         https://bugs.webkit.org/show_bug.cgi?id=76658
1216
1217         Reviewed by James Robinson.
1218
1219         Test: compositing/culling/tile-occlusion-boundaries.html
1220
1221         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
1222         (WebCore::enclosedIntRect):
1223         (WebCore::CCQuadCuller::cullOccludedQuads):
1224
1225 2012-01-20  Ami Fischman  <fischman@chromium.org>
1226
1227         Small cleanup of {get,put}CurrentFrame for  WebMediaPlayerClientImpl/CCVideoLayerImpl.
1228         https://bugs.webkit.org/show_bug.cgi?id=76332
1229
1230         Reviewed by James Robinson.
1231
1232         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
1233         (WebCore::CCVideoLayerImpl::draw):
1234
1235 2012-01-20  Brady Eidson  <beidson@apple.com>
1236
1237         <rdar://problem/9328684> and https://bugs.webkit.org/show_bug.cgi?id=62764
1238         Frequent crashes due to null frame below ApplicationCacheHost::scheduleLoadFallbackResourceFromApplicationCache
1239
1240         Reviewed by Sam Weinig.
1241
1242         No way to reproduce without special malloc debugging and that doesn't even reproduce on all platforms.  So still no test.
1243
1244         * loader/DocumentLoader.cpp:
1245         (WebCore::DocumentLoader::detachFromFrame): Protect m_frame for the duration of this method.
1246
1247 2012-01-20  Alexey Proskuryakov  <ap@apple.com>
1248
1249         WebCore should not send invalid URLs to client createWindow methods.
1250         https://bugs.webkit.org/show_bug.cgi?id=39017
1251
1252         Unreviewed test fix.
1253
1254         * page/DOMWindow.cpp: (WebCore::DOMWindow::createWindow): Let empty URLs through.
1255
1256 2012-01-20  Sam Weinig  <sam@webkit.org>
1257
1258         Make WebCore RunLoop work for WebKit1
1259         https://bugs.webkit.org/show_bug.cgi?id=76739
1260
1261         Reviewed by Anders Carlsson.
1262
1263         * platform/RunLoop.cpp:
1264         Specialize RunLoop initialization for Mac, where it can happen on any thread.
1265         
1266         * platform/RunLoop.h:
1267         Add RunLoop constructor that takes a CFRunLoopRef on the mac for initializing
1268         the main thread.
1269
1270         * platform/mac/RunLoopMac.mm:
1271         (WebCore::RunLoop::initializeMainRunLoop):
1272         Add new implementation that can work from any thread (and multiple threads at the
1273         same time if necessary).
1274
1275         (WebCore::RunLoop::current):
1276         Treat the main thread specially, not storing it in thread specific data.
1277
1278         (WebCore::RunLoop::main):
1279         Copy main accessor since it needs access to the file static.
1280
1281         (WebCore::RunLoop::RunLoop):
1282         Add constructor which takes a CFRunLoopRef.
1283
1284 2012-01-20  Tim Horton  <timothy_horton@apple.com>
1285
1286         Crash in RenderSVGResourceContainer::markAllClientsForInvalidation
1287         https://bugs.webkit.org/show_bug.cgi?id=76606
1288         <rdar://problem/10720970>
1289
1290         Reviewed by Dirk Schulze.
1291
1292         Notify SVGResourcesCache and superclass when RenderSVGInline is about
1293         to be destroyed, preventing a crash.
1294
1295         Test: svg/custom/crash-inline-container-client.html
1296
1297         * rendering/svg/RenderSVGInline.cpp:
1298         (WebCore::RenderSVGInline::willBeDestroyed):
1299         * rendering/svg/RenderSVGInline.h:
1300
1301 2012-01-20  Alexey Proskuryakov  <ap@apple.com>
1302
1303         WebCore should not send invalid URLs to client createWindow methods.
1304         https://bugs.webkit.org/show_bug.cgi?id=39017
1305
1306         Reviewed by Sam Weinig.
1307
1308         Test: fast/dom/window/open-invalid-url.html
1309
1310         * page/DOMWindow.cpp: (WebCore::DOMWindow::createWindow): Bail out early for invalid URLs.
1311
1312 2012-01-20  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1313
1314         Remove unused variable in RenderReplaced after r105513
1315         https://bugs.webkit.org/show_bug.cgi?id=76742
1316
1317         Reviewed by Daniel Bates.
1318
1319         * rendering/RenderReplaced.cpp:
1320         (WebCore::RenderReplaced::computeReplacedLogicalWidth):
1321         (WebCore::RenderReplaced::computeReplacedLogicalHeight):
1322
1323 2012-01-20  Jonathan Backer  <backer@chromium.org>
1324
1325         [chromium] Plumb damage from accelerated canvas 2D.
1326         https://bugs.webkit.org/show_bug.cgi?id=76728
1327
1328         Reviewed by Kenneth Russell.
1329
1330         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
1331         (WebCore::Canvas2DLayerChromium::contentChanged):
1332
1333 2012-01-20  Julien Chaffraix  <jchaffraix@webkit.org>
1334
1335         Crash in RenderTable::borderBefore
1336         https://bugs.webkit.org/show_bug.cgi?id=75215
1337
1338         Reviewed by David Hyatt.
1339
1340         Test: fast/table/crash-beforeBorder-dirty-section.html
1341
1342         This is a regression from r97661 that added some calls to get the object's borders but tables are a
1343         special case and they may need to recompute some sections' pointers.
1344
1345         The whole sections' pointers lazy recomputation logic is unfortunately far from being bullet proof and
1346         this change is only a mitigation for the current crash.
1347
1348         * rendering/RenderTable.cpp:
1349         (WebCore::RenderTable::borderBefore):
1350         (WebCore::RenderTable::borderAfter):
1351         Make sure we recompute our sections. The change was made here to avoid hitting the
1352         path used inside the table code (ie outerBorder{Before|After}) that shouldn't be
1353         affected.
1354
1355         * rendering/RenderTable.h:
1356         (WebCore::RenderTable::topSection):
1357         Added an ASSERT to catch more bad use in the future.
1358
1359 2012-01-20  Marc-Andre Decoste  <mad@chromium.org>
1360
1361         Add proper offset to position right click to simulate a context menu invocation.
1362         https://bugs.webkit.org/show_bug.cgi?id=76421
1363
1364         Reviewed by Ojan Vafai.
1365
1366         Manual tests only because DRT doesn't support context menu key.
1367
1368         * page/EventHandler.cpp:
1369         (WebCore::EventHandler::sendContextMenuEventForKey):
1370
1371 2012-01-20  Sheriff Bot  <webkit.review.bot@gmail.com>
1372
1373         Unreviewed, rolling out r105426.
1374         http://trac.webkit.org/changeset/105426
1375         https://bugs.webkit.org/show_bug.cgi?id=76726
1376
1377         Might have caused a 20% regression in the PLT (Requested by
1378         abarth|gardener on #webkit).
1379
1380         * rendering/RenderObject.h:
1381         (WebCore::RenderObject::style):
1382
1383 2012-01-20  Sadrul Habib Chowdhury  <sadrul@chromium.org>
1384
1385         [chromium] Revert a couple of changes in fileapi/ that break tests in chromeos.
1386         https://bugs.webkit.org/show_bug.cgi?id=76718
1387
1388         Reviewed by Darin Fisher.
1389
1390         * fileapi/BlobURL.cpp:
1391         (WebCore::BlobURL::getIdentifier):
1392         (WebCore::BlobURL::createBlobURL):
1393         * fileapi/BlobURL.h:
1394         (WebCore::BlobURL::blobProtocol):
1395         * fileapi/DOMFileSystemBase.cpp:
1396         (WebCore::DOMFileSystemBase::crackFileSystemURL):
1397         * fileapi/DOMFileSystemBase.h:
1398         * fileapi/EntryBase.cpp:
1399         (WebCore::EntryBase::toURL):
1400         * fileapi/FileWriter.cpp:
1401         (WebCore::FileWriter::write):
1402         (WebCore::FileWriter::truncate):
1403         * page/DOMWindow.cpp:
1404         (WebCore::DOMWindow::webkitRequestFileSystem):
1405         * page/DOMWindow.h:
1406         * platform/AsyncFileSystem.cpp:
1407         * platform/AsyncFileSystem.h:
1408         * workers/WorkerContext.cpp:
1409         (WebCore::WorkerContext::webkitRequestFileSystem):
1410         (WebCore::WorkerContext::webkitRequestFileSystemSync):
1411
1412 2012-01-20  Tim Dresser  <tdresser@chromium.org>
1413
1414         Refactor canvas drawing to be more data driven
1415         https://bugs.webkit.org/show_bug.cgi?id=76635
1416
1417         CCCanvasLayerImpl no longer handles drawing itself, but produces a list of CCCanvasDrawQuads.
1418         These quads are then drawn by LayerRendererChromium.
1419
1420         This is a refactor, so no new tests were added.
1421
1422         Reviewed by James Robinson.
1423
1424         * platform/graphics/chromium/LayerRendererChromium.cpp:
1425         (WebCore::LayerRendererChromium::drawCanvasQuad):
1426         * platform/graphics/chromium/cc/CCCanvasDrawQuad.cpp:
1427         (WebCore::CCCanvasDrawQuad::create):
1428         (WebCore::CCCanvasDrawQuad::CCCanvasDrawQuad):
1429         * platform/graphics/chromium/cc/CCCanvasDrawQuad.h:
1430         (WebCore::CCCanvasDrawQuad::textureId):
1431         (WebCore::CCCanvasDrawQuad::hasAlpha):
1432         (WebCore::CCCanvasDrawQuad::premultipliedAlpha):
1433         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp:
1434         (WebCore::CCCanvasLayerImpl::appendQuads):
1435         * platform/graphics/chromium/cc/CCCanvasLayerImpl.h:
1436
1437 2012-01-19  Abhishek Arya  <inferno@chromium.org>
1438
1439         Crash in xsltParseGlobalVariable.
1440         https://bugs.webkit.org/show_bug.cgi?id=75978
1441
1442         Reviewed by Andreas Kling.
1443
1444         The code missed to reset the stylesheet pointer after we fail
1445         to compile the XSLT stylesheet. As a result, the stylesheet gets
1446         reused with a removed document in the next transformToFragment call.
1447
1448         Test: fast/xsl/xslt-transform-to-fragment-crash.html
1449
1450         * xml/XSLTProcessorLibxslt.cpp:
1451         (WebCore::XSLTProcessor::transformToString):
1452
1453 2012-01-20  Nikolas Zimmermann  <nzimmermann@rim.com>
1454
1455         REGRESSION (r98852): apple.com navigation bar is broken under full-page zoom
1456         https://bugs.webkit.org/show_bug.cgi?id=76249
1457
1458         Reviewed by Andreas Kling.
1459
1460         Fix regression with full-page zoom & border-image. paintNinePieceImage() expects local, unzoomed coordinates.
1461         Restore the behaviour as it was before r98852, fixing the regression.
1462
1463         Test: fast/borders/scaled-border-image.html
1464
1465         * rendering/RenderBoxModelObject.cpp:
1466         (WebCore::RenderBoxModelObject::paintNinePieceImage):
1467
1468 2012-01-20  Mihnea Ovidenie  <mihnea@adobe.com>
1469
1470         [CSSRegion]Expose DOM interface for WebKitCSSRegionRule
1471         https://bugs.webkit.org/show_bug.cgi?id=73985
1472
1473         Reviewed by Antti Koivisto.
1474
1475         Start by exposing the interface and the cssRules attribute of type CSSRuleList.
1476         Test: fast/regions/webkit-region-rule.html
1477
1478         * CMakeLists.txt:
1479         * DerivedSources.cpp:
1480         * DerivedSources.make:
1481         * DerivedSources.pri:
1482         * GNUmakefile.list.am:
1483         * WebCore.gypi:
1484         * WebCore.vcproj/WebCore.vcproj:
1485         * WebCore.xcodeproj/project.pbxproj:
1486         * bindings/js/JSCSSRuleCustom.cpp:
1487         (WebCore::toJS):
1488         * bindings/objc/DOMCSS.mm:
1489         (kitClass):
1490         * bindings/v8/custom/V8CSSRuleCustom.cpp:
1491         (WebCore::toV8):
1492         * css/WebKitCSSRegionRule.cpp:
1493         * css/WebKitCSSRegionRule.h:
1494         * css/WebKitCSSRegionRule.idl:
1495         * page/DOMWindow.idl:
1496
1497 2012-01-20  Nikolas Zimmermann  <nzimmermann@rim.com>
1498
1499         Differentiate between SVG/CSS width/height attributes/properties
1500         https://bugs.webkit.org/show_bug.cgi?id=76447
1501
1502         Reviewed by Antti Koivisto.
1503
1504         Remove a gazillion of hacks out of our SVG implementation, by correctly differentiating between the
1505         SVG width/height attributes and the CSS width/height properties. They need to be treated independently
1506         when handling the intrinsic size negotiation, according to both CSS 2.1 & SVG 1.1 2nd Edition specs.
1507
1508         Fixes several bugs in the LayoutTests/svg/custom/*object*sizing tests, we now match Opera perfectly. FF still has some bugs, and IE9 as well.
1509
1510         * css/svg.css: Remove hardcoded, width/height: 100% on <svg>.
1511         * rendering/RenderBox.h:
1512         (WebCore::RenderBox::computeIntrinsicRatioInformation): Make 'intrinsicRatio' a float, and add 'intrinsicSize' as seperated FloatSize, to avoid confusion.
1513         * rendering/RenderBoxModelObject.cpp:
1514         (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions): Add forgotton case for percentage intrinsic sizes, that lead to workarounds in other places, that can now be removed.
1515         * rendering/RenderImage.cpp:
1516         (WebCore::RenderImage::computeReplacedLogicalWidth): Directly use imageHasRelativeWidth/Height(), it does differentiate between SVG/CSS width/height attributes/properties now.
1517         (WebCore::RenderImage::computeIntrinsicRatioInformation): Adapt to 'intrinsicRatio' argument change.
1518         * rendering/RenderImage.h: Ditto.
1519         * rendering/RenderReplaced.cpp: Refactor existing code, break out firstContainingBlockWithLogicalWidth/hasReplacedLogicalWidth/hasReplacedLogicalHeight/hasAutoHeightOrContainingBlockWithAutoHeight.
1520         (WebCore::firstContainingBlockWithLogicalWidth): Refactored.
1521         (WebCore::RenderReplaced::hasReplacedLogicalWidth): Refactored, and exported, so SVGSVGElement::widthAttributeEstablishesViewport() can use it.
1522         (WebCore::hasAutoHeightOrContainingBlockWithAutoHeight): Refactored.
1523         (WebCore::RenderReplaced::hasReplacedLogicalHeight): Refactored, and exported, so SVGSVGElement::heightAttributeEstablishesViewport() can use it.
1524         (WebCore::RenderReplaced::computeReplacedLogicalWidth): Adapt to 'intrinsicRatio' changes ('intrinsicSize' is now decoupled from it). Refactor so that RenderSVGRoot can directly use it as well!
1525         (WebCore::RenderReplaced::computeReplacedLogicalHeight): Ditto.
1526         * rendering/RenderReplaced.h:
1527         * rendering/svg/RenderSVGRoot.cpp:
1528         (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation): Only determine the intrinsic size & ratio using the SVG width/height attributes, not the CSS width/height properties, as it's specified.
1529         (WebCore::resolveLengthAttributeForSVG): Helper function for computeReplacedLogicalWidth/Height, that scales Length values that come from SVG width/height attributes.
1530         (WebCore::RenderSVGRoot::computeReplacedLogicalWidth): Finally remove home-brewn size computation logic - it can be fully shared with RenderReplaced now that we inherit from it.
1531         (WebCore::RenderSVGRoot::computeReplacedLogicalHeight): Ditto.
1532         * rendering/svg/RenderSVGRoot.h:
1533         * rendering/svg/RenderSVGViewportContainer.h:
1534         (WebCore::RenderSVGViewportContainer::viewport): Export viewport() for easier length resolution.
1535         * svg/SVGLengthContext.cpp:
1536         (WebCore::SVGLengthContext::determineViewport): Finally clean up this hell, and make it easy to understand. Only need to resolve lengths against either RenderSVGRoot or RenderSVGViewportContainer now.
1537         * svg/SVGSVGElement.cpp: 
1538         (WebCore::SVGSVGElement::viewport): Remove wrong code and disable this. Its not used, and we have no test coverage for it. Its current implementation didn't make any sense.
1539         (WebCore::SVGSVGElement::parseMappedAttribute): Remove hacks mapping SVG width/height attributes to CSS properties.
1540         (WebCore::SVGSVGElement::svgAttributeChanged): Ditto.
1541         (WebCore::SVGSVGElement::localCoordinateSpaceTransform): Refactored.
1542         (WebCore::SVGSVGElement::currentViewBoxRect): Ditto.
1543         (WebCore::SVGSVGElement::currentViewportSize): Ditto.
1544         (WebCore::SVGSVGElement::widthAttributeEstablishesViewport): Main logic determining if the SVG or CSS properties establish the viewport -  a direct transliteration from the spec.
1545         (WebCore::SVGSVGElement::heightAttributeEstablishesViewport): Ditto.
1546         (WebCore::SVGSVGElement::intrinsicWidth): Helper.
1547         (WebCore::SVGSVGElement::intrinsicHeight): Ditto.
1548         * svg/SVGSVGElement.h:
1549         * svg/graphics/SVGImage.cpp:
1550         (WebCore::SVGImage::size): Cleanup code.
1551         (WebCore::SVGImage::hasRelativeWidth): Added, avoids hacks in RenderBoxModelObject.
1552         (WebCore::SVGImage::hasRelativeHeight): Ditto.
1553         (WebCore::SVGImage::computeIntrinsicDimensions): Make use of new SVGSVGElement::computeIntrinsicDimensions.
1554         * svg/graphics/SVGImage.h:
1555
1556 2012-01-20  Sami Kyostila  <skyostil@chromium.org>
1557
1558         window.innerWidth/Height should not include page scale
1559         https://bugs.webkit.org/show_bug.cgi?id=76555
1560
1561         The DOM attributes window.innerWidth and window.innerHeight should be in
1562         CSS pixels instead of device pixels. Currently the text zoom factor is
1563         cancelled out when calculating these values, but the same also needs to
1564         be done for the page scale.
1565
1566         There is an additional subtlety concerning frames/iframes since their
1567         visible content rectangle is already in (unscaled) CSS pixels. By using
1568         Frame::frameScaleFactor() we avoid unnecessarily cancelling out the page
1569         scale factor in this case.
1570
1571         Reviewed by Kenneth Rohde Christiansen.
1572
1573         Tests: fast/dom/iframe-inner-size-scaling.html
1574                fast/dom/window-inner-size-scaling.html
1575
1576         * page/DOMWindow.cpp:
1577         (WebCore::DOMWindow::innerHeight):
1578         (WebCore::DOMWindow::innerWidth):
1579
1580 2012-01-20  Kinuko Yasuda  <kinuko@chromium.org>
1581
1582         Add DataTransferItems support for drag-and-drop'ed files and texts
1583         https://bugs.webkit.org/show_bug.cgi?id=76367
1584
1585         Reviewed by Tony Chang.
1586
1587         Per http://www.whatwg.org/specs/web-apps/current-work/multipage/dnd.html#the-datatransfer-interface
1588         the new interface should also support drag-and-dropped files and texts in
1589         addition to pasted texts/images.  The user apps should also be able to add
1590         texts/files to the drag store by calling event.dataTransfer.items.add().
1591
1592         This patch adds drag-and-drop'ed items support in DataTransferItem and
1593         DataTransferItemList so that they work for dropped files and texts (as well as
1594         the copy-pasted texts/images).
1595
1596         This patch also adds customized toJS()/toV8() code to Blob/File javascript
1597         binding so that the JS code can get either Blob or File underlying object
1598         where the API returns Blob. This change is necessary since we return Blob
1599         from DataTransferItem.getAsFile() for pasted images but want to return File
1600         for dropped files.
1601
1602         Tests: editing/pasteboard/data-transfer-items-drag-drop-file.html
1603                editing/pasteboard/data-transfer-items-drag-drop-string.html
1604
1605         * GNUmakefile.list.am: Added entries for the new {JS,V8}BlobCustom.
1606         * Target.pri: Ditto.
1607         * UseJSC.cmake: Ditto.
1608         * WebCore.gypi: Ditto.
1609         * bindings/js/JSBindingsAllInOne.cpp: Ditto.
1610         * bindings/js/JSBlobCustom.cpp: Added toJS custom code that returns File or
1611         Blob depending on the return value of isFile().
1612         (WebCore::toJS):
1613         * bindings/v8/custom/V8BlobCustom.cpp: Added toV8 custom code.
1614         (WebCore::toV8):
1615         * dom/DataTransferItem.h: Added a new create() method which takes File.
1616         * dom/DataTransferItemList.cpp: Added add(File) method.
1617         (WebCore::DataTransferItemList::add):
1618         * dom/DataTransferItemList.h: Ditto.
1619         * dom/DataTransferItemList.idl: Ditto.
1620         * fileapi/Blob.idl: Added CustomToJS for toJS/toV8.
1621         * platform/chromium/ClipboardChromium.cpp: Added code for drag-and-drop'ed items.
1622         (WebCore::ClipboardChromium::items): Revised.
1623         (WebCore::ClipboardChromium::mayUpdateItems): Added.
1624         (WebCore::ClipboardChromium::isStorageUpdated): Added.
1625         * platform/chromium/ClipboardChromium.h:
1626         * platform/chromium/DataTransferItemChromium.cpp: Added a new constructor that
1627         takes File and updated getAsFile() to make it support dropped files.
1628         (WebCore::DataTransferItem::create):
1629         (WebCore::DataTransferItemChromium::DataTransferItemChromium):
1630         (WebCore::DataTransferItemChromium::getAsFile):
1631         * platform/chromium/DataTransferItemChromium.h:
1632         * platform/chromium/DataTransferItemListChromium.cpp:
1633         (WebCore::DataTransferItemListChromium::addInternalItem):
1634         * platform/chromium/DataTransferItemListChromium.cpp: Added overrides implementation for m_item accessors to make them reflect the changes in the owner clipboard.
1635         (WebCore::DataTransferItemListChromium::length):
1636         (WebCore::DataTransferItemListChromium::item):
1637         (WebCore::DataTransferItemListChromium::deleteItem):
1638         (WebCore::DataTransferItemListChromium::clear):
1639         (WebCore::DataTransferItemListChromium::add):
1640         (WebCore::DataTransferItemListChromium::mayUpdateItems): Added.
1641         * platform/qt/DataTransferItemQt.cpp: Added a new constructor that takes File and updated
1642         getAsFile() to make it support dropped files.
1643         (WebCore::DataTransferItem::create):
1644         (WebCore::DataTransferItemQt::DataTransferItemQt):
1645         (WebCore::DataTransferItemQt::getAsFile):
1646         * platform/qt/DataTransferItemQt.h:
1647
1648 2012-01-20  Alexis Menard  <alexis.menard@openbossa.org>
1649
1650         remove CSSBorderImageValue
1651         https://bugs.webkit.org/show_bug.cgi?id=75563
1652
1653         Reviewed by Tony Chang.
1654
1655         Remove CSSBorderImageValue as border-image is a shorthand therefore we don't
1656         need a dedicated CSS class type for it. CSSBorderImageValue was here for
1657         -webkit-border-image which is not a shorthand. This is the first step to move border-image
1658         close to a correct shorthand implementation while keeping -webkit-border-image being a regular
1659         CSS property.
1660
1661         No new tests : It's a refactor, existing tests should cover it.
1662
1663         * CMakeLists.txt:
1664         * GNUmakefile.list.am:
1665         * Target.pri:
1666         * WebCore.gypi:
1667         * WebCore.order:
1668         * WebCore.vcproj/WebCore.vcproj:
1669         * WebCore.xcodeproj/project.pbxproj:
1670         * css/CSSAllInOne.cpp:
1671         * css/CSSBorderImage.cpp: Added.
1672         (WebCore::createBorderImageValue):
1673         * css/CSSBorderImage.h: Added.
1674         * css/CSSBorderImageValue.cpp: Removed.
1675         * css/CSSBorderImageValue.h: Removed.
1676         * css/CSSComputedStyleDeclaration.cpp:
1677         (WebCore::valueForNinePieceImage):
1678         * css/CSSParser.cpp:
1679         (WebCore::BorderImageParseContext::commitBorderImage):
1680         * css/CSSStyleSelector.cpp:
1681         (WebCore::CSSStyleSelector::mapNinePieceImage):
1682         * css/CSSValue.cpp:
1683         (WebCore::CSSValue::addSubresourceStyleURLs):
1684         (WebCore::CSSValue::cssText):
1685         (WebCore::CSSValue::destroy):
1686         * css/CSSValue.h:
1687
1688 2012-01-20  Hayato Ito  <hayato@chromium.org>
1689
1690         Add ShadowRoot.idl which is enabled by newly introduced SHADOW_DOM flag.
1691         https://bugs.webkit.org/show_bug.cgi?id=76353
1692
1693         Reviewed by Hajime Morita.
1694
1695         Add ShadowRoot.idl, which is enabled only on chromium port since this is
1696         under development feature.
1697         ShadowRoot.idl contains minimum API so that we can test it.
1698         Other APIs should be added on other changes so that we can isolate issues.
1699
1700         Test: fast/dom/shadow/shadow-root-js-api.html
1701
1702         * WebCore.gypi:
1703         * bindings/generic/RuntimeEnabledFeatures.cpp:
1704         * bindings/generic/RuntimeEnabledFeatures.h:
1705         (WebCore::RuntimeEnabledFeatures::shadowDOMEnabled):
1706         (WebCore::RuntimeEnabledFeatures::setShadowDOMEnabled):
1707         * dom/ShadowRoot.h:
1708         (WebCore::ShadowRoot::host):
1709         * dom/ShadowRoot.idl: Added.
1710         * testing/Internals.cpp:
1711         (WebCore::Internals::ensureShadowRoot):
1712         (WebCore::Internals::shadowRoot):
1713         * testing/Internals.h:
1714         * testing/Internals.idl:
1715
1716 2012-01-19  Kent Tamura  <tkent@chromium.org>
1717
1718         Change LocalizedNumber interface
1719         https://bugs.webkit.org/show_bug.cgi?id=76613
1720
1721         Reviewed by Hajime Morita.
1722
1723         Change the functions of LocalizedNumber from:
1724           double parseLocalizedNumber(const String&);
1725           String formatLocalizedNumber(double, unsigned fractionDigits);
1726         To:
1727           String convertToLocalizedNumber(const String&, usnigned fractionDigits);
1728           String convertFromLocalizedNumber(const String&);
1729         in order that we can avoid conversion from/to a double value.
1730
1731         The fractionDigits argumetn of convertToLocalizedNumber() will be
1732         removed in the future.  We need it because we'd like to recycle the old
1733         functions to implement new functions for now and functions in
1734         LocalizedNumber can't call functions in HTMLParserIdioms.cpp.
1735
1736         No new tests because the change doesn't make any behavior change.
1737
1738         * html/NumberInputType.cpp:
1739         (WebCore::NumberInputType::visibleValue):
1740         Use convertToLocalizedNumber.
1741         (WebCore::NumberInputType::convertFromVisibleValue):
1742         Use convertFromLocalizedNumber.
1743         (WebCore::NumberInputType::isAcceptableValue): ditto.
1744         * platform/text/LocalizedNumber.h:
1745         Remove parseLocalizedNumber and formatLocalizedNumber, and
1746         introduce convertToLocalizedNumber and convertFromLocalizedNumber.
1747         * platform/text/LocalizedNumberICU.cpp:
1748         (WebCore::parseLocalizedNumber): Make this static.
1749         (WebCore::formatLocalizedNumber): Make this static.
1750         (WebCore::convertToLocalizedNumber): Implement this with formatLocalizedNumber.
1751         (WebCore::convertFromLocalizedNumber): Implement this with parseLocalizedNumber.
1752         * platform/text/LocalizedNumberNone.cpp:
1753         (WebCore::convertToLocalizedNumber):
1754         Implement this as a function returning the input string.
1755         (WebCore::convertFromLocalizedNumber): ditto.
1756         * platform/text/mac/LocalizedNumberMac.mm:
1757         (WebCore::parseLocalizedNumber): Make this static.
1758         (WebCore::formatLocalizedNumber): Make this static.
1759         (WebCore::convertToLocalizedNumber): Implement this with formatLocalizedNumber.
1760         (WebCore::convertFromLocalizedNumber): Implement this with parseLocalizedNumber.
1761
1762 2012-01-19  Pavel Feldman  <pfeldman@google.com>
1763
1764         Web Inspector: problem with Ctrl - <arrows> shortcuts in Scripts panel
1765         https://bugs.webkit.org/show_bug.cgi?id=76622
1766
1767         Reviewed by Yury Semikhatsky.
1768
1769         * inspector/front-end/InspectorView.js:
1770         (WebInspector.InspectorView.prototype._keyDown):
1771         * inspector/front-end/TextViewer.js:
1772         (WebInspector.TextViewer.prototype.set readOnly):
1773         (WebInspector.TextViewer.prototype._cancelEditing):
1774         (WebInspector.TextViewer.prototype.wasShown):
1775         (WebInspector.TextViewer.prototype.willHide):
1776         * inspector/front-end/UIUtils.js:
1777         (WebInspector.isInEditMode):
1778         * inspector/front-end/inspector.js:
1779         (WebInspector.documentKeyDown):
1780
1781 2012-01-19  Kaustubh Atrawalkar  <kaustubh@motorola.com> & Erik Arvidsson  <arv@chromium.org>
1782
1783         Migrate createObjectURL & revokeObjectURL to static (Class) methods.
1784         https://bugs.webkit.org/show_bug.cgi?id=74386
1785
1786         Reviewed by Adam Barth.
1787
1788         Test: fast/dom/DOMURL/check-instanceof-domurl-functions.html
1789         Already Existing -
1790             fast/files/revoke-blob-url.html
1791             fast/dom/window-domurl-crash.html
1792             fast/files/apply-blob-url-to-img.html
1793             fast/files/create-blob-url-crash.html
1794             fast/files/workers/inline-worker-via-blob-url.html
1795
1796         * html/DOMURL.cpp: Added HashMap for local static objects.
1797         (WebCore::PublicURLManager::PublicURLManager):
1798         (WebCore::PublicURLManager::contextDestroyed):
1799         (WebCore::PublicURLManager::blobURLs):
1800         (WebCore::PublicURLManager::streamURLs):
1801         (WebCore::publicURLManagerMap):
1802         (WebCore::publicURLManager):
1803         (WebCore::publicBlobURLs):
1804         (WebCore::publicStreamURLs):
1805         (WebCore::DOMURL::createObjectURL): Changed to static.
1806         (WebCore::DOMURL::revokeObjectURL): ditto.
1807         * html/DOMURL.h:
1808         (WebCore::DOMURL::create):
1809         (WebCore::DOMURL::~DOMURL):
1810         (WebCore::DOMURL::DOMURL):
1811         * html/DOMURL.idl:
1812         * page/DOMWindow.cpp: Removed object initialization for DOMURL.
1813         * page/DOMWindow.h: ditto.
1814         * page/DOMWindow.idl: ditto.
1815         * workers/WorkerContext.cpp: ditto.
1816         * workers/WorkerContext.h: ditto.
1817         * workers/WorkerContext.idl: ditto.
1818
1819 2012-01-20  Alexandru Chiculita  <achicu@adobe.com>
1820
1821         CSS Shaders: Add a Settings flag to enable/disable CSS Shaders at runtime
1822         https://bugs.webkit.org/show_bug.cgi?id=76444
1823         
1824         Added setCSSCustomFilterEnabled/isCSSCustomFilterEnabled that is false by default.
1825         I've enabled it by default on Apple Mac, to make sure there's no behavior change. Anyway, CSS shaders need
1826         WebGL enabled, so it ends up being disabled by default.
1827
1828         Reviewed by Nikolas Zimmermann.
1829
1830         Test: css3/filters/effect-custom-disabled.html
1831
1832         * css/CSSParser.cpp:
1833         (WebCore::CSSParser::parseFilter):
1834             Do not parse the custom() function when shaders are disabled.
1835             
1836         * css/CSSStyleSelector.cpp:
1837         (WebCore::CSSStyleSelector::applyProperty):
1838             Do not overwrite the old style->filter() if parsing fails.
1839             
1840         (WebCore::CSSStyleSelector::createFilterOperations):
1841             Do not continue if one custom() filter fails to parse.
1842             
1843         * page/Settings.cpp:
1844         (WebCore::Settings::Settings):
1845         * page/Settings.h:
1846         (WebCore::Settings::setCSSCustomFilterEnabled):
1847         (WebCore::Settings::isCSSCustomFilterEnabled):
1848         * rendering/FilterEffectRenderer.cpp:
1849         (WebCore::isCSSCustomFilterEnabled):
1850         (WebCore::FilterEffectRenderer::build):
1851             Avoid creating the filter when shaders are disabled. It may happen to get here if shaders were disabled between parsing and rendering.
1852         
1853 2012-01-19  Shinya Kawanaka  <shinyak@google.com>
1854
1855         Node::canHaveLightChildRendererWithShadow is not used anywhere.
1856         https://bugs.webkit.org/show_bug.cgi?id=76627
1857
1858         Reviewed by Darin Adler.
1859
1860         Since Node::canHaveLightChildRendererWithShadow is not overriden anywhere, and it returns always false.
1861         We can remove it.
1862
1863         No new tests, because no change in behavior.
1864
1865         * dom/Node.h:
1866         * dom/NodeRenderingContext.cpp:
1867         (WebCore::NodeRenderingContext::shouldCreateRenderer):
1868
1869 2012-01-19  Kinuko Yasuda  <kinuko@chromium.org>
1870
1871         Cleanup: make constant variable names in fileapi/ conform to WebKit's coding guideline
1872         https://bugs.webkit.org/show_bug.cgi?id=76625
1873
1874         Reviewed by David Levin.
1875
1876         No new tests as this patch has no functional changes.
1877
1878         * fileapi/BlobURL.cpp:
1879         (WebCore::BlobURL::getIdentifier):
1880         (WebCore::BlobURL::createBlobURL):
1881         * fileapi/BlobURL.h:
1882         * fileapi/FileWriter.cpp:
1883         (WebCore::FileWriter::write):
1884         (WebCore::FileWriter::truncate):
1885         * platform/AsyncFileSystem.cpp:
1886         (WebCore::AsyncFileSystem::crackFileSystemURL):
1887         (WebCore::AsyncFileSystem::toURL):
1888         (WebCore::AsyncFileSystem::isAvailable):
1889         * platform/AsyncFileSystem.h:
1890
1891 2012-01-18  Sam Weinig  <sam@webkit.org>
1892
1893         Move RunLoop to WebCore/platform
1894         https://bugs.webkit.org/show_bug.cgi?id=76471
1895
1896         Reviewed by Anders Carlsson.
1897
1898         * GNUmakefile.list.am:
1899         * Target.pri:
1900         * WebCore.exp.in:
1901         * WebCore.vcproj/WebCore.vcproj:
1902         * WebCore.xcodeproj/project.pbxproj:
1903         Add newly moved files.
1904
1905         * platform/RunLoop.cpp: Moved from Source/WebKit2/Platform/RunLoop.cpp.
1906         * platform/RunLoop.h: Moved from Source/WebKit2/Platform/RunLoop.h.
1907         * platform/gtk/RunLoopGtk.cpp: Moved from Source/WebKit2/Platform/gtk/RunLoopGtk.cpp.
1908         * platform/mac/RunLoopMac.mm: Moved from Source/WebKit2/Platform/mac/RunLoopMac.mm.
1909         * platform/qt/RunLoopQt.cpp: Moved from Source/WebKit2/Platform/qt/RunLoopQt.cpp.
1910         * platform/win/RunLoopWin.cpp: Moved from Source/WebKit2/Platform/win/RunLoopWin.cpp.
1911         Move the files.
1912
1913 2012-01-19  Pablo Flouret  <pablof@motorola.com>
1914
1915         Fix inconsistent text selection behavior with option-shift-left/right/up/down.
1916         https://bugs.webkit.org/show_bug.cgi?id=75652
1917
1918         Reviewed by Enrica Casucci.
1919
1920         On Mac, selecting backwards by word, line or paragraph from the middle
1921         of some text, and then going forward leaves the caret back in the middle
1922         with no selection, instead of directly selecting to the other end of the
1923         word/line/paragraph (Unix/Windows behavior). Fix this by adding a new
1924         editing behavior to control whether the selection should go across the
1925         initial position of the caret directly or not in situations like the one
1926         outlined above.
1927
1928         Test: editing/selection/selection-extend-should-not-move-across-caret-on-mac.html
1929
1930         * editing/EditingBehavior.h:
1931         (WebCore::EditingBehavior::shouldExtendSelectionByWordOrLineAcrossCaret):
1932         * editing/FrameSelection.cpp:
1933         (WebCore::FrameSelection::modify):
1934
1935 2012-01-19  Simon Fraser  <simon.fraser@apple.com>
1936
1937         Regression (r98735): Video chat moles in Gmail render incorrectly on Mac OS
1938         https://bugs.webkit.org/show_bug.cgi?id=75682
1939
1940         Reviewed by James Robinson.
1941         
1942         RenderLayerBacking::isSimpleContainerCompositingLayer() gave incorret
1943         results in the case where the layer itself was visibility:hidden, but
1944         where it had visible, non-composited descendant layers.
1945         
1946         Fix by breaking RenderLayerBacking::hasVisibleNonCompositingDescendants()
1947         into two methods, one that tests for renderers in this layer which
1948         render stuff (and are thus affected by visibility on this layer), and
1949         another which walks descendant, non-composited layers looking for those
1950         which are visible.
1951         
1952         Removed an early return in the "renderObject->node()->isDocumentNode()"
1953         clause, because we want to run the same code that we run for non-document
1954         nodes.
1955
1956         Test: compositing/visibility/layer-visible-content.html
1957
1958         * rendering/RenderLayerBacking.cpp:
1959         (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
1960         (WebCore::RenderLayerBacking::containsNonEmptyRenderers):
1961         (WebCore::RenderLayerBacking::hasVisibleNonCompositingDescendantLayers):
1962         * rendering/RenderLayerBacking.h:
1963
1964 2012-01-19  Alexandre Elias  <aelias@google.com>
1965
1966         [chromium] Draw gutter quads outside root content layer
1967         https://bugs.webkit.org/show_bug.cgi?id=76328
1968
1969         Reviewed by James Robinson.
1970
1971         Add new layer property "backgroundCoversViewport".  If the content
1972         layers don't fully cover the render surface, this code calculates the
1973         difference between the root clip rect and the root content layer and
1974         draws up to four background-color quads in exactly the area that would
1975         be undrawn.
1976
1977         Test: CCTiledLayerImplTest::backgroundCoversViewport
1978
1979         * platform/graphics/chromium/LayerChromium.cpp:
1980         (WebCore::LayerChromium::LayerChromium):
1981         (WebCore::LayerChromium::setBackgroundCoversViewport):
1982         (WebCore::LayerChromium::pushPropertiesTo):
1983         * platform/graphics/chromium/LayerChromium.h:
1984         (WebCore::LayerChromium::backgroundCoversViewport):
1985         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1986         (WebCore::CCLayerImpl::CCLayerImpl):
1987         (WebCore::CCLayerImpl::setBackgroundCoversViewport):
1988         * platform/graphics/chromium/cc/CCLayerImpl.h:
1989         (WebCore::CCLayerImpl::backgroundCoversViewport):
1990         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1991         (WebCore::CCTiledLayerImpl::appendQuads):
1992
1993 2012-01-19  Cary Clark  <caryclark@google.com>
1994
1995         [Skia Mac] Match style of platform error underline for misspellings
1996         https://bugs.webkit.org/show_bug.cgi?id=76556
1997
1998         Reviewed by Stephen White.
1999
2000         Add Darwin-specific code in Skia to draw the error underline so that
2001         it matches the CoreGraphics style.
2002
2003         Many existing layout tests inadvertantly trigger the misspelling
2004         underline by including the word 'foo' in an editable field. Those
2005         tests are temporarily suppressed separately in an edit to
2006         test_expectations.txt.
2007
2008         * platform/graphics/skia/GraphicsContextSkia.cpp:
2009         (WebCore::GraphicsContext::drawLineForTextChecking):
2010
2011 2012-01-19  No'am Rosenthal  <noam.rosenthal@nokia.com>
2012
2013         [Texmap] TextureMapper creates two many big intermediate surfaces
2014         https://bugs.webkit.org/show_bug.cgi?id=76336
2015
2016         Reviewed by Simon Hausmann.
2017
2018         The following has been done to optimize surface allocation:
2019         1. Instead of using a viewport-size surface, use a surface in the size of the layer's
2020            bounding rect and apply the transform after the content has been rendered into it.
2021         2. Avoid generating intermediate surface for occasions where they're not necessary,
2022            such as nested reflections without opacity.
2023         3. Releasing of textures from the pool is now implicit, based on refCount.
2024         4. Do not use intermediate surfaces for preserve-3d layers. This is in alignment with
2025            other ports.
2026
2027         Tests in LayoutTests/compositing/masks and LayoutTests/compositing/reflection cover this.
2028
2029         * platform/graphics/texmap/TextureMapper.cpp:
2030         (WebCore::TextureMapper::acquireTextureFromPool):
2031         * platform/graphics/texmap/TextureMapper.h:
2032         * platform/graphics/texmap/TextureMapperNode.cpp:
2033         (WebCore::TextureMapperNode::paintSelf):
2034         (WebCore::TextureMapperNode::paintSelfAndChildren):
2035         (WebCore::TextureMapperNode::intermediateSurfaceRect):
2036         (WebCore::TextureMapperNode::shouldPaintToIntermediateSurface):
2037         (WebCore::TextureMapperNode::isVisible):
2038         (WebCore::TextureMapperNode::paintSelfAndChildrenWithReplica):
2039         (WebCore::TextureMapperNode::paintRecursive):
2040         (WebCore::TextureMapperNode::syncCompositingStateSelf):
2041         (WebCore::TextureMapperNode::syncCompositingState):
2042         * platform/graphics/texmap/TextureMapperNode.h:
2043         (WebCore::TextureMapperPaintOptions::TextureMapperPaintOptions):
2044
2045 2012-01-19  Eric Seidel  <eric@webkit.org>
2046
2047         Assertion failure in WebCore::HTMLFrameElementBase::insertedIntoDocument()
2048         https://bugs.webkit.org/show_bug.cgi?id=50312
2049
2050         Reviewed by Alexey Proskuryakov.
2051
2052         Removed the ASSERT and updated the comment.
2053
2054         Test: fast/frames/assert-on-insertedIntoDocument.html
2055
2056         * html/HTMLFrameElementBase.cpp:
2057         (WebCore::HTMLFrameElementBase::insertedIntoDocument):
2058
2059 2012-01-19  James Robinson  <jamesr@chromium.org>
2060
2061         [chromium] Remove CCLayerDelegate, add ContentLayerDelegate for painting
2062         https://bugs.webkit.org/show_bug.cgi?id=76663
2063
2064         Reviewed by Kenneth Russell.
2065
2066         CCLayerDelegate used to be an interface with a half-dozen callbacks on it, but now it has only one call -
2067         paintContents() - and that one call is only valid for one subclass of LayerChromium, ContentLayerChromium. This
2068         removes the CCLayerDelegate pointer from LayerChromium and adds a ContentLayerDelegate for the paint call.
2069
2070         The majority of the code changes in this patch are removing the nil parameter from various places that construct
2071         LayerChromium instances. Also tightens the type of GraphicsLayerChromium::m_layer to ContentLayerChromium.
2072
2073         Refactoring/removing dead code, so no new tests.
2074
2075         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
2076         (WebCore::Canvas2DLayerChromium::Canvas2DLayerChromium):
2077         * platform/graphics/chromium/CanvasLayerChromium.cpp:
2078         (WebCore::CanvasLayerChromium::CanvasLayerChromium):
2079         * platform/graphics/chromium/CanvasLayerChromium.h:
2080         * platform/graphics/chromium/ContentLayerChromium.cpp:
2081         (WebCore::ContentLayerPainter::create):
2082         (WebCore::ContentLayerPainter::ContentLayerPainter):
2083         (WebCore::ContentLayerChromium::create):
2084         (WebCore::ContentLayerChromium::ContentLayerChromium):
2085         * platform/graphics/chromium/ContentLayerChromium.h:
2086         (WebCore::ContentLayerDelegate::~ContentLayerDelegate):
2087         (WebCore::ContentLayerChromium::clearDelegate):
2088         * platform/graphics/chromium/DrawingBufferChromium.cpp:
2089         (WebCore::DrawingBuffer::platformLayer):
2090         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2091         (WebCore::GraphicsLayerChromium::~GraphicsLayerChromium):
2092         (WebCore::GraphicsLayerChromium::setContentsToImage):
2093         (WebCore::GraphicsLayerChromium::setContentsToCanvas):
2094         (WebCore::GraphicsLayerChromium::setContentsToMedia):
2095         (WebCore::GraphicsLayerChromium::updateLayerPreserves3D):
2096         * platform/graphics/chromium/GraphicsLayerChromium.h:
2097         * platform/graphics/chromium/ImageLayerChromium.cpp:
2098         (WebCore::ImageLayerChromium::create):
2099         (WebCore::ImageLayerChromium::ImageLayerChromium):
2100         * platform/graphics/chromium/ImageLayerChromium.h:
2101         * platform/graphics/chromium/LayerChromium.cpp:
2102         (WebCore::LayerChromium::create):
2103         (WebCore::LayerChromium::LayerChromium):
2104         * platform/graphics/chromium/LayerChromium.h:
2105         * platform/graphics/chromium/PluginLayerChromium.cpp:
2106         (WebCore::PluginLayerChromium::create):
2107         (WebCore::PluginLayerChromium::PluginLayerChromium):
2108         * platform/graphics/chromium/PluginLayerChromium.h:
2109         * platform/graphics/chromium/TiledLayerChromium.cpp:
2110         (WebCore::TiledLayerChromium::TiledLayerChromium):
2111         (WebCore::TiledLayerChromium::drawsContent):
2112         * platform/graphics/chromium/TiledLayerChromium.h:
2113         * platform/graphics/chromium/VideoLayerChromium.cpp:
2114         (WebCore::VideoLayerChromium::create):
2115         (WebCore::VideoLayerChromium::VideoLayerChromium):
2116         * platform/graphics/chromium/VideoLayerChromium.h:
2117         * platform/graphics/chromium/WebGLLayerChromium.cpp:
2118         (WebCore::WebGLLayerChromium::create):
2119         (WebCore::WebGLLayerChromium::WebGLLayerChromium):
2120         * platform/graphics/chromium/WebGLLayerChromium.h:
2121
2122 2012-01-19  Greg Billock  <gbillock@google.com>
2123
2124         [Coverity] Fix uninitialized constructor defects in .../html
2125         https://bugs.webkit.org/show_bug.cgi?id=74965
2126
2127         Reviewed by Simon Fraser.
2128
2129         Test: fast/canvas/script-tests/canvas-webkitLineDash.js
2130
2131         * html/HTMLFormCollection.cpp:
2132         (WebCore::HTMLFormCollection::HTMLFormCollection):
2133         * html/StepRange.cpp:
2134         (WebCore::StepRange::StepRange):
2135         * html/canvas/CanvasRenderingContext2D.cpp:
2136         (WebCore::CanvasRenderingContext2D::State::State):
2137         * html/canvas/CanvasStyle.h:
2138         (WebCore::CanvasStyle::CMYKAValues::CMYKAValues):
2139         * html/canvas/WebGLGetInfo.cpp:
2140         (WebCore::WebGLGetInfo::WebGLGetInfo):
2141         * html/parser/CSSPreloadScanner.cpp:
2142         (WebCore::CSSPreloadScanner::CSSPreloadScanner):
2143         * html/track/WebVTTParser.cpp:
2144         (WebCore::WebVTTParser::WebVTTParser):
2145
2146 2012-01-19  Alexandru Chiculita  <achicu@adobe.com>
2147
2148         CSS Shaders: Remove the setTimeout from the layout tests
2149         https://bugs.webkit.org/show_bug.cgi?id=76535
2150
2151         Reviewed by Tony Chang.
2152
2153         We had setTimeout on old tests because the snapshot picture was taken too early, before the shaders were loaded.
2154         The problem was that the RenderLayer was notified that the shader was loaded only after the onload event was triggered,
2155         so a simple setTimeout(0) would have fixed the issue, but better than that would be to to always call CachedResource::data 
2156         in CachedShader::data, which notifies the load earlier (before onload).
2157
2158         No new tests, just removed the setTimeout from old ones.
2159
2160         * loader/cache/CachedShader.cpp:
2161         (WebCore::CachedShader::data):
2162
2163 2012-01-19  Min Qin  <qinmin@google.com>
2164
2165         Improve touch handling performance by reusing the hitTest result
2166         https://bugs.webkit.org/show_bug.cgi?id=75506
2167
2168         Reviewed by Adam Barth.
2169
2170         This is a performance optimization and should not cause behavior changes. Existing tests should cover it.
2171
2172         * page/EventHandler.cpp:
2173         (WebCore::EventHandler::handleTouchEvent):
2174
2175 2012-01-19  Jon Lee  <jonlee@apple.com>
2176
2177         Add text-overflow support that allows placeholder and value text to show an ellipsis when not focused
2178         https://bugs.webkit.org/show_bug.cgi?id=76118
2179         <rdar://problem/9271742>
2180
2181         Reviewed by Dan Bernstein.
2182
2183         Tests: fast/css/text-overflow-input-focus-placeholder-expected.html
2184                fast/css/text-overflow-input-focus-placeholder.html
2185                fast/css/text-overflow-input-focus-value-expected.html
2186                fast/css/text-overflow-input-focus-value.html
2187                fast/css/text-overflow-input.html
2188
2189         * rendering/RenderTextControlSingleLine.cpp:
2190         (WebCore::RenderTextControlSingleLine::styleDidChange): When the style of the text control
2191         changes, we update the text overflow property of the placeholder.
2192         (WebCore::RenderTextControlSingleLine::createInnerTextStyle): When the style of the text control
2193         changes, we update the text overflow property of the inner text block.
2194         (WebCore::RenderTextControlSingleLine::textShouldBeTruncated): The text of the value and placeholder should
2195         only contain the ellipsis if the input's text-overflow property is set to ellipsis, and the input is not focused.
2196         * rendering/RenderTextControlSingleLine.h:
2197
2198 2012-01-19  Mark Hahnenberg  <mhahnenberg@apple.com>
2199
2200         Implement a new allocator for backing stores
2201         https://bugs.webkit.org/show_bug.cgi?id=75181
2202
2203         Reviewed by Filip Pizlo.
2204
2205         No new tests.
2206
2207         Added forwarding header for new CheckedBoolean used in the bump allocator.
2208
2209         * ForwardingHeaders/wtf/CheckedBoolean.h: Added.
2210
2211 2012-01-13  Ryosuke Niwa  <rniwa@webkit.org>
2212
2213         Crash in CompositeEditCommand::ensureComposition
2214         https://bugs.webkit.org/show_bug.cgi?id=76207
2215
2216         Reviewed by Chang Shu.
2217
2218         The crash was caused by TypingCommand not kept alive when new editing commands are executed
2219         during adding more typings to the open last typing command since m_lastEditCommand is replaced
2220         by the new command. Fixed the bug by keeping them alive a little longer with RefPtr.
2221
2222         Test: editing/execCommand/editing-command-while-executing-typing-command-crash.html
2223
2224         * editing/FrameSelection.cpp:
2225         (WebCore::shouldStopBlinkingDueToTypingCommand):
2226         (WebCore::FrameSelection::updateAppearance):
2227         * editing/TypingCommand.cpp:
2228         (WebCore::TypingCommand::deleteSelection):
2229         (WebCore::TypingCommand::deleteKeyPressed):
2230         (WebCore::TypingCommand::forwardDeleteKeyPressed):
2231         (WebCore::TypingCommand::insertText):
2232         (WebCore::TypingCommand::insertLineBreak):
2233         (WebCore::TypingCommand::insertParagraphSeparatorInQuotedContent):
2234         (WebCore::TypingCommand::insertParagraphSeparator):
2235         (WebCore::TypingCommand::lastTypingCommandIfStillOpenForTyping):
2236         (WebCore::TypingCommand::closeTyping):
2237         * editing/TypingCommand.h:
2238
2239 2012-01-19  Andreas Kling  <awesomekling@apple.com>
2240
2241         Unreviewed debug build fix.
2242
2243         Remove ASSERT that the cached match is cacheable (we don't store that flag anymore.)
2244
2245         * css/CSSStyleSelector.cpp:
2246         (WebCore::CSSStyleSelector::findFromMatchedDeclarationCache):
2247
2248 2012-01-19  Robert Hogan  <robert@webkit.org>
2249
2250         Fix Debug build after r105433
2251
2252         Unreviewed, build fix.
2253
2254         * rendering/RenderTable.cpp:
2255         (WebCore::RenderTable::recalcCollapsedBorders):
2256
2257 2012-01-19  Andreas Kling  <awesomekling@apple.com>
2258
2259         CSSStyleSelector: Factor 'isCacheable' flag out of MatchedResult.
2260         <http://webkit.org/b/76376>
2261
2262         Reviewed by Antti Koivisto.
2263
2264         Break up the MatchResult struct into MatchResult and MatchRanges. The matched
2265         declaration cache only needs the ranges, so we save 4 bytes per entry.
2266
2267         * css/CSSStyleSelector.cpp:
2268         (WebCore::CSSStyleSelector::matchAllRules):
2269         (WebCore::CSSStyleSelector::matchUARules):
2270         (WebCore::CSSStyleSelector::pseudoStyleForElement):
2271         (WebCore::CSSStyleSelector::pseudoStyleRulesForElement):
2272         (WebCore::operator==):
2273         (WebCore::operator!=):
2274         (WebCore::CSSStyleSelector::findFromMatchedDeclarationCache):
2275         (WebCore::CSSStyleSelector::addToMatchedDeclarationCache):
2276         (WebCore::CSSStyleSelector::applyMatchedDeclarations):
2277         * css/CSSStyleSelector.h:
2278         (WebCore::CSSStyleSelector::MatchRanges::MatchRanges):
2279         (WebCore::CSSStyleSelector::MatchResult::MatchResult):
2280
2281 2012-01-19  Eric Carlson  <eric.carlson@apple.com>
2282
2283         https://bugs.webkit.org/show_bug.cgi?id=75192
2284
2285         Reviewed by Darin Adler.
2286
2287         Notify the media element when tracks are added to and removed from a document instead of
2288         a tree because we don't want to trigger loading unless a track element is in the document.
2289
2290         Test: media/track/track-delete-during-setup.html
2291
2292         * html/HTMLMediaElement.cpp:
2293         (WebCore::HTMLMediaElement::trackWasRemoved): Renamed from trackWillBeRemoved because it is
2294             now called after removal.
2295         * html/HTMLMediaElement.h:
2296
2297         * html/HTMLTrackElement.cpp:
2298         (WebCore::HTMLTrackElement::insertedIntoDocument): Was insertedIntoTree. Use this instead
2299             because we care about when a track is inserted and removed from a document, not a tree.
2300         (WebCore::HTMLTrackElement::removedFromDocument): Ditto.
2301         * html/HTMLTrackElement.h:
2302
2303 2012-01-18  Robert Hogan  <robert@webkit.org>
2304
2305         Hit ASSERTION FAILED: table()->collapseBorders() on techcrunch.com
2306         https://bugs.webkit.org/show_bug.cgi?id=76405
2307
2308         Reviewed by Julien Chaffraix.
2309
2310         Tests: fast/css/nested-table-with-collapsed-borders.html
2311
2312         Change recalcCollapsedBorders() so that it only collects border values for the current
2313         table. Calculating the borders for nested tables was wrong as well as wasting cycles, though it would never
2314         have impacted rendering since a cell only paints the borders that match its own.
2315
2316         * rendering/RenderTable.cpp:
2317         (WebCore::RenderTable::recalcCollapsedBorders):
2318
2319 2012-01-18  Jer Noble  <jer.noble@apple.com>
2320
2321         Make WebAudio API const-correct.
2322         https://bugs.webkit.org/show_bug.cgi?id=76573
2323
2324         Reviewed by Daniel Bates.
2325
2326         No new tests; no net change in functionality, so covered by existing tests.
2327
2328         The non-const data() accessor was renamed mutableData() to expose const-correctness
2329         bugs during compile time:
2330         * platform/audio/AudioChannel.h:
2331         (WebCore::AudioChannel::mutableData):
2332
2333         The following functions were made const correct:
2334         * platform/audio/AudioArray.h:
2335         (WebCore::AudioArray::copyToRange):
2336         * platform/audio/AudioBus.h:
2337         (WebCore::AudioBus::createBufferFromRange):
2338         (WebCore::AudioBus::createBySampleRateConverting):
2339         (WebCore::AudioBus::createByMixingToMono):
2340         * platform/audio/FFTConvolver.cpp:
2341         (WebCore::FFTConvolver::process):
2342         * platform/audio/FFTConvolver.h:
2343         * platform/audio/FFTFrame.cpp:
2344         (WebCore::FFTFrame::doPaddedFFT):
2345         (WebCore::FFTFrame::doFFT):
2346         * platform/audio/FFTFrame.h:
2347         * platform/audio/ReverbConvolverStage.cpp:
2348         (WebCore::ReverbConvolverStage::ReverbConvolverStage):
2349         (WebCore::ReverbConvolverStage::process):
2350         * platform/audio/ReverbConvolverStage.h:
2351         * platform/audio/ReverbInputBuffer.cpp:
2352         (WebCore::ReverbInputBuffer::write):
2353         * platform/audio/ReverbInputBuffer.h:
2354         * platform/audio/SincResampler.cpp:
2355         (WebCore::SincResampler::process):
2356         * platform/audio/SincResampler.h:
2357         * platform/audio/ZeroPole.cpp:
2358         (WebCore::ZeroPole::process):
2359         * platform/audio/ZeroPole.h:
2360         * platform/audio/AudioBus.cpp:
2361         (WebCore::AudioBus::channelByType):
2362         * platform/audio/AudioBus.h:
2363         (WebCore::AudioBus::gain):
2364         * platform/audio/AudioDSPKernelProcessor.cpp:
2365         (WebCore::AudioDSPKernelProcessor::process):
2366         * platform/audio/AudioDSPKernelProcessor.h:
2367         * platform/audio/AudioProcessor.h:
2368         * platform/audio/DynamicsCompressor.cpp:
2369         (WebCore::DynamicsCompressor::process):
2370         * platform/audio/DynamicsCompressor.h:
2371         * platform/audio/DynamicsCompressorKernel.cpp:
2372         (WebCore::DynamicsCompressorKernel::process):
2373         * platform/audio/DynamicsCompressorKernel.h:
2374         * platform/audio/EqualPowerPanner.cpp:
2375         (WebCore::EqualPowerPanner::pan):
2376         * platform/audio/EqualPowerPanner.h:
2377         * platform/audio/HRTFElevation.h:
2378         (WebCore::HRTFElevation::numberOfAzimuths):
2379         * platform/audio/HRTFPanner.cpp:
2380         (WebCore::HRTFPanner::pan):
2381         * platform/audio/HRTFPanner.h:
2382         * platform/audio/Panner.h:
2383         * platform/audio/Reverb.cpp:
2384         (WebCore::Reverb::process):
2385         * platform/audio/Reverb.h:
2386         * platform/audio/ReverbConvolver.cpp:
2387         (WebCore::ReverbConvolver::process):
2388         * platform/audio/ReverbConvolver.h:
2389         * platform/audio/ffmpeg/FFTFrameFFMPEG.cpp:
2390         (WebCore::FFTFrame::doFFT):
2391         * platform/audio/mkl/FFTFrameMKL.cpp:
2392         (WebCore::FFTFrame::doFFT):
2393
2394         The following functions were modified to use the renamed mutableData() accessor:
2395         * platform/audio/AudioBus.cpp:
2396         (WebCore::AudioBus::processWithGainFromMonoStereo):
2397         (WebCore::AudioBus::copyWithSampleAccurateGainValuesFrom):
2398         * platform/audio/AudioChannel.cpp:
2399         (WebCore::AudioChannel::scale):
2400         (WebCore::AudioChannel::copyFrom):
2401         (WebCore::AudioChannel::copyFromRange):
2402         (WebCore::AudioChannel::sumFrom):
2403         * platform/audio/AudioDSPKernelProcessor.cpp:
2404         (WebCore::AudioDSPKernelProcessor::process):
2405         * platform/audio/AudioResampler.cpp:
2406         (WebCore::AudioResampler::process):
2407         * platform/audio/DynamicsCompressor.cpp:
2408         (WebCore::DynamicsCompressor::process):
2409         * platform/audio/EqualPowerPanner.cpp:
2410         (WebCore::EqualPowerPanner::pan):
2411         * platform/audio/HRTFKernel.cpp:
2412         (WebCore::extractAverageGroupDelay):
2413         (WebCore::HRTFKernel::HRTFKernel):
2414         (WebCore::HRTFKernel::createImpulseResponse):
2415         * platform/audio/HRTFPanner.cpp:
2416         (WebCore::HRTFPanner::pan):
2417         * platform/audio/MultiChannelResampler.cpp:
2418         (WebCore::MultiChannelResampler::process):
2419         * platform/audio/Reverb.cpp:
2420         (WebCore::Reverb::process):
2421         * platform/audio/ReverbConvolver.cpp:
2422         (WebCore::ReverbConvolver::ReverbConvolver):
2423         (WebCore::ReverbConvolver::process):
2424         * platform/audio/mac/AudioFileReaderMac.cpp:
2425         (WebCore::AudioFileReader::createBus):
2426         * platform/audio/mac/FFTFrameMac.cpp:
2427         (WebCore::FFTFrame::doFFT):
2428         * webaudio/AudioBufferSourceNode.cpp:
2429         (WebCore::AudioBufferSourceNode::process):
2430         (WebCore::AudioBufferSourceNode::renderFromBuffer):
2431         * webaudio/BiquadProcessor.cpp:
2432         (WebCore::BiquadProcessor::process):
2433         * webaudio/JavaScriptAudioNode.cpp:
2434         (WebCore::JavaScriptAudioNode::process):
2435         * webaudio/OfflineAudioDestinationNode.cpp:
2436         (WebCore::OfflineAudioDestinationNode::render):
2437         * webaudio/RealtimeAnalyser.cpp:
2438         (WebCore::RealtimeAnalyser::writeInput):
2439         * webaudio/WaveShaperProcessor.cpp:
2440         (WebCore::WaveShaperProcessor::process):
2441
2442 2012-01-19  Vsevolod Vlasov  <vsevik@chromium.org>
2443
2444         Unreviewed, inspector closure compilation fix.
2445
2446         * inspector/front-end/ScriptsPanel.js:
2447         * inspector/front-end/TabbedEditorContainer.js:
2448
2449 2012-01-19  David Hyatt  <hyatt@apple.com>
2450
2451         https://bugs.webkit.org/show_bug.cgi?id=76644
2452
2453         Before landing support for centering, fix the keyword value to match the latest draft.
2454         The new keyword is "contain" instead of "bounds."
2455
2456         Revised the existing parsing tests to reflect the updated value.
2457
2458         Reviewed by Dan Bernstein.
2459
2460         * css/CSSParser.cpp:
2461         (WebCore::CSSParser::parseValue):
2462         * css/CSSPrimitiveValueMappings.h:
2463         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2464         (WebCore::CSSPrimitiveValue::operator LineGridSnap):
2465         * css/CSSValueKeywords.in:
2466         * rendering/style/RenderStyleConstants.h:
2467
2468 2012-01-19  Joi Sigurdsson  <joi@chromium.org>
2469
2470         Enable use of precompiled headers in Chromium port on Windows.
2471
2472         Bug 76381 - Use precompiled headers in Chromium port on Windows
2473         https://bugs.webkit.org/show_bug.cgi?id=76381
2474
2475         Reviewed by Tony Chang.
2476
2477         No new tests needed; if the change builds and existing tests pass
2478         that should provide enough coverage.
2479
2480         * WebCore.gyp/WebCore.gyp: Include WinPrecompile.gypi.
2481
2482 2012-01-19  Vsevolod Vlasov  <vsevik@chromium.org>
2483
2484         Web Inspector: Switching tabs in TabbedEditorContainer should reveal selected script in navigator.
2485         https://bugs.webkit.org/show_bug.cgi?id=76636
2486
2487         Reviewed by Pavel Feldman.
2488
2489         Renamed FileSelector's ScriptSelected event into FileSelected, added EditorSelected
2490         event to EditorContainer.
2491         Renamed _showSourceFrame into _showFile.
2492         Made _uiSourceCodeRemoved reuse _removeSourceFrame.
2493
2494         * inspector/front-end/ScriptsNavigator.js:
2495         (WebInspector.ScriptsNavigator.prototype.scriptSelected):
2496         * inspector/front-end/ScriptsPanel.js:
2497         (WebInspector.ScriptsPanel.prototype._uiSourceCodeRemoved):
2498         (WebInspector.ScriptsPanel.prototype._showAndRevealInFileSelector):
2499         (WebInspector.ScriptsPanel.prototype._editorSelected):
2500         (WebInspector.ScriptsPanel.prototype._fileSelected):
2501         (WebInspector.ScriptsPanel.ComboBoxFileSelector.prototype._goBack):
2502         (WebInspector.ScriptsPanel.ComboBoxFileSelector.prototype._goForward):
2503         (WebInspector.ScriptsPanel.ComboBoxFileSelector.prototype._filesSelectChanged):
2504         * inspector/front-end/TabbedEditorContainer.js:
2505         (WebInspector.TabbedEditorContainer):
2506         (WebInspector.TabbedEditorContainer.prototype._tabSelected):
2507
2508 2012-01-19  Mihnea Ovidenie  <mihnea@adobe.com>
2509
2510         [CSSRegions]Add support for background-color in region styling
2511         https://bugs.webkit.org/show_bug.cgi?id=71488
2512
2513         Reviewed by David Hyatt.
2514
2515         This patch enables region styling again. The region styling tests were also added back. 
2516         With the improvements from https://bugs.webkit.org/show_bug.cgi?id=76265, hopefully we will not see the same 3% regressions
2517         in performance.
2518
2519         * rendering/RenderObject.h:
2520         (WebCore::RenderObject::style):
2521
2522 2012-01-16  Jer Noble  <jer.noble@apple.com>
2523
2524         Crash at WebCore::MediaControlRootElement::makeOpaque + 97
2525         https://bugs.webkit.org/show_bug.cgi?id=76391
2526
2527         Reviewed by John Sullivan.
2528
2529         No new tests; Speculative fix for crash.
2530
2531         Crash report data suggests this crash is occurring as the document is being
2532         closed.  Check the nullity of document()->page() before deref-ing.
2533
2534         * html/shadow/MediaControlElements.cpp:
2535         (WebCore::MediaControlPanelElement::makeOpaque):
2536
2537 2012-01-19  Ken Buchanan <kenrb@chromium.org>
2538
2539         Layout Test fast/text/international/spaces-combined-in-vertical-text.html is failing
2540         https://bugs.webkit.org/show_bug.cgi?id=75787
2541
2542         Reviewed by Simon Fraser.
2543
2544         This is a tweak to my patch in r104322. On some platforms
2545         RenderCombineText::combineText() can abort early during inline
2546         iteration, causing this loop in skipLeadingWhitespace to spin,
2547         hence the layout test timeouts. This patch accounts for that
2548         condition and makes the loop iteration more robust.
2549
2550         No new test because this is fixing a failure on an existing test.
2551
2552         * rendering/RenderBlockLineLayout.cpp:
2553         (WebCore::RenderBlock::LineBreaker::skipLeadingWhitespace):
2554
2555 2012-01-19  Jer Noble  <jer.noble@apple.com>
2556
2557         HRTFPanner not rendering correctly on mac port
2558         https://bugs.webkit.org/show_bug.cgi?id=76397
2559
2560         Reviewed by Eric Carlson.
2561
2562         No new tests; HRTF results are currently not testable.
2563
2564         Re-generate the Composite.wav file from its constituent azimuth & elevation files.
2565
2566         * platform/audio/resources/Composite.wav:
2567
2568 2012-01-19  David Hyatt  <hyatt@apple.com>
2569
2570         https://bugs.webkit.org/show_bug.cgi?id=76577
2571         
2572         Fix crash when nested line grids are used. Make sure to bail out if no line grid
2573         is found rather than crashing.
2574
2575         Reviewed by Dan Bernstein.
2576
2577         Added fast/line-grid/line-grid-nested.html.
2578
2579         * rendering/LayoutState.cpp:
2580         (WebCore::LayoutState::establishLineGrid):
2581
2582 2012-01-18  Enrica Casucci  <enrica@apple.com>
2583
2584         editingAttributedStringFromRange in WebHTMLConverter does not handle NSUnderlineStyleAttributeName.
2585         https://bugs.webkit.org/show_bug.cgi?id=76588
2586         <rdar://problem/9325183>
2587
2588         Reviewed by Dan Bernstein.
2589
2590         Added TestWebKitAPI test.
2591
2592         * platform/mac/HTMLConverter.mm:
2593         (+[WebHTMLConverter editingAttributedStringFromRange:]):
2594
2595 2012-01-18  Alexander Pavlov  <apavlov@chromium.org>
2596
2597         Web Inspector: Implement screen resolution emulation backend
2598         https://bugs.webkit.org/show_bug.cgi?id=76532
2599
2600         Reviewed by Pavel Feldman.
2601
2602         The emulation affects [min-|max-]device-(width|height) media queries, window.screen.(width|height),
2603         and window.inner(Width|Height).
2604
2605         Test: inspector/styles/override-screen-size.html
2606
2607         * css/MediaQueryEvaluator.cpp:
2608         (WebCore::device_heightMediaFeatureEval): Apply device-height override if necessary.
2609         (WebCore::device_widthMediaFeatureEval): Apply device-width override if necessary.
2610         * inspector/Inspector.json:
2611         * inspector/InspectorCSSAgent.cpp:
2612         (WebCore::InspectorCSSAgent::InspectorCSSAgent):
2613         (WebCore::InspectorCSSAgent::startSelectorProfiler):
2614         (WebCore::InspectorCSSAgent::stopSelectorProfilerImpl):
2615         (WebCore::InspectorCSSAgent::willMatchRule):
2616         (WebCore::InspectorCSSAgent::didMatchRule):
2617         (WebCore::InspectorCSSAgent::willProcessRule):
2618         (WebCore::InspectorCSSAgent::didProcessRule):
2619         * inspector/InspectorInstrumentation.cpp:
2620         (WebCore::InspectorInstrumentation::applyScreenWidthOverrideImpl):
2621         (WebCore::InspectorInstrumentation::applyScreenHeightOverrideImpl):
2622         * inspector/InspectorInstrumentation.h:
2623         (WebCore::InspectorInstrumentation::applyScreenWidthOverride):
2624         (WebCore::InspectorInstrumentation::applyScreenHeightOverride):
2625         * inspector/InspectorPageAgent.cpp:
2626         (WebCore::InspectorPageAgent::InspectorPageAgent):
2627         (WebCore::InspectorPageAgent::restore):
2628         (WebCore::InspectorPageAgent::disable):
2629         (WebCore::InspectorPageAgent::setScreenSizeOverride):
2630         (WebCore::InspectorPageAgent::applyScreenWidthOverride):
2631         (WebCore::InspectorPageAgent::applyScreenHeightOverride):
2632         (WebCore::InspectorPageAgent::updateFrameViewFixedLayout):
2633         (WebCore::InspectorPageAgent::clearFrameViewFixedLayout):
2634         (WebCore::InspectorPageAgent::setFrameViewFixedLayout):
2635         * inspector/InspectorPageAgent.h:
2636         * page/DOMWindow.cpp:
2637         (WebCore::DOMWindow::innerHeight): Apply height override if necessary.
2638         (WebCore::DOMWindow::innerWidth): Apply width override if necessary.
2639         * page/Screen.cpp:
2640         (WebCore::Screen::height): Apply height override if necessary.
2641         (WebCore::Screen::width): Apply width override if necessary.
2642
2643 2012-01-18  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
2644
2645         [Qt] Handle the layers visible rect calculation on the web process.
2646         https://bugs.webkit.org/show_bug.cgi?id=74720
2647
2648         Reviewed by Noam Rosenthal.
2649
2650         Remove all visible rect calculation related code from TextureMapperNode.
2651
2652         * platform/graphics/texmap/TextureMapperNode.cpp:
2653         * platform/graphics/texmap/TextureMapperNode.h:
2654
2655 2012-01-19  Vsevolod Vlasov  <vsevik@chromium.org>
2656
2657         Web Inspector: Improve focus switching in scripts panel.
2658         https://bugs.webkit.org/show_bug.cgi?id=76628
2659
2660         Reviewed by Pavel Feldman.
2661
2662         * inspector/front-end/Dialog.js:
2663         (WebInspector.Dialog.prototype._hide):
2664         * inspector/front-end/FilteredItemSelectionDialog.js:
2665         (WebInspector.FilteredItemSelectionDialog.prototype.onEnter):
2666         (WebInspector.JavaScriptOutlineDialog.prototype.selectItem):
2667         * inspector/front-end/ScriptsNavigator.js:
2668         (WebInspector.ScriptsNavigator.prototype.get defaultFocusedElement):
2669         * inspector/front-end/ScriptsPanel.js:
2670         (WebInspector.ScriptsPanel.prototype._showSourceLine):
2671
2672 2012-01-19  Vsevolod Vlasov  <vsevik@chromium.org>
2673
2674         Web Inspector: Add isSelfOrAnsector and isSelfOrDescendant methods to utilities.
2675         https://bugs.webkit.org/show_bug.cgi?id=76618
2676
2677         Added isSelfOrAncestor, isSelfOrDescendant and WebInspector.restoreFocusFromElement methods.
2678
2679         Reviewed by Pavel Feldman.
2680
2681         * inspector/front-end/Drawer.js:
2682         * inspector/front-end/HelpScreen.js:
2683         (WebInspector.HelpScreen.prototype._onBlur):
2684         * inspector/front-end/MetricsSidebarPane.js:
2685         (WebInspector.MetricsSidebarPane.prototype._handleKeyDown):
2686         * inspector/front-end/Popover.js:
2687         * inspector/front-end/ScriptsPanel.js:
2688         (WebInspector.ScriptsPanel.prototype.showUISourceCode):
2689         * inspector/front-end/StylesSidebarPane.js:
2690         ():
2691         * inspector/front-end/TextPrompt.js:
2692         (WebInspector.TextPrompt.prototype.detach):
2693         (WebInspector.TextPrompt.prototype.isCaretAtEndOfPrompt):
2694         * inspector/front-end/TextViewer.js:
2695         (WebInspector.TextEditorMainPanel.prototype._updateSelectionOnStartEditing):
2696         (WebInspector.TextEditorMainPanel.prototype._handleDOMUpdates):
2697         * inspector/front-end/UIUtils.js:
2698         (WebInspector.startEditing.cleanUpAfterEditing):
2699         (WebInspector.restoreFocusFromElement):
2700         * inspector/front-end/utilities.js:
2701         (Element.prototype.isInsertionCaretInside):
2702         ():
2703
2704 2012-01-19  Andreas Kling  <awesomekling@apple.com>
2705
2706         DynamicNodeList: Simplify internal Caches object.
2707         <http://webkit.org/b/76600>
2708
2709         Reviewed by Ryosuke Niwa.
2710
2711         Move m_caches from DynamicSubtreeNodeList and ChildNodeList up into DynamicNodeList.
2712         Remove the inheritance from RefCounted and store it simply as "Caches m_caches"
2713         This avoids one heap allocation per DynamicNodeList. Also reordered the Caches members
2714         to pack slightly better on 64-bit.
2715
2716         * dom/ChildNodeList.cpp:
2717         (WebCore::ChildNodeList::ChildNodeList):
2718         (WebCore::ChildNodeList::length):
2719         (WebCore::ChildNodeList::item):
2720         * dom/ChildNodeList.h:
2721         * dom/DynamicNodeList.cpp:
2722         (WebCore::DynamicSubtreeNodeList::DynamicSubtreeNodeList):
2723         (WebCore::DynamicSubtreeNodeList::length):
2724         (WebCore::DynamicSubtreeNodeList::itemForwardsFromCurrent):
2725         (WebCore::DynamicSubtreeNodeList::itemBackwardsFromCurrent):
2726         (WebCore::DynamicSubtreeNodeList::item):
2727         * dom/DynamicNodeList.h:
2728         (WebCore::DynamicNodeList::invalidateCache):
2729         * dom/Node.cpp:
2730         (WebCore::NodeRareData::clearChildNodeListCache):
2731
2732 2012-01-19  Vsevolod Vlasov  <vsevik@chromium.org>
2733
2734         Web Inspector: TabbedPane closeAllTabs does not close all tabs.
2735         https://bugs.webkit.org/show_bug.cgi?id=76624
2736
2737         Reviewed by Pavel Feldman.
2738
2739         * inspector/front-end/ScriptsPanel.js:
2740         * inspector/front-end/TabbedPane.js:
2741         (WebInspector.TabbedPane.prototype.closeAllTabs):
2742
2743 2012-01-18  Rob Buis  <rbuis@rim.com>
2744
2745         image/pjpeg not supported for decoding on BlackBerry platform
2746         https://bugs.webkit.org/show_bug.cgi?id=76595
2747
2748         Reviewed by Antonio Gomes.
2749
2750         Add image/pjpeg as one of the supported types for image decoding on BlackBerry platform.
2751
2752         * platform/MIMETypeRegistry.cpp:
2753         (WebCore::initializeSupportedImageMIMETypes):
2754
2755 2012-01-19  Sheriff Bot  <webkit.review.bot@gmail.com>
2756
2757         Unreviewed, rolling out r105402.
2758         http://trac.webkit.org/changeset/105402
2759         https://bugs.webkit.org/show_bug.cgi?id=76623
2760
2761         Layout test problems (Requested by WildFox on #webkit).
2762
2763         * css/svg.css:
2764         (svg):
2765         * rendering/RenderBox.h:
2766         (WebCore::RenderBox::computeIntrinsicRatioInformation):
2767         * rendering/RenderBoxModelObject.cpp:
2768         (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
2769         * rendering/RenderImage.cpp:
2770         (WebCore::RenderImage::computeReplacedLogicalWidth):
2771         (WebCore::RenderImage::computeIntrinsicRatioInformation):
2772         * rendering/RenderImage.h:
2773         * rendering/RenderReplaced.cpp:
2774         (WebCore::RenderReplaced::computeReplacedLogicalWidth):
2775         (WebCore::RenderReplaced::logicalHeightIsAuto):
2776         (WebCore::RenderReplaced::computeReplacedLogicalHeight):
2777         * rendering/RenderReplaced.h:
2778         * rendering/svg/RenderSVGRoot.cpp:
2779         (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation):
2780         (WebCore::RenderSVGRoot::computeReplacedLogicalWidth):
2781         (WebCore::RenderSVGRoot::computeReplacedLogicalHeight):
2782         * rendering/svg/RenderSVGRoot.h:
2783         * rendering/svg/RenderSVGViewportContainer.h:
2784         * svg/SVGLengthContext.cpp:
2785         (WebCore::SVGLengthContext::determineViewport):
2786         * svg/SVGSVGElement.cpp:
2787         (WebCore::SVGSVGElement::viewport):
2788         (WebCore::SVGSVGElement::parseMappedAttribute):
2789         (WebCore::updateCSSForAttribute):
2790         (WebCore::SVGSVGElement::svgAttributeChanged):
2791         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
2792         (WebCore::SVGSVGElement::currentViewBoxRect):
2793         * svg/SVGSVGElement.h:
2794         * svg/graphics/SVGImage.cpp:
2795         (WebCore::SVGImage::size):
2796         (WebCore::SVGImage::computeIntrinsicDimensions):
2797         * svg/graphics/SVGImage.h:
2798
2799 2012-01-19  Alexis Menard  <alexis.menard@openbossa.org>
2800
2801         Strange Result for getComputedStyle on borderWidth set in em
2802         https://bugs.webkit.org/show_bug.cgi?id=18294
2803
2804         Reviewed by Tony Chang.
2805
2806         BorderValue stores its width on a 12 bits unsigned. This patch 
2807         increase it to 27. The patch also modify the way to set the 
2808         width or to get it, we now use a unsigned rather than a short.
2809
2810         Test: fast/css/border-width-large.html
2811
2812         * css/CSSPrimitiveValue.cpp:
2813         (WebCore::CSSPrimitiveValue::computeLength):
2814         * css/CSSStyleApplyProperty.cpp:
2815         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
2816         * page/animation/AnimationBase.cpp:
2817         (WebCore::blendFunc):
2818         (WebCore::AnimationBase::ensurePropertyMap):
2819         * platform/animation/AnimationUtilities.h:
2820         (WebCore::blend):
2821         * rendering/RenderTheme.cpp:
2822         (WebCore::RenderTheme::adjustStyle):
2823         * rendering/style/BorderData.h:
2824         (WebCore::BorderData::borderLeftWidth):
2825         (WebCore::BorderData::borderRightWidth):
2826         (WebCore::BorderData::borderTopWidth):
2827         (WebCore::BorderData::borderBottomWidth):
2828         * rendering/style/BorderValue.h:
2829         (WebCore::BorderValue::width):
2830         * rendering/style/RenderStyle.cpp:
2831         * rendering/style/RenderStyle.h:
2832         (WebCore::RenderStyleBitfields::borderLeftWidth):
2833         (WebCore::RenderStyleBitfields::borderRightWidth):
2834         (WebCore::RenderStyleBitfields::borderTopWidth):
2835         (WebCore::RenderStyleBitfields::borderBottomWidth):
2836         (WebCore::RenderStyleBitfields::setBorderLeftWidth):
2837         (WebCore::RenderStyleBitfields::setBorderRightWidth):
2838         (WebCore::RenderStyleBitfields::setBorderTopWidth):
2839         (WebCore::RenderStyleBitfields::setBorderBottomWidth):
2840         (WebCore::RenderStyleBitfields::initialBorderWidth):
2841         (WebCore::RenderStyleBitfields::initialColumnRuleWidth):
2842         (WebCore::RenderStyleBitfields::initialOutlineWidth):
2843
2844 2012-01-18  Nikolas Zimmermann  <nzimmermann@rim.com>
2845
2846         Differentiate between SVG/CSS width/height attributes/properties
2847         https://bugs.webkit.org/show_bug.cgi?id=76447
2848
2849         Reviewed by Antti Koivisto.
2850
2851         Remove a gazillion of hacks out of our SVG implementation, by correctly differentiating between the
2852         SVG width/height attributes and the CSS width/height properties. They need to be treated independently
2853         when handling the intrinsic size negotiation, according to both CSS 2.1 & SVG 1.1 2nd Edition specs.
2854
2855         Fixes several bugs in the LayoutTests/svg/custom/*object*sizing tests, we now match Opera perfectly. FF still has some bugs, and IE9 as well.
2856
2857         * css/svg.css: Remove hardcoded, width/height: 100% on <svg>.
2858         * rendering/RenderBox.h:
2859         (WebCore::RenderBox::computeIntrinsicRatioInformation): Make 'intrinsicRatio' a float, and add 'intrinsicSize' as seperated FloatSize, to avoid confusion.
2860         * rendering/RenderBoxModelObject.cpp:
2861         (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions): Add forgotton case for percentage intrinsic sizes, that lead to workarounds in other places, that can now be removed.
2862         * rendering/RenderImage.cpp:
2863         (WebCore::RenderImage::computeReplacedLogicalWidth): Directly use imageHasRelativeWidth/Height(), it does differentiate between SVG/CSS width/height attributes/properties now.
2864         (WebCore::RenderImage::computeIntrinsicRatioInformation): Adapt to 'intrinsicRatio' argument change.
2865         * rendering/RenderImage.h: Ditto.
2866         * rendering/RenderReplaced.cpp: Refactor existing code, break out firstContainingBlockWithLogicalWidth/hasReplacedLogicalWidth/hasReplacedLogicalHeight/hasAutoHeightOrContainingBlockWithAutoHeight.
2867         (WebCore::firstContainingBlockWithLogicalWidth): Refactored.
2868         (WebCore::RenderReplaced::hasReplacedLogicalWidth): Refactored, and exported, so SVGSVGElement::widthAttributeEstablishesViewport() can use it.
2869         (WebCore::hasAutoHeightOrContainingBlockWithAutoHeight): Refactored.
2870         (WebCore::RenderReplaced::hasReplacedLogicalHeight): Refactored, and exported, so SVGSVGElement::heightAttributeEstablishesViewport() can use it.
2871         (WebCore::RenderReplaced::computeReplacedLogicalWidth): Adapt to 'intrinsicRatio' changes ('intrinsicSize' is now decoupled from it). Refactor so that RenderSVGRoot can directly use it as well!
2872         (WebCore::RenderReplaced::computeReplacedLogicalHeight): Ditto.
2873         * rendering/RenderReplaced.h:
2874         * rendering/svg/RenderSVGRoot.cpp:
2875         (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation): Only determine the intrinsic size & ratio using the SVG width/height attributes, not the CSS width/height properties, as it's specified.
2876         (WebCore::resolveLengthAttributeForSVG): Helper function for computeReplacedLogicalWidth/Height, that scales Length values that come from SVG width/height attributes.
2877         (WebCore::RenderSVGRoot::computeReplacedLogicalWidth): Finally remove home-brewn size computation logic - it can be fully shared with RenderReplaced now that we inherit from it.
2878         (WebCore::RenderSVGRoot::computeReplacedLogicalHeight): Ditto.
2879         * rendering/svg/RenderSVGRoot.h:
2880         * rendering/svg/RenderSVGViewportContainer.h:
2881         (WebCore::RenderSVGViewportContainer::viewport): Export viewport() for easier length resolution.
2882         * svg/SVGLengthContext.cpp:
2883         (WebCore::SVGLengthContext::determineViewport): Finally clean up this hell, and make it easy to understand. Only need to resolve lengths against either RenderSVGRoot or RenderSVGViewportContainer now.
2884         * svg/SVGSVGElement.cpp: 
2885         (WebCore::SVGSVGElement::viewport): Remove wrong code and disable this. Its not used, and we have no test coverage for it. Its current implementation didn't make any sense.
2886         (WebCore::SVGSVGElement::parseMappedAttribute): Remove hacks mapping SVG width/height attributes to CSS properties.
2887         (WebCore::SVGSVGElement::svgAttributeChanged): Ditto.
2888         (WebCore::SVGSVGElement::localCoordinateSpaceTransform): Refactored.
2889         (WebCore::SVGSVGElement::currentViewBoxRect): Ditto.
2890         (WebCore::SVGSVGElement::currentViewportSize): Ditto.
2891         (WebCore::SVGSVGElement::widthAttributeEstablishesViewport): Main logic determining if the SVG or CSS properties establish the viewport -  a direct transliteration from the spec.
2892         (WebCore::SVGSVGElement::heightAttributeEstablishesViewport): Ditto.
2893         (WebCore::SVGSVGElement::intrinsicWidth): Helper.
2894         (WebCore::SVGSVGElement::intrinsicHeight): Ditto.
2895         * svg/SVGSVGElement.h:
2896         * svg/graphics/SVGImage.cpp:
2897         (WebCore::SVGImage::size): Cleanup code.
2898         (WebCore::SVGImage::hasRelativeWidth): Added, avoids hacks in RenderBoxModelObject.
2899         (WebCore::SVGImage::hasRelativeHeight): Ditto.
2900         (WebCore::SVGImage::computeIntrinsicDimensions): Make use of new SVGSVGElement::computeIntrinsicDimensions.
2901         * svg/graphics/SVGImage.h:
2902
2903 2012-01-19  Ryosuke Niwa  <rniwa@webkit.org>
2904
2905         drop event isn't fired for contentEditable in edit drag
2906         https://bugs.webkit.org/show_bug.cgi?id=57185
2907
2908         Reviewed by Adam Barth.
2909
2910         Dispatch drop and dragend events after edit drag per HTML5 spec:
2911         http://www.whatwg.org/specs/web-apps/current-work/multipage/dnd.html#drag-and-drop-processing-model
2912
2913         There are two major differences between the spec and WebKit's new behavior:
2914
2915         While the spec says we have to insert the dragged contents immediately after dispatching drop event
2916         and delete the source in the default event handler of dragend event, doing so in WebKit is extremely
2917         difficult because of the way we manage the selection. Instead, we continue to delete the source
2918         and insert the dragged contents immediately after the drop event; this behavior matches that of Firefox 9.
2919
2920         When the dragged contents and the destination of the move is in the same text node, ReplaceSelectionCommand
2921         may end up replacing it with a new text node. But this removal causes a problem when EventHandler uses
2922         the node to dispatch dragend event because the node is "orphaned" from its parent at that point. To mitigate
2923         this issue, we update the dragState's m_dragSrc when the node is orphaned by the edit drag. While this behavior
2924         may differ from the spec and other browsers, not delivering dragend to the editing host seems strictly worse than
2925         dispatching it at the slightly wrong target.
2926
2927         Tests: fast/events/moving-text-should-fire-drop-and-dragend-events-2.html
2928                fast/events/moving-text-should-fire-drop-and-dragend-events.html
2929
2930         * page/DragController.cpp:
2931         (WebCore::DragController::performDrag): Dispatch drop event even when m_isHandlingDrag is true as long
2932         as DragDestinationActionDHTML is an acceptable action.
2933         (WebCore::DragController::concludeEditDrag): Call updateDragStateAfterEditDragIfNeeded after inserting
2934         the dragged contents. This is necessary when ReplaceSelectionCommand or MoveSelectionCommand modifies
2935         the source node while inserting the dragged contents.
2936         * page/EventHandler.cpp:
2937         (WebCore::EventHandler::performDragAndDrop): Clear the drag state only if drop event's default action
2938         was prevented so that we dispatch dragevent event later.
2939         (WebCore::EventHandler::updateDragStateAfterEditDragIfNeeded): Update dragState's m_dragSrc when the node
2940         is orphaned. See above for the rationale.
2941         * page/EventHandler.h:
2942
2943 2012-01-18  Kinuko Yasuda  <kinuko@chromium.org>
2944
2945         Cleanup: Move chrome-specific filesystem type handling code (for FileSystem API) under chromium directory
2946         https://bugs.webkit.org/show_bug.cgi?id=76551
2947
2948         Reviewed by Darin Fisher.
2949
2950         Moved the implementation of crackFileSystemURL() and toURL() from
2951         WebCore/fileapi/DOMFileSystemBase into WebCore/platform/AsyncFileSystem
2952         so that each platform can extend/implement their behavior if necessary.
2953
2954         No new tests since this patch has no functionality changes. (Existing
2955         tests should pass)
2956
2957         * fileapi/DOMFileSystemBase.cpp: Moved the implementation of
2958         crackFileSystemURL() to AsyncFileSystem
2959         (WebCore::DOMFileSystemBase::crackFileSystemURL):
2960         * fileapi/DOMFileSystemBase.h:
2961         * fileapi/EntryBase.cpp: Moved the implementation of toURL() to AsyncFileSystem
2962         (WebCore::EntryBase::toURL):
2963         * page/DOMWindow.cpp: Removed chrome-specific type handling code.
2964         (WebCore::DOMWindow::webkitRequestFileSystem):
2965         * page/DOMWindow.h: Removed chrome-specific filesystem type
2966         (EXTERNAL).
2967         * platform/AsyncFileSystem.cpp: Added default implementation of toURL() and crackFileSystemURL()
2968         (WebCore::AsyncFileSystem::toURL):
2969         (WebCore::AsyncFileSystem::crackFileSystemURL):
2970         * platform/AsyncFileSystem.h:
2971         * workers/WorkerContext.cpp: Removed chrome-specific type handling code.
2972         (WebCore::WorkerContext::webkitRequestFileSystem):
2973         (WebCore::WorkerContext::webkitRequestFileSystemSync):
2974
2975 2012-01-19  Mihnea Ovidenie  <mihnea@adobe.com>
2976
2977         Cache RenderStyle pointer as a method to avoid performance regression for region styling
2978         https://bugs.webkit.org/show_bug.cgi?id=76265
2979
2980         Reviewed by David Hyatt.
2981
2982         No new tests since this is just refactoring.
2983         When region styling was enabled in https://bugs.webkit.org/show_bug.cgi?id=71488,
2984         it introduced a performance regression due to the change of RenderObject::style() method.
2985         This patch tries to avoid a new performance regression when region styling will be enabled again.
2986
2987         * rendering/RenderBlock.cpp:
2988         (WebCore::RenderBlock::MarginInfo::MarginInfo):
2989         (WebCore::RenderBlock::styleWillChange):
2990         (WebCore::RenderBlock::layoutBlock):
2991         (WebCore::RenderBlock::layoutBlockChildren):
2992         (WebCore::RenderBlock::layoutBlockChild):
2993         (WebCore::RenderBlock::computePreferredLogicalWidths):
2994         (WebCore::getBorderPaddingMargin):
2995         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
2996         (WebCore::RenderBlock::computeBlockPreferredLogicalWidths):
2997         * rendering/RenderBlockLineLayout.cpp:
2998         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
2999         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
3000         * rendering/RenderBox.cpp:
3001         (WebCore::RenderBox::willBeDestroyed):
3002         (WebCore::RenderBox::styleWillChange):
3003         (WebCore::RenderBox::styleDidChange):
3004         (WebCore::RenderBox::updateBoxModelInfoFromStyle):
3005         (WebCore::RenderBox::computeRectForRepaint):
3006         (WebCore::RenderBox::computeLogicalWidthInRegion):
3007         (WebCore::RenderBox::computeLogicalWidthUsing):
3008         (WebCore::RenderBox::computeLogicalHeight):
3009         (WebCore::RenderBox::computePercentageLogicalHeight):
3010         (WebCore::RenderBox::computePositionedLogicalHeight):
3011         * rendering/RenderBoxModelObject.cpp:
3012         (WebCore::RenderBoxModelObject::styleWillChange):
3013         (WebCore::RenderBoxModelObject::updateBoxModelInfoFromStyle):
3014         * rendering/RenderInline.cpp:
3015         (WebCore::RenderInline::styleDidChange):
3016         * rendering/RenderText.cpp:
3017         (WebCore::RenderText::styleDidChange):
3018         (WebCore::RenderText::computePreferredLogicalWidths):
3019
3020 2012-01-19  Kazuhiro Inaba  <kinaba@chromium.org>
3021
3022         [Chromium] Random characters got rendered as empty boxes or with incorrect glyphs even when a font is present
3023         https://bugs.webkit.org/show_bug.cgi?id=76508
3024
3025         Reviewed by Kent Tamura.
3026
3027         Wrapped GetGlyphIndices() API calls so that when they failed we trigger font
3028         loading outside the sandbox and retry the call.
3029
3030         No new auto tests since the bug involves the system's occasional cache behavior
3031         and thus there's no reliable way to reproduce and test the situation.
3032
3033         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
3034         (WebCore::getGlyphIndices):
3035         GDI call wrapper ensuring fonts to be loaded.
3036         (WebCore::initSpaceGlyph):
3037         Changed to use the wrapper function.
3038         (WebCore::fillBMPGlyphs):
3039         Changed to use the wrapper function.
3040         Introduced scoped HDC management by HWndDC.
3041         (WebCore::GlyphPage::fill):
3042
3043 2012-01-19  Adam Barth  <abarth@webkit.org>
3044
3045         createAttributeNS should understand that "xmlns" is allowed in the http://www.w3.org/2000/xmlns/
3046         https://bugs.webkit.org/show_bug.cgi?id=76579
3047
3048         Reviewed by Eric Seidel.
3049
3050         This patch cleans up a tiny corner case involving the (somewhat
3051         magical) xmlns attribute that we uncovered when working on
3052         setAttributeNS.
3053
3054         Tests: fast/dom/Document/createAttributeNS-namespace-err.html
3055
3056         * dom/Document.cpp:
3057         (WebCore::Document::importNode):
3058         (WebCore::Document::hasValidNamespaceForElements):
3059         (WebCore::Document::hasValidNamespaceForAttributes):
3060         (WebCore::Document::createElementNS):
3061         (WebCore::Document::createAttributeNS):
3062         * dom/Document.h:
3063         * dom/Element.cpp:
3064         (WebCore::Element::setAttributeNS):
3065
3066 2012-01-19  Roland Steiner  <rolandsteiner@chromium.org>
3067
3068         Unreviewed build fix for DEBUG: remove comparison of an unsigned variable with '>= 0' in ASSERT.
3069
3070         No new tests. (no functionality change)
3071
3072         * webaudio/AudioNodeOutput.cpp:
3073         (WebCore::AudioNodeOutput::AudioNodeOutput):
3074
3075 2012-01-18  Li Yin  <li.yin@intel.com>
3076
3077         [v8] Low efficiency of writing long string from web application to plugin.
3078         https://bugs.webkit.org/show_bug.cgi?id=76592
3079
3080         The efficiency will be improved by 300 times in the best case, when the
3081         size of string reaches 1MB.
3082
3083         Reviewed by Adam Barth.
3084
3085         * bindings/v8/V8NPUtils.cpp:
3086         (WebCore::convertV8ObjectToNPVariant):
3087
3088 2012-01-18  Adam Barth  <abarth@webkit.org>
3089
3090         Assigning to Element.prefix should throw exception when using illegal characters
3091         https://bugs.webkit.org/show_bug.cgi?id=76589
3092
3093         Reviewed by Eric Seidel.
3094
3095         This patch fixes a FIXME and implements the INVALID_CHARACTER_ERR
3096         exception described in
3097         http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-NodeNSPrefix
3098
3099         Tests: fast/dom/Element/prefix-setter-exception.html
3100
3101         * dom/Node.cpp:
3102         (WebCore::isValidNameStartCharacter):
3103         (WebCore::isValidNameCharacter):
3104         (WebCore::hasInvalidValidNameCharacters):
3105         (WebCore::Node::checkSetPrefix):
3106
3107 2012-01-18  Shinya Kawanaka  <shinyak@google.com>
3108
3109         ShadowContent query should be able to have fallback elements.
3110         https://bugs.webkit.org/show_bug.cgi?id=75306
3111
3112         Reviewed by Hajime Morita.
3113
3114         When no elements are selected by a shadow content element selector query,
3115         light children are selected as a fallback elements.
3116
3117         Test: fast/dom/shadow/shadow-contents-fallback.html
3118
3119         * dom/NodeRenderingContext.cpp:
3120         (WebCore::NodeRenderingContext::NodeRenderingContext):
3121           Considers fallback phase. When no elements are chosen, the phase is set to 'fallback'.
3122         (WebCore::NodeRenderingContext::nextRenderer):
3123           Takes fallback phase into account.
3124         (WebCore::NodeRenderingContext::previousRenderer): ditto.
3125         * dom/NodeRenderingContext.h:
3126         * html/shadow/HTMLContentElement.cpp:
3127         (WebCore::HTMLContentElement::attach):
3128           Calculates inclusions before attaching light children.
3129         * html/shadow/HTMLContentElement.h:
3130         (WebCore::HTMLContentElement::hasInclusion):
3131
3132 2012-01-18  Kent Tamura  <tkent@chromium.org>
3133
3134         REGRESSION(r100111): A 'change' event does not fire when a mouse drag
3135         occurs to switch elements in a listbox <select>
3136         https://bugs.webkit.org/show_bug.cgi?id=76244
3137
3138         Reviewed by Hajime Morita.
3139
3140         Test: fast/forms/select/listbox-drag-in-non-multiple.html
3141
3142         * html/HTMLSelectElement.cpp:
3143         (WebCore::HTMLSelectElement::updateSelectedState):
3144         Do not update m_activeSelectionState for non-multiple <select>.
3145         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
3146         Use setActiveSelection*Index() and updateListBoxSelection(true) instead
3147         of updateSelectedState() because updateSelectedState() updates
3148         m_lastOnChangeSelection and will prevent the mouseup handler from
3149         dispatching 'change' event.
3150         We should not call listBoxOnChange() in the mousemove handler in order
3151         to align the behavior of IE and Firefox.
3152
3153 2012-01-18  Eric Seidel  <eric@webkit.org>
3154
3155         setAttributeNS should comply with the obscure rules of DOM2, just like createAttributeNS and createElementNS do
3156         https://bugs.webkit.org/show_bug.cgi?id=76143
3157
3158         Reviewed by Adam Barth.
3159
3160         Test: fast/dom/Element/setAttributeNS-namespace-err.html
3161
3162         * dom/Element.cpp:
3163         (WebCore::Element::setAttributeNS):
3164
3165 2012-01-18  Sheriff Bot  <webkit.review.bot@gmail.com>
3166
3167         Unreviewed, rolling out r105376.
3168         http://trac.webkit.org/changeset/105376
3169         https://bugs.webkit.org/show_bug.cgi?id=76601
3170
3171         Roll 76493 back in after discussion with jsbell (Requested by
3172         rolandsteiner on #webkit).
3173
3174         * bindings/v8/IDBBindingUtilities.cpp:
3175         (WebCore::injectIDBKeyIntoSerializedValue):
3176
3177 2012-01-18  Ian Vollick  <vollick@chromium.org>
3178
3179         [chromium] Create a base-class CCAnimation to represent compositor animations
3180         https://bugs.webkit.org/show_bug.cgi?id=73233
3181
3182         Adds a kernel for running animations on the chromium compositor
3183         thread.
3184
3185         Reviewed by Kenneth Russell.
3186
3187         * WebCore.gypi:
3188         * platform/graphics/chromium/cc/CCActiveAnimation.cpp: Added.
3189         (WebCore::CCActiveAnimation::CCActiveAnimation):
3190         (WebCore::CCActiveAnimation::setRunState):
3191         (WebCore::CCActiveAnimation::isFinishedAt):
3192         (WebCore::CCActiveAnimation::trimTimeToCurrentIteration):
3193         * platform/graphics/chromium/cc/CCActiveAnimation.h: Added.
3194         (WebCore::CCActiveAnimation::create):
3195         (WebCore::CCActiveAnimation::~CCActiveAnimation):
3196         (WebCore::CCActiveAnimation::group):
3197         (WebCore::CCActiveAnimation::targetProperty):
3198         (WebCore::CCActiveAnimation::runState):
3199         (WebCore::CCActiveAnimation::iterations):
3200         (WebCore::CCActiveAnimation::setIterations):
3201         (WebCore::CCActiveAnimation::startTime):
3202         (WebCore::CCActiveAnimation::setStartTime):
3203         (WebCore::CCActiveAnimation::isFinished):
3204         (WebCore::CCActiveAnimation::animationCurve):
3205         * platform/graphics/chromium/cc/CCAnimationCurve.cpp: Added.
3206         (WebCore::CCAnimationCurve::toFloatAnimationCurve):
3207         (WebCore::CCAnimationCurve::toTransformAnimationCurve):
3208         * platform/graphics/chromium/cc/CCAnimationCurve.h: Added.
3209         (WebCore::CCAnimationCurve::~CCAnimationCurve):
3210         (WebCore::CCFloatAnimationCurve::~CCFloatAnimationCurve):
3211         (WebCore::CCFloatAnimationCurve::type):
3212         (WebCore::CCTransformAnimationCurve::~CCTransformAnimationCurve):
3213         (WebCore::CCTransformAnimationCurve::type):
3214         * platform/graphics/chromium/cc/CCLayerAnimationControllerImpl.cpp: Added.
3215         (WebCore::CCLayerAnimationControllerImpl::create):
3216         (WebCore::CCLayerAnimationControllerImpl::CCLayerAnimationControllerImpl):
3217         (WebCore::CCLayerAnimationControllerImpl::animate):
3218         (WebCore::CCLayerAnimationControllerImpl::add):
3219         (WebCore::CCLayerAnimationControllerImpl::getActiveAnimation):
3220         (WebCore::CCLayerAnimationControllerImpl::hasActiveAnimation):
3221         (WebCore::CCLayerAnimationControllerImpl::startAnimationsWaitingForNextTick):
3222         (WebCore::CCLayerAnimationControllerImpl::startAnimationsWaitingForStartTime):
3223         (WebCore::CCLayerAnimationControllerImpl::startAnimationsWaitingForTargetAvailability):
3224         (WebCore::CCLayerAnimationControllerImpl::resolveConflicts):
3225         (WebCore::CCLayerAnimationControllerImpl::purgeFinishedAnimations):
3226         (WebCore::CCLayerAnimationControllerImpl::tickAnimations):
3227         * platform/graphics/chromium/cc/CCLayerAnimationControllerImpl.h: Added.
3228         (WebCore::CCLayerAnimationControllerImplClient::~CCLayerAnimationControllerImplClient):
3229
3230 2012-01-18  Sheriff Bot  <webkit.review.bot@gmail.com>
3231
3232         Unreviewed, rolling out r105331.
3233         http://trac.webkit.org/changeset/105331
3234         https://bugs.webkit.org/show_bug.cgi?id=76599
3235
3236         May have broken Chromium InjectIDBKey browser_test (Requested
3237         by rolandsteiner on #webkit).
3238
3239         * bindings/v8/IDBBindingUtilities.cpp:
3240         (WebCore::injectIDBKeyIntoSerializedValue):
3241
3242 2012-01-18  Raymond Liu  <raymond.liu@intel.com>
3243
3244         Remove some unused code in AudioContext
3245         https://bugs.webkit.org/show_bug.cgi?id=76506
3246
3247         Reviewed by Kenneth Russell.
3248
3249         No new tests required.
3250
3251         * webaudio/AudioContext.cpp:
3252         (WebCore::AudioContext::constructCommon):
3253         (WebCore::AudioContext::uninitialize):
3254         * webaudio/AudioContext.h:
3255
3256 2012-01-18  Raymond Liu  <raymond.liu@intel.com>
3257
3258         Only create AudioBus with required number of channels for AudioNodeOutput
3259         https://bugs.webkit.org/show_bug.cgi?id=76417
3260
3261         Reviewed by Kenneth Russell.
3262
3263         No new tests required.
3264
3265         * webaudio/AudioNodeOutput.cpp:
3266         (WebCore::AudioNodeOutput::AudioNodeOutput):
3267         (WebCore::AudioNodeOutput::setNumberOfChannels):
3268         (WebCore::AudioNodeOutput::updateInternalBus):
3269         (WebCore::AudioNodeOutput::updateNumberOfChannels):
3270         (WebCore::AudioNodeOutput::pull):
3271         * webaudio/AudioNodeOutput.h:
3272
3273 2012-01-18  Andreas Kling  <awesomekling@apple.com>
3274
3275         Cache and reuse the NodeList returned by Node::childNodes().
3276         <http://webkit.org/b/76591>
3277
3278         Reviewed by Ryosuke Niwa.
3279
3280         Instead of only caching the DynamicNodeList::Caches for .childNodes on NodeRareData,
3281         cache the full ChildNodeList object. Lifetime management is left to wrappers who
3282         invalidate the cached (raw) pointer via Node::removeCachedChildNodeList(), called
3283         from ~ChildNodeList().
3284
3285         This is a slight behavior change, in that Node.childNodes === Node.childNodes will
3286         now be true. This matches the behavior of both Firefox and Opera.
3287
3288         This reduces memory consumption by 192 kB (on 32-bit) when viewing the full
3289         HTML5 spec at <http://whatwg.org/c>
3290
3291         Test: fast/dom/gc-9.html
3292               fast/dom/node-childNodes-idempotence.html
3293
3294         * dom/Node.cpp:
3295         (WebCore::Node::childNodes):
3296         * dom/NodeRareData.h:
3297         (WebCore::NodeRareData::NodeRareData):
3298         (WebCore::NodeRareData::childNodeList):
3299         (WebCore::NodeRareData::setChildNodeList):
3300
3301             Only construct one ChildNodeList per Node and store it on NodeRareData for
3302             retrieval across childNodes() calls.
3303
3304         * dom/ChildNodeList.h:
3305         (WebCore::ChildNodeList::create):
3306         * dom/ChildNodeList.cpp:
3307         (WebCore::ChildNodeList::ChildNodeList):
3308
3309             Construct the Caches at creation instead of passing it to the constructor.
3310
3311         (WebCore::ChildNodeList::reset):
3312
3313             Added, resets the internal cache.
3314
3315         (WebCore::ChildNodeList::~ChildNodeList):
3316
3317             Call Node::removeCachedChildNodeList().
3318
3319         * dom/DynamicNodeList.cpp:
3320         * dom/DynamicNodeList.h:
3321
3322             Have DynamicNodeList (and subclasses) respond "true" to isDynamicNodeList().
3323             Previously only DynamicSubtreeNodeList (and subclasses) were doing this.
3324             Without it, JSC may GC our ChildNodeLists prematurely (due to NodeList's
3325             isReachableFromOpaqueRoots() implementation checking isDynamicNodeList().)
3326
3327         * dom/Node.h:
3328         * dom/Node.cpp:
3329         (WebCore::Node::removeCachedChildNodeList):
3330
3331             Added for ~ChildNodeList() to remove the pointer to itself from the Node.
3332
3333         (WebCore::NodeRareData::clearChildNodeListCache):
3334
3335             Call ChildNodeList::reset().
3336
3337 2012-01-18  James Robinson  <jamesr@chromium.org>
3338
3339         Unreviewed, rolling out r105366.
3340         http://trac.webkit.org/changeset/105366
3341         https://bugs.webkit.org/show_bug.cgi?id=76015
3342
3343         Breaks CCLayerTreeHostImplTest unit test
3344
3345         * platform/graphics/chromium/TiledLayerChromium.cpp:
3346         (WebCore::TiledLayerChromium::pushPropertiesTo):
3347         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
3348         * platform/graphics/chromium/cc/CCDrawQuad.h:
3349         (WebCore::CCDrawQuad::drawsOpaque):
3350         (WebCore::CCDrawQuad::needsBlending):
3351         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
3352         (WebCore::CCQuadCuller::cullOccludedQuads):
3353         * platform/graphics/chromium/cc/CCSolidColorDrawQuad.cpp:
3354         (WebCore::CCSolidColorDrawQuad::CCSolidColorDrawQuad):
3355         * platform/graphics/chromium/cc/CCTileDrawQuad.cpp:
3356         (WebCore::CCTileDrawQuad::create):
3357         (WebCore::CCTileDrawQuad::CCTileDrawQuad):
3358         * platform/graphics/chromium/cc/CCTileDrawQuad.h:
3359         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
3360         (WebCore::CCTiledLayerImpl::appendQuads):
3361         (WebCore::CCTiledLayerImpl::syncTextureId):
3362         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
3363
3364 2012-01-18  Thiago Marcos P. Santos  <tmpsantos@gmail.com>
3365
3366         Save two ID checks on CSS Min/Width property validation
3367         https://bugs.webkit.org/show_bug.cgi?id=76565
3368
3369         The same validation is done again in the next case statement. Check for
3370         CSSValueIntrinsic and CSSValueMinIntrinsic was done twice when the value
3371         is a number.
3372
3373         Reviewed by Andreas Kling.
3374
3375         * css/CSSParser.cpp:
3376         (WebCore::CSSParser::parseValue):
3377
3378 2012-01-18  Dana Jansens  <danakj@chromium.org>
3379
3380         [chromium] Use region reported painted opaque for draw culling
3381         https://bugs.webkit.org/show_bug.cgi?id=76015
3382
3383         Reviewed by James Robinson.
3384
3385         New unit tests in CCQuadCullerTest.cpp and CCTiledLayerImplTest.cpp
3386
3387         * platform/graphics/chromium/TiledLayerChromium.cpp:
3388         (WebCore::TiledLayerChromium::pushPropertiesTo):
3389         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
3390         * platform/graphics/chromium/cc/CCDrawQuad.h:
3391         (WebCore::CCDrawQuad::opaqueRect):
3392         (WebCore::CCDrawQuad::needsBlending):
3393         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
3394         (WebCore::CCQuadCuller::cullOccludedQuads):
3395         * platform/graphics/chromium/cc/CCTileDrawQuad.cpp:
3396         (WebCore::CCTileDrawQuad::create):
3397         (WebCore::CCTileDrawQuad::CCTileDrawQuad):
3398         * platform/graphics/chromium/cc/CCTileDrawQuad.h:
3399         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
3400         (WebCore::DrawableTile::opaqueRect):
3401         (WebCore::DrawableTile::setOpaqueRect):
3402         (WebCore::CCTiledLayerImpl::appendQuads):
3403         (WebCore::CCTiledLayerImpl::pushTileProperties):
3404         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
3405
3406 2012-01-18  Victoria Kirst  <vrk@chromium.org>
3407
3408         HTMLMediaElement should fire 'progress' event before 'idle' if it was previously loading
3409         https://bugs.webkit.org/show_bug.cgi?id=76568
3410
3411         Reviewed by Eric Carlson.
3412
3413         This fires a progress event when going from a non-empty state to idle,
3414         for the same reason that a progress event is fired when going from a
3415         non-idle state to loaded. Also consolidated logic in a single helper method.
3416
3417         No new tests because the decision of if/when a user agent sets the network state
3418         to idle is up to the user agent in this scenario.
3419
3420         * html/HTMLMediaElement.cpp:
3421         (WebCore::HTMLMediaElement::setNetworkState):
3422         (WebCore::HTMLMediaElement::changeNetworkStateFromLoadingToIdle):
3423         * html/HTMLMediaElement.h:
3424
3425 2012-01-18  Jon Lee  <jonlee@apple.com>
3426
3427         [WK2] Sync call for notifications permissions causes flashes on gmail.com
3428         https://bugs.webkit.org/show_bug.cgi?id=76570
3429         <rdar://problem/10647155>
3430
3431         Reviewed by Anders Carlsson and Sam Weinig.
3432
3433         * WebCore.exp.in: Export SecurityOrigin::toString().
3434
3435         Add runtime setting to enable/disable notifications.
3436
3437         * page/Settings.cpp:
3438         (WebCore::Settings::Settings):
3439         * page/Settings.h: Add new bit for whether notifications are enabled.
3440         (WebCore::Settings::setNotificationsEnabled):
3441         (WebCore::Settings::notificationsEnabled):
3442
3443 2012-01-18  Eric Carlson  <eric.carlson@apple.com>
3444
3445         Provide access to user's list of preferred languages
3446         https://bugs.webkit.org/show_bug.cgi?id=76138
3447
3448         Reviewed by Timothy Hatcher.
3449
3450         No new tests, tested by fast/harness/user-preferred-language.html.
3451
3452         * platform/mac/Language.mm:
3453         (WebCore::platformUserPreferredLanguages): Don't over-release a the CFStrings returned by 
3454             CFLocaleCopyPreferredLanguages.
3455
3456 2012-01-18  Joshua Bell  <jsbell@chromium.org>
3457
3458         IndexedDB: Implement create-intermediate-objects semantics when injecting values via keyPaths
3459         https://bugs.webkit.org/show_bug.cgi?id=76493
3460
3461         Reviewed by Tony Chang.
3462
3463         Tests: storage/indexeddb/objectstore-autoincrement.html
3464
3465         * bindings/v8/IDBBindingUtilities.cpp:
3466         (WebCore::injectIDBKeyIntoSerializedValue):
3467
3468 2012-01-18  Joshua Bell  <jsbell@chromium.org>