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