Use references in public EventSender functions
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-09-02  Myles C. Maxfield  <mmaxfield@apple.com>
2
3         Use references in public EventSender functions
4         https://bugs.webkit.org/show_bug.cgi?id=136463
5
6         Reviewed by Dan Bates.
7
8         Passing nullptr to EventSender shouldn't be allowed.
9
10         No new tests because there is no behavior change.
11
12         * dom/EventSender.h:
13         (WebCore::EventSender::hasPendingEvents):
14         (WebCore::EventSender<T>::dispatchEventSoon):
15         (WebCore::EventSender<T>::cancelEvent):
16         (WebCore::EventSender<T>::dispatchPendingEvents):
17         * html/HTMLLinkElement.cpp:
18         (WebCore::HTMLLinkElement::~HTMLLinkElement):
19         (WebCore::HTMLLinkElement::notifyLoadedSheetAndAllCriticalSubresources):
20         * html/HTMLStyleElement.cpp:
21         (WebCore::HTMLStyleElement::~HTMLStyleElement):
22         (WebCore::HTMLStyleElement::notifyLoadedSheetAndAllCriticalSubresources):
23         * loader/ImageLoader.cpp:
24         (WebCore::ImageLoader::~ImageLoader):
25         (WebCore::ImageLoader::setImageWithoutConsideringPendingLoadEvent):
26         (WebCore::ImageLoader::updateFromElement):
27         (WebCore::ImageLoader::notifyFinished):
28         (WebCore::ImageLoader::dispatchPendingBeforeLoadEvent):
29
30 2014-09-02  Daniel Bates  <dabates@apple.com>
31
32         [iOS] Exclude touch and gesture files when building without ENABLE_TOUCH_EVENTS
33         and ENABLE_IOS_GESTURE_EVENTS, respectively
34         https://bugs.webkit.org/show_bug.cgi?id=136456
35
36         Reviewed by Andy Estes.
37
38         It's sufficient to exclude the touch and gesture files when building without
39         ENABLE_TOUCH_EVENTS and ENABLE_IOS_GESTURE_EVENTS, respectively. Currently we
40         exclude these files when building without the Apple Internal SDK, which is
41         heavy handed.
42
43         * Configurations/WebCore.xcconfig:
44
45 2014-09-02  Simon Fraser  <simon.fraser@apple.com>
46
47         Fix an assertion sometimes seen under RenderLayerCompositor::detachRootLayer()
48         https://bugs.webkit.org/show_bug.cgi?id=136464
49
50         Reviewed by Tim Horton.
51
52         Don't try to call RenderLayer::isVisuallyNonEmpty() under RenderLayerCompositor::detachRootLayer()
53         when layout might be stale; there's not point trying to update the backing store state
54         when detaching, only when attaching.
55
56         * rendering/RenderLayerCompositor.cpp:
57         (WebCore::RenderLayerCompositor::rootLayerAttachmentChanged):
58
59 2014-09-02  Simon Fraser  <simon.fraser@apple.com>
60
61         Avoid backing store allocation with some combinations of replaced elements, masking and visibility:hidden
62         https://bugs.webkit.org/show_bug.cgi?id=136400
63
64         Reviewed by Tim Horton.
65         
66         RenderLayer::isVisuallyNonEmpty() would return true for replaced elements (e.g. images)
67         with visibility:hidden, and for layers with a mask, and both would cause additional
68         backing store in some cases.
69         
70         We can move the hasVisibleContent() to the top of the function, since visibility:hidden
71         will always hide any content of this layer. The hasMask() check can also be removed;
72         a mask can only mask content that is already visible; it never contributes additional
73         pixels.
74
75         Tests: compositing/backing/masked-child-no-backing.html
76                compositing/backing/replaced-child-no-backing.html
77
78         * rendering/RenderLayer.cpp:
79         (WebCore::RenderLayer::calculateClipRects):
80
81 2014-09-02  Joseph Pecoraro  <pecoraro@apple.com>
82
83         Use jsNontrivialString for strings we know are more than a single character
84         https://bugs.webkit.org/show_bug.cgi?id=136393
85
86         Reviewed by Geoffrey Garen.
87
88         * bindings/js/JSCryptoKeySerializationJWK.cpp:
89         (WebCore::addUsagesToJSON):
90
91 2014-09-02  Alex Christensen  <achristensen@webkit.org>
92
93         Fix bindings tests after r173176.
94         https://bugs.webkit.org/show_bug.cgi?id=136460
95
96         Reviewed by Simon Fraser.
97
98         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
99         * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
100         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
101         * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
102         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
103         * bindings/scripts/test/JS/JSTestEventConstructor.h:
104         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
105         * bindings/scripts/test/JS/JSTestEventTarget.h:
106         * bindings/scripts/test/JS/JSTestException.cpp:
107         * bindings/scripts/test/JS/JSTestException.h:
108         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
109         * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
110         * bindings/scripts/test/JS/JSTestInterface.cpp:
111         * bindings/scripts/test/JS/JSTestInterface.h:
112         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
113         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
114         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
115         * bindings/scripts/test/JS/JSTestNamedConstructor.h:
116         * bindings/scripts/test/JS/JSTestNode.cpp:
117         * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
118         * bindings/scripts/test/JS/JSTestNondeterministic.h:
119         * bindings/scripts/test/JS/JSTestObj.cpp:
120         * bindings/scripts/test/JS/JSTestObj.h:
121         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
122         * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
123         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
124         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
125         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
126         * bindings/scripts/test/JS/JSTestTypedefs.h:
127         * bindings/scripts/test/JS/JSattribute.cpp:
128         * bindings/scripts/test/JS/JSattribute.h:
129         * bindings/scripts/test/JS/JSreadonly.cpp:
130         * bindings/scripts/test/JS/JSreadonly.h:
131         * bindings/scripts/test/ObjC/DOMFloat64ArrayInternal.h:
132         * bindings/scripts/test/ObjC/DOMTestActiveDOMObjectInternal.h:
133         * bindings/scripts/test/ObjC/DOMTestCallbackInternal.h:
134         * bindings/scripts/test/ObjC/DOMTestCustomNamedGetterInternal.h:
135         * bindings/scripts/test/ObjC/DOMTestEventConstructorInternal.h:
136         * bindings/scripts/test/ObjC/DOMTestEventTargetInternal.h:
137         * bindings/scripts/test/ObjC/DOMTestExceptionInternal.h:
138         * bindings/scripts/test/ObjC/DOMTestGenerateIsReachableInternal.h:
139         * bindings/scripts/test/ObjC/DOMTestInterfaceInternal.h:
140         * bindings/scripts/test/ObjC/DOMTestMediaQueryListListenerInternal.h:
141         * bindings/scripts/test/ObjC/DOMTestNamedConstructorInternal.h:
142         * bindings/scripts/test/ObjC/DOMTestNodeInternal.h:
143         * bindings/scripts/test/ObjC/DOMTestNondeterministicInternal.h:
144         * bindings/scripts/test/ObjC/DOMTestObjInternal.h:
145         * bindings/scripts/test/ObjC/DOMTestOverloadedConstructorsInternal.h:
146         * bindings/scripts/test/ObjC/DOMTestSerializedScriptValueInterfaceInternal.h:
147         * bindings/scripts/test/ObjC/DOMTestTypedefsInternal.h:
148         * bindings/scripts/test/ObjC/DOMattributeInternal.h:
149         * bindings/scripts/test/ObjC/DOMreadonlyInternal.h:
150         Added new WEBCORE_EXPORT macros.
151
152 2014-09-02  Simon Fraser  <simon.fraser@apple.com>
153
154         Non-composited child RenderLayers cause allocation of unncessary backing store
155         https://bugs.webkit.org/show_bug.cgi?id=136375
156
157         Reviewed by David Hyatt.
158         
159         A composited element that has non-composited descendant elements that fall into
160         RenderLayers was getting backing store when none was required. descendentLayerPaintsIntoAncestor()
161         was simply checking the "visibility:visible" bit on descendant non-composited layers,
162         instead of actually asking them if they have any visual content.
163         
164         Added a couple of FIXME comments.
165
166         Test: compositing/backing/child-layer-no-backing.html
167
168         * rendering/RenderLayer.cpp:
169         (WebCore::RenderLayer::calculateClipRects):
170         * rendering/RenderLayerBacking.cpp:
171         (WebCore::descendentLayerPaintsIntoAncestor):
172
173 2014-09-02  Commit Queue  <commit-queue@webkit.org>
174
175         Unreviewed, rolling out r173175.
176         https://bugs.webkit.org/show_bug.cgi?id=136454
177
178         it broke debug builds (Requested by jessieberlin on #webkit).
179
180         Reverted changeset:
181
182         "Introduce CSS_BASIC_TYPE_CASTS, and use it"
183         https://bugs.webkit.org/show_bug.cgi?id=136403
184         http://trac.webkit.org/changeset/173175
185
186 2014-09-02  Alex Christensen  <achristensen@webkit.org>
187
188         More use of WEBCORE_EXPORT.
189
190         Reviewed by Darin Adler.
191
192         These changes from a patch attached to https://bugs.webkit.org/show_bug.cgi?id=136172
193         contain more deployment of the WEBCORE_EXPORT macro. As of this writing, the macro is
194         defined to do nothing, so landing these is a harmless way to get closer to be the point
195         where we can throw the switch to use these instead of explicit export files on OS X,
196         iOS, and Windows.
197
198         * bindings/js/JSDOMBinding.h:
199         * bindings/js/JSDOMGlobalObject.h:
200         * bindings/js/JSDOMWindowBase.h:
201         * bindings/scripts/CodeGeneratorJS.pm:
202         (GenerateHeader):
203         (GenerateImplementation):
204         * bindings/scripts/CodeGeneratorObjC.pm:
205         (GenerateHeader):
206         * bridge/runtime_method.cpp:
207         * bridge/runtime_object.cpp:
208         * dom/Document.h:
209         * dom/Element.h:
210         * dom/Position.h:
211         * dom/Range.h:
212         * dom/StaticNodeList.h:
213         * dom/make_names.pl:
214         (printInit):
215         (printNamesCppFile):
216         * editing/Editor.h:
217         * editing/FrameSelection.h:
218         * editing/TextIterator.h:
219         * inspector/InspectorFrontendClient.h:
220         * inspector/InspectorFrontendClientLocal.h:
221         * loader/DocumentLoader.h:
222         * loader/FrameLoader.h:
223         * loader/cache/MemoryCache.h:
224         * loader/cocoa/DiskCacheMonitorCocoa.h:
225         * loader/mac/LoaderNSURLExtras.h:
226         * page/Page.h:
227         * page/PageGroup.h:
228         * page/SecurityPolicy.h:
229         * page/Settings.h:
230         * page/make_settings.pl:
231         (printGetterAndSetter):
232         * page/scrolling/ScrollingStateScrollingNode.h:
233         * platform/CrossThreadCopier.h:
234         * platform/LocalizedStrings.h:
235         * platform/MemoryPressureHandler.cpp:
236         * platform/PlatformScreen.h:
237         * platform/PublicSuffix.h:
238         * platform/graphics/Gradient.h:
239         * platform/graphics/cocoa/WebActionDisablingCALayerDelegate.h:
240         * platform/graphics/filters/FilterOperation.h:
241         * platform/ios/WebVideoFullscreenControllerAVKit.h:
242         * platform/mac/PlatformEventFactoryMac.h:
243         * platform/mac/WebCoreFullScreenPlaceholderView.h:
244         * platform/mac/WebCoreFullScreenWindow.h:
245         * platform/mac/WebCoreNSStringExtras.h:
246         * platform/mac/WebCoreObjCExtras.h:
247         * platform/mac/WebFontCache.h:
248         * platform/mac/WebVideoFullscreenController.h:
249         * platform/mac/WebWindowAnimation.h:
250         * platform/network/BlobRegistryImpl.h:
251         * platform/network/CredentialStorage.h:
252         * platform/network/PlatformCookieJar.h:
253         * platform/network/ProxyServer.h:
254         * platform/sql/SQLiteStatement.h:
255         * platform/text/TextEncoding.h:
256         * rendering/HitTestResult.h:
257         * rendering/RenderTreeAsText.h:
258         * testing/Internals.h:
259         Add many more correct uses of WEBCORE_EXPORT; remove a few incorrect ones.
260
261 2014-09-02  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
262
263         Introduce CSS_BASIC_TYPE_CASTS, and use it
264         https://bugs.webkit.org/show_bug.cgi?id=136403
265
266         Reviewed by Darin Adler.
267
268         toCSSBasicFoo() will help to detect wrong type casting. So this patch generates it, and use it
269         instead of static_cast<const CSSBasicFoo*>().
270
271         No new tests no behavior changes.
272
273         * css/BasicShapeFunctions.cpp:
274         (WebCore::basicShapeForValue):
275         * css/CSSBasicShapes.cpp:
276         (WebCore::CSSBasicShapeCircle::equals):
277         (WebCore::CSSBasicShapeEllipse::equals):
278         (WebCore::CSSBasicShapePolygon::equals):
279         (WebCore::CSSBasicShapeInset::equals):
280         * css/CSSBasicShapes.h:
281
282 2014-09-02  Youenn Fablet  <youenn.fablet@crf.canon.fr>
283
284         CachedResourceLoader should check redirections to reuse or not cached resources
285         https://bugs.webkit.org/show_bug.cgi?id=131757
286
287         Reviewed by Antti Koivisto.
288
289         Added cache-control redirection check to properly determine revalidation policy.
290         Tightened redirection cache-control header check by testing for no-cache and must-revalidate directives.
291         Added redirection freshness check.
292
293         Test: http/tests/cache/cache-redirections.html
294
295         * loader/cache/CachedRawResource.cpp:
296         (WebCore::CachedRawResource::canReuse): Removed redirection check (now handled by CachedResource::redirectChainAllowsReuse).
297         * loader/cache/CachedResource.cpp:
298         (WebCore::currentAge): Moved from WebCore::CachedResource::currentAge method to static function. Added response and responseTimestamp as parameters.
299         (WebCore::CachedResource::CachedResource): Initialized redirection chain status (no redirection and expiracy date set to never).
300         (WebCore::CachedResource::isExpired): Updated according new currentAge/freshnessLifetime method parameters.
301         (WebCore::CachedResource::freshnessLifetime): Added response as parameter.
302         (WebCore::CachedResource::willSendRequest): Computes whether a redirection can be cached, and if cached for how long it will remain fresh.
303         (WebCore::CachedResource::redirectChainAllowsReuse): Return false if any of the redirection in the redirection chain cannot be cached or expired. 
304         * loader/cache/CachedResource.h: Added cache chain member that stores whether the redirection chain can be cached and if so when it will be expired.
305         * loader/cache/CachedResourceLoader.cpp:
306         (WebCore::CachedResourceLoader::determineRevalidationPolicy): Added check of the redirection chain.
307
308 2014-09-02  Daewoong Jang  <daewoong.jang@navercorp.com>
309
310         Prevent decoded images from being destroyed when they're in use.
311         https://bugs.webkit.org/show_bug.cgi?id=136259.
312
313         Reviewed by Darin Adler.
314
315         Try to fix a regression introduced by r172790. Before the patch,
316         CachedImage does not release its Image object if it still has clients.
317         However this behavior was changed due to removal of CachedResource::isSafeToMakePurgeable(),
318         which implied a call to CachedResource::hasClients(). This patch restores
319         the behavior by adding a check to hasClients() in CachedImage::destroyDecodedData().
320
321         * loader/cache/CachedImage.cpp:
322         (WebCore::CachedImage::destroyDecodedData):
323
324 2014-09-01  Tim Horton  <timothy_horton@apple.com>
325
326         RenderThemeMac::paintProgressBar creates a buffer without respecting the destination's acceleration setting
327         https://bugs.webkit.org/show_bug.cgi?id=136427
328
329         Reviewed by Dan Bernstein.
330
331         No new tests, just a performance improvement.
332
333         * rendering/RenderThemeMac.mm:
334         (WebCore::RenderThemeMac::paintProgressBar):
335
336 2014-09-01  Tim Horton  <timothy_horton@apple.com>
337
338         Remove an unnecessary local in GraphicsLayerCA::ensureStructuralLayer
339         https://bugs.webkit.org/show_bug.cgi?id=136426
340
341         Reviewed by Dan Bernstein.
342
343         * platform/graphics/ca/GraphicsLayerCA.cpp:
344         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
345         This was here so that we could call PlatformCALayerClient::platformLayerChanged,
346         but that no longer exists!
347
348 2014-08-29  Sergio Villar Senin  <svillar@igalia.com>
349
350         [CSS Grid Layout] Resolved value of grid-template-* must include every track listed
351         https://bugs.webkit.org/show_bug.cgi?id=136362
352
353         Reviewed by Darin Adler.
354
355         Section 5.1.5 of the specs clearly states that the resolved value
356         for grid-template-* must include every listed track, whether
357         explicitly or implicitly created. We were only listing the
358         explicit grid tracks.
359
360         * css/CSSComputedStyleDeclaration.cpp:
361         (WebCore::valueForGridTrackList):
362
363 2014-09-01  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
364
365         [CMAKE] Build warning by INTERFACE_LINK_LIBRARIES
366         https://bugs.webkit.org/show_bug.cgi?id=136194
367
368         Reviewed by Csaba Osztrogonác.
369
370         Set the LINK_INTERFACE_LIBRARIES target property on the top level CMakeLists.txt.
371
372         * CMakeLists.txt:
373
374 2014-08-31  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
375
376         Unreviewed, fix build break on EFL and GTK since r173152.
377
378         * platform/graphics/cairo/GraphicsContextCairo.cpp:
379         (WebCore::GraphicsContext::platformInit): Remove a bool parameter because it was removed from function's declaration.
380
381 2014-08-31  Tim Horton  <timothy_horton@apple.com>
382
383         Remove GraphicsContext constructor that takes shouldUseContextColors
384         https://bugs.webkit.org/show_bug.cgi?id=136421
385
386         Reviewed by Dan Bernstein.
387
388         * WebCore.exp.in:
389         * platform/graphics/GraphicsContext.cpp:
390         (WebCore::GraphicsContext::GraphicsContext):
391         * platform/graphics/GraphicsContext.h:
392         (WebCore::GraphicsContextState::GraphicsContextState):
393         * platform/graphics/cg/GraphicsContextCG.cpp:
394         (WebCore::GraphicsContext::platformInit):
395         (WebCore::GraphicsContext::drawLinesForText):
396         As far as I can tell, the last user of this constructor died with WebNSStringDrawing.
397         Adjust all code to assume shouldUseContextColors=true.
398
399 2014-08-31  Tim Horton  <timothy_horton@apple.com>
400
401         Remove unused ARMv6-specific #if branches in WebCore::canHyphenate
402         https://bugs.webkit.org/show_bug.cgi?id=136420
403
404         Reviewed by Dan Bernstein.
405
406         * platform/text/cf/HyphenationCF.cpp:
407         (WebCore::AtomicStringKeyedMRUCache<RetainPtr<CFLocaleRef>>::createValueForNullKey):
408         Use kCFAllocatorDefault instead of 0.
409
410         (WebCore::canHyphenate):
411         Remove ARMv6-specific code.
412
413 2014-08-31  Tim Horton  <timothy_horton@apple.com>
414
415         Remove unnecessary (and unnecessarily iOS-specific) setStrokeAndFillColor
416         https://bugs.webkit.org/show_bug.cgi?id=136416
417
418         Reviewed by Dan Bernstein.
419
420         * WebCore.exp.in:
421         * platform/graphics/GraphicsContext.h:
422         * platform/graphics/cg/GraphicsContextCG.cpp:
423         (WebCore::setStrokeAndFillColor): Deleted.
424         Remove.
425
426 2014-08-31  Tim Horton  <timothy_horton@apple.com>
427
428         Remove duplicate implementation of drawEllipse and some related PLATFORM(IOS) ifdefs
429         https://bugs.webkit.org/show_bug.cgi?id=136413
430
431         Reviewed by Dan Bernstein.
432
433         No new tests, just cleanup.
434
435         * platform/graphics/GraphicsContext.cpp:
436         (WebCore::GraphicsContext::drawRaisedEllipse):
437         There's nothing iOS specific about this function.
438
439         * platform/graphics/GraphicsContext.h:
440         * platform/graphics/cairo/GraphicsContextCairo.cpp:
441         (WebCore::GraphicsContext::drawEllipse):
442         * platform/graphics/cg/GraphicsContextCG.cpp:
443         (WebCore::GraphicsContext::drawEllipse):
444         Un-ifdef drawRaisedEllipse; delete the reimplementation of drawEllipse that takes
445         a FloatRect and make the normal one take a FloatRect instead.
446
447         (WebCore::GraphicsContext::platformInit):
448         Make sure that the CGContext's line width starts out in sync with GraphicsContext's.
449         By default, CGContext has a line width of 1 and GraphicsContext 0, so they could previously
450         have been out of sync until someone set the width explicitly.
451
452 2014-08-31  Tim Horton  <timothy_horton@apple.com>
453
454         Fix a harmless mismerge in BitmapImage::destroyDecodedDataIfNecessary
455         https://bugs.webkit.org/show_bug.cgi?id=136412
456
457         Reviewed by Alexey Proskuryakov.
458
459         No new tests, just cleanup.
460
461         * platform/graphics/BitmapImage.cpp:
462         (WebCore::BitmapImage::destroyDecodedDataIfNecessary):
463         Drop the leading 'c' and the 'static' on the cutoff parameter.
464         Remove the duplicated early return (seems like it happened in the merge).
465         Remove reference to the exact size in the comment, since it's different on iOS.
466
467 2014-08-31  Tim Horton  <timothy_horton@apple.com>
468
469         Use SinkDocument instead of PDFDocument; get rid of PDFDocument
470         https://bugs.webkit.org/show_bug.cgi?id=136414
471
472         Reviewed by Alexey Proskuryakov.
473
474         * WebCore.xcodeproj/project.pbxproj:
475         * loader/DocumentWriter.cpp:
476         (WebCore::DocumentWriter::createDocument):
477         * pdf/ios/PDFDocument.cpp: Removed.
478         * pdf/ios/PDFDocument.h: Removed.
479         Use the generic SinkDocument, which ignores all incoming data just like PDFDocument.
480         Delete the unnecessary and iOS-specific PDFDocument.cpp/h
481
482 2014-08-31  Tim Horton  <timothy_horton@apple.com>
483
484         Adjust an antique comment in Image::drawPattern
485         https://bugs.webkit.org/show_bug.cgi?id=136411
486
487         Reviewed by Dan Bernstein.
488
489         * platform/graphics/cg/ImageCG.cpp:
490         (WebCore::Image::drawPattern):
491         Reword the comment.
492
493 2014-08-31  Tim Horton  <timothy_horton@apple.com>
494
495         SVGImage::drawPatternForContainer creates a buffer without respecting the destination's acceleration setting
496         https://bugs.webkit.org/show_bug.cgi?id=136408
497         <rdar://problem/12013317>
498
499         Reviewed by Dan Bernstein.
500
501         No new tests required, just a performance improvement.
502
503         * svg/graphics/SVGImage.cpp:
504         (WebCore::SVGImage::drawPatternForContainer):
505         Use ImageBuffer::createCompatibleBuffer, which passes the destination's
506         acceleration setting through to the ImageBuffer constructor.
507
508         I didn't use GraphicsContext::createCompatibleBuffer because adjusting
509         how this function applies the destination's CTM is outside the scope of this patch.
510
511 2014-08-30  Joseph Pecoraro  <pecoraro@apple.com>
512
513         Convert string literals to character literals in makeString usage
514         https://bugs.webkit.org/show_bug.cgi?id=136394
515
516         Reviewed by Sam Weinig.
517
518         * inspector/InspectorOverlay.cpp:
519         (WebCore::InspectorOverlay::evaluateInOverlay):
520         * loader/FrameLoader.cpp:
521         (WebCore::FrameLoader::setOriginalURLForDownloadRequest):
522         * loader/MixedContentChecker.cpp:
523         (WebCore::MixedContentChecker::logWarning):
524         * page/ContentSecurityPolicy.cpp:
525         (WebCore::CSPDirectiveList::checkMediaTypeAndReportViolation):
526         (WebCore::ContentSecurityPolicy::reportUnsupportedDirective):
527         (WebCore::ContentSecurityPolicy::reportInvalidPathCharacter):
528         Also reorder some code to ensure single string creation.
529
530 2014-08-26  Maciej Stachowiak  <mjs@apple.com>
531
532         Use RetainPtr::autorelease in some places where it seems appropriate
533         https://bugs.webkit.org/show_bug.cgi?id=136280
534
535         Reviewed by Darin Adler.
536
537         * platform/mac/URLMac.mm:
538         (WebCore::URL::operator NSURL *): Use autorelease() instead of
539         CFBridgingRelease(leakRef())
540
541 2014-08-30  Yusuke Suzuki  <utatane.tea@gmail.com>
542
543         CSS: Refactor :visited handling in SelectorChecker
544         https://bugs.webkit.org/show_bug.cgi?id=135639
545
546         Reviewed by Benjamin Poulain.
547
548         :visited is specially handled in the SelectorChecker and style resolution
549         because of security issues. That is nested links and adjacent combinators.
550         Since we propagate linkState from the ancestors,
551
552             1. linkStates of ancestors from the target node are only used to calculate
553             the linkState of the current node.
554             This is why adjacent combinators disable :visited.
555
556             2. linkState is overrides by the closest link element in the ancestors.
557             This is why :visited is effective on the closest link element.
558
559         In this patch, we fix 3 things.
560
561             1. Simplify SelectorChecker. Move m_mode to CheckingContext and it makes
562             CheckingContext more similar to SelectorCompiler::CheckingContext in CSS JIT.
563             And hide visitedMatchType parameter from the caller of SelectorChecker.
564
565             2. Disable :visited inside :-webkit-any. Currently, :-webkit-any provides MatchAll
566             link match type. So considering visited match type in the matching phase of :visited
567             provides inconsistency. In this patch, :-webkit-any(:visited) never matches.
568             And :-webkit-any(:link) acts like a :-webkit-any(:any-link). This behavior represents
569             that visited match type is always considered as disabled inside :-webkit-any.
570             This behavior may be changed when Selector Level4 is implemented.
571
572             3. Fix the issue when traversing the descendant element,
573             first encountered link check is missing.
574
575         Tests: fast/history/link-inside-any.html
576                fast/history/link-inside-not.html
577                fast/history/nested-visited-test-override.html
578                fast/history/visited-inside-any.html
579                fast/history/visited-inside-not.html
580
581         * css/ElementRuleCollector.cpp:
582         (WebCore::ElementRuleCollector::ruleMatches):
583         * css/SelectorChecker.cpp:
584         (WebCore::SelectorChecker::SelectorChecker):
585         (WebCore::SelectorChecker::match):
586         (WebCore::hasScrollbarPseudoElement):
587         (WebCore::checkingContextForParent):
588         (WebCore::SelectorChecker::matchRecursively):
589         (WebCore::SelectorChecker::checkOne):
590         * css/SelectorChecker.h:
591         (WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext):
592         * css/StyleResolver.h:
593         (WebCore::checkRegionSelector):
594         * dom/SelectorQuery.cpp:
595         (WebCore::SelectorDataList::selectorMatches):
596
597 2014-08-29  Zalan Bujtas  <zalan@apple.com>
598
599         Subpixel layout: Remove LayoutUnit's kEffectiveFixedPointDenominator.
600         https://bugs.webkit.org/show_bug.cgi?id=136383.
601
602         Reviewed by Simon Fraser.
603
604         There's only one subpixel denominator now.
605
606         No change in functionality.
607
608         * platform/LayoutUnit.h:
609         (WebCore::LayoutUnit::LayoutUnit):
610         (WebCore::LayoutUnit::fromFloatCeil):
611         (WebCore::LayoutUnit::fromFloatFloor):
612         (WebCore::LayoutUnit::toInt):
613         (WebCore::LayoutUnit::toFloat):
614         (WebCore::LayoutUnit::toDouble):
615         (WebCore::LayoutUnit::operator++):
616         (WebCore::LayoutUnit::ceil):
617         (WebCore::LayoutUnit::round):
618         (WebCore::LayoutUnit::floor):
619         (WebCore::LayoutUnit::ceilToFloat):
620         (WebCore::LayoutUnit::fraction):
621         (WebCore::LayoutUnit::epsilon):
622         (WebCore::LayoutUnit::nearlyMax):
623         (WebCore::LayoutUnit::nearlyMin):
624         (WebCore::LayoutUnit::isInBounds):
625         (WebCore::LayoutUnit::setValue):
626         (WebCore::boundedMultiply):
627         (WebCore::operator*):
628         (WebCore::operator/):
629         (WebCore::operator%):
630         (WebCore::roundToDevicePixel):
631         (WebCore::floorToDevicePixel):
632         (WebCore::ceilToDevicePixel):
633
634 2014-08-29  Zalan Bujtas  <zalan@apple.com>
635
636         Rename updatePreferredWidth to make it more explicit.
637         https://bugs.webkit.org/show_bug.cgi?id=136389
638
639         Reviewed by Simon Fraser.
640
641         No change in functionality.
642
643         * rendering/RenderBlock.cpp:
644         (WebCore::preferredWidth):
645         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
646         (WebCore::updatePreferredWidth): Deleted.
647
648 2014-08-29  Gavin Barraclough  <barraclough@apple.com>
649
650         Make timerNestingLevel threadsafe
651         https://bugs.webkit.org/show_bug.cgi?id=136401
652
653         Reviewed by Tim Horton.
654
655         timerNestingLevel, used by DOMTimer to determine whether a timer is 'nested'
656         (repeating, possible due to a timer rescheduling itself) is a global. Since
657         worker threads can set timers too this is not thread safe.
658
659         * dom/ScriptExecutionContext.cpp:
660         (WebCore::ScriptExecutionContext::ScriptExecutionContext):
661             - added initialize m_timerNestingLevel
662         * dom/ScriptExecutionContext.h:
663         (WebCore::ScriptExecutionContext::timerNestingLevel):
664         (WebCore::ScriptExecutionContext::setTimerNestingLevel):
665             - added accessors
666         * page/DOMTimer.cpp:
667         (WebCore::DOMTimer::DOMTimer):
668         (WebCore::DOMTimer::fired):
669             - move timerNestingLevel to the context
670
671 2014-08-29  Gavin Barraclough  <barraclough@apple.com>
672
673         DOMTimer::m_nestingLevel is prone to overflow
674         https://bugs.webkit.org/show_bug.cgi?id=136399
675
676         Reviewed by Alexey Proskuryakov.
677
678         Since this would happen after the 2 billionth timer fire this is unlikely,
679         and consequences aren't severe (breaks throttling).
680
681         This change has the following consequences.
682
683             - m_nestingLevel saturates to its max value.
684             - unnested timers are indicated by a nesting level of 0.
685             - repeat timers update m_nestingLevel on every fire,
686               not just those that should have been throttled.
687
688         The last point is subtle, but ultimately should be inconsequential. Timers
689         whose requested timeout is less that the minimum interval will saturate quickly
690         anyway; timers with an original interval greater than the minimum previously
691         wouldn't have incremented m_nestingLevel, but doing so now doesn't hurt since
692         they won't be throttled when they hit the threshold. This simplifies things
693         conceptually a little & reduces the test performed on each timer fire.
694
695         * page/DOMTimer.cpp:
696         (WebCore::shouldForwardUserGesture):
697             - unnested timers are indicated by a nesting level of 0
698         (WebCore::DOMTimer::DOMTimer):
699             - don't increment nesting level on construction
700         (WebCore::DOMTimer::fired):
701             - saturating increments
702         (WebCore::DOMTimer::adjustMinimumTimerInterval):
703         (WebCore::DOMTimer::intervalClampedToMinimum):
704             - added ASSERTs
705
706 2014-08-29  Zalan Bujtas  <zalan@apple.com>
707
708         Improve showRenderTree() output.
709         https://bugs.webkit.org/show_bug.cgi?id=136244
710
711         Reviewed by Darin Adler.
712
713         Add more debugging information to showRenderTree().
714
715         Not testable.
716
717         * rendering/InlineBox.cpp:
718         (WebCore::InlineBox::showLineTreeForThis):
719         (WebCore::InlineBox::showLineTreeAndMark):
720         (WebCore::InlineBox::showLineBox):
721         (showNodeTree):
722         (showLineTree):
723         (WebCore::InlineBox::showBox): Deleted.
724         * rendering/InlineBox.h:
725         * rendering/InlineFlowBox.cpp:
726         (WebCore::InlineFlowBox::showLineTreeAndMark):
727         * rendering/InlineFlowBox.h:
728         * rendering/InlineTextBox.cpp:
729         (WebCore::InlineTextBox::showLineBox):
730         (WebCore::InlineTextBox::showBox): Deleted.
731         * rendering/InlineTextBox.h:
732         * rendering/RenderBlock.cpp:
733         (WebCore::RenderBlock::showLineTreeAndMark): Deleted.
734         * rendering/RenderBlock.h:
735         * rendering/RenderBlockFlow.cpp:
736         (WebCore::RenderBlockFlow::showLineTreeAndMark):
737         * rendering/RenderBlockFlow.h:
738         * rendering/RenderObject.cpp:
739         (WebCore::showRenderTreeLegend):
740         (WebCore::RenderObject::showNodeTreeForThis):
741         (WebCore::RenderObject::showRenderTreeForThis):
742         (WebCore::RenderObject::showLineTreeForThis):
743         (WebCore::RenderObject::showRegionsInformation):
744         (WebCore::RenderObject::showRenderObject):
745         (WebCore::RenderObject::showRenderSubTreeAndMark):
746         (showNodeTree):
747         (showLineTree):
748         (showRenderTree):
749         (WebCore::RenderObject::showRenderTreeAndMark): Deleted.
750         * rendering/RenderObject.h:
751         * rendering/RootInlineBox.h:
752
753 2014-08-29  Csaba Osztrogonác  <ossy@webkit.org>
754
755         Unreviewed, remove empty directories.
756
757         * Modules/networkinfo: Removed.
758         * inspector/front-end: Removed.
759         * inspector/front-end/Images: Removed.
760         * inspector/front-end/UglifyJS: Removed.
761         * inspector/front-end/ace: Removed.
762         * inspector/front-end/cm: Removed.
763         * platform/audio/ffmpeg: Removed.
764         * platform/audio/ipp: Removed.
765         * platform/graphics/gpu/opencl: Removed.
766
767 2014-08-29  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
768
769         [EFL] Remove non Coordinated Graphics code path from cmake build system after r142169
770         https://bugs.webkit.org/show_bug.cgi?id=135560
771
772         Reviewed by Gyuyoung Kim.
773
774         No new tests required, no new functionality.
775
776         * PlatformEfl.cmake: Removed TEXTURE_MAPPER and 3D_GRAPHICS guards.
777         * platform/graphics/efl/GraphicsContext3DEfl.cpp: Removed TEXTURE_MAPPER_GL and GRAPHICS_SURFACE guards.
778         (WebCore::GraphicsContext3D::platformLayer):
779         (WebCore::GraphicsContext3D::createGraphicsSurfaces):
780         * platform/graphics/efl/GraphicsContext3DPrivate.cpp: Removed TEXTURE_MAPPER_GL and GRAPHICS_SURFACE guards.
781         (WebCore::GraphicsContext3DPrivate::initialize):
782         (WebCore::GraphicsContext3DPrivate::releaseResources):
783         (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
784         (WebCore::GraphicsContext3DPrivate::graphicsSurfaceFlags):
785         * platform/graphics/efl/GraphicsContext3DPrivate.h: Removed TEXTURE_MAPPER_GL and GRAPHICS_SURFACE guards.
786         * platform/graphics/surfaces/efl/GraphicsSurfaceCommon.cpp: Removed GRAPHICS_SURFACE guard.
787
788 2014-08-29  Carlos Garcia Campos  <cgarcia@igalia.com>
789
790         RenderThemeGtk depends on classes outside of platform
791         https://bugs.webkit.org/show_bug.cgi?id=22176
792
793         Reviewed by Martin Robinson.
794
795         Move RenderThemeGtk.cpp from platform to rendering.
796
797         * PlatformGTK.cmake:
798         * rendering/RenderThemeGtk.cpp: Renamed from Source/WebCore/platform/gtk/RenderThemeGtk.cpp.
799
800 2014-08-29  Carlos Garcia Campos  <cgarcia@igalia.com>
801
802         [GTK] ScrollbarThemeGtk should not depend on RenderThemeGtk
803         https://bugs.webkit.org/show_bug.cgi?id=136338
804
805         Reviewed by Philippe Normand.
806
807         Remove the dependency by creating the GtkStyleContext for the
808         scrollbars in ScrollbarThemeGtk.
809
810         * platform/gtk/RenderThemeGtk.cpp:
811         (WebCore::gtkStyleChangedCallback): Call ScrollbarThemeGtk::themeChanged().
812         (WebCore::getStyleContext): Remove the scrollbar style context support.
813         * platform/gtk/RenderThemeGtk.h: Remove gtkScrollbarStyle().
814         * platform/gtk/ScrollbarThemeGtk.cpp:
815         (WebCore::ScrollbarStyleContext::ScrollbarStyleContext): Helper
816         class to create the global GtkStyleContext for scrollbars.
817         (WebCore::ScrollbarStyleContext::~ScrollbarStyleContext):
818         (WebCore::ScrollbarStyleContext::context):
819         (WebCore::gtkScrollbarStyleContext):
820         (WebCore::ScrollbarThemeGtk::ScrollbarThemeGtk): Remove m_context initialization.
821         (WebCore::ScrollbarThemeGtk::themeChanged): Invalidate the
822         GtkStylecontext and call updateThemeProperties().
823         (WebCore::ScrollbarThemeGtk::updateThemeProperties): Use the
824         global style context.
825         (WebCore::ScrollbarThemeGtk::paintTrackBackground): Ditto.
826         (WebCore::ScrollbarThemeGtk::paintScrollbarBackground): Ditto.
827         (WebCore::ScrollbarThemeGtk::paintThumb): Ditto.
828         (WebCore::ScrollbarThemeGtk::paintButton): Ditto.
829         * platform/gtk/ScrollbarThemeGtk.h:
830
831 2014-08-28  Carlos Garcia Campos  <cgarcia@igalia.com>
832
833         [GTK] Merge RenderThemeGtk3.cpp into RenderThemeGtk.cpp and ScrollbarThemeGtk3.cpp intoScrollbarThemeGtk.cpp
834         https://bugs.webkit.org/show_bug.cgi?id=136336
835
836         Reviewed by Philippe Normand.
837
838         There's no reason to have two files now that there's no GTK+2
839         support. Also fix coding style issues and compile warnings.
840
841         * PlatformGTK.cmake:
842         * platform/gtk/RenderThemeGtk.cpp:
843         * platform/gtk/RenderThemeGtk.h:
844         * platform/gtk/RenderThemeGtk3.cpp: Removed.
845         * platform/gtk/ScrollbarThemeGtk.cpp:
846         * platform/gtk/ScrollbarThemeGtk3.cpp: Removed.
847
848 2014-08-28  Mark Lam  <mark.lam@apple.com>
849
850         DebuggerCallFrame::scope() should return a DebuggerScope.
851         <https://webkit.org/b/134420>
852
853         Reviewed by Geoffrey Garen.
854
855         No new tests.
856
857         Rolling back in r170680 with the fix for <https://webkit.org/b/135656>.
858
859         * bindings/js/ScriptController.cpp:
860         (WebCore::ScriptController::attachDebugger):
861         - We should acquire the JSLock before modifying a JS global object.
862
863 2014-08-28  Enrica Casucci  <enrica@apple.com>
864
865         Can't hit tab key more than 3 times continuously.
866         https://bugs.webkit.org/show_bug.cgi?id=136357
867         rdar://problem/17927266
868
869         Reviewed by Dean Jackson.
870
871         Test: fast/css/multiple-tabs.html
872
873         When computing the tabWidth disregard increments of less than half the size of the space character
874         for the given font.
875
876         * platform/graphics/Font.h:
877         (WebCore::Font::tabWidth):
878
879 2014-08-28  Daniel Bates  <dabates@apple.com>
880
881         [iOS] Clients that include WebCoreThread.h fail to build after <http://trac.webkit.org/changeset/172814/>
882         (https://bugs.webkit.org/show_bug.cgi?id=136108)
883
884         Define WEBCORE_EXPORT (if its not already defined) in WebCoreThread.h so as to fix the
885         build for clients that include this header.
886
887         * platform/ios/wak/WebCoreThread.h:
888
889 2014-08-28  Pratik Solanki  <psolanki@apple.com>
890
891         WebContent hangs under SharedBuffer::duplicateDataBufferIfNecessary() while browsing some websites
892         https://bugs.webkit.org/show_bug.cgi?id=136347
893         <rdar://problem/18073745>
894
895         Reviewed by Andreas Kling.
896
897         When passing data to ImageIO, we create a copy if we have to reallocate the buffer. We would
898         set the size of the new buffer to be the size of the SharedBuffer data. This causes memory
899         churn since we would create a new buffer for every data chunk we get. Fix this by at least
900         doubling the capacity of the buffer when we duplicate it.
901
902         * platform/SharedBuffer.cpp:
903         (WebCore::SharedBuffer::duplicateDataBufferIfNecessary):
904
905 2014-08-28  Dan Bernstein  <mitz@apple.com>
906
907         iOS build fix.
908
909         * WebCore.exp.in: Updated symbol.
910
911 2014-08-28  Benjamin Poulain  <bpoulain@apple.com>
912
913         Scrolling with spacebar on a page with fixed header breaks reading flow
914         https://bugs.webkit.org/show_bug.cgi?id=135506
915
916         Reviewed by Simon Fraser.
917
918         When scrolling by page, find the height of any bar that is obscuring the top or bottom of the page,
919         and substract that height from the step to scroll.
920
921         Tests: scrollbars/scrolling-backward-by-page-accounting-bottom-fixed-elements-on-keyboard-spacebar.html
922                scrollbars/scrolling-backward-by-page-on-keyboard-spacebar.html
923                scrollbars/scrolling-by-page-accounting-oversized-fixed-elements-on-keyboard-spacebar.html
924                scrollbars/scrolling-by-page-accounting-top-fixed-elements-on-keyboard-spacebar.html
925                scrollbars/scrolling-by-page-accounting-top-fixed-elements-with-negative-top-on-keyboard-spacebar.html
926                scrollbars/scrolling-by-page-ignoring-hidden-fixed-elements-on-keyboard-spacebar.html
927                scrollbars/scrolling-by-page-ignoring-transparent-fixed-elements-on-keyboard-spacebar.html
928                scrollbars/scrolling-by-page-on-keyboard-spacebar.html
929
930         * WebCore.exp.in:
931         * page/FrameView.cpp:
932         (WebCore::FrameView::adjustScrollStepForFixedContent):
933         * page/FrameView.h:
934         * platform/ScrollableArea.cpp:
935         (WebCore::ScrollableArea::adjustScrollStepForFixedContent):
936         (WebCore::ScrollableArea::scroll):
937         * platform/ScrollableArea.h:
938
939 2014-08-28  Zalan Bujtas  <zalan@apple.com>
940
941         Subpixel layout: Remove unused pixel snapping functions.
942         https://bugs.webkit.org/show_bug.cgi?id=136341
943
944         Reviewed by Simon Fraser.
945
946         Let's not encourage integral snapping by having these functions around.
947         
948         No change in functionality.
949
950         * accessibility/AccessibilityObject.h:
951         (WebCore::AccessibilityObject::pixelSnappedElementRect): Deleted.
952         (WebCore::AccessibilityObject::pixelSnappedSize): Deleted.
953         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
954         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
955         * html/HTMLImageElement.cpp:
956         (WebCore::HTMLImageElement::width):
957         (WebCore::HTMLImageElement::height):
958         * page/FrameView.cpp:
959         (WebCore::FrameView::qualifiesAsVisuallyNonEmpty):
960         * platform/graphics/LayoutPoint.h:
961         (WebCore::snappedIntSize):
962         (WebCore::snapSizeToDevicePixel):
963         * platform/graphics/LayoutRect.h:
964         (WebCore::LayoutRect::pixelSnappedLocation): Deleted.
965         (WebCore::LayoutRect::pixelSnappedX): Deleted.
966         (WebCore::LayoutRect::pixelSnappedY): Deleted.
967         (WebCore::LayoutRect::pixelSnappedWidth): Deleted.
968         (WebCore::LayoutRect::pixelSnappedHeight): Deleted.
969         (WebCore::LayoutRect::pixelSnappedMaxX): Deleted.
970         (WebCore::LayoutRect::pixelSnappedMaxY): Deleted.
971         (WebCore::snappedIntRectFromEdges): Deleted.
972         * rendering/RenderBlockFlow.h:
973         (WebCore::RenderBlockFlow::pixelSnappedLogicalTopForFloat): Deleted.
974         (WebCore::RenderBlockFlow::pixelSnappedLogicalBottomForFloat): Deleted.
975         (WebCore::RenderBlockFlow::pixelSnappedLogicalLeftForFloat): Deleted.
976         (WebCore::RenderBlockFlow::pixelSnappedLogicalRightForFloat): Deleted.
977         * rendering/RenderBox.h:
978         (WebCore::RenderBox::pixelSnappedLogicalHeight):
979         (WebCore::RenderBox::pixelSnappedLogicalWidth):
980         (WebCore::RenderBox::pixelSnappedBorderBoxRect):
981         (WebCore::RenderBox::pixelSnappedWidth): Deleted.
982         (WebCore::RenderBox::pixelSnappedHeight): Deleted.
983         (WebCore::RenderBox::pixelSnappedFrameRect): Deleted.
984         * rendering/RenderFileUploadControl.cpp:
985         (WebCore::nodeWidth):
986         (WebCore::nodeHeight):
987         (WebCore::RenderFileUploadControl::maxFilenameWidth):
988         * rendering/RenderLayer.cpp:
989         (WebCore::RenderLayer::updateLayerPosition):
990         (WebCore::RenderLayer::isPointInResizeControl):
991         * rendering/RenderLayerCompositor.cpp:
992         (WebCore::RenderLayerCompositor::ensureRootLayer):
993         * rendering/RenderMediaControls.cpp:
994         (WebCore::RenderMediaControls::volumeSliderOffsetFromMuteButton):
995         * rendering/RenderMultiColumnSet.cpp:
996         (WebCore::RenderMultiColumnSet::paintColumnRules):
997         * rendering/RenderScrollbar.cpp:
998         (WebCore::RenderScrollbar::buttonRect):
999         * rendering/RenderView.h:
1000
1001 2014-08-27  Enrica Casucci  <enrica@apple.com>
1002
1003         textStylingAtPosition returns incorrect values after executing toggleBold, toggleItalic and toggleUnderline.
1004         https://bugs.webkit.org/show_bug.cgi?id=136323
1005         rdar://problem/18141964
1006
1007         Reviewed by Antti Koivisto.
1008
1009         For underline style we need to check typingStyle first and use that information to populate
1010         the dictionary. If there is no typing style we can use the render style.
1011
1012         * WebCore.exp.in:
1013         * editing/ios/EditorIOS.mm:
1014         (WebCore::Editor::fontAttributesForSelectionStart):
1015
1016 2014-08-28  Iago Toral  <itoral@igalia.com> and Zan Dobersek  <zdobersek@igalia.com>
1017
1018         [GTK] Add WaylandEventSource
1019         https://bugs.webkit.org/show_bug.cgi?id=136213
1020
1021         Reviewed by Martin Robinson.
1022
1023         Add the WaylandEventSource class. Its static method, createEventSource(),
1024         creates a new GSource object that is attached to the main context and
1025         enables handling Wayland display events through the GLib's main loop.
1026
1027         The method will be called by the nested Wayland compositor during its
1028         initialization, which will also take the control over the ownership and
1029         will be tasked with properly removing the GSource from the main context.
1030
1031         GLibSource is a GSource-based struct that additionally holds a GPollFD object
1032         and the pointer to the wl_display object whose event loop we'll be
1033         dispatching during the GSource dispatch. This is the type that g_source_new
1034         uses when allocating the new GSource object.
1035
1036         The GSource is assigned the default priorty, can recurse, and is attached
1037         to the main context.
1038
1039         * PlatformGTK.cmake:
1040         * platform/graphics/wayland/WaylandEventSource.cpp: Added.
1041         (WebCore::GLibSource::initialize):
1042         (WebCore::GLibSource::check):
1043         (WebCore::GLibSource::dispatch):
1044         (WebCore::prepareCallback):
1045         (WebCore::checkCallback):
1046         (WebCore::dispatchCallback):
1047         (WebCore::WaylandEventSource::createDisplayEventSource):
1048         * platform/graphics/wayland/WaylandEventSource.h: Added.
1049
1050 2014-08-28  Chris Fleizach  <cfleizach@apple.com>
1051
1052         AX: Safari at com.apple.WebCore: WebCore::AXObjectCache::clearTextMarkerNodesInUse
1053         https://bugs.webkit.org/show_bug.cgi?id=136333
1054
1055         Reviewed by David Kilzer.
1056
1057         If a Node is asked for it's Document when it's not actually in a document, it can lead to an assert/crash.
1058         We can avoid this by checking that the node is in a document before asking for its document.
1059
1060         I was not able to make a test case.      
1061
1062         * accessibility/AXObjectCache.cpp:
1063         (WebCore::AXObjectCache::clearTextMarkerNodesInUse):
1064
1065 2014-08-28  Andreas Kling  <akling@apple.com>
1066
1067         ASSERTION FAILED: !m_renderView.document().inPageCache() in compositing/iframes/resources/page-cache-helper.html
1068         <https://webkit.org/b/136329>
1069
1070         Cancel any pending compositing layer updates when moving a document
1071         into the page cache.
1072
1073         Reviewed by Zalan Bujtas.
1074
1075         * dom/Document.cpp:
1076         (WebCore::Document::documentWillSuspendForPageCache):
1077         * rendering/RenderLayerCompositor.cpp:
1078         (WebCore::RenderLayerCompositor::cancelCompositingLayerUpdate):
1079         * rendering/RenderLayerCompositor.h:
1080
1081 2014-08-28  Mihnea Ovidenie  <mihnea@adobe.com>
1082
1083         [CSSRegions] Incorrect selection clearing on a document without regions
1084         https://bugs.webkit.org/show_bug.cgi?id=134901
1085
1086         Reviewed by David Hyatt.
1087
1088         When we select all the content of document with named flows but without regions,
1089         the start and end points of selection is cached in RenderView. However, since
1090         the document has named flows, the selection is split between the subtrees. During the split,
1091         it is possible that the cached end-points of the original selection are not included
1092         in any of the resulting subtree selection and they are not marked accordingly.
1093         In order to process the selection clearing correctly, we have to take the original
1094         selection end-points into account.
1095
1096         Test: fast/regions/selection/select-all-without-regions.html
1097
1098         * rendering/RenderObject.cpp:
1099         (WebCore::RenderObject::isSelectionBorder):
1100
1101 2014-08-28  Carlos Garcia Campos  <cgarcia@igalia.com>
1102
1103         [GTK] Add webkit_uri_response_get_http_headers to WebKit2 GTK+ API
1104         https://bugs.webkit.org/show_bug.cgi?id=136248
1105
1106         Reviewed by Gustavo Noronha Silva.
1107
1108         Move the code to update the SoupMessageHeaders to a new public
1109         method.
1110
1111         * platform/network/soup/ResourceResponse.h:
1112         * platform/network/soup/ResourceResponseSoup.cpp:
1113         (WebCore::ResourceResponse::updateSoupMessageHeaders):
1114         (WebCore::ResourceResponse::toSoupMessage):
1115
1116 2014-08-28  Carlos Garcia Campos  <cgarcia@igalia.com>
1117
1118         [GTK] Remove support for GTK+2 theme rendering
1119         https://bugs.webkit.org/show_bug.cgi?id=136285
1120
1121         Reviewed by Philippe Normand.
1122
1123         GTK+2 is only used by the plugin process that doesn't need to
1124         render html controls themed. Since the theme files are still
1125         built for WebCorePlatformGTK2, we need to provide dummy
1126         implementations for the pure virtual methods when
1127         GTK_API_VERSION_2 is defined.
1128
1129         * PlatformGTK.cmake: Remove deleted files from compilation.
1130         * platform/gtk/RenderThemeGtk.cpp:
1131         (WebCore::RenderThemeGtk::create):
1132         (WebCore::RenderTheme::themeForPage):
1133         (WebCore::getScreenDPI):
1134         (WebCore::RenderThemeGtk::systemFont):
1135         (WebCore::RenderThemeGtk::sliderTickSize):
1136         (WebCore::RenderThemeGtk::sliderTickOffsetFromTrackCenter):
1137         (WebCore::RenderThemeGtk::getScreenDPI): Deleted.
1138         * platform/gtk/RenderThemeGtk.h:
1139         * platform/gtk/RenderThemeGtk2.cpp: Removed.
1140         * platform/gtk/RenderThemeGtk3.cpp:
1141         * platform/gtk/ScrollbarThemeGtk.cpp:
1142         (WebCore::ScrollbarThemeGtk::hasThumb):
1143         (WebCore::ScrollbarThemeGtk::backButtonRect):
1144         (WebCore::ScrollbarThemeGtk::forwardButtonRect):
1145         (WebCore::ScrollbarThemeGtk::trackRect):
1146         (WebCore::ScrollbarThemeGtk::registerScrollbar):
1147         (WebCore::ScrollbarThemeGtk::unregisterScrollbar):
1148         (WebCore::ScrollbarThemeGtk::updateScrollbarsFrameThickness):
1149         * platform/gtk/ScrollbarThemeGtk.h:
1150         * platform/gtk/ScrollbarThemeGtk2.cpp: Removed.
1151         * platform/gtk/WidgetRenderingContext.cpp: Removed.
1152         * platform/gtk/WidgetRenderingContext.h: Removed.
1153
1154 2014-08-28  Zan Dobersek  <zdobersek@igalia.com>
1155
1156         Unreviewed GTK build fix for the Wayland windowing target after r173052.
1157
1158         * platform/graphics/wayland/WaylandSurface.cpp: Include the IntSize header.
1159         * platform/graphics/wayland/WaylandSurface.h: Forward-declare IntSize.
1160
1161 2014-08-27  Csaba Osztrogonác  <ossy@webkit.org>
1162
1163         One more URTBF after r173047.
1164
1165         * accessibility/atk/WebKitAccessibleInterfaceComponent.cpp:
1166         (webkitAccessibleComponentGetExtents):
1167
1168 2014-08-27  Iago Toral  <itoral@igalia.com> and Zan Dobersek  <zdobersek@igalia.com>
1169
1170         [GTK] Add WaylandSurface
1171         https://bugs.webkit.org/show_bug.cgi?id=136220
1172
1173         Reviewed by Martin Robinson.
1174
1175         Add the WaylandSurface class. An objects of this type is meant to be used
1176         by the LayerTreeHostGtk in the WebProcess and is constructed via the
1177         WaylandDisplay::createSurface() method.
1178
1179         LayerTreeHostGtk uses such object to perform frame requests to the nested
1180         Wayland compositor in the UIProcess, and to create the GLContextEGL object
1181         that's used during the layer flushing and compositing.
1182
1183         The resize() method is called whenever LayerTreeHostGtk is being resized,
1184         and basically only wraps the wl_egL_window_resize() call.
1185
1186         * PlatformGTK.cmake:
1187         * platform/graphics/wayland/WaylandSurface.cpp: Added.
1188         (WebCore::frameCallback):
1189         (WebCore::WaylandSurface::WaylandSurface):
1190         (WebCore::WaylandSurface::~WaylandSurface):
1191         (WebCore::WaylandSurface::resize):
1192         (WebCore::WaylandSurface::createGLContext):
1193         (WebCore::WaylandSurface::requestFrame):
1194         * platform/graphics/wayland/WaylandSurface.h: Added.
1195         (WebCore::WaylandSurface::surface):
1196         (WebCore::WaylandSurface::nativeWindowHandle):
1197
1198 2014-08-27  Csaba Osztrogonác  <ossy@webkit.org>
1199
1200         URTBF after r173047.
1201
1202         * accessibility/atk/WebKitAccessibleInterfaceImage.cpp:
1203         (webkitAccessibleImageGetImagePosition):
1204
1205 2014-08-27  Zalan Bujtas  <zalan@apple.com>
1206
1207         Subpixel layout: Cleanup snapSizeToPixel/snapSizeToDevicePixel.
1208         https://bugs.webkit.org/show_bug.cgi?id=136264
1209
1210         Reviewed by Simon Fraser.
1211         
1212         1. Align snapSizeToPixel()/snapSizeToDevicePixel() function names with the rest of snapping
1213         functions. ->snappedIntSize()/snapSizeToDevicePixel().
1214         2. Operate on LayoutSize/LayoutPoint instead of LayoutUnit/LayoutUnit to reflect functionality.
1215
1216         Covered by existing tests.
1217
1218         * platform/LayoutUnit.h:
1219         (WebCore::snapSizeToPixel): Deleted.
1220         (WebCore::snapSizeToDevicePixel): Deleted.
1221         * platform/graphics/LayoutPoint.h:
1222         (WebCore::snappedIntSize):
1223         (WebCore::snapSizeToDevicePixel):
1224         (WebCore::pixelSnappedIntSize): Deleted.
1225         * platform/graphics/LayoutRect.h:
1226         (WebCore::LayoutRect::pixelSnappedSize):
1227         (WebCore::LayoutRect::pixelSnappedWidth):
1228         (WebCore::LayoutRect::pixelSnappedHeight):
1229         (WebCore::pixelSnappedIntRect):
1230         (WebCore::pixelSnappedIntRectFromEdges):
1231         (WebCore::pixelSnappedForPainting):
1232         (WebCore::directionalPixelSnappedForPainting):
1233         * rendering/RenderBox.cpp:
1234         (WebCore::RenderBox::pixelSnappedClientWidth):
1235         (WebCore::RenderBox::pixelSnappedClientHeight):
1236         (WebCore::RenderBox::pixelSnappedOffsetWidth):
1237         (WebCore::RenderBox::pixelSnappedOffsetHeight):
1238         (WebCore::RenderBox::scrollWidth):
1239         (WebCore::RenderBox::scrollHeight):
1240         * rendering/RenderBoxModelObject.cpp:
1241         (WebCore::RenderBoxModelObject::pixelSnappedOffsetWidth):
1242         (WebCore::RenderBoxModelObject::pixelSnappedOffsetHeight):
1243         * rendering/RenderLayer.cpp:
1244         (WebCore::RenderLayer::updateLayerPosition):
1245         (WebCore::RenderLayer::scrollWidth):
1246         (WebCore::RenderLayer::scrollHeight):
1247         * rendering/RenderTreeAsText.cpp:
1248         (WebCore::writeLayers):
1249
1250 2014-08-27  Zalan Bujtas  <zalan@apple.com>
1251
1252         Subpixel layout: Rename LayoutRect's device pixel snapping functions.
1253         https://bugs.webkit.org/show_bug.cgi?id=136319
1254
1255         Reviewed by Simon Fraser.
1256
1257         From pixelSnappedForPainting() to snapRectToDevicePixels() and 
1258         pixelSnappedIntRect*() to snappedIntRect*().
1259
1260         No change in functionality.
1261
1262         * accessibility/AccessibilityObject.cpp:
1263         (WebCore::AccessibilityObject::boundingBoxForQuads):
1264         (WebCore::AccessibilityObject::isOnscreen):
1265         (WebCore::AccessibilityObject::scrollToMakeVisible):
1266         * accessibility/AccessibilityObject.h:
1267         (WebCore::AccessibilityObject::pixelSnappedBoundingBoxRect):
1268         (WebCore::AccessibilityObject::pixelSnappedElementRect):
1269         * accessibility/AccessibilityRenderObject.cpp:
1270         (WebCore::AccessibilityRenderObject::isOffScreen):
1271         (WebCore::AccessibilityRenderObject::boundsForVisiblePositionRange):
1272         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1273         (-[WebAccessibilityObjectWrapper accessibilityActivationPoint]):
1274         (-[WebAccessibilityObjectWrapper accessibilityFrame]):
1275         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
1276         (-[WebAccessibilityObjectWrapper position]):
1277         (-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
1278         * bindings/objc/DOMUIKitExtensions.mm:
1279         (-[DOMHTMLAreaElement boundingBoxWithOwner:]):
1280         (-[DOMHTMLAreaElement absoluteQuadWithOwner:]):
1281         * css/CSSComputedStyleDeclaration.cpp:
1282         (WebCore::computedTransform):
1283         * dom/Node.h:
1284         (WebCore::Node::pixelSnappedBoundingBox):
1285         (WebCore::Node::pixelSnappedRenderRect):
1286         * editing/RenderedPosition.cpp:
1287         (WebCore::RenderedPosition::absoluteRect):
1288         * editing/mac/FrameSelectionMac.mm:
1289         (WebCore::FrameSelection::notifyAccessibilityForSelectionChange):
1290         * html/HTMLCanvasElement.cpp:
1291         (WebCore::HTMLCanvasElement::paint):
1292         * inspector/InspectorOverlay.cpp:
1293         (WebCore::buildObjectForElementInfo):
1294         * inspector/InspectorPageAgent.cpp:
1295         (WebCore::InspectorPageAgent::didPaint):
1296         * page/FrameSnapshotting.cpp:
1297         (WebCore::snapshotNode):
1298         * page/FrameView.cpp:
1299         (WebCore::FrameView::scrollContentsFastPath):
1300         (WebCore::FrameView::extendedBackgroundRectForPainting):
1301         (WebCore::FrameView::windowClipRectForFrameOwner):
1302         (WebCore::FrameView::convertFromRendererToContainingView):
1303         * page/Page.cpp:
1304         (WebCore::Page::addRelevantRepaintedObject):
1305         (WebCore::Page::addRelevantUnpaintedObject):
1306         * page/ios/FrameIOS.mm:
1307         (WebCore::ancestorRespondingToClickEvents):
1308         * platform/DragImage.cpp:
1309         (WebCore::createDragImageForImage):
1310         * platform/graphics/LayoutRect.cpp:
1311         (WebCore::enclosingRectToDevicePixels):
1312         (WebCore::enclosingRectForPainting): Deleted.
1313         * platform/graphics/LayoutRect.h:
1314         (WebCore::snappedIntRect):
1315         (WebCore::snappedIntRectFromEdges):
1316         (WebCore::snapRectToDevicePixels):
1317         (WebCore::snapRectToDevicePixelsWithWritingDirection):
1318         (WebCore::pixelSnappedIntRect): Deleted.
1319         (WebCore::pixelSnappedIntRectFromEdges): Deleted.
1320         (WebCore::pixelSnappedForPainting): Deleted.
1321         (WebCore::directionalPixelSnappedForPainting): Deleted.
1322         * platform/graphics/RoundedRect.cpp:
1323         (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
1324         * platform/graphics/ca/GraphicsLayerCA.cpp:
1325         (WebCore::GraphicsLayerCA::computePixelAlignment):
1326         * platform/text/TextStream.cpp:
1327         (WebCore::TextStream::operator<<):
1328         * rendering/EllipsisBox.cpp:
1329         (WebCore::EllipsisBox::paintSelection):
1330         * rendering/FilterEffectRenderer.cpp:
1331         (WebCore::FilterEffectRendererHelper::applyFilterEffect):
1332         * rendering/InlineFlowBox.cpp:
1333         (WebCore::InlineFlowBox::paint):
1334         * rendering/InlineTextBox.cpp:
1335         (WebCore::InlineTextBox::paintSelection):
1336         (WebCore::InlineTextBox::paintCompositionBackground):
1337         (WebCore::InlineTextBox::paintTextMatchMarker):
1338         (WebCore::InlineTextBox::positionForOffset):
1339         * rendering/RenderBlock.cpp:
1340         (WebCore::RenderBlock::addVisualOverflowFromTheme):
1341         (WebCore::RenderBlock::paint):
1342         (WebCore::RenderBlock::blockSelectionGap):
1343         (WebCore::RenderBlock::logicalLeftSelectionGap):
1344         (WebCore::RenderBlock::logicalRightSelectionGap):
1345         (WebCore::RenderBlock::absoluteRects):
1346         (WebCore::RenderBlock::addFocusRingRects):
1347         * rendering/RenderBlockFlow.cpp:
1348         (WebCore::RenderBlockFlow::clipOutFloatingObjects):
1349         (WebCore::RenderBlockFlow::addFocusRingRectsForInlineChildren):
1350         * rendering/RenderBox.cpp:
1351         (WebCore::RenderBox::absoluteRects):
1352         (WebCore::RenderBox::absoluteContentBox):
1353         (WebCore::RenderBox::outlineBoundsForRepaint):
1354         (WebCore::RenderBox::addFocusRingRects):
1355         (WebCore::RenderBox::getBackgroundPaintedExtent):
1356         (WebCore::RenderBox::pushContentsClip):
1357         (WebCore::RenderBox::computeRectForRepaint):
1358         * rendering/RenderBox.h:
1359         (WebCore::RenderBox::pixelSnappedFrameRect):
1360         * rendering/RenderBoxModelObject.cpp:
1361         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1362         (WebCore::RenderBoxModelObject::pixelSnapBackgroundImageGeometryForPainting):
1363         (WebCore::RenderBoxModelObject::paintNinePieceImage):
1364         (WebCore::RenderBoxModelObject::paintBorder):
1365         (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
1366         (WebCore::RenderBoxModelObject::paintBoxShadow):
1367         * rendering/RenderDetailsMarker.cpp:
1368         (WebCore::RenderDetailsMarker::paint):
1369         * rendering/RenderEmbeddedObject.cpp:
1370         (WebCore::RenderEmbeddedObject::paintSnapshotImage):
1371         (WebCore::RenderEmbeddedObject::isReplacementObscured):
1372         * rendering/RenderFieldset.cpp:
1373         (WebCore::RenderFieldset::paintBoxDecorations):
1374         * rendering/RenderFlowThread.cpp:
1375         (WebCore::RenderFlowThread::addRegionsVisualOverflowFromTheme):
1376         * rendering/RenderFrameSet.cpp:
1377         (WebCore::RenderFrameSet::paint):
1378         (WebCore::RenderFrameSet::layout):
1379         (WebCore::RenderFrameSet::positionFramesWithFlattening):
1380         * rendering/RenderHTMLCanvas.cpp:
1381         (WebCore::RenderHTMLCanvas::paintReplaced):
1382         * rendering/RenderImage.cpp:
1383         (WebCore::RenderImage::paintReplaced):
1384         * rendering/RenderInline.cpp:
1385         (WebCore::RenderInline::paintOutlineForLine):
1386         * rendering/RenderLayer.cpp:
1387         (WebCore::RenderLayer::updateTransform):
1388         (WebCore::RenderLayer::currentTransform):
1389         (WebCore::RenderLayer::beginTransparencyLayers):
1390         (WebCore::RenderLayer::scrollRectToVisible):
1391         (WebCore::RenderLayer::scrollCornerRect):
1392         (WebCore::RenderLayer::drawPlatformResizerImage):
1393         (WebCore::RenderLayer::paintResizer):
1394         (WebCore::RenderLayer::hitTestOverflowControls):
1395         (WebCore::RenderLayer::clipToRect):
1396         (WebCore::RenderLayer::paintLayerByApplyingTransform):
1397         (WebCore::RenderLayer::paintOverflowControlsForFragments):
1398         (WebCore::RenderLayer::hitTestResizerInFragments):
1399         (WebCore::RenderLayer::calculateClipRects):
1400         * rendering/RenderLayerBacking.cpp:
1401         (WebCore::RenderLayerBacking::updateTransform):
1402         (WebCore::RenderLayerBacking::updateGeometry):
1403         (WebCore::RenderLayerBacking::resetContentsRect):
1404         (WebCore::RenderLayerBacking::updateImageContents):
1405         (WebCore::RenderLayerBacking::backgroundBoxForPainting):
1406         (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
1407         (WebCore::RenderLayerBacking::paintContents):
1408         * rendering/RenderLayerCompositor.cpp:
1409         (WebCore::RenderLayerCompositor::addToOverlapMap):
1410         (WebCore::RenderLayerCompositor::requiresCompositingForPlugin):
1411         (WebCore::RenderLayerCompositor::requiresCompositingForFrame):
1412         (WebCore::RenderLayerCompositor::paintContents):
1413         * rendering/RenderListBox.cpp:
1414         (WebCore::RenderListBox::addFocusRingRects):
1415         (WebCore::RenderListBox::paintScrollbar):
1416         (WebCore::RenderListBox::paintItemBackground):
1417         * rendering/RenderListMarker.cpp:
1418         (WebCore::RenderListMarker::paint):
1419         * rendering/RenderMeter.cpp:
1420         (WebCore::RenderMeter::updateLogicalWidth):
1421         (WebCore::RenderMeter::computeLogicalHeight):
1422         * rendering/RenderMultiColumnSet.cpp:
1423         (WebCore::RenderMultiColumnSet::paintColumnRules):
1424         * rendering/RenderObject.cpp:
1425         (WebCore::RenderObject::drawLineForBoxSide):
1426         (WebCore::RenderObject::addPDFURLRect):
1427         (WebCore::RenderObject::paintOutline):
1428         (WebCore::RenderObject::absoluteBoundingBoxRect):
1429         (WebCore::RenderObject::repaintUsingContainer):
1430         (WebCore::RenderObject::repaintSlowRepaintObject):
1431         (WebCore::RenderObject::pixelSnappedAbsoluteClippedOverflowRect):
1432         * rendering/RenderProgress.cpp:
1433         (WebCore::RenderProgress::computeLogicalHeight):
1434         * rendering/RenderReplaced.cpp:
1435         (WebCore::RenderReplaced::paint):
1436         * rendering/RenderScrollbarPart.cpp:
1437         (WebCore::RenderScrollbarPart::paintIntoRect):
1438         * rendering/RenderSearchField.cpp:
1439         (WebCore::RenderSearchField::showPopup):
1440         * rendering/RenderSnapshottedPlugIn.cpp:
1441         (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
1442         * rendering/RenderTableCell.cpp:
1443         (WebCore::RenderTableCell::paintCollapsedBorders):
1444         * rendering/RenderTextControl.cpp:
1445         (WebCore::RenderTextControl::addFocusRingRects):
1446         * rendering/RenderTextControlSingleLine.cpp:
1447         (WebCore::RenderTextControlSingleLine::paint):
1448         * rendering/RenderTheme.cpp:
1449         (WebCore::RenderTheme::paint):
1450         (WebCore::RenderTheme::paintBorderOnly):
1451         (WebCore::RenderTheme::paintDecorations):
1452         * rendering/RenderThemeMac.mm:
1453         (WebCore::RenderThemeMac::paintSnapshottedPluginOverlay):
1454         * rendering/RenderTreeAsText.cpp:
1455         (WebCore::write):
1456         * rendering/RenderVideo.cpp:
1457         (WebCore::RenderVideo::videoBox):
1458         (WebCore::RenderVideo::paintReplaced):
1459         * rendering/RenderView.cpp:
1460         (WebCore::RenderView::repaintViewRectangle):
1461         (WebCore::RenderView::computeRectForRepaint):
1462         (WebCore::RenderView::absoluteRects):
1463         (WebCore::RenderView::selectionBounds):
1464         (WebCore::RenderView::unscaledDocumentRect):
1465         * rendering/RenderView.h:
1466         * rendering/RenderWidget.cpp:
1467         (WebCore::RenderWidget::paintContents):
1468         (WebCore::RenderWidget::paint):
1469         * rendering/SimpleLineLayoutFunctions.cpp:
1470         (WebCore::SimpleLineLayout::paintDebugBorders):
1471         * rendering/shapes/Shape.cpp:
1472         (WebCore::Shape::createRasterShape):
1473         * rendering/svg/RenderSVGModelObject.cpp:
1474         (WebCore::RenderSVGModelObject::outlineBoundsForRepaint):
1475         * rendering/svg/RenderSVGRoot.cpp:
1476         (WebCore::RenderSVGRoot::paintReplaced):
1477         * rendering/svg/SVGInlineTextBox.cpp:
1478         (WebCore::SVGInlineTextBox::selectionRectForTextFragment):
1479
1480 2014-08-27  Daniel Bates  <dabates@apple.com>
1481
1482         Scrollbar corner can be drawn outside containing frame
1483         https://bugs.webkit.org/show_bug.cgi?id=133131
1484         <rdar://problem/16382769>
1485
1486         Reviewed by Simon Fraser.
1487
1488         Merged from Blink (patch by Levi Weintraub):
1489         <https://src.chromium.org/viewvc/blink?revision=170625&view=revision>
1490
1491         Fixes an issue where the scroll corner may be painted outside the rectangle of
1492         its associated frame by setting a clip rectangle before painting the scroll bar(s)
1493         and scroll corner.
1494
1495         Test: scrollbars/custom-scrollbars-paint-outside-iframe.html
1496
1497         * platform/ScrollView.cpp:
1498         (WebCore::ScrollView::paint):
1499
1500 2014-08-27  Zalan Bujtas  <zalan@apple.com>
1501
1502         Subpixel layout: Rename FloatPoint/FloatRect device pixel snapping functions.
1503         https://bugs.webkit.org/show_bug.cgi?id=136314
1504
1505         Reviewed by Simon Fraser.
1506
1507         From *edToDevicePixels() to *PointToDevicePixels() (* = floor/round/ceil)
1508
1509         EnclosedIntRect -> enclosingIntRect() changes functionality for InspectorOverlay painting,
1510         but currently untestable.
1511
1512         * WebCore.exp.in:
1513         * inspector/InspectorOverlay.cpp:
1514         (WebCore::InspectorOverlay::showPaintRect):
1515         * platform/graphics/FloatPoint.h:
1516         (WebCore::flooredIntSize):
1517         (WebCore::floorPointToDevicePixels):
1518         (WebCore::ceilPointToDevicePixels):
1519         (WebCore::flooredToDevicePixels): Deleted.
1520         (WebCore::ceiledToDevicePixels): Deleted.
1521         * platform/graphics/FloatRect.cpp:
1522         (WebCore::enclosingRectToDevicePixels):
1523         (WebCore::enclosingRectExtendedToDevicePixels): Deleted. Renamed.
1524         (WebCore::enclosedIntRect): Deleted. Not needed.
1525         * platform/graphics/FloatRect.h:
1526
1527 2014-08-27  Zalan Bujtas  <zalan@apple.com>
1528
1529         Subpixel layout: Rename LayoutPoint's device pixel snapping functions.
1530         https://bugs.webkit.org/show_bug.cgi?id=136306
1531
1532         Reviewed by Simon Fraser.
1533
1534         From *edForPainting() to *PointToDevicePixels() (* = floor/round/ceil)
1535
1536         No change in functionality.
1537
1538         * platform/graphics/LayoutPoint.h:
1539         (WebCore::roundPointToDevicePixels):
1540         (WebCore::floorPointToDevicePixels):
1541         (WebCore::ceilPointToDevicePixels):
1542         (WebCore::roundedForPainting): Deleted.
1543         (WebCore::flooredForPainting): Deleted.
1544         (WebCore::ceiledForPainting): Deleted.
1545         * platform/graphics/LayoutRect.cpp:
1546         (WebCore::enclosingRectForPainting):
1547         * platform/graphics/LayoutRect.h:
1548         (WebCore::directionalPixelSnappedForPainting):
1549         * rendering/RenderBoxModelObject.cpp:
1550         (WebCore::RenderBoxModelObject::pixelSnapBackgroundImageGeometryForPainting):
1551         * rendering/RenderLayer.cpp:
1552         (WebCore::RenderLayer::paintLayerByApplyingTransform):
1553         (WebCore::RenderLayer::calculateClipRects):
1554         * rendering/RenderLayerBacking.cpp:
1555         (WebCore::RenderLayerBacking::updateGeometry):
1556
1557 2014-08-27  Zalan Bujtas  <zalan@apple.com>
1558
1559         Subpixel layout: Rename LayoutSize's device pixel snapping functions.
1560         https://bugs.webkit.org/show_bug.cgi?id=136310
1561
1562         Reviewed by Simon Fraser.
1563
1564         From *edForPainting() to *SizeToDevicePixels() (* = floor/round/ceil)
1565
1566         No change in functionality.
1567
1568          * platform/graphics/LayoutSize.h:
1569         (WebCore::floorSizeToDevicePixels):
1570         (WebCore::flooredForPainting): Deleted.
1571         * rendering/style/StyleGeneratedImage.cpp:
1572         (WebCore::StyleGeneratedImage::computeIntrinsicDimensions):
1573
1574 2014-08-27  Brian J. Burg  <burg@cs.washington.edu>
1575
1576         Enums in ScrollTypes and PlatformWheelEvent should not use uint64_t storage
1577         https://bugs.webkit.org/show_bug.cgi?id=136318
1578
1579         Reviewed by Simon Fraser.
1580
1581         This regressed in a replay-related patch. Revert back to uint8_t storage size.
1582
1583         * platform/PlatformWheelEvent.h:
1584         * platform/ScrollTypes.h:
1585         * replay/WebInputs.json:
1586
1587 2014-08-27  Simon Fraser  <simon.fraser@apple.com>
1588
1589         Speling is hard.
1590
1591         Reviewed by Tim Horton.
1592
1593         * page/EventHandler.cpp:
1594         (WebCore::EventHandler::handleMousePressEvent):
1595         (WebCore::EventHandler::handleMouseDoubleClickEvent):
1596         (WebCore::EventHandler::handleMouseMoveEvent):
1597         (WebCore::EventHandler::handleMouseReleaseEvent):
1598         (WebCore::EventHandler::handlePasteGlobalSelection):
1599         (WebCore::EventHandler::updateMouseEventTargetNode):
1600         (WebCore::EventHandler::dispatchMouseEvent):
1601         (WebCore::EventHandler::sendContextMenuEventForKey):
1602         (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
1603
1604 2014-08-27  Simon Fraser  <simon.fraser@apple.com>
1605
1606         Fix the iOS build.
1607
1608         * page/EventHandler.cpp:
1609         (WebCore::EventHandler::handleMousePressEvent):
1610
1611 2014-08-27  Andreas Kling  <akling@apple.com>
1612
1613         Drawing text in an SVG font causes load events to be fired.
1614         <https://webkit.org/b/136269>
1615         <rdar://problem/15724915>
1616
1617         Don't flush pending load events in Document::implicitClose() for frameless documents.
1618         This is a targeted fix for an issue where parsing SVG fonts during layout would cause
1619         event dispatch to happen in the main document, leading to arbitrary JS execution.
1620
1621         Note that the testcase only works in DRT/WTR, since once the SVG font is in cached
1622         by WebCore, we won't reparse it again. Caches are cleared between tests, so it will
1623         correctly fail if this should regress.
1624
1625         Longer-term, we should clean this up and get rid of the global dispatch entirely.
1626
1627         Reviewed by Simon Fraser.
1628
1629         Test: fast/text/svg-font-trigger-load-event.html
1630
1631         * dom/Document.cpp:
1632         (WebCore::Document::implicitClose):
1633
1634 2014-08-27  Simon Fraser  <simon.fraser@apple.com>
1635
1636         Some EventHandler naming cleanup
1637         https://bugs.webkit.org/show_bug.cgi?id=136303
1638
1639         Reviewed by Beth Dakin.
1640         
1641         Rename "mev" variables to "mouseEvent".
1642         
1643         No behavior change.
1644
1645         * page/EventHandler.cpp:
1646         (WebCore::EventHandler::handleMousePressEvent):
1647         (WebCore::EventHandler::handleMouseDoubleClickEvent):
1648         (WebCore::EventHandler::handleMouseMoveEvent):
1649         (WebCore::EventHandler::handleMouseReleaseEvent):
1650         (WebCore::EventHandler::updateDragAndDrop):
1651         (WebCore::EventHandler::prepareMouseEvent):
1652         (WebCore::EventHandler::sendContextMenuEvent):
1653         (WebCore::EventHandler::passMousePressEventToScrollbar):
1654         (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
1655
1656 2014-08-27  Simon Fraser  <simon.fraser@apple.com>
1657
1658         Some EventHandler naming cleanup
1659         https://bugs.webkit.org/show_bug.cgi?id=136303
1660
1661         Reviewed by Beth Dakin.
1662
1663         Rename PlatformMouseEvent variables from "mouseEvent" to "platformMouseEvent"
1664         so that a later patch can rename "mev" to "mouseEvent".
1665         
1666         0 => nullptr.
1667         
1668         No behavior change.
1669
1670         * page/EventHandler.cpp:
1671         (WebCore::EventHandler::clear):
1672         (WebCore::EventHandler::handleMousePressEvent):
1673         (WebCore::EventHandler::handleMouseDoubleClickEvent):
1674         (WebCore::EventHandler::handleMouseMoveEvent):
1675         (WebCore::EventHandler::invalidateClick):
1676         (WebCore::EventHandler::handleMouseReleaseEvent):
1677         (WebCore::EventHandler::handlePasteGlobalSelection):
1678         (WebCore::EventHandler::updateMouseEventTargetNode):
1679         (WebCore::EventHandler::dispatchMouseEvent):
1680         (WebCore::EventHandler::sendContextMenuEventForKey):
1681         (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
1682
1683 2014-08-27  Beth Dakin  <bdakin@apple.com>
1684
1685         Make isScrollableOrRubberbandable() a virtual function on RenderLayerModelObject
1686         https://bugs.webkit.org/show_bug.cgi?id=136307
1687
1688         Reviewed by Simon Fraser.
1689
1690         Remove extra parentheses. 
1691         * page/FrameView.cpp:
1692         (WebCore::FrameView::isScrollable):
1693
1694         Mark isScrollableOrRubberbandable() as override now that the root implementation 
1695         is moving to RenderLayerModelObject. It can also be private now.
1696         * rendering/RenderBox.h:
1697
1698         isBox() check and cast are no longer necessary.
1699         * rendering/RenderLayer.cpp:
1700         (WebCore::RenderLayer::hasScrollableOrRubberbandableAncestor):
1701
1702         Base implementation should return false.
1703         * rendering/RenderLayerModelObject.h:
1704         (WebCore::RenderLayerModelObject::isScrollableOrRubberbandable):
1705
1706         Mark as override.
1707         * rendering/RenderView.h:
1708
1709 2014-08-27  Antti Koivisto  <antti@apple.com>
1710
1711         REGRESSION(r172946): Plugin tests asserting on Yosemite debug bot
1712         https://bugs.webkit.org/show_bug.cgi?id=136301
1713
1714         Reviewed by Alexey Proskuryakov.
1715
1716         Don't pull the priority from the platform request if it is not defined.
1717
1718         * platform/network/cf/ResourceRequestCFNet.cpp:
1719         (WebCore::ResourceRequest::doUpdateResourceRequest):
1720         * platform/network/cocoa/ResourceRequestCocoa.mm:
1721         (WebCore::ResourceRequest::doUpdateResourceRequest):
1722
1723 2014-08-27  Timothy Hatcher  <timothy@apple.com>
1724
1725         Web Inspector: Crash when you open Web Inspector in a private window (due to IndexedDB)
1726         https://bugs.webkit.org/show_bug.cgi?id=136293
1727
1728         Reviewed by Joseph Pecoraro.
1729
1730         * inspector/InspectorIndexedDBAgent.cpp:
1731         (WebCore::InspectorIndexedDBAgent::requestDatabaseNames): Null check idbRequest from
1732         IDBFactory::getDatabaseNames, which can return null now after r172603 in private browsing.
1733
1734 2014-08-27  Beth Dakin  <bdakin@apple.com>
1735
1736         overflow:scroll elements should not latch to the body if the body is 
1737         overflow:hidden
1738         https://bugs.webkit.org/show_bug.cgi?id=136273
1739
1740         Reviewed by Darin Adler.
1741
1742         This patch adds an optional parameter to isScrollable(). The Scrollability 
1743         parameter that allows the caller to define what they mean by 'scrollable.' Most 
1744         callers are interested in the default value, Scrollability::Scrollable, which 
1745         means that there is actually content to scroll to, and a scrollbar that will allow 
1746         you to access it. In some cases, such as this latching case, callers want to know 
1747         if the FrameView is allowed to rubber-band, which the main frame might be allowed 
1748         to do even if there is no content to scroll to. In that case, callers use 
1749         Scrollability::ScrollableOrRubberbandable.
1750         * page/FrameView.cpp:
1751         (WebCore::FrameView::isScrollable):
1752         (WebCore::FrameView::hasScrollableOrRubberbandableAncestor):
1753
1754         New virtual function on ScrollableArea answers whether a ScrollableArea has any 
1755         scrollable or rubber-bandable ancestor.
1756         * page/FrameView.h:
1757         * platform/ScrollableArea.h:
1758
1759         Events should only be allowed to prevent stretching if there is some ancestor 
1760         ScrollableArea that will be able to make use of the event. 
1761         * platform/mac/ScrollAnimatorMac.mm:
1762         (WebCore::ScrollAnimatorMac::allowsVerticalStretching):
1763         (WebCore::ScrollAnimatorMac::allowsHorizontalStretching):
1764
1765         New ScrollableArea virtual function.
1766         * platform/win/PopupMenuWin.h:
1767
1768         New RenderBox isScrollableOrRubberbandable() returns just 
1769         canBeScrolledAndHasScrollableArea() for most RenderBox, but will be overridden by 
1770         RenderView.
1771         * rendering/RenderBox.cpp:
1772         (WebCore::RenderBox::isScrollableOrRubberbandable):
1773         * rendering/RenderBox.h:
1774
1775         Recurse up the parent chain to find out if anything is scrollable or just rubber-
1776         bandable.
1777         * rendering/RenderLayer.cpp:
1778         (WebCore::RenderLayer::hasScrollableOrRubberbandableAncestor):
1779         * rendering/RenderLayer.h:
1780
1781         Call into RenderLayer.
1782         * rendering/RenderListBox.cpp:
1783         (WebCore::RenderListBox::hasScrollableOrRubberbandableAncestor):
1784         * rendering/RenderListBox.h:
1785
1786         Override isScrollableOrRubberbandable() to handle the main frame case where the 
1787         main frame is typically allowed to rubber-band even if there is no content to 
1788         scroll to.
1789         * rendering/RenderView.cpp:
1790         (WebCore::RenderView::isScrollableOrRubberbandable):
1791         * rendering/RenderView.h:
1792
1793 2014-08-27  Benjamin Poulain  <bpoulain@apple.com>
1794
1795         Updating attributes on HTML elements do not invalidate the style correctly unless the attribute name is lowercase in the stylesheet
1796         https://bugs.webkit.org/show_bug.cgi?id=136270
1797
1798         Reviewed by Andreas Kling.
1799
1800         In HTML, WebKit treats every attribute name lowercase to implement case-insensitive matching.
1801         When invalidating style, the StyleResolver was ignoring HTML and always using the XML names.
1802
1803         This patch split the names on RuleFeatureSet in two sets: one for XML, one for HTML.
1804         In StyleResolver, the name used depends on the type of the element being updated.
1805
1806         This patch also adds nodeNeedsStyleRecalc() to Internals to test the optimization and various cases
1807         of style update.
1808
1809         Tests: fast/css/attribute-for-content-property-style-update-html.html
1810                fast/css/attribute-for-content-property-style-update-xhtml.xhtml
1811                fast/css/attribute-style-invalidation-optimization-html.html
1812                fast/css/attribute-style-invalidation-optimization-xhtml.xhtml
1813                fast/css/attribute-style-update-html.html
1814                fast/selectors/attribute-style-update-html.html
1815                fast/selectors/attribute-style-update-svg-in-html.html
1816                fast/selectors/attribute-style-update-xhtml.xhtml
1817
1818         * css/RuleFeature.cpp:
1819         (WebCore::RuleFeatureSet::collectFeaturesFromSelector):
1820         (WebCore::RuleFeatureSet::add):
1821         (WebCore::RuleFeatureSet::clear):
1822         * css/RuleFeature.h:
1823         * css/StyleResolver.cpp:
1824         (WebCore::StyleResolver::applyProperty):
1825         * css/StyleResolver.h:
1826         (WebCore::StyleResolver::hasSelectorForAttribute):
1827         * dom/Element.cpp:
1828         (WebCore::Element::willModifyAttribute):
1829         * testing/Internals.cpp:
1830         (WebCore::Internals::address):
1831         (WebCore::Internals::nodeNeedsStyleRecalc):
1832         * testing/Internals.h:
1833         * testing/Internals.idl:
1834
1835 2014-08-27  Benjamin Poulain  <bpoulain@apple.com>
1836
1837         Update the CSS Grammar selector names to get closer to the latest terminology
1838         https://bugs.webkit.org/show_bug.cgi?id=136277
1839
1840         Reviewed by Andreas Kling.
1841
1842         CSS Selector Level 4 gives useful definitions for various parts of a selector
1843         (see http://dev.w3.org/csswg/selectors4/#structure). This patch updates our names to be closer
1844         to that spec.
1845
1846         Stricto sensu, our definition of "simple selector list" is wrong. I did not attempt to fix this
1847         because updates of CSS Selector Level 4 and WebVTT will eventually make that whole concept useless.
1848
1849         * css/CSSGrammar.y.in:
1850
1851 2014-08-27  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1852
1853         [EFL] Unskip compositing test
1854         https://bugs.webkit.org/show_bug.cgi?id=136151
1855
1856         Reviewed by Csaba Osztrogonác.
1857
1858         * rendering/RenderLayerBacking.cpp: Set true to setContentsOpaque() to support compositing test.
1859         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
1860
1861 2014-08-26  Vivek Galatage  <vivek.vg@samsung.com>
1862
1863         Canvas direction should reflect change in dir attribute and also across save/restore operations
1864         https://bugs.webkit.org/show_bug.cgi?id=136098
1865
1866         Reviewed by Darin Adler.
1867
1868         Changed State.m_direction type from TextDirection to Direction enum to accomodate 'inherit'
1869         as a separate value. Modified the getter to compute the 'live' value for the direction attribute.
1870         Removed explicit passing of direction to CanvasRenderingContext2D::State constructor.
1871
1872         Updated existing canvas-direction.html with additional cases to reflect this change.
1873
1874         * html/canvas/CanvasRenderingContext2D.cpp:
1875         (WebCore::CanvasRenderingContext2D::CanvasRenderingContext2D):
1876         (WebCore::CanvasRenderingContext2D::reset):
1877         (WebCore::CanvasRenderingContext2D::State::State):
1878         (WebCore::CanvasRenderingContext2D::toTextDirection):
1879         (WebCore::CanvasRenderingContext2D::direction):
1880         (WebCore::CanvasRenderingContext2D::setDirection):
1881         (WebCore::CanvasRenderingContext2D::drawTextInternal):
1882         (WebCore::inheritedDirection): Deleted.
1883         * html/canvas/CanvasRenderingContext2D.h:
1884
1885 2014-08-26  Benjamin Poulain  <bpoulain@apple.com>
1886
1887         Minor style tweak on StyleResolveTree
1888         https://bugs.webkit.org/show_bug.cgi?id=136233
1889
1890         Reviewed by Sam Weinig.
1891
1892         * style/StyleResolveTree.cpp:
1893         (WebCore::Style::resolveTree):
1894         Clang likely optimized it away, but I find that explicit style cleaner.
1895
1896 2014-08-26  Brian J. Burg  <burg@cs.washington.edu>
1897
1898         Web Inspector: put feature flags for Inspector domains in the protocol specification
1899         https://bugs.webkit.org/show_bug.cgi?id=136027
1900
1901         Reviewed by Timothy Hatcher.
1902
1903         Add 'featureGuard' settings to wrap domains with ENABLE macros.
1904
1905         No new tests. No behavior was changed.
1906
1907         * inspector/protocol/Database.json:
1908         * inspector/protocol/IndexedDB.json:
1909         * inspector/protocol/Replay.json:
1910
1911 2014-08-26  Andy Estes  <aestes@apple.com>
1912
1913         [Cocoa] Some projects are incorrectly installed to $BUILT_PRODUCTS_DIR
1914         https://bugs.webkit.org/show_bug.cgi?id=136267
1915
1916         Reviewed by Dan Bernstein.
1917
1918         INSTALL_PATH was set to $BUILT_PRODUCTS_DIR for engineering configurations in r20225 as part of a build fix.
1919         Not only is this no longer necessary to build, but it causes built products to be incorrectly installed in
1920         engineering configurations.
1921
1922         Remove the setting of INSTALL_PATH from the pbxproj file so that the value specified in the xcconfig files is
1923         used instead.
1924
1925         * WebCore.xcodeproj/project.pbxproj:
1926
1927 2014-08-26  Brent Fulgham  <bfulgham@apple.com>
1928
1929         [Win] WebKit IDL incorrectly passes HWND as OLE_HANDLE
1930         https://bugs.webkit.org/show_bug.cgi?id=136258
1931         <rdar://problem/18134138>
1932
1933         Reviewed by Tim Horton.
1934
1935         Avoid 32/64-bit truncation by preventing 64-bit HWND (and other)
1936         values from passing through the 32-bit OLE_HANDLE data type.
1937
1938         * platform/win/WindowMessageBroadcaster.cpp:
1939         (WebCore::WindowMessageBroadcaster::addListener):
1940         (WebCore::WindowMessageBroadcaster::removeListener):
1941         (WebCore::WindowMessageBroadcaster::destroy):
1942         (WebCore::WindowMessageBroadcaster::unsubclassWindow):
1943         (WebCore::WindowMessageBroadcaster::SubclassedWndProc):
1944
1945 2014-08-25  Maciej Stachowiak  <mjs@apple.com>
1946
1947         Replace use of WKCopyCFLocalizationPreferredName with NSLocale public API
1948         https://bugs.webkit.org/show_bug.cgi?id=136082
1949
1950         Reviewed by Alexey Proskuryakov.
1951
1952         * platform/mac/Language.mm:
1953         (WebCore::httpStyleLanguageCode): Replace use of WKCopyCFLocalizationPreferredName
1954         with new WebCoreNSStringExtras helper.
1955         * platform/mac/WebCoreNSStringExtras.mm: Replacements for the aspects of
1956         WKCopyCFLocalizationPreferredName.
1957         (preferredBundleLocalizationName): New helper - most preferred localization available
1958         in the main bundle, canonicalized the way we like it.
1959         (canonicalLocalizationName): Convert a lcalization name to a string with language and
1960         country code, using default if necessary (e.g. "en" maps to "en_US").
1961         * WebCore.order: Remove mention of WKCopyCFLocalizationPreferredName.
1962         * WebCore.exp.in: ditto; also export preferredBundleLocalizationName for WebKit(2).
1963         * platform/ios/WebCoreSystemInterfaceIOS.mm: ditto
1964         * platform/mac/WebCoreSystemInterface.h: ditto
1965         * platform/mac/WebCoreSystemInterface.mm: ditto
1966         * platform/spi/cf: Added.
1967         * platform/spi/cf/CFLocaleSPI.h: Added. Declare
1968         CFLocaleGetLanguageRegionEncodingForLocaleIdentifier.
1969
1970 2014-08-26  Zoltan Horvath  <zoltan@webkit.org>
1971
1972         [CSS Shapes] Positioned polygon reftests failing
1973         https://bugs.webkit.org/show_bug.cgi?id=135925
1974
1975         Reviewed by David Hyatt.
1976
1977         We didn't respect the shape-margin before a positioned polygon, since we checked
1978         the shape-margin for only 1 vertex for a polygon edge. This patch fixes the behavior,
1979         removes the tests from the skipped list and updates 1 test, which was incorrect.
1980
1981         Updated existing test and removed tests from skipped list.
1982
1983         * rendering/shapes/PolygonShape.cpp:
1984         (WebCore::clippedCircleXRange):
1985         (WebCore::PolygonShape::getExcludedInterval):
1986
1987 2014-08-26  Zalan Bujtas  <zalan@apple.com>
1988
1989         Subpixel layout: Remove float to LayoutUnit ceil/round function wrappers.
1990         https://bugs.webkit.org/show_bug.cgi?id=136253
1991
1992         Reviewed by Simon Fraser.
1993
1994         These functions wrap LayoutUnit::fromFloatCeil/fromFloatRound() functions to ceil/round float to LayoutUnit.
1995         Their usage is limited and can easily be confused with the snapping functions (snap to css/device pixels).
1996
1997         No change in functionality.
1998
1999         * platform/LayoutUnit.h:
2000         (WebCore::roundedLayoutUnit): Deleted. : Callers use the more explicit LayoutUnit::fromFloatRound() function.
2001         (WebCore::ceiledLayoutUnit): Deleted. : Callers use the more explicit LayoutUnit::fromFloatCeil() function.
2002         * rendering/RenderBlock.cpp:
2003         (WebCore::updatePreferredWidth):
2004         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
2005         (WebCore::adjustFloatForSubPixelLayout): Deleted.
2006         * rendering/RenderBox.cpp:
2007         (WebCore::RenderBox::positionLineBox):
2008         * rendering/RenderFlexibleBox.cpp:
2009         (WebCore::RenderFlexibleBox::resolveFlexibleLengths):
2010         * rendering/RenderInline.cpp:
2011         (WebCore::RenderInline::offsetForInFlowPositionedInline):
2012         * rendering/RenderTextControlSingleLine.cpp:
2013         (WebCore::RenderTextControlSingleLine::preferredContentLogicalWidth):
2014
2015 2014-08-26  Simon Fraser  <simon.fraser@apple.com>
2016
2017         Ensure that layout is up-to-date before hit testing
2018         https://bugs.webkit.org/show_bug.cgi?id=136242
2019         rdar://problem/17435564
2020
2021         Reviewed by Tim Horton.
2022         
2023         Various code paths can call into RenderView::hitTest() but fail to
2024         ensure that layout is up-to-date. This is a conservative change that
2025         fixes the issue for callers of EventHandler::hitTestResultAtPoint(),
2026         including WebPage::acceptsFirstMouse() and WebFrame::hitTest().
2027         
2028         This change is not general enough that we can ASSERT(!needsLayout())
2029         in RenderView::hitTest() yet.
2030         
2031         * page/EventHandler.cpp:
2032         (WebCore::EventHandler::hitTestResultAtPoint):
2033
2034 2014-08-26  Beth Dakin  <bdakin@apple.com>
2035
2036         Rubber-banding in overflow:scroll regions does not work correctly with 
2037         direction:rtl
2038         https://bugs.webkit.org/show_bug.cgi?id=136176
2039
2040         Reviewed by Tim Horton.
2041
2042         Small cleanup.
2043         * rendering/RenderLayer.cpp:
2044         (WebCore::RenderLayer::visibleContentRectInternal):
2045
2046 2014-08-26  Tim Horton  <timothy_horton@apple.com>
2047
2048         Fix the build after r172963
2049
2050         * page/DOMTimer.h:
2051
2052 2014-08-25  Gavin Barraclough  <barraclough@apple.com>
2053
2054         DOMTimer may be deleted during timer fire
2055         https://bugs.webkit.org/show_bug.cgi?id=136198
2056
2057         Reviewed by Geoff Garen.
2058
2059         Consequentially ScheduledActions may also be deleted mid execution.
2060         This is fairly surprising & fragile, let's make this simpler.
2061
2062         Currently DOMTimer instances are effectively owned by the ScriptExecutionContext.
2063         There is a 1-1 mapping between timers and contexts, all timers are help in a map
2064         on the context and if the context goes away all timers are deleted. Rather than
2065         being implemented in a straightforward fashion (a smart pointer type for the map
2066         value) this is currently implemented by having the timer objects listen for the
2067         context going away using contextDestroyed, and deleting themselves if so.
2068
2069         Switch to using a smart pointer for values of m_timeouts in ScriptExecutionContext.
2070         By using a RefCounted object we can also extend the lifetime of the DOMTimer instance
2071         from within the DOMTimer::fired method, so the object is not destroyed while the
2072         member function is still on the stack.
2073
2074         * WebCore.xcodeproj/project.pbxproj:
2075             - project -> private since DOMTimer could no longer be a forward declare in ScriptExecutionContext.h.
2076         * dom/ScriptExecutionContext.cpp:
2077         (WebCore::ScriptExecutionContext::adjustMinimumTimerInterval):
2078         (WebCore::ScriptExecutionContext::didChangeTimerAlignmentInterval):
2079             - auto* -> auto& since value type in map is no longer a raw pointer.
2080         * dom/ScriptExecutionContext.h:
2081         (WebCore::ScriptExecutionContext::addTimeout):
2082             - DOMTimer* -> PassRefPtr<DOMTimer>
2083         * page/DOMTimer.cpp:
2084         (WebCore::DOMTimer::DOMTimer):
2085             - adopt the initial ref, and pass to addTimeout.
2086         (WebCore::DOMTimer::install):
2087             - updated comment.
2088         (WebCore::DOMTimer::removeById):
2089             - instead of explicitly deleting the timer and assuming this will implicitly remove it from the context map,
2090               we explicitly remove it from the context map and assume this will implicitly deleting the timer!
2091         (WebCore::DOMTimer::fired):
2092             - Add a RefPtr to keep the DOMTimer object alive until the fired method completes; to cancel a one-shot timer
2093               just remove it from the context's map, rather than explicitly deleting it.
2094         (WebCore::DOMTimer::~DOMTimer): Deleted.
2095         (WebCore::DOMTimer::contextDestroyed): Deleted.
2096             - no need! object lifetime management now handled by smart pointers.
2097         * page/DOMTimer.h:
2098             - added parent class RefCounted<DOMTimer>.
2099
2100 2014-08-26  Carlos Garcia Campos  <cgarcia@igalia.com>
2101
2102         [GTK] Selection background is rendered white when unfocused with recent GTK+
2103         https://bugs.webkit.org/show_bug.cgi?id=136251
2104
2105         Reviewed by Martin Robinson.
2106
2107         This is due to a change in the GTK+ theme, but because we are not
2108         using the right flags to get the selections colors. We should use
2109         GTK_STATE_FLAG_SELECTED | GTK_STATE_FLAG_FOCUSED when focused and
2110         GTK_STATE_FLAG_SELECTED when unfocused, instead of
2111         GTK_STATE_FLAG_ACTIVE when unfocused.
2112
2113         * platform/gtk/RenderThemeGtk3.cpp:
2114         (WebCore::RenderThemeGtk::platformActiveSelectionBackgroundColor):
2115         (WebCore::RenderThemeGtk::platformInactiveSelectionBackgroundColor):
2116         (WebCore::RenderThemeGtk::platformActiveSelectionForegroundColor):
2117         (WebCore::RenderThemeGtk::platformInactiveSelectionForegroundColor):
2118         (WebCore::RenderThemeGtk::platformActiveListBoxSelectionBackgroundColor):
2119         (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionBackgroundColor):
2120         (WebCore::RenderThemeGtk::platformActiveListBoxSelectionForegroundColor):
2121         (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionForegroundColor):
2122
2123 2014-08-26  Krzysztof Czech  <k.czech@samsung.com>
2124
2125         [EFL] Utilize espeak as a synthesizer back-end for WebSpeech
2126         https://bugs.webkit.org/show_bug.cgi?id=136127
2127
2128         Reviewed by Gyuyoung Kim.
2129
2130         Utilize espeak API to have support for speak, cancel and initializeVoiceList.
2131
2132         * PlatformEfl.cmake:
2133         * platform/efl/PlatformSpeechSynthesisProviderEfl.cpp:
2134         (WebCore::PlatformSpeechSynthesisProviderEfl::PlatformSpeechSynthesisProviderEfl):
2135         (WebCore::PlatformSpeechSynthesisProviderEfl::convertRateToEspeakValue):
2136         (WebCore::PlatformSpeechSynthesisProviderEfl::convertVolumeToEspeakValue):
2137         (WebCore::PlatformSpeechSynthesisProviderEfl::convertPitchToEspeakValue):
2138         (WebCore::PlatformSpeechSynthesisProviderEfl::voiceName):
2139         (WebCore::PlatformSpeechSynthesisProviderEfl::engineInit):
2140         (WebCore::PlatformSpeechSynthesisProviderEfl::currentVoice):
2141         (WebCore::PlatformSpeechSynthesisProviderEfl::initializeVoiceList):
2142         (WebCore::PlatformSpeechSynthesisProviderEfl::speak):
2143         (WebCore::PlatformSpeechSynthesisProviderEfl::cancel):
2144         (WebCore::PlatformSpeechSynthesisProviderEfl::fireSpeechEvent):
2145         * platform/efl/PlatformSpeechSynthesisProviderEfl.h:
2146         * platform/efl/PlatformSpeechSynthesizerEfl.cpp:
2147         (WebCore::PlatformSpeechSynthesizer::PlatformSpeechSynthesizer):
2148         (WebCore::PlatformSpeechSynthesizer::initializeVoiceList):
2149         (WebCore::PlatformSpeechSynthesizer::pause):
2150         (WebCore::PlatformSpeechSynthesizer::resume):
2151         (WebCore::PlatformSpeechSynthesizer::speak):
2152         (WebCore::PlatformSpeechSynthesizer::cancel):
2153
2154 2014-08-26  Ryuan Choi  <ryuan.choi@samsung.com>
2155
2156         [EFL] Build break using clang
2157         https://bugs.webkit.org/show_bug.cgi?id=136245
2158
2159         Reviewed by Gyuyoung Kim.
2160
2161         * css/ViewportStyleResolver.cpp: Includes NodeRenderStyle.h
2162
2163 2014-08-26  Mark Rowe  <mrowe@apple.com>
2164
2165         Build fix after r172951.
2166
2167         * fileapi/Blob.h: Give the argument the name that the predicates expect.
2168
2169 2014-08-25  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2170
2171         Generate toFile() instead of manual functions.
2172         https://bugs.webkit.org/show_bug.cgi?id=136207
2173
2174         Reviewed by Darin Adler.
2175
2176         No new tests, no behavior changes.
2177
2178         * fileapi/Blob.h: Define BLOB_TYPE_CASTS.
2179         * fileapi/File.h: Use BLOB_TYPE_CASTS to generate toFile().
2180         (WebCore::toFile): Deleted.
2181
2182 2014-08-25  Zalan Bujtas  <zalan@apple.com>
2183
2184         Subpixel layout: remove roundedLayoutPoint/roundedLayoutSize functions.
2185         https://bugs.webkit.org/show_bug.cgi?id=136236
2186
2187         Reviewed by Simon Fraser.
2188
2189         These functions simply call LayoutPoint/LayoutSize c'tors. They don't round the input value at all.
2190
2191         Non change in functionality.
2192
2193         * dom/MouseRelatedEvent.cpp:
2194         (WebCore::MouseRelatedEvent::computePageLocation):
2195         (WebCore::MouseRelatedEvent::computeRelativePosition):
2196         * dom/Touch.cpp:
2197         (WebCore::Touch::Touch):
2198         * html/shadow/SliderThumbElement.cpp:
2199         (WebCore::SliderThumbElement::setPositionFromPoint):
2200         * page/DragController.cpp:
2201         (WebCore::elementUnderMouse):
2202         * page/EventHandler.cpp:
2203         (WebCore::selectionExtentRespectingEditingBoundary):
2204         * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm:
2205         (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateChildNodesAfterScroll):
2206         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
2207         (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollLayerPosition):
2208         * platform/graphics/LayoutPoint.h:
2209         (WebCore::roundedLayoutPoint): Deleted.
2210         * platform/graphics/LayoutSize.h:
2211         (WebCore::roundedLayoutSize): Deleted.
2212         * rendering/EllipsisBox.cpp:
2213         (WebCore::EllipsisBox::nodeAtPoint):
2214         * rendering/RenderBlock.cpp:
2215         (WebCore::RenderBlock::selectionGapRectsForRepaint):
2216         * rendering/RenderBox.cpp:
2217         (WebCore::RenderBox::mapLocalToContainer):
2218         (WebCore::RenderBox::positionLineBox):
2219         * rendering/RenderEmbeddedObject.cpp:
2220         (WebCore::RenderEmbeddedObject::isInUnavailablePluginIndicator):
2221         * rendering/RenderEmbeddedObject.h:
2222         * rendering/RenderInline.cpp:
2223         (WebCore::RenderInline::localCaretRect):
2224         (WebCore::RenderInline::mapLocalToContainer):
2225         * rendering/RenderLayer.cpp:
2226         (WebCore::RenderLayer::absoluteToContents):
2227         (WebCore::RenderLayer::calculateClipRects):
2228         * rendering/RenderMultiColumnFlowThread.cpp:
2229         (WebCore::RenderMultiColumnFlowThread::mapAbsoluteToLocalPoint):
2230         * rendering/RenderObject.cpp:
2231         (WebCore::RenderObject::mapLocalToContainer):
2232         * rendering/shapes/ShapeOutsideInfo.cpp:
2233         (WebCore::ShapeOutsideInfo::createShapeForImage):
2234         * rendering/svg/RenderSVGContainer.cpp:
2235         (WebCore::RenderSVGContainer::nodeAtFloatPoint):
2236         * rendering/svg/RenderSVGForeignObject.cpp:
2237         (WebCore::RenderSVGForeignObject::nodeAtFloatPoint):
2238         * rendering/svg/RenderSVGImage.cpp:
2239         (WebCore::RenderSVGImage::nodeAtFloatPoint):
2240         * rendering/svg/RenderSVGShape.cpp:
2241         (WebCore::RenderSVGShape::nodeAtFloatPoint):
2242         * testing/Internals.cpp:
2243         (WebCore::Internals::nodesFromRect):
2244
2245 2014-08-25  Zalan Bujtas  <zalan@apple.com>
2246
2247         Rename RenderObject::showTree() and showTreeForThis() to showNodeTree*().
2248         https://bugs.webkit.org/show_bug.cgi?id=136238
2249
2250         Reviewed by Simon Fraser.
2251
2252         showNodeTree()/showNodeTreeForThis() reflects the functionality better.
2253
2254         No change in functionality.
2255
2256         * rendering/InlineBox.cpp:
2257         (WebCore::InlineBox::showNodeTreeForThis):
2258         (showNodeTree):
2259         (WebCore::InlineBox::showTreeForThis): Deleted.
2260         (showTree): Deleted.
2261         * rendering/InlineBox.h:
2262         * rendering/RenderObject.cpp:
2263         (WebCore::RenderObject::showNodeTreeForThis):
2264         (showNodeTree):
2265         (WebCore::RenderObject::showTreeForThis): Deleted.
2266         (showTree): Deleted.
2267         * rendering/RenderObject.h:
2268
2269 2014-08-25  Antti Koivisto  <antti@apple.com>
2270
2271         Don't pass priority as parameter to ResourceLoadScheduler
2272         https://bugs.webkit.org/show_bug.cgi?id=136232
2273
2274         Reviewed by Sam Weinig.
2275
2276         It is part of the ResourceRequest which is also passed in.
2277
2278         * WebCore.exp.in:
2279         * loader/ResourceLoadScheduler.cpp:
2280         (WebCore::ResourceLoadScheduler::scheduleSubresourceLoad):
2281         (WebCore::ResourceLoadScheduler::schedulePluginStreamLoad):
2282         (WebCore::ResourceLoadScheduler::scheduleLoad):
2283         * loader/ResourceLoadScheduler.h:
2284         * loader/cache/CachedResource.cpp:
2285         (WebCore::CachedResource::load):
2286         * platform/network/cf/ResourceRequestCFNet.cpp:
2287         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties):
2288         * platform/network/cocoa/ResourceRequestCocoa.mm:
2289         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties):
2290
2291             Restore the original request priority when a delegate modifies the request.
2292
2293 2014-08-25  Beth Dakin  <bdakin@apple.com>
2294
2295         Rubber-banding in overflow:scroll regions does not work correctly with direction:rtl
2296         https://bugs.webkit.org/show_bug.cgi?id=136176
2297
2298         Reviewed by Sam Weinig.
2299
2300         Use scrollPosition() instead of scrollXOffset() and scrollYOffset() which both add 
2301         in the scrollOrigin(). Other implementations of visibleContentRectInternal() do 
2302         not add in the scrollOrigin(), so RenderLayer's shouldn't either in order to be
2303         consistent. This makes rubber-banding work for RTL because 
2304         ScrollAnimatorMac::pinnedInDirection() and 
2305         ScrollAnimatorMac::absoluteScrollPosition() both return the expect values now.
2306
2307         * rendering/RenderLayer.cpp:
2308         (WebCore::RenderLayer::visibleContentRectInternal):
2309
2310 2014-08-25  Benjamin Poulain  <benjamin@webkit.org>
2311
2312         Reduce style marking when using the pseudo class :placeholder-shown
2313         https://bugs.webkit.org/show_bug.cgi?id=136203
2314
2315         Reviewed by Darin Adler.
2316
2317         When the :placeholder-shown filter is hit, we were always marking the RenderStyle as unique.
2318         As a result, if :placeholder-shown was used without a more restrictive filter (e.g. "*:placeholder-shown"
2319         or simply ":placeholder-shown"), style sharing was disabled for the whole tree.
2320
2321         This patch rescope the tree marking to any element that can be affected by a placeholder:
2322         any the subclass of HTMLTextFormControlElement. For other elements, any change in internal state
2323         would be irrelevant for "isPlaceholderVisible".
2324
2325         Styling of :placeholder-shown is covered by the existing tests. Style sharing of :placeholder-shown
2326         is covered by LayoutTests/fast/css/placeholder-shown-basics.html.
2327
2328         * css/SelectorChecker.cpp:
2329         (WebCore::SelectorChecker::checkOne):
2330         * css/SelectorCheckerTestFunctions.h:
2331         (WebCore::isPlaceholderShown): Deleted.
2332         * cssjit/SelectorCompiler.cpp:
2333         (WebCore::SelectorCompiler::makeContextStyleUniqueIfNecessaryAndTestIsPlaceholderShown):
2334         (WebCore::SelectorCompiler::makeElementStyleUniqueIfNecessaryAndTestIsPlaceholderShown):
2335         (WebCore::SelectorCompiler::isPlaceholderShown):
2336         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementHasPlaceholderShown):
2337         (WebCore::SelectorCompiler::makeUniqueIfNecessaryAndTestIsPlaceholderShown): Deleted.
2338
2339 2014-08-25  Antti Koivisto  <antti@apple.com>
2340
2341         Remove ResourceLoader::didChangePriority
2342         https://bugs.webkit.org/show_bug.cgi?id=136230
2343
2344         Reviewed by Andreas Kling.
2345
2346         It doesn't do anything on any platform.
2347
2348         * loader/ResourceLoader.cpp:
2349         (WebCore::ResourceLoader::didChangePriority): Deleted.
2350         * loader/ResourceLoader.h:
2351         * loader/cache/CachedResource.cpp:
2352         (WebCore::CachedResource::setLoadPriority):
2353         * platform/network/ResourceHandle.cpp:
2354         (WebCore::ResourceHandle::didChangePriority): Deleted.
2355         * platform/network/ResourceHandle.h:
2356
2357 2014-08-24  Brian J. Burg  <burg@cs.washington.edu>
2358
2359         Web Inspector: rename Inspector::TypeBuilder to Inspector::Protocol
2360         https://bugs.webkit.org/show_bug.cgi?id=136031
2361
2362         Reviewed by Timothy Hatcher.
2363
2364         Rename TypeBuilder namespace to Protocol. Disambiguate where
2365         necessary. Also rename InspectorTypeBuilder to ProtocolTypes.
2366
2367         * CMakeLists.txt:
2368         * DerivedSources.make:
2369         * ForwardingHeaders/inspector/InspectorJSTypeBuilders.h: Removed.
2370         * ForwardingHeaders/inspector/InspectorTypeBuilder.h: Removed.
2371         * WebCore.order:
2372         * WebCore.vcxproj/WebCore.vcxproj:
2373         * WebCore.vcxproj/WebCore.vcxproj.filters:
2374         * WebCore.xcodeproj/project.pbxproj:
2375         * inspector/CommandLineAPIHost.cpp:
2376         (WebCore::CommandLineAPIHost::inspectImpl):
2377         * inspector/InspectorApplicationCacheAgent.cpp:
2378         (WebCore::InspectorApplicationCacheAgent::getFramesWithManifests):
2379         (WebCore::InspectorApplicationCacheAgent::getApplicationCacheForFrame):
2380         (WebCore::InspectorApplicationCacheAgent::buildObjectForApplicationCache):
2381         (WebCore::InspectorApplicationCacheAgent::buildArrayForApplicationCacheResources):
2382         (WebCore::InspectorApplicationCacheAgent::buildObjectForApplicationCacheResource):
2383         * inspector/InspectorApplicationCacheAgent.h:
2384         * inspector/InspectorCSSAgent.cpp:
2385         (WebCore::InspectorCSSAgent::getMatchedStylesForNode):
2386         (WebCore::InspectorCSSAgent::getInlineStylesForNode):
2387         (WebCore::InspectorCSSAgent::getComputedStyleForNode):
2388         (WebCore::InspectorCSSAgent::getAllStyleSheets):
2389         (WebCore::InspectorCSSAgent::getStyleSheet):
2390         (WebCore::InspectorCSSAgent::setStyleText):
2391         (WebCore::InspectorCSSAgent::setPropertyText):
2392         (WebCore::InspectorCSSAgent::toggleProperty):
2393         (WebCore::InspectorCSSAgent::setRuleSelector):
2394         (WebCore::InspectorCSSAgent::addRule):
2395         (WebCore::InspectorCSSAgent::getSupportedCSSProperties):
2396         (WebCore::InspectorCSSAgent::getNamedFlowCollection):
2397         (WebCore::InspectorCSSAgent::asInspectorStyleSheet):
2398         (WebCore::InspectorCSSAgent::collectStyleSheets):
2399         (WebCore::InspectorCSSAgent::viaInspectorStyleSheet):
2400         (WebCore::InspectorCSSAgent::detectOrigin):
2401         (WebCore::InspectorCSSAgent::buildObjectForRule):
2402         (WebCore::InspectorCSSAgent::buildArrayForRuleList):
2403         (WebCore::InspectorCSSAgent::buildArrayForMatchedRuleList):
2404         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
2405         (WebCore::InspectorCSSAgent::buildArrayForRegions):
2406         (WebCore::InspectorCSSAgent::buildObjectForNamedFlow):
2407         * inspector/InspectorCSSAgent.h:
2408         * inspector/InspectorDOMAgent.cpp:
2409         (WebCore::InspectorDOMAgent::didCreateFrontendAndBackend):
2410         (WebCore::InspectorDOMAgent::getDocument):
2411         (WebCore::InspectorDOMAgent::pushChildNodesToFrontend):
2412         (WebCore::InspectorDOMAgent::querySelectorAll):
2413         (WebCore::InspectorDOMAgent::pushNodePathToFrontend):
2414         (WebCore::InspectorDOMAgent::getEventListenersForNode):
2415         (WebCore::InspectorDOMAgent::getAccessibilityPropertiesForNode):
2416         (WebCore::InspectorDOMAgent::getSearchResults):
2417         (WebCore::InspectorDOMAgent::resolveNode):
2418         (WebCore::InspectorDOMAgent::getAttributes):
2419         (WebCore::InspectorDOMAgent::buildObjectForNode):
2420         (WebCore::InspectorDOMAgent::buildArrayForElementAttributes):
2421         (WebCore::InspectorDOMAgent::buildArrayForContainerChildren):
2422         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
2423         (WebCore::InspectorDOMAgent::processAccessibilityChildren):
2424         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
2425         (WebCore::InspectorDOMAgent::didCommitLoad):
2426         (WebCore::InspectorDOMAgent::didInsertDOMNode):
2427         (WebCore::InspectorDOMAgent::styleAttributeInvalidated):
2428         * inspector/InspectorDOMAgent.h:
2429         * inspector/InspectorDOMDebuggerAgent.cpp:
2430         (WebCore::InspectorDOMDebuggerAgent::descriptionForDOMEvent):
2431         * inspector/InspectorDOMStorageAgent.cpp:
2432         (WebCore::InspectorDOMStorageAgent::getDOMStorageItems):
2433         (WebCore::InspectorDOMStorageAgent::storageId):
2434         (WebCore::InspectorDOMStorageAgent::didDispatchDOMStorageEvent):
2435         * inspector/InspectorDOMStorageAgent.h:
2436         * inspector/InspectorDatabaseAgent.cpp:
2437         (WebCore::InspectorDatabaseAgent::getDatabaseTableNames):
2438         * inspector/InspectorDatabaseAgent.h:
2439         * inspector/InspectorDatabaseResource.cpp:
2440         (WebCore::InspectorDatabaseResource::bind):
2441         * inspector/InspectorIndexedDBAgent.cpp:
2442         * inspector/InspectorLayerTreeAgent.cpp:
2443         (WebCore::InspectorLayerTreeAgent::layersForNode):
2444         (WebCore::InspectorLayerTreeAgent::gatherLayersUsingRenderObjectHierarchy):
2445         (WebCore::InspectorLayerTreeAgent::gatherLayersUsingRenderLayerHierarchy):
2446         (WebCore::InspectorLayerTreeAgent::buildObjectForLayer):
2447         (WebCore::InspectorLayerTreeAgent::buildObjectForIntRect):
2448         (WebCore::InspectorLayerTreeAgent::reasonsForCompositingLayer):
2449         * inspector/InspectorLayerTreeAgent.h:
2450         * inspector/InspectorPageAgent.cpp:
2451         (WebCore::InspectorPageAgent::resourceTypeJson):
2452         (WebCore::InspectorPageAgent::cachedResourceTypeJson):
2453         (WebCore::buildObjectForCookie):
2454         (WebCore::buildArrayForCookies):
2455         (WebCore::InspectorPageAgent::getCookies):
2456         (WebCore::InspectorPageAgent::getResourceTree):
2457         (WebCore::InspectorPageAgent::searchInResource):
2458         (WebCore::buildObjectForSearchResult):
2459         (WebCore::InspectorPageAgent::searchInResources):
2460         (WebCore::InspectorPageAgent::buildObjectForFrame):
2461         (WebCore::InspectorPageAgent::buildObjectForFrameTree):
2462         * inspector/InspectorPageAgent.h:
2463         * inspector/InspectorReplayAgent.cpp:
2464         (WebCore::buildInspectorObjectForPosition):
2465         (WebCore::buildInspectorObjectForInput):
2466         (WebCore::buildInspectorObjectForSession):
2467         (WebCore::buildInspectorObjectForSessionState):
2468         (WebCore::buildInspectorObjectForSegmentState):
2469         (WebCore::SerializeInputToJSONFunctor::SerializeInputToJSONFunctor):
2470         (WebCore::SerializeInputToJSONFunctor::operator()):
2471         (WebCore::buildInspectorObjectForSegment):
2472         (WebCore::InspectorReplayAgent::switchSession):
2473         (WebCore::InspectorReplayAgent::insertSessionSegment):
2474         (WebCore::InspectorReplayAgent::removeSessionSegment):
2475         (WebCore::InspectorReplayAgent::currentReplayState):
2476         (WebCore::InspectorReplayAgent::getAvailableSessions):
2477         (WebCore::InspectorReplayAgent::getSessionData):
2478         (WebCore::InspectorReplayAgent::getSegmentData):
2479         * inspector/InspectorReplayAgent.h:
2480         * inspector/InspectorResourceAgent.cpp:
2481         (WebCore::buildObjectForTiming):
2482         (WebCore::buildObjectForResourceRequest):
2483         (WebCore::buildObjectForResourceResponse):
2484         (WebCore::buildObjectForCachedResource):
2485         (WebCore::InspectorResourceAgent::willSendRequest):
2486         (WebCore::InspectorResourceAgent::didReceiveResponse):
2487         (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache):
2488         (WebCore::InspectorResourceAgent::buildInitiatorObject):
2489         (WebCore::InspectorResourceAgent::willSendWebSocketHandshakeRequest):
2490         (WebCore::InspectorResourceAgent::didReceiveWebSocketHandshakeResponse):
2491         (WebCore::InspectorResourceAgent::didReceiveWebSocketFrame):
2492         (WebCore::InspectorResourceAgent::didSendWebSocketFrame):
2493         * inspector/InspectorResourceAgent.h:
2494         * inspector/InspectorStyleSheet.cpp:
2495         (WebCore::buildSourceRangeObject):
2496         (WebCore::buildMediaObject):
2497         (WebCore::fillMediaListChain):
2498         (WebCore::InspectorStyle::buildObjectForStyle):
2499         (WebCore::InspectorStyle::buildArrayForComputedStyle):
2500         (WebCore::InspectorStyle::styleWithProperties):
2501         (WebCore::InspectorStyleSheet::create):
2502         (WebCore::InspectorStyleSheet::InspectorStyleSheet):
2503         (WebCore::InspectorStyleSheet::buildObjectForStyleSheet):
2504         (WebCore::InspectorStyleSheet::buildObjectForStyleSheetInfo):
2505         (WebCore::selectorsFromSource):
2506         (WebCore::InspectorStyleSheet::buildObjectForSelectorList):
2507         (WebCore::InspectorStyleSheet::buildObjectForRule):
2508         (WebCore::InspectorStyleSheet::buildObjectForStyle):
2509         (WebCore::InspectorStyleSheet::resourceStyleSheetText):
2510         (WebCore::InspectorStyleSheet::buildArrayForRuleList):
2511         (WebCore::InspectorStyleSheetForInlineStyle::create):
2512         (WebCore::InspectorStyleSheetForInlineStyle::InspectorStyleSheetForInlineStyle):
2513         * inspector/InspectorStyleSheet.h:
2514         (WebCore::InspectorStyleSheet::canBind):
2515         * inspector/InspectorTimelineAgent.cpp:
2516         (WebCore::toProtocol):
2517         (WebCore::InspectorTimelineAgent::addRecordToTimeline):
2518         (WebCore::InspectorTimelineAgent::sendEvent):
2519         * inspector/PageRuntimeAgent.cpp:
2520
2521 2014-08-25  Brendan Long  <b.long@cablelabs.com>
2522
2523         [GStreamer] ASSERT failure in WebKitWebSource in StreamingClient
2524         https://bugs.webkit.org/show_bug.cgi?id=136132
2525
2526         adoptGRef() has an ASSERT failure if it's used on a floating pointer. For some reason,
2527         WebKitWebSrc* src in StreamingClient's constructor is floating. Since we
2528         don't construct this ourselves, I assume this is happening in Playbin.
2529
2530         If we remove the ref and adopt, GRefPtr's constructor calls gst_object_ref_sink,
2531         which removes the floating reference and doesn't increment the reference count.
2532         This should work, but actually causes the page to either lock up or crash (different
2533         results for different testers).
2534
2535         In this case, it seems like the adoptGRef / gst_object_ref was the correct thing to do,
2536         but adoptGRef won't actually let us do. Removing the ASSERT is a bad idea, because
2537         usually we don't want to adopt floating pointers.
2538
2539         This is all a long way of saying that making m_src a raw pointer and manually
2540         calling gst_object_ref(), and calling gst_object_unref in the destructor is the
2541         best solution in this case, since it fixes the problem while leaving the ASSERT
2542         to protect us in the much more common case where adopting a floating reference is bad.
2543
2544         Reviewed by Philippe Normand.
2545
2546         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
2547         (StreamingClient::StreamingClient): Make m_src a raw pointer instead of a GRefPtr.
2548         (StreamingClient::~StreamingClient): Unref m_src.
2549         (StreamingClient::createReadBuffer): Replace m_src.get() with m_src, since it's a raw pointer now.
2550         (StreamingClient::handleResponseReceived): Same.
2551         (StreamingClient::handleDataReceived): Same.
2552         (StreamingClient::handleNotifyFinished): Same.
2553         (CachedResourceStreamingClient::notifyFinished): Same.
2554         (ResourceHandleStreamingClient::didFail): Same.
2555         (ResourceHandleStreamingClient::wasBlocked): Same.
2556         (ResourceHandleStreamingClient::cannotShowURL): Same.
2557
2558 2014-08-25  Zan Dobersek  <zdobersek@igalia.com>
2559
2560         [GTK] Remove PopupMenuGtk, SearchPopupMenuGtk
2561         https://bugs.webkit.org/show_bug.cgi?id=136211
2562
2563         Reviewed by Carlos Garcia Campos.
2564
2565         Remove the two classes from the codebase. They're not used anymore
2566         after the WebKit1 layer of the GTK port was removed some time ago.
2567
2568         * PlatformGTK.cmake:
2569         * platform/gtk/PopupMenuGtk.cpp: Removed.
2570         * platform/gtk/PopupMenuGtk.h: Removed.
2571         * platform/gtk/SearchPopupMenuGtk.cpp: Removed.
2572         * platform/gtk/SearchPopupMenuGtk.h: Removed.
2573
2574 2014-08-25  Shivakumar JM  <shiva.jm@samsung.com>
2575
2576         Web Core: Fix unused parameter build warning.
2577         https://bugs.webkit.org/show_bug.cgi?id=136208
2578
2579         Reviewed by Darin Adler.
2580
2581         Fix unused build warning by removing parameter, which is not used.
2582
2583         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
2584         (WebCore::CoordinatedGraphicsLayer::setContentsToPlatformLayer):
2585
2586 2014-08-22  Sergio Villar Senin  <svillar@igalia.com>
2587
2588         ASSERTION FAILED: !trackSizes.isEmpty() in WebCore::createGridTrackList
2589         https://bugs.webkit.org/show_bug.cgi?id=136149
2590
2591         Reviewed by Darin Adler.
2592
2593         The second argument of the repeat() function is a <track-list>
2594         that must have at least one <track-size>. Should it not be found,
2595         the declaration must be invalidated.
2596
2597         * css/CSSParser.cpp:
2598         (WebCore::CSSParser::parseGridTrackRepeatFunction):
2599
2600 2014-08-24  Zan Dobersek  <zdobersek@igalia.com>
2601
2602         Move WebCore storage code to C++11 lambdas, std::function
2603         https://bugs.webkit.org/show_bug.cgi?id=126435
2604
2605         Reviewed by Darin Adler.
2606
2607         Use C++11 lambdas instead of WTF::bind and std::function<void ()>
2608         instead of WTF::Function<void ()> in StorageAreaSync, StorageSyncManager,
2609         StorageThread and StorageTracker classes.
2610
2611         * storage/StorageAreaSync.cpp:
2612         (WebCore::StorageAreaSync::StorageAreaSync):
2613         (WebCore::StorageAreaSync::scheduleFinalSync):
2614         (WebCore::StorageAreaSync::syncTimerFired):
2615         * storage/StorageSyncManager.cpp:
2616         (WebCore::StorageSyncManager::dispatch):
2617         * storage/StorageSyncManager.h:
2618         * storage/StorageThread.cpp:
2619         (WebCore::StorageThread::dispatch):
2620         (WebCore::StorageThread::terminate):
2621         (WebCore::StorageThread::releaseFastMallocFreeMemoryInAllThreads):
2622         * storage/StorageThread.h:
2623         * storage/StorageTracker.cpp:
2624         (WebCore::StorageTracker::importOriginIdentifiers):
2625         (WebCore::StorageTracker::syncImportOriginIdentifiers):
2626         (WebCore::StorageTracker::syncFileSystemAndTrackerDatabase):
2627         (WebCore::StorageTracker::setOriginDetails):
2628         (WebCore::StorageTracker::deleteAllOrigins):
2629         (WebCore::StorageTracker::deleteOrigin):
2630
2631 2014-08-24  Alexey Proskuryakov  <ap@apple.com>
2632
2633         ASSERT(extractable()) when storing a non-extractable key in IndexedDB
2634         https://bugs.webkit.org/show_bug.cgi?id=136202
2635         rdar://problem/17993967
2636
2637         Reviewed by Darin Adler.
2638
2639         Test: crypto/subtle/rsa-indexeddb-non-exportable.html
2640
2641         Removed the obsolete assertion.
2642
2643         * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::exportData):
2644         * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::exportData):
2645         * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::exportData):
2646
2647 2014-08-24  Brian J. Burg  <burg@cs.washington.edu>
2648
2649         Web Inspector: Rename DOM.RGBA and remove workarounds in the bindings generator
2650         https://bugs.webkit.org/show_bug.cgi?id=136025
2651
2652         Reviewed by Joseph Pecoraro.
2653
2654         Rename DOM.RGBA to DOM.RGBAColor to avoid name clashes with headers on Windows CE.
2655         This workaround used to be special-cased in the bindings generator.
2656
2657         Type names are not used in protocol messages, so this does not introduce legacy issues.
2658
2659         * inspector/protocol/DOM.json:
2660
2661 2014-08-24  Michael Catanzaro  <mcatanzaro@igalia.com>
2662
2663         [GTK] Toggle buttons visually broken with GTK+ 3.13.7
2664         https://bugs.webkit.org/show_bug.cgi?id=136130
2665
2666         Reviewed by Martin Robinson.
2667
2668         No new tests. Hopefully covered by existing tests, and our tests only
2669         run with GTK+ 3.6 anyway.
2670
2671         * platform/gtk/RenderThemeGtk3.cpp:
2672         (WebCore::paintToggle): use GTK_STATE_FLAG_CHECKED when compiling for
2673         GTK+ 3.13.7 and above to ensure toggle buttons display as toggled.
2674
2675 2014-08-23  Brady Eidson  <beidson@apple.com>
2676
2677         Random Gamepad cleanup
2678         https://bugs.webkit.org/show_bug.cgi?id=136193
2679
2680         Reviewed by Sam Weinig.
2681
2682         No new tests (Not tested yet, and no change in behavior anyways)
2683
2684         - Use DOMWindow WeakPtrs when iterating
2685         - More references instead of pointers
2686
2687         * Modules/gamepad/GamepadEvent.cpp:
2688         (WebCore::GamepadEvent::GamepadEvent):
2689         * Modules/gamepad/GamepadEvent.h:
2690         (WebCore::GamepadEvent::create):
2691
2692         * Modules/gamepad/GamepadManager.cpp:
2693         (WebCore::GamepadManager::platformGamepadDisconnected):
2694         (WebCore::GamepadManager::makeGamepadVisible):
2695         * Modules/gamepad/NavigatorGamepad.cpp:
2696         (WebCore::NavigatorGamepad::gamepadFromPlatformGamepad):
2697         (WebCore::NavigatorGamepad::gamepadAtIndex): Deleted.
2698         * Modules/gamepad/NavigatorGamepad.h:
2699
2700         * page/DOMWindow.cpp:
2701         (WebCore::DOMWindow::DOMWindow):
2702         * page/DOMWindow.h:
2703
2704 2014-08-23  Byungseon Shin  <sun.shin@lge.com>
2705
2706         Unify GraphicsLayer::setContentsToMedia and setContentsToCanvas
2707         https://bugs.webkit.org/show_bug.cgi?id=109658
2708
2709         Reviewed by Martin Robinson.
2710  
2711         Based on patch originally written by Tim Horton.
2712         Merge setContentsToMedia and setContentsToCanvas into setContentsToPlatformLayer.
2713  
2714         * WebCore.exp.in:
2715         Adjust exports.
2716  
2717         * platform/graphics/GraphicsLayer.h:
2718         Move ContentsLayerPurpose enum up out of GraphicsLayer platform implmentations
2719         and into GraphicsLayer, so we can use it as a parameter.
2720         Add ContentsLayerForPlugin.
2721  
2722         (WebCore::GraphicsLayer::setContentsToPlatformLayer):
2723         Remove setContentsToMedia and setContentsToCanvas, and replace them
2724         with setContentsToPlatformLayer, which previously existed but was unused
2725         and simply called setContentsToMedia.
2726         setContentsToPlatformLayer takes a ContentsLayerPurpose, primarily
2727         so that GraphicsLayerCA can know whether it needs to setNeedsDisplay
2728         the layer when parenting it (canvas) or not (everything else).
2729  
2730         * platform/graphics/ca/GraphicsLayerCA.cpp:
2731         (WebCore::GraphicsLayerCA::setContentsToPlatformLayer):
2732         Rename function setContentsToMedia -> setContentsToPlatformLayer.
2733         Rename argument mediaLayer -> platformLayer.
2734         Store the passed-in ContentsLayerPurpose.
2735         Remove setContentsToCanvas.
2736  
2737         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
2738         (WebCore::GraphicsLayerCA::updateContentsPlatformLayer):
2739         Remove updateContentsMediaLayer and updateContentsCanvas layer,
2740         add updateContentsPlatformLayer.
2741  
2742         * platform/graphics/ca/GraphicsLayerCA.h:
2743         Do the same to the LayerChange enum.
2744  
2745         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2746         (WebCore::GraphicsLayerTextureMapper::setContentsToImage):
2747         (WebCore::GraphicsLayerTextureMapper::setContentsToPlatformLayer):
2748         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
2749         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
2750         (WebCore::CoordinatedGraphicsLayer::CoordinatedGraphicsLayer):
2751         (WebCore::CoordinatedGraphicsLayer::setContentsNeedsDisplay):
2752         (WebCore::CoordinatedGraphicsLayer::setContentsToPlatformLayer):
2753         (WebCore::CoordinatedGraphicsLayer::syncPlatformLayer):
2754         (WebCore::CoordinatedGraphicsLayer::destroyPlatformLayerIfNeeded):
2755         (WebCore::CoordinatedGraphicsLayer::createPlatformLayerIfNeeded):
2756         (WebCore::CoordinatedGraphicsLayer::flushCompositingStateForThisLayerOnly):
2757         Fold these together in the same way as elsewhere.
2758  
2759         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
2760         Do the same to the LayerChange enum.
2761  
2762         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
2763         (WebCore::CoordinatedGraphicsScene::createPlatformLayerIfNeeded):
2764         (WebCore::CoordinatedGraphicsScene::syncPlatformLayerIfNeeded):
2765         (WebCore::CoordinatedGraphicsScene::destroyPlatformLayerIfNeeded):
2766         (WebCore::CoordinatedGraphicsScene::setLayerState):
2767         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
2768         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
2769         (WebCore::CoordinatedGraphicsLayerState::CoordinatedGraphicsLayerState):
2770         Rename canvasLayer -> platformLayer.
2771  
2772         * rendering/RenderLayerBacking.cpp:
2773         (WebCore::RenderLayerBacking::updateConfiguration):
2774         Use the new setContentsToPlatformLayer, passing in the relevant ContentsLayerPurpose.
2775
2776 2014-08-23  Joseph Pecoraro  <pecoraro@apple.com>
2777
2778         Web Inspector: Do not copy large module source strings
2779         https://bugs.webkit.org/show_bug.cgi?id=136191
2780
2781         Reviewed by Benjamin Poulain.
2782
2783         * inspector/CommandLineAPIModule.cpp:
2784         (WebCore::CommandLineAPIModule::source):
2785
2786 2014-08-23  Zan Dobersek  <zdobersek@igalia.com>
2787
2788         Remove uses of CrossThreadTask in ThreadableWebSocketChannelClientWrapper, WorkerThreadableWebSocketChannel
2789         https://bugs.webkit.org/show_bug.cgi?id=133954
2790
2791         Reviewed by Darin Adler.
2792
2793         Replace uses of CrossThreadTask with C++11 lambdas in the ThreadableWebSocketChannelClientWrapper
2794         and WorkerThreadableWebSocketChannel classes.
2795
2796         * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
2797         (WebCore::ThreadableWebSocketChannelClientWrapper::didConnect):
2798         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessage):
2799         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
2800         (WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmount):
2801         (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshake):
2802         (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
2803         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageError):
2804         (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks):
2805         (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasksCallback): Deleted.
2806         (WebCore::ThreadableWebSocketChannelClientWrapper::didConnectCallback): Deleted.
2807         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageCallback): Deleted.
2808         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryDataCallback): Deleted.
2809         (WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmountCallback): Deleted.
2810         (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshakeCallback): Deleted.
2811         (WebCore::ThreadableWebSocketChannelClientWrapper::didCloseCallback): Deleted.
2812         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageErrorCallback): Deleted.
2813         * Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
2814         * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
2815         (WebCore::WorkerThreadableWebSocketChannel::Peer::send):
2816         (WebCore::WorkerThreadableWebSocketChannel::Peer::bufferedAmount):
2817         (WebCore::WorkerThreadableWebSocketChannel::Peer::didConnect):
2818         (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveMessage):
2819         (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData):
2820         (WebCore::WorkerThreadableWebSocketChannel::Peer::didUpdateBufferedAmount):
2821         (WebCore::WorkerThreadableWebSocketChannel::Peer::didStartClosingHandshake):
2822         (WebCore::WorkerThreadableWebSocketChannel::Peer::didClose):
2823         (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveMessageError):
2824         (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadInitialize):
2825         (WebCore::WorkerThreadableWebSocketChannel::Bridge::connect):
2826         (WebCore::WorkerThreadableWebSocketChannel::Bridge::send):
2827         (WebCore::WorkerThreadableWebSocketChannel::Bridge::bufferedAmount):
2828         (WebCore::WorkerThreadableWebSocketChannel::Bridge::close):
2829         (WebCore::WorkerThreadableWebSocketChannel::Bridge::fail):
2830         (WebCore::WorkerThreadableWebSocketChannel::Bridge::disconnect):
2831         (WebCore::WorkerThreadableWebSocketChannel::Bridge::suspend):
2832         (WebCore::WorkerThreadableWebSocketChannel::Bridge::resume):
2833         (WebCore::workerGlobalScopeDidSend): Deleted.
2834         (WebCore::workerGlobalScopeDidGetBufferedAmount): Deleted.
2835         (WebCore::workerGlobalScopeDidConnect): Deleted.
2836         (WebCore::workerGlobalScopeDidReceiveMessage): Deleted.
2837         (WebCore::workerGlobalScopeDidReceiveBinaryData): Deleted.
2838         (WebCore::workerGlobalScopeDidUpdateBufferedAmount): Deleted.
2839         (WebCore::workerGlobalScopeDidStartClosingHandshake): Deleted.
2840         (WebCore::workerGlobalScopeDidClose): Deleted.
2841         (WebCore::workerGlobalScopeDidReceiveMessageError): Deleted.
2842         (WebCore::WorkerThreadableWebSocketChannel::mainThreadConnect): Deleted.
2843         (WebCore::WorkerThreadableWebSocketChannel::mainThreadSend): Deleted.
2844         (WebCore::WorkerThreadableWebSocketChannel::mainThreadSendArrayBuffer): Deleted.
2845         (WebCore::WorkerThreadableWebSocketChannel::mainThreadSendBlob): Deleted.
2846         (WebCore::WorkerThreadableWebSocketChannel::mainThreadBufferedAmount): Deleted.
2847         (WebCore::WorkerThreadableWebSocketChannel::mainThreadClose): Deleted.
2848         (WebCore::WorkerThreadableWebSocketChannel::mainThreadFail): Deleted.
2849         (WebCore::WorkerThreadableWebSocketChannel::mainThreadDestroy): Deleted.
2850         (WebCore::WorkerThreadableWebSocketChannel::mainThreadSuspend): Deleted.
2851         (WebCore::WorkerThreadableWebSocketChannel::mainThreadResume): Deleted.
2852         * Modules/websockets/WorkerThreadableWebSocketChannel.h:
2853
2854 2014-08-23  Yusuke Suzuki  <utatane.tea@gmail.com>
2855
2856         Clean up build warnings: control reaches end of non-void function
2857         https://bugs.webkit.org/show_bug.cgi?id=135889
2858
2859         Reviewed by Alexey Proskuryakov.
2860
2861         * bindings/js/JSCryptoAlgorithmDictionary.cpp:
2862         (WebCore::JSCryptoAlgorithmDictionary::createParametersForEncrypt):
2863         (WebCore::JSCryptoAlgorithmDictionary::createParametersForDecrypt):
2864         (WebCore::JSCryptoAlgorithmDictionary::createParametersForSign):
2865         (WebCore::JSCryptoAlgorithmDictionary::createParametersForVerify):
2866         (WebCore::JSCryptoAlgorithmDictionary::createParametersForDigest):
2867         (WebCore::JSCryptoAlgorithmDictionary::createParametersForGenerateKey):
2868         (WebCore::JSCryptoAlgorithmDictionary::createParametersForDeriveKey):
2869         (WebCore::JSCryptoAlgorithmDictionary::createParametersForDeriveBits):
2870         (WebCore::JSCryptoAlgorithmDictionary::createParametersForImportKey):
2871         (WebCore::JSCryptoAlgorithmDictionary::createParametersForExportKey):
2872         * crypto/CryptoKey.cpp:
2873         (WebCore::CryptoKey::type):
2874
2875 2014-08-23  Zan Dobersek  <zdobersek@igalia.com>
2876
2877         [TexMap] Only notify of a required flush on the first layer property change
2878         https://bugs.webkit.org/show_bug.cgi?id=136104
2879
2880         Reviewed by Martin Robinson.
2881
2882         The GraphicsLayer's client should only be notified that a flush is required
2883         when the first change of one of the layer's properties is initiated, instead
2884         of requesting the flush on every such change.
2885
2886         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2887         (WebCore::GraphicsLayerTextureMapper::notifyChange):
2888
2889 2014-08-22  Dan Bernstein  <mitz@apple.com>
2890
2891         Try to fix the Mac build using the internal SDK.
2892
2893         * bindings/objc/PublicDOMInterfaces.h:
2894
2895 2014-08-22  Renato Nagy  <nagy.renato@stud.u-szeged.hu>
2896
2897         Remove LevelDB.
2898         https://bugs.webkit.org/show_bug.cgi?id=136170
2899
2900         Reviewed by Gyuyoung Kim.
2901
2902         * CMakeLists.txt:
2903         * Modules/indexeddb/IDBObjectStore.cpp:
2904         (WebCore::IDBObjectStore::createIndex):
2905         * Modules/indexeddb/IDBTransactionCoordinator.cpp:
2906         (WebCore::IDBTransactionCoordinator::canRunTransaction):
2907         (WebCore::doScopesOverlap): Deleted.
2908         * Modules/indexeddb/leveldb/IDBBackingStoreCursorLevelDB.cpp: Removed.
2909         * Modules/indexeddb/leveldb/IDBBackingStoreCursorLevelDB.h: Removed.
2910         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp: Removed.
2911         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h: Removed.
2912         * Modules/indexeddb/leveldb/IDBBackingStoreTransactionLevelDB.cpp: Removed.
2913         * Modules/indexeddb/leveldb/IDBBackingStoreTransactionLevelDB.h: Removed.
2914         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp: Removed.
2915         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.h: Removed.
2916         * Modules/indexeddb/leveldb/IDBIndexWriterLevelDB.cpp: Removed.
2917         * Modules/indexeddb/leveldb/IDBIndexWriterLevelDB.h: Removed.
2918         * Modules/indexeddb/leveldb/IDBLevelDBCoding.cpp: Removed.
2919         * Modules/indexeddb/leveldb/IDBLevelDBCoding.h: Removed.
2920         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp: Removed.
2921         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.h: Removed.
2922         * WebCore.vcxproj/WebCore.vcxproj:
2923         * WebCore.vcxproj/WebCore.vcxproj.filters:
2924         * WebCore.xcodeproj/project.pbxproj:
2925         * platform/DatabaseStrategy.cpp:
2926         (WebCore::DatabaseStrategy::createIDBFactoryBackend):
2927         * platform/leveldb/LevelDBComparator.h: Removed.
2928         * platform/leveldb/LevelDBDatabase.cpp: Removed.
2929         * platform/leveldb/LevelDBDatabase.h: Removed.
2930         * platform/leveldb/LevelDBIterator.h: Removed.
2931         * platform/leveldb/LevelDBSlice.h: Removed.
2932         * platform/leveldb/LevelDBTransaction.cpp: Removed.
2933         * platform/leveldb/LevelDBTransaction.h: Removed.
2934         * platform/leveldb/LevelDBWriteBatch.cpp: Removed.
2935         * platform/leveldb/LevelDBWriteBatch.h: Removed.
2936
2937 2014-08-22  KwangHyuk Kim  <hyuki.kim@samsung.com>
2938
2939         [EFL] Fix build break caused by ENABLE_GAMEPAD_DEPRECATED.
2940         https://bugs.webkit.org/show_bug.cgi?id=136110
2941
2942         Reviewed by Gyuyoung Kim.
2943
2944         WebCore_INCLUDE_DIRECTORY for gamepad was removed from WK2 Efl in order to fix build break when ENABLE_GAMEPAD_DEPRECATED is on.
2945
2946         No new tests because no functional changes.
2947
2948         * PlatformEfl.cmake:
2949
2950 2014-08-22  Benjamin Poulain  <benjamin@webkit.org>
2951
2952         Style invalidation does not work for adjacent node updates
2953         https://bugs.webkit.org/show_bug.cgi?id=136145
2954
2955         Reviewed by Antti Koivisto.
2956
2957         There were a bunch of cases in which the style would be in an inconsistent
2958         state until the style resolver kicks in for the entire document.
2959
2960         For example, let's take the selector "foo.bar + target". When the class "bar"
2961         changes, the element foo is invalidated. The element target is untouched.
2962
2963         Now, if the style of "target" is accessed, nodeOrItsAncestorNeedsStyleRecalc()
2964         returns false and the old style is accessed.
2965
2966         At some point, when the style of the entire document is resolved, the node
2967         "foo" is styled, and "target" is invalidated.
2968
2969
2970         To fix the issue, this patch adds an extra flag keeping track of subtrees that
2971         have any node needing style recalc: DirectChildNeedsStyleRecalcFlag.
2972
2973         When invalidating the node "foo", its parent is marked with
2974         DirectChildNeedsStyleRecalcFlag to note that one of the child nodes has an invalid style.
2975
2976         When verifying the style state in nodeOrItsAncestorNeedsStyleRecalc(), we check that flag
2977         in addition to the siblings dependencies to find if the node is part of a subtree that may
2978         be invalid due to sibling selectors.
2979
2980         Similarly, in the style resolver, we use the flag to clear the style on all elements
2981         that could potentially be invalid.
2982
2983
2984         This patch removes the changes introduced by r172721
2985         (The style is not updated correctly when the pseudo class :empty is applied on anything but the rightmost element).
2986         That bug was just a special case of what is solved here.
2987
2988
2989         Tests: fast/selectors/attribute-direct-adjacent-style-update.html
2990                fast/selectors/attribute-sibling-style-update.html
2991                fast/selectors/class-direct-adjacent-style-update.html
2992                fast/selectors/class-sibling-style-update.html
2993                fast/selectors/first-child-direct-adjacent-style-update.html
2994                fast/selectors/first-child-sibling-style-update.html
2995
2996         * css/SelectorChecker.cpp:
2997         (WebCore::SelectorChecker::checkOne):
2998         * cssjit/SelectorCompiler.cpp:
2999         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsEmpty):
3000         (WebCore::SelectorCompiler::setStyleOfSiblingsAffectedByEmpty): Deleted.
3001         * dom/ContainerNode.h:
3002         (WebCore::ContainerNode::directChildNeedsStyleRecalc):
3003         (WebCore::ContainerNode::setDirectChildNeedsStyleRecalc):
3004         Remove the special case for :empty.
3005
3006         * dom/Document.cpp:
3007         (WebCore::nodeOrItsAncestorNeedsStyleRecalc):
3008         * dom/Element.cpp:
3009         (WebCore::checkForEmptyStyleChange):
3010         (WebCore::checkForSiblingStyleChanges):
3011         (WebCore::Element::setStyleOfSiblingsAffectedByEmpty): Deleted.
3012         (WebCore::Element::rareDataStyleOfSiblingsAffectedByEmpty): Deleted.
3013         * dom/Element.h:
3014         (WebCore::Element::styleOfSiblingsAffectedByEmpty): Deleted.
3015         * dom/ElementRareData.h:
3016         (WebCore::ElementRareData::ElementRareData):
3017         (WebCore::ElementRareData::styleOfSiblingsAffectedByEmpty): Deleted.
3018         (WebCore::ElementRareData::setStyleOfSiblingsAffectedByEmpty): Deleted.
3019         * dom/Node.cpp:
3020         (WebCore::markAncestorsWithChildNeedsStyleRecalc):
3021         (WebCore::Node::setNeedsStyleRecalc):
3022         (WebCore::Node::markAncestorsWithChildNeedsStyleRecalc): Deleted.
3023         * dom/Node.h:
3024         (WebCore::Node::clearChildNeedsStyleRecalc):
3025         * style/StyleResolveTree.cpp:
3026         (WebCore::Style::resetStyleForNonRenderedDescendants):
3027
3028 2014-08-22  Joseph Pecoraro  <pecoraro@apple.com>
3029
3030         Remove unused legacy InspectorFrontendHost methods
3031         https://bugs.webkit.org/show_bug.cgi?id=136186
3032
3033         Reviewed by Andreas Kling.
3034
3035         * bindings/js/JSInspectorFrontendHostCustom.cpp:
3036         (WebCore::JSInspectorFrontendHost::recordActionTaken): Deleted.
3037         (WebCore::JSInspectorFrontendHost::recordPanelShown): Deleted.
3038         (WebCore::JSInspectorFrontendHost::recordSettingChanged): Deleted.
3039         * inspector/InspectorFrontendHost.idl:
3040
3041 2014-08-22  Joseph Pecoraro  <pecoraro@apple.com>
3042
3043         Remove unnecessary WTFString creation in Dictionary getter
3044         https://bugs.webkit.org/show_bug.cgi?id=136184
3045
3046         Reviewed by Benjamin Poulain.
3047
3048         * bindings/js/Dictionary.cpp:
3049         (WebCore::Dictionary::getWithUndefinedOrNullCheck):
3050         * bindings/js/Dictionary.h:
3051         * bindings/js/JSDictionary.cpp:
3052         (WebCore::JSDictionary::getWithUndefinedOrNullCheck):
3053         * bindings/js/JSDictionary.h:
3054
3055 2014-08-22  Commit Queue  <commit-queue@webkit.org>
3056
3057         Unreviewed, rolling out r172866.
3058         https://bugs.webkit.org/show_bug.cgi?id=136177
3059
3060         Broke iOS build (Requested by othermaciej on #webkit).
3061
3062         Reverted changeset:
3063
3064         "Replace use of WKCopyCFLocalizationPreferredName with
3065         NSLocale public API"
3066         https://bugs.webkit.org/show_bug.cgi?id=136082
3067         http://trac.webkit.org/changeset/172866
3068
3069 2014-08-22  David Hyatt  <hyatt@apple.com>
3070
3071         Add proper support for letter-spacing to bopomofo Ruby
3072         https://bugs.webkit.org/show_bug.cgi?id=136171
3073
3074         Reviewed by Sam Weinig.
3075
3076         Added fast/ruby/bopomofo-letter-spacing.html
3077
3078         * rendering/RenderRubyRun.cpp:
3079         (WebCore::RenderRubyRun::layout):
3080         Alter the layout of bopomofo ruby so that the distance between the base characters is the max of
3081         the letter-spacing between the characters and the minimum required width to hold two rows of
3082         Ruby.
3083
3084         Push the bopomofo ruby into the letter-spacing to ensure that it comes right after the base character
3085         and not after all the letter-spacing.
3086
3087 2014-08-22  Simon Fraser  <simon.fraser@apple.com>
3088
3089         Fix showing paint rects when selecting lines in the timeline
3090         https://bugs.webkit.org/show_bug.cgi?id=136173
3091
3092         Reviewed by Joseph Pecoraro.
3093
3094         Fix the condition used to decide when to show the overlay.
3095
3096         * inspector/InspectorOverlay.cpp:
3097         (WebCore::InspectorOverlay::shouldShowOverlay):
3098
3099 2014-08-22  Simon Fraser  <simon.fraser@apple.com>
3100
3101         Use the correct rect for paint flashing
3102         https://bugs.webkit.org/show_bug.cgi?id=136169
3103
3104         Reviewed by Sam Weinig.
3105
3106         Use the rect we've converted to root document coordinates for paint flashing.
3107
3108         * inspector/InspectorPageAgent.cpp:
3109         (WebCore::InspectorPageAgent::didPaint):
3110
3111 2014-08-22  Dean Jackson  <dino@apple.com>
3112
3113         Google Canvas2D maps are too slow and uncontrollable with Safari with full screen mode
3114         https://bugs.webkit.org/show_bug.cgi?id=136168
3115
3116         Reviewed by Tim Horton.
3117
3118         When Google maps are using their 2D "lite" fallback and you're drawing in a huge
3119         window such as fullscreen 4K, we would drop back to unaccelerated mode, thinking
3120         that we'd exceeded the maximum IOSurface size.
3121
3122         Remove the hardcoded limit on IOSurface sizes, and instead ask the system
3123         what it believe the maximum to be. This was significantly higher than our
3124         limit on the systems I tested.
3125
3126         * platform/graphics/cg/ImageBufferCG.cpp:
3127         (WebCore::ImageBuffer::ImageBuffer): Include our IOSurface wrapper, which
3128         has a query for maximum size, and use that instead.
3129
3130 2014-08-22  Simon Fraser  <simon.fraser@apple.com>
3131
3132         Maybe fix Windows.
3133
3134         * inspector/InspectorOverlay.cpp:
3135         (WebCore::InspectorOverlay::showPaintRect):
3136
3137 2014-08-22  Simon Fraser  <simon.fraser@apple.com>
3138
3139         Implement paint flashing in the WK1 InspectorOverlay page
3140         https://bugs.webkit.org/show_bug.cgi?id=136138
3141
3142         Reviewed by Sam Weinig, Joseph Pecoraro.
3143
3144         Implement paint flashing for the WebKit1 InspectorOverlay via a second canvas in the overlay page.
3145         We avoid allocating backing store for this canvas until we have paint rects.
3146         
3147         Because this overlay page is weird and doesn't know how to paint itself, InspectorOverlay manages
3148         an array of rects, and pushes them to the page when they change, before forcing a paint.
3149         
3150         Because iOS doesn't use the InspectorOverlay page, stub out setShowPaintRects on its
3151         WebKit WebInspectorClient, but don't yet implement paint flashing there.
3152
3153         * inspector/InspectorOverlay.cpp:
3154         (WebCore::InspectorOverlay::InspectorOverlay):
3155         (WebCore::InspectorOverlay::shouldShowOverlay):
3156         (WebCore::InspectorOverlay::update):
3157         (WebCore::buildObjectForRect):
3158         (WebCore::InspectorOverlay::setShowingPaintRects):
3159         (WebCore::InspectorOverlay::showPaintRect):
3160         (WebCore::InspectorOverlay::updatePaintRectsTimerFired):
3161         (WebCore::InspectorOverlay::drawPaintRects):
3162         (WebCore::InspectorOverlay::forcePaint):
3163         (WebCore::quadToPath): Deleted.
3164         (WebCore::drawOutlinedQuad): Deleted.
3165         (WebCore::InspectorOverlay::drawOutline): Deleted.
3166         * inspector/InspectorOverlay.h:
3167         * inspector/InspectorOverlayPage.html:
3168         * inspector/InspectorOverlayPage.js:
3169         (updatePaintRects):
3170         (reset):
3171         (_drawShapeHighlight):
3172         * inspector/InspectorPageAgent.cpp:
3173         (WebCore::InspectorPageAgent::setShowPaintRects):
3174         (WebCore::InspectorPageAgent::didPaint):
3175
3176 2014-08-22  Eric Carlson  <eric.carlson@apple.com>
3177
3178         [iOS] Cleanup media code
3179         https://bugs.webkit.org/show_bug.cgi?id=136163
3180
3181         Reviewed by Jer Noble.
3182
3183         No new tests, no functionality was changed.
3184
3185         * html/HTMLMediaElement.cpp:
3186         (WebCore::HTMLMediaElement::HTMLMediaElement): Don't initialize m_requestingPlay.
3187         (WebCore::HTMLMediaElement::parseMediaPlayerAttribute): Deleted.
3188         (WebCore::HTMLMediaElement::parseAttribute): Don't call parseMediaPlayerAttribute.
3189         (WebCore::HTMLMediaElement::playInternal): m_requestingPlay is dead, Jim.
3190         (WebCore::HTMLMediaElement::updatePlayState): Ditto.
3191         (WebCore::HTMLMediaElement::updatePlayState): Remove obsolete FIXME.
3192         * html/HTMLMediaElement.h:
3193         * platform/graphics/MediaPlayer.cpp:
3194         (WebCore::MediaPlayer::attributeChanged): Deleted.
3195         (WebCore::MediaPlayer::readyForPlayback): Deleted.
3196         * platform/graphics/MediaPlayer.h:
3197         * platform/graphics/MediaPlayerPrivate.h:
3198         (WebCore::MediaPlayerPrivateInterface::attributeChanged): Deleted.
3199         (WebCore::MediaPlayerPrivateInterface::readyForPlayback): Deleted.
3200
3201 2014-08-20  Maciej Stachowiak  <mjs@apple.com>
3202
3203         Replace use of WKCopyCFLocalizationPreferredName with NSLocale public API
3204         https://bugs.webkit.org/show_bug.cgi?id=136082
3205
3206         Reviewed by Alexey Proskuryakov.
3207
3208         * platform/mac/Language.mm:
3209         (WebCore::httpStyleLanguageCode): Replace use of WKCopyCFLocalizationPreferredName
3210         with new WebCoreNSStringExtras helper.
3211         * platform/mac/WebCoreNSStringExtras.mm: Replacements for the aspects of
3212         WKCopyCFLocalizationPreferredName.
3213         (preferredBundleLocalizationName): New helper - most preferred localization available
3214         in the main bundle, canonicalized the way we like it.
3215         (canonicalLocalizationName): Convert a lcalization name to a string with language and
3216         country code, using default if necessary (e.g. "en" maps to "en_US").
3217         * WebCore.order: Remove mention of WKCopyCFLocalizationPreferredName.
3218         * WebCore.exp.in: ditto; also export preferredBundleLocalizationName for WebKit(2).
3219         * platform/ios/WebCoreSystemInterfaceIOS.mm: ditto
3220         * platform/mac/WebCoreSystemInterface.h: ditto
3221         * platform/mac/WebCoreSystemInterface.mm: ditto
3222
3223 2014-08-22  Daniel Bates  <dabates@apple.com>
3224
3225         [iOS] Disable ENABLE_IOS_{GESTURE, TOUCH}_EVENTS, and temporarily disable ENABLE_TOUCH_EVENTS
3226         and ENABLE_XSLT when building with the iOS public SDK
3227         https://bugs.webkit.org/show_bug.cgi?id=135945
3228
3229         Reviewed by Andy Estes.
3230
3231         Towards bringing up the iOS WebKit port using the iOS public SDK, disable the proprietary
3232         iOS gesture and touch event code. For now we also temporarily disable ENABLE_TOUCH_EVENTS
3233         and ENABLE_XSLT while we focus to get the rest of the port built using the public SDK. We'll
3234         look to enable these features once we stabilize the build.
3235
3236         * Configurations/FeatureDefines.xcconfig: Disable ENABLE_IOS_{GESTURE, TOUCH}_EVENTS, ENABLE_TOUCH_EVENTS
3237         and ENABLE_XSLT when building with the public SDK.
3238         * Configurations/WebCore.xcconfig:
3239         * DerivedSources.make: Conditionally generate derived sources for touch and gesture events as applicable and pass
3240         define WTF_USE_APPLE_INTERNAL_SDK when generating bindings (if applicable). Make the logic for determining
3241         whether WTF_PLATFORM_IOS is defined consistent with logic for determining whether WTF_USE_APPLE_INTERNAL_SDK and
3242         ENABLE_ORIENTATION_EVENTS are defined. We should look to further cleanup this code.
3243         * bindings/js/ios/TouchConstructors.cpp: Substitute ENABLE(IOS_TOUCH_EVENTS) for macro expression "PLATFORM(IOS) && ENABLE(TOUCH_EVENTS)".
3244         * bindings/objc/DOMEvents.h: Write preprocessor logic in terms of ENABLE_TOUCH_EVENTS and ENABLE_IOS_GESTURE_EVENTS.
3245         * bindings/objc/PublicDOMInterfaces.h: Include private header <WebKitAdditions/PublicDOMInterfacesIOS.h> when
3246         it exists as opposed to assuming it exists when building for iOS.
3247         * dom/Document.cpp:
3248         (WebCore::Document::Document): Substitute ENABLE(IOS_TOUCH_EVENTS) for macro expression "ENABLE(TOUCH_EVENTS) && PLATFORM(IOS)".
3249         (WebCore::Document::prepareForDestruction): Ditto.
3250         (WebCore::Document::removeAllEventListeners): Ditto.
3251         * dom/Document.h: Write preprocessor logic in terms of ENABLE_IOS_TOUCH_EVENTS and ENABLE_TOUCH_EVENTS.
3252         * dom/Document.idl: Ditto.
3253         * dom/Touch.h: Substitute ENABLE(IOS_TOUCH_EVENTS) for PLATFORM(IOS)..
3254         * dom/TouchEvent.h: Ditto.
3255         * dom/TouchList.h: Ditto.
3256         * dom/ios/TouchEvents.cpp: Substitute ENABLE(IOS_TOUCH_EVENTS) for macro expression "PLATFORM(IOS) && ENABLE(TOUCH_EVENTS)".
3257         * history/CachedFrame.cpp: Add PLATFORM(IOS) guard.
3258         * html/shadow/SliderThumbElement.cpp:
3259         (WebCore::SliderThumbElement::SliderThumbElement): Substitute ENABLE(IOS_TOUCH_EVENTS) for ENABLE(TOUCH_EVENTS).
3260         (WebCore::SliderThumbElement::willDetachRenderers): Ditto.
3261         * html/shadow/SliderThumbElement.h: Ditto.
3262         * loader/EmptyClients.h: Ditto.
3263         * platform/ios/PlatformEventFactoryIOS.h: Write preprocessor logic in terms of ENABLE_IOS_TOUCH_EVENTS and ENABLE_TOUCH_EVENTS.
3264         Only include header <WebKitAdditions/PlatformTouchEventIOS.h> when building with ENABLE_TOUCH_EVENTS enabled.
3265
3266 2014-08-22  Simon Fraser  <simon.fraser@apple.com>
3267
3268         Implement paint flashing via GraphicsLayers in the WK2 inspector overlay
3269         https://bugs.webkit.org/show_bug.cgi?id=136136
3270
3271         Reviewed by Sam Weinig, Joseph Pecoraro.
3272
3273         Allow InspectorClient to have a custom implementation of showPaintRect(). For
3274         WebKit2's WebInspectorClient, implement this by creating a set of GraphicsLayers
3275         which are parented in a document overlay, with 0.25s fade-out animations.
3276         
3277         Also change InspectorInstrumentation::didPaintImpl() to no longer take a GraphicsContext;
3278         it makes no sense to paint the paint rects directly into the context of the web page.
3279         Now that the paint rects are painted into an overlay, the rectangles need to be converted
3280         to root document coordinates, which is done in InspectorInstrumentation::didPaintImpl().
3281         
3282         Remove the generic InspectorOverlay::drawOutline()-based indicators; they will
3283         be reimplemented in a later patch.
3284
3285         * WebCore.exp.in:
3286         * inspector/InspectorClient.h:
3287         (WebCore::InspectorClient::showPaintRect):
3288         * inspector/InspectorInstrumentation.cpp:
3289         (WebCore::InspectorInstrumentation::didPaintImpl):
3290         * inspector/InspectorInstrumentation.h:
3291         (WebCore::InspectorInstrumentation::didPaint):
3292         * inspector/InspectorPageAgent.cpp:
3293         (WebCore::InspectorPageAgent::didPaint):
3294         * inspector/InspectorPageAgent.h:
3295         * page/FrameView.cpp:
3296         (WebCore::FrameView::didPaintContents):
3297         * rendering/RenderLayerBacking.cpp:
3298         (WebCore::RenderLayerBacking::paintContents):
3299
3300 2014-08-22  Commit Queue  <commit-queue@webkit.org>
3301
3302         Unreviewed, rolling out r172844.
3303         https://bugs.webkit.org/show_bug.cgi?id=136164
3304
3305         re-applying WEBCORE_EXPORTS patch (Requested by
3306         alexchristensen on #webkit).
3307
3308         Reverted changeset:
3309
3310         "Revert r172831, it broke the Windows build."
3311         http://trac.webkit.org/changeset/172844
3312
3313 2014-08-21  David Hyatt  <hyatt@apple.com>
3314
3315         Implement rudimentary Bopomofo Ruby support (ruby-position:inter-character)
3316         https://bugs.webkit.org/show_bug.cgi?id=136137
3317         <rdar://problem/12567545>
3318
3319         Reviewed by Sam Weinig.
3320
3321         Added fast/ruby/bopomofo.html and fast/ruby/bopomofo-rl.html.
3322
3323         * css/CSSParser.cpp:
3324         (WebCore::isValidKeywordPropertyAndValue):
3325         * css/CSSPrimitiveValueMappings.h:
3326         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3327         (WebCore::CSSPrimitiveValue::operator RubyPosition):
3328         * css/CSSPropertyNames.in:
3329         * css/CSSValueKeywords.in:
3330         Add support for the new inter-character value for ruby-position and also
3331         add support for a new font-size keyword, -webkit-ruby-text, that is used
3332         to set a smart initial font size based off the type of ruby being presented.
3333
3334         * css/DeprecatedStyleBuilder.cpp:
3335         (WebCore::ApplyPropertyFontSize::determineRubyTextSizeMultiplier):
3336         (WebCore::ApplyPropertyFontSize::applyValue):
3337         Determine the Ruby text size multiplier when -webkit-ruby-text is specified
3338         as the font size. For ruby-position of before/after, we use 50% of the parent
3339         font size. For inter-character ruby, we default to 25% instead. If inter-character
3340         Ruby is nested, we assume it's to display tone marks, and we use 100% to ensure
3341         the tone mark is the same size and does not get smaller.
3342
3343         * css/StyleResolver.cpp:
3344         (WebCore::StyleResolver::adjustStyleForInterCharacterRuby):
3345         (WebCore::StyleResolver::applyMatchedProperties):
3346         * css/StyleResolver.h:
3347         ruby-position is now the highest priority CSS property, and it is resolved
3348         before all other properties to ensure that its value can be checked when
3349         determining a smart default font size. adjustStyleForInterCharacterRuby is a new
3350         function called to auto-adjust inter-character ruby text to be vertical writing mode when
3351         encountered inside horizontal documents.
3352
3353         * css/html.css:
3354         (ruby > rt):
3355         Change the font-size from 50% to -webkit-ruby-text to allow us to customize it as
3356         needed depending on what kind of Ruby we want to show.
3357
3358         * rendering/RenderRubyRun.cpp:
3359         (WebCore::RenderRubyRun::layout):
3360         * rendering/RenderRubyRun.h:
3361         Add layout code to properly position vertical ruby text relative to a horizontal base.
3362
3363         * rendering/style/RenderStyleConstants.h:
3364         Add the new inter-character constant for ruby-position.
3365
3366         * rendering/style/StyleRareInheritedData.h:
3367         Increase the number of storage bits for RubyPosition from 1 to 2 now that we support 3 values.
3368
3369 2014-08-22  Jon Lee  <jonlee@apple.com>
3370
3371         Fix iOS build due to r172832 and move RUBBER_BANDING out of FeatureDefines.h
3372         https://bugs.webkit.org/show_bug.cgi?id=136157
3373
3374         Reviewed by Simon Fraser.
3375
3376         * Configurations/FeatureDefines.xcconfig: Add ENABLE(RUBBER_BANDING).
3377
3378 2014-08-22  Iago Toral  <itoral@igalia.com> and Zan Dobersek  <zdobersek@igalia.com>
3379
3380         [GTK] Add the Wayland protocol extension
3381         https://bugs.webkit.org/show_bug.cgi?id=136102
3382
3383         Reviewed by Martin Robinson.
3384
3385         Add the Wayland protocol extension that allows mapping GtkWidget
3386         objects (via an ID that's unique to that GtkWidget) to the
3387         corresponding Wayland surface objects. This way the nested
3388         compositor has the proper information about what GtkWidget has
3389         to be updated when surfaces are committed by the LayerTreeHost.
3390
3391         * PlatformGTK.cmake:
3392         * platform/graphics/wayland: Added.
3393         * platform/graphics/wayland/WebKitGtkWaylandClientProtocol.xml: Added.
3394
3395 2014-08-21  Antti Koivisto  <antti@apple.com>
3396
3397         Animated GIFs scrolled out of view still cause titlebar blur to update, on tumblr.com page
3398         https://bugs.webkit.org/show_bug.cgi?id=136139
3399
3400         Reviewed by Simon Fraser.
3401
3402         The mechanism for pausing GIF images outside the viewport did not work for subframes.
3403
3404         Test: fast/repaint/no-animation-outside-viewport-subframe.html
3405
3406         * WebCore.exp.in:
3407         * page/FrameView.cpp:
3408         (WebCore::FrameView::scrollPositionChanged):
3409         (WebCore::FrameView::resumeVisibleImageAnimationsIncludingSubframes):
3410
3411             Add a function for resuming animations as needed in all subframes.
3412             This is used after scrolling instead of calling the RenderView function directly.
3413
3414         * page/FrameView.h:
3415         * page/Page.cpp:
3416         (WebCore::Page::resumeAnimatingImages):
3417         * rendering/RenderElement.cpp:
3418         (WebCore::RenderElement::newImageAnimationFrameAvailable):
3419
3420             Determine the overall visible rect so that it is correct in subframes too.
3421
3422         * rendering/RenderLayer.cpp:
3423         (WebCore::RenderLayer::scrollTo):
3424         * rendering/RenderView.cpp:
3425         (WebCore::RenderView::resumePausedImageAnimationsIfNeeded):
3426
3427 2014-08-21  Alex Christensen  <achristensen@webkit.org>
3428
3429         More WEBCORE_EXPORT macros!
3430         https://bugs.webkit.org/show_bug.cgi?id=136146
3431
3432         Reviewed by Benjamin Poulain.
3433
3434         * Modules/geolocation/GeolocationClient.h:
3435         * Modules/mediastream/UserMediaClient.h:
3436         * Modules/mediastream/UserMediaRequest.h:
3437         * Modules/notifications/NotificationClient.h:
3438         * Modules/speech/SpeechSynthesis.h:
3439         * bindings/generic/RuntimeEnabledFeatures.h:
3440         * bindings/js/DOMWrapperWorld.h:
3441         * bindings/js/GCController.h:
3442         * bindings/js/IDBBindingUtilities.h:
3443         * bindings/js/JSDOMBinding.h:
3444         * bindings/js/JSNodeCustom.h:
3445         * bindings/js/JSNodeListCustom.h:
3446         * bindings/js/JSPluginElementFunctions.h:
3447         * bindings/js/ScriptController.h:
3448         * bindings/js/SerializedScriptValue.h:
3449         * crypto/SerializedCryptoKeyWrap.h:
3450         * css/LengthFunctions.h:
3451         * css/StyleProperties.h: