[EFL] accessibility/loading-iframe-sends-notification.html is failing
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-09-25  Krzysztof Czech  <k.czech@samsung.com>
2
3         [EFL] accessibility/loading-iframe-sends-notification.html is failing
4         https://bugs.webkit.org/show_bug.cgi?id=112003
5
6         Reviewed by Mario Sanchez Prada.
7
8         Enabled AXLayoutComplete on EFL platform.
9
10         * dom/Document.cpp:
11         (WebCore::Document::implicitClose):
12         * page/FrameView.cpp:
13         (WebCore::FrameView::layout):
14
15 2013-09-24  Commit Queue  <commit-queue@webkit.org>
16
17         Unreviewed, rolling out r156379.
18         http://trac.webkit.org/changeset/156379
19         https://bugs.webkit.org/show_bug.cgi?id=121894
20
21         Caused many assertion failures (Requested by ap on #webkit).
22
23         * css/CSSValue.cpp:
24         (WebCore::CSSValue::destroy):
25         * css/StyleResolver.cpp:
26         (WebCore::StyleResolver::createCustomFilterOperationWithInlineSyntax):
27         (WebCore::StyleResolver::createFilterOperations):
28         * css/TransformFunctions.cpp:
29         (WebCore::transformsForValue):
30         * css/WebKitCSSArrayFunctionValue.h:
31         * css/WebKitCSSFilterValue.h:
32         * css/WebKitCSSMatFunctionValue.h:
33         * css/WebKitCSSMixFunctionValue.h:
34         * css/WebKitCSSSVGDocumentValue.h:
35         * css/WebKitCSSShaderValue.h:
36         (WebCore::toWebKitCSSShaderValue):
37         * css/WebKitCSSTransformValue.h:
38
39 2013-09-24  Ryosuke Niwa  <rniwa@webkit.org>
40
41         Crash in Document::setFocusedElement
42         https://bugs.webkit.org/show_bug.cgi?id=121888
43
44         Reviewed by Andreas Kling.
45
46         Merge https://chromium.googlesource.com/chromium/blink/+/4a594a3de7d9761462b55fb27a6850d767419af2
47
48         The crash was caused by attempting to call Chrome:focusedNodeChanged() after m_page had already
49         been cleared. This could happen when blur's event handler removes the iframe from which
50         the focus had been moved. Fixed the bug by adding a null pointer check.
51
52         Test: fast/events/blur-remove-parent-crash.html
53
54         * dom/Document.cpp:
55         (WebCore::Document::setFocusedElement):
56
57 2013-09-24  Antti Koivisto  <antti@apple.com>
58
59         Remove HTMLContentElement
60         https://bugs.webkit.org/show_bug.cgi?id=121891
61
62         Reviewed by Andreas Kling.
63
64         Remove an unsused Shadow DOM type.
65
66         * DerivedSources.make:
67         * WebCore.exp.in:
68         * WebCore.xcodeproj/project.pbxproj:
69         * html/HTMLDetailsElement.cpp:
70         * html/HTMLSummaryElement.cpp:
71         * html/HTMLTagNames.in:
72         * html/shadow/ContentDistributor.cpp:
73         * html/shadow/HTMLContentElement.cpp: Removed.
74         * html/shadow/HTMLContentElement.h: Removed.
75         * html/shadow/HTMLContentElement.idl: Removed.
76         * html/shadow/InsertionPoint.h:
77         (WebCore::InsertionPoint::matchTypeFor):
78         * testing/Internals.cpp:
79         * testing/Internals.h:
80         * testing/Internals.idl:
81
82 2013-09-24  Benjamin Poulain  <benjamin@webkit.org>
83
84         Remove a contradiction from SelectorChecker
85         https://bugs.webkit.org/show_bug.cgi?id=121881
86
87         Reviewed by Andreas Kling.
88
89         The matching code for PseudoHover and PseudoActive is done on the current
90         selector pseudo type. The current selector match type must be CSSSelector::PseudoClass
91         in order to reach this code. Consequently, selector->m_match == CSSSelector::Tag can
92         never be true.
93
94         * css/SelectorChecker.cpp:
95         (WebCore::SelectorChecker::checkOne):
96
97 2013-09-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
98
99         Add toWebKitCSS*Value functions to cast from CSSValue
100         https://bugs.webkit.org/show_bug.cgi?id=121776
101
102         Reviewed by Darin Adler.
103
104         CSS_VALUE_TYPE_CASTS can't cover WebKitCSS*Value classes. So, this patch adds toWebKitCSS*Value manually.
105
106         No new tests, no behavior change.
107
108         * css/CSSValue.cpp:
109         (WebCore::CSSValue::destroy):
110         * css/StyleResolver.cpp:
111         (WebCore::StyleResolver::createCustomFilterOperationWithInlineSyntax):
112         (WebCore::StyleResolver::createFilterOperations):
113         * css/TransformFunctions.cpp:
114         (WebCore::transformsForValue):
115         * css/WebKitCSSArrayFunctionValue.h:
116         (WebCore::toWebKitCSSArrayFunctionValue):
117         * css/WebKitCSSFilterValue.h:
118         (WebCore::toWebKitCSSFilterValue):
119         * css/WebKitCSSMatFunctionValue.h:
120         (WebCore::toWebKitCSSMatFunctionValue):
121         * css/WebKitCSSMixFunctionValue.h:
122         (WebCore::toWebKitCSSMixFunctionValue):
123         * css/WebKitCSSSVGDocumentValue.h:
124         (WebCore::toWebKitCSSSVGDocumentValue):
125         * css/WebKitCSSShaderValue.h:
126         (WebCore::toWebKitCSSShaderValue):
127         * css/WebKitCSSTransformValue.h:
128         (WebCore::toWebKitCSSTransformValue):
129
130 2013-09-24  Antti Koivisto  <antti@apple.com>
131
132         Clean up some uses of first/lastChildSlow
133         https://bugs.webkit.org/show_bug.cgi?id=121882
134
135         Reviewed by Andreas Kling.
136
137         Tighten typing and use first/lastChild instead.
138
139         * dom/Position.cpp:
140         (WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
141         (WebCore::Position::isCandidate):
142         (WebCore::Position::getInlineBoxAndOffset):
143         * dom/Position.h:
144         * dom/PositionIterator.cpp:
145         (WebCore::PositionIterator::isCandidate):
146         * editing/CompositeEditCommand.cpp:
147         (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
148         * rendering/RenderBlock.cpp:
149         (WebCore::canMergeAnonymousBlock):
150         (WebCore::canMergeContiguousAnonymousBlocks):
151         (WebCore::RenderBlock::firstLineBlock):
152         (WebCore::RenderBlock::updateFirstLetter):
153         * rendering/RenderRegion.cpp:
154         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
155         (WebCore::RenderRegion::computeChildrenStyleInRegion):
156         * rendering/RenderRegion.h:
157         * rendering/RenderRuby.cpp:
158         (WebCore::rubyBeforeBlock):
159         (WebCore::rubyAfterBlock):
160         (WebCore::lastRubyRun):
161         * rendering/RenderTreeAsText.cpp:
162         (WebCore::write):
163         (WebCore::writeCounterValuesFromChildren):
164         * rendering/svg/RenderSVGText.cpp:
165         (WebCore::findPreviousAndNextAttributes):
166         * style/StyleResolveTree.cpp:
167         (WebCore::Style::textRendererIsNeeded):
168
169 2013-09-24  Mark Lam  <mark.lam@apple.com>
170
171         Change JSC debug hooks to pass a CallFrame* instead of a DebuggerCallFrame.
172         https://bugs.webkit.org/show_bug.cgi?id=121867.
173
174         Reviewed by Geoffrey Garen.
175
176         No new tests.
177
178         * bindings/js/ScriptDebugServer.cpp:
179         (WebCore::ScriptDebugServer::createCallFrame):
180         (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
181         (WebCore::ScriptDebugServer::callEvent):
182         (WebCore::ScriptDebugServer::atStatement):
183         (WebCore::ScriptDebugServer::returnEvent):
184         (WebCore::ScriptDebugServer::exception):
185         (WebCore::ScriptDebugServer::willExecuteProgram):
186         (WebCore::ScriptDebugServer::didExecuteProgram):
187         (WebCore::ScriptDebugServer::didReachBreakpoint):
188         * bindings/js/ScriptDebugServer.h:
189         * bindings/js/WorkerScriptDebugServer.cpp:
190         (WebCore::WorkerScriptDebugServer::willExecuteProgram):
191         * bindings/js/WorkerScriptDebugServer.h:
192
193 2013-09-24  Andreas Kling  <akling@apple.com>
194
195         Move keyboard event dispatch from Node to Element.
196         <https://webkit.org/b/121873>
197
198         Reviewed by Antti Koivisto.
199
200         We only dispatch keyboard events on Elements so that logic shouldn't be in Node.
201
202         * dom/Document.cpp:
203         (WebCore::eventTargetElementForDocument):
204
205             Reworked to return Element instead of Node.
206
207         * dom/Document.h:
208         * dom/Element.h:
209         * dom/Element.cpp:
210         (WebCore::Element::dispatchKeyEvent):
211
212             Moved from Node to Element.
213
214         * editing/AlternativeTextController.cpp:
215         (WebCore::AlternativeTextController::insertDictatedText):
216         * page/EventHandler.cpp:
217         (WebCore::EventHandler::keyEvent):
218         (WebCore::EventHandler::handleTextInputEvent):
219
220             Adjusted for above changes.
221
222 2013-09-24  Zoltan Horvath  <zoltan@webkit.org>
223
224         [CSS Shapes] Modify updateSegmentsForShapes function to use logical coordinates
225         https://bugs.webkit.org/show_bug.cgi?id=121864
226
227         Reviewed by David Hyatt.
228
229         When I landed updateSegmentsForShapes in r156022, I didn't use logical coordinates. This change modifies the
230         code to use coordinates for positioning the float and the content around the float in a shape-inside. Now I
231         added only one writing mode tests, but I will add more later in bug #121866.
232
233         Test: fast/shapes/shape-inside/shape-inside-left-float-in-upper-left-triangle-vertical-lr-inline-content.html
234
235         * rendering/FloatingObjects.h:
236         (WebCore::FloatingObject::logicalHeight):
237         * rendering/RenderBlock.cpp:
238         (WebCore::RenderBlock::computeLogicalLocationForFloat):
239         * rendering/RenderBlockLineLayout.cpp:
240         (WebCore::updateSegmentsForShapes):
241
242 2013-09-24  Brady Eidson  <beidson@apple.com>
243
244         Remove IDBTransactionCallbacks.h from the .xcodeproj, as it's gone from the repository.
245
246         Rubberstamped by Anders Carlsson and Alexey Proskuryakov.
247
248         * WebCore.xcodeproj/project.pbxproj:
249
250 2013-09-24  Antti Koivisto  <antti@apple.com>
251
252         Tighten table rendering code
253         https://bugs.webkit.org/show_bug.cgi?id=121860
254
255         Reviewed by Andreas Kling.
256
257         Hide firstChild/lastChild/nextSibling/previousSibling in table renderers, 
258         expose correctly typed firstRow/nextCell etc instead.
259
260 2013-09-24  Dean Jackson  <dino@apple.com>
261
262         Implement symbol name hashing for WebGL shaders
263         https://bugs.webkit.org/show_bug.cgi?id=121849
264
265         Reviewed by Anders Carlsson.
266
267         Turn on ANGLE's symbol name mapping for shader programs.
268         This avoids compilation failures (or worse, crashers)
269         on some hardware that doesn't like it when shaders redefine
270         symbols like "sin", even though that is valid.
271
272         The way ANGLE exposes this is via setting a pointer
273         to a char* -> uint64_t hash function. Since we only have
274         a 32-bit hash in WebKit, I combine the 32-bit value with
275         a counter value that exists over the lifetime of a GC3D context.
276         Before calling ANGLE, I point the global hash map to the local
277         hash map, and then clean up after we're done. This introduces
278         a memory hit, in that the symbol table will build up until
279         the context is released.
280
281         Covered by Khronos WebGL tests, including
282         conformance/glsl/misc/shader-with-non-reserved-words.html
283
284         * platform/graphics/GraphicsContext3D.h: Define a ShaderNameHash type,
285         and add an OwnPtr to one as a member variable.
286         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
287         (WebCore::nameHashForShader): Global function used for ANGLE hashing.
288         (WebCore::GraphicsContext3D::compileShader): Set up the ANGLE properties,
289         point to the local hash map, and call compile/translate.
290
291 2013-09-24  Dean Jackson  <dino@apple.com>
292
293         Use mapped name in attribute location binding
294         https://bugs.webkit.org/show_bug.cgi?id=121847
295         <rdar://problem/15067526>
296
297         Reviewed by Eric Carlson.
298
299         The shader that we send down to OpenGL to compile
300         may have been translated by ANGLE, so we keep a
301         table around that maps input symbols to output symbols.
302         We used the table when binding to and looking up
303         uniforms, and when looking up attributes, but not
304         when actually binding to attribute locations.
305
306         Test: fast/canvas/webgl/gl-bind-attrib-mapped-names.html
307
308         * platform/graphics/ANGLEWebKitBridge.cpp:
309         (WebCore::getSymbolInfo): Add logging of symbol mapping.
310         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
311         (WebCore::GraphicsContext3D::bindAttribLocation): Used the mapped name.
312         (WebCore::GraphicsContext3D::getAttribLocation): Remove comment since
313         we do the lookup everywhere.
314         (WebCore::GraphicsContext3D::getUniformLocation): Ditto.
315
316 2013-09-24  Enrica Casucci  <enrica@apple.com>
317
318         Upstream changes to Pasteboard implementation for iOS.
319         https://bugs.webkit.org/show_bug.cgi?id=121818
320
321         Reviewed by Darin Adler.
322
323         * WebCore.xcodeproj/project.pbxproj:
324         * editing/Editor.cpp:
325         (WebCore::Editor::cut):
326         (WebCore::Editor::copyImage):
327         * editing/ios/EditorIOS.mm:
328         (WebCore::attributedStringForRange):
329         (WebCore::dataInRTFDFormat):
330         (WebCore::dataInRTFFormat):
331         (WebCore::Editor::stringSelectionForPasteboardWithImageAltText):
332         (WebCore::Editor::selectionInWebArchiveFormat):
333         (WebCore::Editor::writeSelectionToPasteboard):
334         (WebCore::getImage):
335         (WebCore::Editor::writeImageToPasteboard):
336         * platform/Pasteboard.h:
337         * platform/PasteboardStrategy.h:
338         * platform/PlatformPasteboard.h:
339         * platform/ios/PasteboardIOS.mm:
340         * platform/ios/PlatformPasteboardIOS.mm: Added.
341         (WebCore::PlatformPasteboard::PlatformPasteboard):
342         (WebCore::PlatformPasteboard::getTypes):
343         (WebCore::PlatformPasteboard::bufferForType):
344         (WebCore::PlatformPasteboard::getPathnamesForType):
345         (WebCore::PlatformPasteboard::stringForType):
346         (WebCore::PlatformPasteboard::color):
347         (WebCore::PlatformPasteboard::url):
348         (WebCore::PlatformPasteboard::copy):
349         (WebCore::PlatformPasteboard::addTypes):
350         (WebCore::PlatformPasteboard::setTypes):
351         (WebCore::PlatformPasteboard::setBufferForType):
352         (WebCore::PlatformPasteboard::setPathnamesForType):
353         (WebCore::PlatformPasteboard::setStringForType):
354         (WebCore::PlatformPasteboard::changeCount):
355         (WebCore::PlatformPasteboard::uniqueName):
356         (WebCore::PlatformPasteboard::write):
357
358 2013-09-24  Mark Rowe  <mrowe@apple.com>
359
360         <rdar://problem/14971518> WebKit should build against the Xcode default toolchain when targeting OS X 10.8
361
362         Reviewed by Dan Bernstein.
363
364         * Configurations/Base.xcconfig:
365
366 2013-09-24  Daniel Bates  <dabates@apple.com>
367
368         [iOS] Upstream -webkit-touch-callout
369         https://bugs.webkit.org/show_bug.cgi?id=121507
370
371         Reviewed by Antti Koivisto.
372
373         * css/CSSComputedStyleDeclaration.cpp:
374         (WebCore::ComputedStyleExtractor::propertyValue):
375         * css/CSSParser.cpp:
376         (WebCore::CSSParser::parseValue):
377         * css/CSSPropertyNames.in: Added -webkit-touch-callout.
378         * css/StyleResolver.cpp:
379         (WebCore::StyleResolver::applyProperty):
380         * html/HTMLImageElement.cpp:
381         (WebCore::HTMLImageElement::willRespondToMouseClickEvents): Added.
382         * html/HTMLImageElement.h:
383         * rendering/style/RenderStyle.h:
384         * rendering/style/StyleRareInheritedData.cpp:
385         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
386         (WebCore::StyleRareInheritedData::operator==):
387         * rendering/style/StyleRareInheritedData.h:
388
389 2013-09-24  Bem Jones-Bey  <bjonesbe@adobe.com>
390
391         Properly handle bottom margin on float with shape-outside
392         https://bugs.webkit.org/show_bug.cgi?id=121808
393
394         Reviewed by David Hyatt.
395
396         When a float has a shape-outside, inline content must conform to the
397         shape, not to the margin box. Thus, if a float with shape-outside has
398         a bottom margin and the shape does not intrude into that margin, then
399         the inline content should ignore the margin. Before this patch, inline
400         content would drop below the margin box instead of obeying the shape.
401         
402         Note that content that should clear the float still clears the margin
403         box, not the shape's contour.
404
405         Tests: csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-002.html
406                csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-003.html
407                csswg/contributors/adobe/submitted/shapes/shape-outside/shape-outside-floats-margin-004.html
408
409         * rendering/LineWidth.cpp:
410         (WebCore::LineWidth::fitBelowFloats): Compute the logical bottom based
411         on the shape.
412         * rendering/RenderBlock.cpp:
413         (WebCore::RenderBlock::nextFloatLogicalBottomBelow): Add option to
414         compute the logical bottom based on the shape instead of on the margin
415         box.
416         * rendering/RenderBlock.h:
417
418 2013-09-24  Lorenzo Tilve  <ltilve@igalia.com>
419
420         [GTK] Fix compilation problems when setting ENABLE_DRAG_SUPPORT = FALSE
421         https://bugs.webkit.org/show_bug.cgi?id=121782
422
423         Reviewed by Martin Robinson.
424
425         Disabled drag functions.
426
427         * page/gtk/EventHandlerGtk.cpp:
428         * platform/gtk/PasteboardGtk.cpp:
429
430 2013-09-24  Samuel White  <samuel_white@apple.com>
431
432         AX: Replace AXObjectCache postNotification method boolean arguments with enum values.
433         https://bugs.webkit.org/show_bug.cgi?id=121504
434
435         Reviewed by Chris Fleizach.
436
437         No new tests, no functional changes. Changed argument type from bool
438         to enum per "Names" rule #10 in the WebKit coding style guidelines.
439
440         * accessibility/AXObjectCache.cpp:
441         (WebCore::AXObjectCache::textChanged):
442         (WebCore::AXObjectCache::postNotification):
443         (WebCore::AXObjectCache::checkedStateChanged):
444         (WebCore::AXObjectCache::selectedChildrenChanged):
445         (WebCore::AXObjectCache::handleAttributeChanged):
446         * accessibility/AXObjectCache.h:
447         (WebCore::AXObjectCache::postNotification):
448         * accessibility/AccessibilityMenuList.cpp:
449         (WebCore::AccessibilityMenuList::didUpdateActiveOption):
450         * accessibility/AccessibilityMenuListPopup.cpp:
451         (WebCore::AccessibilityMenuListPopup::didUpdateActiveOption):
452         * accessibility/AccessibilityNodeObject.cpp:
453         (WebCore::AccessibilityNodeObject::childrenChanged):
454         (WebCore::AccessibilityNodeObject::changeValueByStep):
455         (WebCore::AccessibilityNodeObject::changeValueByPercent):
456         * accessibility/AccessibilityRenderObject.cpp:
457         (WebCore::AccessibilityRenderObject::handleAriaExpandedChanged):
458         (WebCore::AccessibilityRenderObject::handleActiveDescendantChanged):
459         (WebCore::AccessibilityRenderObject::textChanged):
460         * dom/Document.cpp:
461         (WebCore::Document::implicitClose):
462         * editing/Editor.cpp:
463         (WebCore::Editor::respondToChangedContents):
464         (WebCore::Editor::markAndReplaceFor):
465         * editing/mac/FrameSelectionMac.mm:
466         (WebCore::FrameSelection::notifyAccessibilityForSelectionChange):
467         * html/HTMLTextFormControlElement.cpp:
468         (WebCore::HTMLTextFormControlElement::setInnerTextValue):
469         * html/InputType.cpp:
470         (WebCore::InputType::applyStep):
471         * html/RangeInputType.cpp:
472         (WebCore::RangeInputType::handleKeydownEvent):
473         * page/FocusController.cpp:
474         (WebCore::FocusController::setInitialFocus):
475         * page/FrameView.cpp:
476         (WebCore::FrameView::layout):
477
478 2013-09-24  Andreas Kling  <akling@apple.com>
479
480         Make hoverAncestor() a RenderElement concept.
481         <https://webkit.org/b/121845>
482
483         Reviewed by Antti Koivisto.
484
485         The hover ancestor renderer is always a RenderElement, we only ever
486         ask RenderElements for their hover ancestors.
487
488         Updated Document::updateHoverActiveState() to take advantage of the
489         tighter typing, removing a few isElementNode() checks.
490
491 2013-09-24  Daniel Bates  <dabates@apple.com>
492
493         [iOS] Initialize settings mediaPlayback{AllowsInline, RequiresUserGesture} and
494         shouldRespectImageOrientation as appropriate
495         https://bugs.webkit.org/show_bug.cgi?id=121792
496
497         Reviewed by Darin Adler.
498
499         On iOS we explicitly want to disable mediaPlaybackAllowsInline, and enable
500         mediaPlaybackRequiresUserGesture and shouldRespectImageOrientation by default.
501         This differs from other platforms. We need to extract the initialization logic
502         for these settings into constants whose definition is conditioned on the platform.
503
504         * page/Settings.cpp:
505         * page/Settings.in:
506
507 2013-09-24  peavo@outlook.com  <peavo@outlook.com>
508
509         [WinCairo] Compile error.
510         https://bugs.webkit.org/show_bug.cgi?id=121839
511
512         Reviewed by Brent Fulgham.
513
514         * platform/graphics/GraphicsContext3DPrivate.cpp:
515         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate): Added missing guard.
516
517 2013-09-24  Andreas Kling  <akling@apple.com>
518
519         Cache continuation() in a local to avoid repeat hash lookups.
520         <https://webkit.org/b/121840>
521
522         Reviewed by Geoffrey Garen.
523
524         RenderBoxModelObject::continuation() does a hash lookup every time.
525         Cache the result in a local instead of calling it repeatedly.
526
527         * rendering/RenderBlock.h:
528         (WebCore::RenderBlock::isAnonymousBlockContinuation):
529
530             Reorder to check bitfield before hash map.
531
532         * rendering/RenderBlock.cpp:
533         (WebCore::RenderBlock::updateDragState):
534         * rendering/RenderInline.cpp:
535         (WebCore::RenderInline::absoluteRects):
536         (WebCore::RenderInline::absoluteQuads):
537         (WebCore::RenderInline::clippedOverflowRectForRepaint):
538         (WebCore::RenderInline::updateDragState):
539         (WebCore::RenderInline::addFocusRingRects):
540
541             Cache continuation() in locals where it's used more than once.
542
543 2013-09-24  Allan Sandfeld Jensen  <allan.jensen@digia.com>
544
545         [Qt] Crash when trying to download blob url
546         https://bugs.webkit.org/show_bug.cgi?id=121681
547
548         Reviewed by Simon Hausmann.
549
550         Resolve any blob URLs before creating a QUrl.
551
552         * platform/network/qt/ResourceRequestQt.cpp:
553         (WebCore::appendBlobResolved):
554         (WebCore::resolveBlobUrl):
555         (WebCore::ResourceRequest::toNetworkRequest):
556
557 2013-09-23  Antti Koivisto  <antti@apple.com>
558
559         Move more style change code from RenderObject to RenderElement
560         https://bugs.webkit.org/show_bug.cgi?id=121822
561
562         Reviewed by Darin Adler.
563
564         * rendering/RenderElement.cpp:
565         (WebCore::RenderElement::~RenderElement):
566         
567             RenderTexts are no longer registered as image clients. They don't need be unregistered either.
568
569         (WebCore::RenderElement::adjustStyleDifference):
570         (WebCore::RenderElement::hasImmediateNonWhitespaceTextChild):
571         (WebCore::RenderElement::shouldRepaintForStyleDifference):
572         (WebCore::RenderElement::updateFillImages):
573         (WebCore::RenderElement::updateImage):
574         (WebCore::RenderElement::updateShapeImage):
575         (WebCore::RenderElement::setStyle):
576         
577             Move from RenderObject and remove the text specific bits.
578
579         * rendering/RenderElement.h:
580         * rendering/RenderObject.cpp:
581         (WebCore::RenderObject::setStyle):
582         (WebCore::RenderObject::arenaDelete):
583         * rendering/RenderObject.h:
584         
585             Remove styleWill/DidChange which move to subclasses.
586
587         * rendering/RenderText.cpp:
588         (WebCore::RenderText::setStyle):
589         
590             Add simple text specific setStyle.
591
592         * rendering/RenderText.h:
593
594 2013-09-24  Andrei Parvu  <parvu@adobe.com>
595
596         [CSS Background] repeat: round should round the number of tiles to the nearest natural number
597         https://bugs.webkit.org/show_bug.cgi?id=120668
598
599         Reviewed by Darin Adler.
600
601         Tests already available in css3/masking and css3/background
602
603         * rendering/RenderBoxModelObject.cpp: Rounded the number of tiles to the nearest natural number.
604         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
605
606 2013-09-24  Ryuan Choi  <ryuan.choi@samsung.com>
607
608         Remove ScrollView::platformInit() and ScrollView::platformDestroy()
609         https://bugs.webkit.org/show_bug.cgi?id=121824
610
611         Reviewed by Darin Adler.
612
613         ScrollView::platformInit() and ScrollView::platformDestroy() are just
614         empty functions for all ports after removed WX port at r149186.
615
616         * PlatformEfl.cmake: Removed ScrollViewEfl.cpp from source list.
617         * platform/ScrollView.cpp: Removed platformInit and PlatformDestroy.
618         (WebCore::ScrollView::ScrollView):
619         (WebCore::ScrollView::~ScrollView):
620         * platform/ScrollView.h: Ditto.
621         * platform/efl/ScrollViewEfl.cpp: Removed.
622
623 2013-09-23  Darin Adler  <darin@apple.com>
624
625         Use unique_ptr instead of deleteAllValues in FloatingObject code
626         https://bugs.webkit.org/show_bug.cgi?id=121823
627
628         Reviewed by Sam Weinig.
629
630         * rendering/FloatingObjects.cpp:
631         (WebCore::FloatingObject::create): Return a unique_ptr instead of PassOwnPtr.
632         Use auto and a word for the local variable instead of an abbreviation. Also
633         changed to take a reference instead of a pointer.
634         (WebCore::FloatingObject::copyToNewContainer): Ditto.
635         (WebCore::FloatingObject::unsafeClone): Ditto.
636         (WebCore::FloatingObjects::~FloatingObjects): Removed call to deleteAllValues.
637         (WebCore::FloatingObjects::clearLineBoxTreePointers): Use auto to make this
638         read clearly.
639         (WebCore::FloatingObjects::clear): Removed call to deleteAllValues.
640         (WebCore::FloatingObjects::moveAllToFloatInfoMap): Use std::move to move values
641         out of the set, into the map. Removed code to clear the set, since it was a
642         trick to prevent the values from being deleted when they were not moved.
643         (WebCore::FloatingObjects::add): Changed to take a unique_ptr and to move the
644         pointer into the set instead of using leakPtr.
645         (WebCore::FloatingObjects::remove): Rearranged code so that the remove is at
646         the end of the function rather than the beginning. Also had to use a hash
647         translator and a find/remove combo since we don't have hash translator version
648         of the remove function.
649         (WebCore::FloatingObjects::computePlacedFloatsTree): Updated for changes to
650         the types.
651         (WebCore::FloatingObjects::placedFloatsTree): Moved this function here instead
652         of having it in the header, since it's only used within the file.
653
654         * rendering/FloatingObjects.h: Changed functions to take references instead
655         of pointers and return unique_ptr instead of PassOwnPtr. Also made
656         constructors public so we can use them with make_unique. Changed types to
657         use unique_ptr instead of raw pointers, and made the FloatingObjectHashTranslator
658         work for both RenderBox& and FloatingObject&.
659
660         * rendering/LineWidth.cpp:
661         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
662         Updated for changes to types.
663
664         * rendering/RenderBlock.cpp:
665         (WebCore::RenderBlock::styleDidChange):
666         (WebCore::RenderBlock::moveAllChildrenIncludingFloatsTo):
667         (WebCore::RenderBlock::addOverflowFromFloats):
668         (WebCore::RenderBlock::repaintOverhangingFloats):
669         (WebCore::RenderBlock::paintFloats):
670         (WebCore::RenderBlock::selectionGaps):
671         (WebCore::RenderBlock::insertFloatingObject):
672         (WebCore::RenderBlock::removeFloatingObject):
673         (WebCore::RenderBlock::removeFloatingObjectsBelow):
674         (WebCore::RenderBlock::positionNewFloats):
675         (WebCore::RenderBlock::nextFloatLogicalBottomBelow):
676         (WebCore::RenderBlock::lowestFloatLogicalBottom):
677         (WebCore::RenderBlock::addOverhangingFloats):
678         (WebCore::RenderBlock::hasOverhangingFloat):
679         (WebCore::RenderBlock::addIntrudingFloats):
680         (WebCore::RenderBlock::containsFloat):
681         (WebCore::RenderBlock::markSiblingsWithFloatsForLayout):
682         (WebCore::RenderBlock::updateLocalFloatingObjectsForPaintingContainer):
683         (WebCore::RenderBlock::hitTestFloats):
684         (WebCore::RenderBlock::adjustForBorderFit):
685         Updated for changes to types.
686
687         * rendering/RenderBlockFlow.cpp:
688         (WebCore::RenderBlockFlow::clearFloats): Updated to use take instead of
689         a combination of remove and delete.
690
691         * rendering/RenderBlockLineLayout.cpp:
692         (WebCore::RenderBlock::layoutRunsAndFloats):
693         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
694         (WebCore::RenderBlock::linkToEndLineIfNeeded):
695         (WebCore::RenderBlock::checkPaginationAndFloatsAtEndLine):
696         (WebCore::RenderBlock::positionNewFloatOnLine):
697         Updated for changes to types.
698
699 2013-09-23  Gurpreet Kaur  <k.gurpreet@samsung.com>
700
701         CSS Unit vh, vw, vmin and vmax in box-shadow are not applied.
702         https://bugs.webkit.org/show_bug.cgi?id=121422
703
704         Reviewed by Darin Adler.
705
706         Box-shadow properties were not applied incase its values
707         were given in vh, vw, vmax, vmin unit.
708
709         Tests: fast/css/box-shadow-negative-viewportlength.html
710                fast/css/box-shadow-viewport-height.html
711                fast/css/box-shadow-viewport-vmax.html
712                fast/css/box-shadow-viewport-vmin.html
713                fast/css/box-shadow-viewport-width.html
714
715         * css/CSSParser.cpp:
716         (WebCore::CSSParser::parseShadow):
717         * css/StyleResolver.cpp:
718         (WebCore::StyleResolver::applyProperty):
719         (WebCore::StyleResolver::MatchedProperties::~MatchedProperties):
720         (WebCore::StyleResolver::viewportPercentageHeight):
721         (WebCore::StyleResolver::viewportPercentageWidth):
722         (WebCore::StyleResolver::viewportPercentageMax):
723         (WebCore::StyleResolver::viewportPercentageMin):
724         * css/StyleResolver.h:
725         Parsing and calculating the shadow values which has been specified
726         in viewport units.The vh/vw units are calcultated as percent of
727         viewport height and viewport width respectively. 1vmax: 1vw or 1vh,
728         whatever is largest.1vmin: 1vw or 1vh, whatever is smallest.
729
730 2013-09-23  Ryuan Choi  <ryuan.choi@samsung.com>
731
732         Unreviewed build fix for CMake ports with INDEXED_DATABASE after r156296
733
734         * CMakeLists.txt: Removed IDBBackingStore.cpp from source list.
735
736 2013-09-23  Anders Carlsson  <andersca@apple.com>
737
738         Remove WTF_USE_SCROLLBAR_PAINTER #define
739         https://bugs.webkit.org/show_bug.cgi?id=121819
740
741         Reviewed by Sam Weinig.
742
743         Remove unnecessary if checks and dead code.
744
745         * platform/mac/NSScrollerImpDetails.h:
746         * platform/mac/ScrollAnimatorMac.mm:
747         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
748         (WebCore::ScrollAnimatorMac::~ScrollAnimatorMac):
749         (WebCore::ScrollAnimatorMac::contentAreaWillPaint):
750         (WebCore::ScrollAnimatorMac::mouseEnteredContentArea):
751         (WebCore::ScrollAnimatorMac::mouseExitedContentArea):
752         (WebCore::ScrollAnimatorMac::mouseMovedInContentArea):
753         (WebCore::ScrollAnimatorMac::mouseEnteredScrollbar):
754         (WebCore::ScrollAnimatorMac::mouseExitedScrollbar):
755         (WebCore::ScrollAnimatorMac::willStartLiveResize):
756         (WebCore::ScrollAnimatorMac::contentsResized):
757         (WebCore::ScrollAnimatorMac::willEndLiveResize):
758         (WebCore::ScrollAnimatorMac::contentAreaDidShow):
759         (WebCore::ScrollAnimatorMac::contentAreaDidHide):
760         (WebCore::ScrollAnimatorMac::didBeginScrollGesture):
761         (WebCore::ScrollAnimatorMac::didEndScrollGesture):
762         (WebCore::ScrollAnimatorMac::mayBeginScrollGesture):
763         (WebCore::ScrollAnimatorMac::finishCurrentScrollAnimations):
764         (WebCore::ScrollAnimatorMac::didAddVerticalScrollbar):
765         (WebCore::ScrollAnimatorMac::willRemoveVerticalScrollbar):
766         (WebCore::ScrollAnimatorMac::didAddHorizontalScrollbar):
767         (WebCore::ScrollAnimatorMac::willRemoveHorizontalScrollbar):
768         (WebCore::ScrollAnimatorMac::shouldScrollbarParticipateInHitTesting):
769         (WebCore::ScrollAnimatorMac::notifyContentAreaScrolled):
770         (WebCore::ScrollAnimatorMac::cancelAnimations):
771         (WebCore::ScrollAnimatorMac::setIsActive):
772         (WebCore::ScrollAnimatorMac::updateScrollerStyle):
773         (WebCore::ScrollAnimatorMac::initialScrollbarPaintTimerFired):
774         * platform/mac/ScrollViewMac.mm:
775         (WebCore::toNSScrollerKnobStyle):
776         (WebCore::ScrollView::platformSetScrollbarOverlayStyle):
777         * platform/mac/ScrollbarThemeMac.mm:
778         (WebCore::updateArrowPlacement):
779         (WebCore::ScrollbarThemeMac::registerScrollbar):
780         (WebCore::ScrollbarThemeMac::ScrollbarThemeMac):
781         (WebCore::ScrollbarThemeMac::scrollbarThickness):
782         (WebCore::ScrollbarThemeMac::usesOverlayScrollbarsChanged):
783         (WebCore::ScrollbarThemeMac::hasThumb):
784         (WebCore::ScrollbarThemeMac::minimumThumbLength):
785         (WebCore::ScrollbarThemeMac::updateEnabledState):
786         (WebCore::ScrollbarThemeMac::paint):
787
788 2013-09-23  Brent Fulgham  <bfulgham@apple.com>
789
790         [Windows] Moving back in history from a page with <video>, then moving forward causes crash.
791         https://bugs.webkit.org/show_bug.cgi?id=120475
792
793         Reviewed by Anders Carlsson.
794
795         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
796         (WebCore::AVFWrapper::AVFWrapper): Add assertion that creation is on main thread.
797         (WebCore::AVFWrapper::~AVFWrapper): Add assertion that destruction is on main thread.
798         (WebCore::destroyAVFWrapper): Helper function to dispatch on main queue.
799         (WebCore::AVFWrapper::disconnectAndDeleteAVFWrapper): Spawn AVFoundationCF destruction to
800         main queue.
801
802 2013-09-23  Andreas Kling  <akling@apple.com>
803
804         RenderTextControlSingleLine::updateFromElement() override not needed.
805         <https://webkit.org/b/121815>
806
807         Reviewed by Anders Carlsson.
808
809         * rendering/RenderTextControlSingleLine.cpp:
810         * rendering/RenderTextControlSingleLine.h:
811
812 2013-09-23  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
813
814         Introduce CSS_VALUE_TYPE_CASTS macro in order to cast CSSValue type
815         https://bugs.webkit.org/show_bug.cgi?id=121462
816
817         Reviewed by Darin Adler.
818
819         As r155429 introduced ELEMENT_TYPE_CASTS, CSS_VALUE_TYPE_CASTS can be used
820         by css value type casting as well. This type cast macros will help to detect
821         bad-cast bugs as well as improve a code readibility.
822
823         This patch adds the following methods,
824
825         - CSSFooValue* toCSSFooValue(CSSValue*)
826         - const CSSFooValue* toCSSFooValue(const CSSValue*)
827
828         This patch support CSSImageSetValue and CSSReflectValue first. Other CSS*Values
829         will use this macro step by step.
830
831         Besides this patch will remove unnecessary local variables.
832
833         No new tests, no behavior change.
834
835         * css/CSSCursorImageValue.cpp:
836         (WebCore::CSSCursorImageValue::cachedImage):
837         (WebCore::CSSCursorImageValue::cachedOrPendingImage):
838         * css/CSSImageSetValue.h:
839         * css/CSSReflectValue.h:
840         * css/CSSValue.cpp:
841         (WebCore::CSSValue::destroy):
842         * css/CSSValue.h:
843         * css/StyleResolver.cpp:
844         (WebCore::hasVariableReference):
845         (WebCore::StyleResolver::applyProperty):
846         (WebCore::StyleResolver::styleImage):
847         * rendering/style/StylePendingImage.h:
848         (WebCore::StylePendingImage::cssImageSetValue):
849
850 2013-09-23  Antti Koivisto  <antti@apple.com>
851
852         Move style change analysis code to RenderElement
853         https://bugs.webkit.org/show_bug.cgi?id=121812
854
855         Reviewed by Andreas Kling.
856
857         Text renderers don't need this. There is no text renderer specific invalidation and text
858         style never changes independent from the containing RenderElement.
859
860 2013-09-23  Commit Queue  <commit-queue@webkit.org>
861
862         Unreviewed, rolling out r156307.
863         http://trac.webkit.org/changeset/156307
864         https://bugs.webkit.org/show_bug.cgi?id=121817
865
866         Broke the build, and crashes the compiler (Requested by ap on
867         #webkit).
868
869         * css/MediaQuery.cpp:
870         (WebCore::expressionCompare):
871         (WebCore::MediaQuery::MediaQuery):
872         * dom/MutationObserver.cpp:
873         (WebCore::MutationObserver::ObserverLessThan::operator()):
874         (WebCore::MutationObserver::deliverAllMutations):
875         * page/CaptionUserPreferences.cpp:
876         (WebCore::textTrackCompare):
877         (WebCore::CaptionUserPreferences::sortedTrackListForMenu):
878
879 2013-09-23  Andreas Kling  <akling@apple.com>
880
881         Move rendererForRootBackground() to RenderElement.
882         <http://webkit.org/b/121813>
883
884         Reviewed by Antti Koivisto.
885
886         Move this to RenderElement (and make it return one, too) since the
887         document element renderer will always be a RenderElement.
888
889 2013-09-23  Brady Eidson  <beidson@apple.com>
890
891         Make the Mac build work with IndexedDB enabled.
892         https://bugs.webkit.org/show_bug.cgi?id=121814
893
894         Reviewed by Alexey Proskuryakov.
895
896         This patch makes the Mac build work if one were to enable the IndexedDB feature flag.
897         This patch does not actually enable the flag for everyone.
898
899         * DerivedSources.make:
900         * WebCore.xcodeproj/project.pbxproj:
901
902         * Modules/indexeddb/IDBBackingStore.cpp: Added.
903         (WebCore::IDBBackingStore::open):
904         (WebCore::IDBBackingStore::openInMemory):
905         (WebCore::IDBBackingStore::getObjectStores):
906         (WebCore::IDBBackingStore::Cursor::advance):
907         (WebCore::IDBBackingStore::Cursor::continueFunction):
908         (WebCore::IDBBackingStore::Transaction::Transaction):
909         (WebCore::IDBBackingStore::Transaction::begin):
910         (WebCore::IDBBackingStore::Transaction::commit):
911         (WebCore::IDBBackingStore::Transaction::rollback):
912         * Modules/indexeddb/IDBBackingStore.h:
913         (WebCore::LevelDBFactory::~LevelDBFactory):
914         (WebCore::IDBBackingStore::Transaction::reset):
915         (WebCore::IDBBackingStore::Transaction::levelDBTransactionFrom):
916
917         * Modules/indexeddb/IDBKeyPath.cpp:
918         (WebCore::IDBIsValidKeyPath):
919
920         * bindings/js/IDBBindingUtilities.cpp:
921         (WebCore::createIDBKeyFromValue):
922
923         * bindings/js/JSIDBAnyCustom.cpp:
924         (WebCore::toJS):
925
926 2013-09-23  Andreas Kling  <akling@apple.com>
927
928         CTTE: RenderObject::container() should return a RenderElement*.
929         <https://webkit.org/b/121811>
930
931         Reviewed by Antti Koivisto.
932
933         The containing renderer is always a RenderElement.
934
935 2013-09-23  Anders Carlsson  <andersca@apple.com>
936
937         Test the waters and begin using lambdas
938         https://bugs.webkit.org/show_bug.cgi?id=121809
939
940         Reviewed by Andreas Kling.
941
942         Use lambdas instead of static functions and function objects.
943         
944         * css/MediaQuery.cpp:
945         (WebCore::MediaQuery::MediaQuery):
946         * dom/MutationObserver.cpp:
947         (WebCore::MutationObserver::deliverAllMutations):
948         * page/CaptionUserPreferences.cpp:
949         (WebCore::CaptionUserPreferences::sortedTrackListForMenu):
950
951 2013-09-23  Patrick Gansterer  <paroga@webkit.org>
952
953         [WIN] Add implementation for WebCore::readFromFile()
954         https://bugs.webkit.org/show_bug.cgi?id=119210
955
956         Reviewed by Brent Fulgham.
957
958         * platform/win/FileSystemWin.cpp:
959         (WebCore::readFromFile):
960
961 2013-09-23  Patrick Gansterer  <paroga@webkit.org>
962
963         [WIN] Implement WebMutableURLRequest::setHTTPBody()
964         https://bugs.webkit.org/show_bug.cgi?id=91920
965
966         Reviewed by Brent Fulgham.
967
968         Add a method to FormData for growing the internal buffer with a given size.
969
970         * platform/network/FormData.cpp:
971         (WebCore::FormData::appendData):
972         (WebCore::FormData::expandDataStore):
973         * platform/network/FormData.h:
974
975 2013-09-23  Patrick Gansterer  <paroga@webkit.org>
976
977         use NOMINMAX instead of #define min min
978         https://bugs.webkit.org/show_bug.cgi?id=73563
979
980         Reviewed by Brent Fulgham.
981
982         Use NOMINMAX instead of #define min/max as a cleaner
983         way of ensuring that Windows system header files don't
984         define min/max as macro in the first place.
985
986         * WebCorePrefix.h:
987         * config.h:
988
989 2013-09-23  Simon Fraser  <simon.fraser@apple.com>
990
991         REGRESSION (r155998): when zooming in, tiles are too small
992         https://bugs.webkit.org/show_bug.cgi?id=121765
993
994         Reviewed by Dean Jackson.
995
996         In r155998 I made GraphicsLayerCA take root-relative transforms
997         into account when computing contentsScale, and landed a bunch of
998         new results which should actually have told me that I broke page
999         scaling.
1000         
1001         We don't want to take page scale into account when computing contentsScale,
1002         because we already do so, so ignore the transform on the layer that
1003         applies page scale (the only transform it should ever has is the page scale).
1004
1005         * platform/graphics/ca/GraphicsLayerCA.cpp:
1006         (WebCore::GraphicsLayerCA::updateRootRelativeScale):
1007
1008 2013-09-23  Antonio Gomes  <a1.gomes@sisa.samsung.com>
1009
1010         iframe and scrollbar with "overflow:auto" should support autoscroll with mousedrag
1011         https://bugs.webkit.org/show_bug.cgi?id=40981
1012
1013         Reviewed by Darin Adler.
1014
1015         RenderBox::calculateAutoscrollDirection does not properly translate
1016         inner frames' coordinates in order to determine its auto-scrollability.
1017         By coincidence, if the inner frame box it placed near to page's 0, 0 position
1018         (upper left corner), it might work.
1019
1020         Patch fixes it by changing ::calculateAutoscrollDirection algorithm to operate
1021         with window coordinates, taking inner frames offset and scroll position into account.
1022         The behavior of auto-scrollable non-frame overflow boxes, including divs, still works
1023         as it is used to.
1024
1025         Test: fast/events/drag-and-drop-autoscroll-inner-frame.html
1026
1027         * rendering/RenderBox.cpp:
1028         (WebCore::RenderBox::calculateAutoscrollDirection):
1029
1030 2013-09-23  Brady Eidson  <beidson@apple.com>
1031
1032         Move LevelDB specific IDB files into their own subdirectory.
1033         https://bugs.webkit.org/show_bug.cgi?id=121804
1034
1035         Rubberstamped by Alexey Proskuryakov.
1036
1037         * CMakeLists.txt:
1038         * GNUmakefile.list.am:
1039         * WebCore.xcodeproj/project.pbxproj:
1040
1041         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp: Renamed from Source/WebCore/Modules/indexeddb/IDBBackingStore.cpp.
1042         (WebCore::recordInternalError):
1043         (WebCore::putBool):
1044         (WebCore::getInt):
1045         (WebCore::putInt):
1046         (WebCore::getVarInt):
1047         (WebCore::putVarInt):
1048         (WebCore::getString):
1049         (WebCore::putString):
1050         (WebCore::putIDBKeyPath):
1051         (WebCore::compareKeys):
1052         (WebCore::compareIndexKeys):
1053         (WebCore::Comparator::compare):
1054         (WebCore::Comparator::name):
1055         (WebCore::isSchemaKnown):
1056         (WebCore::setUpMetadata):
1057         (WebCore::getMaxObjectStoreId):
1058         (WebCore::DefaultLevelDBFactory::openLevelDB):
1059         (WebCore::DefaultLevelDBFactory::destroyLevelDB):
1060         (WebCore::IDBBackingStore::IDBBackingStore):
1061         (WebCore::IDBBackingStore::~IDBBackingStore):
1062         (WebCore::IDBBackingStore::open):
1063         (WebCore::IDBBackingStore::openInMemory):
1064         (WebCore::IDBBackingStore::create):
1065         (WebCore::IDBBackingStore::getDatabaseNames):
1066         (WebCore::IDBBackingStore::getIDBDatabaseMetaData):
1067         (WebCore::getNewDatabaseId):
1068         (WebCore::IDBBackingStore::createIDBDatabaseMetaData):
1069         (WebCore::IDBBackingStore::updateIDBDatabaseIntVersion):
1070         (WebCore::IDBBackingStore::updateIDBDatabaseMetaData):
1071         (WebCore::deleteRange):
1072         (WebCore::IDBBackingStore::deleteDatabase):
1073         (WebCore::checkObjectStoreAndMetaDataType):
1074         (WebCore::IDBBackingStore::getObjectStores):
1075         (WebCore::setMaxObjectStoreId):
1076         (WebCore::IDBBackingStore::createObjectStore):
1077         (WebCore::IDBBackingStore::deleteObjectStore):
1078         (WebCore::IDBBackingStore::getRecord):
1079         (WebCore::getNewVersionNumber):
1080         (WebCore::IDBBackingStore::putRecord):
1081         (WebCore::IDBBackingStore::clearObjectStore):
1082         (WebCore::IDBBackingStore::deleteRecord):
1083         (WebCore::IDBBackingStore::getKeyGeneratorCurrentNumber):
1084         (WebCore::IDBBackingStore::maybeUpdateKeyGeneratorCurrentNumber):
1085         (WebCore::IDBBackingStore::keyExistsInObjectStore):
1086         (WebCore::checkIndexAndMetaDataKey):
1087         (WebCore::IDBBackingStore::getIndexes):
1088         (WebCore::setMaxIndexId):
1089         (WebCore::IDBBackingStore::createIndex):
1090         (WebCore::IDBBackingStore::deleteIndex):
1091         (WebCore::IDBBackingStore::putIndexDataForRecord):
1092         (WebCore::findGreatestKeyLessThanOrEqual):
1093         (WebCore::versionExists):
1094         (WebCore::IDBBackingStore::findKeyInIndex):
1095         (WebCore::IDBBackingStore::getPrimaryKeyViaIndex):
1096         (WebCore::IDBBackingStore::keyExistsInIndex):
1097         (WebCore::IDBBackingStore::Cursor::Cursor):
1098         (WebCore::IDBBackingStore::Cursor::firstSeek):
1099         (WebCore::IDBBackingStore::Cursor::advance):
1100         (WebCore::IDBBackingStore::Cursor::continueFunction):
1101         (WebCore::IDBBackingStore::Cursor::haveEnteredRange):
1102         (WebCore::IDBBackingStore::Cursor::isPastBounds):
1103         (WebCore::ObjectStoreKeyCursorImpl::create):
1104         (WebCore::ObjectStoreKeyCursorImpl::clone):
1105         (WebCore::ObjectStoreKeyCursorImpl::value):
1106         (WebCore::ObjectStoreKeyCursorImpl::encodeKey):
1107         (WebCore::ObjectStoreKeyCursorImpl::ObjectStoreKeyCursorImpl):
1108         (WebCore::ObjectStoreKeyCursorImpl::loadCurrentRow):
1109         (WebCore::ObjectStoreCursorImpl::create):
1110         (WebCore::ObjectStoreCursorImpl::clone):
1111         (WebCore::ObjectStoreCursorImpl::value):
1112         (WebCore::ObjectStoreCursorImpl::encodeKey):
1113         (WebCore::ObjectStoreCursorImpl::ObjectStoreCursorImpl):
1114         (WebCore::ObjectStoreCursorImpl::loadCurrentRow):
1115         (WebCore::IndexKeyCursorImpl::create):
1116         (WebCore::IndexKeyCursorImpl::clone):
1117         (WebCore::IndexKeyCursorImpl::value):
1118         (WebCore::IndexKeyCursorImpl::primaryKey):
1119         (WebCore::IndexKeyCursorImpl::recordIdentifier):
1120         (WebCore::IndexKeyCursorImpl::encodeKey):
1121         (WebCore::IndexKeyCursorImpl::IndexKeyCursorImpl):
1122         (WebCore::IndexKeyCursorImpl::loadCurrentRow):
1123         (WebCore::IndexCursorImpl::create):
1124         (WebCore::IndexCursorImpl::clone):
1125         (WebCore::IndexCursorImpl::value):
1126         (WebCore::IndexCursorImpl::primaryKey):
1127         (WebCore::IndexCursorImpl::recordIdentifier):
1128         (WebCore::IndexCursorImpl::encodeKey):
1129         (WebCore::IndexCursorImpl::IndexCursorImpl):
1130         (WebCore::IndexCursorImpl::loadCurrentRow):
1131         (WebCore::objectStoreCursorOptions):
1132         (WebCore::indexCursorOptions):
1133         (WebCore::IDBBackingStore::openObjectStoreCursor):
1134         (WebCore::IDBBackingStore::openObjectStoreKeyCursor):
1135         (WebCore::IDBBackingStore::openIndexKeyCursor):
1136         (WebCore::IDBBackingStore::openIndexCursor):
1137         (WebCore::IDBBackingStore::Transaction::Transaction):
1138         (WebCore::IDBBackingStore::Transaction::begin):
1139         (WebCore::IDBBackingStore::Transaction::commit):
1140         (WebCore::IDBBackingStore::Transaction::rollback):
1141         * Modules/indexeddb/leveldb/IDBLevelDBCoding.cpp: Renamed from Source/WebCore/Modules/indexeddb/IDBLevelDBCoding.cpp.
1142         (WebCore::IDBLevelDBCoding::encodeByte):
1143         (WebCore::IDBLevelDBCoding::decodeByte):
1144         (WebCore::IDBLevelDBCoding::maxIDBKey):
1145         (WebCore::IDBLevelDBCoding::minIDBKey):
1146         (WebCore::IDBLevelDBCoding::encodeBool):
1147         (WebCore::IDBLevelDBCoding::decodeBool):
1148         (WebCore::IDBLevelDBCoding::encodeInt):
1149         (WebCore::IDBLevelDBCoding::decodeInt):
1150         (WebCore::IDBLevelDBCoding::compareInts):
1151         (WebCore::IDBLevelDBCoding::encodeVarInt):
1152         (WebCore::IDBLevelDBCoding::decodeVarInt):
1153         (WebCore::IDBLevelDBCoding::encodeString):
1154         (WebCore::IDBLevelDBCoding::decodeString):
1155         (WebCore::IDBLevelDBCoding::encodeStringWithLength):
1156         (WebCore::IDBLevelDBCoding::decodeStringWithLength):
1157         (WebCore::IDBLevelDBCoding::compareEncodedStringsWithLength):
1158         (WebCore::IDBLevelDBCoding::encodeDouble):
1159         (WebCore::IDBLevelDBCoding::decodeDouble):
1160         (WebCore::IDBLevelDBCoding::encodeIDBKey):
1161         (WebCore::IDBLevelDBCoding::decodeIDBKey):
1162         (WebCore::IDBLevelDBCoding::extractEncodedIDBKey):
1163         (WebCore::IDBLevelDBCoding::keyTypeByteToKeyType):
1164         (WebCore::IDBLevelDBCoding::compareEncodedIDBKeys):
1165         (WebCore::IDBLevelDBCoding::encodeIDBKeyPath):
1166         (WebCore::IDBLevelDBCoding::decodeIDBKeyPath):
1167         (WebCore::IDBLevelDBCoding::compare):
1168         (WebCore::IDBLevelDBCoding::KeyPrefix::KeyPrefix):
1169         (WebCore::IDBLevelDBCoding::KeyPrefix::createWithSpecialIndex):
1170         (WebCore::IDBLevelDBCoding::KeyPrefix::isValidDatabaseId):
1171         (WebCore::IDBLevelDBCoding::KeyPrefix::isValidObjectStoreId):
1172         (WebCore::IDBLevelDBCoding::KeyPrefix::isValidIndexId):
1173         (WebCore::IDBLevelDBCoding::KeyPrefix::decode):
1174         (WebCore::IDBLevelDBCoding::KeyPrefix::encodeEmpty):
1175         (WebCore::IDBLevelDBCoding::KeyPrefix::encode):
1176         (WebCore::IDBLevelDBCoding::KeyPrefix::encodeInternal):
1177         (WebCore::IDBLevelDBCoding::KeyPrefix::compare):
1178         (WebCore::IDBLevelDBCoding::KeyPrefix::type):
1179         (WebCore::IDBLevelDBCoding::SchemaVersionKey::encode):
1180         (WebCore::IDBLevelDBCoding::MaxDatabaseIdKey::encode):
1181         (WebCore::IDBLevelDBCoding::DataVersionKey::encode):
1182         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::DatabaseFreeListKey):
1183         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::decode):
1184         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::encode):
1185         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::encodeMaxKey):
1186         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::databaseId):
1187         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::compare):
1188         (WebCore::IDBLevelDBCoding::DatabaseNameKey::decode):
1189         (WebCore::IDBLevelDBCoding::DatabaseNameKey::encode):
1190         (WebCore::IDBLevelDBCoding::DatabaseNameKey::encodeMinKeyForOrigin):
1191         (WebCore::IDBLevelDBCoding::DatabaseNameKey::encodeStopKeyForOrigin):
1192         (WebCore::IDBLevelDBCoding::DatabaseNameKey::compare):
1193         (WebCore::IDBLevelDBCoding::DatabaseMetaDataKey::encode):
1194         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::ObjectStoreMetaDataKey):
1195         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::decode):
1196         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::encode):
1197         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::encodeMaxKey):
1198         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::objectStoreId):
1199         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::metaDataType):
1200         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::compare):
1201         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::IndexMetaDataKey):
1202         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::decode):
1203         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::encode):
1204         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::encodeMaxKey):
1205         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::compare):
1206         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::indexId):
1207         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::ObjectStoreFreeListKey):
1208         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::decode):
1209         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::encode):
1210         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::encodeMaxKey):
1211         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::objectStoreId):
1212         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::compare):
1213         (WebCore::IDBLevelDBCoding::IndexFreeListKey::IndexFreeListKey):
1214         (WebCore::IDBLevelDBCoding::IndexFreeListKey::decode):
1215         (WebCore::IDBLevelDBCoding::IndexFreeListKey::encode):
1216         (WebCore::IDBLevelDBCoding::IndexFreeListKey::encodeMaxKey):
1217         (WebCore::IDBLevelDBCoding::IndexFreeListKey::compare):
1218         (WebCore::IDBLevelDBCoding::IndexFreeListKey::objectStoreId):
1219         (WebCore::IDBLevelDBCoding::IndexFreeListKey::indexId):
1220         (WebCore::IDBLevelDBCoding::ObjectStoreNamesKey::decode):
1221         (WebCore::IDBLevelDBCoding::ObjectStoreNamesKey::encode):
1222         (WebCore::IDBLevelDBCoding::ObjectStoreNamesKey::compare):
1223         (WebCore::IDBLevelDBCoding::IndexNamesKey::IndexNamesKey):
1224         (WebCore::IDBLevelDBCoding::IndexNamesKey::decode):
1225         (WebCore::IDBLevelDBCoding::IndexNamesKey::encode):
1226         (WebCore::IDBLevelDBCoding::IndexNamesKey::compare):
1227         (WebCore::IDBLevelDBCoding::ObjectStoreDataKey::decode):
1228         (WebCore::IDBLevelDBCoding::ObjectStoreDataKey::encode):
1229         (WebCore::IDBLevelDBCoding::ObjectStoreDataKey::compare):
1230         (WebCore::IDBLevelDBCoding::ObjectStoreDataKey::userKey):
1231         (WebCore::IDBLevelDBCoding::ExistsEntryKey::decode):
1232         (WebCore::IDBLevelDBCoding::ExistsEntryKey::encode):
1233         (WebCore::IDBLevelDBCoding::ExistsEntryKey::compare):
1234         (WebCore::IDBLevelDBCoding::ExistsEntryKey::userKey):
1235         (WebCore::IDBLevelDBCoding::IndexDataKey::IndexDataKey):
1236         (WebCore::IDBLevelDBCoding::IndexDataKey::decode):
1237         (WebCore::IDBLevelDBCoding::IndexDataKey::encode):
1238         (WebCore::IDBLevelDBCoding::IndexDataKey::encodeMinKey):
1239         (WebCore::IDBLevelDBCoding::IndexDataKey::encodeMaxKey):
1240         (WebCore::IDBLevelDBCoding::IndexDataKey::compare):
1241         (WebCore::IDBLevelDBCoding::IndexDataKey::databaseId):
1242         (WebCore::IDBLevelDBCoding::IndexDataKey::objectStoreId):
1243         (WebCore::IDBLevelDBCoding::IndexDataKey::indexId):
1244         (WebCore::IDBLevelDBCoding::IndexDataKey::userKey):
1245         (WebCore::IDBLevelDBCoding::IndexDataKey::primaryKey):
1246         * Modules/indexeddb/leveldb/IDBLevelDBCoding.h: Renamed from Source/WebCore/Modules/indexeddb/IDBLevelDBCoding.h.
1247         (WebCore::IDBLevelDBCoding::encodeIntSafely):
1248         (WebCore::IDBLevelDBCoding::KeyPrefix::validIds):
1249         (WebCore::IDBLevelDBCoding::DatabaseNameKey::origin):
1250         (WebCore::IDBLevelDBCoding::DatabaseNameKey::databaseName):
1251         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::metaDataType):
1252         (WebCore::IDBLevelDBCoding::ObjectStoreNamesKey::objectStoreName):
1253         (WebCore::IDBLevelDBCoding::IndexNamesKey::indexName):
1254
1255 2013-09-23  Antti Koivisto  <antti@apple.com>
1256
1257         Try to fix GTK build.
1258         
1259         Not reviewed.
1260
1261         * accessibility/atk/AccessibilityObjectAtk.cpp:
1262         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
1263         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
1264         (textForRenderer):
1265
1266 2013-09-23  Alexandru Chiculita  <achicu@adobe.com>
1267
1268         Web Inspector: [CSS Regions] Display CSS Regions flow name in the inspector overlay
1269         https://bugs.webkit.org/show_bug.cgi?id=121794
1270
1271         Reviewed by Joseph Pecoraro.
1272
1273         No new tests, the previous test for CSS Regions highlighting covers the flow name.
1274
1275         This patch adds the "Flow" property in the inspector overlay. The region
1276         chain is already displayed with numbers, so it makes sense to have the flow 
1277         name around when a CSS region is highlighted.
1278
1279         I've consolidated the flow information into "elementInfo.flowInfo". 
1280         Flow info has two properties: "name" and "regions".
1281
1282         * inspector/InspectorOverlay.cpp:
1283         (WebCore::buildObjectForCSSRegionsHighlight):
1284         (WebCore::InspectorOverlay::buildObjectForHighlightedNode):
1285         * inspector/InspectorOverlayPage.css:
1286         (.css-property): Added the CSS property font color that the Inspector uses.
1287         * inspector/InspectorOverlayPage.html: Added a new element to be used to display the flow-from property.
1288         * inspector/InspectorOverlayPage.js:
1289         (_drawElementTitle):
1290         (drawNodeHighlight):
1291
1292 2013-09-23  Simon Fraser  <simon.fraser@apple.com>
1293
1294         Rapidly loading pages can result in !needsLayout() assertions in FrameView::paintContents() and RenderView::paint()
1295         https://bugs.webkit.org/show_bug.cgi?id=121725
1296         <rdar://problem/13982161> ASSERT(!needsLayout()) in WebCore::RenderView::paint (121196)
1297
1298         Reviewed by Dean Jackson.
1299         
1300         Layout has to be up-to-date before we paint, and when composited we rely on a
1301         CFRunLoopObserver owned by LayerFlushScheduler to enforce this. The contract is
1302         that changes to GraphicsLayers accumulate in those layers, and are all pushed to
1303         CALayers only inside of flushCompositingState(). CALayers must not be touched
1304         directly outside of flushCompositingState(), since this may trigger a CA commit
1305         and resultant painting without us having updated layout.
1306         
1307         In addition, we rely on the CA commits only happening after our runloop observer
1308         has fired in order for LayerFlushScheduler's suspend/resume to work (these are used
1309         for freezing the layer tree during page transitions).
1310         
1311         However, TileController was violating this contract. It called revalidateTiles()
1312         at random times, and on a timer. This would result in CA commits happening when
1313         layer flushing was suspended at the LayerFlushScheduler level, and thus before
1314         we'd had a chance to do layout.
1315         
1316         Fix by only ever revalidatingTiles inside of flushCompositingState(). Calls
1317         that used to result in revalidateTiles() at other times now just set a bit
1318         on GraphicsLayerCA to indicate that revalidation is required, and this triggers
1319         a later flush like any other GraphicsLayerCA change.
1320         
1321         There is one exception to the revalidate-inside-flush rule: when purging
1322         files for background tabs on a timer, we are only dealing with an unparented
1323         layer tree, so CALayer manipulation is safe at any time.
1324
1325         Very timing dependent, so hard to test.
1326
1327         * platform/graphics/TiledBacking.h: Expose revalidateTiles()
1328         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp: Remove
1329         platformCALayerDidCreateTiles() override.
1330         * platform/graphics/ca/GraphicsLayerCA.h: Keep track of m_isCommittingChanges
1331         so we can assert. Add TilingAreaChanged flag.
1332         * platform/graphics/ca/GraphicsLayerCA.cpp:
1333         (WebCore::GraphicsLayerCA::GraphicsLayerCA):
1334         (WebCore::GraphicsLayerCA::recursiveCommitChanges): noteSublayersChanged() is
1335         used inside of a commit in some cases to trigger a parent layer to update
1336         children after the children have been processed. To avoid trying to pointlessly
1337         schedule the flusher inside a flush, and for strong assertions, use a new flag
1338         that indicates that flushing is not required in this situation.
1339         Set the m_isCommittingChanges flag around committing state.
1340         (WebCore::GraphicsLayerCA::platformCALayerSetNeedsToRevalidateTiles): We used
1341         to use platformCALayerDidCreateTiles() to ensure that we would flush after adding
1342         new tiles to avoid garbage flashes. Now that we only ever create tiles inside
1343         a flush, this is no longer necessary.
1344         The new platformCALayerSetNeedsToRevalidateTiles() function just sets the
1345         TilingAreaChanged flag and triggers a flush.
1346         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): After updating
1347         visible rect, we look for the TilingAreaChanged flag to tell us whether to
1348         revalidate TiledBacking tiles.
1349         (WebCore::GraphicsLayerCA::ensureStructuralLayer): Use DontScheduleFlush when 
1350         telling a parent layer that it needs to reconsider sublayers.
1351         (WebCore::GraphicsLayerCA::updateTiles): The caller of revalidateTiles().
1352         (WebCore::GraphicsLayerCA::updateContentsRects): DontScheduleFlush again.
1353         (WebCore::GraphicsLayerCA::noteSublayersChanged): Pass scheduleFlush along.
1354         (WebCore::GraphicsLayerCA::noteLayerPropertyChanged): Handle scheduleFlush.
1355         * platform/graphics/ca/PlatformCALayerClient.h:
1356         (WebCore::PlatformCALayerClient::platformCALayerSetNeedsToRevalidateTiles): Added
1357         so that TileController can call back out to GraphicsLayerCA.
1358         (WebCore::PlatformCALayerClient::isCommittingChanges):
1359         * platform/graphics/ca/mac/TileController.h: Need to keep track of secondary
1360         coverage rects in m_secondaryTileCoverageRects.
1361         * platform/graphics/ca/mac/TileController.mm:
1362         (WebCore::TileController::tileCacheLayerBoundsChanged): Just trigger a tile revalidate,
1363         which will happen later in this same commit.
1364         (WebCore::TileController::setScale): This is called inside the commit. Does an extra
1365         revalidate, which is needed to prune tiles. This could be optimized in future.
1366         (WebCore::TileController::setVisibleRect): Assert that we're inside a commit,
1367         and trigger a revalidate.
1368         (WebCore::TileController::setExposedRect): Trigger a revalidate.
1369         (WebCore::TileController::setClipsToExposedRect): Ditto.
1370         (WebCore::TileController::prepopulateRect): Save the rect and trigger a revalidate.
1371         (WebCore::TileController::setIsInWindow): If we're in the window, trigger a revalidate
1372         otherwise schedule the timer.
1373         (WebCore::TileController::revalidateTiles): Wrapper for the real revalidateTiles().
1374         (WebCore::TileController::tileRevalidationTimerFired): If we're in the window,
1375         schedule a revalidate. Otherwise our layer tree is disconnected, and it's OK to call revalidateTiles().
1376         (WebCore::TileController::setNeedsRevalidateTiles): Call through the client to GraphicsLayerCA
1377         which will schedule a layer tree flush.
1378         (WebCore::TileController::revalidateTiles):
1379         (WebCore::TileController::ensureTilesForRect): Move code from prepopulateRect
1380         into here; ensureTilesForRect() for each secondary rect, then clear the rects.
1381         No need to call platformCALayerDidCreateTiles() at the end.
1382         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp: Remove
1383         platformCALayerDidCreateTiles() override.
1384         * rendering/RenderLayerCompositor.cpp:
1385         (WebCore::RenderLayerCompositor::scheduleLayerFlush): This should only be
1386         called when we're not inside a flush, otherwise it will fail to schedule
1387         another one.
1388
1389 2013-09-23  Sam Weinig  <sam@webkit.org>
1390
1391         CTTE: htmlediting.h Element creation function should take a Document&
1392         https://bugs.webkit.org/show_bug.cgi?id=121800
1393
1394         Reviewed by Antti Koivisto.
1395
1396         Thread the Document&!
1397
1398 2013-09-23  Jacky Jiang  <zhajiang@blackberry.com>
1399
1400         [BlackBerry] Poor rendering opening a Google map short link
1401         https://bugs.webkit.org/show_bug.cgi?id=121687
1402
1403         Reviewed by Yong Li.
1404         Internally reviewed by Liam Quinn and Joe Mason.
1405
1406         Fix a regression. It turns out that LayerCompositingThread already has
1407         an API named isVisible() which by default returns false. So rename the
1408         one in the LayerData to isLayerVisible().
1409
1410         * platform/graphics/blackberry/LayerData.h:
1411         (WebCore::LayerData::isLayerVisible):
1412         * platform/graphics/blackberry/LayerRenderer.cpp:
1413         (WebCore::LayerRenderer::compositeLayersRecursive):
1414
1415 2013-09-23  Antti Koivisto  <antti@apple.com>
1416
1417         Rename RenderObject::first/lastChild to RenderObject::first/lastChildSlow
1418         https://bugs.webkit.org/show_bug.cgi?id=121784
1419
1420         Reviewed by Andreas Kling.
1421
1422         This will make it obvious in code where typing should be tightened.
1423         Handled some simple cases by tightening the code instead of renaming.
1424
1425 2013-09-23  ChangSeok Oh  <changseok.oh@collabora.com>
1426
1427         [Texmap] Reloading a webgl page doesn't work
1428         https://bugs.webkit.org/show_bug.cgi?id=120593
1429
1430         Reviewed by Noam Rosenthal.
1431
1432         Let GraphicsLayerTextureMapper know it needs to detach the platform layer when a GraphicsContext3D is destroyed.
1433
1434         Test: fast/canvas/webgl/webgl-reload-crash.html
1435
1436         * platform/graphics/GraphicsContext3DPrivate.cpp:
1437         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
1438         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
1439         * platform/graphics/texmap/TextureMapperPlatformLayer.h:
1440
1441 2013-09-23  Antti Koivisto  <antti@apple.com>
1442
1443         Remove RenderObjectChildList
1444         https://bugs.webkit.org/show_bug.cgi?id=121771
1445
1446         Reviewed by Darin Adler.
1447
1448         Most RenderElement subclasses have m_children member (>90% of instances on typical page). It is not worth optimising
1449         for memory for the few cases that don't (RenderImage, RenderLineBreak mostly) in expense of performance.
1450         
1451         This patch moves child handling to RenderElement. This gets rid of virtual children() calls and simplifies the code.
1452
1453 2013-09-23  Andreas Kling  <akling@apple.com>
1454
1455         Document::destroyRenderTree() shouldn't do anything but.
1456         <https://webkit.org/b/121786>
1457
1458         Reviewed by Anders Carlsson.
1459
1460         Move everything in destroyRenderTree() that doesn't actually destroy
1461         render trees to prepareForDestruction() instead.
1462
1463         Destroying the render tree is now a reparable operation.
1464
1465 2013-09-23  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1466
1467         [Qt] Tiled backing-store causes wrong translation
1468         https://bugs.webkit.org/show_bug.cgi?id=121789
1469
1470         Reviewed by Noam Rosenthal.
1471
1472         Move the translation inside save/restore of the GraphicsContext.
1473
1474         * platform/graphics/qt/TileQt.cpp:
1475         (WebCore::TileQt::updateBackBuffer):
1476
1477 2013-09-23  Andreas Kling  <akling@apple.com>
1478
1479         Unify code paths leading to render tree teardown.
1480         <https://webkit.org/b/121785>
1481
1482         Reviewed by Antti Koivisto.
1483
1484         Make Document::prepareForDestruction() fit all the call sites that were
1485         doing destroyRenderTree() + disconnectFromFrame().
1486
1487         - disconnectDescendantFrames() is already a no-op if there are no frames.
1488         - willDetachDocumentFromFrame() will only run if there is a frame.
1489
1490         This is another step towards making tree rebuild possible.
1491
1492         Removed some age-old FIXMEs about why we aren't calling willRemove(),
1493         a long-gone function.
1494
1495 2013-09-23  Patrick Gansterer  <paroga@webkit.org>
1496
1497         Cleanup CMake files in WebCore
1498         https://bugs.webkit.org/show_bug.cgi?id=119262
1499
1500         Reviewed by Gyuyoung Kim.
1501
1502         Sort files and unify style.
1503
1504         * CMakeLists.txt:
1505         * PlatformBlackBerry.cmake:
1506         * PlatformEfl.cmake:
1507         * PlatformGTK.cmake:
1508         * PlatformWin.cmake:
1509         * PlatformWinCE.cmake:
1510
1511 2013-09-22  Commit Queue  <commit-queue@webkit.org>
1512
1513         Unreviewed, rolling out r156254.
1514         http://trac.webkit.org/changeset/156254
1515         https://bugs.webkit.org/show_bug.cgi?id=121779
1516
1517         Caused assertions in fast/regions tests (Requested by ap on
1518         #webkit).
1519
1520         * CMakeLists.txt:
1521         * GNUmakefile.list.am:
1522         * Target.pri:
1523         * WebCore.vcxproj/WebCore.vcxproj:
1524         * WebCore.xcodeproj/project.pbxproj:
1525         * rendering/AutoTableLayout.cpp:
1526         (WebCore::AutoTableLayout::recalcColumn):
1527         * rendering/RenderBlock.cpp:
1528         (WebCore::RenderBlock::willBeDestroyed):
1529         (WebCore::RenderBlock::addChildToAnonymousColumnBlocks):
1530         (WebCore::RenderBlock::splitBlocks):
1531         (WebCore::RenderBlock::splitFlow):
1532         (WebCore::RenderBlock::makeChildrenAnonymousColumnBlocks):
1533         (WebCore::RenderBlock::makeChildrenNonInline):
1534         (WebCore::RenderBlock::removeLeftoverAnonymousBlock):
1535         (WebCore::RenderBlock::collapseAnonymousBoxChild):
1536         (WebCore::RenderBlock::removeChild):
1537         (WebCore::RenderBlock::updateFirstLetterStyle):
1538         * rendering/RenderBlock.h:
1539         (WebCore::RenderBlock::firstChild):
1540         (WebCore::RenderBlock::lastChild):
1541         * rendering/RenderBox.cpp:
1542         (WebCore::RenderBox::splitAnonymousBoxesAroundChild):
1543         * rendering/RenderBoxModelObject.cpp:
1544         (WebCore::RenderBoxModelObject::moveChildTo):
1545         * rendering/RenderElement.cpp:
1546         (WebCore::RenderElement::RenderElement):
1547         (WebCore::RenderElement::addChild):
1548         (WebCore::RenderElement::removeChild):
1549         * rendering/RenderElement.h:
1550         * rendering/RenderEmbeddedObject.cpp:
1551         (WebCore::RenderEmbeddedObject::layout):
1552         * rendering/RenderEmbeddedObject.h:
1553         * rendering/RenderFrameSet.h:
1554         * rendering/RenderInline.cpp:
1555         (WebCore::RenderInline::willBeDestroyed):
1556         (WebCore::RenderInline::splitInlines):
1557         (WebCore::RenderInline::splitFlow):
1558         (WebCore::RenderInline::childBecameNonInline):
1559         * rendering/RenderInline.h:
1560         (WebCore::RenderInline::firstChild):
1561         (WebCore::RenderInline::lastChild):
1562         * rendering/RenderLayerModelObject.cpp:
1563         (WebCore::RenderLayerModelObject::willBeDestroyed):
1564         * rendering/RenderLineBreak.h:
1565         * rendering/RenderListMarker.h:
1566         * rendering/RenderMedia.cpp:
1567         (WebCore::RenderMedia::layout):
1568         * rendering/RenderMedia.h:
1569         (WebCore::RenderMedia::firstChild):
1570         (WebCore::RenderMedia::lastChild):
1571         * rendering/RenderObject.cpp:
1572         (WebCore::RenderObject::handleDynamicFloatPositionChange):
1573         (WebCore::RenderObject::willBeDestroyed):
1574         (WebCore::RenderObject::removeFromRenderFlowThreadRecursive):
1575         * rendering/RenderObject.h:
1576         (WebCore::RenderObject::firstChild):
1577         (WebCore::RenderObject::lastChild):
1578         (WebCore::RenderObject::children):
1579         (WebCore::RenderObject::canHaveChildren):
1580         * rendering/RenderObjectChildList.cpp: Added.
1581         (WebCore::RenderObjectChildList::destroyLeftoverChildren):
1582         (WebCore::RenderObjectChildList::removeChildNode):
1583         (WebCore::RenderObjectChildList::insertChildNode):
1584         * rendering/RenderObjectChildList.h: Copied from Source/WebCore/rendering/RenderMedia.h.
1585         (WebCore::RenderObjectChildList::RenderObjectChildList):
1586         (WebCore::RenderObjectChildList::firstChild):
1587         (WebCore::RenderObjectChildList::lastChild):
1588         (WebCore::RenderObjectChildList::setFirstChild):
1589         (WebCore::RenderObjectChildList::setLastChild):
1590         (WebCore::RenderObjectChildList::appendChildNode):
1591         * rendering/RenderReplaced.h:
1592         (WebCore::RenderReplaced::canHaveChildren):
1593         * rendering/RenderReplica.h:
1594         * rendering/RenderRubyBase.cpp:
1595         (WebCore::RenderRubyBase::moveInlineChildren):
1596         (WebCore::RenderRubyBase::moveBlockChildren):
1597         * rendering/RenderTableCol.h:
1598         * rendering/RenderTableRow.h:
1599         * rendering/RenderTableSection.h:
1600         * rendering/RenderText.h:
1601         * rendering/RenderingAllInOne.cpp:
1602         * rendering/mathml/RenderMathMLOperator.cpp:
1603         (WebCore::RenderMathMLOperator::updateFromElement):
1604         * rendering/svg/RenderSVGContainer.h:
1605         (WebCore::RenderSVGContainer::firstChild):
1606         (WebCore::RenderSVGContainer::lastChild):
1607         * rendering/svg/RenderSVGGradientStop.h:
1608         * rendering/svg/RenderSVGImage.h:
1609         * rendering/svg/RenderSVGModelObject.cpp:
1610         (WebCore::RenderSVGModelObject::willBeDestroyed):
1611         * rendering/svg/RenderSVGRoot.h:
1612         * rendering/svg/RenderSVGShape.h:
1613
1614 2013-09-22  Commit Queue  <commit-queue@webkit.org>
1615
1616         Unreviewed, rolling out r156253.
1617         http://trac.webkit.org/changeset/156253
1618         https://bugs.webkit.org/show_bug.cgi?id=121778
1619
1620         Caused >20 tests to crash with assertion failures (Requested
1621         by ap on #webkit).
1622
1623         * css/CSSAspectRatioValue.h:
1624         * css/CSSBorderImageSliceValue.h:
1625         * css/CSSCalculationValue.cpp:
1626         (WebCore::CSSCalcExpressionNodeParser::parseValue):
1627         * css/CSSCalculationValue.h:
1628         * css/CSSCrossfadeValue.cpp:
1629         (WebCore::subimageKnownToBeOpaque):
1630         * css/CSSCrossfadeValue.h:
1631         (WebCore::toCSSCrossfadeValue):
1632         * css/CSSCursorImageValue.cpp:
1633         (WebCore::CSSCursorImageValue::~CSSCursorImageValue):
1634         (WebCore::CSSCursorImageValue::updateIfSVGCursorIsUsed):
1635         (WebCore::CSSCursorImageValue::cachedImage):
1636         (WebCore::CSSCursorImageValue::cachedOrPendingImage):
1637         (WebCore::CSSCursorImageValue::isSVGCursor):
1638         * css/CSSCursorImageValue.h:
1639         * css/CSSFilterImageValue.h:
1640         (WebCore::toCSSFilterImageValue):
1641         * css/CSSFontSelector.cpp:
1642         (WebCore::CSSFontSelector::addFontFaceRule):
1643         * css/CSSGradientValue.h:
1644         * css/CSSImageGeneratorValue.cpp:
1645         (WebCore::CSSImageGeneratorValue::image):
1646         (WebCore::CSSImageGeneratorValue::fixedSize):
1647         (WebCore::CSSImageGeneratorValue::loadSubimages):
1648         (WebCore::CSSImageGeneratorValue::subimageIsPending):
1649         (WebCore::CSSImageGeneratorValue::cachedImageForCSSValue):
1650         * css/CSSImageGeneratorValue.h:
1651         * css/CSSImageSetValue.cpp:
1652         (WebCore::CSSImageSetValue::fillImageSet):
1653         * css/CSSImageSetValue.h:
1654         * css/CSSImageValue.h:
1655         * css/CSSInheritedValue.h:
1656         * css/CSSInitialValue.h:
1657         * css/CSSLineBoxContainValue.h:
1658         * css/CSSParser.cpp:
1659         (WebCore::CSSParser::parseColor):
1660         (WebCore::CSSParser::addProperty):
1661         (WebCore::CSSParser::parse3ValuesFillPosition):
1662         (WebCore::CSSParser::parseFillPosition):
1663         (WebCore::CSSParser::parseFillRepeat):
1664         (WebCore::CSSParser::parseDeprecatedRadialGradient):
1665         (WebCore::CSSParser::parseRadialGradient):
1666         * css/CSSPrimitiveValue.h:
1667         * css/CSSReflectValue.h:
1668         * css/CSSToStyleMap.cpp:
1669         (WebCore::CSSToStyleMap::mapFillAttachment):
1670         (WebCore::CSSToStyleMap::mapFillClip):
1671         (WebCore::CSSToStyleMap::mapFillComposite):
1672         (WebCore::CSSToStyleMap::mapFillBlendMode):
1673         (WebCore::CSSToStyleMap::mapFillOrigin):
1674         (WebCore::CSSToStyleMap::mapFillRepeatX):
1675         (WebCore::CSSToStyleMap::mapFillRepeatY):
1676         (WebCore::CSSToStyleMap::mapFillSize):
1677         (WebCore::CSSToStyleMap::mapFillXPosition):
1678         (WebCore::CSSToStyleMap::mapFillYPosition):
1679         (WebCore::CSSToStyleMap::mapFillMaskSourceType):
1680         (WebCore::CSSToStyleMap::mapAnimationDelay):
1681         (WebCore::CSSToStyleMap::mapAnimationDirection):
1682         (WebCore::CSSToStyleMap::mapAnimationDuration):
1683         (WebCore::CSSToStyleMap::mapAnimationFillMode):
1684         (WebCore::CSSToStyleMap::mapAnimationIterationCount):
1685         (WebCore::CSSToStyleMap::mapAnimationName):
1686         (WebCore::CSSToStyleMap::mapAnimationPlayState):
1687         (WebCore::CSSToStyleMap::mapAnimationProperty):
1688         (WebCore::CSSToStyleMap::mapAnimationTimingFunction):
1689         (WebCore::CSSToStyleMap::mapNinePieceImageSlice):
1690         (WebCore::CSSToStyleMap::mapNinePieceImageQuad):
1691         (WebCore::CSSToStyleMap::mapNinePieceImageRepeat):
1692         * css/CSSValue.cpp:
1693         (WebCore::CSSValue::destroy):
1694         * css/CSSValue.h:
1695         (WebCore::CSSValue::isCSSLineBoxContainValue):
1696         (WebCore::CSSValue::isCalculationValue):
1697         * css/CSSValueList.h:
1698         * css/CSSVariableValue.h:
1699         * css/DeprecatedStyleBuilder.cpp:
1700         (WebCore::ApplyPropertyDefault::applyValue):
1701         (WebCore::ApplyPropertyNumber::applyValue):
1702         (WebCore::ApplyPropertyAuto::applyValue):
1703         (WebCore::ApplyPropertyClip::applyValue):
1704         (WebCore::ApplyPropertyColor::applyValue):
1705         (WebCore::ApplyPropertyLength::applyValue):
1706         (WebCore::ApplyPropertyString::applyValue):
1707         (WebCore::ApplyPropertyBorderRadius::applyValue):
1708         (WebCore::ApplyPropertyComputeLength::applyValue):
1709         (WebCore::ApplyPropertyFont::applyValue):
1710         (WebCore::ApplyPropertyFontFamily::applyValue):
1711         (WebCore::ApplyPropertyFontSize::applyValue):
1712         (WebCore::ApplyPropertyFontWeight::applyValue):
1713         (WebCore::ApplyPropertyFontVariantLigatures::applyValue):
1714         (WebCore::ApplyPropertyCounter::applyValue):
1715         (WebCore::ApplyPropertyCursor::applyValue):
1716         (WebCore::ApplyPropertyTextAlign::applyValue):
1717         (WebCore::ApplyPropertyTextDecoration::applyValue):
1718         (WebCore::ApplyPropertyMarqueeIncrement::applyValue):
1719         (WebCore::ApplyPropertyMarqueeRepetition::applyValue):
1720         (WebCore::ApplyPropertyMarqueeSpeed::applyValue):
1721         (WebCore::ApplyPropertyTextUnderlinePosition::applyValue):
1722         (WebCore::ApplyPropertyLineHeight::applyValue):
1723         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyValue):
1724         (WebCore::ApplyPropertyPageSize::applyValue):
1725         (WebCore::ApplyPropertyTextEmphasisStyle::applyValue):
1726         (WebCore::ApplyPropertyResize::applyValue):
1727         (WebCore::ApplyPropertyVerticalAlign::applyValue):
1728         (WebCore::ApplyPropertyAspectRatio::applyValue):
1729         (WebCore::ApplyPropertyZoom::applyValue):
1730         (WebCore::ApplyPropertyDisplay::applyValue):
1731         (WebCore::ApplyPropertyClipPath::applyValue):
1732         (WebCore::ApplyPropertyShape::applyValue):
1733         (WebCore::ApplyPropertyImageResolution::applyValue):
1734         (WebCore::ApplyPropertyTextIndent::applyValue):
1735         * css/FontFeatureValue.h:
1736         * css/FontValue.h:
1737         * css/MediaList.cpp:
1738         (WebCore::reportMediaQueryWarningIfNeeded):
1739         * css/MediaQueryEvaluator.cpp:
1740         (WebCore::compareAspectRatioValue):
1741         (WebCore::numberValue):
1742         (WebCore::orientationMediaFeatureEval):
1743         (WebCore::evalResolution):
1744         (WebCore::device_pixel_ratioMediaFeatureEval):
1745         (WebCore::resolutionMediaFeatureEval):
1746         (WebCore::computeLength):
1747         (WebCore::view_modeMediaFeatureEval):
1748         (WebCore::pointerMediaFeatureEval):
1749         * css/SVGCSSStyleSelector.cpp:
1750         (WebCore::StyleResolver::applySVGProperty):
1751         * css/ShadowValue.h:
1752         * css/StylePropertySet.cpp:
1753         (WebCore::StylePropertySet::getLayeredShorthandValue):
1754         * css/StyleResolver.cpp:
1755         (WebCore::createGridTrackSize):
1756         (WebCore::createGridTrackList):
1757         (WebCore::createGridPosition):
1758         (WebCore::hasVariableReference):
1759         (WebCore::StyleResolver::applyProperty):
1760         (WebCore::StyleResolver::styleImage):
1761         (WebCore::StyleResolver::generatedOrPendingFromValue):
1762         (WebCore::StyleResolver::styleShader):
1763         (WebCore::StyleResolver::parseCustomFilterArrayParameter):
1764         (WebCore::StyleResolver::parseCustomFilterColorParameter):
1765         (WebCore::StyleResolver::parseCustomFilterNumberParameter):
1766         (WebCore::StyleResolver::parseCustomFilterParameter):
1767         (WebCore::StyleResolver::parseCustomFilterParameterList):
1768         (WebCore::StyleResolver::createCustomFilterOperationWithInlineSyntax):
1769         (WebCore::StyleResolver::createFilterOperations):
1770         * css/TransformFunctions.cpp:
1771         (WebCore::transformsForValue):
1772         * css/ViewportStyleResolver.cpp:
1773         (WebCore::ViewportStyleResolver::getViewportArgumentValue):
1774         * css/WebKitCSSMatrix.cpp:
1775         (WebCore::WebKitCSSMatrix::setMatrixValue):
1776         * editing/ApplyStyleCommand.cpp:
1777         (WebCore::ApplyStyleCommand::computedFontSize):
1778         * editing/EditingStyle.cpp:
1779         (WebCore::identifierForStyleProperty):
1780         (WebCore::HTMLElementEquivalent::valueIsPresentInStyle):
1781         (WebCore::cssValueToRGBA):
1782         (WebCore::EditingStyle::extractFontSizeDelta):
1783         (WebCore::EditingStyle::textDirection):
1784         (WebCore::EditingStyle::prepareToApplyAt):
1785         (WebCore::EditingStyle::mergeStyleFromRulesForSerialization):
1786         (WebCore::EditingStyle::legacyFontSize):
1787         (WebCore::EditingStyle::textDirectionForSelection):
1788         (WebCore::StyleChange::extractTextStyles):
1789         (WebCore::fontWeightIsBold):
1790         (WebCore::isTransparentColorValue):
1791         * editing/markup.cpp:
1792         (WebCore::propertyMissingOrEqualToNone):
1793         * page/PageSerializer.cpp:
1794         (WebCore::PageSerializer::retrieveResourcesForProperties):
1795         * rendering/style/StylePendingImage.h:
1796         (WebCore::StylePendingImage::data):
1797         (WebCore::StylePendingImage::cssImageValue):
1798         (WebCore::StylePendingImage::cssImageGeneratorValue):
1799         (WebCore::StylePendingImage::cssCursorImageValue):
1800         (WebCore::StylePendingImage::cssImageSetValue):
1801
1802 2013-09-22  Commit Queue  <commit-queue@webkit.org>
1803
1804         Unreviewed, rolling out r156257.
1805         http://trac.webkit.org/changeset/156257
1806         https://bugs.webkit.org/show_bug.cgi?id=121777
1807
1808         The test from this patch fails (Requested by ap on #webkit).
1809
1810         * rendering/RenderBox.cpp:
1811         (WebCore::RenderBox::calculateAutoscrollDirection):
1812
1813 2013-09-22  Antonio Gomes  <a1.gomes@sisa.samsung.com>
1814
1815         iframe and scrollbar with "overflow:auto" should support autoscroll with mousedrag
1816         https://bugs.webkit.org/show_bug.cgi?id=40981
1817
1818         Reviewed by Darin Adler.
1819
1820         RenderBox::calculateAutoscrollDirection does not properly translate
1821         inner frames' coordinates in order to determine its auto-scrollability.
1822         By coincidence, if the inner frame box it placed near to page's 0, 0 position
1823         (upper left corner), it might work.
1824
1825         Patch fixes it by changing ::calculateAutoscrollDirection algorithm to operate
1826         with window coordinates, taking inner frames offset and scroll position into account.
1827         The behavior of auto-scrollable non-frame overflow boxes, including divs, still works
1828         as it is used to.
1829
1830         Test: fast/events/drag-and-drop-autoscroll-inner-frame.html
1831
1832         * rendering/RenderBox.cpp:
1833         (WebCore::RenderBox::calculateAutoscrollDirection):
1834
1835 2013-09-22  Sam Weinig  <sam@webkit.org>
1836
1837         CTTE: Use references more in ContainerNode, ContainerNodeAlgorithms and related classes
1838         https://bugs.webkit.org/show_bug.cgi?id=121772
1839
1840         Reviewed by Andreas Kling.
1841
1842         Use references for never null Nodes in ContainerNode and related classes.
1843
1844 2013-09-22  Antti Koivisto  <antti@apple.com>
1845
1846         Fix functions calling to RenderObject superclass to call RenderElement instead
1847         https://bugs.webkit.org/show_bug.cgi?id=121773
1848
1849         Reviewed by Andreas Kling.
1850
1851         The class hierarchy has a new class. Superclass calls should be pointed there instead to
1852         avoid future bugs.
1853
1854         * rendering/RenderBoxModelObject.cpp:
1855         (WebCore::RenderBoxModelObject::setSelectionState):
1856         * rendering/RenderLayerModelObject.cpp:
1857         (WebCore::RenderLayerModelObject::styleWillChange):
1858         (WebCore::RenderLayerModelObject::styleDidChange):
1859         * rendering/svg/RenderSVGGradientStop.cpp:
1860         (WebCore::RenderSVGGradientStop::styleDidChange):
1861         * rendering/svg/RenderSVGModelObject.cpp:
1862         (WebCore::RenderSVGModelObject::styleWillChange):
1863         (WebCore::RenderSVGModelObject::styleDidChange):
1864
1865 2013-09-22  Antti Koivisto  <antti@apple.com>
1866
1867         Remove RenderObjectChildList
1868         https://bugs.webkit.org/show_bug.cgi?id=121771
1869
1870         Reviewed by Darin Adler.
1871
1872         Most RenderElement subclasses have m_children member (>90% of instances on typical page). It is not worth optimising
1873         for memory for the few cases that don't (RenderImage, RenderLineBreak mostly) in expense of performance.
1874         
1875         This patch moves child handling to RenderElement. This gets rid of virtual children() calls and simplifies the code.
1876
1877 2013-09-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1878
1879         Introduce CSS_VALUE_TYPE_CASTS macro in order to cast CSSValue type
1880         https://bugs.webkit.org/show_bug.cgi?id=121462
1881
1882         Reviewed by Andreas Kling.
1883
1884         As r155429 introduced ELEMENT_TYPE_CASTS, CSS_VALUE_TYPE_CASTS can be used
1885         by css value type casting as well. This type cast macros will help to detect
1886         bad-cast bugs as well as improve a code readibility.
1887
1888         This patch adds the following methods,
1889
1890         - CSSFooValue* toCSSFooValue(CSSValue*)
1891         - const CSSFooValue* toCSSFooValue(const CSSValue*)
1892
1893         To be consistent with other is*Value() naming style, isCSSLineBoxContainValue() and isCalculationValue()
1894         are changed with isLineBoxContainValue() and isCalcValue().
1895
1896         FontValue, FontFeatureValue, ShadowValue have a manual type case function because of different
1897         class naming style. So, toFontValue(), toFontFeatureValue() and toShadowValue() are added manually.
1898
1899         This patch removes unnecessary local variables.
1900
1901         No new tests, no behavior change.
1902
1903         * css/CSSAspectRatioValue.h:
1904         * css/CSSBorderImageSliceValue.h:
1905         * css/CSSCalculationValue.cpp:
1906         (WebCore::CSSCalcExpressionNodeParser::parseValue):
1907         * css/CSSCalculationValue.h:
1908         * css/CSSCrossfadeValue.cpp:
1909         (WebCore::subimageKnownToBeOpaque):
1910         * css/CSSCrossfadeValue.h:
1911         * css/CSSCursorImageValue.cpp:
1912         (WebCore::CSSCursorImageValue::~CSSCursorImageValue):
1913         (WebCore::CSSCursorImageValue::updateIfSVGCursorIsUsed):
1914         (WebCore::CSSCursorImageValue::cachedImage):
1915         (WebCore::CSSCursorImageValue::cachedOrPendingImage):
1916         (WebCore::CSSCursorImageValue::isSVGCursor):
1917         * css/CSSCursorImageValue.h:
1918         * css/CSSFilterImageValue.h:
1919         * css/CSSFontSelector.cpp:
1920         (WebCore::CSSFontSelector::addFontFaceRule):
1921         * css/CSSGradientValue.h:
1922         * css/CSSImageGeneratorValue.cpp:
1923         (WebCore::CSSImageGeneratorValue::image):
1924         (WebCore::CSSImageGeneratorValue::fixedSize):
1925         (WebCore::CSSImageGeneratorValue::loadSubimages):
1926         (WebCore::CSSImageGeneratorValue::subimageIsPending):
1927         (WebCore::CSSImageGeneratorValue::cachedImageForCSSValue):
1928         * css/CSSImageGeneratorValue.h:
1929         * css/CSSImageSetValue.cpp:
1930         (WebCore::CSSImageSetValue::fillImageSet):
1931         * css/CSSImageSetValue.h:
1932         * css/CSSImageValue.h:
1933         * css/CSSInheritedValue.h:
1934         * css/CSSInitialValue.h:
1935         * css/CSSLineBoxContainValue.h:
1936         * css/CSSParser.cpp:
1937         (WebCore::CSSParser::parseColor):
1938         (WebCore::CSSParser::addProperty):
1939         (WebCore::CSSParser::parse3ValuesFillPosition):
1940         (WebCore::CSSParser::parseFillPosition):
1941         (WebCore::CSSParser::parseFillRepeat):
1942         (WebCore::CSSParser::parseDeprecatedRadialGradient):
1943         (WebCore::CSSParser::parseRadialGradient):
1944         * css/CSSPrimitiveValue.h:
1945         * css/CSSReflectValue.h:
1946         * css/CSSToStyleMap.cpp:
1947         (WebCore::CSSToStyleMap::mapFillAttachment):
1948         (WebCore::CSSToStyleMap::mapFillClip):
1949         (WebCore::CSSToStyleMap::mapFillComposite):
1950         (WebCore::CSSToStyleMap::mapFillBlendMode):
1951         (WebCore::CSSToStyleMap::mapFillOrigin):
1952         (WebCore::CSSToStyleMap::mapFillRepeatX):
1953         (WebCore::CSSToStyleMap::mapFillRepeatY):
1954         (WebCore::CSSToStyleMap::mapFillSize):
1955         (WebCore::CSSToStyleMap::mapFillXPosition):
1956         (WebCore::CSSToStyleMap::mapFillYPosition):
1957         (WebCore::CSSToStyleMap::mapFillMaskSourceType):
1958         (WebCore::CSSToStyleMap::mapAnimationDelay):
1959         (WebCore::CSSToStyleMap::mapAnimationDirection):
1960         (WebCore::CSSToStyleMap::mapAnimationDuration):
1961         (WebCore::CSSToStyleMap::mapAnimationFillMode):
1962         (WebCore::CSSToStyleMap::mapAnimationIterationCount):
1963         (WebCore::CSSToStyleMap::mapAnimationName):
1964         (WebCore::CSSToStyleMap::mapAnimationPlayState):
1965         (WebCore::CSSToStyleMap::mapAnimationProperty):
1966         (WebCore::CSSToStyleMap::mapAnimationTimingFunction):
1967         (WebCore::CSSToStyleMap::mapNinePieceImageSlice):
1968         (WebCore::CSSToStyleMap::mapNinePieceImageQuad):
1969         (WebCore::CSSToStyleMap::mapNinePieceImageRepeat):
1970         * css/CSSValue.cpp:
1971         (WebCore::CSSValue::destroy):
1972         * css/CSSValue.h:
1973         (WebCore::CSSValue::isLineBoxContainValue):
1974         (WebCore::CSSValue::isCalcValue):
1975         * css/CSSValueList.h:
1976         * css/CSSVariableValue.h:
1977         * css/DeprecatedStyleBuilder.cpp:
1978         (WebCore::ApplyPropertyDefault::applyValue):
1979         (WebCore::ApplyPropertyNumber::applyValue):
1980         (WebCore::ApplyPropertyAuto::applyValue):
1981         (WebCore::ApplyPropertyClip::applyValue):
1982         (WebCore::ApplyPropertyColor::applyValue):
1983         (WebCore::ApplyPropertyLength::applyValue):
1984         (WebCore::ApplyPropertyString::applyValue):
1985         (WebCore::ApplyPropertyBorderRadius::applyValue):
1986         (WebCore::ApplyPropertyComputeLength::applyValue):
1987         (WebCore::ApplyPropertyFont::applyValue):
1988         (WebCore::ApplyPropertyFontFamily::applyValue):
1989         (WebCore::ApplyPropertyFontSize::applyValue):
1990         (WebCore::ApplyPropertyFontWeight::applyValue):
1991         (WebCore::ApplyPropertyFontVariantLigatures::applyValue):
1992         (WebCore::ApplyPropertyCounter::applyValue):
1993         (WebCore::ApplyPropertyCursor::applyValue):
1994         (WebCore::ApplyPropertyTextAlign::applyValue):
1995         (WebCore::ApplyPropertyTextDecoration::applyValue):
1996         (WebCore::ApplyPropertyMarqueeIncrement::applyValue):
1997         (WebCore::ApplyPropertyMarqueeRepetition::applyValue):
1998         (WebCore::ApplyPropertyMarqueeSpeed::applyValue):
1999         (WebCore::ApplyPropertyTextUnderlinePosition::applyValue):
2000         (WebCore::ApplyPropertyLineHeight::applyValue):
2001         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyValue):
2002         (WebCore::ApplyPropertyPageSize::applyValue):
2003         (WebCore::ApplyPropertyTextEmphasisStyle::applyValue):
2004         (WebCore::ApplyPropertyResize::applyValue):
2005         (WebCore::ApplyPropertyVerticalAlign::applyValue):
2006         (WebCore::ApplyPropertyAspectRatio::applyValue):
2007         (WebCore::ApplyPropertyZoom::applyValue):
2008         (WebCore::ApplyPropertyDisplay::applyValue):
2009         (WebCore::ApplyPropertyClipPath::applyValue):
2010         (WebCore::ApplyPropertyShape::applyValue):
2011         (WebCore::ApplyPropertyImageResolution::applyValue):
2012         (WebCore::ApplyPropertyTextIndent::applyValue):
2013         * css/FontFeatureValue.h:
2014         (WebCore::toFontFeatureValue):
2015         * css/FontValue.h:
2016         (WebCore::toFontValue):
2017         * css/MediaList.cpp:
2018         (WebCore::reportMediaQueryWarningIfNeeded):
2019         * css/MediaQueryEvaluator.cpp:
2020         (WebCore::compareAspectRatioValue):
2021         (WebCore::numberValue):
2022         (WebCore::orientationMediaFeatureEval):
2023         (WebCore::evalResolution):
2024         (WebCore::device_pixel_ratioMediaFeatureEval):
2025         (WebCore::resolutionMediaFeatureEval):
2026         (WebCore::computeLength):
2027         (WebCore::view_modeMediaFeatureEval):
2028         (WebCore::pointerMediaFeatureEval):
2029         * css/SVGCSSStyleSelector.cpp:
2030         (WebCore::StyleResolver::applySVGProperty):
2031         * css/ShadowValue.h:
2032         (WebCore::toShadowValue):
2033         * css/StylePropertySet.cpp:
2034         (WebCore::StylePropertySet::getLayeredShorthandValue):
2035         * css/StyleResolver.cpp:
2036         (WebCore::createGridTrackSize):
2037         (WebCore::createGridTrackList):
2038         (WebCore::createGridPosition):
2039         (WebCore::hasVariableReference):
2040         (WebCore::StyleResolver::applyProperty):
2041         (WebCore::StyleResolver::styleImage):
2042         (WebCore::StyleResolver::generatedOrPendingFromValue):
2043         (WebCore::StyleResolver::styleShader):
2044         (WebCore::StyleResolver::parseCustomFilterArrayParameter):
2045         (WebCore::StyleResolver::parseCustomFilterColorParameter):
2046         (WebCore::StyleResolver::parseCustomFilterNumberParameter):
2047         (WebCore::StyleResolver::parseCustomFilterParameter):
2048         (WebCore::StyleResolver::parseCustomFilterParameterList):
2049         (WebCore::StyleResolver::createCustomFilterOperationWithInlineSyntax):
2050         (WebCore::StyleResolver::createFilterOperations):
2051         * css/TransformFunctions.cpp:
2052         (WebCore::transformsForValue):
2053         * css/ViewportStyleResolver.cpp:
2054         (WebCore::ViewportStyleResolver::getViewportArgumentValue):
2055         * css/WebKitCSSMatrix.cpp:
2056         (WebCore::WebKitCSSMatrix::setMatrixValue):
2057         * css/WebKitCSSShaderValue.h:
2058         (WebCore::toWebKitCSSShaderValue):
2059         * editing/ApplyStyleCommand.cpp:
2060         (WebCore::ApplyStyleCommand::computedFontSize):
2061         * editing/EditingStyle.cpp:
2062         (WebCore::identifierForStyleProperty):
2063         (WebCore::HTMLElementEquivalent::valueIsPresentInStyle):
2064         (WebCore::cssValueToRGBA):
2065         (WebCore::EditingStyle::extractFontSizeDelta):
2066         (WebCore::EditingStyle::textDirection):
2067         (WebCore::EditingStyle::prepareToApplyAt):
2068         (WebCore::EditingStyle::mergeStyleFromRulesForSerialization):
2069         (WebCore::EditingStyle::legacyFontSize):
2070         (WebCore::EditingStyle::textDirectionForSelection):
2071         (WebCore::StyleChange::extractTextStyles):
2072         (WebCore::fontWeightIsBold):
2073         (WebCore::isTransparentColorValue):
2074         * editing/markup.cpp:
2075         (WebCore::propertyMissingOrEqualToNone):
2076         * page/PageSerializer.cpp:
2077         (WebCore::PageSerializer::retrieveResourcesForProperties):
2078         * rendering/style/StylePendingImage.h:
2079         (WebCore::StylePendingImage::data):
2080         (WebCore::StylePendingImage::cssImageValue):
2081         (WebCore::StylePendingImage::cssImageGeneratorValue):
2082         (WebCore::StylePendingImage::cssCursorImageValue):
2083         (WebCore::StylePendingImage::cssImageSetValue):
2084
2085 2013-09-22  Arunprasad Rajkumar  <ararunprasad@gmail.com>
2086
2087         Hiding a focused element should unfocus it and fire a blur event
2088         https://bugs.webkit.org/show_bug.cgi?id=29241
2089
2090         Reviewed by Darin Adler.
2091
2092         Test: fast/dom/HTMLDocument/active-element-gets-unfocusable.html
2093
2094         We check whether the current focus element is really focusable after
2095         the style recalculation and layout change. If it is not focusable then schedule a
2096         timer to reset it asynchronously.
2097
2098         * dom/Document.cpp:
2099         (WebCore::Document::Document):
2100         (WebCore::Document::recalcStyle): Check isFocusable() on the focus element after
2101         style recalculation.
2102         (WebCore::Document::updateLayout): Check isFocusable() on the focus element after
2103         layout.
2104         (WebCore::Document::resetHiddenFocusElementSoon):
2105         (WebCore::Document::resetHiddenFocusElementTimer):
2106         * dom/Document.h:
2107
2108 2013-09-22  Sam Weinig  <sam@webkit.org>
2109
2110         CTTE: StaticNodeLists often contain only Elements, we shouldn't store them as Vector<RefPtr<Node>> in those cases
2111         https://bugs.webkit.org/show_bug.cgi?id=121769
2112
2113         Reviewed by Andreas Kling.
2114
2115         Introduces StaticElementList and uses it.
2116
2117         * accessibility/AccessibilityRenderObject.cpp:
2118         (WebCore::AccessibilityRenderObject::addRadioButtonGroupMembers):
2119         * bindings/js/JSHTMLAllCollectionCustom.cpp:
2120         (WebCore::getNamedItems):
2121         * bindings/js/JSHTMLCollectionCustom.cpp:
2122         * bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
2123         (WebCore::getNamedItems):
2124         * bindings/js/JSHTMLFormElementCustom.cpp:
2125         (WebCore::JSHTMLFormElement::nameGetter):
2126         * dom/SelectorQuery.cpp:
2127         (WebCore::AllElementExtractorSelectorQueryTrait::appendOutputForElement):
2128         (WebCore::SelectorDataList::queryAll):
2129         * dom/StaticNodeList.cpp:
2130         (WebCore::StaticElementList::length):
2131         (WebCore::StaticElementList::item):
2132         (WebCore::StaticElementList::namedItem):
2133         * dom/StaticNodeList.h:
2134         * dom/WebKitNamedFlow.cpp:
2135         (WebCore::WebKitNamedFlow::getRegionsByContent):
2136         (WebCore::WebKitNamedFlow::getRegions):
2137         (WebCore::WebKitNamedFlow::getContent):
2138         (WebCore::WebKitNamedFlow::dispatchRegionLayoutUpdateEvent):
2139         (WebCore::WebKitNamedFlow::dispatchRegionOversetChangeEvent):
2140         * html/HTMLCollection.cpp:
2141         (WebCore::HTMLCollection::namedItems):
2142         * html/HTMLCollection.h:
2143         * html/HTMLFormElement.cpp:
2144         (WebCore::HTMLFormElement::getNamedElements):
2145         * html/HTMLFormElement.h:
2146         * svg/SVGSVGElement.cpp:
2147         (WebCore::SVGSVGElement::collectIntersectionOrEnclosureList):
2148
2149 2013-09-22  Sam Weinig  <sam@webkit.org>
2150
2151         CTTE: RenderNamedFlowThread and FlowThreadController should operate on Elements, not Nodes
2152         https://bugs.webkit.org/show_bug.cgi?id=121768
2153
2154         Reviewed by Andreas Kling.
2155
2156         * dom/Element.cpp:
2157         (WebCore::Element::unregisterNamedFlowContentElement):
2158         (WebCore::Element::shouldMoveToFlowThread):
2159         (WebCore::Element::clearStyleDerivedDataBeforeDetachingRenderer):
2160         * dom/Element.h:
2161         Update to new names and to pass this as a reference to the FlowThreadController.
2162
2163         * dom/Node.cpp:
2164         * dom/Node.h:
2165         Move isRegisteredWithNamedFlow() to Element.
2166
2167         * dom/WebKitNamedFlow.cpp:
2168         (WebCore::WebKitNamedFlow::getRegionsByContent):
2169         (WebCore::WebKitNamedFlow::getRegions):
2170         (WebCore::WebKitNamedFlow::getContent):
2171         Update for contentNodes() -> contentElements() name change. Modernize the code a bit
2172         as well.
2173
2174         * rendering/FlowThreadController.cpp:
2175         (WebCore::FlowThreadController::registerNamedFlowContentElement):
2176         (WebCore::FlowThreadController::unregisterNamedFlowContentElement):
2177         (WebCore::FlowThreadController::isContentElementRegisteredWithAnyNamedFlow):
2178         * rendering/FlowThreadController.h:
2179         Change the Node* -> RenderNamedFlowThread* map to a Element* -> RenderNamedFlowThread*. Update
2180         functions taking Node*s to take Element&s.
2181
2182         * rendering/RenderNamedFlowThread.cpp:
2183         (WebCore::RenderNamedFlowThread::~RenderNamedFlowThread):
2184         (WebCore::RenderNamedFlowThread::clearContentElements):
2185         (WebCore::RenderNamedFlowThread::registerNamedFlowContentElement):
2186         (WebCore::RenderNamedFlowThread::unregisterNamedFlowContentElement):
2187         (WebCore::RenderNamedFlowThread::hasContentElement):
2188         (WebCore::isContainedInElements):
2189         (WebCore::nextNodeInsideContentElement):
2190         (WebCore::RenderNamedFlowThread::getRanges):
2191         * rendering/RenderNamedFlowThread.h:
2192         Change the NamedFlowContent set to store Elements rather than Nodes. Like with FlowThreadController,
2193         update registration functions to take Element&s instead of Node*s, removing asserts.
2194         
2195         * rendering/RenderRegion.cpp:
2196         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
2197         Update for new names.
2198
2199         * style/StyleResolveTree.cpp:
2200         (WebCore::Style::moveToFlowThreadIfNeeded):
2201         Pass the Element and RenderNamedFlowThread as references.
2202
2203 2013-09-22  Andreas Kling  <akling@apple.com>
2204
2205         Give purity hints to compiler to avoid penalizing repeated calls to some functions.
2206         <https://webkit.org/b/121744>
2207
2208         Reviewed by Darin Adler.
2209
2210         Mark the following functions pure:
2211
2212             - gcController()
2213             - cssValuePool()
2214             - threadGlobalData()
2215
2216         I had this idea when I saw Darin's patch to cache cssValuePool() in a local.
2217         We know that this function will always return the same value, so we should just
2218         share this knowledge with the compiler and let it do the cleverness instead.
2219
2220 2013-09-21  Darin Adler  <darin@apple.com>
2221
2222         Fix too-strict type error exceptions introduced in WebGL bindings
2223         https://bugs.webkit.org/show_bug.cgi?id=121759
2224
2225         Reviewed by Alexey Proskuryakov.
2226
2227         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2228         (WebCore::JSWebGLRenderingContext::getAttachedShaders): Allow undefined
2229         or null without throwing type error.
2230         (WebCore::JSWebGLRenderingContext::getProgramParameter): Ditto.
2231         (WebCore::JSWebGLRenderingContext::getUniform): Ditto.
2232         (WebCore::dataFunctionf): Ditto.
2233         (WebCore::dataFunctioni): Ditto.
2234         (WebCore::dataFunctionMatrix): Ditto.
2235
2236 2013-09-21  Sam Weinig  <sam@webkit.org>
2237
2238         Event and EventTarget interfaces don't need to be store as AtomicStrings
2239         https://bugs.webkit.org/show_bug.cgi?id=121751
2240
2241         Reviewed by Andreas Kling.
2242
2243         Convert the Event and EventTarget interface identifiers from AtomicStrings to enums. They
2244         are not extensible and not exposed as Strings anywhere.
2245
2246         * Files elided *
2247
2248 2013-09-21  Darin Adler  <darin@apple.com>
2249
2250         Add ExecState::uncheckedArgument and use where possible to shrink a bit
2251         https://bugs.webkit.org/show_bug.cgi?id=121750
2252
2253         Reviewed by Andreas Kling.
2254
2255         * bindings/js/JSHTMLCanvasElementCustom.cpp:
2256         (WebCore::JSHTMLCanvasElement::probablySupportsContext): Already checked count.
2257         (WebCore::JSHTMLCanvasElement::toDataURL): Ditto.
2258         * bindings/js/JSHTMLDocumentCustom.cpp:
2259         (WebCore::documentWrite): In a loop.
2260         * bindings/js/JSInjectedScriptHostCustom.cpp:
2261         (WebCore::JSInjectedScriptHost::inspectedObject): Already checked count.
2262         (WebCore::JSInjectedScriptHost::internalConstructorName): Ditto.
2263         (WebCore::JSInjectedScriptHost::isHTMLAllCollection): Ditto.
2264         (WebCore::JSInjectedScriptHost::type): Ditto.
2265         (WebCore::JSInjectedScriptHost::functionDetails): Ditto.
2266         (WebCore::JSInjectedScriptHost::getEventListeners): Ditto.
2267         (WebCore::JSInjectedScriptHost::inspect): Ditto.
2268         (WebCore::JSInjectedScriptHost::databaseId): Ditto.
2269         (WebCore::JSInjectedScriptHost::storageId): Ditto.
2270         * bindings/js/JSSQLTransactionSyncCustom.cpp:
2271         (WebCore::JSSQLTransactionSync::executeSql): Ditto.
2272         * bindings/js/JSSVGLengthCustom.cpp:
2273         (WebCore::JSSVGLength::convertToSpecifiedUnits): Ditto.
2274         * bindings/js/JSSharedWorkerCustom.cpp:
2275         (WebCore::JSSharedWorkerConstructor::constructJSSharedWorker): Ditto.
2276
2277         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2278         (WebCore::getObjectParameter): Already checked count.
2279         (WebCore::JSWebGLRenderingContext::getAttachedShaders): Removed tortured code
2280         to triply do the checking that the toWebGLProgram function already does, including
2281         spurious exception checking in code that can't create an exception. Also count is
2282         already checked.
2283         (WebCore::JSWebGLRenderingContext::getExtension): More of the same.
2284         (WebCore::JSWebGLRenderingContext::getFramebufferAttachmentParameter): Ditto.
2285         (WebCore::JSWebGLRenderingContext::getParameter): Ditto.
2286         (WebCore::JSWebGLRenderingContext::getProgramParameter): Ditto.
2287         (WebCore::JSWebGLRenderingContext::getShaderParameter): Ditto.
2288         (WebCore::JSWebGLRenderingContext::getUniform): Ditto.
2289         (WebCore::dataFunctionf): Ditto.
2290         (WebCore::dataFunctioni): Ditto.
2291         (WebCore::dataFunctionMatrix): Ditto.
2292
2293         * bindings/js/JSWorkerGlobalScopeCustom.cpp:
2294         (WebCore::JSWorkerGlobalScope::importScripts): In a loop.
2295         * bindings/js/JSXMLHttpRequestCustom.cpp:
2296         (WebCore::JSXMLHttpRequest::open): Already checked. Also removed some unneeded
2297         argument count checks.
2298         (WebCore::JSXMLHttpRequest::send): Removed unneeded special case for 0 argument
2299         count that does the same thing as the undefined case, since asking for an
2300         argument past the count yields undefined.
2301
2302         * bindings/js/JSXSLTProcessorCustom.cpp:
2303         (WebCore::JSXSLTProcessor::setParameter): Already checked.
2304         (WebCore::JSXSLTProcessor::getParameter): Already checked.
2305         (WebCore::JSXSLTProcessor::removeParameter): Already checked.
2306
2307         * bindings/js/ScheduledAction.cpp:
2308         (WebCore::ScheduledAction::ScheduledAction): In a loop.
2309         * bindings/js/ScriptCallStackFactory.cpp:
2310         (WebCore::createScriptArguments): Ditto.
2311
2312         * bindings/scripts/CodeGeneratorJS.pm:
2313         (GenerateParametersCheck): Removed some excess argumentCount checks.
2314         Used uncheckedArgument in a few places. More needs to be done, especially for
2315         overloaded functions.
2316
2317         * bridge/c/c_instance.cpp:
2318         (JSC::Bindings::CInstance::invokeMethod): In a loop.
2319         (JSC::Bindings::CInstance::invokeDefaultMethod): Ditto.
2320         * bridge/objc/objc_instance.mm:
2321         (ObjcInstance::invokeObjcMethod): Ditto.
2322         (ObjcInstance::invokeDefaultMethod): Ditto.
2323
2324         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
2325         * bindings/scripts/test/JS/JSTestObj.cpp:
2326         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
2327         Updated.
2328
2329 2013-09-21  Jon Lee  <jonlee@apple.com>
2330
2331         Fix Obj-C bindings test expectations.
2332         Unreviewed.
2333
2334         Bindings tests failed with r156232, from https://bugs.webkit.org/show_bug.cgi?id=121745.
2335
2336         * bindings/scripts/test/ObjC/DOMTestObj.mm:
2337         (-[DOMTestObj reflectedStringAttr]): Update test expectations.
2338
2339 2013-09-21  Andreas Kling  <akling@apple.com>
2340
2341         Node: FINAL-ize EventTarget overrides.
2342         <https://webkit.org/b/121748>
2343
2344         Reviewed by Darin Adler.
2345
2346         Mark the following Node functions FINAL:
2347
2348             - scriptExecutionContext()
2349             - eventTargetData()
2350             - ensureEventTargetData()
2351
2352         This devirtualizes a myriad of generated calls in the JSC bindings.
2353
2354 2013-09-21  Andreas Kling  <akling@apple.com>
2355
2356         Don't bloat Obj-C bindings with inlined attribute retrieval.
2357         <https://webkit.org/b/121745>
2358
2359         Reviewed by Anders Carlsson.
2360
2361         Hack bindings generator to always use getAttribute() for Objective-C.
2362         Reduces WebCore binary size by 25120 bytes.
2363
2364 2013-09-20  Darin Adler  <darin@apple.com>
2365
2366         Shink attribute event listener code
2367         https://bugs.webkit.org/show_bug.cgi?id=121735
2368
2369         Reviewed by Antti Koivisto.
2370
2371         * GNUmakefile.list.am: Eliminate ScriptEventListener source files.
2372         * Target.pri: Ditto.
2373         * UseJSC.cmake: Ditto.
2374         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
2375         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
2376         * WebCore.xcodeproj/project.pbxproj: Ditto.
2377         * bindings/js/JSBindingsAllInOne.cpp: Ditto.
2378
2379         * bindings/js/JSDOMGlobalObject.h: Removed unneeded forward declarations
2380         of JSEventListener and JSLazyEventListener.
2381
2382         * bindings/js/JSLazyEventListener.cpp:
2383         (WebCore::JSLazyEventListener::JSLazyEventListener): Changed type to
2384         ContainerNode because the node pointer is only ever used for elements
2385         and documents.
2386         (WebCore::eventParameterName): Moved this function here from
2387         ScriptEventListener.cpp, but also rewrote to use NeverDestroyed.
2388         (WebCore::JSLazyEventListener::createForNode): Moved this function
2389         here from ScriptEventListener.cpp, cleaned up a bit.
2390         (WebCore::JSLazyEventListener::createForDOMWindow): Ditto.
2391
2392         * bindings/js/JSLazyEventListener.h: Replaced the old create function
2393         with two new create functions we can use directly. Also used some
2394         OVERRIDE, some FINAL, and a bit of WTF_DELETED_FUNCTION so we don't
2395         accidentally call create and create a non-lazy listener.
2396
2397         * bindings/js/ScriptEventListener.cpp: Removed.
2398         * bindings/js/ScriptEventListener.h: Removed.
2399
2400         * dom/ContainerNode.cpp:
2401         (WebCore::ContainerNode::setAttributeEventListener): Added.
2402         Calls JSLazyEventListener::createForNode and then calls the other
2403         overload of setAttributeEventListener, to obviate having more code
2404         at the call site.
2405         * dom/ContainerNode.h: Added overload of setAttributeEventListener
2406         for convenient use in Document and Element implementations.
2407
2408         * dom/Document.cpp:
2409         (WebCore::Document::prepareForDestruction): Use m_domWindow instead
2410         of the domWindow() function.
2411         (WebCore::Document::removeAllEventListeners): Ditto.
2412         (WebCore::Document::errorEventTarget): Ditto.
2413         (WebCore::Document::takeDOMWindowFrom): Ditto.
2414         (WebCore::Document::setWindowAttributeEventListener): Ditto. Also
2415         added an overload that calls JSLazyEventListener::createForDOMWindow.
2416         (WebCore::Document::getWindowAttributeEventListener): Use m_domWindow.
2417         (WebCore::Document::dispatchWindowEvent): Ditto.
2418         (WebCore::Document::dispatchWindowLoadEvent): Ditto.
2419         (WebCore::Document::enqueueWindowEvent): Ditto.
2420         (WebCore::Document::enqueuePopstateEvent): Ditto.
2421         * dom/Document.h: Added overload of setWindowAttributeEventListener.
2422
2423         * html/HTMLBodyElement.cpp: Removed unnneded include.
2424         (WebCore::HTMLBodyElement::parseAttribute): Removed all the calls to
2425         createAttributeEventListener, and use the setAttributeEventListener
2426         overloads instead.
2427         * html/HTMLButtonElement.cpp: Ditto.
2428         * html/HTMLElement.cpp:
2429         (WebCore::HTMLElement::parseAttribute): Ditto.
2430         * html/HTMLFormControlElement.cpp: Ditto.
2431         * html/HTMLFormElement.cpp: Ditto.
2432         * html/HTMLFrameElementBase.cpp:
2433         (WebCore::HTMLFrameElementBase::parseAttribute): Ditto.
2434         * html/HTMLFrameSetElement.cpp:
2435         (WebCore::HTMLFrameSetElement::parseAttribute): Ditto.
2436         * html/HTMLImageElement.cpp:
2437         (WebCore::HTMLImageElement::parseAttribute): Ditto.
2438         * html/HTMLInputElement.cpp:
2439         (WebCore::HTMLInputElement::parseAttribute): Ditto.
2440         * html/HTMLLinkElement.cpp:
2441         (WebCore::HTMLLinkElement::parseAttribute): Ditto.
2442         * html/HTMLMediaElement.cpp:
2443         (WebCore::HTMLMediaElement::parseAttribute): Ditto.
2444         * html/HTMLObjectElement.cpp:
2445         (WebCore::HTMLObjectElement::parseAttribute): Ditto.
2446         * html/HTMLScriptElement.cpp:
2447         (WebCore::HTMLScriptElement::parseAttribute): Ditto.
2448         * html/HTMLSelectElement.cpp: Ditto.
2449         * html/HTMLStyleElement.cpp: Ditto.
2450         * html/HTMLTextFormControlElement.cpp: Ditto.
2451         * html/HTMLTrackElement.cpp: Ditto.
2452         * html/track/LoadableTextTrack.cpp: Ditto.
2453         * svg/SVGElement.cpp:
2454         (WebCore::SVGElement::parseAttribute): Ditto.
2455         * svg/SVGSVGElement.cpp:
2456         (WebCore::SVGSVGElement::parseAttribute): Ditto.
2457         * svg/SVGScriptElement.cpp:
2458         (WebCore::SVGScriptElement::parseAttribute): Ditto.
2459
2460         * inspector/InspectorDOMAgent.cpp:
2461         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
2462         Moved the code here to dig inside a JSEventListener for things like
2463         the source location. This used to be spread across multiple function
2464         calls in ScriptEventListener.h, which were doing and redoing the same
2465         things, so better to just get it all at once.
2466
2467         * html/parser/XSSAuditor.cpp:
2468         (WebCore::XSSAuditor::init): Fixed "minium" typo.
2469
2470 2013-09-21  Anders Carlsson  <andersca@apple.com>
2471
2472         Don't store the "processing-instruction" string for PI tokens in the XPath parser
2473         https://bugs.webkit.org/show_bug.cgi?id=121746
2474
2475         Reviewed by Antti Koivisto.
2476
2477         For PI tokens, the string is always going to be "processing-instruction", and it's never used so we don't need to save it.
2478
2479         * xml/XPathGrammar.y:
2480         * xml/XPathParser.cpp:
2481         (Parser::nextTokenInternal):
2482         (Parser::lex):
2483
2484 2013-09-21  Patrick Gansterer  <paroga@webkit.org>
2485
2486         Handle windows lineendings in makeprop.pl after r155511
2487         https://bugs.webkit.org/show_bug.cgi?id=121740
2488
2489         Reviewed by Ryosuke Niwa.
2490
2491         Check for an optinal \r at the end of a line in regular expressions
2492         to make it work again on native windows machines which use CRLF.
2493
2494         * css/makeprop.pl:
2495
2496 2013-09-21  Andreas Kling  <akling@apple.com>
2497
2498         Re-inline some hot ElementData functions.
2499         <https://webkit.org/b/121743>
2500
2501         Reviewed by Antti Koivisto.
2502
2503         Make the following functions inline again:
2504
2505             - deref()
2506             - addAttribute()
2507             - removeAttribute()
2508             - attributeAt()
2509
2510         They were out-of-lined in r154249 and perf.webkit.org reports a 1.4%
2511         regression on the html5 spec for that revision. This'll hopefully steer
2512         the graph back in the right direction.
2513
2514 2013-09-21  Tim Horton  <timothy_horton@apple.com>
2515
2516         GeneratorGeneratedImage should be called GradientImage
2517         https://bugs.webkit.org/show_bug.cgi?id=121085
2518
2519         Reviewed by Simon Fraser.
2520
2521         No new tests, just a refactor.
2522
2523         r150053 removed the concept of a Generator, making GeneratorGeneratedImage
2524         take a Gradient. This leaves GeneratorGeneratedImage's name not making a
2525         whole lot of sense, so let's rename it to GradientImage.
2526
2527         * CMakeLists.txt:
2528         * GNUmakefile.list.am:
2529         * Target.pri:
2530         * WebCore.vcxproj/WebCore.vcxproj:
2531         * WebCore.vcxproj/WebCore.vcxproj.filters:
2532         * WebCore.xcodeproj/project.pbxproj:
2533         * css/CSSGradientValue.cpp:
2534         (WebCore::CSSGradientValue::image):
2535         * platform/graphics/BitmapImage.h:
2536         * platform/graphics/GradientImage.cpp: Renamed from Source/WebCore/platform/graphics/GeneratorGeneratedImage.cpp.
2537         (WebCore::GradientImage::draw):
2538         (WebCore::GradientImage::drawPattern):
2539         * platform/graphics/GradientImage.h: Renamed from Source/WebCore/platform/graphics/GeneratorGeneratedImage.h.
2540         * platform/graphics/Image.h:
2541         * platform/graphics/ImageBuffer.h:
2542         Rename.
2543
2544         * css/CSSImageGeneratorValue.cpp:
2545         (WebCore::CSSImageGeneratorValue::cachedImageForSize):
2546         (WebCore::CSSImageGeneratorValue::saveCachedImageForSize):
2547         (WebCore::CSSImageGeneratorValue::CachedGeneratedImage::CachedGeneratedImage):
2548         * css/CSSImageGeneratorValue.h:
2549         (WebCore::CSSImageGeneratorValue::CachedGeneratedImage::image):
2550         Drive-by, the CSSImageGeneratorValue generated image cache should be
2551         in terms of GeneratedImage, not a random subclass, regardless
2552         of the fact that it's only used for GradientImage as of yet.
2553
2554 2013-09-21  Darin Adler  <darin@apple.com>
2555
2556         Shrink valueForBasicShape by removing repeated calls to cssValuePool()
2557         https://bugs.webkit.org/show_bug.cgi?id=121736
2558
2559         Reviewed by Sam Weinig.
2560
2561         * css/BasicShapeFunctions.cpp:
2562         (WebCore::valueForBasicShape): Put the pool into a local variable and use that.
2563
2564 2013-09-20  Darin Adler  <darin@apple.com>
2565
2566         Another CSS parser leak fix
2567         https://bugs.webkit.org/show_bug.cgi?id=121730
2568
2569         Reviewed by Alexey Proskuryakov.
2570
2571         * css/CSSGrammar.y.in: Added a missing adoptPtr.
2572
2573 2013-09-20  Alexey Proskuryakov  <ap@apple.com>
2574
2575         Handle panning gestures messages properly on Windows
2576         https://bugs.webkit.org/show_bug.cgi?id=121711
2577
2578         Follow-up fix: five regression tests started to crash on Mac.
2579
2580         Reviewed by Anders Carlsson.
2581
2582         * rendering/RenderLayer.cpp: (WebCore::RenderLayer::scrollByRecursively):
2583         Added null checks, not all callers are interested in scrolled view pointer.
2584
2585 2013-09-20  Ryosuke Niwa  <rniwa@webkit.org>
2586
2587         Bad cast from CSSInitialValue to CSSValueList
2588         https://bugs.webkit.org/show_bug.cgi?id=121729
2589
2590         Reviewed by Beth Dakin.
2591
2592         Merge https://chromium.googlesource.com/chromium/blink/+/fcfaa51f9207b32cffe751c1a1380a921e464cbb
2593
2594         The issue was that we would cast to CSSValueList without checking
2595         the type of the CSSValue. After this change, we use the ASSERT'ing
2596         cast and explicitly check the type of the CSSValue before the cast.
2597
2598         Test: fast/css/crash-inherit-value-font-family.html
2599
2600         * css/CSSParser.cpp:
2601         (WebCore::CSSParser::parseFontFaceValue):
2602
2603 2013-09-20  Zoltan Horvath  <zoltan@webkit.org>
2604
2605         Remove includes from LineWidth.h
2606         https://bugs.webkit.org/show_bug.cgi?id=121716
2607
2608         Reviewed by Darin Adler.
2609
2610         In r156197 I removed logicalLineHeight from LineWidth.h, so we don't need to include RenderBlock.h
2611         and RenderRubyRun.h anymore in LineWidth.h.
2612
2613         No new tests, no behavior change.
2614
2615         * rendering/LineWidth.cpp:
2616         * rendering/LineWidth.h:
2617
2618 2013-09-20  Roger Fong  <roger_fong@apple.com>
2619
2620         Handle panning gestures messages properly on Windows.
2621         https://bugs.webkit.org/show_bug.cgi?id=121711.
2622
2623         Reviewed by Brent Fulgham.
2624
2625         This is needed by the Windows port to keep track to determine whether or not
2626         we need to overpan.
2627
2628         No new functionality added.
2629
2630         * rendering/RenderLayer.cpp:
2631         (WebCore::RenderLayer::scrollByRecursively):
2632         * rendering/RenderLayer.h: 
2633         Added an argument to keep track of which scrollview was actually scrolled
2634
2635 2013-09-20  Alexandru Chiculita  <achicu@adobe.com>
2636
2637         Web Inspector: [CSS Regions] Display CSS Regions chain when highlighting a CSS Region node
2638         https://bugs.webkit.org/show_bug.cgi?id=121719
2639
2640         Reviewed by Joseph Pecoraro.
2641
2642         Test: inspector/elements/highlight-node-regions.html
2643
2644         When a CSS Region node is highlighted through the WebInspector, it will also lookup all the regions
2645         that are part of the same flow and inject enough information into InspectorOverlayPage.js to get the other
2646         CSS Regions highlighted as well. A chain will also link the regions and a number will display the ordering
2647         of the content.
2648
2649         * WebCore.exp.in:
2650         * inspector/InspectorController.cpp:
2651         (WebCore::InspectorController::buildObjectForHighlightedNode):
2652         * inspector/InspectorController.h:
2653         * inspector/InspectorOverlay.cpp:
2654         (WebCore::buildObjectForRegionHighlight):
2655         (WebCore::buildObjectForCSSRegionsHighlight):
2656         (WebCore::InspectorOverlay::buildObjectForHighlightedNode):
2657         (WebCore::InspectorOverlay::drawNodeHighlight): Separated the InspectorObject building part out of this function,
2658         so that we can call buildObjectForHighlightedNode from the Internals APIs for testing.
2659         * inspector/InspectorOverlay.h:
2660         * inspector/InspectorOverlayPage.js:
2661         (_drawRegionNumber):
2662         (_quadMidPoint):
2663         (_drawRegionLink):
2664         (_fixQuadScrollPosition):
2665         (_drawRegionsHighlight):
2666         (drawNodeHighlight):
2667         * testing/Internals.cpp: Exposed the generated InspectorObject to the layout test.
2668         (WebCore::Internals::inspectorHighlightObject):
2669         * testing/Internals.h:
2670         * testing/Internals.idl:
2671
2672 2013-09-20  Commit Queue  <commit-queue@webkit.org>
2673
2674         Unreviewed, rolling out r156185.
2675         http://trac.webkit.org/changeset/156185
2676         https://bugs.webkit.org/show_bug.cgi?id=121727
2677
2678         Caused a lot of crashes in tests (Requested by ap on #webkit).
2679
2680         * dom/Document.cpp:
2681         (WebCore::Document::Document):
2682         (WebCore::Document::recalcStyle):
2683         (WebCore::Document::updateLayout):
2684         * dom/Document.h:
2685
2686 2013-09-20  Dean Jackson  <dino@apple.com>
2687
2688         Shaders that fail to compile should be marked as such
2689         https://bugs.webkit.org/show_bug.cgi?id=121721
2690
2691         Reviewed by Simon Fraser.
2692
2693         1. Add a new logging channel for WebGL.
2694
2695         2. If a translated shader fails to compile (technically
2696         this should never happen), mark it as invalid.
2697
2698         Test: https://www.khronos.org/registry/webgl/sdk/tests/conformance/glsl/misc/shader-with-non-reserved-words.html
2699
2700         * platform/Logging.h: New WebGL channel.
2701         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
2702         (WebCore::GraphicsContext3D::compileShader): Log the raw and translated
2703         input to glCompileShader, but mark the entry as invalid.
2704
2705 2013-09-20  Mario Sanchez Prada  <mario.prada@samsung.com>
2706
2707         [ATK] Do not expose aria-help in ATK based platforms
2708         https://bugs.webkit.org/show_bug.cgi?id=121675
2709
2710         Reviewed by Chris Fleizach.
2711
2712         Stop exposing the value for the 'aria-help' attribute as an
2713         AtkObject attribute, based in AccessibilityObject::helpText().
2714
2715         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2716         (webkitAccessibleGetAttributes): Remove the mapping.
2717
2718 2013-09-20  Simon Fraser  <simon.fraser@apple.com>
2719
2720         Scrollbars don't appear on long pages after r155660
2721         https://bugs.webkit.org/show_bug.cgi?id=121714
2722         <rdar://problem/15042478>
2723
2724         Reviewed by Beth Dakin.
2725         
2726         After r155660, we don't do any additional layouts when scrollbars are 
2727         added or removed. That caused us to not enter the code that creates or
2728         destroys composting layers for scrollbars in RenderLayerCompositor, resulting
2729         in missing scrollbars.
2730         
2731         Fix by having ScrollView::updateScrollbars() call addedOrRemovedScrollbar()
2732         when a scrollbar was added or removed, which is overridden in FrameView
2733         to call through to RenderLayerCompositor::frameViewDidAddOrRemoveScrollbars().
2734
2735         Not testable since scrollbar layers aren't contained in layer tree dumps
2736         (to reduce diffs between platforms).
2737
2738         * page/FrameView.cpp:
2739         (WebCore::FrameView::addedOrRemovedScrollbar): New function to tell the compositor
2740         that scrollbars changed.
2741         * page/FrameView.h:
2742         * platform/ScrollView.cpp:
2743         (WebCore::ScrollView::setHasHorizontalScrollbar): Change the meaning of the return
2744         value to say if the scrollbar was added or removed. Add an out param that indicates
2745         whether the scrollbar change affects content size (not true for overlay scrollbars).
2746         (WebCore::ScrollView::setHasVerticalScrollbar): Ditto.
2747         (WebCore::ScrollView::updateScrollbars): Keep track of whether scrollbars were
2748         added or removed, and call addedOrRemovedScrollbar() if true.
2749         * platform/ScrollView.h:
2750         * rendering/RenderLayerCompositor.cpp:
2751         (WebCore::RenderLayerCompositor::frameViewDidAddOrRemoveScrollbars): Call updateOverflowControlsLayers().
2752         (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
2753         * rendering/RenderLayerCompositor.h:
2754
2755 2013-09-20  Simon Fraser  <simon.fraser@apple.com>
2756
2757         Ensure that TileController tile coverage is updated on scrolling even when we don't have scrollbars
2758         https://bugs.webkit.org/show_bug.cgi?id=121700
2759         <rdar://problem/15030589>
2760
2761         Reviewed by Dean Jackson.
2762
2763         r155660 introduced a bug where we wouldn't make scrollbars on long pages. However,
2764         that revealed a fundamental flaw in the TiledBacking update logic; it relied on the
2765         GraphicsLayer flushes triggered by scrollbars updates in order to update the main
2766         TileController's tile coverage. No scrollbars meant no tile coverage updates.
2767         
2768         Fix by explicitly triggering a flush when the FrameView is scrolled (we get
2769         notified about this on the main thread after the scrolling thread has moved
2770         layers around).
2771         
2772         No test since this will only be exposed for a short time while scrollbars are
2773         broken.
2774
2775         * rendering/RenderLayerCompositor.cpp:
2776         (WebCore::RenderLayerCompositor::frameViewDidScroll):
2777
2778 2013-09-20  Zoltan Horvath  <zoltan@webkit.org>
2779
2780         Refactoring LineBreaker and RenderTextInfo out of RenderBlock.h
2781         https://bugs.webkit.org/show_bug.cgi?id=121707
2782
2783         Reviewed by David Hyatt.
2784
2785         LineBreaker and RenderTextInfo are defined in RenderBlock.h, but only used in RenderBlockLineLayout.cpp.
2786         Moving them there (LineBreaker needs to be a friend class of RenderBlock) in the first step in the process
2787         of refactoring LineBreaker::NextSegmentBreak into more manageable chunks.
2788
2789         This change was reviewed and landed in Blink:
2790         https://src.chromium.org/viewvc/blink?revision=157402&view=revision
2791
2792         No new tests.
2793
2794         * rendering/RenderBlock.h:
2795         * rendering/RenderBlockLineLayout.cpp:
2796         (WebCore::LineBreaker::LineBreaker):
2797         (WebCore::LineBreaker::lineWasHyphenated):
2798         (WebCore::LineBreaker::positionedObjects):
2799         (WebCore::LineBreaker::clear):
2800         (WebCore::RenderTextInfo::RenderTextInfo):
2801         (WebCore::RenderTextInfo::~RenderTextInfo):
2802         (WebCore::LineBreaker::skipTrailingWhitespace):
2803         (WebCore::LineBreaker::skipLeadingWhitespace):
2804         (WebCore::LineBreaker::reset):
2805         (WebCore::LineBreaker::nextLineBreak):
2806         (WebCore::LineBreaker::nextSegmentBreak):
2807
2808 2013-09-20  Zoltan Horvath  <zoltan@webkit.org>
2809
2810         Move logicalHeightForLine out of LineWidth.h
2811         https://bugs.webkit.org/show_bug.cgi?id=121575
2812
2813         Reviewed by David Hyatt.
2814
2815         In bug #121107 (r155565), I moved logicalHeightForLine into LineWidth.h as part of LineWidth
2816         refactoring. LogicalHeightForLine without passing the second parameter uses RenderBlock::lineHeight
2817         anyway, except it doesn't take -line-box-contain CSS property into account. For Shapes we don't
2818         have implementation for variable-height lines (https://bugs.webkit.org/show_bug.cgi?id=95361) yet, so
2819         so I modified the affected functions to call lineHeight directly. I renamed logicalHeightForLine
2820         to minLineHeightForReplacedRenderer, and I made the second parameter a mandatory for that function.
2821
2822         No new tests, no behavior change.
2823
2824         * rendering/LineWidth.cpp:
2825         (WebCore::LineWidth::updateAvailableWidth):
2826         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
2827         * rendering/LineWidth.h:
2828         * rendering/RenderBlock.cpp: Move the definition here.
2829         (WebCore::RenderBlock::minLineHeightForReplacedRenderer):
2830         * rendering/RenderBlock.h: Move the function here and rename it.
2831         * rendering/RenderBlockLineLayout.cpp:
2832         (WebCore::RenderBlock::layoutShapeInsideInfo):
2833         (WebCore::updateLogicalInlinePositions):
2834         (WebCore::updateSegmentsForShapes):
2835
2836 2013-09-20  Alexey Proskuryakov  <ap@apple.com>
2837
2838         -[WebHTMLConveter _getFloat:forNode:property:] leaks
2839         https://bugs.webkit.org/show_bug.cgi?id=121709
2840
2841         Reviewed by Enrica Casucci.
2842
2843         * platform/mac/HTMLConverter.mm:
2844         (-[WebHTMLConverter _getFloat:forNode:property:]): Don't leak.
2845
2846 2013-09-20  Yongjun Zhang  <yongjun_zhang@apple.com>
2847
2848         Add an argument to ImageSource::createFrameAtIndex to hint a decoder that we expect a scaled image.
2849         https://bugs.webkit.org/show_bug.cgi?id=121696
2850
2851         Reviewed by Antti Koivisto.
2852
2853         Add an argument to ImageSource::createFrameAtIndex.  A platform image decoder can decide the optimal
2854         scale based on the hint and pass the real scale it used for decoding.
2855
2856         No new tests, no behavior change.
2857
2858         * platform/graphics/ImageSource.cpp:
2859         (WebCore::ImageSource::createFrameAtIndex):
2860         * platform/graphics/ImageSource.h:
2861         * platform/graphics/cg/ImageSourceCG.cpp:
2862         (WebCore::ImageSource::createFrameAtIndex):
2863
2864 2013-09-20  Andreas Kling  <akling@apple.com>
2865
2866         Make JSMainThreadNullState noncopyable.
2867
2868         Blindly rubber-stamped by Antti Koivisto.
2869
2870         * bindings/js/JSMainThreadExecState.h:
2871
2872 2013-09-20  Dan Bernstein  <mitz@apple.com>
2873
2874         Make extract-localizable-strings available to WebCore clients
2875         https://bugs.webkit.org/show_bug.cgi?id=121699
2876
2877         Reviewed by Darin Adler.
2878
2879         * WebCore.xcodeproj/project.pbxproj: Added a Scripts group with a reference to
2880         extract-localizable-strings.pl. Added a Copy Scripts build phase to the WebCore target that
2881         copies the script into PrivateHeaders/Scripts in the framework.
2882         * extract-localizable-strings.pl: Copied from Tools/Scripts/extract-localizable-strings.
2883
2884 2013-09-20  Antti Koivisto  <antti@apple.com>
2885
2886         Move layer hierarchy functions from RenderObject to RenderElement
2887         https://bugs.webkit.org/show_bug.cgi?id=121692
2888
2889         Reviewed by Andreas Kling.
2890
2891         * rendering/RenderElement.cpp:
2892         (WebCore::RenderElement::addLayers):
2893         (WebCore::RenderElement::removeLayers):
2894         (WebCore::RenderElement::moveLayers):
2895         (WebCore::RenderElement::findNextLayer):
2896         (WebCore::RenderElement::layerCreationAllowedForSubtree):
2897         
2898             Move these from RenderObject.
2899
2900         (WebCore::RenderElement::insertedIntoTree):
2901         (WebCore::RenderElement::willBeRemovedFromTree):
2902         
2903             Factor the layer related portion of these virtuals here.
2904
2905 2013-09-20  Benjamin Poulain  <benjamin@webkit.org>
2906
2907         Start cleaning the API of SelectorChecker
2908         https://bugs.webkit.org/show_bug.cgi?id=121654
2909
2910         Reviewed by Antti Koivisto.
2911
2912         Make the matching mode internal.
2913         Remove unused accessors.
2914         Make isFrameFocused() internal.
2915
2916         * css/ElementRuleCollector.cpp:
2917         (WebCore::ElementRuleCollector::ruleMatches):
2918         * css/SelectorChecker.cpp:
2919         (WebCore::SelectorChecker::matchRecursively):
2920         (WebCore::SelectorChecker::checkOne):
2921         (WebCore::isFrameFocused):
2922         * css/SelectorChecker.h:
2923         (WebCore::SelectorChecker::match):
2924         * css/StyleResolver.h:
2925         (WebCore::checkRegionSelector):
2926         * dom/SelectorQuery.cpp:
2927         (WebCore::SelectorDataList::selectorMatches):
2928
2929 2013-09-20  Benjamin Poulain  <benjamin@webkit.org>
2930
2931         Remove SelectorChecker's CrossesBoundary boundary mode
2932         https://bugs.webkit.org/show_bug.cgi?id=121653
2933
2934         Reviewed by Antti Koivisto.
2935
2936         This mode is an ancient vestige of shadow dom.
2937
2938         * css/SelectorChecker.cpp:
2939         (WebCore::SelectorChecker::match):
2940         (WebCore::SelectorChecker::checkOne):
2941         * css/SelectorChecker.h:
2942
2943 2013-09-20  Benjamin Poulain  <benjamin@webkit.org>
2944
2945         Move the SharingRules mode outside of SelectorChecker
2946         https://bugs.webkit.org/show_bug.cgi?id=121652
2947
2948         Reviewed by Antti Koivisto.
2949
2950         The SharingRules handling inside SelectorChecker is a weird hack
2951         to hit a specific branch of ElementRuleCollector.
2952
2953         This patch moves the exception to ElementRuleCollector, where it is easier
2954         to understand what it is for.
2955
2956         * css/ElementRuleCollector.cpp:
2957         (WebCore::ElementRuleCollector::doCollectMatchingRulesForList):
2958         * css/SelectorChecker.cpp:
2959         (WebCore::SelectorChecker::match):
2960
2961 2013-09-20  Yoav Weiss  <yoav@yoav.ws>
2962
2963         Fixed img src URLS with multiple spaces
2964         https://bugs.webkit.org/show_bug.cgi?id=121592
2965
2966         Reviewed by Darin Adler.
2967
2968         Test: fast/loader/image-src-multiple-space.html
2969
2970         I've removed the simplifyWhiteSpace step from HTMLImageElement's src attribute during the srcset selection algorithm.
2971         That step prevented URLs with multiple spaces from being loaded as images, minimizing the multiple spaces into a single one.
2972
2973         * html/parser/HTMLParserIdioms.cpp:
2974         (WebCore::bestFitSourceForImageAttributes):
2975
2976 2013-09-20  Arunprasad Rajkumar  <ararunprasad@gmail.com>
2977
2978         Hiding a focused element should unfocus it and fire a blur event
2979         https://bugs.webkit.org/show_bug.cgi?id=29241
2980
2981         Reviewed by Darin Adler.
2982
2983         Test: fast/dom/HTMLDocument/active-element-gets-unfocusable.html
2984
2985         We check whether the current focus element is really focusable after
2986         the style recalculation and layout change. If it is not focusable then schedule a
2987         timer to reset it asynchronously.
2988
2989         * dom/Document.cpp:
2990         (WebCore::Document::Document):
2991         (WebCore::Document::recalcStyle): Check isFocusable() on the focus element after
2992         style recalculation.
2993         (WebCore::Document::updateLayout): Check isFocusable() on the focus element after
2994         layout.
2995         (WebCore::Document::resetHiddenFocusElementSoon):
2996         (WebCore::Document::resetHiddenFocusElementTimer):
2997         * dom/Document.h:
2998
2999 2013-09-20  Alexey Proskuryakov  <ap@apple.com>
3000
3001         REGRESSION (r156140): Srcset tests are frequently crashing
3002         https://bugs.webkit.org/show_bug.cgi?id=121695
3003
3004         Reviewed by Dean Jackson.
3005
3006         Returning a string created without copying bytes is not safe. It used to be OK
3007         because a new string was immediately created by decodeURLEscapeSequences().
3008         But even that was not great, because decodeURLEscapeSequences() could potentially
3009         return the same string, not a deep copy, if we decided to optimize it like that.
3010
3011         Also made a number of drive-by style fixes.
3012         - It's URL, not Url.
3013         - It's srcset, not srcSet.
3014         -  We don't add ".0" in floating point value initializers. It's particularly misleading
3015         to initialize a float with 1.0, which is a double value.
3016         - Renamed srcSetLength to srcsetAttributeLength to match srcsetAttribute variable
3017         whose length it caches.
3018
3019         * html/parser/HTMLParserIdioms.cpp:
3020         (WebCore::parseImagesWithScaleFromSrcsetAttribute):
3021         (WebCore::bestFitSourceForImageAttributes):
3022
3023 2013-09-19  Martin Robinson  <mrobinson@igalia.com>
3024
3025         [GTK] Clean up the Skip* functions in the GObject DOM bindings code generator
3026         https://bugs.webkit.org/show_bug.cgi?id=121633
3027
3028         Reviewed by Gustavo Noronha Silva.
3029
3030         * bindings/scripts/CodeGeneratorGObject.pm:
3031         (SkipAttribute): Fold in some skipping checks that are used by all callers.
3032         (SkipFunction): Ditto.
3033         (GenerateProperties): Rely on SkipAttribute more thoroughly.
3034         (GenerateFunction): Rely on SkipFunction more thoroughly.
3035         (GenerateFunctions): Rely on SkipAttribute more thoroughly.
3036
3037 2013-09-20  Patrick Gansterer  <paroga@webkit.org>
3038
3039         Fix the build after r156144
3040
3041         * html/canvas/CanvasRenderingContext2D.cpp: Added missing include.
3042
3043 2013-09-20  Ryosuke Niwa  <rniwa@webkit.org>
3044
3045         renderStyleOfEnclosingTextNode should update style before using a renderer
3046         https://bugs.webkit.org/show_bug.cgi?id=121690
3047
3048         Reviewed by Enrica Casucci.
3049
3050         Merge https://chromium.googlesource.com/chromium/blink/+/65f089545e8c18cb268dfcbe56cba1cd8045527a
3051
3052         When accessing a renderer editing should always make sure that the style has been updated for the node.
3053         Editing calls splitTextNode in a number of places and then accesses the renderer later. This patch is
3054         the first of many to make sure editing always updates the style before attempting to access the renderer
3055         (or style) of a node after calling a mutation method.
3056
3057         * editing/ApplyBlockElementCommand.cpp:
3058         (WebCore::ApplyBlockElementCommand::renderStyleOfEnclosingTextNode):
3059         * editing/ApplyBlockElementCommand.h:
3060
3061 2013-09-20  Darin Adler  <darin@apple.com>
3062
3063         Fix a couple more CSS leaks
3064         https://bugs.webkit.org/show_bug.cgi?id=121683
3065
3066         Reviewed by Alexey Proskuryakov.
3067
3068         * css/CSSDefaultStyleSheets.cpp:
3069         (WebCore::CSSDefaultStyleSheets::viewSourceStyle): Put the result of the
3070         parseUASheet into a global variable so it doesn't show up as a storage leak.
3071
3072         * css/CSSGrammar.y.in: Added a missing adoptRef. This was leaking any rule
3073         we parsed individually.
3074
3075 2013-09-20  Bem Jones-Bey  <bjonesbe@adobe.com>
3076
3077         Simplify the ShapeOutsideInfo and ShapeInfo interfaces
3078         https://bugs.webkit.org/show_bug.cgi?id=121685
3079
3080         Reviewed by Darin Adler.
3081
3082         With the creation ShapeInfo::computeSegmentsForLine, it became possible to
3083         simplify the ShapeInfo classes. ShapeOutsideInfo has no need to save the
3084         segments, and now that segment creation is in its own method, it doesn't have
3085         to save the segments anymore. This also simplifies the public interface of
3086         ShapeOutsideInfo, as it only has one method to do the computation.
3087
3088         Also, the methods in ShapeOutsideInfo have been renamed to reflect the fact
3089         that ShapeOutsideInfo isn't really interested in segments.
3090
3091         No new tests, no new behavior.
3092
3093         * rendering/FloatingObjects.cpp:
3094         (WebCore::FloatingObjects::logicalLeftOffset):
3095         (WebCore::FloatingObjects::logicalRightOffset):
3096         * rendering/LineWidth.cpp:
3097         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
3098         * rendering/shapes/ShapeInfo.cpp:
3099         * rendering/shapes/ShapeInfo.h:
3100         * rendering/shapes/ShapeInsideInfo.h:
3101         * rendering/shapes/ShapeOutsideInfo.cpp:
3102         (WebCore::ShapeOutsideInfo::updateDeltasForContainingBlockLine):
3103         * rendering/shapes/ShapeOutsideInfo.h:
3104
3105 2013-09-20  Antonio Gomes  <a1.gomes@sisa.samsung.com>
3106
3107         Making tests added in r156157 JS-only, given that other
3108         code generators are still broken.
3109
3110         Original bug 121305 (StrictTypeChecking extended attribute fails for methods with sequence<T>).
3111         https://bugs.webkit.org/show_bug.cgi?id=121305
3112
3113         Rubber stamped by Alexey Proskuryakov.
3114
3115         * bindings/scripts/test/TestObj.idl:
3116
3117 2013-09-20  Jacky Jiang  <zhajiang@blackberry.com>
3118
3119         [BlackBerry] Poor rendering opening a Google map short link
3120         https://bugs.webkit.org/show_bug.cgi?id=121687
3121
3122         Reviewed by Yong Li.
3123         Internally reviewed by Arvid Nilsson.
3124
3125         JIRA 495023
3126         Route lines on google map were shown even they were on a hidden canvas.
3127         Include visibility on LayerWebKitThread if it's a canvas layer and respect
3128         the visibility when compositing layers in LayerRenderer.
3129
3130         * platform/graphics/blackberry/LayerData.h:
3131         (WebCore::LayerData::isCanvasLayer):
3132         (WebCore::LayerData::isVisible):
3133         (WebCore::LayerData::includeVisibility):
3134         * platform/graphics/blackberry/LayerRenderer.cpp:
3135         (WebCore::LayerRenderer::compositeLayersRecursive):
3136
3137 2013-09-20  Sam White  <samuel_white@apple.com>
3138
3139         AX: WebArea claims to have a subrole, but always returns nil.
3140         https://bugs.webkit.org/show_bug.cgi?id=121658
3141
3142         Reviewed by Chris Fleizach.
3143
3144         No new tests, updated existing AXWebArea related test to reflect unused attribute removal.
3145
3146         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
3147         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
3148
3149 2013-09-20  Andreas Kling  <akling@apple.com>
3150
3151         Add valueForLength/minimumValueForLength wrappers to RenderElement.
3152         <https://webkit.org/b/121676>
3153
3154         Reviewed by Antti Koivisto.
3155
3156         Add two inline wrappers for these functions so we don't have to pass
3157         the RenderView everywhere.
3158
3159 2013-09-20  Martin Robinson  <mrobinson@igalia.com>
3160
3161         [GTK] Fix some small style issues in the bindings
3162         https://bugs.webkit.org/show_bug.cgi?id=121613
3163
3164         Reviewed by Carlos Garcia Campos.
3165
3166         * bindings/scripts/CodeGeneratorGObject.pm: When printing the license
3167         header use the more common comment style within the WebKit project.
3168         (GenerateProperty): Indent property definitions according to WebKit style, improve
3169         the nick and blurb properties, and improve the various parameter spec argument layout.
3170         (GenerateFunction): Remove the newline from function signatures to match WebKit style.
3171         * bindings/scripts/test/GObject: Update bindings test results.
3172
3173 2013-09-20  Patrick Gansterer  <paroga@webkit.org>
3174
3175         [CMake] Use COMPILE_DEFINITIONS target property for setting BUILDING_* defines
3176         https://bugs.webkit.org/show_bug.cgi?id=121672
3177
3178         Reviewed by Gyuyoung Kim.
3179
3180         Since the scope of add_definitions() is always a whole file, we need to use
3181         target properties instead to set definitions only for specific targets.
3182
3183         * CMakeLists.txt:
3184
3185 2013-09-18  Antonio Gomes  <a1.gomes@sisa.samsung.com>
3186
3187         Make "autoscroll for drag'n drop" a setting
3188         https://bugs.webkit.org/show_bug.cgi?id=121559
3189
3190         Reviewed by Ryosuke Niwa.
3191
3192         Currently, there is a ChromeClient hook to make the
3193         feature opt'ed-in or out. That makes it harder to test the
3194         feature on ports that do not enable it, e.g. Mac/WebKit2 port.
3195         However, Mac/WebKit2 is the port that has the best drag'n drop
3196         WTR implementation.
3197
3198         Patch changes the toggle on/off mechanism to be a setting,
3199         and exposes it through InternalSetting interface for testing.
3200
3201         * page/AutoscrollController.cpp:
3202         (WebCore::AutoscrollController::updateDragAndDrop):
3203         * page/ChromeClient.h:
3204         * page/Settings.in:
3205         * testing/InternalSettings.cpp:
3206         (WebCore::InternalSettings::Backup::Backup):
3207         (WebCore::InternalSettings::Backup::restoreTo):
3208         (WebCore::InternalSettings::setAutoscrollForDragAndDropEnabled):
3209         * testing/InternalSettings.h:
3210         * testing/InternalSettings.idl:
3211
3212 2013-09-16  Antonio Gomes  <a1.gomes@sisa.samsung.com>
3213
3214         StrictTypeChecking extended attribute fails for methods with sequence<T>
3215         https://bugs.webkit.org/show_bug.cgi?id=121305
3216
3217         Reviewed by Darin Adler.
3218
3219         The extended attribute StrictTypeChecking can not be set to methods if
3220         one of the parameters is a "sequence".
3221         Basically, since "sequence" is not considered a native type
3222         (see function IsNativeType) the Perl code generator tries to
3223         include its supposedly associated header, in this case "JSsequence.h"
3224         Compilation then fails.
3225
3226         It is a problem for bindings including WebGL, where all methods
3227         are supposed to be set as StrictTypeChecking (see bug 44202 [1]). Due to this restriction,
3228         it relaxed, but I would like to bring it back.
3229
3230         Patch fixes the issue by hardening the way includes are auto-added
3231         for methods where StrictTypeChecking extended attribute is present.
3232         Now, only wrapper types (see IsWrapperType) trigger header inclusion,
3233         excluding arrays, sequences, basic types, etc.
3234
3235         [1] https://bugs.webkit.org/show_bug.cgi?id=44202
3236
3237         * bindings/scripts/CodeGeneratorJS.pm:
3238         (GenerateParametersCheck):
3239         * bindings/scripts/test/JS/JSTestObj.cpp:
3240         (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
3241         * bindings/scripts/test/JS/JSTestObj.h:
3242         * bindings/scripts/test/TestObj.idl:
3243
3244 2013-09-20  Andreas Kling  <akling@apple.com>
3245
3246         Optimize fetching the Node for never-anonymous renderers.
3247         <https://webkit.org/b/121627>
3248
3249         Reviewed by Antti Koivisto.
3250
3251         Add a RenderObject::nodeForNonAnonymous() that can be used instead
3252         of node() when a renderer is guaranteed non-anonymous.
3253
3254         Use this to implement reference element getters for the various
3255         renderers that are known at compile-time to correspond to a DOM node.
3256
3257         Also renamed existingElement() => element() since using an alternate
3258         name for a reference overload isn't actually necessary.
3259
3260 2013-09-20  Patrick Gansterer  <paroga@webkit.org>
3261
3262         Remove duplicated secondsPerDay variables
3263         https://bugs.webkit.org/show_bug.cgi?id=121601
3264
3265         Reviewed by Andreas Kling.
3266
3267         Use secondsPerDay from DateMath.h instead of defining it again.
3268
3269         * history/HistoryItem.cpp:
3270         (WebCore::timeToDay):
3271
3272 2013-09-20  Patrick Gansterer  <paroga@webkit.org>
3273
3274         Fix duplicated loop variable names after r155743
3275         https://bugs.webkit.org/show_bug.cgi?id=121667
3276
3277         Reviewed by Andreas Kling.
3278
3279         Do not use the same name for variables in nested loops to fix a compiler warning.
3280
3281         * page/animation/CSSPropertyAnimation.cpp:
3282         (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
3283
3284 2013-09-20  Antti Koivisto  <antti@apple.com>
3285
3286         Make RenderObject::parent() return RenderElement
3287         https://bugs.webkit.org/show_bug.cgi?id=121671
3288
3289         Reviewed by Andreas Kling.
3290
3291         Make RenderObject::parent() return RenderElement and adopt everywhere.
3292         Moved addChild/removeChild from RenderObject to RenderElement.
3293         Uninlined a few big RenderObject functions.
3294         Renamed RenderObject::remove() -> RenderObject::removeFromParent()
3295
3296 2013-09-20  Csaba Osztrogon√°c  <ossy@webkit.org>
3297
3298         Buildfix after r156133 for !ENABLE(WORKERS) platforms
3299         https://bugs.webkit.org/show_bug.cgi?id=121669
3300
3301         Reviewed by Antti Koivisto.
3302
3303         * platform/ThreadGlobalData.cpp:
3304         * platform/ThreadGlobalData.h:
3305
3306 2013-09-20  Antti Koivisto  <antti@apple.com>
3307
3308         Make createRenderer() return RenderElement
3309         https://bugs.webkit.org/show_bug.cgi?id=121666
3310
3311         Rubber-stamped by Andreas Kling.
3312         
3313         Tighter typing.
3314
3315 2013-09-20  Patrick Gansterer  <paroga@webkit.org>
3316
3317         Buildfix for ENABLE(CSS_FILTERS) && !ENABLE(ACCELERATED_COMPOSITING) after r155131.
3318
3319         * rendering/RenderLayer.cpp:
3320         (WebCore::RenderLayer::enclosingFilterRepaintLayer):
3321
3322 2013-09-20  Patrick Gansterer  <paroga@webkit.org>
3323
3324         [WIN] Fix build without precompiled header after r154146.
3325
3326         * platform/win/WebCoreBundleWin.cpp:
3327
3328 2013-09-20  Antti Koivisto  <antti@apple.com>
3329
3330         Add covariant RenderElement* Element::renderer()
3331         https://bugs.webkit.org/show_bug.cgi?id=121638
3332
3333         Reviewed by Andreas Kling.
3334
3335         Also add isRenderElement() test and casting functions.
3336
3337 2013-09-19  Anders Carlsson  <andersca@apple.com>
3338
3339         Handle null font families.
3340
3341         Reviewed by Darin Adler.
3342
3343         * platform/graphics/Font.cpp:
3344         (WebCore::computeFontGlyphsCacheHash):
3345         Don't crash when trying to hash null strings.
3346
3347 2013-09-19  Darin Adler  <darin@apple.com>
3348
3349         Fix a couple mistakes in my recent CSS grammar leak patch
3350         https://bugs.webkit.org/show_bug.cgi?id=121659
3351
3352         Reviewed by Alexey Proskuryakov.
3353
3354         * css/CSSGrammar.y.in: Added initialization to nullptr for some error cases
3355         that were otherwise leaving a bad value for the result of the production.
3356         Also fixed a reversed logical expression.
3357
3358 2013-09-19  Yoav Weiss  <yoav@yoav.ws>
3359
3360         Remove URL decoding in srcset handling
3361         https://bugs.webkit.org/show_bug.cgi?id=121609
3362
3363         Reviewed by Benjamin Poulain.
3364
3365         Tests: fast/hidpi/image-srcset-question-mark.html
3366                fast/loader/image-src-question-mark.html
3367
3368         Removed URL decoding from src and srcset's handling algorithm, since they break encoded URLS.
3369
3370         * html/parser/HTMLParserIdioms.cpp:
3371         (WebCore::parseImagesWithScaleFromSrcSetAttribute):
3372         (WebCore::bestFitSourceForImageAttributes):
3373
3374 2013-09-19  Anders Carlsson  <andersca@apple.com>
3375
3376         Avoid calling AtomicString::lower() in makeFontGlyphsCacheKey
3377         https://bugs.webkit.org/show_bug.cgi?id=121656
3378
3379         Reviewed by Darin Adler.
3380
3381         Instead of lower casing AtomicStrings, store the strings as is and use the case folding
3382         hash and case insensitive compare to determine equality.
3383
3384         * platform/graphics/Font.cpp:
3385         (WebCore::operator==):
3386         (WebCore::makeFontGlyphsCacheKey):
3387         (WebCore::computeFontGlyphsCacheHash):
3388
3389 2013-09-19  Darin Adler  <darin@apple.com>
3390
3391         Fix leaks in CSS parser caused by overwriting owned raw pointers with 0
3392         https://bugs.webkit.org/show_bug.cgi?id=121655
3393
3394         Reviewed by Anders Carlsson.
3395
3396         * css/CSSGrammar.y.in: Use nullptr instead of 0. Use unique_ptr instead
3397         of a raw pointer in cases where we might or might not actually keep
3398         the allocated memory. This can still be cleaned up further, but this
3399         should fix the memory leaks we have been seeing.
3400
3401 2013-09-19  Eric Carlson  <eric.carlson@apple.com>
3402
3403         MediaStream API: update MediaStreamTrackEvent object to match spec
3404         https://bugs.webkit.org/show_bug.cgi?id=121624
3405
3406         Reviewed by Dean Jackson.
3407
3408         Test: fast/mediastream/MediaStreamTrackEvent-constructor.html
3409
3410         * Modules/mediastream/MediaStreamTrack.idl: Remove NoInterfaceObject.
3411
3412         * Modules/mediastream/MediaStreamTrackEvent.cpp: 
3413         (WebCore::MediaStreamTrackEventInit::MediaStreamTrackEventInit): New.
3414         (WebCore::MediaStreamTrackEvent::create): New form that takes an initialize.
3415         (WebCore::MediaStreamTrackEvent::MediaStreamTrackEvent): Ditto.
3416         * Modules/mediastream/MediaStreamTrackEvent.h:
3417         * Modules/mediastream/MediaStreamTrackEvent.idl:
3418
3419         * bindings/js/JSDictionary.cpp:
3420         (WebCore::JSDictionary::convertValue): New.
3421         * bindings/js/JSDictionary.h:
3422
3423 2013-09-19  Anders Carlsson  <andersca@apple.com>
3424
3425         Remove #if !ENABLE(WORKERS) code in ThreadGlobalData
3426         https://bugs.webkit.org/show_bug.cgi?id=121649
3427
3428         Reviewed by Sam Weinig.
3429
3430         This lets us remove a FIXME. Also, move threadGlobalData out of line; there's no need for it to be inline.
3431
3432         * WebCore.exp.in:
3433         * platform/ThreadGlobalData.cpp:
3434         (WebCore::threadGlobalData):
3435         * platform/ThreadGlobalData.h:
3436
3437 2013-09-19  Anders Carlsson  <andersca@apple.com>
3438
3439         Modernize Length setters/getters
3440         https://bugs.webkit.org/show_bug.cgi?id=121647
3441
3442         Reviewed by Andreas Kling.
3443
3444         Add a move constructor and move assignment operator to Length and fixup some of the getters and setters.
3445
3446         * css/CSSComputedStyleDeclaration.cpp:
3447         (WebCore::getBorderRadiusCornerValues):
3448         (WebCore::getBorderRadiusCornerValue):
3449         * css/DeprecatedStyleBuilder.cpp:
3450         (WebCore::ApplyPropertyLength::setValue):
3451         (WebCore::ApplyPropertyLength::createHandler):
3452         (WebCore::ApplyPropertyBorderRadius::setValue):
3453         (WebCore::ApplyPropertyBorderRadius::createHandler):
3454         (WebCore::ApplyPropertyLineHeight::createHandler):
3455         * page/animation/CSSPropertyAnimation.cpp:
3456         (WebCore::LengthPropertyWrapper::LengthPropertyWrapper):
3457         (WebCore::LengthPropertyWrapper::blend):
3458         (WebCore::FillLayerPropertyWrapper::FillLayerPropertyWrapper):
3459         (WebCore::FillLayerPropertyWrapper::blend):
3460         (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
3461         * platform/CalculationValue.h:
3462         (WebCore::CalcExpressionLength::CalcExpressionLength):
3463         (WebCore::CalcExpressionBlendLength::CalcExpressionBlendLength):
3464         * platform/Length.cpp:
3465         (WebCore::CalculationValueHandleMap::remove):
3466         (WebCore::CalculationValueHandleMap::find):
3467         (WebCore::Length::decrementCalculatedRef):
3468         * platform/Length.h:
3469         (WebCore::Length::Length):
3470         (WebCore::Length::operator=):
3471         (WebCore::Length::moveFromLength):
3472         * platform/LengthBox.cpp:
3473         (WebCore::LengthBox::logicalLeft):
3474         (WebCore::LengthBox::logicalRight):
3475         (WebCore::LengthBox::before):
3476         (WebCore::LengthBox::after):
3477         (WebCore::LengthBox::start):
3478         (WebCore::LengthBox::end):
3479         * platform/LengthBox.h:
3480         (WebCore::LengthBox::LengthBox):
3481         (WebCore::LengthBox::left):
3482         (WebCore::LengthBox::right):