Leaving a streaming movie by going "Back" keeps playing the audio
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-04-03  Jer Noble  <jer.noble@apple.com>
2
3         Leaving a streaming movie by going "Back" keeps playing the audio
4         https://bugs.webkit.org/show_bug.cgi?id=131149
5
6         Reviewed by Eric Carlson.
7
8         When stopping a HTMLMediaElement, call userCancelledLoad() (which clears the
9         MediaPlayer) only after calling setPausedInternal() (which pauses the MediaPlayer).
10         Previously, and in the reverse order, the MediaPlayer would never get a chance to pause
11         before being cleared. There is an underlying error with the QTKit media engine which
12         is causing it to continue playing even after its last reference is released, but this
13         does fix the symptom of playback continuing even after stopping.
14
15         * html/HTMLMediaElement.cpp:
16         (WebCore::HTMLMediaElement::stop):
17
18 2014-04-03  Jer Noble  <jer.noble@apple.com>
19
20         [EME] Crash when passing a NULL initData to MediaKeys.createSession()
21         https://bugs.webkit.org/show_bug.cgi?id=131156
22
23         Reviewed by Eric Carlson.
24
25         Update the checks at the start of createSession() to match the current spec, notably
26         bailing early if the initData parameter is NULL or empty.
27
28         * Modules/encryptedmedia/MediaKeys.cpp:
29         (WebCore::MediaKeys::createSession):
30
31 2014-04-03  Eric Carlson  <eric.carlson@apple.com>
32
33         [iOS] add missing QuickTime plug-in replacement API
34         https://bugs.webkit.org/show_bug.cgi?id=131042
35
36         Reviewed by Dean Jackson.
37
38         Rename QuickTimePluginReplacement.cpp to QuickTimePluginReplacement.mm to make it possible
39         to use the ObjC JSC API.
40         * Modules/plugins/QuickTimePluginReplacement.cpp:
41         * Modules/plugins/QuickTimePluginReplacement.h:
42         (WebCore::QuickTimePluginReplacement::parentElement):
43         * Modules/plugins/QuickTimePluginReplacement.idl:
44
45         * Modules/plugins/QuickTimePluginReplacement.js:
46         (Replacement.prototype.timedMetadataUpdates): Implement.
47         (Replacement.prototype.accessLog): Ditto.
48         (Replacement.prototype.errorLog): Ditto.
49
50         Use the JSC ObjC API to create a JavaScript object from an array of AVMetadataItems. The
51         JSC ObjC API supports basic NSTypes, but an AVMetadataItem can also contain NSData which 
52         the existing plug-in returns as base-64 encoded data, so create wrappers for NSDictionary
53         and NSArray.
54         * Modules/plugins/QuickTimePluginReplacement.mm: Copied from Source/WebCore/Modules/plugins/QuickTimePluginReplacement.cpp.
55         (WebCore::QuickTimePluginReplacement::ensureReplacementScriptInjected): Disambiguate with "JSC::"
56         (WebCore::QuickTimePluginReplacement::installReplacement): Ditto.
57         (WebCore::jsValueWithDataInContext): Create JSValue* from NSData.
58         (WebCore::jsValueWithArrayInContext): Create JSValue* from NSArray.
59         (WebCore::jsValueWithDictionaryInContext): Create JSValue* from NSDictionary.
60         (WebCore::jsValueWithValueInContext): Create JSValue* from basic NSTypes plus AVMetadataItem
61             and NSData.
62         (WebCore::jsValueWithAVMetadataItemInContext): Create JSValue* from AVMetadataItem.
63         (WebCore::JSQuickTimePluginReplacement::timedMetaData): Script interface.
64         (WebCore::JSQuickTimePluginReplacement::accessLog): Ditto.
65         (WebCore::JSQuickTimePluginReplacement::errorLog): Ditto.
66
67         * WebCore.xcodeproj/project.pbxproj: QuickTimePluginReplacement.cpp -> QuickTimePluginReplacement.mm.
68
69         * platform/graphics/MediaPlayer.cpp:
70         (WebCore::MediaPlayer::timedMetadata): iOS only accessor.
71         (WebCore::MediaPlayer::accessLog): Ditto.
72         (WebCore::MediaPlayer::errorLog): Ditto.
73         * platform/graphics/MediaPlayer.h:
74         * platform/graphics/MediaPlayerPrivate.h:
75
76         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
77         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
78         (WebCore::MediaPlayerPrivateAVFoundationObjC::timedMetadata):
79         (WebCore::MediaPlayerPrivateAVFoundationObjC::accessLog):
80         (WebCore::MediaPlayerPrivateAVFoundationObjC::errorLog):
81         (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive):
82         (WebCore::itemKVOProperties):
83         (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]):
84
85 2014-04-03  Andrei Bucur  <abucur@adobe.com>
86
87         [CSS Regions] Include region range information when printing the render tree
88         https://bugs.webkit.org/show_bug.cgi?id=131159
89
90         Reviewed by Mihnea Ovidenie.
91
92         With this change showRenderObject() will print the region range for objects inside
93         a flow thread. The format is:
94         Rs: <startRegion> Re: <endRegion>
95
96         Because this can be called anytime during debugging, it's necessary to disable the
97         current flow thread caching to prevent using the wrong flow thread for an object.
98
99         Tests: No new tests, no functional change.
100
101         * rendering/RenderFlowThread.cpp:
102         (WebCore::CurrentRenderFlowThreadDisabler::CurrentRenderFlowThreadDisabler):
103         (WebCore::CurrentRenderFlowThreadDisabler::~CurrentRenderFlowThreadDisabler):
104         * rendering/RenderFlowThread.h:
105         * rendering/RenderObject.cpp:
106         (WebCore::RenderObject::showRegionsInformation): Added.
107         (WebCore::RenderObject::showRenderObject):
108         * rendering/RenderObject.h:
109
110 2014-04-03  Antti Koivisto  <antti@apple.com>
111
112         RenderSnapshottedPlugIn::paint should use iterator for traversal.
113         https://bugs.webkit.org/show_bug.cgi?id=131158
114
115         Reviewed by Dean Jackson.
116
117         * rendering/RenderSnapshottedPlugIn.cpp:
118         (WebCore::RenderSnapshottedPlugIn::paint):
119
120 2014-03-27  Sergio Villar Senin  <svillar@igalia.com>
121
122         [CSS Grid Layout] <string> not allowed in grid-{area | row | column} syntax
123         https://bugs.webkit.org/show_bug.cgi?id=129713
124
125         Reviewed by Darin Adler.
126
127         Grid positioning properties no longer accept <string> values for
128         named grid lines as they did in previous versions of the specs. They
129         were first replaced by <ident> and since the beginning of 2014 they
130         should only accept <custom-ident>.
131
132         Updated the parser and the style resolver to this new syntax. Also
133         updated the tests accordingly.
134
135         Test: fast/css-grid-layout/grid-container-change-named-grid-lines-recompute-child.html
136
137         * css/CSSParser.cpp:
138         (WebCore::isValidCustomIdent): New function that checks that the
139         <custom-ident> is valid.
140         (WebCore::CSSParser::parseIntegerOrCustomIdentFromGridPosition):
141         (WebCore::CSSParser::parseGridPosition):
142         (WebCore::CSSParser::parseIntegerOrStringFromGridPosition):
143         Replaced by WebCore::CSSParser::parseIntegerOrCustomIdentFromGridPosition.
144         * css/CSSParser.h:
145         * css/StyleResolver.cpp:
146         (WebCore::createGridPosition):
147
148 2014-04-03  Antti Koivisto  <antti@apple.com>
149
150         Crash after mutating after pseudo style
151         https://bugs.webkit.org/show_bug.cgi?id=130881
152
153         Reviewed by Andreas Kling.
154
155         Test: fast/css/pseudo-after-crash.html
156
157         * style/StyleResolveTree.cpp:
158         (WebCore::Style::updateBeforeOrAfterPseudoElement):
159         
160             Invalidate the cached renderer for pseudo elements too.
161     
162         (WebCore::Style::needsPseudeElement): Deleted.
163         
164             Fix spelling.
165
166 2014-04-02  Chris Fleizach  <cfleizach@apple.com>
167
168         AX: AccessibilityObject::children() returns invalid results sometimes
169         https://bugs.webkit.org/show_bug.cgi?id=130563
170
171         Reviewed by Joseph Pecoraro.
172
173         Allow the DOM inspector to handle AX objects that do not have Node equivalents
174         (e.g. anonymous renderers).
175
176         * inspector/InspectorDOMAgent.cpp:
177         (WebCore::InspectorDOMAgent::processAccessibilityChildren):
178         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
179         * inspector/InspectorDOMAgent.h:
180
181 2014-04-02  Alexey Proskuryakov  <ap@apple.com>
182
183         Sandbox violation in NetworkProcess when uploading a bundle
184         https://bugs.webkit.org/show_bug.cgi?id=131133
185
186         Reviewed by Brady Eidson.
187
188         Track generated file ownership explicitly, so that each copy of FormData would know
189         whether to delete the file.
190
191         This part is needed to prevent asserting in FormData destructor in NetworkProcess,
192         because it doesn't delete the files. Also, some cleanup.
193
194         * WebCore.exp.in: Don't export FormData::removeGeneratedFilesIfNeeded(), WebKit2
195         doesn't need it any more.
196         * platform/network/FormData.cpp: Removed m_hasGeneratedFiles. There is no problem
197         iterating over FormDataElements to compute it, and that's more robust when FormDatas
198         are passed or stored on disk permanently.
199         Updated touched functions to use C++ iteration, and renamed "e" to "element".
200         (WebCore::FormData::encode): Keep encoding a boolean for hasGeneratedFiles, because
201         the encoded FormData can be stored persitently, and we can't change the format.
202
203         * platform/network/FormData.h: (WebCore::FormDataElement::FormDataElement):
204         Added m_ownsGeneratedFile. FormData will only delete files it owns. Since files
205         are generated immediately before form submission, it's always the FormData being
206         submitted that owns the generated files.
207
208 2014-04-02  Mihnea Ovidenie  <mihnea@adobe.com>
209
210         [CSSRegions] Use RenderStyle::hasFlowInto when needed
211         https://bugs.webkit.org/show_bug.cgi?id=131092
212
213         Reviewed by Andrei Bucur.
214
215         Add hasFlowInto() helper method on RenderStyle to be used
216         instead of directly checking the presence or absence of flowThread value.
217         No new functionality, no new tests.
218
219         * css/CSSComputedStyleDeclaration.cpp:
220         (WebCore::ComputedStyleExtractor::propertyValue):
221         * dom/Element.cpp:
222         (WebCore::Element::shouldMoveToFlowThread):
223         * rendering/style/RenderStyle.h:
224         * style/StyleResolveTree.cpp:
225         (WebCore::Style::isRendererReparented):
226
227 2014-04-02  Benjamin Poulain  <benjamin@webkit.org>
228
229         CSS JIT: the adjacent position is never reset
230         https://bugs.webkit.org/show_bug.cgi?id=131145
231
232         Reviewed by Andreas Kling.
233
234         Corresponding radar: <rdar://problem/16440036>. The backtracking action would use a tail
235         when not needed.
236
237         Test: fast/selectors/multiple-adjacent-chain-without-adjacent-tail.html
238
239         * cssjit/SelectorCompiler.cpp:
240         (WebCore::SelectorCompiler::updateChainStates):
241
242 2014-04-02  Brent Fulgham  <bfulgham@apple.com>
243
244         Speculative build fix for Windows.
245
246         * DerivedSources.make: Make sure we generate our media control
247         scripts for Apple Windows (but not WinCairo)
248
249 2014-04-02  Tim Horton  <timothy_horton@apple.com>
250
251         Fix the !USE(IOSURFACE) iOS build.
252
253         * platform/ios/MemoryPressureHandlerIOS.mm:
254         (WebCore::MemoryPressureHandler::platformReleaseMemory):
255
256 2014-04-02  Mark Rowe  <mrowe@apple.com>
257
258         <https://webkit.org/b/131136> Remove FrameLoadRequest's m_lockHistory member since it's always false.
259
260         Reviewed by Andreas Kling.
261
262         * loader/FrameLoadRequest.cpp:
263         (WebCore::FrameLoadRequest::FrameLoadRequest):
264         * loader/FrameLoadRequest.h:
265         (WebCore::FrameLoadRequest::FrameLoadRequest):
266         (WebCore::FrameLoadRequest::lockHistory): Deleted.
267         (WebCore::FrameLoadRequest::setLockHistory): Deleted.
268         * loader/FrameLoader.cpp:
269         (WebCore::FrameLoader::load): Remove an if whose body was never executed.
270
271 2014-04-02  Mark Rowe  <mrowe@apple.com>
272
273         <https://webkit.org/b/131135> Introduce LockHistory and LockBackForwardList enums to use in place of bools.
274
275         These arguments are often passed using literals at the call site, where the use of bools severely hinders
276         the readability of the code.
277
278         Reviewed by Andreas Kling.
279
280         * WebCore.exp.in:
281         * html/HTMLAnchorElement.cpp:
282         (WebCore::HTMLAnchorElement::handleClick):
283         * html/HTMLFormElement.cpp:
284         (WebCore::HTMLFormElement::submit):
285         * html/HTMLFrameElementBase.cpp:
286         (WebCore::HTMLFrameElementBase::openURL):
287         (WebCore::HTMLFrameElementBase::setLocation):
288         * html/HTMLFrameElementBase.h:
289         * inspector/InspectorFrontendClientLocal.cpp:
290         (WebCore::InspectorFrontendClientLocal::openInNewTab):
291         * inspector/InspectorPageAgent.cpp:
292         (WebCore::InspectorPageAgent::navigate):
293         * loader/FormSubmission.cpp:
294         (WebCore::FormSubmission::FormSubmission):
295         (WebCore::FormSubmission::create):
296         * loader/FormSubmission.h:
297         (WebCore::FormSubmission::lockHistory):
298         * loader/FrameLoader.cpp:
299         (WebCore::FrameLoader::changeLocation):
300         (WebCore::FrameLoader::urlSelected):
301         (WebCore::FrameLoader::loadURLIntoChildFrame):
302         (WebCore::FrameLoader::loadFrameRequest):
303         (WebCore::FrameLoader::loadURL):
304         (WebCore::FrameLoader::loadWithNavigationAction):
305         (WebCore::FrameLoader::clientRedirected):
306         (WebCore::FrameLoader::loadPostRequest):
307         (WebCore::FrameLoader::continueLoadAfterNewWindowPolicy):
308         (WebCore::FrameLoader::loadDifferentDocumentItem):
309         * loader/FrameLoader.h:
310         * loader/FrameLoaderTypes.h:
311         * loader/NavigationScheduler.cpp:
312         (WebCore::ScheduledNavigation::ScheduledNavigation):
313         (WebCore::ScheduledNavigation::lockHistory):
314         (WebCore::ScheduledNavigation::lockBackForwardList):
315         (WebCore::ScheduledURLNavigation::ScheduledURLNavigation):
316         (WebCore::ScheduledRedirect::ScheduledRedirect):
317         (WebCore::ScheduledLocationChange::ScheduledLocationChange):
318         (WebCore::ScheduledRefresh::ScheduledRefresh):
319         (WebCore::ScheduledHistoryNavigation::ScheduledHistoryNavigation):
320         (WebCore::ScheduledFormSubmission::ScheduledFormSubmission):
321         (WebCore::NavigationScheduler::scheduleRedirect):
322         (WebCore::NavigationScheduler::mustLockBackForwardList):
323         (WebCore::NavigationScheduler::scheduleLocationChange):
324         (WebCore::NavigationScheduler::scheduleFormSubmission):
325         * loader/NavigationScheduler.h:
326         * loader/SubframeLoader.cpp:
327         (WebCore::SubframeLoader::requestFrame):
328         (WebCore::SubframeLoader::requestObject):
329         (WebCore::SubframeLoader::loadOrRedirectSubframe):
330         * loader/SubframeLoader.h:
331         * page/ContextMenuController.cpp:
332         (WebCore::openNewWindow):
333         (WebCore::ContextMenuController::contextMenuItemSelected):
334         * page/DOMWindow.cpp:
335         (WebCore::DOMWindow::setLocation):
336         (WebCore::DOMWindow::createWindow):
337         (WebCore::DOMWindow::open):
338         * svg/SVGAElement.cpp:
339         (WebCore::SVGAElement::defaultEventHandler):
340
341 2014-04-02  Tim Horton  <timothy_horton@apple.com>
342
343         Pool IOSurfaces to help with allocation cost
344         https://bugs.webkit.org/show_bug.cgi?id=131096
345         <rdar://problem/15373942>
346
347         Reviewed by Simon Fraser.
348
349         * WebCore.exp.in:
350         * WebCore.xcodeproj/project.pbxproj:
351         
352         * platform/Timer.h:
353         (WebCore::TimerBase::startRepeating): Add a std::chrono startRepeating.
354
355         * platform/graphics/cg/IOSurfacePool.h: Added.
356         (WebCore::IOSurfacePool::CachedSurfaceDetails::CachedSurfaceDetails):
357         (WebCore::IOSurfacePool::CachedSurfaceDetails::resetLastUseTime):
358         * platform/graphics/cg/ImageBufferBackingStoreCache.cpp: Removed.
359         * platform/graphics/cg/ImageBufferBackingStoreCache.h: Removed.
360         * platform/graphics/cg/IOSurfacePool.cpp: Added.
361         (WebCore::IOSurfacePool::IOSurfacePool):
362         (WebCore::IOSurfacePool::sharedPool):
363         (WebCore::surfaceMatchesParameters):
364         (WebCore::IOSurfacePool::willAddSurface):
365         (WebCore::IOSurfacePool::didRemoveSurface):
366         (WebCore::IOSurfacePool::didUseSurfaceOfSize):
367         (WebCore::IOSurfacePool::takeSurface):
368         (WebCore::IOSurfacePool::addSurface):
369         (WebCore::IOSurfacePool::insertSurfaceIntoPool):
370         (WebCore::IOSurfacePool::setPoolSize):
371         (WebCore::IOSurfacePool::tryEvictInUseSurface):
372         (WebCore::IOSurfacePool::tryEvictOldestCachedSurface):
373         (WebCore::IOSurfacePool::evict):
374         (WebCore::IOSurfacePool::collectInUseSurfaces):
375         (WebCore::IOSurfacePool::markOlderSurfacesPurgeable):
376         (WebCore::IOSurfacePool::collectionTimerFired):
377         (WebCore::IOSurfacePool::scheduleCollectionTimer):
378         (WebCore::IOSurfacePool::discardAllSurfaces):
379         (WebCore::IOSurfacePool::showPoolStatistics):
380         Add a pool of IOSurfaces. It behaves as such:
381
382             - Keeps up to 64MB of surfaces.
383             - Keeps unused and in-use surfaces (but never gets more than 1/2 full with the latter)
384             - Marks surfaces purgeable after they've been unused for 2 seconds.
385             - Tries to move surfaces from the in-use pool to the unused pool every 500ms.
386             - Evicts in an LRU-ish fashion, interleaving eviction of the oldest
387               surfaces and the in-use surfaces (since in-use surfaces are not immediately
388               useful for the pool, but they are desirous because they were recently used).
389             - Throws everything away under memory pressure.
390
391         * platform/graphics/cocoa/IOSurface.mm:
392         (IOSurface::create):
393         Try to grab a surface from the IOSurfacePool.
394
395         * platform/ios/MemoryPressureHandlerIOS.mm:
396         (WebCore::MemoryPressureHandler::platformReleaseMemory):
397         * platform/mac/MemoryPressureHandlerMac.mm:
398         (WebCore::MemoryPressureHandler::install):
399         (WebCore::MemoryPressureHandler::platformReleaseMemory):
400         * platform/MemoryPressureHandler.cpp:
401         (WebCore::MemoryPressureHandler::platformReleaseMemory):
402         Fix some includes, and throw away all surfaces when we're under memory pressure.
403
404 2014-04-02  Stephanie Lewis  <slewis@apple.com>
405
406         Roll out http://trac.webkit.org/changeset/166144
407         <rdar://problem/16481284> PLT stops loading on news.google.com
408
409         Unreviewed rollout.
410
411         Rollout 166144 since it prevents the PLT from completing.
412
413         * dom/ContainerNode.cpp:
414         (WebCore::ContainerNode::suspendPostAttachCallbacks):
415         (WebCore::ContainerNode::resumePostAttachCallbacks):
416         (WebCore::ContainerNode::queuePostAttachCallback):
417         (WebCore::ContainerNode::postAttachCallbacksAreSuspended):
418         (WebCore::ContainerNode::dispatchPostAttachCallbacks):
419         * dom/ContainerNode.h:
420         * dom/Document.cpp:
421         (WebCore::Document::recalcStyle):
422         * dom/Element.h:
423         (WebCore::PostAttachCallbackDisabler::PostAttachCallbackDisabler):
424         (WebCore::PostAttachCallbackDisabler::~PostAttachCallbackDisabler):
425         * html/HTMLEmbedElement.cpp:
426         (WebCore::HTMLEmbedElement::parseAttribute):
427         * html/HTMLFormControlElement.cpp:
428         (WebCore::focusPostAttach):
429         (WebCore::HTMLFormControlElement::didAttachRenderers):
430         (WebCore::updateFromElementCallback):
431         (WebCore::HTMLFormControlElement::didRecalcStyle):
432         * html/HTMLFrameOwnerElement.cpp:
433         (WebCore::needsStyleRecalcCallback):
434         (WebCore::HTMLFrameOwnerElement::scheduleSetNeedsStyleRecalc):
435         * html/HTMLObjectElement.cpp:
436         (WebCore::HTMLObjectElement::parseAttribute):
437         (WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk):
438         (WebCore::HTMLObjectElement::hasValidClassId):
439         (WebCore::HTMLObjectElement::renderFallbackContent):
440         * html/HTMLObjectElement.h:
441         * html/HTMLPlugInImageElement.cpp:
442         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
443         (WebCore::HTMLPlugInImageElement::createElementRenderer):
444         (WebCore::HTMLPlugInImageElement::didAttachRenderers):
445         (WebCore::HTMLPlugInImageElement::willDetachRenderers):
446         (WebCore::HTMLPlugInImageElement::updateWidgetIfNecessary):
447         (WebCore::HTMLPlugInImageElement::didMoveToNewDocument):
448         (WebCore::HTMLPlugInImageElement::updateWidgetCallback):
449         (WebCore::HTMLPlugInImageElement::startLoadingImage):
450         (WebCore::HTMLPlugInImageElement::startLoadingImageCallback):
451         (WebCore::HTMLPlugInImageElement::createShadowIFrameSubtree):
452         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn):
453         (WebCore::HTMLPlugInImageElement::didRecalcStyle): Deleted.
454         (WebCore::HTMLPlugInImageElement::scheduleUpdateForAfterStyleResolution): Deleted.
455         (WebCore::HTMLPlugInImageElement::updateAfterStyleResolution): Deleted.
456         (WebCore::HTMLPlugInImageElement::removedFrom): Deleted.
457         (WebCore::is100Percent): Deleted.
458         (WebCore::HTMLPlugInImageElement::setNeedsImageReload): Deleted.
459         * html/HTMLPlugInImageElement.h:
460         (WebCore::HTMLPlugInImageElement::imageLoader): Deleted.
461         (WebCore::HTMLPlugInImageElement::updateImageLoaderWithNewURLSoon): Deleted.
462         * style/StyleResolveTree.cpp:
463         (WebCore::Style::needsPseudeElement):
464         (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded):
465         (WebCore::Style::attachRenderTree):
466         (WebCore::Style::updateBeforeOrAfterPseudoElement):
467         (WebCore::Style::needsPseudoElement): Deleted.
468         (WebCore::Style::postResolutionCallbackQueue): Deleted.
469         (WebCore::Style::queuePostResolutionCallback): Deleted.
470         (WebCore::Style::suspendMemoryCacheClientCalls): Deleted.
471         (WebCore::Style::PostResolutionCallbackDisabler::PostResolutionCallbackDisabler): Deleted.
472         (WebCore::Style::PostResolutionCallbackDisabler::~PostResolutionCallbackDisabler): Deleted.
473         (WebCore::Style::postResolutionCallbacksAreSuspended): Deleted.
474         * style/StyleResolveTree.h:
475
476 2014-04-02  Jinwoo Song  <jinwoo7.song@samsung.com>
477
478         Page should use std::unique_ptr for PointerLockController
479         https://bugs.webkit.org/show_bug.cgi?id=131098
480
481         Reviewed by Anders Carlsson.
482
483         Make Page keep a std::unique_ptr to PointerLockController. Store page 
484         references and return controller references where possible.
485
486         * dom/Document.cpp:
487         (WebCore::Document::prepareForDestruction):
488         (WebCore::Document::webkitExitPointerLock):
489         (WebCore::Document::webkitPointerLockElement):
490         * dom/Element.cpp:
491         (WebCore::Element::removedFrom):
492         (WebCore::Element::webkitRequestPointerLock):
493         * page/Page.cpp:
494         (WebCore::Page::Page):
495         * page/Page.h:
496         (WebCore::Page::pointerLockController):
497         * page/PointerLockController.cpp:
498         (WebCore::PointerLockController::PointerLockController):
499         (WebCore::PointerLockController::requestPointerLock):
500         (WebCore::PointerLockController::requestPointerUnlock):
501         (WebCore::PointerLockController::create): Deleted.
502         * page/PointerLockController.h:
503
504 2014-04-02  Dean Jackson  <dino@apple.com>
505
506         Load Media Controls js/css from bundle
507         https://bugs.webkit.org/show_bug.cgi?id=131086
508
509         Followup comments from Eric Carlson.
510
511         Remove the booleans that were guarding loading the resources.
512
513         * rendering/RenderThemeIOS.h:
514         * rendering/RenderThemeIOS.mm:
515         (WebCore::RenderThemeIOS::mediaControlsStyleSheet):
516         (WebCore::RenderThemeIOS::mediaControlsScript):
517         (WebCore::RenderThemeIOS::RenderThemeIOS):
518         * rendering/RenderThemeMac.h:
519         * rendering/RenderThemeMac.mm:
520         (WebCore::RenderThemeMac::RenderThemeMac):
521         (WebCore::RenderThemeMac::mediaControlsStyleSheet):
522         (WebCore::RenderThemeMac::mediaControlsScript):
523
524 2014-04-01  Dean Jackson  <dino@apple.com>
525
526         Load Media Controls js/css from bundle
527         https://bugs.webkit.org/show_bug.cgi?id=131086
528
529         Reviewed by Eric Carlson.
530
531         Rather than embed encoded versions of the JS and CSS files
532         into C++ source, just load the files directly from the bundle.
533
534         * DerivedSources.make: Removed now unnecessary rules.
535         * WebCore.xcodeproj/project.pbxproj: Copy mediaControls files to the bundle.
536         * rendering/RenderThemeIOS.h:
537         * rendering/RenderThemeIOS.mm:
538         (WebCore::RenderThemeIOS::RenderThemeIOS):
539         (WebCore::RenderThemeIOS::mediaControlsStyleSheet): Load from the bundle.
540         (WebCore::RenderThemeIOS::mediaControlsScript): Ditto.
541         * rendering/RenderThemeMac.h:
542         * rendering/RenderThemeMac.mm:
543         (WebCore::RenderThemeMac::RenderThemeMac):
544         (WebCore::RenderThemeMac::mediaControlsStyleSheet):
545         (WebCore::RenderThemeMac::mediaControlsScript):
546
547 2014-04-02  Daniel Bates  <dabates@apple.com>
548
549         Move focus management API from HTMLDocument to Document
550         https://bugs.webkit.org/show_bug.cgi?id=131079
551         <rdar://problem/16220103>
552
553         Reviewed by Timothy Hatcher.
554
555         Merged from Blink (patch by Christophe Dumez):
556         https://src.chromium.org/viewvc/blink?view=rev&revision=165515
557
558         Move hasFocus() and attribute activeElement from interface HTMLDocument
559         to DOMDocument as per section Focus management APIs of the HTML5 standard:
560         <http://www.whatwg.org/specs/web-apps/current-work/#focus-management-apis> (1 April 2014).
561
562         Test: fast/dom/Document/xml-document-focus.xml
563
564         * bindings/objc/PublicDOMInterfaces.h: Moved hasFocus() and property activeElement from
565         interface DOMHTMLDocument to DOMDocument.
566         * dom/Document.cpp:
567         (WebCore::Document::activeElement): Added.
568         (WebCore::Document::hasFocus): Added.
569         * dom/Document.h:
570         * dom/Document.idl:
571         * html/HTMLDocument.cpp:
572         (WebCore::HTMLDocument::activeElement): Deleted.
573         (WebCore::HTMLDocument::hasFocus): Deleted.
574         * html/HTMLDocument.h:
575         * html/HTMLDocument.idl:
576
577 2014-04-02  Benjamin Poulain  <benjamin@webkit.org>
578
579         Refactor the function call generator to take the arguments by value
580         https://bugs.webkit.org/show_bug.cgi?id=131129
581
582         Reviewed by Andreas Kling.
583
584         Nothing forces the pointed address to stay alive between setOneArgument/setTwoArguments
585         and prepareAndCall.
586
587         This patch changes FunctionCall to:
588         -Keep the register by value instead of using pointers.
589         -Crash at compile time if a register is invalid.
590
591         * cssjit/FunctionCall.h:
592         (WebCore::FunctionCall::FunctionCall):
593         (WebCore::FunctionCall::setOneArgument):
594         (WebCore::FunctionCall::setTwoArguments):
595         (WebCore::FunctionCall::swapArguments):
596         (WebCore::FunctionCall::prepareAndCall):
597         * cssjit/RegisterAllocator.h:
598         (WebCore::RegisterAllocator::isValidRegister):
599
600 2014-04-02  Daniel Bates  <dabates@apple.com>
601
602         Remove Settings::maximumDecodedImageSize()
603         https://bugs.webkit.org/show_bug.cgi?id=131057
604         <rdar://problem/15626368>
605
606         Reviewed by Darin Adler.
607
608         The setting Settings::maximumDecodedImageSize() and its related logic have various
609         shortcomings, including the inability to cancel an image load when the estimated
610         decoded image size exceeds the maximum decoded image size. In the iOS port, this
611         setting is less useful given image subsampling support. For now, we remove this
612         setting and its related logic. Should it turn out that such a setting is useful
613         then we can implement it again taking care to address the shortcomings in the
614         original design.
615
616         * html/HTMLCanvasElement.cpp: For the iOS port, define MaxCanvasArea to be 4580 * 1145
617         pixels such that the maximum size of the image buffer is 20 MB (assumes 4 bytes per pixel).
618         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
619         (WebCore::HTMLCanvasElement::createImageBuffer):
620         * html/HTMLCanvasElement.h:
621         * html/canvas/CanvasRenderingContext2D.cpp:
622         (WebCore::CanvasRenderingContext2D::createImageData):
623         (WebCore::CanvasRenderingContext2D::getImageData):
624         * loader/cache/CachedImage.cpp:
625         (WebCore::CachedImage::addIncrementalDataBuffer):
626         (WebCore::CachedImage::finishLoading):
627         * loader/cache/CachedImage.h:
628         * page/Settings.in:
629
630 2014-04-02  Martin Hock  <mhock@apple.com>
631
632         Unify private browsing with sessions.
633         https://bugs.webkit.org/show_bug.cgi?id=130099
634
635         Reviewed by Alexey Proskuryakov.
636
637         Unless otherwise noted, the following consists solely of mechanical changes to replace querying WebCore::Settings::privateBrowsingEnabled() with Page::usesEphemeralSession().
638
639         * Modules/webdatabase/DatabaseContext.cpp:
640         (WebCore::DatabaseContext::allowDatabaseAccess):
641         * WebCore.exp.in: Remove Settings::setPrivateBrowsingEnabled, add Page::legacyPrivateBrowsingEnabled.
642         * html/HTMLMediaElement.cpp:
643         (WebCore::HTMLMediaElement::parseAttribute):
644         * loader/HistoryController.cpp:
645         (WebCore::HistoryController::updateForStandardLoad):
646         (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
647         (WebCore::HistoryController::updateForClientRedirect):
648         (WebCore::HistoryController::updateForSameDocumentNavigation):
649         (WebCore::HistoryController::pushState):
650         (WebCore::HistoryController::replaceState):
651         * loader/appcache/ApplicationCacheGroup.cpp:
652         (WebCore::ApplicationCacheGroup::cacheForMainRequest):
653         (WebCore::ApplicationCacheGroup::selectCache):
654         (WebCore::ApplicationCacheGroup::selectCacheWithoutManifestURL):
655         (WebCore::ApplicationCacheGroup::update):
656         * loader/appcache/ApplicationCacheHost.cpp:
657         (WebCore::ApplicationCacheHost::isApplicationCacheEnabled):
658         * loader/icon/IconController.cpp:
659         (WebCore::IconController::continueLoadWithDecision):
660         * page/Page.cpp:
661         (WebCore::Page::Page): Initialize with defaultSessionID.
662         (WebCore::Page::legacyPrivateBrowsingEnabled): Legacy setting for private browsing.
663         (WebCore::Page::privateBrowsingStateChanged): Move implementation to setSessionID.
664         (WebCore::Page::sessionID): Simplify to just return m_sessionID.
665         (WebCore::Page::setSessionID): Also perform privateBrowsingStateChanged action.a
666         (WebCore::Page::privateBrowsingStateChanged): Deleted.
667         (WebCore::Page::checkSubframeCountConsistency): Deleted.
668         * page/Page.h:
669         * page/PageConsole.cpp:
670         (WebCore::PageConsole::addMessage):
671         (WebCore::PageConsole::messageWithTypeAndLevel):
672         * page/Settings.cpp: Remove privateBrowsingEnabled setting.
673         (WebCore::Settings::Settings):
674         (WebCore::Settings::setPrivateBrowsingEnabled): Page reflects setting using session.
675         * page/Settings.h:
676         * plugins/PluginView.cpp:
677         (WebCore::PluginView::getValue):
678         * rendering/RenderSearchField.cpp:
679         (WebCore::RenderSearchField::addSearchResult):
680         * storage/Storage.cpp:
681         (WebCore::Storage::isDisabledByPrivateBrowsing):
682
683 2014-04-02  Antti Koivisto  <antti@apple.com>
684
685         Try to fix test failures.
686
687         * platform/graphics/ca/mac/TileGrid.mm:
688         (WebCore::TileGrid::TileGrid):  Initialize a field.
689
690 2014-04-02  Timothy Hatcher  <timothy@apple.com>
691
692         Remove Input domain from the Web Inspector protocol.
693
694         https://bugs.webkit.org/show_bug.cgi?id=131073
695
696         Reviewed by Joseph Pecoraro.
697
698         * CMakeLists.txt:
699         * DerivedSources.make:
700         * WebCore.vcxproj/WebCore.vcxproj:
701         * WebCore.vcxproj/WebCore.vcxproj.filters:
702         * WebCore.xcodeproj/project.pbxproj:
703         * inspector/InspectorAllInOne.cpp:
704         * inspector/InspectorController.cpp:
705         (WebCore::InspectorController::InspectorController):
706         * inspector/InspectorInputAgent.cpp: Removed.
707         * inspector/InspectorInputAgent.h: Removed.
708         * inspector/protocol/Input.json: Removed.
709
710 2014-04-02  Antti Koivisto  <antti@apple.com>
711
712         Split tile grid out from TileController
713         https://bugs.webkit.org/show_bug.cgi?id=131102
714
715         Reviewed by Simon Fraser.
716
717         Add a TileGrid class that encapsulates tiles, zoom level and the related metadata.
718         This will make it possible to have multiple grids per TileController later.
719
720 2014-03-31  Brent Fulgham  <bfulgham@apple.com>
721
722         [Win] Correct media controls for test harness
723         https://bugs.webkit.org/show_bug.cgi?id=131008 
724
725         Reviewed by Eric Carlson.
726
727         * rendering/RenderThemeSafari.cpp: Revise to match RenderThemeWin logic.
728         (WebCore::RenderThemeSafari::systemFont):
729         (WebCore::RenderThemeSafari::paintMenuList):
730         (WebCore::RenderThemeSafari::paintSearchFieldResultsButton):
731         (WebCore::RenderThemeSafari::mediaControlsStyleSheet):
732         (WebCore::RenderThemeSafari::mediaControlsScript):
733         (WebCore::RenderThemeSafari::paintMediaFullscreenButton): Deleted.
734         (WebCore::RenderThemeSafari::paintMediaMuteButton): Deleted.
735         (WebCore::RenderThemeSafari::paintMediaPlayButton): Deleted.
736         (WebCore::RenderThemeSafari::paintMediaSeekBackButton): Deleted.
737         (WebCore::RenderThemeSafari::paintMediaSeekForwardButton): Deleted.
738         (WebCore::RenderThemeSafari::paintMediaSliderTrack): Deleted.
739         (WebCore::RenderThemeSafari::paintMediaSliderThumb): Deleted.
740         * rendering/RenderThemeSafari.h:
741
742 2014-04-02  peavo@outlook.com  <peavo@outlook.com>
743
744         [WinCairo] Compile error.
745         https://bugs.webkit.org/show_bug.cgi?id=131110
746
747         Reviewed by Simon Fraser.
748
749         Image::size() now returns a FloatSize instead of an IntSize.
750
751         * platform/win/DragImageCairoWin.cpp:
752         (WebCore::createDragImageFromImage):
753
754 2014-04-02  David Kilzer  <ddkilzer@apple.com>
755
756         Use outermost containing isolate when constructing bidi runs
757         <http://webkit.org/b/131107>
758         <rdar://problem/15690021>
759
760         Reviewed by Darin Adler.
761
762         Merged from Blink (patch by jww@chromium.org):
763         https://src.chromium.org/viewvc/blink?revision=157268&view=revision
764         http://crbug.com/279277
765
766             Update containingIsolate to go back all the way to top
767             isolate from current root, rather than stopping at the first
768             isolate it finds. This works because the current root is
769             always updated with each isolate run.
770
771         Tests: fast/text/international/unicode-bidi-isolate-nested-with-removes-not-adjacent.html
772                fast/text/international/unicode-bidi-isolate-nested-with-removes.html
773
774         * rendering/InlineIterator.h:
775         (WebCore::highestContainingIsolateWithinRoot):
776         * rendering/RenderBlockLineLayout.cpp:
777         (WebCore::constructBidiRunsForSegment):
778
779 2014-04-02  Chris Fleizach  <cfleizach@apple.com>
780
781         AX: Improve ARIA live region reliability by sending notifications when live regions are created/shown and hidden/destroyed
782         https://bugs.webkit.org/show_bug.cgi?id=124381
783
784         Reviewed by Mario Sanchez Prada.
785
786         Re-organize some code so that when we detect a new node has been created, we can safely determine its live region status.
787         If it is a live region, we fire off a live region created notification.
788
789         Test: platform/mac/accessibility/live-region-creation-notification.html
790
791         * accessibility/AXObjectCache.cpp:
792         (WebCore::AXObjectCache::handleLiveRegionCreated):
793         (WebCore::AXObjectCache::childrenChanged):
794         (WebCore::AXObjectCache::handleAttributeChanged):
795         * accessibility/AXObjectCache.h:
796         (WebCore::AXObjectCache::childrenChanged):
797         * accessibility/AccessibilityObject.cpp:
798         (WebCore::AccessibilityObject::defaultLiveRegionStatusForRole):
799         (WebCore::AccessibilityObject::liveRegionStatusIsEnabled):
800         (WebCore::AccessibilityObject::supportsARIALiveRegion):
801         * accessibility/AccessibilityObject.h:
802         (WebCore::AccessibilityObject::ariaLiveRegionStatus):
803         * accessibility/AccessibilityRenderObject.cpp:
804         (WebCore::AccessibilityRenderObject::ariaLiveRegionStatus):
805         * accessibility/AccessibilityRenderObject.h:
806         * accessibility/ios/AXObjectCacheIOS.mm:
807         (WebCore::AXObjectCache::postPlatformNotification):
808         * accessibility/ios/WebAccessibilityObjectWrapperIOS.h:
809         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
810         (-[WebAccessibilityObjectWrapper postLiveRegionCreatedNotification]):
811         * accessibility/mac/AXObjectCacheMac.mm:
812         (WebCore::AXObjectCache::postPlatformNotification):
813
814 2014-04-02  Martin Robinson  <mrobinson@igalia.com>
815
816         REGRESSION(r165704): [GTK] Inspector resources not correctly generated
817         https://bugs.webkit.org/show_bug.cgi?id=130343
818
819         Reviewed by Gustavo Noronha Silva.
820
821         * CMakeLists.txt: Generate the web inspector JS file into the new WebInspectorUI derived sources
822         directory.
823
824 2014-04-02  Zalan Bujtas  <zalan@apple.com>
825
826         Unreviewed build fix after r166642.
827         (WinCairo should really turn subpixel layout on.)
828
829         * platform/graphics/LayoutSize.h:
830         (WebCore::flooredForPainting):
831
832 2014-04-02  Zalan Bujtas  <zalan@apple.com>
833
834         Subpixel rendering: Make GraphicsContext::drawTiledImage* functions float based.
835         https://bugs.webkit.org/show_bug.cgi?id=131062
836
837         Reviewed by Simon Fraser.
838
839         This is in preparation to support subpixel positioned/sized background images. Generated images
840         need to be able to sized on device pixels.
841
842         No change in behavior.
843
844         * platform/graphics/GraphicsContext.cpp:
845         (WebCore::GraphicsContext::drawImage):
846         (WebCore::GraphicsContext::drawTiledImage):
847         * platform/graphics/GraphicsContext.h:
848
849 2014-04-02  Alex Christensen  <achristensen@webkit.org>
850
851         [WinCairo] Build fix after r166496.
852         https://bugs.webkit.org/show_bug.cgi?id=131006
853
854         Reviewed by Carlos Garcia Campos.
855
856         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
857         (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
858         (WebCore::InbandTextTrackPrivateGStreamer::streamChanged):
859         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
860         (WebCore::MediaPlayerPrivateGStreamer::changePipelineState):
861         (WebCore::MediaPlayerPrivateGStreamer::videoChanged):
862         (WebCore::MediaPlayerPrivateGStreamer::videoCapsChanged):
863         (WebCore::MediaPlayerPrivateGStreamer::audioChanged):
864         (WebCore::MediaPlayerPrivateGStreamer::textChanged):
865         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
866         (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
867         (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
868         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
869         (WebCore::TrackPrivateBaseGStreamer::activeChanged):
870         (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
871         * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
872         (webkitVideoSinkRender):
873         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
874         (webKitWebSrcChangeState):
875         (webKitWebSrcNeedDataCb):
876         (webKitWebSrcEnoughDataCb):
877         (webKitWebSrcSeekDataCb):
878         Added std::function<void()> constructors to help Visual Studio decide which version of 
879         GMainLoopSource::schedule or GMainLoopSource::scheduleAfterDelay to use.
880
881 2014-04-02  Zalan Bujtas  <zalan@apple.com>
882
883         Subpixel rendering: Transition class CSSImageGeneratorValue/class StyleImage (and its dependencies) from 
884         IntSize to FloatSize to enable subpixel sized (generated)images.
885         https://bugs.webkit.org/show_bug.cgi?id=130659
886
887         Reviewed by Simon Fraser and Andreas Kling.
888
889         This is in preparation to support subpixel positioned/sized background images. Generated images
890         needs to be able to sized on device pixels.
891
892         No change in behavior.
893
894         * WebCore.vcxproj/WebCore.vcxproj:
895         * WebCore.vcxproj/WebCore.vcxproj.filters:
896         * WebCore.xcodeproj/project.pbxproj:
897         * css/CSSCanvasValue.cpp:
898         (WebCore::CSSCanvasValue::fixedSize):
899         (WebCore::CSSCanvasValue::image):
900         * css/CSSCanvasValue.h:
901         * css/CSSCrossfadeValue.cpp:
902         (WebCore::CSSCrossfadeValue::fixedSize):
903         (WebCore::CSSCrossfadeValue::image):
904         * css/CSSCrossfadeValue.h:
905         * css/CSSFilterImageValue.cpp:
906         (WebCore::CSSFilterImageValue::fixedSize):
907         (WebCore::CSSFilterImageValue::image):
908         * css/CSSFilterImageValue.h:
909         * css/CSSGradientValue.cpp:
910         (WebCore::CSSGradientValue::image):
911         (WebCore::positionFromValue):
912         (WebCore::CSSGradientValue::computeEndPoint):
913         (WebCore::endPointsFromAngle):
914         (WebCore::CSSLinearGradientValue::createGradient):
915         (WebCore::CSSRadialGradientValue::createGradient):
916         * css/CSSGradientValue.h:
917         (WebCore::CSSGradientValue::fixedSize):
918         * css/CSSImageGeneratorValue.cpp:
919         (WebCore::CSSImageGeneratorValue::cachedImageForSize):
920         (WebCore::CSSImageGeneratorValue::saveCachedImageForSize):
921         (WebCore::CSSImageGeneratorValue::evictCachedGeneratedImage):
922         (WebCore::CSSImageGeneratorValue::CachedGeneratedImage::CachedGeneratedImage):
923         (WebCore::CSSImageGeneratorValue::image):
924         (WebCore::CSSImageGeneratorValue::fixedSize):
925         * css/CSSImageGeneratorValue.h:
926         * loader/cache/CachedImage.cpp:
927         (WebCore::CachedImage::setContainerSizeForRenderer):
928         * loader/cache/CachedImage.h:
929         * platform/graphics/FloatSizeHash.h: Added.
930         (WTF::FloatHash<WebCore::FloatSize>::hash):
931         (WTF::FloatHash<WebCore::FloatSize>::equal):
932         (WTF::HashTraits<WebCore::FloatSize>::constructDeletedValue):
933         (WTF::HashTraits<WebCore::FloatSize>::isDeletedValue):
934         * platform/graphics/LayoutSize.h:
935         (WebCore::flooredForPainting):
936         * rendering/RenderImageResourceStyleImage.h:
937         * rendering/RenderListMarker.cpp:
938         (WebCore::RenderListMarker::computePreferredLogicalWidths):
939         * rendering/style/StyleCachedImage.cpp:
940         (WebCore::StyleCachedImage::imageSize):
941         (WebCore::StyleCachedImage::setContainerSizeForRenderer):
942         (WebCore::StyleCachedImage::image):
943         * rendering/style/StyleCachedImage.h:
944         * rendering/style/StyleCachedImageSet.cpp:
945         (WebCore::StyleCachedImageSet::imageSize):
946         (WebCore::StyleCachedImageSet::setContainerSizeForRenderer):
947         (WebCore::StyleCachedImageSet::image):
948         * rendering/style/StyleCachedImageSet.h:
949         * rendering/style/StyleGeneratedImage.cpp:
950         (WebCore::StyleGeneratedImage::imageSize):
951         (WebCore::StyleGeneratedImage::computeIntrinsicDimensions):
952         (WebCore::StyleGeneratedImage::image):
953         * rendering/style/StyleGeneratedImage.h:
954         * rendering/style/StyleImage.h:
955         * rendering/style/StylePendingImage.h:
956         * svg/graphics/SVGImageCache.cpp:
957         (WebCore::SVGImageCache::setContainerSizeForRenderer):
958         * svg/graphics/SVGImageCache.h:
959
960 2014-04-02  Gergo Balogh  <gbalogh.u-szeged@partner.samsung.com>
961
962         Warning fix for RenderLayer.
963         https://bugs.webkit.org/show_bug.cgi?id=131090
964
965         Reviewed by Csaba Osztrogonác.
966
967         * rendering/RenderLayer.cpp:
968         (WebCore::RenderLayer::updateDescendantDependentFlags):
969
970 2014-04-02  Frédéric Wang  <fred.wang@free.fr>
971
972         Operator stretching: read the Open Type MATH table
973         https://bugs.webkit.org/show_bug.cgi?id=130324
974
975         Reviewed by Chris Fleizach.
976
977         We parse and expose some data from the OpenType MATH table that will be
978         be relevant for at least the MathML operator stretching (bug 130322):
979         math constants, italic corrections and size variants / glyph assembly.
980         This will be tested when the MathML code uses the data.
981
982         * WebCore.xcodeproj/project.pbxproj: Add OpenTypeTypes.h to the Mac build.
983         * platform/graphics/opentype/OpenTypeMathData.cpp: We implement the low-level parsing of the MATH table.
984         (WebCore::OpenType::MathItalicsCorrectionInfo::getItalicCorrection):
985         (WebCore::OpenType::MathGlyphInfo::mathItalicsCorrectionInfo):
986         (WebCore::OpenType::GlyphAssembly::getAssemblyParts):
987         (WebCore::OpenType::MathGlyphConstruction::getSizeVariants):
988         (WebCore::OpenType::MathGlyphConstruction::getAssemblyParts):
989         (WebCore::OpenType::MathVariants::mathGlyphConstruction):
990         (WebCore::OpenType::MATHTable::mathConstants):
991         (WebCore::OpenType::MATHTable::mathGlyphInfo):
992         (WebCore::OpenType::MATHTable::mathVariants):
993         (WebCore::OpenTypeMathData::OpenTypeMathData): We load the MATH table.
994         (WebCore::OpenTypeMathData::getMathConstant): We add a function to get values from the MathConstant subtable.
995         (WebCore::OpenTypeMathData::getItalicCorrection): We add a function to get italic correction from the MathGlyphInfo subtable.
996         (WebCore::OpenTypeMathData::getMathVariants): We add a function to get size variants / glyph assembly from the MathVariants subtable.
997         * platform/graphics/opentype/OpenTypeMathData.h: We expose three new functions to get math data.
998         * platform/graphics/opentype/OpenTypeTypes.h: We share the coverage tables that are common to vertical and math data.
999         (WebCore::OpenType::TableWithCoverage::getCoverageIndex): We add a function to get the coverage index from a given glyph.
1000         * platform/graphics/opentype/OpenTypeVerticalData.cpp: We move the coverage tables to OpenTypeTypes.h.
1001
1002 2014-04-02  Ion Rosca  <rosca@adobe.com>
1003
1004         [CSS Blending] Compositing requirements for blending are not computed correctly
1005         https://bugs.webkit.org/show_bug.cgi?id=130664
1006
1007         Reviewed by Dean Jackson.
1008
1009         Tests: css3/compositing/blend-mode-accelerated-with-multiple-stacking-contexts.html
1010                css3/compositing/blend-mode-with-accelerated-sibling.html
1011
1012         Compositing requirements for blending: if a layer having blend mode
1013         other than normal is composited for any reason, its closest stacking
1014         context ancestor should be composited as well.
1015
1016         * rendering/RenderLayer.cpp:
1017         (WebCore::RenderLayer::RenderLayer):
1018         * rendering/RenderLayer.h: added a new field,
1019         m_hasUnisolatedCompositedBlendingDescendants, which is true if the layer
1020         has composited blending descendants not isolated by any stacking context child;
1021         added a new method: isolatesCompositedBlending(), which is true if we should
1022         accelerate that layer in order to perform isolation correctly.
1023
1024         * rendering/RenderLayerCompositor.cpp:
1025         (WebCore::CompositingState::CompositingState): m_subtreeHasBlending was renamed
1026         m_hasUnisolatedCompositedBlendingDescendants in order to be more self-explanatory.
1027         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
1028         computes the isolation requirements for composited blending by
1029         (re)setting RenderLayer::m_hasUnisolatedCompositedBlendingDescendants flag.
1030
1031         (WebCore::RenderLayerCompositor::reasonsForCompositing):
1032         fixed the reason of compositing: isolation instead of blending.
1033
1034         (WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason):
1035         * rendering/RenderLayerCompositor.h:
1036
1037 2014-04-02  Frédéric Wang  <fred.wang@free.fr>
1038
1039         Operator stretching: expose a math data API
1040         https://bugs.webkit.org/show_bug.cgi?id=130572
1041
1042         Reviewed by Chris Fleizach.
1043
1044         We expose a new SimpleFontData API to give access to the data from the
1045         OpenType MATH table. The class OpenTypeMathData will
1046         be implemented in bug 130324. On Darwin platform, we also implement the
1047         missing FontPlatformData::openTypeTable function which will be necessary
1048         to load the OpenType MATH table. The changes are intended to be used
1049         for MathML operator stretching (bug 130322) so tests are not added yet.
1050
1051         * CMakeLists.txt: add new OpenTypeMathData files.
1052         * WebCore.vcxproj/WebCore.vcxproj: ditto.
1053         * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
1054         * WebCore.xcodeproj/project.pbxproj: ditto.
1055         * platform/graphics/FontPlatformData.cpp:
1056         (WebCore::FontPlatformData::openTypeTable): We implement openTypeTable() on Darwin platform.
1057         * platform/graphics/FontPlatformData.h: We expose openTypeTable() on Darwin platform.
1058         * platform/graphics/SimpleFontData.cpp:
1059         (WebCore::SimpleFontData::SimpleFontData):
1060         (WebCore::SimpleFontData::mathData): Initialize and return the math data.
1061         * platform/graphics/SimpleFontData.h: We expose a mathData() function to access the MATH data.
1062         * platform/graphics/opentype/OpenTypeMathData.cpp: Added. This is a new class that will be used to parse the data from the OpenType MATH table.
1063         (WebCore::OpenTypeMathData::OpenTypeMathData):
1064         * platform/graphics/opentype/OpenTypeMathData.h: Added.
1065         (WebCore::OpenTypeMathData::create):
1066         (WebCore::OpenTypeMathData::hasMathData):
1067
1068 2014-04-01  Mihnea Ovidenie  <mihnea@adobe.com>
1069
1070         [CSSRegions] Displaying region's children in another region not supported
1071         https://bugs.webkit.org/show_bug.cgi?id=130735
1072
1073         Reviewed by David Hyatt.
1074
1075         With http://trac.webkit.org/changeset/166353, we disabled the possibility
1076         of collecting the region's children into another flow and displaying them
1077         in another region.
1078         I added a new test for this and also changed the plain ASSERT in Element dtor
1079         to ASSERT_WITH_SECURITY_IMPLICATION to better reflect the meaning of the assertion.
1080
1081         Test: fast/regions/region-child-not-flowed.html
1082
1083         * dom/Element.cpp:
1084         (WebCore::Element::~Element):
1085
1086 2014-04-01  Andrei Bucur  <abucur@adobe.com>
1087
1088         [CSS Regions] Simplify the RenderFlowThread state pusher
1089         https://bugs.webkit.org/show_bug.cgi?id=131035
1090
1091         Reviewed by David Hyatt.
1092
1093         The RenderFlowThread state pusher is desynchronized from the RenderView layout state pusher
1094         by one renderer. This patch fixes the anomaly by correctly ordering the push and pop operations
1095         between the two systems.
1096
1097         Tests: no functional change, no new tests.
1098
1099         * rendering/RenderFlowThread.cpp:
1100         (WebCore::RenderFlowThread::pushFlowThreadLayoutState):
1101         (WebCore::RenderFlowThread::popFlowThreadLayoutState):
1102         (WebCore::RenderFlowThread::offsetFromLogicalTopOfFirstRegion):
1103         * rendering/RenderView.cpp:
1104         (WebCore::RenderView::pushLayoutState):
1105         * rendering/RenderView.h:
1106
1107 2014-04-01  Beth Dakin  <bdakin@apple.com>
1108
1109         willReveal edge events should be hooked up for overflow:scroll
1110         https://bugs.webkit.org/show_bug.cgi?id=131071
1111         -and corresponding-
1112         <rdar://problem/16190392>
1113
1114         Reviewed by Sam Weinig.
1115
1116         This patch moves the will reveal logic from FrameView to Document so that it can 
1117         be shared for RenderLayers.
1118
1119         This is mostly just a moved function, but now the function takes an Element* that 
1120         represents the target of the event if the target is not the window.
1121         * dom/Document.cpp:
1122         (WebCore::Document::sendWillRevealEdgeEventsIfNeeded):
1123         * dom/Document.h:
1124
1125         No longer implement sendWillRevealEdgeEventsIfNeeded() on FrameView or 
1126         ScrollableArea at all. Call into Document instead.
1127         * page/FrameView.cpp:
1128         (WebCore::FrameView::scrollPositionChanged):
1129         (WebCore::FrameView::sendWillRevealEdgeEventsIfNeeded): Deleted.
1130         * page/FrameView.h:
1131         * platform/ScrollableArea.h:
1132         (WebCore::ScrollableArea::sendWillRevealEdgeEventsIfNeeded): Deleted.
1133
1134         Call sendWillRevealEdgeEventsIfNeeded() after sending scroll events. 
1135         * rendering/RenderLayer.cpp:
1136         (WebCore::RenderLayer::scrollTo):
1137
1138 2014-04-01  Jon Honeycutt  <jhoneycutt@apple.com>
1139
1140         Crash in WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients
1141
1142         <https://bugs.webkit.org/show_bug.cgi?id=121887>
1143         <rdar://problem/15073043>
1144
1145         Reviewed by Dean Jackson.
1146
1147         Test: svg/filters/first-letter-crash.html
1148
1149         * rendering/FilterEffectRenderer.cpp:
1150         (WebCore::FilterEffectRenderer::buildReferenceFilter):
1151         Added a null check to prevent crashes for anonymous RenderObjects.
1152
1153         * rendering/RenderLayer.cpp:
1154         (WebCore::RenderLayer::filterNeedsRepaint):
1155         Get the enclosing element, if there is one, and recalculate its style.
1156         We use the enclosing element so that we recalculate style for the
1157         ancestor of an anonymous RenderElement.
1158         (WebCore::RenderLayer::enclosingElement):
1159         Remove an assertion; we may now reach this condition if loading a
1160         cached SVG document results in RenderLayer::filterNeedsRepaint() being
1161         called before the object has been inserted into the render tree.
1162
1163         * rendering/RenderLayerFilterInfo.cpp:
1164         (WebCore::RenderLayer::FilterInfo::notifyFinished):
1165         Tell the RenderLayer that the filter needs repainting.
1166         (WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients):
1167         Get the Element from the renderer rather than asking the renderer's
1168         Element, which will be null for anonymous RenderObjects.
1169
1170         * rendering/RenderLayerFilterInfo.h:
1171         Removed declaration for the old workaround function, layerElement().
1172
1173 2014-04-01  Ryuan Choi  <ryuan.choi@samsung.com>
1174
1175         Build break when disabled VIDEO since r166261
1176         https://bugs.webkit.org/show_bug.cgi?id=131087
1177
1178         Reviewed by Gyuyoung Kim.
1179
1180         * testing/Internals.cpp: Added ENABLE(VIDEO) guards
1181         (WebCore::Internals::simulateSystemSleep):
1182         (WebCore::Internals::simulateSystemWake):
1183
1184 2014-04-01  Timothy Hatcher  <timothy@apple.com>
1185
1186         Remove HeapProfiler from the Web Inspector protocol.
1187
1188         https://bugs.webkit.org/show_bug.cgi?id=131070
1189
1190         Reviewed by Joseph Pecoraro.
1191
1192         * CMakeLists.txt:
1193         * DerivedSources.make:
1194         * WebCore.vcxproj/WebCore.vcxproj:
1195         * WebCore.vcxproj/WebCore.vcxproj.filters:
1196         * WebCore.xcodeproj/project.pbxproj:
1197         * bindings/js/ScriptHeapSnapshot.h: Removed.
1198         * bindings/js/ScriptProfiler.h:
1199         (WebCore::ScriptProfiler::takeHeapSnapshot): Deleted.
1200         (WebCore::ScriptProfiler::isSampling): Deleted.
1201         (WebCore::ScriptProfiler::hasHeapProfiler): Deleted.
1202         * inspector/InspectorAllInOne.cpp:
1203         * inspector/InspectorController.cpp:
1204         (WebCore::InspectorController::InspectorController):
1205         * inspector/InspectorHeapProfilerAgent.cpp: Removed.
1206         * inspector/InspectorHeapProfilerAgent.h: Removed.
1207         * inspector/InspectorInstrumentation.cpp:
1208         (WebCore::InspectorInstrumentation::didCommitLoadImpl):
1209         * inspector/InspectorProfilerAgent.cpp:
1210         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
1211         (WebCore::InspectorProfilerAgent::getProfileHeaders):
1212         (WebCore::InspectorProfilerAgent::removeProfile):
1213         (WebCore::InspectorProfilerAgent::resetState): The CommandLineAPIHost call to
1214         clear inspected objects should have not been here. It was only needed by the
1215         HeapProfilerAgent.
1216         (WebCore::InspectorProfilerAgent::resetFrontendProfiles):
1217         (WebCore::InspectorProfilerAgent::collectGarbage): Deleted.
1218         (WebCore::InspectorProfilerAgent::createSnapshotHeader): Deleted.
1219         (WebCore::InspectorProfilerAgent::isSampling): Deleted.
1220         (WebCore::InspectorProfilerAgent::hasHeapProfiler): Deleted.
1221         (WebCore::InspectorProfilerAgent::getHeapSnapshot): Deleted.
1222         (WebCore::InspectorProfilerAgent::takeHeapSnapshot): Deleted.
1223         (WebCore::InspectorProfilerAgent::getObjectByHeapObjectId): Deleted.
1224         (WebCore::InspectorProfilerAgent::getHeapObjectId): Deleted.
1225         * inspector/InspectorProfilerAgent.h:
1226         * inspector/InstrumentingAgents.h:
1227         (WebCore::InstrumentingAgents::inspectorHeapProfilerAgent): Deleted.
1228         (WebCore::InstrumentingAgents::setInspectorHeapProfilerAgent): Deleted.
1229         * inspector/WebConsoleAgent.cpp:
1230         (WebCore::WebConsoleAgent::addInspectedHeapObject): Deleted.
1231         * inspector/WebConsoleAgent.h:
1232         * inspector/WorkerInspectorController.cpp:
1233         (WebCore::WorkerInspectorController::WorkerInspectorController):
1234         * inspector/protocol/HeapProfiler.json: Removed.
1235         * inspector/protocol/Profiler.json:
1236
1237 2014-04-01  Zoltan Horvath  <zoltan@webkit.org>
1238
1239         [CSS Exclusions] Remove exclusions parsing support
1240         https://bugs.webkit.org/show_bug.cgi?id=131046
1241
1242         Reviewed by David Hyatt.
1243
1244         CSS Exclusions specification [1] needs some evolution before the actual implementation happens.
1245         We have only the parsing code in WebKit for -webkit-wrap-flow and -webkit-wrap-through.
1246         This patch removes the code from the trunk for now, it doesn't make sense to keep it around.
1247
1248         [1] http://www.w3.org/TR/css3-exclusions/
1249
1250         Removed existing parsing tests.
1251
1252         * css/CSSComputedStyleDeclaration.cpp:
1253         (WebCore::ComputedStyleExtractor::propertyValue):
1254         * css/CSSParser.cpp:
1255         (WebCore::isValidKeywordPropertyAndValue):
1256         (WebCore::isKeywordPropertyID):
1257         (WebCore::CSSParser::parseValue):
1258         * css/CSSPrimitiveValueMappings.h:
1259         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Deleted.
1260         (WebCore::CSSPrimitiveValue::operator WrapFlow): Deleted.
1261         (WebCore::CSSPrimitiveValue::operator WrapThrough): Deleted.
1262         * css/CSSPropertyNames.in:
1263         * css/CSSValueKeywords.in:
1264         * css/DeprecatedStyleBuilder.cpp:
1265         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
1266         * css/StyleResolver.cpp:
1267         (WebCore::StyleResolver::applyProperty):
1268         * rendering/style/RenderStyle.cpp:
1269         (WebCore::RenderStyle::changeRequiresLayout):
1270         * rendering/style/RenderStyle.h:
1271         * rendering/style/RenderStyleConstants.h:
1272         * rendering/style/StyleRareNonInheritedData.cpp:
1273         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1274         (WebCore::StyleRareNonInheritedData::operator==):
1275         * rendering/style/StyleRareNonInheritedData.h:
1276
1277 2014-04-01  Timothy Hatcher  <timothy@apple.com>
1278
1279         Remove the rest of the old Canvas inspection support.
1280
1281         https://bugs.webkit.org/show_bug.cgi?id=131066
1282
1283         Reviewed by Joseph Pecoraro.
1284
1285         * CMakeLists.txt: Removed Canvas.json.
1286         * DerivedSources.make: Ditto.
1287         * inspector/InjectedScriptCanvasModuleSource.js: Removed.
1288         * inspector/protocol/Canvas.json: Removed.
1289
1290 2014-04-01  Alexey Proskuryakov  <ap@apple.com>
1291
1292         Eliminate HTMLFormElement::m_shouldSubmit
1293         https://bugs.webkit.org/show_bug.cgi?id=131055
1294
1295         Reviewed by Tim Horton.
1296
1297         m_shouldSubmit was used for two purposes:
1298         - as a return value in a function whose return value is ignored by all callers;
1299         - to make a decision that's local to a function.
1300
1301         There is no need for it to be an instance variable.
1302
1303         * html/HTMLFormElement.cpp:
1304         (WebCore::HTMLFormElement::HTMLFormElement):
1305         (WebCore::HTMLFormElement::prepareForSubmission):
1306         (WebCore::HTMLFormElement::submit):
1307         * html/HTMLFormElement.h:
1308
1309 2014-04-01  Benjamin Poulain  <bpoulain@apple.com>
1310
1311         Remove a couple of useless static strings
1312         https://bugs.webkit.org/show_bug.cgi?id=131003
1313
1314         Reviewed by David Kilzer.
1315
1316         There is zero value in keeping those strings alive.
1317
1318         * css/StyleProperties.cpp:
1319         (WebCore::isInitialOrInherit):
1320
1321 2014-04-01  Myles C. Maxfield  <mmaxfield@apple.com>
1322
1323         svg/text/text-overflow-ellipsis-svgfont-kerning-ligatures.html and svg/css/font-face-crash.html frequently assert in ComplexTextController::offsetForPosition
1324         https://bugs.webkit.org/show_bug.cgi?id=119747
1325
1326         Reviewed by Simon Fraser.
1327
1328         Even though kerning and ligatures currently don't work with the
1329         simple text path, messing those up is better than creating null
1330         CTRun and CTLine objects.
1331
1332         Rather than calling the badly-named renderingContext() function on TextRun objects
1333         to determine if they are drawn with an SVG font, this patch creates a wrapper function
1334         with a better name and uses that instead.
1335
1336         Test: svg/text/svg-font-hittest.html
1337
1338         * platform/graphics/Font.cpp:
1339         (WebCore::isDrawnWithSVGFont): Wrapper around renderingContext()
1340         (WebCore::Font::drawText): Use wrapper function
1341         (WebCore::Font::drawEmphasisMarks): Use wrapper function
1342         (WebCore::Font::width): Use wrapper function
1343         (WebCore::Font::selectionRectForText): Use wrapper function
1344         (WebCore::Font::offsetForPosition): If we are using an SVG font, use the simple path
1345         instead of the complex one
1346         (WebCore::Font::codePath): Use wrapper function
1347         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
1348         (WebCore::FontPlatformData::ctFont):
1349
1350 2014-04-01  Daniel Bates  <dabates@apple.com>
1351
1352         RenderQuote must destroy remaining text renderer before first letter renderer
1353         https://bugs.webkit.org/show_bug.cgi?id=78023
1354         <rdar://problem/10830009>
1355
1356         Reviewed by Brent Fulgham.
1357
1358         Merged from Blink (patch by Abhishek Arya):
1359         https://src.chromium.org/viewvc/blink?view=rev&revision=151270
1360
1361         Following the fix for <https://bugs.webkit.org/show_bug.cgi?id=114586>, a
1362         RenderQuote may have child render objects for the first letter of its text
1363         and everything following the first letter so as to support the CSS first-
1364         letter property. The latter renderer is responsible for destroying the former
1365         on destruction. It's sufficient to reverse the destruction of the children of
1366         RenderQuote to ensure that we destroy the remaining text renderer before we
1367         destroy the first letter renderer.
1368
1369         Test: fast/css-generated-content/quote-first-letter-crash.html
1370
1371         * rendering/RenderQuote.cpp:
1372         (WebCore::RenderQuote::updateText):
1373
1374 2014-04-01  David Kilzer  <ddkilzer@apple.com>
1375
1376         Do not allow HTTP refresh headers to refresh to javascript: URLs
1377         <http://webkit.org/b/119051>
1378         <rdar://problem/14536453>
1379
1380         Reviewed by Alexey Proskuryakov.
1381
1382         Merged from Blink (patch by tsepez@chromium.org):
1383         https://src.chromium.org/viewvc/blink?revision=153912&view=revision
1384         http://crbug.com/258151
1385
1386             This behaviour has been standard in IE since IE7.  This makes us both
1387             more compatible and less vulnerable to XSS.
1388
1389         Tests: http/tests/security/no-javascript-location-percent-escaped.html
1390                http/tests/security/no-javascript-location.html
1391                http/tests/security/no-javascript-refresh-percent-escaped.php
1392                http/tests/security/no-javascript-refresh-spaces.php
1393                http/tests/security/no-javascript-refresh-static-percent-escaped.html
1394                http/tests/security/no-javascript-refresh-static-spaces.html
1395                http/tests/security/no-javascript-refresh-static.html
1396                http/tests/security/no-javascript-refresh.php
1397
1398         * dom/Document.cpp:
1399         (WebCore::Document::processHttpEquiv):
1400         * loader/FrameLoader.cpp:
1401         (WebCore::FrameLoader::receivedFirstData):
1402         - Do not fire meta http refresh for a javascript: URL protocol.
1403
1404 2014-04-01  Pratik Solanki  <psolanki@apple.com>
1405
1406         Unreviewed build fix. Remove duplicate file entries.
1407
1408         * WebCore.xcodeproj/project.pbxproj:
1409
1410 2014-03-31  Simon Fraser  <simon.fraser@apple.com>
1411
1412         Enable WEB_TIMING on Mac and iOS
1413         https://bugs.webkit.org/show_bug.cgi?id=128064
1414
1415         Reviewed by Sam Weinig, Brent Fulgham.
1416
1417         Enable WEB_TIMING. Add PerformanceTiming.cpp and JSPerformanceTiming.cpp
1418         to the project.
1419         
1420         * Configurations/FeatureDefines.xcconfig:
1421         * WebCore.xcodeproj/project.pbxproj:
1422
1423 2014-04-01  James Craig  <jcraig@apple.com>
1424
1425         AX: AccessibilityRenderObject::ariaLiveRegionAtomic() should default to true if
1426         roleValue is ApplicationAlertRole || ApplicationStatusRole
1427         https://bugs.webkit.org/show_bug.cgi?id=130907
1428
1429         Reviewed by Chris Fleizach.
1430
1431         Tests: inspector-protocol/dom/getAccessibilityPropertiesForNode_liveRegion.html:
1432                platform/mac/accessibility/aria-liveregions-attributes.html:
1433
1434         Updated AccessibilityRenderObject::ariaLiveRegionAtomic() to match ARIA spec.
1435
1436         * accessibility/AccessibilityRenderObject.cpp:
1437         (WebCore::AccessibilityRenderObject::ariaLiveRegionAtomic):
1438
1439 2014-04-01  Zan Dobersek  <zdobersek@igalia.com>
1440
1441         Unreviewed. Fixing debug builds after r166586.
1442
1443         * svg/SVGElement.cpp:
1444         (WebCore::SVGElement::addEventListener): Fix the ASSERT.
1445         (WebCore::SVGElement::removeEventListener): Ditto.
1446
1447 2014-04-01  Zan Dobersek  <zdobersek@igalia.com>
1448
1449         Prevent unnecessary copies in compareEqual template
1450         https://bugs.webkit.org/show_bug.cgi?id=131014
1451
1452         Reviewed by Antti Koivisto.
1453
1454         * rendering/style/RenderStyle.h:
1455         (compareEqual): Casting the second parameter to a non-const, non-reference type
1456         causes an extra copy of that object. Casting to the const reference type of the
1457         first parameter avoids that.
1458
1459 2014-04-01  Zan Dobersek  <zdobersek@igalia.com>
1460
1461         Avoid unnecessary HashSet copies when calling collectInstancesForSVGElement
1462         https://bugs.webkit.org/show_bug.cgi?id=131020
1463
1464         Reviewed by Andreas Kling.
1465
1466         Remove collectInstancesForSVGElement() to avoid HashSet copies when assigning a const
1467         HashSet reference to a non-const HashSet reference. Instead, range-based for-loops are
1468         deployed to iterate directly over the const reference to HashSet that's returned by
1469         SVGElement::instancesForElement(). SVGElement::containingShadowRoot() return value
1470         is checked to see if the iteration should be performed in the first place, preserving
1471         the behavior of collectInstancesForSVGElement().
1472
1473         * svg/SVGElement.cpp:
1474         (WebCore::SVGElement::addEventListener):
1475         (WebCore::SVGElement::removeEventListener):
1476         (WebCore::collectInstancesForSVGElement): Deleted.
1477
1478 2014-04-01  Zan Dobersek  <zdobersek@igalia.com>
1479
1480         Move the attributes HashMap out of the parseAttributes function
1481         https://bugs.webkit.org/show_bug.cgi?id=131019
1482
1483         Reviewed by Andreas Kling.
1484
1485         * xml/parser/XMLDocumentParserLibxml2.cpp:
1486         (WebCore::parseAttributes): Avoid copying the HashMap object that's being returned by
1487         converting it to an xvalue through using std::move() in the return statement.
1488
1489 2014-04-01  Zalan Bujtas  <zalan@apple.com>
1490
1491         Subpixel rendering: Transition class Image (and its dependencies) from int to float to enable subpixel positioned/sized images.
1492         https://bugs.webkit.org/show_bug.cgi?id=130643
1493
1494         Reviewed by Simon Fraser.
1495
1496         This is in preparation to support subpixel positioned/sized background images. While 1x bitmap images can't take
1497         subpixel sizing on hidpi resolutions, both generated and hidpi images can.
1498         This patch does not change Image behavior in general as both position and size are still snapped to integral values.  
1499
1500         No change in behavior.
1501
1502         * WebCore.exp.in:
1503         * css/CSSCrossfadeValue.cpp:
1504         (WebCore::CSSCrossfadeValue::fixedSize):
1505         * css/CSSFilterImageValue.cpp:
1506         (WebCore::CSSFilterImageValue::fixedSize):
1507         * html/canvas/WebGLRenderingContext.cpp:
1508         (WebCore::WebGLRenderingContext::drawImageIntoBuffer):
1509         * loader/cache/CachedImage.cpp:
1510         (WebCore::CachedImage::imageSizeForRenderer):
1511         * page/EventHandler.cpp:
1512         (WebCore::EventHandler::selectCursor):
1513         * platform/Cursor.cpp:
1514         (WebCore::determineHotSpot):
1515         * platform/graphics/BitmapImage.cpp:
1516         (WebCore::BitmapImage::size):
1517         (WebCore::BitmapImage::currentFrameSize):
1518         * platform/graphics/BitmapImage.h:
1519         * platform/graphics/CrossfadeGeneratedImage.cpp:
1520         (WebCore::CrossfadeGeneratedImage::CrossfadeGeneratedImage):
1521         (WebCore::drawCrossfadeSubimage):
1522         (WebCore::CrossfadeGeneratedImage::drawCrossfade):
1523         * platform/graphics/CrossfadeGeneratedImage.h:
1524         * platform/graphics/GeneratedImage.h:
1525         * platform/graphics/Gradient.cpp:
1526         (WebCore::Gradient::adjustParametersForTiledDrawing):
1527         * platform/graphics/Gradient.h:
1528         * platform/graphics/GradientImage.cpp:
1529         (WebCore::GradientImage::drawPattern):
1530         * platform/graphics/GradientImage.h:
1531         * platform/graphics/GraphicsContext.cpp:
1532         (WebCore::GraphicsContext::createCompatibleBuffer):
1533         * platform/graphics/GraphicsContext.h:
1534         * platform/graphics/Image.cpp:
1535         (WebCore::Image::adjustSourceRectForDownSampling):
1536         * platform/graphics/Image.h:
1537         (WebCore::Image::setContainerSize):
1538         (WebCore::Image::rect):
1539         (WebCore::Image::width):
1540         (WebCore::Image::height):
1541         * platform/graphics/ImageBuffer.cpp:
1542         (WebCore::ImageBuffer::createCompatibleBuffer):
1543         * platform/graphics/ImageBuffer.h:
1544         (WebCore::ImageBuffer::create):
1545         * platform/graphics/IntPoint.cpp:
1546         (WebCore::IntPoint::IntPoint):
1547         * platform/graphics/IntPoint.h:
1548         * platform/graphics/IntSize.cpp:
1549         (WebCore::IntSize::IntSize):
1550         * platform/graphics/IntSize.h:
1551         * platform/graphics/cairo/ImageBufferCairo.cpp:
1552         (WebCore::ImageBuffer::ImageBuffer):
1553         * platform/graphics/cairo/ImageCairo.cpp:
1554         (WebCore::Image::drawPattern):
1555         * platform/graphics/cg/ImageBufferCG.cpp:
1556         (WebCore::ImageBuffer::ImageBuffer):
1557         * platform/graphics/cg/ImageBufferDataCG.cpp:
1558         * platform/graphics/cg/PDFDocumentImage.cpp:
1559         (WebCore::PDFDocumentImage::size):
1560         (WebCore::PDFDocumentImage::updateCachedImageIfNeeded):
1561         (WebCore::applyRotationForPainting):
1562         * platform/graphics/cg/PDFDocumentImage.h:
1563         * platform/graphics/cg/PatternCG.cpp:
1564         (WebCore::Pattern::createPlatformPattern):
1565         * platform/graphics/mac/GraphicsContextMac.mm:
1566         * platform/graphics/mac/IconMac.mm:
1567         * platform/graphics/texmap/TextureMapperTiledBackingStore.cpp:
1568         (WebCore::TextureMapperTiledBackingStore::updateContentsFromImageIfNeeded):
1569         * platform/graphics/texmap/coordinated/CoordinatedImageBacking.cpp:
1570         (WebCore::CoordinatedImageBacking::update):
1571         * platform/graphics/win/ImageCGWin.cpp:
1572         (WebCore::BitmapImage::getHBITMAPOfSize):
1573         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
1574         * platform/graphics/win/ImageCairoWin.cpp:
1575         (WebCore::BitmapImage::getHBITMAPOfSize):
1576         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
1577         * platform/mac/DragImageMac.mm:
1578         (WebCore::createDragImageFromImage):
1579         * platform/win/DragImageCGWin.cpp:
1580         (WebCore::createDragImageFromImage):
1581         * platform/win/PasteboardWin.cpp:
1582         (WebCore::Pasteboard::writeImage):
1583         * rendering/RenderImage.cpp:
1584         (WebCore::RenderImage::imageSizeForError):
1585         (WebCore::RenderImage::paintReplaced):
1586         * rendering/RenderLayer.cpp:
1587         (WebCore::RenderLayer::drawPlatformResizerImage):
1588         * svg/graphics/SVGImage.cpp:
1589         (WebCore::SVGImage::setContainerSize):
1590         * svg/graphics/SVGImage.h:
1591         * svg/graphics/SVGImageCache.cpp:
1592         (WebCore::SVGImageCache::imageSizeForRenderer):
1593         * svg/graphics/SVGImageCache.h:
1594         * svg/graphics/SVGImageForContainer.cpp:
1595         (WebCore::SVGImageForContainer::size):
1596         * svg/graphics/SVGImageForContainer.h:
1597         * svg/graphics/filters/SVGFEImage.cpp:
1598         (WebCore::FEImage::externalRepresentation):
1599         * testing/Internals.cpp:
1600         (WebCore::Internals::getCurrentCursorInfo):
1601
1602 2014-04-01  Ryuan Choi  <ryuan.choi@samsung.com>
1603
1604         Unreviewed build fix when disabled ACCESSIBILITY
1605
1606         * accessibility/atk/WebKitAccessibleInterfaceTableCell.cpp:
1607         Separated macros not to check ATK version when disabled ACCESSIBILITY
1608
1609 2014-04-01  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1610
1611         [CMake][EFL] Enable CSS JIT
1612         https://bugs.webkit.org/show_bug.cgi?id=131010
1613
1614         Reviewed by Benjamin Poulain.
1615
1616         Add an inclusion path for enabling CSS JIT on EFL and GTK ports.
1617         This patch only enables it for EFL port.
1618
1619         * CMakeLists.txt:
1620
1621 2014-04-01  Martin Robinson  <mrobinson@igalia.com>
1622
1623         [GTK] Readonly attributes installed as readwrite in GObject DOM bindings
1624         https://bugs.webkit.org/show_bug.cgi?id=130978
1625
1626         Reviewed by Carlos Garcia Campos.
1627
1628         Unify how we decide if an attribute is readable or writeable and improve the code.
1629         This results in some attributes now being marked as read-only which didn't have
1630         corresponding case statements in the set_property switch statements and also correctly
1631         installs set_property support for some more POD types.
1632
1633         * bindings/scripts/CodeGeneratorGObject.pm:
1634         (IsPropertyReadable): Added this helper to simplify deciding if an attribute is readable.
1635         (IsPropertyWriteable): Added this helper to simplify deciding if an attribute is writeable. Also
1636         update the list of types to reflect the full list of types we can generate setters for.
1637         (GenerateProperty): Use the IsPropertyWriteable helper instead of checking whether the attribute is read-only.
1638         Also fix generation of the blurb by using $mutableString instead of $mutableStringconst which isn't used.
1639         (GenerateProperties): Use grep and the new helpers to simplify the code.
1640         (GetReadableProperties): Deleted.
1641         (GetWriteableProperties): Deleted.
1642         * bindings/scripts/test/GObject: Update results
1643
1644 2014-03-31  Ryuan Choi  <ryuan.choi@samsung.com>
1645
1646         [EFL][WK2] Extract the control of page background out of color_set
1647         https://bugs.webkit.org/show_bug.cgi?id=127539
1648
1649         Reviewed by Gyuyoung Kim.
1650
1651         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
1652         Added m_viewBackgroundColor to clear when m_setDrawsBackground is false.
1653         (WebCore::CoordinatedGraphicsScene::CoordinatedGraphicsScene):
1654         (WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext):
1655         (WebCore::CoordinatedGraphicsScene::paintToGraphicsContext):
1656         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
1657         (WebCore::CoordinatedGraphicsScene::setViewBackgroundColor):
1658         (WebCore::CoordinatedGraphicsScene::viewBackgroundColor):
1659         * rendering/RenderLayerBacking.cpp:
1660         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
1661         Added EFL guard not to set opaque as a default for MainFrameRenderViewLayer.
1662         * rendering/RenderLayerCompositor.cpp:
1663         (WebCore::RenderLayerCompositor::ensureRootLayer):
1664         Added EFL guard to apply page scale on RenderView like IOS.
1665
1666 2014-03-31  Byungseon Shin  <sun.shin@lge.com>
1667
1668         [WebGL][OpenGLES] Enable MSAA support for WebGL Canvas
1669         https://bugs.webkit.org/show_bug.cgi?id=130955
1670
1671         Reviewed by Dean Jackson.
1672
1673         To avoid aliasing issues when we render content to WebGL canvas,
1674          we need to implement MSAA support.
1675         - Imagination OpenGLES GPU Driver already support MSAA, so we
1676          need a separate code path to enable it.
1677
1678         * platform/graphics/Extensions3D.h:
1679         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
1680         (WebCore::Extensions3DOpenGLCommon::Extensions3DOpenGLCommon):
1681         * platform/graphics/opengl/Extensions3DOpenGLCommon.h:
1682         (WebCore::Extensions3DOpenGLCommon::isImagination):
1683         * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
1684         (WebCore::GraphicsContext3D::reshapeFBOs):
1685
1686 2014-03-31  Alexey Proskuryakov  <ap@apple.com>
1687
1688         Crashes in PageConsole::addMessage
1689         https://bugs.webkit.org/show_bug.cgi?id=130991
1690         <rdar://problem/14795232>
1691
1692         Reviewed by Geoffrey Garen.
1693
1694         Test: http/tests/misc/detached-frame-console.html
1695
1696         * page/DOMWindow.cpp: (WebCore::DOMWindow::printErrorMessage): Added a null check.
1697         It's legitimate for this to be called for a window that is not currently displayed
1698         in a frame.
1699
1700 2014-03-31  Simon Fraser  <simon.fraser@apple.com>
1701
1702         [UI-side compositing] Proxy animations to the UI process
1703         https://bugs.webkit.org/show_bug.cgi?id=130946
1704
1705         Reviewed by Tim Horton.
1706         
1707         To proxy CA animations, make PlatformCAAnimation a pure virtual base class
1708         and subclass for Mac, Windows, and Remote (just like PlatformCALayer).
1709         
1710         Add coding support for TimingFunctions.
1711         
1712         Do some minor #include tidyup.
1713         
1714         Minor refactor in GraphicsLayerCA to share some animations code.
1715
1716         * WebCore.exp.in:
1717         * WebCore.xcodeproj/project.pbxproj:
1718         * platform/animation/TimingFunction.h: Add setters need for encode/decode.
1719         (WebCore::CubicBezierTimingFunction::setValues):
1720         (WebCore::CubicBezierTimingFunction::setTimingFunctionPreset):
1721         (WebCore::StepsTimingFunction::create):
1722         (WebCore::StepsTimingFunction::setNumberOfSteps):
1723         (WebCore::StepsTimingFunction::setStepAtStart):
1724         * platform/graphics/ca/GraphicsLayerCA.cpp:
1725         (WebCore::GraphicsLayerCA::createPlatformCAAnimation):
1726         (WebCore::GraphicsLayerCA::animationCanBeAccelerated): Minor refactor so we can share
1727         code with GraphicsLayerCARemote.
1728         (WebCore::GraphicsLayerCA::addAnimation):
1729         (WebCore::GraphicsLayerCA::createBasicAnimation):
1730         (WebCore::PassRefPtr<PlatformCAAnimation>GraphicsLayerCA::createKeyframeAnimation):
1731         * platform/graphics/ca/GraphicsLayerCA.h:
1732         * platform/graphics/ca/PlatformCAAnimation.h:
1733         (WebCore::PlatformCAAnimation::~PlatformCAAnimation):
1734         (WebCore::PlatformCAAnimation::isPlatformCAAnimationMac):
1735         (WebCore::PlatformCAAnimation::isPlatformCAAnimationWin):
1736         (WebCore::PlatformCAAnimation::isPlatformCAAnimationRemote):
1737         (WebCore::PlatformCAAnimation::PlatformCAAnimation):
1738         (WebCore::PlatformCAAnimation::setType):
1739         * platform/graphics/ca/PlatformCALayer.h:
1740         * platform/graphics/ca/mac/PlatformCAAnimationMac.h: Added.
1741         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
1742         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1743         (PlatformCALayerMac::addAnimationForKey):
1744         (PlatformCALayerMac::animationForKey):
1745         * platform/graphics/ca/mac/TileController.mm:
1746         * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
1747         * platform/graphics/ca/win/PlatformCAAnimationWin.h: Added.
1748
1749 2014-03-31  Benjamin Poulain  <benjamin@webkit.org>
1750
1751         CSS JIT: compile the first-child pseudo class
1752         https://bugs.webkit.org/show_bug.cgi?id=130954
1753
1754         Reviewed by Andreas Kling.
1755
1756         * css/ElementRuleCollector.cpp:
1757         (WebCore::ElementRuleCollector::collectMatchingRules):
1758         The compiler use the context's style directly when resolving style. An error introduced
1759         in the rule collector would cause a crash in the compiled code which would be hard to debug.
1760         Add an assertion early in the stack to catch errors where it is easier to debug them.
1761
1762         * css/StyleResolver.cpp:
1763         (WebCore::StyleResolver::State::initForStyleResolve):
1764         * cssjit/SelectorCompiler.cpp:
1765         (WebCore::SelectorCompiler::addPseudoType):
1766         (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
1767         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToPreviousAdjacentElement):
1768         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToPreviousAdjacent):
1769         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
1770         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateIndirectAdjacentTreeWalker):
1771         Refactor those to be able to reuse the code getting a sibling element preceding the current element.
1772
1773         (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNotResolvingStyle):
1774         Extract the code checking the current mode from SelectorCodeGenerator::markParentElementIfResolvingStyle()
1775         in a separate function. This will be useful for all the pseudo class with marking.
1776
1777         (WebCore::SelectorCompiler::SelectorCodeGenerator::markParentElementIfResolvingStyle):
1778         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
1779         (WebCore::SelectorCompiler::setFirstChildState):
1780         This is the slow path for when the first-child pseudo class is on a fragment that is not
1781         the rightmost.
1782         The reason to use a slow path is accessing renderStyle() is not trivial and this case isn't not
1783         as common. We should improve this later.
1784
1785         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
1786         This is just implementing the test for first-child plus the tree marking. Nothing fancy,
1787         this is basically the same thing as SelectorChecker.
1788
1789         * dom/Element.cpp:
1790         (WebCore::Element::setChildrenAffectedByFirstChildRules):
1791         * dom/Element.h:
1792         C++ fallback to set the flag, to be improved later with the other flags.
1793
1794         * rendering/style/RenderStyle.h:
1795         I accidentaly put noninheritedFlagsMemoryOffset() as private in the RenderStyle refactoring.
1796
1797         Also update the flags accessor to make them easier to work with from the compiler. In particular,
1798         setFirstChildStateFlags() sets both isUnique and firstChild. Currently the JIT does not need to access
1799         the value so individual flags are made private.
1800
1801 2014-03-31  Dean Jackson  <dino@apple.com>
1802
1803         Remove WEB_ANIMATIONS
1804         https://bugs.webkit.org/show_bug.cgi?id=130989
1805
1806         Reviewed by Simon Fraser.
1807
1808         Remove this feature flag until we plan to implement.
1809
1810         * Configurations/FeatureDefines.xcconfig:
1811
1812 2014-03-31  Simon Fraser  <simon.fraser@apple.com>
1813
1814         Fix iOS build.
1815
1816         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
1817         (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterDelegatedScroll):
1818
1819 2014-03-31  Pratik Solanki  <psolanki@apple.com>
1820
1821         Unreviewed. iOS build fix after r166532. Add missing comma.
1822
1823         * dom/DocumentMarker.h:
1824
1825 2014-03-31  Brady Eidson  <beidson@apple.com>
1826
1827         Add variant of phone number parsing that use DocumentMarker in the current selection
1828         <rdar://problem/16379566> and https://bugs.webkit.org/show_bug.cgi?id=130917
1829
1830         Reviewed by Darin Adler.
1831
1832         * dom/DocumentMarker.h:
1833         (WebCore::DocumentMarker::AllMarkers::AllMarkers): Add a new TelephoneNumber document marker type.
1834
1835         * editing/Editor.cpp:
1836         (WebCore::Editor::respondToChangedSelection):
1837         (WebCore::Editor::scanSelectionForTelephoneNumbers): TextIterate over the selected range looking for numbers.
1838         (WebCore::Editor::scanRangeForTelephoneNumbers): Scan the given range for a telephone number,
1839           adding the DocumentMarker to any that are found.
1840         (WebCore::Editor::clearDataDetectedTelephoneNumbers):
1841         * editing/Editor.h:
1842
1843         * html/parser/HTMLTreeBuilder.cpp:
1844         (WebCore::HTMLTreeBuilder::processCharacterBufferForInBody): Only linkify on iOS.
1845
1846         * rendering/InlineTextBox.cpp:
1847         (WebCore::InlineTextBox::paintTelephoneNumberMarker): Placeholder UI while the feature is developed.
1848         (WebCore::InlineTextBox::paintDocumentMarkers):
1849         * rendering/InlineTextBox.h:
1850
1851         * testing/Internals.cpp:
1852         (WebCore::markerTypesFrom):
1853
1854 2014-03-31  Simon Fraser  <simon.fraser@apple.com>
1855
1856         [iOS WK2] Hook up scroll events for accelerated overflow:scroll
1857         https://bugs.webkit.org/show_bug.cgi?id=130976
1858
1859         Reviewed by Tim Horton.
1860
1861         When an accelerated overflow:scroll is scrolled in the UI process,
1862         tell the WebProcess that the scroll happened to update RenderLayer
1863         state and fire events.
1864         
1865         In the WebProcess, RemoteScrollingCoordinator gets a message from the
1866         UI process and calls AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll().
1867         Fixed that function to handle scrolling nodes other than the root, which
1868         required storing a map of ScrollingNodeID->RenderLayer* on RenderLayerCompositor,
1869         accessible through FrameView::scrollableAreaForScrollLayerID().
1870
1871         * WebCore.exp.in:
1872         * page/FrameView.cpp:
1873         (WebCore::FrameView::scrollableAreaForScrollLayerID):
1874         * page/FrameView.h:
1875         * page/scrolling/AsyncScrollingCoordinator.cpp:
1876         (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll): Handle
1877         overflow as well as main frame scrolling nodes.
1878         * page/scrolling/ScrollingTree.cpp:
1879         (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling): Use isScrollingNode().
1880         (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling): When an overflow
1881         scroll node was scrolled externally, we have to update layers in decendant nodes,
1882         and then call scrollingTreeNodeDidScroll() which tells the ScrollingCoordinator that
1883         we scrolled.
1884         * page/scrolling/ScrollingTree.h: Try to reduce confusion between the roles played
1885         by these various functions, some of which happen in the UI process with UI-side
1886         compositing.
1887         * page/scrolling/ScrollingTreeScrollingNode.h:
1888         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h: Need some functions to be
1889         callable by subclasses.
1890         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
1891         (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterDelegatedScroll):
1892         * rendering/RenderLayerCompositor.cpp:
1893         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer): Add
1894         scrolling layers to the m_scrollingNodeToLayerMap
1895         (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer): Remove
1896         layer from the m_scrollingNodeToLayerMap.
1897         (WebCore::RenderLayerCompositor::scrollableAreaForScrollLayerID):
1898         * rendering/RenderLayerCompositor.h:
1899
1900 2014-03-31  Antti Koivisto  <antti@apple.com>
1901
1902         Rename TileCache to LegacyTileCache
1903         https://bugs.webkit.org/show_bug.cgi?id=130986
1904
1905         Reviewed by Simon Fraser.
1906
1907         Rename iOS WebKit1 tile cache classes to reflect its status.
1908         This also frees some good type names.
1909
1910         TileCache -> LegacyTileCache
1911         TileGrid -> LegacyTileGrid
1912         TileGridTile -> LegacyTileGridTile
1913         etc.
1914
1915 2014-03-31  Tim Horton  <timothy_horton@apple.com>
1916
1917         Small adjustments to WebCore::IOSurface
1918         https://bugs.webkit.org/show_bug.cgi?id=130981
1919
1920         Reviewed by Simon Fraser.
1921
1922         * WebCore.exp.in:
1923         Export some more things.
1924
1925         * platform/graphics/cocoa/IOSurface.h:
1926         createImage() can't be const because it calls ensurePlatformContext().
1927
1928         * platform/graphics/cocoa/IOSurface.mm:
1929         (IOSurface::createImage):
1930         We should be able to create an image even if the CGContext has been cleared (or never created).
1931
1932         (IOSurface::isInUse):
1933         Rename inUse() to isInUse().
1934
1935         (IOSurface::clearGraphicsContext):
1936         Add clearGraphicsContext().
1937
1938 2014-03-31  Tim Horton  <timothy_horton@apple.com>
1939
1940         Allocate IOSurfaces with the same cache mode that CoreAnimation uses
1941         https://bugs.webkit.org/show_bug.cgi?id=130982
1942
1943         Reviewed by Simon Fraser.
1944
1945         * platform/graphics/cocoa/IOSurface.mm:
1946         (IOSurface::IOSurface):
1947         CA uses kIOMapWriteCombineCache for IOSurfaces allocated on iOS.
1948
1949 2014-03-31  Ion Rosca  <rosca@adobe.com>
1950
1951         [CSS Blending] Blend mode property is propagated to multiple GraphicLayers
1952         https://bugs.webkit.org/show_bug.cgi?id=130337
1953
1954         Reviewed by Dean Jackson.
1955
1956         Resets the blend mode for graphicsLayer when it has an ancestorClippingLayer.
1957
1958         Test: css3/compositing/blend-mode-ancestor-clipping-layer.html
1959
1960         * rendering/RenderLayer.cpp:
1961         (WebCore::RenderLayer::updateBlendMode):
1962         (WebCore::RenderLayer::calculateClipRects):
1963         * rendering/RenderLayerBacking.cpp:
1964         (WebCore::RenderLayerBacking::updateBlendMode):
1965         * rendering/RenderLayerBacking.h:
1966
1967 2014-03-31  Ion Rosca  <rosca@adobe.com>
1968
1969         [CSS Blending] showLayerTree should dump layer's blend mode and isolation properties
1970         https://bugs.webkit.org/show_bug.cgi?id=130922
1971
1972         Reviewed by Simon Fraser.
1973
1974         This change only updates existing tests involving blending. No new test required,
1975         as there is no new or changed functionality.
1976
1977         * rendering/RenderLayer.h: adding blendMode() getter.
1978         * rendering/RenderTreeAsText.cpp:
1979         (WebCore::write):
1980         adding blendMode property and layer's isolation status (does layer isolate blending descendants or not?).
1981
1982 2014-03-31  Benjamin Poulain  <benjamin@webkit.org>
1983
1984         CSS JIT: clean up the functions ending when generating a checker with context
1985         https://bugs.webkit.org/show_bug.cgi?id=130959
1986
1987         Reviewed by Andreas Kling.
1988
1989         This code got refactored over time and now both branches do the exact same action
1990         on the stack.
1991         This patch removes the stack split and move the stack cleanup in the common ending
1992         just before restoring the callee saved registers.
1993
1994         * cssjit/SelectorCompiler.cpp:
1995         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
1996
1997 2014-03-31  Beth Dakin  <bdakin@apple.com>
1998
1999         ThemeMac should use std::array instead of IntSize* for control sizes
2000         https://bugs.webkit.org/show_bug.cgi?id=130985
2001
2002         Reviewed by Darin Adler.
2003
2004         Replace uses of const IntSize* with const std::array<IntSize, 3>
2005         * platform/mac/ThemeMac.mm:
2006         (WebCore::sizeFromNSControlSize):
2007         (WebCore::sizeFromFont):
2008         (WebCore::controlSizeFromPixelSize):
2009         (WebCore::setControlSize):
2010         (WebCore::checkboxSizes):
2011         (WebCore::radioSizes):
2012         (WebCore::buttonSizes):
2013         (WebCore::setUpButtonCell):
2014         (WebCore::stepperSizes):
2015
2016 2014-03-31  Hans Muller  <hmuller@adobe.com>
2017
2018         [CSS Shapes] Simplify RasterShape implementation
2019         https://bugs.webkit.org/show_bug.cgi?id=130916
2020
2021         Reviewed by Dean Jackson.
2022
2023         Since only floats can specify shape-outside, the RasterShapeIntervals
2024         class only needs to track the first and last above threshold pixel column
2025         (x1 and x2 in the implementation) for each row. Removed code for dealing with
2026         multiple "runs" per row as well as shape-inside internals.
2027
2028         No new tests, since functionality was only removed.
2029
2030         * rendering/shapes/RasterShape.cpp:
2031         (WebCore::RasterShapeIntervals::computeShapeMarginIntervals):
2032         (WebCore::RasterShapeIntervals::initializeBounds):
2033         (WebCore::RasterShapeIntervals::buildBoundsPath):
2034         (WebCore::RasterShape::getExcludedIntervals):
2035         * rendering/shapes/RasterShape.h:
2036         (WebCore::RasterShapeIntervals::RasterShapeIntervals):
2037         (WebCore::RasterShapeIntervals::intervalAt):
2038         (WebCore::RasterShape::RasterShape):
2039         * rendering/shapes/Shape.cpp:
2040         (WebCore::Shape::createRasterShape):
2041         * rendering/shapes/ShapeInterval.h:
2042         (WebCore::ShapeInterval::unite):
2043
2044 2014-03-31  Andreas Kling  <akling@apple.com>
2045
2046         Always inline toJS() for NodeList.
2047         <https://webkit.org/b/130974>
2048
2049         This is a pretty cheesy optimization, but it's a 3% progression on
2050         Dromaeo/dom-query.html on my MBP.
2051
2052         Reviewed by Benjamin Poulain.
2053
2054         * WebCore.exp.in:
2055         * WebCore.xcodeproj/project.pbxproj:
2056         * bindings/js/JSNodeListCustom.h: Added.
2057         (WebCore::toJS):
2058         * dom/NodeList.idl:
2059
2060 2014-03-31  Benjamin Poulain  <bpoulain@apple.com>
2061
2062         Attempt to fix the 32bits debug builds
2063
2064         The additional debug flags in RefCounted cause the structure to have different alignment
2065         with the 64bits flags.
2066
2067         * rendering/style/RenderStyle.cpp:
2068
2069 2014-03-29  Simon Fraser  <simon.fraser@apple.com>
2070
2071         Clarify some scrolling tree terminology
2072         https://bugs.webkit.org/show_bug.cgi?id=130929
2073
2074         Reviewed by Tim Horton.
2075
2076         Attempt to reduce some ambiguity in scrolling tree terminology.
2077         When async scrolling occurs, there are two tasks we have to perform:
2078         1. Layers need to be updated to reflect the scroll
2079         2. WebCore state has to be updated.
2080         The "updateForViewport" name didn't clearly reflect which of these
2081         tasks was being performed, so rename it to updateLayersAfterViewportChange()
2082         to reflect the fact that it only does the first.
2083         
2084         Remove the Mac implementation of updateLayersAfterViewportChange(), since
2085         it was confsued about this, and was never called anyway.
2086
2087         * WebCore.exp.in:
2088         * page/scrolling/ScrollingTree.cpp:
2089         (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling):
2090         * page/scrolling/ScrollingTreeScrollingNode.h:
2091         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
2092         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
2093         (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterViewportChange):
2094         (WebCore::ScrollingTreeScrollingNodeIOS::updateForViewport): Deleted.
2095         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
2096         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
2097         (WebCore::ScrollingTreeScrollingNodeMac::updateLayersAfterViewportChange):
2098         (WebCore::ScrollingTreeScrollingNodeMac::updateForViewport): Deleted.
2099
2100 2014-03-31  Tim Horton  <timothy_horton@apple.com>
2101
2102         [iOS WebKit2] Disable tile cohort retention for now
2103         https://bugs.webkit.org/show_bug.cgi?id=130926
2104         <rdar://problem/16465413>
2105
2106         Reviewed by Simon Fraser.
2107
2108         * WebCore.exp.in:
2109         * page/Settings.cpp:
2110         (WebCore::Settings::Settings):
2111         (WebCore::Settings::setScrollingPerformanceLoggingEnabled):
2112         (WebCore::Settings::setAggressiveTileRetentionEnabled): Deleted.
2113         * page/Settings.h:
2114         (WebCore::Settings::aggressiveTileRetentionEnabled): Deleted.
2115         * page/Settings.in:
2116         Use Settings.in for these simple settings.
2117
2118         * platform/graphics/GraphicsLayerClient.h:
2119         (WebCore::GraphicsLayerClient::shouldAggressivelyRetainTiles):
2120         (WebCore::GraphicsLayerClient::shouldTemporarilyRetainTileCohorts):
2121         * platform/graphics/TiledBacking.h:
2122         * platform/graphics/ca/GraphicsLayerCA.cpp:
2123         (WebCore::GraphicsLayerCA::platformCALayerShouldAggressivelyRetainTiles):
2124         (WebCore::GraphicsLayerCA::platformCALayerShouldTemporarilyRetainTileCohorts):
2125         * platform/graphics/ca/GraphicsLayerCA.h:
2126         * platform/graphics/ca/PlatformCALayerClient.h:
2127         (WebCore::PlatformCALayerClient::platformCALayerShouldAggressivelyRetainTiles):
2128         (WebCore::PlatformCALayerClient::platformCALayerShouldTemporarilyRetainTileCohorts):
2129         * rendering/RenderLayerBacking.cpp:
2130         (WebCore::RenderLayerBacking::shouldAggressivelyRetainTiles):
2131         (WebCore::RenderLayerBacking::shouldTemporarilyRetainTileCohorts):
2132         * rendering/RenderLayerBacking.h:
2133         Plumb the two tile-retention settings through to TileController in a pull manner
2134         instead of a push manner, as there were some cases (especially on iOS) where
2135         the settings weren't always getting pushed down.
2136
2137         * platform/graphics/ca/mac/TileController.h:
2138         * platform/graphics/ca/mac/TileController.mm:
2139         (WebCore::TileController::TileController):
2140         (WebCore::TileController::tileRevalidationTimerFired):
2141         (WebCore::TileController::revalidateTiles):
2142         (WebCore::TileController::drawTileMapContents):
2143         Aggressive tile retention wins over temporary retention. If we aren't
2144         using temporary (cohort) retention, throw away the cohort as soon as it
2145         is created.
2146
2147 2014-03-31  Beth Dakin  <bdakin@apple.com>
2148
2149         Radio buttons and checkboxes should share code
2150         https://bugs.webkit.org/show_bug.cgi?id=130915
2151
2152         Reviewed by Sam Weinig.
2153
2154         Radio buttons and checkboxes now share a lot of code. The common term for both is 
2155         toggle buttons.
2156
2157         Move these radio-sizing functions up in the file to be next to the checkbox sizing 
2158         functions.
2159         * platform/mac/ThemeMac.mm:
2160         (WebCore::radioSizes):
2161         (WebCore::radioMargins):
2162         (WebCore::radioSize):
2163
2164         Configures a radio button or a checkbox.
2165         (WebCore::configureToggleButton):
2166
2167         Creates a radio button or a checkbox.
2168         (WebCore::createToggleButtonCell):
2169
2170         Still have a shared cell for each.
2171         (WebCore::sharedRadioCell):
2172         (WebCore::sharedCheckboxCell):
2173
2174         Does the work of the old paintRadio() and paintCheckbox().
2175         (WebCore::paintToggleButton):
2176
2177         Use sharedRadioCell() here.
2178         (WebCore::ThemeMac::inflateControlPaintRect):
2179
2180         Call paintToggleButton() for radio buttons and checkboxes.
2181         (WebCore::ThemeMac::paint):
2182
2183         All gone.
2184         (WebCore::configureCheckbox): Deleted.
2185         (WebCore::createCheckboxCell): Deleted.
2186         (WebCore::paintCheckbox): Deleted.
2187         (WebCore::radio): Deleted.
2188         (WebCore::paintRadio): Deleted.
2189
2190 2014-03-31  Samuel White  <samuel_white@apple.com>
2191
2192         AX: Need ability to get line range for text marker.
2193         https://bugs.webkit.org/show_bug.cgi?id=130906
2194
2195         Reviewed by Chris Fleizach.
2196
2197         Added ability to get line range from any marker on that line. This matches the functionality of existing
2198         attributes such as AXParagraphTextMarkerRangeForTextMarker and AXSentenceTextMarkerRangeForTextMarker.
2199
2200         Test: platform/mac/accessibility/line-range-for-text-marker.html
2201
2202         * accessibility/AccessibilityObject.cpp:
2203         (WebCore::AccessibilityObject::visiblePositionRangeForRange):
2204         (WebCore::AccessibilityObject::lineRangeForPosition):
2205         * accessibility/AccessibilityObject.h:
2206         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2207         (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
2208         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
2209
2210 2014-03-31  Anders Carlsson  <andersca@apple.com>
2211
2212         Fix iOS build.
2213
2214         * page/ChromeClient.h:
2215         (WebCore::ChromeClient::updateViewportConstrainedLayers):
2216
2217 2014-03-31  Jer Noble  <jer.noble@apple.com>
2218
2219         [MSE][Mac] Support lease-renewal.
2220         https://bugs.webkit.org/show_bug.cgi?id=130919
2221
2222         Reviewed by Eric Carlson.
2223
2224         Trigger a new key request when receiving an update message containting "renew".
2225
2226         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
2227         (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest): Drive-by fix; generate a UTF-8
2228             based array.
2229         (WebCore::CDMSessionMediaSourceAVFObjC::update):
2230
2231 2014-03-31  Alexey Proskuryakov  <ap@apple.com>
2232
2233         Remove special handling of soft hyphens in search code
2234         https://bugs.webkit.org/show_bug.cgi?id=130940
2235
2236         Reviewed by Anders Carlsson.
2237
2238         ICU knows to ignore soft hyphens, so we don't need to replace them before searching.
2239
2240         Covered by existing tests.
2241
2242         * editing/TextIterator.cpp:
2243         (WebCore::foldQuoteMark):
2244         (WebCore::foldQuoteMarks):
2245         (WebCore::SearchBuffer::SearchBuffer):
2246         (WebCore::SearchBuffer::append):
2247         (WebCore::foldQuoteMarkOrSoftHyphen): Deleted.
2248         (WebCore::foldQuoteMarksAndSoftHyphens): Deleted.
2249
2250 2014-03-31  Alex Christensen  <achristensen@webkit.org>
2251
2252         Preparation for using Soup on Windows.
2253         https://bugs.webkit.org/show_bug.cgi?id=130615
2254
2255         Reviewed by Carlos Garcia Campos.
2256
2257         * WebCore.vcxproj/WebCore.vcxproj:
2258         * WebCore.vcxproj/WebCore.vcxproj.filters:
2259         Added Soup source files in WinCairo build.
2260         * loader/soup/CachedRawResourceSoup.cpp:
2261         * loader/soup/SubresourceLoaderSoup.cpp:
2262         * platform/soup/SharedBufferSoup.cpp:
2263         * platform/soup/URLSoup.cpp:
2264         * platform/network/NetworkStorageSessionStub.cpp:
2265         Only build if USE(SOUP) to prevent building when USE(CURL) is true.
2266         * platform/network/soup/ResourceHandleSoup.cpp:
2267         Only include unistd.h in non-Visual Studio builds.
2268         This would normally be done with a HAVE_UNISTD_H macro when compiling glib and Soup,
2269         but that would need to be left undefined for Visual Studio.
2270
2271 2014-03-31  Zan Dobersek  <zdobersek@igalia.com>
2272
2273         Unreviewed. Addressing reviewing comments for r166491 that I forgot
2274         to address before landing.
2275
2276         * html/FormController.cpp:
2277         (WebCore::SavedFormState::deserialize): No need to move the std::unique_ptr
2278         object on the way out.
2279         (WebCore::FormController::createSavedFormStateMap): FormKeyGenerator can be
2280         allocated on the stack.
2281         (WebCore::FormController::formStatesFromStateVector): Use auto.
2282
2283 2014-03-20  Carlos Garcia Campos  <cgarcia@igalia.com>
2284
2285         [GTK] Use GMainLoopSource for idle and timeout sources in WebCore
2286         https://bugs.webkit.org/show_bug.cgi?id=130078
2287
2288         Reviewed by Philippe Normand.
2289
2290         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
2291         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
2292         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h:
2293         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2294         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
2295         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
2296         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
2297         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
2298         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:
2299         * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
2300         * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
2301         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
2302         * platform/gtk/GtkDragAndDropHelper.cpp:
2303         * platform/gtk/SharedTimerGtk.cpp:
2304
2305 2014-03-31  Andrei Bucur  <abucur@adobe.com>
2306
2307         Wrong layout while animating content in regions
2308         https://bugs.webkit.org/show_bug.cgi?id=125086
2309
2310         Reviewed by David Hyatt.
2311
2312         The region to layer and regions to layer mappings should be cleared when the region chain changes.
2313
2314         Test: fast/regions/layers/region-removed-during-animation.html
2315
2316         * rendering/RenderFlowThread.cpp:
2317         (WebCore::RenderFlowThread::invalidateRegions): Clear the two maps and flag them for recomputation.
2318         (WebCore::RenderFlowThread::cachedRegionForCompositedLayer): Assert that the returned region exists.
2319
2320 2014-03-31  Dániel Bátyai  <dbatyai.u-szeged@partner.samsung.com>
2321
2322         Remove hostThisRegister() and hostThisValue()
2323         https://bugs.webkit.org/show_bug.cgi?id=130895
2324
2325         Reviewed by Geoffrey Garen.
2326
2327         Removed hostThisRegister() and hostThisValue() and instead use thisArgumentOffset() and thisValue() respectively.
2328
2329         No new tests, no behavior changes.
2330
2331         * bindings/js/JSNavigatorCustom.cpp:
2332         (WebCore::JSNavigator::webkitGetUserMedia):
2333         * bindings/js/JSPluginElementFunctions.cpp:
2334         (WebCore::callPlugin):
2335         * bindings/scripts/CodeGeneratorJS.pm:
2336         (GenerateImplementation):
2337         * bindings/scripts/test/JS/JSFloat64Array.cpp:
2338         (WebCore::jsFloat64ArrayPrototypeFunctionFoo):
2339         (WebCore::jsFloat64ArrayPrototypeFunctionSet):
2340         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
2341         (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
2342         (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):
2343         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
2344         (WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):
2345         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
2346         (WebCore::jsTestEventTargetPrototypeFunctionItem):
2347         (WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
2348         (WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
2349         (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
2350         * bindings/scripts/test/JS/JSTestInterface.cpp:
2351         (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod1):
2352         (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
2353         (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod3):
2354         (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod1):
2355         (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
2356         (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod3):
2357         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
2358         (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
2359         * bindings/scripts/test/JS/JSTestObj.cpp:
2360         (WebCore::jsTestObjPrototypeFunctionVoidMethod):
2361         (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
2362         (WebCore::jsTestObjPrototypeFunctionByteMethod):
2363         (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
2364         (WebCore::jsTestObjPrototypeFunctionOctetMethod):
2365         (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
2366         (WebCore::jsTestObjPrototypeFunctionLongMethod):
2367         (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
2368         (WebCore::jsTestObjPrototypeFunctionObjMethod):
2369         (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
2370         (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
2371         (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
2372         (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
2373         (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
2374         (WebCore::jsTestObjPrototypeFunctionSerializedValue):
2375         (WebCore::jsTestObjPrototypeFunctionOptionsObject):
2376         (WebCore::jsTestObjPrototypeFunctionMethodWithException):
2377         (WebCore::jsTestObjPrototypeFunctionCustomMethod):
2378         (WebCore::jsTestObjPrototypeFunctionCustomMethodWithArgs):
2379         (WebCore::jsTestObjPrototypeFunctionAddEventListener):
2380         (WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
2381         (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoid):
2382         (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
2383         (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoidException):
2384         (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
2385         (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContext):
2386         (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptState):
2387         (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
2388         (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
2389         (WebCore::jsTestObjPrototypeFunctionWithScriptArgumentsAndCallStack):
2390         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
2391         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
2392         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
2393         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalString):
2394         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefined):
2395         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullString):
2396         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
2397         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
2398         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
2399         (WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
2400         (WebCore::jsTestObjPrototypeFunctionConditionalMethod2):
2401         (WebCore::jsTestObjPrototypeFunctionConditionalMethod3):
2402         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
2403         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
2404         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
2405         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
2406         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
2407         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
2408         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
2409         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
2410         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod9):
2411         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
2412         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
2413         (WebCore::jsTestObjPrototypeFunctionClassMethodWithClamp):
2414         (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
2415         (WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
2416         (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
2417         (WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
2418         (WebCore::jsTestObjPrototypeFunctionConvert1):
2419         (WebCore::jsTestObjPrototypeFunctionConvert2):
2420         (WebCore::jsTestObjPrototypeFunctionConvert4):
2421         (WebCore::jsTestObjPrototypeFunctionConvert5):
2422         (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
2423         (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
2424         (WebCore::jsTestObjPrototypeFunctionOrange):
2425         (WebCore::jsTestObjPrototypeFunctionStrictFunction):
2426         (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
2427         (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithArray):
2428         (WebCore::jsTestObjPrototypeFunctionVariadicStringMethod):
2429         (WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethod):
2430         (WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
2431         (WebCore::jsTestObjPrototypeFunctionAny):
2432         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
2433         (WebCore::jsTestTypedefsPrototypeFunctionFunc):
2434         (WebCore::jsTestTypedefsPrototypeFunctionSetShadow):
2435         (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
2436         (WebCore::jsTestTypedefsPrototypeFunctionNullableArrayArg):
2437         (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClamp):
2438         (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
2439         (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction):
2440         (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction2):
2441         (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
2442         (WebCore::jsTestTypedefsPrototypeFunctionMethodWithException):
2443         * bridge/objc/objc_runtime.mm:
2444         (JSC::Bindings::callObjCFallbackObject):
2445         * bridge/runtime_method.cpp:
2446         (JSC::callRuntimeMethod):
2447
2448 2014-03-31  Zan Dobersek  <zdobersek@igalia.com>
2449
2450         Move the rest of Source/WebCore/html/ code to std::unique_ptr
2451         https://bugs.webkit.org/show_bug.cgi?id=129669
2452
2453         Reviewed by Anders Carlsson.
2454
2455         Replace the remaining uses of OwnPtr, PassOwnPtr under Source/WebCore/html/ with std::unique_ptr.
2456
2457         * html/FormController.cpp:
2458         (WebCore::SavedFormState::SavedFormState):
2459         (WebCore::SavedFormState::deserialize):
2460         (WebCore::FormController::createSavedFormStateMap):
2461         (WebCore::FormController::formElementsState):
2462         (WebCore::FormController::takeStateForFormElement):
2463         (WebCore::FormController::formStatesFromStateVector):
2464         * html/FormController.h:
2465         * html/HTMLAreaElement.cpp:
2466         (WebCore::HTMLAreaElement::mapMouseEvent):
2467         * html/HTMLAreaElement.h:
2468         * html/HTMLCanvasElement.cpp:
2469         (WebCore::HTMLCanvasElement::setSurfaceSize):
2470         (WebCore::HTMLCanvasElement::createImageBuffer):
2471         * html/HTMLCanvasElement.h:
2472         * html/HTMLCollection.h:
2473         * html/HTMLEmbedElement.cpp:
2474         (WebCore::HTMLEmbedElement::parseAttribute):
2475         * html/HTMLFormControlElement.cpp:
2476         (WebCore::HTMLFormControlElement::updateVisibleValidationMessage):
2477         * html/HTMLFormControlElement.h:
2478         * html/HTMLFormElement.cpp:
2479         (WebCore::HTMLFormElement::addToPastNamesMap):
2480         * html/HTMLFormElement.h:
2481         * html/HTMLInputElement.cpp:
2482         (WebCore::HTMLInputElement::imageLoader):
2483         (WebCore::HTMLInputElement::resetListAttributeTargetObserver):
2484         * html/HTMLInputElement.h:
2485         (WebCore::HTMLInputElement::hasImageLoader):
2486         * html/HTMLObjectElement.cpp:
2487         (WebCore::HTMLObjectElement::parseAttribute):
2488         * html/HTMLPlugInImageElement.cpp:
2489         (WebCore::HTMLPlugInImageElement::startLoadingImage):
2490         * html/HTMLPlugInImageElement.h:
2491         * html/HTMLVideoElement.cpp:
2492         (WebCore::HTMLVideoElement::didAttachRenderers):
2493         (WebCore::HTMLVideoElement::parseAttribute):
2494         * html/HTMLVideoElement.h:
2495         * html/ValidationMessage.cpp:
2496         (WebCore::ValidationMessage::ValidationMessage):
2497         (WebCore::ValidationMessage::setMessage):
2498         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
2499         (WebCore::ValidationMessage::requestToHideMessage):
2500         * html/ValidationMessage.h:
2501
2502 2014-03-31  Maurice van der Pot  <griffon26@kfk4ever.com>
2503
2504         Fix mixed use of booleans in JPEGImageDecoder.cpp
2505         https://bugs.webkit.org/show_bug.cgi?id=122412
2506
2507         Reviewed by Darin Adler.
2508
2509         Trivial fix for compilation error; no new tests.
2510
2511         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
2512         (WebCore::JPEGImageReader::decode):
2513         (WebCore::fill_input_buffer):
2514         Use TRUE/FALSE defined by libjpeg for libjpeg booleans
2515
2516 2014-03-23  Zan Dobersek  <zdobersek@igalia.com>
2517
2518         Move Source/WebCore/rendering/ code to std::unique_ptr
2519         https://bugs.webkit.org/show_bug.cgi?id=129664
2520
2521         Reviewed by Anders Carlsson.
2522
2523         Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/rendering/ with std::unique_ptr.
2524
2525         * platform/graphics/FloatPolygon.cpp:
2526         (WebCore::FloatPolygon::FloatPolygon):
2527         * platform/graphics/FloatPolygon.h:
2528         * rendering/ClipPathOperation.h:
2529         * rendering/FlowThreadController.cpp:
2530         (WebCore::FlowThreadController::ensureRenderFlowThreadWithName):
2531         * rendering/FlowThreadController.h:
2532         * rendering/HitTestLocation.h:
2533         * rendering/HitTestResult.cpp:
2534         (WebCore::HitTestResult::HitTestResult):
2535         (WebCore::HitTestResult::operator=):
2536         (WebCore::HitTestResult::rectBasedTestResult):
2537         (WebCore::HitTestResult::mutableRectBasedTestResult):
2538         * rendering/HitTestResult.h:
2539         * rendering/HitTestingTransformState.cpp:
2540         * rendering/ImageQualityController.h:
2541         * rendering/RenderBlock.cpp:
2542         (WebCore::removeBlockFromDescendantAndContainerMaps):
2543         (WebCore::RenderBlock::finishDelayUpdateScrollInfo):
2544         (WebCore::RenderBlock::addContinuationWithOutline):
2545         (WebCore::RenderBlock::paintContinuationOutlines):
2546         (WebCore::RenderBlock::insertIntoTrackedRendererMaps):
2547         (WebCore::RenderBlock::removeFromTrackedRendererMaps):
2548         (WebCore::RenderBlock::setComputedColumnCountAndWidth):
2549         * rendering/RenderBlock.h:
2550         * rendering/RenderBlockFlow.cpp:
2551         (WebCore::RenderBlockFlow::createFloatingObjects):
2552         * rendering/RenderBlockFlow.h:
2553         * rendering/RenderBoxRegionInfo.h:
2554         * rendering/RenderButton.cpp:
2555         (WebCore::RenderButton::styleDidChange):
2556         * rendering/RenderButton.h:
2557         * rendering/RenderCounter.cpp:
2558         (WebCore::makeCounterNode):
2559         * rendering/RenderFlowThread.cpp:
2560         (WebCore::RenderFlowThread::updateAllLayerToRegionMappings):
2561         (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
2562         * rendering/RenderFlowThread.h:
2563         * rendering/RenderGeometryMap.cpp:
2564         (WebCore::RenderGeometryMap::push):
2565         (WebCore::RenderGeometryMap::pushView):
2566         * rendering/RenderGeometryMap.h:
2567         * rendering/RenderGrid.cpp:
2568         (WebCore::RenderGrid::GridIterator::nextEmptyGridArea):
2569         (WebCore::RenderGrid::placeItemsOnGrid):
2570         (WebCore::RenderGrid::populateExplicitGridAndOrderIterator):
2571         (WebCore::RenderGrid::placeSpecifiedMajorAxisItemsOnGrid):
2572         (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid):
2573         (WebCore::RenderGrid::resolveGridPositionsFromStyle):
2574         (WebCore::RenderGrid::resolveGridPositionAgainstOppositePosition):
2575         (WebCore::RenderGrid::resolveNamedGridLinePositionAgainstOppositePosition):
2576         (WebCore::RenderGrid::resolveRowStartColumnStartNamedGridLinePositionAgainstOppositePosition):
2577         (WebCore::RenderGrid::resolveRowEndColumnEndNamedGridLinePositionAgainstOppositePosition):
2578         * rendering/RenderGrid.h:
2579         * rendering/RenderImageResource.h:
2580         * rendering/RenderLayer.cpp:
2581         (WebCore::RenderLayer::updateDescendantsAreContiguousInStackingOrder):
2582         (WebCore::RenderLayer::updateTransform):
2583         (WebCore::RenderLayer::setupFilters):
2584         (WebCore::RenderLayer::paintLayerContents):
2585         (WebCore::RenderLayer::paintChildLayerIntoColumns):
2586         (WebCore::RenderLayer::hitTestChildLayerColumns):
2587         (WebCore::RenderLayer::updateClipRects):
2588         (WebCore::RenderLayer::calculateClipRects):
2589         * rendering/RenderLayer.h:
2590         (WebCore::RenderLayer::clearZOrderLists):
2591         * rendering/RenderLayerCompositor.cpp:
2592         (WebCore::RenderLayerCompositor::notifyFlushBeforeDisplayRefresh):
2593         (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
2594         * rendering/RenderLayerCompositor.h:
2595         * rendering/RenderLayerFilterInfo.cpp:
2596         (WebCore::RenderLayer::FilterInfo::map):
2597         (WebCore::RenderLayer::FilterInfo::get):
2598         * rendering/RenderLayerFilterInfo.h:
2599         * rendering/RenderRegion.cpp:
2600         (WebCore::RenderRegion::setRenderBoxRegionInfo):
2601         (WebCore::RenderRegion::takeRenderBoxRegionInfo):
2602         * rendering/RenderRegion.h:
2603         * rendering/RenderTable.cpp:
2604         (WebCore::RenderTable::styleDidChange):
2605         * rendering/RenderTable.h:
2606         * rendering/RenderView.cpp:
2607         (WebCore::RenderView::selectionBounds):
2608         (WebCore::RenderView::setSelection):
2609         (WebCore::RenderView::compositor):
2610         (WebCore::RenderView::flowThreadController):
2611         (WebCore::RenderView::imageQualityController):
2612         * rendering/RenderView.h:
2613         * rendering/RootInlineBox.h:
2614         (WebCore::RootInlineBox::appendFloat):
2615         * rendering/TextAutosizer.h:
2616         * rendering/shapes/PolygonShape.cpp:
2617         (WebCore::computeShapePaddingBounds):
2618         (WebCore::computeShapeMarginBounds):
2619         * rendering/shapes/PolygonShape.h:
2620         (WebCore::PolygonShape::PolygonShape):
2621         * rendering/shapes/RasterShape.cpp:
2622         (WebCore::RasterShapeIntervals::computeShapeMarginIntervals):
2623         * rendering/shapes/RasterShape.h:
2624         (WebCore::RasterShape::RasterShape):
2625         * rendering/shapes/Shape.cpp:
2626         (WebCore::createInsetShape):
2627         (WebCore::createRectangleShape):
2628         (WebCore::createCircleShape):
2629         (WebCore::createEllipseShape):
2630         (WebCore::createPolygonShape):
2631         (WebCore::Shape::createShape):
2632         (WebCore::Shape::createRasterShape):
2633         (WebCore::Shape::createLayoutBoxShape):
2634         * rendering/shapes/Shape.h:
2635         * rendering/shapes/ShapeInfo.h:
2636         (WebCore::ShapeInfo::markShapeAsDirty):
2637         (WebCore::ShapeInfo::isShapeDirty):
2638         * rendering/shapes/ShapeInsideInfo.h:
2639         * rendering/style/ContentData.h:
2640         * rendering/style/CounterDirectives.cpp:
2641         (WebCore::clone):
2642         * rendering/style/CounterDirectives.h:
2643         * rendering/style/GridCoordinate.h:
2644         * rendering/style/RenderStyle.cpp:
2645         (WebCore::RenderStyle::addCachedPseudoStyle):
2646         (WebCore::RenderStyle::accessCounterDirectives):
2647         (WebCore::RenderStyle::accessAnimations):
2648         (WebCore::RenderStyle::accessTransitions):
2649         * rendering/style/RenderStyle.h:
2650         * rendering/style/StyleRareNonInheritedData.cpp:
2651         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
2652         * rendering/style/StyleRareNonInheritedData.h:
2653         * rendering/svg/RenderSVGResourceGradient.cpp:
2654         (WebCore::RenderSVGResourceGradient::applyResource):
2655         * rendering/svg/RenderSVGResourceGradient.h:
2656         * rendering/svg/RenderSVGResourcePattern.cpp:
2657         (WebCore::RenderSVGResourcePattern::buildPattern):
2658         * rendering/svg/RenderSVGResourcePattern.h:
2659         * rendering/svg/RenderSVGShape.cpp:
2660         (WebCore::RenderSVGShape::updateShapeFromElement):
2661         * rendering/svg/RenderSVGShape.h:
2662         * rendering/svg/SVGResources.cpp:
2663         (WebCore::SVGResources::setClipper):
2664         (WebCore::SVGResources::setFilter):
2665         (WebCore::SVGResources::setMarkerStart):
2666         (WebCore::SVGResources::setMarkerMid):
2667         (WebCore::SVGResources::setMarkerEnd):
2668         (WebCore::SVGResources::setMasker):
2669         (WebCore::SVGResources::setFill):
2670         (WebCore::SVGResources::setStroke):
2671         * rendering/svg/SVGResources.h:
2672         * rendering/svg/SVGResourcesCache.cpp:
2673         (WebCore::SVGResourcesCache::addResourcesFromRenderer):
2674         (WebCore::SVGResourcesCache::removeResourcesFromRenderer):
2675         * rendering/svg/SVGResourcesCache.h:
2676         * rendering/svg/SVGTextMetricsBuilder.cpp:
2677         (WebCore::SVGTextMetricsBuilder::initializeMeasurementWithTextRenderer):
2678         * rendering/svg/SVGTextMetricsBuilder.h:
2679
2680 2014-03-28  Sergio Villar Senin  <svillar@igalia.com>
2681
2682         Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in loader
2683         https://bugs.webkit.org/show_bug.cgi?id=130893
2684
2685         Reviewed by Darin Adler.
2686
2687         * loader/ImageLoader.cpp:
2688         (WebCore::beforeLoadEventSender):
2689         (WebCore::loadEventSender):
2690         (WebCore::errorEventSender):
2691         * loader/appcache/ApplicationCacheStorage.cpp:
2692         (WebCore::cacheStorage):
2693         * loader/appcache/ApplicationCacheStorage.h:
2694         * loader/archive/ArchiveFactory.cpp:
2695         (WebCore::archiveMIMETypes):
2696         * loader/cache/CachedImage.cpp:
2697         (WebCore::CachedImage::brokenImage):
2698         * loader/cache/CachedRawResource.cpp:
2699         (WebCore::shouldIgnoreHeaderForCacheReuse):
2700         * loader/cache/MemoryCache.cpp:
2701         (WebCore::dummyCachedImageClient):
2702
2703 2014-03-28  Sergio Villar Senin  <svillar@igalia.com>
2704
2705         Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in css
2706         https://bugs.webkit.org/show_bug.cgi?id=130409
2707
2708         Reviewed by Darin Adler.
2709
2710         * css/CSSComputedStyleDeclaration.cpp:
2711         (WebCore::logUnimplementedPropertyID):
2712         * css/CSSDefaultStyleSheets.cpp:
2713         (WebCore::screenEval):
2714         (WebCore::printEval):
2715         * css/CSSParser.cpp:
2716         (WebCore::strictCSSParserContext):
2717         * css/CSSPrimitiveValue.cpp:
2718         (WebCore::cssTextCache):
2719         * css/CSSProperty.cpp:
2720         (WebCore::borderDirections):
2721         * css/CSSStyleRule.cpp:
2722         (WebCore::selectorTextCache):
2723         * css/CSSValuePool.cpp:
2724         (WebCore::cssValuePool):
2725         * css/CSSValuePool.h:
2726         * css/DeprecatedStyleBuilder.cpp:
2727         (WebCore::ApplyPropertyPageSize::getPageSizeFromName):
2728         (WebCore::DeprecatedStyleBuilder::sharedStyleBuilder):
2729         * css/DeprecatedStyleBuilder.h:
2730
2731 2014-03-30  Xabier Rodriguez Calvar  <calvaris@igalia.com>
2732
2733         [GTK] [TextureMapper] Weird brightness with some videos with acceletared compositing
2734         https://bugs.webkit.org/show_bug.cgi?id=130665
2735
2736         Reviewed by Martin Robinson.
2737
2738         When we uploaded a video texture to the mapper we were not
2739         considering that some videos could be decoded into a format
2740         without alpha component. Now we check if the video has alpha and
2741         if it does not, we remove the alpha flag when retrieving the
2742         texture from the pool. For this, the method to get the texture
2743         from the pool was modified to receive the flags, that is mapped to
2744         have alpha by default in order not to break any other existing
2745         code.
2746
2747         Though we have a problem with AC in WTR and that makes it
2748         currently not testable, no new tests are needed because once this
2749         is fixed the current test set suffices to detect a possible
2750         regression in this.
2751
2752         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
2753         (WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): Check
2754         the video format and decide if the texture shall be pulled with
2755         alpha support or not.
2756         * platform/graphics/texmap/TextureMapper.cpp:
2757         (WebCore::TextureMapper::acquireTextureFromPool): Use the flags
2758         when resetting the texture.
2759         * platform/graphics/texmap/TextureMapper.h:
2760         (WebCore::BitmapTexture::Flag::None): Added with 0x00.
2761         (WebCore::TextureMapper::acquireTextureFromPool): Added flag
2762         parameter to set up the texture with the default for including
2763         alpha channel.
2764
2765 2014-03-30  Jinwoo Song  <jinwoo7.song@samsung.com>
2766
2767         Adopt range-based for loops to TextCheckerEnchant
2768         https://bugs.webkit.org/show_bug.cgi?id=130714
2769
2770         Reviewed by Darin Adler.
2771
2772         * platform/text/enchant/TextCheckerEnchant.cpp:
2773         (WebCore::TextCheckerEnchant::ignoreWord):
2774         (WebCore::TextCheckerEnchant::learnWord):
2775         (WebCore::TextCheckerEnchant::checkSpellingOfWord):
2776         (WebCore::TextCheckerEnchant::getGuessesForWord):
2777         (WebCore::TextCheckerEnchant::updateSpellCheckingLanguages):
2778         (WebCore::TextCheckerEnchant::loadedSpellCheckingLanguages):
2779         (WebCore::TextCheckerEnchant::availableSpellCheckingLanguages):
2780         (WebCore::TextCheckerEnchant::freeEnchantBrokerDictionaries):
2781
2782 2014-03-30  Benjamin Poulain  <benjamin@webkit.org>
2783
2784         Second attempt to fix 32bits build after r166465
2785
2786         * rendering/style/RenderStyle.h:
2787         The compiler probably complain about the return value, that makes more sense.
2788
2789 2014-03-30  Benjamin Poulain  <benjamin@webkit.org>
2790
2791         Attempt to fix 32bits build after r166465
2792
2793         * rendering/style/RenderStyle.h:
2794
2795 2014-03-30  Benjamin Poulain  <benjamin@webkit.org>
2796
2797         Make RenderStyle's non inherited flags more JSC friendly
2798         https://bugs.webkit.org/show_bug.cgi?id=130939
2799
2800         Reviewed by Andreas Kling.
2801
2802         Make RenderStyle::NonInheritedFlags accessible to the JIT:
2803         -Make the struct public to give access to the offset.
2804         -Move away from a bit field to static offsets we can use
2805          with the MacroAssembler.
2806         -Reorder the field to simplify bit access of the flags we need.
2807
2808         * css/DeprecatedStyleBuilder.cpp:
2809         (WebCore::ApplyPropertyVerticalAlign::createHandler):
2810         (WebCore::ApplyPropertyDisplay::applyInitialValue):
2811         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
2812         * css/StyleResolver.cpp:
2813         (WebCore::StyleResolver::adjustRenderStyle):
2814         * rendering/style/RenderStyle.cpp:
2815         (WebCore::RenderStyle::RenderStyle):
2816         (WebCore::RenderStyle::copyNonInheritedFrom):
2817         (WebCore::RenderStyle::hashForTextAutosizing):
2818         (WebCore::RenderStyle::equalForTextAutosizing):
2819         (WebCore::RenderStyle::changeRequiresLayout):
2820         * rendering/style/RenderStyle.h:
2821         (WebCore::RenderStyle::hasAnyPublicPseudoStyles):
2822         (WebCore::RenderStyle::hasPseudoStyle):
2823         (WebCore::RenderStyle::setHasPseudoStyle):
2824         * rendering/style/StyleMultiColData.cpp:
2825         (WebCore::StyleMultiColData::StyleMultiColData):
2826         * rendering/style/StyleRareNonInheritedData.cpp:
2827         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
2828
2829 2014-03-30  David Kilzer  <ddkilzer@apple.com>
2830
2831         [iOS] Fix build of HTMLConverter.mm after r166454
2832
2833         Fixes the following build failures:
2834
2835             WebCore/editing/cocoa/HTMLConverter.mm:1507:13: error: value of type 'WebCore::Element' is not contextually convertible to 'bool'
2836                     if (element)
2837                         ^~~~~~~
2838             WebCore/editing/cocoa/HTMLConverter.mm:1508:49: error: no matching function for call to 'core'
2839                         _caches->floatPropertyValueForNode(*core(element), CSSPropertyVerticalAlign, verticalAlign);
2840                                                             ^~~~
2841             In file included from WebCore/editing/cocoa/HTMLConverter.mm:41:
2842             In file included from WebCore/page/Frame.h:42:
2843             In file included from WebCore/editing/VisibleSelection.h:30:
2844             In file included from WebCore/editing/VisiblePosition.h:30:
2845             In file included from WebCore/dom/Position.h:31:
2846             WebCore/editing/TextAffinity.h:54:27: note: candidate function not viable: no known conversion from 'WebCore::Element' to 'NSSelectionAffinity' (aka '_NSSelectionAffinity') for 1st argument
2847             inline WebCore::EAffinity core(NSSelectionAffinity affinity)
2848                                       ^
2849             WebCore/editing/cocoa/HTMLConverter.mm:1509:81: error: reference to non-static member function must be called; did you mean to call it with no arguments?
2850                     attachment.get().bounds = CGRectMake(0, (verticalAlign / 100) * element.clientHeight, element.clientWidth, element.clientHeight);
2851                                                                                     ~~~~~~~~^~~~~~~~~~~~
2852                                                                                                         ()
2853             WebCore/editing/cocoa/HTMLConverter.mm:1509:103: error: reference to non-static member function must be called; did you mean to call it with no arguments?
2854                     attachment.get().bounds = CGRectMake(0, (verticalAlign / 100) * element.clientHeight, element.clientWidth, element.clientHeight);
2855                                                                                                           ~~~~~~~~^~~~~~~~~~~
2856                                                                                                                              ()
2857             WebCore/editing/cocoa/HTMLConverter.mm:1509:124: error: reference to non-static member function must be called; did you mean to call it with no arguments?
2858                     attachment.get().bounds = CGRectMake(0, (verticalAlign / 100) * element.clientHeight, element.clientWidth, element.clientHeight);
2859                                                                                                                                ~~~~~~~~^~~~~~~~~~~~
2860                                                                                                                                                    ()
2861             5 errors generated.
2862
2863         * editing/cocoa/HTMLConverter.mm:
2864         (HTMLConverter::_addAttachmentForElement):
2865
2866 2014-03-30  Andreas Kling  <akling@apple.com>
2867
2868         Make NodeList and HTMLCollection caching helpers use PassRef.
2869         <https://webkit.org/b/130943>
2870
2871         Tweak the helpers in NodeListsNodeData to return PassRef instead of
2872         PassRefPtr. This knocks 2 branches off of some pretty hot code on
2873         Dromaeo/dom-query.
2874
2875         Reviewed by Antti Koivisto.
2876
2877         * dom/ChildNodeList.h:
2878         * dom/ClassNodeList.h:
2879         * dom/NameNodeList.h:
2880         * dom/NodeRareData.h:
2881         (WebCore::NodeListsNodeData::ensureChildNodeList):
2882         (WebCore::NodeListsNodeData::ensureEmptyChildNodeList):
2883         (WebCore::NodeListsNodeData::addCacheWithAtomicName):
2884         (WebCore::NodeListsNodeData::addCacheWithName):
2885         (WebCore::NodeListsNodeData::addCacheWithQualifiedName):
2886         (WebCore::NodeListsNodeData::addCachedCollection):
2887         * dom/TagNodeList.h:
2888         * html/HTMLCollection.cpp:
2889         (WebCore::HTMLCollection::create):
2890         * html/HTMLCollection.h:
2891         * html/HTMLFormControlsCollection.cpp:
2892         (WebCore::HTMLFormControlsCollection::create):
2893         * html/HTMLFormControlsCollection.h:
2894         * html/RadioNodeList.h:
2895
2896 2014-03-29  Antti Koivisto  <antti@apple.com>
2897
2898         LiveNodeLists should use ElementDescendantIterator
2899         https://bugs.webkit.org/show_bug.cgi?id=130931
2900
2901         Reviewed by Andreas Kling.
2902         
2903         Make LiveNodeList traversal use the common DOM tree iterator.
2904
2905         * dom/ChildNodeList.cpp:
2906         (WebCore::ChildNodeList::ChildNodeList):
2907         (WebCore::ChildNodeList::collectionBegin):
2908         (WebCore::ChildNodeList::collectionTraverseForward):
2909         (WebCore::ChildNodeList::collectionTraverseBackward):
2910         (WebCore::ChildNodeList::invalidateCache):
2911         (WebCore::ChildNodeList::collectionFirst): Deleted.
2912         
2913             Iterator for ChildNodeList is still just Node*.
2914
2915         * dom/ChildNodeList.h:
2916         * dom/CollectionIndexCache.h:
2917         (WebCore::CollectionIndexCache::hasValidCache):
2918         (WebCore::Iterator>::CollectionIndexCache):
2919         (WebCore::Iterator>::nodeCount):
2920         (WebCore::Iterator>::computeNodeCountUpdatingListCache):
2921         (WebCore::Iterator>::traverseBackwardTo):
2922         (WebCore::Iterator>::traverseForwardTo):
2923         (WebCore::Iterator>::nodeAt):
2924         (WebCore::Iterator>::invalidate):
2925         
2926             Make CollectionIndexCache iterator based instead of using NodeType*. The iterator type may
2927             still be a Node* though.
2928
2929         (WebCore::NodeType>::CollectionIndexCache): Deleted.
2930         (WebCore::NodeType>::nodeCount): Deleted.
2931         (WebCore::NodeType>::computeNodeCountUpdatingListCache): Deleted.
2932         (WebCore::NodeType>::nodeBeforeCached): Deleted.
2933         (WebCore::NodeType>::nodeAfterCached): Deleted.
2934         (WebCore::NodeType>::nodeAt): Deleted.
2935         (WebCore::NodeType>::invalidate): Deleted.
2936         * dom/ElementDescendantIterator.h:
2937         (WebCore::ElementDescendantIterator::operator--):
2938         
2939             Add backward iteration support.
2940
2941         (WebCore::ElementDescendantIteratorAdapter::last):
2942         (WebCore::ElementDescendantConstIteratorAdapter::last):
2943         
2944             Add a way to get the last item.
2945             Provide std::iterator_traits so we can extract the type.
2946
2947         * dom/LiveNodeList.h:
2948         (WebCore::CachedLiveNodeList::collectionEnd):
2949         (WebCore::CachedLiveNodeList<NodeListType>::CachedLiveNodeList):
2950         (WebCore::CachedLiveNodeList<NodeListType>::~CachedLiveNodeList):
2951         (WebCore::CachedLiveNodeList<NodeListType>::collectionBegin):
2952         (WebCore::CachedLiveNodeList<NodeListType>::collectionLast):
2953         (WebCore::CachedLiveNodeList<NodeListType>::collectionTraverseForward):
2954         (WebCore::CachedLiveNodeList<NodeListType>::collectionTraverseBackward):
2955         (WebCore::CachedLiveNodeList<NodeListType>::invalidateCache):
2956         (WebCore::CachedLiveNodeList<NodeListType>::collectionFirst): Deleted.
2957         
2958             Make LiveNodeList traversal use ElementDescendantIterator.
2959
2960         (WebCore::nextMatchingElement): Deleted.
2961         (WebCore::previousMatchingElement): Deleted.
2962         * html/HTMLCollection.cpp:
2963         (WebCore::HTMLCollection::HTMLCollection):
2964         (WebCore::HTMLCollection::~HTMLCollection):
2965         (WebCore::HTMLCollection::collectionBegin):
2966         (WebCore::HTMLCollection::collectionTraverseForward):
2967         (WebCore::HTMLCollection::collectionTraverseBackward):
2968         (WebCore::HTMLCollection::invalidateCache):
2969         (WebCore::HTMLCollection::collectionFirst): Deleted.
2970         * html/HTMLCollection.h:
2971         (WebCore::HTMLCollection::collectionEnd):
2972         
2973             HTMLCollection still uses Element* as iterator for now.
2974
2975 2014-03-29  Commit Queue  <commit-queue@webkit.org>
2976
2977         Unreviewed, rolling out r166434.
2978         https://bugs.webkit.org/show_bug.cgi?id=130938
2979
2980         Caused crashes and other failures on cache tests (Requested by
2981         ap on #webkit).
2982
2983         Reverted changeset:
2984
2985         "Web Replay: add page-level setting to bypass the MemoryCache"
2986         https://bugs.webkit.org/show_bug.cgi?id=130728
2987         http://trac.webkit.org/changeset/166434
2988
2989 2014-03-29  David Kilzer  <ddkilzer@apple.com>
2990
2991         Preserve selection end positions in directionOfSelection
2992         <http://webkit.org/b/104813>
2993         <rdar://problem/13666417>
2994
2995         Reviewed by Brent Fulgham.
2996
2997         Merged from Blink (patch by kenrb@chromium.org):
2998         https://src.chromium.org/viewvc/blink?revision=150621&view=revision
2999         http://crbug.com/164263
3000
3001             VisibleSelection::visibleStart() and VisibleSelection::visibleEnd()
3002             can both cause layouts, which has the potential to invalidate any
3003             rendertree-based objects. This was causing a problem in
3004             FrameSelection::directionOfSelection(), where a reference to a
3005             lineBox was being held across a call to visibleEnd().
3006
3007             This patch ensures that the any layout is completed before linebox
3008             references are retrieved.
3009
3010         Test: editing/selection/layout-during-move-selection-crash.html
3011
3012         * editing/FrameSelection.cpp:
3013         (WebCore::FrameSelection::directionOfSelection):
3014
3015 2014-03-29  Zalan Bujtas  <zalan@apple.com>
3016
3017         Subpixel rendering: Simple line layout should not round to integral position while painting.
3018         https://bugs.webkit.org/show_bug.cgi?id=130934
3019
3020         Reviewed by Simon Fraser.
3021
3022         Remove rounding to integral position. When RenderLayer is injected and hides subpixel positions,
3023         integral rounding produces different paint position.
3024
3025         Test: fast/flexbox/hidpi-simple-line-layout-with-flexbox-and-transition.html
3026
3027         * rendering/SimpleLineLayoutFunctions.cpp:
3028         (WebCore::SimpleLineLayout::paintFlow):
3029
3030 2014-03-29  Zalan Bujtas  <zalan@apple.com>
3031
3032         Subpixel rendering: Make GraphicsContext::drawImageBuffer* functions float based.
3033         https://bugs.webkit.org/show_bug.cgi?id=130932
3034
3035         Reviewed by Simon Fraser.
3036         
3037         This is in preparation to support device pixel based filter painting.
3038         Filter calculation is still integral based.
3039
3040         No change in behavior.
3041
3042         * platform/graphics/GraphicsContext.cpp:
3043         (WebCore::GraphicsContext::drawImageBuffer):
3044         * platform/graphics/GraphicsContext.h:
3045         * platform/graphics/filters/FilterEffect.cpp: This will eventually be fully float based.
3046         Right now, this IntRect->FloatRect change is only to ensure that we can call 
3047         the float based drawImageBuffer(). 
3048         (WebCore::FilterEffect::drawingRegionOfInputImage):
3049         * platform/graphics/filters/FilterEffect.h:
3050
3051 2014-03-27  Sam Weinig  <sam@webkit.org>
3052
3053         Convert yet more of HTMLConverter to C++
3054         https://bugs.webkit.org/show_bug.cgi?id=130850
3055
3056         Reviewed by Anders Carlsson.
3057
3058         * editing/cocoa/HTMLConverter.mm:
3059         (HTMLConverterCaches::isAncestorsOfStartToBeConverted):
3060         (HTMLConverter::HTMLConverter):
3061         (HTMLConverter::~HTMLConverter):
3062         (HTMLConverter::convert):
3063         (HTMLConverter::computedAttributesForElement):
3064         (HTMLConverter::attributesForElement):
3065         (HTMLConverter::_newParagraphForElement):
3066         (HTMLConverter::_newLineForElement):
3067         (HTMLConverter::_newTabForElement):
3068         (HTMLConverter::_addAttachmentForElement):
3069         (HTMLConverter::_addQuoteForElement):
3070         (HTMLConverter::_addValue):
3071         (HTMLConverter::_processHeadElement):
3072         (HTMLConverter::_enterElement):
3073         (HTMLConverter::_addTableCellForElement):
3074         (HTMLConverter::_processElement):
3075         (HTMLConverter::_addMarkersToList):
3076         (HTMLConverter::_exitElement):
3077         (HTMLConverter::_processText):
3078         (HTMLConverter::_traverseNode):
3079         (HTMLConverter::_traverseFooterNode):
3080         (WebCore::attributedStringFromRange):
3081         (_childrenForNode): Deleted.
3082         (HTMLConverter::_computedAttributesForElement): Deleted.
3083         (HTMLConverter::_attributesForElement): Deleted.
3084         (HTMLConverter::_loadFromDOMRange): Deleted.
3085
3086 2014-03-28  Csaba Osztrogonác  <ossy@webkit.org>
3087
3088         Unreviewed buildfix after r166441 and r166443.
3089
3090         * CMakeLists.txt: Add platform/audio/AudioHardwareListener.cpp.
3091
3092 2014-03-28  Javier Fernandez  <jfernandez@igalia.com>
3093
3094         [CSS Grid Layout] The 'auto' height must be adapted to the item's margin.
3095         https://bugs.webkit.org/show_bug.cgi?id=130920
3096
3097         Reviewed by Darin Adler.
3098
3099         Adding the grid-item's marginLogicalHeight to the used breadth when computing
3100         content based grid-track sizes.
3101
3102         Test: fast/css-grid-layout/grid-item-margin-auto-columns-rows.html
3103
3104         * rendering/RenderGrid.cpp:
3105         (WebCore::RenderGrid::logicalContentHeightForChild):
3106
3107 2014-03-28  James Craig  <jcraig@apple.com>
3108
3109         Web Inspector: AXI: support for live regions
3110         https://bugs.webkit.org/show_bug.cgi?id=130725
3111
3112         Reviewed by Timothy Hatcher.
3113
3114         Tests: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
3115                inspector-protocol/dom/getAccessibilityPropertiesForNode_liveRegion.html
3116
3117         Initial support for @aria-live, @aria-atomic, and @aria-busy.
3118
3119         * inspector/InspectorDOMAgent.cpp:
3120         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
3121         * inspector/protocol/DOM.json:
3122
3123 2014-03-28  Darin Adler  <darin@apple.com>
3124
3125         Fix recently-introduced off-by-one error in centerTruncateToBuffer
3126         https://bugs.webkit.org/show_bug.cgi?id=130889
3127         <rdar://problem/16408694>
3128
3129         Reviewed by Alexey Proskuryakov.
3130
3131         * platform/graphics/StringTruncator.cpp:
3132         (WebCore::centerTruncateToBuffer): Simplified expression that computes truncatedLength.
3133         Removed incorrect "+ 1" from computation of where to write characters.
3134
3135 2014-03-28  Benjamin Poulain  <bpoulain@apple.com>
3136
3137         Update the code related to SelectorPseudoTypeMap to reflect its new purpose
3138         https://bugs.webkit.org/show_bug.cgi?id=130620
3139
3140         Reviewed by Andreas Kling.
3141
3142         Since r166094, SelectorPseudoTypeMap only contains PseudoClass instances and the 4 compatibility PseudoElement.
3143
3144         This patch rename SelectorPseudoTypeMap to SelectorPseudoClassAndCompatibilityElementMap and update the parsing
3145         to split PseudoClass and PseudoElement.
3146
3147         * CMakeLists.txt:
3148         * DerivedSources.make:
3149         * WebCore.xcodeproj/project.pbxproj:
3150         * css/CSSGrammar.y.in:
3151         * css/CSSParserValues.cpp:
3152         (WebCore::CSSParserSelector::parsePseudoClassAndCompatibilityElementSelector):
3153         (WebCore::CSSParserSelector::setPseudoClassValue):
3154         * css/CSSParserValues.h:
3155         * css/CSSSelector.cpp:
3156         (WebCore::appendPseudoClassFunctionTail):
3157         (WebCore::CSSSelector::selectorText):
3158         * css/SelectorPseudoClassAndCompatibilityElementMap.in: Renamed from Source/WebCore/css/SelectorPseudoTypeMap.in.
3159         * css/SelectorPseudoTypeMap.h:
3160         * css/makeSelectorPseudoClassAndCompatibilityElementMap.py: Renamed from Source/WebCore/css/makeSelectorPseudoTypeMap.py.
3161         (enumerablePseudoType):
3162         (expand_ifdef_condition):
3163
3164 2014-03-28  Stephanie Lewis  <slewis@apple.com>
3165
3166         Unreviewed build fix.
3167
3168         * platform/audio/AudioHardwareListener.cpp:
3169         (WebCore::AudioHardwareListener::create):
3170         (WebCore::AudioHardwareListener::audioHardwareListenerIsSupported): Deleted.
3171         * platform/audio/AudioHardwareListener.h:
3172
3173 2014-03-28  Lukasz Bialek  <l.bialek@samsung.com>
3174
3175         Refactor cut and copy functions as suggested in FIXME line
3176         https://bugs.webkit.org/show_bug.cgi?id=129867
3177
3178         Reviewed by Darin Adler.
3179
3180         Cut and Copy functions in Editor.cpp use lots of common code.
3181         Those functions are merged into one to share code, several
3182         additional conditions are added to preserve Cut and Copy
3183         functionality.
3184
3185         * editing/Editor.cpp:
3186         (WebCore::Editor::cut):
3187         (WebCore::Editor::copy):
3188         (WebCore::Editor::performCutOrCopy):
3189         * editing/Editor.h:
3190
3191 2014-03-28  Stephanie Lewis  <slewis@apple.com>
3192
3193         Rename pluginDidEvaluate to better represent when it’s called.
3194         Part of <rdar://problem/16061257> PluginProcess should AppNap when no plugins on active tab.
3195
3196         Reviewed by Anders Carlsson.
3197
3198         No new test because it’s just a name change.
3199
3200         * page/PageThrottler.h:
3201         (WebCore::PageThrottler::pluginDidEvaluateWhileAudioIsPlaying):
3202
3203 2014-03-28  Stephanie Lewis  <slewis@apple.com>
3204
3205         Notification handler for telling if audio hardware is active.
3206         https://bugs.webkit.org/show_bug.cgi?id=130743
3207
3208         Reviewed by Jer Noble.
3209
3210         Not web-exposed so no easy way to test.
3211
3212         Listen to CoreAudio to see if audio hardware is active in the current process.
3213
3214         * WebCore.exp.in:
3215         * WebCore.xcodeproj/project.pbxproj:
3216         * platform/audio/AudioHardwareListener.cpp: Added.
3217         (WebCore::AudioHardwareListener::create):
3218         (WebCore::AudioHardwareListener::AudioHardwareListener):
3219         * platform/audio/AudioHardwareListener.h: Added.
3220         (WebCore::AudioHardwareListener::Client::~Client):
3221         (WebCore::AudioHardwareListener::~AudioHardwareListener):
3222         (WebCore::AudioHardwareListener::isHardwareActive):
3223         * platform/audio/mac/AudioHardwareListenerMac.cpp: Added.
3224         (WebCore::isAudioHardwareProcessRunning):
3225         (WebCore::AudioHardwareListener::create):
3226         (WebCore::AudioHardwareListenerMac::create):
3227         (WebCore::AudioHardwareListenerMac::AudioHardwareListenerMac):
3228         (WebCore::AudioHardwareListenerMac::~AudioHardwareListenerMac):
3229         (WebCore::AudioHardwareListenerMac::setHardwareActive):
3230         * platform/audio/mac/AudioHardwareListenerMac.h: Added.
3231
3232 2014-03-28  James Craig  <jcraig@apple.com>
3233
3234         Web Inspector: AXI: expose what elements get generic "clickable" status
3235         https://bugs.webkit.org/show_bug.cgi?id=130721
3236
3237         Reviewed by Timothy Hatcher.
3238
3239         Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html:
3240         Test: inspector-protocol/dom/getAccessibilityPropertiesForNode_mouseEventNodeId.html
3241
3242         Expose ancestor element link to "Click Listener" or generic "Clickable: Yes" if current node has mouse handler.
3243
3244         Update AccessibilityNodeObject::mouseButtonListener() to optionally return body element if 
3245             requested so that Web Inspector can display body event delegate handlers.
3246
3247         * accessibility/AccessibilityNodeObject.cpp:
3248         (WebCore::AccessibilityNodeObject::mouseButtonListener):
3249         * accessibility/AccessibilityNodeObject.h:
3250         * inspector/InspectorDOMAgent.cpp:
3251         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
3252         * inspector/protocol/DOM.json:
3253
3254 2014-03-28  Joseph Pecoraro  <pecoraro@apple.com>
3255
3256         Web Inspector: Really drop all locks in nested run loop on iOS if WebThread is enabled
3257         https://bugs.webkit.org/show_bug.cgi?id=130912
3258
3259         Reviewed by Geoffrey Garen.
3260
3261         Previously we were calling DropAllLocks inside of a single line if statement,
3262         so the JSLock was getting reaquired very quickly. We really want to DropAllLocks
3263         for the duration of running the nested run loop on iOS if there is a WebThread.
3264
3265         * bindings/js/PageScriptDebugServer.h:
3266         * bindings/js/PageScriptDebugServer.cpp:
3267         (WebCore::PageScriptDebugServer::runEventLoopWhilePaused):
3268         (WebCore::PageScriptDebugServer::runEventLoopWhilePausedInternal):
3269
3270 2014-03-28  Brent Fulgham  <bfulgham@apple.com>
3271
3272         [Win] Enable Media Track testing features on Windows
3273         https://bugs.webkit.org/show_bug.cgi?id=130851
3274
3275         Reviewed by Eric Carlson.
3276
3277         * testing/Internals.cpp:
3278         (WebCore::Internals::resetToConsistentState): Execute code on Windows as well.
3279         (WebCore::Internals::Internals): Ditto.
3280         (WebCore::Internals::captionsStyleSheetOverride): Ditto.
3281         (WebCore::Internals::setCaptionsStyleSheetOverride): Ditto.
3282         (WebCore::Internals::setPrimaryAudioTrackLanguageOverride): Ditto.
3283         (WebCore::Internals::setCaptionDisplayMode): Ditto.
3284
3285 2014-03-28  Brian Burg  <bburg@apple.com>
3286
3287         Web Replay: add page-level setting to bypass the MemoryCache
3288         https://bugs.webkit.org/show_bug.cgi?id=130728
3289
3290         Reviewed by Timothy Hatcher.
3291
3292         When replaying a specific Page we don't want to store its cached resources in the
3293         MemoryCache. This patch adds a page setting to prevent the page's resources from
3294         being saved in the MemoryCache.
3295
3296         If Settings::usesMemoryCache() is false, page resources are given the special
3297         SessionID bypassCacheSessionID(). The cached resource loader and memory cache
3298         act as if the memory cache is disabled if the resource has this special session id.
3299
3300         Hook up ReplayController to override the memory cache setting during capture/replay.
3301
3302         Test: http/tests/cache/bypass-memory-cache-after-reload.html
3303
3304         * loader/cache/CachedResourceLoader.cpp:
3305         (WebCore::CachedResourceLoader::requestResource):
3306         (WebCore::CachedResourceLoader::revalidateResource):
3307         * loader/cache/MemoryCache.cpp:
3308         (WebCore::MemoryCache::add):
3309         * page/Page.cpp:
3310         (WebCore::Page::sessionID):
3311         * page/SessionID.h:
3312         (WebCore::SessionID::bypassCacheSessionID):
3313         * page/Settings.cpp:
3314         (WebCore::Settings::Settings):
3315         * page/Settings.h:
3316         (WebCore::Settings::setUsesMemoryCache):
3317         (WebCore::Settings::usesMemoryCache):
3318         * replay/ReplayController.cpp:
3319         (WebCore::ReplayController::setForceDeterministicSettings):
3320         * replay/ReplayController.h:
3321         * testing/InternalSettings.cpp:
3322         (WebCore::InternalSettings::Backup::Backup):
3323         (WebCore::InternalSettings::Backup::restoreTo):
3324         (WebCore::InternalSettings::setUsesMemoryCache):
3325         * testing/InternalSettings.h:
3326         * testing/InternalSettings.idl:
3327
3328 2014-03-28  Radu Stavila  <stavila@adobe.com>
3329
3330         In some situations, partial layouts of floating elements produce incorrect results.
3331         https://bugs.webkit.org/show_bug.cgi?id=122668
3332
3333         Reviewed by David Hyatt.
3334
3335         When performing partial layout of float elements and checking if other float
3336         elements are encountered, incorrect results were obtained by not checking
3337         the size of the existing floats vector.
3338
3339         Test: fast/block/float/floats-in-clean-line-crash.html
3340
3341         * rendering/RenderBlockLineLayout.cpp:
3342         (WebCore::RenderBlockFlow::checkFloatsInCleanLine):
3343
3344 2014-03-28  Beth Dakin  <bdakin@apple.com>
3345
3346         Build fix.
3347
3348         * rendering/RenderTheme.cpp:
3349         (WebCore::RenderTheme::paint):
3350
3351 2014-03-28  Jer Noble  <jer.noble@apple.com>
3352
3353         [MSE] Implement support for SourceBuffer.remove()
3354         https://bugs.webkit.org/show_bug.cgi?id=121562
3355
3356         Reviewed by Eric Carlson.
3357
3358         Test: media/media-source/media-source-remove.html
3359
3360         Add support for SourceBuffer.remove().
3361
3362         * Modules/mediasource/SourceBuffer.cpp:
3363         (WebCore::SourceBuffer::SourceBuffer): Initialize new member variables.
3364         (WebCore::SourceBuffer::setTimestampOffset): Update comments to match spec.
3365         (WebCore::SourceBuffer::remove): Added; start removeTimer.
3366         (WebCore::SourceBuffer::abortIfUpdating): Cancel removeTimer.
3367         (WebCore::SourceBuffer::removedFromMediaSource): Call abortIfUpdating().
3368         (WebCore::SourceBuffer::stop): Cancel removeTimer.
3369         (WebCore::SourceBuffer::removeCodedFrames): Added.
3370         (WebCore::SourceBuffer::removeTimerFired): Added.
3371         * Modules/mediasource/SourceBuffer.h:
3372         * Modules/mediasource/SourceBuffer.idl:
3373
3374 2014-03-27  Dean Jackson  <dino@apple.com>
3375
3376         Support form controls that may need incremental redraw
3377         https://bugs.webkit.org/show_bug.cgi?id=130736
3378
3379         Reviewed by Beth Dakin.
3380
3381         There are some form controls that change appearance
3382         over time. Expand the ControlStates so that it can
3383         hold a little more information, including a reference
3384         to the native form control. This way the Theme implementation
3385         can repaint the existing native control if necessary. At
3386         least ThemeMac was reusing a single control for painting
3387         all instances before this change.
3388
3389         Since ControlStates is now a class, pass it around by
3390         reference.
3391
3392         The other major change is keeping a timer to trigger a
3393         repaint in RenderBox, which happens if Theme/RenderTheme
3394         update the ControlState to request one.
3395
3396         * WebCore.xcodeproj/project.pbxproj: Add ControlStates.h.
3397         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
3398         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
3399         * dom/Element.cpp:
3400         (WebCore::Element::setActive): States now within ControlStates.
3401         (WebCore::Element::setHovered): Ditto.
3402         * editing/FrameSelection.cpp:
3403         (WebCore::FrameSelection::focusedOrActiveStateChanged): Ditto.
3404         * html/HTMLFormControlElement.cpp:
3405         (WebCore::HTMLFormControlElement::disabledStateChanged): Ditto.
3406         (WebCore::HTMLFormControlElement::readOnlyAttributeChanged): Ditto.
3407         * html/HTMLInputElement.cpp:
3408         (WebCore::HTMLInputElement::setChecked): Ditto.
3409         (WebCore::HTMLInputElement::setIndeterminate): Ditto.
3410         * html/HTMLOptionElement.cpp:
3411         (WebCore::HTMLOptionElement::parseAttribute): Ditto.
3412         * platform/ControlStates.h: New file. Copied the old ControlStates enum,
3413         and added accessors to hold whether or not the state is dirty, and
3414         a reference to a platform control if necessary.
3415         * platform/Theme.h:
3416         (WebCore::Theme::selectionColor): Pass ControlStates pointer.
3417         (WebCore::Theme::paint): Ditto.
3418         (WebCore::Theme::inflateControlPaintRect): Ditto.
3419         * platform/ThemeTypes.h: Remove ControlStates enum.
3420         * platform/efl/RenderThemeEfl.cpp:
3421         (WebCore::RenderThemeEfl::applyEdjeStateFromForm): Pass ControlStates pointer.
3422         (WebCore::RenderThemeEfl::paintThemePart): Ditto.
3423         * platform/efl/RenderThemeEfl.h: Ditto.
3424         * platform/mac/ThemeMac.h: Ditto.
3425         * platform/mac/ThemeMac.mm:
3426         (-[WebCoreThemeView addSubview:]): New method to make sure we don't add CALayer backed
3427         views to the NSView we're using for rendering.
3428         (WebCore::updateStates): Use the private animated setters if necessary.
3429         (WebCore::convertControlStatesToThemeDrawState): Namespacing.
3430         (WebCore::configureCheckbox): Pass ControlStates pointer.
3431         (WebCore::createCheckboxCell): New helper since we're creating non-static cells.
3432         (WebCore::sharedCheckboxCell): The old static provider, renamed.
3433         (WebCore::paintCheckbox): Check if this paint was triggered by a state change
3434         or an animation. Update the ControlStates if we need to be repainted.
3435         (WebCore::radio): Parameter is now ControlStates*.
3436         (WebCore::paintRadio): Ditto.
3437         (WebCore::setUpButtonCell): Ditto.