Optimize GlyphPage for case where all glyphs are available in the same font.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-02-17  Andreas Kling  <akling@apple.com>
2
3         Optimize GlyphPage for case where all glyphs are available in the same font.
4         <http://webkit.org/b/108835>
5         <rdar://problem/13157042>
6
7         Reviewed by Antti Koivisto.
8
9         Let GlyphPage begin optimistically assuming that all its glyphs will be represented in
10         the same SimpleFontData*. In this (very common) case, only keep a single SimpleFontData*.
11
12         If glyphs from multiple fonts are mixed in one page, an array of per-glyph SimpleFontData*
13         is allocated transparently.
14
15         This was landed before with some bogus branch prediction hints and didn't fare well on
16         page cyclers (intl2 specifically.) These have been removed this time around, and will
17         hopefully be regression-free.
18
19         4.98 MB progression on Membuster3.
20
21         * platform/graphics/GlyphPageTreeNode.cpp:
22         (WebCore::GlyphPageTreeNode::initializePage):
23         * platform/graphics/GlyphPage.h:
24         (WebCore::GlyphPage::createUninitialized):
25         (WebCore::GlyphPage::createZeroedSystemFallbackPage):
26         (WebCore::GlyphPage::createCopiedSystemFallbackPage):
27
28             There are now three ways of constructing a GlyphPage, two of them are only used for
29             creating system fallback pages.
30
31         (WebCore::GlyphPage::setGlyphDataForIndex):
32
33             Hold off creating a SimpleFontData* array until we're sure there are two different
34             SimpleFontData* backing the glyphs in this page.
35             We don't store font data for glyph #0, instead we let the getters always return null for it.
36
37         (WebCore::GlyphPage::~GlyphPage):
38
39             Free the SimpleFontData* array if needed.
40
41         (WebCore::GlyphPage::glyphDataForCharacter):
42         (WebCore::GlyphPage::glyphDataForIndex):
43         (WebCore::GlyphPage::fontDataForCharacter):
44
45             The font data for glyph #0 is always a null pointer now.
46
47         (WebCore::GlyphPage::clearForFontData):
48
49             Updated for new storage format.
50
51         * rendering/svg/SVGTextRunRenderingContext.cpp:
52         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
53
54             Fix bug where non-zero glyph was temporarily associated with null font data,
55             which triggered the new assertion in setGlyphDataForIndex().
56
57 2013-02-16  Andreas Kling  <akling@apple.com>
58
59         Remove multi-threading gunk from WebKit2's PluginInfoStore.
60         <http://webkit.org/b/110046>
61
62         Reviewed by Alexey Proskuryakov.
63
64         Remove now-unused code for making deep (isolated) copies of WebCore plugin structures.
65
66         * plugins/PluginData.h:
67         (MimeClassInfo):
68         (PluginInfo):
69
70 2013-02-16  Alexey Proskuryakov  <ap@apple.com>
71
72         Identifier generated twice in FrameLoader::loadResourceSynchronously()
73         https://bugs.webkit.org/show_bug.cgi?id=110022
74
75         Reviewed by Darin Adler.
76
77         * loader/FrameLoader.cpp: (WebCore::FrameLoader::loadResourceSynchronously):
78         Fix an apparent refactoring mistake.
79
80 2013-02-16  Andreas Kling  <akling@apple.com>
81
82         [JSC] Remove custom mark function for NamedNodeMap.
83         <http://webkit.org/b/110029>
84
85         Reviewed by Darin Adler.
86
87         NamedNodeMap refs and unrefs its Element owner, so there's no need for the wrapper to keep the Element alive.
88
89         Covered by fast/dom/Attr/access-after-element-destruction.html
90
91         * bindings/js/JSNamedNodeMapCustom.cpp:
92         * dom/NamedNodeMap.idl:
93
94 2013-02-16  Peter Nelson  <peter@peterdn.com>
95
96         REGRESSION(r143076): Crash when calling removeNamedItem or removeNamedItemNS with a non-existent attribute of newly created element.
97         <http://webkit.org/b/110019>
98
99         Reviewed by Andreas Kling.
100
101         Now checks Element::hasAttributes() before calling Element::getAttributeItemIndex().
102
103         Test: http/tests/misc/acid3.html
104
105         * dom/NamedNodeMap.cpp:
106         (WebCore::NamedNodeMap::removeNamedItem):
107         (WebCore::NamedNodeMap::removeNamedItemNS):
108
109 2013-02-16  Andreas Kling  <akling@apple.com>
110
111         Element: Devirtualize attribute synchronization functions.
112         <http://webkit.org/b/110033>
113
114         Reviewed by Darin Adler.
115
116         Devirtualize the functions that perform re-serialization of lazy attributes and give
117         them "synchronize"-style names:
118
119             - SVGElement::synchronizeAnimatedSVGAttribute()
120             - StyledElement::synchronizeStyleAttributeInternal()
121
122         * dom/Element.cpp:
123         (WebCore::Element::synchronizeAllAttributes):
124         (WebCore::Element::synchronizeAttribute):
125         * dom/Element.h:
126         * dom/StyledElement.cpp:
127         (WebCore::StyledElement::synchronizeStyleAttribute):
128         * dom/StyledElement.h:
129         (StyledElement):
130         * rendering/svg/RenderSVGResourceGradient.cpp:
131         (WebCore::RenderSVGResourceGradient::applyResource):
132         * rendering/svg/RenderSVGResourcePattern.cpp:
133         (WebCore::RenderSVGResourcePattern::buildPattern):
134         * svg/SVGElement.cpp:
135         (WebCore::SVGElement::synchronizeAnimatedSVGAttribute):
136         * svg/SVGElement.h:
137         (SVGElement):
138
139 2013-02-16  Andreas Kling  <akling@apple.com>
140
141         Element: Avoid unrelated attribute synchronization on other attribute access.
142         <http://webkit.org/b/110025>
143
144         Reviewed by Darin Adler.
145
146         We've been extremely trigger happy with re-serializing the style attribute (and SVG animatables)
147         whenever any Element attribute API was used. This patch narrows this down to (almost always)
148         only synchronizing an attribute when someone specifically wants to read/update it.
149
150         Also removed two more confusing ElementData accessors:
151
152             - Element::elementDataWithSynchronizedAttributes()
153             - Element::ensureElementDataWithSynchronizedAttributes()
154
155         * dom/Element.h:
156         * dom/Element.cpp:
157         (WebCore::Element::hasAttributes):
158         (WebCore::Element::hasEquivalentAttributes):
159         (WebCore::Element::cloneAttributesFromElement):
160         (WebCore::Element::synchronizeAllAttributes):
161
162             Renamed updateInvalidAttributes() to synchronizeAllAttributes().
163             This function should only be used when we need every single attribute to be up-to-date.
164
165         (WebCore::Element::synchronizeAttribute):
166
167             Broke out logic for synchronizing a specific attribute, given either a full QualifiedName
168             or a localName.
169
170         (WebCore::Element::setSynchronizedLazyAttribute):
171
172             Don't call ensureUniqueElementData() indisciminately here. This avoids converting the attribute
173             storage when re-serializing the inline style yields the same CSS text that was already in the
174             style attribute.
175
176         (WebCore::Element::hasAttribute):
177         (WebCore::Element::hasAttributeNS):
178         (WebCore::Element::getAttribute):
179         (WebCore::Element::getAttributeNode):
180         (WebCore::Element::getAttributeNodeNS):
181         (WebCore::Element::setAttribute):
182         (WebCore::Element::setAttributeNode):
183         (WebCore::Element::removeAttributeNode):
184
185             Only synchronize the attribute in question.
186
187         * dom/Node.cpp:
188         (WebCore::Node::compareDocumentPosition):
189
190             Call synchronizeAllAttributes() when comparing two Attr nodes on the same Element instead
191             of relying on the side-effects of another function doing this.
192
193 2013-02-16  Seokju Kwon  <seokju.kwon@gmail.com>
194
195         Fix build warnings after r139853
196         https://bugs.webkit.org/show_bug.cgi?id=109929
197
198         Reviewed by Alexey Proskuryakov.
199
200         Use UNUSED_PARAM macro to fix build warning -Wunused-parameter
201         when INSPECTOR is disabled.
202
203         No new tests, no behavior change.
204
205         * inspector/InspectorInstrumentation.h:
206         (WebCore::InspectorInstrumentation::frameStartedLoading):
207         (WebCore::InspectorInstrumentation::frameStoppedLoading):
208         (WebCore::InspectorInstrumentation::frameScheduledNavigation):
209         (WebCore::InspectorInstrumentation::frameClearedScheduledNavigation):
210
211 2013-02-16  Sheriff Bot  <webkit.review.bot@gmail.com>
212
213         Unreviewed, rolling out r142734.
214         http://trac.webkit.org/changeset/142734
215         https://bugs.webkit.org/show_bug.cgi?id=110018
216
217         "Triggered crashes on lots of websites" (Requested by ggaren
218         on #webkit).
219
220         * bindings/js/JSLocationCustom.cpp:
221         (WebCore::JSLocation::getOwnPropertySlotDelegate):
222
223 2013-02-16  Robert Hogan  <robert@webkit.org>
224
225         percentage top value of position:relative element not calculated using parent's min-height unless height set
226         https://bugs.webkit.org/show_bug.cgi?id=14762
227
228         Reviewed by Julien Chaffraix.
229
230         Percentage height "is calculated with respect to the height of the generated box's containing block" says  
231         http://www.w3.org/TR/CSS21/visudet.html#the-height-property and "If the height of the containing block is not 
232         specified explicitly (i.e., it depends on content height), and this element is not absolutely positioned, the
233         value computes to 'auto'." So when calculating the used height of a replaced element do not crawl through ancestor 
234         blocks except when traversing anonymous blocks. Ensure that anonymous table cells are not skipped through though.
235
236         http://www.w3.org/TR/CSS21/tables.html#height-layout adds "In CSS 2.1, the height of a cell box is the minimum 
237         height required by the content." This height is decided by allowing table cells to report their height as auto.
238         It's not clear why http://trac.webkit.org/changeset/91242 decided it should no longer do this - doing so caused
239         us to regress in our rendering of computed-image-width-with-percent-height-inside-table-cell-and-fixed-ancestor.html.
240
241         Tests: fast/block/percent-top-parent-respects-min-height.html
242                fast/replaced/computed-image-width-with-percent-height-and-fixed-ancestor-vertical-lr.html
243                fast/replaced/computed-image-width-with-percent-height-and-fixed-ancestor.html
244                fast/replaced/computed-image-width-with-percent-height-inside-table-cell-and-fixed-ancestor-vertical-lr.html
245                fast/replaced/computed-image-width-with-percent-height-inside-table-cell-and-fixed-ancestor.html
246
247         * rendering/RenderBoxModelObject.cpp:
248         (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight):
249         (WebCore):
250         (WebCore::RenderBoxModelObject::relativePositionOffset):
251         * rendering/RenderBoxModelObject.h:
252         (RenderBoxModelObject):
253         * rendering/RenderReplaced.cpp:
254         (WebCore::RenderReplaced::hasReplacedLogicalHeight):
255
256 2013-02-16  Stephen White  <senorblanco@chromium.org>
257
258         [skia] FEOffset should have a Skia implementation.
259         https://bugs.webkit.org/show_bug.cgi?id=109831
260
261         Reviewed by James Robinson.
262
263         Covered by css3/filters/effect-reference.html and -hw.html.
264
265         * WebCore.gypi:
266         * platform/graphics/filters/FEOffset.h:  Implement createImageFilter()
267         for the Skia path.
268         * platform/graphics/filters/skia/FEOffsetSkia.cpp: Added.
269         (WebCore::FEOffset::createImageFilter):
270         Instantiate an SkOffsetImageFilter when building the Skia DAG.
271
272 2013-02-16  Vsevolod Vlasov  <vsevik@chromium.org>
273
274         Web Inspector: Create separate project for each domain for UISourceCode based on browser resources.
275         https://bugs.webkit.org/show_bug.cgi?id=109691
276
277         Reviewed by Pavel Feldman.
278
279         Separate project of certain type is now created for each domain.
280         UISourceCode path represents a path in the project now.
281         UISourceCode uri is now calculated based on project id and path.
282         It is also possible to calculate path based on projectId and URI, which is used for uiSourceCodeForURI() methods.
283
284         * inspector/front-end/ScriptSnippetModel.js:
285         (WebInspector.ScriptSnippetModel.prototype._addScriptSnippet):
286         * inspector/front-end/SimpleWorkspaceProvider.js:
287         (WebInspector.SimpleProjectDelegate):
288         (WebInspector.SimpleProjectDelegate.projectId):
289         (WebInspector.SimpleProjectDelegate.prototype.id):
290         (WebInspector.SimpleProjectDelegate.prototype.displayName):
291         (WebInspector.SimpleProjectDelegate.prototype.addFile):
292         (WebInspector.SimpleWorkspaceProvider):
293         (WebInspector.SimpleWorkspaceProvider.splitURL):
294         (WebInspector.SimpleWorkspaceProvider._pathForSplittedURL):
295         (WebInspector.SimpleWorkspaceProvider.uriForURL):
296         (WebInspector.SimpleWorkspaceProvider.prototype._projectDelegate):
297         (WebInspector.SimpleWorkspaceProvider.prototype._innerAddFileForURL):
298         (WebInspector.SimpleWorkspaceProvider.prototype.addFileByName):
299         (WebInspector.SimpleWorkspaceProvider.prototype._innerAddFile):
300         (WebInspector.SimpleWorkspaceProvider.prototype.removeFileByName):
301         (WebInspector.SimpleWorkspaceProvider.prototype.reset):
302         * inspector/front-end/UISourceCode.js:
303         (WebInspector.UISourceCode.uri):
304         (WebInspector.UISourceCode.path):
305         (WebInspector.UISourceCode.prototype.uri):
306         * inspector/front-end/Workspace.js:
307         (WebInspector.Project.prototype._fileAdded):
308         (WebInspector.Project.prototype._fileRemoved):
309         (WebInspector.Project.prototype.uiSourceCodeForURI):
310
311 2013-02-15  Chris Fleizach  <cfleizach@apple.com>
312
313         AX: Split WebAccessibilityObjectWrapper so code can be shared with iOS
314         https://bugs.webkit.org/show_bug.cgi?id=109849
315
316         Reviewed by David Kilzer.
317
318         Split up the WebAccessibilityObjectWrapper so that iOS can share more 
319         code with MacOS. I imagine over time, more code will move into this base class,
320         but for now this will be a good start.
321
322         A base class called WebAccessibilityObjectWrapper now exists, and Mac has a subclass
323         of that. iOS will be able to do the same.
324
325         * WebCore.xcodeproj/project.pbxproj:
326         * accessibility/mac/AXObjectCacheMac.mm:
327         (WebCore::AXObjectCache::attachWrapper):
328         * accessibility/mac/WebAccessibilityObjectWrapper.h:
329         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
330         (-[WebAccessibilityObjectWrapper detach]):
331         (-[WebAccessibilityObjectWrapper attachmentView]):
332         (-[WebAccessibilityObjectWrapper accessibilityObject]):
333         (-[WebAccessibilityObjectWrapper accessibilityPostedNotification:]):
334         (-[WebAccessibilityObjectWrapper titleTagShouldBeUsedInDescriptionField]):
335         (-[WebAccessibilityObjectWrapper accessibilityTitle]):
336         (-[WebAccessibilityObjectWrapper accessibilityDescription]):
337         (-[WebAccessibilityObjectWrapper accessibilityHelpText]):
338         * accessibility/mac/WebAccessibilityObjectWrapperMac.h: Added.
339         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm: Added.
340         (std):
341         (-[WebAccessibilityObjectWrapperMac detach]):
342         (-[WebAccessibilityObjectWrapperMac attachmentView]):
343         (CFAutoreleaseHelper):
344         (AXObjectIsTextMarker):
345         (AXObjectIsTextMarkerRange):
346         (AXTextMarkerRange):
347         (AXTextMarkerRangeStart):
348         (AXTextMarkerRangeEnd):
349         (SearchKeyEntry):
350         (createAccessibilitySearchKeyMap):
351         (accessibilitySearchKeyForString):
352         (textMarkerForVisiblePosition):
353         (-[WebAccessibilityObjectWrapperMac textMarkerForVisiblePosition:]):
354         (visiblePositionForTextMarker):
355         (-[WebAccessibilityObjectWrapperMac visiblePositionForTextMarker:]):
356         (visiblePositionForStartOfTextMarkerRange):
357         (visiblePositionForEndOfTextMarkerRange):
358         (textMarkerRangeFromMarkers):
359         (AXAttributedStringRangeIsValid):
360         (AXAttributeStringSetFont):
361         (CreateCGColorIfDifferent):
362         (AXAttributeStringSetColor):
363         (AXAttributeStringSetNumber):
364         (AXAttributeStringSetStyle):
365         (AXAttributeStringSetBlockquoteLevel):
366         (AXAttributeStringSetSpelling):
367         (AXAttributeStringSetHeadingLevel):
368         (AXAttributeStringSetElement):
369         (AXAttributedStringAppendText):
370         (nsStringForReplacedNode):
371         (-[WebAccessibilityObjectWrapperMac doAXAttributedStringForTextMarkerRange:]):
372         (textMarkerRangeFromVisiblePositions):
373         (-[WebAccessibilityObjectWrapperMac textMarkerRangeFromVisiblePositions:endPosition:]):
374         (-[WebAccessibilityObjectWrapperMac accessibilityActionNames]):
375         (-[WebAccessibilityObjectWrapperMac additionalAccessibilityAttributeNames]):
376         (-[WebAccessibilityObjectWrapperMac accessibilityAttributeNames]):
377         (-[WebAccessibilityObjectWrapperMac visiblePositionRangeForTextMarkerRange:]):
378         (-[WebAccessibilityObjectWrapperMac renderWidgetChildren]):
379         (-[WebAccessibilityObjectWrapperMac remoteAccessibilityParentObject]):
380         (convertToVector):
381         (convertToNSArray):
382         (-[WebAccessibilityObjectWrapperMac textMarkerRangeForSelection]):
383         (-[WebAccessibilityObjectWrapperMac position]):
384         (createAccessibilityRoleMap):
385         (roleValueToNSString):
386         (-[WebAccessibilityObjectWrapperMac role]):
387         (-[WebAccessibilityObjectWrapperMac subrole]):
388         (-[WebAccessibilityObjectWrapperMac roleDescription]):
389         (-[WebAccessibilityObjectWrapperMac scrollViewParent]):
390         (-[WebAccessibilityObjectWrapperMac titleTagShouldBeUsedInDescriptionField]):
391         (-[WebAccessibilityObjectWrapperMac accessibilityTitle]):
392         (-[WebAccessibilityObjectWrapperMac accessibilityDescription]):
393         (-[WebAccessibilityObjectWrapperMac accessibilityHelpText]):
394         (-[WebAccessibilityObjectWrapperMac accessibilityAttributeValue:]):
395         (-[WebAccessibilityObjectWrapperMac accessibilityFocusedUIElement]):
396         (-[WebAccessibilityObjectWrapperMac accessibilityHitTest:]):
397         (-[WebAccessibilityObjectWrapperMac accessibilityIsAttributeSettable:]):
398         (-[WebAccessibilityObjectWrapperMac accessibilityIsIgnored]):
399         (-[WebAccessibilityObjectWrapperMac accessibilityParameterizedAttributeNames]):
400         (-[WebAccessibilityObjectWrapperMac accessibilityPerformPressAction]):
401         (-[WebAccessibilityObjectWrapperMac accessibilityPerformIncrementAction]):
402         (-[WebAccessibilityObjectWrapperMac accessibilityPerformDecrementAction]):
403         (-[WebAccessibilityObjectWrapperMac accessibilityPerformShowMenuAction]):
404         (-[WebAccessibilityObjectWrapperMac accessibilityShowContextMenu]):
405         (-[WebAccessibilityObjectWrapperMac accessibilityPerformAction:]):
406         (-[WebAccessibilityObjectWrapperMac accessibilitySetValue:forAttribute:]):
407         (rendererForView):
408         (-[WebAccessibilityObjectWrapperMac _accessibilityParentForSubview:]):
409         (-[WebAccessibilityObjectWrapperMac accessibilityActionDescription:]):
410         (-[WebAccessibilityObjectWrapperMac doAXAttributedStringForRange:]):
411         (-[WebAccessibilityObjectWrapperMac _convertToNSRange:]):
412         (-[WebAccessibilityObjectWrapperMac _indexForTextMarker:]):
413         (-[WebAccessibilityObjectWrapperMac _textMarkerForIndex:]):
414         (-[WebAccessibilityObjectWrapperMac doAXRTFForRange:]):
415         (-[WebAccessibilityObjectWrapperMac accessibilityAttributeValue:forParameter:]):
416         (-[WebAccessibilityObjectWrapperMac accessibilitySupportsOverriddenAttributes]):
417         (-[WebAccessibilityObjectWrapperMac accessibilityShouldUseUniqueId]):
418         (-[WebAccessibilityObjectWrapperMac accessibilityIndexOfChild:]):
419         (-[WebAccessibilityObjectWrapperMac accessibilityArrayAttributeCount:]):
420         (-[WebAccessibilityObjectWrapperMac accessibilityArrayAttributeValues:index:maxCount:]):
421         ([WebAccessibilityObjectWrapperMac accessibilitySetShouldRepostNotifications:]):
422         (-[WebAccessibilityObjectWrapperMac accessibilityPostedNotification:]):
423
424 2013-02-15  Eric Carlson  <eric.carlson@apple.com>
425
426         [Mac] remove wkCaptionAppearance from WebKitSystemInterface
427         https://bugs.webkit.org/show_bug.cgi?id=109996
428
429         Reviewed by Simon Fraser.
430
431         * platform/mac/WebCoreSystemInterface.h:
432         * platform/mac/WebCoreSystemInterface.mm:
433
434 2013-02-15  Sheriff Bot  <webkit.review.bot@gmail.com>
435
436         Unreviewed, rolling out r143088.
437         http://trac.webkit.org/changeset/143088
438         https://bugs.webkit.org/show_bug.cgi?id=110000
439
440         Breaks the build (Requested by dgorbik on #webkit).
441
442         * platform/mac/WebCoreSystemInterface.h:
443         * platform/mac/WebCoreSystemInterface.mm:
444
445 2013-02-15  Chris Rogers  <crogers@google.com>
446
447         Enhance AudioBus copyFrom() and sumFrom() to be able to handle discrete and speakers up and down-mixing
448         https://bugs.webkit.org/show_bug.cgi?id=109983
449
450         Reviewed by Kenneth Russell.
451
452         The Web Audio spec has a more detailed explanation for how channels are to be up and down-mixed:
453         https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html#UpMix
454
455         This patch adds the initial support for handling ChannelInterpretation, although no
456         new JS API is yet implemented.
457
458         No new tests since no new APIs have yet been exposed.
459
460         * platform/audio/AudioBus.cpp:
461         (WebCore::AudioBus::copyFrom):
462         (WebCore):
463         (WebCore::AudioBus::sumFrom):
464         (WebCore::AudioBus::speakersCopyFrom):
465         (WebCore::AudioBus::speakersSumFrom):
466         (WebCore::AudioBus::discreteCopyFrom):
467         (WebCore::AudioBus::discreteSumFrom):
468         * platform/audio/AudioBus.h:
469         (AudioBus):
470
471 2013-02-15  Tony Chang  <tony@chromium.org>
472
473         Padding and border changes doesn't trigger relayout of children
474         https://bugs.webkit.org/show_bug.cgi?id=109639
475
476         Reviewed by Kent Tamura.
477
478         In RenderBlock::layoutBlock, we only relayout our children if our logical width
479         changes. This misses cases where our logical width doesn't change (i.e., padding
480         or border changes), but our content width does change.
481
482         Also convert the needsLayout ASSERT into the if statement. This is because
483         RenderScrollbarPart can change border widths and not need a layout if the scrollbar
484         doesn't have a parent. In this case, we don't need to set any children for layout.
485
486         This is a more general case of bug 104997.
487
488         Test: fast/block/dynamic-padding-border.html
489
490         * rendering/RenderBox.cpp:
491         (WebCore::borderOrPaddingLogicalWidthChanged): Only check if the logical width changed.
492         (WebCore::RenderBox::styleDidChange): Drop the border-box condition since this can happen
493         even without border-box box sizing.
494
495 2013-02-15  Mark Lam  <mark.lam@apple.com>
496
497         Split SQLStatement work between the frontend and backend.
498         https://bugs.webkit.org/show_bug.cgi?id=104751.
499
500         Reviewed by Geoffrey Garen.
501
502         This is part of the webdatabase refactoring for webkit2.
503
504         1. Copied SQLTransaction to SQLTransactionBackend, and then reduce the
505            2 to only handle frontend and backend work respectively.
506
507         2. Changed how statements are created.
508
509            - SQLTransaction::executeSQL() first creates a SQLStatement frontend
510              which encapsulates the 2 script callbacks. It then passes the
511              SQLStatement to the backend database to create the
512              SQLStatementBackend.
513            - The SQLStatementBackend manages all sqlite work.
514
515         3. Remove the Database::reportExecuteStatementResult() wrapper because
516            it is only needed in the backend now.
517
518         4. Added new files to the build / project files.
519
520         5. Updated / added comments about how the SQLStatement life-cycle works.
521
522         No new tests.
523
524         * CMakeLists.txt:
525         * GNUmakefile.list.am:
526         * Modules/webdatabase/Database.cpp:
527         * Modules/webdatabase/Database.h:
528         (Database):
529         (WebCore::Database::reportCommitTransactionResult):
530         * Modules/webdatabase/DatabaseBackend.h:
531         (DatabaseBackend):
532         * Modules/webdatabase/SQLStatement.cpp:
533         (WebCore::SQLStatement::create):
534         (WebCore::SQLStatement::SQLStatement):
535         (WebCore::SQLStatement::setBackend):
536         (WebCore::SQLStatement::hasCallback):
537         (WebCore::SQLStatement::hasErrorCallback):
538         (WebCore::SQLStatement::performCallback):
539         * Modules/webdatabase/SQLStatement.h:
540         (SQLStatement):
541         * Modules/webdatabase/SQLStatementBackend.cpp: Copied from Source/WebCore/Modules/webdatabase/SQLStatement.cpp.
542         (WebCore::SQLStatementBackend::create):
543         (WebCore::SQLStatementBackend::SQLStatementBackend):
544         (WebCore::SQLStatementBackend::frontend):
545         (WebCore::SQLStatementBackend::sqlError):
546         (WebCore::SQLStatementBackend::sqlResultSet):
547         (WebCore::SQLStatementBackend::execute):
548         (WebCore::SQLStatementBackend::setDatabaseDeletedError):
549         (WebCore::SQLStatementBackend::setVersionMismatchedError):
550         (WebCore::SQLStatementBackend::setFailureDueToQuota):
551         (WebCore::SQLStatementBackend::clearFailureDueToQuota):
552         (WebCore::SQLStatementBackend::lastExecutionFailedDueToQuota):
553         * Modules/webdatabase/SQLStatementBackend.h: Copied from Source/WebCore/Modules/webdatabase/SQLStatement.h.
554         (SQLStatementBackend):
555         (WebCore::SQLStatementBackend::hasStatementCallback):
556         (WebCore::SQLStatementBackend::hasStatementErrorCallback):
557         * Modules/webdatabase/SQLTransaction.cpp:
558         (WebCore::SQLTransaction::deliverStatementCallback):
559         (WebCore::SQLTransaction::deliverQuotaIncreaseCallback):
560         (WebCore::SQLTransaction::executeSQL):
561         * Modules/webdatabase/SQLTransactionBackend.cpp:
562         (WebCore::SQLTransactionBackend::doCleanup):
563         (WebCore::SQLTransactionBackend::currentStatement):
564         (WebCore::SQLTransactionBackend::enqueueStatementBackend):
565         (WebCore::SQLTransactionBackend::executeSQL):
566         (WebCore::SQLTransactionBackend::runStatements):
567         (WebCore::SQLTransactionBackend::getNextStatement):
568         (WebCore::SQLTransactionBackend::runCurrentStatementAndGetNextState):
569         (WebCore::SQLTransactionBackend::nextStateForCurrentStatementError):
570         * Modules/webdatabase/SQLTransactionBackend.h:
571         (SQLTransactionBackend):
572         * Target.pri:
573         * WebCore.gypi:
574         * WebCore.vcproj/WebCore.vcproj:
575         * WebCore.vcxproj/WebCore.vcxproj:
576         * WebCore.vcxproj/WebCore.vcxproj.filters:
577         * WebCore.xcodeproj/project.pbxproj:
578
579 2013-02-15  Elliott Sprehn  <esprehn@chromium.org>
580
581         Rename HasCustomCallbacks to HasCustomStyleCallbacks
582         https://bugs.webkit.org/show_bug.cgi?id=109982
583
584         Reviewed by Eric Seidel.
585
586         Now that inside ChildFrameDisconnector we only call isFrameOwnerElement()
587         on elements that report having descendants (or themselves) have connected
588         frames we don't need to be as agressive about avoiding the virtual call
589         to isFrameOwnerElement() which lets us rename hasCustomCallbacks to
590         hasCustomStyleCallbacks to better reflect it's purpose.
591
592         * dom/ContainerNodeAlgorithms.h:
593         (WebCore::ChildFrameDisconnector::collectFrameOwners):
594         * dom/Element.cpp:
595         (WebCore::Element::styleForRenderer):
596         (WebCore::Element::recalcStyle):
597         (WebCore::Element::willRecalcStyle):
598         (WebCore::Element::didRecalcStyle):
599         (WebCore::Element::customStyleForRenderer):
600         * dom/Node.h:
601         (WebCore::Node::pseudoId):
602         (WebCore::Node::hasCustomStyleCallbacks):
603         (WebCore::Node::customPseudoId):
604         (WebCore::Node::setHasCustomStyleCallbacks):
605         * dom/PseudoElement.cpp:
606         (WebCore::PseudoElement::PseudoElement):
607         * dom/ShadowRoot.cpp:
608         (WebCore::ShadowRoot::recalcStyle):
609         * html/HTMLFormControlElement.cpp:
610         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
611         * html/HTMLFrameOwnerElement.cpp:
612         (WebCore::HTMLFrameOwnerElement::HTMLFrameOwnerElement):
613         (WebCore::HTMLFrameOwnerElement::disconnectContentFrame):
614         * html/HTMLFrameSetElement.cpp:
615         (WebCore::HTMLFrameSetElement::HTMLFrameSetElement):
616         * html/HTMLIFrameElement.cpp:
617         (WebCore::HTMLIFrameElement::HTMLIFrameElement):
618         * html/HTMLInputElement.cpp:
619         (WebCore::HTMLInputElement::HTMLInputElement):
620         * html/HTMLMediaElement.cpp:
621         (WebCore::HTMLMediaElement::HTMLMediaElement):
622         * html/HTMLOptGroupElement.cpp:
623         (WebCore::HTMLOptGroupElement::HTMLOptGroupElement):
624         * html/HTMLOptionElement.cpp:
625         (WebCore::HTMLOptionElement::HTMLOptionElement):
626         * html/HTMLPlugInImageElement.cpp:
627         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
628         * html/shadow/DateTimeEditElement.cpp:
629         (WebCore::DateTimeEditElement::DateTimeEditElement):
630         * html/shadow/TextControlInnerElements.cpp:
631         (WebCore::TextControlInnerElement::TextControlInnerElement):
632         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
633         * html/shadow/TextFieldDecorationElement.cpp:
634         (WebCore::TextFieldDecorationElement::TextFieldDecorationElement):
635         * svg/SVGElement.cpp:
636         (WebCore::SVGElement::SVGElement):
637         * svg/SVGUseElement.cpp:
638         (WebCore::SVGUseElement::SVGUseElement):
639
640 2013-02-15  Eric Carlson  <eric.carlson@apple.com>
641
642         [Mac] remove wkCaptionAppearance from WebKitSystemInterface
643         https://bugs.webkit.org/show_bug.cgi?id=109996
644
645         Reviewed by Simon Fraser.
646
647         * platform/mac/WebCoreSystemInterface.h:
648         * platform/mac/WebCoreSystemInterface.mm:
649
650 2013-02-15  Andreas Kling  <akling@apple.com>
651
652         Calling DOM Element.attributes shouldn't force creation of ElementData.
653         <http://webkit.org/b/109976>
654
655         Reviewed by Darin Adler.
656
657         Don't create ElementData for an Element unnecessarily just because someone calls .attributes on it.
658         Previously, JS like this would create empty ElementData when 'element' has no attributes:
659
660             for (i = 0; i < element.attributes.length; ++i)
661                 doStuff(element.attributes[i]);
662
663         Make NamedNodeMap::length() short-circuit and return 0 if !Element::hasAttributes().
664
665         * dom/Element.cpp:
666         (WebCore::Element::attributes):
667         * dom/NamedNodeMap.cpp:
668         (WebCore::NamedNodeMap::length):
669
670 2013-02-15  Kentaro Hara  <haraken@chromium.org>
671
672         [V8] An "EvenTarget" type in IDL should be converted to EventTarget*, not to Node*
673         https://bugs.webkit.org/show_bug.cgi?id=109895
674
675         Reviewed by Adam Barth.
676
677         Currently an "EventTarget" type in IDL is converted to Node*.
678         This is wrong because there are non-Node interfaces that inherit
679         a EventTarget. We should convert an "EventTarget" type to EventTarget*.
680         This will fix FIXMEs in CodeGeneratorV8.pm.
681
682         * bindings/scripts/CodeGeneratorV8.pm:
683         (GetNativeType):
684         (JSValueToNative):
685
686 2013-02-15  Simon Fraser  <simon.fraser@apple.com>
687
688         REGRESSION (r142505?): Crashes in WebCore::ScrollingStateNode::appendChild when using back/forward buttons
689         https://bugs.webkit.org/show_bug.cgi?id=109826
690         <rdar://problem/13216100>
691
692         Reviewed by Beth Dakin.
693
694         Fix a crash when going Back on some pages with fixed position elements.
695         
696         When a page was being restored from the page cache, and a layout from
697         FrameLoader::commitProvisionalLoad() caused us to try to register the fixed
698         position layer before the main scrolling layer, we'd crash trying to dereference
699         the root node.
700         
701         Fix by bailing from ScrollingStateTree::attachNode() if we can't find the parent
702         node.
703
704         Test: platform/mac-wk2/tiled-drawing/null-parent-back-crash.html
705
706         * page/scrolling/ScrollingStateTree.cpp:
707         (WebCore::ScrollingStateTree::attachNode):
708         (WebCore::ScrollingStateTree::stateNodeForID):
709         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
710         (WebCore::ScrollingCoordinatorMac::updateViewportConstrainedNode):
711
712 2013-02-15  Simon Fraser  <simon.fraser@apple.com>
713
714         Constrain fixed layers to the viewport, not the document
715         https://bugs.webkit.org/show_bug.cgi?id=109646
716
717         Reviewed by Beth Dakin.
718         
719         It's bad to constrain position:fixed compositing layers to the
720         document rect, because their bounds will change every time the scroll
721         position changes, and we're not good currently at synchronizing scrolling
722         thread layer updates with main thread layer updates, so jiggles ensue.
723         
724         Fix by constraining position:fixed layers to the viewport.
725
726         Test: compositing/geometry/limit-layer-bounds-fixed.html
727
728         * rendering/RenderLayerBacking.cpp:
729         (WebCore::RenderLayerBacking::updateCompositedBounds):
730
731 2013-02-13  Jer Noble  <jer.noble@apple.com>
732
733         Add a CDMClient class which allows the CDM to query for the currently attached MediaPlayer.
734         https://bugs.webkit.org/show_bug.cgi?id=109702
735
736         Reviewed by Eric Carlson.
737
738         Some CDM implementations will need to work closely with an associated
739         MediaPlayer in order to generate key requests and provide keys. Add a
740         client protocol to be implemented by the MediaKeys object which can
741         provide access to the associated MediaPlayer if present.
742
743         * Modules/encryptedmedia/CDM.cpp:
744         (WebCore::CDM::CDM): Initialize the m_client ivar.
745         (WebCore::CDM::mediaPlayer): Pass to the client, if present.
746         * Modules/encryptedmedia/CDM.h:
747         (WebCore::CDM::client): Simple getter.
748         (WebCore::CDM::setClient): Simple setter.
749         * Modules/encryptedmedia/MediaKeys.cpp:
750         (WebCore::MediaKeys::MediaKeys): Initialize the m_mediaElement ivar
751             and call setClient() on the passed in CDM.
752         (WebCore::MediaKeys::setMediaElement): Simple setter.
753         (WebCore::MediaKeys::cdmMediaPlayer): Retrieve the MediaPlayer from
754             the m_mediaElement if present.
755         * Modules/encryptedmedia/MediaKeys.h:
756         * html/HTMLMediaElement.cpp:
757         (WebCore::HTMLMediaElement::~HTMLMediaElement): Call setMediaKeys(0)
758             to clear the mediaElement in any associated MediaKeys.
759         (WebCore::HTMLMediaElement::setMediaKeys): Clear the mediaElement on
760             any associated MediaKeys, and set the mediaElement on the newly
761             associated MediaKeys.
762
763 2013-02-15  Simon Fraser  <simon.fraser@apple.com>
764
765         drop-shadow filter with overflow:hidden child misbehaves
766         https://bugs.webkit.org/show_bug.cgi?id=109783
767
768         Reviewed by Dean Jackson.
769         
770         The change in r112745 was not sufficient; it failed to account
771         for descendant layers that needed to not clipping to avoid artefacts
772         with filters like drop-shadow.
773
774         Test: css3/filters/filter-repaint-shadow-layer-child.html
775
776         * rendering/RenderLayer.cpp:
777         (WebCore::RenderLayer::paintLayerContents): Remove the useClipRect bool.
778         Replace it with a clipToDirtyRect member on the LayerPaintingInfo, which
779         gets passed to descendants. Remove some "Restore the clip" comments that added
780         nothing.
781         * rendering/RenderLayer.h:
782         (WebCore::RenderLayer::LayerPaintingInfo::LayerPaintingInfo):
783         (LayerPaintingInfo):
784
785 2013-02-15  Sheriff Bot  <webkit.review.bot@gmail.com>
786
787         Unreviewed, rolling out r143066.
788         http://trac.webkit.org/changeset/143066
789         https://bugs.webkit.org/show_bug.cgi?id=109986
790
791         Broke the Apple Lion build (among others). (Requested by
792         ddkilzer on #webkit).
793
794         * accessibility/mac/AXObjectCacheMac.mm:
795         (WebCore::AXObjectCache::attachWrapper):
796         * accessibility/mac/WebAccessibilityObjectWrapper.h:
797         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
798         (-[WebAccessibilityObjectWrapper unregisterUniqueIdForUIElement]):
799         (-[WebAccessibilityObjectWrapper detach]):
800         (-[WebAccessibilityObjectWrapper accessibilityObject]):
801         (-[WebAccessibilityObjectWrapper attachmentView]):
802         (CFAutoreleaseHelper):
803         (AXObjectIsTextMarker):
804         (AXObjectIsTextMarkerRange):
805         (AXTextMarkerRange):
806         (AXTextMarkerRangeStart):
807         (AXTextMarkerRangeEnd):
808         (SearchKeyEntry):
809         (createAccessibilitySearchKeyMap):
810         (accessibilitySearchKeyForString):
811         (textMarkerForVisiblePosition):
812         (-[WebAccessibilityObjectWrapper textMarkerForVisiblePosition:]):
813         (visiblePositionForTextMarker):
814         (-[WebAccessibilityObjectWrapper visiblePositionForTextMarker:]):
815         (visiblePositionForStartOfTextMarkerRange):
816         (visiblePositionForEndOfTextMarkerRange):
817         (textMarkerRangeFromMarkers):
818         (AXAttributedStringRangeIsValid):
819         (AXAttributeStringSetFont):
820         (CreateCGColorIfDifferent):
821         (AXAttributeStringSetColor):
822         (AXAttributeStringSetNumber):
823         (AXAttributeStringSetStyle):
824         (AXAttributeStringSetBlockquoteLevel):
825         (AXAttributeStringSetSpelling):
826         (AXAttributeStringSetHeadingLevel):
827         (AXAttributeStringSetElement):
828         (AXAttributedStringAppendText):
829         (nsStringForReplacedNode):
830         (-[WebAccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:]):
831         (textMarkerRangeFromVisiblePositions):
832         (-[WebAccessibilityObjectWrapper textMarkerRangeFromVisiblePositions:endPosition:]):
833         (-[WebAccessibilityObjectWrapper accessibilityActionNames]):
834         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
835         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
836         (-[WebAccessibilityObjectWrapper visiblePositionRangeForTextMarkerRange:]):
837         (-[WebAccessibilityObjectWrapper renderWidgetChildren]):
838         (-[WebAccessibilityObjectWrapper remoteAccessibilityParentObject]):
839         (convertToVector):
840         (convertToNSArray):
841         (-[WebAccessibilityObjectWrapper textMarkerRangeForSelection]):
842         (-[WebAccessibilityObjectWrapper position]):
843         (createAccessibilityRoleMap):
844         (roleValueToNSString):
845         (-[WebAccessibilityObjectWrapper role]):
846         (-[WebAccessibilityObjectWrapper subrole]):
847         (-[WebAccessibilityObjectWrapper roleDescription]):
848         (-[WebAccessibilityObjectWrapper scrollViewParent]):
849         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
850         (-[WebAccessibilityObjectWrapper accessibilityFocusedUIElement]):
851         (-[WebAccessibilityObjectWrapper accessibilityHitTest:]):
852         (-[WebAccessibilityObjectWrapper accessibilityIsAttributeSettable:]):
853         (-[WebAccessibilityObjectWrapper accessibilityIsIgnored]):
854         (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
855         (-[WebAccessibilityObjectWrapper accessibilityPerformPressAction]):
856         (-[WebAccessibilityObjectWrapper accessibilityPerformIncrementAction]):
857         (-[WebAccessibilityObjectWrapper accessibilityPerformDecrementAction]):
858         (-[WebAccessibilityObjectWrapper accessibilityPerformShowMenuAction]):
859         (-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
860         (-[WebAccessibilityObjectWrapper accessibilityPerformAction:]):
861         (-[WebAccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
862         (rendererForView):
863         (-[WebAccessibilityObjectWrapper _accessibilityParentForSubview:]):
864         (-[WebAccessibilityObjectWrapper accessibilityActionDescription:]):
865         (-[WebAccessibilityObjectWrapper doAXAttributedStringForRange:]):
866         (-[WebAccessibilityObjectWrapper _convertToNSRange:]):
867         (-[WebAccessibilityObjectWrapper _indexForTextMarker:]):
868         (-[WebAccessibilityObjectWrapper _textMarkerForIndex:]):
869         (-[WebAccessibilityObjectWrapper doAXRTFForRange:]):
870         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
871         (-[WebAccessibilityObjectWrapper accessibilitySupportsOverriddenAttributes]):
872         (-[WebAccessibilityObjectWrapper accessibilityShouldUseUniqueId]):
873         (-[WebAccessibilityObjectWrapper accessibilityIndexOfChild:]):
874         (-[WebAccessibilityObjectWrapper accessibilityArrayAttributeCount:]):
875         (-[WebAccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
876         * accessibility/mac/WebAccessibilityObjectWrapperMac.h: Removed.
877         * accessibility/mac/WebAccessibilityObjectWrapperMac.m: Removed.
878
879 2013-02-15  Emil A Eklund  <eae@chromium.org>
880
881         Change MouseRelatedEvent to use LayoutPoint::scale
882         https://bugs.webkit.org/show_bug.cgi?id=109979
883
884         Reviewed by Dimitri Glazkov.
885         
886         Change MouseRelatedEvent::MouseRelatedEvent to use LayoutPoint::
887         scale to adjust location and scroll offset for scale factor and
888         zooming.
889
890         No new tests, no change in functionality.
891
892         * dom/MouseRelatedEvent.cpp:
893         (WebCore::MouseRelatedEvent::MouseRelatedEvent):
894
895 2013-02-15  Chris Fleizach  <cfleizach@apple.com>
896
897         AX: Split WebAccessibilityObjectWrapper so code can be shared with iOS
898         https://bugs.webkit.org/show_bug.cgi?id=109849
899
900         Reviewed by David Kilzer.
901
902         Split up the WebAccessibilityObjectWrapper so that iOS can share more 
903         code with MacOS. I imagine over time, more code will move into this base class,
904         but for now this will be a good start.
905
906         A base class called WebAccessibilityObjectWrapper now exists, and Mac has a subclass
907         of that. iOS will be able to do the same.
908
909         * WebCore.xcodeproj/project.pbxproj:
910         * accessibility/mac/AXObjectCacheMac.mm:
911         (WebCore::AXObjectCache::attachWrapper):
912         * accessibility/mac/WebAccessibilityObjectWrapper.h:
913         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
914         (-[WebAccessibilityObjectWrapper detach]):
915         (-[WebAccessibilityObjectWrapper attachmentView]):
916         (-[WebAccessibilityObjectWrapper accessibilityObject]):
917         (-[WebAccessibilityObjectWrapper accessibilityPostedNotification:]):
918         (-[WebAccessibilityObjectWrapper titleTagShouldBeUsedInDescriptionField]):
919         (-[WebAccessibilityObjectWrapper accessibilityTitle]):
920         (-[WebAccessibilityObjectWrapper accessibilityDescription]):
921         (-[WebAccessibilityObjectWrapper accessibilityHelpText]):
922         * accessibility/mac/WebAccessibilityObjectWrapperMac.h: Added.
923         * accessibility/mac/WebAccessibilityObjectWrapperMac.m: Added.
924         (std):
925         (-[WebAccessibilityObjectWrapperMac detach]):
926         (-[WebAccessibilityObjectWrapperMac attachmentView]):
927         (CFAutoreleaseHelper):
928         (AXObjectIsTextMarker):
929         (AXObjectIsTextMarkerRange):
930         (AXTextMarkerRange):
931         (AXTextMarkerRangeStart):
932         (AXTextMarkerRangeEnd):
933         (SearchKeyEntry):
934         (createAccessibilitySearchKeyMap):
935         (accessibilitySearchKeyForString):
936         (textMarkerForVisiblePosition):
937         (-[WebAccessibilityObjectWrapperMac textMarkerForVisiblePosition:]):
938         (visiblePositionForTextMarker):
939         (-[WebAccessibilityObjectWrapperMac visiblePositionForTextMarker:]):
940         (visiblePositionForStartOfTextMarkerRange):
941         (visiblePositionForEndOfTextMarkerRange):
942         (textMarkerRangeFromMarkers):
943         (AXAttributedStringRangeIsValid):
944         (AXAttributeStringSetFont):
945         (CreateCGColorIfDifferent):
946         (AXAttributeStringSetColor):
947         (AXAttributeStringSetNumber):
948         (AXAttributeStringSetStyle):
949         (AXAttributeStringSetBlockquoteLevel):
950         (AXAttributeStringSetSpelling):
951         (AXAttributeStringSetHeadingLevel):
952         (AXAttributeStringSetElement):
953         (AXAttributedStringAppendText):
954         (nsStringForReplacedNode):
955         (-[WebAccessibilityObjectWrapperMac doAXAttributedStringForTextMarkerRange:]):
956         (textMarkerRangeFromVisiblePositions):
957         (-[WebAccessibilityObjectWrapperMac textMarkerRangeFromVisiblePositions:endPosition:]):
958         (-[WebAccessibilityObjectWrapperMac accessibilityActionNames]):
959         (-[WebAccessibilityObjectWrapperMac additionalAccessibilityAttributeNames]):
960         (-[WebAccessibilityObjectWrapperMac accessibilityAttributeNames]):
961         (-[WebAccessibilityObjectWrapperMac visiblePositionRangeForTextMarkerRange:]):
962         (-[WebAccessibilityObjectWrapperMac renderWidgetChildren]):
963         (-[WebAccessibilityObjectWrapperMac remoteAccessibilityParentObject]):
964         (convertToVector):
965         (convertToNSArray):
966         (-[WebAccessibilityObjectWrapperMac textMarkerRangeForSelection]):
967         (-[WebAccessibilityObjectWrapperMac position]):
968         (createAccessibilityRoleMap):
969         (roleValueToNSString):
970         (-[WebAccessibilityObjectWrapperMac role]):
971         (-[WebAccessibilityObjectWrapperMac subrole]):
972         (-[WebAccessibilityObjectWrapperMac roleDescription]):
973         (-[WebAccessibilityObjectWrapperMac scrollViewParent]):
974         (-[WebAccessibilityObjectWrapperMac titleTagShouldBeUsedInDescriptionField]):
975         (-[WebAccessibilityObjectWrapperMac accessibilityTitle]):
976         (-[WebAccessibilityObjectWrapperMac accessibilityDescription]):
977         (-[WebAccessibilityObjectWrapperMac accessibilityHelpText]):
978         (-[WebAccessibilityObjectWrapperMac accessibilityAttributeValue:]):
979         (-[WebAccessibilityObjectWrapperMac accessibilityFocusedUIElement]):
980         (-[WebAccessibilityObjectWrapperMac accessibilityHitTest:]):
981         (-[WebAccessibilityObjectWrapperMac accessibilityIsAttributeSettable:]):
982         (-[WebAccessibilityObjectWrapperMac accessibilityIsIgnored]):
983         (-[WebAccessibilityObjectWrapperMac accessibilityParameterizedAttributeNames]):
984         (-[WebAccessibilityObjectWrapperMac accessibilityPerformPressAction]):
985         (-[WebAccessibilityObjectWrapperMac accessibilityPerformIncrementAction]):
986         (-[WebAccessibilityObjectWrapperMac accessibilityPerformDecrementAction]):
987         (-[WebAccessibilityObjectWrapperMac accessibilityPerformShowMenuAction]):
988         (-[WebAccessibilityObjectWrapperMac accessibilityShowContextMenu]):
989         (-[WebAccessibilityObjectWrapperMac accessibilityPerformAction:]):
990         (-[WebAccessibilityObjectWrapperMac accessibilitySetValue:forAttribute:]):
991         (rendererForView):
992         (-[WebAccessibilityObjectWrapperMac _accessibilityParentForSubview:]):
993         (-[WebAccessibilityObjectWrapperMac accessibilityActionDescription:]):
994         (-[WebAccessibilityObjectWrapperMac doAXAttributedStringForRange:]):
995         (-[WebAccessibilityObjectWrapperMac _convertToNSRange:]):
996         (-[WebAccessibilityObjectWrapperMac _indexForTextMarker:]):
997         (-[WebAccessibilityObjectWrapperMac _textMarkerForIndex:]):
998         (-[WebAccessibilityObjectWrapperMac doAXRTFForRange:]):
999         (-[WebAccessibilityObjectWrapperMac accessibilityAttributeValue:forParameter:]):
1000         (-[WebAccessibilityObjectWrapperMac accessibilitySupportsOverriddenAttributes]):
1001         (-[WebAccessibilityObjectWrapperMac accessibilityShouldUseUniqueId]):
1002         (-[WebAccessibilityObjectWrapperMac accessibilityIndexOfChild:]):
1003         (-[WebAccessibilityObjectWrapperMac accessibilityArrayAttributeCount:]):
1004         (-[WebAccessibilityObjectWrapperMac accessibilityArrayAttributeValues:index:maxCount:]):
1005         ([WebAccessibilityObjectWrapperMac accessibilitySetShouldRepostNotifications:]):
1006         (-[WebAccessibilityObjectWrapperMac accessibilityPostedNotification:]):
1007
1008 2013-02-15  Elliott Sprehn  <esprehn@chromium.org>
1009
1010         RenderQuote should not mark renderers as needing layout during layout
1011         https://bugs.webkit.org/show_bug.cgi?id=109876
1012
1013         Reviewed by Ojan Vafai.
1014
1015         Marking RenderQuotes as needing pref width recalcs and layouts during a
1016         layout is dangerous since an ancestor may mark itself as having completed
1017         layout, but then some subtree still thinks it needs layout.
1018
1019         Instead, since the only time we create RenderQuote instances is inside
1020         PseudoElement, we can call attachQuote inside PseudoElement::attach during
1021         the regular tree mutating cycle. We can then use RenderQuote::styleDidChange
1022         to update the kind of quotes on normal style changes.
1023
1024         This makes RenderQuote behave much more similarly to DOM nodes and means
1025         we no longer need to set dirty bits during layout.
1026
1027         Test: fast/css-generated-content/quote-layout-focus-crash.html
1028
1029         * dom/PseudoElement.cpp:
1030         (WebCore::PseudoElement::attach): Now call attachQuote().
1031         * rendering/RenderQuote.cpp:
1032         (WebCore::RenderQuote::~RenderQuote):
1033         (WebCore::RenderQuote::willBeRemovedFromTree):
1034         (WebCore::RenderQuote::styleDidChange):
1035         (WebCore::RenderQuote::updateText):
1036         (WebCore::RenderQuote::attachQuote):
1037         (WebCore::RenderQuote::detachQuote):
1038         (WebCore::RenderQuote::updateDepth):
1039         * rendering/RenderQuote.h:
1040         (RenderQuote):
1041
1042 2013-02-15  Sheriff Bot  <webkit.review.bot@gmail.com>
1043
1044         Unreviewed, rolling out r143044.
1045         http://trac.webkit.org/changeset/143044
1046         https://bugs.webkit.org/show_bug.cgi?id=109974
1047
1048         broke windows build (Requested by kling on #webkit).
1049
1050         * dom/DocumentSharedObjectPool.cpp:
1051         (WebCore::DocumentSharedObjectPool::cachedShareableElementDataWithAttributes):
1052         * dom/Element.cpp:
1053         (WebCore::sizeForShareableElementDataWithAttributeCount):
1054         (WebCore::ShareableElementData::ShareableElementData):
1055         (WebCore::ShareableElementData::~ShareableElementData):
1056         (WebCore::UniqueElementData::UniqueElementData):
1057         * dom/Element.h:
1058         (WebCore::ShareableElementData::immutableAttributeArray):
1059         (ShareableElementData):
1060         (WebCore::ElementData::attributeItem):
1061
1062 2013-02-15  Adam Barth  <abarth@webkit.org>
1063
1064         Enable the preload scanner on the background parser thread
1065         https://bugs.webkit.org/show_bug.cgi?id=108027
1066
1067         Reviewed by Tony Gentilcore.
1068
1069         The patch causes us to pass all the fast/preloader tests with the
1070         threaded parser enabled.
1071
1072         This patch wires up the BackgroundHTMLParser to the
1073         TokenPreloadScanner.  Currently, we bail out of preload scanning if we
1074         encounter a document.write becaues we don't know how to rewind the
1075         preload scanner, but that's something we can tune in the future.
1076
1077         The BackgroundHTMLParser delivers the preloads to the
1078         HTMLDocumentParser together with the token stream. If the
1079         HTMLDocumentParser isn't able to use the token stream immediately, it
1080         kicks off the preloads.
1081
1082         * html/parser/BackgroundHTMLParser.cpp:
1083         (WebCore::checkThatPreloadsAreSafeToSendToAnotherThread):
1084         (WebCore::BackgroundHTMLParser::BackgroundHTMLParser):
1085         (WebCore::BackgroundHTMLParser::resumeFrom):
1086         (WebCore::BackgroundHTMLParser::pumpTokenizer):
1087         (WebCore::BackgroundHTMLParser::sendTokensToMainThread):
1088         * html/parser/BackgroundHTMLParser.h:
1089         (Configuration):
1090             - We need to add a struct for the create function because the
1091               number of arguments exceeds the limits of Functional.h.
1092         (BackgroundHTMLParser):
1093         (WebCore::BackgroundHTMLParser::create):
1094         * html/parser/CSSPreloadScanner.cpp:
1095         (WebCore::CSSPreloadScanner::scanCommon):
1096         (WebCore::CSSPreloadScanner::scan):
1097         (WebCore::CSSPreloadScanner::emitRule):
1098             - We need to use a new string here so that the string is safe to
1099               send to another thread.
1100         * html/parser/CSSPreloadScanner.h:
1101         (CSSPreloadScanner):
1102         * html/parser/HTMLDocumentParser.cpp:
1103         (WebCore::HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser):
1104         (WebCore::HTMLDocumentParser::startBackgroundParser):
1105             - Following the example of the XSSAuditor, we create the
1106               TokenPreloadScanner on the main thread and then send it to the
1107               background thread for operation.
1108         * html/parser/HTMLDocumentParser.h:
1109         (WebCore):
1110         (ParsedChunk):
1111         * html/parser/HTMLParserOptions.h:
1112         (HTMLParserOptions):
1113             - We need to add a default constructor so that the
1114               HTMLDocumentParser can create an empty
1115               BackgroundHTMLParser::Configuration struct.
1116         * html/parser/HTMLPreloadScanner.cpp:
1117         (WebCore::TokenPreloadScanner::scan):
1118         (WebCore::TokenPreloadScanner::scanCommon):
1119         (WebCore::HTMLPreloadScanner::scan):
1120         * html/parser/HTMLPreloadScanner.h:
1121         (TokenPreloadScanner):
1122         (WebCore::TokenPreloadScanner::isSafeToSendToAnotherThread):
1123         * html/parser/HTMLResourcePreloader.cpp:
1124         (WebCore::HTMLResourcePreloader::takeAndPreload):
1125         (WebCore):
1126         * html/parser/HTMLResourcePreloader.h:
1127         (WebCore::PreloadRequest::PreloadRequest):
1128         (WebCore):
1129         (HTMLResourcePreloader):
1130
1131 2013-02-15  Ryosuke Niwa  <rniwa@webkit.org>
1132
1133         Build fix after r143030. We need to keep updatedRange around until createMarkupInternal returns.
1134
1135         * editing/markup.cpp:
1136         (WebCore::createMarkup):
1137
1138 2013-02-15  Rik Cabanier  <cabanier@adobe.com>
1139
1140         Add platform support for -webkit-background-blend-mode to CG context
1141         https://bugs.webkit.org/show_bug.cgi?id=108549
1142
1143         Reviewed by Dean Jackson.
1144
1145         Tests: css3/compositing/effect-background-blend-mode-stacking.html
1146                css3/compositing/effect-background-blend-mode.html
1147
1148         This patch adds support for blending on background images to the Core Graphics port of WebKit.
1149
1150         * platform/graphics/CrossfadeGeneratedImage.cpp: Added interface change for blending.
1151         (WebCore::CrossfadeGeneratedImage::drawPattern):
1152         * platform/graphics/CrossfadeGeneratedImage.h: Added interface change for blending.
1153         (CrossfadeGeneratedImage):
1154         * platform/graphics/GeneratedImage.h: Added interface change for blending.
1155         (GeneratedImage):
1156         * platform/graphics/GeneratorGeneratedImage.cpp: Added interface change for blending.
1157         (WebCore::GeneratorGeneratedImage::drawPattern):
1158         * platform/graphics/GeneratorGeneratedImage.h: Added interface change for blending.
1159         (GeneratorGeneratedImage):
1160         * platform/graphics/GraphicsContext.cpp: Added interface change for blending and passes blend mode to image object.
1161         (WebCore::GraphicsContext::drawTiledImage):
1162         (WebCore::GraphicsContext::blendModeOperation):
1163         (WebCore):
1164         * platform/graphics/GraphicsContext.h: Added interface change for blending.
1165         (GraphicsContext):
1166         * platform/graphics/Image.cpp: Added interface change for blending and passed it to graphics layer.
1167         (WebCore::Image::drawTiled):
1168         * platform/graphics/Image.h: Added interface change for blending.
1169         (Image):
1170         * platform/graphics/cg/ImageCG.cpp: Added interface change for blending and passed it to OS.
1171         (WebCore::Image::drawPattern):
1172         * rendering/RenderBoxModelObject.cpp: Passed blend mode when drawing background images.
1173         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1174         * platform/graphics/cairo/ImageCairo.cpp: Added interface change for blending.
1175         (WebCore::Image::drawPattern):
1176         * platform/graphics/qt/ImageQt.cpp: Added interface change for blending.
1177         (WebCore::Image::drawPattern):
1178         * platform/graphics/skia/ImageSkia.cpp: Added interface change for blending.
1179         (WebCore::Image::drawPattern):
1180         * rendering/RenderBoxModelObject.cpp: Added interface change for blending.
1181         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1182         * svg/graphics/SVGImageForContainer.cpp: Added interface change for blending.
1183         (WebCore::SVGImageForContainer::drawPattern):
1184         * svg/graphics/SVGImageForContainer.h: Added interface change for blending.
1185
1186 2013-02-14  Emil A Eklund  <eae@chromium.org>
1187
1188         Clamp span value in RenderTableCell::parse[Col|Row]SpanFromDOM
1189         https://bugs.webkit.org/show_bug.cgi?id=109878
1190
1191         Reviewed by Abhishek Arya.
1192
1193         Test: fast/table/colspan-huge-number.html
1194         
1195         Clamp colspan and rowspan values to their respective maximum
1196         supported values.
1197
1198         * rendering/RenderTableCell.cpp:
1199         (WebCore::RenderTableCell::parseColSpanFromDOM):
1200         (WebCore::RenderTableCell::parseRowSpanFromDOM):
1201
1202 2013-02-15  Andreas Kling  <akling@apple.com>
1203
1204         ShareableElementData should use zero-length array for storage.
1205         <http://webkit.org/b/109959>
1206
1207         Reviewed by Anders Carlsson.
1208
1209         Use a zero-length Attribute array instead of always casting from void* to an array.
1210         It was done this way originally because I didn't know we could sidestep the MSVC
1211         build error with some #pragma hackery.
1212
1213         * dom/DocumentSharedObjectPool.cpp:
1214         (WebCore::DocumentSharedObjectPool::cachedShareableElementDataWithAttributes):
1215         * dom/Element.cpp:
1216         (WebCore::sizeForShareableElementDataWithAttributeCount):
1217         (WebCore::ShareableElementData::ShareableElementData):
1218         (WebCore::ShareableElementData::~ShareableElementData):
1219         (WebCore::UniqueElementData::UniqueElementData):
1220         * dom/Element.h:
1221         (ShareableElementData):
1222         (WebCore::ElementData::attributeItem):
1223
1224 2013-02-14  Ojan Vafai  <ojan@chromium.org>
1225
1226         Implement RenderGrid::computeIntrinsicLogicalWidths
1227         https://bugs.webkit.org/show_bug.cgi?id=109881
1228
1229         Reviewed by Tony Chang.
1230
1231         For now this is not observable due to the FIXMEs for unimplemented bits
1232         of computePreferredLogicalWidths. But, soon, I'll be removing the computePreferredLogicalWidths
1233         override entirely and instead use RenderBlock's, which will also address the
1234         RenderGrid FIXMEs.
1235
1236         * rendering/RenderGrid.cpp:
1237         (WebCore::RenderGrid::computeIntrinsicLogicalWidths):
1238         const_cast the usages of m_grid. Alternately, we could stack allocate it, but there's disagreement on
1239         whether that's the right choice. See https://bugs.webkit.org/show_bug.cgi?id=109880.
1240
1241         (WebCore::RenderGrid::computePreferredLogicalWidths):
1242         * rendering/RenderGrid.h:
1243
1244
1245 2013-02-15  Xueqing Huang  <huangxueqing@baidu.com>
1246
1247         Flexbox should ignore firstLine pseudo element.
1248         https://bugs.webkit.org/show_bug.cgi?id=104485
1249
1250         Reviewed by Tony Chang.
1251
1252         Spec[1] said that "None of the properties defined in this module
1253         apply to '::first-line' or '::first-letter' pseudo-elements." and
1254         css2[2] define "The :first-line pseudo-element can only be attached
1255         to a block container element." 
1256         [1]http://dev.w3.org/csswg/css3-flexbox/#display-flex
1257         [2]http://www.w3.org/TR/CSS2/selector.html#first-line-pseudo
1258
1259         tests:
1260         css3/flexbox/flexbox-ignore-firstLine.html
1261         css3/flexbox/flexitem-firstLine-valid.html
1262         css3/flexbox/inline-flexbox-ignore-firstLine.html 
1263
1264         * rendering/RenderBlock.cpp:
1265         (WebCore::RenderBlock::firstLineBlock):
1266
1267 2013-02-15  Alec Flett  <alecflett@chromium.org>
1268
1269         IndexedDB: Implement SharedBuffer version of put()
1270         https://bugs.webkit.org/show_bug.cgi?id=109092
1271
1272         Reviewed by Adam Barth.
1273
1274         Switch IDBDatabaseBackendInterface::put over
1275         to SharedBuffer, to avoid buffer copies of the value.
1276
1277         No new tests, this is a refactor.
1278
1279         * Modules/indexeddb/IDBBackingStore.cpp:
1280         (WebCore::IDBBackingStore::putRecord):
1281         * Modules/indexeddb/IDBBackingStore.h:
1282         (WebCore):
1283         (IDBBackingStore):
1284         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
1285         (WebCore::PutOperation::create):
1286         (WebCore::PutOperation::PutOperation):
1287         (PutOperation):
1288         (WebCore::IDBDatabaseBackendImpl::put):
1289         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
1290         (IDBDatabaseBackendImpl):
1291         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
1292         (WebCore):
1293         * Modules/indexeddb/IDBObjectStore.cpp:
1294         (WebCore::IDBObjectStore::put):
1295
1296 2013-02-15  Anders Carlsson  <andersca@apple.com>
1297
1298         Implement StorageAreaProxy::length
1299         https://bugs.webkit.org/show_bug.cgi?id=109962
1300
1301         Reviewed by Andreas Kling.
1302
1303         Export a symbol needed by WebKit2.
1304
1305         * WebCore.exp.in:
1306
1307 2013-02-15  Anders Carlsson  <andersca@apple.com>
1308
1309         Remove const from a bunch of StorageArea member functions
1310         https://bugs.webkit.org/show_bug.cgi?id=109957
1311
1312         Reviewed by Beth Dakin.
1313
1314         StorageArea is an abstract base class, and its subclasses might want to mutate the object
1315         when certain member functions are called so remove const from all member functions.
1316
1317         * storage/StorageArea.h:
1318         (WebCore):
1319         (StorageArea):
1320         (WebCore::StorageArea::~StorageArea):
1321         (WebCore::StorageArea::incrementAccessCount):
1322         (WebCore::StorageArea::decrementAccessCount):
1323         (WebCore::StorageArea::closeDatabaseIfIdle):
1324         * storage/StorageAreaImpl.cpp:
1325         (WebCore::StorageAreaImpl::canAccessStorage):
1326         (WebCore::StorageAreaImpl::length):
1327         (WebCore::StorageAreaImpl::key):
1328         (WebCore::StorageAreaImpl::getItem):
1329         (WebCore::StorageAreaImpl::contains):
1330         (WebCore::StorageAreaImpl::memoryBytesUsedByCache):
1331         * storage/StorageAreaImpl.h:
1332         (StorageAreaImpl):
1333
1334 2013-02-13  Ryosuke Niwa  <rniwa@webkit.org>
1335
1336         DeleteButtonController::enable and disable should be called via a RAII object
1337         https://bugs.webkit.org/show_bug.cgi?id=109550
1338
1339         Reviewed by Enrica Casucci.
1340
1341         Added DeleteButtonControllerDisableScope, a friend class of DeleteButtonController,
1342         and made DeleteButtonController::enable/disable private.
1343
1344         * dom/ContainerNode.cpp:
1345         * editing/CompositeEditCommand.cpp:
1346         (WebCore::EditCommandComposition::unapply):
1347         (WebCore::EditCommandComposition::reapply):
1348         (WebCore::CompositeEditCommand::apply):
1349         * editing/DeleteButtonController.h:
1350         (WebCore):
1351         (DeleteButtonController):
1352         (DeleteButtonControllerDisableScope):
1353         (WebCore::DeleteButtonControllerDisableScope::DeleteButtonControllerDisableScope):
1354         (WebCore::DeleteButtonControllerDisableScope::~DeleteButtonControllerDisableScope):
1355         * editing/markup.cpp:
1356         (WebCore::createMarkup):
1357         (WebCore::createFragmentFromNodes):
1358
1359 2013-02-15  Max Vujovic  <mvujovic@adobe.com>
1360
1361         Add code from other branch.
1362
1363         [CSS Shaders] Parse src property in @-webkit-filter at-rules
1364         https://bugs.webkit.org/show_bug.cgi?id=109770
1365
1366         Reviewed by Dean Jackson.
1367
1368         This patch implements the parsing for the CSS src property in @-webkit-filter at-rules.
1369
1370         The Filter Effects spec [1] specifies its syntax:
1371             src: [ <uri> [format(<string>)]?]#
1372
1373         In practice, it can look like:
1374             src: url(shader.vs) format('x-shader/x-vertex'),
1375                  url(shader.fs) format('x-shader/x-fragment');
1376
1377         This src property is similar to the src property in CSS font-face rules, but a little
1378         different. The CSS Fonts spec [2] specifies:
1379             src: [ <uri> [format(<string>#)]? | <font-face-name> ]#
1380             The syntax for a <font-face-name> is a unique font face name enclosed by "local("
1381             and ")".
1382
1383         Unlike the filter src property, the font face src property accepts the local function
1384         [e.g. src: local("SomeFont");]. Also, the font face src property accepts a list of strings
1385         instead of just one string in its format function.
1386
1387         [1]: https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.html#custom-filter-src
1388         [2]: http://www.w3.org/TR/css3-fonts/#src-desc
1389
1390         Tests: css3/filters/custom-with-at-rule-syntax/parsing-src-property-invalid.html
1391                css3/filters/custom-with-at-rule-syntax/parsing-src-property-valid.html
1392
1393         * css/CSSGrammar.y.in:
1394             Set (and unset) a flag called "m_inFilterRule", which tells us if we are in a
1395             @-webkit-filter at-rule or in a @font-face at-rule when we encounter a src property.
1396             We parse the two variants of the src property separately so that we can create different
1397             objects (WebKitCSSShaderValue vs. CSSFontFaceSrcValue) and because their syntax is a
1398             little different.
1399         * css/CSSParser.cpp:
1400         (WebCore::CSSParser::CSSParser):
1401         (WebCore::CSSParser::parseValue):
1402         (WebCore::CSSParser::parseFilterRuleSrcUriAndFormat):
1403             Parses a URI and format pair found in the @-webkit-filter src property.
1404         (WebCore::CSSParser::parseFilterRuleSrc):
1405             Parse the @-webkit-filter src property.
1406         * css/CSSParser.h:
1407         (CSSParser):
1408         * css/WebKitCSSShaderValue.cpp:
1409         (WebCore::WebKitCSSShaderValue::customCssText):
1410             WebKitCSSShaderValue now has an m_format member, which needs to be included in its
1411             cssText.
1412         (WebCore::WebKitCSSShaderValue::reportDescendantMemoryUsage):
1413         * css/WebKitCSSShaderValue.h:
1414         (WebCore::WebKitCSSShaderValue::format):
1415         (WebCore::WebKitCSSShaderValue::setFormat):
1416         (WebKitCSSShaderValue):
1417
1418 2013-02-15  Eric Carlson  <eric.carlson@apple.com>
1419
1420         Crash occurs at WebCore::TextTrackList::length() when enabling closed captions in movie
1421         https://bugs.webkit.org/show_bug.cgi?id=109886
1422
1423         Reviewed by Dean Jackson.
1424
1425         No new tests, media/media-captions.html does not crash with this change.
1426
1427         * html/HTMLMediaElement.cpp:
1428         (WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): Early return when
1429             m_textTracks is NULL.
1430
1431 2013-02-15  Adam Barth  <abarth@webkit.org>
1432
1433         TokenPreloadScanner should be able to scan CompactHTMLTokens
1434         https://bugs.webkit.org/show_bug.cgi?id=109861
1435
1436         Reviewed by Eric Seidel.
1437
1438         This patch moves the main scanning logic for the TokenPreloadScanner to
1439         a templated scanCommon routine that can scan either an HTMLToken or a
1440         CompactHTMLToken. This patch will let the BackgroundHTMLParser preload
1441         scan its CompactHTMLTokens.
1442
1443         * html/parser/CSSPreloadScanner.cpp:
1444         (WebCore):
1445         (WebCore::CSSPreloadScanner::scanCommon):
1446         (WebCore::CSSPreloadScanner::scan):
1447         * html/parser/CSSPreloadScanner.h:
1448         (CSSPreloadScanner):
1449             - Tweak the CSSPreloadScanner API slightly to make it easier to
1450               call from templated code.
1451         * html/parser/HTMLPreloadScanner.cpp:
1452         (WebCore::TokenPreloadScanner::tagIdFor):
1453         (WebCore):
1454         (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
1455         (TokenPreloadScanner::StartTagScanner):
1456         (WebCore::TokenPreloadScanner::scan):
1457         (WebCore::TokenPreloadScanner::scanCommon):
1458         (WebCore::TokenPreloadScanner::updatePredictedBaseURL):
1459         (WebCore::HTMLPreloadScanner::scan):
1460         * html/parser/HTMLPreloadScanner.h:
1461         (TokenPreloadScanner):
1462
1463 2013-02-15  Alexis Menard  <alexis@webkit.org>
1464
1465         WebKit shouldn't accept "none, none" in transition shorthand property.
1466         https://bugs.webkit.org/show_bug.cgi?id=108751
1467
1468         Reviewed by Dean Jackson.
1469
1470         http://dev.w3.org/csswg/css3-transitions/#transition-shorthand-property
1471         specifies that if there is more than one transition defined in the
1472         shorthand and any of them has a value of 'none' then the declaration is
1473         invalid. This patch fixes the problem by passing a parsing context to
1474         track if a keyword has been set for the transition-property and if so
1475         then use it to invalidate or not the declaration.
1476
1477         Test: transitions/transitions-parsing.html
1478
1479         * css/CSSParser.cpp:
1480         (AnimationParseContext):
1481         (WebCore::AnimationParseContext::AnimationParseContext):
1482         (WebCore::AnimationParseContext::commitFirstAnimation): track whether
1483         it's the first <single-transition/animation> or not defined in the
1484         shorthand.
1485         (WebCore::AnimationParseContext::hasCommittedFirstAnimation):
1486         (WebCore::AnimationParseContext::commitAnimationPropertyKeywordInShorthand):
1487         In the shorthand as soon as a keyword has been found then the parsing
1488         is 'finished', if any other animation/transition declaration part of
1489         the shorthand are with a keyword then it's invalid.
1490         (WebCore::AnimationParseContext::animationPropertyKeywordInShorthandAllowed):
1491         (WebCore::AnimationParseContext::hasSeenAnimationPropertyKeyword):
1492         (WebCore::AnimationParseContext::sawAnimationPropertyKeyword):
1493         (WebCore):
1494         (WebCore::CSSParser::parseValue):
1495         (WebCore::CSSParser::parseAnimationShorthand):
1496         (WebCore::CSSParser::parseTransitionShorthand):
1497         (WebCore::CSSParser::parseAnimationProperty):
1498         * css/CSSParser.h:
1499         (WebCore):
1500
1501 2013-02-15  Andreas Kling  <akling@apple.com>
1502
1503         ElementData: Move leafy things out of the base class.
1504         <http://webkit.org/b/109888>
1505
1506         Reviewed by Antti Koivisto.
1507
1508         - Moved functions for mutating/adding/removing attributes into UniqueElementData.
1509           Attempts to modify shared element data will now fail at compile-time.
1510
1511         - Removed mutableAttributeVector() and have call sites access the vector directly.
1512
1513         - Move immutableAttributeArray() to ShareableElementData.
1514
1515         - Move some function bodies from Element.h to Element.cpp since all clients are in there.
1516
1517         * dom/Element.cpp:
1518         (WebCore::Element::addAttributeInternal):
1519         (WebCore::ShareableElementData::ShareableElementData):
1520         (WebCore::UniqueElementData::makeShareableCopy):
1521         (WebCore::UniqueElementData::addAttribute):
1522         (WebCore::UniqueElementData::removeAttribute):
1523         (WebCore::ElementData::reportMemoryUsage):
1524         (WebCore::UniqueElementData::getAttributeItem):
1525         (WebCore::UniqueElementData::attributeItem):
1526         * dom/Element.h:
1527         (ElementData):
1528         (WebCore::ShareableElementData::immutableAttributeArray):
1529         (ShareableElementData):
1530         (UniqueElementData):
1531         (WebCore::ElementData::length):
1532         (WebCore::ElementData::attributeItem):
1533
1534 2013-02-15  Hans Muller  <hmuller@adobe.com>
1535
1536         [CSS Exclusions] Enable shape-inside support for circles
1537         https://bugs.webkit.org/show_bug.cgi?id=109713
1538
1539         Reviewed by Dirk Schulze.
1540
1541         Removed the test that disabled circle values for shape-inside.
1542         The remaining support for circles, which is based on rounded rectangles
1543         whose width/height is equal to their radiusX/radiusY, has not changed.
1544
1545         Test: fast/exclusions/shape-inside/shape-inside-circle.html
1546
1547         * rendering/ExclusionShapeInsideInfo.h:
1548         (WebCore::ExclusionShapeInsideInfo::isEnabledFor): Now only disallows ellipse.
1549
1550 2013-02-15  Christophe Dumez  <ch.dumez@sisa.samsung.com>
1551
1552         [Soup] Leverage new soup_cookie_jar_get_cookie_list() API
1553         https://bugs.webkit.org/show_bug.cgi?id=109931
1554
1555         Reviewed by Kenneth Rohde Christiansen.
1556
1557         In several cases, the CookieJarSoup implementation was retrieving / copying ALL the
1558         cookies using soup_cookie_jar_all_cookies() and then using soup_cookie_applies_to_uri()
1559         to filter out cookies it is not interested in. This was inefficient.
1560
1561         In libsoup 2.40, soup_cookie_jar_get_cookie_list() was introduced to retrieve only the
1562         cookies that apply to a given URI. This patch leverages this new API in CookieJarSoup's
1563         getRawCookies() and deleteCookie(). This way, only the cookies we are interested in
1564         are retrieved and copied. Libsoup does not need to iterate over all the cookies itself
1565         because it keeps the cookies in a hash table using the host names as key.
1566
1567         No new tests, no behavior change.
1568
1569         * platform/network/soup/CookieJarSoup.cpp:
1570         (WebCore::getRawCookies):
1571         (WebCore::deleteCookie):
1572
1573 2013-02-15  Vladislav Kaznacheev  <kaznacheev@chromium.org>
1574
1575         Web Inspector: Added an option to split Elements and Sources sidebars in two panes.
1576         https://bugs.webkit.org/show_bug.cgi?id=109298.
1577
1578         Reviewed by Vsevolod Vlasov.
1579
1580         Introduced the "Split sidebar" context menu option that splits the horizontal sidebar into two panes.
1581         The width split ratio is 1:1 by default and is preserved when the Inspector window is resized.
1582         Elements sidebar is split into two tabbed panes, Sources sidebar is split into a pane stack and a tabbed pane.
1583
1584         No new tests.
1585
1586         * inspector/front-end/DOMBreakpointsSidebarPane.js:
1587         (WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype._reattachBody):
1588         * inspector/front-end/ElementsPanel.js:
1589         (WebInspector.ElementsPanel.get this):
1590         (WebInspector.ElementsPanel):
1591         (WebInspector.ElementsPanel.prototype._sidebarContextMenuEventFired):
1592         (WebInspector.ElementsPanel.prototype._populateContextMenuForSidebar.toggleSetting):
1593         (WebInspector.ElementsPanel.prototype.get _arrangeSidebarPanes.get this):
1594         (WebInspector.ElementsPanel.prototype.addExtensionSidebarPane):
1595         * inspector/front-end/ExtensionServer.js:
1596         (WebInspector.ExtensionServer.prototype._onCreateSidebarPane):
1597         * inspector/front-end/ScriptsPanel.js:
1598         (WebInspector.ScriptsPanel):
1599         (WebInspector.ScriptsPanel.prototype._appendUISourceCodeItems):
1600         (WebInspector.ScriptsPanel.prototype._contextMenuEventFired):
1601         (WebInspector.ScriptsPanel.prototype._sidebarContextMenuEventFired):
1602         (WebInspector.ScriptsPanel.prototype._populateContextMenuForSidebar.toggleSetting):
1603         (WebInspector.ScriptsPanel.prototype.get _arrangeSidebarPanes.get this):
1604         * inspector/front-end/SidebarPane.js:
1605         (WebInspector.SidebarPane):
1606         (WebInspector.SidebarPane.prototype.expand):
1607         (WebInspector.SidebarPane.prototype.onContentReady):
1608         (WebInspector.SidebarPane.prototype._setExpandCallback):
1609         (WebInspector.SidebarPane.prototype.wasShown):
1610         (WebInspector.SidebarPaneTitle):
1611         (WebInspector.SidebarPaneTitle.prototype._expand):
1612         (WebInspector.SidebarPaneTitle.prototype._collapse):
1613         (WebInspector.SidebarPaneTitle.prototype._toggleExpanded):
1614         (WebInspector.SidebarPaneTitle.prototype._onTitleKeyDown):
1615         (WebInspector.SidebarPaneStack):
1616         (WebInspector.SidebarPaneStack.prototype.addPane):
1617         (WebInspector.SidebarTabbedPane):
1618         (WebInspector.SidebarTabbedPane.prototype.addPane):
1619         * inspector/front-end/SidebarView.js:
1620         * inspector/front-end/SplitView.js:
1621         (WebInspector.SplitView):
1622         (WebInspector.SplitView.prototype.get mainElement):
1623         (WebInspector.SplitView.prototype.get sidebarElement):
1624
1625 2013-02-15  Vsevolod Vlasov  <vsevik@chromium.org>
1626
1627         Web Inspector: Several consecutive Backspace or Delete strikes should not be marked as undoable state.
1628         https://bugs.webkit.org/show_bug.cgi?id=109915
1629
1630         Reviewed by Pavel Feldman.
1631
1632         Extracted _isEditRangeUndoBoundary() and _isEditRangeAdjacentToLastCommand() in TextEditorModel
1633         to detect if markUndoableState() call is needed before and after editRange.
1634
1635         * inspector/front-end/TextEditorModel.js:
1636         (WebInspector.TextRange.prototype.immediatelyPrecedes):
1637         (WebInspector.TextRange.prototype.immediatelyFollows):
1638         (WebInspector.TextEditorModel.endsWithBracketRegex.):
1639
1640 2013-02-15  Andrey Adaikin  <aandrey@chromium.org>
1641
1642         Fix inconsistency in WebGLRenderingContext.idl for getAttribLocation
1643         https://bugs.webkit.org/show_bug.cgi?id=109892
1644
1645         Reviewed by Kentaro Hara.
1646
1647         * html/canvas/WebGLRenderingContext.idl:
1648
1649 2013-02-15  Andrey Adaikin  <aandrey@chromium.org>
1650
1651         Web Inspector: [Canvas] show replay log grouped by draw calls
1652         https://bugs.webkit.org/show_bug.cgi?id=109592
1653
1654         Reviewed by Pavel Feldman.
1655
1656         Show canvas capturing log grouped by drawing calls.
1657         Drive-by: extended Array.prototype with a handy peekLast function.
1658         Drive-by: removed code dups in few places.
1659
1660         * inspector/front-end/CanvasProfileView.js:
1661         (WebInspector.CanvasProfileView):
1662         (WebInspector.CanvasProfileView.prototype.dispose):
1663         (WebInspector.CanvasProfileView.prototype._onReplayStepClick):
1664         (WebInspector.CanvasProfileView.prototype._onReplayDrawingCallClick):
1665         (WebInspector.CanvasProfileView.prototype._onReplayLastStepClick):
1666         (WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
1667         (WebInspector.CanvasProfileView.prototype._replayTraceLog):
1668         (WebInspector.CanvasProfileView.prototype._didReceiveTraceLog):
1669         (WebInspector.CanvasProfileView.prototype._selectedCallIndex):
1670         (WebInspector.CanvasProfileView.prototype._selectedDrawCallGroupIndex):
1671         (WebInspector.CanvasProfileView.prototype._appendCallNode):
1672         * inspector/front-end/DataGrid.js:
1673         (WebInspector.DataGrid.prototype.setColumnVisible):
1674         (WebInspector.DataGridNode.prototype.set hasChildren):
1675         (WebInspector.DataGridNode.prototype.set revealed):
1676         (WebInspector.DataGridNode.prototype.get leftPadding):
1677         * inspector/front-end/externs.js:
1678         (Array.prototype.peekLast):
1679         * inspector/front-end/utilities.js:
1680
1681 2013-02-15  Yury Semikhatsky  <yurys@chromium.org>
1682
1683         Web Inspector: highlight record revealed in Timeline
1684         https://bugs.webkit.org/show_bug.cgi?id=109930
1685
1686         Reviewed by Pavel Feldman.
1687
1688         Revealed timeline record is now highlighted with yellow background
1689         that fades out in 2 seconds.
1690
1691         * inspector/front-end/TimelinePanel.js:
1692         (WebInspector.TimelinePanel.prototype._revealRecord):
1693         (WebInspector.TimelinePanel.prototype._refreshRecords):
1694         (WebInspector.TimelinePanel.prototype._clearRecordHighlight):
1695         * inspector/front-end/timelinePanel.css:
1696         (.highlighted-timeline-record):
1697         (@-webkit-keyframes timeline_record_highlight):
1698         (to):
1699
1700 2013-02-15  Vsevolod Vlasov  <vsevik@chromium.org>
1701
1702         Web Inspector: Pass original selection to textModel to correctly restore it after undo.
1703         https://bugs.webkit.org/show_bug.cgi?id=109911
1704
1705         Reviewed by Pavel Feldman.
1706
1707         We can distinguish backspace pressed with and without selection now.
1708
1709         * inspector/front-end/DefaultTextEditor.js:
1710         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
1711         (WebInspector.DefaultTextEditor.WordMovementController.prototype._handleCtrlBackspace):
1712         * inspector/front-end/TextEditorModel.js:
1713         (WebInspector.TextEditorCommand):
1714         (WebInspector.TextEditorModel.endsWithBracketRegex.):
1715
1716 2013-02-15  Joe Mason  <jmason@rim.com>
1717
1718         [BlackBerry] Remove redundant requireAuth parameter of NetworkJob::notifyAuthReceived
1719         https://bugs.webkit.org/show_bug.cgi?id=109855
1720
1721         Reviewed by Yong Li.
1722
1723         Internal PR: 296697
1724         Internally Reviewed By: Leo Yang
1725
1726         Code cleanup: The requireAuth parameter of NetworkJob::notifyAuthReceived is redundant as its value
1727         can be determined from "result" - if result is AuthResultRetry, requireAuth is false, otherwise it
1728         is true.
1729
1730         No new tests as there is no behaviour change.
1731
1732         * platform/network/blackberry/NetworkJob.cpp:
1733         (WebCore::NetworkJob::notifyAuthReceived):
1734         * platform/network/blackberry/NetworkJob.h:
1735         (NetworkJob):
1736
1737 2013-02-15  Vsevolod Vlasov  <vsevik@chromium.org>
1738
1739         Web Inspector: Redo in text editor should always collapse selection to end.
1740         https://bugs.webkit.org/show_bug.cgi?id=109907
1741
1742         Reviewed by Pavel Feldman.
1743
1744         * inspector/front-end/TextEditorModel.js:
1745         (WebInspector.TextEditorModel.endsWithBracketRegex.):
1746
1747 2013-02-15  Dan Carney  <dcarney@google.com>
1748
1749         [v8] persistent handle dispose before last use
1750         https://bugs.webkit.org/show_bug.cgi?id=109927
1751
1752         Reviewed by Jochen Eisinger.
1753
1754         No new tests. No change in functionality.
1755
1756         * bindings/v8/ScriptWrappable.h:
1757         (WebCore::ScriptWrappable::weakCallback):
1758
1759 2013-02-15  Keishi Hattori  <keishi@webkit.org>
1760
1761         PagePopupController.formatMonth should support short month format
1762         https://bugs.webkit.org/show_bug.cgi?id=109530
1763
1764         Reviewed by Kent Tamura.
1765
1766         PagePopupController.formatMonth should support short month format so we
1767         can use it in the new calendar picker.
1768
1769         Tested by LocaleMacTest::formatMonth.
1770
1771         * page/PagePopupController.cpp:
1772         (WebCore::PagePopupController::formatMonth): Take an extra bool argument to switch to short month format.
1773         * page/PagePopupController.h:
1774         (PagePopupController):
1775         * page/PagePopupController.idl:
1776         * platform/text/LocaleICU.cpp:
1777         (WebCore::LocaleICU::shortMonthFormat):
1778         (WebCore):
1779         * platform/text/LocaleICU.h:
1780         (LocaleICU):
1781         * platform/text/LocaleNone.cpp:
1782         (WebCore::shortMonthFormat):
1783         (WebCore):
1784         * platform/text/PlatformLocale.cpp:
1785         (WebCore::DateTimeStringBuilder::visitField):
1786         (WebCore::Locale::formatDateTime):
1787         * platform/text/PlatformLocale.h:
1788         (Locale):
1789         * platform/text/mac/LocaleMac.h:
1790         (LocaleMac):
1791         * platform/text/mac/LocaleMac.mm:
1792         (WebCore::LocaleMac::shortMonthFormat):
1793         (WebCore):
1794         * platform/text/win/LocaleWin.cpp:
1795         (WebCore::LocaleWin::shortMonthFormat): Windows doesn't have a short
1796         month format so we just replace MMMM with MMM.
1797         (WebCore):
1798         * platform/text/win/LocaleWin.h:
1799         (LocaleWin):
1800
1801 2013-02-15  Keishi Hattori  <keishi@webkit.org>
1802
1803         Add setValue and closePopup methods to PagePopupController
1804         https://bugs.webkit.org/show_bug.cgi?id=109897
1805
1806         Reviewed by Kent Tamura.
1807
1808         The new calendar picker (Bug 109439) needs to set a value without
1809         closing the popup. We can't do that with the existing
1810         setValueAndClosePopup.
1811
1812         No new tests. Existing calendar picker and color suggestion picker tests
1813         that closing and setting values work properly.
1814
1815         * Resources/pagepopups/pickerCommon.js:
1816         (Picker.prototype.submitValue): Stop using setValueAndClosePopup.
1817         (Picker.prototype.handleCancel): Ditto.
1818         * page/PagePopupClient.h:
1819         (PagePopupClient):
1820         * page/PagePopupController.cpp:
1821         (WebCore::PagePopupController::setValue): Sets value to element without closing popup.
1822         (WebCore):
1823         (WebCore::PagePopupController::closePopup): Just closes popup.
1824         * page/PagePopupController.h:
1825         (PagePopupController):
1826         * page/PagePopupController.idl:
1827
1828 2013-02-15  Mihnea Ovidenie  <mihnea@adobe.com>
1829
1830         [CSS Regions] RenderRegion should inherit from RenderBlock
1831         https://bugs.webkit.org/show_bug.cgi?id=74132
1832
1833         Reviewed by Julien Chaffraix.
1834
1835         Change the base class for RenderRegion to be RenderBlock instead of RenderReplaced.
1836         Per spec http://dev.w3.org/csswg/css3-regions/#the-flow-from-property, a region is a non-replaced block container.
1837         This change is covered by the existing regions tests (in fast/region and fast/repaint).
1838
1839         The RenderFlowThread object is a self-painting layer (it requires layer and is positioned).
1840         Because of that, the RenderFlowThread object is responsible for painting its children,
1841         the collected objects. When the RenderRegion::paintObject is called during paint, it delegates painting
1842         of content collected inside the flow thread to the associated RenderFlowThread object.
1843         Since we do not want to paint the flow thread content multiple times (for each paint phase
1844         in which the RenderRegion::paintObject is called), we allow RenderFlowThread painting only for
1845         selection and foreground paint phases.
1846
1847         * rendering/RenderBox.cpp: Clean-up the code from regions specific stuff, now that the regions are render blocks.
1848         (WebCore::RenderBox::computePositionedLogicalWidth):
1849         (WebCore::RenderBox::computePositionedLogicalHeight):
1850         * rendering/RenderLayerBacking.cpp: A region should always render content from its associated flow thread,
1851         even when it does not have children of its own.
1852         (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
1853         * rendering/RenderMultiColumnSet.cpp: Make changes to match the new inheritance for RenderRegion.
1854         (WebCore::RenderMultiColumnSet::paint):
1855         (WebCore::RenderMultiColumnSet::paintColumnRules):
1856         * rendering/RenderMultiColumnSet.h:
1857         * rendering/RenderRegion.cpp:
1858         (WebCore::RenderRegion::RenderRegion):
1859         (WebCore::RenderRegion::paintObject):
1860         (WebCore::RenderRegion::styleDidChange):
1861         (WebCore::RenderRegion::layoutBlock):
1862         (WebCore::RenderRegion::insertedIntoTree):
1863         (WebCore::RenderRegion::willBeRemovedFromTree):
1864         (WebCore::RenderRegion::computePreferredLogicalWidths): Use this method instead of min/maxPreferredLogicalWidth.
1865         (WebCore::RenderRegion::updateLogicalHeight):
1866         * rendering/RenderRegion.h: For now, assume the region is not allowed to have children.
1867         When we will implement the processing model for pseudo-elements http://dev.w3.org/csswg/css3-regions/#processing-model,
1868         we will have to remove this function. By having this function return false i was able to leave some tests unchanged.
1869
1870 2013-02-15  Andrey Lushnikov  <lushnikov@chromium.org>
1871
1872         Web Inspector: implement smart braces functionality
1873         https://bugs.webkit.org/show_bug.cgi?id=109200
1874
1875         Reviewed by Pavel Feldman.
1876
1877         - implement SmartBraceController which will handle character insertions
1878         and override them if brace character was inserted. Additionally it
1879         should handle Backspace key and override it if a cursor is located
1880         inside of a bracket pair.
1881         - guard smart brace functionality via experiment checkbox.
1882
1883         New test: inspector/editor/text-editor-smart-braces.html
1884
1885         * inspector/front-end/DefaultTextEditor.js:
1886         (WebInspector.TextEditorMainPanel):
1887         (WebInspector.TextEditorMainPanel.prototype._registerShortcuts):
1888         (WebInspector.TextEditorMainPanel.prototype._handleKeyPress):
1889         (WebInspector.TextEditorMainPanel.SmartBraceController):
1890         (WebInspector.TextEditorMainPanel.SmartBraceController.prototype.registerShortcuts):
1891         (WebInspector.TextEditorMainPanel.SmartBraceController.prototype.registerCharOverrides):
1892         (WebInspector.TextEditorMainPanel.SmartBraceController.prototype._handleBackspace):
1893         (WebInspector.TextEditorMainPanel.SmartBraceController.prototype._handleBracePairInsertion):
1894         (WebInspector.TextEditorMainPanel.SmartBraceController.prototype._handleClosingBraceOverride):
1895         * inspector/front-end/Settings.js:
1896         (WebInspector.ExperimentsSettings):
1897
1898 2013-02-15  Andrei Bucur  <abucur@adobe.com>
1899
1900         [CSS Regions][Mac] fast/regions/full-screen-video-from-region.html hits an assertion in RenderFlowThread::removeRenderBoxRegionInfo
1901         https://bugs.webkit.org/show_bug.cgi?id=106075
1902
1903         Reviewed by Tony Chang.
1904
1905         The crash is caused by two issues.
1906
1907         The first problem is how a block inside a flow thread determines if the children needs relayout or not.
1908         When the region chain is invalidated, the information is lost so we need to return true, even for the
1909         enclosing RenderFlowThread. Because the video renderer is the first child of the flow thread this doesn't
1910         happen.
1911
1912         The patch implements this behaviour by inspecting both if the region chain has changed and
1913         if the block has no range computed yet.
1914
1915         The second problem is RenderMedia not inheriting from RenderBlock. The logic of child relayout doesn't apply
1916         to it. In the test case, when the full screen button is pressed, the region changes width to fill the viewport,
1917         the chain is invalidated and the box info hash map is cleared. When the video is laid out again (after fixing
1918         the first issue) it has the same size so the controls don't do a layout. They remain without box info inside
1919         the flow thread, thus causing the assertion.
1920
1921         The patch forces the controls to relayout if the region chain was invalidated. We can't use the
1922         logicalWidthChangedInRegions method because it is block specific. This will be fixed in a later patch.
1923
1924         Tests: No new tests. fast/regions/full-screen-video-from-region.html no longer crashes.
1925
1926         * rendering/RenderBlock.cpp:
1927         (WebCore::RenderBlock::checkForPaginationLogicalHeightChange):
1928         * rendering/RenderFlowThread.cpp:
1929         (WebCore::RenderFlowThread::RenderFlowThread):
1930         (WebCore::RenderFlowThread::layout):
1931         (WebCore::RenderFlowThread::logicalWidthChangedInRegions):
1932         * rendering/RenderFlowThread.h: Renamed pageLogicalHeightChanged to pageLogicalSizeChanged.
1933         * rendering/RenderMedia.cpp:
1934         (WebCore::RenderMedia::layout):
1935
1936 2013-02-13  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1937
1938         [CoordGfx] Regression from r135212: big layers with transform animations sometime fail to render tiles
1939         https://bugs.webkit.org/show_bug.cgi?id=109179
1940
1941         Reviewed by Jocelyn Turcotte.
1942
1943         Fix adjustForContentsRect logic for AC layers that are higher or wider than the visible rect.
1944
1945         Force updates of the visible rect while it is animating, and until we have done one last update after
1946         it stops animating.
1947
1948         Test: compositing/transitions/transform-on-large-layer.html
1949
1950         * platform/graphics/TiledBackingStore.cpp:
1951         (WebCore::TiledBackingStore::adjustForContentsRect):
1952         (WebCore::TiledBackingStore::computeCoverAndKeepRect):
1953         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
1954         (WebCore::CoordinatedGraphicsLayer::CoordinatedGraphicsLayer):
1955         (WebCore::CoordinatedGraphicsLayer::flushCompositingStateForThisLayerOnly):
1956         (WebCore::CoordinatedGraphicsLayer::computePixelAlignment):
1957         (WebCore::CoordinatedGraphicsLayer::computeTransformedVisibleRect):
1958         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
1959         (CoordinatedGraphicsLayer):
1960
1961 2013-02-15  Sheriff Bot  <webkit.review.bot@gmail.com>
1962
1963         Unreviewed, rolling out r142876.
1964         http://trac.webkit.org/changeset/142876
1965         https://bugs.webkit.org/show_bug.cgi?id=109920
1966
1967         Broke relative URL linkification in the computed styles pane
1968         (Requested by apavlov on #webkit).
1969
1970         * inspector/front-end/StylesSidebarPane.js:
1971         (WebInspector.StylesSidebarPane.prototype._rebuildSectionsForStyleRules):
1972
1973 2013-02-15  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1974
1975         Simplify hitTestResultAtPoint and nodesFromRect APIs
1976         https://bugs.webkit.org/show_bug.cgi?id=95720
1977
1978         Reviewed by Julien Chaffraix.
1979
1980         The existing API was overloaded and could be simplified by passing all the bool arguments in 
1981         a HitTestRequest argument. This should also help clarify the call as the enum values explicitely
1982         state what they do.
1983
1984         * WebCore.exp.in:
1985         * WebCore.order:
1986         * dom/Document.cpp:
1987         (WebCore::Document::nodesFromRect):
1988         * dom/Document.h:
1989         (Document):
1990         * page/ContextMenuController.cpp:
1991         (WebCore::ContextMenuController::createContextMenu):
1992         * page/DragController.cpp:
1993         (WebCore::DragController::canProcessDrag):
1994         (WebCore::DragController::startDrag):
1995         * page/EventHandler.cpp:
1996         (WebCore::EventHandler::hitTestResultAtPoint):
1997         (WebCore::EventHandler::handleMousePressEvent):
1998         (WebCore::EventHandler::handleGestureEvent):
1999         (WebCore::EventHandler::handleGestureForTextSelectionOrContextMenu):
2000         (WebCore::EventHandler::bestClickableNodeForTouchPoint):
2001         (WebCore::EventHandler::bestContextMenuNodeForTouchPoint):
2002         (WebCore::EventHandler::bestZoomableAreaForTouchPoint):
2003         (WebCore::EventHandler::handleTouchEvent):
2004         * page/EventHandler.h:
2005         (WebCore):
2006         (EventHandler):
2007         * page/FocusController.cpp:
2008         (WebCore::updateFocusCandidateIfNeeded):
2009         * page/Frame.cpp:
2010         (WebCore::Frame::visiblePositionForPoint):
2011         (WebCore::Frame::documentAtPoint):
2012         * page/TouchDisambiguation.cpp:
2013         (WebCore::findGoodTouchTargets):
2014         * rendering/HitTestRequest.h:
2015         (WebCore::HitTestRequest::allowsFrameScrollbars):
2016         * testing/Internals.cpp:
2017         (WebCore::Internals::nodesFromRect):
2018
2019 2013-02-14  Pavel Feldman  <pfeldman@chromium.org>
2020
2021         Web Inspector: make component-based compile-front-end happy
2022         https://bugs.webkit.org/show_bug.cgi?id=109798
2023
2024         Reviewed by Vsevolod Vlasov.
2025
2026         * inspector/Inspector.json:
2027         * inspector/InspectorDebuggerAgent.cpp:
2028         (WebCore::InspectorDebuggerAgent::setVariableValue):
2029         * inspector/InspectorDebuggerAgent.h:
2030         (InspectorDebuggerAgent):
2031         * inspector/compile-front-end.py:
2032         * inspector/front-end/AuditResultView.js:
2033         * inspector/front-end/CPUProfileView.js:
2034         * inspector/front-end/DataGrid.js:
2035         * inspector/front-end/InspectorFrontendAPI.js:
2036         (InspectorFrontendAPI.loadTimelineFromURL):
2037
2038 2013-02-14  Alexander Pavlov  <apavlov@chromium.org>
2039
2040         Web Inspector: Implement tracking of active stylesheets in the frontend
2041         https://bugs.webkit.org/show_bug.cgi?id=105828
2042
2043         Reviewed by Pavel Feldman.
2044
2045         - This change introduces the CSS.styleSheetAdded() and CSS.styleSheetRemoved() events
2046         that update the frontend with all active stylesheet changes in the inspected page.
2047         As such, fetching stylesheet headers from the backend manually is no longer needed,
2048         and many asynchronous methods have been turned into normal accessors.
2049         - One notable change to the stylesheet binding process is that when a via-inspector stylesheet
2050         is created, it is instantly reported through the instrumentation, and the viaInspectorStyleSheet() method
2051         is [indirectly] called recursively from bindStyleSheet(). Thus, the actual creation and registration
2052         of the respective InspectorStyleSheet have been moved into bindStyleSheet(),
2053         which relies upon the m_creatingViaInspectorStyleSheet flag.
2054
2055         Test: inspector/styles/stylesheet-tracking.html
2056
2057         * dom/DocumentStyleSheetCollection.cpp:
2058         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets): Instrumented.
2059         * inspector/Inspector.json: Add events, update the CSS domain description.
2060         * inspector/InspectorCSSAgent.cpp:
2061         (WebCore::InspectorCSSAgent::InspectorCSSAgent):
2062         (WebCore::InspectorCSSAgent::clearFrontend):
2063         (WebCore::InspectorCSSAgent::enable): Push all existing stylesheet headers into the frontend.
2064         (WebCore::InspectorCSSAgent::activeStyleSheetsUpdated): Push added/removed stylesheet into the frontend.
2065         (WebCore::InspectorCSSAgent::getAllStyleSheets): Slightly refactored to make use of collectAllStyleSheets().
2066         (WebCore::InspectorCSSAgent::collectAllStyleSheets): Added to collect InspectorStyleSheets rather than headers.
2067         (WebCore::InspectorCSSAgent::collectStyleSheets):
2068         (WebCore::InspectorCSSAgent::bindStyleSheet): Binds via-inspector stylesheets, too.
2069         (WebCore::InspectorCSSAgent::unbindStyleSheet): Now we can unbind stylesheets upon their removal from the document.
2070         (WebCore::InspectorCSSAgent::viaInspectorStyleSheet): Modifies m_creatingViaInspectorStyleSheet when necessary.
2071         (WebCore::InspectorCSSAgent::detectOrigin): Modified to make use of m_creatingViaInspectorStyleSheet.
2072         (WebCore::InspectorCSSAgent::buildObjectForRule): Removed extraneous bound InspectorStyleSheet 0-check.
2073         * inspector/InspectorCSSAgent.h:
2074         * inspector/InspectorInstrumentation.cpp: Instrumentation of active stylesheet set updates.
2075         (WebCore::InspectorInstrumentation::activeStyleSheetsUpdatedImpl):
2076         * inspector/InspectorInstrumentation.h: Ditto.
2077         (WebCore::InspectorInstrumentation::activeStyleSheetsUpdated):
2078         * inspector/front-end/CSSStyleModel.js:
2079         (WebInspector.CSSStyleModel.prototype.styleSheetHeaders):
2080         (WebInspector.CSSStyleModel.prototype._styleSheetAdded): Added.
2081         (WebInspector.CSSStyleModel.prototype._styleSheetRemoved): Added.
2082         (WebInspector.CSSStyleModel.prototype.viaInspectorResourceForRule):
2083         (WebInspector.CSSStyleModelResourceBinding.prototype._setHeaderForStyleSheetId):
2084         (WebInspector.CSSStyleModelResourceBinding.prototype.resourceURLForStyleSheetId):
2085         (WebInspector.CSSStyleModelResourceBinding.prototype.styleSheetIdForResource):
2086         (WebInspector.CSSStyleModelResourceBinding.prototype._headerKey): Calculate the (frameID + URL) key for CSSStyleSheetHeader.
2087         (WebInspector.CSSStyleModelResourceBinding.prototype._createInspectorResource):
2088         (WebInspector.CSSStyleModelResourceBinding.prototype._inspectorResource):
2089         (WebInspector.CSSStyleModelResourceBinding.prototype._reset):
2090         (WebInspector.CSSDispatcher.prototype.styleSheetAdded): Added.
2091         (WebInspector.CSSDispatcher.prototype.styleSheetRemoved): Added.
2092         * inspector/front-end/SASSSourceMapping.js: Get rid of async implementations.
2093         (WebInspector.SASSSourceMapping.prototype._styleSheetChanged):
2094         * inspector/front-end/StylesSidebarPane.js: Ditto.
2095         (WebInspector.StylePropertiesSection.prototype._createRuleOriginNode):
2096         * inspector/front-end/StylesSourceMapping.js: Ditto.
2097         (WebInspector.StyleContentBinding.prototype._innerStyleSheetChanged):
2098
2099 2013-02-15  Andrei Bucur  <abucur@adobe.com>
2100
2101         Implement the -webkit-margin-collapse properties correct rendering
2102         https://bugs.webkit.org/show_bug.cgi?id=108168
2103
2104         Reviewed by David Hyatt.
2105
2106         The patch implements the correct behavior for the -webkit-margin-collapse properties:
2107         - a value of "discard" on a margin will truncate all the margins collapsing with it;
2108         - a value of "separate" will prevent the margin to collapse;
2109         - a value of "collapse" is the default collapse behavior.
2110
2111         The implementation is aware of multiple writing-modes:
2112         - if the writing mode of a child is parallel with the writing mode of the container and has the same direction,
2113         the -webkit-margin-collapse properties on the child are left as is;
2114         - if the writing mode of a child is parallel with the writing mode of the container but has a different direction,
2115         the -webkit-margin-collapse properties on the child are reversed;
2116         - if the writing mode of a child is perpendicular on the writing mode of the container,
2117         the -webkit-margin-collapse properties on the child are ignored;
2118
2119         I. The "discard" value implementation
2120         There are two new bits (before and after) added on the RenderBlockRareData structure specifying if the margins
2121         of the block will be discarded or not. We can't rely only on the value from style() because
2122         it's possible a block to discard it's margins because it has collapsed with a children that
2123         specified "discard" for -webkit-margin-collapse. However, the bits are set only if it is
2124         required.
2125         Another bit is added on the MarginInfo structure specifying if the margin has to be discarded or not. When
2126         collapsing at the before side of a block it will hold information if the container block needs to discard
2127         or not. If the collapsing happens between siblings/with after side of the container it will tell if the previous
2128         child discards the margin or not. The self collapsing blocks are a special case. If any of its margins
2129         discards then both its margins discard and all the other margins collapsing with it.
2130         To ensure an optimal behavior it is asserted margin values can't be set on the MarginInfo object if the
2131         discard flag is active. If this happens it may indicate someone ignored the possibility of the margin being
2132         discarded altogether and incorrectly updated the margin values.
2133         Float clearing also needs to change because it may force margins to stop collapsing. If this happens the discard
2134         flags and margins needs to be restored to their values before the collapse.
2135
2136         II. The "separate" value implementation
2137         The implementation for separate was not changed too much. I've added new accessor methods for the property
2138         that take writing mode into consideration and I've removed some code that didn't work correctly in layoutBlockChild.
2139         The problem was the marginInfo structure was cleared if the child was specifying the "separate" value for before.
2140         This is wrong because you lose the margin information of the previous child/before side.
2141
2142         Tests: fast/block/margin-collapse/webkit-margin-collapse-container.html
2143                fast/block/margin-collapse/webkit-margin-collapse-floats.html
2144                fast/block/margin-collapse/webkit-margin-collapse-siblings-bt.html
2145                fast/block/margin-collapse/webkit-margin-collapse-siblings.html
2146
2147         * rendering/RenderBlock.cpp:
2148         (WebCore::RenderBlock::MarginInfo::MarginInfo):
2149         (WebCore::RenderBlock::layoutBlock):
2150         (WebCore::RenderBlock::collapseMargins):
2151         (WebCore::RenderBlock::clearFloatsIfNeeded):
2152         (WebCore::RenderBlock::marginBeforeEstimateForChild):
2153         (WebCore::RenderBlock::estimateLogicalTopPosition):
2154         (WebCore::RenderBlock::setCollapsedBottomMargin):
2155         (WebCore::RenderBlock::handleAfterSideOfBlock):
2156         (WebCore::RenderBlock::layoutBlockChild):
2157         (WebCore::RenderBlock::setMustDiscardMarginBefore):
2158         (WebCore):
2159         (WebCore::RenderBlock::setMustDiscardMarginAfter):
2160         (WebCore::RenderBlock::mustDiscardMarginBefore):
2161         (WebCore::RenderBlock::mustDiscardMarginAfter):
2162         (WebCore::RenderBlock::mustDiscardMarginBeforeForChild):
2163         (WebCore::RenderBlock::mustDiscardMarginAfterForChild):
2164         (WebCore::RenderBlock::mustSeparateMarginBeforeForChild):
2165         (WebCore::RenderBlock::mustSeparateMarginAfterForChild):
2166         * rendering/RenderBlock.h:
2167         (RenderBlock):
2168         (WebCore::RenderBlock::initMaxMarginValues):
2169         (MarginInfo):
2170         (WebCore::RenderBlock::MarginInfo::setPositiveMargin):
2171         (WebCore::RenderBlock::MarginInfo::setNegativeMargin):
2172         (WebCore::RenderBlock::MarginInfo::setPositiveMarginIfLarger):
2173         (WebCore::RenderBlock::MarginInfo::setNegativeMarginIfLarger):
2174         (WebCore::RenderBlock::MarginInfo::setMargin):
2175         (WebCore::RenderBlock::MarginInfo::setCanCollapseMarginAfterWithChildren):
2176         (WebCore::RenderBlock::MarginInfo::setDiscardMargin):
2177         (WebCore::RenderBlock::MarginInfo::discardMargin):
2178         (WebCore::RenderBlock::RenderBlockRareData::RenderBlockRareData):
2179         (WebCore::RenderBlock::RenderBlockRareData::positiveMarginBeforeDefault):
2180         (RenderBlockRareData):
2181         * rendering/style/RenderStyle.h:
2182
2183 2013-02-14  Yury Semikhatsky  <yurys@chromium.org>
2184
2185         Web Inspector: always show memory size in Mb on the native memory graph
2186         https://bugs.webkit.org/show_bug.cgi?id=109813
2187
2188         Reviewed by Pavel Feldman.
2189
2190         Memory size vlue is alway shown in Mb on the native memory graph.
2191
2192         * inspector/front-end/NativeMemoryGraph.js:
2193         (WebInspector.NativeMemoryCounterUI.prototype.updateCurrentValue):
2194
2195 2013-02-14  Andrey Adaikin  <aandrey@chromium.org>
2196
2197         Use GL typedefs in WebGLRenderingContext.idl
2198         https://bugs.webkit.org/show_bug.cgi?id=109060
2199
2200         Reviewed by Kenneth Russell.
2201
2202         Use GL typedefs in WebGLRenderingContext.idl according to the specs.
2203         Added a FIXME about inconsistency with the current WebGL spec for getAttribLocation.
2204
2205         Tested manually that generators V8, JS, ObjC, GObject, CPP produce same output.
2206
2207         * html/canvas/WebGLRenderingContext.idl:
2208
2209 2013-02-14  Vsevolod Vlasov  <vsevik@chromium.org>
2210
2211         Web Inspector: Copy-pasting selected text over itself should be an undoable state.
2212         https://bugs.webkit.org/show_bug.cgi?id=109830
2213
2214         Reviewed by Pavel Feldman.
2215
2216         * inspector/front-end/TextEditorModel.js:
2217         (WebInspector.TextEditorModel.endsWithBracketRegex.):
2218
2219 2013-02-14  Sheriff Bot  <webkit.review.bot@gmail.com>
2220
2221         Unreviewed, rolling out r142889.
2222         http://trac.webkit.org/changeset/142889
2223         https://bugs.webkit.org/show_bug.cgi?id=109891
2224
2225         It caused an assertion failure in scrollbars/overflow-
2226         scrollbar-combinations.html (Requested by tkent on #webkit).
2227
2228         * rendering/RenderBox.cpp:
2229         (WebCore::borderWidthChanged):
2230         (WebCore::RenderBox::styleDidChange):
2231
2232 2013-02-14  Arpita Bahuguna  <arpitabahuguna@gmail.com>
2233
2234         Caret positioned at the end of a text line (followed by an empty block) in vertical writing mode disappears when pressing the right/down arrow key.
2235         https://bugs.webkit.org/show_bug.cgi?id=106452
2236
2237         Reviewed by Ryosuke Niwa.
2238
2239         Pressing the down or the right arrow key at the end of a text line in
2240         vertical writing mode would make the caret dissapear. This occurs only
2241         when the text line is followed by an empty block.
2242
2243         When trying to compute the next position for placing the caret (for
2244         down/right key), we try to ascertain whether the renderer (in this
2245         case the empty block) is a valid candidate or not. For blockFlow
2246         elements we check against their height.
2247         In vertical writing mode though we would fail such a check since we
2248         should instead be comparing against the renderer's width and not
2249         it's height. Thus, a valid position for the placement of the caret
2250         was not found in such a case.
2251
2252         Test: editing/selection/caret-at-end-of-text-line-followed-by-empty-block-in-vertical-mode.html
2253
2254         * dom/Position.cpp:
2255         (WebCore::Position::isCandidate):
2256         * dom/PositionIterator.cpp:
2257         (WebCore::PositionIterator::isCandidate):
2258         Instead of checking against the height(), check against the
2259         logicalHeight() of the renderer has been added. logicalHeight()
2260         on blockFlow renderer's returns a value in accordance with
2261         the writing mode.
2262
2263 2013-02-14  Ryosuke Niwa  <rniwa@webkit.org>
2264
2265         Windows build fix after r142957.
2266
2267         * dom/DOMAllInOne.cpp:
2268
2269 2013-02-14  Ryosuke Niwa  <rniwa@webkit.org>
2270
2271         Fix a typo introduced in r142705.
2272
2273         Without this fix, text-input-controller.html can fail when DeleteButtonController is enabled.
2274         e.g. "run-webkit-tests platform/mac/editing/deleting/deletionUI-single-instance.html
2275             platform/mac/editing/input/text-input-controller.html --child-processes=1"
2276
2277         * editing/Editor.cpp:
2278         (WebCore::Editor::avoidIntersectionWithDeleteButtonController):
2279
2280 2013-02-14  Hayato Ito  <hayato@chromium.org>
2281
2282         Factor Event retargeting code.
2283         https://bugs.webkit.org/show_bug.cgi?id=109156
2284
2285         Reviewed by Dimitri Glazkov.
2286
2287         To supoort Touch event retargeting (bug 107800), we have to factor
2288         event retargeting code so that it can support not only MouseEvent,
2289         but also other events.
2290
2291         New class, EventRetargeter, was introduced. From now,
2292         EventDispatchMediator (and its subclasses) should call, if event
2293         retargeting is required, an appropriate function provided in
2294         EventRetargeter rather than calling
2295         EventDispatcher::adjustRelatedTarget(), which was removed in this
2296         patch.
2297
2298         No tests. No change in behavior.
2299
2300         * CMakeLists.txt:
2301         * GNUmakefile.list.am:
2302         * Target.pri:
2303         * WebCore.gypi:
2304         * WebCore.xcodeproj/project.pbxproj:
2305         * dom/EventDispatchMediator.cpp:
2306         * dom/EventDispatcher.cpp:
2307         (WebCore):
2308         (WebCore::EventDispatcher::ensureEventPath): Changed to return an EventPath, which will be used by EventRetargeter.
2309         (WebCore::EventDispatcher::dispatchScopedEvent):
2310         (WebCore::EventDispatcher::dispatchEvent):
2311         (WebCore::EventDispatcher::dispatchEventPostProcess):
2312         * dom/EventDispatcher.h:
2313         (WebCore):
2314         (EventDispatcher):
2315         * dom/EventRetargeter.cpp: Added.
2316         (WebCore):
2317         (WebCore::inTheSameScope):
2318         (WebCore::determineDispatchBehavior):
2319         (WebCore::EventRetargeter::calculateEventPath): Factored out from EventDispatcher::ensureEventPath().
2320         (WebCore::EventRetargeter::adjustForMouseEvent):
2321         (WebCore::EventRetargeter::adjustForFocusEvent):
2322         (WebCore::EventRetargeter::adjustForRelatedTarget):
2323         (WebCore::EventRetargeter::calculateAdjustedNodes): Factored out from EventRelatedTargetAjuster::adjustRelatedTarget().
2324         (WebCore::EventRetargeter::buildRelatedNodeMap): Factored out from EventRelatedTargetAjuster::adjustRelatedTarget().
2325         (WebCore::EventRetargeter::findRelatedNode):
2326         * dom/EventRetargeter.h: Added.
2327         (WebCore):
2328         (EventRetargeter):
2329         (WebCore::EventRetargeter::eventTargetRespectingTargetRules):
2330         * dom/FocusEvent.cpp:
2331         (WebCore::FocusEventDispatchMediator::dispatchEvent): Changed to call EventRetargeter::adjustForFocusEvent().
2332         (WebCore::BlurEventDispatchMediator::dispatchEvent): Ditto.
2333         (WebCore::FocusInEventDispatchMediator::dispatchEvent): Ditto.
2334         (WebCore::FocusOutEventDispatchMediator::dispatchEvent): Ditto.
2335         * dom/MouseEvent.cpp:
2336         (WebCore::MouseEventDispatchMediator::dispatchEvent): Changed to call EventRetargeter::adjustForMouseEvent().
2337
2338 2013-02-14  Simon Fraser  <simon.fraser@apple.com>
2339
2340         Reverting r142861. Hit testing inside of style recalc is fundamentally wrong
2341
2342         * page/EventHandler.cpp:
2343         (WebCore::EventHandler::selectCursor):
2344         (WebCore::EventHandler::handleMouseMoveEvent):
2345         * page/EventHandler.h:
2346         * rendering/RenderObject.cpp:
2347         (WebCore::RenderObject::setStyle):
2348         (WebCore::areNonIdenticalCursorListsEqual):
2349         (WebCore::areCursorsEqual):
2350         (WebCore::RenderObject::styleDidChange):
2351
2352 2013-02-14  Florin Malita  <fmalita@chromium.org>
2353
2354         [SVG] Cached filter results are not invalidated on repaint rect change
2355         https://bugs.webkit.org/show_bug.cgi?id=106221
2356
2357         Reviewed by Dean Jackson.
2358
2359         Since the cached filter results are not invalidated for different repaint rects, we need
2360         to render the content of the whole filter region upfront (otherwise elements not visible
2361         during the initial paint due to scrolling/window size/etc. are never redrawn).
2362
2363         Tests: svg/filters/filter-hidden-content-expected.svg
2364                svg/filters/filter-hidden-content.svg
2365
2366         * rendering/svg/RenderSVGResourceFilter.cpp:
2367         (WebCore::RenderSVGResourceFilter::applyResource):
2368         (WebCore::RenderSVGResourceFilter::drawingRegion):
2369         (WebCore):
2370         * rendering/svg/RenderSVGResourceFilter.h:
2371         (FilterData):
2372         (RenderSVGResourceFilter):
2373         Track the filter drawing region in FilterData.
2374
2375         * rendering/svg/SVGRenderingContext.cpp:
2376         (WebCore::SVGRenderingContext::~SVGRenderingContext):
2377         (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
2378         * rendering/svg/SVGRenderingContext.h:
2379         Update paintInfo.rect to cover the whole drawing region while rendering filter content, and
2380         restore it when done.
2381
2382 2013-02-14  Jinwoo Song  <jinwoo7.song@samsung.com>
2383
2384         [EFL] Correct the mismatched cursor map
2385         https://bugs.webkit.org/show_bug.cgi?id=109655
2386
2387         Reviewed by Laszlo Gombos.
2388
2389         Correct the mismatched ECORE_X_CURSOR values in the cursor map.
2390
2391         * platform/efl/EflScreenUtilities.cpp:
2392         (WebCore::CursorMap::CursorMap):
2393
2394 2013-02-14  Kentaro Hara  <haraken@chromium.org>
2395
2396         Unreviewed. Rebaselined run-bindings-tests.
2397
2398         * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
2399         (WebDOMTestObj::anyAttribute):
2400         (WebDOMTestObj::setAnyAttribute):
2401         * bindings/scripts/test/CPP/WebDOMTestObj.h:
2402         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
2403         (webkit_dom_test_obj_get_any_attribute):
2404         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
2405         (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClamp):
2406         * bindings/scripts/test/V8/V8TestTypedefs.cpp:
2407         (WebCore::TestTypedefsV8Internal::funcWithClampCallback):
2408
2409 2013-02-14  Christian Biesinger  <cbiesinger@chromium.org>
2410
2411         Convert media controls from DeprecatedFlexibleBox to FlexibleBox
2412         https://bugs.webkit.org/show_bug.cgi?id=109775
2413
2414         Reviewed by Ojan Vafai.
2415
2416         Covered by existing tests in media/.
2417
2418         * css/mediaControls.css:
2419         * css/mediaControlsBlackBerry.css:
2420         * css/mediaControlsChromium.css:
2421         * css/mediaControlsChromiumAndroid.css:
2422         * css/mediaControlsEfl.css:
2423         * css/mediaControlsGtk.css:
2424         * css/mediaControlsQt.css:
2425         * css/mediaControlsQuickTime.css:
2426         Automated search and replace of old flexbox CSS rules to new ones.
2427         Minor tuning of the chromium rules.
2428
2429         * rendering/RenderMediaControlElements.cpp:
2430         (WebCore::RenderMediaControlTimeDisplay::RenderMediaControlTimeDisplay):
2431         (WebCore::RenderMediaControlTimeDisplay::layout):
2432         * rendering/RenderMediaControlElements.h:
2433         Make media controls inherit from RenderFlexibleBox
2434
2435 2013-02-14  Roger Fong  <roger_fong@apple.com>
2436
2437         Build fix for Windows.
2438
2439         * Modules/webdatabase/SQLTransactionStateMachine.cpp:
2440         (WebCore::nameForSQLTransactionState):
2441
2442 2013-02-14  Dean Jackson  <dino@apple.com>
2443
2444         Inspector doesn't show rules from pluginsStyleSheet
2445         https://bugs.webkit.org/show_bug.cgi?id=109872
2446
2447         Reviewed by Darin Adler.
2448
2449         Make sure getWrapperForRuleInSheets collects the rules
2450         from CSSDefaultStyleSheets::plugInsStyleSheet.
2451
2452         Making a test for this is difficult because the rules in
2453         this sheet only apply to snapshotted plugins at the moment,
2454         which are disabled in DRT, and would require a fairly long
2455         timeout in the test.
2456
2457         * css/InspectorCSSOMWrappers.cpp:
2458         (WebCore::InspectorCSSOMWrappers::getWrapperForRuleInSheets):
2459
2460 2013-02-14  Hayato Ito  <hayato@chromium.org>
2461
2462         Recover edge names used in MemoryInstrumentation for DocumentRuleSets.
2463         https://bugs.webkit.org/show_bug.cgi?id=109800
2464
2465         Reviewed by Hajime Morita.
2466
2467         This is a following patch for r142573.
2468         r142563 accidentally removes edge names for MemoryInstrumentation. We should recover edge names.
2469
2470         No tests. No change in behavior.
2471
2472         * css/DocumentRuleSets.cpp:
2473         (WebCore::DocumentRuleSets::reportMemoryUsage):
2474
2475 2013-02-14  Hajime Morrita  <morrita@google.com>
2476
2477         [V8] Assertion failure on an exception is thrown
2478         https://bugs.webkit.org/show_bug.cgi?id=109129
2479
2480         An assertion in V8AbstractEventListener is wrong. This change turns it into an error check.
2481
2482         Reviewed by Kentaro Hara.
2483
2484         Test: fast/events/onerror-no-constructor.html
2485
2486         * bindings/v8/V8AbstractEventListener.cpp:
2487         (WebCore::V8AbstractEventListener::handleEvent):
2488
2489 2013-02-14  Kentaro Hara  <haraken@chromium.org>
2490
2491         [V8] CodeGeneratorV8.pm can assume that DOMWindow has [CheckSecurity]
2492         https://bugs.webkit.org/show_bug.cgi?id=109788
2493
2494         Reviewed by Adam Barth.
2495
2496         There is code like this:
2497
2498           if ($extendedAttr{"CheckSecurity"} || $interfaceName eq "DOMWindow")
2499
2500         This check is redundant. DOMWindow has [CheckSecurity]. We can remove the
2501         DOMWindow check.
2502
2503         No tests. No change in behavior.
2504
2505         * bindings/scripts/CodeGeneratorV8.pm:
2506         (GenerateReplaceableAttrSetter):
2507         (GenerateFunctionCallback):
2508         (GenerateNonStandardFunction):
2509         (GenerateImplementation):
2510
2511 2013-02-14  Joshua Bell  <jsbell@chromium.org>
2512
2513         [V8] IndexedDB: Remove unused creationContext paramter from idbKeyToV8Value
2514         https://bugs.webkit.org/show_bug.cgi?id=109870
2515
2516         Reviewed by Kentaro Hara.
2517
2518         This parameter was left over from when the function was toV8(IDBKey). Remove it.
2519
2520         No new tests - just removing dead code.
2521
2522         * bindings/v8/IDBBindingUtilities.cpp:
2523         (WebCore::idbKeyToV8Value): Remove unused parameter.
2524         (WebCore::injectIDBKeyIntoScriptValue): No need for dummy handle.
2525         (WebCore::idbKeyToScriptValue): No need for dummy handle.
2526
2527 2013-02-14  Kondapally Kalyan  <kalyan.kondapally@intel.com>
2528
2529         [WebGL][Qt] regression:r142786 Qt Build fix for Arm and Windows.
2530         https://bugs.webkit.org/show_bug.cgi?id=109797
2531
2532         Reviewed by Csaba Osztrogon√°c.
2533
2534         After r142786, we use OpenGLShims to load necessary GL functions
2535         exposed by ARB_vertex_array_object extension. Qt uses OpenGLShims
2536         to load functions with GLES too. This patch adds support for loading the
2537         equivalent functions on GLES exposed by OES_vertex_array_object.
2538         
2539         * platform/graphics/OpenGLShims.cpp:
2540         (WebCore::initializeOpenGLShims):
2541         * platform/graphics/OpenGLShims.h:
2542
2543 2013-02-14  Alexey Proskuryakov  <ap@apple.com>
2544
2545         <rdar://problem/13210723> CORS preflight broken with NetworkProcess
2546         https://bugs.webkit.org/show_bug.cgi?id=109753
2547
2548         Reviewed by Brady Eidson.
2549
2550         * loader/DocumentThreadableLoader.h:
2551         * loader/DocumentThreadableLoader.cpp:
2552         (WebCore::DocumentThreadableLoader::DocumentThreadableLoader):
2553         (WebCore::DocumentThreadableLoader::cancel):
2554         (WebCore::DocumentThreadableLoader::didReceiveResponse):
2555         (WebCore::DocumentThreadableLoader::dataReceived):
2556         (WebCore::DocumentThreadableLoader::didReceiveData):
2557         (WebCore::DocumentThreadableLoader::notifyFinished):
2558         (WebCore::DocumentThreadableLoader::didFinishLoading):
2559         (WebCore::DocumentThreadableLoader::didFail):
2560         (WebCore::DocumentThreadableLoader::preflightFailure): Notify InspectorInstrumentation
2561         immediately. In addition to keeping up eith other changes, this means that an accurate
2562         error will be passed now, not a cancellation.
2563         (WebCore::DocumentThreadableLoader::loadRequest):
2564         Get rid of m_preflightRequestIdentifier. Every loader has an identifier, and tracking
2565         identifiers twice is wrong.
2566         Pass identifier explicitly to more internal functions, so that they would not have to
2567         second-guess callers.
2568
2569         * loader/ResourceLoader.cpp: (WebCore::ResourceLoader::willSendRequest):
2570         Create an identifier for all loaders, not just those that we expect to have client
2571         callbacks about. Both Inspector and NetworkProcess need identifiers everywhere.
2572
2573         * loader/TextTrackLoader.cpp: (WebCore::TextTrackLoader::deprecatedDidReceiveCachedResource):
2574         * loader/TextTrackLoader.h:
2575         * loader/cache/CachedResourceClient.h:
2576         (WebCore::CachedResourceClient::deprecatedDidReceiveCachedResource):
2577         * loader/cache/CachedTextTrack.cpp: (WebCore::CachedTextTrack::data):
2578         Renamed didReceiveData to avoid conflict with the new DocumentThreadableLoader::didReceiveData.
2579         And we should really get rid of this CachedResourceClient function anyway.
2580
2581 2013-02-14  Kentaro Hara  <haraken@chromium.org>
2582
2583         Replace 'DOMObject' with 'any'
2584         https://bugs.webkit.org/show_bug.cgi?id=109793
2585
2586         Reviewed by Dimitri Glazkov.
2587
2588         In the Web IDL spec, there is no type named 'DOMObject'.
2589         It should be 'any'. We should replace all 'DOMObject's in WebKit IDLs with 'any's.
2590
2591         * Modules/webdatabase/SQLResultSetRowList.idl:
2592         * bindings/scripts/CodeGeneratorCPP.pm:
2593         (GetClassName):
2594         (AddIncludesForType):
2595         * bindings/scripts/CodeGeneratorGObject.pm:
2596         (GenerateFunction):
2597         * bindings/scripts/CodeGeneratorJS.pm:
2598         (AddIncludesForType):
2599         (GenerateImplementation):
2600         (JSValueToNative):
2601         (NativeToJSValue):
2602         * bindings/scripts/CodeGeneratorV8.pm:
2603         (GetNativeType):
2604         (JSValueToNative):
2605         (GetV8HeaderName):
2606         * dom/CustomEvent.idl:
2607         * dom/MessageEvent.idl:
2608         * dom/PopStateEvent.idl:
2609         * fileapi/FileReader.idl:
2610         * html/HTMLCanvasElement.idl:
2611         * html/HTMLElement.idl:
2612         * html/canvas/DataView.idl:
2613         * inspector/InjectedScriptHost.idl:
2614         * inspector/InspectorFrontendHost.idl:
2615         * inspector/JavaScriptCallFrame.idl:
2616         * page/DOMWindow.idl:
2617         * page/Location.idl:
2618
2619 2013-02-14  Kentaro Hara  <haraken@chromium.org>
2620
2621         [V8] Remove GenerateEventListenerCallback() from CodeGeneratorV8.pm
2622         https://bugs.webkit.org/show_bug.cgi?id=109786
2623
2624         Reviewed by Adam Barth.
2625
2626         Some code is duplicated between GenerateEventListenerCallback()
2627         and GenerateFunctionCallback(). By inlining GenerateEventListenerCallback()
2628         into GenerateFunctionCallback(), we can remove the duplication.
2629
2630         No tests. No change in behavior.
2631
2632         * bindings/scripts/CodeGeneratorV8.pm:
2633         (GenerateFunctionCallback):
2634
2635 2013-02-14  Ojan Vafai  <ojan@chromium.org>
2636
2637         Intrinsic and preferred widths on replaced elements are wrong in many cases
2638         https://bugs.webkit.org/show_bug.cgi?id=109859
2639
2640         Reviewed by Levi Weintraub.
2641
2642         Test: fast/replaced/preferred-widths.html
2643
2644         * rendering/RenderReplaced.cpp:
2645         (WebCore::RenderReplaced::computeIntrinsicLogicalWidths):
2646         Separate out computing the intrinsic widths. Eventually,
2647         we should be able to share computePreferredLogicalWidth implementations
2648         for all replaced elements and form controls since only the intrinsic width
2649         changes.
2650
2651         (WebCore::RenderReplaced::computePreferredLogicalWidths):
2652         -Apply min-width and max-width constraints and then add borderAndPaddingLogicalWidth
2653         at the end to make sure it's always applied. This matches all our other
2654         computePreferredLogicalWidths override and makes use match Gecko's/Opera's rendering.
2655         -Only set the minPreferredLogicalWidth to 0 if the width or max-width is a percent value.
2656         Doing it for height values and for min-width doesn't make any sense and doesn't
2657         match other browsers. Doing this for max-width still doesn't match other browsers,
2658         but it sounds like Gecko at least would like to change that.
2659
2660         * rendering/RenderReplaced.h:
2661         (WebCore::RenderReplaced::hasRelativeIntrinsicLogicalWidth):
2662         * rendering/svg/RenderSVGRoot.cpp:
2663         (WebCore::RenderSVGRoot::hasRelativeIntrinsicLogicalWidth):
2664         Add a way to check if the logicalWidth is relative so that we only check
2665         the width in computePreferredLogicalWidths instead of also checking the height.
2666
2667         * rendering/svg/RenderSVGRoot.h:
2668
2669 2013-02-14  Stephen Chenney  <schenney@chromium.org>
2670
2671         Crash when selecting a HarfBuzz text run with SVG fonts included
2672         https://bugs.webkit.org/show_bug.cgi?id=109833
2673
2674         Reviewed by Tony Chang.
2675
2676         There is an assert in SimpleFontData::applyTransforms that should not
2677         be there, as the code is valid for SVG fonts. If we get past this,
2678         then the HarfBuzz text run shaping code assumes that font data has a
2679         SkTypeface member, and SVG fonts do not. So we crash there too.
2680
2681         For now, we fix the crashes. This still leaves incorrect selection
2682         rectangles in this situation, on all platforms, tracked in
2683         https://bugs.webkit.org/show_bug.cgi?id=108133
2684
2685         Test: svg/css/font-face-crash.html
2686
2687         * platform/graphics/SimpleFontData.h:
2688         (WebCore::SimpleFontData::applyTransforms): Remove ASSERT_NOT_REACHED as the code can legally be reached for SVG fonts.
2689         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
2690         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns): Check for SVG fonts in the text run, and abort if we find them.
2691
2692 2013-02-13 Joe Mason <jmason@rim.com>
2693
2694         [BlackBerry] Notify platform layer of failing to get authentication credentials
2695         https://bugs.webkit.org/show_bug.cgi?id=109751
2696
2697         Reviewed by Yong Li.
2698         Reviewed internally by Leo Yang
2699         Internal PR: 181302
2700
2701         The BlackBerry platform network layer needs to know if a stream failed to get authentication credentials.
2702         This patch is using newly added stream API to do it.
2703
2704         No functionality changed no new tests.
2705
2706         * platform/network/blackberry/NetworkJob.cpp:
2707         (WebCore::NetworkJob::notifyAuthReceived):
2708         (WebCore::NetworkJob::sendRequestWithCredentials):
2709         (WebCore::NetworkJob::notifyChallengeResult):
2710         * platform/network/blackberry/NetworkJob.h:
2711         * platform/network/blackberry/NetworkManager.cpp:
2712         (WebCore::protectionSpaceToPlatformAuth):
2713         (WebCore):
2714         (WebCore::setAuthCredentials):
2715         * platform/network/blackberry/NetworkManager.h:
2716         (WebCore):
2717
2718 2013-02-14  Kondapally Kalyan  <kalyan.kondapally@intel.com>
2719
2720         [GTK] Fix indentation in GNUmakefile.list.am.
2721         https://bugs.webkit.org/show_bug.cgi?id=109854
2722
2723         Reviewed by Martin Robinson.
2724
2725         This patch fixes indentation in GNUmakefile.list.am.
2726
2727         * GNUmakefile.list.am:
2728
2729 2013-02-14  Tony Chang  <tony@chromium.org>
2730
2731         Unreviewed, set svn:eol-style native for .sln, .vcproj, and .vsprops files.
2732         https://bugs.webkit.org/show_bug.cgi?id=96934
2733
2734         * WebCore.vcproj/WebCore.sln: Modified property svn:eol-style.
2735         * WebCore.vcproj/WebCore.submit.sln: Modified property svn:eol-style.
2736
2737 2013-02-14  Abhishek Arya  <inferno@chromium.org>
2738
2739         Bad cast in RenderBlock::splitBlocks.
2740         https://bugs.webkit.org/show_bug.cgi?id=108691
2741
2742         Reviewed by Levi Weintraub.
2743
2744         Test: fast/multicol/remove-child-split-flow-crash.html
2745
2746         * rendering/RenderBlock.cpp:
2747         (WebCore):
2748         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks): rename gIsInColumnFlowSplit to gColumnFlowSplitEnabled
2749         and use it to decide when to do the column flow split or not.
2750         (WebCore::RenderBlock::removeChild): Do not allow column flow split inside removeChild
2751         since we might be merging anonymous blocks.
2752
2753 2013-02-14  Mark Lam  <mark.lam@apple.com>
2754
2755         Split SQLTransaction work between the frontend and backend.
2756         https://bugs.webkit.org/show_bug.cgi?id=104750.
2757
2758         Reviewed by Sam Weinig.
2759
2760         This is part of the webdatabase refactoring for webkit2.
2761
2762         1. Changed how transactions are created.
2763
2764            - Database::runTransaction() first creates a SQLTransaction frontend
2765              which encapsulates the 3 script callbacks. It then passes the
2766              SQLTransaction to the backend database to create the
2767              SQLTransactionBackend.
2768            - The SQLTransactionBackend manages all SQLiteTransaction work.
2769
2770         2. Introduced SQLTransactionState and SQLTransactionStateMachine.
2771
2772            - Instead of tracking the transaction phases as "steps" in m_nextStep,
2773              we now use m_nextState which is of enum class SQLTransactionState.
2774              Unlike m_nextStep which is a pointer to a "step" function,
2775              m_nextState is a state variable which is used to index into a
2776              state dispatch table.
2777
2778            - Both SQLTransaction and SQLTransactionBackend now extends
2779              SQLTransactionStateMachine, and uses its dispatch mechanism based on
2780              the SQLTransactionState.
2781
2782            - Instead of having 1 state machine instances, there are 2: 1 in the
2783              frontend, and 1 in the backend. The 2 have mirrored states, and
2784              transfers work to the other state machine when needed.
2785
2786            - Previously, state functions can be called inline from other states.
2787              They are now only called from the state machines runStateMachine()
2788              method. This makes it possible to isolate the state transition
2789              mechanism going between the sides (frontend and backend) to 2
2790              functions only: SQLTransaction::sendToBackendState() and
2791              SQLTransactionBackend::sendToFrontendState().
2792
2793         3. Consolidated cleanup work (mostly) to a unified cleanup function.
2794
2795         4. Changed the frontend Database::runTransaction() to use a
2796            ChangeVersionData* (instead of a ChangeVersionWrapper ref ptr).
2797
2798            - This is necessary because ChangeVersionWrapper contains functionality
2799              used in processing a transaction (to be invoked in the backend).
2800              Instead, what we want is to simply pass the 2 old and new version
2801              strings to the backend. The new ChangeVersionData simply packages up
2802              these 2 strings.
2803            - This makes ChangeVersionData easy to serialize for IPC messaging later.
2804
2805         5. Moved some transaction functions back to the frontend SQLTransaction
2806            because they belong there.
2807
2808         6. Moved some Database functions to its DatabaseBackendAsync backend
2809            now that the transaction has been split up.
2810
2811            - This is driven naturally by those functions being used exclusively
2812              in the backend for transaction work.
2813            - SQLTransactionClient, SQLTransactionCoordinator, and
2814              SQLTransactionWrapper are now exclusively backend data structures.
2815              SQLTransactionClient still has some frontend "pollution" that I'll
2816              fix later.
2817
2818         7. Made the few database report functions used only by Chromium conditional
2819            on PLATFORM(chromium).
2820
2821            - The report functions gets re-routed to Chromium's DatabaseObserver
2822              which further routes them elsewhere. It is unclear how Chromium uses
2823              these routed messages, and I am therefore not able to determine how
2824              they should work in a frontend/backend world. So, I'm #ifdef'ing
2825              them out. They still work like in the old way for Chromium.
2826
2827         8. Added new files to the build / project files.
2828
2829         9. Updated / added comments about how the transaction and its states work.
2830
2831         No new tests.
2832
2833         * CMakeLists.txt:
2834         * GNUmakefile.list.am:
2835         * Modules/webdatabase/AbstractDatabaseServer.h:
2836         * Modules/webdatabase/ChangeVersionData.h: Added.
2837         (ChangeVersionData):
2838         (WebCore::ChangeVersionData::ChangeVersionData):
2839         (WebCore::ChangeVersionData::oldVersion):
2840         (WebCore::ChangeVersionData::newVersion):
2841         * Modules/webdatabase/ChangeVersionWrapper.cpp:
2842         (WebCore::ChangeVersionWrapper::performPreflight):
2843         (WebCore::ChangeVersionWrapper::performPostflight):
2844         (WebCore::ChangeVersionWrapper::handleCommitFailedAfterPostflight):
2845         * Modules/webdatabase/ChangeVersionWrapper.h:
2846         (ChangeVersionWrapper):
2847         * Modules/webdatabase/Database.cpp:
2848         (WebCore::Database::Database):
2849         (WebCore::Database::close):
2850         (WebCore::Database::changeVersion):
2851         (WebCore::Database::transaction):
2852         (WebCore::Database::readTransaction):
2853         (WebCore::Database::runTransaction):
2854         (WebCore::Database::reportStartTransactionResult):
2855         (WebCore::Database::reportCommitTransactionResult):
2856         (WebCore::Database::reportExecuteStatementResult):
2857         * Modules/webdatabase/Database.h:
2858         (WebCore::Database::databaseContext):
2859         (Database):
2860         (WebCore::Database::reportStartTransactionResult):
2861         (WebCore::Database::reportCommitTransactionResult):
2862         (WebCore::Database::reportExecuteStatementResult):
2863         * Modules/webdatabase/DatabaseBackend.cpp:
2864         * Modules/webdatabase/DatabaseBackend.h:
2865         (DatabaseBackend):
2866         (WebCore::DatabaseBackend::reportOpenDatabaseResult):
2867         (WebCore::DatabaseBackend::reportChangeVersionResult):
2868         (WebCore::DatabaseBackend::reportStartTransactionResult):
2869         (WebCore::DatabaseBackend::reportCommitTransactionResult):
2870         (WebCore::DatabaseBackend::reportExecuteStatementResult):
2871         (WebCore::DatabaseBackend::reportVacuumDatabaseResult):
2872         * Modules/webdatabase/DatabaseBackendAsync.cpp:
2873         (WebCore::DatabaseBackendAsync::DatabaseBackendAsync):
2874         (WebCore::DatabaseBackendAsync::runTransaction):
2875         (WebCore::DatabaseBackendAsync::inProgressTransactionCompleted): Moved from frontend.
2876         (WebCore::DatabaseBackendAsync::scheduleTransaction): Moved from frontend.
2877         (WebCore::DatabaseBackendAsync::scheduleTransactionStep): Moved from frontend.
2878         (WebCore::DatabaseBackendAsync::transactionClient): Moved from frontend.
2879         (WebCore::DatabaseBackendAsync::transactionCoordinator): Moved from frontend.
2880         * Modules/webdatabase/DatabaseBackendAsync.h:
2881         (DatabaseBackendAsync):
2882         * Modules/webdatabase/DatabaseBackendContext.cpp:
2883         (WebCore::DatabaseBackendContext::frontend):
2884         * Modules/webdatabase/DatabaseBackendContext.h:
2885         (DatabaseBackendContext):
2886         * Modules/webdatabase/DatabaseManager.cpp:
2887         * Modules/webdatabase/DatabaseManager.h:
2888         (DatabaseManager):
2889         * Modules/webdatabase/DatabaseServer.cpp:
2890         * Modules/webdatabase/DatabaseServer.h:
2891         * Modules/webdatabase/DatabaseTask.cpp:
2892         (WebCore::DatabaseBackendAsync::DatabaseTransactionTask::doPerformTask):
2893         * Modules/webdatabase/SQLTransaction.cpp:
2894         (WebCore::SQLTransaction::create):
2895         (WebCore::SQLTransaction::SQLTransaction):
2896         (WebCore::SQLTransaction::setBackend):
2897         (WebCore::SQLTransaction::stateFunctionFor):
2898         (WebCore::SQLTransaction::requestTransitToState):
2899         (WebCore::SQLTransaction::nextStateForTransactionError):
2900             - was handleTransactionError(). There's also a backend version.
2901         (WebCore::SQLTransaction::deliverTransactionCallback): Moved from backend.
2902         (WebCore::SQLTransaction::deliverTransactionErrorCallback): Moved from backend.
2903         (WebCore::SQLTransaction::deliverStatementCallback): Moved from backend.
2904         (WebCore::SQLTransaction::deliverQuotaIncreaseCallback): Moved from backend.
2905         (WebCore::SQLTransaction::deliverSuccessCallback): Moved from backend.
2906         (WebCore::SQLTransaction::unreachableState):
2907         (WebCore::SQLTransaction::sendToBackendState):
2908         (WebCore::SQLTransaction::performPendingCallback): Moved from backend.
2909         (WebCore::SQLTransaction::executeSQL): Moved from backend.
2910         (WebCore::SQLTransaction::checkAndHandleClosedOrInterruptedDatabase):
2911         (WebCore::SQLTransaction::clearCallbackWrappers):
2912         * Modules/webdatabase/SQLTransaction.h:
2913         (SQLTransaction):
2914         (WebCore::SQLTransaction::database):
2915         (WebCore::SQLTransaction::hasCallback):
2916         (WebCore::SQLTransaction::hasSuccessCallback):
2917         (WebCore::SQLTransaction::hasErrorCallback):
2918         * Modules/webdatabase/SQLTransactionBackend.cpp:
2919         (WebCore::SQLTransactionBackend::create):
2920         (WebCore::SQLTransactionBackend::SQLTransactionBackend):
2921         (WebCore::SQLTransactionBackend::doCleanup):
2922         (WebCore::SQLTransactionBackend::transactionError):
2923         (WebCore::SQLTransactionBackend::setShouldRetryCurrentStatement):
2924         (WebCore::SQLTransactionBackend::stateFunctionFor):
2925         (WebCore::SQLTransactionBackend::enqueueStatement):
2926         (WebCore::SQLTransactionBackend::checkAndHandleClosedOrInterruptedDatabase):
2927         (WebCore::SQLTransactionBackend::performNextStep):
2928         (WebCore::SQLTransactionBackend::notifyDatabaseThreadIsShuttingDown):
2929         (WebCore::SQLTransactionBackend::acquireLock):
2930         (WebCore::SQLTransactionBackend::lockAcquired):
2931         (WebCore::SQLTransactionBackend::openTransactionAndPreflight):
2932         (WebCore::SQLTransactionBackend::runStatements):
2933         (WebCore::SQLTransactionBackend::runCurrentStatementAndGetNextState):
2934             - was runCurrentStatement().
2935         (WebCore::SQLTransactionBackend::nextStateForCurrentStatementError):
2936             - was handleCurrentStatementError().
2937         (WebCore::SQLTransactionBackend::postflightAndCommit):
2938         (WebCore::SQLTransactionBackend::cleanupAndTerminate):
2939         (WebCore::SQLTransactionBackend::nextStateForTransactionError):
2940             - was handleTransactionError(). There's also a frontend version.
2941         (WebCore::SQLTransactionBackend::cleanupAfterTransactionErrorCallback):
2942         (WebCore::SQLTransactionBackend::requestTransitToState):
2943         (WebCore::SQLTransactionBackend::unreachableState):
2944         (WebCore::SQLTransactionBackend::sendToFrontendState):
2945         * Modules/webdatabase/SQLTransactionBackend.h:
2946         (SQLTransactionWrapper):
2947         (SQLTransactionBackend):
2948         (WebCore::SQLTransactionBackend::database):
2949         * Modules/webdatabase/SQLTransactionClient.cpp:
2950         (WebCore::SQLTransactionClient::didCommitWriteTransaction):
2951         (WebCore::SQLTransactionClient::didExecuteStatement):
2952         * Modules/webdatabase/SQLTransactionCoordinator.cpp:
2953         (WebCore::getDatabaseIdentifier):
2954         * Modules/webdatabase/SQLTransactionState.h: Added.
2955         * Modules/webdatabase/SQLTransactionStateMachine.cpp: Added.
2956         (WebCore::nameForSQLTransactionState):
2957             - was debugStepName().
2958         * Modules/webdatabase/SQLTransactionStateMachine.h: Added.
2959         (SQLTransactionStateMachine):
2960         (WebCore::SQLTransactionStateMachine::~SQLTransactionStateMachine):
2961         (WebCore::::SQLTransactionStateMachine):
2962         (WebCore::::setStateToRequestedState):
2963         (WebCore::::runStateMachine):
2964         * Target.pri:
2965         * WebCore.gypi:
2966         * WebCore.vcproj/WebCore.vcproj:
2967         * WebCore.vcxproj/WebCore.vcxproj:
2968         * WebCore.vcxproj/WebCore.vcxproj.filters:
2969         * WebCore.xcodeproj/project.pbxproj:
2970         * inspector/InspectorDatabaseAgent.cpp:
2971
2972 2013-02-14  Jer Noble  <jer.noble@apple.com>
2973
2974         EME: replace MediaKeySession.addKey() -> update()
2975         https://bugs.webkit.org/show_bug.cgi?id=109461
2976
2977         Reviewed by Eric Carlson.
2978
2979         No new tests; updated media/encrypted-media/encrypted-media-v2-syntax.html test.
2980
2981         In the latest draft of the Encrypted Media Spec, the addKeys() method has been replaced
2982         with update().
2983
2984         * Modules/encryptedmedia/CDM.h:
2985         * Modules/encryptedmedia/MediaKeySession.cpp:
2986         (WebCore::MediaKeySession::update):
2987         (WebCore::MediaKeySession::addKeyTimerFired):
2988         * Modules/encryptedmedia/MediaKeySession.h:
2989         * Modules/encryptedmedia/MediaKeySession.idl:
2990         * html/HTMLMediaElement.cpp:
2991         (WebCore::HTMLMediaElement::webkitAddKey):
2992         * testing/MockCDM.cpp:
2993         (WebCore::MockCDMSession::update):
2994
2995 2013-02-14  Tony Chang  <tony@chromium.org>
2996
2997         Unreviewed, set svn:eol-style CRLF for .sln files.
2998
2999         * WebCore.vcproj/WebCore.sln: Modified property svn:eol-style.
3000         * WebCore.vcproj/WebCore.submit.sln: Modified property svn:eol-style.
3001
3002 2013-02-14  Eric Carlson  <eric.carlson@apple.com>
3003
3004         [Mac] adjust caption color user preference calculation
3005         https://bugs.webkit.org/show_bug.cgi?id=109840
3006
3007         Reviewed by Dean Jackson.
3008
3009         No new tests, it isn't possible to test this with DRT.
3010
3011         * page/CaptionUserPreferencesMac.mm:
3012         (WebCore::CaptionUserPreferencesMac::captionsWindowCSS): The color is "important" if either the
3013             color or opacity are supposed to override.
3014         (WebCore::CaptionUserPreferencesMac::captionsBackgroundCSS): Ditto.
3015         (WebCore::CaptionUserPreferencesMac::captionsTextColor): Ditto.
3016
3017         * WebCore.vcproj/WebCore.sln: Modified property svn:eol-style.
3018         * WebCore.vcproj/WebCore.submit.sln: Modified property svn:eol-style.
3019
3020 2013-02-14  Cosmin Truta  <ctruta@rim.com>
3021
3022         Numeric identifiers of events are not guaranteed to be unique
3023         https://bugs.webkit.org/show_bug.cgi?id=103259
3024
3025         Reviewed by Alexey Proskuryakov.
3026
3027         The results of setTimeout, setInterval and navigator.geolocation.watchPosition
3028         are positive integer values extracted from a simple circular sequential number
3029         generator, whose uniqueness can be guaranteed for no more than 2^31 calls to
3030         any of these functions. In order to provide this guarantee beyond this limit,
3031         we repeatedly ask for the next sequential id until we get one that's not used
3032         already.
3033
3034         This solution works instantly under normal circumstances, when there are few
3035         live timeout ids or geolocation ids at any given moment. Handling millions of
3036         live ids will require another solution.
3037
3038         No new tests. Brief tests of uniqueness already exist.
3039         Moreover, reproducing this particular issue would require 2^31 set/clear
3040         function calls, which is prohibitively expensive.
3041
3042         * Modules/geolocation/Geolocation.cpp:
3043         (WebCore::Geolocation::Watchers::add): Rename from Watchers::set; return false if watch id already exists.
3044         (WebCore::Geolocation::watchPosition): Repeat until the new watch id is unique.
3045         * Modules/geolocation/Geolocation.h:
3046         (Watchers): Rename Watchers::set to Watchers::add.
3047         * Modules/geolocation/Geolocation.idl: Rename the argument of Geolocation::clearWatch to WatchID.
3048         * dom/ScriptExecutionContext.cpp:
3049         (WebCore::ScriptExecutionContext::ScriptExecutionContext): Update initialization.
3050         (WebCore::ScriptExecutionContext::circularSequentialID): Rename from newUniqueID; remove FIXME note.
3051         * dom/ScriptExecutionContext.h:
3052         (ScriptExecutionContext): Rename ScriptExecutionContext::newUniqueID to ScriptExecutionContext::circularSequentialID.
3053         (WebCore::ScriptExecutionContext::addTimeout): Return false (do not assert) if timeout id already exists.
3054         * page/DOMTimer.cpp:
3055         (WebCore::DOMTimer::DOMTimer): Repeat until the new timeout id is unique.
3056
3057 2013-02-14  Sheriff Bot  <webkit.review.bot@gmail.com>
3058
3059         Unreviewed, rolling out r142825.
3060         http://trac.webkit.org/changeset/142825
3061         https://bugs.webkit.org/show_bug.cgi?id=109856
3062
3063         Causes some inspector tests to time out (Requested by anttik
3064         on #webkit).
3065
3066         * platform/mac/SharedTimerMac.mm:
3067         (WebCore):
3068         (WebCore::PowerObserver::restartSharedTimer):
3069         (WebCore::setSharedTimerFireInterval):
3070         (WebCore::stopSharedTimer):
3071
3072 2013-02-14  Lamarque V. Souza  <Lamarque.Souza@basyskom.com>
3073
3074         Support the ch unit from css3-values
3075         https://bugs.webkit.org/show_bug.cgi?id=85755
3076
3077         Reviewed by David Hyatt.
3078
3079         Original patch by Sumedha Widyadharma <sumedha.widyadharma@basyskom.com>.
3080
3081         Test: fast/css/css3-ch-unit.html
3082
3083         * css/CSSCalculationValue.cpp:
3084         (WebCore::unitCategory):
3085         * css/CSSGrammar.y.in:
3086         * css/CSSParser.cpp:
3087         (WebCore::CSSParser::validUnit):
3088         (WebCore::CSSParser::createPrimitiveNumericValue):
3089         (WebCore::CSSParser::parseValidPrimitive):
3090         (WebCore::CSSParser::detectNumberToken):
3091         * css/CSSParserValues.cpp:
3092         (WebCore::CSSParserValue::createCSSValue):
3093         * css/CSSPrimitiveValue.cpp:
3094         (WebCore::isValidCSSUnitTypeForDoubleConversion):
3095         (WebCore::CSSPrimitiveValue::cleanup):
3096         (WebCore::CSSPrimitiveValue::computeLengthDouble):
3097         (WebCore::CSSPrimitiveValue::customCssText):
3098         (WebCore::CSSPrimitiveValue::cloneForCSSOM):
3099         * css/CSSPrimitiveValue.h:
3100         (WebCore::CSSPrimitiveValue::isFontRelativeLength):
3101         (WebCore::CSSPrimitiveValue::isLength):
3102         * platform/graphics/FontMetrics.h:
3103         (WebCore::FontMetrics::FontMetrics):
3104         (WebCore::FontMetrics::zeroWidth):
3105         (WebCore::FontMetrics::setZeroWidth):
3106         (FontMetrics):
3107         (WebCore::FontMetrics::hasZeroWidth):
3108         (WebCore::FontMetrics::setHasZeroWidth):
3109         * platform/graphics/SimpleFontData.cpp:
3110         (WebCore::SimpleFontData::platformGlyphInit):
3111         * platform/graphics/SimpleFontData.h:
3112         (WebCore::SimpleFontData::zeroGlyph):
3113         (WebCore::SimpleFontData::setZeroGlyph):
3114         (SimpleFontData):
3115         * platform/graphics/qt/SimpleFontDataQt.cpp:
3116         (WebCore::SimpleFontData::platformInit):
3117
3118 2013-02-14  David Kilzer  <ddkilzer@apple.com>
3119
3120         [Mac] Clean up WARNING_CFLAGS
3121         <http://webkit.org/b/109747>
3122         <rdar://problem/13208373>
3123
3124         Reviewed by Mark Rowe.
3125
3126         * Configurations/Base.xcconfig: Use
3127         GCC_WARN_64_TO_32_BIT_CONVERSION to enable and disable
3128         -Wshorten-64-to-32 rather than WARNING_CFLAGS.
3129
3130 2013-02-14  Christophe Dumez  <ch.dumez@sisa.samsung.com>
3131
3132         Add addHTTPHeaderField() method to ResourceResponse
3133         https://bugs.webkit.org/show_bug.cgi?id=109844
3134
3135         Reviewed by Adam Barth.
3136
3137         ResourceRequestBase provides both setHTTPHeaderField() and addHTTPHeaderField(). However,
3138         ResourceResponseBase only provides setHTTPHeaderField(). This is a bit inconsistent. As a
3139         result, the addHTTPHeaderField() functionality's implementation is duplicated in several
3140         ports (at least chromium and soup).
3141
3142         This patch introduces addHTTPHeaderField() to ResourceResponseBase and makes use of it
3143         in Chromium and Soup backends.
3144
3145         No new tests, no behavior change.
3146
3147         * platform/chromium/support/WebURLResponse.cpp:
3148         (WebKit::WebURLResponse::addHTTPHeaderField): Use ResourceResponseBase::addHTTPHeaderField().
3149         * platform/network/ResourceResponseBase.cpp:
3150         (WebCore::ResourceResponseBase::updateHeaderParsedState): Move headers' parsed state update code
3151         from setHTTPHeaderField() to a new updateHeaderParsedState() method to avoid code duplication.
3152         (WebCore):
3153         (WebCore::ResourceResponseBase::setHTTPHeaderField):
3154         (WebCore::ResourceResponseBase::addHTTPHeaderField):
3155         * platform/network/ResourceResponseBase.h:
3156         (ResourceResponseBase):
3157         * platform/network/soup/ResourceResponseSoup.cpp:
3158         (WebCore::ResourceResponse::updateFromSoupMessageHeaders): Use ResourceResponseBase::addHTTPHeaderField().
3159
3160 2013-02-14  Philip Rogers  <pdr@google.com>
3161
3162         Prevent inconsistent firstChild during document destruction
3163         https://bugs.webkit.org/show_bug.cgi?id=106530
3164
3165         Reviewed by Abhishek Arya.
3166
3167         During document destruction, addChildNodesToDeletionQueue can allow a container
3168         node to have an invalid first child, causing a crash. This patch updates
3169         addChildNodesToDeletionQueue to maintain a valid value for firstChild() even
3170         while updating its children.
3171
3172         Test: svg/custom/animateMotion-path-change-crash.svg
3173
3174         * dom/ContainerNodeAlgorithms.h:
3175         (WebCore::Private::addChildNodesToDeletionQueue):
3176             To ensure prevoiusSibling() is also valid, this code was slightly refactored
3177             to call setPreviousSibling(0) on the next node instead of the current node.
3178
3179 2013-02-14  Julien Chaffraix  <jchaffraix@webkit.org>
3180
3181         [CSS Grid Layout] Add an internal 2D grid representation to RenderGrid
3182         https://bugs.webkit.org/show_bug.cgi?id=109714
3183
3184         Reviewed by Ojan Vafai.
3185
3186         This change introduces a 2D grid representation of the grid areas. Our implementation
3187         is a straight Vector of Vectors for the grid areas, each grid area able to hold an
3188         arbitrary number of RenderBox* so they hold a Vector of RenderBoxes. As an optimization,
3189         each grid area has enough inline storage to hold one grid item which should cover
3190         most cases.
3191
3192         In order to keep the code readable, a GridIterator was introduced to hide the new grid.
3193
3194         Refactoring, covered by existing tests.
3195
3196         * rendering/RenderGrid.cpp:
3197         (RenderGrid::GridIterator):
3198         (WebCore::RenderGrid::GridIterator::GridIterator):
3199         (WebCore::RenderGrid::GridIterator::nextGridItem):
3200         Added a mono-directional iterator. In order to be more aligned with the rest of the code,
3201         this iterator actually walks orthogonally to the |direction| (ie fixing the |direction|'s track).
3202
3203         * rendering/RenderGrid.cpp:
3204         (WebCore::RenderGrid::computePreferredLogicalWidths):
3205         (WebCore::RenderGrid::layoutGridItems):
3206         Updated these 2 functions to place the items on the grid and clear it at the end.
3207
3208         (WebCore::RenderGrid::computePreferredTrackWidth):
3209         (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForItems):
3210         Updated to use the GridIterator to walk over the rows / columns.
3211
3212         (WebCore::RenderGrid::placeItemsOnGrid):
3213         Added this function that inserts the grid items into the right grid area.
3214
3215         * rendering/RenderGrid.h:
3216         (WebCore::RenderGrid::gridColumnCount):
3217         (WebCore::RenderGrid::gridRowCount):
3218         Added these helper functions.
3219
3220 2013-02-14  Sheriff Bot  <webkit.review.bot@gmail.com>
3221
3222         Unreviewed, rolling out r141990.
3223         http://trac.webkit.org/changeset/141990
3224         https://bugs.webkit.org/show_bug.cgi?id=109850
3225
3226         ~5% regression on intl2 page cycler (Requested by kling on
3227         #webkit).
3228
3229         * platform/graphics/GlyphPage.h:
3230         (WebCore::GlyphPage::create):
3231         (WebCore::GlyphPage::glyphDataForCharacter):
3232         (WebCore::GlyphPage::glyphDataForIndex):
3233         (WebCore::GlyphPage::fontDataForCharacter):
3234         (WebCore::GlyphPage::setGlyphDataForIndex):
3235         (GlyphPage):
3236         (WebCore::GlyphPage::copyFrom):
3237         (WebCore::GlyphPage::clear):
3238         (WebCore::GlyphPage::clearForFontData):
3239         (WebCore::GlyphPage::GlyphPage):
3240         * platform/graphics/GlyphPageTreeNode.cpp:
3241         (WebCore::GlyphPageTreeNode::initializePage):
3242         * rendering/svg/SVGTextRunRenderingContext.cpp:
3243         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
3244
3245 2013-02-14  Mark Pilgrim  <pilgrim@chromium.org>
3246
3247         [Chromium] Move PlatformMessagePortChannel to WebCore
3248         https://bugs.webkit.org/show_bug.cgi?id=109845
3249
3250         Reviewed by Adam Barth.
3251
3252         Part of a larger refactoring series; see tracking bug 106829.
3253
3254         * WebCore.gyp/WebCore.gyp:
3255         * WebCore.gypi:
3256         * dom/default/chromium: Added.
3257         * dom/default/chromium/PlatformMessagePortChannelChromium.cpp: Added.
3258         (WebCore):
3259         (WebCore::MessagePortChannel::create):
3260         (WebCore::MessagePortChannel::createChannel):
3261         (WebCore::MessagePortChannel::MessagePortChannel):
3262         (WebCore::MessagePortChannel::~MessagePortChannel):
3263         (WebCore::MessagePortChannel::entangleIfOpen):
3264         (WebCore::MessagePortChannel::disentangle):
3265         (WebCore::MessagePortChannel::postMessageToRemote):
3266         (WebCore::MessagePortChannel::tryGetMessageFromRemote):
3267         (WebCore::MessagePortChannel::close):
3268         (WebCore::MessagePortChannel::isConnectedTo):
3269         (WebCore::MessagePortChannel::hasPendingActivity):
3270         (WebCore::MessagePortChannel::locallyEntangledPort):
3271         (WebCore::PlatformMessagePortChannel::create):
3272         (WebCore::PlatformMessagePortChannel::PlatformMessagePortChannel):
3273         (WebCore::PlatformMessagePortChannel::~PlatformMessagePortChannel):
3274         (WebCore::PlatformMessagePortChannel::createChannel):
3275         (WebCore::PlatformMessagePortChannel::messageAvailable):
3276         (WebCore::PlatformMessagePortChannel::entangleIfOpen):
3277         (WebCore::PlatformMessagePortChannel::disentangle):
3278         (WebCore::PlatformMessagePortChannel::postMessageToRemote):
3279         (WebCore::PlatformMessagePortChannel::tryGetMessageFromRemote):
3280         (WebCore::PlatformMessagePortChannel::close):
3281         (WebCore::PlatformMessagePortChannel::isConnectedTo):
3282         (WebCore::PlatformMessagePortChannel::hasPendingActivity):
3283         (WebCore::PlatformMessagePortChannel::setEntangledChannel):
3284         (WebCore::PlatformMessagePortChannel::webChannelRelease):
3285         * dom/default/chromium/PlatformMessagePortChannelChromium.h: Added.
3286         (WebKit):
3287         (WebCore):
3288         (PlatformMessagePortChannel):
3289
3290 2013-02-14  Chris Fleizach  <cfleizach@apple.com>
3291
3292         Remove Leopard Accessibility support from WebCore (now that no port builds on Leopard)
3293         https://bugs.webkit.org/show_bug.cgi?id=90250
3294
3295         Reviewed by Eric Seidel.
3296
3297         The Leopard era checks for accessibility lists and accessibility tables can be removed now.
3298
3299         * accessibility/AccessibilityARIAGrid.cpp:
3300         (WebCore):
3301         * accessibility/AccessibilityARIAGrid.h:
3302         (AccessibilityARIAGrid):
3303         (WebCore::AccessibilityARIAGrid::isTableExposableThroughAccessibility):
3304         * accessibility/AccessibilityList.cpp:
3305         (WebCore::AccessibilityList::computeAccessibilityIsIgnored):
3306         * accessibility/AccessibilityList.h:
3307         * accessibility/AccessibilityTable.cpp:
3308         (WebCore::AccessibilityTable::AccessibilityTable):
3309         (WebCore::AccessibilityTable::init):
3310         * accessibility/AccessibilityTable.h:
3311         (AccessibilityTable):
3312         * accessibility/mac/AXObjectCacheMac.mm:
3313         (WebCore::AXObjectCache::postPlatformNotification):
3314         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
3315         (createAccessibilityRoleMap):
3316
3317 2013-02-14  Bear Travis  <betravis@adobe.com>
3318
3319         Make outside-shape the default value for shape-inside
3320         https://bugs.webkit.org/show_bug.cgi?id=109605
3321
3322         Reviewed by Levi Weintraub.
3323
3324         Creating a single reference outside-shape value and setting it as the default
3325         for shape-inside.
3326
3327         Existing tests cover the default value, just updating them to use outside-shape.
3328
3329         * rendering/style/RenderStyle.cpp:
3330         (WebCore::RenderStyle::initialShapeInside): Define a local static outside-shape
3331         value.
3332         (WebCore):
3333         * rendering/style/RenderStyle.h: Move the initialShapeInside method to the .cpp
3334         file.
3335
3336 2013-02-14  Min Qin  <qinmin@chromium.org>
3337
3338         Passing alpha to DeferredImageDecoder once decoding completes
3339         https://bugs.webkit.org/show_bug.cgi?id=108892
3340
3341         Reviewed by Stephen White.
3342
3343         We should pass hasAlpha value back to the DeferredImageDecoder once decoding is completed
3344         Added unit tests in ImageFrameGeneratorTest.
3345
3346         * platform/graphics/chromium/DeferredImageDecoder.cpp:
3347         (WebCore::DeferredImageDecoder::frameHasAlphaAtIndex):
3348         * platform/graphics/chromium/ImageFrameGenerator.cpp:
3349         (WebCore::ImageFrameGenerator::tryToScale):
3350         (WebCore::ImageFrameGenerator::decode):
3351         * platform/graphics/chromium/LazyDecodingPixelRef.cpp:
3352         (WebCore::LazyDecodingPixelRef::LazyDecodingPixelRef):
3353         (WebCore::LazyDecodingPixelRef::onUnlockPixels):
3354         * platform/graphics/chromium/LazyDecodingPixelRef.h:
3355         (WebCore::LazyDecodingPixelRef::hasAlpha):
3356         (LazyDecodingPixelRef):
3357         * platform/graphics/chromium/ScaledImageFragment.cpp:
3358         (WebCore::ScaledImageFragment::ScaledImageFragment):
3359         * platform/graphics/chromium/ScaledImageFragment.h:
3360         (WebCore::ScaledImageFragment::create):
3361         (ScaledImageFragment):
3362         (WebCore::ScaledImageFragment::hasAlpha):
3363
3364 2013-02-14  David Grogan  <dgrogan@chromium.org>
3365
3366         IndexedDB: Add a few more histogram calls
3367         https://bugs.webkit.org/show_bug.cgi?id=109762
3368
3369         Reviewed by Tony Chang.
3370
3371         A few places where commits could fail weren't being logged.
3372
3373         * Modules/indexeddb/IDBBackingStore.cpp:
3374         (WebCore::IDBBackingStore::deleteDatabase):
3375         (WebCore::IDBBackingStore::Transaction::commit):
3376
3377 2013-02-14  Tony Chang  <tony@chromium.org>
3378
3379         Padding and border changes doesn't trigger relayout of children
3380         https://bugs.webkit.org/show_bug.cgi?id=109639
3381
3382         Reviewed by Kent Tamura.
3383
3384         In RenderBlock::layoutBlock, we only relayout our children if our logical width
3385         changes. This misses cases where our logical width doesn't change (i.e., padding
3386         or border changes), but our content width does change.
3387
3388         This is a more general case of bug 104997.
3389
3390         Test: fast/block/dynamic-padding-border.html
3391
3392         * rendering/RenderBox.cpp:
3393         (WebCore::borderOrPaddingLogicalWidthChanged): Only check if the logical width changed.
3394         (WebCore::RenderBox::styleDidChange): Drop the border-box condition since this can happen
3395         even without border-box box sizing.
3396
3397 2013-02-14  Peter Rybin  <prybin@chromium.org>
3398
3399         Web Inspector: fix closure compilation warnings caused by setVariableValue change
3400         https://bugs.webkit.org/show_bug.cgi?id=109488
3401
3402         Reviewed by Pavel Feldman.
3403
3404         Annotations are fixed as required by closure compiler.
3405         Parameters in Inspector.json are reordered as required.
3406
3407         * inspector/InjectedScriptExterns.js:
3408         (InjectedScriptHost.prototype.setFunctionVariableValue):
3409         (JavaScriptCallFrame.prototype.setVariableValue):
3410         * inspector/InjectedScriptSource.js:
3411         (.):
3412         * inspector/Inspector.json:
3413         * inspector/InspectorDebuggerAgent.cpp:
3414         (WebCore::InspectorDebuggerAgent::setVariableValue):
3415         * inspector/InspectorDebuggerAgent.h:
3416         (InspectorDebuggerAgent):
3417
3418 2013-02-14  Tommy Widenflycht  <tommyw@google.com>
3419
3420         MediaStream API: RTCDataChannel triggers a use-after-free