14366e905cf95f73ccb3830bb85cbefc3ee79aa1
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-04-19  Benjamin Poulain  <benjamin@webkit.org>
2
3         Use Vector instead of StringBuilder for CSSPreloadScanner's buffers
4         https://bugs.webkit.org/show_bug.cgi?id=114794
5
6         Reviewed by Ryosuke Niwa.
7
8         Cleanup for other String changes.
9
10         CSSPreloadScanner only handles UChar, StringBuilder was a little
11         overkill.
12
13         * html/parser/CSSPreloadScanner.cpp:
14         (WebCore):
15         (WebCore::ruleEqualIgnoringCase):
16         (WebCore::CSSPreloadScanner::emitRule):
17         * html/parser/CSSPreloadScanner.h:
18
19 2013-04-19  Benjamin Poulain  <benjamin@webkit.org>
20
21         StyledMarkupAccumulator::appendText() should not allocate an intermediary StringBuilder
22         https://bugs.webkit.org/show_bug.cgi?id=114847
23
24         Reviewed by Geoffrey Garen.
25
26         For some reason StyledMarkupAccumulator::appendText() was allocating a separate buffer
27         for invoking appendStyleNodeOpenTag. This is a bad idea.
28
29         * editing/markup.cpp:
30         (WebCore::StyledMarkupAccumulator::appendStyleNodeOpenTag):
31         (WebCore::StyledMarkupAccumulator::appendText):
32
33 2013-04-19  Joseph Pecoraro  <pecoraro@apple.com>
34
35         Web Inspector: Support the SourceMap header, X-SourceMap was deprecated
36         https://bugs.webkit.org/show_bug.cgi?id=114888
37
38         Check first for SourceMap, then fallback to X-SourceMap. Leaving in
39         support for the deprecated header because most tools and articles
40         online mention that version and have not yet updated.
41
42         Reviewed by Timothy Hatcher.
43
44         * inspector/InspectorDebuggerAgent.cpp:
45         (WebCore::InspectorDebuggerAgent::sourceMapURLForScript):
46         * inspector/InspectorPageAgent.cpp:
47         (WebCore::InspectorPageAgent::sourceMapURLForResource):
48
49 2013-04-19  Joseph Pecoraro  <pecoraro@apple.com>
50
51         Web Inspector: Backend should detect sourceMappingURLs in CSS Resources
52         https://bugs.webkit.org/show_bug.cgi?id=114854
53
54         Reviewed by Timothy Hatcher.
55
56         Test: http/tests/inspector/network/css-source-mapping-url.html
57
58         * inspector/Inspector.json:
59         - Page.getResourceTree - add sourceMapURL to resource payloads
60         - Network.loadingFinished and Network.requestServedFromMemoryCache,
61           include the sourceMapURL in the results.
62
63         * inspector/ContentSearchUtils.h:
64         * inspector/ContentSearchUtils.cpp:
65         (WebCore::ContentSearchUtils::scriptCommentPattern):
66         (WebCore::ContentSearchUtils::stylesheetCommentPattern):
67         (WebCore::ContentSearchUtils::findMagicComment):
68         (WebCore::ContentSearchUtils::findScriptSourceURL):
69         (WebCore::ContentSearchUtils::findScriptSourceMapURL):
70         (WebCore::ContentSearchUtils::findStylesheetSourceMapURL):
71         Separate Script and Stylesheet regex pattern creation, but
72         share the search function using the pattern.
73
74         * inspector/InspectorDebuggerAgent.cpp:
75         (WebCore::InspectorDebuggerAgent::sourceMapURLForScript):
76         (WebCore::InspectorDebuggerAgent::didParseSource):
77         Update function names. Check for the SourceMap header before
78         checking for a sourceMappingURL comment.
79
80         * inspector/InspectorPageAgent.h:
81         * inspector/InspectorPageAgent.cpp:
82         (WebCore::InspectorPageAgent::sourceMapURLForResource):
83         (WebCore::InspectorPageAgent::buildObjectForFrameTree):
84         Provide the sourceMapURL for Page.getResourceTree.
85
86         * inspector/InspectorResourceAgent.cpp:
87         (WebCore::buildObjectForCachedResource):
88         (WebCore::InspectorResourceAgent::didFinishLoading):
89         (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache):
90         Include sourceMapURLs in finish loading and request served from cache.
91
92 2013-04-19  Shawn Singh  <shawnsingh@chromium.org>
93
94         Remove non-overlap testing code in RenderLayerCompositor
95         https://bugs.webkit.org/show_bug.cgi?id=85521
96
97         Reviewed by Simon Fraser.
98
99         m_compositingConsultsOverlap is always true in the current
100         code. This patch removes this flag, and removes dead code that is
101         never executed because it was never false.
102
103         No new tests, no change in behavior.  The cleanup is covered by
104         existing tests.
105
106         * rendering/RenderLayer.cpp:
107         (WebCore::RenderLayer::updateCompositingLayersAfterScroll):
108         removed if-statement that is always true.
109         
110         * rendering/RenderLayerBacking.cpp:
111         (WebCore::RenderLayerBacking::shouldClipCompositedBounds):
112         removed if-statement that would never get triggered.
113
114         * rendering/RenderLayerCompositor.cpp:
115         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
116         (WebCore::RenderLayerCompositor::updateCompositingLayers):
117         removed m_compositingConsultsOverlap, and retained the code as if the flag were "true".
118         
119         * rendering/RenderLayerCompositor.h:
120         (RenderLayerCompositor):
121
122 2013-04-19  Roger Fong  <roger_fong@apple.com>
123
124         Unreviewed. WebKit_Source is incorrectly set.
125
126         * WebCore.vcxproj/WebCore.make:
127
128 2013-04-18  Ryosuke Niwa  <rniwa@webkit.org>
129
130         Make loops in RenderObject::containingBlock homogeneous in their forms to simplify
131         https://bugs.webkit.org/show_bug.cgi?id=114853
132
133         Reviewed by David Hyatt.
134
135         This patch prepares us to avoid computing containing blocks during a depth-first traversal of the render tree.
136
137         Extracted inline functions out of RenderBlock::containingBlock to make the code simpler. Also moved the code
138         to obtain the nearest containing block out of the loop for a relatively positioned inline.
139
140         * rendering/RenderObject.cpp:
141         (WebCore::isNonReplacedInlineInFlowPosition): Extracted.
142         (WebCore::isContainingBlockCandidateForAbsolutelyPositionedObject): Extracted.
143         (WebCore::isNonRenderBlockInline): Extracted.
144         (WebCore::RenderObject::containingBlock): Refactored as stated above.
145
146 2013-04-19  Tim Horton  <timothy_horton@apple.com>
147
148         WebKit should not decode or support PDF favicons
149         https://bugs.webkit.org/show_bug.cgi?id=114650
150         <rdar://problem/10133914>
151
152         Reviewed by Dan Bernstein.
153
154         Drop the image data on the floor if it begins with the PDF magic number.
155         No other browser I can find on OS X supports PDF favicons (by experimentation),
156         and we do not properly display them.
157
158         * loader/icon/IconLoader.cpp:
159         (WebCore::IconLoader::notifyFinished):
160
161 2013-04-19  Martin Robinson  <mrobinson@igalia.com>
162
163         Remove the OpenVG backend
164         https://bugs.webkit.org/show_bug.cgi?id=114881
165
166         Reviewed by Tim Horton.
167
168         * platform/graphics/FloatRect.h:
169         (FloatRect): Remove #ifdefs for OpenVG backend.
170         * platform/graphics/GraphicsContext.cpp:
171         (WebCore): Ditto.
172         * platform/graphics/GraphicsContext.h:
173         * platform/graphics/NativeImagePtr.h:
174         (WebCore): Ditto.
175         * platform/graphics/Path.cpp:
176         (WebCore): Ditto.
177         * platform/graphics/Path.h:
178         * platform/graphics/openvg/EGLDisplayOpenVG.cpp: Removed.
179         * platform/graphics/openvg/EGLDisplayOpenVG.h: Removed.
180         * platform/graphics/openvg/EGLUtils.h: Removed.
181         * platform/graphics/openvg/GraphicsContextOpenVG.cpp: Removed.
182         * platform/graphics/openvg/ImageOpenVG.cpp: Removed.
183         * platform/graphics/openvg/PainterOpenVG.cpp: Removed.
184         * platform/graphics/openvg/PainterOpenVG.h: Removed.
185         * platform/graphics/openvg/PathOpenVG.cpp: Removed.
186         * platform/graphics/openvg/PlatformPathOpenVG.h: Removed.
187         * platform/graphics/openvg/SharedResourceOpenVG.cpp: Removed.
188         * platform/graphics/openvg/SharedResourceOpenVG.h: Removed.
189         * platform/graphics/openvg/SurfaceOpenVG.cpp: Removed.
190         * platform/graphics/openvg/SurfaceOpenVG.h: Removed.
191         * platform/graphics/openvg/TiledImageOpenVG.cpp: Removed.
192         * platform/graphics/openvg/TiledImageOpenVG.h: Removed.
193         * platform/graphics/openvg/VGUtils.cpp: Removed.
194         * platform/graphics/openvg/VGUtils.h: Removed.
195         * platform/graphics/transforms/AffineTransform.h:
196         (AffineTransform): Ditto.
197         * platform/graphics/transforms/TransformationMatrix.h:
198         (TransformationMatrix): Ditto.
199         * platform/image-decoders/openvg/ImageDecoderOpenVG.cpp: Removed.
200
201 2013-04-19  Andrei Bucur  <abucur@adobe.com>
202
203         ContainerNode::removeChildren should first detach the children then remove them
204         https://bugs.webkit.org/show_bug.cgi?id=113433
205
206         Reviewed by Ryosuke Niwa.
207
208         Currently, ContainerNode::removeChildren initially removes the nodes from the DOM tree and then
209         calls detach() on each of them. This is anti-intuitive and can lead to subtle bugs because the
210         detached renderers are not backed by a valid DOM tree any more. With the patch, the nodes are first
211         detached and then removed from the DOM.
212         The patch also lets the tree in a consistent state after each node removal by clearing the previous
213         sibling pointer of the node following the one removed.
214         I haven't found any proof the performance will get worse if the detachment happens when the children
215         are still in the DOM tree.
216
217         Tests: No changed visible functionality.
218
219         * dom/ContainerNode.cpp:
220         (WebCore::ContainerNode::removeChildren):
221
222 2013-04-19  Dirk Schulze  <krit@webkit.org>
223
224         Refactor transform code in StyleResolver
225         https://bugs.webkit.org/show_bug.cgi?id=114874
226
227         Reviewed by Andreas Kling.
228
229         Move transform code frome StyleResolver into own files.
230
231         Refactoring, no changes in functionality.
232
233         * CMakeLists.txt:
234         * GNUmakefile.list.am:
235         * Target.pri:
236         * WebCore.vcproj/WebCore.vcproj:
237         * WebCore.vcxproj/WebCore.vcxproj:
238         * WebCore.vcxproj/WebCore.vcxproj.filters:
239         * WebCore.xcodeproj/project.pbxproj:
240         * css/StyleResolver.cpp:
241         (WebCore::StyleResolver::applyProperty):
242         (WebCore::StyleResolver::parseCustomFilterTransformParameter):
243         * css/StyleResolver.h:
244         * css/TransformFunctions.cpp: Added.
245         (WebCore):
246         (WebCore::transformOperationType):
247         (WebCore::convertToFloatLength):
248         (WebCore::transformsForValue):
249         * css/TransformFunctions.h: Added.
250         (WebCore):
251         * css/WebKitCSSMatrix.cpp:
252         (WebCore::WebKitCSSMatrix::setMatrixValue):
253
254 2013-04-19  Erik Arvidsson  <arv@chromium.org>
255
256         Rename TextTrackList owner to element for consistency
257         https://bugs.webkit.org/show_bug.cgi?id=79822
258
259         Reviewed by Eric Carlson.
260
261         No new tests. Covered by existing tests.
262
263         * bindings/js/JSTextTrackListCustom.cpp:
264         (WebCore::JSTextTrackListOwner::isReachableFromOpaqueRoots):
265         (WebCore::JSTextTrackList::visitChildren):
266         * html/HTMLMediaElement.cpp:
267         (WebCore::HTMLMediaElement::~HTMLMediaElement):
268         * html/track/TextTrackList.cpp:
269         (TextTrackList::append):
270         (TextTrackList::remove):
271         * html/track/TextTrackList.h:
272         (WebCore::TextTrackList::create):
273         * html/track/TrackListBase.cpp:
274         (TrackListBase::TrackListBase):
275         (TrackListBase::remove):
276         * html/track/TrackListBase.h:
277         (WebCore::TrackListBase::clearElement):
278         (WebCore::TrackListBase::element):
279         (TrackListBase):
280
281 2013-04-19  Andreas Kling  <akling@apple.com>
282
283         [Mac] ComplexTextController is slow with large numbers of text runs.
284         <http://webkit.org/b/114875>
285         <rdar://problem/13337036>
286
287         Reviewed by Dan Bernstein.
288
289         Instead of iterating over the text runs in indexOfCurrentRun() to figure out the leftmost glyph,
290         create a lookup table of [run# -> distance in glyphs] at ComplexTextController construction time.
291
292         This avoids O(n^2) behavior in indexOfCurrentRun().
293
294         * platform/graphics/mac/ComplexTextController.cpp:
295         (WebCore::ComplexTextController::ComplexTextController):
296         (WebCore::ComplexTextController::indexOfCurrentRun):
297         * platform/graphics/mac/ComplexTextController.h:
298         (ComplexTextController):
299
300 2013-04-19  Mario Sanchez Prada  <mario.prada@samsung.com>
301
302         [GTK] Minimize calls to GailTextUtil in AtkText implementation
303         https://bugs.webkit.org/show_bug.cgi?id=114868
304
305         Reviewed by Martin Robinson.
306
307         Create a new helper function to concentrate inside of it the calls to
308         gail_text_util_get_text(), so we can get rid of it later more easily.
309
310         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
311         (webkitAccessibleTextGetTextForOffset): New helper function.
312         (webkitAccessibleTextGetTextAfterOffset): Rely on the new function.
313         (webkitAccessibleTextGetTextAtOffset): Ditto.
314         (webkitAccessibleTextGetTextBeforeOffset): Ditto.
315
316 2013-04-19  Noam Rosenthal  <noam@webkit.org>
317
318         [Texmap] Implementation for pattern compositing
319         https://bugs.webkit.org/show_bug.cgi?id=109588
320
321         Reviewed by Allan Sandfeld Jensen.
322
323         Enable pattern compositing (background images) for CoordinatedGraphics/TextureMapperGL.
324         Use the existing patternTransform shader uniform, multiplying it by a matrix calculated
325         using the contentsRect, tileSize and tilePhase.
326
327         Covered by existing tests in compositing/patterns.
328
329         * platform/graphics/GraphicsLayer.h:
330         (GraphicsLayer):
331             Conditionally enable pattern compositing for coordinated graphics.
332
333         * platform/graphics/texmap/TextureMapper.cpp:
334         (WebCore::TextureMapper::TextureMapper):
335         * platform/graphics/texmap/TextureMapper.h:
336         (WebCore::TextureMapper::setPatternTransform):
337         (WebCore::TextureMapper::setWrapMode):
338         (WebCore::TextureMapper::wrapMode):
339         (WebCore::TextureMapper::patternTransform):
340             Add wrapMode and patternTransform properties to the TextureMapper state.
341
342         * platform/graphics/texmap/TextureMapperGL.cpp:
343         (WebCore::TextureMapperGL::drawTexturedQuadWithProgram):
344             Paint with GL_REPEAT and a pattern transform when needed.
345
346         * platform/graphics/texmap/TextureMapperLayer.cpp:
347         (WebCore::TextureMapperLayer::computePatternTransformIfNeeded):
348         (WebCore):
349         (WebCore::TextureMapperLayer::paintSelf):
350         (WebCore::TextureMapperLayer::setContentsRect):
351         (WebCore::TextureMapperLayer::setContentsTileSize):
352         (WebCore::TextureMapperLayer::setContentsTilePhase):
353             Apply the patternTransform from the tile size/phase.
354
355         * platform/graphics/texmap/TextureMapperLayer.h:
356         (WebCore::TextureMapperLayer::TextureMapperLayer):
357         (TextureMapperLayer):
358         (WebCore::TextureMapperLayer::setShouldMapBackingStoreToContentsRect):
359         (State):
360         (WebCore::TextureMapperLayer::State::State):
361             Allow the client to configure whether a layer uses its bounds or its
362             contents rect to paint the backing store.
363             This is needed now since layers with background images, unlike layers
364             with regular images, may have bounds that are greater than the contents
365             rect.
366
367         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
368         (WebCore::CoordinatedGraphicsLayer::setContentsTileSize):
369         (WebCore):
370         (WebCore::CoordinatedGraphicsLayer::setContentsTilePhase):
371         (WebCore::CoordinatedGraphicsLayer::setShouldSupportContentsTiling):
372         (WebCore::GraphicsLayer::supportsContentsTiling):
373         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
374         (CoordinatedGraphicsLayer):
375         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
376         (WebCore::CoordinatedGraphicsScene::setLayerState):
377         (WebCore::CoordinatedGraphicsScene::assignImageBackingToLayer):
378         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
379         (CoordinatedGraphicsLayerState):
380             Logic to pass the tileSize/tilePhase from CoordinatedGraphicsLayer
381             to TextureMapperLayer.
382
383         * rendering/RenderLayerBacking.cpp:
384         (WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundImage):
385             Don't reset the layer's image contents when this is a directly composited image.
386
387 2013-04-19  ChangSeok Oh  <changseok.oh@collabora.com>
388
389         [GTK][AC] Manage actor's children by using clutter's own way.
390         https://bugs.webkit.org/show_bug.cgi?id=114257
391
392         Reviewed by Gustavo Noronha Silva.
393
394         I believe we don't need to maintain a children list of GList. We can do it
395         by using clutter APIs like clutter_actor_get_children, clutter_actor_get_first_child, etc.
396
397         No new tests since no functionality changed.
398
399         * platform/graphics/clutter/GraphicsLayerActor.cpp:
400         (graphics_layer_actor_init):
401         (graphicsLayerActorAllocate):
402         (graphicsLayerActorPaint):
403         (graphicsLayerActorRemoveAll):
404         (graphicsLayerActorGetnChildren):
405         (graphicsLayerActorReplaceSublayer):
406         (graphicsLayerActorInsertSublayer):
407         * platform/graphics/clutter/GraphicsLayerActor.h:
408         (_GraphicsLayerActor):
409
410 2013-04-19  ChangSeok Oh  <changseok.oh@collabora.com>
411
412         [GTK][AC] Support masksToBounds for clutter AC backend.
413         https://bugs.webkit.org/show_bug.cgi?id=114113
414
415         Reviewed by Gustavo Noronha Silva.
416
417         We can support the masksToBounds property by using clutter_actor_set_clip simply.
418
419         Covered by existing AC tests.
420
421         * platform/graphics/clutter/GraphicsLayerActor.cpp:
422         (graphicsLayerActorSetMasksToBounds):
423         * platform/graphics/clutter/GraphicsLayerActor.h:
424         * platform/graphics/clutter/GraphicsLayerClutter.cpp:
425         (WebCore::GraphicsLayerClutter::setMasksToBounds):
426         (WebCore):
427         (WebCore::GraphicsLayerClutter::commitLayerChangesBeforeSublayers):
428         (WebCore::GraphicsLayerClutter::setupContentsLayer):
429         (WebCore::GraphicsLayerClutter::updateMasksToBounds):
430         * platform/graphics/clutter/GraphicsLayerClutter.h:
431         (GraphicsLayerClutter):
432
433 2013-04-19  Dan Beam  <dbeam@chromium.org>
434
435         Remove unmaintained feature REQUEST_AUTOCOMPLETE
436         https://bugs.webkit.org/show_bug.cgi?id=114846
437
438         Reviewed by Kent Tamura.
439
440         * GNUmakefile.list.am: Remove AutocompleteErrorEvent.h include.
441         * bindings/generic/RuntimeEnabledFeatures.cpp:
442         (WebCore): Remove requestAutocomplete() runtime feature.
443         * bindings/generic/RuntimeEnabledFeatures.h:
444         (RuntimeEnabledFeatures): Remove requestAutocomplete() runtime feature.
445         * dom/AutocompleteErrorEvent.h: Removed.
446         * dom/AutocompleteErrorEvent.idl: Removed.
447         * dom/EventNames.h: Remove `autocomplete` and `autocompleteerror` event names.
448         (WebCore):
449         * dom/EventNames.in: Remove `autocomplete` and `autocompleteerror` event names.
450         * html/HTMLAttributeNames.in: Remove `onautocomplete` and `onautocompleteerror` form attributes.
451         * html/HTMLFormElement.cpp: Remove requestAutocomplete() related code.
452         (WebCore::HTMLFormElement::HTMLFormElement): Remove timer and event queue for requestAutocomplete() related events.
453         (WebCore::HTMLFormElement::parseAttribute): Remove parsing of `onautocomplete` and `onautocompleterror`.
454         * html/HTMLFormElement.h: Remove requestAutocomplete() related members.
455         (HTMLFormElement):
456         * html/HTMLFormElement.idl: Remove public requestAutocomplete() API method.
457         * loader/EmptyClients.cpp: Remove stub implementation.
458         (WebCore):
459         * loader/EmptyClients.h: Remove stub interface.
460         (EmptyFrameLoaderClient):
461         * loader/FrameLoaderClient.h: Remove didRequestAutocomplete() from interface.
462         (FrameLoaderClient):
463         * page/DOMWindow.idl: Remove `AutocompleteErrorEvent` from window DOM interface.
464
465 2013-04-18  Timothy Hatcher  <timothy@apple.com>
466
467         Add CSS.setStyleText to the Web Inspector protocol.
468
469         This provides a direct path for the Safari Web Inspector to live edit whole style rules.
470
471         https://webkit.org/b/109340
472         rdar://problem/13337211
473
474         Reviewed by Joseph Pecoraro.
475
476         * inspector/Inspector.json:
477         (CSS.setStyleText): Added.
478         * inspector/InspectorCSSAgent.cpp:
479         (InspectorCSSAgent::SetStyleTextAction):
480         (WebCore::InspectorCSSAgent::SetStyleTextAction::SetStyleTextAction): Added.
481         (WebCore::InspectorCSSAgent::SetStyleTextAction::perform): Added.
482         (WebCore::InspectorCSSAgent::SetStyleTextAction::undo): Added.
483         (WebCore::InspectorCSSAgent::SetStyleTextAction::redo): Added.
484         (WebCore::InspectorCSSAgent::SetStyleTextAction::mergeId): Added.
485         (WebCore::InspectorCSSAgent::SetStyleTextAction::merge): Added.
486         (WebCore::InspectorCSSAgent::SetPropertyTextAction::redo):
487         (WebCore::InspectorCSSAgent::setStyleText): Added.
488         * inspector/InspectorCSSAgent.h:
489         * inspector/InspectorStyleSheet.cpp:
490         (WebCore::InspectorStyle::getText): Added.
491         (WebCore::InspectorStyle::setText): Added.
492         (WebCore::InspectorStyleSheet::setStyleText):
493         (WebCore::InspectorStyleSheetForInlineStyle::setStyleText):
494         * inspector/InspectorStyleSheet.h:
495         (WebCore::InspectorStyle::styleText): Added as an alias to getText.
496         (WebCore::InspectorStyle::applyStyleText): Added as an alias to setText.
497
498 2013-04-18  Jer Noble  <jer.noble@apple.com>
499
500         Unreviewed gardening; fix bindings tests after r148700.
501
502         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
503         (WebCore::JSTestEventTargetOwner::isReachableFromOpaqueRoots):
504
505 2013-04-18  Andy Estes  <aestes@apple.com>
506
507         REGRESSION (r116645): Versions app's UI is munged in HiDPI due to background-size being reset to 'auto' when background short-hand is also specified
508         https://bugs.webkit.org/show_bug.cgi?id=114833
509
510         Reviewed by David Kilzer.
511
512         Added applicationIsVersions() to RuntimeApplicationChecks.
513
514         * WebCore.exp.in:
515         * platform/RuntimeApplicationChecks.cpp:
516         (WebCore::applicationIsVersions):
517         (WebCore):
518         * platform/RuntimeApplicationChecks.h:
519         (WebCore):
520
521 2013-04-18  Sam Weinig  <sam@webkit.org>
522
523         Network Process crashing trying to read in IDNScriptWhiteList.txt
524         https://bugs.webkit.org/show_bug.cgi?id=114827
525
526         Reviewed by Anders Carlsson.
527
528         Move IDNScriptWhiteList.txt from WebKit to WebCore, so that the NetworkProcess does not have to link against
529         WebKit. It was a layering violation for WebCore to be trying to access WebKit resources anyway.
530
531         * Resources/IDNScriptWhiteList.txt: Copied from Source/WebKit/mac/Resources/IDNScriptWhiteList.txt.
532         * WebCore.xcodeproj/project.pbxproj:
533         * platform/mac/WebCoreNSURLExtras.mm:
534         (WebCore::readIDNScriptWhiteList):
535
536 2013-04-18  Simon Fraser  <simon.fraser@apple.com>
537
538         Remove GraphicsLayerCA::constrainedSize() now that we can manage large layer memory use ourselves in TileController
539         https://bugs.webkit.org/show_bug.cgi?id=114834
540
541         Reviewed by Tim Horton.
542
543         GraphicsLayerCA::constrainedSize() was added to handle poor CATiledLayer behavior when layer sizes
544         got extremely large. Now that we no longer use CATiledLayer, remove this code. We can later add
545         tile memory bounding to TileController if that becomes necessary.
546
547         * platform/graphics/ca/GraphicsLayerCA.cpp:
548         (WebCore::GraphicsLayerCA::updateGeometry):
549         * platform/graphics/ca/GraphicsLayerCA.h:
550         (GraphicsLayerCA):
551
552 2013-04-18  Alberto Garcia  <agarcia@igalia.com>
553
554         Remove obsolete macros from libpng
555         https://bugs.webkit.org/show_bug.cgi?id=114817
556
557         Reviewed by Benjamin Poulain.
558
559         libpng 1.4 removes the png_voidp_NULL and png_error_ptr_NULL
560         macros. Null pointers must be used directly instead.
561
562         * platform/image-encoders/PNGImageEncoder.cpp:
563         (WebCore::compressRGBABigEndianToPNG):
564
565 2013-04-18  Jer Noble  <jer.noble@apple.com>
566
567         CodeGeneratorJS.pm should generate "isFiringEventListeners()" check in isReachableFromOpaqueRoots()
568         https://bugs.webkit.org/show_bug.cgi?id=114784
569
570         Reviewed by Geoffrey Garen.
571
572         EventTarget subclasses shouldn't have to use CustomIsReachable directives
573         in order to keep their wrappers alive while firing event listeners.
574
575         * bindings/scripts/CodeGeneratorJS.pm:
576         (GenerateImplementation):
577
578 2013-04-17  Geoffrey Garen  <ggaren@apple.com>
579
580         Renamed JSGlobalData to VM
581         https://bugs.webkit.org/show_bug.cgi?id=114777
582
583         Reviewed by Phil Pizlo.
584
585         * ForwardingHeaders/runtime/JSGlobalData.h: Removed.
586         * ForwardingHeaders/runtime/VM.h: Copied from Source/WebCore/ForwardingHeaders/runtime/JSGlobalData.h.
587         * WebCore.exp.in:
588         * WebCore.order:
589         * WebCore.vcxproj/WebCore.vcxproj:
590         * WebCore.vcxproj/WebCore.vcxproj.filters:
591         * bindings/js/DOMObjectHashTableMap.cpp:
592         (WebCore::DOMObjectHashTableMap::mapFor):
593         * bindings/js/DOMObjectHashTableMap.h:
594         (JSC):
595         (DOMObjectHashTableMap):
596         * bindings/js/DOMWrapperWorld.cpp:
597         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
598         (WebCore::DOMWrapperWorld::~DOMWrapperWorld):
599         (WebCore::normalWorld):
600         (WebCore::mainThreadNormalWorld):
601         * bindings/js/DOMWrapperWorld.h:
602         (WebCore::DOMWrapperWorld::create):
603         (WebCore::DOMWrapperWorld::vm):
604         (DOMWrapperWorld):
605         (WebCore):
606         * bindings/js/GCController.cpp:
607         (WebCore::collect):
608         (WebCore::GCController::garbageCollectSoon):
609         (WebCore::GCController::garbageCollectNow):
610         (WebCore::GCController::setJavaScriptGarbageCollectorTimerEnabled):
611         (WebCore::GCController::discardAllCompiledCode):
612         * bindings/js/IDBBindingUtilities.cpp:
613         (WebCore::get):
614         (WebCore::set):
615         (WebCore::deserializeIDBValue):
616         (WebCore::deserializeIDBValueBuffer):
617         (WebCore::idbKeyToScriptValue):
618         * bindings/js/JSCallbackData.h:
619         (WebCore::JSCallbackData::JSCallbackData):
620         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
621         (WebCore::JSSQLStatementErrorCallback::handleEvent):
622         * bindings/js/JSCustomXPathNSResolver.cpp:
623         (WebCore::JSCustomXPathNSResolver::JSCustomXPathNSResolver):
624         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
625         * bindings/js/JSDOMBinding.cpp:
626         (WebCore::getHashTableForGlobalData):
627         (WebCore::reportException):
628         (WebCore::cacheDOMStructure):
629         * bindings/js/JSDOMBinding.h:
630         (WebCore::DOMConstructorObject::createStructure):
631         (WebCore::DOMConstructorWithDocument::finishCreation):
632         (WebCore::getDOMStructure):
633         (WebCore::setInlineCachedWrapper):
634         (WebCore):
635         (WebCore::jsStringWithCache):
636         * bindings/js/JSDOMGlobalObject.cpp:
637         (WebCore::JSDOMGlobalObject::JSDOMGlobalObject):
638         (WebCore::JSDOMGlobalObject::finishCreation):
639         * bindings/js/JSDOMGlobalObject.h:
640         (JSDOMGlobalObject):
641         (WebCore::JSDOMGlobalObject::createStructure):
642         (WebCore::getDOMConstructor):
643         * bindings/js/JSDOMWindowBase.cpp:
644         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
645         (WebCore::JSDOMWindowBase::finishCreation):
646         (WebCore::JSDOMWindowBase::updateDocument):
647         (WebCore::JSDOMWindowBase::commonVM):
648         * bindings/js/JSDOMWindowBase.h:
649         (JSDOMWindowBase):
650         (WebCore::JSDOMWindowBase::createStructure):
651         * bindings/js/JSDOMWindowCustom.cpp:
652         (WebCore::JSDOMWindow::setLocation):
653         (WebCore::DialogHandler::dialogCreated):
654         (WebCore::DialogHandler::returnValue):
655         * bindings/js/JSDOMWindowShell.cpp:
656         (WebCore::JSDOMWindowShell::JSDOMWindowShell):
657         (WebCore::JSDOMWindowShell::finishCreation):
658         (WebCore::JSDOMWindowShell::setWindow):
659         * bindings/js/JSDOMWindowShell.h:
660         (JSDOMWindowShell):
661         (WebCore::JSDOMWindowShell::create):
662         (WebCore::JSDOMWindowShell::createStructure):
663         * bindings/js/JSDOMWrapper.h:
664         (WebCore::JSDOMWrapper::JSDOMWrapper):
665         * bindings/js/JSDeviceMotionEventCustom.cpp:
666         (WebCore::createAccelerationObject):
667         (WebCore::createRotationRateObject):
668         * bindings/js/JSDictionary.cpp:
669         (WebCore::JSDictionary::convertValue):
670         * bindings/js/JSDictionary.h:
671         (WebCore::JSDictionary::JSDictionary):
672         * bindings/js/JSErrorHandler.cpp:
673         (WebCore::JSErrorHandler::handleEvent):
674         * bindings/js/JSEventListener.cpp:
675         (WebCore::JSEventListener::handleEvent):
676         * bindings/js/JSEventListener.h:
677         (WebCore::JSEventListener::setWrapper):
678         (WebCore::JSEventListener::jsFunction):
679         * bindings/js/JSHTMLDocumentCustom.cpp:
680         (WebCore::JSHTMLDocument::all):
681         (WebCore::JSHTMLDocument::setAll):
682         * bindings/js/JSHTMLTemplateElementCustom.cpp:
683         (WebCore::JSHTMLTemplateElement::content):
684         * bindings/js/JSHistoryCustom.cpp:
685         (WebCore::JSHistory::state):
686         * bindings/js/JSImageConstructor.cpp:
687         (WebCore::JSImageConstructor::finishCreation):
688         * bindings/js/JSImageConstructor.h:
689         (WebCore::JSImageConstructor::createStructure):
690         * bindings/js/JSImageDataCustom.cpp:
691         (WebCore::toJS):
692         * bindings/js/JSInjectedScriptHostCustom.cpp:
693         (WebCore::InjectedScriptHost::nodeAsScriptValue):
694         (WebCore::JSInjectedScriptHost::functionDetails):
695         (WebCore::getJSListenerFunctions):
696         (WebCore::JSInjectedScriptHost::getEventListeners):
697         (WebCore::JSInjectedScriptHost::inspect):
698         * bindings/js/JSLazyEventListener.cpp:
699         (WebCore::JSLazyEventListener::initializeJSFunction):
700         * bindings/js/JSMessageEventCustom.cpp:
701         (WebCore::JSMessageEvent::data):
702         (WebCore::handleInitMessageEvent):
703         * bindings/js/JSMutationCallback.cpp:
704         (WebCore::JSMutationCallback::call):
705         * bindings/js/JSMutationObserverCustom.cpp:
706         (WebCore::JSMutationObserverConstructor::constructJSMutationObserver):
707         * bindings/js/JSNodeFilterCondition.cpp:
708         (WebCore::JSNodeFilterCondition::JSNodeFilterCondition):
709         * bindings/js/JSNodeFilterCondition.h:
710         (WebCore::JSNodeFilterCondition::create):
711         (JSNodeFilterCondition):
712         * bindings/js/JSNodeFilterCustom.cpp:
713         (WebCore::toNodeFilter):
714         * bindings/js/JSPopStateEventCustom.cpp:
715         (WebCore::cacheState):
716         * bindings/js/JSRequestAnimationFrameCallbackCustom.cpp:
717         (WebCore::JSRequestAnimationFrameCallback::handleEvent):
718         * bindings/js/JSSQLResultSetRowListCustom.cpp:
719         (WebCore::JSSQLResultSetRowList::item):
720         * bindings/js/JSWorkerContextBase.cpp:
721         (WebCore::JSWorkerContextBase::JSWorkerContextBase):
722         (WebCore::JSWorkerContextBase::finishCreation):
723         * bindings/js/JSWorkerContextBase.h:
724         (WebCore::JSWorkerContextBase::createStructure):
725         (JSWorkerContextBase):
726         * bindings/js/PageScriptDebugServer.cpp:
727         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
728         * bindings/js/ScheduledAction.cpp:
729         (WebCore::ScheduledAction::ScheduledAction):
730         (WebCore::ScheduledAction::executeFunctionInContext):
731         * bindings/js/ScheduledAction.h:
732         (WebCore::ScheduledAction::ScheduledAction):
733         * bindings/js/ScriptCachedFrameData.cpp:
734         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
735         (WebCore::ScriptCachedFrameData::restore):
736         (WebCore::ScriptCachedFrameData::clear):
737         * bindings/js/ScriptCallStackFactory.cpp:
738         (WebCore::createScriptCallStack):
739         (WebCore::createScriptArguments):
740         * bindings/js/ScriptController.cpp:
741         (WebCore::ScriptController::createWindowShell):
742         (WebCore::ScriptController::evaluateInWorld):
743         (WebCore::ScriptController::createWorld):
744         (WebCore::ScriptController::getAllWorlds):
745         (WebCore::ScriptController::clearWindowShell):
746         (WebCore::ScriptController::initScript):
747         (WebCore::ScriptController::updateDocument):
748         (WebCore::ScriptController::cacheableBindingRootObject):
749         (WebCore::ScriptController::bindingRootObject):
750         (WebCore::ScriptController::clearScriptObjects):
751         (WebCore::ScriptController::shouldBypassMainWorldContentSecurityPolicy):
752         * bindings/js/ScriptControllerMac.mm:
753         (WebCore::ScriptController::windowScriptObject):
754         * bindings/js/ScriptDebugServer.cpp:
755         (WebCore::ScriptDebugServer::dispatchDidPause):
756         * bindings/js/ScriptEventListener.cpp:
757         (WebCore::eventListenerHandlerBody):
758         (WebCore::eventListenerHandler):
759         (WebCore::eventListenerHandlerLocation):
760         * bindings/js/ScriptFunctionCall.cpp:
761         (WebCore::ScriptFunctionCall::call):
762         (WebCore::ScriptCallback::call):
763         * bindings/js/ScriptGCEvent.cpp:
764         (WebCore::ScriptGCEvent::getHeapSize):
765         * bindings/js/ScriptObject.cpp:
766         (WebCore::ScriptObject::ScriptObject):
767         (WebCore::ScriptGlobalObject::set):
768         * bindings/js/ScriptState.h:
769         (WebCore):
770         * bindings/js/ScriptValue.cpp:
771         (WebCore::ScriptValue::deserialize):
772         * bindings/js/ScriptValue.h:
773         (WebCore::ScriptValue::ScriptValue):
774         * bindings/js/ScriptWrappable.h:
775         (JSC):
776         (ScriptWrappable):
777         * bindings/js/ScriptWrappableInlines.h:
778         (WebCore::ScriptWrappable::setWrapper):
779         * bindings/js/SerializedScriptValue.cpp:
780         (WebCore::CloneDeserializer::readTerminal):
781         (WebCore::SerializedScriptValue::deserializeForInspector):
782         (WebCore::SerializedScriptValue::maybeThrowExceptionIfSerializationFailed):
783         * bindings/js/WebCoreJSClientData.h:
784         (WebCoreJSClientData):
785         (WebCore::initNormalWorldClientData):
786         * bindings/js/WorkerScriptController.cpp:
787         (WebCore::WorkerScriptController::WorkerScriptController):
788         (WebCore::WorkerScriptController::~WorkerScriptController):
789         (WebCore::WorkerScriptController::initScript):
790         (WebCore::WorkerScriptController::evaluate):
791         (WebCore::WorkerScriptController::scheduleExecutionTermination):
792         (WebCore::WorkerScriptController::isExecutionTerminating):
793         (WebCore::WorkerScriptController::disableEval):
794         * bindings/js/WorkerScriptController.h:
795         (JSC):
796         (WebCore::WorkerScriptController::vm):
797         (WorkerScriptController):
798         * bindings/js/WorkerScriptDebugServer.cpp:
799         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
800         * bindings/objc/WebScriptObject.mm:
801         (+[WebScriptObject _convertValueToObjcValue:JSC::originRootObject:rootObject:]):
802         * bindings/scripts/CodeGeneratorJS.pm:
803         (GenerateHeader):
804         (GenerateImplementation):
805         (GenerateCallbackImplementation):
806         (JSValueToNative):
807         (GenerateConstructorDeclaration):
808         (GenerateConstructorHelperMethods):
809         * bindings/scripts/test/JS/JSFloat64Array.cpp:
810         (WebCore::getJSFloat64ArrayConstructorTable):
811         (WebCore::JSFloat64ArrayConstructor::finishCreation):
812         (WebCore::getJSFloat64ArrayPrototypeTable):
813         (WebCore::getJSFloat64ArrayTable):
814         (WebCore::JSFloat64Array::finishCreation):
815         (WebCore::JSFloat64Array::createPrototype):
816         * bindings/scripts/test/JS/JSFloat64Array.h:
817         (WebCore::JSFloat64Array::create):
818         (WebCore::JSFloat64Array::createStructure):
819         (JSFloat64Array):
820         (WebCore::JSFloat64ArrayPrototype::create):
821         (WebCore::JSFloat64ArrayPrototype::createStructure):
822         (WebCore::JSFloat64ArrayPrototype::JSFloat64ArrayPrototype):
823         (WebCore::JSFloat64ArrayConstructor::createStructure):
824         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
825         (WebCore::JSTestActiveDOMObjectConstructor::finishCreation):
826         (WebCore::JSTestActiveDOMObject::finishCreation):
827         (WebCore::JSTestActiveDOMObject::createPrototype):
828         * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
829         (WebCore::JSTestActiveDOMObject::create):
830         (WebCore::JSTestActiveDOMObject::createStructure):
831         (JSTestActiveDOMObject):
832         (WebCore::JSTestActiveDOMObjectPrototype::create):
833         (WebCore::JSTestActiveDOMObjectPrototype::createStructure):
834         (WebCore::JSTestActiveDOMObjectPrototype::JSTestActiveDOMObjectPrototype):
835         (WebCore::JSTestActiveDOMObjectConstructor::createStructure):
836         * bindings/scripts/test/JS/JSTestCallback.cpp:
837         (WebCore::JSTestCallback::callbackWithNoParam):
838         (WebCore::JSTestCallback::callbackWithClass1Param):
839         (WebCore::JSTestCallback::callbackWithClass2Param):
840         (WebCore::JSTestCallback::callbackWithStringList):
841         (WebCore::JSTestCallback::callbackWithBoolean):
842         (WebCore::JSTestCallback::callbackRequiresThisToPass):
843         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
844         (WebCore::JSTestCustomNamedGetterConstructor::finishCreation):
845         (WebCore::JSTestCustomNamedGetter::finishCreation):
846         (WebCore::JSTestCustomNamedGetter::createPrototype):
847         * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
848         (WebCore::JSTestCustomNamedGetter::create):
849         (WebCore::JSTestCustomNamedGetter::createStructure):
850         (JSTestCustomNamedGetter):
851         (WebCore::JSTestCustomNamedGetterPrototype::create):
852         (WebCore::JSTestCustomNamedGetterPrototype::createStructure):
853         (WebCore::JSTestCustomNamedGetterPrototype::JSTestCustomNamedGetterPrototype):
854         (WebCore::JSTestCustomNamedGetterConstructor::createStructure):
855         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
856         (WebCore::JSTestEventConstructorConstructor::finishCreation):
857         (WebCore::JSTestEventConstructor::finishCreation):
858         (WebCore::JSTestEventConstructor::createPrototype):
859         * bindings/scripts/test/JS/JSTestEventConstructor.h:
860         (WebCore::JSTestEventConstructor::create):
861         (WebCore::JSTestEventConstructor::createStructure):
862         (JSTestEventConstructor):
863         (WebCore::JSTestEventConstructorPrototype::create):
864         (WebCore::JSTestEventConstructorPrototype::createStructure):
865         (WebCore::JSTestEventConstructorPrototype::JSTestEventConstructorPrototype):
866         (WebCore::JSTestEventConstructorConstructor::createStructure):
867         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
868         (WebCore::JSTestEventTargetConstructor::finishCreation):
869         (WebCore::JSTestEventTarget::finishCreation):
870         (WebCore::JSTestEventTarget::createPrototype):
871         * bindings/scripts/test/JS/JSTestEventTarget.h:
872         (WebCore::JSTestEventTarget::create):
873         (WebCore::JSTestEventTarget::createStructure):
874         (JSTestEventTarget):
875         (WebCore::JSTestEventTargetPrototype::create):
876         (WebCore::JSTestEventTargetPrototype::createStructure):
877         (WebCore::JSTestEventTargetPrototype::JSTestEventTargetPrototype):
878         (WebCore::JSTestEventTargetConstructor::createStructure):
879         * bindings/scripts/test/JS/JSTestException.cpp:
880         (WebCore::JSTestExceptionConstructor::finishCreation):
881         (WebCore::JSTestException::finishCreation):
882         (WebCore::JSTestException::createPrototype):
883         * bindings/scripts/test/JS/JSTestException.h:
884         (WebCore::JSTestException::create):
885         (WebCore::JSTestException::createStructure):
886         (JSTestException):
887         (WebCore::JSTestExceptionPrototype::create):
888         (WebCore::JSTestExceptionPrototype::createStructure):
889         (WebCore::JSTestExceptionPrototype::JSTestExceptionPrototype):
890         (WebCore::JSTestExceptionConstructor::createStructure):
891         * bindings/scripts/test/JS/JSTestInterface.cpp:
892         (WebCore::JSTestInterfaceConstructor::finishCreation):
893         (WebCore::JSTestInterface::finishCreation):
894         (WebCore::JSTestInterface::createPrototype):
895         * bindings/scripts/test/JS/JSTestInterface.h:
896         (WebCore::JSTestInterface::create):
897         (WebCore::JSTestInterface::createStructure):
898         (JSTestInterface):
899         (WebCore::JSTestInterfacePrototype::create):
900         (WebCore::JSTestInterfacePrototype::createStructure):
901         (WebCore::JSTestInterfacePrototype::JSTestInterfacePrototype):
902         (WebCore::JSTestInterfaceConstructor::createStructure):
903         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
904         (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation):
905         (WebCore::JSTestMediaQueryListListener::finishCreation):
906         (WebCore::JSTestMediaQueryListListener::createPrototype):
907         (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
908         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
909         (WebCore::JSTestMediaQueryListListener::create):
910         (WebCore::JSTestMediaQueryListListener::createStructure):
911         (JSTestMediaQueryListListener):
912         (WebCore::JSTestMediaQueryListListenerPrototype::create):
913         (WebCore::JSTestMediaQueryListListenerPrototype::createStructure):
914         (WebCore::JSTestMediaQueryListListenerPrototype::JSTestMediaQueryListListenerPrototype):
915         (WebCore::JSTestMediaQueryListListenerConstructor::createStructure):
916         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
917         (WebCore::JSTestNamedConstructorConstructor::finishCreation):
918         (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation):
919         (WebCore::JSTestNamedConstructor::finishCreation):
920         (WebCore::JSTestNamedConstructor::createPrototype):
921         * bindings/scripts/test/JS/JSTestNamedConstructor.h:
922         (WebCore::JSTestNamedConstructor::create):
923         (WebCore::JSTestNamedConstructor::createStructure):
924         (JSTestNamedConstructor):
925         (WebCore::JSTestNamedConstructorPrototype::create):
926         (WebCore::JSTestNamedConstructorPrototype::createStructure):
927         (WebCore::JSTestNamedConstructorPrototype::JSTestNamedConstructorPrototype):
928         (WebCore::JSTestNamedConstructorConstructor::createStructure):
929         (WebCore::JSTestNamedConstructorNamedConstructor::createStructure):
930         * bindings/scripts/test/JS/JSTestNode.cpp:
931         (WebCore::JSTestNodeConstructor::finishCreation):
932         (WebCore::JSTestNode::finishCreation):
933         (WebCore::JSTestNode::createPrototype):
934         * bindings/scripts/test/JS/JSTestNode.h:
935         (WebCore::JSTestNode::create):
936         (WebCore::JSTestNode::createStructure):
937         (JSTestNode):
938         (WebCore::JSTestNodePrototype::create):
939         (WebCore::JSTestNodePrototype::createStructure):
940         (WebCore::JSTestNodePrototype::JSTestNodePrototype):
941         (WebCore::JSTestNodeConstructor::createStructure):
942         * bindings/scripts/test/JS/JSTestObj.cpp:
943         (WebCore::JSTestObjConstructor::finishCreation):
944         (WebCore::JSTestObj::finishCreation):
945         (WebCore::JSTestObj::createPrototype):
946         (WebCore::jsTestObjCachedAttribute1):
947         (WebCore::jsTestObjCachedAttribute2):
948         (WebCore::setJSTestObjConditionalAttr4Constructor):
949         (WebCore::setJSTestObjConditionalAttr5Constructor):
950         (WebCore::setJSTestObjConditionalAttr6Constructor):
951         (WebCore::setJSTestObjAnyAttribute):
952         (WebCore::setJSTestObjReplaceableAttribute):
953         * bindings/scripts/test/JS/JSTestObj.h:
954         (WebCore::JSTestObj::create):
955         (WebCore::JSTestObj::createStructure):
956         (JSTestObj):
957         (WebCore::JSTestObjPrototype::create):
958         (WebCore::JSTestObjPrototype::createStructure):
959         (WebCore::JSTestObjPrototype::JSTestObjPrototype):
960         (WebCore::JSTestObjConstructor::createStructure):
961         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
962         (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
963         (WebCore::JSTestOverloadedConstructors::finishCreation):
964         (WebCore::JSTestOverloadedConstructors::createPrototype):
965         * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
966         (WebCore::JSTestOverloadedConstructors::create):
967         (WebCore::JSTestOverloadedConstructors::createStructure):
968         (JSTestOverloadedConstructors):
969         (WebCore::JSTestOverloadedConstructorsPrototype::create):
970         (WebCore::JSTestOverloadedConstructorsPrototype::createStructure):
971         (WebCore::JSTestOverloadedConstructorsPrototype::JSTestOverloadedConstructorsPrototype):
972         (WebCore::JSTestOverloadedConstructorsConstructor::createStructure):
973         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
974         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation):
975         (WebCore::JSTestSerializedScriptValueInterface::finishCreation):
976         (WebCore::JSTestSerializedScriptValueInterface::createPrototype):
977         (WebCore::jsTestSerializedScriptValueInterfaceCachedValue):
978         (WebCore::jsTestSerializedScriptValueInterfaceCachedReadonlyValue):
979         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
980         (WebCore::JSTestSerializedScriptValueInterface::create):
981         (WebCore::JSTestSerializedScriptValueInterface::createStructure):
982         (JSTestSerializedScriptValueInterface):
983         (WebCore::JSTestSerializedScriptValueInterfacePrototype::create):
984         (WebCore::JSTestSerializedScriptValueInterfacePrototype::createStructure):
985         (WebCore::JSTestSerializedScriptValueInterfacePrototype::JSTestSerializedScriptValueInterfacePrototype):
986         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::createStructure):
987         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
988         (WebCore::JSTestTypedefsConstructor::finishCreation):
989         (WebCore::JSTestTypedefs::finishCreation):
990         (WebCore::JSTestTypedefs::createPrototype):
991         * bindings/scripts/test/JS/JSTestTypedefs.h:
992         (WebCore::JSTestTypedefs::create):
993         (WebCore::JSTestTypedefs::createStructure):
994         (JSTestTypedefs):
995         (WebCore::JSTestTypedefsPrototype::create):
996         (WebCore::JSTestTypedefsPrototype::createStructure):
997         (WebCore::JSTestTypedefsPrototype::JSTestTypedefsPrototype):
998         (WebCore::JSTestTypedefsConstructor::createStructure):
999         * bridge/c/CRuntimeObject.h:
1000         (JSC::Bindings::CRuntimeObject::createStructure):
1001         * bridge/c/c_instance.cpp:
1002         (JSC::Bindings::CRuntimeMethod::create):
1003         (JSC::Bindings::CRuntimeMethod::createStructure):
1004         (JSC::Bindings::CRuntimeMethod::finishCreation):
1005         * bridge/jsc/BridgeJSC.cpp:
1006         (JSC::Bindings::Instance::createRuntimeObject):
1007         * bridge/objc/ObjCRuntimeObject.h:
1008         (JSC::Bindings::ObjCRuntimeObject::createStructure):
1009         * bridge/objc/objc_instance.mm:
1010         (ObjCRuntimeMethod::create):
1011         (ObjCRuntimeMethod::createStructure):
1012         (ObjCRuntimeMethod::finishCreation):
1013         * bridge/objc/objc_runtime.h:
1014         (JSC::Bindings::ObjcFallbackObjectImp::createStructure):
1015         * bridge/objc/objc_runtime.mm:
1016         (JSC::Bindings::ObjcFallbackObjectImp::ObjcFallbackObjectImp):
1017         (JSC::Bindings::ObjcFallbackObjectImp::finishCreation):
1018         * bridge/qt/qt_instance.cpp:
1019         (JSC::Bindings::QtRuntimeObject::createStructure):
1020         (JSC::Bindings::QtInstance::~QtInstance):
1021         (JSC::Bindings::QtInstance::getQtInstance):
1022         * bridge/runtime_array.cpp:
1023         (JSC::RuntimeArray::RuntimeArray):
1024         (JSC::RuntimeArray::finishCreation):
1025         * bridge/runtime_array.h:
1026         (JSC::RuntimeArray::create):
1027         (JSC::RuntimeArray::createStructure):
1028         (RuntimeArray):
1029         * bridge/runtime_method.cpp:
1030         (JSC::RuntimeMethod::finishCreation):
1031         * bridge/runtime_method.h:
1032         (JSC::RuntimeMethod::create):
1033         (JSC::RuntimeMethod::createStructure):
1034         (RuntimeMethod):
1035         * bridge/runtime_object.cpp:
1036         (JSC::Bindings::RuntimeObject::RuntimeObject):
1037         (JSC::Bindings::RuntimeObject::finishCreation):
1038         * bridge/runtime_object.h:
1039         (JSC::Bindings::RuntimeObject::createStructure):
1040         * bridge/runtime_root.cpp:
1041         (JSC::Bindings::RootObject::RootObject):
1042         (JSC::Bindings::RootObject::gcProtect):
1043         (JSC::Bindings::RootObject::gcUnprotect):
1044         (JSC::Bindings::RootObject::updateGlobalObject):
1045         (JSC::Bindings::RootObject::addRuntimeObject):
1046         * bridge/runtime_root.h:
1047         (RootObject):
1048         * dom/Node.cpp:
1049         * dom/Node.h:
1050         (JSC):
1051         * dom/ScriptExecutionContext.cpp:
1052         (WebCore::ScriptExecutionContext::vm):
1053         * dom/ScriptExecutionContext.h:
1054         (JSC):
1055         (ScriptExecutionContext):
1056         * html/HTMLCanvasElement.cpp:
1057         (WebCore::HTMLCanvasElement::createImageBuffer):
1058         * html/HTMLImageLoader.cpp:
1059         (WebCore::HTMLImageLoader::notifyFinished):
1060         * inspector/ScriptArguments.cpp:
1061         (WebCore::ScriptArguments::ScriptArguments):
1062         * loader/icon/IconDatabaseBase.cpp:
1063         (WebCore):
1064         (WebCore::iconDatabase):
1065         (WebCore::setGlobalIconDatabase):
1066         * platform/qt/MemoryUsageSupportQt.cpp:
1067         (WebCore::memoryUsageKB):
1068         (WebCore::actualMemoryUsageKB):
1069         * platform/win/ClipboardUtilitiesWin.cpp:
1070         (WebCore::createGlobalData):
1071         * plugins/PluginView.cpp:
1072         (WebCore::PluginView::start):
1073         (WebCore::PluginView::stop):
1074         (WebCore::PluginView::performRequest):
1075         (WebCore::PluginView::npObject):
1076         (WebCore::PluginView::privateBrowsingStateChanged):
1077         * plugins/blackberry/PluginViewBlackBerry.cpp:
1078         (WebCore::PluginView::dispatchNPEvent):
1079         (WebCore::PluginView::setNPWindowIfNeeded):
1080         (WebCore::PluginView::platformStart):
1081         (WebCore::PluginView::getWindowInfo):
1082         * plugins/efl/PluginViewEfl.cpp:
1083         (WebCore::PluginView::dispatchNPEvent):
1084         * plugins/gtk/PluginViewGtk.cpp:
1085         (WebCore::PluginView::dispatchNPEvent):
1086         (WebCore::PluginView::handleKeyboardEvent):
1087         (WebCore::PluginView::handleMouseEvent):
1088         (WebCore::PluginView::setNPWindowIfNeeded):
1089         (WebCore::PluginView::platformStart):
1090         * plugins/mac/PluginViewMac.mm:
1091         (WebCore::PluginView::platformStart):
1092         * plugins/qt/PluginViewQt.cpp:
1093         (WebCore::PluginView::dispatchNPEvent):
1094         (WebCore::PluginView::setNPWindowIfNeeded):
1095         * plugins/win/PluginViewWin.cpp:
1096         (WebCore::PluginView::dispatchNPEvent):
1097         (WebCore::PluginView::handleKeyboardEvent):
1098         (WebCore::PluginView::handleMouseEvent):
1099         (WebCore::PluginView::setNPWindowRect):
1100         * testing/js/WebCoreTestSupport.cpp:
1101         (WebCoreTestSupport::injectInternalsObject):
1102         * xml/XMLHttpRequest.cpp:
1103         (WebCore::XMLHttpRequest::dropProtection):
1104
1105 2013-04-18  Oliver Hunt  <oliver@apple.com>
1106
1107         Fix windows build by moving template definition to JSDOMBinding.h
1108
1109         * bindings/js/JSDOMBinding.h:
1110         (WebCore):
1111         * bindings/scripts/CodeGeneratorJS.pm:
1112         (GenerateImplementation):
1113         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
1114         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
1115         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
1116         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
1117         * bindings/scripts/test/JS/JSTestException.cpp:
1118         * bindings/scripts/test/JS/JSTestInterface.cpp:
1119         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
1120         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
1121         * bindings/scripts/test/JS/JSTestObj.cpp:
1122         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
1123         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
1124         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
1125
1126 2013-04-18  Eric Carlson  <eric.carlson@apple.com>
1127
1128         Forced subtitles never rendered
1129         https://bugs.webkit.org/show_bug.cgi?id=114818
1130
1131         Reviewed by Jer Noble.
1132
1133         No new tests, media/track/track-forced-subtitles-in-band.html was updated to test this change.
1134
1135         * html/track/TextTrack.cpp:
1136         (WebCore::TextTrack::isRendered): "forced" tracks are rendered.
1137
1138 2013-04-17  Anders Carlsson  <andersca@apple.com>
1139
1140         Change storage factory functions to take a PageGroup and Page respectively
1141         https://bugs.webkit.org/show_bug.cgi?id=114776
1142
1143         Reviewed by Beth Dakin.
1144
1145         Change StorageNamespace::localStorageNamespace to take a PageGroup since WebKit2 needs
1146         to know which local storage namespace belongs to which page group. Also remove the quota parameter from
1147         the sessionStorageNamespace function since that's trivial to get from the Page.
1148
1149         * WebCore.exp.in:
1150         * page/Page.cpp:
1151         (WebCore::Page::sessionStorage):
1152         * page/PageGroup.cpp:
1153         (WebCore::PageGroup::localStorage):
1154         * storage/StorageNamespace.cpp:
1155         (WebCore::StorageNamespace::localStorageNamespace):
1156         (WebCore::StorageNamespace::sessionStorageNamespace):
1157         * storage/StorageNamespace.h:
1158         * storage/StorageNamespaceImpl.cpp:
1159         (WebCore::StorageNamespaceImpl::localStorageNamespace):
1160         (WebCore::StorageNamespaceImpl::sessionStorageNamespace):
1161         * storage/StorageNamespaceImpl.h:
1162         * storage/StorageStrategy.cpp:
1163         (WebCore::StorageStrategy::localStorageNamespace):
1164         (WebCore::StorageStrategy::sessionStorageNamespace):
1165         * storage/StorageStrategy.h:
1166
1167 2013-04-18  Martin Robinson  <mrobinson@igalia.com>
1168
1169         [GTK] fast/canvas/DrawImageSinglePixelStretch.html fails
1170         https://bugs.webkit.org/show_bug.cgi?id=58309
1171
1172         Reviewed by Alejandro G. Castro.
1173
1174         No new tests. This patch unskips a test.
1175
1176         Prevent sampling outside source boundaries, by creating subsurfaces from source surfaces.
1177         This also requires careful handling of negative and floating source rectangles.
1178
1179         * platform/graphics/cairo/PlatformContextCairo.cpp:
1180         (WebCore::PlatformContextCairo::drawSurfaceToContext): Use a subsurface to prevent sampling
1181         outside rectangle boundaries.
1182
1183 2013-04-18  Jonathan Feldstein  <jfeldstein@blackberry.com>
1184
1185         [BlackBerry] Improper initialization of ANGLEResources (resubmission)
1186         https://bugs.webkit.org/show_bug.cgi?id=114814
1187
1188         Reviewed by Yong Li, Rob Buis
1189         Internally reviewed by Maxim Mogilnitsky
1190
1191         MaxDrawBuffers, OES_standard_derivatives, OES_EGL_image_external and ARB_texture_rectangle
1192         are initialized through the ShBuiltInResources function so these fields do not need to be
1193         set again in GraphicsContext3DBlackBerry.cpp. In addition, the extension flags should not
1194         be set to true without getExtension being called (Khronos WebGL specs, section 5.14.14.).
1195         In fact, as a direct result of these extensions being enabled prior to calling
1196         getExtension, a WebGL conformance suite test for GL_OES_standard_derivatives was failing.
1197
1198         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
1199         (WebCore::GraphicsContext3D::GraphicsContext3D):
1200
1201 2013-04-18  Xuefei Ren  <xren@blackberry.com>
1202
1203         remove build warning(unused parameter)
1204         https://bugs.webkit.org/show_bug.cgi?id=114670
1205
1206         Reviewed by Rob Buis.
1207
1208         remove warning(unused parameter) in
1209         Source/WebCore/html/shadow/MediaControlsBlackBerry.cpp
1210         Source/WebCore/loader/blackberry/CookieJarBlackBerry.cpp
1211         Source/WebCore/platform/blackberry/AuthenticationChallengeManager.cpp
1212         Source/WebCore/platform/blackberry/RenderThemeBlackBerry.cpp
1213         Source/WebCore/platform/network/blackberry/ResourceResponseBlackBerry.cpp
1214         Source/WebCore/platform/network/blackberry/SocketStreamHandleBlackBerry.cpp
1215         Source/WebCore/plugins/blackberry/PluginViewBlackBerry.cpp
1216
1217
1218         * html/shadow/MediaControlsBlackBerry.cpp:
1219         (WebCore::MediaControlFullscreenFullscreenButtonElement::setIsFullscreen):
1220         * loader/blackberry/CookieJarBlackBerry.cpp:
1221         (WebCore::getRawCookies):
1222         (WebCore::deleteCookie):
1223         * platform/blackberry/AuthenticationChallengeManager.cpp:
1224         (WebCore::AuthenticationChallengeManager::notifyChallengeResult):
1225         * platform/blackberry/RenderThemeBlackBerry.cpp:
1226         (WebCore::RenderTheme::themeForPage):
1227         * platform/network/blackberry/ResourceResponseBlackBerry.cpp:
1228         (WebCore::ResourceResponse::doPlatformAdopt):
1229         * platform/network/blackberry/SocketStreamHandleBlackBerry.cpp:
1230         (WebCore::SocketStreamHandle::notifyStatusReceived):
1231         * plugins/blackberry/PluginViewBlackBerry.cpp:
1232         (WebCore::PluginView::invalidateRegion):
1233
1234 2013-04-18  Xuefei Ren  <xren@blackberry.com>
1235
1236
1237         remove build warning(unused parameter)
1238         https://bugs.webkit.org/show_bug.cgi?id=114670
1239
1240         Reviewed by Rob Buis.
1241
1242         remove builde warning (unused parameter) in
1243         Source/WebCore/platform/blackberry/CursorBlackBerry.cpp
1244
1245         * platform/blackberry/CursorBlackBerry.cpp:
1246         (WebCore::Cursor::Cursor):
1247
1248 2013-04-18  Andreas Kling  <akling@apple.com>
1249
1250         EditingStyle: Avoid some unnecessary CSSStyleDeclaration wrappers.
1251         <http://webkit.org/b/114763>
1252
1253         Reviewed by Antti Koivisto.
1254
1255         removeEquivalentProperties(CSSStyleDeclaration) and removeEquivalentProperties(StylePropertySet)
1256         only have different behavior if the CSSStyleDeclaration is computed style (they differ in handling
1257         of the 'font-size' property.)
1258
1259         Avoid creating a CSSStyleDeclaration for StylePropertySets where we can just pass them in directly.
1260
1261         * editing/EditingStyle.cpp:
1262         (WebCore::EditingStyle::removeStyleAddedByNode):
1263         (WebCore::EditingStyle::removeStyleConflictingWithStyleOfNode):
1264
1265 2013-04-18  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1266
1267         Unset :hover in inner documents
1268         https://bugs.webkit.org/show_bug.cgi?id=114446
1269
1270         Reviewed by Antonio Gomes.
1271
1272         Fixes a regression from r145126 where hover nodes in inner documents was sometimes
1273         not unset. Additionally it uses the new api from r145126 to avoid an unnecessary
1274         hit test in touch-event handling.
1275
1276         Test: fast/events/touch/frame-hover-update.html
1277
1278         * dom/Document.cpp:
1279         (WebCore::Document::updateHoverActiveState):
1280         * page/EventHandler.cpp:
1281         (WebCore::shouldGesturesTriggerActive):
1282         (WebCore::EventHandler::handleTouchEvent):
1283
1284 2013-04-18  Seokju Kwon  <seokju.kwon@gmail.com>
1285
1286         Web Inspector: Toolbar icons are displayed incorrectly
1287         https://bugs.webkit.org/show_bug.cgi?id=114792
1288
1289         Reviewed by Timothy Hatcher.
1290
1291         Inspector uses small toolbar icons when docking the inspector.
1292         So icons should have different x position.
1293
1294         No tests because no behavior change is expected.
1295
1296         * inspector/front-end/inspector.css: Add missing 'background-position-x' values.
1297         (body.dock-to-bottom .toolbar-item.profiles .toolbar-icon):
1298         (body.dock-to-bottom .toolbar-item.cpu-profiler .toolbar-icon):
1299         (body.dock-to-bottom .toolbar-item.css-profiler .toolbar-icon):
1300         (body.dock-to-bottom .toolbar-item.heap-profiler .toolbar-icon):
1301         (body.dock-to-bottom .toolbar-item.canvas-profiler .toolbar-icon):
1302         (body.dock-to-bottom .toolbar-item.memory-chart-profiler .toolbar-icon):
1303         (body.dock-to-bottom .toolbar-item.memory-snapshot-profiler .toolbar-icon):
1304
1305 2013-04-17  Jaehun Lim  <ljaehun.lim@samsung.com>
1306
1307         [css3-text] Rendering -webkit-hanging value for text-indent from css3-text
1308         https://bugs.webkit.org/show_bug.cgi?id=114663
1309
1310         Reviewed by Beth Dakin.
1311
1312         This patch is the rendering part to support hanging value for text-indent.
1313         "hanging" means "Inverts which lines are affected."
1314         It's prefixed and guarded by CSS3_TEXT flag.
1315
1316         Spec: http://dev.w3.org/csswg/css-text/#text-indent
1317
1318         Test: fast/css3-text/css3-text-indent/text-indent-each-line-hanging.html
1319
1320         * rendering/RenderBlockLineLayout.cpp:
1321         (WebCore::requiresIndent): Inverted the return value when "-webkit-hanging" is applied.
1322
1323 2013-04-17  James Craig  <james@cookiecrook.com>
1324
1325         AX: aria-level does not override implicit level on h1, h2, etc
1326         https://bugs.webkit.org/show_bug.cgi?id=114692
1327
1328         Reviewed by Chris Fleizach.
1329
1330         aria-level now works on headings without an explicit role="heading" defined. Updated existing test coverage.
1331
1332         * accessibility/AccessibilityNodeObject.cpp:
1333         (WebCore::AccessibilityNodeObject::headingLevel):
1334
1335 2013-04-17  Chris Fleizach  <cfleizach@apple.com>
1336
1337         AX: VoiceOver says everything that isn't a link is a "clickable" in Safari reader?
1338         https://bugs.webkit.org/show_bug.cgi?id=114687
1339
1340         Reviewed by Tim Horton.
1341
1342         VoiceOver is saying all text is clickable, because AXPress is exposed as an action on static text.
1343         That is happening, because there's a click handler on the body element in this case.
1344
1345         I think the best plan to keep existing functionality, but fix this case is not to expose
1346         the press action for static text when the handler is on the body element.
1347
1348         Test: platform/mac/accessibility/press-action-not-exposed-when-body-is-click-handler.html
1349
1350         * accessibility/AccessibilityNodeObject.cpp:
1351         (WebCore::AccessibilityNodeObject::mouseButtonListener):
1352            Change from checking getAttributeEventListener to hasEventListeners. The former only
1353            checks if "onclick" is installed on the element and does not work with addEventListener!
1354
1355         * accessibility/AccessibilityObject.cpp:
1356         (WebCore::AccessibilityObject::isAccessibilityObjectSearchMatchAtIndex):
1357         * accessibility/AccessibilityObject.h:
1358         (WebCore::AccessibilityObject::isStaticText):
1359
1360 2013-04-17  Simon Fraser  <simon.fraser@apple.com>
1361
1362         Fix GraphicsLayerCA::recursiveVisibleRectChangeRequiresFlush() to do predictive visible rect expansion
1363         https://bugs.webkit.org/show_bug.cgi?id=114775
1364
1365         Reviewed by Tim Horton.
1366
1367         GraphicsLayerCA::recursiveVisibleRectChangeRequiresFlush() is intended to answer the question
1368         "if your visible rect is changed to X, would any tiles be created or destroyed?".
1369         
1370         However, for compositing layer tiled layers, we do some predictive visible rect expansion based on how
1371         the visible rect is changing when we actually commit visible rect changes. recursiveVisibleRectChangeRequiresFlush()
1372         was not doing that, causing it to give confusing answers, so fix it to do so.
1373         
1374         Both now call adjustTiledLayerVisibleRect(), and it's cleaner to make this a static function.
1375         
1376         A somewhat unrelated change is to take the layer bounds origin into account
1377         in GraphicsLayerCA::computeVisibleRect(). Desktop WebKit never sets this, but it's used
1378         on other platforms for composited scrolling, so needs to be taken into account
1379         when computing visible rects.
1380
1381         * platform/graphics/ca/GraphicsLayerCA.cpp:
1382         (WebCore::GraphicsLayerCA::recursiveVisibleRectChangeRequiresFlush):
1383         (WebCore::GraphicsLayerCA::computeVisibleRect):
1384         (WebCore::GraphicsLayerCA::adjustTiledLayerVisibleRect):
1385         (WebCore::GraphicsLayerCA::updateVisibleRect):
1386         * platform/graphics/ca/GraphicsLayerCA.h:
1387         (GraphicsLayerCA):
1388
1389 2013-04-17  Oliver Hunt  <oliver@apple.com>
1390
1391         Automate generation of toJS function for classes that need to report extra memory usage
1392         https://bugs.webkit.org/show_bug.cgi?id=114768
1393
1394         Reviewed by Geoff Garen.
1395
1396         Only really used by AudioBuffer for now.  The other classes that need it can be
1397         trivially refactored at a later date.
1398
1399         * Modules/webaudio/AudioBuffer.idl:
1400         * bindings/js/JSAudioBufferCustom.cpp:
1401         * bindings/js/JSDOMBinding.h:
1402         (WebCore):
1403         (HasMemoryCost):
1404         (NoType):
1405         (BaseMixin):
1406         * bindings/scripts/CodeGeneratorJS.pm:
1407         (GenerateImplementation):
1408
1409 2013-04-17  Dirk Schulze  <krit@webkit.org>
1410
1411         BasicShapeFunctions should use RenderStyle instead of StyleResolver
1412         https://bugs.webkit.org/show_bug.cgi?id=114743
1413
1414         Reviewed by Antti Koivisto.
1415
1416         BasicShapeFunctions does include RenderStyle instead of StyleResolver now.
1417         This is a simple refactoring patch, no new tests.
1418
1419         * css/BasicShapeFunctions.cpp:
1420         (WebCore::convertToLength): Use style and rootElementStyle directly.
1421         (WebCore::basicShapeForValue): Ditto.
1422         * css/BasicShapeFunctions.h:
1423         (WebCore):
1424         * css/DeprecatedStyleBuilder.cpp:
1425         (WebCore::ApplyPropertyClipPath::applyValue):
1426         (WebCore::ApplyPropertyExclusionShape::applyValue):
1427
1428 2013-04-17  Beth Dakin  <bdakin@apple.com>
1429
1430         Content inside frames and scrollbars in overflow areas hit-tests incorrectly when 
1431         the WKView has a header
1432         https://bugs.webkit.org/show_bug.cgi?id=114769
1433
1434         Reviewed by Simon Fraser.
1435
1436         convertToRenderer() and convertFromRenderer() need to factor in the headerHeight, 
1437         much like all of the conversion functions on ScrollView. 
1438         * page/FrameView.cpp:
1439         (WebCore::FrameView::convertFromRenderer):
1440         (WebCore::FrameView::convertToRenderer):
1441
1442         The scrollPosition equivalent of the existing scrollOffsetRelativeToDocument() 
1443         function. 
1444         * platform/ScrollView.cpp:
1445         (WebCore::ScrollView::scrollPositionRelativeToDocument):
1446         * platform/ScrollView.h:
1447         (ScrollView):
1448
1449 2013-04-17  Andreas Kling  <akling@apple.com>
1450
1451         Remove FragmentScriptingPermission.h include from Element.h.
1452         <http://webkit.org/b/114757>
1453
1454         Rubber-stamped by Anders Carlsson.
1455
1456         * dom/Element.h:
1457
1458 2013-04-17  Mark Lam  <mark.lam@apple.com>
1459
1460         Add LLINT and baseline JIT support for timing out scripts.
1461         https://bugs.webkit.org/show_bug.cgi?id=114577.
1462
1463         Reviewed by Geoffrey Garen.
1464
1465         Replaced use of the obsolete JSGlobalData.terminator methods with the
1466         JSGlobalData.watchdog equivalents.
1467
1468         * bindings/js/JSEventListener.cpp:
1469         (WebCore::JSEventListener::handleEvent):
1470         * bindings/js/SerializedScriptValue.cpp:
1471         (WebCore::SerializedScriptValue::maybeThrowExceptionIfSerializationFailed):
1472         * bindings/js/WorkerScriptController.cpp:
1473         (WebCore::WorkerScriptController::evaluate):
1474         (WebCore::WorkerScriptController::scheduleExecutionTermination):
1475         (WebCore::WorkerScriptController::isExecutionTerminating):
1476
1477 2013-04-16  Jer Noble <jer.noble@apple.com>
1478
1479         Crash in WebCore::HTMLMediaElement::~HTMLMediaElement.
1480         https://bugs.webkit.org/show_bug.cgi?id=113531
1481
1482         Reviewed by Eric Carlson.
1483
1484         No new tests, though this is intermittently reproducible with
1485         http/tests/misc/delete-frame-during-readystatechange.html under ASAN.
1486
1487         * html/HTMLMediaElement.cpp:
1488         (WebCore::HTMLMediaElement::~HTMLMediaElement): Clear the media player manually
1489             before the destructor exits. Clearing the media player may cancel a resource load,
1490             which can trigger a readystatechange event. It's possible for the HTMLMediaElement
1491             to attempt to fire an abort event within the readystatechange event, even though it is
1492             now in an inconsistent state. Clearling the media player before finishing the destructor
1493             ensures that the HTMLMediaElement will at least still be alive if this case is triggered.
1494             Set m_completelyLoaded to true to ensure that if userCancelledLoad() is called, it doesn't
1495             attempt to fire events while destructing.
1496
1497 2013-04-17  Sergio Correia  <sergio.correia@openbossa.org>
1498
1499         Web Inspector: make generate-inspector-protocol-version work with python3 
1500         https://bugs.webkit.org/show_bug.cgi?id=114717
1501
1502         Revision r146765 added print() calls that made the script complain about 
1503         invalid syntax when using python3.
1504
1505         This commit replaces such calls with calls to sys.stdout.write(), analogous
1506         to the sys.stderr.write() ones already used throughout the file.
1507
1508         Reviewed by Timothy Hatcher.
1509
1510         No new tests. No user visible behavior changed.
1511
1512         * inspector/generate-inspector-protocol-version:
1513         (main):
1514
1515 2013-04-17  Seokju Kwon  <seokju.kwon@gmail.com>
1516
1517         Web Inspector: Fix Localized string warngs
1518         https://bugs.webkit.org/show_bug.cgi?id=114718
1519
1520         Reviewed by Timothy Hatcher.
1521
1522         No tests because no behavior change is expected.
1523
1524         * English.lproj/localizedStrings.js:
1525
1526 2013-04-17  Csaba Osztrogon√°c  <ossy@webkit.org>
1527
1528         [Qt] Unreviewed Windows buildfix.
1529
1530         * platform/qt/DragDataQt.cpp: Add a missing include.
1531
1532 2013-04-17  ChangSeok Oh  <shivamidow@gmail.com>
1533
1534         Breaking Float: floated block level element following inline element in floated container breaks to next line
1535         https://bugs.webkit.org/show_bug.cgi?id=45274
1536
1537         Reviewed by David Hyatt.
1538
1539         Fix position issue of floating element in floating element.
1540         Inner floating element has placed at next line when outer floating element has text,
1541         even though previous line has spaces enough to fit it.
1542         To solve this, the width of a space added temporarily for prohibiting duplication more than 2 empty spaces
1543         is subtracted when floating element is checked whether it fits on a line.
1544
1545         Tests: css2.1/20110323/floats-001.html
1546                css2.1/20110323/floats-102.html
1547                fast/inline-block/float-both-whitespace.html
1548                fast/inline-block/float-leading-whitespace.html
1549                fast/inline-block/float-no-whitespace.html
1550                fast/inline-block/float-trailing-whitespace.html
1551                fast/inline-block/multiple-floats-with-whitespace.html
1552
1553         * rendering/RenderBlockLineLayout.cpp:
1554         (WebCore::LineWidth::LineWidth):
1555         (WebCore::LineWidth::fitsOnLine):
1556         (WebCore::LineWidth::trailingWhitespaceWidth):
1557         (WebCore::LineWidth::setTrailingWhitespaceWidth):
1558         (LineWidth):
1559         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
1560
1561 2013-04-17  Leo Yang  <leoyang@rim.com>
1562
1563         Lots of unused parameter warnings in filesystem code
1564         https://bugs.webkit.org/show_bug.cgi?id=114747
1565
1566         Reviewed by Carlos Garcia Campos.
1567
1568         Comment out or remove unused parameter identifiers.
1569
1570         No functionalities changed, no new tests.
1571
1572         * Modules/filesystem/DOMFileSystem.cpp: Comment out |snapshot| because
1573         it is referred in the comments inside the function.
1574         (WebCore):
1575         * Modules/filesystem/DOMFileSystemSync.cpp: Ditto.
1576         (WebCore):
1577         * Modules/filesystem/FileWriter.cpp: Remove unused |ec|.
1578         (WebCore::FileWriter::abort):
1579         * Modules/filesystem/FileWriterSync.cpp:
1580         (WebCore::FileWriterSync::didWrite): Remove unused |bytes|.
1581         * platform/AsyncFileSystemCallbacks.h:
1582         (WebCore::AsyncFileSystemCallbacks::didOpenFileSystem): Comment out unused parameters
1583         because the function is inlined.
1584         (WebCore::AsyncFileSystemCallbacks::didCreateSnapshotFile): Ditto.
1585         (WebCore::AsyncFileSystemCallbacks::didReadDirectoryEntry): Ditto.
1586         (WebCore::AsyncFileSystemCallbacks::didReadDirectoryEntries): Ditto.
1587         (WebCore::AsyncFileSystemCallbacks::didCreateFileWriter): Ditto.
1588         * platform/blackberry/WorkerAsyncFileSystemBlackBerry.cpp:
1589         (WebCore::WorkerAsyncFileSystemBlackBerry::createWriterOnMainThread): Remove unused |client|.
1590
1591 2013-04-17  Brent Fulgham  <bfulgham@webkit.org>
1592
1593         [Windows, WinCairo] Stop individually building WTF files in WebCore
1594         https://bugs.webkit.org/show_bug.cgi?id=114705
1595
1596         Reviewed by Anders Carlsson.
1597
1598         * WebCore.vcproj/WebCore.vcproj: Remove references to WTF objects.
1599         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
1600         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto
1601
1602 2013-04-17  Dirk Schulze  <krit@webkit.org>
1603
1604         Make lengthConversion methods and arguments const
1605         https://bugs.webkit.org/show_bug.cgi?id=114749
1606
1607         Reviewed by Andreas Kling.
1608
1609         Refactoring, no new tests.
1610
1611         * css/CSSCalculationValue.cpp:
1612         (WebCore::CSSCalcValue::computeLengthPx):
1613         (WebCore::CSSCalcPrimitiveValue::toCalcValue):
1614         (WebCore::CSSCalcPrimitiveValue::computeLengthPx):
1615         (WebCore::CSSCalcBinaryOperation::toCalcValue):
1616         (WebCore::CSSCalcBinaryOperation::computeLengthPx):
1617         * css/CSSCalculationValue.h:
1618         (WebCore::CSSCalcValue::toCalcValue):
1619         (CSSCalcValue):
1620         * css/CSSPrimitiveValue.cpp:
1621         (WebCore::CSSPrimitiveValue::computeLength):
1622         (WebCore::CSSPrimitiveValue::computeLengthDouble):
1623         (WebCore::CSSPrimitiveValue::viewportPercentageLength):
1624         * css/CSSPrimitiveValue.h:
1625         (CSSPrimitiveValue):
1626         * css/CSSPrimitiveValueMappings.h:
1627         (WebCore::CSSPrimitiveValue::convertToLength):
1628         * css/StyleResolver.cpp:
1629         (WebCore::StyleResolver::convertToIntLength):
1630         (WebCore::StyleResolver::convertToFloatLength):
1631         * css/StyleResolver.h:
1632         (StyleResolver):
1633
1634 2013-04-17  Bruno de Oliveira Abinader  <bruno.abinader@basyskom.com>
1635
1636         [refactor] Moved ScriptedAnimationController common code to inline function
1637         https://bugs.webkit.org/show_bug.cgi?id=114681
1638
1639         Reviewed by Daniel Bates.
1640
1641         Avoided duplicated code by moving ScriptedAnimationController clearance
1642         code to a common function used by both Document::dispose() and
1643         Document::detach().
1644
1645         No new tests, no behavior changes.
1646
1647         * dom/Document.cpp:
1648         (WebCore::Document::dispose):
1649         (WebCore::Document::detach):
1650         (WebCore::Document::clearScriptedAnimationController): Added.
1651         * dom/Document.h:
1652         (Document):
1653
1654 2013-04-17  Chris Fleizach  <cfleizach@apple.com>
1655
1656         AX: When img@alt is undefined, WebKit should use @title as accessibility label if available
1657         https://bugs.webkit.org/show_bug.cgi?id=114535
1658
1659         Reviewed by Tim Horton.
1660
1661         Don't hide images from Accessibility that have the title attribute on them.
1662
1663         Test: accessibility/empty-image-with-title.html
1664
1665         * accessibility/AccessibilityRenderObject.cpp:
1666         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
1667
1668 2013-04-17  Arpita Bahuguna  <a.bah@samsung.com>
1669
1670         getAttribute does not behave correctly for mixed-case attributes on HTML elements
1671         https://bugs.webkit.org/show_bug.cgi?id=105713
1672
1673         Reviewed by Andreas Kling.
1674
1675         getAttribute() and getAttributeNode() APIs do not convert the
1676         passed attribute name to lowercase before comparing against the
1677         existing attributes.
1678         The specification however states that the passed name should
1679         be converted to ASCII lowercase before checking for the existence
1680         of the given attribute. [www.w3.org/TR/domcore/#dom-element-getattribute]
1681
1682         Test: fast/dom/Element/getAttribute-case-insensitivity.html
1683
1684         * dom/Element.h:
1685         (WebCore::ElementData::getAttributeItemIndex):
1686         getAttributeItemIndex() accepts a bool param 'shouldIgnoreAttributeCase'
1687         which specifies whether or not the attribute's case should be ignored
1688         before comparison but we don't really convert the passed name to lowercase
1689         before carrying out the comparison.
1690
1691         Thus, when called from APIs such as getAttribute() and getAttributeNode()
1692         which do not explicitally convert the attribute name to lowercase
1693         before calling on this method, it fails to carry out a case-insensitive
1694         search.
1695
1696         Have thus made changes to convert the passed attribute's name to
1697         lowercase if 'shouldIgnoreAttributeCase' is true.
1698
1699 2013-04-17  John Griggs  <jgriggs@blackberry.com>
1700
1701         [BlackBerry] Add support for filesystem: URLs to BlackBerry Media Player.
1702         https://bugs.webkit.org/show_bug.cgi?id=114686
1703         https://przilla.ott.qnx.com/bugzilla/show_bug.cgi?id=314865
1704
1705         Reviewed by Rob Buis.
1706
1707         Translate filesystem: URLs to file:// URLs for use by the media player, but only after the filesystem: URL has been checked for security, etc.
1708
1709         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
1710         (WebCore::MediaPlayerPrivate::load):
1711         (WebCore::MediaPlayerPrivate::onError):
1712         (WebCore::MediaPlayerPrivate::onDurationChanged):
1713         (WebCore::MediaPlayerPrivate::notifyChallengeResult):
1714
1715 2013-04-17  Brendan Long  <b.long@cablelabs.com>
1716
1717         [GStreamer] Eclipse warnings in MediaPlayerPrivateGStreamer
1718         https://bugs.webkit.org/show_bug.cgi?id=114654
1719
1720         Reviewed by Philippe Normand.
1721
1722         No new tests (nothing added).
1723
1724         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1725         (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
1726         Initialize m_volumeAndMuteInitialized
1727         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
1728         (WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
1729         Initialize signal handlers to 0.
1730
1731 2013-04-17  Andrei Bucur  <abucur@adobe.com>
1732
1733         [CSS Regions] Remove m_flowThread from NodeRenderingContext
1734         https://bugs.webkit.org/show_bug.cgi?id=114732
1735
1736         Reviewed by Antti Koivisto.
1737
1738         Cleanup NodeRenderingContext. Remove unused member m_flowThread.
1739
1740         Tests: None needed.
1741
1742         * dom/NodeRenderingContext.cpp:
1743         (WebCore::NodeRenderingContext::moveToFlowThreadIfNeeded):
1744         * dom/NodeRenderingContext.h: Removed m_flowThread.
1745
1746 2013-04-17  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1747
1748         [Qt] MediaPlayerPrivateQt.cpp doesn't build in debug
1749
1750         Unreviewed build fix.
1751
1752         We need to include Logging.h to get the LOG definitions.
1753
1754         * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
1755
1756 2013-04-17  Claudio Saavedra  <csaavedra@igalia.com>
1757
1758         execCommand("RemoveFormat") might remove format after the selection
1759         https://bugs.webkit.org/show_bug.cgi?id=112240
1760
1761         Reviewed by Ryosuke Niwa.
1762
1763         Tests: editing/execCommand/remove-format-multiple-elements-mac.html
1764
1765         This bug is hit when ApplyStyleCommand is used to change the
1766         style and the current selection ends in the beginning of a new node.
1767         The bug is actually a two-fold thing:
1768
1769         1. There was no check as to whether the end node is really
1770         selected or not, and format was always removed from it with
1771         pushDownInlineStyleAroundNode(). An equivalent check for the start
1772         node was already in place, so fix it analogously.
1773
1774         2. Previous stage might change the dom tree, resulting in a render
1775         tree that is not up-to-date. Position::upstream() is later used
1776         and, in order to be able to find a visually equivalent position in
1777         a text node, this method needs the render tree to be up-to-date,
1778         therefore, a call to updateLayoutIgnorePendingStylesheets() is
1779         necessary.
1780
1781         * editing/ApplyStyleCommand.cpp:
1782         (WebCore::ApplyStyleCommand::removeInlineStyle): Make sure that no
1783         format is removed from the end node if it's not fully selected.
1784         (WebCore::ApplyStyleCommand::nodeFullySelected): Call updateLayoutIgnorePendingStylesheets()
1785
1786 2013-04-17  Alberto Garcia  <agarcia@igalia.com>
1787
1788         [BlackBerry] GraphicsContext3D: don't initialize m_extensions in the constructor
1789         https://bugs.webkit.org/show_bug.cgi?id=114726
1790
1791         Reviewed by Carlos Garcia Campos.
1792
1793         m_extensions is now initialized on demand by
1794         GraphicsContext3D::getExtensions().
1795
1796         Doing it in the constructor produces a crash, because
1797         Extensions3DOpenGLES() calls glGetString before the WebGL context
1798         is current.
1799
1800         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
1801         (WebCore::GraphicsContext3D::GraphicsContext3D):
1802
1803 2013-04-16  Maciej Stachowiak  <mjs@apple.com>
1804
1805         Replace JSC-specific IDL extended attributes with generic (JSC+V8) ones, now that the distinction no longer matters
1806         https://bugs.webkit.org/show_bug.cgi?id=114712
1807
1808         Reviewed by Dan Bernstein.
1809
1810         No behavior change expected.
1811
1812         * bindings/scripts/IDLAttributes.txt: Remove the JSFoo attributes
1813         that have bare Foo equivalents.
1814         * bindings/scripts/CodeGeneratorJS.pm: Remove support for JSFoo
1815         aliases.
1816         (GetGenerateIsReachable):
1817         (GetCustomIsReachable):
1818         (ShouldGenerateToJSDeclaration):
1819         (ShouldGenerateToJSImplementation):
1820         (HasCustomConstructor):
1821         (HasCustomGetter):
1822         (HasCustomSetter):
1823         (HasCustomMethod):
1824
1825         Replace JSFoo attributes with equivalen Foo attributs in all files
1826         below:
1827         
1828         * Modules/geolocation/Geolocation.idl:
1829         * Modules/indexeddb/IDBDatabase.idl:
1830         * Modules/indexeddb/IDBObjectStore.idl:
1831         * Modules/webaudio/DOMWindowWebAudio.idl:
1832         * Modules/websockets/DOMWindowWebSocket.idl:
1833         * Modules/websockets/WorkerContextWebSocket.idl:
1834         * css/CSSRule.idl:
1835         * css/CSSRuleList.idl:
1836         * css/CSSStyleDeclaration.idl:
1837         * css/CSSValue.idl:
1838         * css/MediaList.idl:
1839         * css/StyleMedia.idl:
1840         * css/StyleSheet.idl:
1841         * dom/MessagePort.idl:
1842         * dom/MutationObserver.idl:
1843         * dom/Node.idl:
1844         * fileapi/Blob.idl:
1845         * html/HTMLDocument.idl:
1846         * html/HTMLTemplateElement.idl:
1847         * html/canvas/ArrayBuffer.idl:
1848         * html/canvas/CanvasRenderingContext.idl:
1849         * html/canvas/DataView.idl:
1850         * html/canvas/EXTDrawBuffers.idl:
1851         * html/canvas/EXTTextureFilterAnisotropic.idl:
1852         * html/canvas/OESElementIndexUint.idl:
1853         * html/canvas/OESStandardDerivatives.idl:
1854         * html/canvas/OESTextureFloat.idl:
1855         * html/canvas/OESTextureHalfFloat.idl:
1856         * html/canvas/OESVertexArrayObject.idl:
1857         * html/canvas/WebGLCompressedTextureATC.idl:
1858         * html/canvas/WebGLCompressedTexturePVRTC.idl:
1859         * html/canvas/WebGLCompressedTextureS3TC.idl:
1860         * html/canvas/WebGLDebugRendererInfo.idl:
1861         * html/canvas/WebGLDebugShaders.idl:
1862         * html/canvas/WebGLDepthTexture.idl:
1863         * html/canvas/WebGLLoseContext.idl:
1864         * html/track/TextTrack.idl:
1865         * html/track/TextTrackCue.idl:
1866         * html/track/TextTrackList.idl:
1867         * loader/appcache/DOMApplicationCache.idl:
1868         * page/BarInfo.idl:
1869         * page/Console.idl:
1870         * page/DOMSelection.idl:
1871         * page/DOMWindow.idl:
1872         * page/History.idl:
1873         * page/Location.idl:
1874         * page/MemoryInfo.idl:
1875         * page/Navigator.idl:
1876         * page/Screen.idl:
1877         * page/WorkerNavigator.idl:
1878         * plugins/DOMMimeTypeArray.idl:
1879         * plugins/DOMPluginArray.idl:
1880         * storage/Storage.idl:
1881         * workers/AbstractWorker.idl:
1882         * workers/SharedWorker.idl:
1883         * workers/Worker.idl:
1884         * workers/WorkerContext.idl:
1885         * workers/WorkerLocation.idl:
1886         * xml/XMLHttpRequestUpload.idl:
1887
1888 2013-04-16  Beth Dakin  <bdakin@apple.com>
1889
1890         Re-name Page::layoutMilestones() to Page::requestedLayoutMilestones()
1891         https://bugs.webkit.org/show_bug.cgi?id=114713
1892
1893         Reviewed by Simon Fraser.
1894
1895         * page/FrameView.cpp:
1896         (WebCore::FrameView::performPostLayoutTasks):
1897         * page/Page.cpp:
1898         (WebCore::Page::Page):
1899         (WebCore::Page::addLayoutMilestones):
1900         (WebCore::Page::removeLayoutMilestones):
1901         (WebCore::Page::isCountingRelevantRepaintedObjects):
1902         * page/Page.h:
1903         (WebCore::Page::requestedLayoutMilestones):
1904         (Page):
1905         * rendering/RenderLayerCompositor.cpp:
1906         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
1907
1908 2013-04-16  Patrick Gansterer  <paroga@webkit.org>
1909
1910         [CMake] Fix dependecy calculation for generated inspector files
1911         https://bugs.webkit.org/show_bug.cgi?id=114092
1912
1913         Reviewed by Brent Fulgham.
1914
1915         At least in a generated Visual Studio solution the files generated via
1916         CodeGeneratorInspector.py are considered outdated all the time because
1917         the code generator only touches the file when the content changed.
1918         Add an --write_always parameter to the script to touch the file always.
1919
1920         * CMakeLists.txt:
1921         * inspector/CodeGeneratorInspector.py:
1922
1923 2013-04-16  Anders Carlsson  <andersca@apple.com>
1924
1925         Clone storage namespaces for window.open
1926         https://bugs.webkit.org/show_bug.cgi?id=114703
1927
1928         Reviewed by Sam Weinig.
1929
1930         Pass the new page to StorageNamespace::copy.
1931
1932         * page/Chrome.cpp:
1933         (WebCore::Chrome::createWindow):
1934         * storage/StorageNamespace.h:
1935         (StorageNamespace):
1936         * storage/StorageNamespaceImpl.cpp:
1937         (WebCore::StorageNamespaceImpl::copy):
1938         * storage/StorageNamespaceImpl.h:
1939         (WebCore):
1940         (StorageNamespaceImpl):
1941
1942 2013-04-16  Sam Weinig  <sam@webkit.org>
1943
1944         Fix fallout after r148545.
1945
1946         * platform/text/TextChecking.h:
1947         Move Platform defines that were incorrectly in WebCore, into Platform.h
1948
1949 2013-04-16  Hans Muller  <hmuller@adobe.com>
1950
1951         [CSS Exclusions] polygon shape-inside layout fails
1952         https://bugs.webkit.org/show_bug.cgi?id=114402
1953
1954         Reviewed by Dirk Schulze.
1955
1956         The firstIncludedIntervalLogicalTop() method's implementation relied on optimistic
1957         assumptions about floating point accuracy which, in rare cases, caused it to discard
1958         first-fit locations based on the intersection of the minLogicalIntervalTop offset edge
1959         and a polygon offset edge. Now: we do not verify that first-fit locations based on the
1960         intersection of an offset edge and the minLogicalIntervalTop offset edge are below
1961         the horizontal minLogicalIntervalTop line. They're essentially below the line "by definition".
1962
1963         Test: fast/exclusions/shape-inside/shape-inside-polygon-layout.html
1964
1965         * rendering/ExclusionPolygon.cpp:
1966         (WebCore::ExclusionPolygon::firstIncludedIntervalLogicalTop): Avoid floating point problems
1967             when checking intersections with the offset edge based on minLogicalIntervalTop.
1968         * rendering/ExclusionPolygon.h:
1969         (WebCore::OffsetPolygonEdge::OffsetPolygonEdge): Initialize the basis field.
1970         (WebCore::OffsetPolygonEdge::basis): Report what the offset edge is "based on": a polygon
1971             edge, the top of the line, or a (reflex) vertex.
1972         (OffsetPolygonEdge): Added the Basis enum to enable tracking what the geometry of
1973             an offset edge is based on.
1974
1975 2013-04-16  Jer Noble  <jer.noble@apple.com>
1976
1977         Further unreviewed build fix: protect JSAudioBufferCustom with a ENABLE(WEB_AUDIO) check.
1978
1979         * bindings/js/JSAudioBufferCustom.cpp:
1980
1981 2013-04-16  Jer Noble  <jer.noble@apple.com>
1982
1983         Unreviewed build fix; add new JSAudioBuffer.cpp file to more build systems.
1984
1985         * GNUmakefile.list.am:
1986         * Target.pri:
1987         * UseJSC.cmake:
1988
1989 2013-04-16  Jer Noble  <jer.noble@apple.com>
1990
1991         Repeated use of decodeAudioData() causes leak
1992         https://bugs.webkit.org/show_bug.cgi?id=114709
1993
1994         Reviewed by Geoffrey Garen.
1995
1996         Report the correct size of the AudioBuffer to the garbage collector so that creating
1997         these large buffers will trigger garbage collection.
1998
1999         * Modules/webaudio/AudioBuffer.cpp:
2000         (WebCore::AudioBuffer::memoryCost): Added; simple sum of the buffer sizes in m_channels;
2001         * Modules/webaudio/AudioBuffer.h:
2002         * Modules/webaudio/AudioBuffer.idl: Add the CustomToJSObject flag.
2003         * WebCore.xcodeproj/project.pbxproj:
2004         * bindings/js/JSAudioBufferCustom.cpp: Added.
2005         (WebCore::toJS): Added; report the extra size of an AudioBuffer when the wrapper
2006             is created.
2007
2008 2013-04-16  Beth Dakin  <bdakin@apple.com>
2009
2010         Need a new layout milestone to notify bundle clients when the header has been 
2011         flushed
2012         https://bugs.webkit.org/show_bug.cgi?id=114706
2013         -and corresponding-
2014         <rdar://problem/13657284>
2015
2016         Reviewed by Simon Fraser.
2017
2018         New LayoutMilestone is DidFirstFlushForHeaderLayer.
2019         * page/LayoutMilestones.h:
2020         
2021         New API to allow removing a LayoutMilestone.
2022         * WebCore.exp.in:
2023         * page/Page.cpp:
2024         (WebCore::Page::removeLayoutMilestones):
2025         * page/Page.h:
2026         (Page):
2027
2028         New boolean member variable m_headerLayerAwaitingFirstFlush keeps track of whether 
2029         we need to send the DidFirstFlushForHeaderLayer milestone.
2030         * rendering/RenderLayerCompositor.h:
2031         (RenderLayerCompositor):
2032         * rendering/RenderLayerCompositor.cpp:
2033         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
2034
2035         Send the milestone if appropriate.
2036         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
2037
2038          Set m_headerLayerAwaitingFirstFlush to true for a newly created layer.
2039         (WebCore::RenderLayerCompositor::updateLayerForHeader):
2040
2041 2013-04-16  Tim Horton  <timothy_horton@apple.com>
2042
2043         PlugIn Snapshotting: Crashes refreshing non-main-frame PDFPlugins
2044         https://bugs.webkit.org/show_bug.cgi?id=114702
2045         <rdar://problem/13542020>
2046
2047         Reviewed by Dean Jackson.
2048
2049         If:
2050
2051             a) a plugin fails all the tests in willCreatePlugIn, so it is WaitingForSnapshot there
2052             b) primary plugin detection attempts to restart a plugin between the
2053                time that willCreatePlugIn and didCreatePlugIn fire
2054             c) when didCreatePlugIn fires, shouldAlwaysAutoStart() returns true,
2055                because the plug-in is whitelisted,
2056
2057         we end up reattach()ing and going to Restarted state, and then going straight
2058         to Playing state in didCreatePlugIn.
2059
2060         Instead, primary plugin promotion should be deferred until after the plugin is created,
2061         so that we can take that one last bit of information (shouldAlwaysAutoStart) into account
2062         before restarting and reattaching the plug-in.
2063
2064         * html/HTMLPlugInImageElement.cpp:
2065         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
2066         (WebCore::HTMLPlugInImageElement::setIsPrimarySnapshottedPlugIn):
2067         (WebCore::HTMLPlugInImageElement::restartSnapshottedPlugIn):
2068         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn):
2069         (WebCore::HTMLPlugInImageElement::subframeLoaderDidCreatePlugIn):
2070         * html/HTMLPlugInImageElement.h:
2071
2072 2013-04-16  Wei James  <james.wei@intel.com>
2073
2074         ASSERTION FAILED: i < size(), UNKNOWN in WebCore::ChannelMergerNode::process
2075         https://bugs.webkit.org/show_bug.cgi?id=112657
2076
2077         Avoid to access input bus in checkNumberOfChannelsForInput() before the
2078         bus is updated with AudioNode::checkNumberOfChannelsForInput().
2079
2080         Reviewed by Chris Rogers.
2081
2082         * Modules/webaudio/ChannelMergerNode.cpp:
2083         (WebCore::ChannelMergerNode::checkNumberOfChannelsForInput):
2084
2085 2013-04-16  Ryosuke Niwa  <rniwa@webkit.org>
2086
2087         Even more Windows build fix and a Qt minimal build fix attempt.
2088
2089         * html/parser/XSSAuditorDelegate.cpp:
2090         * page/win/FrameCGWin.cpp:
2091
2092 2013-04-16  Ryosuke Niwa  <rniwa@webkit.org>
2093
2094         More Windows build fixes.
2095
2096         * platform/win/DragDataWin.cpp:
2097         * platform/win/PasteboardWin.cpp:
2098
2099 2013-04-16  Sam Weinig  <sam@webkit.org>
2100
2101         Windows build fix.
2102
2103         * page/win/FrameWin.cpp:
2104
2105 2013-04-16  Dean Jackson  <dino@apple.com>
2106
2107         PlugIns that resize in user gestures should be immune to snapshotting
2108         https://bugs.webkit.org/show_bug.cgi?id=114697
2109         <rdar://problem/13666258>
2110
2111         Reviewed by Tim Horton.
2112
2113         Now that we snapshot plugins if they resize above the snapshotting threshold,
2114         we need to make sure that we don't do it in response to a user gesture
2115         such as a click.
2116
2117         Due to the complexities of real-world content and the way they often do
2118         things using timeout, I copied the code from the generic user gesture
2119         timeout, which gives a 5 second grace period after clicks.
2120
2121         * html/HTMLPlugInImageElement.cpp:
2122         (WebCore::documentHadRecentUserGesture): New static function to share the code for
2123             checking the time since the last click (or whatever).
2124         (WebCore::HTMLPlugInImageElement::checkSizeChangeForSnapshotting): Make sure
2125             to test for a user gesture.
2126         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Move the
2127             code into the new function.
2128
2129 2013-04-15  Sam Weinig  <sam@webkit.org>
2130
2131         Remove more #includes from Frame.h
2132         https://bugs.webkit.org/show_bug.cgi?id=114642
2133
2134         Reviewed by Anders Carlsson.
2135
2136         Convert Editor, FrameSelection, EventHandler and AnimationController into
2137         OwnPtrs, to avoid inclusion.
2138
2139         * accessibility/AXObjectCache.cpp:
2140         * accessibility/AccessibilityObject.cpp:
2141         * accessibility/atk/WebKitAccessibleInterfaceEditableText.cpp:
2142         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2143         * bindings/objc/DOM.mm:
2144         * dom/CharacterData.cpp:
2145         * dom/ContainerNode.cpp:
2146         * dom/Element.cpp:
2147         * editing/AlternativeTextController.cpp:
2148         * editing/CompositeEditCommand.cpp:
2149         * editing/DeleteButtonController.h:
2150         * editing/EditingStyle.cpp:
2151         * editing/InsertLineBreakCommand.cpp:
2152         * editing/SpellChecker.cpp:
2153         * editing/SpellingCorrectionCommand.cpp:
2154         * editing/TextInsertionBaseCommand.cpp:
2155         * history/CachedFrame.cpp:
2156         * html/HTMLAnchorElement.cpp:
2157         * html/HTMLInputElement.cpp:
2158         * html/HTMLPlugInElement.cpp:
2159         * html/HTMLSelectElement.cpp:
2160         * html/HTMLTextAreaElement.cpp:
2161         * html/HTMLTextFormControlElement.cpp:
2162         * html/TextFieldInputType.cpp:
2163         * html/shadow/ClearButtonElement.cpp:
2164         * html/shadow/MediaControlElements.cpp:
2165         * html/shadow/SliderThumbElement.cpp:
2166         * inspector/InspectorPageAgent.h:
2167         * loader/FrameLoader.cpp:
2168         * page/DOMWindow.cpp:
2169         * page/Frame.cpp:
2170         * page/Frame.h:
2171         * page/FrameView.cpp:
2172         * page/FrameView.h:
2173         * page/Page.cpp:
2174         * page/TouchAdjustment.cpp:
2175         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2176         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2177         * platform/gtk/PasteboardGtk.cpp:
2178         * platform/qt/ClipboardQt.cpp:
2179         * rendering/HitTestResult.cpp:
2180         * rendering/RenderBlock.cpp:
2181         * rendering/RenderEmbeddedObject.cpp:
2182         * rendering/RenderLayer.cpp:
2183         * rendering/RenderNamedFlowThread.cpp:
2184         * rendering/RenderObject.cpp:
2185         * rendering/RenderSnapshottedPlugIn.cpp:
2186         * svg/graphics/SVGImage.cpp:
2187         * testing/Internals.cpp:
2188
2189 2013-04-16  Jessie Berlin  <jberlin@apple.com>
2190
2191         Speculative Windows build fix.
2192
2193         * platform/win/ContextMenuWin.cpp:
2194
2195 2013-04-16  Eric Carlson  <eric.carlson@apple.com>
2196
2197         [Mac] in-band cues sometimes displayed late
2198         https://bugs.webkit.org/show_bug.cgi?id=114629
2199
2200         Reviewed by Jer Noble.
2201
2202         No new tests, this deals with a platform-specific issue that is extremely timing dependent.
2203
2204         * html/track/InbandTextTrack.cpp:
2205         (WebCore::TextTrackCueMap::add): New, two way cue data <-> cue map.
2206         (WebCore::TextTrackCueMap::find): 
2207         (WebCore::TextTrackCueMap::remove):
2208         (WebCore::InbandTextTrack::updateCueFromCueData): New, update an existing cue. Set cue end time
2209             to video duration if it is unknown.
2210         (WebCore::InbandTextTrack::addGenericCue): Look for existing cues without considering duration
2211             so we can match incomplete cues.
2212         (WebCore::InbandTextTrack::updateGenericCue): New, update an existing cue. This allows us to 
2213             add in-band cues as soon as we get them from the media engine and update them as more
2214             information becomes available.
2215         (WebCore::InbandTextTrack::removeGenericCue): New, remove an existing cue. This is necessary
2216             because we never want to keep an incomplete cue when a seek happens.
2217         (WebCore::InbandTextTrack::removeCue): New, base class override so we can keep the two way
2218             map up to date.
2219         * html/track/InbandTextTrack.h:
2220
2221         * html/track/TextTrack.cpp:
2222         (WebCore::TextTrack::addCue): TextTrack::removeCue takes a RefPtr.
2223         (WebCore::TextTrack::removeCue): Take a RefPtr.
2224         (WebCore::TextTrack::hasCue): Allow caller to request match without considering end time.
2225         * html/track/TextTrack.h:
2226
2227         * html/track/TextTrackCue.cpp:
2228         (WebCore::TextTrackCue::TextTrackCue): Initialize m_processingCueChanges.
2229         (WebCore::TextTrackCue::willChange): Renamed from cueWillChange. Use m_processingCueChanges
2230             to avoid thrashing the track when many cue properties will change.
2231         (WebCore::TextTrackCue::didChange): Renamed from cueDidChange. Use m_processingCueChanges
2232             to avoid thrashing the track when many cue properties will change.
2233         (WebCore::TextTrackCue::setId): cueWillChange -> willChange. cueDidChange -> didChange. 
2234         (WebCore::TextTrackCue::setStartTime): Ditto.
2235         (WebCore::TextTrackCue::setEndTime): Ditto.
2236         (WebCore::TextTrackCue::setPauseOnExit): Ditto.
2237         (WebCore::TextTrackCue::setVertical): Ditto.
2238         (WebCore::TextTrackCue::setSnapToLines): Ditto.
2239         (WebCore::TextTrackCue::setLine): Ditto.
2240         (WebCore::TextTrackCue::setPosition): Ditto.
2241         (WebCore::TextTrackCue::setSize): Ditto.
2242         (WebCore::TextTrackCue::setAlign): Ditto.
2243         (WebCore::TextTrackCue::setText): Ditto.
2244         (WebCore::TextTrackCue::setRegionId): Ditto.
2245         (WebCore::TextTrackCue::isEqual): Renamed from operator==, take match rules param.
2246         * html/track/TextTrackCue.h:
2247
2248         * html/track/TextTrackCueGeneric.cpp:
2249         (WebCore::TextTrackCueGeneric::isEqual): Renamed from operator==, take match rules param.
2250         * html/track/TextTrackCueGeneric.h:
2251
2252         * platform/graphics/InbandTextTrackPrivateClient.h: Make GenericCueData refcounted.
2253         (WebCore::GenericCueData::create): New.
2254         (WebCore::GenericCueData::status): Ditto.
2255         (WebCore::GenericCueData::setStatus): Ditto.
2256         (WebCore::GenericCueData::GenericCueData):
2257
2258         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
2259         (WebCore::InbandTextTrackPrivateAVF::processCue): Add cues as soon as we get them from the media
2260             engine, update duration once we know it.
2261         (WebCore::InbandTextTrackPrivateAVF::resetCueValues): Tell the client to remove all incomplete
2262             cues we have delivered.
2263         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
2264
2265         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2266         (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted): Do not flush cues when seek completes,
2267             we did that when the seek started and cues can be delivered before we get the the 
2268             seek completed  notification.
2269
2270 2013-04-16  James Craig  <james@cookiecrook.com>
2271
2272         dfn element should be exposed as AXGroup:AXDefinition
2273         https://bugs.webkit.org/show_bug.cgi?id=108980
2274
2275         Reviewed by Chris Fleizach.
2276
2277         dfn element now exposed as AXGroup:AXDefinition. Updated existing tests.
2278
2279         * accessibility/AccessibilityRenderObject.cpp:
2280         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
2281         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
2282
2283 2013-04-16  Anders Carlsson  <andersca@apple.com>
2284
2285         Begin chipping away at ScriptState
2286         https://bugs.webkit.org/show_bug.cgi?id=114695
2287
2288         Reviewed by Geoffrey Garen.
2289
2290         Remove ScriptStateProtectedPtr as well as evalEnabled and setEvalEnabled.
2291
2292         * bindings/js/ScriptState.cpp:
2293         * bindings/js/ScriptState.h:
2294         * inspector/InjectedScriptBase.cpp:
2295         (WebCore::InjectedScriptBase::callFunctionWithEvalEnabled):
2296         * inspector/ScriptArguments.cpp:
2297         (WebCore::ScriptArguments::ScriptArguments):
2298         (WebCore::ScriptArguments::globalState):
2299         * inspector/ScriptArguments.h:
2300
2301 2013-04-15  Anders Carlsson  <andersca@apple.com>
2302
2303         Remove unneeded headers from ScriptExecutionContext.h
2304         https://bugs.webkit.org/show_bug.cgi?id=114631
2305
2306         Reviewed by Alexey Proskuryakov.
2307
2308         This shaves another minute off WebCore build time on my MacBook Pro.
2309
2310         * dom/ScriptExecutionContext.cpp:
2311         * dom/ScriptExecutionContext.h:
2312         * fileapi/Blob.cpp:
2313         * rendering/RenderBlock.cpp:
2314         * rendering/RenderBox.cpp:
2315         * rendering/RenderFlowThread.cpp:
2316         * rendering/RenderFrameSet.cpp:
2317         * rendering/RenderIFrame.cpp:
2318         * rendering/RenderImage.cpp:
2319         * rendering/RenderListBox.cpp:
2320         * rendering/RenderListItem.cpp:
2321         * rendering/RenderListMarker.cpp:
2322         * rendering/RenderMedia.cpp:
2323         * rendering/RenderObject.cpp:
2324         * rendering/RenderRegion.cpp:
2325         * rendering/RenderReplaced.cpp:
2326         * rendering/RenderReplica.cpp:
2327         * rendering/RenderRubyRun.cpp:
2328         * rendering/RenderScrollbarPart.cpp:
2329         * rendering/RenderSlider.cpp:
2330         * rendering/RenderTable.cpp:
2331         * rendering/RenderTableCell.cpp:
2332         * rendering/RenderTableRow.cpp:
2333         * rendering/RenderTableSection.cpp:
2334         * rendering/RenderTextControlSingleLine.cpp:
2335         * rendering/RenderTextTrackCue.cpp:
2336         * rendering/RenderVideo.cpp:
2337         * rendering/RenderView.cpp:
2338         * rendering/RenderWidget.cpp:
2339         * rendering/svg/RenderSVGContainer.cpp:
2340         * rendering/svg/RenderSVGForeignObject.cpp:
2341         * rendering/svg/RenderSVGGradientStop.cpp:
2342         * rendering/svg/RenderSVGHiddenContainer.cpp:
2343         * rendering/svg/RenderSVGImage.cpp:
2344         * rendering/svg/RenderSVGResourceContainer.cpp:
2345         * rendering/svg/RenderSVGResourceMarker.cpp:
2346         * rendering/svg/RenderSVGRoot.cpp:
2347         * rendering/svg/RenderSVGShape.cpp:
2348         * rendering/svg/RenderSVGText.cpp:
2349
2350 2013-04-16  Maciej Stachowiak  <mjs@apple.com>
2351
2352         Remove even yet still more traces of v8
2353         https://bugs.webkit.org/show_bug.cgi?id=114693
2354
2355         Reviewed by Anders Carlsson.
2356
2357         No behavior change.
2358
2359         * bindings/generic/ActiveDOMCallback.h:
2360         (WebCore::ActiveDOMCallback::isScriptControllerTerminating): Remove a V8-specific
2361         method and the comment referencing it.
2362         * bindings/generic/ActiveDOMCallback.cpp:
2363         (WebCore::ActiveDOMCallback::isScriptControllerTerminating): ditto
2364         * fileapi/File.cpp:
2365         (WebCore::File::File): Remove a comment referencing v8
2366         * inspector/InjectedScriptExterns.js: ditto
2367
2368 2013-04-16  Alexey Proskuryakov  <ap@apple.com>
2369
2370         Remove unused AlternativeTextClient::dismissDictationAlternativeUI
2371         https://bugs.webkit.org/show_bug.cgi?id=114598
2372
2373         Reviewed by Ryosuke Niwa.
2374
2375         Removing dead code.
2376
2377         * WebCore.exp.in:
2378         * editing/mac/AlternativeTextUIController.h: Made dismissAlternatives() private.
2379         * page/AlternativeTextClient.h:
2380
2381 2013-04-16  Robert Hogan  <robert@webkit.org>
2382
2383         Float at exact multiple of line-height affects too many lines
2384         https://bugs.webkit.org/show_bug.cgi?id=112744
2385
2386         Reviewed by David Hyatt.
2387
2388         Tests: fast/block/float/float-with-fractional-height-vertical-lr.html
2389                fast/block/float/float-with-fractional-height.html
2390
2391         When adding floats to the interval tree used for testing floats' overlap with lineboxes
2392         truncate the dimensions of the float rather than rounding them. This matches the
2393         treatment of linebox dimensions so ensures the test for overlap is comparing like
2394         with like.
2395
2396         * rendering/RenderBlock.cpp:
2397         (WebCore::::collectIfNeeded):
2398         (WebCore::RenderBlock::FloatingObjects::intervalForFloatingObject):
2399         (WebCore::::string):
2400
2401 2013-04-16  Chris Fleizach  <cfleizach@apple.com>
2402
2403         AX: aria-valuetext is not exposed on OS X.
2404         https://bugs.webkit.org/show_bug.cgi?id=114628
2405
2406         Reviewed by Tim Horton.
2407
2408         aria-valuetext is only being exposed on ARIA controls. That's because there were
2409         checks in place so that ONLY ARIA defined controls would return anything related to valuetext.
2410         We should allow this to work on native controls as well.
2411
2412         Test: platform/mac/accessibility/aria-valuetext-on-native-slider.html
2413
2414         * accessibility/AccessibilityNodeObject.cpp:
2415         (WebCore::AccessibilityNodeObject::valueDescription):
2416         (WebCore):
2417         (WebCore::AccessibilityNodeObject::valueForRange):
2418         (WebCore::AccessibilityNodeObject::maxValueForRange):
2419         (WebCore::AccessibilityNodeObject::minValueForRange):
2420         * accessibility/AccessibilityNodeObject.h:
2421         (AccessibilityNodeObject):
2422         * accessibility/AccessibilityObject.cpp:
2423         (WebCore::AccessibilityObject::isRangeControl):
2424              Rename isARIAControl to isRangeControl and make it apply to all elements.
2425         * accessibility/AccessibilityObject.h:
2426
2427 2013-04-15  Jon Lee  <jonlee@apple.com>
2428
2429         RenderView should bail out of paintBoxDecorations() when painting with a different renderer
2430         https://bugs.webkit.org/show_bug.cgi?id=114665
2431         <rdar://problem/13434884>
2432
2433         Reviewed by Simon Fraser.
2434
2435         * rendering/RenderView.cpp:
2436         (WebCore::RenderView::paintBoxDecorations): Add a check to see if we should paint within the renderer.
2437         This check exists in all other implementations of paintBoxDecorations(), and correctly avoids painting the
2438         decorations if the root provided is not the RenderView.
2439
2440 2013-04-16  Max Vujovic  <mvujovic@adobe.com>
2441
2442         [CSS Shaders] Remove the cache of validated programs
2443         https://bugs.webkit.org/show_bug.cgi?id=112844
2444
2445         Reviewed by Dean Jackson.
2446
2447         Since we're caching CustomFilterProgram(s) now, we don't need another cache for
2448         CustomFilterValidatedProgram(s). With this patch, CustomFilterProgram stores a reference
2449         to a lazily created CustomFilterValidatedProgram, and CustomFilterGlobalContext no longer
2450         has a validated program cache.
2451
2452         Also, this patch removes the CustomFilterValidatedProgram's stored reference to
2453         CustomFilterGlobalContext. The removal of the validated program cache would cause
2454         this reference to become weak. Validated programs only needed to keep the global context
2455         reference in order to create a CustomFilterCompiledProgram. In this patch, we create
2456         CustomFilterCompiledProgram(s) in FECustomFilter instead of in CustomFilterValidatedProgram,
2457         so validated programs don't need to store the global context reference anymore.
2458
2459         No new tests. Just Refactoring.
2460
2461         * platform/graphics/filters/CustomFilterCompiledProgram.cpp:
2462         (WebCore::CustomFilterCompiledProgram::CustomFilterCompiledProgram):
2463         * platform/graphics/filters/CustomFilterGlobalContext.cpp:
2464         (WebCore::CustomFilterGlobalContext::~CustomFilterGlobalContext):
2465         * platform/graphics/filters/CustomFilterGlobalContext.h:
2466         (CustomFilterGlobalContext):
2467         * platform/graphics/filters/CustomFilterProgram.cpp:
2468         (WebCore::CustomFilterProgram::validatedProgram):
2469         (WebCore::CustomFilterProgram::setValidatedProgram):
2470         * platform/graphics/filters/CustomFilterProgram.h:
2471         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
2472         (WebCore::CustomFilterValidatedProgram::CustomFilterValidatedProgram):
2473         (WebCore::CustomFilterValidatedProgram::compiledProgram):
2474         (WebCore::CustomFilterValidatedProgram::setCompiledProgram):
2475         (WebCore::CustomFilterValidatedProgram::~CustomFilterValidatedProgram):
2476         * platform/graphics/filters/CustomFilterValidatedProgram.h:
2477         (CustomFilterValidatedProgram):
2478         * platform/graphics/filters/FECustomFilter.cpp:
2479         (WebCore::FECustomFilter::prepareForDrawing):
2480         * rendering/FilterEffectRenderer.cpp:
2481         * rendering/RenderLayer.cpp:
2482         (WebCore::RenderLayer::computeFilterOperations):
2483
2484 2013-04-16  Anthony Scian  <ascian@blackberry.com>
2485
2486         [BlackBerry] LayerTexture: check if the graphics context is NULL
2487         https://bugs.webkit.org/show_bug.cgi?id=114674
2488
2489         Reviewed by Rob Buis.
2490
2491         Internal PR: 256522
2492
2493         * platform/graphics/blackberry/LayerTexture.cpp:
2494         (WebCore::LayerTexture::setContentsToColor):
2495
2496 2013-04-13  Andreas Kling  <akling@apple.com>
2497
2498         REGRESSION(r148128): window.resizeTo doesn't work from Safari address bar.
2499         <rdar://problem/13635894>
2500         <http://webkit.org/b/114561>
2501
2502         Reviewed by Sam Weinig.
2503
2504         Suppressing window geometry changes while any user gesture is active was a bit too restrictive,
2505         and broke legitimate use-cases. Narrow it down to checking EventHandler::mousePressed().
2506
2507         No test yet, adding one is tracked by <http://webkit.org/b/114561>.
2508
2509         * page/DOMWindow.cpp:
2510         (WebCore::DOMWindow::allowedToChangeWindowGeometry):
2511
2512             Added to share code between all DOMWindow functions that alter window geometry.
2513
2514         (WebCore::DOMWindow::moveBy):
2515         (WebCore::DOMWindow::moveTo):
2516         (WebCore::DOMWindow::resizeBy):
2517         (WebCore::DOMWindow::resizeTo):
2518
2519 2013-04-16  Manuel Rego Casasnovas  <rego@igalia.com>
2520
2521         [GTK][EFL] Remove deprecated libsoup API usage
2522         https://bugs.webkit.org/show_bug.cgi?id=104894
2523
2524         Reviewed by Philippe Normand.
2525
2526         Based on a patch by Claudio Saavedra <csaavedra@igalia.com>.
2527         Remove LIBSOUP_USE_UNSTABLE_REQUEST_API and only include
2528         libsoup/soup.h.
2529
2530         * platform/network/ResourceHandleInternal.h:
2531         * platform/network/soup/GOwnPtrSoup.cpp:
2532         * platform/network/soup/ProxyResolverSoup.h:
2533         * platform/network/soup/ResourceErrorSoup.cpp:
2534         * platform/network/soup/ResourceHandleSoup.cpp:
2535         (WebCore::ensureSessionIsInitialized): No need to add the requester
2536         feature.
2537         (WebCore::createSoupRequestAndMessageForHandle): SoupSession has a
2538         requester API, use it.
2539
2540 2013-04-15  Maciej Stachowiak  <mjs@apple.com>
2541
2542         Remove more traces of the now-obsolete support for V8
2543         https://bugs.webkit.org/show_bug.cgi?id=114657
2544
2545         Reviewed by Ryosuke Niwa.
2546
2547         In addition to passing existing tests, I verified that the ElementFactory
2548         and ElementWrapperFactory files were all textually identical before and after.
2549
2550         * dom/CustomEvent.cpp:
2551         (WebCore): Remove Use(V8) bock.
2552         * dom/CustomEvent.h:
2553         (CustomEvent): ditto
2554         * dom/MessageEvent.cpp:
2555         (WebCore::MessageEvent::MessageEvent): ditto
2556         (WebCore::MessageEvent::initMessageEvent): ditto
2557         * dom/Node.h:
2558         (Node): ditto
2559         * dom/make_event_factory.pl:
2560         (generateImplementation): Remove V8 support.
2561         * dom/make_names.pl: Remove gobs of V8 support and simplify.
2562         (printJSElementIncludes): 
2563         (printConditionalElementIncludes):
2564         (printFactoryCppFile):
2565         (printWrapperFunctions):
2566         (printWrapperFactoryCppFile):
2567         (printWrapperFactoryHeaderFile):
2568         * inspector/InjectedScriptCanvasModuleSource.js: Remove V8 stack
2569         trace code.
2570         * platform/qt/PlatformSupport.h: Remove a macro only used for V8 
2571         bindings.
2572         * svg/SVGZoomAndPan.h:
2573         (SVGZoomAndPan): Remove mention of V8 from comment.
2574
2575 2013-04-15  Ryosuke Niwa  <rniwa@webkit.org>
2576
2577         Potential use after free in ApplyStyleCommand::splitAncestorsWithUnicodeBidi
2578         https://bugs.webkit.org/show_bug.cgi?id=114664
2579
2580         Reviewed by Oliver Hunt.
2581
2582         Use RefPtr as needed.
2583
2584         No new tests since this bug was discovered by code inspection.
2585
2586         * editing/ApplyStyleCommand.cpp:
2587         (WebCore::ApplyStyleCommand::splitAncestorsWithUnicodeBidi):
2588
2589 2013-04-15  Timothy Hatcher  <timothy@apple.com>
2590
2591         Web Inspector: Make var and function declarations work again in the Console.
2592
2593         https://webkit.org/b/114534
2594         rdar://problem/13614477
2595
2596         Reviewed by Oliver Hunt.
2597
2598         * inspector/InjectedScriptSource.js:
2599         (InjectedScript.prototype._evaluateOn): Use 'with' when not evaluating
2600         on a call frame.
2601
2602 2013-04-15  Seokju Kwon  <seokju.kwon@gmail.com>
2603
2604         Web Inspector: Add missing Localized strings
2605         https://bugs.webkit.org/show_bug.cgi?id=114656
2606
2607         Reviewed by Timothy Hatcher.
2608
2609         No tests because no behavior change is expected.
2610
2611         * English.lproj/localizedStrings.js:
2612
2613 2013-04-15  Dean Jackson  <dino@apple.com>
2614
2615         Rename restartedPlugin to isRestartedPlugin. This was
2616         review feedback from r148038 that I thought I fixed
2617         everywhere but failed.
2618         https://bugs.webkit.org/show_bug.cgi?id=114233
2619
2620         * html/HTMLPlugInElement.h:
2621         (WebCore::HTMLPlugInElement::isRestartedPlugin): Prefix with "is".
2622         * html/HTMLPlugInImageElement.cpp:
2623         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
2624         (WebCore::HTMLPlugInImageElement::setDisplayState):
2625         (WebCore::HTMLPlugInImageElement::removeSnapshotTimerFired):
2626         * html/HTMLPlugInImageElement.h:
2627         * rendering/RenderEmbeddedObject.cpp:
2628         (WebCore::RenderEmbeddedObject::paintContents):
2629         * rendering/RenderLayerBacking.cpp:
2630         (WebCore::isRestartedPlugin):
2631
2632 2013-04-15  Maciej Stachowiak  <mjs@apple.com>
2633
2634         Remove V8 attribtues from IDLAttributes.txt
2635         https://bugs.webkit.org/show_bug.cgi?id=114651
2636
2637         Reviewed by Sam Weinig.
2638
2639         No tests because no behavior change is expected.
2640
2641         * bindings/scripts/IDLAttributes.txt: Remove V8 attribtues.
2642         * html/track/TextTrackList.idl: Remove a stray V8-specific attribute
2643         (so I guess this change is not useless)
2644
2645 2013-04-15  James Craig  <james@cookiecrook.com>
2646
2647         WebKit should not expose AXSubrole:AXDescriptionList on Mountain Lion as it causes a regression in VoiceOver behavior
2648         https://bugs.webkit.org/show_bug.cgi?id=113975
2649
2650         Reviewed by Chris Fleizach.
2651
2652         Serve NSAccessibilityDescriptionListSubrole or NSAccessibilityDefinitionListSubrole
2653         depending on platform. Updated existing test coverage.
2654
2655         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2656         (-[WebAccessibilityObjectWrapper subrole]):
2657
2658 2013-04-15  Dean Jackson  <dino@apple.com>
2659
2660         Plugins that resize might need to be snapshotted.
2661         https://bugs.webkit.org/show_bug.cgi?id=102157
2662         <rdar://problem/12696259>
2663
2664         Reviewed by Tim Horton.
2665
2666         A plugin could avoid snapshotting if it started very
2667         small (below the threshold where we autostart), and then
2668         resized to be large (above the threshold). Detect this
2669         case and tell the plugin to snapshot.
2670
2671         There unfortunately is a bit of state to track when doing
2672         this. We have to start the snapshotting in a post-layout
2673         task, so we carry a flag to say we're checking size but
2674         not wanting the plugin to update (which would restart it).
2675         We also might be a plugin that would have already restarted
2676         due to a similar plugin being clicked or detected as dominant.
2677         So this patch introduces a member variable that tracks what
2678         decision has been made on snapshotting.
2679
2680         I also added some more logging to be more clear about what is
2681         happening to plugins going through the snapshot process, and
2682         changed the order of the tests in the algorithm so that domain
2683         detection comes before examining the size.
2684
2685         * html/HTMLPlugInImageElement.cpp:
2686         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): Initialise
2687             the two new member variables.
2688         (WebCore::HTMLPlugInImageElement::setDisplayState): Mark a restarted
2689             plugin as NeverSnapshot. This means that if it later resizes above the
2690             threshold, it won't trigger the snapshot detection.
2691         (WebCore::HTMLPlugInImageElement::checkSnapshotStatus): Renamed from
2692             updateSnapshotInfo. This now updates the snapshot, but also runs
2693             the check for size changes.
2694         (WebCore::addPlugInsFromNodeListMatchingPlugInOrigin): Gather all plugins
2695             that look like a restarting plugin, not just those snapshotted. That
2696             way they can all be marked as NeverSnapshot.
2697         (WebCore::HTMLPlugInImageElement::restartSimilarPlugIns): Bless every
2698             plugin that looks similar, whether or not it is snapshotted.
2699         (WebCore::HTMLPlugInImageElement::userDidClickSnapshot): More logging.
2700         (WebCore::HTMLPlugInImageElement::setIsPrimarySnapshottedPlugIn): Ditto.
2701         (WebCore::HTMLPlugInImageElement::checkSizeChangeForSnapshotting): New
2702             method. If the plugin was below the threshold and is now above it,
2703             begin the snapshotting process.
2704         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Plugins
2705             that were marked as NeverSnapshot should start immediately. Move the origin
2706             test earlier in the method. If a plugin avoided snapshotting due to size,
2707             remember the size.
2708         (WebCore::HTMLPlugInImageElement::subframeLoaderDidCreatePlugIn): Mark the
2709             plugin as NeverSnapshot.
2710
2711         * html/HTMLPlugInImageElement.h:
2712         (HTMLPlugInImageElement): Four new member variables:
2713             - the decision we made regarding snapshotting (or not), uses the SnapshotDecision enum
2714             - the size when it avoided snapshotting
2715             - a flag to indicate the post layout update was triggered due to
2716               a size change
2717         (WebCore::HTMLPlugInImageElement::needsCheckForSizeChange): New method.
2718         (WebCore::HTMLPlugInImageElement::setNeedsCheckForSizeChange): New method.
2719         (WebCore::HTMLPlugInImageElement::snapshotDecision): Return the decision
2720             regarding snapshotting or not snapshotting.
2721
2722         * page/FrameView.cpp:
2723         (WebCore::FrameView::addWidgetToUpdate): Guard updating the widget. We don't
2724             want to do it when we're checking for a size change in the plugin.
2725         (WebCore::FrameView::updateWidget): Call new name.
2726
2727         * plugins/PluginViewBase.h:
2728         (WebCore::PluginViewBase::beginSnapshottingRunningPlugin): Empty virtual
2729             method to snapshot a running plugin.
2730
2731         * rendering/RenderEmbeddedObject.cpp:
2732         (WebCore::RenderEmbeddedObject::layout): If the plugin has increased in
2733             size add it to the post layout list so that it will be checked.
2734
2735 2013-04-15  Chris Fleizach  <cfleizach@apple.com>
2736
2737         activating a focused link to an in-page fragment ID should transfer focus to the target of the link when possible
2738         https://bugs.webkit.org/show_bug.cgi?id=17450
2739
2740         Reviewed by Maciej Stachowiak.
2741
2742         When a fragment is scrolled to due to an activation event or on load, focus should attempt to 
2743         move to the fragment if possible.
2744
2745         Test: fast/dom/fragment-activation-focuses-target.html
2746
2747         * page/FrameView.cpp:
2748         (WebCore::FrameView::scrollToAnchor):
2749
2750 2013-04-12  Maciej Stachowiak  <mjs@apple.com>
2751
2752         Remove V8-specific extended attributes from IDL files
2753         https://bugs.webkit.org/show_bug.cgi?id=114523
2754
2755         Reviewed by Geoffrey Garen.
2756
2757         No tests because no behavior change is expected.
2758
2759         * Modules/encryptedmedia/MediaKeyMessageEvent.idl:
2760         * Modules/encryptedmedia/MediaKeyNeededEvent.idl:
2761         * Modules/encryptedmedia/MediaKeySession.idl:
2762         * Modules/encryptedmedia/MediaKeys.idl:
2763         * Modules/filesystem/HTMLInputElementFileSystem.idl:
2764         * Modules/indexeddb/IDBAny.idl:
2765         * Modules/mediasource/MediaSource.idl:
2766         * Modules/mediasource/SourceBuffer.idl:
2767         * Modules/mediasource/SourceBufferList.idl:
2768         * Modules/mediastream/MediaStream.idl:
2769         * Modules/webaudio/AudioDestinationNode.idl:
2770         * html/track/TextTrackCue.idl:
2771         * html/track/TextTrackCueList.idl:
2772         * html/track/TextTrackList.idl:
2773         * html/track/TextTrackRegion.idl:
2774         * html/track/TextTrackRegionList.idl:
2775         * html/track/TrackEvent.idl:
2776         * storage/Storage.idl:
2777         * svg/SVGDocument.idl:
2778         * svg/SVGElement.idl:
2779         * workers/WorkerContext.idl:
2780         * xml/XMLHttpRequest.idl:
2781         * xml/XPathNSResolver.idl:
2782
2783 2013-04-15  Anders Carlsson  <andersca@apple.com>
2784
2785         ScriptWrappable subclasses shouldn't have to include WeakInlines.h
2786         https://bugs.webkit.org/show_bug.cgi?id=114641
2787
2788         Reviewed by Alexey Proskuryakov.
2789
2790         Remove ScriptWrappableInlines.h includes, they're not needed anymore.
2791
2792         * css/WebKitCSSMatrix.cpp:
2793         * dom/ClientRect.cpp:
2794         * dom/ClientRectList.cpp:
2795         * dom/Clipboard.cpp:
2796         * dom/DOMStringMap.cpp:
2797         * dom/Event.cpp:
2798         * dom/MutationRecord.cpp:
2799         * fileapi/FileList.cpp:
2800         * page/BarInfo.cpp:
2801         * plugins/DOMMimeTypeArray.cpp:
2802         * plugins/DOMPlugin.cpp:
2803         * plugins/DOMPluginArray.cpp:
2804         * storage/Storage.cpp:
2805
2806 2013-04-15  Igor Oliveira  <igor.o@sisa.samsung.com>
2807
2808         Call directly RenderBlock::deleteLineBoxTree
2809         https://bugs.webkit.org/show_bug.cgi?id=102761
2810
2811         Reviewed by Darin Adler.
2812
2813         Instead of implementing RenderLineBoxList::deleteLineBoxTree logic inside 
2814         RenderBlock::determineStartPosition, we can reuse the code. The commentaries added
2815         in the changeset #86628 are not valid anymore, nextRootBox is casting m_nextLineBox 
2816         and nextLineBox is returning m_nextLineBox.
2817
2818         * rendering/RenderBlockLineLayout.cpp:
2819         (WebCore::RenderBlock::determineStartPosition):
2820
2821 2013-04-15  Anders Carlsson  <andersca@apple.com>
2822
2823         Remove files related to quota and proximity events from the Xcode project
2824         https://bugs.webkit.org/show_bug.cgi?id=114635
2825
2826         Reviewed by Benjamin Poulain.
2827
2828         * WebCore.xcodeproj/project.pbxproj:
2829         * history/PageCache.cpp:
2830         * page/DOMWindow.cpp:
2831
2832 2013-04-15  Patrick Gansterer  <paroga@webkit.org>
2833
2834         [CMake] Add WTF_USE_*_UNICODE variables
2835         https://bugs.webkit.org/show_bug.cgi?id=114556
2836
2837         Reviewed by Brent Fulgham.
2838
2839         WTF_USE_ICU_UNICODE and WTF_USE_WCHAR_UNICODE are used to
2840         reduce duplication in the platform specific CMake files.
2841
2842         * CMakeLists.txt:
2843         * PlatformBlackBerry.cmake:
2844         * PlatformEfl.cmake:
2845         * PlatformWinCE.cmake:
2846
2847 2013-04-15  Eric Carlson  <eric.carlson@apple.com>
2848
2849         HTMLMediaElement::removeTextTrack should clear track client
2850         https://bugs.webkit.org/show_bug.cgi?id=114630
2851
2852         Reviewed by Jer Noble.
2853
2854         No new tests, this is clean-up that prevents a potential crash.
2855
2856         * html/HTMLMediaElement.cpp:
2857         (WebCore::HTMLMediaElement::removeTextTrack): Clear the track client.
2858
2859 2013-04-15  Robert Hogan  <robert@webkit.org>
2860
2861         An inline element with an absolutely positioned child does not correctly calculate/render padding and margin
2862         https://bugs.webkit.org/show_bug.cgi?id=47554
2863
2864         Reviewed by David Hyatt.
2865
2866         When looking for padding/margin to add from the start of a child's parent skip past any leading positioned siblings as 
2867         we don't add the padding/margin of the common parent when skipping past them in |skipLeadingWhitespace|. We
2868         don't need to worry about the case of trailing positioned objects as we will account for their parent's
2869         border/margin/padding when we encounter them in |nextSegmentBreak|.
2870
2871         Test: fast/inline/padding-before-leading-positioned-element-contributes-width.html
2872
2873         * rendering/RenderBlockLineLayout.cpp:
2874         (WebCore::previousInFlowSibling):
2875         (WebCore):
2876         (WebCore::inlineLogicalWidth):
2877
2878 2013-04-15  peavo@outlook.com  <peavo@outlook.com>
2879
2880         [WinCairo] Compile fix.
2881         https://bugs.webkit.org/show_bug.cgi?id=114623
2882
2883         Reviewed by Brent Fulgham.
2884
2885         * platform/network/curl/CookieJarCurl.cpp: Added required header files.
2886
2887 2013-04-15  Rob Buis  <rbuis@rim.com>
2888
2889         Fix some compiler warnings (miscellaneous)
2890         https://bugs.webkit.org/show_bug.cgi?id=80790
2891
2892         Reviewed by Darin Adler.
2893
2894         It does not seem needed to initialize jpeg_create_compress struct to zero,
2895         all that is needed is set the err field. See for instance SkImageDecoder_libjpeg.cpp.
2896
2897         * platform/image-encoders/JPEGImageEncoder.cpp:
2898         (WebCore::compressRGBABigEndianToJPEG):
2899
2900 2013-04-15  Patrick Gansterer  <paroga@webkit.org>
2901
2902         [GTK] Remove platform specific implementation of KURL::fileSystemPath()
2903         https://bugs.webkit.org/show_bug.cgi?id=114133
2904
2905         Reviewed by Martin Robinson.
2906
2907         r147883 added a generic implementation of this function,
2908         which can be used by all ports to share the code.
2909
2910         * GNUmakefile.list.am:
2911         * platform/KURL.cpp:
2912         (WebCore):
2913         * platform/gtk/KURLGtk.cpp: Removed.
2914
2915 2013-04-15  Csaba Osztrogon√°c  <ossy@webkit.org>
2916
2917         Debug buildfix after r148433.
2918         https://bugs.webkit.org/show_bug.cgi?id=108295
2919
2920         Reviewed by Allan Sandfeld Jensen.
2921
2922         * platform/graphics/texmap/TextureMapperLayer.h:
2923         (WebCore::TextureMapperLayer::children): Added.
2924
2925 2013-04-15  Noam Rosenthal  <noam@webkit.org>
2926
2927         Coordinated Graphics: Remove GraphicsLayerTextureMapper dependency from CoordinatedGraphicsScene.
2928         https://bugs.webkit.org/show_bug.cgi?id=108295
2929
2930         Since all the changes to the TextureMapperLayer tree now come in a single IPC message via
2931         CoordinatedGraphicsState, we don't need the additional buffering done in GraphicsLayerTextureMapper.
2932
2933         This reduces unnecessary function calls, and also streamlines GraphicsLayerTextureMapper to be used
2934         only in WebKit1 (without CoordinatedGraphics).
2935
2936         Reviewed by Allan Sandfeld Jensen.
2937
2938         No new tests, refactor only.
2939
2940         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2941         (WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
2942         (WebCore::GraphicsLayerTextureMapper::setNeedsDisplay):
2943         (WebCore::GraphicsLayerTextureMapper::setNeedsDisplayInRect):
2944         (WebCore::GraphicsLayerTextureMapper::setDrawsContent):
2945         (WebCore::GraphicsLayerTextureMapper::prepareBackingStoreIfNeeded):
2946         (WebCore::GraphicsLayerTextureMapper::updateDebugBorderAndRepaintCount):
2947         (WebCore::GraphicsLayerTextureMapper::updateBackingStoreIfNeeded):
2948         (WebCore):
2949         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
2950         (GraphicsLayerTextureMapper):
2951             Removed references to m_hasOwnBackingStore, which was done to separate the CoordinatedGraphics
2952             path from the WK1 path.
2953
2954         * platform/graphics/texmap/TextureMapperLayer.h:
2955         (WebCore::TextureMapperLayer::drawsContent):
2956         (WebCore::TextureMapperLayer::contentsAreVisible):
2957         (WebCore::TextureMapperLayer::size):
2958         (WebCore::TextureMapperLayer::opacity):
2959         (WebCore::TextureMapperLayer::transform):
2960         (WebCore::TextureMapperLayer::isShowingRepaintCounter):
2961         (WebCore::TextureMapperLayer::fixedToViewport):
2962         (TextureMapperLayer):
2963             Added a few public functions needed by CoordinatedGraphicsScene.
2964
2965         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
2966         (WebCore::layerShouldHaveBackingStore):
2967         (WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext):
2968         (WebCore::CoordinatedGraphicsScene::paintToGraphicsContext):
2969         (WebCore::CoordinatedGraphicsScene::adjustPositionForFixedLayers):
2970         (WebCore::CoordinatedGraphicsScene::createCanvasIfNeeded):
2971         (WebCore::CoordinatedGraphicsScene::syncCanvasIfNeeded):
2972         (WebCore::CoordinatedGraphicsScene::destroyCanvasIfNeeded):
2973         (WebCore::CoordinatedGraphicsScene::setLayerRepaintCountIfNeeded):
2974         (WebCore::CoordinatedGraphicsScene::setLayerChildrenIfNeeded):
2975         (WebCore::CoordinatedGraphicsScene::setLayerFiltersIfNeeded):
2976         (WebCore::CoordinatedGraphicsScene::setLayerState):
2977         (WebCore::CoordinatedGraphicsScene::getLayerByIDIfExists):
2978         (WebCore::CoordinatedGraphicsScene::createLayer):
2979         (WebCore::CoordinatedGraphicsScene::deleteLayer):
2980         (WebCore::CoordinatedGraphicsScene::setRootLayerID):
2981         (WebCore::CoordinatedGraphicsScene::prepareContentBackingStore):
2982         (WebCore::CoordinatedGraphicsScene::createBackingStoreIfNeeded):
2983         (WebCore::CoordinatedGraphicsScene::removeBackingStoreIfNeeded):
2984         (WebCore::CoordinatedGraphicsScene::resetBackingStoreSizeToLayerSize):
2985         (WebCore::CoordinatedGraphicsScene::createTilesIfNeeded):
2986         (WebCore::CoordinatedGraphicsScene::removeTilesIfNeeded):
2987         (WebCore::CoordinatedGraphicsScene::updateTilesIfNeeded):
2988         (WebCore::CoordinatedGraphicsScene::assignImageBackingToLayer):
2989         (WebCore::CoordinatedGraphicsScene::commitSceneState):
2990         (WebCore::CoordinatedGraphicsScene::ensureRootLayer):
2991         (WebCore::CoordinatedGraphicsScene::setLayerAnimationsIfNeeded):
2992         (WebCore::CoordinatedGraphicsScene::findScrollableContentsLayerAt):
2993         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
2994         (CoordinatedGraphicsScene):
2995         (WebCore::CoordinatedGraphicsScene::layerByID):
2996         (WebCore::CoordinatedGraphicsScene::rootLayer):
2997             Use TextureMapperLayer instead of GraphicsLayer and GraphicsLayerTextureMapper.
2998
2999 2013-04-15  Antti Koivisto  <antti@apple.com>
3000
3001         Dynamically triggered subframe loads are causing tile churn
3002         https://bugs.webkit.org/show_bug.cgi?id=114440
3003         
3004         Reviewed by Andreas Kling.
3005         
3006         In some cases we switch in and out of minimal tiles multiple times during page loading. This
3007         creates tile churn where we create speculative tiles and then throw them out. This can be
3008         caused by various reasons including dynamically created subframes.
3009
3010         * page/FrameView.cpp:
3011         (WebCore::FrameView::setIsVisuallyNonEmpty):
3012         
3013             Stay in minimal tiles modes until there is some visual contents. This avoids switching out from minimal
3014             tiles while awaiting response for the initial requests.
3015
3016         * page/FrameView.h:
3017         * rendering/RenderLayerBacking.cpp:
3018         (WebCore::RenderLayerBacking::RenderLayerBacking):
3019         (WebCore::computeTileCoverage):
3020         * rendering/RenderLayerBacking.h:
3021         (WebCore::RenderLayerBacking::didSwitchToFullTileCoverageDuringLoading):
3022         (WebCore::RenderLayerBacking::setDidSwitchToFullTileCoverageDuringLoading):
3023         
3024             Only switch into minimal coverage mode once per page load.
3025
3026         (RenderLayerBacking):
3027
3028 2013-04-15  Rune Lillesveen  <rune@opera.com>
3029
3030         color-index media feature not supported
3031         https://bugs.webkit.org/show_bug.cgi?id=114468
3032
3033         Reviewed by Kenneth Rohde Christiansen.
3034
3035         Support the color-index media feature. Currently assumes that no WebKit
3036         browser will have an output device that uses a color lookup table.
3037
3038         Tests: fast/media/mq-color-index-01.html
3039                fast/media/mq-color-index-02.html
3040
3041         * css/MediaFeatureNames.h:
3042         (MediaFeatureNames):
3043         * css/MediaQueryEvaluator.cpp:
3044         (WebCore::color_indexMediaFeatureEval):
3045         (WebCore):
3046         (WebCore::min_color_indexMediaFeatureEval):
3047         (WebCore::max_color_indexMediaFeatureEval):
3048         * css/MediaQueryExp.cpp:
3049         (WebCore::featureWithPositiveInteger):
3050         (WebCore::featureWithoutValue):
3051
3052 2013-04-15  Balazs Kelemen  <kbalazs@webkit.org>
3053
3054         [CoordGfx] Background color should not be part of GraphicsLayerState
3055         https://bugs.webkit.org/show_bug.cgi?id=113785
3056
3057         Page background is independent from layer state, send it to the UI
3058         as soon as possible.
3059
3060         Should not cause observable change in behavior so no new tests.
3061
3062         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
3063         (WebCore::CoordinatedGraphicsScene::commitSceneState):
3064         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
3065
3066 2013-04-15  Carlos Garcia Campos  <cgarcia@igalia.com>
3067
3068         [BlackBerry] Filesystem callback notifyCreateSnapshotFileAndReadMetadata can be called on the wring thread
3069         https://bugs.webkit.org/show_bug.cgi?id=114610
3070
3071         Reviewed by Xan Lopez.
3072
3073         Override notifyCreateSnapshotFileAndReadMetadata to make sure the
3074         callback is called on the right thread.
3075
3076         Fixes a crash in several fast/filesystem test in debug builds.
3077
3078         * platform/blackberry/WorkerPlatformAsyncFileSystemCallbacks.cpp:
3079         (WebCore::WorkerPlatformAsyncFileSystemCallbacks::notifyCreateSnapshotFileAndReadMetadata):
3080         (WebCore::WorkerPlatformAsyncFileSystemCallbacks::notifyCreateSnapshotFileAndReadMetadataOnWorkerThread):
3081         * platform/blackberry/WorkerPlatformAsyncFileSystemCallbacks.h:
3082
3083 2013-04-15  Arvid Nilsson  <anilsson@rim.com>
3084
3085         [BlackBerry][CSS Filters] Non-image content disappears when filter applied
3086         https://bugs.webkit.org/show_bug.cgi?id=114498
3087
3088         Reviewed by Carlos Garcia Campos.
3089
3090         Applying a filter to a div with simple text content caused the div to
3091         disappear.
3092
3093         In https://bugs.webkit.org/show_bug.cgi?id=114276, we added some GL
3094         state save/restore code for vertex attributes to make sure the state
3095         changes done by BlackBerry::Platform::Graphics don't interfere with
3096         GL code executing in WebKit. However, saving and restoring vertex
3097         attribute state won't do much good if those attributes were never
3098         enabled to begin with. Fixed by enabling vertex attributes
3099         appropriately when setting them, so that state can be saved and
3100         restored.
3101
3102         All the CSS Filters layout tests apply the filters to simple rectangles
3103         or images, there's nothing sufficiently complex that we manage to
3104         trigger this GL state conflict in the BlackBerry port. This suggests
3105         adding a new platform-specific layout test would be appropriate, but
3106         since we don't use pixel tests yet, such a test would not help detect
3107         regressions. Ultimately we decided against adding a layout test for
3108         this bug at this time.
3109
3110         * platform/graphics/blackberry/LayerFilterRenderer.cpp:
3111         (WebCore::LayerFilterRenderer::applyActions):
3112
3113 2013-04-14  Jaehun Lim  <ljaehun.lim@samsung.com>
3114
3115         [css3-text] Parsing -webkit-hanging value for text-indent from css3-text
3116         https://bugs.webkit.org/show_bug.cgi?id=113680
3117
3118         Reviewed by Andreas Kling.
3119
3120         This patch is the parsing part to support hanging value for text-indent.
3121         "hanging" means "Inverts which lines are affected."
3122         It's prefixed and guarded by CSS3_TEXT flag.
3123
3124         No new tests, this patch updates existing tests.
3125
3126         * css/CSSComputedStyleDeclaration.cpp:
3127         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3128         * css/CSSParser.cpp:
3129         (WebCore::CSSParser::parseTextIndent): Parsed "-webkit-hanging" with "-webkit-each-line".
3130         * css/CSSValueKeywords.in: Added "-webkit-hanging" keyword.
3131         * css/DeprecatedStyleBuilder.cpp:
3132         (WebCore::ApplyPropertyTextIndent::applyInheritValue):
3133         (WebCore::ApplyPropertyTextIndent::applyInitialValue):
3134         (WebCore::ApplyPropertyTextIndent::applyValue):
3135         * rendering/style/RenderStyle.h:
3136         * rendering/style/RenderStyleConstants.h: Added enum TextIndentType.
3137         * rendering/style/StyleRareInheritedData.cpp:
3138         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
3139         (WebCore::StyleRareInheritedData::operator==):
3140         * rendering/style/StyleRareInheritedData.h: Added m_textIndentType.
3141         (StyleRareInheritedData):
3142             Added the usual getter / setter / initial methods for m_textIndentType.
3143
3144 2013-04-14  Sam Weinig  <sam@webkit.org>
3145
3146         Move Mac specific snapshotting code into its own file
3147         https://bugs.webkit.org/show_bug.cgi?id=114597
3148
3149         Reviewed by Andreas Kling.
3150
3151         * WebCore.exp.in:
3152         * WebCore.xcodeproj/project.pbxproj:
3153         * bindings/objc/DOM.mm:
3154         (-[DOMRange renderedImageForcingBlackText:]):
3155         * page/Frame.h:
3156         * page/mac/FrameMac.mm:
3157         (WebCore::Frame::nodeImage):
3158         (WebCore::Frame::dragImageForSelection):
3159         * page/mac/FrameSnapshottingMac.h: Added.
3160         * page/mac/FrameSnapshottingMac.mm: Added.
3161         (WebCore::imageFromRect):
3162         (WebCore::selectionImage):
3163         (WebCore::rangeImage):
3164         (WebCore::snapshotDragImage):
3165         * platform/mac/ClipboardMac.mm:
3166         (WebCore::ClipboardMac::dragNSImage):
3167         Move the four Mac specific snapshotting functions in Frame.h into FrameSnapshottingMac.h/mm and turn
3168         them into free standing functions.
3169
3170 2013-04-14  Andreas Kling  <akling@apple.com>
3171
3172         Hawtfix Mac build.
3173
3174         * WebCore.exp.in:
3175
3176 2013-04-14  Andreas Kling  <akling@apple.com>
3177
3178         Only MutableStylePropertySets should be able to have CSSOM wrappers.
3179         <http://webkit.org/b/114595>
3180
3181         Reviewed by Antti Koivisto.
3182
3183         Tighten typing so that only MutableStylePropertySets can have CSSOM wrappers associated.
3184         This allows us to get rid of the out-of-line base class destructor.
3185
3186         * WebCore.exp.in:
3187         * css/StylePropertySet.cpp:
3188         (WebCore::MutableStylePropertySet::~MutableStylePropertySet):
3189         (WebCore::MutableStylePropertySet::cssStyleDeclaration):
3190         (WebCore::MutableStylePropertySet::ensureInlineCSSStyleDeclaration):
3191         * css/StylePropertySet.h:
3192         (StylePropertySet):
3193         (MutableStylePropertySet):
3194         * dom/StyledElement.cpp:
3195         (WebCore::StyledElement::inlineStyleCSSOMWrapper):
3196
3197 2013-04-14  Andreas Kling  <akling@apple.com>
3198
3199         Remove unused function declaration StylePropertySet::setNeedsStyleRecalc().
3200
3201         Rubber-stamped by Antti Koivisto.
3202
3203         * css/StylePropertySet.h:
3204         (StylePropertySet):
3205
3206 2013-04-14  Andreas Kling  <akling@apple.com>
3207
3208         Move StylePropertySet internal storage access helpers to subclass.
3209         <http://webkit.org/b/114592>
3210
3211         Reviewed by Antti Koivisto.
3212
3213         Removed mutablePropertyVector() since most call sites are inside MutableStylePropertySet
3214         and can access m_propertyVector directly. The few ones that aren't can just cast.
3215
3216         For ImmutableStylePropertySet, moved value/metadata array accessors to the subclass
3217         and remove "immutable" from their names.
3218
3219         * css/StylePropertySet.cpp:
3220         (WebCore::StylePropertySet::immutableCopyIfNeeded):
3221         (WebCore::ImmutableStylePropertySet::ImmutableStylePropertySet):
3222         (WebCore::ImmutableStylePropertySet::~ImmutableStylePropertySet):
3223         (WebCore::MutableStylePropertySet::MutableStylePropertySet):
3224         (WebCore::MutableStylePropertySet::removeProperty):
3225         (WebCore::MutableStylePropertySet::removePrefixedOrUnprefixedProperty):
3226         (WebCore::MutableStylePropertySet::setProperty):
3227         (WebCore::MutableStylePropertySet::appendPrefixingVariantProperty):
3228         (WebCore::MutableStylePropertySet::parseDeclaration):
3229         (WebCore::MutableStylePropertySet::addParsedProperties):
3230         (WebCore::MutableStylePropertySet::clear):
3231         (WebCore::MutableStylePropertySet::removePropertiesInSet):
3232         (WebCore::MutableStylePropertySet::findCSSPropertyWithID):
3233         (WebCore::MutableStylePropertySet::removeEquivalentProperties):
3234         (WebCore::StylePropertySet::reportMemoryUsage):
3235         * css/StylePropertySet.h:
3236         (PropertyReference):
3237         (StylePropertySet):
3238         (ImmutableStylePropertySet):
3239         (WebCore::ImmutableStylePropertySet::valueArray):
3240         (WebCore::ImmutableStylePropertySet::metadataArray):
3241         (WebCore::StylePropertySet::PropertyReference::propertyMetadata):
3242         (WebCore::StylePropertySet::PropertyReference::propertyValue):
3243         (WebCore::StylePropertySet::propertyCount):
3244
3245 2013-04-14  Andreas Kling  <akling@apple.com>
3246
3247         Specialize propertyCount() in StylePropertySet subclasses.
3248         <http://webkit.org/b/114590>
3249
3250         Reviewed by Antti Koivisto.
3251
3252         Avoid branching on m_isMutable in code that already knows which type of set it is.
3253
3254         * css/StylePropertySet.h:
3255         (WebCore::ImmutableStylePropertySet::propertyCount):
3256         (ImmutableStylePropertySet):
3257         (WebCore::MutableStylePropertySet::propertyCount):
3258         (MutableStylePropertySet):
3259
3260 2013-04-14  Andreas Kling  <akling@apple.com>
3261
3262         Move property setting/removing functions to MutableStylePropertySet.
3263         <http://webkit.org/b/114589>
3264
3265         Reviewed by Antti Koivisto.
3266
3267         Move all functions for setting/removing properties from StylePropertySet to MutableStylePropertySet.
3268         Had to change SVGElement::animatedSMILStyleProperties() & friends to hand out MutableStylePropertySet*
3269         which was always the internal type anyway.
3270
3271         * css/StylePropertySet.cpp:
3272         (WebCore::MutableStylePropertySet::removeShorthandProperty):
3273         (WebCore::MutableStylePropertySet::removeProperty):
3274         (WebCore::MutableStylePropertySet::removePrefixedOrUnprefixedProperty):
3275         (WebCore::MutableStylePropertySet::setProperty):
3276         (WebCore::MutableStylePropertySet::appendPrefixingVariantProperty):
3277         (WebCore::MutableStylePropertySet::setPrefixingVariantProperty):
3278         (WebCore::MutableStylePropertySet::mergeAndOverrideOnConflict):
3279         (WebCore::MutableStylePropertySet::removeBlockProperties):
3280         (WebCore::MutableStylePropertySet::removePropertiesInSet):
3281         (WebCore::MutableStylePropertySet::findCSSPropertyWithID):
3282         (WebCore::MutableStylePropertySet::removeEquivalentProperties):
3283         * css/StylePropertySet.h:
3284         (StylePropertySet):
3285         (MutableStylePropertySet):
3286         * editing/ApplyStyleCommand.cpp:
3287         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
3288         (WebCore::ApplyStyleCommand::removeEmbeddingUpToEnclosingBlock):
3289         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
3290         * editing/EditingStyle.cpp:
3291         (WebCore::EditingStyle::triStateOfStyle):
3292         (WebCore::removePropertiesInStyle):
3293         (WebCore::reconcileTextDecorationProperties):
3294         * svg/SVGAnimateElement.cpp:
3295         (WebCore::applyCSSPropertyToTarget):
3296         * svg/SVGElement.cpp:
3297         (WebCore::SVGElement::animatedSMILStyleProperties):
3298         (WebCore::SVGElement::ensureAnimatedSMILStyleProperties):
3299         * svg/SVGElement.h:
3300         (SVGElement):
3301         * svg/SVGElementRareData.h:
3302         (WebCore::SVGElementRareData::animatedSMILStyleProperties):
3303         (WebCore::SVGElementRareData::ensureAnimatedSMILStyleProperties):
3304         (SVGElementRareData):
3305
3306 2013-04-14  Andreas Kling  <akling@apple.com>
3307
3308         EditingStyle should have a MutableStylePropertySet internally.
3309         <http://webkit.org/b/114588>
3310
3311         Reviewed by Anders Carlsson.
3312
3313         Switch EditingStyle::m_mutableStyle to a RefPtr<MutableStylePropertySet>.
3314
3315         * css/StylePropertySet.cpp:
3316         (WebCore::StylePropertySet::copyBlockProperties):
3317         * css/StylePropertySet.h:
3318         (StylePropertySet):
3319         * editing/EditingStyle.cpp:
3320         (WebCore::EditingStyle::setStyle):
3321         (WebCore::EditingStyle::mergeStyleFromRules):
3322         (WebCore::StyleChange::StyleChange):
3323         (WebCore::setTextDecorationProperty):
3324         (WebCore::StyleChange::extractTextStyles):
3325         (WebCore::diffTextDecorations):
3326         (WebCore::getPropertiesNotIn):
3327         * editing/EditingStyle.h:
3328         (WebCore::EditingStyle::style):
3329         (EditingStyle):
3330         (StyleChange):
3331
3332 2013-04-14  Andreas Kling  <akling@apple.com>
3333
3334         Move addParsedProperty/addParsedProperties to MutableStylePropertySet.
3335         <http://webkit.org/b/114587>
3336
3337         Reviewed by Antti Koivisto.
3338
3339         All CSSParser methods that mutate an existing StylePropertySet now take a MutableStylePropertySet*
3340         instead of a StylePropertySet*.
3341
3342         * css/CSSParser.cpp:
3343         (WebCore::parseColorValue):
3344         (WebCore::parseSimpleLengthValue):
3345         (WebCore::parseKeywordValue):
3346         (WebCore::parseTranslateTransformValue):
3347         (WebCore::CSSParser::parseValue):
3348         (WebCore::CSSParser::parseDeclaration):
3349         * css/CSSParser.h:
3350         (CSSParser):
3351         * css/StylePropertySet.cpp:
3352         (WebCore::StylePropertySet::setProperty):
3353         (WebCore::MutableStylePropertySet::addParsedProperties):
3354         (WebCore::MutableStylePropertySet::addParsedProperty):
3355         * css/StylePropertySet.h:
3356         (StylePropertySet):
3357         (MutableStylePropertySet):
3358         * css/ViewportStyleResolver.h:
3359         (ViewportStyleResolver):
3360
3361 2013-04-14  Andreas Kling  <akling@apple.com>
3362
3363         CSSParser should return ImmutableStylePropertySets.
3364         <http://webkit.org/b/114585>
3365
3366         Reviewed by Anders Carlsson.
3367
3368         The StylePropertySets created by CSSParser were already immutable.
3369         Let this be reflected in the pointer types returned.
3370
3371         * css/CSSParser.cpp:
3372         (WebCore::CSSParser::parseInlineStyleDeclaration):
3373         (WebCore::CSSParser::parseDeclaration):
3374         (WebCore::CSSParser::createStylePropertySet):
3375         * css/CSSParser.h:
3376         (CSSParser):
3377
3378 2013-04-14  Andreas Kling  <akling@apple.com>
3379
3380         Move StylePropertySet::createImmutable() to ImmutableStylePropertySet.
3381         <http://webkit.org/b/114584>
3382
3383         Reviewed by Anders Carlsson.
3384
3385         StylePropertySet::createImmutable() -> ImmutableStylePropertySet::create()
3386         Also, immutableCopyIfNeeded() now returns a PassRefPtr<ImmutableStylePropertySet>.
3387
3388         * css/CSSParser.cpp:
3389         (WebCore::CSSParser::createStylePropertySet):
3390         * css/StylePropertySet.cpp:
3391         (WebCore::ImmutableStylePropertySet::create):
3392         (WebCore::StylePropertySet::immutableCopyIfNeeded):
3393         * css/StylePropertySet.h:
3394         (StylePropertySet):
3395         (ImmutableStylePropertySet):
3396
3397 2013-04-14  Andreas Kling  <akling@apple.com>
3398
3399         Move parseDeclaration() and clear() to MutableStylePropertySet.
3400         <http://webkit.org/b/114583>
3401
3402         Reviewed by Anders Carlsson.
3403
3404         ...and remove ASSERT(isMutable()) from the function bodies.
3405
3406         * svg/SVGFontFaceElement.cpp:
3407         (WebCore::SVGFontFaceElement::removedFrom):
3408
3409             Use clear() directly instead of taking an empty string through the CSS parser.
3410
3411         * css/StylePropertySet.cpp:
3412         (WebCore::MutableStylePropertySet::parseDeclaration):
3413         (WebCore::MutableStylePropertySet::clear):
3414         * css/StylePropertySet.h:
3415         (StylePropertySet):
3416         (MutableStylePropertySet):
3417         * dom/StyledElement.cpp:
3418         (WebCore::StyledElement::setInlineStyleFromString):
3419
3420 2013-04-14  Andreas Kling  <akling@apple.com>
3421
3422         Move CSSOM classes to using MutableStylePropertySet over StylePropertySet.
3423         <http://webkit.org/b/114581>
3424
3425         Reviewed by Anders Carlsson.
3426
3427         Moved ensureCSSStyleDeclaration() and ensureInlineCSSStyleDeclaration() from StylePropertySet
3428         to MutableStylePropertySet.
3429
3430         StyleRule & co now return a MutableStylePropertySet* from mutableProperties() to aid with...
3431
3432         CSSStyleDeclaration now only deals with MutableStylePropertySets. This was already the case
3433         in practice, we just didn't have any compile-time foot-shooting protection.
3434         In other words, if there's a CSSOM wrapper for a given StylePropertySet, it's guaranteed to
3435         be mutable, and the pointer types now reflect this.
3436
3437         * WebCore.exp.in:
3438         * css/PropertySetCSSStyleDeclaration.cpp:
3439         (WebCore::StyleRuleCSSStyleDeclaration::StyleRuleCSSStyleDeclaration):
3440         (WebCore::StyleRuleCSSStyleDeclaration::reattach):
3441         * css/PropertySetCSSStyleDeclaration.h:
3442         (WebCore::PropertySetCSSStyleDeclaration::PropertySetCSSStyleDeclaration):
3443         (PropertySetCSSStyleDeclaration):
3444         (WebCore::StyleRuleCSSStyleDeclaration::create):
3445         (StyleRuleCSSStyleDeclaration):
3446         (WebCore::InlineCSSStyleDeclaration::InlineCSSStyleDeclaration):
3447         * css/StylePropertySet.cpp:
3448         (WebCore::MutableStylePropertySet::ensureCSSStyleDeclaration):
3449         (WebCore::MutableStylePropertySet::ensureInlineCSSStyleDeclaration):
3450         * css/StylePropertySet.h:
3451         (StylePropertySet):
3452         (MutableStylePropertySet):
3453         * css/StyleRule.cpp:
3454         (WebCore::StyleRule::mutableProperties):
3455         (WebCore::StyleRulePage::mutableProperties):
3456         (WebCore::StyleRuleFontFace::mutableProperties):
3457         (WebCore::StyleRuleViewport::mutableProperties):
3458         (WebCore::StyleRuleFilter::mutableProperties):
3459         * css/StyleRule.h:
3460         (StyleRule):
3461         (StyleRuleFontFace):
3462         (StyleRulePage):
3463         (StyleRuleViewport):
3464         (StyleRuleFilter):
3465         * css/WebKitCSSKeyframeRule.cpp:
3466         (WebCore::StyleKeyframe::mutableProperties):
3467         * css/WebKitCSSKeyframeRule.h:
3468         (StyleKeyframe):
3469         * dom/Attr.cpp:
3470         (WebCore::Attr::style):
3471         * dom/Attr.h:
3472         (Attr):
3473         * editing/EditingStyle.cpp:
3474         (WebCore::EditingStyle::removeStyleAddedByNode):
3475         (WebCore::EditingStyle::removeStyleConflictingWithStyleOfNode):
3476         (WebCore::EditingStyle::triStateOfStyle):
3477         (WebCore::styleFromMatchedRulesForElement):
3478         (WebCore::EditingStyle::removeStyleFromRulesAndContext):
3479         * editing/FrameSelection.cpp:
3480         (WebCore::FrameSelection::copyTypingStyle):
3481         * editing/FrameSelection.h:
3482         * inspector/InspectorCSSAgent.cpp:
3483         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
3484
3485 2013-04-14  Andreas Kling  <akling@apple.com>
3486
3487         Move create() methods from StylePropertySet to MutableStylePropertySet.
3488         <http://webkit.org/b/114574>
3489
3490         Reviewed by Antti Koivisto.
3491
3492         Move the two create() methods that create MutableStylePropertySets from StylePropertySet
3493         to MutableStylePropertySet, and make them actually return MutableStylePropertySets.
3494         Switch to using {Pass,}RefPtr<MutableStylePropertySet> where appropriate to keep things building.
3495
3496         * css/CSSComputedStyleDeclaration.cpp:
3497         (WebCore::CSSComputedStyleDeclaration::copyPropertiesInSet):
3498         * css/CSSParser.cpp:
3499         (WebCore::CSSParser::parseFontFaceValue):
3500         * css/DOMWindowCSS.cpp:
3501         (WebCore::DOMWindowCSS::supports):
3502         * css/ElementRuleCollector.cpp:
3503         (WebCore::leftToRightDeclaration):
3504         (WebCore::rightToLeftDeclaration):
3505         * css/FontLoader.cpp:
3506         (WebCore::FontLoader::resolveFontStyle):
3507         * css/StylePropertySet.cpp:
3508         (WebCore::StylePropertySet::copyPropertiesInSet):
3509         (WebCore::MutableStylePropertySet::create):
3510         * css/StylePropertySet.h:
3511         (StylePropertySet):
3512         (MutableStylePropertySet):
3513         * css/StyleResolver.cpp:
3514         (WebCore::StyleResolver::resolveVariables):
3515         * css/WebKitCSSMatrix.cpp:
3516         (WebCore::WebKitCSSMatrix::setMatrixValue):
3517         * dom/Attr.cpp:
3518         (WebCore::Attr::style):
3519         * dom/Document.cpp:
3520         (WebCore::Document::createCSSStyleDeclaration):
3521         * dom/StyledElement.cpp:
3522         (WebCore::StyledElement::ensureMutableInlineStyle):
3523         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
3524         * editing/ApplyStyleCommand.cpp:
3525         (WebCore::copyStyleOrCreateEmpty):
3526         * editing/EditingStyle.cpp:
3527         (WebCore::editingStyleFromComputedStyle):
3528         (WebCore::HTMLAttributeEquivalent::attributeValueAsCSSValue):
3529         (WebCore::EditingStyle::setProperty):
3530         (WebCore::EditingStyle::extractAndRemoveTextDirection):
3531         (WebCore::styleFromMatchedRulesForElement):
3532         (WebCore::EditingStyle::mergeStyleFromRulesForSerialization):
3533         (WebCore::EditingStyle::forceInline):
3534         * editing/Editor.cpp:
3535         (WebCore::Editor::setBaseWritingDirection):
3536         * editing/EditorCommand.cpp:
3537         (WebCore::executeApplyStyle):
3538         (WebCore::executeToggleStyleInList):
3539         (WebCore::executeApplyParagraphStyle):
3540         (WebCore::executeMakeTextWritingDirectionLeftToRight):
3541         (WebCore::executeMakeTextWritingDirectionNatural):
3542         (WebCore::executeMakeTextWritingDirectionRightToLeft):
3543         * html/HTMLTableElement.cpp:
3544         (WebCore::leakBorderStyle):
3545         (WebCore::HTMLTableElement::createSharedCellStyle):
3546         (WebCore::leakGroupBorderStyle):
3547         * html/canvas/CanvasRenderingContext2D.cpp:
3548         (WebCore::CanvasRenderingContext2D::setFont):
3549         * inspector/InspectorStyleSheet.cpp:
3550         (WebCore::InspectorStyle::setPropertyText):
3551         (WebCore::InspectorStyleSheetForInlineStyle::getStyleAttributeRanges):
3552         * page/DragController.cpp:
3553         (WebCore::DragController::concludeEditDrag):
3554         * svg/SVGElementRareData.h:
3555         (WebCore::SVGElementRareData::ensureAnimatedSMILStyleProperties):
3556         * svg/SVGFontFaceElement.cpp:
3557         (WebCore::SVGFontFaceElement::SVGFontFaceElement):
3558         * svg/SVGStyledElement.cpp:
3559         (WebCore::SVGStyledElement::getPresentationAttribute):
3560
3561 2013-04-13  Sam Weinig  <sam@webkit.org>
3562
3563         Fix three crashes seen on the bots after "Make Frame's ScriptController an OwnPtr and remove the #include"
3564
3565         * xml/XMLHttpRequest.cpp:
3566         (WebCore::XMLHttpRequest::open):
3567         Check that the frame is not null (as it can be in cases like http/tests/xmlhttprequest/detaching-frame-2.html).
3568         We used to be getting lucky, in that shouldBypassMainWorldContentSecurityPolicy(), the function that is ultimately
3569         called, only operates on global state. Now that we need to actually dereference the Frame to get the ScriptController,
3570         we see this crash.
3571
3572 2013-04-13  Sukolsak Sakshuwong  <sukolsak@gmail.com>
3573
3574         Selection direction is not preserved when applying styles
3575         https://bugs.webkit.org/show_bug.cgi?id=110979
3576
3577         Reviewed by Ryosuke Niwa.
3578
3579         The patch is based on the one submitted by Shezan Baig.
3580
3581         If the starting selection was directional and its base was not first,
3582         switch newStart and newEnd when setting the ending direction. Otherwise,
3583         leave the order unchanged.
3584
3585         Test: editing/style/preserve-selection-direction.html
3586
3587         * editing/ApplyStyleCommand.cpp:
3588         (WebCore::ApplyStyleCommand::updateStartEnd):
3589
3590 2013-04-13  Alexey Proskuryakov  <ap@apple.com>
3591
3592         Added svn:ignore for inspector/CodeGeneratorInspectorStrings.pyc
3593
3594         * inspector: Added property svn:ignore.
3595
3596 2013-04-13  Sam Weinig  <sam@webkit.org>
3597
3598         Make Frame's ScriptController an OwnPtr and remove the #include
3599         https://bugs.webkit.org/show_bug.cgi?id=114105
3600
3601         Reviewed by Dean Jackson.
3602
3603         * Modules/websockets/WebSocket.cpp:
3604         * bindings/generic/BindingSecurity.cpp:
3605         * bindings/js/JSEventListener.cpp:
3606         * bindings/js/JSLazyEventListener.cpp:
3607         * bindings/js/PageScriptDebugServer.cpp:
3608         * bindings/js/ScriptEventListener.cpp:
3609         * bindings/js/ScriptState.cpp:
3610         * bindings/objc/DOM.mm:
3611         * bindings/objc/DOMAbstractView.mm:
3612         * bindings/objc/DOMInternal.mm:
3613         * dom/DocumentStyleSheetCollection.cpp:
3614         * dom/EventTarget.cpp:
3615         * dom/ScriptElement.cpp:
3616         * history/CachedFrame.cpp:
3617         * html/HTMLCanvasElement.cpp:
3618         * html/HTMLDocument.cpp:
3619         * html/HTMLElement.cpp:
3620         * html/HTMLFormElement.cpp:
3621         * html/HTMLPlugInElement.cpp:
3622         * html/HTMLPlugInImageElement.cpp:
3623         * html/parser/HTMLParserOptions.cpp:
3624         * inspector/InspectorAgent.cpp:
3625         * inspector/InspectorController.cpp:
3626         * inspector/InspectorFrontendClientLocal.cpp:
3627         * inspector/InspectorFrontendHost.cpp:
3628         * inspector/InspectorInstrumentation.cpp:
3629         * inspector/InspectorOverlay.cpp:
3630         * inspector/InspectorPageAgent.cpp:
3631         * inspector/PageRuntimeAgent.cpp:
3632         * loader/DocumentWriter.cpp:
3633         * loader/NavigationScheduler.cpp:
3634         * loader/SubframeLoader.cpp:
3635         * loader/cache/CachedResourceLoader.cpp:
3636         * page/DOMWindow.cpp:
3637         * page/EventSource.cpp:
3638         * page/Frame.cpp:
3639         * page/Frame.h:
3640         * page/Navigator.cpp:
3641         * page/Page.cpp:
3642         * page/PageGroup.cpp:
3643         * xml/XMLHttpRequest.cpp:
3644         * xml/XMLTreeViewer.cpp:
3645
3646 2013-04-13  Anders Carlsson  <andersca@apple.com>
3647
3648         Add form delegate method that's invoked right before sending a submit event to a form element
3649         https://bugs.webkit.org/show_bug.cgi?id=114575
3650
3651         Reviewed by Dan Bernstein.
3652
3653         * WebCore.exp.in:
3654         Export a symbol.
3655
3656         * WebCore.xcodeproj/project.pbxproj:
3657         Make DOMHTMLFormElementInternal.h a private header.
3658
3659 2013-03-13  Robert Hogan  <robert@webkit.org>
3660
3661         Whitespace between nowrap elements ignored after collapsed trailing space in a text run
3662         https://bugs.webkit.org/show_bug.cgi?id=17705
3663
3664         Reviewed by Ryosuke Niwa.
3665
3666         Bug 93448 and r138654 fixed the treatment of line-breaks between nowrap elements. This augments
3667         that fix by recognizing that we have a potential break not only in situations where the next character is a 
3668         space and the current character is not, but also where the next character is a space and the current character 
3669         *is* a space *and* we are ignoring spaces. This is so because any spaces we have ignored up to this point 
3670         after the actual word end will get collapsed away even if we don't end up taking the line break. 
3671
3672         In a nutshell, if we allow whitespace collapsing 'word  ' and 'word' are equivalent when before a whitespace
3673         character, so treat the first as well as the second as a potential linebreak.
3674
3675         Test: fast/text/whitespace/inline-whitespace-wrapping-5.html
3676
3677         * rendering/RenderBlockLineLayout.cpp:
3678         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
3679
3680 2013-04-13  Andreas Kling  <akling@apple.com>
3681
3682         Rename/tweak some StylePropertySet/CSSStyleDeclaration copying functions.
3683         <http://webkit.org/b/114569>
3684
3685         Reviewed by Anders Carlsson.
3686
3687         - StylePropertySet::copy() -> mutableCopy()
3688
3689             This function now returns a MutableStylePropertySet, and this is also reflected in the name.
3690
3691         - CSSStyleDeclaration::copy() -> copyProperties()
3692
3693             Renamed to reflect that it's the properties being copied, not the CSSStyleDeclaration.
3694             They also now return MutableStylePropertySets.
3695
3696         - StylePropertySet::copyPropertiesInSet()
3697         - CSSStyleDeclaration::copyPropertiesInSet()
3698
3699             These functions now return MutableStylePropertySets.
3700
3701         * css/CSSComputedStyleDeclaration.cpp:
3702         (WebCore::CSSComputedStyleDeclaration::copyProperties):
3703         (WebCore::CSSComputedStyleDeclaration::copyPropertiesInSet):
3704         * css/CSSComputedStyleDeclaration.h:
3705         (CSSComputedStyleDeclaration):
3706         * css/CSSStyleDeclaration.h:
3707         (CSSStyleDeclaration):
3708         * css/PropertySetCSSStyleDeclaration.cpp:
3709         (WebCore::PropertySetCSSStyleDeclaration::copyProperties):
3710         * css/PropertySetCSSStyleDeclaration.h:
3711         * css/StylePropertySet.cpp:
3712         (WebCore::StylePropertySet::mutableCopy):
3713         (WebCore::StylePropertySet::copyPropertiesInSet):
3714         * css/StylePropertySet.h:
3715         (StylePropertySet):
3716         * css/StyleRule.cpp:
3717         (WebCore::StyleRule::StyleRule):
3718         (WebCore::StyleRule::mutableProperties):
3719         (WebCore::StyleRulePage::StyleRulePage):
3720         (WebCore::StyleRulePage::mutableProperties):
3721         (WebCore::StyleRuleFontFace::StyleRuleFontFace):
3722         (WebCore::StyleRuleFontFace::mutableProperties):
3723         (WebCore::StyleRuleViewport::StyleRuleViewport):
3724         (WebCore::StyleRuleViewport::mutableProperties):
3725         (WebCore::StyleRuleFilter::StyleRuleFilter):
3726         (WebCore::StyleRuleFilter::mutableProperties):
3727         * css/ViewportStyleResolver.cpp:
3728         (WebCore::ViewportStyleResolver::addViewportRule):
3729         * css/WebKitCSSKeyframeRule.cpp:
3730         (WebCore::StyleKeyframe::mutableProperties):
3731         * dom/Element.cpp:
3732         (WebCore::UniqueElementData::UniqueElementData):
3733         * dom/StyledElement.cpp:
3734         (WebCore::StyledElement::ensureMutableInlineStyle):
3735         * editing/ApplyStyleCommand.cpp:
3736         (WebCore::copyStyleOrCreateEmpty):
3737         * editing/EditingStyle.cpp:
3738         (WebCore::copyEditingProperties):
3739         (WebCore::editingStyleFromComputedStyle):
3740         (WebCore::EditingStyle::EditingStyle):
3741         (WebCore::EditingStyle::init):
3742         (WebCore::EditingStyle::copy):
3743         (WebCore::EditingStyle::mergeStyle):
3744         (WebCore::getPropertiesNotIn):
3745         * editing/FrameSelection.cpp:
3746         (WebCore::FrameSelection::copyTypingStyle):
3747
3748 2013-04-13  Dirk Schulze  <krit@webkit.org>
3749
3750         Rename StyleBuilder to DeprecatedStyleBuilder
3751         https://bugs.webkit.org/show_bug.cgi?id=114532
3752
3753         Reviewed by Benjamin Poulain.
3754
3755         The StyleBuilder code is hard to read and maintain. People should
3756         not add new properties to this class. To make this clear, this
3757         patch renames the class to DeprecatedStyleBuilder.
3758
3759         Pure refactoring, no change in functionality.
3760
3761         * CMakeLists.txt:
3762         * GNUmakefile.list.am:
3763         * Target.pri:
3764         * WebCore.vcproj/WebCore.vcproj:
3765         * WebCore.vcxproj/WebCore.vcxproj.filters:
3766         * WebCore.xcodeproj/project.pbxproj:
3767         * css/CSSAllInOne.cpp:
3768         * css/DeprecatedStyleBuilder.cpp: Renamed from Source/WebCore/css/StyleBuilder.cpp.
3769         * css/DeprecatedStyleBuilder.h: Renamed from Source/WebCore/css/StyleBuilder.h.
3770         * css/StyleResolver.cpp:
3771         (WebCore::StyleResolver::StyleResolver):
3772         (WebCore::StyleResolver::applyProperty):
3773         (WebCore::StyleResolver::reportMemoryUsage):
3774         * css/StyleResolver.h:
3775         (StyleResolver):
3776         * rendering/style/RenderStyle.h:
3777
3778 2013-04-13  Andreas Kling  <akling@apple.com>
3779
3780         Remove unused method CSSStyleDeclaration::makeMutable().
3781         <http://webkit.org/b/114567>
3782
3783         Reviewed by Anders Carlsson.
3784
3785         * css/CSSComputedStyleDeclaration.cpp:
3786         * css/CSSComputedStyleDeclaration.h:
3787         (CSSComputedStyleDeclaration):
3788         * css/CSSStyleDeclaration.h:
3789         (CSSStyleDeclaration):
3790         * css/PropertySetCSSStyleDeclaration.cpp:
3791         * css/PropertySetCSSStyleDeclaration.h:
3792
3793 2013-04-13  Antoine Quint  <graouts@apple.com>
3794
3795         Width of last of consecutive tabs may be incorrect with "white-space: pre-wrap"
3796         https://bugs.webkit.org/show_bug.cgi?id=114562
3797
3798         Reviewed by Dan Bernstein.
3799
3800         When we measure the last word of a RenderText, make sure we use the correct x
3801         position taking into account the current accumulated word measurements up to
3802         this character. This is of particular importance in the case of tabs where the
3803         measured width would differ based on the x position.
3804
3805         Test: fast/text/tab-last-word-in-renderer-pre-wrap.html
3806
3807         * rendering/RenderBlockLineLayout.cpp:
3808         (WebCore::setLogicalWidthForTextRun):
3809
3810 2013-04-13  Mark Salisbury  <mark.salisbury@hp.com>
3811
3812         [Windows, WinCairo] ImageBufferCairo.cpp fails to compile after 148247, 148264.
3813         https://bugs.webkit.org/show_bug.cgi?id=114540
3814         
3815         Reviewed by Brent Fulgham.
3816
3817         * platform/graphics/cairo/ImageBufferCairo.cpp:
3818
3819 2013-04-13  Zan Dobersek  <zdobersek@igalia.com>
3820
3821         Unreviewed GTK build fix after r148305.
3822
3823         * GNUmakefile.list.am: Adding the TrackListBase build targets to the build.
3824
3825 2013-04-09  Roger Fong  <roger_fong@apple.com>
3826
3827         Update AVFoundationCF code following http://trac.webkit.org/changeset/148291.
3828         https://bugs.webkit.org/show_bug.cgi?id=114548.
3829
3830         Reviewed by Eric Carlson.
3831
3832         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3833         (WebCore::MediaPlayerPrivateAVFoundationCF::seekToTime):
3834         (WebCore::MediaPlayerPrivateAVFoundationCF::platformMinTimeSeekable):
3835         (WebCore):
3836         (WebCore::MediaPlayerPrivateAVFoundationCF::platformMaxTimeSeekable):
3837         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
3838         (MediaPlayerPrivateAVFoundationCF):
3839
3840 2013-04-12  Simon Fraser  <simon.fraser@apple.com>
3841
3842         Demystify some code in RenderLayer::updateScrollableAreaSet()
3843         https://bugs.webkit.org/show_bug.cgi?id=114543
3844
3845         Reviewed by Tim Horton.
3846
3847         Clean up some code that called functions with important side effects
3848         inside a ternary operator, and clean up the #ifdefs.
3849
3850         * rendering/RenderLayer.cpp:
3851         (WebCore::RenderLayer::updateScrollableAreaSet):
3852
3853 2013-04-12  Alexey Proskuryakov  <ap@apple.com>
3854
3855         <rdar://problem/13277362> REGRESSION (r141981): Crash when closing a Google Docs document
3856         https://bugs.webkit.org/show_bug.cgi?id=114541
3857
3858         Reviewed by Brady Eidson.
3859
3860         Test: http/tests/ssl/ping-with-unsafe-redirect.html
3861
3862         * loader/FrameNetworkingContext.h:
3863         (WebCore::FrameNetworkingContext::shouldClearReferrerOnHTTPSToHTTPRedirect):
3864         Added a null check. All NetworkingContext functions except for this one had it already.
3865
3866 2013-04-12  Ryosuke Niwa  <rniwa@webkit.org>
3867
3868         [Mac] REGRESSION: Auto substitution strips new lines
3869         https://bugs.webkit.org/show_bug.cgi?id=114537
3870
3871         Reviewed by Enrica Casucci.
3872
3873         The bug was caused by SpellingCorrectionCommand's use of InsertTextCommand. This command can't insert
3874         new lines and there's even an assertion for it. Use TypingCommand::insertText instead.
3875
3876         Since TypingCommand::insertText calls appliedEditing on its own, we need to avoid calling that again in
3877         CompositeEditCommand::apply after SpellingCorrectionCommand::doApply. Replaced the check in apply to use
3878         callsAppliedEditingInDoApply instead of isTypingCommand, and added callsAppliedEditingInDoApply to both
3879         TypingCommand and SpellingCorrectionCommand to return true (it returns false by default).
3880
3881         Test: platform/mac/editing/spelling/autocorrection-with-multi-line-text.html
3882
3883         * editing/CompositeEditCommand.cpp:
3884         (WebCore::CompositeEditCommand::apply): Use TypingCommand::insertText instead of InsertTextCommand
3885         (WebCore::CompositeEditCommand::callsAppliedEditingInDoApply): Added. Returns false.
3886         * editing/CompositeEditCommand.h:
3887         (CompositeEditCommand):
3888         * editing/SpellingCorrectionCommand.cpp:
3889         (WebCore::SpellingCorrectionCommand::doApply):
3890         (WebCore::SpellingCorrectionCommand::callsAppliedEditingInDoApply): Added. Returns true.
3891         * editing/SpellingCorrectionCommand.h:
3892         (SpellingCorrectionCommand):
3893         * editing/TypingCommand.cpp:
3894         (WebCore::TypingCommand::callsAppliedEditingInDoApply): Added. Returns true.
3895         * editing/TypingCommand.h:
3896         (TypingCommand):
3897
3898 2013-04-12  Brendan Long  <b.long@cablelabs.com>
3899
3900         Refactor TextTrack and TextTrackList to make it easier to add audio and video tracks
3901         https://bugs.webkit.org/show_bug.cgi?id=114330
3902
3903         Reviewed by Jer Noble.
3904
3905         No new tests because this doesn't add new functionality.
3906
3907         * CMakeLists.txt: Only compile text track files if ENABLE(VIDEO_TRACK), and add TrackListBase
3908         * Target.pri: Add TrackListBase
3909         * WebCore.vcproj/WebCore.vcproj: Correct InbandTextTrackPrivate.h's location and add TrackListBase
3910         * WebCore.xcodeproj/project.pbxproj: Add TrackListBase
3911         * html/HTMLMediaElement.cpp: Renamed "track" functions to "textTrack"
3912         (WebCore::HTMLMediaElement::mediaPlayerDidAddTextTrack): Renamed.
3913         (WebCore::HTMLMediaElement::mediaPlayerDidRemoveTextTrack): Renamed.
3914         (WebCore::HTMLMediaElement::addTextTrack): Renamed.
3915         (WebCore::HTMLMediaElement::removeTextTrack): Renamed.
3916         (WebCore::HTMLMediaElement::removeAllInbandTracks): Use renamed functions.
3917         (WebCore::HTMLMediaElement::didAddTextTrack): Renamed.
3918         (WebCore::HTMLMediaElement::didRemoveTextTrack): Renamed.
3919         * html/HTMLMediaElement.h:
3920         Renamed "track" functions to "textTrack" and only forward-declare TextTrackList if ENABLE(VIDEO_TRACK)
3921         * html/HTMLTrackElement.cpp: Renamed "track" functions to "textTrack"
3922         (WebCore::HTMLTrackElement::insertedInto):
3923         (WebCore::HTMLTrackElement::removedFrom):
3924         * html/track/TextTrack.cpp:
3925         Move media element, label, language and kind into TrackBase and move EventTarget functions into TextTrack.
3926         (WebCore::TextTrack::TextTrack): Added.
3927         (WebCore::TextTrack::interfaceName): Added.
3928         (WebCore::TextTrack::scriptExecutionContext): Added.
3929         (WebCore::TextTrack::eventTargetData): Added.
3930         (WebCore::TextTrack::ensureEventTargetData): Added.
3931         (WebCore::TextTrack::isValidKind): Added to support TrackBase::setKind()
3932         (WebCore::TextTrack::setKind): Override to support textTrackKindChanged()
3933         (WebCore::TextTrack::isRendered): Use kind(), label() and language() instead of m_kind, etc.
3934         (WebCore::TextTrack::platformTextTrack): Ditto.
3935         (WebCore::TextTrack::isMainProgramContent): Ditto.
3936         * html/track/TextTrack.h:
3937         Same as TextTrack.cpp, plus added defaultKindKeyword() so TrackBase::setKind() will work and added
3938         toTextTrack().
3939         * html/track/TextTrackList.cpp:
3940         Move functionality into TrackListBase, add toTextTrack() casts, use
3941         TrackBase where necesssary and use owner() instead of m_owner.
3942
3943         Moved EventTarget functions into TrackListBase.
3944         (TextTrackList::TextTrackList):
3945         (TextTrackList::getTrackIndexRelativeToRenderedTracks):
3946         (TextTrackList::item):
3947         (TextTrackList::invalidateTrackIndexesAfterTrack):
3948         (TextTrackList::append):
3949         (TextTrackList::remove):
3950         (TextTrackList::contains):
3951         * html/track/TextTrackList.h:
3952         Move EventTarget, RefCounted and m_inbandTracks into TrackListBase.
3953         Override length(), contains() and remove().
3954         * html/track/TrackBase.cpp: Remove EventTarget functions.
3955         (WebCore::TrackBase::TrackBase):
3956         Remove EventTarget, add label and language
3957         (WebCore::TrackBase::setKind): Added
3958         * html/track/TrackBase.h:
3959         Don't extend EventTarget (AudioTrack and VideoTrack aren't). Handle
3960         kind, label, language and media element.
3961         (WebCore::TrackBase::setMediaElement): Added.
3962         (WebCore::TrackBase::mediaElement): Added.
3963         (WebCore::TrackBase::kind): Added.
3964         (WebCore::TrackBase::label): Added.
3965         (WebCore::TrackBase::setLabel): Added.
3966         (WebCore::TrackBase::language): Added.
3967         (WebCore::TrackBase::setLanguage): Added.
3968         * html/track/TrackListBase.cpp:
3969         Added. Handles functionality common to TextTrackList, AudioTrackList and
3970         VideoTrackList.
3971         (TrackListBase::TrackListBase): Added.
3972         (TrackListBase::~TrackListBase): Added.
3973         (TrackListBase::length): Added.
3974         (TrackListBase::remove): Added.
3975         (TrackListBase::contains): Added.
3976         (TrackListBase::scheduleAddTrackEvent): Added.
3977         (TrackListBase::scheduleRemoveTrackEvent): Added.
3978         (TrackListBase::scheduleChangeEvent): Added.
3979         (TrackListBase::asyncEventTimerFired): Added.
3980         * html/track/TrackListBase.h:
3981         Copied from Source/WebCore/html/track/TextTrackList.h. Handles
3982         functionality common to TextTrackList, AudioTrackList and VideoTrackList.
3983         (WebCore::TrackListBase::scriptExecutionContext): Added.
3984         (WebCore::TrackListBase::clearOwner): Added.
3985         (WebCore::TrackListBase::owner): Added.
3986         (WebCore::TrackListBase::isFiringEventListeners): Added.
3987         * platform/graphics/MediaPlayer.cpp:
3988         (WebCore::MediaPlayer::addTextTrack): Renamed (was addTrack)
3989         (WebCore::MediaPlayer::removeTextTrack): Renamed (was removeTrack)
3990         * platform/graphics/MediaPlayer.h:
3991         (WebCore::MediaPlayerClient::mediaPlayerDidAddTextTrack): Renamed (was mediaPlayerDidAddTrack)
3992         (WebCore::MediaPlayerClient::mediaPlayerDidRemoveTextTrack): Renamed (was mediaPlayerDidRemoveTrack)
3993
3994 2013-04-12  Oliver Hunt  <oliver@apple.com>
3995
3996         make the codegenerator actually emit polymorphism check in the "no vtable" path
3997         https://bugs.webkit.org/show_bug.cgi?id=114533
3998
3999         Reviewed by David Kilzer.
4000
4001         Make the "no vtable" check correct so that we actually plant a polymorphism
4002         check.  Update a few interfaces to have the correct validation attributes.        
4003
4004         * Modules/webdatabase/SQLTransaction.idl:
4005         * bindings/scripts/CodeGeneratorJS.pm:
4006         (GenerateImplementation):
4007         * bindings/scripts/test/JS/JSTestInterface.cpp:
4008         (WebCore::toJS):
4009         * bindings/scripts/test/TestInterface.idl:
4010         * html/track/TextTrackCue.idl:
4011         * svg/SVGAnimatedAngle.idl:
4012         * svg/SVGAnimatedBoolean.idl:
4013         * svg/SVGAnimatedEnumeration.idl:
4014         * svg/SVGAnimatedInteger.idl:
4015         * svg/SVGAnimatedLength.idl:
4016         * svg/SVGAnimatedLengthList.idl:
4017         * svg/SVGAnimatedNumber.idl:
4018         * svg/SVGAnimatedNumberList.idl:
4019         * svg/SVGAnimatedPreserveAspectRatio.idl:
4020         * svg/SVGAnimatedRect.idl:
4021         * svg/SVGAnimatedString.idl:
4022         * svg/SVGAnimatedTransformList.idl:
4023
4024 2013-04-12  Oliver Hunt  <oliver@apple.com>
4025
4026         Make CodeGeneratorJS plant comments to explain failures in the binding validation
4027         https://bugs.webkit.org/show_bug.cgi?id=114528
4028
4029         Reviewed by Sam Weinig.
4030
4031         No change in behaviour, just make the generated bindings include comments
4032         to aid diagnosing issues that may be non-obvious.
4033
4034         * bindings/scripts/CodeGeneratorJS.pm:
4035         (GenerateImplementation):
4036         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
4037         (WebCore::toJS):
4038         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
4039         (WebCore::toJS):
4040         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
4041         (WebCore::toJS):
4042         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
4043         (WebCore::toJS):
4044         * bindings/scripts/test/JS/JSTestException.cpp:
4045         (WebCore::toJS):
4046         * bindings/scripts/test/JS/JSTestInterface.cpp:
4047         (WebCore::toJS):
4048         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
4049         (WebCore::toJS):
4050         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
4051         (WebCore::toJS):
4052         * bindings/scripts/test/JS/JSTestObj.cpp:
4053         (WebCore::toJS):
4054         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
4055         (WebCore::toJS):
4056         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
4057         (WebCore::toJS):
4058         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
4059         (WebCore::toJS):
4060
4061 2013-04-12  Tim Horton  <timothy_horton@apple.com>
4062
4063         REGRESSION (r138858): GIFs don't start playing when they come out of background tabs
4064         https://bugs.webkit.org/show_bug.cgi?id=108864
4065         <rdar://problem/13140489>
4066
4067         Reviewed by Antti Koivisto.
4068
4069         * loader/cache/CachedImage.cpp:
4070         (WebCore::CachedImage::resumeAnimatingImagesForLoader): Added.
4071         Iterate through all of the loader's cached resources. If they are bitmap images
4072         which claim to be animatable, notify the image's observers that the animation advanced
4073         by one frame. In reality, the image is still on the same frame, but will now be repainted,
4074         restarting the animation loop.
4075         * loader/cache/CachedImage.h:
4076         * page/FrameView.cpp: