Recommit r191428.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2015-10-21  Alex Christensen  <achristensen@webkit.org>
2
3         Recommit r191428.
4
5         I don't think it was supposed to be reverted in r191429, and it really does fix the build.
6
7         * loader/EmptyClients.h:
8         (WebCore::EmptyContextMenuClient::~EmptyContextMenuClient):
9         Remove customizeMenu again.
10
11 2015-10-21  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
12
13         [EFL][GTK][WK2] Fix build break since r191402, r191401
14         https://bugs.webkit.org/show_bug.cgi?id=150432
15
16         Unreviewed EFL and GTK build fix.
17
18         * loader/EmptyClients.h:
19
20 2015-10-21  Alex Christensen  <achristensen@webkit.org>
21
22         Build fix after r191422.
23
24         * page/ContextMenuClient.h:
25         (WebCore::ContextMenuClient::~ContextMenuClient):
26         Completely remove customizeMenu.
27
28 2015-10-21  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
29
30         Remove unnecessary default quota setting in DatabaseContext::databaseExceededQuota
31         https://bugs.webkit.org/show_bug.cgi?id=150356
32
33         Reviewed by Darin Adler.
34
35         All ports have supported DatabaseContext::databaseExceededQuota(). Thus we don't need to
36         keep a test code to extend database quota anymore.
37
38         * Modules/webdatabase/DatabaseContext.cpp:
39         (WebCore::DatabaseContext::databaseExceededQuota): Deleted.
40
41 2015-10-21  Chris Dumez  <cdumez@apple.com>
42
43         Un-expose obsolete HTMLBaseFontElement
44         https://bugs.webkit.org/show_bug.cgi?id=150397
45
46         Reviewed by Anders Carlsson.
47
48         Un-expose obsolete HTMLBaseFontElement:
49         - https://html.spec.whatwg.org/multipage/obsolete.html#non-conforming-features
50
51         This means that we no longer expose HTMLBaseFontElement on the global
52         Window object. Firefox and Chrome do not expose it either.
53
54         Also, document.createElement("basefont") now returns an HTMLUnknownElement
55         as per the specification. Firefox and Chrome return a generic HTMLElement
56         instead but I don't think this is a big compatibility risk.
57
58         No new tests, already covered by existing tests.
59
60         * html/HTMLBaseFontElement.cpp:
61         (WebCore::HTMLBaseFontElement::HTMLBaseFontElement):
62         * html/HTMLBaseFontElement.h:
63         * html/HTMLBaseFontElement.idl:
64         * html/HTMLTagNames.in:
65
66 2015-10-21  Anders Carlsson  <andersca@apple.com>
67
68         Get rid of WebContextMenuClient::customizeMenu, it's no longer used
69         https://bugs.webkit.org/show_bug.cgi?id=150427
70
71         Reviewed by Tim Horton.
72         * loader/EmptyClients.cpp:
73         (WebCore::EmptyContextMenuClient::customizeMenu): Deleted.
74         * loader/EmptyClients.h:
75         * page/ContextMenuController.cpp:
76         (WebCore::ContextMenuController::showContextMenu):
77
78 2015-10-21  Anders Carlsson  <andersca@apple.com>
79
80         Remove dead MHTML code
81         https://bugs.webkit.org/show_bug.cgi?id=150426
82
83         Reviewed by Tim Horton.
84
85         * loader/archive/mhtml/MHTMLArchive.cpp:
86         (WebCore::MHTMLArchive::generateMHTMLData):
87         (WebCore::MHTMLArchive::generateMHTMLDataUsingBinaryEncoding): Deleted.
88         * loader/archive/mhtml/MHTMLArchive.h:
89
90 2015-10-21  Dean Jackson  <dino@apple.com>
91
92         Null dereference loading Blink layout test svg/filters/display-none-filter-primitive.html
93         https://bugs.webkit.org/show_bug.cgi?id=150212
94         <rdar://problem/23137376>
95
96         Reviewed by Brent Fulgham.
97
98         Handle the case where a filter element doesn't have a renderer. Inspired by the Blink
99         commit:
100         https://chromium.googlesource.com/chromium/src.git/+/fb79f7fc46552d45127acd2959a23662ad8f271e
101
102         Test: svg/filters/display-none-filter-primitive.html
103
104         * rendering/svg/RenderSVGResourceFilter.cpp:
105         (WebCore::RenderSVGResourceFilter::buildPrimitives):
106         * svg/graphics/filters/SVGFilterBuilder.cpp:
107         (WebCore::SVGFilterBuilder::appendEffectToEffectReferences):
108
109 2015-10-21  Brady Eidson  <beidson@apple.com>
110
111         Modern IDB: Add basic transaction aborting.
112         https://bugs.webkit.org/show_bug.cgi?id=150148
113
114         Reviewed by Alex Christensen.
115
116         Tests: storage/indexeddb/modern/double-abort.html
117                storage/indexeddb/modern/versionchange-abort-then-reopen.html
118
119         * CMakeLists.txt:
120         * WebCore.xcodeproj/project.pbxproj:
121         
122         * Modules/indexeddb/IndexedDB.h:
123         
124         * Modules/indexeddb/client/IDBConnectionToServer.cpp:
125         (WebCore::IDBClient::IDBConnectionToServer::abortTransaction):
126         (WebCore::IDBClient::IDBConnectionToServer::didAbortTransaction):
127         * Modules/indexeddb/client/IDBConnectionToServer.h:
128         * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
129         
130         * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
131         (WebCore::IDBClient::IDBDatabase::abortTransaction):
132         (WebCore::IDBClient::IDBDatabase::didCommitOrAbortTransaction):
133         * Modules/indexeddb/client/IDBDatabaseImpl.h:
134         
135         * Modules/indexeddb/client/IDBTransactionImpl.cpp:
136         (WebCore::IDBClient::IDBTransaction::IDBTransaction):
137         (WebCore::IDBClient::IDBTransaction::abort):
138         (WebCore::IDBClient::IDBTransaction::isFinishedOrFinishing):
139         (WebCore::IDBClient::IDBTransaction::activationTimerFired):
140         (WebCore::IDBClient::IDBTransaction::didAbort):
141         * Modules/indexeddb/client/IDBTransactionImpl.h:
142         
143         * Modules/indexeddb/server/IDBBackingStore.h:
144         
145         * Modules/indexeddb/server/IDBConnectionToClient.cpp:
146         (WebCore::IDBServer::IDBConnectionToClient::didAbortTransaction):
147         * Modules/indexeddb/server/IDBConnectionToClient.h:
148         * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
149         
150         * Modules/indexeddb/server/IDBServer.cpp:
151         (WebCore::IDBServer::IDBServer::abortTransaction):
152         * Modules/indexeddb/server/IDBServer.h:
153         
154         * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
155         (WebCore::IDBServer::MemoryBackingStoreTransaction::create):
156         (WebCore::IDBServer::MemoryBackingStoreTransaction::MemoryBackingStoreTransaction):
157         (WebCore::IDBServer::MemoryBackingStoreTransaction::~MemoryBackingStoreTransaction):
158         (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
159         (WebCore::IDBServer::MemoryBackingStoreTransaction::commit):
160         * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
161         (WebCore::IDBServer::MemoryBackingStoreTransaction::isVersionChange):
162         
163         * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
164         (WebCore::IDBServer::MemoryIDBBackingStore::setDatabaseInfo):
165         (WebCore::IDBServer::MemoryIDBBackingStore::beginTransaction):
166         (WebCore::IDBServer::MemoryIDBBackingStore::abortTransaction):
167         (WebCore::IDBServer::MemoryIDBBackingStore::commitTransaction):
168         * Modules/indexeddb/server/MemoryIDBBackingStore.h:
169
170         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
171         (WebCore::IDBServer::UniqueIDBDatabase::startVersionChangeTransaction):
172         (WebCore::IDBServer::UniqueIDBDatabase::beginTransactionInBackingStore):
173         (WebCore::IDBServer::UniqueIDBDatabase::commitTransaction):
174         (WebCore::IDBServer::UniqueIDBDatabase::performCommitTransaction):
175         (WebCore::IDBServer::UniqueIDBDatabase::didPerformCommitTransaction):
176         (WebCore::IDBServer::UniqueIDBDatabase::abortTransaction):
177         (WebCore::IDBServer::UniqueIDBDatabase::performAbortTransaction):
178         (WebCore::IDBServer::UniqueIDBDatabase::didPerformAbortTransaction):
179         * Modules/indexeddb/server/UniqueIDBDatabase.h:
180         
181         * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
182         (WebCore::IDBServer::UniqueIDBDatabaseConnection::didAbortTransaction):
183         * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
184         
185         * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
186         (WebCore::IDBServer::UniqueIDBDatabaseTransaction::UniqueIDBDatabaseTransaction):
187         (WebCore::IDBServer::UniqueIDBDatabaseTransaction::originalDatabaseInfo):
188         (WebCore::IDBServer::UniqueIDBDatabaseTransaction::abort):
189         * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
190         
191         * Modules/indexeddb/shared/IDBError.cpp:
192         (WebCore::idbErrorName):
193         (WebCore::idbErrorDescription):
194         * Modules/indexeddb/shared/IDBError.h:
195
196         * Modules/indexeddb/shared/InProcessIDBServer.cpp:
197         (WebCore::InProcessIDBServer::didAbortTransaction):
198         (WebCore::InProcessIDBServer::abortTransaction):
199         * Modules/indexeddb/shared/InProcessIDBServer.h:
200
201 2015-10-21  Chris Dumez  <cdumez@apple.com>
202
203         bgsound should use HTMLUnknownElement interface
204         https://bugs.webkit.org/show_bug.cgi?id=148857
205         <rdar://problem/22589036>
206
207         Reviewed by Sam Weinig.
208
209         The blink, bgsound, isindex, multicol, nextid, and spacer elements must
210         use the HTMLUnknownElement interface, as per the HTML specification:
211         https://html.spec.whatwg.org/multipage/obsolete.html#other-elements,-attributes-and-apis
212
213         WebKit was using HTMLUnknownElement for all of them except bgsound.
214         This patch fixes the issue and aligns our behavior with Chrome and
215         Firefox.
216
217         No new tests, already covered by existing tests.
218
219         * html/HTMLTagNames.in:
220
221 2015-10-21  Antoine Quint  <graouts@apple.com>
222
223         Support for the SVG `onend` attribute
224         https://bugs.webkit.org/show_bug.cgi?id=150393
225
226         Reviewed by Dean Jackson.
227
228         Add support for the SVG `onend` attribute to SVG timing and animation elements, which allow the definition
229         of a JS event listener declaratively for the SVG `endEvent` event.
230
231         Tests: svg/animations/end-event-attribute-expected.svg
232                svg/animations/end-event-attribute.svg
233                svg/animations/end-event-syncbase-expected.svg
234                svg/animations/end-event-syncbase.svg
235
236         * dom/EventNames.h:
237         * svg/animation/SVGSMILElement.cpp:
238         (WebCore::SVGSMILElement::parseAttribute):
239         * svg/svgattrs.in:
240
241 2015-10-21  Nan Wang  <n_wang@apple.com>
242
243         AX: Expose table size and cell indexes on iOS
244         https://bugs.webkit.org/show_bug.cgi?id=150366
245
246         Add support to expose table row/column count and cell indexes on iOS.
247
248         Reviewed by Chris Fleizach.
249
250         Test: accessibility/aria-table-attributes.html
251
252         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
253         (-[WebAccessibilityObjectWrapper tableParent]):
254         (-[WebAccessibilityObjectWrapper accessibilityElementForRow:andColumn:]):
255         (-[WebAccessibilityObjectWrapper accessibilityRowCount]):
256         (-[WebAccessibilityObjectWrapper accessibilityColumnCount]):
257         (-[WebAccessibilityObjectWrapper accessibilityARIARowCount]):
258         (-[WebAccessibilityObjectWrapper accessibilityARIAColumnCount]):
259         (-[WebAccessibilityObjectWrapper accessibilityARIARowIndex]):
260         (-[WebAccessibilityObjectWrapper accessibilityARIAColumnIndex]):
261         (-[WebAccessibilityObjectWrapper accessibilityRowRange]):
262
263 2015-10-21  Chris Dumez  <cdumez@apple.com>
264
265         HTMLIFrameElement.sandbox should be a DOMSettableTokenList
266         https://bugs.webkit.org/show_bug.cgi?id=150377
267
268         Reviewed by Ryosuke Niwa.
269
270         HTMLIFrameElement.sandbox should be a DOMSettableTokenList as per the
271         HTML specification:
272         - https://html.spec.whatwg.org/multipage/embedded-content.html#htmliframeelement
273
274         Chrome and Firefox match the specification but Safari/WebKit was uding
275         a DOMString.
276
277         Test: fast/frames/sandbox-attribute.html
278
279         * html/HTMLIFrameElement.cpp:
280         (WebCore::HTMLIFrameElement::sandbox):
281         (WebCore::HTMLIFrameElement::parseAttribute):
282         * html/HTMLIFrameElement.h:
283         * html/HTMLIFrameElement.idl:
284
285 2015-10-21  Carlos Garcia Campos  <cgarcia@igalia.com>
286
287         ASSERTION FAILED: markFontData in FontCascade::emphasisMarkHeight
288         https://bugs.webkit.org/show_bug.cgi?id=150171
289
290         Reviewed by Myles C. Maxfield.
291
292         It happens with several tests like fast/ruby/text-emphasis.html in
293         the GTK Debug bot. The tests seem to pass in Release and the rendering
294         looks correct as well removing the assert. The thing is that
295         for some reason we can get an empty GlyphData from
296         FontCascade::getEmphasisMarkGlyphData() when it ends up falling
297         back to system (FontCascadeFonts::glyphDataForSystemFallback).
298
299         * platform/graphics/FontCascade.cpp:
300         (WebCore::FontCascade::getEmphasisMarkGlyphData): Return
301         Optional<GlyphData> instead of returning a boolean and an out
302         parameter. If we get an invalid GlyphData, Nullopt is
303         returned. Also use a SurrogatePairAwareTextIterator to handle
304         surrogate pairs.
305         (WebCore::FontCascade::emphasisMarkAscent):
306         (WebCore::FontCascade::emphasisMarkDescent):
307         (WebCore::FontCascade::emphasisMarkHeight):
308         (WebCore::FontCascade::drawEmphasisMarks):
309         * platform/graphics/FontCascade.h:
310         * platform/graphics/GlyphPage.h:
311         (WebCore::GlyphData::isValid): Return whether the GlyphData is valid.
312
313 2015-10-20  Sergio Villar Senin  <svillar@igalia.com>
314
315         [css-grid] Fix availableLogicalSpace computation with non-zero baseSize flex tracks
316         https://bugs.webkit.org/show_bug.cgi?id=150359
317
318         Reviewed by Zalan Bujtas.
319
320         The availableLogicalSpace computation was incorrect whenever
321         the flex tracks had a non-zero baseSize before the 1fr unit
322         size resolution. That happened because when assigning the new
323         baseSize to the flex track, we were unconditionally
324         subtracting the whole baseSize to the
325         availableLogicalSpace. That's correct if the track is a "pure"
326         flex track, i.e. 2fr, but if the track had a non-zero baseSize
327         (like minmax(10px, 1fr)) then both the new and the old base
328         sizes were incorrectly used to compute the
329         availableLogicalSpace.
330
331         We can test the amount of remaining freeSpace by using content
332         distribution to align and item place on a non-zero baseSize
333         flex track. The content distribution will be accurate if and
334         only if the availableLogicalSpace computation is correct.
335
336         Test: fast/css-grid-layout/flex-content-distribution.html
337
338         * rendering/RenderGrid.cpp:
339         (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
340
341 2015-10-21  Xabier Rodriguez Calvar  <calvaris@igalia.com>
342
343         [Streams API] Construct a writable stream
344         https://bugs.webkit.org/show_bug.cgi?id=150360
345
346         Reviewed by Darin Adler.
347
348         This patch initializes a writable stream according to the spec. To do it we need two internal functions, which
349         are syncWritableStreamStateWithQueue and errorWritableStream, which are also implemented as a quite direct
350         translation from the spec.
351
352         Current test set suffices, expectations are updated accordingly.
353
354         * CMakeLists.txt:
355         * DerivedSources.make:
356         * WebCore.xcodeproj/project.pbxproj:
357         * bindings/js/JSDOMWindowBase.cpp:
358         * bindings/js/WebCoreBuiltinNames.h:
359         * bindings/js/WebCoreJSBuiltinInternals.h:
360         * bindings/js/WebCoreJSBuiltins.cpp:
361         * bindings/js/WebCoreJSBuiltins.h: Build infrastructure.
362         * Modules/streams/WritableStream.js:
363         (initializeWritableStream): Function that acts as constructor of WritableStream.
364         * Modules/streams/WritableStreamInternals.js:
365         (syncWritableStreamStateWithQueue):
366         (errorWritableStream): As per spec.
367
368 2015-10-21  Carlos Garcia Campos  <cgarcia@igalia.com>
369
370         NetworkProcess: DNS prefetch happens in the Web Process
371         https://bugs.webkit.org/show_bug.cgi?id=147824
372
373         Reviewed by Chris Dumez.
374
375         Use FrameLoaderClient to do the DNS prefetch.
376
377         * html/HTMLAnchorElement.cpp:
378         (WebCore::HTMLAnchorElement::parseAttribute):
379         * loader/EmptyClients.h:
380         * loader/FrameLoaderClient.h:
381         * loader/LinkLoader.cpp:
382         (WebCore::LinkLoader::loadLink):
383         * page/Chrome.cpp:
384         (WebCore::Chrome::mouseDidMoveOverElement):
385
386 2015-10-21  Frederic Wang  <fred.wang@free.fr>
387
388         [FreeType] Add support for the USE_TYPO_METRICS flag
389         https://bugs.webkit.org/show_bug.cgi?id=150340
390
391         Reviewed by Martin Robinson.
392
393         Test: fonts/use-typo-metrics-1.html
394
395         Make the FreeType backend use the typo metrics when the OS/2 USE_TYPO_METRICS flag is set.
396         Similar work should be done for other backends, see bug 131839.
397
398         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
399         (WebCore::Font::platformInit): Verify whether the OS/2 USE_TYPO_METRICS flag is set and use the typo metrics if that's the case.
400
401 2015-10-20  Hunseop Jeong  <hs85.jeong@samsung.com>
402
403         Replace 0 and NULL with nullptr in WebCore/loader.
404         https://bugs.webkit.org/show_bug.cgi?id=149657
405
406         Reviewed by Darin Adler.
407
408         No new tests because there is no behavior change.
409
410         * loader/CookieJar.cpp:
411         (WebCore::networkingContext):
412         * loader/DocumentLoader.cpp:
413         (WebCore::DocumentLoader::DocumentLoader):
414         (WebCore::DocumentLoader::frameLoader):
415         (WebCore::DocumentLoader::popArchiveForSubframe):
416         (WebCore::DocumentLoader::clearArchiveResources):
417         (WebCore::DocumentLoader::clearMainResource):
418         (WebCore::DocumentLoader::subresourceLoaderFinishedLoadingOnePart):
419         * loader/DocumentThreadableLoader.cpp:
420         (WebCore::DocumentThreadableLoader::cancel):
421         (WebCore::DocumentThreadableLoader::setDefersLoading):
422         (WebCore::DocumentThreadableLoader::clearResource):
423         * loader/EmptyClients.cpp:
424         (WebCore::EmptyFrameLoaderClient::createJavaAppletWidget):
425         (WebCore::EmptyFrameLoaderClient::createNetworkingContext):
426         * loader/EmptyClients.h:
427         * loader/FTPDirectoryParser.cpp:
428         (WebCore::parseOneFTPLine):
429         * loader/FTPDirectoryParser.h:
430         (WebCore::ListResult::clear):
431         * loader/FormSubmission.cpp:
432         (WebCore::FormSubmission::create):
433         * loader/FrameLoader.cpp:
434         (WebCore::FrameLoader::clear):
435         (WebCore::FrameLoader::stopAllLoaders):
436         (WebCore::FrameLoader::clearProvisionalLoad):
437         (WebCore::FrameLoader::transitionToCommitted):
438         (WebCore::FrameLoader::closeAndRemoveChild):
439         (WebCore::FrameLoader::detachFromParent):
440         (WebCore::FrameLoader::detachViewsAndDocumentLoader):
441         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
442         (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
443         * loader/FrameLoader.h:
444         (WebCore::FrameLoader::stateMachine):
445         * loader/FrameNetworkingContext.h:
446         (WebCore::FrameNetworkingContext::invalidate):
447         * loader/HistoryController.cpp:
448         (WebCore::HistoryController::replaceState):
449         * loader/ImageLoader.cpp:
450         (WebCore::ImageLoader::ImageLoader):
451         (WebCore::ImageLoader::updateFromElement):
452         * loader/NetscapePlugInStreamLoader.cpp:
453         (WebCore::NetscapePlugInStreamLoader::releaseResources):
454         * loader/ResourceLoadNotifier.h:
455         * loader/ResourceLoadScheduler.cpp:
456         (WebCore::resourceLoadScheduler):
457         * loader/SubresourceLoader.cpp:
458         (WebCore::SubresourceLoader::releaseResources):
459         * loader/TextResourceDecoder.cpp:
460         (WebCore::TextResourceDecoder::TextResourceDecoder):
461         * loader/ThreadableLoaderClientWrapper.h:
462         (WebCore::ThreadableLoaderClientWrapper::clearClient):
463         (WebCore::ThreadableLoaderClientWrapper::done):
464         * loader/appcache/ApplicationCache.cpp:
465         (WebCore::fallbackURLLongerThan):
466         (WebCore::ApplicationCache::ApplicationCache):
467         (WebCore::ApplicationCache::resourceForRequest):
468         * loader/appcache/ApplicationCache.h:
469         (WebCore::ApplicationCache::fallbackURLs):
470         * loader/appcache/ApplicationCacheGroup.cpp:
471         (WebCore::ApplicationCacheGroup::ApplicationCacheGroup):
472         (WebCore::ApplicationCacheGroup::fallbackCacheForMainRequest):
473         (WebCore::ApplicationCacheGroup::selectCache):
474         (WebCore::ApplicationCacheGroup::finishedLoadingMainResource):
475         (WebCore::ApplicationCacheGroup::failedLoadingMainResource):
476         (WebCore::ApplicationCacheGroup::manifestNotFound):
477         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
478         * loader/appcache/ApplicationCacheHost.cpp:
479         (WebCore::ApplicationCacheHost::ApplicationCacheHost):
480         (WebCore::ApplicationCacheHost::setApplicationCache):
481         * loader/appcache/ApplicationCacheHost.h:
482         (WebCore::ApplicationCacheHost::candidateApplicationCacheGroup):
483         * loader/appcache/ApplicationCacheStorage.cpp:
484         (WebCore::StorageIDJournal::Record::Record):
485         (WebCore::StorageIDJournal::Record::restore):
486         (WebCore::ApplicationCacheStorage::loadCacheGroup):
487         (WebCore::ApplicationCacheStorage::cacheGroupForURL):
488         (WebCore::ApplicationCacheStorage::fallbackCacheGroupForURL):
489         (WebCore::ApplicationCacheStorage::cacheGroupDestroyed):
490         (WebCore::ApplicationCacheStorage::loadCache):
491         * loader/appcache/DOMApplicationCache.cpp:
492         (WebCore::DOMApplicationCache::disconnectFrameForPageCache):
493         (WebCore::DOMApplicationCache::willDestroyGlobalObjectInFrame):
494         (WebCore::DOMApplicationCache::applicationCacheHost):
495         (WebCore::DOMApplicationCache::scriptExecutionContext):
496         (WebCore::DOMApplicationCache::toEventType):
497         * loader/archive/ArchiveFactory.cpp:
498         (WebCore::ArchiveFactory::create):
499         (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
500         * loader/archive/ArchiveResourceCollection.cpp:
501         (WebCore::ArchiveResourceCollection::archiveResourceForURL):
502         * loader/archive/cf/LegacyWebArchive.cpp:
503         (WebCore::LegacyWebArchive::createPropertyListRepresentation):
504         (WebCore::LegacyWebArchive::createResource):
505         (WebCore::LegacyWebArchive::create):
506         (WebCore::LegacyWebArchive::rawDataRepresentation):
507         * loader/archive/cf/LegacyWebArchiveMac.mm:
508         (WebCore::LegacyWebArchive::createPropertyListRepresentation):
509         * loader/archive/mhtml/MHTMLArchive.cpp:
510         (WebCore::MHTMLArchive::create):
511         (WebCore::MHTMLArchive::generateMHTMLData):
512         * loader/archive/mhtml/MHTMLParser.cpp:
513         (WebCore::MHTMLParser::parseArchiveWithHeader):
514         (WebCore::MHTMLParser::parseNextPart):
515         * loader/cache/CachedImage.cpp:
516         (WebCore::CachedImage::CachedImage):
517         * loader/cache/CachedImageClient.h:
518         (WebCore::CachedImageClient::imageChanged):
519         (WebCore::CachedImageClient::newImageAnimationFrameAvailable):
520         * loader/cache/CachedRawResource.cpp:
521         (WebCore::CachedRawResource::calculateIncrementalDataChunk):
522         * loader/cache/CachedRawResourceClient.h:
523         (WebCore::CachedRawResourceClient::dataReceived):
524         (WebCore::CachedRawResourceClient::redirectReceived):
525         (WebCore::CachedRawResourceClient::getOrCreateReadBuffer):
526         * loader/cache/CachedResource.cpp:
527         (WebCore::CachedResource::CachedResource):
528         (WebCore::CachedResource::clearResourceToRevalidate):
529         * loader/cache/CachedResourceClientWalker.h:
530         (WebCore::CachedResourceClientWalker::next):
531         * loader/cache/CachedResourceHandle.cpp:
532         (WebCore::CachedResourceHandleBase::CachedResourceHandleBase):
533         * loader/cache/CachedResourceLoader.cpp:
534         (WebCore::createResource):
535         (WebCore::CachedResourceLoader::CachedResourceLoader):
536         (WebCore::CachedResourceLoader::~CachedResourceLoader):
537         (WebCore::CachedResourceLoader::canRequest): Return value is bool.
538         (WebCore::CachedResourceLoader::requestResource):
539         * loader/cache/CachedResourceLoader.h:
540         (WebCore::CachedResourceLoader::document):
541         (WebCore::CachedResourceLoader::setDocument):
542         (WebCore::CachedResourceLoader::clearDocumentLoader):
543         * loader/cache/CachedSVGDocumentReference.cpp:
544         (WebCore::CachedSVGDocumentReference::CachedSVGDocumentReference):
545         * loader/cf/ResourceLoaderCFNet.cpp:
546         (WebCore::ResourceLoader::shouldCacheResponse): Return value is bool.
547         * loader/icon/IconDatabase.cpp:
548         (WebCore::IconDatabase::synchronousIconForPageURL):
549         (WebCore::IconDatabase::synchronousNativeIconForPageURL):
550         (WebCore::IconDatabase::setIconDataForIconURL):
551         (WebCore::IconDatabase::getOrCreatePageURLRecord):
552         (WebCore::IconDatabase::cleanupSyncThread):
553         * loader/icon/IconDatabaseBase.cpp:
554         (WebCore::IconDatabaseBase::open):
555         (WebCore::iconDatabase):
556         * loader/icon/IconDatabaseBase.h:
557         (WebCore::EnumCallback::performCallback):
558         (WebCore::EnumCallback::invalidate):
559         (WebCore::ObjectCallback::performCallback):
560         (WebCore::ObjectCallback::invalidate):
561         * loader/icon/PageURLRecord.cpp:
562         (WebCore::PageURLRecord::~PageURLRecord):
563         (WebCore::PageURLRecord::setIconRecord):
564         * loader/mac/ResourceLoaderMac.mm:
565         (WebCore::ResourceLoader::willCacheResponse):
566         * loader/soup/CachedRawResourceSoup.cpp:
567         (WebCore::CachedRawResource::getOrCreateReadBuffer):
568
569 2015-10-20  Chris Dumez  <cdumez@apple.com>
570
571         Unreviewed, GTK API test fix after r191351.
572
573         Reverted API change for GTK bindings.
574
575         * html/HTMLOptionsCollection.idl:
576         * html/HTMLSelectElement.idl:
577
578 2015-10-20  Chris Dumez  <cdumez@apple.com>
579
580         Unreviewed, Another GTK build fix after r191351.
581
582         * html/HTMLCollection.idl:
583
584 2015-10-20  Chris Dumez  <cdumez@apple.com>
585
586         Unreviewed, Another GTK build fix after r191351.
587
588         * html/HTMLFieldSetElement.cpp:
589         (WebCore::HTMLFieldSetElement::elementsForNativeBindings):
590         (WebCore::HTMLFieldSetElement::elementsForObjC): Deleted.
591         * html/HTMLFieldSetElement.h:
592         * html/HTMLFieldSetElement.idl:
593
594 2015-10-20  Chris Fleizach  <cfleizach@apple.com>
595
596         AX: CrashTracer: com.apple.WebKit.WebContent at com.apple.WebCore: WebCore::AccessibilityTable::tableElement const + 116
597         https://bugs.webkit.org/show_bug.cgi?id=150349
598
599         Reviewed by Brent Fulgham.
600
601         The crash point for this bug says that the parentElement of the firstBody is garbage when it's accessed. 
602         Unfortunately, I could not reproduce this in-situ or with a test. 
603         So my speculative solution is to recalculate those body elements to ensure that they're valid before we access.
604
605         * accessibility/AccessibilityTable.cpp:
606         (WebCore::AccessibilityTable::tableElement):
607         (WebCore::AccessibilityTable::isDataTable):
608
609 2015-10-20  Chris Dumez  <cdumez@apple.com>
610
611         Unreviewed, GTK build fix after r191351.
612
613         * html/HTMLFormElement.cpp:
614         (WebCore::HTMLFormElement::elementsForNativeBindings):
615         (WebCore::HTMLFormElement::elementsForObjC): Deleted.
616         * html/HTMLFormElement.h:
617         * html/HTMLFormElement.idl:
618
619 2015-10-20  Simon Fraser  <simon.fraser@apple.com>
620
621         Add basic TextStream output for Images
622         https://bugs.webkit.org/show_bug.cgi?id=150350
623
624         Reviewed by Darin Adler.
625
626         Add a TextStream output operator for Image, and virtual dump() member functions
627         that the various image types override to dump their own data.
628         
629         Add isFoo() functions for each image type (surprising that these didn't already
630         exist) so we can print the image type.
631         
632         Make isAnimated() const, and isBitmapImage() private.
633
634         * platform/graphics/BitmapImage.cpp:
635         (WebCore::BitmapImage::dump):
636         * platform/graphics/BitmapImage.h:
637         * platform/graphics/CrossfadeGeneratedImage.cpp:
638         (WebCore::CrossfadeGeneratedImage::dump):
639         * platform/graphics/CrossfadeGeneratedImage.h:
640         * platform/graphics/GeneratedImage.cpp:
641         * platform/graphics/GeneratedImage.h:
642         * platform/graphics/GradientImage.cpp:
643         (WebCore::GradientImage::dump):
644         * platform/graphics/GradientImage.h:
645         * platform/graphics/Image.cpp:
646         (WebCore::Image::dump):
647         (WebCore::operator<<):
648         * platform/graphics/Image.h:
649         (WebCore::Image::isGeneratedImage):
650         (WebCore::Image::isCrossfadeGeneratedImage):
651         (WebCore::Image::isNamedImageGeneratedImage):
652         (WebCore::Image::isGradientImage):
653         (WebCore::Image::isSVGImage):
654         (WebCore::Image::isAnimated):
655         * platform/graphics/NamedImageGeneratedImage.cpp:
656         (WebCore::NamedImageGeneratedImage::dump):
657         * platform/graphics/NamedImageGeneratedImage.h:
658         * platform/graphics/cg/PDFDocumentImage.cpp:
659         (WebCore::PDFDocumentImage::dump):
660         * platform/graphics/cg/PDFDocumentImage.h:
661         * svg/graphics/SVGImage.cpp:
662         (WebCore::SVGImage::dump):
663         * svg/graphics/SVGImage.h:
664
665 2015-10-20  Chris Dumez  <cdumez@apple.com>
666
667         Use tighter typing for collections / node lists' item() / namedItem() methods
668         https://bugs.webkit.org/show_bug.cgi?id=150347
669
670         Reviewed by Darin Adler.
671
672         Use tighter typing for collections / node lists' item() / namedItem() methods.
673
674         * accessibility/AccessibilityRenderObject.cpp:
675         (WebCore::AccessibilityRenderObject::getDocumentLinks):
676         * dom/LiveNodeList.h:
677         * dom/StaticNodeList.cpp:
678         (WebCore::StaticElementList::item):
679         * dom/StaticNodeList.h:
680         * html/CachedHTMLCollection.h:
681         * html/HTMLAllCollection.idl:
682         * html/HTMLCollection.idl:
683         * html/HTMLFieldSetElement.cpp:
684         (WebCore::HTMLFieldSetElement::elements):
685         (WebCore::HTMLFieldSetElement::elementsForObjC):
686         * html/HTMLFieldSetElement.h:
687         * html/HTMLFieldSetElement.idl:
688         * html/HTMLFormControlsCollection.cpp:
689         (WebCore::HTMLFormControlsCollection::customElementAfter):
690         * html/HTMLFormControlsCollection.h:
691         * html/HTMLFormControlsCollection.idl:
692         * html/HTMLFormElement.cpp:
693         (WebCore::HTMLFormElement::item):
694         (WebCore::HTMLFormElement::elements):
695         (WebCore::HTMLFormElement::elementsForObjC):
696         * html/HTMLFormElement.h:
697         * html/HTMLFormElement.idl:
698         * html/HTMLOptionsCollection.cpp:
699         (WebCore::HTMLOptionsCollection::add):
700         * html/HTMLOptionsCollection.h:
701         * html/HTMLOptionsCollection.idl:
702         * html/HTMLSelectElement.cpp:
703         (WebCore::HTMLSelectElement::namedItem):
704         (WebCore::HTMLSelectElement::item):
705         (WebCore::HTMLSelectElement::setOption):
706         * html/HTMLSelectElement.idl:
707         * html/HTMLTableRowElement.cpp:
708         (WebCore::HTMLTableRowElement::deleteCell):
709         * html/HTMLTableSectionElement.cpp:
710         (WebCore::HTMLTableSectionElement::deleteRow):
711         * html/RadioNodeList.cpp:
712         (WebCore::toRadioButtonInputElement):
713         (WebCore::RadioNodeList::value):
714         (WebCore::RadioNodeList::setValue):
715         * html/RadioNodeList.h:
716         * html/RadioNodeList.idl:
717
718 2015-10-20  Chris Dumez  <cdumez@apple.com>
719
720         Only HTML spaces should be stripped from a <script>'s 'for' / 'event' attributes
721         https://bugs.webkit.org/show_bug.cgi?id=150335
722
723         Reviewed by Darin Adler.
724
725         Only HTML spaces should be stripped from a <script>'s 'for' / 'event' attributes:
726         https://html.spec.whatwg.org/multipage/scripting.html#prepare-a-script (step 12.3)
727         https://html.spec.whatwg.org/multipage/infrastructure.html#space-character
728
729         Previously, we were uding the wrong stripping function and we were stripping
730         some non-HTML spaces.
731
732         Test: fast/dom/script-for-event-spaces.html
733
734         * dom/ScriptElement.cpp:
735         (WebCore::ScriptElement::isScriptForEventSupported):
736
737 2015-10-20  Csaba Osztrogonác  <ossy@webkit.org>
738
739         Fix the !ENABLE(CSS_GRID_LAYOUT) build after r191128
740         https://bugs.webkit.org/show_bug.cgi?id=150321
741
742         Reviewed by Darin Adler.
743
744         * css/CSSGrammar.y.in: Typo fix.
745
746 2015-10-20  Tim Horton  <timothy_horton@apple.com>
747
748         Try to fix the build by disabling MAC_GESTURE_EVENTS on 10.9 and 10.10
749
750         * Configurations/FeatureDefines.xcconfig:
751
752 2015-10-13  Sergio Villar Senin  <svillar@igalia.com>
753
754         ASSERTION FAILED: computeMainAxisExtentForChild(child, MainOrPreferredSize, mainSize) in WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax
755         https://bugs.webkit.org/show_bug.cgi?id=149459
756
757         Reviewed by Darin Adler.
758
759         This was regressed after 189567 where min-height|width:auto
760         support was added to flex items. The merge from Blink changes
761         was not correctly done for assertions. In particular we were
762         asserting if the resolved main size was not strictly greater
763         than 0, but 0 is actually a valid value.
764
765         Test: fast/flexbox/crash-resolved-main-size-zero.html
766
767         * rendering/RenderFlexibleBox.cpp:
768         (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax):
769
770 2015-10-20  Xabier Rodriguez Calvar  <calvaris@igalia.com>
771
772         [Streams API] Rework some readable stream internals that can be common to writable streams
773         https://bugs.webkit.org/show_bug.cgi?id=150133
774
775         Reviewed by Darin Adler.
776
777         There are some things in ReadableStream internals that be be used also for Writable Streams so it was necessary
778         to move some functions and refactor some code that can be shared by both implementations.
779
780         Queue was written with the functions declared at the implementation and keeping the improvement of having the
781         total size calculated instead of having to transverse the whole array.
782
783         The strategy is kept as an object and a common method is used to validate it as per spec.
784
785         Promises are reworked to keep in an internal slot inside the promise object the resolve and reject
786         functions. For convinience three functions were written, one to create the promise (and keep internally the
787         resolve and reject functions), one to resolve and another to reject. Promises can still be created with
788         Promise.resolve or reject as the resolve and rejectStreamsPromise functions operate under the assumption that
789         the internal slots might not exist.
790
791         invokeOrNoop and promiseInvokeOrNoop were moved to the common code as they will be also used by WritableStream.
792
793         Current test set suffices.
794
795         * CMakeLists.txt:
796         * DerivedSources.make:
797         * WebCore.xcodeproj/project.pbxproj:
798         * bindings/js/JSDOMWindowBase.cpp:
799         * bindings/js/WebCoreJSBuiltinInternals.h:
800         * bindings/js/WebCoreJSBuiltins.cpp:
801         * bindings/js/WebCoreJSBuiltins.h: Build infrastructure.
802         * Modules/streams/ReadableStream.js:
803         (initializeReadableStream): Reworked queue and strategy.
804         * Modules/streams/ReadableStreamInternals.js:
805         (privateInitializeReadableStreamReader):
806         (errorReadableStream):
807         (getReadableStreamDesiredSize):
808         (cancelReadableStream):
809         (closeReadableStream):
810         (closeReadableStreamReader):
811         (enqueueInReadableStream):
812         (readFromReadableStreamReader): Reworked queue, strategy and promises.
813         (invokeOrNoop): Deleted.
814         (promiseInvokeOrNoop): Deleted.
815         * Modules/streams/StreamInternals.js: Added.
816         (invokeOrNoop):
817         (promiseInvokeOrNoop): Moved from ReadableStreamInternals.js.
818         (validateAndNormalizeQueuingStrategy):
819         (createNewStreamsPromise):
820         (resolveStreamsPromise):
821         (rejectStreamsPromise):
822         (newQueue):
823         (dequeueValue):
824         (enqueueValueWithSize): Added according to the spec.
825         * bindings/js/WebCoreBuiltinNames.h: Updated private names according to the new slots.
826
827 2015-10-20  Yoav Weiss  <yoav@yoav.ws>
828
829         Rename the PICTURE_SIZES flag to CURRENTSRC
830         https://bugs.webkit.org/show_bug.cgi?id=150275
831
832         Reviewed by Dean Jackson.
833
834         No new tests, since there is no functional change.
835
836         * Configurations/FeatureDefines.xcconfig:
837         * html/HTMLImageElement.cpp:
838         * html/HTMLImageElement.h:
839         * html/HTMLImageElement.idl:
840
841 2015-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
842
843         ASSERTION FAILED: m_state == Initialized in SubresourceLoader::didReceiveResponse()
844         https://bugs.webkit.org/show_bug.cgi?id=150327
845
846         Reviewed by Antti Koivisto.
847
848         This is how it happens:
849
850         1. print() is called while the document is still loading, so
851            m_shouldPrintWhenFinishedLoading is set to true
852         2. DataURLDecoder::decode() finishes in the work queue thread,
853            the completion handler is scheduled in the main thread
854         3. The load is cancelled
855           3.1. SubresourceLoader::willCancel sets m_state = Finishing
856           3.2. DOMWindow::finishedLoading() is called, and since
857                m_shouldPrintWhenFinishedLoading is true, it does the print.
858           3.3. Cancellation finishes and ResourceLoader::releaseResources()
859                is called that sets m_reachedTerminalState = true
860
861         So, between 3.1 and 3.3, the state is Finishing, but
862         m_reachedTerminalState is false. What happens, in the GTK+ port at
863         least, is that the nested main loop used to make print()
864         synchronous, processes the DataURLDecoder::decode() completion
865         handler that was pending. The completion handler returns early if
866         m_reachedTerminalState is true, but it's not yet in this
867         particular case. So, it ends up calling didReceiveResponse,
868         because the decode didn't fail, when the subresource loader state
869         is Finishing.
870
871         I think there are two things here. One is that we shouldn't start
872         a print that was waiting for the load to finish when it
873         failed. That would fix the problem. But it's probably a good idea
874         to also check for cancellation in the DataURLDecoder::decode()
875         completion handler.
876
877         Fixes printing/print-close-crash.html in GTK+ Debug.
878
879         * loader/ResourceLoader.cpp:
880         (WebCore::ResourceLoader::loadDataURL): Return early from
881         DataURLDecoder::decode() completion handler if the load was cancelled.
882         * page/DOMWindow.cpp:
883         (WebCore::DOMWindow::finishedLoading): Do not start a print that
884         was witing for the load to finish when it failed.
885
886 2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
887
888         FontCascade::typesettingFeatures() is not privy to font-variant-* nor font-feature-settings
889         https://bugs.webkit.org/show_bug.cgi?id=149775
890
891         Reviewed by Darin Adler.
892
893         This patch has two pieces:
894
895         We used to have a boolean, enableLigatures, which affected how we perform shaping in both our
896         simple and complex text codepaths. However, in this brave new world of font-feature-settings
897         and font-variant-*, there are many properties which may affect shaping (and multiple kinds
898         of ligatures). This patch renames this boolean to requiresShaping, and teaches it about all
899         the various properties which affect text shaping.
900
901         Similarly, one of the places which used this enableLigatures boolean was to tell CoreText
902         if it should disable ligatures. However, we now have much finer-grained control over
903         ligatures during font creation. This patch moves the responsibility of dictating which
904         font features should be enabled entirely to the Font. Therefore, getCFStringAttributes()
905         doesn't know anything about ligatures anymore; the logic inside font creation is used
906         instead.
907
908         An added benefit of moving all the font feature logic to one place is that we can implement
909         the feature resolution algorithm described in the CSS3 fonts spec. This patch adds a test to
910         makes sure that text-rendering, font-feature-settings, and font-variant-* play together
911         nicely.
912
913         Test: fast/text/multiple-feature-properties.html
914
915         * platform/graphics/Font.cpp:
916         (WebCore::Font::applyTransforms):
917         * platform/graphics/Font.h:
918         * platform/graphics/FontCascade.cpp:
919         (WebCore::FontCascade::FontCascade):
920         (WebCore::FontCascade::operator=):
921         (WebCore::FontCascade::update):
922         (WebCore::FontCascade::drawText):
923         (WebCore::FontCascade::drawEmphasisMarks):
924         (WebCore::FontCascade::width):
925         (WebCore::FontCascade::adjustSelectionRectForText):
926         (WebCore::FontCascade::offsetForPosition):
927         (WebCore::FontCascade::codePath):
928         (WebCore::FontCascade::floatWidthForSimpleText):
929         * platform/graphics/FontCascade.h:
930         (WebCore::FontCascade::requiresShaping):
931         (WebCore::FontCascade::computeRequiresShaping):
932         (WebCore::FontCascade::enableLigatures): Deleted.
933         (WebCore::FontCascade::computeEnableLigatures): Deleted.
934         * platform/graphics/WidthIterator.cpp:
935         (WebCore::WidthIterator::WidthIterator):
936         (WebCore::WidthIterator::applyFontTransforms):
937         * platform/graphics/WidthIterator.h:
938         * platform/graphics/cocoa/FontCacheCoreText.cpp:
939         (WebCore::preparePlatformFont):
940         * platform/graphics/cocoa/FontCocoa.mm:
941         (WebCore::Font::canRenderCombiningCharacterSequence):
942         * platform/graphics/mac/ComplexTextControllerCoreText.mm:
943         (WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
944         * platform/graphics/mac/SimpleFontDataCoreText.cpp:
945         (WebCore::Font::getCFStringAttributes):
946         * svg/SVGFontData.h:
947
948 2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
949
950         Shadow GraphicsContext's ImageInterpolationQuality inside GraphicsContextState
951         https://bugs.webkit.org/show_bug.cgi?id=150306
952
953         Reviewed by Simon Fraser.
954
955         When getting the ImageInterpolationQuality, there is no need to round-trip through
956         the platform's graphics context. This patch migrates this piece of state to the
957         existing idiom of having a setter in GraphicsContext.cpp which sets the relevent
958         state in GraphicsContextState and then calls into a platform-specific setter.
959
960         No new tests because there is no behavior change.
961
962         * platform/graphics/GraphicsContext.cpp:
963         (WebCore::GraphicsContext::setImageInterpolationQuality):
964         * platform/graphics/GraphicsContext.h:
965         (WebCore::GraphicsContext::imageInterpolationQuality):
966         * platform/graphics/cairo/GraphicsContextCairo.cpp:
967         (WebCore::GraphicsContext::setPlatformImageInterpolationQuality):
968         (WebCore::GraphicsContext::setImageInterpolationQuality): Deleted.
969         (WebCore::GraphicsContext::imageInterpolationQuality): Deleted.
970         * platform/graphics/cg/GraphicsContextCG.cpp:
971         (WebCore::convertInterpolationQuality):
972         (WebCore::GraphicsContext::platformInit):
973         (WebCore::GraphicsContext::setPlatformImageInterpolationQuality):
974         (WebCore::GraphicsContext::setImageInterpolationQuality): Deleted.
975         (WebCore::GraphicsContext::imageInterpolationQuality): Deleted.
976
977 2015-10-19  Chris Dumez  <cdumez@apple.com>
978
979         Drop unnecessary Node::toInputElement() virtual function
980         https://bugs.webkit.org/show_bug.cgi?id=150341
981
982         Reviewed by Darin Adler.
983
984         Drop unnecessary Node::toInputElement() virtual function and use the
985         usual is<HTMLInputElement>() / downcast< HTMLInputElement >() instead.
986
987 2015-10-19  Commit Queue  <commit-queue@webkit.org>
988
989         Unreviewed, rolling out r191324.
990         https://bugs.webkit.org/show_bug.cgi?id=150352
991
992         Shadowing CTM's state is not necessary (Requested by litherum
993         on #webkit).
994
995         Reverted changeset:
996
997         "Host GraphicsContext's CTM inside GraphicsContextState"
998         https://bugs.webkit.org/show_bug.cgi?id=150146
999         http://trac.webkit.org/changeset/191324
1000
1001 2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
1002
1003         Host GraphicsContext's CTM inside GraphicsContextState
1004         https://bugs.webkit.org/show_bug.cgi?id=150146
1005
1006         There are 6 operations which interact with CTMs:
1007         - Get
1008         - Set
1009         - Concatenate
1010         - Scale
1011         - Rotate
1012         - Translate
1013
1014         This patch modifies all these operations so that these operations shadow the
1015         platform's CTM inside GraphicsContextState. This way, we don't have to consult
1016         with the underlying graphics context in order to know the current CTM.
1017
1018         There are currently many places in the Core Graphics ports where we will change
1019         the platform's CTM out from under the GraphicsContext. This patch migrates
1020         those users to going through GraphicsContext, thereby preserving the integrity
1021         of the shadowed state.
1022
1023         No new tests because there is no behavior change.
1024
1025         * platform/graphics/GraphicsContext.cpp: Setters deletate to platform calls.
1026         The getter can just consult with the shadowed state.
1027         (WebCore::GraphicsContext::concatCTM):
1028         (WebCore::GraphicsContext::scale):
1029         (WebCore::GraphicsContext::rotate):
1030         (WebCore::GraphicsContext::translate):
1031         (WebCore::GraphicsContext::setCTM):
1032         (WebCore::GraphicsContext::getCTM):
1033         (WebCore::GraphicsContext::beginTransparencyLayer):
1034         (WebCore::GraphicsContext::applyDeviceScaleFactor):
1035         * platform/graphics/GraphicsContext.h:
1036         (WebCore::GraphicsContext::scale):
1037         (WebCore::GraphicsContext::checkCTMInvariants): Make sure the shadowed state
1038         matches the platform graphics context's state.
1039         * platform/graphics/Image.h:
1040         (WebCore::Image::nativeImageForCurrentFrame):
1041         * platform/graphics/cairo/GraphicsContextCairo.cpp: Renaming functions.
1042         (WebCore::GraphicsContext::resetPlatformCTM):
1043         (WebCore::GraphicsContext::getPlatformCTM):
1044         (WebCore::GraphicsContext::translatePlatformCTM):
1045         (WebCore::GraphicsContext::concatPlatformCTM):
1046         (WebCore::GraphicsContext::setPlatformCTM):
1047         (WebCore::GraphicsContext::rotatePlatformCTM):
1048         (WebCore::GraphicsContext::scalePlatformCTM):
1049         (WebCore::GraphicsContext::getCTM): Deleted.
1050         (WebCore::GraphicsContext::translate): Deleted.
1051         (WebCore::GraphicsContext::concatCTM): Deleted.
1052         (WebCore::GraphicsContext::setCTM): Deleted.
1053         (WebCore::GraphicsContext::rotate): Deleted.
1054         (WebCore::GraphicsContext::scale): Deleted.
1055         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
1056         Renaming functions.
1057         (WebCore::GraphicsContextPlatformPrivate::save):
1058         (WebCore::GraphicsContextPlatformPrivate::restore):
1059         (WebCore::GraphicsContextPlatformPrivate::flush):
1060         (WebCore::GraphicsContextPlatformPrivate::clip):
1061         (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
1062         (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
1063         (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
1064         (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
1065         (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
1066         (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
1067         (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
1068         (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
1069         (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
1070         (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
1071         * platform/graphics/cg/GraphicsContextCG.cpp: Renaming functions. Also,
1072         migrate CTM setters to go through GraphicsContext.
1073         (WebCore::GraphicsContext::resetPlatformCTM):
1074         (WebCore::GraphicsContext::platformInit):
1075         (WebCore::GraphicsContext::drawNativeImage):
1076         (WebCore::GraphicsContext::drawPattern):
1077         (WebCore::GraphicsContext::fillPath):
1078         (WebCore::GraphicsContext::scalePlatformCTM):
1079         (WebCore::GraphicsContext::rotatePlatformCTM):
1080         (WebCore::GraphicsContext::translatePlatformCTM):
1081         (WebCore::GraphicsContext::concatPlatformCTM):
1082         (WebCore::GraphicsContext::setPlatformCTM):
1083         (WebCore::GraphicsContext::getPlatformCTM):
1084         (WebCore::GraphicsContext::scale): Deleted.
1085         (WebCore::GraphicsContext::rotate): Deleted.
1086         (WebCore::GraphicsContext::translate): Deleted.
1087         (WebCore::GraphicsContext::concatCTM): Deleted.
1088         (WebCore::GraphicsContext::setCTM): Deleted.
1089         (WebCore::GraphicsContext::getCTM): Deleted.
1090         * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
1091         (WebCore::GraphicsContextPlatformPrivate::save):
1092         (WebCore::GraphicsContextPlatformPrivate::restore):
1093         (WebCore::GraphicsContextPlatformPrivate::flush):
1094         (WebCore::GraphicsContextPlatformPrivate::clip):
1095         (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
1096         (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
1097         (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
1098         (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
1099         (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
1100         (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
1101         (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
1102         (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
1103         (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
1104         (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
1105         * platform/graphics/transforms/AffineTransform.h:
1106         (WebCore::AffineTransform::isEssentiallyEqualTo): Equality comparison on floats
1107         is not a good idea. Instead, this function is more valuable. (However, note that
1108         it is expected for values in a CTM to hold values close to 0, which means that
1109         this function might erroneously return false (similar to operator=()).
1110         * platform/graphics/win/GraphicsContextWin.cpp:
1111         (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
1112         (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
1113         (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
1114         (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
1115         (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
1116         (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
1117         (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
1118         (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
1119         (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
1120         (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
1121         * platform/mac/DragImageMac.mm:
1122         (WebCore::drawAtPoint):
1123         * platform/spi/cg/CoreGraphicsSPI.h:
1124
1125 2015-10-19  Tim Horton  <timothy_horton@apple.com>
1126
1127         Remove unused support for long presses from WebKit
1128         https://bugs.webkit.org/show_bug.cgi?id=150345
1129
1130         Reviewed by Beth Dakin.
1131
1132         * page/Chrome.cpp:
1133         (WebCore::Chrome::didBeginTrackingPotentialLongMousePress): Deleted.
1134         (WebCore::Chrome::didRecognizeLongMousePress): Deleted.
1135         (WebCore::Chrome::didCancelTrackingPotentialLongMousePress): Deleted.
1136         * page/Chrome.h:
1137         * page/ChromeClient.h:
1138         * page/EventHandler.cpp:
1139         (WebCore::EventHandler::EventHandler): Deleted.
1140         (WebCore::EventHandler::clear): Deleted.
1141         (WebCore::EventHandler::handleMousePressEvent): Deleted.
1142         (WebCore::EventHandler::eventMayStartDrag): Deleted.
1143         (WebCore::EventHandler::handleMouseReleaseEvent): Deleted.
1144         (WebCore::EventHandler::beginTrackingPotentialLongMousePress): Deleted.
1145         (WebCore::EventHandler::recognizeLongMousePress): Deleted.
1146         (WebCore::EventHandler::cancelTrackingPotentialLongMousePress): Deleted.
1147         (WebCore::EventHandler::clearLongMousePressState): Deleted.
1148         (WebCore::EventHandler::handleLongMousePressMouseMovedEvent): Deleted.
1149         (WebCore::EventHandler::handleMouseMoveEvent): Deleted.
1150         (WebCore::EventHandler::handleDrag): Deleted.
1151         * page/EventHandler.h:
1152         * page/Settings.in:
1153
1154 2015-10-19  Tim Horton  <timothy_horton@apple.com>
1155
1156         WKView being inside WKWebView leads to weird API issues
1157         https://bugs.webkit.org/show_bug.cgi?id=150174
1158
1159         Reviewed by Darin Adler.
1160
1161         No new tests, just moving code around.
1162
1163         * WebCore.xcodeproj/project.pbxproj:
1164         * platform/spi/mac/NSWindowSPI.h: Added.
1165
1166 2015-10-19  Simon Fraser  <simon.fraser@apple.com>
1167
1168         Restore an assertion to the way it was before r191310, which was correct.
1169
1170         * platform/graphics/GraphicsTypes.cpp:
1171         (WebCore::compositeOperatorName):
1172
1173 2015-10-19  Beth Dakin  <bdakin@apple.com>
1174
1175         Build fix.
1176
1177         * dom/EventNames.in:
1178         * dom/make_event_factory.pl:
1179         (generateImplementation):
1180
1181 2015-10-19  Csaba Osztrogonác  <ossy@webkit.org>
1182
1183         Fix the binding generator after r191176
1184         https://bugs.webkit.org/show_bug.cgi?id=150320
1185
1186         Reviewed by Darin Adler.
1187
1188         * bindings/scripts/CodeGeneratorJS.pm:
1189         (GenerateConstructorHelperMethods):
1190         * bindings/scripts/test/JS/JSTestInterface.cpp:
1191         (WebCore::JSTestInterfaceConstructor::getConstructData):
1192
1193 2015-10-19  Commit Queue  <commit-queue@webkit.org>
1194
1195         Unreviewed, rolling out r191307.
1196         https://bugs.webkit.org/show_bug.cgi?id=150338
1197
1198         broke lots of API tests, need time to figure out whats up
1199         (Requested by thorton on #webkit).
1200
1201         Reverted changeset:
1202
1203         "WKView being inside WKWebView leads to weird API issues"
1204         https://bugs.webkit.org/show_bug.cgi?id=150174
1205         http://trac.webkit.org/changeset/191307
1206
1207 2015-10-19  Commit Queue  <commit-queue@webkit.org>
1208
1209         Unreviewed, rolling out r191295, r191297, and r191301.
1210         https://bugs.webkit.org/show_bug.cgi?id=150337
1211
1212         ASSERTs in 5 tests (Requested by litherum on #webkit).
1213
1214         Reverted changesets:
1215
1216         "Host GraphicsContext's CTM inside GraphicsContextState"
1217         https://bugs.webkit.org/show_bug.cgi?id=150146
1218         http://trac.webkit.org/changeset/191295
1219
1220         "[iOS] Build fix after r191295"
1221         http://trac.webkit.org/changeset/191297
1222
1223         "Unreviewed build fix after r191295."
1224         http://trac.webkit.org/changeset/191301
1225
1226 2015-10-16  Brian Burg  <bburg@apple.com>
1227
1228         Unify handling of JavaScriptCore scripts that are used in WebCore
1229         https://bugs.webkit.org/show_bug.cgi?id=150245
1230
1231         Reviewed by Alex Christensen.
1232
1233         Use the new JavaScriptCore_SCRIPTS_DIR variable.
1234
1235         * CMakeLists.txt:
1236         * DerivedSources.make:
1237         * WebCore.xcodeproj/project.pbxproj:
1238
1239             No need to export other variables like InspectorScripts anymore.
1240
1241 2015-10-19  Simon Fraser  <simon.fraser@apple.com>
1242
1243         Add TextStream formatters for FillLayer and all it entails
1244         https://bugs.webkit.org/show_bug.cgi?id=150312
1245
1246         Reviewed by Tim Horton.
1247
1248         Add TextStream output formatters for FillLayer, and all the enum
1249         types used by it.
1250         
1251         Drive-by fixes for CompositeOperator and BlendMode string conversions.
1252         compositeOperatorNames was missing the "difference" string, and compositeOperatorName()
1253         would do an OOB memory access if blendOp was zero.
1254
1255         * CMakeLists.txt:
1256         * WebCore.xcodeproj/project.pbxproj:
1257         * platform/Length.cpp:
1258         (WebCore::operator<<):
1259         * platform/Length.h:
1260         * platform/LengthSize.cpp: Added.
1261         (WebCore::operator<<):
1262         * platform/LengthSize.h:
1263         * platform/text/TextStream.h:
1264         * rendering/style/FillLayer.cpp:
1265         (WebCore::operator<<):
1266         * rendering/style/FillLayer.h:
1267         * rendering/style/RenderStyleConstants.cpp: Added.
1268         (WebCore::operator<<):
1269         * rendering/style/RenderStyleConstants.h:
1270
1271 2015-10-19  Tim Horton  <timothy_horton@apple.com>
1272
1273         WKView being inside WKWebView leads to weird API issues
1274         https://bugs.webkit.org/show_bug.cgi?id=150174
1275
1276         Reviewed by Darin Adler.
1277
1278         No new tests, just moving code around.
1279
1280         * WebCore.xcodeproj/project.pbxproj:
1281         * platform/spi/mac/NSWindowSPI.h: Added.
1282
1283 2015-10-19  Tim Horton  <timothy_horton@apple.com>
1284
1285         Try to fix the iOS build
1286
1287         * Configurations/FeatureDefines.xcconfig:
1288
1289 2015-10-19  Alex Christensen  <achristensen@webkit.org>
1290
1291         Unreviewed build fix after r191295.
1292
1293         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1294         (WebCore::GraphicsContext::translatePlatformCTM):
1295         (WebCore::GraphicsContext::setPlatformFillColor):
1296         (WebCore::GraphicsContext::concatPlatformCTM):
1297         (WebCore::GraphicsContext::setPlatformCTM):
1298         (WebCore::GraphicsContext::setPlatformShadow):
1299         (WebCore::GraphicsContext::rotatePlatformCTM):
1300         (WebCore::GraphicsContext::scalePlatformCTM):
1301         (WebCore::GraphicsContext::clipOut):
1302         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
1303         (WebCore::GraphicsContextPlatformPrivate::save):
1304         (WebCore::GraphicsContextPlatformPrivate::restore):
1305         (WebCore::GraphicsContextPlatformPrivate::flush):
1306         (WebCore::GraphicsContextPlatformPrivate::clip):
1307         (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
1308         (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
1309         (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
1310         (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
1311         (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
1312         (WebCore::GraphicsContextPlatformPrivate::syncContext):
1313         (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
1314         (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
1315         (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
1316         (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
1317         (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
1318
1319 2015-10-19  Tim Horton  <timothy_horton@apple.com>
1320
1321         Add magnify and rotate gesture event support for Mac
1322         https://bugs.webkit.org/show_bug.cgi?id=150179
1323         <rdar://problem/8036240>
1324
1325         Reviewed by Darin Adler.
1326
1327         No new tests.
1328
1329         * Configurations/FeatureDefines.xcconfig:
1330         New feature flag.
1331
1332         * Configurations/WebCore.xcconfig:
1333         Don't exclude generated gesture sources; they are already #ifdef-guarded.
1334
1335         * DerivedSources.make:
1336         Add GestureEvent.idl for ENABLE_MAC_GESTURE_EVENTS too.
1337
1338         * WebCore.xcodeproj/project.pbxproj:
1339         Add GestureEvents.cpp.
1340
1341         * bindings/objc/DOMEvents.mm:
1342         (kitClass):
1343         Support DOMGestureEvent on Mac if the new flag is enabled.
1344
1345         * dom/mac/GestureEvents.cpp: Added.
1346         * page/mac/EventHandlerMac.mm:
1347
1348         * page/EventHandler.cpp:
1349         (WebCore::EventHandler::clear):
1350         * page/EventHandler.h:
1351         Enable some gesture-related code on Mac if the new flag is enabled.
1352
1353         * platform/PlatformEvent.h:
1354
1355 2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
1356
1357         [iOS] Build fix after r191295
1358
1359         Unreviewed.
1360
1361         * platform/graphics/cg/GraphicsContextCG.cpp:
1362         (WebCore::GraphicsContext::resetPlatformCTM):
1363
1364 2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
1365
1366         Host GraphicsContext's CTM inside GraphicsContextState
1367         https://bugs.webkit.org/show_bug.cgi?id=150146
1368
1369         Reviewed by Simon Fraser.
1370
1371         There are 6 operations which interact with CTMs:
1372         - Get
1373         - Set
1374         - Concatenate
1375         - Scale
1376         - Rotate
1377         - Translate
1378
1379         This patch modifies all these operations so that these operations shadow the
1380         platform's CTM inside GraphicsContextState. This way, we don't have to consult
1381         with the underlying graphics context in order to know the current CTM.
1382
1383         There are currently many places in the Core Graphics ports where we will change
1384         the platform's CTM out from under the GraphicsContext. This patch migrates
1385         those users to going through GraphicsContext, thereby preserving the integrity
1386         of the shadowed state.
1387
1388         No new tests because there is no behavior change.
1389
1390         * platform/graphics/GraphicsContext.cpp: Setters deletate to platform calls.
1391         The getter can just consult with the shadowed state.
1392         (WebCore::GraphicsContext::concatCTM):
1393         (WebCore::GraphicsContext::scale):
1394         (WebCore::GraphicsContext::rotate):
1395         (WebCore::GraphicsContext::translate):
1396         (WebCore::GraphicsContext::setCTM):
1397         (WebCore::GraphicsContext::getCTM):
1398         (WebCore::GraphicsContext::beginTransparencyLayer):
1399         (WebCore::GraphicsContext::applyDeviceScaleFactor):
1400         * platform/graphics/GraphicsContext.h:
1401         (WebCore::GraphicsContext::scale):
1402         (WebCore::GraphicsContext::checkCTMInvariants): Make sure the shadowed state
1403         matches the platform graphics context's state.
1404         * platform/graphics/cairo/GraphicsContextCairo.cpp: Renaming functions.
1405         (WebCore::GraphicsContext::resetPlatformCTM):
1406         (WebCore::GraphicsContext::getPlatformCTM):
1407         (WebCore::GraphicsContext::translatePlatformCTM):
1408         (WebCore::GraphicsContext::concatPlatformCTM):
1409         (WebCore::GraphicsContext::setPlatformCTM):
1410         (WebCore::GraphicsContext::rotatePlatformCTM):
1411         (WebCore::GraphicsContext::scalePlatformCTM):
1412         (WebCore::GraphicsContext::getCTM): Deleted.
1413         (WebCore::GraphicsContext::translate): Deleted.
1414         (WebCore::GraphicsContext::concatCTM): Deleted.
1415         (WebCore::GraphicsContext::setCTM): Deleted.
1416         (WebCore::GraphicsContext::rotate): Deleted.
1417         (WebCore::GraphicsContext::scale): Deleted.
1418         * platform/graphics/cg/GraphicsContextCG.cpp: Renaming functions. Also,
1419         migrate CTM setters to go through GraphicsContext.
1420         (WebCore::GraphicsContext::resetPlatformCTM):
1421         (WebCore::GraphicsContext::platformInit):
1422         (WebCore::GraphicsContext::drawNativeImage):
1423         (WebCore::drawPatternCallback):
1424         (WebCore::GraphicsContext::drawPattern):
1425         (WebCore::GraphicsContext::fillPath):
1426         (WebCore::GraphicsContext::strokePath):
1427         (WebCore::GraphicsContext::fillRect):
1428         (WebCore::GraphicsContext::strokeRect):
1429         (WebCore::GraphicsContext::scalePlatformCTM):
1430         (WebCore::GraphicsContext::rotatePlatformCTM):
1431         (WebCore::GraphicsContext::translatePlatformCTM):
1432         (WebCore::GraphicsContext::concatPlatformCTM):
1433         (WebCore::GraphicsContext::setPlatformCTM):
1434         (WebCore::GraphicsContext::getPlatformCTM):
1435         (WebCore::GraphicsContext::scale): Deleted.
1436         (WebCore::GraphicsContext::rotate): Deleted.
1437         (WebCore::GraphicsContext::translate): Deleted.
1438         (WebCore::GraphicsContext::concatCTM): Deleted.
1439         (WebCore::GraphicsContext::setCTM): Deleted.
1440         (WebCore::GraphicsContext::getCTM): Deleted.
1441         * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
1442         (WebCore::GraphicsContextPlatformPrivate::save):
1443         (WebCore::GraphicsContextPlatformPrivate::restore):
1444         (WebCore::GraphicsContextPlatformPrivate::flush):
1445         (WebCore::GraphicsContextPlatformPrivate::clip):
1446         (WebCore::GraphicsContextPlatformPrivate::scale):
1447         (WebCore::GraphicsContextPlatformPrivate::rotate):
1448         (WebCore::GraphicsContextPlatformPrivate::translate):
1449         (WebCore::GraphicsContextPlatformPrivate::concatCTM):
1450         (WebCore::GraphicsContextPlatformPrivate::setCTM):
1451         * platform/graphics/transforms/AffineTransform.h:
1452         (WebCore::AffineTransform::isEssentiallyEqualTo): Equality comparison on floats
1453         is not a good idea. Instead, this function is more valuable. (However, note that
1454         it is expected for values in a CTM to hold values close to 0, which means that
1455         this function might erroneously return false (similar to operator=()).
1456         * platform/graphics/win/GraphicsContextWin.cpp:
1457         (WebCore::GraphicsContextPlatformPrivate::scale):
1458         (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
1459         (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
1460         (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
1461         (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
1462         * platform/mac/DragImageMac.mm:
1463         (WebCore::drawAtPoint):
1464
1465 2015-10-19  Chris Dumez  <cdumez@apple.com>
1466
1467         Null dereference loading Blink layout test fast/forms/color/input-color-onchange-event.html
1468         https://bugs.webkit.org/show_bug.cgi?id=150192
1469         <rdar://problem/23135050>
1470
1471         Reviewed by Darin Adler.
1472
1473         Calling internals.selectColorInColorChooser() with a non-Element would
1474         cause a null dereference. This is because in such case, the implementation
1475         method is passed a null pointer and we would fail to null-check it. This
1476         patch now does the null-check.
1477
1478         No new tests, existing test was updated.
1479
1480         * testing/Internals.cpp:
1481         (WebCore::Internals::selectColorInColorChooser):
1482
1483 2015-10-19  Csaba Osztrogonác  <ossy@webkit.org>
1484
1485         Fix the !ENABLE(CSS_GRID_LAYOUT) build after r190840
1486         https://bugs.webkit.org/show_bug.cgi?id=150322
1487
1488         Reviewed by Ryosuke Niwa.
1489
1490         * html/HTMLDetailsElement.cpp:
1491
1492 2015-10-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1493
1494         Binding generator should generate names for JSBuiltins partial interface methods using ImplementedBy value
1495         https://bugs.webkit.org/show_bug.cgi?id=150163
1496
1497         Reviewed by Darin Adler.
1498
1499         Covered by updated binding tests.
1500
1501         Updating generation of JS built-in function/attribute name to use the ImplementedBy value of the interface if any.
1502         This allows splitting JS built-ins just like is done for IDLs.
1503         Updated accordingly the JS Builtin header include.
1504
1505         * bindings/scripts/CodeGeneratorJS.pm:
1506         (GetAttributeGetterName): Updated to pass function object and not only function name.
1507         (GetAttributeSetterName): Ditto.
1508         (GetFunctionName): Removed unneeded code plus updated to pass function object and not only function name.
1509         (GenerateConstructorHelperMethods): Making direct use of GetJSBuiltinFunctionNameFromString since there is no function object for the constructor.
1510         (GetJSBuiltinFunctionName): Updated to take into accound ImplementedBy value if any.
1511         (GetJSBuiltinFunctionNameFromString):
1512         (GetJSBuiltinScopeName): Returns either the interface name or its ImplementedBy value.
1513         (AddJSBuiltinIncludesIfNeeded): Updating name of the header in case of partial interface.
1514         * bindings/scripts/test/JS/JSTestInterface.cpp:
1515         * bindings/scripts/test/ObjC/DOMTestInterface.h:
1516         * bindings/scripts/test/ObjC/DOMTestInterface.mm:
1517         (-[DOMTestInterface builtinAttribute]):
1518         (-[DOMTestInterface setBuiltinAttribute:]):
1519         (-[DOMTestInterface builtinFunction]):
1520         * bindings/scripts/test/TestSupplemental.idl: Added JSBuiltin attribute and function.
1521
1522 2015-10-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1523
1524         Binding generator should allow generating private JS functions
1525         https://bugs.webkit.org/show_bug.cgi?id=150167
1526
1527         Reviewed by Darin Adler.
1528
1529         Introducing the "Private" keyword for that purpose.
1530         Applying it to MediaDevices.getUserMedia which can be used directly or through navigator.webkitGetUserMedia
1531         which could be implemented as JS builtin based on it.
1532
1533         "Private" functions are added to the prototype with a corresponding private symbol.
1534         This symbol must be defined in bindings/js/WebCoreBuiltinNames.h.
1535
1536         Adding a getUserMediaFromJS function visible from builtins script.
1537         Implementing MediaDevices.getUserMedia as a JS builtin based on it.
1538
1539         Adding binding generator test.
1540
1541         * CMakeLists.txt: Adding MediaDevices.js.
1542         * DerivedSources.make: Ditto.
1543         * Modules/mediastream/MediaDevices.h:
1544         (WebCore::MediaDevices::getUserMediaFromJS):
1545         * Modules/mediastream/MediaDevices.idl: Marking getUserMediaFromJS private and getUserMedia JSBuiltin.
1546         * Modules/mediastream/MediaDevices.js: Added.
1547         (getUserMedia):
1548         * bindings/js/WebCoreBuiltinNames.h:
1549         * bindings/js/WebCoreJSBuiltins.cpp:
1550         * bindings/js/WebCoreJSBuiltins.h:
1551         (WebCore::JSBuiltinFunctions::JSBuiltinFunctions):
1552         (WebCore::JSBuiltinFunctions::mediaDevicesBuiltins):
1553         * bindings/scripts/CodeGeneratorGObject.pm: Skipping generation of Private functions.
1554         (SkipFunction):
1555         * bindings/scripts/CodeGeneratorJS.pm:
1556         (GenerateImplementation): Disabling addition of private function in table and adding private member field to the prototype.
1557         * bindings/scripts/CodeGeneratorObjC.pm: Skipping generation of Private functions.
1558         (SkipFunction):
1559         * bindings/scripts/IDLAttributes.txt: Adding Private keyword.
1560         * bindings/scripts/test/JS/JSTestObj.cpp: Adding Private keyword test.
1561         (WebCore::JSTestObjPrototype::finishCreation):
1562         (WebCore::jsTestObjPrototypeFunctionPrivateMethod):
1563         * bindings/scripts/test/TestObj.idl:
1564
1565 2015-10-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1566
1567         [Streams API] Implement ReadableStream tee
1568         https://bugs.webkit.org/show_bug.cgi?id=146315
1569
1570         Reviewed by Darin Adler.
1571
1572         Covered by rebased test.
1573
1574         * Modules/streams/ReadableStream.js:
1575         (tee): Removing not implemented exception throwing.
1576         * Modules/streams/ReadableStreamInternals.js:
1577         (teeReadableStream): Implementing as per spec.
1578         (teeReadableStreamPullFunction): Ditto.
1579         (teeReadableStreamBranch2CancelFunction): Ditto.
1580
1581 2015-10-19  Xabier Rodriguez Calvar  <calvaris@igalia.com>
1582
1583         [Streams API] Add skeleton for initial WritableStream support
1584         https://bugs.webkit.org/show_bug.cgi?id=149951
1585
1586         Reviewed by Darin Adler.
1587
1588         This basically adds an empty WritableStream object without initializing the object. It also adds all empty
1589         methods by raising an exception.
1590
1591         The reason why the object is not fully initialized is that it requires some other support and some refactorings
1592         to share more code with ReadableStream and we will make in following patches.
1593
1594         Tests are covered by current set and their expectations are properly updated.
1595
1596         * CMakeLists.txt:
1597         * DerivedSources.cpp:
1598         * DerivedSources.make:
1599         * WebCore.vcxproj/WebCore.vcxproj:
1600         * WebCore.vcxproj/WebCore.vcxproj.filters:
1601         * WebCore.xcodeproj/project.pbxproj:
1602         * bindings/js/WebCoreJSBuiltins.cpp:
1603         * bindings/js/WebCoreJSBuiltins.h: Build infrastructure.
1604         * Modules/streams/WritableStream.idl: Added all methods and attributes.
1605         * Modules/streams/WritableStream.js:
1606         (initializeWritableStream):
1607         (abort):
1608         (close):
1609         (write):
1610         (closed):
1611         (ready):
1612         (state): Added all by throwing an EvalError.
1613
1614 2015-10-18  Chris Dumez  <cdumez@apple.com>
1615
1616         Script element with an empty for or event attributes should not execute
1617         https://bugs.webkit.org/show_bug.cgi?id=148855
1618         <rdar://problem/22588156>
1619
1620         Reviewed by Darin Adler.
1621
1622         A script element with an empty for or event attributes should not execute
1623         as per:
1624         https://html.spec.whatwg.org/multipage/scripting.html#prepare-a-script (step 12)
1625
1626         Our implementation had a bug where it would not correctly differentiate
1627         an empty attribute from a missing one. This patch fixes this.
1628
1629         No new tests, already covered by existing test.
1630
1631         * dom/ScriptElement.cpp:
1632         (WebCore::ScriptElement::isScriptForEventSupported):
1633
1634 2015-10-18  Chris Dumez  <cdumez@apple.com>
1635
1636         WebKit must support all JavaScript MIME types in HTML5 spec
1637         https://bugs.webkit.org/show_bug.cgi?id=148854
1638         <rdar://problem/22588195>
1639
1640         Reviewed by Darin Adler.
1641
1642         WebKit did not execute certain EcmaScript MIME types although the HTML
1643         specification says all user agents should support those:
1644         https://html.spec.whatwg.org/multipage/scripting.html#javascript-mime-type
1645
1646         In particular, the following MIME types are now recognized as valid and
1647         executed: "application/x-ecmascript", "text/javascript1.0",
1648         "text/javascript1.4", "text/javascript1.5", "text/x-javascript",
1649         "text/x-ecmascript".
1650
1651         The new behavior is consistent with Firefox.
1652
1653         No new tests, already covered by existing test.
1654
1655         * platform/MIMETypeRegistry.cpp:
1656         (WebCore::initializeSupportedJavaScriptMIMETypes):
1657
1658 2015-10-18  Sungmann Cho  <sungmann.cho@navercorp.com>
1659
1660         [Win] Fix the Windows builds.
1661         https://bugs.webkit.org/show_bug.cgi?id=150300
1662
1663         Reviewed by Darin Adler.
1664
1665         Add missing files to WebCore.vcxproj.
1666         Add missing #includes to CSSAllInOne.cpp and HTMLElementsAllInOne.cpp.
1667
1668         No new tests, no behavior change.
1669
1670         * WebCore.vcxproj/WebCore.vcxproj:
1671         * WebCore.vcxproj/WebCore.vcxproj.filters:
1672         * css/CSSAllInOne.cpp:
1673         * html/HTMLElementsAllInOne.cpp:
1674
1675 2015-10-18  Sungmann Cho  <sungmann.cho@navercorp.com>
1676
1677         Fix the builds with ENABLE_CONTENT_EXTENSIONS=OFF.
1678         https://bugs.webkit.org/show_bug.cgi?id=150302
1679
1680         Reviewed by Darin Adler.
1681
1682         Add missing #if ENABLE(CONTENT_EXTENSIONS).
1683
1684         No new tests, no behavior change.
1685
1686         * page/UserContentController.h:
1687
1688 2015-10-18  Joonghun Park  <jh718.park@samsung.com>
1689
1690         [EFL] Fix debug build break since r191198
1691         https://bugs.webkit.org/show_bug.cgi?id=150277
1692
1693         Reviewed by Darin Adler.
1694
1695         No new tests, no new behaviours.
1696
1697         Use the correct %"PRIu64" for uint64_t,
1698         instead of %llu.
1699
1700         * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
1701         (WebCore::IDBClient::IDBDatabase::fireVersionChangeEvent):
1702         * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
1703         (WebCore::IDBClient::IDBOpenDBRequest::onUpgradeNeeded):
1704         * Modules/indexeddb/legacy/IDBDatabaseBackend.cpp:
1705         (WebCore::IDBDatabaseBackend::processPendingOpenCalls):
1706         (WebCore::IDBDatabaseBackend::openConnectionInternal):
1707         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
1708         (WebCore::IDBServer::UniqueIDBDatabase::notifyConnectionsOfVersionChange):
1709
1710 2015-10-18  Sungmann Cho  <sungmann.cho@navercorp.com>
1711
1712         Fix the builds with ENABLE_INDEX_DATABASE=OFF.
1713         https://bugs.webkit.org/show_bug.cgi?id=150301
1714
1715         Reviewed by Darin Adler.
1716
1717         Add missing #if ENABLE(INDEXED_DATABASE).
1718
1719         No new tests, no behavior change.
1720
1721         * page/Page.cpp:
1722
1723 2015-10-18  Myles C. Maxfield  <mmaxfield@apple.com>
1724
1725         [Cocoa] [Win] Remove unused code from GraphicsContext
1726         https://bugs.webkit.org/show_bug.cgi?id=150304
1727
1728         Reviewed by Darin Adler.
1729
1730         No new tests because there is no behavior change.
1731
1732         * platform/graphics/GraphicsContext.h:
1733         * platform/graphics/cg/GraphicsContextCG.cpp:
1734         (WebCore::GraphicsContext::setAllowsFontSmoothing): Deleted.
1735
1736 2015-10-18  Antti Koivisto  <antti@apple.com>
1737
1738         Computed style should work correctly with slotted elements that have display:none
1739         https://bugs.webkit.org/show_bug.cgi?id=150237
1740
1741         Reviewed by Andreas Kling..
1742
1743         If an element has display:none we don't normally retain or even compute its style (as it is not rendered).
1744         If getComputedStyle is invoked for such element we resolve the style (along with any ancestors) and cache
1745         it separately to rare data. This path needs to work with slotted elements in shadow trees.
1746
1747         This patch also make computedStyle() iterative rather than recursive.
1748
1749         Test: fast/shadow-dom/computed-style-display-none.html
1750
1751         * dom/Document.cpp:
1752         (WebCore::Document::styleForElementIgnoringPendingStylesheets):
1753
1754             Pass in the parent style instead of invoking computedStyle() recursively.
1755
1756         * dom/Document.h:
1757         * dom/Element.cpp:
1758         (WebCore::beforeOrAfterPseudoElement):
1759         (WebCore::Element::existingComputedStyle):
1760         (WebCore::Element::resolveComputedStyle):
1761
1762             Iterative resolve function that uses composed tree iterator.
1763
1764         (WebCore::Element::computedStyle):
1765
1766             Factor into helpers.
1767
1768         * dom/Element.h:
1769         * dom/Node.cpp:
1770         (WebCore::Node::computedStyle):
1771
1772             Use the composed tree iterator.
1773
1774         * html/HTMLSelectElement.cpp:
1775         (WebCore::HTMLSelectElement::selectOption):
1776
1777             Call updateValidity() before calling renderer->updateFromElement(). Calling updateFromElement()
1778             may end up in Element::computedStyle() which can asserts if validity is not up to date.
1779
1780 2015-10-18  Myles C. Maxfield  <mmaxfield@apple.com>
1781
1782         Stop honoring the user default "WebKitKerningAndLigaturesEnabledByDefault"
1783         https://bugs.webkit.org/show_bug.cgi?id=150287
1784
1785         Reviewed by Simon Fraser.
1786
1787         This user default is currently on by default. Therefore, by setting the user default,
1788         users can only disable kerning / ligatures (rather than enable it).
1789
1790         There are a few reasons why we should stop honoring it:
1791
1792         1. In the brave new world of font-feature-settings and font-variant-ligatures, there
1793         are many different kinds of ligatures which may be enabled at will. The simplistic
1794         statement of "turn on ligatures" no longer has any meaning.
1795
1796         2. If a user wants to disable kerning / ligatures, he/she can do it with a user
1797         stylesheet.
1798
1799         3. The default isn't able to be tested with DumpRenderTree or WebKitTestRunner.
1800
1801         4. I have never heard of anyone actually using this user default.
1802
1803         * platform/graphics/FontCascade.cpp:
1804         (WebCore::FontCascade::setDefaultKerning): Deleted.
1805         (WebCore::FontCascade::setDefaultLigatures): Deleted.
1806         * platform/graphics/FontCascade.h:
1807         (WebCore::FontCascade::advancedTextRenderingMode):
1808
1809 2015-10-18  Commit Queue  <commit-queue@webkit.org>
1810
1811         Unreviewed, rolling out r191250 and r191253.
1812         https://bugs.webkit.org/show_bug.cgi?id=150296
1813
1814         Broke all the tests on Windows (Requested by ap on #webkit).
1815
1816         Reverted changesets:
1817
1818         "Stop honoring the user default
1819         "WebKitKerningAndLigaturesEnabledByDefault""
1820         https://bugs.webkit.org/show_bug.cgi?id=150287
1821         http://trac.webkit.org/changeset/191250
1822
1823         "Build fix after r191250"
1824         http://trac.webkit.org/changeset/191253
1825
1826 2015-10-17  David Hyatt  <hyatt@apple.com>
1827
1828         Implement the CSS4 'revert' keyword.
1829         https://bugs.webkit.org/show_bug.cgi?id=149702
1830
1831         Reviewed by Simon Fraser.
1832
1833         Added new tests in fast/css and fast/css/variables.
1834
1835         * CMakeLists.txt:
1836         * WebCore.xcodeproj/project.pbxproj:
1837         Add CSSRevertValue to the project and makefiles.
1838
1839         * css/CSSParser.cpp:
1840         (WebCore::parseKeywordValue):
1841         Make sure to handle "revert" in the keyword parsing path (along with inherit/initial/unset).
1842
1843         (WebCore::CSSParser::parseValue):
1844         (WebCore::CSSParser::parseCustomPropertyDeclaration):
1845         At the parser level, "revert" is just like inherit/initial/unset and gets its own special
1846         singleton value, CSSRevertValue.
1847
1848         * css/CSSRevertValue.cpp: Added.
1849         (WebCore::CSSRevertValue::customCSSText):
1850         * css/CSSRevertValue.h: Added.
1851         (WebCore::CSSRevertValue::create):
1852         (WebCore::CSSRevertValue::equals):
1853         (WebCore::CSSRevertValue::CSSRevertValue):
1854         This value is identical to the inherit/initial/unset values, i.e., its own special value
1855         that can be used to indicate a revert when doing style resolution.
1856
1857         * css/CSSValue.cpp:
1858         (WebCore::CSSValue::cssValueType):
1859         (WebCore::CSSValue::equals):
1860         (WebCore::CSSValue::cssText):
1861         (WebCore::CSSValue::destroy):
1862         * css/CSSValue.h:
1863         (WebCore::CSSValue::isInheritedValue):
1864         (WebCore::CSSValue::isInitialValue):
1865         (WebCore::CSSValue::isUnsetValue):
1866         (WebCore::CSSValue::isRevertValue):
1867         Add the RevertClass to CSSValue and make sure it is handled in all the appropriate methods.
1868
1869         * css/CSSValueKeywords.in:
1870         Add the "revert" keyword to the list of allowed CSS keywords.
1871
1872         * css/CSSValuePool.cpp:
1873         (WebCore::CSSValuePool::CSSValuePool):
1874         * css/CSSValuePool.h:
1875         (WebCore::CSSValuePool::createRevertValue):
1876         Add support for a CSSRevertValue singleton, just like inherit/unset/initial.
1877
1878         * css/FontLoader.cpp:
1879         (WebCore::FontLoader::resolveFontStyle):
1880         Add "unset" and "revert" as special keywords to be ignored. This code seems to be turned off,
1881         but patching it anyway.
1882
1883         * css/SelectorChecker.h:
1884         Add a MatchDefault value of 0 to the LinkMatchMask. This enables it to be used as an index
1885         to the correct value in Property (in the style resolution code).
1886
1887         * css/StyleResolver.cpp:
1888         (WebCore::StyleResolver::State::initForStyleResolve):
1889         Delete any lingering old CascadedProperty rollbacks for UA/user rules.
1890
1891         (WebCore::StyleResolver::styleForKeyframe):
1892         (WebCore::StyleResolver::styleForPage):
1893         (WebCore::StyleResolver::applyMatchedProperties):
1894         Pass along the MatchResult as an additional parameter, since we need it to lazily compute
1895         the cascade rollbacks if the "revert" keyword is encountered.
1896
1897         (WebCore::StyleResolver::cascadedPropertiesForRollback):
1898         This method will lazily create and return a new CascadedProperties pointer that is cached
1899         in the StyleResolver's state. This will contain only UA rules (for user reverts) and UA/user
1900         rules (for author reverts). These will only be computed at most once for a given element
1901         when doing a reversion, and they will be computed lazily, i.e., only if a revert is
1902         requested.
1903
1904         (WebCore::StyleResolver::applyProperty):
1905         Pass along the LinkMatchMask and the MatchResult to applyProperty. This way we know specifically
1906         which link type we were computing if we have to revert (so that we roll back and look at the
1907         same index in the reverted version). The MatchResult is passed along because it is needed
1908         to build the CascadedProperties rollbacks.
1909
1910         The basic idea is that if a revert is encountered, the level that the rule came from is
1911         checked. If it is UA level, just treat as "unset." If it is author or user level, get
1912         the correct CascadedProperties rollback and repeat the applyProperty using the property
1913         found in the rollback. If the property is not present in the cascade rollback, then the
1914         revert becomes an unset.
1915
1916         (WebCore::StyleResolver::CascadedProperties::hasCustomProperty):
1917         (WebCore::StyleResolver::CascadedProperties::customProperty):
1918         Helpers used by applyProperty to check on custom properties, since they can revert too
1919         just like a regular property can.
1920
1921         (WebCore::StyleResolver::CascadedProperties::setPropertyInternal):
1922         (WebCore::StyleResolver::CascadedProperties::set):
1923         (WebCore::StyleResolver::CascadedProperties::setDeferred):
1924         Passing along the CascadeLevel (UA, User, Author) so that it can be stored in the Property.
1925         This way when we do property application, we always know where the rule came from so
1926         that the reversion can be handled properly.
1927
1928         (WebCore::StyleResolver::CascadedProperties::addStyleProperties):
1929         (WebCore::cascadeLevelForIndex):
1930         (WebCore::StyleResolver::CascadedProperties::addMatches):
1931         When style properties are added, also figure out the CascadeLevel and pass it along to be
1932         stored in the Property. We use the MatchResult's ranges to know where a property comes from.
1933
1934         (WebCore::StyleResolver::CascadedProperties::applyDeferredProperties):
1935         (WebCore::StyleResolver::CascadedProperties::Property::apply):
1936         (WebCore::StyleResolver::applyCascadedProperties):
1937         Pass along the MatchResult so we know how to build the rollback.
1938
1939         * css/StyleResolver.h:
1940         (WebCore::StyleResolver::State::cascadeLevel):
1941         (WebCore::StyleResolver::State::setCascadeLevel):
1942         (WebCore::StyleResolver::State::authorRollback):
1943         (WebCore::StyleResolver::State::userRollback):
1944         (WebCore::StyleResolver::State::setAuthorRollback):
1945         (WebCore::StyleResolver::State::setUserRollback):
1946         (WebCore::StyleResolver::state):
1947         (WebCore::StyleResolver::cascadeLevel):
1948         (WebCore::StyleResolver::setCascadeLevel):
1949         Move CascadedProperties into the header. Add CascadeLevel to Property. Add the level and
1950         rollbacks to the resolver's state.
1951
1952 2015-10-17  Myles C. Maxfield  <mmaxfield@apple.com>
1953
1954         Delete FontPlatformData::allowsLigatures()
1955         https://bugs.webkit.org/show_bug.cgi?id=150286
1956
1957         Reviewed by Dan Bernstein.
1958
1959         This function is only used to force ligatures on for complex fonts (where "complex"
1960         means "does not support the letter 'a'"). However, ligatures are turned on for all
1961         fonts by default, which means that this function is unnecessary.
1962
1963         Required ligatures, such as those which make these complex scripts legible, are always
1964         enabled, no matter what.
1965
1966         Test: fast/text/required-ligatures.html
1967
1968         * platform/graphics/FontPlatformData.h:
1969         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
1970         (WebCore::FontPlatformData::allowsLigatures): Deleted.
1971         * platform/graphics/mac/SimpleFontDataCoreText.cpp:
1972         (WebCore::Font::getCFStringAttributes):
1973
1974 2015-10-17  Myles C. Maxfield  <mmaxfield@apple.com>
1975
1976         Stop honoring the user default "WebKitKerningAndLigaturesEnabledByDefault"
1977         https://bugs.webkit.org/show_bug.cgi?id=150287
1978
1979         Reviewed by Simon Fraser.
1980
1981         This user default is currently on by default. Therefore, by setting the user default,
1982         users can only disable kerning / ligatures (rather than enable it).
1983
1984         There are a few reasons why we should stop honoring it:
1985
1986         1. In the brave new world of font-feature-settings and font-variant-ligatures, there
1987         are many different kinds of ligatures which may be enabled at will. The simplistic
1988         statement of "turn on ligatures" no longer has any meaning.
1989
1990         2. If a user wants to disable kerning / ligatures, he/she can do it with a user
1991         stylesheet.
1992
1993         3. The default isn't able to be tested with DumpRenderTree or WebKitTestRunner.
1994
1995         4. I have never heard of anyone actually using this user default.
1996
1997         * platform/graphics/FontCascade.cpp:
1998         (WebCore::FontCascade::setDefaultKerning): Deleted.
1999         (WebCore::FontCascade::setDefaultLigatures): Deleted.
2000         * platform/graphics/FontCascade.h:
2001         (WebCore::FontCascade::advancedTextRenderingMode):
2002
2003 2015-10-17  Dan Bernstein  <mitz@apple.com>
2004
2005         [Cocoa] Stop using WKAXRegisterRemoteApp
2006         https://bugs.webkit.org/show_bug.cgi?id=150283
2007
2008         Reviewed by Alexey Proskuryakov.
2009
2010         * platform/spi/ios/GraphicsServicesSPI.h: Added declaration of GSSystemRootDirectory.
2011
2012 2015-10-17  Chris Dumez  <cdumez@apple.com>
2013
2014         td and th should use HTMLTableDataCellElement and HTMLTableHeaderCellElement interfaces
2015         https://bugs.webkit.org/show_bug.cgi?id=148859
2016         <rdar://problem/22588664>
2017
2018         Reviewed by Ryosuke Niwa.
2019
2020         td and th should use HTMLTableDataCellElement and HTMLTableHeaderCellElement interfaces
2021         as per the latest HTML specification:
2022         https://html.spec.whatwg.org/multipage/tables.html#htmltabledatacellelement
2023         https://html.spec.whatwg.org/multipage/tables.html#htmltableheadercellelement
2024
2025         This patch aligns our behavior with the specification and IE. Firefox and Chrome do not
2026         seem to expose HTMLTableDataCellElement / HTMLTableHeaderCellElement at this time.
2027
2028         The compatibility risk is low, given that the API stays the same and those new
2029         interfaces inherit the pre-existing HTMLTableCellElement interface.
2030
2031         No new tests, already covered by existing tests.
2032
2033         * CMakeLists.txt:
2034         * DerivedSources.cpp:
2035         * DerivedSources.make:
2036         * WebCore.vcxproj/WebCore.vcxproj:
2037         * WebCore.vcxproj/WebCore.vcxproj.filters:
2038         * WebCore.xcodeproj/project.pbxproj:
2039         * html/HTMLTableCellElement.cpp:
2040         (WebCore::HTMLTableCellElement::HTMLTableCellElement):
2041         (WebCore::HTMLTableCellElement::colSpan): Deleted.
2042         * html/HTMLTableCellElement.h:
2043         * html/HTMLTableCellElement.idl:
2044         * html/HTMLTableDataCellElement.h: Added.
2045         * html/HTMLTableDataCellElement.idl: Added.
2046         * html/HTMLTableHeaderCellElement.h: Added.
2047         * html/HTMLTableHeaderCellElement.idl: Added.
2048         * html/HTMLTableRowElement.cpp:
2049         (WebCore::HTMLTableRowElement::insertCell):
2050         * html/HTMLTagNames.in:
2051
2052 2015-10-17  Zalan Bujtas  <zalan@apple.com>
2053
2054         RenderBlockFlow::xPositionForFloatIncludingMargin/yPositionForFloatIncludingMargin/flipFloatForWritingModeForChild
2055         should all take FloatingObject reference.
2056         https://bugs.webkit.org/show_bug.cgi?id=150267
2057
2058         Reviewed by Simon Fraser.
2059
2060         No change in behaviour.
2061
2062         * rendering/RenderBlockFlow.cpp:
2063         (WebCore::RenderBlockFlow::addOverflowFromFloats):
2064         (WebCore::RenderBlockFlow::paintFloats):
2065         (WebCore::RenderBlockFlow::clipOutFloatingObjects):
2066         (WebCore::RenderBlockFlow::addOverhangingFloats):
2067         (WebCore::RenderBlockFlow::flipFloatForWritingModeForChild):
2068         (WebCore::RenderBlockFlow::hitTestFloats):
2069         (WebCore::RenderBlockFlow::adjustForBorderFit):
2070         * rendering/RenderBlockFlow.h:
2071         (WebCore::RenderBlockFlow::xPositionForFloatIncludingMargin):
2072         (WebCore::RenderBlockFlow::yPositionForFloatIncludingMargin):
2073
2074 2015-10-17  Simon Fraser  <simon.fraser@apple.com>
2075
2076         Sort the project file.
2077
2078         * WebCore.xcodeproj/project.pbxproj:
2079
2080 2015-10-16  Simon Fraser  <simon.fraser@apple.com>
2081
2082         Enhance TextStream for logging, remove subclasses, log more things
2083         https://bugs.webkit.org/show_bug.cgi?id=150269
2084
2085         Reviewed by Zalan Bujtas.
2086
2087         Remove the various TextStream subclasses that only existed to support indenting,
2088         and output additional types. Add output for more WebCore and WebKit2 types, and
2089         just use TextStream everywhere.
2090         
2091         TextStream is enhance to support grouping (open paren and intent), with a 
2092         stack-based class to open/end a group.
2093         
2094         Remove some SVG-specific duplicate output functions.
2095         
2096         Outdent namespace contents of GraphicsTypes.h.
2097         
2098         * CMakeLists.txt:
2099         * WebCore.xcodeproj/project.pbxproj:
2100         * dom/ViewportArguments.cpp:
2101         (WebCore::operator<<):
2102         * dom/ViewportArguments.h:
2103         * page/ViewportConfiguration.cpp:
2104         (WebCore::operator<<):
2105         (WebCore::ViewportConfiguration::description):
2106         (WebCore::ViewportConfigurationTextStream::ViewportConfigurationTextStream): Deleted.
2107         (WebCore::ViewportConfigurationTextStream::increaseIndent): Deleted.
2108         (WebCore::ViewportConfigurationTextStream::decreaseIndent): Deleted.
2109         (WebCore::dumpProperty): Deleted.
2110         (WebCore::ViewportConfigurationTextStream::writeIndent): Deleted.
2111         (WebCore::ViewportConfigurationTextStream::operator<<): Deleted.
2112         * page/ViewportConfiguration.h:
2113         * page/scrolling/ScrollingConstraints.cpp:
2114         (WebCore::operator<<):
2115         * page/scrolling/ScrollingConstraints.h:
2116         * page/scrolling/ScrollingCoordinator.cpp:
2117         (WebCore::operator<<):
2118         * page/scrolling/ScrollingCoordinator.h:
2119         * platform/animation/TimingFunction.cpp: Added.
2120         (WebCore::operator<<):
2121         * platform/animation/TimingFunction.h:
2122         * platform/graphics/Color.cpp:
2123         (WebCore::operator<<):
2124         * platform/graphics/Color.h:
2125         * platform/graphics/FloatPoint3D.cpp:
2126         (WebCore::operator<<):
2127         * platform/graphics/FloatPoint3D.h:
2128         * platform/graphics/FloatRoundedRect.cpp:
2129         (WebCore::operator<<):
2130         * platform/graphics/FloatRoundedRect.h:
2131         * platform/graphics/GraphicsLayer.cpp:
2132         (WebCore::operator<<):
2133         * platform/graphics/GraphicsLayer.h:
2134         * platform/graphics/GraphicsTypes.cpp:
2135         (WebCore::operator<<):
2136         * platform/graphics/GraphicsTypes.h:
2137         * platform/graphics/ca/PlatformCAAnimation.cpp: Added.
2138         (WebCore::operator<<):
2139         * platform/graphics/ca/PlatformCAAnimation.h:
2140         * platform/graphics/ca/PlatformCALayer.cpp:
2141         (WebCore::operator<<):
2142         * platform/graphics/ca/PlatformCALayer.h:
2143         * platform/graphics/filters/FilterOperation.cpp:
2144         (WebCore::operator<<):
2145         * platform/graphics/filters/FilterOperation.h:
2146         * platform/graphics/filters/FilterOperations.cpp:
2147         (WebCore::operator<<):
2148         * platform/graphics/filters/FilterOperations.h:
2149         * platform/graphics/filters/PointLightSource.cpp:
2150         (WebCore::operator<<): Deleted.
2151         * platform/graphics/filters/SpotLightSource.cpp:
2152         (WebCore::operator<<): Deleted.
2153         * platform/graphics/transforms/AffineTransform.cpp:
2154         (WebCore::operator<<):
2155         * platform/graphics/transforms/AffineTransform.h:
2156         * platform/graphics/transforms/TransformationMatrix.cpp:
2157         (WebCore::operator<<):
2158         * platform/graphics/transforms/TransformationMatrix.h:
2159         * platform/text/TextStream.cpp:
2160         (WebCore::TextStream::startGroup):
2161         (WebCore::TextStream::endGroup):
2162         (WebCore::TextStream::nextLine):
2163         (WebCore::TextStream::writeIndent):
2164         * platform/text/TextStream.h:
2165         (WebCore::TextStream::operator<<):
2166         (WebCore::TextStream::dumpProperty):
2167         (WebCore::TextStream::increaseIndent):
2168         (WebCore::TextStream::decreaseIndent):
2169         (WebCore::TextStream::GroupScope::GroupScope):
2170         (WebCore::TextStream::GroupScope::~GroupScope):
2171         * rendering/svg/SVGRenderTreeAsText.cpp:
2172         (WebCore::operator<<): Deleted.
2173         * rendering/svg/SVGRenderTreeAsText.h:
2174
2175 2015-10-17  Youenn Fablet  <youenn.fablet@crf.canon.fr>
2176
2177         Finalize bug 149952 patch
2178         https://bugs.webkit.org/show_bug.cgi?id=150238
2179
2180         Reviewed by Darin Adler.
2181
2182         No change in behavior.
2183
2184         * bindings/js/JSDOMConstructor.h:
2185         (WebCore::JSDOMConstructor<JSClass>::finishCreation): Marked as inline.
2186         (WebCore::JSDOMConstructor<JSClass>::getConstructData): Marked as inline.
2187
2188 2015-10-16  Zalan Bujtas  <zalan@apple.com>
2189
2190         RenderBlockFlow::*logical*ForFloat should take FloatingObject reference.
2191         https://bugs.webkit.org/show_bug.cgi?id=150266
2192
2193         Reviewed by Simon Fraser.
2194
2195         No change in behaviour.
2196
2197         * rendering/FloatingObjects.cpp:
2198         (WebCore::FindNextFloatLogicalBottomAdapter::collectIfNeeded):
2199         (WebCore::ComputeFloatOffsetForFloatLayoutAdapter<FloatingObject::FloatLeft>::updateOffsetIfNeeded):
2200         (WebCore::ComputeFloatOffsetForFloatLayoutAdapter<FloatingObject::FloatRight>::updateOffsetIfNeeded):
2201         (WebCore::ComputeFloatOffsetForFloatLayoutAdapter<FloatTypeValue>::heightRemaining):
2202         (WebCore::ComputeFloatOffsetAdapter<FloatTypeValue>::collectIfNeeded):
2203         (WebCore::ComputeFloatOffsetForLineLayoutAdapter<FloatingObject::FloatLeft>::updateOffsetIfNeeded):
2204         (WebCore::ComputeFloatOffsetForLineLayoutAdapter<FloatingObject::FloatRight>::updateOffsetIfNeeded):
2205         * rendering/RenderBlockFlow.cpp:
2206         (WebCore::RenderBlockFlow::rebuildFloatingObjectSetFromIntrudingFloats):
2207         (WebCore::RenderBlockFlow::repaintOverhangingFloats):
2208         (WebCore::RenderBlockFlow::insertFloatingObject):
2209         (WebCore::RenderBlockFlow::removeFloatingObject):
2210         (WebCore::RenderBlockFlow::removeFloatingObjectsBelow):
2211         (WebCore::RenderBlockFlow::computeLogicalLocationForFloat):
2212         (WebCore::RenderBlockFlow::positionNewFloats):
2213         (WebCore::RenderBlockFlow::lowestFloatLogicalBottom):
2214         (WebCore::RenderBlockFlow::lowestInitialLetterLogicalBottom):
2215         (WebCore::RenderBlockFlow::addOverhangingFloats):
2216         (WebCore::RenderBlockFlow::hasOverhangingFloat):
2217         (WebCore::RenderBlockFlow::addIntrudingFloats):
2218         * rendering/RenderBlockFlow.h:
2219         (WebCore::RenderBlockFlow::logicalTopForFloat):
2220         (WebCore::RenderBlockFlow::logicalBottomForFloat):
2221         (WebCore::RenderBlockFlow::logicalLeftForFloat):
2222         (WebCore::RenderBlockFlow::logicalRightForFloat):
2223         (WebCore::RenderBlockFlow::logicalWidthForFloat):
2224         (WebCore::RenderBlockFlow::logicalHeightForFloat):
2225         (WebCore::RenderBlockFlow::setLogicalTopForFloat):
2226         (WebCore::RenderBlockFlow::setLogicalLeftForFloat):
2227         (WebCore::RenderBlockFlow::setLogicalHeightForFloat):
2228         (WebCore::RenderBlockFlow::setLogicalWidthForFloat):
2229         (WebCore::RenderBlockFlow::logicalSizeForFloat): Deleted.
2230         * rendering/RenderBlockLineLayout.cpp:
2231         (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
2232         (WebCore::RenderBlockFlow::checkPaginationAndFloatsAtEndLine):
2233         (WebCore::RenderBlockFlow::positionNewFloatOnLine):
2234         * rendering/RenderBox.cpp:
2235         (WebCore::RenderBox::addOverflowFromChild):
2236         * rendering/RenderBox.h:
2237         (WebCore::RenderBox::addOverflowFromChild):
2238         * rendering/line/BreakingContext.h:
2239         (WebCore::BreakingContext::handleFloat):
2240         * rendering/line/LineWidth.cpp:
2241         (WebCore::newFloatShrinksLine):
2242         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
2243         * rendering/shapes/ShapeOutsideInfo.cpp:
2244         (WebCore::ShapeOutsideInfo::computeDeltasForContainingBlockLine):
2245
2246 2015-10-16  Jiewen Tan  <jiewen_tan@apple.com>
2247
2248         Avoid to insert TAB before HTML element.
2249         https://bugs.webkit.org/show_bug.cgi?id=149295
2250         <rdar://problem/22746706>
2251
2252         Reviewed by Ryosuke Niwa.
2253
2254         This is a merge of Blink r175047:
2255         https://codereview.chromium.org/306583005
2256
2257         This patch avoids InsertTextCommand::insertTab before HTML element because
2258         we can't set Text node as document element.
2259
2260         Test: editing/execCommand/insert-tab-to-html-element-crash.html
2261
2262         * editing/InsertTextCommand.cpp:
2263         (WebCore::InsertTextCommand::insertTab):
2264
2265 2015-10-16  Commit Queue  <commit-queue@webkit.org>
2266
2267         Unreviewed, rolling out r191204.
2268         https://bugs.webkit.org/show_bug.cgi?id=150263
2269
2270         This change is causing existing tests to fail (Requested by
2271         ryanhaddad on #webkit).
2272
2273         Reverted changeset:
2274
2275         "Computed style should work correctly with slotted elements
2276         that have display:none"
2277         https://bugs.webkit.org/show_bug.cgi?id=150237
2278         http://trac.webkit.org/changeset/191204
2279
2280 2015-10-16  Alex Christensen  <achristensen@webkit.org>
2281
2282         Disabled content blockers should not block any loads
2283         https://bugs.webkit.org/show_bug.cgi?id=150261
2284
2285         Reviewed by Brady Eidson.
2286
2287         This fix was tested manually by reloading without content blockers
2288         on websites with iframes and content blockers that block the contents of the iframes.
2289
2290         * page/UserContentController.cpp:
2291         (WebCore::UserContentController::removeAllUserContentExtensions):
2292         (WebCore::contentExtensionsEnabled):
2293         (WebCore::UserContentController::processContentExtensionRulesForLoad):
2294         (WebCore::UserContentController::actionsForResourceLoad):
2295         Check the DocumentLoader of the main frame when checking if content extensions are disabled,
2296         because that is the DocumentLoader that has the flag from reloading without content blockers.
2297
2298 2015-10-16  Simon Fraser  <simon.fraser@apple.com>
2299
2300         Make TextStream the canonical way to log classes in WebCore
2301         https://bugs.webkit.org/show_bug.cgi?id=150256
2302
2303         Reviewed by Sam Weinig.
2304
2305         We vacillated between PrintStream and TextStream as being the canonical way
2306         to stringify WebCore data structures. This patch solidifies TextStream
2307         as the solution, since it has convenient stream syntax, and is what we
2308         use for render tree dumps.
2309
2310         Remove TextStream member functions that output non-simple structs
2311         (sizes, points and rects), replacing them with free operator<< functions
2312         in the .cpp file for the relevant class. Formatting is currently consistent
2313         with RenderTreeAsText output, to avoid breaking tests.
2314
2315         Remove custom FloatRect outputting in SVG and RemoteLayerTreeTransaction.
2316
2317         * CMakeLists.txt:
2318         * WebCore.xcodeproj/project.pbxproj:
2319         * platform/graphics/FloatPoint.cpp:
2320         (WebCore::operator<<):
2321         (WebCore::FloatPoint::dump): Deleted.
2322         * platform/graphics/FloatPoint.h:
2323         * platform/graphics/FloatRect.cpp:
2324         (WebCore::operator<<):
2325         (WebCore::FloatRect::dump): Deleted.
2326         * platform/graphics/FloatRect.h:
2327         * platform/graphics/FloatSize.cpp:
2328         (WebCore::FloatSize::FloatSize):
2329         (WebCore::operator<<):
2330         (WebCore::FloatSize::dump): Deleted.
2331         * platform/graphics/FloatSize.h:
2332         * platform/graphics/IntPoint.cpp:
2333         (WebCore::operator<<):
2334         (WebCore::IntPoint::dump): Deleted.
2335         * platform/graphics/IntPoint.h:
2336         * platform/graphics/IntRect.cpp:
2337         (WebCore::operator<<):
2338         (WebCore::IntRect::dump): Deleted.
2339         * platform/graphics/IntRect.h:
2340         * platform/graphics/IntSize.cpp:
2341         (WebCore::operator<<):
2342         (WebCore::IntSize::dump): Deleted.
2343         * platform/graphics/IntSize.h:
2344         * platform/graphics/LayoutPoint.cpp: Copied from Source/WebCore/platform/graphics/IntPoint.cpp.
2345         (WebCore::operator<<):
2346         * platform/graphics/LayoutPoint.h:
2347         * platform/graphics/LayoutRect.cpp:
2348         (WebCore::operator<<):
2349         * platform/graphics/LayoutRect.h:
2350         * platform/graphics/LayoutSize.cpp: Copied from Source/WebCore/platform/graphics/IntPoint.cpp.
2351         (WebCore::operator<<):
2352         * platform/graphics/LayoutSize.h:
2353         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
2354         (WebCore::MediaSampleAVFObjC::dump):
2355         * platform/text/TextStream.cpp:
2356         (WebCore::TextStream::operator<<):
2357         * platform/text/TextStream.h:
2358         * rendering/svg/SVGRenderTreeAsText.cpp:
2359         (WebCore::operator<<): Deleted.
2360
2361 2015-10-16  Brent Fulgham  <bfulgham@apple.com>
2362
2363         Hide all plugin names except Flash, Java, and QuickTime
2364         https://bugs.webkit.org/show_bug.cgi?id=149014
2365
2366         Reviewed by Darin Adler.
2367
2368         Revise plugin interface so that sites cannot iterate over all plugins to obtain
2369         a list of installed plugins for fingerprinting purposes. Sites need to ask for
2370         specific plugins by name, rather than iterating and comparing to avoid making
2371         this information accessible for fingerprinting purposes.
2372
2373         * plugins/DOMPluginArray.cpp:
2374         (WebCore::DOMPluginArray::length): Only return length of the plugins we are
2375         allowing to be seen.
2376         (WebCore::DOMPluginArray::item): Only iterate through the plugins we are
2377         allowing to be seen.
2378         * plugins/PluginData.cpp:
2379         (WebCore::PluginData::publiclyVisiblePlugins): Added.
2380         * plugins/PluginData.h:
2381
2382 2015-10-16  Brady Eidson  <beidson@apple.com>
2383
2384         "enum class" some IDB enums.
2385         https://bugs.webkit.org/show_bug.cgi?id=150246
2386
2387         Reviewed by Alex Christensen.
2388
2389         No new tests (No change in behavior).
2390
2391         * Modules/indexeddb/IDBKeyPath.cpp:
2392         (WebCore::IDBIsValidKeyPath):
2393         (WebCore::IDBParseKeyPath):
2394         (WebCore::IDBKeyPath::IDBKeyPath):
2395         (WebCore::IDBKeyPath::isValid):
2396         (WebCore::IDBKeyPath::operator==):
2397         (WebCore::IDBKeyPath::encode):
2398         (WebCore::IDBKeyPath::decode):
2399         * Modules/indexeddb/IDBKeyPath.h:
2400         (WebCore::IDBKeyPath::IDBKeyPath):
2401         (WebCore::IDBKeyPath::type):
2402         (WebCore::IDBKeyPath::array):
2403         (WebCore::IDBKeyPath::string):
2404         (WebCore::IDBKeyPath::isNull):
2405         (WebCore::IDBKeyPath::encode):
2406         (WebCore::IDBKeyPath::decode):
2407         * Modules/indexeddb/IndexedDB.h:
2408         * Modules/indexeddb/legacy/LegacyDatabase.cpp:
2409         (WebCore::LegacyDatabase::createObjectStore):
2410         * Modules/indexeddb/legacy/LegacyObjectStore.cpp:
2411         (WebCore::LegacyObjectStore::createIndex):
2412         * bindings/js/IDBBindingUtilities.cpp:
2413         (WebCore::internalCreateIDBKeyFromScriptValueAndKeyPath):
2414         (WebCore::injectIDBKeyIntoScriptValue):
2415         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
2416         (WebCore::canInjectIDBKeyIntoScriptValue):
2417         * bindings/js/JSIDBAnyCustom.cpp:
2418         (WebCore::toJS):
2419         * inspector/InspectorIndexedDBAgent.cpp:
2420
2421 2015-10-16  Anders Carlsson  <andersca@apple.com>
2422
2423         Add indexeddb/shared to the include paths.
2424
2425         * WebCore.vcxproj/WebCoreIncludeCommon.props:
2426
2427 2015-10-16  Antti Koivisto  <antti@apple.com>
2428
2429         Computed style should work correctly with slotted elements that have display:none
2430         https://bugs.webkit.org/show_bug.cgi?id=150237
2431
2432         Reviewed by Andreas Kling.
2433
2434         If an element has display:none we don't normally retain or even compute its style (as it is not rendered).
2435         If getComputedStyle is invoked for such element we resolve the style (along with any ancestors) and cache
2436         it separately to rare data. This path needs to work with slotted elements in shadow trees.
2437
2438         This patch also make computedStyle() iterative rather than recursive.
2439
2440         Test: fast/shadow-dom/computed-style-display-none.html
2441
2442         * dom/Document.cpp:
2443         (WebCore::Document::styleForElementIgnoringPendingStylesheets):
2444
2445             Pass in the parent style instead of invoking computedStyle() recursively.
2446
2447         * dom/Document.h:
2448         * dom/Element.cpp:
2449         (WebCore::beforeOrAfterPseudoElement):
2450         (WebCore::Element::existingComputedStyle):
2451         (WebCore::Element::resolveComputedStyle):
2452
2453             Iterative resolve function that uses composed tree iterator.
2454
2455         (WebCore::Element::computedStyle):
2456
2457             Factor into helpers.
2458
2459         * dom/Element.h:
2460         * dom/Node.cpp:
2461         (WebCore::Node::computedStyle):
2462
2463             Use the composed tree iterator.
2464
2465 2015-10-16  David Hyatt  <hyatt@apple.com>
2466
2467         ASSERT in imported/blink/fast/block/float/overhanging-float-crashes-when-sibling-becomes-formatting-context.html
2468         https://bugs.webkit.org/show_bug.cgi?id=150249
2469
2470         Reviewed by Myles Maxfield.
2471
2472         Covered by existing tests.
2473
2474         * css/CSSValue.cpp:
2475         (WebCore::CSSValue::equals):
2476         Make sure the "unset" value has an equals implementation.
2477
2478 2015-10-16  Brady Eidson  <beidson@apple.com>
2479
2480         Modern IDB: Handle versionchange events.
2481         https://bugs.webkit.org/show_bug.cgi?id=150149
2482
2483         Reviewed by Alex Christensen.
2484
2485         Test: storage/indexeddb/modern/versionchange-event.html
2486         
2487         - IDBVersionChangeEvents are now dispatched to open connections when a
2488           version upgrade request comes in.
2489         - Once all of those open connections have closed, the version upgrade 
2490           request is handled.
2491
2492         * Modules/indexeddb/client/IDBConnectionToServer.cpp:
2493         (WebCore::IDBClient::IDBConnectionToServer::fireVersionChangeEvent):
2494         (WebCore::IDBClient::IDBConnectionToServer::registerDatabaseConnection):
2495         (WebCore::IDBClient::IDBConnectionToServer::unregisterDatabaseConnection):
2496         * Modules/indexeddb/client/IDBConnectionToServer.h:
2497
2498         * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
2499         (WebCore::IDBClient::IDBDatabase::fireVersionChangeEvent):
2500         * Modules/indexeddb/client/IDBDatabaseImpl.h:
2501
2502         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
2503         (WebCore::IDBServer::UniqueIDBDatabase::UniqueIDBDatabase):
2504         (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
2505         (WebCore::IDBServer::UniqueIDBDatabase::invokeTransactionScheduler):
2506         (WebCore::IDBServer::UniqueIDBDatabase::transactionSchedulingTimerFired):
2507         * Modules/indexeddb/server/UniqueIDBDatabase.h:
2508
2509 2015-10-16  Zalan Bujtas  <zalan@apple.com>
2510
2511         First line box in paragraph using initial-letter overflows.
2512         https://bugs.webkit.org/show_bug.cgi?id=147977
2513         <rdar://problem/22901553>
2514
2515         Reviewed by David Hyatt.
2516
2517         When initial-letter float is present, we should shrink the first
2518         line even if it's not intersected with the block's current height.
2519         This is because of the sunken behaviour of initial-letter. 
2520
2521         Test: fast/css-generated-content/initial-letter-first-line-wrapping.html
2522
2523         * rendering/RenderBlockFlow.h:
2524         * rendering/RenderBlockLineLayout.cpp:
2525         (WebCore::RenderBlockFlow::positionNewFloatOnLine):
2526         * rendering/line/BreakingContext.h:
2527         (WebCore::BreakingContext::handleFloat):
2528         * rendering/line/LineBreaker.cpp:
2529         (WebCore::LineBreaker::skipLeadingWhitespace):
2530         * rendering/line/LineBreaker.h:
2531         (WebCore::LineBreaker::positionNewFloatOnLine):
2532         * rendering/line/LineWidth.cpp:
2533         (WebCore::newFloatShrinksLine):
2534         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
2535         * rendering/line/LineWidth.h:
2536
2537 2015-10-16  Keith Rollin  <krollin@apple.com>
2538
2539         The value sanitization algorithm for input[type=url] should strip whitespaces
2540         https://bugs.webkit.org/show_bug.cgi?id=148864
2541         rdar://problem/22589358
2542
2543         Reviewed by Chris Dumez.
2544
2545         Follow the sanitization algorithm specified in:
2546         https://html.spec.whatwg.org/multipage/forms.html#url-state-(type=url)
2547
2548         Chrome also has the same issue with url.html. Firefox passes.  All
2549         three browsers have multiple issues with type-change-state.html, with
2550         each browser having a different set of failures. Addressing this in
2551         WebKit is another issue outside the scope of bz=148864. For now, I'm
2552         updating that test to capture current WebKit behavior.
2553
2554         No new tests (covered by existing tests):
2555         - web-platform-tests/html/semantics/forms/the-input-element/type-change-state.html
2556         - web-platform-tests/html/semantics/forms/the-input-element/url.html
2557
2558         * html/TextFieldInputType.h:
2559         * html/URLInputType.cpp:
2560         (WebCore::URLInputType::sanitizeValue):
2561         * html/URLInputType.h:
2562
2563 2015-10-16  Antti Koivisto  <antti@apple.com>
2564
2565         Remove NodeRenderingTraversal
2566         https://bugs.webkit.org/show_bug.cgi?id=150226
2567
2568         Reviewed by Chris Dumez.
2569
2570         It has been reduced to an implementation detail of FocusController. Move the remaining
2571         functions there as they have no general utility (and are wrong for focus navigation too).
2572
2573         * CMakeLists.txt:
2574         * WebCore.xcodeproj/project.pbxproj:
2575         * dom/DOMAllInOne.cpp:
2576         * dom/NodeRenderingTraversal.cpp: Removed.
2577         * dom/NodeRenderingTraversal.h: Removed.
2578         * page/FocusController.cpp:
2579         (WebCore::firstChildInScope):
2580         (WebCore::lastChildInScope):
2581         (WebCore::parentInScope):
2582         (WebCore::nextInScope):
2583         (WebCore::previousInScope):
2584         (WebCore::FocusNavigationScope::FocusNavigationScope):
2585         (WebCore::FocusNavigationScope::focusNavigationScopeOf):
2586         (WebCore::FocusController::findElementWithExactTabIndex):
2587         (WebCore::nextElementWithGreaterTabIndex):
2588         (WebCore::previousElementWithLowerTabIndex):
2589         (WebCore::FocusController::nextFocusableElement):
2590         (WebCore::FocusController::previousFocusableElement):
2591
2592 2015-10-16  David Hyatt  <hyatt@apple.com>
2593
2594         Build fix. "all" keyword introduction exposed a typo bug in the grid-area property definition.
2595
2596         * css/CSSPropertyNames.in:
2597
2598 2015-10-16  Tim Horton  <timothy_horton@apple.com>
2599
2600         Hook up autolayout intrinsic sizing for WKWebView
2601         https://bugs.webkit.org/show_bug.cgi?id=150219
2602         <rdar://problem/20016905>
2603
2604         Reviewed by Simon Fraser.
2605
2606         New API test: WebKit2.AutoLayoutIntegration.
2607
2608         * page/FrameView.cpp:
2609         (WebCore::FrameView::autoSizeIfEnabled):
2610         When autosizing a document in which the body expands to the size of 
2611         the view (a feature of quirks mode), the first (width-determining)
2612         autosizing will resize the view to the document height (which is at 
2613         least the body height), and the second time around, the height will
2614         not decrease (because it was expanded to the size of the view).
2615
2616         Instead, the first time around, we should use the computed width,
2617         but shrink the height back down to the minimum, and then expand
2618         only as much as needed to fit the content.
2619
2620 2015-10-16  Brady Eidson  <beidson@apple.com>
2621
2622         Modern IDB: Support IDBDatabase.close().
2623         https://bugs.webkit.org/show_bug.cgi?id=150150
2624
2625         Reviewed by Alex Christensen.
2626
2627         No new tests (Covered by changes to storage/indexeddb/modern/opendatabase-versions.html).
2628
2629         * Modules/indexeddb/client/IDBConnectionToServer.cpp:
2630         (WebCore::IDBClient::IDBConnectionToServer::databaseConnectionClosed):
2631         * Modules/indexeddb/client/IDBConnectionToServer.h:
2632         * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
2633
2634         * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
2635         (WebCore::IDBClient::IDBDatabase::IDBDatabase):
2636         (WebCore::IDBClient::IDBDatabase::~IDBDatabase):
2637         (WebCore::IDBClient::IDBDatabase::close):
2638         (WebCore::IDBClient::IDBDatabase::maybeCloseInServer):
2639         (WebCore::IDBClient::IDBDatabase::commitTransaction):
2640         * Modules/indexeddb/client/IDBDatabaseImpl.h:
2641         (WebCore::IDBClient::IDBDatabase::databaseConnectionIdentifier):
2642
2643         * Modules/indexeddb/client/IDBRequestImpl.cpp:
2644         (WebCore::IDBClient::IDBRequest::result):
2645
2646         * Modules/indexeddb/server/IDBServer.cpp:
2647         (WebCore::IDBServer::IDBServer::databaseConnectionClosed):
2648         * Modules/indexeddb/server/IDBServer.h:
2649
2650         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
2651         (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
2652         (WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations): Deleted.
2653         * Modules/indexeddb/server/UniqueIDBDatabase.h:
2654
2655         * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
2656         (WebCore::IDBServer::UniqueIDBDatabaseConnection::UniqueIDBDatabaseConnection):
2657         (WebCore::IDBServer::UniqueIDBDatabaseConnection::~UniqueIDBDatabaseConnection):
2658         (WebCore::IDBServer::UniqueIDBDatabaseConnection::hasNonFinishedTransactions):
2659         (WebCore::IDBServer::UniqueIDBDatabaseConnection::connectionClosedFromClient):
2660         * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
2661
2662         * Modules/indexeddb/shared/InProcessIDBServer.cpp:
2663         (WebCore::InProcessIDBServer::databaseConnectionClosed):
2664         * Modules/indexeddb/shared/InProcessIDBServer.h:
2665
2666 2015-10-16  Chris Dumez  <cdumez@apple.com>
2667
2668         HTMLPreloadScanner should preload iframes
2669         https://bugs.webkit.org/show_bug.cgi?id=150097
2670         <rdar://problem/23094475>
2671
2672         Reviewed by Antti Koivisto.
2673
2674         HTMLPreloadScanner should preload iframes to decrease page load time.
2675
2676         Tests:
2677         - fast/preloader/frame-src.html
2678         - http/tests/loading/preload-no-store-frame-src.html
2679
2680         * html/parser/HTMLPreloadScanner.cpp:
2681         (WebCore::TokenPreloadScanner::tagIdFor):
2682         (WebCore::TokenPreloadScanner::initiatorFor):
2683         (WebCore::TokenPreloadScanner::StartTagScanner::createPreloadRequest):
2684         (WebCore::TokenPreloadScanner::StartTagScanner::processAttribute):
2685         (WebCore::TokenPreloadScanner::StartTagScanner::resourceType):
2686         (WebCore::TokenPreloadScanner::StartTagScanner::setUrlToLoad): Deleted.
2687         (WebCore::TokenPreloadScanner::StartTagScanner::charset): Deleted.
2688         * html/parser/HTMLPreloadScanner.h:
2689
2690 2015-10-16  David Hyatt  <hyatt@apple.com>
2691
2692         Implement the "all" CSS property.
2693         https://bugs.webkit.org/show_bug.cgi?id=116966
2694
2695         Reviewed by Zalan Bujtas.
2696
2697         Added new tests in fast/css.
2698
2699         * css/CSSComputedStyleDeclaration.cpp:
2700         (WebCore::ComputedStyleExtractor::propertyValue):
2701         Don't support "all" from computed style for now.
2702
2703         * css/CSSParser.cpp:
2704         (WebCore::CSSParser::parseValue):
2705         Make sure to bail after checking inherit/unset/initial for all, since you can't actually
2706         accept longhand values in the shorthand declarations.
2707
2708         (WebCore::CSSParser::parseAnimationProperty):
2709         "all" for animations is a special value and should not be confused with the property. It
2710         animates everything and does not omit unicode-bidi/direction the way the "all" property does.
2711
2712         * css/CSSPropertyNames.in:
2713         Add the "all" property to the list and use a special keyword in the Longhands value, "all",
2714         that makeprop.pl will look for. This way we don't have to dump every single CSS property
2715         into the Longhands expression, since that would be nuts.
2716
2717         * css/StyleProperties.cpp:
2718         (WebCore::StyleProperties::getPropertyValue):
2719         Look for a common value across all properties supported by "all". That way you can get
2720         back inherit/initial/unset from it.
2721
2722         * css/makeprop.pl:
2723         Make the perl script look for "all" in the longhand list, and if it sees it, put every
2724         single CSS property into the list for the all shorthand.
2725
2726 2015-10-16  Youenn Fablet  <youenn.fablet@crf.canon.fr>
2727
2728         Binding generator should use templated JSXXConstructor
2729         https://bugs.webkit.org/show_bug.cgi?id=149952
2730
2731         Reviewed by Darin Adler.
2732
2733         Adding constructor templates:
2734         - JSDOMConstructor: usual JS constructors
2735         - JSDOMNamedConstructor: for named constructors
2736         - JSDOMConstructorNotConstructable: for objects that cannot be constructed directly from JS.
2737
2738         Binding generator is using these 3 templates and is generating specializations for construct, initializeProperties and s_info.
2739         These templates may also be used for private or custom constructors as examplified by JSImageConstructor
2740         and JSReadableStream reader and controller private constructors.
2741
2742         Updated binding generator to use those templates.
2743         Updated JSImageConstructor.cpp to use JSDOMNamedConstructor.
2744         Updated default template implementation of JSBuiltinConstructor::createObject.
2745         Updated generated helper routines of binding generator to fit with the templates.
2746
2747         A further patch should remove DOMConstructorWithDocument and DOMConstructorJSBuiltinObject. 
2748
2749         Covered by binding tests.
2750
2751         * bindings/js/JSDOMConstructor.h:
2752         (WebCore::JSDOMConstructorNotConstructable::create):
2753         (WebCore::JSDOMConstructorNotConstructable::createStructure):
2754         (WebCore::JSDOMConstructorNotConstructable::JSDOMConstructorNotConstructable):
2755         (WebCore::JSDOMConstructorNotConstructable::initializeProperties):
2756         (WebCore::JSDOMConstructorNotConstructable<JSClass>::finishCreation):
2757         (WebCore::JSDOMConstructor::create):
2758         (WebCore::JSDOMConstructor::createStructure):
2759         (WebCore::JSDOMConstructor::JSDOMConstructor):
2760         (WebCore::JSDOMConstructor::initializeProperties):
2761         (WebCore::JSDOMConstructor<JSClass>::finishCreation):
2762         (WebCore::JSDOMConstructor<JSClass>::getConstructData):
2763         (WebCore::JSDOMNamedConstructor::create):
2764         (WebCore::JSDOMNamedConstructor::createStructure):
2765         (WebCore::JSDOMNamedConstructor::JSDOMNamedConstructor):
2766         (WebCore::JSDOMNamedConstructor::initializeProperties):
2767         (WebCore::JSDOMNamedConstructor<JSClass>::finishCreation):
2768         (WebCore::JSDOMNamedConstructor<JSClass>::getConstructData):
2769         * bindings/js/JSDOMWindowCustom.cpp:
2770         (WebCore::JSDOMWindow::image):
2771         * bindings/js/JSImageConstructor.cpp:
2772         (WebCore::JSImageConstructor::initializeProperties):
2773         (WebCore::JSImageConstructor::construct):
2774         (WebCore::createImageConstructor):
2775         * bindings/js/JSImageConstructor.h:
2776         * bindings/scripts/CodeGeneratorJS.pm:
2777         (GetConstructorTemplateClassName):
2778         (GenerateConstructorDeclaration):
2779         (GenerateOverloadedConstructorDefinition):
2780         (GenerateConstructorDefinition):
2781         (GenerateConstructorHelperMethods):
2782         (GenerateImplementation): Deleted.
2783         (GenerateConstructorDefinitions): Deleted.
2784         (HasCustomSetter): Deleted.
2785         (HasCustomMethod): Deleted.
2786         (NeedsConstructorProperty): Deleted.
2787         (ComputeFunctionSpecial): Deleted.
2788         (AddJSBuiltinIncludesIfNeeded): Deleted.
2789         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
2790         (WebCore::JSTestActiveDOMObjectConstructor::initializeProperties):
2791         (WebCore::JSTestActiveDOMObjectPrototype::finishCreation): Deleted.
2792         (WebCore::JSTestActiveDOMObject::JSTestActiveDOMObject): Deleted.
2793         * bindings/scripts/test/JS/JSTestCallback.cpp:
2794         (WebCore::JSTestCallbackConstructor::initializeProperties):
2795         (WebCore::JSTestCallback::callbackWithNoParam): Deleted.
2796         * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
2797         (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::construct):
2798         (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::initializeProperties):
2799         (WebCore::JSTestCustomConstructorWithNoInterfaceObjectPrototype::finishCreation): Deleted.
2800         (WebCore::JSTestCustomConstructorWithNoInterfaceObject::JSTestCustomConstructorWithNoInterfaceObject): Deleted.
2801         (WebCore::JSTestCustomConstructorWithNoInterfaceObject::createPrototype): Deleted.
2802         (WebCore::JSTestCustomConstructorWithNoInterfaceObject::getPrototype): Deleted.
2803         (WebCore::JSTestCustomConstructorWithNoInterfaceObject::destroy): Deleted.
2804         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
2805         (WebCore::JSTestCustomNamedGetterConstructor::initializeProperties):
2806         (WebCore::JSTestCustomNamedGetterPrototype::finishCreation): Deleted.
2807         (WebCore::JSTestCustomNamedGetter::JSTestCustomNamedGetter): Deleted.
2808         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
2809         (WebCore::JSTestEventConstructorConstructor::construct):
2810         (WebCore::JSTestEventConstructorConstructor::initializeProperties):
2811         (WebCore::JSTestEventConstructorPrototype::finishCreation): Deleted.
2812         (WebCore::JSTestEventConstructor::JSTestEventConstructor): Deleted.
2813         (WebCore::JSTestEventConstructor::getPrototype): Deleted.
2814         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
2815         (WebCore::JSTestEventTargetConstructor::initializeProperties):
2816         (WebCore::JSTestEventTargetPrototype::finishCreation): Deleted.
2817         * bindings/scripts/test/JS/JSTestException.cpp:
2818         (WebCore::JSTestExceptionConstructor::initializeProperties):
2819         (WebCore::JSTestExceptionPrototype::finishCreation): Deleted.
2820         (WebCore::JSTestException::JSTestException): Deleted.
2821         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
2822         (WebCore::JSTestGenerateIsReachableConstructor::initializeProperties):
2823         (WebCore::JSTestGenerateIsReachablePrototype::finishCreation): Deleted.
2824         (WebCore::JSTestGenerateIsReachable::JSTestGenerateIsReachable): Deleted.
2825         * bindings/scripts/test/JS/JSTestInterface.cpp:
2826         (WebCore::JSTestInterfaceConstructor::construct):
2827         (WebCore::JSTestInterfaceConstructor::initializeProperties):
2828         (WebCore::JSTestInterfaceConstructor::getConstructData):
2829         * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
2830         (WebCore::JSTestJSBuiltinConstructorConstructor::createJSObject):
2831         (WebCore::JSTestJSBuiltinConstructorConstructor::initializeProperties):
2832         (WebCore::JSTestJSBuiltinConstructorPrototype::finishCreation): Deleted.
2833         (WebCore::JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor): Deleted.
2834         (WebCore::JSTestJSBuiltinConstructor::createPrototype): Deleted.
2835         (WebCore::JSTestJSBuiltinConstructor::getPrototype): Deleted.
2836         (WebCore::JSTestJSBuiltinConstructor::destroy): Deleted.
2837         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
2838         (WebCore::JSTestMediaQueryListListenerConstructor::initializeProperties):
2839         (WebCore::JSTestMediaQueryListListenerPrototype::finishCreation): Deleted.
2840         (WebCore::JSTestMediaQueryListListener::JSTestMediaQueryListListener): Deleted.
2841         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
2842         (WebCore::JSTestNamedConstructorConstructor::initializeProperties):
2843         (WebCore::JSTestNamedConstructorNamedConstructor::construct):
2844         (WebCore::JSTestNamedConstructorNamedConstructor::initializeProperties):
2845         (WebCore::JSTestNamedConstructorPrototype::finishCreation): Deleted.
2846         (WebCore::JSTestNamedConstructor::JSTestNamedConstructor): Deleted.
2847         (WebCore::jsTestNamedConstructorConstructor): Deleted.
2848         (WebCore::JSTestNamedConstructor::getConstructor): Deleted.
2849         (WebCore::JSTestNamedConstructorOwner::isReachableFromOpaqueRoots): Deleted.
2850         * bindings/scripts/test/JS/JSTestNode.cpp:
2851         (WebCore::JSTestNodeConstructor::construct):
2852         (WebCore::JSTestNodeConstructor::initializeProperties):
2853         (WebCore::JSTestNodePrototype::finishCreation): Deleted.
2854         (WebCore::JSTestNode::JSTestNode): Deleted.
2855         (WebCore::JSTestNode::getPrototype): Deleted.
2856         * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
2857         (WebCore::JSTestNondeterministicConstructor::initializeProperties):
2858         (WebCore::JSTestNondeterministicPrototype::finishCreation): Deleted.
2859         * bindings/scripts/test/JS/JSTestObj.cpp:
2860         (WebCore::JSTestObjConstructor::construct):
2861         (WebCore::JSTestObjConstructor::initializeProperties):
2862         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
2863         (WebCore::JSTestOverloadedConstructorsConstructor::construct):
2864         (WebCore::JSTestOverloadedConstructorsConstructor::initializeProperties):
2865         (WebCore::constructJSTestOverloadedConstructors1): Deleted.
2866         (WebCore::constructJSTestOverloadedConstructors2): Deleted.
2867         (WebCore::JSTestOverloadedConstructorsPrototype::finishCreation): Deleted.
2868         (WebCore::JSTestOverloadedConstructors::JSTestOverloadedConstructors): Deleted.
2869         (WebCore::JSTestOverloadedConstructors::createPrototype): Deleted.
2870         (WebCore::JSTestOverloadedConstructors::getPrototype): Deleted.
2871         (WebCore::JSTestOverloadedConstructors::destroy): Deleted.
2872         * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
2873         (WebCore::JSTestOverrideBuiltinsConstructor::initializeProperties):
2874         (WebCore::JSTestOverrideBuiltinsPrototype::finishCreation): Deleted.
2875         (WebCore::JSTestOverrideBuiltins::JSTestOverrideBuiltins): Deleted.
2876         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
2877         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::initializeProperties):
2878         (WebCore::JSTestSerializedScriptValueInterfacePrototype::finishCreation): Deleted.
2879         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
2880         (WebCore::JSTestTypedefsConstructor::construct):
2881         (WebCore::JSTestTypedefsConstructor::initializeProperties):
2882         (WebCore::JSTestTypedefsPrototype::finishCreation): Deleted.
2883         * bindings/scripts/test/JS/JSattribute.cpp:
2884         (WebCore::JSattributeConstructor::initializeProperties):
2885         (WebCore::JSattributePrototype::finishCreation): Deleted.
2886         (WebCore::JSattribute::JSattribute): Deleted.
2887         * bindings/scripts/test/JS/JSreadonly.cpp:
2888         (WebCore::JSreadonlyConstructor::initializeProperties):
2889         (WebCore::JSreadonlyPrototype::finishCreation): Deleted.
2890         (WebCore::JSreadonly::JSreadonly): Deleted.
2891
2892 2015-10-16  Carlos Garcia Campos  <cgarcia@igalia.com>
2893
2894         [GStreamer] ASSERTION FAILED: !m_adoptionIsRequired in MediaSourceGStreamer::addSourceBuffer
2895         https://bugs.webkit.org/show_bug.cgi?id=150229
2896
2897         Reviewed by Philippe Normand.
2898
2899         This happens in the debug bot in all media source tests that run
2900         that code. The problem is that we are creating a RefPtr without
2901         adopting the reference.
2902
2903         * platform/graphics/gstreamer/MediaSourceGStreamer.cpp:
2904         (WebCore::MediaSourceGStreamer::addSourceBuffer): Use
2905         SourceBufferPrivateGStreamer::create().
2906         * platform/graphics/gstreamer/SourceBufferPrivateGStreamer.cpp:
2907         (WebCore::SourceBufferPrivateGStreamer::create): Added to make
2908         sure you can't create a SourceBufferPrivateGStreamer without
2909         adopting the reference.
2910         (WebCore::SourceBufferPrivateGStreamer::SourceBufferPrivateGStreamer):
2911         Takes a reference to the client instead of a PassRefPtr.
2912         * platform/graphics/gstreamer/SourceBufferPrivateGStreamer.h:
2913
2914 2015-10-15  Roopesh Chander  <roop@roopc.net>
2915
2916         [Content Extensions] Content blocking rules are not consulted for pings
2917         https://bugs.webkit.org/show_bug.cgi?id=149873
2918
2919         Reviewed by Alex Christensen.
2920
2921         This patch makes requests sent through the PingLoader
2922         respect content blocking rules. Specifically, the following
2923         are now subject to content blocking rules:
2924  
2925          1. <a ping> pings
2926          2. Images loaded in unload / beforeunload / pagehide handlers
2927          3. X-XSS-Protection / CSP violation reports
2928
2929         Tests: http/tests/contentextensions/block-cookies-in-csp-report.html
2930                http/tests/contentextensions/block-cookies-in-image-load-in-onunload.html
2931                http/tests/contentextensions/block-cookies-in-ping.html
2932                http/tests/contentextensions/block-csp-report.html
2933                http/tests/contentextensions/block-image-load-in-onunload.html
2934                http/tests/contentextensions/block-ping.html
2935                http/tests/contentextensions/hide-on-csp-report.html
2936
2937         * loader/PingLoader.cpp:
2938         (WebCore::processContentExtensionRulesForLoad):
2939         (WebCore::PingLoader::loadImage):
2940         (WebCore::PingLoader::sendPing):
2941         (WebCore::PingLoader::sendViolationReport):
2942
2943 2015-10-14  Joseph Pecoraro  <pecoraro@apple.com>
2944
2945         Web Inspector: Include Garbage Collection Event in Timeline
2946         https://bugs.webkit.org/show_bug.cgi?id=142510
2947
2948         Reviewed by Geoffrey Garen and Brian Burg.
2949
2950         Tests: inspector/heap/garbageCollected.html
2951                inspector/heap/gc.html
2952
2953         * ForwardingHeaders/heap/HeapObserver.h: Added.
2954         * ForwardingHeaders/inspector/agents/InspectorHeapAgent.h: Added.
2955         * WebCore.vcxproj/WebCore.vcxproj:
2956         * WebCore.vcxproj/WebCore.vcxproj.filters:
2957         Forwarding headers.
2958
2959         * inspector/InspectorController.cpp:
2960         (WebCore::InspectorController::InspectorController):
2961         (WebCore::InspectorController::vm):
2962         * inspector/InspectorController.h:
2963         * inspector/WorkerInspectorController.cpp:
2964         (WebCore::WorkerInspectorController::vm):
2965         * inspector/WorkerInspectorController.h:
2966         Implement InspectorEnvironment::vm and create a Heap agent for the
2967         Page inspector controller.
2968
2969 2015-10-15  Commit Queue  <commit-queue@webkit.org>
2970
2971         Unreviewed, rolling out r191156.
2972         https://bugs.webkit.org/show_bug.cgi?id=150215
2973
2974         Introduced crashing test (Requested by bradee-oh on #webkit).
2975
2976         Reverted changeset:
2977
2978         "Modern IDB: Support IDBDatabase.close()."
2979         https://bugs.webkit.org/show_bug.cgi?id=150150
2980         http://trac.webkit.org/changeset/191156
2981
2982 2015-10-15  Brady Eidson  <beidson@apple.com>
2983
2984         Modern IDB: Support IDBDatabase.close().
2985         https://bugs.webkit.org/show_bug.cgi?id=150150
2986
2987         Reviewed by Alex Christensen.
2988
2989         No new tests (Covered by changes to storage/indexeddb/modern/opendatabase-versions.html).
2990
2991         * Modules/indexeddb/client/IDBConnectionToServer.cpp:
2992         (WebCore::IDBClient::IDBConnectionToServer::databaseConnectionClosed):
2993         * Modules/indexeddb/client/IDBConnectionToServer.h:
2994         * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
2995
2996         * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
2997         (WebCore::IDBClient::IDBDatabase::IDBDatabase):
2998         (WebCore::IDBClient::IDBDatabase::~IDBDatabase):
2999         (WebCore::IDBClient::IDBDatabase::close):
3000         (WebCore::IDBClient::IDBDatabase::maybeCloseInServer):
3001         (WebCore::IDBClient::IDBDatabase::commitTransaction):
3002         * Modules/indexeddb/client/IDBDatabaseImpl.h:
3003         (WebCore::IDBClient::IDBDatabase::databaseConnectionIdentifier):
3004
3005         * Modules/indexeddb/client/IDBRequestImpl.cpp:
3006         (WebCore::IDBClient::IDBRequest::result):
3007
3008         * Modules/indexeddb/server/IDBServer.cpp:
3009         (WebCore::IDBServer::IDBServer::databaseConnectionClosed):
3010         * Modules/indexeddb/server/IDBServer.h:
3011
3012         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
3013         (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
3014         (WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations): Deleted.
3015         * Modules/indexeddb/server/UniqueIDBDatabase.h:
3016
3017         * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
3018         (WebCore::IDBServer::UniqueIDBDatabaseConnection::UniqueIDBDatabaseConnection):
3019         (WebCore::IDBServer::UniqueIDBDatabaseConnection::~UniqueIDBDatabaseConnection):
3020         (WebCore::IDBServer::UniqueIDBDatabaseConnection::hasNonFinishedTransactions):
3021         (WebCore::IDBServer::UniqueIDBDatabaseConnection::connectionClosedFromClient):
3022         * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
3023
3024         * Modules/indexeddb/shared/InProcessIDBServer.cpp:
3025         (WebCore::InProcessIDBServer::databaseConnectionClosed):
3026         * Modules/indexeddb/shared/InProcessIDBServer.h:
3027
3028 2015-10-15  David Hyatt  <hyatt@apple.com>
3029
3030         Patch parseKeywordValue to accept "unset" so that it goes down the faster parsing path.
3031         https://bugs.webkit.org/show_bug.cgi?id=150213
3032
3033         Reviewed by Dean Jackson.
3034
3035         No new tests as correctness doesn't change (just speed).
3036
3037         * css/CSSParser.cpp:
3038         (WebCore::parseKeywordValue):
3039
3040 2015-10-15  David Hyatt  <hyatt@apple.com>
3041
3042         Add support for the CSS 'unset' keyword.
3043         https://bugs.webkit.org/show_bug.cgi?id=148614
3044
3045         Reviewed by Dean Jackson.
3046
3047         Added new test in fast/css, and existing variables tests also use unset in several tests.
3048
3049         * WebCore.xcodeproj/project.pbxproj:
3050         Add CSSUnsetValue.cpp to the project.
3051
3052         * bindings/objc/DOMCSS.mm:
3053         (kitClass):
3054         Make sure UNSET is handled in the switch.
3055
3056         * css/CSSParser.cpp:
3057         (WebCore::parseKeywordValue):
3058         (WebCore::CSSParser::parseValue):
3059         (WebCore::CSSParser::parseCustomPropertyDeclaration):
3060         Add cases to create a CSSUnsetValue properly.
3061
3062         * css/CSSToStyleMap.cpp:
3063         (WebCore::CSSToStyleMap::styleImage):
3064         (WebCore::CSSToStyleMap::mapFillAttachment):
3065         (WebCore::CSSToStyleMap::mapFillClip):
3066         (WebCore::CSSToStyleMap::mapFillComposite):
3067         (WebCore::CSSToStyleMap::mapFillBlendMode):
3068         (WebCore::CSSToStyleMap::mapFillOrigin):
3069         (WebCore::CSSToStyleMap::mapFillImage):
3070         (WebCore::CSSToStyleMap::mapFillRepeatX):
3071         (WebCore::CSSToStyleMap::mapFillRepeatY):
3072         (WebCore::convertToLengthSize):
3073         (WebCore::CSSToStyleMap::mapFillSize):
3074         (WebCore::CSSToStyleMap::mapFillXPosition):
3075         (WebCore::CSSToStyleMap::mapFillYPosition):
3076         (WebCore::CSSToStyleMap::mapFillMaskSourceType):
3077         (WebCore::CSSToStyleMap::mapAnimationDelay):
3078         (WebCore::CSSToStyleMap::mapAnimationDirection):
3079         (WebCore::CSSToStyleMap::mapAnimationDuration):
3080         (WebCore::CSSToStyleMap::mapAnimationFillMode):
3081         (WebCore::CSSToStyleMap::mapAnimationIterationCount):
3082         (WebCore::CSSToStyleMap::mapAnimationName):
3083         (WebCore::CSSToStyleMap::mapAnimationPlayState):
3084         (WebCore::CSSToStyleMap::mapAnimationProperty):
3085         (WebCore::CSSToStyleMap::mapAnimationTimingFunction):
3086         (WebCore::CSSToStyleMap::mapAnimationTrigger):
3087         The background and animation functions need to check for unset and be able to map it properly to initial. This is done
3088         with a new treatAsInitial method on CSSValue that can take the property ID and check for both initial
3089         or unset on a non-inherited property.
3090
3091         * css/CSSUnsetValue.cpp: Added.
3092         (WebCore::CSSUnsetValue::customCSSText):
3093         * css/CSSUnsetValue.h: Added.
3094         (WebCore::CSSUnsetValue::create):
3095         (WebCore::CSSUnsetValue::equals):
3096         (WebCore::CSSUnsetValue::CSSUnsetValue):
3097         This new value looks exactly like CSSInheritedValue and CSSInitialValue.
3098
3099         * css/CSSValue.cpp:
3100         (WebCore::CSSValue::cssValueType):
3101         (WebCore::CSSValue::cssText):
3102         (WebCore::CSSValue::destroy):
3103         (WebCore::CSSValue::isInvalidCustomPropertyValue):
3104         (WebCore::CSSValue::treatAsInheritedValue):
3105         (WebCore::CSSValue::treatAsInitialValue):
3106         * css/CSSValue.h:
3107         (WebCore::CSSValue::isUnsetValue):
3108         Add isUnsetValue and the UnsetClass. Add support for treatAsInheritedValue and treatAsInitialValue to have
3109         a way to query for initial/inherit or the matching unset type.
3110
3111         * css/CSSValueKeywords.in:
3112         Add the unset keyword.
3113
3114         * css/CSSValuePool.cpp:
3115         (WebCore::CSSValuePool::CSSValuePool):
3116         * css/CSSValuePool.h:
3117         (WebCore::CSSValuePool::createUnsetValue):
3118         Have a singleton model for unset just like we do for inherit/initial.
3119
3120         * css/StyleResolver.cpp:
3121         (WebCore::StyleResolver::applyProperty):
3122         Handle unset correctly. It maps to inherit for inherited properties and initial for non-inherited ones.
3123
3124 2015-10-15  Myles C. Maxfield  <mmaxfield@apple.com>
3125
3126         Migrate to CGContextSetBaseCTM() and CGContextResetClip() from WKSI
3127         https://bugs.webkit.org/show_bug.cgi?id=150155
3128
3129         Reviewed by Tim Horton.
3130
3131         No new tests because there is no behavior change.
3132
3133         * platform/graphics/cg/GraphicsContextCG.cpp:
3134         (WebCore::GraphicsContext::drawPattern):
3135         (WebCore::GraphicsContext::platformApplyDeviceScaleFactor):
3136         * platform/graphics/cg/ImageBufferCG.cpp:
3137         (WebCore::ImageBuffer::putByteArray):
3138         * platform/ios/WebCoreSystemInterfaceIOS.mm:
3139         * platform/mac/WebCoreSystemInterface.h:
3140         * platform/mac/WebCoreSystemInterface.mm:
3141
3142 2015-10-15  Dan Bernstein  <mitz@apple.com>
3143
3144         Fixed the build.
3145
3146         * platform/network/mac/ResourceHandleMac.mm:
3147
3148 2015-10-15  Dan Bernstein  <mitz@apple.com>
3149
3150         [Cocoa] Stop using WKSetNSURLConnectionDefersCallbacks
3151         https://bugs.webkit.org/show_bug.cgi?id=150189
3152
3153         Reviewed by Anders Carlsson.
3154
3155         * platform/ios/WebCoreSystemInterfaceIOS.mm: Removed definition.
3156         * platform/mac/WebCoreSystemInterface.h: Removed declaration.
3157         * platform/mac/WebCoreSystemInterface.mm: Removed definition.
3158
3159         * platform/network/mac/ResourceHandleMac.mm:
3160         (WebCore::ResourceHandle::start): Changed to use -[NSURLConnection setDefersLoading:].
3161         (WebCore::ResourceHandle::platformSetDefersLoading): Ditto.
3162
3163         * platform/spi/cocoa/NSURLConnectionSPI.h: Added declaration of
3164           -[NSURLConnection setDefersLoading:].
3165
3166 2015-10-15  Dean Jackson  <dino@apple.com>
3167
3168         CSSKeyframesRule::appendRule is deprecated, but is actually the spec
3169         https://bugs.webkit.org/show_bug.cgi?id=150113
3170
3171         Reviewed by Simon Fraser.
3172
3173         I stupidly deprecated the wrong function in
3174         http://trac.webkit.org/changeset/174469
3175
3176         * css/CSSKeyframesRule.cpp:
3177         (WebCore::CSSKeyframesRule::insertRule): Swap the code between these two.
3178         (WebCore::CSSKeyframesRule::appendRule):
3179
3180 2015-10-14  David Hyatt  <hyatt@apple.com>
3181
3182         Implement CSS Variables.
3183         https://bugs.webkit.org/show_bug.cgi?id=19660
3184
3185         Reviewed by Dean Jackson.
3186
3187         Added new tests in fast/css/custom-properties and fast/css/variables.
3188
3189         * CMakeLists.txt:
3190         * WebCore.xcodeproj/project.pbxproj:
3191         Add CSSVariableValue.cpp and CSSVariableDependentValue.cpp to builds.
3192
3193         * css/CSSCalculationValue.cpp:
3194         (WebCore::hasDoubleValue):
3195         Handle the new CSS_PARSER_WHITESPACE value.
3196
3197         * css/CSSComputedStyleDeclaration.cpp:
3198         (WebCore::ComputedStyleExtractor::customPropertyValue):
3199         Patched to make sure style is updated so that dynamic changes to custom properties are reflected
3200         immediately when querying values.
3201
3202         (WebCore::CSSComputedStyleDeclaration::length):
3203         (WebCore::CSSComputedStyleDeclaration::item):
3204         The custom properties table is a reference and not a pointer now.
3205
3206         * css/CSSCustomPropertyValue.h:
3207         (WebCore::CSSCustomPropertyValue::create):
3208         (WebCore::CSSCustomPropertyValue::createInvalid):
3209         (WebCore::CSSCustomPropertyValue::customCSSText):
3210         (WebCore::CSSCustomPropertyValue::equals):
3211         (WebCore::CSSCustomPropertyValue::isInvalid):
3212         (WebCore::CSSCustomPropertyValue::containsVariables):
3213         (WebCore::CSSCustomPropertyValue::value):
3214         (WebCore::CSSCustomPropertyValue::CSSCustomPropertyValue):
3215         The CSSCustomPropertyValue represents a custom property/value pair in the back end. It holds on
3216         to both the property name and a CSSValueList that has the original parser terms. This class also
3217         doubles as the invalid-at-compute-time value for custom properties when they contain cycles, etc.
3218
3219         * css/CSSFunctionValue.cpp:
3220         (WebCore::CSSFunctionValue::buildParserValueSubstitutingVariables):
3221          * css/CSSFunctionValue.h:
3222         (WebCore::CSSFunctionValue::buildParserValueSubstitutingVariables):
3223         Hands back a CSSParserValue for a function with variables replaced with their real values (or fallback).
3224
3225         * css/CSSGrammar.y.in:
3226         Many changes to support the var() syntax and to handle error conditions and cases.
3227
3228         * css/CSSParser.cpp:
3229         (WebCore::filterProperties):
3230         Null check the value here. Shouldn't happen, but being paranoid.
3231
3232         (WebCore::CSSParser::parseVariableDependentValue):
3233         This function converts a CSSValueList back into a CSSParserValueList and then passes
3234         it off to the parser. If the result parses, successfully, then the parsed CSSValue is handed back.
3235
3236         (WebCore::CSSParser::parseValue):
3237         Detect when a property value contains variables and simply make a CSSVariableDependentValue to hold
3238         a copy of the parser value list (as a CSSValueList). We defer parsing the list until compute-time
3239         when we know the values of the variables to use.
3240
3241         (WebCore::CSSParser::parseCustomPropertyDeclaration):
3242         Add support for inherit, initial and variable references in custom properties.
3243
3244         (WebCore::CSSParser::detectFunctionTypeToken):
3245         Add support for detection of the "var" token.
3246
3247         (WebCore::CSSParser::realLex):
3248         Fix the parsing of custom properties to allow "--" and to allow them to start with digits, e.g., "--0".
3249
3250         * css/CSSParser.h:
3251         Add parseVariableDependentValue function for handling variable substitution and subsequent parsing
3252         of the resolved parser value list.
3253
3254         * css/CSSParserValues.cpp:
3255         (WebCore::CSSParserValueList::containsVariables):
3256         Get rid of the toString() function (no longer needed) and replace it with containsVariables(). This
3257         check is used to figure out if a parser value list has variables and thus needs to defer parsing
3258         until later.
3259
3260         (WebCore::CSSParserValue::createCSSValue):
3261         Add support for the creation of values for variables, CSSVariableValues.
3262
3263         (WebCore::CSSParserValueList::toString): Deleted.
3264         No longer needed.
3265
3266         * css/CSSParserValues.h:
3267         Add CSSParserVariable as a new kind of parser value. This represents a var() that is encountered
3268         during parsing. It is similar to a function except it has to hold both the reference (custom property name)
3269         and fallback arguments.
3270
3271         * css/CSSPrimitiveValue.cpp:
3272         (WebCore::isValidCSSUnitTypeForDoubleConversion):
3273         (WebCore::CSSPrimitiveValue::cleanup):
3274         (WebCore::CSSPrimitiveValue::formatNumberForCustomCSSText):
3275         (WebCore::CSSPrimitiveValue::cloneForCSSOM):
3276         (WebCore::CSSPrimitiveValue::equals):
3277         Add support for CSS_PARSER_WHITESPACE as a way of preserving whitespace as a parsed item (variables can
3278         be only whitespace, and this has to be retained).
3279
3280         (WebCore::CSSPrimitiveValue::buildParserValue):
3281         Conversion from a CSSPrimitiveValue back into a parser value is handled by this function.
3282
3283         * css/CSSPrimitiveValue.h:
3284         (WebCore::CSSPrimitiveValue::isParserOperator):
3285         (WebCore::CSSPrimitiveValue::parserOperator):
3286         Add ability to get parser operator info. Add the buildParserValue declaration.
3287
3288         * css/CSSValue.cpp:
3289         (WebCore::CSSValue::equals):
3290         (WebCore::CSSValue::cssText):
3291         (WebCore::CSSValue::destroy):
3292         (WebCore::CSSValue::cloneForCSSOM):
3293         (WebCore::CSSValue::isInvalidCustomPropertyValue):
3294         * css/CSSValue.h:
3295         Add support for variable values and variable dependent values.
3296
3297         * css/CSSValueList.cpp:
3298         (WebCore::CSSValueList::customCSSText):
3299         Improve serialization to not output extra spaces when a comma operator is a value.
3300
3301         (WebCore::CSSValueList::containsVariables):
3302         Whether or not a CSSVariableValue can be found somewhere within the list (or its descendants).
3303
3304         (WebCore::CSSValueList::checkVariablesForCycles):
3305         Called to check variables for cycles.
3306
3307         (WebCore::CSSValueList::buildParserValueSubstitutingVariables):
3308         (WebCore::CSSValueList::buildParserValueListSubstitutingVariables):
3309         Functions that handle converting the value list to a parser value list while making
3310         variable substitutions along the way.
3311
3312         * css/CSSValueList.h:
3313         Add the new buildParserXXX functions.
3314
3315         * css/CSSVariableDependentValue.cpp: Added.
3316         (WebCore::CSSVariableDependentValue::checkVariablesForCycles):
3317         * css/CSSVariableDependentValue.h: Added.
3318         (WebCore::CSSVariableDependentValue::create):
3319         (WebCore::CSSVariableDependentValue::customCSSText):
3320         (WebCore::CSSVariableDependentValue::equals):
3321         (WebCore::CSSVariableDependentValue::propertyID):
3322         (WebCore::CSSVariableDependentValue::valueList):
3323         (WebCore::CSSVariableDependentValue::CSSVariableDependentValue):
3324         This value represents a list of terms that have not had variables substituted yet. The list
3325         is held by the value so that it can be converted back into a parser value list once the
3326         variable values are known.
3327
3328         * css/CSSVariableValue.cpp: Added.
3329         (WebCore::CSSVariableValue::CSSVariableValue):
3330         (WebCore::CSSVariableValue::customCSSText):
3331         (WebCore::CSSVariableValue::equals):
3332         (WebCore::CSSVariableValue::buildParserValueListSubstitutingVariables):
3333         * css/CSSVariableValue.h: Added.
3334         (WebCore::CSSVariableValue::create):
3335         (WebCore::CSSVariableValue::name):
3336         (WebCore::CSSVariableValue::fallbackArguments):
3337         This value represents a var() itself. It knows how to do the substitution of the variable
3338         value and to apply fallback if that value is not present.
3339
3340         * css/StyleProperties.cpp:
3341         (WebCore::StyleProperties::getPropertyValue):
3342         (WebCore::StyleProperties::borderSpacingValue):
3343         (WebCore::StyleProperties::getLayeredShorthandValue):
3344         (WebCore::StyleProperties::getShorthandValue):
3345         (WebCore::StyleProperties::getCommonValue):
3346         (WebCore::StyleProperties::getPropertyCSSValue):
3347         (WebCore::StyleProperties::getPropertyCSSValueInternal):
3348         (WebCore::StyleProperties::asText):
3349         (WebCore::StyleProperties::copyPropertiesInSet):
3350         * css/StyleProperties.h:
3351         Patched to factor property fetching into an internal method so that variables can work with shorthands
3352         in the CSS OM.
3353
3354         * css/StyleResolver.cpp:
3355         (WebCore::StyleResolver::applyProperty):
3356         Resolve variable values at compute time. If they fail to resolve, use inherit or initial as the
3357         value (depending on whether the property inherits by default).
3358
3359         (WebCore::StyleResolver::resolvedVariableValue):
3360         Helper function that calls parseVariableDependentValue and gets the resolved result.
3361
3362         (WebCore::StyleResolver::applyCascadedProperties):
3363         After custom properties have been collected, we check for cycles and perform variable substitutions.
3364         This way we get all the variables replaced before we inherit down the style tree.
3365
3366         * css/StyleResolver.h:
3367         Add resolvedVariableValue declaration.
3368
3369         * css/makeprop.pl:
3370         Make sure custom properties are inherited by default.
3371
3372         * rendering/style/RenderStyle.cpp:
3373         (WebCore::RenderStyle::checkVariablesInCustomProperties):
3374         This function handles updating variables with cycles to be invalid in the RenderStyle. It then also
3375         handles the replacement of variables found in custom properties with resolved values. All custom
3376         properties are either invalid or are real non-variable-dependent value lists after this function
3377         completes.
3378
3379         * rendering/style/RenderStyle.h:
3380         Add checkVariablesInCustomProperties declaration.
3381
3382         * rendering/style/StyleCustomPropertyData.h:
3383         (WebCore::StyleCustomPropertyData::create):
3384         (WebCore::StyleCustomPropertyData::copy):
3385         (WebCore::StyleCustomPropertyData::operator==):
3386         (WebCore::StyleCustomPropertyData::operator!=):
3387         (WebCore::StyleCustomPropertyData::setCustomPropertyValue):
3388         (WebCore::StyleCustomPropertyData::getCustomPropertyValue):
3389         (WebCore::StyleCustomPropertyData::values):
3390         (WebCore::StyleCustomPropertyData::hasCustomProperty):
3391         (WebCore::StyleCustomPropertyData::containsVariables):
3392         (WebCore::StyleCustomPropertyData::setContainsVariables):
3393         (WebCore::StyleCustomPropertyData::StyleCustomPropertyData):
3394         Miscellaneous cleanup, and the addition of whether or not the properties still contain variable
3395         dependent values that need to be resolved.
3396
3397 2015-10-15  Csaba Osztrogonác  <ossy@webkit.org>
3398
3399         Fix the !(ENABLE(SHADOW_DOM) || ENABLE(DETAILS_ELEMENT)) build after r191112
3400         https://bugs.webkit.org/show_bug.cgi?id=150175
3401
3402         Reviewed by Antti Koivisto.
3403
3404         * dom/ComposedTreeAncestorIterator.h:
3405         (WebCore::ComposedTreeAncestorIterator::traverseParent):
3406         * dom/ComposedTreeIterator.cpp:
3407         (WebCore::ComposedTreeIterator::initializeShadowStack):
3408         * dom/Element.cpp:
3409         (WebCore::Element::childrenChanged):
3410
3411 2015-10-15  Csaba Osztrogonác  <ossy@webkit.org>
3412
3413         Get rid of the only once used isIntegerArray function
3414         https://bugs.webkit.org/show_bug.cgi?id=150170
3415
3416         Reviewed by Geoffrey Garen.
3417
3418         * page/Crypto.cpp:
3419         (WebCore::Crypto::getRandomValues):
3420
3421 2015-10-15  Tim Horton  <timothy_horton@apple.com>
3422
3423         Try to fix the iOS build.
3424
3425         * page/EventHandler.h:
3426
3427 2015-10-15  Zalan Bujtas  <zalan@apple.com>
3428
3429         Anonymous table objects: Collapse anonymous table rows.
3430         https://bugs.webkit.org/show_bug.cgi?id=150154
3431
3432         Reviewed by David Hyatt.
3433
3434         Merge anonymous table rows when they are not needed anymore.
3435         Generated table rows can be collapsed into one when there's no
3436         non-generated sibling table row left in the tree.
3437
3438         Import W3C CSS2.1 anonymous table tests.
3439
3440         * rendering/RenderObject.cpp:
3441         (WebCore::collapseAnonymousTableRowsIfNeeded):
3442         (WebCore::RenderObject::destroyAndCleanupAnonymousWrappers):
3443
3444 2015-10-15  Simon Fraser  <simon.fraser@apple.com>
3445
3446         Un-indent contents of the WebCore namespace
3447         in GraphicsContext.h. No code changes.
3448
3449         * platform/graphics/GraphicsContext.h:
3450
3451 2015-10-14  Simon Fraser  <simon.fraser@apple.com>
3452
3453         Move ImageBuffer:clip() into GraphicsContextCG
3454         https://bugs.webkit.org/show_bug.cgi?id=150140
3455
3456         Reviewed by Zalan Bujtas.
3457
3458         Move the guts of CG's ImageBuffer:clip() into GraphicsContextCG.
3459
3460         * platform/graphics/GraphicsContext.h:
3461         * platform/graphics/cg/GraphicsContextCG.cpp:
3462         (WebCore::GraphicsContext::clipToNativeImage):
3463         * platform/graphics/cg/ImageBufferCG.cpp: