[CSS Regions] Elements in a region should be assignable to a named flow
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-04-05  Mihai Maerean  <mmaerean@adobe.com>
2
3         [CSS Regions] Elements in a region should be assignable to a named flow
4         https://bugs.webkit.org/show_bug.cgi?id=74144
5
6         Reviewed by David Hyatt.
7
8         DOM children of a region must not be rendered as children of the region, but can be collected in flow threads.
9
10         NodeRenderingContext::parentRenderer now creates the parent render flow thread if it doesn't exist.
11
12         Element::moveToFlowThreadIsNeeded is a virtual method that is overriden in PseudoElement to return false and
13         in SVGElement so only svg root elements can directly be collected by a render flow thread.
14
15         RenderObject::canDOMChildrenHaveRenderParent exists to optimize the code so nodes inside regions (and maybe
16         other types of renderers in the future) can still have renderers if they need to be in a flow thread while the
17         rest of renderers that can't have children skip the new instructions.
18
19         Tests: fast/regions/flow-body-in-html.html . To test the duplicate bug #103685.
20                fast/regions/region-content-flown-into-region.html
21                fast/regions/universal-selector-children-to-the-same-region.html . To test the duplicate bug #103685.
22
23         * dom/Element.cpp:
24         (WebCore::Element::moveToFlowThreadIsNeeded):
25         * dom/Element.h:
26         * dom/NodeRenderingContext.cpp:
27         (WebCore::NodeRenderingContext::parentRenderer): the renderer that will be the parent for this node's renderer.
28         In the case of RenderFlowThreads, it may need to create it.
29         (WebCore::NodeRenderingContext::shouldCreateRenderer): In a region, only the children that need to be in a flow
30         thread should have a renderer.
31         (WebCore::NodeRenderingContext::moveToFlowThreadIfNeeded):
32         (WebCore::NodeRenderingContext::moveToFlowThread):
33         * dom/NodeRenderingContext.h:
34         (NodeRenderingContext):
35         * dom/PseudoElement.h: pseudo-elements cannot be directly collected into a named flow.
36         * dom/Text.cpp:
37         (WebCore::Text::textRendererIsNeeded):
38         (WebCore::Text::updateTextRenderer): Because calling textRendererIsNeeded(NodeRenderingContext(...)) on a
39         non-const l-value NodeRenderingContext cannot be done on a temporary object on the stack.
40         * dom/Text.h:
41         * rendering/FlowThreadController.cpp:
42         (WebCore::FlowThreadController::isContentNodeRegisteredWithAnyNamedFlow):
43         * rendering/FlowThreadController.h:
44         * rendering/RenderObject.h:
45         (WebCore::RenderObject::canDOMChildrenHaveRenderParent): Even if this render object can't have render children,
46         the children in the DOM tree may have a render parent (that is different from this render object).
47         * rendering/RenderRegion.h:
48         * svg/SVGElement.cpp:
49         (WebCore::SVGElement::moveToFlowThreadIsNeeded): Allow only svg root elements to be directly collected by a
50         render flow thread.
51         * svg/SVGElement.h:
52         (SVGElement):
53
54 2013-04-05  Allan Sandfeld Jensen  <allan.jensen@digia.com>
55
56         Fix GCC with C++11 build
57         https://bugs.webkit.org/show_bug.cgi?id=111579
58
59         Reviewed by Anders Carlsson.
60
61         If the destructor is private, MemoryInstrumentation can not create an inherited class.
62
63         * css/PropertySetCSSStyleDeclaration.h:
64         (StyleRuleCSSStyleDeclaration):
65         * dom/ShadowRoot.h:
66         (ShadowRoot):
67         * loader/SubresourceLoader.h:
68         (SubresourceLoader):
69         * platform/Timer.h:
70
71 2013-03-28  Allan Sandfeld Jensen  <allan.jensen@digia.com>
72
73         [Qt] Create ShadowBlur on demand.
74         https://bugs.webkit.org/show_bug.cgi?id=113506
75
76         Reviewed by Noam Rosenthal.
77
78         This patch creates ShadowBlur objects on demand instead of keeping a single one alive for
79         each GraphicsContext. This matches what other platforms does and fixes the problem with 
80         an active shadowblur being affected by changing shadow settings on the GraphicsContext.
81
82         The method mustUseShadowBlur is moved from ShadowBlur to GraphcisContext, so that it can
83         be used to determine if a ShadowBlur object should even be generated.
84
85         * platform/graphics/GraphicsContext.cpp:
86         (WebCore::GraphicsContext::hasBlurredShadow):
87         (WebCore::GraphicsContext::mustUseShadowBlur):
88         * platform/graphics/GraphicsContext.h:
89         (GraphicsContext):
90         * platform/graphics/ShadowBlur.cpp:
91         (WebCore::ShadowBlur::ShadowBlur):
92         * platform/graphics/ShadowBlur.h:
93         * platform/graphics/cairo/FontCairo.cpp:
94         (WebCore::drawGlyphsShadow):
95         * platform/graphics/cg/GraphicsContextCG.cpp:
96         (WebCore::GraphicsContext::fillRect):
97         (WebCore::GraphicsContext::fillRoundedRect):
98         (WebCore::GraphicsContext::fillRectWithRoundedHole):
99         * platform/graphics/qt/FontQt.cpp:
100         (WebCore::drawQtGlyphRun):
101         * platform/graphics/qt/GraphicsContextQt.cpp:
102         (GraphicsContextPlatformPrivate):
103         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
104         (WebCore::GraphicsContextPlatformPrivate::~GraphicsContextPlatformPrivate):
105         (WebCore::GraphicsContext::restorePlatformState):
106         (WebCore::GraphicsContext::fillPath):
107         (WebCore::GraphicsContext::strokePath):
108         (WebCore::GraphicsContext::fillRect):
109         (WebCore::GraphicsContext::fillRoundedRect):
110         (WebCore::GraphicsContext::fillRectWithRoundedHole):
111         (WebCore::GraphicsContext::setPlatformShadow):
112         (WebCore::GraphicsContext::clearPlatformShadow):
113         * platform/graphics/qt/ImageQt.cpp:
114         (WebCore::BitmapImage::draw):
115         * platform/graphics/qt/StillImageQt.cpp:
116         (WebCore::StillImage::draw):
117
118 2013-04-05  Ryosuke Niwa  <rniwa@webkit.org>
119
120         Remove Chromium code from WebCore/page
121         https://bugs.webkit.org/show_bug.cgi?id=114013
122
123         Reviewed by Anders Carlsson.
124
125         Removed.
126
127         * page/Console.cpp:
128         (WebCore::Console::time):
129         (WebCore::Console::timeEnd):
130         * page/EventHandler.cpp:
131         (WebCore::shouldGesturesTriggerActive):
132         (WebCore::EventHandler::handleMouseReleaseEvent):
133         (WebCore):
134         (WebCore::EventHandler::sendScrollEventToView):
135         * page/FeatureObserver.cpp:
136         (WebCore::FeatureObserver::updateMeasurements):
137         * page/FrameView.cpp:
138         (WebCore::FrameView::layout):
139         (WebCore::FrameView::useSlowRepaints):
140         * page/PageConsole.cpp:
141         * page/PageGroup.cpp:
142         (WebCore::PageGroup::isLinkVisited):
143         (WebCore::PageGroup::addVisitedLink):
144         * page/Settings.cpp:
145         (WebCore):
146         * page/android: Removed.
147         * page/chromium: Removed.
148         * page/chromium/ChromeClientChromium.h: Removed.
149         * page/chromium/DragControllerChromium.cpp: Removed.
150         * page/chromium/EventHandlerChromium.cpp: Removed.
151         * page/scrolling/ScrollingCoordinator.cpp:
152         (WebCore::ScrollingCoordinator::create):
153         (WebCore):
154         * page/scrolling/ScrollingCoordinator.h:
155         (ScrollingCoordinator):
156         * page/scrolling/ScrollingTree.cpp:
157         (WebCore):
158         * page/scrolling/ScrollingTree.h:
159         (ScrollingTree):
160         * page/scrolling/chromium: Removed.
161         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp: Removed.
162         * page/scrolling/chromium/ScrollingCoordinatorChromium.h: Removed.
163
164 2013-04-05  Ryosuke Niwa  <rniwa@webkit.org>
165
166         Remove Chromium code from WebCore/rendering
167         https://bugs.webkit.org/show_bug.cgi?id=114017
168
169         Reviewed by Simon Fraser.
170
171         Removed.
172
173         * rendering/RenderBlockLineLayout.cpp:
174         (WebCore::setLogicalWidthForTextRun):
175         * rendering/RenderLayerBacking.cpp:
176         (WebCore::RenderLayerBacking::requiresHorizontalScrollbarLayer):
177         (WebCore::RenderLayerBacking::requiresVerticalScrollbarLayer):
178         (WebCore::RenderLayerBacking::requiresScrollCornerLayer):
179         * rendering/RenderLayerCompositor.cpp:
180         (WebCore::RenderLayerCompositor::paintContents):
181         (WebCore::shouldCompositeOverflowControls):
182         (WebCore::RenderLayerCompositor::requiresOverhangAreasLayer):
183         * rendering/RenderMediaControlsChromium.cpp: Removed.
184         * rendering/RenderMediaControlsChromium.h: Removed.
185         * rendering/RenderObject.cpp:
186         (WebCore::RenderObject::shouldRespectImageOrientation):
187         * rendering/RenderText.cpp:
188         (WebCore):
189         (WebCore::RenderText::previousOffsetForBackwardDeletion):
190         * rendering/RenderThemeChromiumAndroid.cpp: Removed.
191         * rendering/RenderThemeChromiumAndroid.h: Removed.
192         * rendering/RenderThemeChromiumCommon.cpp: Removed.
193         * rendering/RenderThemeChromiumCommon.h: Removed.
194         * rendering/RenderThemeChromiumDefault.cpp: Removed.
195         * rendering/RenderThemeChromiumDefault.h: Removed.
196         * rendering/RenderThemeChromiumFontProvider.cpp: Removed.
197         * rendering/RenderThemeChromiumFontProvider.h: Removed.
198         * rendering/RenderThemeChromiumFontProviderLinux.cpp: Removed.
199         * rendering/RenderThemeChromiumFontProviderWin.cpp: Removed.
200         * rendering/RenderThemeChromiumMac.h: Removed.
201         * rendering/RenderThemeChromiumMac.mm: Removed.
202         * rendering/RenderThemeChromiumSkia.cpp: Removed.
203         * rendering/RenderThemeChromiumSkia.h: Removed.
204         * rendering/RenderThemeChromiumWin.cpp: Removed.
205         * rendering/RenderThemeChromiumWin.h: Removed.
206         * rendering/RenderThemeMacShared.mm:
207         (WebCore::RenderThemeMacShared::paintSliderThumb):
208
209 2013-04-05  Noam Rosenthal  <noam@webkit.org>
210
211         [Texmap] css3/filters/filter-animation-from-none-hw.html does not animate
212         https://bugs.webkit.org/show_bug.cgi?id=114026
213
214         Reviewed by Allan Sandfeld Jensen.
215
216         Allow the filter's blending function to take place when animating from/to none.
217
218         * platform/graphics/GraphicsLayerAnimation.cpp:
219         (WebCore::applyFilterAnimation):
220
221 2013-04-05  Noam Rosenthal  <noam@webkit.org>
222
223         [CoordGfx] Enable filter animations
224         https://bugs.webkit.org/show_bug.cgi?id=114027
225
226         Reviewed by Allan Sandfeld Jensen.
227
228         Allow CoordinatedGraphicsLayer to serialize filter animations to the UI process.
229
230         Covered by animation tests in css3/filters.
231
232         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
233         (WebCore::CoordinatedGraphicsLayer::addAnimation):
234
235 2013-04-05  Christophe Dumez  <ch.dumez@sisa.samsung.com>
236
237         Avoid double hash table lookups in TextureMapperGL
238         https://bugs.webkit.org/show_bug.cgi?id=114030
239
240         Reviewed by Noam Rosenthal.
241
242         Use Vector::add() and leverage its returned AddResult value instead of
243         calling Vector::find() then Vector::set() if the key does not already
244         exist in the map. This results in a single hash lookup instead of two
245         in this case.
246
247         No new tests, no behavior change.
248
249         * platform/graphics/texmap/TextureMapperGL.cpp:
250         (WebCore::TextureMapperGLData::SharedGLData::getShaderProgram):
251         (WebCore::TextureMapperGLData::getStaticVBO):
252         (WebCore::TextureMapperGL::drawUsingCustomFilter):
253
254 2013-04-05  Aivo Paas  <aivopaas@gmail.com>
255
256         Updating mouse cursor on style changes without emitting fake mousemove event
257         https://bugs.webkit.org/show_bug.cgi?id=101857
258
259         Reviewed by Allan Sandfeld Jensen.
260
261         Mouse cursor changes in styles used to be reflected in UI through dispatching a fake
262         mousemove event. The old approach has some flaws: it emits a mousemove event in
263         javascript when there is no mouse movement involved (bug 85343); the fake mousemove
264         event is cancelled while there is a mouse button held down - cursor won't change
265         until mouse is moved or the button released (bug 53341).
266
267         The new approach does not use the fake mousemove event. Instead, it uses only the logic
268         needed for the actual cursor change to happen.
269
270         EventHandler::selectCursor was refactored to not take a whole mouse event but instead work with
271         HitTestResult so that EventHandler::updateCursor must not create a useless PlatformEvent.
272
273         Fixes: https://bugs.webkit.org/show_bug.cgi?id=85343 (mousemove event on cursor change)
274                https://bugs.webkit.org/show_bug.cgi?id=53341 (no cursor change when mouse button down)
275
276         Tests: fast/events/mouse-cursor-change.html
277                fast/events/mouse-cursor-no-mousemove.html
278
279         * page/EventHandler.cpp:
280         (WebCore::EventHandler::EventHandler):
281         (WebCore::EventHandler::clear):
282         (WebCore::EventHandler::cursorUpdateTimerFired):
283         (WebCore::EventHandler::updateCursor):
284         (WebCore::EventHandler::selectCursor):
285         (WebCore::EventHandler::handleMouseMoveEvent):
286         (WebCore::EventHandler::scheduleCursorUpdate):
287         * page/EventHandler.h:
288         * page/FrameView.cpp:
289         (WebCore::FrameView::shouldSetCursor):
290         * page/FrameView.h:
291         * page/MouseEventWithHitTestResults.cpp:
292         (WebCore::MouseEventWithHitTestResults::isOverLink):
293         * rendering/HitTestResult.cpp:
294         (WebCore::HitTestResult::isOverLink):
295         * rendering/HitTestResult.h:
296         * rendering/RenderObject.cpp:
297         (WebCore::RenderObject::styleDidChange):
298
299 2013-04-05  Jocelyn Turcotte  <jocelyn.turcotte@digia.com>
300
301         [Qt] PluginsX11: exposedRect offset is applied twice when painting windowless
302         https://bugs.webkit.org/show_bug.cgi?id=114020
303
304         Reviewed by Simon Hausmann.
305
306         Both XGetImage and QPainter::drawImage would apply the offset.
307         Since the XImage will only contain the exposed rect, no need to specify
308         the source rect to drawImage.
309
310         * plugins/qt/PluginViewQt.cpp:
311         (WebCore::PluginView::paintUsingXPixmap):
312
313 2013-04-05  Seokju Kwon  <seokju.kwon@gmail.com>
314
315         Web Inspector: crash in InspectorDOMAgent::innerHighlightQuad after r147566
316         https://bugs.webkit.org/show_bug.cgi?id=113991
317
318         Reviewed by Joseph Pecoraro.
319
320         * inspector/InspectorDOMAgent.cpp:
321         (WebCore::InspectorDOMAgent::innerHighlightQuad):
322
323 2013-04-05  Carlos Garcia Campos  <cgarcia@igalia.com>
324
325         REGRESSION(r145279): Build fails while linking when MEDIA_STREAM is enabled
326         https://bugs.webkit.org/show_bug.cgi?id=113294
327
328         Reviewed by Xan Lopez.
329
330         In r145279 NamedGetter extended attribute is added to
331         RTCStatsResponse.idl which makes the code generator to add
332         prototypes for JSRTCStatsResponse::nameGetter and
333         JSRTCStatsResponse::canGetItemsForName to the generated
334         JSRTCStatsResponse header, but they are not implemented
335         anywhere. We need to provide a JSRTCStatsResponseCustom file with
336         the implementation of both functions.
337
338         * GNUmakefile.list.am: Add JSRTCStatsResponseCustom.cpp to
339         compilation.
340         * Target.pri: Ditto.
341         * UseJSC.cmake: Ditto.
342         * WebCore.vcproj/WebCore.vcproj: Ditto.
343         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
344         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
345         * bindings/js/JSRTCStatsResponseCustom.cpp: Added.
346         (WebCore):
347         (WebCore::JSRTCStatsResponse::canGetItemsForName):
348         (WebCore::JSRTCStatsResponse::nameGetter):
349
350 2013-04-05  Ryosuke Niwa  <rniwa@webkit.org>
351
352         Remove Chromium code from WebCore/loader
353         https://bugs.webkit.org/show_bug.cgi?id=114011
354
355         Reviewed by Benjamin Poulain.
356
357         Removed.
358
359         * loader/DocumentLoader.cpp:
360         (WebCore::DocumentLoader::responseReceived):
361         * loader/DocumentThreadableLoader.h:
362         * loader/FrameLoader.cpp:
363         (WebCore::FrameLoader::FrameLoader):
364         (WebCore::FrameLoader::defaultObjectContentType):
365         (WebCore):
366         * loader/FrameLoader.h:
367         (FrameLoader):
368         * loader/FrameLoaderClient.h:
369         (FrameLoaderClient):
370         * loader/PingLoader.cpp:
371         (WebCore::PingLoader::loadImage):
372         (WebCore::PingLoader::sendPing):
373         (WebCore::PingLoader::sendViolationReport):
374         * loader/ResourceLoadScheduler.cpp:
375         (WebCore):
376         (WebCore::ResourceLoadScheduler::ResourceLoadScheduler):
377         (WebCore::ResourceLoadScheduler::scheduleLoad):
378         * loader/ResourceLoader.h:
379         * loader/SubresourceLoader.h:
380         * loader/ThreadableLoaderClient.h:
381         (ThreadableLoaderClient):
382         * loader/ThreadableLoaderClientWrapper.h:
383         (ThreadableLoaderClientWrapper):
384         * loader/appcache/ApplicationCacheHost.h:
385         (WebCore):
386         (ApplicationCacheHost):
387         * loader/cache/CachedRawResource.h:
388         (CachedRawResource):
389         (WebCore::CachedRawResourceClient::redirectReceived):
390         * loader/cache/CachedResource.cpp:
391         (WebCore):
392         (WebCore::CachedResource::load):
393         * loader/cache/CachedResource.h:
394         (WebCore::CachedResource::didSendData):
395         * loader/cache/CachedResourceLoader.cpp:
396         (WebCore::CachedResourceLoader::requestResource):
397         (WebCore::CachedResourceLoader::preload):
398         * loader/chromium: Removed.
399         * loader/chromium/CachedRawResourceChromium.cpp: Removed.
400         * loader/chromium/DocumentThreadableLoaderChromium.cpp: Removed.
401         * loader/chromium/ResourceLoaderChromium.cpp: Removed.
402         * loader/chromium/SubresourceLoaderChromium.cpp: Removed.
403
404 2013-04-05  Ryosuke Niwa  <rniwa@webkit.org>
405
406         Remove Chromium code from WebCore/editing
407         https://bugs.webkit.org/show_bug.cgi?id=114008
408
409         Reviewed by Benjamin Poulain.
410
411         Removed.
412
413         * editing/EditingBehavior.h:
414         (WebCore::EditingBehavior::shouldAllowSpellingSuggestionsWithoutSelection):
415         * editing/FrameSelection.h:
416         (WebCore):
417         * editing/chromium: Removed.
418         * editing/chromium/EditorChromium.cpp: Removed.
419         * editing/chromium/FrameSelectionChromium.cpp: Removed.
420
421 2013-04-05  Benjamin Poulain  <benjamin@webkit.org>
422
423         Remove the chromium code from the filesystem module
424         https://bugs.webkit.org/show_bug.cgi?id=114002
425
426         Reviewed by Ryosuke Niwa.
427
428         * Modules/filesystem/DOMFileSystemBase.cpp:
429         (WebCore::DOMFileSystemBase::createFileSystemURL):
430         * Modules/filesystem/FileSystemType.h:
431         * Modules/filesystem/LocalFileSystem.cpp:
432         * Modules/filesystem/LocalFileSystem.h:
433         (LocalFileSystem):
434
435 2013-04-05  Ryosuke Niwa  <rniwa@webkit.org>
436
437         Remove Chromium code from Source/WebCore/dom
438         https://bugs.webkit.org/show_bug.cgi?id=114007
439
440         Reviewed by Benjamin Poulain.
441
442         Removed.
443
444         * dom/Document.cpp:
445         (WebCore::Document::recalcStyle):
446         (WebCore::Document::implicitClose):
447         (WebCore::Document::setFocusedNode):
448         * dom/MessagePortChannel.h:
449         (MessagePortChannel):
450         * dom/ShadowRoot.cpp:
451         (WebCore::ShadowRoot::ShadowRoot):
452         * dom/default/chromium: Removed.
453         * dom/default/chromium/PlatformMessagePortChannelChromium.cpp: Removed.
454         * dom/default/chromium/PlatformMessagePortChannelChromium.h: Removed.
455
456 2013-04-05  Benjamin Poulain  <benjamin@webkit.org>
457
458         Remove the chromium directories from WebCore/Modules
459         https://bugs.webkit.org/show_bug.cgi?id=114000
460
461         Reviewed by Ryosuke Niwa.
462
463         First step in cleaning the code: remove the chromium-specific files.
464
465         * Modules/filesystem/chromium/DOMFileSystemChromium.cpp: Removed.
466         * Modules/filesystem/chromium/DataTransferItemFileSystemChromium.cpp: Removed.
467         * Modules/filesystem/chromium/DraggedIsolatedFileSystem.cpp: Removed.
468         * Modules/filesystem/chromium/DraggedIsolatedFileSystem.h: Removed.
469         * Modules/indexeddb/chromium/IDBFactoryBackendInterfaceChromium.cpp: Removed.
470         * Modules/indexeddb/chromium/IDBFactoryBackendInterfaceChromium.h: Removed.
471         * Modules/speech/chromium/SpeechSynthesisChromium.cpp: Removed.
472         * Modules/webdatabase/chromium/DatabaseObserver.h: Removed.
473         * Modules/webdatabase/chromium/DatabaseTrackerChromium.cpp: Removed.
474         * Modules/webdatabase/chromium/QuotaTracker.cpp: Removed.
475         * Modules/webdatabase/chromium/QuotaTracker.h: Removed.
476         * Modules/webdatabase/chromium/SQLTransactionClientChromium.cpp: Removed.
477
478 2013-04-04  Ryosuke Niwa  <rniwa@webkit.org>
479
480         Remove Chromium code from WebCore/accessibility
481         https://bugs.webkit.org/show_bug.cgi?id=114001
482
483         Reviewed by Benjamin Poulain.
484
485         Removed.
486
487         * accessibility/AccessibilityObject.cpp:
488         (WebCore::AccessibilityObject::AccessibilityObject):
489         (WebCore::AccessibilityObject::detach):
490         (WebCore::AccessibilityObject::isDetached):
491         * accessibility/AccessibilityObject.h:
492         (AccessibilityObject):
493         * accessibility/chromium: Removed.
494         * accessibility/chromium/AXObjectCacheChromium.cpp: Removed.
495         * accessibility/chromium/AccessibilityObjectChromium.cpp: Removed.
496
497 2013-04-05  Benjamin Poulain  <bpoulain@apple.com>
498
499         Remove WTFURL from WebKit
500         https://bugs.webkit.org/show_bug.cgi?id=113994
501
502         Reviewed by Ryosuke Niwa.
503
504         * GNUmakefile.list.am:
505         * WebCore.exp.in:
506         * WebCore.xcodeproj/project.pbxproj:
507         * platform/KURL.cpp:
508         (WebCore):
509         (WebCore::KURL::reportMemoryUsage):
510         (WebCore::KURL::isSafeToSendToAnotherThread):
511         * platform/KURL.h:
512         (KURL):
513         (WebCore):
514         * platform/KURLWTFURL.cpp: Removed.
515         * platform/KURLWTFURLImpl.h: Removed.
516         * platform/cf/KURLCFNet.cpp:
517         (WebCore::KURL::KURL):
518         (WebCore::KURL::createCFURL):
519         (WebCore):
520         * platform/mac/KURLMac.mm:
521         (WebCore::KURL::KURL):
522         (WebCore::KURL::createCFURL):
523
524 2013-04-04  peavo@outlook.com  <peavo@outlook.com>
525
526         WinCairo build fails to link.
527         https://bugs.webkit.org/show_bug.cgi?id=113873
528
529         Reviewed by Brent Fulgham.
530
531         Removed double guards for USE(ACCELERATED_COMPOSITING),
532         and moved methods out of USE(ACCELERATED_COMPOSITING) guard to fix linker errors. 
533
534         * page/FrameView.cpp:
535         (WebCore::FrameView::setWantsLayerForTopOverHangArea):
536         (WebCore::FrameView::setWantsLayerForBottomOverHangArea):
537         (WebCore::FrameView::setWantsLayerForHeader):
538         (WebCore::FrameView::setWantsLayerForFooter):
539         (WebCore::FrameView::setHeaderHeight):
540         (WebCore::FrameView::setFooterHeight):
541
542 2013-04-04  Ryosuke Niwa  <rniwa@webkit.org>
543
544         Remove code for 10.5 and earlier from Source/WebCore
545         https://bugs.webkit.org/show_bug.cgi?id=113754
546
547         Reviewed by Benjamin Poulain.
548
549         Removed the code for 10.5 and removed if-def for 10.6.
550
551         * WebCore.xcodeproj/project.pbxproj:
552         * page/ContextMenuController.cpp:
553         (WebCore::ContextMenuController::populate):
554         * platform/LocalizedStrings.cpp:
555         (WebCore::imageTitle):
556         * platform/graphics/cg/GraphicsContextCG.cpp:
557         (WebCore::GraphicsContext::setAllowsFontSmoothing):
558         * platform/graphics/cg/ImageCG.cpp:
559         (WebCore::Image::drawPattern):
560         * platform/graphics/cg/ImageSourceCG.cpp:
561         (WebCore::ImageSource::clear):
562         * platform/graphics/cg/PathCG.cpp:
563         (WebCore::Path::boundingRect):
564         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
565         (WebCore):
566         (WebCore::FontPlatformData::ctFont):
567         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
568         (WebCore::MediaPlayerPrivateGStreamerBase::supportsFullscreen):
569         * platform/graphics/mac/ComplexTextControllerCoreText.mm:
570         * platform/graphics/mac/FontCacheMac.mm:
571         (WebCore):
572         (WebCore::fontCacheRegisteredFontsChangedNotificationCallback):
573         (WebCore::FontCache::platformInit):
574         * platform/graphics/mac/FontCustomPlatformData.cpp:
575         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
576         (WebCore::createFontCustomPlatformData):
577         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
578         (WebCore::MediaPlayerPrivateQTKit::createQTMovie):
579         (WebCore::MediaPlayerPrivateQTKit::supportsFullscreen):
580         (WebCore::MediaPlayerPrivateQTKit::setClosedCaptionsVisible):
581         (WebCore::MediaPlayerPrivateQTKit::cacheMovieScale):
582         * platform/graphics/mac/SimpleFontDataMac.mm:
583         (WebCore::SimpleFontData::platformInit):
584         * platform/graphics/mac/WebLayer.h:
585         * platform/mac/CursorMac.mm:
586         (WebCore::Cursor::ensurePlatformCursor):
587         * platform/mac/DisplaySleepDisabler.cpp:
588         (WebCore::DisplaySleepDisabler::DisplaySleepDisabler):
589         (WebCore):
590         * platform/mac/DisplaySleepDisabler.h:
591         (DisplaySleepDisabler):
592         * platform/mac/EmptyProtocolDefinitions.h:
593         * platform/mac/HTMLConverter.h:
594         * platform/mac/HTMLConverter.mm:
595         * platform/mac/PopupMenuMac.mm:
596         (WebCore::PopupMenuMac::populate):
597         * platform/mac/ScrollElasticityController.mm:
598         (systemUptime):
599         * platform/mac/SharedTimerMac.mm:
600         (PowerObserver):
601         (WebCore::PowerObserver::PowerObserver):
602         (WebCore::PowerObserver::~PowerObserver):
603         (WebCore::PowerObserver::didReceiveSystemPowerNotification):
604         * platform/mac/SuddenTermination.mm:
605         * platform/mac/WebCoreFullScreenWindow.mm:
606         (-[WebCoreFullScreenWindow initWithContentRect:styleMask:backing:defer:]):
607         * platform/mac/WebFontCache.mm:
608         (+[WebFontCache getTraits:inFamily:]):
609         (+[WebFontCache internalFontWithFamily:traits:weight:size:]):
610         * platform/mac/WebVideoFullscreenController.mm:
611         (SOFT_LINK_POINTER):
612         (-[WebVideoFullscreenController updateMenuAndDockForFullscreen]):
613         * platform/mac/WebVideoFullscreenHUDWindowController.mm:
614         (createControlWithMediaUIControlType):
615         (-[WebVideoFullscreenHUDWindowController windowDidLoad]):
616         * platform/network/Credential.h:
617         * platform/network/cf/DNSCFNet.cpp:
618         (WebCore::DNSResolveQueue::platformProxyIsEnabledInSystemPreferences):
619         * platform/network/cf/ProxyServerCFNet.cpp:
620         (WebCore):
621         (WebCore::proxyServersForURL):
622         * platform/network/cf/SocketStreamHandleCFNet.cpp:
623         (WebCore::SocketStreamHandle::chooseProxy):
624         * platform/network/mac/AuthenticationMac.mm:
625         (WebCore):
626         * platform/network/mac/WebCoreURLResponse.mm:
627         (WebCore::adjustMIMETypeIfNecessary):
628         * platform/text/TextChecking.h:
629         (WebCore):
630
631 2013-04-04  Ryosuke Niwa  <rniwa@webkit.org>
632
633         Qt build fix attempt after r147684.
634
635         * html/canvas/CanvasRenderingContext.cpp:
636
637 2013-04-04  Benjamin Poulain  <bpoulain@apple.com>
638
639         alternateFamilyName should return a null, not an empty value
640         https://bugs.webkit.org/show_bug.cgi?id=113987
641
642         Reviewed by Anders Carlsson.
643
644         The string object corresponding semantically to "no-value" is
645         a null string, not an empty string.
646
647         Fix alternateFamilyName() accordingly.
648
649         * platform/graphics/FontCache.cpp:
650         (WebCore::alternateFamilyName):
651         (WebCore::FontCache::getCachedFontPlatformData):
652
653 2013-04-04  Anders Carlsson  <andersca@apple.com>
654
655         Work around a bug in the bindings generation script.
656
657         * WebCore.xcodeproj/project.pbxproj:
658
659 2013-04-04  Dean Jackson  <dino@apple.com>
660
661         Don't dispatch delayed click if snapshotted plugin was triggered by a click on the label
662         https://bugs.webkit.org/show_bug.cgi?id=113982
663
664         Reviewed by Tim Horton.
665
666         We regressed the way clicks were sent on to restarted plugins when we moved to a
667         Shadow Root - we were always sending the click. We should only send the click
668         on if the user clicked on the main plugin content, and not send it when you
669         click directly on the label.
670
671         * html/HTMLPlugInImageElement.cpp:
672         (WebCore::HTMLPlugInImageElement::didAddUserAgentShadowRoot): Keep a reference to the container and label.
673         (WebCore::HTMLPlugInImageElement::partOfSnapshotLabel): New method that detects if a Node was part
674             of the snapshot label.
675         (WebCore::HTMLPlugInImageElement::userDidClickSnapshot): Only record the event if you should forward it on.
676         * html/HTMLPlugInImageElement.h:
677         (HTMLPlugInImageElement): New parameter to userDidClickSnapshot and member variables for shadow content.
678         * rendering/RenderSnapshottedPlugIn.cpp:
679         (WebCore::RenderSnapshottedPlugIn::handleEvent): Ask the plugin if the clicked target was the snapshot label.
680
681 2013-04-04  Christophe Dumez  <ch.dumez@sisa.samsung.com>
682
683         Unreviewed EFL build fix.
684
685         Add missing include for FloatRect.h.
686
687         * platform/efl/PlatformScreenEfl.cpp:
688
689 2013-04-04  Tim Horton  <timothy_horton@apple.com>
690
691         Unreviewed build fix.
692
693         * platform/graphics/GlyphPageTreeNode.cpp:
694
695 2013-04-04  Anders Carlsson  <andersca@apple.com>
696
697         Another build fix.
698
699         * platform/graphics/FontCache.cpp:
700         * platform/graphics/SimpleFontData.cpp:
701
702 2013-04-04  Anders Carlsson  <andersca@apple.com>
703
704         Fix build.
705
706         * WebCore.xcodeproj/project.pbxproj:
707
708 2013-04-04  Geoffrey Garen  <ggaren@apple.com>
709
710         Removed empty files from the build
711         https://bugs.webkit.org/show_bug.cgi?id=113978
712
713         Reviewed by Anders Carlsson.
714
715         Anders made a list of all the empty files that are slowing down the Mac
716         build, and I grepped them away.
717
718         * WebCore.xcodeproj/project.pbxproj:
719
720 2013-04-04  Anders Carlsson  <andersca@apple.com>
721
722         Prune unneeded header #includes
723         https://bugs.webkit.org/show_bug.cgi?id=113973
724
725         Reviewed by Geoffrey Garen.
726
727         Reduce the amount of headers included by other headers by:
728         - Moving implicit and explicit constructors and destructors into .cpp files so member variable constructors/destructors
729           don't have to be declared.
730         - Move CachedResourceClient subclasses out into separate headers so that their respective CachedResource subclasses don't
731           have to be included by the classes that derive from those subclasses.
732         - Remove headers that were never needed in the first place.
733
734         * Modules/webaudio/AudioContext.h:
735         * WebCore.xcodeproj/project.pbxproj:
736         * bindings/js/JSDOMWindowCustom.cpp:
737         * css/CSSFontFaceSource.h:
738         * html/canvas/CanvasPattern.cpp:
739         (WebCore::CanvasPattern::create):
740         (WebCore::CanvasPattern::CanvasPattern):
741         (WebCore::CanvasPattern::~CanvasPattern):
742         * html/canvas/CanvasPattern.h:
743         (WebCore::CanvasPattern::pattern):
744         (WebCore::CanvasPattern::originClean):
745         * html/parser/HTMLScriptRunner.h:
746         * loader/ImageLoader.h:
747         * loader/LinkLoader.h:
748         * loader/TextTrackLoader.h:
749         * loader/cache/CachedFont.cpp:
750         * loader/cache/CachedFont.h:
751         * loader/cache/CachedFontClient.h: Added.
752         (WebCore::CachedFontClient::~CachedFontClient):
753         (WebCore::CachedFontClient::expectedType):
754         (WebCore::CachedFontClient::resourceClientType):
755         (WebCore::CachedFontClient::fontLoaded):
756         * loader/cache/CachedResourceHandle.cpp:
757         (WebCore::CachedResourceHandleBase::CachedResourceHandleBase):
758         (WebCore::CachedResourceHandleBase::~CachedResourceHandleBase):
759         (WebCore::CachedResourceHandleBase::setResource):
760         * loader/cache/CachedResourceHandle.h:
761         (WebCore::CachedResourceHandleBase::get):
762         (WebCore::CachedResourceHandleBase::operator!):
763         (WebCore::CachedResourceHandleBase::operator UnspecifiedBoolType):
764         (WebCore::CachedResourceHandleBase::operator=):
765         (WebCore::CachedResourceHandle::CachedResourceHandle):
766         (WebCore::CachedResourceHandle::get):
767         (WebCore::CachedResourceHandle::operator->):
768         (WebCore::CachedResourceHandle::operator=):
769         (WebCore::CachedResourceHandle::operator==):
770         (WebCore::CachedResourceHandle::operator!=):
771         (WebCore::operator==):
772         (WebCore::operator!=):
773         * loader/cache/CachedSVGDocument.h:
774         * loader/cache/CachedSVGDocumentReference.h:
775         * loader/cache/CachedSVGDocumentClient.h: Added.
776         (WebCore::CachedSVGDocumentClient::~CachedSVGDocumentClient):
777         (WebCore::CachedSVGDocumentClient::expectedType):
778         (WebCore::CachedSVGDocumentClient::resourceClientType):
779         * loader/cache/CachedStyleSheetClient.h:
780         * platform/PlatformScreen.h:
781         * platform/audio/HRTFElevation.cpp:
782         * platform/audio/HRTFKernel.cpp:
783         (WebCore::HRTFKernel::fftSize):
784         * platform/audio/HRTFKernel.h:
785         * platform/audio/ReverbConvolverStage.cpp:
786         (WebCore::ReverbConvolverStage::~ReverbConvolverStage):
787         * platform/audio/ReverbConvolverStage.h:
788         * platform/graphics/FontPlatformData.h:
789         * platform/graphics/GraphicsContext3D.h:
790         * platform/graphics/Path.cpp:
791         * platform/graphics/Path.h:
792         * platform/graphics/Pattern.cpp:
793         * platform/graphics/Pattern.h:
794         * platform/graphics/filters/FilterOperation.cpp:
795         (WebCore::ReferenceFilterOperation::ReferenceFilterOperation):
796         (WebCore::ReferenceFilterOperation::~ReferenceFilterOperation):
797         (WebCore::ReferenceFilterOperation::setCachedSVGDocumentReference):
798         * platform/graphics/filters/FilterOperation.h:
799         * platform/graphics/transforms/AffineTransform.h:
800         * plugins/DOMMimeType.h:
801         * rendering/RenderLayerFilterInfo.h:
802         * rendering/style/StyleCachedShader.h:
803         * svg/SVGFEImageElement.h:
804         * svg/SVGFontFaceUriElement.h:
805         * svg/SVGUseElement.h:
806         * xml/parser/XMLDocumentParser.h:
807
808 2013-04-04  Christophe Dumez  <ch.dumez@sisa.samsung.com>
809
810         [Cairo] Stop passing raw pointers to BitmapImage::create()
811         https://bugs.webkit.org/show_bug.cgi?id=113945
812
813         Reviewed by Martin Robinson.
814
815         BitmapImage::create() was updated in r147643 to take a PassRefPtr<cairo_surface_t>
816         in argument instead of a cairo_surface_t*. This patch updates several call sites
817         so that they now pass in a smart pointer instead of a raw one to avoid silent
818         converting from cairo_surface_t* to PassRefPtr<cairo_surface_t>.
819
820         No new tests, no behavior change.
821
822         * platform/graphics/cairo/ImageBufferCairo.cpp:
823         (WebCore::ImageBufferData::ImageBufferData): Use RefPtr to m_surface to avoid manual
824         memory handling.
825         (WebCore::ImageBuffer::ImageBuffer):
826         (WebCore::ImageBuffer::~ImageBuffer):
827         (WebCore::ImageBuffer::copyImage):
828         (WebCore::ImageBuffer::clip):
829         (WebCore::ImageBuffer::platformTransformColorSpace):
830         (WebCore::getImageData):
831         (WebCore::ImageBuffer::putByteArray):
832         * platform/graphics/cairo/ImageBufferDataCairo.h:
833         (ImageBufferData):
834         * platform/graphics/gstreamer/ImageGStreamerCairo.cpp:
835         (ImageGStreamer::ImageGStreamer):
836         * platform/graphics/gtk/ImageBufferGtk.cpp:
837         (WebCore::ImageBuffer::toDataURL):
838
839 2013-04-04  Simon Fraser  <simon.fraser@apple.com>
840
841         Page content missing when flipping from an empty layer to a tiled layer
842         https://bugs.webkit.org/show_bug.cgi?id=113977
843         <rdar://problem/13444219>
844
845         Reviewed by Tim Horton.
846         
847         Some articles on USA Today were missing content on load, when a large GraphicsLayer
848         which did not draw content needed to draw content (and become tiled in the process).
849         
850         The bug was an ordering dependency in GraphicsLayerCA::commitLayerChangesBeforeSublayers().
851         swapFromOrToTiledLayer() sets some dirty flags, but for some properties which have
852         already been committed in the current flush cycle.
853         
854         Fix by moving the swapFromOrToTiledLayer() to the top of the commit, which is
855         safe since it only consults GraphicsLayer properties, not CALayer properties.
856
857         Test: compositing/tiling/empty-to-tiled.html
858
859         * platform/graphics/ca/GraphicsLayerCA.cpp:
860         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
861         (WebCore::GraphicsLayerCA::updateGeometry):
862         (WebCore::GraphicsLayerCA::updateLayerDrawsContent):
863         (WebCore::GraphicsLayerCA::updateContentsScale):
864         * platform/graphics/ca/GraphicsLayerCA.h:
865         (GraphicsLayerCA):
866
867 2013-04-04  Christophe Dumez  <ch.dumez@sisa.samsung.com>
868
869         Regression(r147639) Causes assertion hit in HashTable
870         https://bugs.webkit.org/show_bug.cgi?id=113954
871
872         Reviewed by Benjamin Poulain.
873
874         Lookup the key in the hash table again after the recursive call to
875         getCachedFontPlatformData() as it may have altered the hash map and
876         invalidated the previous iterator we had.
877
878         No new tests, covered by existing tests.
879
880         * platform/graphics/FontCache.cpp:
881         (WebCore::FontCache::getCachedFontPlatformData):
882
883 2013-04-04  Eric Carlson  <eric.carlson@apple.com>
884
885         [Mac] add "automatic" text track menu item
886         https://bugs.webkit.org/show_bug.cgi?id=113822
887
888         Reviewed by Jer Noble.
889
890         No new tests, existing tests updated.
891
892         * English.lproj/Localizable.strings: Add new track menu item.
893
894         * html/HTMLMediaElement.cpp: 
895         (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize m_captionDisplayMode.
896         (WebCore::HTMLMediaElement::finishParsingChildren): LoadTextTrackResource -> ConfigureTextTracks.
897         (WebCore::HTMLMediaElement::scheduleDelayedAction): Ditto.
898         (WebCore::HTMLMediaElement::loadTimerFired): Ditto.
899         (WebCore::HTMLMediaElement::loadInternal): Ditto. Flag the caption menu as invalid so it will
900             be rebuilt again.
901         (WebCore::HTMLMediaElement::mediaPlayerDidAddTrack): LoadTextTrackResource -> ConfigureTextTracks.
902         (WebCore::HTMLMediaElement::didAddTrack): Ditto.
903         (WebCore::HTMLMediaElement::configureTextTrackGroup): Deal with new track display modes.
904         (WebCore::HTMLMediaElement::HTMLMediaElement::hasClosedCaptions): Minor cleanup.
905         (WebCore::HTMLMediaElement::configureTextTrackGroup): Add some logging.
906         (WebCore::HTMLMediaElement::configureTextTracks): Call updateActiveTextTrackCues so cue display
907             is updated.
908         (WebCore::HTMLMediaElement::captionPreferencesChanged): Deal with new track display modes.
909         (WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): Add some logging.
910         * html/HTMLMediaElement.h: Ditto.
911
912         * html/shadow/MediaControlElementTypes.cpp: Remove trackIndexAttributeName and trackListIndexForElement.
913         * html/shadow/MediaControlElementTypes.h: Ditto.
914
915         * html/shadow/MediaControlElements.cpp:
916         (WebCore::MediaControlClosedCaptionsTrackListElement::defaultEventHandler): Don't use track index,
917             everything we need is in the track<->element map now.
918         (WebCore::MediaControlClosedCaptionsTrackListElement::updateDisplay): Ditto. Always rebuild the 
919             track list because clear the map each time the menu goes away because it refs every track.
920         (WebCore::MediaControlClosedCaptionsTrackListElement::rebuildTrackListMenu): Don't set the track
921             index attribute on the menu items, just use the map.
922         * html/shadow/MediaControlElements.h:
923
924         * html/shadow/MediaControlsApple.cpp:
925         (WebCore::MediaControlsApple::changedClosedCaptionsVisibility): resetTrackListMenu is gone.
926         (WebCore::MediaControlsApple::reset): Ditto.
927         (WebCore::MediaControlsApple::closedCaptionTracksChanged): Ditto.
928
929         * html/track/TextTrack.cpp:
930         (WebCore::TextTrack::captionMenuOffItem): New, static TextTrack used for the menu "Off" item.
931         (WebCore::TextTrack::captionMenuAutomaticItem): New, static TextTrack used for the menu "Automatic" item.
932         * html/track/TextTrack.h:
933
934         * page/CaptionUserPreferences.cpp:
935         (WebCore::CaptionUserPreferences::shouldShowCaptions): Removed, we use captionDisplayMode instead.
936         (WebCore::CaptionUserPreferences::captionDisplayMode): New.
937         (WebCore::CaptionUserPreferences::setCaptionDisplayMode): New.
938         (WebCore::CaptionUserPreferences::setPreferredLanguage): Make the parameter a const reference.
939         (WebCore::CaptionUserPreferences::textTrackSelectionScore): Return 0 if the user doesn't want
940             captions or subtitles.
941         (WebCore::CaptionUserPreferences::textTrackLanguageSelectionScore): Take language as a parameter
942             instead of assuming that it is always the entire language list.
943         * page/CaptionUserPreferences.h:
944
945         * page/CaptionUserPreferencesMac.h:
946         * page/CaptionUserPreferencesMac.mm:
947         (WebCore::CaptionUserPreferencesMac::shouldShowCaptions): Removed, we use captionDisplayMode instead.
948         (WebCore::CaptionUserPreferencesMac::captionDisplayMode): New.
949         (WebCore::CaptionUserPreferencesMac::setCaptionDisplayMode): New.
950         (WebCore::CaptionUserPreferencesMac::setPreferredLanguage): Make the parameter a const reference.
951         (WebCore::CaptionUserPreferencesMac::textTrackSelectionScore): Deal with "Automatic" mode.
952             captions or subtitles.
953         (WebCore::CaptionUserPreferences::textTrackLanguageSelectionScore): Take language as a parameter
954             instead of assuming that it is always the entire language list.
955         (WebCore::CaptionUserPreferencesMac::sortedTrackListForMenu): Insert "Off" and "Automatic" items.
956
957         * platform/LocalizedStrings.cpp:
958         (WebCore::textTrackAutomaticMenuItemText): New.
959         * platform/LocalizedStrings.h:
960
961         * platform/graphics/MediaPlayer.cpp:
962         (WebCore::MediaPlayer::languageOfPrimaryAudioTrack): New.
963         * platform/graphics/MediaPlayer.h:
964         * platform/graphics/MediaPlayerPrivate.h:
965
966         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
967         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
968         (WebCore::MediaPlayerPrivateAVFoundationObjC::languageOfPrimaryAudioTrack): Return the language
969             of the main audio track.
970
971 2013-04-04  Alexey Proskuryakov  <ap@apple.com>
972
973         REGRESSION (r146580): Assertion using SecurityOrigin::create, URL string is not valid
974         https://bugs.webkit.org/show_bug.cgi?id=113961
975
976         Reviewed by Geoff Garen.
977
978         * page/SecurityOrigin.cpp:
979         (WebCore::SecurityOrigin::createFromDatabaseIdentifier):
980         (WebCore::SecurityOrigin::create):
981         Don't use ParsedURLString, because http://host:80/ is normalized to http://host/,
982         so it's not a parsed URL string.
983
984 2013-04-04  Sheriff Bot  <webkit.review.bot@gmail.com>
985
986         Unreviewed, rolling out r147662.
987         http://trac.webkit.org/changeset/147662
988         https://bugs.webkit.org/show_bug.cgi?id=113955
989
990         The change r147662  breaks fast/regions/fixed-pos-elem-in-
991         region.html (Requested by benjaminp on #webkit).
992
993         * rendering/RenderBlockLineLayout.cpp:
994         (WebCore::inlineLogicalWidth):
995
996 2013-04-04  Tim Horton  <timothy_horton@apple.com>
997
998         REGRESSION (r147373): Auto-sizing doesn't always respect minimum width changes
999         https://bugs.webkit.org/show_bug.cgi?id=113947
1000         <rdar://problem/13579024>
1001
1002         Reviewed by Anders Carlsson.
1003
1004         Reset the FrameView size to the minimum auto-sizing size
1005         before performing auto-sizing. We were already resetting the height,
1006         but not the width, instead using the FrameView's current width.
1007
1008         This means that changing the minimum width without also manually
1009         resizing the FrameView will never see the width change.
1010
1011         Auto-sizing tests are not working on Mac yet.
1012
1013         * page/FrameView.cpp:
1014         (WebCore::FrameView::autoSizeIfEnabled):
1015
1016 2013-04-04  Martin Robinson  <mrobinson@igalia.com>
1017
1018         [GTK] Remove the gyp build
1019         https://bugs.webkit.org/show_bug.cgi?id=113942
1020
1021         Reviewed by Gustavo Noronha Silva.
1022
1023         * WebCore.gyp/WebCoreGTK.gyp: Removed.
1024
1025 2013-04-04  Robert Hogan  <robert@webkit.org>
1026
1027         REGRESSION(r142152): Text wraps in menu
1028         https://bugs.webkit.org/show_bug.cgi?id=113706
1029
1030         Reviewed by David Hyatt.
1031
1032         * rendering/RenderBlockLineLayout.cpp:
1033         (WebCore::inlineLogicalWidth): Empty inline elements add their inline border/padding/margin to the width of the
1034         line when we iterate through them in nextLineBreak(), so no need to add them again here when climbing back up
1035         from their first child looking for border/padding/margin to add. (An empty inline element can have floating children.)
1036
1037 2013-04-04  Ryosuke Niwa  <rniwa@webkit.org>
1038
1039         Changing typing style with font size delta overrides the previous font size delta
1040         https://bugs.webkit.org/show_bug.cgi?id=113923
1041
1042         Reviewed by Andreas Kling.
1043
1044         The bug was caused by a new font size delta value overriding the old one as
1045         opposed to being added to the old value. Fixed that in overrideWithStyle.
1046
1047         Also made overrideWithStyle share code with mergeStyle since there is already
1048         code to merge text-decorations there.
1049
1050         Unfortunately, adding a test for this fix proved to be hard because we don't
1051         expose any API to directly set typing style.
1052
1053         * editing/EditingStyle.cpp:
1054         (WebCore::EditingStyle::overrideWithStyle): Use mergeStyle.
1055         (WebCore::EditingStyle::mergeStyle): Add font size deltas as opposed to simply
1056         using the new value.
1057
1058 2013-04-04  Chris Fleizach  <cfleizach@apple.com>
1059
1060         AX:File upload button has wrong label
1061         https://bugs.webkit.org/show_bug.cgi?id=113924
1062
1063         Reviewed by David Kilzer.
1064
1065         Allow the label and value to be returned for file upload controls on iOS.
1066         Due to the different AX APIs, we can expose a bit more information on iOS.
1067
1068         Test: platform/iphone-simulator/accessibility/file-upload-button.html
1069
1070         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1071         (-[WebAccessibilityObjectWrapper stringValueShouldBeUsedInLabel]):
1072         (-[WebAccessibilityObjectWrapper fileUploadButtonReturnsValueInTitle]):
1073         * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
1074         (-[WebAccessibilityObjectWrapperBase fileUploadButtonReturnsValueInTitle]):
1075         (-[WebAccessibilityObjectWrapperBase accessibilityTitle]):
1076
1077 2013-04-03  Dean Jackson  <dino@apple.com>
1078
1079         Expose settings to disable plugin snapshotting autostart and primary detection
1080         https://bugs.webkit.org/show_bug.cgi?id=113918
1081
1082         Reviewed by Tim Horton.
1083
1084         Three new settings:
1085         - snapshotAllPlugIns: Do not apply any heuristics - immediately snapshot a plugin.
1086         - primaryPlugInSnapshotDetectionEnabled: Toggle snapshotting the "main" plugin in the page.
1087         - autostartOriginPlugInSnapshottingEnabled: Toggle snapshotting based on URL origins.
1088
1089         * html/HTMLPlugInImageElement.cpp:
1090         (WebCore::HTMLPlugInImageElement::userDidClickSnapshot): Don't tell the host that we've started
1091             if the autostartOriginPlugInSnapshottingEnabled is false.
1092         (WebCore::HTMLPlugInImageElement::setIsPrimarySnapshottedPlugIn): Don't restart a primary
1093             plugin if primaryPlugInSnapshotDetectionEnabled is false.
1094         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Snapshot immediately if
1095             snapshotAllPlugIns is true. Also, don't test for autostart if
1096             autostartOriginPlugInSnapshottingEnabled is false.
1097         * page/Settings.in: Three new settings values.
1098
1099 2013-04-04  Carlos Garcia Campos  <cgarcia@igalia.com>
1100
1101         [BlackBerry] Remove skia code from PluginViewBlackBerry
1102         https://bugs.webkit.org/show_bug.cgi?id=113936
1103
1104         Reviewed by Rob Buis.
1105
1106         Skia is not used anymore by the BlackBerry port.
1107
1108         * plugins/blackberry/PluginViewBlackBerry.cpp:
1109         (WebCore::PluginView::paint):
1110
1111 2013-04-04  Emil A Eklund  <eae@chromium.org>
1112
1113         Change RenderFrameSet::computeEdgeInfo to use m-rows/m_cols directly
1114         https://bugs.webkit.org/show_bug.cgi?id=113825
1115
1116         Reviewed by Eric Seidel.
1117
1118         Tests: fast/frames/invalid-frameset-compute-edge.html
1119
1120         * rendering/RenderFrameSet.cpp:
1121         (WebCore::RenderFrameSet::computeEdgeInfo):
1122
1123 2013-04-04  ChangSeok Oh  <changseok.oh@collabora.com>
1124
1125         [GTK][AC] Invalid clear ClutterContent of ClutterActor
1126         https://bugs.webkit.org/show_bug.cgi?id=113758
1127
1128         Reviewed by Gustavo Noronha Silva.
1129
1130         Using clutter_actor_set_content(actor, 0) is better to clear ClutterContent of ClutterActor.
1131         Actually the ClutterContent referece is cleared in the API if we set 0.
1132
1133         No new tests since no functionality changed.
1134
1135         * platform/graphics/clutter/GraphicsLayerActor.cpp:
1136         (graphicsLayerActorUpdateTexture):
1137
1138 2013-04-04  Christophe Dumez  <ch.dumez@sisa.samsung.com>
1139
1140         [Cairo] Fix canvas drawing of SVG-based patterns and remove NativeImageCairo
1141         https://bugs.webkit.org/show_bug.cgi?id=113929
1142
1143         Reviewed by Martin Robinson.
1144
1145         Make (Pass)NativeImagePtr typedefs to (Pass)RefPtr<cairo_surface_t> instead
1146         of NativeImageCairo*. Now that we switch to using smart pointers,
1147         NativeImageCairo is removed as it made no sense to make it ref counted when
1148         it merely held a single ref counted member.
1149
1150         Now that Cairo is using smart pointers for (Pass)NativeImagePtr, this patch
1151         also enables the implementation of SVGImage::nativeImageForCurrentFrame()
1152         for USE(CAIRO) as well. This effectively fixes canvas drawing of SVG-based
1153         patterns for Cairo-based ports.
1154
1155         No new tests, covered by svg/canvas/canvas-pattern-svg.html.
1156
1157         * GNUmakefile.list.am: Remove NativeImageCairo.* for GTK.
1158
1159         * PlatformEfl.cmake: Remove NativeImageCairo.* for EFL.
1160
1161         * WebCore.vcproj/WebCore.vcproj:
1162         * WebCore.vcxproj/WebCore.vcxproj:
1163         * WebCore.vcxproj/WebCore.vcxproj.filters:
1164         Remove NativeImageCairo.* for Win.
1165
1166         * platform/graphics/BitmapImage.cpp:
1167         (WebCore::FrameData::reportMemoryUsage):
1168         Update MemoryClassInfo::addRawBuffer() call now that m_frame is a RefPtr
1169         for USE(CAIRO).
1170
1171         * platform/graphics/BitmapImage.h:
1172         (BitmapImage):
1173         Remove factory method taking a cairo_surface_t* in argument. This is useless
1174         now that PassNativeImagePtr is a typedef to PassRefPtr<cairo_surface_t> and
1175         there is already a factory method taking a PassNativeImagePtr in argument.
1176
1177         * platform/graphics/NativeImagePtr.h:
1178         (WebCore):
1179         Make PassNativeImagePtr a typedef to PassRefPtr<cairo_surface_t> and
1180         NativeImagePtr a typedef to RefPtr<cairo_surface_t>, instead of
1181         NativeImageCairo*. Moving to smart pointers is needed to enable implementation
1182         of SVGImage::nativeImageForCurrentFrame() for Cairo.
1183
1184         * platform/graphics/cairo/BitmapImageCairo.cpp:
1185         (WebCore::BitmapImage::BitmapImage):
1186         (WebCore::BitmapImage::draw):
1187         (WebCore::BitmapImage::checkForSolidColor):
1188         (WebCore::FrameData::clear):
1189         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
1190         (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
1191         * platform/graphics/cairo/ImageCairo.cpp:
1192         (WebCore::Image::drawPattern):
1193         Update Cairo graphics code to reflect the (Pass)NativeImagePtr type changes.
1194
1195         * platform/graphics/cairo/NativeImageCairo.cpp: Removed.
1196         * platform/graphics/cairo/NativeImageCairo.h: Removed.
1197
1198         * platform/graphics/cairo/PatternCairo.cpp:
1199         (WebCore::Pattern::createPlatformPattern):
1200         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
1201         (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
1202         * platform/graphics/efl/ImageEfl.cpp:
1203         (WebCore::BitmapImage::getEvasObject):
1204         * platform/graphics/gtk/ImageGtk.cpp:
1205         (WebCore::BitmapImage::getGdkPixbuf):
1206         * platform/graphics/texmap/TextureMapperGL.cpp:
1207         (WebCore::BitmapTextureGL::updateContents):
1208         * platform/graphics/win/ImageCairoWin.cpp:
1209         (WebCore::BitmapImage::create):
1210         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
1211         * platform/gtk/DragImageGtk.cpp:
1212         (WebCore::createDragImageFromImage):
1213         * platform/image-decoders/cairo/ImageDecoderCairo.cpp:
1214         (WebCore::ImageFrame::asNewNativeImage):
1215         * platform/win/DragImageCairoWin.cpp:
1216         (WebCore::createDragImageFromImage):
1217         Update code to reflect the (Pass)NativeImagePtr type changes.
1218
1219         * svg/graphics/SVGImage.cpp:
1220         (WebCore):
1221         * svg/graphics/SVGImage.h:
1222         Enable SVGImage::nativeImageForCurrentFrame() for USE(CAIRO).
1223
1224 2013-04-04  Ed Bartosh  <bartosh@gmail.com>
1225
1226         [EFL] --minimal build fails with 'error: unused variable'
1227         https://bugs.webkit.org/show_bug.cgi?id=113903
1228
1229         Reviewed by Gustavo Noronha Silva.
1230
1231         Moved variable definition under #if where it's used
1232         * platform/network/soup/ResourceHandleSoup.cpp:
1233         (WebCore::restartedCallback):
1234
1235 2013-04-04  Andreas Kling  <akling@apple.com>
1236
1237         Global FontPlatformData cache should use OwnPtr.
1238         <http://webkit.org/b/111939>
1239
1240         Reviewed by Anders Carlsson.
1241
1242         Let the global FontPlatformData use OwnPtr instead of raw pointers + deleteAllValues().
1243
1244         * platform/graphics/FontCache.cpp:
1245         (WebCore::FontCache::getCachedFontPlatformData):
1246         (WebCore::FontCache::purgeInactiveFontData):
1247         (WebCore::FontCache::invalidate):
1248
1249             Tweaked code for OwnPtr. Also made getCachedFontPlatformData() do one hash lookup
1250             instead of two.
1251
1252         * platform/graphics/FontCache.h:
1253         * platform/graphics/blackberry/FontCacheBlackBerry.cpp:
1254         (WebCore::FontCache::createFontPlatformData):
1255         * platform/graphics/chromium/FontCacheAndroid.cpp:
1256         (WebCore::FontCache::createFontPlatformData):
1257         * platform/graphics/freetype/FontCacheFreeType.cpp:
1258         (WebCore::FontCache::createFontPlatformData):
1259         * platform/graphics/mac/FontCacheMac.mm:
1260         (WebCore::FontCache::createFontPlatformData):
1261         * platform/graphics/qt/FontCacheQt.cpp:
1262         (WebCore::FontCache::createFontPlatformData):
1263         * platform/graphics/skia/FontCacheSkia.cpp:
1264         (WebCore::FontCache::createFontPlatformData):
1265         * platform/graphics/win/FontCacheWin.cpp:
1266         (WebCore::FontCache::createFontPlatformData):
1267         * platform/graphics/wince/FontCacheWinCE.cpp:
1268         (WebCore::FontCache::createFontPlatformData):
1269         * platform/graphics/wx/FontCacheWx.cpp:
1270         (WebCore::FontCache::createFontPlatformData):
1271
1272             FontCache::createFontPlatformData() now returns a PassOwnPtr.
1273
1274 2013-04-04  Andreas Kling  <akling@apple.com>
1275
1276         Render images with low-quality scaling while FrameView is being resized.
1277         <http://webkit.org/b/113764>
1278         <rdar://problem/13555154>
1279
1280         Reviewed by Antti Koivisto.
1281
1282         Have ImageQualityController ask the renderer's containing FrameView if it's currently in live
1283         resize, and if so, paint all images with low-quality scaling. A high-quality repaint will happen
1284         ~0.5 sec after live resizing ends, piggybacking on the same mechanism we use to do JS-animated
1285         resizing with low-quality scaling.
1286
1287         This reduces CPU time spent generating new tiles during live window resize, especially on Retina
1288         systems where a lot of upscaling happens on legacy web content.
1289
1290         * rendering/RenderBoxModelObject.cpp:
1291         (ImageQualityController):
1292
1293             Added an m_liveResizeOptimizationIsActive flag that tracks whether the ImageQualityController
1294             is painting everything in low quality due to live window resize. It gets unset when the HQ
1295             repaint timer fires and everything has been repainted properly.
1296
1297         (WebCore::ImageQualityController::highQualityRepaintTimerFired):
1298
1299             When the HQ repaint timer fires, check if the renderer's containing FrameView is still in
1300             live resize, and if so, abort HQ repaint for now and reschedule the timer.
1301
1302         (WebCore::ImageQualityController::ImageQualityController):
1303         (WebCore::ImageQualityController::objectDestroyed):
1304         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
1305
1306 2013-04-04  Seokju Kwon  <seokju.kwon@gmail.com>
1307
1308         Web Inspector: fix closure compiler warnings in IndexedDBModel.js
1309         https://bugs.webkit.org/show_bug.cgi?id=113926
1310
1311         Reviewed by Alexander Pavlov.
1312
1313         No new tests: no change in behaviour.
1314
1315         * inspector/front-end/IndexedDBModel.js:
1316
1317 2013-04-04  Xidorn Quan  <quanxunzhen@gmail.com>
1318
1319         REGRESSION (r145870): Can't get insertion point to appear in some input and textareas on wordpress
1320         https://bugs.webkit.org/show_bug.cgi?id=113591
1321
1322         Reviewed by Simon Fraser.
1323
1324         Since a child node could overflow its ancestor, it is not wise to check
1325         one's radii boundary before checking whether the given point intersects
1326         its children. This patch moves the related code down to fix the bug.
1327
1328         Test: fast/borders/border-radius-child.html
1329
1330         * rendering/RenderBlock.cpp:
1331         (WebCore::RenderBlock::nodeAtPoint):
1332
1333 2013-04-04  Xabier Rodriguez Calvar  <calvaris@igalia.com>
1334
1335         [GStreamer] Virtual modifier for MediaPlayer::simulateAudioInterruption must go
1336         https://bugs.webkit.org/show_bug.cgi?id=113851
1337
1338         Reviewed by Eric Carlson.
1339
1340         * platform/graphics/MediaPlayer.h:
1341         (MediaPlayer): Removed virtual modifier to
1342         simulateAudioInterruption.
1343
1344 2013-04-04  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1345
1346         [Qt] Support -webkit-font-smoothing
1347         https://bugs.webkit.org/show_bug.cgi?id=106009
1348
1349         Reviewed by Jocelyn Turcotte.
1350
1351         Remove false dependency on Qt 5.1 for the -webkit-font-smoothing property.
1352         For now we are still keeping the dependency on Font::shouldUseSmoothing().
1353
1354         * platform/graphics/qt/FontPlatformDataQt.cpp:
1355         (WebCore::FontPlatformData::FontPlatformData):
1356
1357 2013-04-04  Christophe Dumez  <ch.dumez@sisa.samsung.com>
1358
1359         Regression(r142765) Broke Custom SVG cursors and SVG canvas drawing for Chromium
1360         https://bugs.webkit.org/show_bug.cgi?id=113420
1361
1362         Reviewed by Stephen White.
1363
1364         Introduce a PassNativeImagePtr typedef that is used in place of NativeImagePtr
1365         for method arguments and return values. This is needed as Skia now maps
1366         NativeImagePtr to RefPtr<NativeImageSkia> and PassNativeImagePtr to
1367         PassRefPtr<NativeImageSkia>. We move towards ref counted smart pointers so that
1368         SVGImage::nativeImageForCurrentFrame() can transfer ownership of the native
1369         image to the caller if needed (e.g. for SVGImage).
1370
1371         Provide nativeImageForCurrentFrame() implementation for SVGImage. SVGImage no
1372         longer holds the native image internally, to save memory. It is therefore created
1373         when nativeImageForCurrentFrame() is called and ownership is passed to the
1374         caller. For now, this implementation is only enabled for Skia as others are using
1375         raw pointers for PassNativeImagePtr.
1376
1377         Test: svg/canvas/canvas-pattern-svg.html
1378
1379         * loader/icon/IconDatabase.cpp:
1380         (WebCore::IconDatabase::synchronousNativeIconForPageURL):
1381         Return a PassNativeImagePtr instead of NativeImagePtr.
1382
1383         * loader/icon/IconDatabase.h:
1384         (IconDatabase):
1385         * loader/icon/IconDatabaseBase.h:
1386         (WebCore::IconDatabaseBase::synchronousNativeIconForPageURL):
1387         Return a PassNativeImagePtr instead of NativeImagePtr.
1388
1389         * platform/chromium/DragImageChromiumSkia.cpp:
1390         (WebCore::createDragImageFromImage):
1391         Store return value of nativeImageForCurrentFrame() in a RefPtr instead of a raw
1392         one.
1393
1394         * platform/chromium/PasteboardChromium.cpp:
1395         (WebCore::Pasteboard::writeImage):
1396         Store return value of nativeImageForCurrentFrame() in a RefPtr<NativeImageSkia>
1397         instead of a NativeImagePtr. While these are equivalent, the former is more
1398         readable in Skia-specific code.
1399
1400         * platform/graphics/BitmapImage.cpp:
1401         (WebCore::BitmapImage::frameAtIndex):
1402         Return a PassNativeImagePtr instead of a NativeImagePtr.
1403
1404         (WebCore::BitmapImage::nativeImageForCurrentFrame):
1405         Return a PassNativeImagePtr instead of a NativeImagePtr.
1406
1407         * platform/graphics/BitmapImage.h:
1408         (WebCore::BitmapImage::create):
1409         Take a PassNativeImagePtr in argument instead of a NativeImagePtr.
1410
1411         (BitmapImage): Ditto.
1412
1413         * platform/graphics/GraphicsContext.h:
1414         (GraphicsContext): Ditto.
1415
1416         * platform/graphics/GraphicsContext3D.h:
1417         (ImageExtractor):
1418         Keep NativeImageSkia in a RefPtr instead of OwnPtr, now that it is refcounted.
1419
1420         * platform/graphics/Image.h:
1421         (WebCore::Image::nativeImageForCurrentFrame):
1422         Return a PassNativeImagePtr instead of a NativeImagePtr.
1423
1424         * platform/graphics/ImageBuffer.h:
1425         (ImageBuffer):
1426         Have copyNativeImage() return a PassNativeImagePtr instead of a NativeImagePtr.
1427
1428         * platform/graphics/ImageSource.cpp:
1429         (WebCore::ImageSource::createFrameAtIndex):
1430         Return a PassNativeImagePtr instead of a NativeImagePtr.
1431
1432         * platform/graphics/ImageSource.h:
1433         Have createFrameAtIndex() return a PassNativeImagePtr instead of a NativeImagePtr.
1434
1435         * platform/graphics/NativeImagePtr.h:
1436         Map NativeImagePtr to a RefPtr<NativeImageSkia> instead of NativeImageSkia* for Skia.
1437         Introduce new PassNativeImagePtr that maps to PassRefPtr<NativeImageSkia> for Skia
1438         and is equivalent to NativeImagePtr for other ports. We now use smart pointers for
1439         the native image so that SVGImage::nativeImageForCurrentFrame() can pass ownership
1440         of the native image to the caller, unlike BitmapImage::nativeImageForCurrentFrame().
1441
1442         * platform/graphics/blackberry/ImageBlackBerry.cpp:
1443         (WebCore::ImageFrame::asNewNativeImage):
1444         Return a PassNativeImagePtr instead of a NativeImagePtr.
1445
1446         (WebCore::BitmapImage::BitmapImage):
1447         Take a PassNativeImagePtr instead of a NativeImagePtr in argument.
1448
1449         * platform/graphics/cg/GraphicsContextCG.cpp:
1450         (WebCore::GraphicsContext::drawNativeImage): Ditto.
1451
1452         * platform/graphics/cg/ImageBufferCG.cpp:
1453         (WebCore::ImageBuffer::copyNativeImage):
1454         Take a PassNativeImagePtr instead of a NativeImagePtr in argument.
1455
1456         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1457         (WebCore::GraphicsLayerChromium::setContentsToImage):
1458         Store return value of nativeImageForCurrentFrame() in a RefPtr instead of a raw one.
1459
1460         * platform/graphics/filters/skia/FEBlendSkia.cpp:
1461         (WebCore::FEBlend::platformApplySkia): Ditto.
1462
1463         * platform/graphics/filters/skia/FEColorMatrixSkia.cpp:
1464         (WebCore::FEColorMatrix::platformApplySkia): Ditto.
1465
1466         * platform/graphics/filters/skia/FEComponentTransferSkia.cpp:
1467         (WebCore::FEComponentTransfer::platformApplySkia): Ditto.
1468
1469         * platform/graphics/filters/skia/FEDisplacementMapSkia.cpp:
1470         (WebCore::FEDisplacementMap::platformApplySkia): Ditto.
1471
1472         * platform/graphics/filters/skia/FELightingSkia.cpp:
1473         (WebCore::FELighting::platformApplySkia): Ditto.
1474
1475         * platform/graphics/qt/ImageDecoderQt.cpp:
1476         (WebCore::ImageFrame::asNewNativeImage):
1477         Return a PassNativeImagePtr instead of a NativeImagePtr.
1478
1479         * platform/graphics/qt/StillImageQt.cpp:
1480         (WebCore::StillImage::nativeImageForCurrentFrame):
1481         Return a PassNativeImagePtr instead of a NativeImagePtr.
1482
1483         * platform/graphics/qt/StillImageQt.h:
1484         (StillImage): Ditto.
1485
1486         * platform/graphics/skia/GraphicsContext3DSkia.cpp:
1487         (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
1488         No longer need to adopt the return value of asNewNativeImage() now
1489         that it returns a PassRefPtr instead of a raw one.
1490
1491         * platform/graphics/skia/ImageBufferSkia.cpp:
1492         (WebCore::ImageBuffer::copyImage):
1493         (WebCore::ImageBuffer::draw):
1494         (WebCore::ImageBuffer::drawPattern):
1495         Call NativeImageSkia::create() factory method now that the constructor
1496         is private.
1497
1498         * platform/graphics/skia/ImageSkia.cpp:
1499         (WebCore::FrameData::clear):
1500         Just call clear() on m_frame instead of explicitely deleting it now
1501         that it is a RefPtr.
1502
1503         (WebCore::Image::drawPattern):
1504         Store return value of nativeImageForCurrentFrame() in a RefPtr instead
1505         of a raw one.
1506
1507         (WebCore::BitmapImage::BitmapImage):
1508         (WebCore::BitmapImage::checkForSolidColor):
1509         Store return value of frameAtIndex() in a RefPtr instead of a raw one.
1510
1511         (WebCore::BitmapImage::draw):
1512         Store return value of nativeImageForCurrentFrame() in a RefPtr instead
1513         of a raw one.
1514
1515         * platform/graphics/skia/NativeImageSkia.cpp:
1516         Add new constructor taking all members in argument. This is used for
1517         cloning a NativeImageSkia object.
1518
1519         (WebCore::NativeImageSkia::NativeImageSkia):
1520         (WebCore::NativeImageSkia::deepSkBitmapCopy):
1521         Add convenience function to make a deep copy of a SkBitmap.
1522
1523         * platform/graphics/skia/NativeImageSkia.h:
1524         (WebCore):
1525         (WebCore::NativeImageSkia::create):
1526         (NativeImageSkia):
1527         Make NativeImageSkia subclass RefCounted. Make the constructor private
1528         and add a factory method instead that returns a PassRefPtr.
1529
1530         (WebCore::NativeImageSkia::clone):
1531         Add a clone() method now that NativeImageSkia is refcounted and is no
1532         longer copyable.
1533
1534         * platform/graphics/skia/PatternSkia.cpp:
1535         (WebCore::Pattern::platformPattern):
1536         Store return value of nativeImageForCurrentFrame() in a RefPtr instead
1537         of a raw one.
1538
1539         * platform/graphics/wince/ImageWinCE.cpp:
1540         (WebCore::ImageFrame::asNewNativeImage):
1541         Return a PassNativeImagePtr instead of a NativeImagePtr.
1542
1543         * platform/image-decoders/ImageDecoder.h:
1544         (ImageFrame):
1545         Have asNewNativeImage() return a PassNativeImagePtr instead of a
1546         NativeImagePtr.
1547
1548         (WebCore::ImageFrame::getAddr):
1549         (WebCore::ImageFrame::setSkBitmap):
1550         (WebCore::ImageFrame::getSkBitmap):
1551         (WebCore::ImageFrame::width):
1552         (WebCore::ImageFrame::height):
1553         Update use of m_bitmap now that it is a pointer type and call
1554         NativeImageSkia::create() to construct a NativeImageSkia object now
1555         that the constructor is private.
1556
1557         * platform/image-decoders/cairo/ImageDecoderCairo.cpp:
1558         (WebCore::ImageFrame::asNewNativeImage):
1559         Return a PassNativeImagePtr instead of a NativeImagePtr.
1560
1561         * platform/image-decoders/openvg/ImageDecoderOpenVG.cpp:
1562         (WebCore::ImageFrame::asNewNativeImage): Ditto.
1563
1564         * platform/image-decoders/skia/ImageDecoderSkia.cpp:
1565         (WebCore::ImageFrame::ImageFrame):
1566         Initialize m_bitmap in the constructor now that it is a pointer
1567         type and we need NativeImageSkia's default constructor to be
1568         called.
1569
1570         (WebCore::ImageFrame::operator=):
1571         Call NativeImageSkia's new clone() method to copy m_bitmap as
1572         NativeImageSkia is now RefCounted and no longer copyable.
1573
1574         (WebCore::ImageFrame::clearPixelData):
1575         (WebCore::ImageFrame::zeroFillPixelData):
1576         (WebCore::ImageFrame::copyBitmapData):
1577         (WebCore::ImageFrame::setSize):
1578         Update use of m_bitmap now that it is a pointer type.
1579
1580         (WebCore::ImageFrame::asNewNativeImage):
1581         Return a PassNativeImagePtr instead of a NativeImagePtr.
1582         Call NativeImageSkia's clone method now that it is no longer
1583         copyable.
1584
1585         (WebCore::ImageFrame::setHasAlpha):
1586         (WebCore::ImageFrame::setStatus):
1587         Update use of m_bitmap now that it is a pointer type.
1588
1589         * platform/image-decoders/wx/ImageDecoderWx.cpp:
1590         (WebCore::ImageFrame::asNewNativeImage):
1591         Return a PassNativeImagePtr instead of a NativeImagePtr.
1592
1593         * svg/graphics/SVGImage.cpp:
1594         (WebCore):
1595         (WebCore::SVGImage::nativeImageForCurrentFrame):
1596         Add implementation of nativeImageForCurrentFrame() for SVGImage as
1597         it is needed for SVG custom cursor support and Canvas drawing of
1598         patterns containing SVG images. As SVGImage no longer keep the
1599         native image internally to save memory, the implementation creates
1600         the native image when nativeImageForCurrentFrame() and passes
1601         its ownership to the caller.
1602
1603         * svg/graphics/SVGImage.h:
1604         Override Image::nativeImageForCurrentFrame() and remove dummy
1605         implementation of frameAtIndex() as it is not needed / used.
1606
1607         * svg/graphics/SVGImageForContainer.cpp:
1608         (WebCore::SVGImageForContainer::nativeImageForCurrentFrame):
1609         Add implementation of nativeImageForCurrentFrame() which merely
1610         forwards the call to the Image being contained.
1611
1612         * svg/graphics/SVGImageForContainer.h:
1613         Override Image::nativeImageForCurrentFrame().
1614
1615 2013-04-04  Andrei Bucur  <abucur@adobe.com>
1616
1617         [CSSRegions] RenderFlowThread::renderRegionForLine should use a faster search method
1618         https://bugs.webkit.org/show_bug.cgi?id=66921
1619
1620         Reviewed by David Hyatt.
1621
1622         The RenderFlowThread::regionAtBlockOffset() function is a hot path for the code using
1623         flow threads because it translates from block coordinates to regions.
1624         Currently the method is O(n), using a linear search through the regions chain to find the
1625         region where a block offset lands.
1626         The patch improves this search by using an interval tree (PODIntervalTree). Before a flow
1627         thread is laid out, each region is updated to hold the size of the portion of the flow it
1628         will receive. This information is gathered inside the interval tree and used to speedup the
1629         search in RenderFlowThread::regionAtBlockOffset(). The algorithm uses a custom adapter
1630         simplified for looking up offsets inside the interval tree.
1631         For now, the interval tree is cleared every time the flow thread portions list is updated.
1632         The implementation can be improved but induces some cmplexity as we'd have to manually manage
1633         the life cycle of the tree's nodes. The performance gains are good enough as is to make this
1634         only optional.
1635         Another important change is now the flow thread portion rectangles will not overflow when
1636         using auto-height regions (or very large regions). The maximum size of the flow is set to
1637         LayoutUnit::max()/2. Any region forcing a greater size will be capped so the thread
1638         won't overflow.
1639
1640         Performance test results:
1641         /Layout/RegionsAuto:Time            ms 699.95   181.20  74.11% Better
1642         /Layout/RegionsAutoMaxHeight:Time   ms 2083.00  308.55  85.19% Better
1643         /Layout/RegionsFixed:Time           ms 726.10   223.65  69.20% Better
1644         /Layout/RegionsFixedShort:Time      ms 869.60   288.25  66.85% Better
1645
1646         Tests: See PerformanceTests/Layout/Regions*
1647
1648         * rendering/RenderFlowThread.cpp:
1649         (WebCore::RenderFlowThread::regionAtBlockOffset):
1650         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
1651         (WebCore::RenderFlowThread::RegionSearchAdapter::collectIfNeeded):
1652         (WebCore):
1653         * rendering/RenderFlowThread.h:
1654         (WebCore):
1655
1656 2013-04-04  Seokju Kwon  <seokju.kwon@gmail.com>
1657
1658         [Qt] WebSocket errors should be logged to console
1659         https://bugs.webkit.org/show_bug.cgi?id=113842
1660
1661         Reviewed by Jocelyn Turcotte.
1662
1663         Pass the reason of a failure to SocketStreamError instance
1664         and notify it via SocketStreamHandleClient::didFailSocketStream().
1665
1666         Test : http/tests/inspector/console-websocket-error.html
1667
1668         * platform/network/qt/SocketStreamError.h:
1669         (WebCore::SocketStreamError::SocketStreamError):
1670         * platform/network/qt/SocketStreamHandleQt.cpp:
1671         (WebCore::SocketStreamHandlePrivate::SocketStreamHandlePrivate):
1672         (WebCore::SocketStreamHandlePrivate::socketErrorCallback):
1673
1674 2013-04-04  Ed Bartosh  <bartosh@gmail.com>
1675
1676         [ATK] build fails when accessibility is turned off
1677         https://bugs.webkit.org/show_bug.cgi?id=113699
1678
1679         Reviewed by Gyuyoung Kim.
1680
1681         * editing/atk/FrameSelectionAtk.cpp: Wrapped accessibility code in #if HAVE(ACCESSIBILITY)
1682
1683 2013-04-04  Seokju Kwon  <seokju.kwon@gmail.com>
1684
1685         Web Inspector: fix closure compiler warnings in the profiler code HeapSnapshotDataGrids.js
1686         https://bugs.webkit.org/show_bug.cgi?id=113922
1687
1688         Reviewed by Yury Semikhatsky.
1689
1690         No new tests: no change in behaviour.
1691
1692         * inspector/front-end/HeapSnapshotDataGrids.js:
1693
1694 2013-04-03  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1695
1696         [EFL] Add a decoration image to search input field
1697         https://bugs.webkit.org/show_bug.cgi?id=113552
1698
1699         Reviewed by Laszlo Gombos.
1700
1701         Though EFL port has a decoration image for search input field, we didn't use it.
1702         Start to show it.
1703
1704         Tests: fast/forms/search-cancel-button-style-sharing.html
1705                fast/forms/search-rtl.html
1706                fast/css/input-search-padding.html
1707                fast/css/text-input-with-webkit-border-radius.html
1708                fast/css/text-overflow-input.html
1709                fast/forms/box-shadow-override.html
1710                fast/forms/control-restrict-line-height.html
1711                fast/forms/input-appearance-height.html
1712                fast/forms/placeholder-position.html
1713                fast/forms/placeholder-pseudo-style.html
1714                fast/forms/search-styled.html
1715                fast/forms/search-vertical-alignment.html
1716                fast/forms/searchfield-heights.html
1717                fast/repaint/search-field-cancel.html 
1718                fast/replaced/width100percent-searchfield.html
1719
1720         * platform/efl/RenderThemeEfl.cpp:
1721         (WebCore):
1722         (WebCore::RenderThemeEfl::supportsDataListUI):
1723         (WebCore::RenderThemeEfl::adjustSearchFieldDecorationStyle):
1724
1725 2013-04-03  Kent Tamura  <tkent@chromium.org>
1726
1727         Input value/placeholder is not redrawn when the input height grows
1728         https://bugs.webkit.org/show_bug.cgi?id=113845
1729
1730         Reviewed by Ojan Vafai.
1731
1732         Test: fast/forms/text/text-height-grow.html
1733
1734         * rendering/RenderTextControlSingleLine.cpp:
1735         (WebCore::RenderTextControlSingleLine::styleDidChange):
1736         We need relayout of the inner text element.
1737
1738 2013-04-03  Shawn Singh  <shawnsingh@chromium.org>
1739
1740         Add comment to clarify isStackingContext() in RenderLayer.h
1741         https://bugs.webkit.org/show_bug.cgi?id=113909
1742
1743         Reviewed by Simon Fraser.
1744
1745         It was not obvious how the implementation of isStackingContext()
1746         was correct, a comment is appropriate here for anyone who reads
1747         this code in the future.
1748
1749         Just a change in comment, no test needed.
1750
1751         * rendering/RenderLayer.h:
1752
1753 2013-04-03  Hans Muller  <hmuller@adobe.com>
1754
1755         [CSS Exclusions] Removed ExclusionShape dead code
1756         https://bugs.webkit.org/show_bug.cgi?id=113904
1757
1758         Reviewed by Dirk Schulze.
1759
1760         No new tests, just removing dead code.
1761
1762         * rendering/ExclusionShape.cpp:
1763         (WebCore::ExclusionShape::createExclusionShape):
1764         * rendering/ExclusionShape.h:
1765         (ExclusionShape):
1766
1767 2013-04-03  Otto Derek Cheung  <otcheung@rim.com>
1768
1769         [BlackBerry] Switch MediaPlayerPrivateBlackBerry.cpp's timer to use CLOCK_MONOTONIC
1770         https://bugs.webkit.org/show_bug.cgi?id=113900
1771
1772         Reviewed by Rob Buis.
1773         Internally Reviewed by Jeff Rogers.
1774
1775         Timers should use CLOCK_MONOTONIC to avoid undesirable effects when
1776         the user switches the system time.
1777
1778         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
1779         (WebCore::MediaPlayerPrivate::drawBufferingAnimation):
1780
1781 2013-04-03  Dave Michael  <dmichael@chromium.org>
1782
1783         Unable to focus on embedded plugins such as Flash via javascript focus()
1784         https://bugs.webkit.org/show_bug.cgi?id=32292
1785
1786         Reviewed by Ryosuke Niwa.
1787
1788         Make embed, object, and applet elements support focus() when
1789         appropriate. Prior to this patch, javascript focus() had no effect on
1790         embed, object, or applet elements unless tabindex or contenteditable is
1791         set. With this patch, focus() will focus the element unless the plugin
1792         content has failed to load (i.e., we are showing either fallback content
1793         or an unavailable plugin indicator).
1794
1795         Test: plugins/focus.html
1796               java/focus.html
1797
1798         * html/HTMLPlugInElement.cpp:
1799         (WebCore::HTMLPlugInElement::supportsFocus):
1800         Overridden to return true except when the plugin content has failed to load.
1801         * html/HTMLPlugInElement.h:
1802         (WebCore::HTMLPlugInElement::useFallbackContent):
1803         Moved up from HTMLPlugInImageElement.
1804         (WebCore::HTMLPlugInElement::supportsFocus):
1805         * html/HTMLPlugInElement.h:
1806         (WebCore::HTMLPlugInImageElement::useFallbackContent):
1807         Removed. Now the implementation is inherited from HTMLPlugInElement.
1808
1809 2013-04-03  Glenn Adams  <glenn@skynav.com>
1810
1811         Element boundaries prevent Japanese line break opportunities
1812         https://bugs.webkit.org/show_bug.cgi?id=105692
1813
1814         Reviewed by Darin Adler.
1815
1816         Introduce use of prior context when using text break iterators
1817         in non-ASCII path through nextBreakablePosition(). This enables
1818         the use of line break context across an element boundary for
1819         the non-ASCII path. Use of this context with the ASCII path was
1820         enabled by https://bugs.webkit.org/show_bug.cgi?id=17427.
1821
1822         Performance tests of line layout and html5 parsing show that this
1823         patch provides an approximately 4% improvement with Japanese and
1824         no statistically significant regression with ASCII path. Parsing
1825         (html5-full-render) performance is not significantly affected.
1826
1827         Tests: fast/text/line-break-between-text-nodes-cjk.html
1828                fast/text/line-break-between-text-nodes-latin1.html
1829
1830         Expect rebaselines will be needed due to different line breaks:
1831                fast/text/international/003.html
1832                fast/text/international/text-combine-image-test-expected.html
1833                fast/text/writing-mode/Kusa-Makura-background-canvas.html
1834
1835         * platform/text/TextBreakIterator.cpp:
1836         (WebCore::acquireLineBreakIterator): Pass prior context to non-ICU path.
1837         * platform/text/TextBreakIterator.h:
1838         (WebCore::LazyLineBreakIterator::priorContextLength): Added.
1839         (WebCore::LazyLineBreakIterator::get): Pass prior context to ICU path.
1840         (WebCore::LazyLineBreakIterator::resetStringAndReleaseIterator): Editorial.
1841         * platform/text/TextBreakIteratorICU.cpp:
1842         Use prior context from line break iterators. Requires
1843         adding new UTF16 (UChar*) text provider and reimplementing
1844         Latin1 (LChar*) text provider. Implementation is optimized
1845         by using generic functionality that applies to both string
1846         sources.
1847         (WebCore::textPinIndex): Added.
1848         (WebCore::textNativeLength): Added.
1849         (WebCore::textFixPointer): Added.
1850         (WebCore::textClone): Added.
1851         (WebCore::textExtract): Added.
1852         (WebCore::textClose): Added.
1853         (WebCore::textGetContext): Added.
1854         (WebCore::textLatin1GetCurrentContext): Added.
1855         (WebCore::textLatin1MoveInPrimaryContext): Added.
1856         (WebCore::textLatin1SwitchToPrimaryContext): Added.
1857         (WebCore::textLatin1MoveInPriorContext): Added.
1858         (WebCore::textLatin1SwitchToPriorContext): Added.
1859         (WebCore::textInChunkOrOutOfRange): Added.
1860         (WebCore::textLatin1Access): Added.
1861         (WebCore::textInit): Added.
1862         (WebCore::textOpenLatin1): Added.
1863         (WebCore::textUTF16GetCurrentContext): Added.
1864         (WebCore::textUTF16MoveInPrimaryContext): Added.
1865         (WebCore::textUTF16SwitchToPrimaryContext): Added.
1866         (WebCore::textUTF16MoveInPriorContext): Added.
1867         (WebCore::textUTF16SwitchToPriorContext): Added.
1868         (WebCore::textUTF16Access): Added.
1869         (WebCore::textOpenUTF16): Added.
1870         (WebCore::acquireLineBreakIterator): Use new text providers with prior context.
1871         * platform/text/wchar/TextBreakIteratorWchar.cpp:
1872         (WebCore::acquireLineBreakIterator): Pass prior context to non-ICU path.
1873         * rendering/break_lines.cpp:
1874         (WebCore::nextBreakablePosition): Use prior context in ICU path.
1875
1876 2013-04-03  Christophe Dumez  <ch.dumez@sisa.samsung.com>
1877
1878         [Chromium] Bad cast from BitmapImageSingleFrameSkia to BitmapImage
1879         https://bugs.webkit.org/show_bug.cgi?id=113492
1880
1881         Reviewed by Stephen White.
1882
1883         Remove BitmapImageSingleFrameSkia and have ImageBufferSkia construct
1884         BitmapImage objects instead via an intermediate NativeImageSkia.
1885
1886         No new tests, covered by existing tests.
1887
1888         * WebCore.gypi:
1889         * platform/graphics/filters/skia/FEGaussianBlurSkia.cpp: Remove
1890         include for BitmapImageSingleFrameSkia.h header.
1891         * platform/graphics/skia/BitmapImageSingleFrameSkia.cpp: Removed.
1892         * platform/graphics/skia/BitmapImageSingleFrameSkia.h: Removed.
1893         * platform/graphics/skia/ImageBufferSkia.cpp: Construct BitmapImage
1894         objects instead of BitmapImageSingleFrameSkia ones.
1895         (WebCore::ImageBuffer::copyImage):
1896         (WebCore::drawNeedsCopy):
1897         (WebCore::ImageBuffer::draw):
1898         (WebCore::ImageBuffer::drawPattern):
1899         * platform/graphics/skia/ImageSkia.cpp:
1900         (WebCore::BitmapImage::BitmapImage): Implement BitmapImage constructor
1901         that takes an NativeImageSkia* in argument.
1902         (WebCore):
1903         (WebCore::BitmapImage::draw): Remove m_source.initialized() check as
1904         this will return false for BitmapImage objects constructed from a
1905         NativeImageSkia, due to the lack of decoder.
1906         * platform/graphics/skia/NativeImageSkia.cpp:
1907         (WebCore::NativeImageSkia::NativeImageSkia): Add parameter to the
1908         NativeImageSkia constructor so that the caller can request a deep copy
1909         instead of a shallow one. This is needed by the ImageBuffer.
1910         * platform/graphics/skia/NativeImageSkia.h:
1911         * platform/image-decoders/ImageDecoder.h:
1912         (WebCore::ImageFrame::setSkBitmap):
1913
1914 2013-04-03  David Vest  <davve@opera.com>
1915
1916         ASSERTION FAILED: resultAnimationElement->m_animatedType
1917         https://bugs.webkit.org/show_bug.cgi?id=93528
1918
1919         Reviewed by Philip Rogers.
1920
1921         When the order of animation elements change within an animation
1922         group, we can't assume that the resultElement is the same as it
1923         was when the animation was frozen. Make sure to reset the
1924         animation type for the resultElement before updating the
1925         animation.
1926
1927         Test: svg/animations/animation-dependency-crash.html
1928
1929         * svg/animation/SVGSMILElement.cpp:
1930         (WebCore::SVGSMILElement::progress):
1931
1932 2013-04-03  Timothy Hatcher  <timothy@apple.com>
1933
1934         Stop unconditionally enabling JavaScript execution when closing the Web Inspector.
1935
1936         https://webkit.org/b/113889
1937         rdar://problem/12281794
1938
1939         Reviewed by Joseph Pecoraro.
1940
1941         * inspector/InspectorPageAgent.cpp:
1942         (WebCore::InspectorPageAgent::InspectorPageAgent): Initialize m_originalScriptExecutionDisabled.
1943         (WebCore::InspectorPageAgent::enable): Populate m_originalScriptExecutionDisabled based on current setting.
1944         (WebCore::InspectorPageAgent::disable): Restore previous setting.
1945         * inspector/InspectorPageAgent.h:
1946         (InspectorPageAgent): Added m_originalScriptExecutionDisabled.
1947
1948 2013-04-03  Dean Jackson  <dino@apple.com>
1949
1950         Cross fade into restarted plugin
1951         https://bugs.webkit.org/show_bug.cgi?id=113868
1952
1953         Reviewed by Tim Horton.
1954
1955         Allow a restarted plugin to fade in over its snapshot, avoiding the abrupt
1956         flash of empty content. The WebCore part of this patch marks the plugin
1957         element as restarted, and draws the snapshot for a short amount of time
1958         as the plugin is restarting. After the plugin has reappeared, we stop drawing
1959         the snapshot.
1960
1961         There is a little bit of drive-by whitespace removal in HTMLPlugInImageElement.
1962
1963         * html/HTMLPlugInElement.h:
1964         (WebCore::HTMLPlugInElement::restartedPlugin): New method indicating if the plugin has been restarted.
1965         * html/HTMLPlugInImageElement.cpp:
1966         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): Initialise new timer and member variable.
1967         (WebCore::HTMLPlugInImageElement::setDisplayState): If we are moving into a restarting state, make sure
1968             to remember this and also start a timer so that we show the snapshot for while.
1969         (WebCore::HTMLPlugInImageElement::removeSnapshotTimerFired): No need to draw the snapshot from here on.
1970         * html/HTMLPlugInImageElement.h:
1971         (HTMLPlugInImageElement): Member variable to remember if we've restarted.
1972         * rendering/RenderEmbeddedObject.cpp:
1973         (WebCore::RenderEmbeddedObject::paintContents): Only exit early from the paint if we're not a restarting
1974             plugin, otherwise we do want to draw the snapshot if there is one.
1975         * rendering/RenderLayerBacking.cpp:
1976         (WebCore::isRestartedPlugin): Detects a restarted plugin.
1977         (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer): Don't become a simple container
1978             compositing layer if you're a restarted plugin.
1979
1980 2013-04-03  John Griggs  <jgriggs@blackberry.com>
1981
1982         [BlackBerry] Adjustments to media controls appearance.
1983         https://bugs.webkit.org/show_bug.cgi?id=113816
1984         https://przilla.ott.qnx.com/bugzilla/show_bug.cgi?id=316398
1985         https://przilla.ott.qnx.com/bugzilla/show_bug.cgi?id=316438
1986
1987         Updates to the BlackBerry media controls:
1988          - extend the timeline slider.
1989          - move the volume slider for audio elements up so it does not overlap the main panel.
1990          - upstream some other cosmetic changes to media controls that were not previously upstreamed.
1991
1992         Reviewed by Rob Buis.
1993
1994         BlackBerry-specific, cosmetic change; No new tests required.
1995
1996         * platform/blackberry/RenderThemeBlackBerry.cpp:
1997         (WebCore::RenderThemeBlackBerry::adjustMediaControlStyle):
1998         (WebCore::RenderThemeBlackBerry::paintMediaPlayButton):
1999         (WebCore::RenderThemeBlackBerry::paintMediaMuteButton):
2000         (WebCore::RenderThemeBlackBerry::paintMediaSliderTrack):
2001         (WebCore::RenderThemeBlackBerry::paintMediaVolumeSliderTrack):
2002         (WebCore::RenderThemeBlackBerry::paintMediaVolumeSliderThumb):
2003
2004 2013-04-03  Christophe Dumez  <ch.dumez@sisa.samsung.com>
2005
2006         [Gstreamer] Use gst_buffer_extract() in copyGstreamerBuffersToAudioChannel()
2007         https://bugs.webkit.org/show_bug.cgi?id=113880
2008
2009         Reviewed by Philippe Normand.
2010
2011         copyGstreamerBuffersToAudioChannel() was mapping the GstBuffer content to memcpy
2012         it to the AudioChannel buffer. This patch leverages gst_buffer_extract() to
2013         simplify the code as it does exactly what we need: gst_buffer_map, memcpy,
2014         gst_buffer_unmap and error handling.
2015
2016         Also replace GstBuffer NULL check by an assertion as we already make sure they
2017         are not NULL before adding them to the list. Additionally, we now call
2018         audioChannel->mutableData() only once instead of once per iteration. It is
2019         a bit better as the getter does some work internally.
2020
2021         No new tests, no behavior change.
2022
2023         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
2024         (WebCore::copyGstreamerBuffersToAudioChannel):
2025
2026 2013-04-03  Antoine Quint  <graouts@apple.com>
2027
2028         Web Inspector: DOM.highlightRect() and DOM.highlightQuad() should allow for page coordinates
2029         https://bugs.webkit.org/show_bug.cgi?id=113869
2030
2031         Add a new "usePageCoordinates" parameter to DOM.highlightRect() and DOM.highlightQuad()
2032         allowing to specify that the rect or quad to highlight should be converted to page
2033         coordinates instead of using the default viewport coordinates.
2034
2035         Reviewed by Timothy Hatcher.
2036
2037         * inspector/Inspector.json:
2038         * inspector/InspectorDOMAgent.cpp:
2039         (WebCore::InspectorDOMAgent::highlightRect):
2040         (WebCore::InspectorDOMAgent::highlightQuad):
2041         (WebCore::InspectorDOMAgent::innerHighlightQuad):
2042         Store the "usePageCoordinates" parameter obtained from the protocol calls onto the
2043         highlight configuration object so that it may be used within the InspectorOverlay.
2044
2045         * inspector/InspectorDOMAgent.h:
2046         (InspectorDOMAgent):
2047         * inspector/InspectorOverlay.cpp:
2048         (WebCore::InspectorOverlay::highlightQuad):
2049         Check the highlight configuration for the "usePageCoordinates" parameter and
2050         apply the inverse of the page's scroll offset to the quad if it's true.
2051
2052         * inspector/InspectorOverlay.h:
2053         (HighlightConfig):
2054         (WebCore::Highlight::setDataFromConfig):
2055         (Highlight):
2056
2057 2013-04-03  Kangil Han  <kangil.han@samsung.com>
2058
2059         Add omitted reference operator of VisiblePosition in AccessibilityObject
2060         https://bugs.webkit.org/show_bug.cgi?id=113879
2061
2062         Reviewed by Darin Adler.
2063
2064         Seems reference operator has been omitted in startOfStyleRange function, so add it.
2065
2066         * accessibility/AccessibilityObject.cpp:
2067         (WebCore::startOfStyleRange):
2068
2069 2013-04-03  Jessie Berlin  <jberlin@apple.com>
2070
2071         Update the localizable strings file.
2072
2073         Rubber-stamped by Michael Saboff.
2074
2075         * English.lproj/Localizable.strings:
2076
2077 2013-04-03  David Kilzer  <ddkilzer@apple.com>
2078
2079         BUILD FIX (r147493): Fix number of arguments to AudioDestinationIOS constructor
2080
2081         Fixes the following build failures:
2082
2083             Source/WebCore/platform/audio/ios/AudioDestinationIOS.cpp:84:25: error: no matching constructor for initialization of 'WebCore::AudioDestinationIOS'
2084                 return adoptPtr(new AudioDestinationIOS(callback, sampleRate));
2085                                     ^                   ~~~~~~~~~~~~~~~~~~~~
2086             In file included from Source/WebCore/platform/audio/ios/AudioDestinationIOS.cpp:36:
2087             Source/WebCore/platform/audio/ios/AudioDestinationIOS.h:44:5: note: candidate constructor not viable: requires 3 arguments, but 2 were provided
2088                 AudioDestinationIOS(AudioIOCallback&, unsigned numberOfOutputChannels, double sampleRate);
2089                 ^
2090             Source/WebCore/platform/audio/ios/AudioDestinationIOS.h:42:7: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
2091             class AudioDestinationIOS : public AudioDestination, public AudioSessionListener {
2092                   ^
2093             Source/WebCore/platform/audio/ios/AudioDestinationIOS.cpp:101:22: error: out-of-line definition of 'AudioDestinationIOS' does not match any declaration in 'WebCore::AudioDestinationIOS'
2094             AudioDestinationIOS::AudioDestinationIOS(AudioIOCallback& callback, double sampleRate)
2095                                  ^~~~~~~~~~~~~~~~~~~
2096             2 errors generated.
2097
2098         * platform/audio/ios/AudioDestinationIOS.h:
2099         (AudioDestinationIOS): Remove numberOfOutputChannels argument.
2100
2101 2013-04-03  David Kilzer  <ddkilzer@apple.com>
2102
2103         BUILD FIX (r147494): -[AVAudioSession setCategory:error:] takes NSError**
2104
2105         Fixes the following build failure:
2106
2107             Source/WebCore/platform/audio/ios/AudioSessionIOS.mm:151:71: error: cannot initialize a parameter of type 'NSError **' with an lvalue of type 'NSError *'
2108                 [[AVAudioSession sharedInstance] setCategory:categoryString error:error];
2109                                                                                   ^~~~~
2110
2111         * platform/audio/ios/AudioSessionIOS.mm:
2112         (WebCore::AudioSession::setCategory): Add '&' operator.
2113
2114 2013-04-03  Felipe Zimmerle  <felipe@zimmerle.org>
2115
2116         CSP blocks inline style when cloning a node
2117         https://bugs.webkit.org/show_bug.cgi?id=112270
2118
2119         Reviewed by Adam Barth.
2120
2121         Checks if the Element is being cloned, if so, the application of the
2122         style is allowed otherwise it relies on default permission mechanism.
2123
2124         Test: http/tests/security/contentSecurityPolicy/inline-style-allowed-while-cloning-objects.html
2125
2126         * dom/Element.cpp:
2127         (WebCore::Element::attributeChanged): Added parameter
2128         AttributeModificationReason to the method signature.
2129         (WebCore::Element::cloneAttributesFromElement): It is now calling 
2130         attributeChanged with AttributeModificationReason parameter. In this scope
2131         it is always set to ModifiedByCloning.
2132         (WebCode::Element::attributeChangedFromParserOrByCloning):
2133         Added parameter AttributeModificationReason.
2134         * dom/Element.h: Added AttributeModificationReason enum. Used to specify
2135         whenever an attribute was set by a cloned oject or directly.
2136         AttributeModificationReason added to attributeChanged with the default
2137         value set to ModifiedDirectly. 
2138         * dom/StyledElement.cpp: 
2139         (WebCore::StyledElement::attributeChanged): Added
2140         AttributeModificationReason to the method signature.
2141         (WebCore::StyledElement::styleAttributeChanged): Now it is checking the
2142         reason of the update, if the reason is ModifiedDirectly check CSP
2143         before set. If ModifiedByCloning set the attribute ignoring the CSP
2144         policy.
2145         * dom/StyledElement.h:
2146         (StyledElement): Added AttributeModificationReason parameter to the methods:
2147         attributeChanged and styleAttributeChanged, attributeChanged has
2148         ModifiedDirectly as default value.
2149         * svg/SVGElement.cpp: 
2150         (WebCore::SVGElement::attributeChanged): Added AttributeModificationReason
2151         parameter to the method signature.
2152         * svg/SVGElement.h: 
2153         (SVGElement): Added AttributeModificationReason parameter to the
2154         attributeChanged signature with the default value set to:
2155         ModifiedDirectly.
2156
2157 2013-04-03  Csaba Osztrogonác  <ossy@webkit.org>
2158
2159         Unreviewed 32bit buildfix after r147542.
2160
2161         * Modules/websockets/WebSocket.cpp:
2162         (WebCore::WebSocket::didReceiveBinaryData):
2163
2164 2013-04-03  Christophe Dumez  <ch.dumez@sisa.samsung.com>
2165
2166         [Gstreamer] Avoid calls to g_slist_nth_data in webKitWebAudioSrcLoop()
2167         https://bugs.webkit.org/show_bug.cgi?id=113875
2168
2169         Reviewed by Philippe Normand.
2170
2171         webKitWebAudioSrcLoop() was iterating over 2 GSLists by using a counter and then
2172         calling g_slist_nth_data() to get the element of each GSList. This is inefficient
2173         because calling g_slist_nth_data() will iterate the GSList up until index 'n'.
2174
2175         This patch improves this by keeping pointers to the current element of each list
2176         while iterating, so that we can simply use g_slist_next() to iterate instead
2177         of g_slist_nth_data().
2178
2179         No new tests, no behavior change.
2180
2181         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
2182         (webKitWebAudioSrcLoop):
2183
2184 2013-04-03  Keishi Hattori  <keishi@webkit.org>
2185
2186         Actions that require user gesture don't work in window.showModalDialog in Chromium
2187         https://bugs.webkit.org/show_bug.cgi?id=113777
2188
2189         Reviewed by Jochen Eisinger.
2190
2191         In Chromium the window for showModalDialog is not modal which causes the
2192         UserGestureIndicator to block actions in the sub window. We introduce a
2193         RAII that saves the UserGestureIndicator and state, then resets it before
2194         runModalDialog, and restore it when it's done.
2195
2196         No new tests. Can't cause user gesture inside modal dialog.
2197
2198         * dom/UserGestureIndicator.cpp:
2199         (WebCore::UserGestureIndicatorDisabler::UserGestureIndicatorDisabler): Saves and resets the topmost indicator and state.
2200         (WebCore):
2201         (WebCore::UserGestureIndicatorDisabler::~UserGestureIndicatorDisabler): Restores topmost indicator and state.
2202         * dom/UserGestureIndicator.h:
2203         (WebCore):
2204         (UserGestureIndicatorDisabler): RAII to temporarily disable UserGestureIndicator.
2205         (UserGestureIndicator): Allow access to UserGestureIndicatorDisabler.
2206         * page/DOMWindow.cpp:
2207         (WebCore::DOMWindow::showModalDialog): Disable UserGestureIndicator while runModalDialog.
2208
2209 2013-04-03  Zeno Albisser  <zeno@webkit.org>
2210
2211         [Qt] Fail gracefully if an OpenGL context could not be created.
2212         https://bugs.webkit.org/show_bug.cgi?id=113784
2213
2214         In case we fail to create or adopt a valid platform OpenGL context
2215         we do not want to provide a GraphicsContext3D instance.
2216         Otherwise we would crash as soon as the instance is being used.
2217
2218         Reviewed by Jocelyn Turcotte.
2219
2220         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2221         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
2222         (WebCore::GraphicsContext3D::GraphicsContext3D):
2223
2224 2013-04-03  ChangSeok Oh  <changseok.oh@collabora.com>
2225
2226         [GTK][AC] Implement matrix keyframe animations with clutter ac backend
2227         https://bugs.webkit.org/show_bug.cgi?id=110314
2228
2229         Reviewed by Gustavo Noronha Silva.
2230
2231         Clutter 1.12 doesn't support additive transform animations yet, So clutter ac backend
2232         uses matrix animations for the case. This patch follows changeset 143369, 143343
2233         to support matrix keyframe animations. I believe this change is easy if you understand
2234         above two changesets.
2235
2236         Covered by existing animation tests.
2237
2238         * platform/graphics/clutter/PlatformClutterAnimation.cpp:
2239         (WebCore::PlatformClutterAnimation::setValues):
2240         (WebCore::PlatformClutterAnimation::addClutterKeyframeTransitionForProperty):
2241         (WebCore):
2242         (WebCore::PlatformClutterAnimation::addTransformTransition):
2243         * platform/graphics/clutter/PlatformClutterAnimation.h:
2244         (PlatformClutterAnimation):
2245
2246 2013-04-03  Gustavo Noronha Silva  <gustavo.noronha@collabora.com>
2247
2248         Should close select popup when the element loses focus
2249         https://bugs.webkit.org/show_bug.cgi?id=113220
2250
2251         Reviewed by Kent Tamura.
2252
2253         Test: fast/forms/select-popup-closes-on-blur.html
2254
2255         * html/HTMLSelectElement.cpp:
2256         (WebCore::HTMLSelectElement::menuListDefaultEventHandler): handle the blur event, closing
2257         the popup menu if any.
2258         * testing/Internals.cpp:
2259         (WebCore::Internals::isSelectPopupVisible): utility to query the select node renderer to
2260         find out whether the popup is open or closed.
2261         (WebCore):
2262         * testing/Internals.h: add the new method definition.
2263         * testing/Internals.idl: ditto.
2264
2265 2013-03-28  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
2266
2267         [Qt] Switch ContextMenu implementation to CROSS_PLATFORM_CONTEXT_MENU
2268         https://bugs.webkit.org/show_bug.cgi?id=113535
2269
2270         Reviewed by Simon Hausmann.
2271
2272         Now Qt uses the CROSS_PLATFORM_CONTEXT_MENUS
2273         USE flag. This flag provides a full cross-platform
2274         representation of a ContextMenu and a ContextMenuItem.
2275         The embedder can then decide how to show this, so neither
2276         WebCore nor WebCore/platform need to know any platform
2277         specifics about menus.
2278
2279         No new tests, no behavior changes.
2280
2281         * Target.pri:
2282         * platform/ContextMenu.h:
2283         (ContextMenu):
2284         * platform/ContextMenuItem.h:
2285         * platform/qt/ContextMenuItemQt.cpp:
2286         (WebCore::ContextMenuItem::platformContextMenuItem):
2287         * platform/qt/ContextMenuQt.cpp:
2288         (WebCore::ContextMenu::ContextMenu):
2289         (WebCore::ContextMenu::getContextMenuItems):
2290         (WebCore::ContextMenu::createPlatformContextMenuFromItems):
2291         (WebCore::ContextMenu::platformContextMenu):
2292
2293 2013-04-03  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2294
2295         [Qt] Monospace font does not render in proper sizes
2296         https://bugs.webkit.org/show_bug.cgi?id=93263
2297
2298         Reviewed by Jocelyn Turcotte.
2299
2300         Remove this patch's artificial dependency on Qt 5.1.
2301
2302         * platform/graphics/qt/FontPlatformDataQt.cpp:
2303         (WebCore::FontPlatformData::FontPlatformData):
2304
2305 2013-04-03  Takeshi Yoshino  <tyoshino@chromium.org>
2306
2307         Refine LOG messages in WebSocket related components
2308         https://bugs.webkit.org/show_bug.cgi?id=113852
2309
2310         Reviewed by Kent Tamura.
2311
2312         Refine LOG messages by
2313         - Make them contain method names to ease identifying where the event occurred.
2314         - For consistency, make all messages print the pointer of the origin instance.
2315         - Quote UTF8 data in LOG messages.
2316         - For overloaded methods, add the type to clarify which one is run
2317
2318         * Modules/websockets/WebSocket.cpp:
2319         (WebCore::WebSocket::connect):
2320         (WebCore::WebSocket::send):
2321         (WebCore::WebSocket::close):
2322         (WebCore::WebSocket::contextDestroyed):
2323         (WebCore::WebSocket::didConnect):
2324         (WebCore::WebSocket::didReceiveMessage):
2325         (WebCore::WebSocket::didReceiveBinaryData):
2326         (WebCore::WebSocket::didReceiveMessageError):
2327         (WebCore::WebSocket::didUpdateBufferedAmount):
2328         (WebCore::WebSocket::didStartClosingHandshake):
2329         (WebCore::WebSocket::didClose):
2330         * Modules/websockets/WebSocketChannel.cpp:
2331         (WebCore::WebSocketChannel::connect):
2332         (WebCore::WebSocketChannel::subprotocol):
2333         (WebCore::WebSocketChannel::extensions):
2334         (WebCore::WebSocketChannel::send):
2335         (WebCore::WebSocketChannel::bufferedAmount):
2336         (WebCore::WebSocketChannel::close):
2337         (WebCore::WebSocketChannel::fail):
2338         (WebCore::WebSocketChannel::disconnect):
2339         (WebCore::WebSocketChannel::willOpenSocketStream):
2340         (WebCore::WebSocketChannel::didOpenSocketStream):
2341         (WebCore::WebSocketChannel::didCloseSocketStream):
2342         (WebCore::WebSocketChannel::didReceiveSocketStreamData):
2343         (WebCore::WebSocketChannel::didFailSocketStream):
2344         (WebCore::WebSocketChannel::didStartLoading):
2345         (WebCore::WebSocketChannel::didReceiveData):
2346         (WebCore::WebSocketChannel::didFinishLoading):
2347         (WebCore::WebSocketChannel::didFail):
2348         (WebCore::WebSocketChannel::appendToBuffer):
2349         (WebCore::WebSocketChannel::processBuffer):
2350         (WebCore::WebSocketChannel::startClosingHandshake):
2351         (WebCore::WebSocketChannel::closingTimerFired):
2352         * Modules/websockets/WebSocketDeflater.cpp:
2353         (WebCore::WebSocketDeflater::~WebSocketDeflater):
2354         (WebCore::WebSocketInflater::~WebSocketInflater):
2355         * Modules/websockets/WebSocketHandshake.cpp:
2356         (WebCore::WebSocketHandshake::readServerHandshake):
2357         * platform/network/chromium/SocketStreamHandle.cpp:
2358         (WebCore::SocketStreamHandleInternal::connect):
2359         (WebCore::SocketStreamHandleInternal::send):
2360         (WebCore::SocketStreamHandleInternal::close):
2361         (WebCore::SocketStreamHandleInternal::didOpenStream):
2362         (WebCore::SocketStreamHandleInternal::didSendData):
2363         (WebCore::SocketStreamHandleInternal::didReceiveData):
2364         (WebCore::SocketStreamHandleInternal::didClose):
2365         (WebCore::SocketStreamHandleInternal::didFail):
2366
2367 2013-04-03  Tor Arne Vestbø  <tor.arne.vestbo@digia.com>
2368
2369         [Qt] Update QMAKE_MAC_SDK check for Qt 5.1
2370
2371         Relies on QMAKE_MAC_SDK_VERSION set in features.prf
2372
2373         Reviewed by Simon Hausmann.
2374
2375         * WebCore.pri:
2376
2377 2013-04-03  Kristof Provost  <kristof@codepro.be>
2378
2379         [Qt] assignToHTMLImageElement no longer exists in Qt5
2380         https://bugs.webkit.org/show_bug.cgi?id=113639
2381
2382         Reviewed by Simon Hausmann.
2383
2384         No new tests: covered by ./Source/WebKit/qt/tests/hybridPixmap/test.html
2385
2386         * bridge/qt/qt_pixmapruntime.cpp:
2387         (JSC::Bindings::QtPixmapRuntime::getClassRef):
2388
2389 2013-04-03  Antoine Quint  <graouts@apple.com>
2390
2391         Web Inspector: crash in WebCore::InspectorLayerTreeAgent::buildObjectForLayer if a layer is created for an anonymous RenderObject (:first-letter)
2392         https://bugs.webkit.org/show_bug.cgi?id=113768
2393
2394         The InspectorLayerTreeAgent now knows how to deal with anonymous RenderObjects
2395         for the :first-letter and :first-line pseudo-elements.
2396
2397         Reviewed by Timothy Hatcher.
2398
2399         Test: inspector-protocol/layers/layers-anonymous.html
2400
2401         * inspector/Inspector.json:
2402         Change the Layer type in the LayerTree domain to have more accurate terminology
2403         (pseudo-element vs. pseudo-class) and a new optional isAnonymous flag for layers
2404         associated to anonymous RenderObjects.
2405
2406         * inspector/InspectorLayerTreeAgent.cpp:
2407         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
2408         Check for anonymous RenderObjects and set the parent renderer's node as the node
2409         for this layer since anonymous renderers have the Document as their node and this
2410         would not be satisfactory to show in a front-end. We also check for anonymous
2411         RenderObjects for the :first-letter and :first-line pseudo-elements and set them
2412         in the pseudoElement property of the Layer object created such that a front-end
2413         could correctly identify what type of pseudo-element for the associated node
2414         yielded this layer.
2415
2416         (WebCore::InspectorLayerTreeAgent::idForNode):
2417         Here we fix the actual crash by first checking if the node provided is null and
2418         returning 0 if there's no such node. This ensures that any scenario where there
2419         is no node associated with the RenderObject simply informs of the front-end that
2420         no such node exists and we do not crash.
2421
2422 2013-04-03  Alexander Pavlov  <apavlov@chromium.org>
2423
2424         Web Inspector: [REGRESSION(r147117)][Elements] Copy/paste keyboard shortcuts broken in "Edit as HTML"
2425         https://bugs.webkit.org/show_bug.cgi?id=113798
2426
2427         Reviewed by Yury Semikhatsky.
2428
2429         Stop propagation of "copy" event from the multiline editor's
2430         CodeMirror host element so that it is not handled by
2431         WebInspector.documentCopy().
2432
2433         * inspector/front-end/UIUtils.js:
2434         (.consumeCopy):
2435         (.cleanUpAfterEditing):
2436         * inspector/front-end/inspector.js:
2437         (WebInspector.addMainEventListeners):
2438
2439 2013-04-03  Takashi Sakamoto  <tasak@google.com>
2440
2441         With borders of differing alpha, the corners become squared off
2442         https://bugs.webkit.org/show_bug.cgi?id=113744
2443
2444         Reviewed by Simon Fraser.
2445
2446         paintTranslucentBorderSides should pick up borders with common color
2447         in order: top, bottom, left and right (not top, right, bottom and
2448         left), because willBeOverdrawn depends on the assumption, borders are
2449         drawn in order: top, bottom, left and right.
2450
2451         Test: fast/borders/border-left-right-same-bottom-different-color.html
2452
2453         * rendering/RenderBoxModelObject.cpp:
2454         (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
2455
2456 2013-04-03  Mihnea Ovidenie  <mihnea@adobe.com>
2457
2458         [New Multicolumn]Remove assert in RenderMultiColumnFlowThread::createAnonymous
2459         https://bugs.webkit.org/show_bug.cgi?id=113855
2460
2461         Reviewed by Antti Koivisto.
2462
2463         Remove CSSRegions specific assert from new multicolumn implementation.
2464         No change in functionality, no new tests.
2465
2466         * rendering/RenderMultiColumnFlowThread.cpp:
2467         (WebCore::RenderMultiColumnFlowThread::createAnonymous):
2468
2469 2013-04-03  Mike West  <mkwst@chromium.org>
2470
2471         X-Frame-Options: Blocked frames should not inherit their parent's SecurityOrigin.
2472         https://bugs.webkit.org/show_bug.cgi?id=112903
2473
2474         Reviewed by Adam Barth.
2475
2476         This change brings WebKit in line with IE and Gecko's behavior, both of
2477         which treat the blocked frame as being cross-origin for the purposes of
2478         access checks ('[frame].contentWindow.location.href' is inaccessible,
2479         for example).
2480
2481         * dom/Document.cpp:
2482         (WebCore::Document::processHttpEquiv):
2483             Rather than redirecting to 'about:blank', redirect to a URL which
2484             does not inherit the SecurityOrigin of the parent.
2485         * loader/DocumentLoader.cpp:
2486         (WebCore::DocumentLoader::responseReceived):
2487             Before calling cancelMainResourceLoad, ensure that the frame's
2488             document is sandboxed into a unique origin so that it doesn't inherit
2489             the parent's SecurityOrigin.
2490
2491 2013-04-03  Mikhail Naganov  <mnaganov@chromium.org>
2492
2493         [Chromium] Implement target-densityDpi viewport property emulation
2494         https://bugs.webkit.org/show_bug.cgi?id=110835
2495
2496         The value is only used in the Chromium port, when the corresponding
2497         setting is enabled.
2498
2499         This is needed for supporting existing WebView-based applications
2500         that rely on this property.
2501
2502         Reviewed by Adam Barth.
2503
2504         * dom/ViewportArguments.cpp:
2505         (WebCore::findTargetDensityDPIValue):
2506         (WebCore):
2507         (WebCore::setViewportFeature):
2508         * dom/ViewportArguments.h:
2509         (WebCore::ViewportArguments::ViewportArguments):
2510         (ViewportArguments):
2511         (WebCore::ViewportArguments::operator==):
2512
2513 2013-04-03  Mike West  <mkwst@chromium.org>
2514
2515         Extract URL that doesn't inherit a parent's SecurityOrigin out into a constant.
2516         https://bugs.webkit.org/show_bug.cgi?id=113780
2517
2518         Reviewed by Jochen Eisinger.
2519
2520         We're scheduling navigations to 'data:text/html,' in XSSAuditor in
2521         order to end up on a page that doesn't inherit its parent's
2522         SecurityOrigin. We'll be reusing this mechainsm to solve
2523         http://wkbug.com/112903
2524
2525         This patch makes us more explicit about what we're doing and why.
2526         It doesn't change any behavior: XSSAuditor tests should still pass.
2527
2528         * html/parser/XSSAuditorDelegate.cpp:
2529         (WebCore::XSSAuditorDelegate::didBlockScript):
2530             Use SecurityOrigin::urlWithUniqueSecurityOrigin rather than a
2531             literal string to make our intentions clear.
2532         * page/SecurityOrigin.cpp:
2533         (WebCore::SecurityOrigin::urlWithUniqueSecurityOrigin):
2534         * page/SecurityOrigin.h:
2535             Add the new static method.
2536
2537 2013-04-02  Chris Fleizach  <cfleizach@apple.com>
2538
2539         clean up static casts in WebAccessibilityObjectWrapperMac.mm to methods like toAccessibilityList()
2540         https://bugs.webkit.org/show_bug.cgi?id=113828
2541
2542         Reviewed by Tim Horton.
2543
2544         static_cast changed to toAccessibilityList().
2545
2546         * accessibility/AccessibilityList.h:
2547         (WebCore::toAccessibilityList):
2548         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2549         (-[WebAccessibilityObjectWrapper subrole]):
2550         (-[WebAccessibilityObjectWrapper roleDescription]):
2551
2552 2013-04-02  Sheriff Bot  <webkit.review.bot@gmail.com>
2553
2554         Unreviewed, rolling out r147370.
2555         http://trac.webkit.org/changeset/147370
2556         https://bugs.webkit.org/show_bug.cgi?id=113850
2557
2558         This patch is causing crashes in video tests on all Mac bots.
2559         (Requested by jernoble_ on #webkit).
2560
2561         * html/HTMLMediaElement.cpp:
2562         (WebCore::HTMLMediaElement::~HTMLMediaElement):
2563
2564 2013-04-02  James Craig  <james@cookiecrook.com>
2565
2566         AXRoleDescripton for DL is "list"; should be "description list"
2567         https://bugs.webkit.org/show_bug.cgi?id=111665
2568
2569         Reviewed by Chris Fleizach.
2570
2571         Defining the role and description strings, and accessors for DL.
2572         This previously relied on getting the role and description from the platform API.
2573
2574         Updated existing test coverage.
2575
2576         * English.lproj/Localizable.strings:
2577         * accessibility/AccessibilityObject.h:
2578         * accessibility/AccessibilityRenderObject.cpp:
2579         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
2580         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2581         (createAccessibilityRoleMap):
2582         (-[WebAccessibilityObjectWrapper subrole]):
2583         (-[WebAccessibilityObjectWrapper roleDescription]):
2584         * platform/LocalizedStrings.cpp:
2585         (WebCore::AXDescriptionListText):
2586         (WebCore):
2587         * platform/LocalizedStrings.h:
2588         (WebCore):
2589         * platform/blackberry/LocalizedStringsBlackBerry.cpp:
2590         (WebCore::AXDescriptionListText):
2591         (WebCore):
2592         * platform/chromium/LocalizedStringsChromium.cpp:
2593         (WebCore::AXDescriptionListText):
2594         (WebCore):
2595         * platform/efl/LocalizedStringsEfl.cpp:
2596         (WebCore::AXDescriptionListText):
2597         (WebCore):
2598         * platform/gtk/LocalizedStringsGtk.cpp:
2599         (WebCore::AXDescriptionListText):
2600         (WebCore):
2601         * platform/qt/LocalizedStringsQt.cpp:
2602         (WebCore::AXDescriptionListText):
2603         (WebCore):
2604
2605 2013-04-02  Eugene Klyuchnikov  <eustas@chromium.org>
2606
2607         Web Inspector: [Network] Split business logic and presentation for initiator column.
2608         https://bugs.webkit.org/show_bug.cgi?id=113486
2609
2610         Reviewed by Pavel Feldman.
2611
2612         Currently business logic and presentation are mixed.
2613         This prevents making cell renderer static and applying
2614         viewport rendering, because initiator sorting function
2615         depends on data written when cell is rendered.
2616
2617         * inspector/front-end/NetworkPanel.js:
2618         (WebInspector.NetworkDataGridNode.prototype._refreshInitiatorCell):
2619         Removed business logic. Use "initiatorInfo".
2620         (WebInspector.NetworkDataGridNode.InitiatorComparator):
2621         Use "initiatorInfo".
2622         * inspector/front-end/NetworkRequest.js:
2623         (WebInspector.NetworkRequest.prototype.initiatorInfo):
2624         Extracted business logic from "refreshInitiatorCell".
2625
2626 2013-04-02  Ryosuke Niwa  <rniwa@webkit.org>
2627
2628         needsLeopardMailQuirks should be removed
2629         https://bugs.webkit.org/show_bug.cgi?id=113749
2630
2631         Reviewed by Benjamin Poulain.
2632
2633         Removed needsLeopardMailQuirks from settings.in after r147447.
2634
2635         * page/Settings.in:
2636
2637 2013-04-02  Jaehun Lim  <ljaehun.lim@samsung.com>
2638
2639         [css3-text] Rendering -webkit-each-line value for text-indent from css3-text
2640         https://bugs.webkit.org/show_bug.cgi?id=113259
2641
2642         Reviewed by Levi Weintraub.
2643
2644         CSS3 TEXT introduces new value, "each-line" for text-indent.
2645         Indentation affects the first line of the block container as well as each line
2646         after a forced line break, but does not affect lines after a soft wrap break.
2647
2648         This patch is the rendering part to support each-line value for text-indent.
2649         It's prefixed and guarded by CSS3_TEXT flag.
2650
2651         Test: fast/css3-text/css3-text-indent/text-indent-each-line.html
2652
2653         * rendering/RenderBlock.h:
2654         (WebCore::RenderBlock::availableLogicalWidthForLine):
2655         (WebCore::RenderBlock::logicalRightOffsetForLine):
2656         (WebCore::RenderBlock::logicalLeftOffsetForLine):
2657         (WebCore::RenderBlock::startOffsetForLine):
2658         (WebCore::RenderBlock::endOffsetForLine):
2659         (WebCore::RenderBlock::pixelSnappedLogicalLeftOffsetForLine):
2660         (WebCore::RenderBlock::pixelSnappedLogicalRightOffsetForLine):
2661             Rename a parameter from firstLine to shouldIndentText.
2662
2663         * rendering/RenderBlockLineLayout.cpp:
2664         (WebCore::LineWidth::LineWidth):
2665         (WebCore::LineWidth::shouldIndentText): Return boolean according to m_shouldIndentText.
2666         (WebCore::LineWidth::updateAvailableWidth):
2667         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
2668         (WebCore::LineWidth::fitBelowFloats):
2669             Add enum IndentTextOrNot and m_shouldIndentText.
2670             Use m_shouldIndentText instead of m_isFirstLine.
2671
2672         (WebCore::requiresIndent): Decide whether text indentation is required.
2673         (WebCore::updateLogicalInlinePositions):
2674         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine):
2675         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
2676
2677 2013-04-02  Glenn Adams  <glenn@skynav.com>
2678
2679         Generalize prior line break context state and names.
2680         https://bugs.webkit.org/show_bug.cgi?id=113823
2681
2682         Reviewed by Darin Adler.
2683
2684         No new tests required due to no behavioral change.
2685
2686         * platform/text/TextBreakIterator.h:
2687         (WebCore::LazyLineBreakIterator::LazyLineBreakIterator):
2688         (WebCore::LazyLineBreakIterator::lastCharacter):
2689         (WebCore::LazyLineBreakIterator::secondToLastCharacter):
2690         (WebCore::LazyLineBreakIterator::setPriorContext):
2691         (WebCore::LazyLineBreakIterator::updatePriorContext):
2692         (WebCore::LazyLineBreakIterator::resetPriorContext):
2693         (WebCore::LazyLineBreakIterator::resetStringAndReleaseIterator):
2694         Store previous characters as prior context buffer used directly
2695         by line break iterator implementation. Rename members to reflect
2696         somewhat more general usage. Also fix bad indentations.
2697         * rendering/RenderBlockLineLayout.cpp:
2698         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
2699         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
2700         Use renamed line break iterator methods.
2701
2702 2013-04-02  Emil A Eklund  <eae@chromium.org>
2703
2704         Padding applied twice for empty generated RenderInlines
2705         https://bugs.webkit.org/show_bug.cgi?id=113800
2706
2707         Reviewed by Levi Weintraub.
2708         
2709         The padding for empty generated content render objects is
2710         incorrectly applied twice. Regression from r140693.
2711
2712         Test: fast/css-generated-content/margin-empty-content.html
2713
2714         * rendering/RenderBlockLineLayout.cpp:
2715         (WebCore::inlineLogicalWidth):
2716
2717 2013-04-02  Levi Weintraub  <leviw@chromium.org>
2718
2719         InlineIterator needs to be updated when RenderCombineText shrinks at a line break
2720         https://bugs.webkit.org/show_bug.cgi?id=113733
2721
2722         Reviewed by Emil A Eklund.
2723
2724         Update stale InlineIterators that point beyond the end of a RenderCombineText that's
2725         shrunk when RenderCombineText::combineText() is called.
2726
2727         Test: fast/text/international/combine-at-line-break-crash.html
2728
2729         * rendering/BidiRun.h:
2730         (WebCore::BidiRun::BidiRun): Adding an assertion that runs are created within
2731         the bounds of their associated RenderText.
2732         * rendering/RenderBlockLineLayout.cpp:
2733         (WebCore::iteratorIsBeyondEndOfRenderCombineText): Added.
2734         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak): Update stale iterators.
2735
2736 2013-04-02  Max Vujovic  <mvujovic@adobe.com>
2737
2738         [CSS Filters] Filter outsets clipped on composited layers when filter is applied after first layout
2739         https://bugs.webkit.org/show_bug.cgi?id=109098
2740
2741         Reviewed by Dean Jackson.
2742
2743         This patch addresses the following issues:
2744         (1) Compositors who can compute their own filter outsets don't need WebKit to inflate the
2745             composited layer bounds. Eventually, all platforms' compositors should be able to
2746             compute their own filter outsets.
2747         (2) When filter outsets change, we need to update composited layer bounds if the filters are
2748             painted in software.
2749         (3) When filter outsets change, we need to recompute the overlap map to promote the correct
2750             layers to composited layers on all platforms.
2751
2752         Tests: css3/filters/composited-layer-bounds-after-sw-blur-animation.html
2753                css3/filters/composited-layer-bounds-with-composited-blur.html
2754                css3/filters/composited-layer-child-bounds-after-composited-to-sw-shadow-change.html
2755                css3/filters/composited-layer-promotion-after-outset-overlap-change-using-composited-shadow.html
2756                css3/filters/composited-layer-promotion-after-outset-overlap-change-using-sw-shadow.html
2757
2758         * platform/graphics/IntRectExtent.h:
2759         (WebCore::IntRectExtent::isZero):
2760         (IntRectExtent):
2761
2762             Make isZero public on IntRectExtent.
2763
2764         * rendering/RenderLayer.cpp:
2765         (WebCore::hasOrHadFilters):
2766
2767             Helper function used to exit early from filters related code.
2768
2769         (WebCore::RenderLayer::updateFilters):
2770
2771             Move filter updating code from RenderLayer::styleChanged into this new method.
2772
2773             This method calls RenderLayerBacking::updateFilters instead of
2774             RenderLayerBacking::updateGraphicsLayerGeometry. RenderLayerBacking::updateFilters lets
2775             us know whether there was a filter paint mode change (i.e. the filters were painted in
2776             software and are now painted in the compositor, or vice-versa). We need to know this
2777             earlier, in RenderLayer::styleChanged, because we may need to rebuild the compositing
2778             layers due to a filter paint mode change.
2779
2780         (WebCore::RenderLayer::styleChanged):
2781
2782             Add a condition for filters for setCompositingLayersNeedRebuild. If the filter outsets
2783             on a layer changed, we need to rebuild the compositing layers because there could be new
2784             overlap. Likewise, if there are or were filter outsets and the filter paint mode changed
2785             the layer bounds (and child positions) may have changed. In either case, we don't
2786             rebuild the compositing layers if there is an accelerated filter animation running.
2787
2788             Remove old code to detect a filter paint mode change from the end of
2789             RenderLayer::styleChanged because it could never be executed. The old code counted on
2790             RenderLayerBacking::canCompositeFilters to change on its own, but it doesn't change
2791             unless updateFilters gets called. Thus, we could never enter the if statement that
2792             calls setBackingNeedsRepaint.
2793
2794         * rendering/RenderLayerBacking.cpp:
2795         (WebCore::RenderLayerBacking::updateFilters):
2796
2797             Now return true if there was a filter paint mode change, so RenderLayer::styleChanged
2798             can decide if it should rebuild the compositing layers.
2799
2800             Call updateOrRemoveFilterEffectRenderer and setContentsNeedDisplay if there was a
2801             render mode change. We need to either destroy or create the software renderer and we
2802             need to repaint the layer contents if there was a render mode change.
2803
2804         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2805
2806             Don't call updateFilters here. Call it earlier in RenderLayer::styleChanged, for reasons
2807             explained above.
2808
2809         * rendering/RenderLayerBacking.h:
2810         (RenderLayerBacking):
2811
2812             Make updateFilters public so RenderLayer::styleChanged can call it.
2813
2814         * rendering/RenderLayerCompositor.cpp:
2815         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
2816
2817             If the platform's compositor computes filter outsets for its layers internally, do not
2818             inflate WebKit's composited bounds for filter outsets. This results in smaller layers
2819             on Safari. Note that we still need to include filter outsets in layer bounds for other
2820             situations like overlap testing in WebKit and when we're painting filters in software.
2821
2822 2013-04-02  Martin Robinson  <mrobinson@igalia.com>
2823
2824         [GTK] Make libsecret optional
2825         https://bugs.webkit.org/show_bug.cgi?id=113821
2826
2827         Reviewed by Gustavo Noronha Silva.
2828
2829         Don't try to use libsecret if credential storage is disabled.
2830
2831         * platform/gtk/GRefPtrGtk.cpp: Protect libsecret sections.
2832         * platform/gtk/GRefPtrGtk.h: Ditto.
2833         * platform/network/gtk/CredentialBackingStore.cpp: Ditto.
2834
2835 2013-04-02  Bem Jones-Bey  <bjonesbe@adobe.com>
2836
2837         [CSS Exclusions] refactor shape-outside code to use isFloatingWithShapeOutside() helper method
2838         https://bugs.webkit.org/show_bug.cgi?id=113799
2839
2840         Reviewed by Dirk Schulze.
2841
2842         When reviewing my patch for bug 110349, Julien mentioned that the
2843         common test for floating with shape outside should be factored out.
2844         This patch does that.
2845
2846         No new functionality, so no new tests.
2847
2848         * rendering/ExclusionShapeOutsideInfo.cpp:
2849         (WebCore::ExclusionShapeOutsideInfo::isEnabledFor): Use helper method.
2850         * rendering/RenderBox.h:
2851         (WebCore::RenderBox::exclusionShapeOutsideInfo): Ditto.
2852         * rendering/RenderLayer.cpp:
2853         (WebCore::RenderLayer::shouldBeNormalFlowOnly): Ditto.
2854         * rendering/RenderObject.h:
2855         (WebCore::RenderObject::hasPaintOffset):  Ditto.
2856         (WebCore::RenderObject::isFloatingWithShapeOutside): Add method to
2857             encapsulate the common test.
2858
2859 2013-04-02  Jer Noble  <jer.noble@apple.com>
2860
2861         Add platform AudioSession and iOS platform-specific code.
2862         https://bugs.webkit.org/show_bug.cgi?id=113813
2863         <rdar://problem/11701792>
2864
2865         Reviewed by Eric Carlson.
2866
2867         Replace the deprecated AudioToolbox AudioSession APIs with the new AVAudioSession API.
2868         To protect against exposing platform specific intrinsics to cross-platform code, add a
2869         platform generic class AudioSession, with port-specific implementations. A default
2870         implementation is provided.
2871
2872         Add a new listener interface to receive interruption notifications:
2873         * platform/audio/AudioSessionListener.h: Added.
2874         (WebCore::AudioSessionListener::AudioSessionListener):
2875         (WebCore::AudioSessionListener::~AudioSessionListener):
2876
2877         Add a platform generic AudioSession class:
2878         * platform/audio/AudioSession.cpp: Added.
2879         (AudioSession::sharedSession): AudioSession is a singleton object, and this is its accessor.
2880         (AudioSession::addListener): Add the parameter to the listeners set.
2881         (AudioSession::removeListener): Remove the parameter from the listers set.
2882         (AudioSession::beganAudioInterruption): Iterate over the parameters.
2883         (AudioSession::endedAudioInterruption): Ditto.
2884         (AudioSession::AudioSession): Empty stub.
2885         (AudioSession::~AudioSession): Ditto.
2886         (AudioSession::setCategory): Ditto.
2887         (AudioSession::category): Ditto.
2888         (AudioSession::sampleRate): Ditto.
2889         (AudioSession::numberOfOutputChannels): Ditto.
2890         (AudioSession::setActive): Ditto.
2891         (AudioSession::preferredBufferDuration): Ditto.
2892         (AudioSession::setPreferredBufferDuration): Ditto.
2893         * platform/audio/AudioSession.h: Added.
2894
2895         Add IOS-specific AudioSession implementation:
2896         * platform/audio/ios/AudioSessionIOS.mm: Added.
2897         (-[WebAudioSessionHelper initWithCallback:WebCore::]): Register for interruption notifications.
2898         (-[WebAudioSessionHelper dealloc]): Unregister for interruption notifications.
2899         (-[WebAudioSessionHelper interruption:]): Pass to AudioSession.
2900         (WebCore::AudioSessionPrivate::AudioSessionPrivate): Private storage for AudioSessionIOS.
2901         (WebCore::AudioSession::AudioSession): Create AudioSessionPrivate and WebAudioSessionHelper.
2902         (WebCore::AudioSession::~AudioSession): Simple destructor.
2903         (WebCore::AudioSession::setCategory): Check the current categoryOverride, and refuse to overwrite
2904             "MediaPlayback" with "AmbientSound".
2905         (WebCore::AudioSession::setCategoryOverride): Simple setter.
2906         (WebCore::AudioSession::categoryOverride): Simple getter.
2907         (WebCore::AudioSession::category): Pass to AVAudioSession.
2908         (WebCore::AudioSession::sampleRate): Ditto.
2909         (WebCore::AudioSession::numberOfOutputChannels): Ditto.
2910         (WebCore::AudioSession::setActive): Ditto.
2911         (WebCore::AudioSession::preferredBufferDuration): Ditto.
2912         (WebCore::AudioSession::setPreferredBufferDuration): Ditto.
2913
2914         Use the new AudioSession class in place of explicit AudioToolbox or AVAudioSession calls:
2915         * platform/audio/ios/AudioDestinationIOS.cpp:
2916         (WebCore::AudioDestination::hardwareSampleRate): Pass to AudioSession.
2917         (WebCore::AudioDestination::maxChannelCount): Ditto.
2918         (WebCore::AudioDestinationIOS::AudioDestinationIOS): Register for listeners and activate.
2919         (WebCore::AudioDestinationIOS::~AudioDestinationIOS): Unregister and deactivate.
2920         (WebCore::AudioDestinationIOS::configure): Use AudioSession to set the buffer length.
2921         * platform/audio/ios/AudioDestinationIOS.h:
2922
2923         Add the new files to the project:
2924         * WebCore.xcodeproj/project.pbxproj:
2925
2926 2013-04-02  Jer Noble  <jer.noble@apple.com>
2927
2928         Upstream AudioDestinationIOS.
2929         https://bugs.webkit.org/show_bug.cgi?id=113806
2930
2931         Reviewed by Eric Carlson.
2932
2933         Upstream AudioDestinationIOS from the iOS repository.
2934
2935         * WebCore.xcodeproj/project.pbxproj:
2936         * platform/audio/ios/AudioDestinationIOS.cpp: Added.
2937         (WebCore::audioDestinations):
2938         (WebCore::AudioDestination::create):
2939         (WebCore::AudioDestination::hardwareSampleRate):
2940         (WebCore::AudioDestination::maxChannelCount):
2941         (WebCore::AudioDestinationIOS::AudioDestinationIOS):
2942         (WebCore::AudioDestinationIOS::~AudioDestinationIOS):
2943         (WebCore::AudioDestinationIOS::configure):
2944         (WebCore::AudioDestinationIOS::audioDestinationInterruptionListener):
2945         (WebCore::AudioDestinationIOS::initializeAudioSession):
2946         (WebCore::AudioDestinationIOS::start):
2947         (WebCore::AudioDestinationIOS::stop):
2948         (WebCore::AudioDestinationIOS::beganAudioInterruption):
2949         (WebCore::AudioDestinationIOS::endedAudioInterruption):
2950         (WebCore::AudioDestinationIOS::render):
2951         (WebCore::AudioDestinationIOS::inputProc):
2952         (WebCore::AudioDestinationIOS::frameSizeChangedProc):
2953         * platform/audio/ios/AudioDestinationIOS.h: Added.
2954         (AudioDestinationIOS):
2955         (WebCore::AudioDestinationIOS::isPlaying):
2956         (WebCore::AudioDestinationIOS::sampleRate):
2957
2958 2013-04-02  Christophe Dumez  <ch.dumez@sisa.samsung.com>
2959
2960         fast/dom/HTMLImageElement/image-alt-text.html and fast/dom/HTMLInputElement/input-image-alt-text.html are failing
2961         https://bugs.webkit.org/show_bug.cgi?id=94198
2962
2963         Reviewed by Darin Adler.
2964
2965         Fix alt text not being displayed for img elements or input of type
2966         "image" due to insufficient size. imageSizeForError() was adding
2967         padding for the alt text but setImageSizeForAltText() was not. The
2968         issue was occurring in paintReplaced() because the contentWidth() /
2969         contentHeight() would be exactly the same size as the alt text.
2970         However, paintReplaced() first draws an outline rect where the
2971         image should be and then reduces the usable width / height for the
2972         alt text by 2 so that the text does not get printed over the rect
2973         borders. However, after decreasing the usable width / height, there
2974         is no longer enough space to draw the text.
2975
2976         No new tests, already covered by existing tests.
2977
2978         * rendering/RenderImage.cpp:
2979         (WebCore::RenderImage::setImageSizeForAltText): Add padding to the text size
2980         so that the alt text can still be drawn, despite the outline rect
2981         borders. Such padding was already used in imageSizeForError(). Also use
2982         ceilf() for the value returned by Font::width() instead of truncating it.
2983         This is needed because we need to fit the whole text in the image and this
2984         may not be the case if we truncate.
2985         (WebCore::RenderImage::paintReplaced):
2986
2987 2013-04-02  Raymond Toy  <rtoy@google.com>
2988
2989         Add support for using ARM FFT in WebAudio
2990         https://bugs.webkit.org/show_bug.cgi?id=109755
2991
2992         Reviewed by Chris Rogers.
2993
2994         No new tests.
2995
2996         * WebCore.gyp/WebCore.gyp: Add dependency on openmax_dl when use_openmax_dl_fft is enabled.
2997         * WebCore.gypi: Add source FFTFrameOpenMAXDLAndroid.cpp
2998         * platform/audio/AudioArray.h:
2999         (WebCore::AudioArray::allocate): Need 32-byte aligntment with the
3000         OpenMAX DL FFT.
3001         * platform/audio/FFTFrame.h:
3002         (FFTFrame): Support OpenMAX DL FFT
3003         * platform/audio/FFTFrameStub.cpp: Support OpenMAX DL FFT
3004         * platform/audio/chromium/FFTFrameOpenMAXDLAndroid.cpp: Added.  Implements the
3005         necessary interface using the OpenMAX DL FFT routines.
3006         (WebCore):
3007         (WebCore::FFTFrame::FFTFrame):
3008         (WebCore::FFTFrame::initialize):
3009         (WebCore::FFTFrame::cleanup):
3010         (WebCore::FFTFrame::~FFTFrame):
3011         (WebCore::FFTFrame::multiply):
3012         (WebCore::FFTFrame::doFFT):
3013         (WebCore::FFTFrame::doInverseFFT):
3014         (WebCore::FFTFrame::realData):
3015         (WebCore::FFTFrame::imagData):
3016         (WebCore::FFTFrame::contextForSize):
3017
3018 2013-04-02  Sudarsana Nagineni  <sudarsana.nagineni@intel.com>
3019
3020         [GStreamer] Memory leaks in MediaPlayerPrivateGStreamer
3021         https://bugs.webkit.org/show_bug.cgi?id=113762
3022
3023         Reviewed by Philippe Normand.
3024
3025         Don't leak strings returned by gst_element_get_name() and
3026         gst_missing_plugin_message_get_installer_detail().
3027
3028         No new tests. No change in behavior.
3029
3030         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3031         (WebCore::MediaPlayerPrivateGStreamer::setAudioStreamProperties):
3032         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
3033
3034 2013-04-02  Min Qin  <qinmin@chromium.org>
3035
3036         Fix css style for CC button on android
3037         https://bugs.webkit.org/show_bug.cgi?id=113815
3038
3039         Reviewed by Adam Barth.
3040
3041         The default CC button size is 16px as defined in mediaControls.css. Android should use 35px.
3042         This change fixed that problem.
3043         Also fixed a problem that r142947 does not change the display of fullscreen button to -webkit-flex
3044         Android does not run media layout tests currently. Will fix the test expectations when layout tests are run in content shell.
3045
3046         * css/mediaControlsChromiumAndroid.css:
3047         (video::-webkit-media-controls-fullscreen-button):
3048         (audio::-webkit-media-controls-toggle-closed-captions-button, video::-webkit-media-controls-toggle-closed-captions-button):
3049
3050 2013-04-02  Alexey Proskuryakov  <ap@apple.com>
3051
3052         [Mac] Remove WKCreateNSURLConnectionDelegateProxy
3053         https://bugs.webkit.org/show_bug.cgi?id=113810
3054
3055         Reviewed by Anders Carlsson.
3056
3057         This WKSI function is not used any more.
3058
3059         * WebCore.exp.in:
3060         * platform/mac/WebCoreSystemInterface.h:
3061         * platform/mac/WebCoreSystemInterface.mm:
3062
3063 2013-04-02  Sheriff Bot  <webkit.review.bot@gmail.com>
3064
3065         Unreviewed, rolling out r147464.
3066         http://trac.webkit.org/changeset/147464
3067         https://bugs.webkit.org/show_bug.cgi?id=113812
3068
3069         JSSQLResultSet.cpp:131:24: error: implicit conversion loses
3070         integer precision: 'int64_t' (aka 'long long') to 'int'
3071         [-Werror,-Wshorten-64-to-32] (Requested by xenon on #webkit).
3072
3073         * bindings/scripts/CodeGeneratorJS.pm:
3074         (GenerateImplementation):
3075         * bindings/scripts/test/JS/JSTestObj.cpp:
3076         (WebCore::jsTestObjAttrWithGetterException):
3077         (WebCore::jsTestObjStringAttrWithGetterException):
3078         (WebCore::jsTestObjWithScriptStateAttributeRaises):
3079         (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
3080         (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
3081         (WebCore::jsTestObjNullableDoubleAttribute):
3082         (WebCore::jsTestObjNullableLongAttribute):
3083         (WebCore::jsTestObjNullableBooleanAttribute):
3084         (WebCore::jsTestObjNullableStringAttribute):
3085         (WebCore::jsTestObjNullableLongSettableAttribute):
3086         (WebCore::jsTestObjNullableStringValue):
3087         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
3088         (WebCore::jsTestTypedefsAttrWithGetterException):
3089         (WebCore::jsTestTypedefsStringAttrWithGetterException):
3090
3091 2013-04-02  Andrey Lushnikov  <lushnikov@chromium.org>
3092
3093         Web Inspector: Make Source Frame & status bar a layout boundary
3094         https://bugs.webkit.org/show_bug.cgi?id=112353
3095
3096         Reviewed by Pavel Feldman.
3097
3098         No new tests: no change in behaviour.
3099
3100         - Add View.markAsLayoutBoundary method to mark a view as a layout
3101         boundary. This will force this view to autoupdate its height to actual
3102         pixel value.
3103         - Mark both CodeMirrorTextEditor and DefaultTextEditor as a layout
3104         boundary.
3105         - Mark main-status-bar element with a layout-boundary class.
3106
3107         * inspector/front-end/CodeMirrorTextEditor.js:
3108         (WebInspector.CodeMirrorTextEditor):
3109         * inspector/front-end/DefaultTextEditor.js:
3110         * inspector/front-end/View.js:
3111         (WebInspector.View.prototype.markAsLayoutBoundary):
3112         (WebInspector.View.prototype._processWillShow):
3113         (WebInspector.View.prototype._processWasShown):
3114         (WebInspector.View.prototype._processOnResize):
3115         * inspector/front-end/inspector.css:
3116         (.layout-boundary):
3117         * inspector/front-end/inspector.html:
3118
3119 2013-04-02  Alexey Proskuryakov  <ap@apple.com>
3120
3121         <rdar://problem/13551119> [WK2] Crashes in NetworkProcess when canceling loads
3122         https://bugs.webkit.org/show_bug.cgi?id=113803
3123
3124         Reviewed by Darin Adler.
3125
3126         Stop using a delegate proxy. It hasn't been needed in years, and the extra layer
3127         just adds bugs.
3128
3129         This specific issue gets fixed because connection retains its delegate is retained,
3130         but a proxy does not.
3131
3132         * WebCore.exp.in:
3133         * platform/network/ResourceHandle.h:
3134         * platform/network/ResourceHandleInternal.h:
3135         * platform/network/mac/ResourceHandleMac.mm:
3136         (WebCore::ResourceHandle::start):
3137         (WebCore::ResourceHandle::releaseDelegate):
3138         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
3139         Removed code that was dealing with delegate proxy.
3140
3141 2013-04-02  John J. Barton  <johnjbarton@chromium.org>
3142
3143         Web Inspector: Encapsulate SetEmbedderData/GetEmbedderData
3144         https://bugs.webkit.org/show_bug.cgi?id=113331
3145
3146         Reviewed by Pavel Feldman.
3147
3148         Refactor to encapsulate uses of V8 Set/GetEmbedderData together
3149         with uses of V8 Set/GetAlignedPointerInEmbedderData since these
3150         functions operate on the same underyling array in V8.
3151
3152         * bindings/v8/ScriptController.cpp:
3153         (WebCore::ScriptController::setContextDebugId):
3154         (WebCore::ScriptController::contextDebugId):
3155         * bindings/v8/V8DOMWindowShell.cpp:
3156         (WebCore::setInjectedScriptContextDebugId):
3157         * bindings/v8/V8PerContextData.cpp:
3158         (WebCore::V8PerContextDebugData::setContextDebugData):
3159         (WebCore):
3160         (WebCore::V8PerContextDebugData::contextDebugId):
3161         (WebCore::V8PerContextDebugData::createDebugData):
3162         (WebCore::V8PerContextDebugData::getDebugData):
3163         (WebCore::V8PerContextDebugData::setDebugData):
3164         * bindings/v8/V8PerContextData.h:
3165         (V8PerContextDebugData):
3166         (WebCore):
3167
3168 2013-04-02  Alexei Filippov  <alph@chromium.org>
3169
3170         Web Inspector: Adjust toolbar labels position
3171         https://bugs.webkit.org/show_bug.cgi?id=113805
3172
3173         Reviewed by Pavel Feldman.
3174
3175         Move the labels 1px up to make them centered.
3176         Also fix font centering in native memory distribution snapshot.
3177
3178         * inspector/front-end/inspector.css:
3179         (.toolbar-label):
3180         * inspector/front-end/nativeMemoryProfiler.css:
3181         (.native-snapshot-view .data-grid td):
3182
3183 2013-04-02  Beth Dakin  <bdakin@apple.com>
3184
3185         Viewport constrained elements should work properly with headers and footers
3186         https://bugs.webkit.org/show_bug.cgi?id=113743
3187
3188         Reviewed by Simon Fraser.
3189
3190         ScrollableArea::constrainScrollPositionForOverhang() needs to take headerHeight 
3191         and footerHeight into account. It also needs to use totalContentsSize() instead of 
3192         contentsSize().
3193
3194         Send totalContentsSize() instead of contentsSize() and also send headerHeight() 
3195         and footerHeight().
3196         * page/FrameView.cpp:
3197         (WebCore::FrameView::scrollOffsetForFixedPosition):
3198         * page/FrameView.h:
3199         (FrameView):
3200
3201         The scrolling tree will also need to know about header and footer heights since it 
3202         will need these values to call 
3203         ScrollableArea::constrainScrollPositionForOverhang().
3204         * page/scrolling/ScrollingStateScrollingNode.cpp:
3205         (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
3206         (WebCore::ScrollingStateScrollingNode::setHeaderHeight):
3207         (WebCore::ScrollingStateScrollingNode::setFooterHeight):
3208         * page/scrolling/ScrollingStateScrollingNode.h:
3209         (WebCore::ScrollingStateScrollingNode::headerHeight):
3210         (ScrollingStateScrollingNode):
3211         (WebCore::ScrollingStateScrollingNode::footerHeight):
3212         * page/scrolling/ScrollingTreeScrollingNode.cpp:
3213         (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
3214         (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
3215         * page/scrolling/ScrollingTreeScrollingNode.h:
3216         (WebCore::ScrollingTreeScrollingNode::headerHeight):
3217         (WebCore::ScrollingTreeScrollingNode::footerHeight):
3218         (ScrollingTreeScrollingNode):
3219         * page/scrolling/mac/ScrollingCoordinatorMac.h:
3220         (ScrollParameters):
3221         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
3222         (WebCore::ScrollingCoordinatorMac::frameViewLayoutUpdated):
3223         (WebCore::ScrollingCoordinatorMac::setScrollParametersForNode):
3224         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
3225         (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
3226
3227         Use footerHeight when calculating the maxValue and use headerHeight in determining 
3228         what the minimum value is. 
3229         * platform/ScrollableArea.cpp:
3230         (WebCore::constrainedScrollPosition):
3231         (WebCore::ScrollableArea::constrainScrollPositionForOverhang):
3232         * platform/ScrollableArea.h:
3233         (ScrollableArea):
3234
3235 2013-04-02  Stephen White  <senorblanco@chromium.org>
3236
3237         [Skia] Enable GPU-accelerated Skia path for FEComposite filter.
3238         https://bugs.webkit.org/show_bug.cgi?id=113797
3239
3240         Reviewed by Adrienne Walker.
3241
3242         Tests: css3/filters/effect-reference-composite-hw.html
3243                css3/filters/effect-reference-composite.html
3244
3245         * WebCore.gypi:
3246         * platform/graphics/filters/FEComposite.h:
3247         Enable Skia DAG hook for FEComposite.
3248         * platform/graphics/filters/skia/FECompositeSkia.cpp: Added.
3249         (WebCore::FEComposite::createImageFilter):
3250         Implement skia DAG builder for FEComposite, and implement generic
3251         skia version of composite filter.
3252
3253 2013-04-02  Andrey Lushnikov  <lushnikov@chromium.org>
3254
3255         Web Inspector: Avoid using style.display="inline-block"
3256         https://bugs.webkit.org/show_bug.cgi?id=113802
3257
3258         Reviewed by Pavel Feldman.
3259
3260         No new tests.
3261
3262         - Create class "inline-block" which will set "display: inline-block"
3263         style.
3264         - Use this class with DIV elements to get "inline-block" element.
3265
3266         * inspector/front-end/ObjectPopoverHelper.js:
3267         (WebInspector.ObjectPopoverHelper.prototype.):
3268         (WebInspector.ObjectPopoverHelper.prototype._showObjectPopover):
3269         * inspector/front-end/ScriptsPanel.js:
3270         (WebInspector.ScriptsPanel):
3271         * inspector/front-end/inspector.css:
3272         (.inline-block):
3273
3274 2013-04-02  Andrey Kosyakov  <caseq@chromium.org>
3275
3276         Web Inspector: [Timeline] warning markers are not propagated to coalesced records
3277         https://bugs.webkit.org/show_bug.cgi?id=113789
3278
3279         Reviewed by Pavel Feldman.
3280
3281         Test: inspector/timeline/timeline-coalescing.html
3282
3283         * inspector/front-end/TimelinePresentationModel.js: set childHasWarning on coalescing record if the record it replaces had warnings.
3284         (WebInspector.TimelinePresentationModel.prototype._replaceWithCoalescedRecord):
3285
3286 2013-04-02  Yury Semikhatsky  <yurys@chromium.org>
3287
3288         Web Inspector: memory instrumentation for external strings is broken
3289         https://bugs.webkit.org/show_bug.cgi?id=113788
3290
3291         Reviewed by Pavel Feldman.
3292
3293         Native memory snapshot now provides information about JS external strings.
3294
3295         Test: inspector/profiler/memory-instrumentation-external-string.html
3296
3297         * inspector/InspectorMemoryAgent.cpp:
3298
3299 2013-04-02  Yury Semikhatsky  <yurys@chromium.org>
3300
3301         Web Inspector: memory instrumentation for external arrays is broken
3302         https://bugs.webkit.org/show_bug.cgi?id=113790
3303
3304         Report pointers to external arrays as retaining ones to make sure their
3305         size is counted correctly.
3306
3307         Reviewed by Pavel Feldman.
3308
3309         Test: inspector/profiler/memory-instrumentation-external-array.html
3310
3311         * inspector/InspectorMemoryAgent.cpp:
3312
3313 2013-04-02  Peter Beverloo  <peter@chromium.org>
3314
3315         [JSC] Don't create a JSValue if it's not going to be used for nullable attributes
3316         https://bugs.webkit.org/show_bug.cgi?id=112711
3317
3318         Reviewed by Sam Weinig.
3319
3320         When nullable attributes are used, it's possible that we disregard the JSValue
3321         when null should be returned instead. This is a waste, and we should cast the
3322         native type to a JSValue as late as possible.
3323
3324         * bindings/scripts/CodeGeneratorJS.pm:
3325         (GenerateImplementation):
3326         (NativeValueToLocal):
3327         * bindings/scripts/test/JS/JSTestObj.cpp:
3328         (WebCore::jsTestObjAttrWithGetterException):
3329         (WebCore::jsTestObjStringAttrWithGetterException):
3330         (WebCore::jsTestObjWithScriptStateAttributeRaises):
3331         (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
3332         (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
3333         (WebCore::jsTestObjNullableDoubleAttribute):
3334         (WebCore::jsTestObjNullableLongAttribute):
3335         (WebCore::jsTestObjNullableBooleanAttribute):
3336         (WebCore::jsTestObjNullableStringAttribute):
3337         (WebCore::jsTestObjNullableLongSettableAttribute):
3338         (WebCore::jsTestObjNullableStringValue):
3339         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
3340         (WebCore::jsTestTypedefsAttrWithGetterException):
3341         (WebCore::jsTestTypedefsStringAttrWithGetterException):
3342
3343 2013-04-02  Bem Jones-Bey  <bjonesbe@adobe.com>
3344
3345         [css exclusions] overflow:hidden undoes shape-outside offsets
3346         https://bugs.webkit.org/show_bug.cgi?id=110349
3347
3348         Reviewed by Julien Chaffraix.
3349
3350         When overflow: hidden was set on a float with shape-outside, the
3351         offset from the shape-outside was being ignored. This was because the
3352         float was being placed in the normal flow, causing the offsets to be
3353         calculated differently. Since floats with shape outside behave like
3354         positioned objects in many places, I have caused them to take the same
3355         behavior as positioned objects in this case as well: the floats with
3356         shape-outside do not get placed in the normal flow when overflow:
3357         hidden is set.
3358
3359         Test: fast/exclusions/shape-outside-floats/shape-outside-floats-overflow-hidden.html
3360
3361         * rendering/RenderLayer.cpp:
3362         (WebCore::RenderLayer::shouldBeNormalFlowOnly): Floats that have
3363             shape-outside should not be in the normal flow.
3364
3365 2013-04-02  Andrey Lushnikov  <lushnikov@chromium.org>
3366
3367         Web Inspector: resource preview of html/js/css types should be on a grey background
3368         https://bugs.webkit.org/show_bug.cgi?id=113791
3369
3370         Reviewed by Pavel Feldman.
3371
3372         No new tests.
3373
3374         - Add a css rule to set grey background for SourceFrame in resource view.
3375         - Add "fill" style to SourceFrame element to setup its height.
3376
3377         * inspector/front-end/SourceFrame.js:
3378         (WebInspector.SourceFrame):
3379         * inspector/front-end/resourceView.css:
3380         (.resource-view .script-view):
3381
3382 2013-04-02  Andrey Lushnikov  <lushnikov@chromium.org>
3383
3384         Web Inspector: [CodeMirror] Editor doesn't have yellow background in DivergedFromVM state
3385         https://bugs.webkit.org/show_bug.cgi?id=113783
3386
3387         Reviewed by Pavel Feldman.
3388
3389         No new tests.
3390
3391         Force CodeMirrorTextEditor to have transparent background to inherit
3392         background color from source frame.
3393
3394         * inspector/front-end/cm/cmdevtools.css:
3395         (.CodeMirror):
3396
3397 2013-04-02  Jochen Eisinger  <jochen@chromium.org>
3398
3399         Check whether popups are allowed before creating a new window
3400         https://bugs.webkit.org/show_bug.cgi?id=113782
3401
3402         Reviewed by Adam Barth.
3403
3404         Otherwise, firing a generated mouse event at an anchor is enough to
3405         work around the popup blocker.
3406
3407         Test: fast/loader/url-selected-user-gesture.html
3408
3409         * loader/PolicyChecker.cpp:
3410         (WebCore::PolicyChecker::checkNewWindowPolicy):
3411
3412 2013-04-02  Jochen Eisinger  <jochen@chromium.org>
3413
3414         When computing the percentage of the logical height, use the logical top and bottom
3415         https://bugs.webkit.org/show_bug.cgi?id=113761
3416
3417         Reviewed by Ojan Vafai.
3418
3419         Test: fast/writing-mode/percentage-height-orthogonal-writing-modes.html
3420
3421         * rendering/RenderBox.cpp:
3422         (WebCore::RenderBox::computePercentageLogicalHeight):
3423
3424 2013-04-02  Andrey Lushnikov  <lushnikov@chromium.org>
3425
3426         Web Inspector: [CodeMirror] do not show cursor in read-only mode
3427         https://bugs.webkit.org/show_bug.cgi?id=113793
3428
3429         Reviewed by Alexander Pavlov.
3430
3431         No new tests.
3432
3433         Pass "nocursor" option to CodeMirror's "readonly" setting.
3434
3435         * inspector/front-end/CodeMirrorTextEditor.js:
3436         (WebInspector.CodeMirrorTextEditor.prototype.setReadOnly):
3437
3438 2013-04-02  Nate Chapin  <japhet@chromium.org>
3439
3440         Unreviewed, rolling out r147402.
3441         http://trac.webkit.org/changeset/147402
3442         https://bugs.webkit.org/show_bug.cgi?id=112903
3443
3444         * dom/Document.cpp:
3445         (WebCore::Document::processHttpEquiv):
3446         * loader/DocumentLoader.cpp:
3447         (WebCore::DocumentLoader::responseReceived):
3448
3449 2013-04-02  ChangSeok Oh  <changseok.oh@collabora.com>
3450
3451         [GTK][AC] Support preserves3D css property for clutter ac backend.
3452         https://bugs.webkit.org/show_bug.cgi?id=113318
3453
3454         Reviewed by Gustavo Noronha Silva.
3455
3456         This patch brings preserve-3D css property support