Use enum classes and OptionSets for PaintPhase and PaintBehavior
[WebKit-https.git] / Source / WebKitLegacy / mac / ChangeLog
1 2018-08-06  Alex Christensen  <achristensen@webkit.org>
2
3         Use enum classes and OptionSets for PaintPhase and PaintBehavior
4         https://bugs.webkit.org/show_bug.cgi?id=188323
5
6         Reviewed by Simon Fraser.
7
8         * WebCoreSupport/WebContextMenuClient.mm:
9         (WebContextMenuClient::imageForCurrentSharingServicePickerItem):
10         * WebView/WebFrame.mm:
11         (-[WebFrame _paintBehaviorForDestinationContext:]):
12         (-[WebFrame _drawRect:contentsOnly:]):
13         * WebView/WebHTMLView.mm:
14         (imageFromRect):
15         (selectionImage):
16
17 2018-08-05  Yusuke Suzuki  <utatane.tea@gmail.com>
18
19         Add support for microtasks in workers
20         https://bugs.webkit.org/show_bug.cgi?id=188246
21
22         Reviewed by Darin Adler.
23
24         Rename JSMainThreadExecState.h to JSExecState.h.
25
26         * DOM/DOMAttr.mm:
27         * DOM/DOMBlob.mm:
28         * DOM/DOMCDATASection.mm:
29         * DOM/DOMCSSCharsetRule.mm:
30         * DOM/DOMCSSFontFaceRule.mm:
31         * DOM/DOMCSSImportRule.mm:
32         * DOM/DOMCSSMediaRule.mm:
33         * DOM/DOMCSSPageRule.mm:
34         * DOM/DOMCSSPrimitiveValue.mm:
35         * DOM/DOMCSSRule.mm:
36         * DOM/DOMCSSRuleList.mm:
37         * DOM/DOMCSSStyleDeclaration.mm:
38         * DOM/DOMCSSStyleRule.mm:
39         * DOM/DOMCSSStyleSheet.mm:
40         * DOM/DOMCSSUnknownRule.mm:
41         * DOM/DOMCSSValue.mm:
42         * DOM/DOMCSSValueList.mm:
43         * DOM/DOMCharacterData.mm:
44         * DOM/DOMComment.mm:
45         * DOM/DOMCounter.mm:
46         * DOM/DOMDocument.mm:
47         * DOM/DOMDocumentFragment.mm:
48         * DOM/DOMDocumentType.mm:
49         * DOM/DOMElement.mm:
50         * DOM/DOMEvent.mm:
51         * DOM/DOMFile.mm:
52         * DOM/DOMFileList.mm:
53         * DOM/DOMHTML.mm:
54         * DOM/DOMHTMLAnchorElement.mm:
55         * DOM/DOMHTMLAppletElement.mm:
56         * DOM/DOMHTMLAreaElement.mm:
57         * DOM/DOMHTMLBRElement.mm:
58         * DOM/DOMHTMLBaseElement.mm:
59         * DOM/DOMHTMLBaseFontElement.mm:
60         * DOM/DOMHTMLBodyElement.mm:
61         * DOM/DOMHTMLButtonElement.mm:
62         * DOM/DOMHTMLCanvasElement.mm:
63         * DOM/DOMHTMLCollection.mm:
64         * DOM/DOMHTMLDListElement.mm:
65         * DOM/DOMHTMLDirectoryElement.mm:
66         * DOM/DOMHTMLDivElement.mm:
67         * DOM/DOMHTMLDocument.mm:
68         * DOM/DOMHTMLElement.mm:
69         * DOM/DOMHTMLEmbedElement.mm:
70         * DOM/DOMHTMLFieldSetElement.mm:
71         * DOM/DOMHTMLFontElement.mm:
72         * DOM/DOMHTMLFormElement.mm:
73         * DOM/DOMHTMLFrameElement.mm:
74         * DOM/DOMHTMLFrameSetElement.mm:
75         * DOM/DOMHTMLHRElement.mm:
76         * DOM/DOMHTMLHeadElement.mm:
77         * DOM/DOMHTMLHeadingElement.mm:
78         * DOM/DOMHTMLHtmlElement.mm:
79         * DOM/DOMHTMLIFrameElement.mm:
80         * DOM/DOMHTMLImageElement.mm:
81         * DOM/DOMHTMLInputElement.mm:
82         * DOM/DOMHTMLLIElement.mm:
83         * DOM/DOMHTMLLabelElement.mm:
84         * DOM/DOMHTMLLegendElement.mm:
85         * DOM/DOMHTMLLinkElement.mm:
86         * DOM/DOMHTMLMapElement.mm:
87         * DOM/DOMHTMLMarqueeElement.mm:
88         * DOM/DOMHTMLMediaElement.mm:
89         * DOM/DOMHTMLMenuElement.mm:
90         * DOM/DOMHTMLMetaElement.mm:
91         * DOM/DOMHTMLModElement.mm:
92         * DOM/DOMHTMLOListElement.mm:
93         * DOM/DOMHTMLObjectElement.mm:
94         * DOM/DOMHTMLOptGroupElement.mm:
95         * DOM/DOMHTMLOptionElement.mm:
96         * DOM/DOMHTMLOptionsCollection.mm:
97         * DOM/DOMHTMLParagraphElement.mm:
98         * DOM/DOMHTMLParamElement.mm:
99         * DOM/DOMHTMLPreElement.mm:
100         * DOM/DOMHTMLQuoteElement.mm:
101         * DOM/DOMHTMLScriptElement.mm:
102         * DOM/DOMHTMLSelectElement.mm:
103         * DOM/DOMHTMLStyleElement.mm:
104         * DOM/DOMHTMLTableCaptionElement.mm:
105         * DOM/DOMHTMLTableCellElement.mm:
106         * DOM/DOMHTMLTableColElement.mm:
107         * DOM/DOMHTMLTableElement.mm:
108         * DOM/DOMHTMLTableRowElement.mm:
109         * DOM/DOMHTMLTableSectionElement.mm:
110         * DOM/DOMHTMLTextAreaElement.mm:
111         * DOM/DOMHTMLTitleElement.mm:
112         * DOM/DOMHTMLUListElement.mm:
113         * DOM/DOMHTMLVideoElement.mm:
114         * DOM/DOMImplementation.mm:
115         * DOM/DOMKeyboardEvent.mm:
116         * DOM/DOMMediaError.mm:
117         * DOM/DOMMediaList.mm:
118         * DOM/DOMMouseEvent.mm:
119         * DOM/DOMMutationEvent.mm:
120         * DOM/DOMNamedNodeMap.mm:
121         * DOM/DOMNode.mm:
122         * DOM/DOMNodeIterator.mm:
123         * DOM/DOMNodeList.mm:
124         * DOM/DOMOverflowEvent.mm:
125         * DOM/DOMProcessingInstruction.mm:
126         * DOM/DOMProgressEvent.mm:
127         * DOM/DOMRGBColor.mm:
128         * DOM/DOMRange.mm:
129         * DOM/DOMRect.mm:
130         * DOM/DOMStyleSheet.mm:
131         * DOM/DOMStyleSheetList.mm:
132         * DOM/DOMText.mm:
133         * DOM/DOMTextEvent.mm:
134         * DOM/DOMTimeRanges.mm:
135         * DOM/DOMTokenList.mm:
136         * DOM/DOMTreeWalker.mm:
137         * DOM/DOMUIEvent.mm:
138         * DOM/DOMWheelEvent.mm:
139         * DOM/DOMXPathExpression.mm:
140         * DOM/DOMXPathResult.mm:
141         * DOM/ObjCEventListener.mm:
142
143 2018-08-03  Alex Christensen  <achristensen@webkit.org>
144
145         Fix spelling of "overridden"
146         https://bugs.webkit.org/show_bug.cgi?id=188315
147
148         Reviewed by Darin Adler.
149
150         * Misc/WebKitVersionChecks.mm:
151         (setWebKitLinkTimeVersion):
152         (WebKitLinkTimeVersion):
153         * Plugins/WebBaseNetscapePluginView.mm:
154         (-[WebBaseNetscapePluginView handleMouseMoved:]):
155         * WebCoreSupport/PopupMenuMac.mm:
156         (PopupMenuMac::populate):
157
158 2018-08-01  Nan Wang  <n_wang@apple.com>
159
160         AX: AOM: Add ARIA IDL Attribute Reflection
161         https://bugs.webkit.org/show_bug.cgi?id=184676
162         <rdar://problem/39476882>
163
164         Reviewed by Chris Fleizach.
165
166         * WebView/WebPreferenceKeysPrivate.h:
167         * WebView/WebPreferences.mm:
168         (+[WebPreferences initialize]):
169         (-[WebPreferences ariaReflectionEnabled]):
170         (-[WebPreferences setAriaReflectionEnabled:]):
171         * WebView/WebPreferencesPrivate.h:
172         * WebView/WebView.mm:
173         (-[WebView _preferencesChanged:]):
174
175 2018-07-30  Simon Fraser  <simon.fraser@apple.com>
176
177         Shrink GraphicsLayerCA
178         https://bugs.webkit.org/show_bug.cgi?id=188141
179
180         Reviewed by Zalan Bujtas.
181
182         Shrink GraphicsLayerCA from 1040 to 880 bytes by:
183         * moving all the clone-related stuff into the lazily-allocated m_layerClones
184         * moving all the animation-related stuff into the lazily-allocated m_animations
185         * making enums be 8-bit
186         * re-ordering data members
187
188         * WebView/WebView.mm:
189         (-[WebView _setMediaLayer:forPluginView:]):
190
191 2018-07-30  Rob Buis  <rbuis@igalia.com>
192
193         Merge PlatformCookieJar functions into NetworkStorageSession
194         https://bugs.webkit.org/show_bug.cgi?id=188137
195
196         Adapt callsites to use NetworkStorageSession instead of CookieJar functions.
197
198         Reviewed by Alex Christensen.
199
200         * WebCoreSupport/WebPlatformStrategies.mm:
201         (WebPlatformStrategies::cookiesForDOM):
202         (WebPlatformStrategies::setCookiesFromDOM):
203         (WebPlatformStrategies::cookiesEnabled):
204         (WebPlatformStrategies::cookieRequestHeaderFieldValue):
205         (WebPlatformStrategies::getRawCookies):
206         (WebPlatformStrategies::deleteCookie):
207         * WebView/WebPreferences.mm:
208         (+[WebPreferences _clearNetworkLoaderSession]):
209
210 2018-07-28  Darin Adler  <darin@apple.com>
211
212         [Cocoa] Update more WebCore Objective-C code to be ARC compatible
213         https://bugs.webkit.org/show_bug.cgi?id=188140
214
215         Reviewed by Sam Weinig.
216
217         * WebView/WebImmediateActionController.mm:
218         (-[WebImmediateActionController _animationControllerForText]): Updated to use the
219         new DictionaryLookup function that returns a tuple instead of using an out argument.
220
221 2018-07-26  Andy VanWagoner  <andy@vanwagoner.family>
222
223         [INTL] Remove INTL sub-feature compile flags
224         https://bugs.webkit.org/show_bug.cgi?id=188081
225
226         Reviewed by Michael Catanzaro.
227
228         * Configurations/FeatureDefines.xcconfig:
229
230 2018-07-26  Commit Queue  <commit-queue@webkit.org>
231
232         Unreviewed, rolling out r234181 and r234189.
233         https://bugs.webkit.org/show_bug.cgi?id=188075
234
235         These are not needed right now (Requested by thorton on
236         #webkit).
237
238         Reverted changesets:
239
240         "Enable Web Content Filtering on watchOS"
241         https://bugs.webkit.org/show_bug.cgi?id=187979
242         https://trac.webkit.org/changeset/234181
243
244         "HAVE(PARENTAL_CONTROLS) should be true on watchOS"
245         https://bugs.webkit.org/show_bug.cgi?id=187985
246         https://trac.webkit.org/changeset/234189
247
248 2018-07-26  Timothy Hatcher  <timothy@apple.com>
249
250         Use the Page's appearance when converting pasteboard attributed strings.
251         https://bugs.webkit.org/show_bug.cgi?id=188067
252         rdar://problem/42632246
253
254         Reviewed by Wenson Hsieh.
255
256         * WebCoreSupport/WebEditorClient.mm:
257         (_WebCreateFragment): Create a LocalDefaultSystemAppearance based on the Page.
258
259 2018-07-25  Chris Dumez  <cdumez@apple.com>
260
261         navigator.userAgent may return outdated value after webView.customUserAgent is set
262         https://bugs.webkit.org/show_bug.cgi?id=188009
263         <rdar://problem/42566456>
264
265         Reviewed by Alex Christensen.
266
267         Let the page know when the user agent changes.
268
269         * WebView/WebView.mm:
270         (-[WebView _preferencesChanged:]):
271         (-[WebView setApplicationNameForUserAgent:]):
272         (-[WebView _invalidateUserAgentCache]):
273         (-[WebView setCustomUserAgent:]):
274         * WebView/WebViewInternal.h:
275
276 2018-07-24  Tim Horton  <timothy_horton@apple.com>
277
278         Enable Web Content Filtering on watchOS
279         https://bugs.webkit.org/show_bug.cgi?id=187979
280         <rdar://problem/42559346>
281
282         Reviewed by Wenson Hsieh.
283
284         * Configurations/FeatureDefines.xcconfig:
285
286 2018-07-20  Ryosuke Niwa  <rniwa@apple.com>
287
288         Picking a color from the color panel for typing attributes needs to inverse transform through color-filter
289         https://bugs.webkit.org/show_bug.cgi?id=187846
290
291         Reviewed by Simon Fraser.
292
293         Invert the filtered font and background colors when using font panels, font pasteboard, and other Objective-C APIs.
294
295         * WebView/WebHTMLView.mm:
296         (-[WebHTMLView _applyStyleToSelection:withUndoAction:]): Share code with _applyEditingStyleToSelection.
297         (-[WebHTMLView _applyEditingStyleToSelection:withUndoAction:]):
298
299 2018-07-11  Dean Jackson  <dino@apple.com>
300
301         Allow removal of white backgrounds
302         https://bugs.webkit.org/show_bug.cgi?id=187574
303         <rdar://problem/41146792>
304
305         Reviewed by Simon Fraser.
306
307         Add a new WebPreference for punching out white backgrounds.
308
309         * WebView/WebPreferenceKeysPrivate.h:
310         * WebView/WebPreferences.mm:
311         (+[WebPreferences initialize]):
312         (-[WebPreferences punchOutWhiteBackgroundsInDarkMode]):
313         (-[WebPreferences setPunchOutWhiteBackgroundsInDarkMode:]):
314         * WebView/WebPreferencesPrivate.h:
315         * WebView/WebView.mm:
316         (-[WebView _preferencesChanged:]):
317
318 2018-07-14  Kocsen Chung  <kocsen_chung@apple.com>
319
320         Ensure WebKit stack is ad-hoc signed
321         https://bugs.webkit.org/show_bug.cgi?id=187667
322
323         Reviewed by Alexey Proskuryakov.
324
325         * Configurations/Base.xcconfig:
326
327 2018-07-11  Aditya Keerthi  <akeerthi@apple.com>
328
329         REGRESSION (231276): Attempting to copy an image fails
330         https://bugs.webkit.org/show_bug.cgi?id=187212
331         <rdar://problem/41540074>
332
333         Reviewed by Ryosuke Niwa.
334
335         Renamed methods to make it clear that one URL and one title are being passed in.
336
337         * WebCoreSupport/WebPlatformStrategies.h:
338         * WebCoreSupport/WebPlatformStrategies.mm:
339         (WebPlatformStrategies::setURL):
340
341 2018-07-10  Ryosuke Niwa  <rniwa@webkit.org>
342
343         Disable cross-origin-window-policy by default
344         https://bugs.webkit.org/show_bug.cgi?id=187509
345
346         Reviewed by Chris Dumez.
347
348         * WebView/WebPreferences.mm:
349         (+[WebPreferences initialize]):
350
351 2018-07-09  Timothy Hatcher  <timothy@apple.com>
352
353         Semantic colors don't update when accessibility Increase Contrast mode is enabled.
354         https://bugs.webkit.org/show_bug.cgi?id=187425
355         rdar://problem/39948240
356
357         Reviewed by Tim Horton.
358
359         * WebView/WebView.mm:
360         (-[WebView _commonInitializationWithFrameName:groupName:]): Removed call to
361         _updateDefaultAppearance, which called setUseDarkAppearance. There is already
362         a call in this method to setUseDarkAppearance.
363         (-[WebView _setUseSystemAppearance:]): Just call the page, not setUseDarkAppearance.
364         (-[WebView viewDidChangeEffectiveAppearance]): Added. This is the proper NSView method to use.
365         (-[WebView _updateDefaultAppearance]): Deleted.
366         (-[WebView effectiveAppearanceDidChange]): Deleted. This method is a deprecated name.
367
368 2018-07-09  Simon Fraser  <simon.fraser@apple.com>
369
370         Shrink various loading-related enums to shrink CachedResource
371         https://bugs.webkit.org/show_bug.cgi?id=187443
372
373         Reviewed by Chris Dumez.
374
375         * WebCoreSupport/WebFrameLoaderClient.mm:
376         (WebFrameLoaderClient::convertMainResourceLoadToDownload):
377         (WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
378         (WebFrameLoaderClient::assignIdentifierToInitialRequest):
379         (WebFrameLoaderClient::dispatchWillSendRequest):
380         (WebFrameLoaderClient::dispatchDecidePolicyForResponse):
381         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
382         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
383         (WebFrameLoaderClient::updateGlobalHistory):
384         (WebFrameLoaderClient::canHandleRequest const):
385         * WebView/WebDataSource.mm:
386         (-[WebDataSource initialRequest]):
387         (-[WebDataSource request]):
388
389 2018-07-09  Commit Queue  <commit-queue@webkit.org>
390
391         Unreviewed, rolling out r233612.
392         https://bugs.webkit.org/show_bug.cgi?id=187475
393
394         Revision caused the api test LinkColorWithSystemAppearance to
395         fail on all systems. (Requested by Truitt on #webkit).
396
397         Reverted changeset:
398
399         "Semantic colors don't update when accessibility Increase
400         Contrast mode is enabled."
401         https://bugs.webkit.org/show_bug.cgi?id=187425
402         https://trac.webkit.org/changeset/233612
403
404 2018-07-06  Timothy Hatcher  <timothy@apple.com>
405
406         Semantic colors don't update when accessibility Increase Contrast mode is enabled.
407         https://bugs.webkit.org/show_bug.cgi?id=187425
408         rdar://problem/39948240
409
410         Reviewed by Tim Horton.
411
412         * WebView/WebView.mm:
413         (-[WebView _commonInitializationWithFrameName:groupName:]): Removed call to
414         _updateDefaultAppearance, which called setUseDarkAppearance. There is already
415         a call in this method to setUseDarkAppearance.
416         (-[WebView _setUseSystemAppearance:]): Just call the page, not setUseDarkAppearance.
417         (-[WebView viewDidChangeEffectiveAppearance]): Added. This is the proper NSView method to use.
418         (-[WebView _updateDefaultAppearance]): Deleted.
419         (-[WebView effectiveAppearanceDidChange]): Deleted. This method is a deprecated name.
420
421 2018-07-05  Timothy Hatcher  <timothy@apple.com>
422
423         Rename and flip the meaning of defaultAppearance to be useDarkAppearance.
424         https://bugs.webkit.org/show_bug.cgi?id=187369
425         rdar://problem/41870420
426
427         Reviewed by Tim Horton.
428
429         * WebView/WebMediaPlaybackTargetPicker.mm:
430         (WebMediaPlaybackTargetPicker::showPlaybackTargetPicker):
431         * WebView/WebView.mm:
432         (-[WebView _commonInitializationWithFrameName:groupName:]):
433         (-[WebView _effectiveAppearanceIsDark]):
434         (-[WebView _updateDefaultAppearance]):
435         (-[WebView _defaultAppearance]): Deleted.
436
437 2018-07-04  Ryosuke Niwa  <rniwa@webkit.org>
438
439         Youtube video pages crash after a couple of minutes
440         https://bugs.webkit.org/show_bug.cgi?id=187316
441
442         Reviewed by Antti Koivisto.
443
444         * WebView/WebView.mm:
445         (-[WebView _preferencesChanged:]):
446
447 2018-07-04  Tim Horton  <timothy_horton@apple.com>
448
449         Introduce PLATFORM(IOSMAC)
450         https://bugs.webkit.org/show_bug.cgi?id=187315
451
452         Reviewed by Dan Bernstein.
453
454         * Configurations/Base.xcconfig:
455         * Configurations/FeatureDefines.xcconfig:
456
457 2018-06-28  Wenson Hsieh  <wenson_hsieh@apple.com>
458
459         [iOS] DataTransfer.getData always returns the empty string when dropping text
460         https://bugs.webkit.org/show_bug.cgi?id=187130
461         <rdar://problem/41014117>
462
463         Reviewed by Ryosuke Niwa.
464
465         Add plumbing to grab information for each item in the pasteboard. See WebCore ChangeLog for more detail.
466
467         * WebCoreSupport/WebPlatformStrategies.h:
468         * WebCoreSupport/WebPlatformStrategies.mm:
469         (WebPlatformStrategies::allPasteboardItemInfo):
470
471 2018-06-26  Eric Carlson  <eric.carlson@apple.com>
472
473         [Mac] AirPlay picker uses incorrect theme in Dark mode
474         https://bugs.webkit.org/show_bug.cgi?id=187054
475         <rdar://problem/41291093>
476
477         Reviewed by Timothy Hatcher.
478
479         * WebView/WebMediaPlaybackTargetPicker.mm:
480         (WebMediaPlaybackTargetPicker::showPlaybackTargetPicker): Pass page->defaultAppearance().
481
482 2018-06-23  Yusuke Suzuki  <utatane.tea@gmail.com>
483
484         [WTF] Add user-defined literal for ASCIILiteral
485         https://bugs.webkit.org/show_bug.cgi?id=186839
486
487         Reviewed by Darin Adler.
488
489         * DOM/ExceptionHandlers.mm:
490         (raiseDOMErrorException):
491         * Plugins/Hosted/ProxyInstance.mm:
492         (WebKit::ProxyInstance::invokeMethod):
493         * Storage/WebDatabaseProvider.mm:
494         (WebDatabaseProvider::indexedDatabaseDirectoryPath):
495
496 2018-06-22  Timothy Hatcher  <timothy@apple.com>
497
498         Recalc styles every time defaultAppearance changes.
499         https://bugs.webkit.org/show_bug.cgi?id=186866
500         rdar://problem/41309805
501
502         Reviewed by Tim Horton.
503
504         * WebView/WebView.mm:
505         (-[WebView _updateDefaultAppearance]):
506         (-[WebView _setUseSystemAppearance:]):
507         (-[WebView _useSystemAppearance]):
508
509 2018-06-20  Darin Adler  <darin@apple.com>
510
511         [Cocoa] Use the isDirectory: variants of NSURL methods more to eliminate unnecessary file system activity
512         https://bugs.webkit.org/show_bug.cgi?id=186875
513
514         Reviewed by Anders Carlsson.
515
516         * WebView/WebHTMLView.mm:
517         (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]): Use isDirectory:NO for the URL of the location
518         to write te file to.
519         * WebView/WebPreferences.mm:
520         (-[WebPreferences userStyleSheetLocation]): Use isDirectory:NO to create a URL for the user style sheet.
521         * WebView/WebView.mm:
522         (-[WebView setMainFrameURL:]): Use isDirectory:NO to create a URL for a local webpage to load.
523
524 2018-06-12  Darin Adler  <darin@apple.com>
525
526         [Cocoa] Make some RetainPtr refinements to get more ready for ARC
527         https://bugs.webkit.org/show_bug.cgi?id=186526
528
529         Reviewed by Anders Carlsson.
530
531         * Plugins/Hosted/NetscapePluginHostManager.mm:
532         (WebKit::preferredBundleLocalizationName): Use bridgingAutorelease.
533
534         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
535         (-[WebHostedNetscapePluginView createPluginLayer]): Use move
536         assignment rather than adoptNS/leakRef.
537         * Plugins/WebNetscapePluginView.mm:
538         (-[WebNetscapePluginView createPlugin]): Ditto.
539
540         * WebCoreSupport/WebContextMenuClient.mm:
541         (WebContextMenuClient::contextMenuForEvent): Get rid of unnecessary use of
542         RetainPtr::autorelease; no need to autorelease just to pass something as a function
543         argument, so use RetainPtr::get instead.
544
545         * WebView/WebHTMLView.mm:
546         (customMenuFromDefaultItems): Get rid of of unnecessary use of RetainPtr::autorelease.
547         No need to autorelease the result when the return type is RetainPtr.
548
549         * WebView/WebPDFRepresentation.mm:
550         (-[WebPDFRepresentation convertPostScriptDataSourceToPDF:]): Use bridgingAutorelease.
551
552 2018-06-13  Youenn Fablet  <youenn@apple.com>
553
554         Supported plugin check should be based on plugin identifier
555         https://bugs.webkit.org/show_bug.cgi?id=186578
556         <rdar://problem/40523828>
557
558         Reviewed by Darin Adler.
559
560         * WebCoreSupport/WebPluginInfoProvider.h:
561         * WebCoreSupport/WebPluginInfoProvider.mm:
562         (WebPluginInfoProvider::pluginInfo):
563         (WebPluginInfoProvider::webVisiblePluginInfo):
564
565 2018-06-13  Chris Dumez  <cdumez@apple.com>
566
567         PSON: http/tests/resourceLoadStatistics/classify-as-prevalent-based-on-top-frame-redirect-collusion.html ASSERTS with process swap enabled
568         https://bugs.webkit.org/show_bug.cgi?id=186545
569
570         Reviewed by Brady Eidson.
571
572         Update client delegate now that parameter type has changed.
573
574         * WebCoreSupport/WebFrameLoaderClient.h:
575         * WebCoreSupport/WebFrameLoaderClient.mm:
576         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
577
578 2018-06-11  Tim Horton  <timothy_horton@apple.com>
579
580         Link drag image is inconsistently unreadable in dark mode
581         https://bugs.webkit.org/show_bug.cgi?id=186472
582
583         Reviewed by Timothy Hatcher.
584
585         * WebView/WebView.mm:
586         (-[WebView _defaultAppearance]):
587         Make defaultAppearance accurate even if useSystemAppearance is false.
588         Some parts of WebKit (like the link drag image, but also context menus)
589         want to be able to follow the system appearance regardless of whether
590         the view or content has opted in.
591
592 2018-06-11  Chris Dumez  <cdumez@apple.com>
593
594         http/tests/security/cors-post-redirect-307.html fails with PSON enabled
595         https://bugs.webkit.org/show_bug.cgi?id=186441
596
597         Reviewed by Brady Eidson.
598
599         Rename existing flag to something a bit more generic, now that it is used for
600         more things than bypassing the navigation policy check.
601
602         * WebView/WebView.mm:
603         (-[WebView _loadBackForwardListFromOtherView:]):
604         (-[WebView goToBackForwardItem:]):
605
606 2018-06-09  Dan Bernstein  <mitz@apple.com>
607
608         [Xcode] Clean up and modernize some build setting definitions
609         https://bugs.webkit.org/show_bug.cgi?id=186463
610
611         Reviewed by Sam Weinig.
612
613         * Configurations/Base.xcconfig: Removed definition for macOS 10.11.
614         * Configurations/DebugRelease.xcconfig: Ditto.
615         * Configurations/FeatureDefines.xcconfig: Simplified the definitions of ENABLE_APPLE_PAY and
616           ENABLE_VIDEO_PRESENTATION_MODE now macOS 10.12 is the earliest supported version.
617         * Configurations/Version.xcconfig: Removed definition for macOS 10.11.
618         * Configurations/WebKitLegacy.xcconfig: Simplified the definition of WK_PRIVATE_FRAMEWORKS_DIR
619           now that WK_XCODE_SUPPORTS_TEXT_BASED_STUBS is true for all supported Xcode versions.
620         * Configurations/WebKitTargetConditionals.xcconfig: Removed definitions for macOS 10.11.
621
622 2018-06-08  Darin Adler  <darin@apple.com>
623
624         [Cocoa] Remove all uses of NSAutoreleasePool as part of preparation for ARC
625         https://bugs.webkit.org/show_bug.cgi?id=186436
626
627         Reviewed by Anders Carlsson.
628
629         * Carbon/CarbonUtils.m: Updated include location of FoundationSPI.h.
630         (getNSAutoreleasePoolCount): Use objc_autoreleasePoolPush/Pop.
631         (WebInitForCarbon): Use objc_autoreleasePoolPush/Pop instead of NSAutoreleasePool object.
632         (PoolCleaner): Ditto.
633
634         * History/WebHistory.mm:
635         (-[WebHistoryPrivate loadHistoryGutsFromURL:savedItemsCount:collectDiscardedItemsInto:error:]):
636         Use @autoreleasepool instead of NSAutoreleasePool object. No need to do the "drain pool only
637         every 50 times"; the -[WebHistory loadFromURL] family of methods were once used by Safari, and
638         now hardly used if at all.
639         * WebView/WebView.mm:
640         (-[WebView rectsForTextMatches]): Ditto.
641
642 2018-06-08  Wenson Hsieh  <wenson_hsieh@apple.com>
643
644         [WebKit on watchOS] Upstream watchOS source additions to OpenSource (Part 1)
645         https://bugs.webkit.org/show_bug.cgi?id=186442
646         <rdar://problem/40879364>
647
648         Reviewed by Tim Horton.
649
650         * Configurations/FeatureDefines.xcconfig:
651
652 2018-06-08  Aditya Keerthi  <akeerthi@apple.com>
653
654         [Datalist] Allow TextFieldInputType to show and hide suggestions
655         https://bugs.webkit.org/show_bug.cgi?id=186151
656
657         Reviewed by Tim Horton.
658
659         * WebCoreSupport/WebChromeClient.h:
660         * WebCoreSupport/WebChromeClient.mm:
661         (WebChromeClient::createDataListSuggestionPicker):
662
663 2018-06-07  Chris Dumez  <cdumez@apple.com>
664
665         Add base class to get WeakPtrFactory member and avoid some boilerplate code
666         https://bugs.webkit.org/show_bug.cgi?id=186407
667
668         Reviewed by Brent Fulgham.
669
670         Add CanMakeWeakPtr base class to get WeakPtrFactory member and its getter, in
671         order to avoid some boilerplate code in every class needing a WeakPtrFactory.
672         This also gets rid of old-style createWeakPtr() methods in favor of the newer
673         makeWeakPtr().
674
675         * WebCoreSupport/WebEditorClient.h:
676         * WebCoreSupport/WebEditorClient.mm:
677         (WebEditorClient::requestCandidatesForSelection):
678
679 2018-06-05  Chris Dumez  <cdumez@apple.com>
680
681         Regression(r232082): Websites get loaded inside of Messages App chat transcript
682         https://bugs.webkit.org/show_bug.cgi?id=186331
683         <rdar://problem/40735446>
684
685         Reviewed by Darin Adler.
686
687         r232082 made it so that if the client implements decidePolicyForMIMEType / decidePolicyForNavigationAction
688         but does not call use / ignore on the listener, then we would do "use" by default.
689         The intention was to restore pre-AsyncPolicyDelegates behavior and unbreak Box.app. However,
690         the pre-AsyncPolicyDelegates behavior was only to "use" by default for decidePolicyForMIMEType,
691         not decidePolicyForNavigationAction. Doing "use" by default for decidePolicyForNavigationAction
692         is new behavior and it breaks Messages.app. This patch updates r232082 so that we now do call
693         "use" by default on the listener for decidePolicyForMIMEType and "ignore" by default for other
694         policy decisions. This should restore pre-AsyncPolicyDelegates behavior. This fixes Messages.app
695         and Box.app is still working properly.
696
697         * WebCoreSupport/WebFrameLoaderClient.h:
698         * WebCoreSupport/WebFrameLoaderClient.mm:
699         (WebFrameLoaderClient::dispatchDecidePolicyForResponse):
700         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
701         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
702         (WebFrameLoaderClient::dispatchWillSubmitForm):
703         (WebFrameLoaderClient::setUpPolicyListener):
704         (-[WebFramePolicyListener initWithFrame:policyFunction:defaultPolicy:]):
705         (-[WebFramePolicyListener initWithFrame:policyFunction:defaultPolicy:appLinkURL:]):
706         (-[WebFramePolicyListener dealloc]):
707         (-[WebFramePolicyListener initWithFrame:policyFunction:]): Deleted.
708         (-[WebFramePolicyListener initWithFrame:policyFunction:appLinkURL:]): Deleted.
709
710 2018-06-05  Brent Fulgham  <bfulgham@apple.com>
711
712         Adjust compile and runtime flags to match shippable state of features
713         https://bugs.webkit.org/show_bug.cgi?id=186319
714         <rdar://problem/40352045>
715
716         Reviewed by Maciej Stachowiak, Jon Lee, and others.
717
718         * Configurations/DebugRelease.xcconfig: Don't build ENABLE_INPUT_TYPE_COLOR
719         or ENABLE_INPUT_TYPE_COLOR_POPOVER.
720         * Configurations/FeatureDefines.xcconfig: Update to match WebKit definition of
721         WK_RELOCATABLE_FRAMEWORKS so that ENABLE(EXPERIMENTAL_FEATURES) is defined properly for
722         Cocoa builds.
723
724 2018-06-05  Timothy Hatcher  <timothy@apple.com>
725
726         Clean up LocalDefaultSystemAppearance and prefers-dark-interface media query
727
728         https://bugs.webkit.org/show_bug.cgi?id=186323
729         rdar://problem/38382252
730
731         Reviewed by Tim Horton.
732
733         * WebView/WebView.mm:
734         (-[WebView _defaultAppearance]):
735
736 2018-06-05  Brent Fulgham  <bfulgham@apple.com>
737
738         Revise DEFAULT_EXPERIMENTAL_FEATURES_ENABLED to work properly on Apple builds
739         https://bugs.webkit.org/show_bug.cgi?id=186286
740         <rdar://problem/40782992>
741
742         Reviewed by Dan Bernstein.
743
744         Use the WK_RELOCATABLE_FRAMEWORKS flag (which is always defined for non-production builds)
745         to define ENABLE(EXPERIMENTAL_FEATURES) so that we do not need to manually
746         change this flag when preparing for a production release.
747
748         * Configurations/FeatureDefines.xcconfig: Use WK_RELOCATABLE_FRAMEWORKS to determine
749         whether experimental features should be enabled, and use it to properly define the
750         feature flag.
751
752 2018-06-03  Darin Adler  <darin@apple.com>
753
754         Simplify and remove some unused video element code (helpful for ARC-compatibility)
755         https://bugs.webkit.org/show_bug.cgi?id=186258
756
757         Reviewed by Daniel Bates.
758
759         * WebView/WebVideoFullscreenController.h: Removed some unneeded includes and
760         forward declarations. Removed methods that don't need to be public.
761
762         * WebView/WebVideoFullscreenController.mm: Added additional includes. Removed
763         #if COMPILER(CLANG) since that's all we use on Mac. Moved fields into an
764         unnamed category in here and also replaced the HUDWindowControllerDelegate
765         with the unnamed category. Removed unused NSWindow category defining the
766         isOnActiveSpace, which is not called anywhere in this file at this time.
767         (-[WebVideoFullscreenController setupVideoOverlay:]): Deleted. Moved the code
768         into setVideoElement.
769         (-[WebVideoFullscreenController windowDidLoad]): Slightly rearranged the code
770         and removed unneeded typecast.
771         (-[WebVideoFullscreenController videoElement]): Updated to not rely on a
772         using statement at the top of the file.
773         (-[WebVideoFullscreenController setVideoElement:]): Added a comment about
774         the many side effects and special considerations that this method that sounds
775         like a setter has. Updated code to use the new
776         MediaPlayer::objCAVFoundationAVPlayer function instead of the old
777         HTMLVideoElement::platformMedia function. Also straightened out the logic a
778         bit and added some FIXME comments about small problems noticed but not fixed.
779         (-[WebVideoFullscreenController delegate]): Deleted. Was never called.
780         (-[WebVideoFullscreenController setDelegate:]): Deleted. Was never called.
781         (-[WebVideoFullscreenController windowDidExitFullscreen]): Removed unneeded
782         typecast. Removed call to updatePowerAssertions method.
783         (-[WebVideoFullscreenController windowDidEnterFullscreen]): Removed call to
784         updatePowerAssertions method.
785         (-[WebVideoFullscreenController updatePowerAssertions]): Deleted. This method
786         set _displaySleepEnabler to nullptr, but nothing was ever setting it to anything
787         else, so this was dead code that did nothing.
788         (-[WebVideoFullscreenController rateChanged:]): Removed call to
789         updatePowerAssertions method.
790
791 2018-06-04  Chris Dumez  <cdumez@apple.com>
792
793         Rename "Cross-Origin-Options" HTTP header to "Cross-Origin-Window-Policy"
794         https://bugs.webkit.org/show_bug.cgi?id=186287
795         <rdar://problem/40783352>
796
797         Reviewed by Youenn Fablet.
798
799         * WebView/WebPreferenceKeysPrivate.h:
800         * WebView/WebPreferences.mm:
801         (+[WebPreferences initialize]):
802         (-[WebPreferences crossOriginWindowPolicySupportEnabled]):
803         (-[WebPreferences setCrossOriginWindowPolicySupportEnabled:]):
804         * WebView/WebPreferencesPrivate.h:
805         * WebView/WebView.mm:
806         (-[WebView _preferencesChanged:]):
807
808 2018-06-02  Darin Adler  <darin@apple.com>
809
810         [Cocoa] Update some code to be more ARC-compatible to prepare for future ARC adoption
811         https://bugs.webkit.org/show_bug.cgi?id=186227
812
813         Reviewed by Dan Bernstein.
814
815         * Misc/WebKitErrors.m:
816         (+[NSError _registerWebKitErrors]): Use @autoreleasepool instead of NSAutoreleasePool.
817         * Plugins/WebPluginDatabase.mm:
818         (-[WebPluginDatabase refresh]): Ditto.
819         * WebCoreSupport/WebChromeClient.mm:
820         (WebChromeClient::setStatusbarText): Ditto.
821
822 2018-06-01  Chris Dumez  <cdumez@apple.com>
823
824         REGRESSION (r231456): Colloquy is broken
825         https://bugs.webkit.org/show_bug.cgi?id=186197
826         <rdar://problem/40722960>
827
828         Reviewed by Timothy Hatcher.
829
830         Restore pre-r231456 behavior for Colloquy app so that it works again.
831
832         * WebView/WebView.mm:
833         (-[WebView _needsFrameNameFallbackToIdQuirk]):
834         (-[WebView _preferencesChanged:]):
835
836 2018-05-30  Yusuke Suzuki  <utatane.tea@gmail.com>
837
838         [JSC] Pass VM& parameter as much as possible
839         https://bugs.webkit.org/show_bug.cgi?id=186085
840
841         Reviewed by Saam Barati.
842
843         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
844         (WebKit::NetscapePluginInstanceProxy::invoke):
845
846 2018-05-30  Daniel Bates  <dabates@apple.com>
847
848         NavigationAction does not need to hold initiating DOM Event
849         https://bugs.webkit.org/show_bug.cgi?id=185958
850         <rdar://problem/40531539>
851
852         Reviewed by Simon Fraser.
853
854         Write in terms of NavigationAction::{keyStateEventData, mouseEventDataForFirstMouseEvent}().
855
856         * WebCoreSupport/WebFrameLoaderClient.mm:
857         (WebFrameLoaderClient::actionDictionary const):
858         (findMouseEvent): Deleted.
859
860 2018-05-27  Dan Bernstein  <mitz@apple.com>
861
862         Reverted the changes made for https://webkit.org/b/186016
863
864         They broke the USE(APPLE_INTERNAL_SDK) Sierra build.
865
866
867 2018-05-27  David Kilzer  <ddkilzer@apple.com>
868
869         [iOS] Fix warnings about leaks found by clang static analyzer
870         <https://webkit.org/b/186009>
871         <rdar://problem/40574267>
872
873         Reviewed by Daniel Bates.
874
875         * WebView/WebHTMLView.mm:
876         (-[WebHTMLView doCommandBySelector:]): Fix use of an
877         uninitialized boolean variable (`eventWasHandled`) that only
878         happened on iOS.
879
880 2018-05-27  Dan Bernstein  <mitz@apple.com>
881
882         [Cocoa] Avoid importing directly from subumbrella frameworks
883         https://bugs.webkit.org/show_bug.cgi?id=186016
884
885         Reviewed by Sam Weinig.
886
887         * Carbon/CarbonWindowAdapter.h: Import Carbon.h instead of HIToolbox headers.
888         * Carbon/CarbonWindowAdapter.mm: Ditto.
889         * Carbon/CarbonWindowFrame.m: Ditto.
890         * Carbon/HIViewAdapter.h: Ditto.
891         * Configurations/WebKitLegacy.xcconfig: Removed -iframework options from OTHER_CFLAGS and
892           OTHER_CPLUSPLUSFLAGS.
893         * Plugins/WebNetscapePluginEventHandlerCarbon.mm: Import Carbon.h instead of CarbonEvents.h.
894         * WebView/WebPDFDocumentExtras.mm: Import Quartz.h instead of a PDFKit header.
895         * WebView/WebPDFView.h: Ditto.
896
897 2018-05-27  Sam Weinig  <sam@webkit.org>
898
899         Modernize RenderStyleConstants.h - Part 3
900         https://bugs.webkit.org/show_bug.cgi?id=186015
901
902         Reviewed by Yusuke Suzuki.
903
904         * WebView/WebView.mm:
905         (-[WebView updateTextTouchBar]):
906         Update for new enum name.
907
908 2018-05-25  Chris Dumez  <cdumez@apple.com>
909
910         Minor ApplicationCacheStorage clean up
911         https://bugs.webkit.org/show_bug.cgi?id=185984
912
913         Reviewed by Youenn Fablet.
914
915         * WebCoreSupport/WebApplicationCache.mm:
916         (+[WebApplicationCache originsWithCache]):
917
918 2018-05-25  David Kilzer  <ddkilzer@apple.com>
919
920         Fix issues with -dealloc methods found by clang static analyzer
921         <https://webkit.org/b/185887>
922
923         Reviewed by Joseph Pecoraro.
924
925         * WebView/WebView.mm:
926         (-[WebUITextIndicatorData dealloc]):
927         - Move method implementation from (WebUITextIndicatorInternal)
928           category to the main category since this is public API.  This
929           fixes the false positive warning about a missing -dealloc
930           method.
931
932 2018-05-24  Sam Weinig  <sam@webkit.org>
933
934         Modernize RenderStyleConstants.h - Part 2
935         https://bugs.webkit.org/show_bug.cgi?id=185901
936
937         Reviewed by Simon Fraser.
938
939         * WebView/WebHTMLRepresentation.mm:
940         (searchForLabelsBeforeElement):
941         * WebView/WebView.mm:
942         (nsTextAlignmentFromRenderStyle):
943         Update for new enum names.
944
945 2018-05-22  Chris Dumez  <cdumez@apple.com>
946
947         Regression(AsyncPolicyDelegates): Box.app login Window is blank
948         https://bugs.webkit.org/show_bug.cgi?id=185832
949         <rdar://problem/40307871>
950
951         Reviewed by Geoffrey Garen.
952
953         We used to have a bug where where we would fail to wait for the policy decision for
954         the navigation response from the client and the load would keep going, racing with
955         the client's policy decision. If the client did not respond in time, the behavior
956         would be the same as "Use" policy action.
957
958         Box.app fails to make any policy decision in its decidePolicyForMIMEType delegate
959         but the load happened to proceed anyway due to our bug. Now that we've fixed the
960         WebKit bug, however, the load would hang because the completion handler for the
961         decidePolicyForNavigationResponse would never get called.
962
963         To work around the issue, I made the policy listener weak on the WebFrameLoaderClient
964         instead of retaining it. If the policy listener object gets destroyed because getting
965         resolved, we now use "Use" policy action in its dealloc function to maintain previous
966         behavior.
967
968         * WebCoreSupport/WebFrameLoaderClient.h:
969         * WebCoreSupport/WebFrameLoaderClient.mm:
970         (WebFrameLoaderClient::cancelPolicyCheck):
971         (WebFrameLoaderClient::setUpPolicyListener):
972         (-[WebFramePolicyListener dealloc]):
973
974 2018-05-22  Ryan Haddad  <ryanhaddad@apple.com>
975
976         Unreviewed, rolling out r232052.
977
978         Breaks internal builds.
979
980         Reverted changeset:
981
982         "Use more C++17"
983         https://bugs.webkit.org/show_bug.cgi?id=185176
984         https://trac.webkit.org/changeset/232052
985
986 2018-05-21  Yusuke Suzuki  <utatane.tea@gmail.com>
987
988         Use more C++17
989         https://bugs.webkit.org/show_bug.cgi?id=185176
990
991         Reviewed by JF Bastien.
992
993         * Configurations/Base.xcconfig:
994         * Configurations/WebKitLegacy.xcconfig:
995
996 2018-05-21  Chris Nardi  <cnardi@chromium.org>
997
998         Remove dead exception in MediaList.appendMedium
999         https://bugs.webkit.org/show_bug.cgi?id=185278
1000
1001         Reviewed by Chris Dumez.
1002
1003         Remove code pertaining to an exception being thrown by appendMedium().
1004
1005         * DOM/DOMMediaList.mm:
1006         (-[DOMMediaList appendMedium:]):
1007
1008 2018-05-21  Jer Noble  <jer.noble@apple.com>
1009
1010         Complete fix for enabling modern EME by default
1011         https://bugs.webkit.org/show_bug.cgi?id=185770
1012         <rdar://problem/40368220>
1013
1014         Reviewed by Eric Carlson.
1015
1016         * Configurations/FeatureDefines.xcconfig:
1017
1018 2018-05-21  Antti Koivisto  <antti@apple.com>
1019
1020         WebView._preferencesChanged should apply colorFilterEnabled preference before parsing user stylesheet
1021         https://bugs.webkit.org/show_bug.cgi?id=185815
1022         <rdar://problem/40310069>
1023
1024         Reviewed by Simon Fraser.
1025
1026         User stylesheet parsing may depend on the colorFilterEnabled preference.
1027
1028         * WebView/WebView.mm:
1029         (-[WebView _preferencesChanged:]):
1030
1031 2018-05-18  Commit Queue  <commit-queue@webkit.org>
1032
1033         Unreviewed, rolling out r231982.
1034         https://bugs.webkit.org/show_bug.cgi?id=185793
1035
1036         Caused layout test failures (Requested by realdawei on
1037         #webkit).
1038
1039         Reverted changeset:
1040
1041         "Complete fix for enabling modern EME by default"
1042         https://bugs.webkit.org/show_bug.cgi?id=185770
1043         https://trac.webkit.org/changeset/231982
1044
1045 2018-05-18  Jer Noble  <jer.noble@apple.com>
1046
1047         Complete fix for enabling modern EME by default
1048         https://bugs.webkit.org/show_bug.cgi?id=185770
1049         <rdar://problem/40368220>
1050
1051         Reviewed by Eric Carlson.
1052
1053         * Configurations/FeatureDefines.xcconfig:
1054
1055 2018-05-18  Chris Dumez  <cdumez@apple.com>
1056
1057         Avoid keeping the frame alive when ref'ing a WindowProxy
1058         https://bugs.webkit.org/show_bug.cgi?id=185737
1059         <rdar://problem/40004666>
1060
1061         Reviewed by Sam Weinig.
1062
1063         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1064         (WebKit::NetscapePluginInstanceProxy::getWindowNPObject):
1065
1066 2018-05-16  Andy VanWagoner  <andy@vanwagoner.family>
1067
1068         Add support for Intl NumberFormat formatToParts
1069         https://bugs.webkit.org/show_bug.cgi?id=185375
1070
1071         Reviewed by Yusuke Suzuki.
1072
1073         Add flag for NumberFormat formatToParts.
1074
1075         * Configurations/FeatureDefines.xcconfig:
1076
1077 2018-05-16  Chris Nardi  <cnardi@chromium.org>
1078
1079         Fixup after r231849: Do not mark Mac API methods as deprecated
1080         https://bugs.webkit.org/show_bug.cgi?id=185684
1081
1082         Reviewed by Darin Adler.
1083
1084         Do not mark API methods for Document#selectedStylesheetSet/preferredStylesheetSet as deprecated
1085         as the entire class is already marked as deprecated, so it is unnecessary.
1086
1087         * DOM/DOMDocument.h:
1088
1089 2018-05-16  Chris Nardi  <cnardi@chromium.org>
1090
1091         Remove Document#selectedStylesheetSet/preferredStylesheetSet
1092         https://bugs.webkit.org/show_bug.cgi?id=185381
1093
1094         Reviewed by Darin Adler.
1095
1096         Mark API methods for Document#selectedStylesheetSet/preferredStylesheetSet as deprecated
1097         and make them do nothing.
1098
1099         * DOM/DOMDocument.h:
1100         * DOM/DOMDocument.mm:
1101         (-[DOMDocument preferredStylesheetSet]):
1102         (-[DOMDocument selectedStylesheetSet]):
1103         (-[DOMDocument setSelectedStylesheetSet:]):
1104
1105 2018-05-15  Antoine Quint  <graouts@apple.com>
1106
1107         [Web Animations] Expose Web Animations CSS integration as an experimental feature
1108         https://bugs.webkit.org/show_bug.cgi?id=185647
1109
1110         Reviewed by Dean Jackson.
1111
1112         Rename the Web Animations CSS integration flag.
1113
1114         * WebView/WebPreferenceKeysPrivate.h:
1115         * WebView/WebPreferences.mm:
1116         (+[WebPreferences initialize]):
1117         (-[WebPreferences webAnimationsCSSIntegrationEnabled]):
1118         (-[WebPreferences setWebAnimationsCSSIntegrationEnabled:]):
1119         (-[WebPreferences cssAnimationsAndCSSTransitionsBackedByWebAnimationsEnabled]): Deleted.
1120         (-[WebPreferences setCSSAnimationsAndCSSTransitionsBackedByWebAnimationsEnabled:]): Deleted.
1121         * WebView/WebPreferencesPrivate.h:
1122         * WebView/WebView.mm:
1123         (-[WebView _preferencesChanged:]):
1124
1125 2018-05-14  Daniel Bates  <dabates@apple.com>
1126
1127         Fix the Apple Internal build
1128
1129         See <rdar://problem/40237873> for more details.
1130
1131         * WebView/WebFullScreenController.mm:
1132         (-[WebFullScreenController enterFullScreen:]):
1133         (-[WebFullScreenController finishedEnterFullScreenAnimation:]):
1134         (-[WebFullScreenController exitFullScreen]):
1135         (-[WebFullScreenController finishedExitFullScreenAnimation:]):
1136         (-[WebFullScreenController _startEnterFullScreenAnimationWithDuration:]):
1137         (-[WebFullScreenController _startExitFullScreenAnimationWithDuration:]):
1138
1139 2018-05-11  Timothy Hatcher  <timothy@apple.com>
1140
1141         WebHTMLView is not setting aside subviews when drawing.
1142
1143         https://bugs.webkit.org/show_bug.cgi?id=185561
1144         rdar://problem/40172894
1145
1146         Reviewed by Simon Fraser.
1147
1148         Use the new method signature for _recursive:displayRectIgnoringOpacity:shouldChangeFontReferenceColor:.
1149
1150         * WebView/WebHTMLView.mm:
1151         (-[WebHTMLView _recursive:displayRectIgnoringOpacity:inContext:shouldChangeFontReferenceColor:stopAtLayerBackedViews:]): Added.
1152
1153 2018-05-07  Daniel Bates  <dabates@apple.com>
1154
1155         Substitute CrossOriginPreflightResultCache::clear() for CrossOriginPreflightResultCache::empty()
1156         https://bugs.webkit.org/show_bug.cgi?id=185170
1157
1158         Reviewed by Per Arne Vollan.
1159
1160         * Misc/WebCache.mm:
1161         (+[WebCache empty]):
1162
1163 2018-05-04  Timothy Hatcher  <timothy@apple.com>
1164
1165         Deprecate legacy WebView and friends
1166         https://bugs.webkit.org/show_bug.cgi?id=185279
1167         rdar://problem/33268700
1168
1169         Reviewed by Tim Horton.
1170
1171         Added deprecation macros to all the classes, extern strings, and enums.
1172
1173         * Configurations/WebKitLegacy.xcconfig:
1174         Added BUILDING_WEBKIT define to disable the deprecation macros.
1175         * DOM/DOMAbstractView.h:
1176         * DOM/DOMAttr.h:
1177         * DOM/DOMBlob.h:
1178         * DOM/DOMCDATASection.h:
1179         * DOM/DOMCSSCharsetRule.h:
1180         * DOM/DOMCSSFontFaceRule.h:
1181         * DOM/DOMCSSImportRule.h:
1182         * DOM/DOMCSSMediaRule.h:
1183         * DOM/DOMCSSPageRule.h:
1184         * DOM/DOMCSSPrimitiveValue.h:
1185         * DOM/DOMCSSRule.h:
1186         * DOM/DOMCSSRuleList.h:
1187         * DOM/DOMCSSStyleDeclaration.h:
1188         * DOM/DOMCSSStyleRule.h:
1189         * DOM/DOMCSSStyleSheet.h:
1190         * DOM/DOMCSSUnknownRule.h:
1191         * DOM/DOMCSSValue.h:
1192         * DOM/DOMCSSValueList.h:
1193         * DOM/DOMCharacterData.h:
1194         * DOM/DOMComment.h:
1195         * DOM/DOMCounter.h:
1196         * DOM/DOMDocument.h:
1197         * DOM/DOMDocumentFragment.h:
1198         * DOM/DOMDocumentType.h:
1199         * DOM/DOMElement.h:
1200         * DOM/DOMEntity.h:
1201         * DOM/DOMEntityReference.h:
1202         * DOM/DOMEvent.h:
1203         * DOM/DOMEventException.h:
1204         * DOM/DOMEventListener.h:
1205         * DOM/DOMEventTarget.h:
1206         * DOM/DOMException.h:
1207         * DOM/DOMFile.h:
1208         * DOM/DOMFileList.h:
1209         * DOM/DOMHTMLAnchorElement.h:
1210         * DOM/DOMHTMLAppletElement.h:
1211         * DOM/DOMHTMLAreaElement.h:
1212         * DOM/DOMHTMLBRElement.h:
1213         * DOM/DOMHTMLBaseElement.h:
1214         * DOM/DOMHTMLBaseFontElement.h:
1215         * DOM/DOMHTMLBodyElement.h:
1216         * DOM/DOMHTMLButtonElement.h:
1217         * DOM/DOMHTMLCanvasElement.h:
1218         * DOM/DOMHTMLCollection.h:
1219         * DOM/DOMHTMLDListElement.h:
1220         * DOM/DOMHTMLDirectoryElement.h:
1221         * DOM/DOMHTMLDivElement.h:
1222         * DOM/DOMHTMLDocument.h:
1223         * DOM/DOMHTMLElement.h:
1224         * DOM/DOMHTMLEmbedElement.h:
1225         * DOM/DOMHTMLFieldSetElement.h:
1226         * DOM/DOMHTMLFontElement.h:
1227         * DOM/DOMHTMLFormElement.h:
1228         * DOM/DOMHTMLFrameElement.h:
1229         * DOM/DOMHTMLFrameSetElement.h:
1230         * DOM/DOMHTMLHRElement.h:
1231         * DOM/DOMHTMLHeadElement.h:
1232         * DOM/DOMHTMLHeadingElement.h:
1233         * DOM/DOMHTMLHtmlElement.h:
1234         * DOM/DOMHTMLIFrameElement.h:
1235         * DOM/DOMHTMLImageElement.h:
1236         * DOM/DOMHTMLInputElement.h:
1237         * DOM/DOMHTMLLIElement.h:
1238         * DOM/DOMHTMLLabelElement.h:
1239         * DOM/DOMHTMLLegendElement.h:
1240         * DOM/DOMHTMLLinkElement.h:
1241         * DOM/DOMHTMLMapElement.h:
1242         * DOM/DOMHTMLMarqueeElement.h:
1243         * DOM/DOMHTMLMediaElement.h:
1244         * DOM/DOMHTMLMenuElement.h:
1245         * DOM/DOMHTMLMetaElement.h:
1246         * DOM/DOMHTMLModElement.h:
1247         * DOM/DOMHTMLOListElement.h:
1248         * DOM/DOMHTMLObjectElement.h:
1249         * DOM/DOMHTMLOptGroupElement.h:
1250         * DOM/DOMHTMLOptionElement.h:
1251         * DOM/DOMHTMLOptionsCollection.h:
1252         * DOM/DOMHTMLParagraphElement.h:
1253         * DOM/DOMHTMLParamElement.h:
1254         * DOM/DOMHTMLPreElement.h:
1255         * DOM/DOMHTMLQuoteElement.h:
1256         * DOM/DOMHTMLScriptElement.h:
1257         * DOM/DOMHTMLSelectElement.h:
1258         * DOM/DOMHTMLStyleElement.h:
1259         * DOM/DOMHTMLTableCaptionElement.h:
1260         * DOM/DOMHTMLTableCellElement.h:
1261         * DOM/DOMHTMLTableColElement.h:
1262         * DOM/DOMHTMLTableElement.h:
1263         * DOM/DOMHTMLTableRowElement.h:
1264         * DOM/DOMHTMLTableSectionElement.h:
1265         * DOM/DOMHTMLTextAreaElement.h:
1266         * DOM/DOMHTMLTitleElement.h:
1267         * DOM/DOMHTMLUListElement.h:
1268         * DOM/DOMHTMLVideoElement.h:
1269         * DOM/DOMImplementation.h:
1270         * DOM/DOMKeyboardEvent.h:
1271         * DOM/DOMMediaError.h:
1272         * DOM/DOMMediaList.h:
1273         * DOM/DOMMouseEvent.h:
1274         * DOM/DOMMutationEvent.h:
1275         * DOM/DOMNamedNodeMap.h:
1276         * DOM/DOMNode.h:
1277         * DOM/DOMNodeFilter.h:
1278         * DOM/DOMNodeIterator.h:
1279         * DOM/DOMNodeList.h:
1280         * DOM/DOMObject.h:
1281         * DOM/DOMOverflowEvent.h:
1282         * DOM/DOMProcessingInstruction.h:
1283         * DOM/DOMProgressEvent.h:
1284         * DOM/DOMRGBColor.h:
1285         * DOM/DOMRange.h:
1286         * DOM/DOMRangeException.h:
1287         * DOM/DOMRect.h:
1288         * DOM/DOMStyleSheet.h:
1289         * DOM/DOMStyleSheetList.h:
1290         * DOM/DOMText.h:
1291         * DOM/DOMTextEvent.h:
1292         * DOM/DOMTimeRanges.h:
1293         * DOM/DOMTokenList.h:
1294         * DOM/DOMTreeWalker.h:
1295         * DOM/DOMUIEvent.h:
1296         * DOM/DOMWheelEvent.h:
1297         * DOM/DOMXPathException.h:
1298         * DOM/DOMXPathExpression.h:
1299         * DOM/DOMXPathNSResolver.h:
1300         * DOM/DOMXPathResult.h:
1301         * History/WebBackForwardList.h:
1302         * History/WebHistory.h:
1303         * History/WebHistoryItem.h:
1304         * Misc/WebDownload.h:
1305         * Misc/WebKitErrors.h:
1306         * Plugins/WebPluginViewFactory.h:
1307         * WebView/WebArchive.h:
1308         * WebView/WebDataSource.h:
1309         * WebView/WebDocument.h:
1310         * WebView/WebEditingDelegate.h:
1311         * WebView/WebFormDelegate.h:
1312         * WebView/WebFrame.h:
1313         * WebView/WebFrameLoadDelegate.h:
1314         * WebView/WebFrameView.h:
1315         * WebView/WebPolicyDelegate.h:
1316         * WebView/WebPreferences.h:
1317         * WebView/WebPreferencesPrivate.h:
1318         * WebView/WebResourceLoadDelegate.h:
1319         * WebView/WebUIDelegate.h:
1320         * WebView/WebUIDelegatePrivate.h:
1321         * WebView/WebView.h:
1322         * WebView/WebViewPrivate.h:
1323         * postprocess-headers.sh:
1324         Remove step that converts WEBKIT macros to NS macros.
1325         Change it to just remove the macros on iOS builds.
1326
1327 2018-05-01  Eric Carlson  <eric.carlson@apple.com>
1328
1329         [MediaStream] remove WK1 support
1330         https://bugs.webkit.org/show_bug.cgi?id=185136
1331
1332         Reviewed by Youenn Fablet.
1333
1334         * WebCoreSupport/WebUserMediaClient.h: Removed.
1335         * WebCoreSupport/WebUserMediaClient.mm: Removed.
1336         * WebView/WebView.mm:
1337         (-[WebView _commonInitializationWithFrameName:groupName:]):
1338         (-[WebView _preferencesChanged:]):
1339         (-[WebView _setUserMediaClient:]): Deleted.
1340         (-[WebView _userMediaClient]): Deleted.
1341         * WebView/WebViewData.h:
1342         * WebView/WebViewPrivate.h:
1343
1344 2018-05-01  Oleksandr Skachkov  <gskachkov@gmail.com>
1345
1346         WebAssembly: add support for stream APIs - JavaScript API
1347         https://bugs.webkit.org/show_bug.cgi?id=183442
1348
1349         Reviewed by Yusuke Suzuki and JF Bastien.
1350
1351         Add WEBASSEMBLY_STREAMINNG_API feature flag
1352
1353         * Configurations/FeatureDefines.xcconfig:
1354
1355 2018-04-30  JF Bastien  <jfbastien@apple.com>
1356
1357         Use some C++17 features
1358         https://bugs.webkit.org/show_bug.cgi?id=185135
1359
1360         Reviewed by Alex Christensen.
1361
1362         * Configurations/WebKitLegacy.xcconfig:
1363
1364 2018-04-27  Chris Dumez  <cdumez@apple.com>
1365
1366         Use WindowProxy instead of DOMWindow in our IDL
1367         https://bugs.webkit.org/show_bug.cgi?id=185022
1368
1369         Reviewed by Sam Weinig.
1370
1371         * DOM/DOMAbstractView.mm:
1372         (kit):
1373         (toWindowProxy):
1374         * DOM/DOMAbstractViewInternal.h:
1375         * DOM/DOMDocument.mm:
1376         (-[DOMDocument defaultView]):
1377         (-[DOMDocument getComputedStyle:pseudoElement:]):
1378         (-[DOMDocument getMatchedCSSRules:pseudoElement:authorOnly:]):
1379         * DOM/DOMHTMLFrameElement.mm:
1380         (-[DOMHTMLFrameElement contentWindow]):
1381         * DOM/DOMHTMLIFrameElement.mm:
1382         (-[DOMHTMLIFrameElement contentWindow]):
1383         * DOM/DOMKeyboardEvent.mm:
1384         (-[DOMKeyboardEvent initKeyboardEvent:canBubble:cancelable:view:keyIdentifier:location:ctrlKey:altKey:shiftKey:metaKey:altGraphKey:]):
1385         (-[DOMKeyboardEvent initKeyboardEvent:canBubble:cancelable:view:keyIdentifier:location:ctrlKey:altKey:shiftKey:metaKey:]):
1386         (-[DOMKeyboardEvent initKeyboardEvent:canBubble:cancelable:view:keyIdentifier:keyLocation:ctrlKey:altKey:shiftKey:metaKey:altGraphKey:]):
1387         (-[DOMKeyboardEvent initKeyboardEvent:canBubble:cancelable:view:keyIdentifier:keyLocation:ctrlKey:altKey:shiftKey:metaKey:]):
1388         * DOM/DOMMouseEvent.mm:
1389         (-[DOMMouseEvent initMouseEvent:canBubble:cancelable:view:detail:screenX:screenY:clientX:clientY:ctrlKey:altKey:shiftKey:metaKey:button:relatedTarget:]):
1390         * DOM/DOMTextEvent.mm:
1391         (-[DOMTextEvent initTextEvent:canBubbleArg:cancelableArg:viewArg:dataArg:]):
1392         * DOM/DOMUIEvent.mm:
1393         (-[DOMUIEvent view]):
1394         (-[DOMUIEvent initUIEvent:canBubble:cancelable:view:detail:]):
1395         * DOM/DOMWheelEvent.mm:
1396         (-[DOMWheelEvent initWheelEvent:wheelDeltaY:view:screenX:screenY:clientX:clientY:ctrlKey:altKey:shiftKey:metaKey:]):
1397
1398 2018-04-26  Simon Fraser  <simon.fraser@apple.com>
1399
1400         Implement rendering support for the color-filter CSS property
1401         https://bugs.webkit.org/show_bug.cgi?id=185047
1402         rdar://problem/39664967
1403
1404         Reviewed by Tim Horton.
1405         
1406         The body background should reflect the filtered color.
1407
1408         * WebView/WebFrame.mm:
1409         (-[WebFrame _bodyBackgroundColor]):
1410         * WebView/WebView.mm:
1411         (-[WebView updateTextTouchBar]): No logic change, just cleanup.
1412
1413 2018-04-26  Jer Noble  <jer.noble@apple.com>
1414
1415         WK_COCOA_TOUCH all the things.
1416         https://bugs.webkit.org/show_bug.cgi?id=185006
1417
1418         Reviewed by Tim Horton.
1419
1420         * Configurations/WebKitLegacy.xcconfig:
1421
1422 2018-04-26  Daniel Bates  <dabates@apple.com>
1423
1424         ASSERTION FAILED: ASSERT(!containsImage || MIMETypeRegistry::isSupportedImageResourceMIMEType([resource MIMEType])) in -[NSPasteboard(WebExtras) _web_writePromisedRTFDFromArchive:containsImage:]
1425         https://bugs.webkit.org/show_bug.cgi?id=184161
1426         <rdar://problem/39051645>
1427
1428         Reviewed by Dan Bernstein.
1429
1430         Fixes an assertion failure when quitting an app that uses a Legacy WebKit web view after dragging-and-
1431         dropping a PDF embedded using an HTML image element into the same web view.
1432
1433         When performing a drag-and-drop of a PDF document image (WebCore::PDFDocumentImage) we create a WebArchive
1434         from the main frame's WebHTMLView and promise AppKit that we will provide a Rich Text Format (RTF) document
1435         from this archive if needed. For some reason, on app termination AppKit requests that the WebHTMLView
1436         fulfill its RTF document promise for the WebArchive created at the start of the drag operation. To do this,
1437         we need to extract the image resource from the Web Archive. Currently we query MIMETypeRegistry::isSupportedImageResourceMIMEType()
1438         to see if the contained image is one that we can handle. However MIMETypeRegistry::isSupportedImageResourceMIMEType()
1439         only returns true if WebKit supports creating an image document for the specified MIME type. Disregarding
1440         the iOS motivated setting Settings::useImageDocumentForSubframePDF, PDFs and PostScripts do not create an
1441         image document when navigated to directly. Since we can support dragging PDF document images we need to
1442         query if MIMETypeRegistry::isPDFOrPostScriptMIMEType() in addition to querying MIMETypeRegistry::isSupportedImageResourceMIMEType().
1443         We need to do both such queries before falling back to using the main resource of the Web Archive as
1444         the image. Otherwise, we will cause an assertion failure if the main resource of the Web Archive is
1445         not an image document.
1446
1447         * Misc/WebNSPasteboardExtras.mm:
1448         (-[NSPasteboard _web_writePromisedRTFDFromArchive:containsImage:]):
1449
1450 2018-04-26  Per Arne Vollan  <pvollan@apple.com>
1451
1452         Disable content filtering in minimal simulator mode
1453         https://bugs.webkit.org/show_bug.cgi?id=185027
1454         <rdar://problem/39736091>
1455
1456         Reviewed by Jer Noble.
1457
1458         * Configurations/FeatureDefines.xcconfig:
1459
1460 2018-04-26  Andy VanWagoner  <thetalecrafter@gmail.com>
1461
1462         [INTL] Implement Intl.PluralRules
1463         https://bugs.webkit.org/show_bug.cgi?id=184312
1464
1465         Reviewed by JF Bastien.
1466
1467         Added Intl.PluralRules feature flag.
1468
1469         * Configurations/FeatureDefines.xcconfig:
1470
1471 2018-04-25  Jiewen Tan  <jiewen_tan@apple.com>
1472
1473         Remove access to keychain from the WebContent process
1474         https://bugs.webkit.org/show_bug.cgi?id=184428
1475         <rdar://problem/13150903>
1476
1477         Reviewed by Brent Fulgham.
1478
1479         This patch does the followings:
1480         1. Added necessary support to move HTMLKeygenElement's operation from WebCore space to Client space.
1481         2. Craft new SPI signedPublicKeyAndChallengeStringForWebView to supply HTMLKeygenElement with dummy data
1482         such that DumpRenderTree tests will not modify the underlying key store (e.g., the macOS Keychain).
1483
1484         * WebCoreSupport/WebChromeClient.h:
1485         * WebCoreSupport/WebChromeClient.mm:
1486         (WebChromeClient::signedPublicKeyAndChallengeString const):
1487         * WebView/WebUIDelegatePrivate.h:
1488
1489 2018-04-24  Jer Noble  <jer.noble@apple.com>
1490
1491         Don't add system framework paths to FRAMEWORK_SEARCH_PATHS
1492         https://bugs.webkit.org/show_bug.cgi?id=184786
1493
1494         Reviewed by Tim Horton.
1495
1496         * Configurations/WebKitLegacy.xcconfig:
1497         * MigrateHeaders.make:
1498
1499 2018-04-23  Daniel Bates  <dabates@apple.com>
1500
1501         Implement Same-Site cookies
1502         https://bugs.webkit.org/show_bug.cgi?id=159464
1503         <rdar://problem/27196358>
1504
1505         Reviewed by Brent Fulgham.
1506
1507         Pass the Same-Site info through the strategy.
1508
1509         * WebCoreSupport/WebPlatformStrategies.h:
1510         * WebCoreSupport/WebPlatformStrategies.mm:
1511         (WebPlatformStrategies::cookiesForDOM):
1512         (WebPlatformStrategies::setCookiesFromDOM):
1513         (WebPlatformStrategies::cookieRequestHeaderFieldValue):
1514         (WebPlatformStrategies::getRawCookies):
1515
1516 2018-04-23  Zalan Bujtas  <zalan@apple.com>
1517
1518         [LayoutFormattingContext] Initial commit.
1519         https://bugs.webkit.org/show_bug.cgi?id=184896
1520
1521         Reviewed by Antti Koivisto.
1522
1523         * Configurations/FeatureDefines.xcconfig:
1524
1525 2018-04-23  Daniel Bates  <dabates@apple.com>
1526
1527         Implement Same-Site cookies
1528         https://bugs.webkit.org/show_bug.cgi?id=159464
1529         <rdar://problem/27196358>
1530
1531         Reviewed by Brent Fulgham.
1532
1533         Pass the Same-Site info through the strategy.
1534
1535         * WebCoreSupport/WebPlatformStrategies.h:
1536         * WebCoreSupport/WebPlatformStrategies.mm:
1537         (WebPlatformStrategies::cookiesForDOM):
1538         (WebPlatformStrategies::setCookiesFromDOM):
1539         (WebPlatformStrategies::cookieRequestHeaderFieldValue):
1540         (WebPlatformStrategies::getRawCookies):
1541
1542 2018-04-20  Timothy Hatcher  <timothy@apple.com>
1543
1544         NULL dereference crash sometimes under [super initWithCoder:] in WebView
1545
1546         https://bugs.webkit.org/show_bug.cgi?id=184851
1547         rdar://problem/39611236
1548
1549         Reviewed by Tim Horton.
1550
1551         * WebView/WebView.mm:
1552         (-[WebView _commonInitializationWithFrameName:groupName:]):
1553         (-[WebView effectiveAppearanceDidChange]):
1554         Added a null check and call the code later in initialization.
1555
1556 2018-04-20  Tim Horton  <timothy_horton@apple.com>
1557
1558         Adjust geolocation feature flag
1559         https://bugs.webkit.org/show_bug.cgi?id=184856
1560
1561         Reviewed by Wenson Hsieh.
1562
1563         * Configurations/FeatureDefines.xcconfig:
1564
1565 2018-04-18  Jer Noble  <jer.noble@apple.com>
1566
1567         Don't put build products into WK_ALTERNATE_WEBKIT_SDK_PATH for engineering builds
1568         https://bugs.webkit.org/show_bug.cgi?id=184762
1569
1570         Reviewed by Dan Bernstein.
1571
1572         * Configurations/WebKitLegacy.xcconfig:
1573
1574 2018-04-20  Youenn Fablet  <youenn@apple.com>
1575
1576         Make PluginData cache its web visible plugins
1577         https://bugs.webkit.org/show_bug.cgi?id=184421
1578
1579         Reviewed by Chris Dumez.
1580
1581         * WebCoreSupport/WebPluginInfoProvider.h:
1582         * WebCoreSupport/WebPluginInfoProvider.mm:
1583         (WebPluginInfoProvider::pluginInfo):
1584         (WebPluginInfoProvider::webVisiblePluginInfo):
1585
1586 2018-04-19  Chris Dumez  <cdumez@apple.com>
1587
1588         Rename JSDOMWindowProxy to JSWindowProxy
1589         https://bugs.webkit.org/show_bug.cgi?id=184797
1590
1591         Reviewed by Sam Weinig.
1592
1593         Rename JSDOMWindowProxy to JSWindowProxy for consistency with WindowProxy.
1594
1595         * DOM/DOMUtility.mm:
1596         (createDOMWrapper):
1597         * WebView/WebFrame.mm:
1598         (-[WebFrame _stringByEvaluatingJavaScriptFromString:withGlobalObject:inScriptWorld:]):
1599
1600 2018-04-19  David Kilzer  <ddkilzer@apple.com>
1601
1602         Enable Objective-C weak references
1603         <https://webkit.org/b/184789>
1604         <rdar://problem/39571716>
1605
1606         Reviewed by Dan Bernstein.
1607
1608         * Configurations/Base.xcconfig:
1609         (CLANG_ENABLE_OBJC_WEAK): Enable.
1610
1611 2018-04-18  Chris Dumez  <cdumez@apple.com>
1612
1613         Rename WindowProxyController to WindowProxy
1614         https://bugs.webkit.org/show_bug.cgi?id=184756
1615
1616         Reviewed by Sam Weinig.
1617
1618         Rename WindowProxyController to WindowProxy for clarity. When the IDL uses WindowProxy, the implementation
1619         needed use WindowProxyController type, which was a bit confusing.
1620
1621         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1622         (WebKit::NetscapePluginInstanceProxy::getWindowNPObject):
1623         * WebView/WebFrame.mm:
1624         (-[WebFrame _attachScriptDebugger]):
1625
1626 2018-04-17  Jonathan Bedard  <jbedard@apple.com>
1627
1628         Unreviewed rollout of r230632. Regression in memory usage.
1629
1630         That bug tracked in https://bugs.webkit.org/show_bug.cgi?id=184569.
1631
1632         * WebView/WebPreferences.mm:
1633         (+[WebPreferences initialize]):
1634
1635 2018-04-17  Chris Dumez  <cdumez@apple.com>
1636
1637         REGRESSION (r229831): CMD-clicking an iCloud web app link unexpectedly opens that link in a new tab and the current tab
1638         https://bugs.webkit.org/show_bug.cgi?id=184678
1639         <rdar://problem/39422122>
1640
1641         Reviewed by Alex Christensen.
1642
1643         Add new parameter to dispatchDecidePolicyForNavigationAction.
1644
1645         * WebCoreSupport/WebFrameLoaderClient.h:
1646         * WebCoreSupport/WebFrameLoaderClient.mm:
1647         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1648
1649 2018-04-13  Chris Dumez  <cdumez@apple.com>
1650
1651         Split WindowProxy handling out of ScriptController and into a new class owned by AbstractFrame
1652         https://bugs.webkit.org/show_bug.cgi?id=184591
1653
1654         Reviewed by Sam Weinig.
1655
1656         Split WindowProxy handling out of ScriptController and into a new class owned by AbstractFrame.
1657         RemoteFrames do not need a ScriptController but do need to maintain WindowProxies.
1658         This is work towards fixing Bug 184515.
1659
1660         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1661         (WebKit::NetscapePluginInstanceProxy::getWindowNPObject):
1662         * WebView/WebFrame.mm:
1663         (-[WebFrame _attachScriptDebugger]):
1664
1665 2018-04-12  Antoine Quint  <graouts@apple.com>
1666
1667         [Web Animations] Turn CSS Animations and CSS Transitions as Web Animations on by default
1668         https://bugs.webkit.org/show_bug.cgi?id=184569
1669         <rdar://problem/38671301>
1670
1671         Reviewed by Jon Lee.
1672
1673         * WebView/WebPreferences.mm:
1674
1675 2018-04-05  Yusuke Suzuki  <utatane.tea@gmail.com>
1676
1677         [WTF] Remove StaticLock
1678         https://bugs.webkit.org/show_bug.cgi?id=184332
1679
1680         Reviewed by Mark Lam.
1681
1682         * DOM/DOMInternal.mm:
1683         (getDOMWrapper):
1684         (addDOMWrapper):
1685         (removeDOMWrapper):
1686
1687 2018-04-04  Brent Fulgham  <bfulgham@apple.com>
1688
1689         Failures from mach port reference handling should be fatal
1690         https://bugs.webkit.org/show_bug.cgi?id=184202
1691         <rdar://problem/37771114>
1692
1693         Reviewed by Anders Carlsson.
1694
1695         * Plugins/Hosted/NetscapePluginHostManager.mm:
1696         (WebKit::NetscapePluginHostManager::spawnPluginHost): Adopt new 'safe mach_port_t deallocation' function.
1697
1698 2018-04-03  Andy Estes  <aestes@apple.com>
1699
1700         [Mac] Prioritize file promises over filenames during drag and drop
1701         https://bugs.webkit.org/show_bug.cgi?id=184237
1702         <rdar://problem/38278076>
1703
1704         Reviewed by Wenson Hsieh.
1705
1706         * WebView/WebView.mm:
1707         (-[WebView performDragOperation:]):
1708
1709 2018-04-03  Chris Dumez  <cdumez@apple.com>
1710
1711         Drop MainFrame class
1712         https://bugs.webkit.org/show_bug.cgi?id=184191
1713
1714         Reviewed by Darin Adler.
1715
1716         Drop MainFrame class and move contents into Page / Frame since there is a 1:1
1717         relationship between the Page and the MainFrame.
1718
1719         This is ground work for introducing LocalFrame / RemoteFrame concepts.
1720
1721         * WebCoreSupport/WebDragClient.mm:
1722         * WebCoreSupport/WebFrameLoaderClient.mm:
1723         * WebCoreSupport/WebInspectorClient.mm:
1724         * WebCoreSupport/WebPlatformStrategies.mm:
1725         * WebCoreSupport/WebPluginInfoProvider.mm:
1726         * WebView/WebFrame.mm:
1727         * WebView/WebFrameView.mm:
1728         * WebView/WebHTMLView.mm:
1729         * WebView/WebView.mm:
1730
1731 2018-04-02  Jer Noble  <jer.noble@apple.com>
1732
1733         Enable Legacy EME for all WebKit & WebKitLegacy clients
1734         https://bugs.webkit.org/show_bug.cgi?id=184018
1735         <rdar://problem/34887387>
1736
1737         Reviewed by Eric Carlson.
1738
1739         * WebView/WebPreferences.mm:
1740         (+[WebPreferences initialize]):
1741
1742 2018-03-29  JF Bastien  <jfbastien@apple.com>
1743
1744         Use Forward.h instead of forward-declaring WTF::String
1745         https://bugs.webkit.org/show_bug.cgi?id=184172
1746         <rdar://problem/39026146>
1747
1748         Reviewed by Yusuke Suzuki.
1749
1750         As part of #184164 I'm changing WTF::String, and the forward
1751         declarations are just wrong because I'm making it templated. We
1752         should use Forward.h anyways, so do that instead.
1753
1754         * WebView/WebScriptDebugger.h:
1755
1756 2018-03-28  Brent Fulgham  <bfulgham@apple.com>
1757
1758         Protect against invalid mach ports returned by mach_port_request_notification
1759         https://bugs.webkit.org/show_bug.cgi?id=184106
1760         <rdar://problem/37865316>
1761
1762         Reviewed by Chris Dumez.
1763
1764         * Plugins/Hosted/NetscapePluginHostProxy.mm:
1765         (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy): Check return value from 'mach_port_request_notification'
1766         and clean up if it experienced an error.
1767         (WebKit::NetscapePluginHostProxy::processRequests): Drive-by-fix: Include formatted mach error message in logging.
1768
1769 2018-03-28  Brent Fulgham  <bfulgham@apple.com>
1770
1771         Avoid uninitialized mach ports
1772         https://bugs.webkit.org/show_bug.cgi?id=184090
1773         <rdar://problem/37261129>
1774
1775         Reviewed by Chris Dumez.
1776
1777         It is possible for mach_port_allocate to return an error, but we rarely check its return value. The value
1778         of the argument passed to mach_port_allocate is not guaranteed to be valid when it returns an error, so
1779         there is a potential for us to try to use invalid ports.
1780
1781         We should always check return values, and ensure that the mach port variables we seek to initialize are
1782         kept in a valid state.
1783
1784         Reviewed by Chris Dumez.
1785
1786         * Plugins/Hosted/NetscapePluginHostManager.h:
1787         * Plugins/Hosted/NetscapePluginHostManager.mm:
1788         (WebKit::NetscapePluginHostManager::hostForPlugin): Initialize port to a valid state, ASSERT if an invalid
1789         port is passed to an API function.
1790         (WebKit::NetscapePluginHostManager::spawnPluginHost): Ditto.
1791         (WebKit::NetscapePluginHostManager::initializeVendorPort): Ditto.
1792         * Plugins/Hosted/NetscapePluginHostProxy.h:
1793         * Plugins/Hosted/NetscapePluginHostProxy.mm:
1794         (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy): Ditto.
1795         (WebKit::NetscapePluginHostProxy::~NetscapePluginHostProxy): Ditto.
1796         (WebKit::NetscapePluginHostProxy::processRequests): Ditto.
1797         (WKPCStatusText): Ditto.
1798         (WKPCLoadURL): Ditto.
1799         (WKPCCancelLoadURL): Ditto.
1800         (WKPCInvalidateRect): Ditto.
1801         (WKPCGetScriptableNPObjectReply): Ditto.
1802         (WKPCBooleanReply): Ditto.
1803         (WKPCBooleanAndDataReply): Ditto.
1804         (WKPCInstantiatePluginReply): Ditto.
1805         (WKPCGetWindowNPObject): Ditto.
1806         (WKPCGetPluginElementNPObject): Ditto.
1807         (WKPCForgetBrowserObject): Ditto.
1808         (WKPCEvaluate): Ditto.
1809         (WKPCGetStringIdentifier): Ditto.
1810         (WKPCGetIntIdentifier): Ditto.
1811         (WKPCInvoke): Ditto.
1812         (WKPCInvokeDefault): Ditto.
1813         (WKPCConstruct): Ditto.
1814         (WKPCGetProperty): Ditto.
1815         (WKPCSetProperty): Ditto.
1816         (WKPCRemoveProperty): Ditto.
1817         (WKPCHasProperty): Ditto.
1818         (WKPCHasMethod): Ditto.
1819         (WKPCIdentifierInfo): Ditto.
1820         (WKPCEnumerate): Ditto.
1821         (WKPCSetMenuBarVisible): Ditto.
1822         (WKPCSetFullscreenWindowIsShowing): Ditto.
1823         (WKPCSetModal): Ditto.
1824         (WKPCGetCookies): Ditto.
1825         (WKPCGetProxy): Ditto.
1826         (WKPCSetCookies): Ditto.
1827         (WKPCGetAuthenticationInfo): Ditto.
1828         (WKPCConvertPoint): Ditto.
1829         (WKPCLayerHostingModeChanged): Ditto.
1830         (WKPCSetException): Ditto.
1831
1832 2018-03-26  Tim Horton  <timothy_horton@apple.com>
1833
1834         Adopt WK_ALTERNATE_FRAMEWORKS_DIR in WebKit
1835         https://bugs.webkit.org/show_bug.cgi?id=184030
1836         <rdar://problem/38895281>
1837
1838         Reviewed by Dan Bernstein.
1839
1840         * Configurations/Base.xcconfig:
1841
1842 2018-03-26  Chris Dumez  <cdumez@apple.com>
1843
1844         Use SecurityOriginData more consistently in Service Worker code
1845         https://bugs.webkit.org/show_bug.cgi?id=183969
1846
1847         Reviewed by Darin Adler.
1848
1849         Use SecurityOrigin::data() instead of SecurityOriginData::fromSecurityOrigin().
1850
1851         * Storage/WebDatabaseManager.mm:
1852         (-[WebDatabaseManager databasesWithOrigin:]):
1853         (-[WebDatabaseManager deleteOrigin:]):
1854         (-[WebDatabaseManager deleteDatabase:withOrigin:]):
1855         * Storage/WebDatabaseQuotaManager.mm:
1856         (-[WebDatabaseQuotaManager usage]):
1857         (-[WebDatabaseQuotaManager quota]):
1858         (-[WebDatabaseQuotaManager setQuota:]):
1859         * Storage/WebStorageManager.mm:
1860         (-[WebStorageManager deleteOrigin:]):
1861         * WebCoreSupport/WebSecurityOrigin.mm:
1862         (-[WebSecurityOrigin databaseIdentifier]):
1863         (-[WebSecurityOrigin usage]):
1864         (-[WebSecurityOrigin quota]):
1865         (-[WebSecurityOrigin setQuota:]):
1866
1867 2018-03-26  Brent Fulgham  <bfulgham@apple.com>
1868
1869         Warn against cookie access in the WebContent process using ProcessPrivilege assertions
1870         https://bugs.webkit.org/show_bug.cgi?id=183911
1871         <rdar://problem/38762306>
1872
1873         Reviewed by Youenn Fablet.
1874
1875         Initialize the ProcessPrivilege and Cookie API access levels for single-process use.
1876
1877         * WebView/WebView.mm:
1878         (+[WebView initialize]):
1879
1880 2018-03-26  Alex Christensen  <achristensen@webkit.org>
1881
1882         Merge ResourceHandleClient::willCacheResponseAsync with ResourceHandleClient::willCacheResponse
1883         https://bugs.webkit.org/show_bug.cgi?id=183965
1884
1885         Reviewed by Chris Dumez.
1886
1887         * WebCoreSupport/WebFrameLoaderClient.h:
1888         * WebCoreSupport/WebFrameLoaderClient.mm:
1889         (WebFrameLoaderClient::willCacheResponse const):
1890
1891 2018-03-25  Commit Queue  <commit-queue@webkit.org>
1892
1893         Unreviewed, rolling out r229954.
1894         https://bugs.webkit.org/show_bug.cgi?id=184000
1895
1896         Caused many layout tests to crash on Apple High Sierra,
1897         Sierra, iOS Simulator and GTK Linux Debug test bots (Requested
1898         by dydz on #webkit).
1899
1900         Reverted changeset:
1901
1902         "Use SecurityOriginData more consistently in Service Worker
1903         code"
1904         https://bugs.webkit.org/show_bug.cgi?id=183969
1905         https://trac.webkit.org/changeset/229954
1906
1907 2018-03-24  Chris Dumez  <cdumez@apple.com>
1908
1909         Use SecurityOriginData more consistently in Service Worker code
1910         https://bugs.webkit.org/show_bug.cgi?id=183969
1911
1912         Reviewed by Darin Adler.
1913
1914         Use SecurityOrigin::data() instead of SecurityOriginData::fromSecurityOrigin().
1915
1916         * Storage/WebDatabaseManager.mm:
1917         (-[WebDatabaseManager databasesWithOrigin:]):
1918         (-[WebDatabaseManager deleteOrigin:]):
1919         (-[WebDatabaseManager deleteDatabase:withOrigin:]):
1920         * Storage/WebDatabaseQuotaManager.mm:
1921         (-[WebDatabaseQuotaManager usage]):
1922         (-[WebDatabaseQuotaManager quota]):
1923         (-[WebDatabaseQuotaManager setQuota:]):
1924         * Storage/WebStorageManager.mm:
1925         (-[WebStorageManager deleteOrigin:]):
1926         * WebCoreSupport/WebSecurityOrigin.mm:
1927         (-[WebSecurityOrigin databaseIdentifier]):
1928         (-[WebSecurityOrigin usage]):
1929         (-[WebSecurityOrigin quota]):
1930         (-[WebSecurityOrigin setQuota:]):
1931
1932 2018-03-24  Timothy Horton  <timothy_horton@apple.com>
1933
1934         Fix the build
1935
1936         * WebView/WebView.mm:
1937
1938 2018-03-23  Tim Horton  <timothy_horton@apple.com>
1939
1940         Fix the build with no pasteboard
1941         https://bugs.webkit.org/show_bug.cgi?id=183973
1942
1943         Reviewed by Dan Bernstein.
1944
1945         * Configurations/FeatureDefines.xcconfig:
1946         * WebView/WebView.mm:
1947         (-[WebView _requestStartDataInteraction:globalPosition:]):
1948         (-[WebView _getDataInteractionData]):
1949         (-[WebView _dataOperationTextIndicator]):
1950         (-[WebView _dragSourceAction]):
1951         (-[WebView _draggedLinkTitle]):
1952         (-[WebView _draggedLinkURL]):
1953         (-[WebView _draggedElementBounds]):
1954         (-[WebView _enteredDataInteraction:client:global:operation:]):
1955         (-[WebView _updatedDataInteraction:client:global:operation:]):
1956         (-[WebView _exitedDataInteraction:client:global:operation:]):
1957         (-[WebView _performDataInteraction:client:global:operation:]):
1958         (-[WebView _tryToPerformDataInteraction:client:global:operation:]):
1959         (-[WebView _endedDataInteraction:global:]):
1960         (-[WebView _dataInteractionCaretRect]):
1961         * WebView/WebViewPrivate.h:
1962
1963 2018-03-23  Tim Horton  <timothy_horton@apple.com>
1964
1965         Adopt WK_ALTERNATE_FRAMEWORKS_DIR in WebKitLegacy and update install name
1966         https://bugs.webkit.org/show_bug.cgi?id=183960
1967         <rdar://problem/38812356>
1968
1969         Reviewed by Dan Bernstein.
1970
1971         * Configurations/WebKitLegacy.xcconfig:
1972
1973 2018-03-23  Tim Horton  <timothy_horton@apple.com>
1974
1975         Introduce and adopt HAVE(AUDIO_TOOLBOX_AUDIO_SESSION)
1976         https://bugs.webkit.org/show_bug.cgi?id=183954
1977         <rdar://problem/38808858>
1978
1979         Reviewed by Dan Bernstein.
1980
1981         * WebView/WebPreferences.mm:
1982         (-[WebPreferences setAudioSessionCategoryOverride:]):
1983
1984 2018-03-23  Tim Horton  <timothy_horton@apple.com>
1985
1986         Adopt WK_PLATFORM_NAME in WebKitLegacy
1987         https://bugs.webkit.org/show_bug.cgi?id=183948
1988         <rdar://problem/38803908>
1989
1990         Reviewed by Dan Bernstein.
1991
1992         * Configurations/WebKitLegacy.xcconfig:
1993         * MigrateHeaders.make:
1994         * postprocess-headers.sh:
1995
1996 2018-03-23  Brady Eidson  <beidson@apple.com>
1997
1998         Go to back/forward list items after a process-swapped navigation.
1999         <rdar://problem/38690544> and https://bugs.webkit.org/show_bug.cgi?id=183920
2000
2001         Reviewed by Andy Estes.
2002
2003         * WebView/WebView.mm:
2004         (-[WebView _loadBackForwardListFromOtherView:]):
2005         (-[WebView goToBackForwardItem:]):
2006
2007 2018-03-22  Tim Horton  <timothy_horton@apple.com>
2008
2009         Improve readability of WebCore's OTHER_LDFLAGS
2010         https://bugs.webkit.org/show_bug.cgi?id=183909
2011         <rdar://problem/38760992>
2012
2013         Reviewed by Dan Bernstein.
2014
2015         * Configurations/Base.xcconfig:
2016         * Configurations/FeatureDefines.xcconfig:
2017
2018 2018-03-20  Tim Horton  <timothy_horton@apple.com>
2019
2020         Enable the minimal simulator feature flag when appropriate
2021         https://bugs.webkit.org/show_bug.cgi?id=183807
2022
2023         Reviewed by Dan Bernstein.
2024
2025         * Configurations/FeatureDefines.xcconfig:
2026
2027 2018-03-20  Tim Horton  <timothy_horton@apple.com>
2028
2029         Add and adopt WK_PLATFORM_NAME and adjust default feature defines
2030         https://bugs.webkit.org/show_bug.cgi?id=183758
2031         <rdar://problem/38017644>
2032
2033         Reviewed by Dan Bernstein.
2034
2035         * Configurations/FeatureDefines.xcconfig:
2036
2037 2018-03-19  Megan Gardner  <megan_gardner@apple.com>
2038
2039         Clear style colors when setting default appearance
2040         https://bugs.webkit.org/show_bug.cgi?id=183759
2041
2042         Reviewed by Tim Horton.
2043
2044         Colors are cached and need to be cleared and recalculated.
2045         Refactor to do all style recalcs together.
2046
2047         * WebView/WebView.mm:
2048         (-[WebView _setDefaultAppearanceAndClearStyle]):
2049         (-[WebView _setUseSystemAppearance:]):
2050         (-[WebView effectiveAppearanceDidChange]):
2051
2052 2018-03-19  Jiewen Tan  <jiewen_tan@apple.com>
2053
2054         Unreviewed, another quick fix for r229699
2055
2056         Restricts ENABLE_WEB_AUTHN to only macOS and iOS.
2057
2058         * Configurations/FeatureDefines.xcconfig:
2059
2060 2018-03-16  Megan Gardner  <megan_gardner@apple.com>
2061
2062         Ensure that style is updated when the effective appearance changes
2063         https://bugs.webkit.org/show_bug.cgi?id=183690
2064         <rdar://problem/38385900>
2065
2066         Reviewed by Tim Horton and Wenson Hsieh.
2067
2068         Respond to and respect the effective appearance changing.
2069
2070         * WebView/WebView.mm:
2071         (-[WebView _setUseSystemAppearance:]):
2072         (-[WebView effectiveAppearanceDidChange]):
2073
2074 2018-03-15  Megan Gardner  <megan_gardner@apple.com>
2075
2076         Create MediaQueryParserContext to provide additional context for the evaluation of media queries
2077         https://bugs.webkit.org/show_bug.cgi?id=183677
2078
2079         Reviewed by Tim Horton.
2080
2081         We need additional context for parsing media queries to make sure they are parsed correctly and valid.
2082
2083         * DOM/DOM.mm:
2084         (-[DOMHTMLLinkElement _mediaQueryMatches]):
2085
2086 2018-03-14  Tim Horton  <timothy_horton@apple.com>
2087
2088         Fix the build after r229567
2089
2090         * Configurations/FeatureDefines.xcconfig:
2091
2092 2018-03-12  Tim Horton  <timothy_horton@apple.com>
2093
2094         Stop using SDK conditionals to control feature definitions
2095         https://bugs.webkit.org/show_bug.cgi?id=183430
2096         <rdar://problem/38251619>
2097
2098         Reviewed by Dan Bernstein.
2099
2100         * Configurations/FeatureDefines.xcconfig:
2101         * Configurations/WebKitTargetConditionals.xcconfig: Renamed.
2102
2103 2018-03-12  Yoav Weiss  <yoav@yoav.ws>
2104
2105         Runtime flag for link prefetch and remove link subresource.
2106         https://bugs.webkit.org/show_bug.cgi?id=183540
2107
2108         Reviewed by Chris Dumez.
2109
2110         Remove the LINK_PREFETCH build time flag.
2111
2112         * Configurations/FeatureDefines.xcconfig:
2113
2114 2018-03-12  Javier Fernandez  <jfernandez@igalia.com>
2115
2116         Remove GridLayout runtime flag
2117         https://bugs.webkit.org/show_bug.cgi?id=183484
2118
2119         Reviewed by Myles C. Maxfield.
2120
2121         The Grid Layout feature has been enabled by default for almost a
2122         year, so I think it's time to remove the runtime flag and the
2123
2124         * WebView/WebPreferenceKeysPrivate.h:
2125         * WebView/WebPreferences.mm:
2126         (+[WebPreferences initialize]):
2127         * WebView/WebPreferencesPrivate.h:
2128         * WebView/WebView.mm:
2129         (-[WebView _preferencesChanged:]):
2130
2131 2018-03-12  Antoine Quint  <graouts@apple.com>
2132
2133         [Web Animations] Implement CSS Animations and CSS Transitions as Web Animations
2134         https://bugs.webkit.org/show_bug.cgi?id=183504
2135         <rdar://problem/38372965>
2136
2137         Reviewed by Dean Jackson and Jon Lee.
2138
2139         Add the missing WebKitLegacy support the cssAnimationsAndCSSTransitionsBackedByWebAnimationsEnabled flag
2140         which is required for the matching <!-- webkit-test-runner --> flag to work in DumpRenderTree.
2141
2142         * WebView/WebPreferenceKeysPrivate.h:
2143         * WebView/WebPreferences.mm:
2144         (+[WebPreferences initialize]):
2145         (-[WebPreferences setModernMediaControlsEnabled:]):
2146         (-[WebPreferences cssAnimationsAndCSSTransitionsBackedByWebAnimationsEnabled]):
2147         (-[WebPreferences setCSSAnimationsAndCSSTransitionsBackedByWebAnimationsEnabled:]):
2148         * WebView/WebPreferencesPrivate.h:
2149         * WebView/WebView.mm:
2150         (-[WebView _preferencesChanged:]):
2151
2152 2018-03-10  Megan Gardner  <megan_gardner@apple.com>
2153
2154         Media query for default appearance
2155         https://bugs.webkit.org/show_bug.cgi?id=183539
2156         <rdar://problem/38326388>
2157
2158         Reviewed by Tim Horton.
2159
2160         Write a media query to evaluate appearance.
2161
2162         * WebView/WebView.mm:
2163         (-[WebView _commonInitializationWithFrameName:groupName:]):
2164         (-[WebView _setUseSystemAppearance:]):
2165
2166 2018-03-09  Andy Estes  <aestes@apple.com>
2167
2168         [Mac] WebKit fails to receive file promises when the embedding app is sandboxed
2169         https://bugs.webkit.org/show_bug.cgi?id=183489
2170         <rdar://problem/38267517>
2171
2172         WebKitLegacy calls -[NSFilePromiseReceiver receivePromisedFilesAtDestination:...] with
2173         NSTemporaryDirectory() as the destination for receiving file promise drops. AppKit attempts
2174         to issue a sandbox extension for this directory, but for security reasons App Sandbox
2175         refuses to do so for NSTemporaryDirectory() itself. As a result, AppKit will call our reader
2176         block with a nil error and a valid file URL, but no file will actually exist at that URL.
2177
2178         In order for App Sandbox to grant issuing the sandbox extension needed by AppKit, we need to
2179         use some other destination directory. This patch uses FileSystem::createTemporaryDirectory()
2180         to securely create a unique temporary directory inside NSTemporaryDirectory() for use as the
2181         drop destination.
2182
2183         Reviewed by Wenson Hsieh.
2184
2185         * WebView/WebView.mm:
2186         (-[WebView performDragOperation:]):
2187
2188 2018-03-08  Megan Gardner  <megan_gardner@apple.com>
2189
2190         Allow WebViews to disable system appearance
2191         https://bugs.webkit.org/show_bug.cgi?id=183418
2192         <rdar://problem/36975642>
2193
2194         Reviewed by Tim Horton.
2195
2196         Allow webviews to choose whether or not to follow the default system appearance.
2197
2198         * WebView/WebView.mm:
2199         (-[WebView _setUseSystemAppearance:]):
2200         (-[WebView _useSystemAppearance]):
2201         * WebView/WebViewPrivate.h:
2202
2203 2018-03-08  Youenn Fablet  <youenn@apple.com>
2204
2205         libwebrtc update broke internal builds
2206         https://bugs.webkit.org/show_bug.cgi?id=183454
2207
2208         Reviewed by Eric Carlson.
2209
2210         * Configurations/WebKitLegacy.xcconfig:
2211
2212 2018-03-08  Chris Dumez  <cdumez@apple.com>
2213
2214         Possible null dereference of the page under WebFrameNetworkingContext::storageSession()
2215         https://bugs.webkit.org/show_bug.cgi?id=183455
2216         <rdar://problem/38191749>
2217
2218         Reviewed by Youenn Fablet.
2219
2220         Add a null check for the page as we have evidence from crashes that it can be null.
2221         Other functions in WebFrameNetworkingContext already null check the page as well,
2222         not just the frame so this is consistent.
2223
2224         * WebCoreSupport/WebFrameNetworkingContext.mm:
2225         (WebFrameNetworkingContext::storageSession const):
2226
2227 2018-03-08  Yusuke Suzuki  <utatane.tea@gmail.com>
2228
2229         [JSC] Add inherits<T>(VM&) leveraging JSCast fast path
2230         https://bugs.webkit.org/show_bug.cgi?id=183429
2231
2232         Reviewed by Mark Lam.
2233
2234         * DOM/DOM.mm:
2235         (+[DOMNode _nodeFromJSWrapper:]):
2236         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2237         (WebKit::NetscapePluginInstanceProxy::retainLocalObject):
2238         (WebKit::NetscapePluginInstanceProxy::releaseLocalObject):
2239         * Plugins/Hosted/ProxyInstance.mm:
2240         (WebKit::ProxyInstance::invokeMethod):
2241         * WebView/WebView.mm:
2242         (aeDescFromJSValue):
2243
2244 2018-03-08  Tim Horton  <timothy_horton@apple.com>
2245
2246         Stop linking ApplicationServices directly
2247         https://bugs.webkit.org/show_bug.cgi?id=182867
2248         <rdar://problem/38252142>
2249
2250         Reviewed by Alex Christensen.
2251
2252         The frameworks that we use that live inside ApplicationServices
2253         have mostly moved out, so import them directly.
2254
2255         * Carbon/CarbonUtils.h:
2256         * WebKitPrefix.h:
2257         * WebView/WebHTMLView.mm:
2258         * WebView/WebPDFView.mm:
2259
2260 2018-03-07  Tim Horton  <timothy_horton@apple.com>
2261
2262         Sort and separate FeatureDefines.xcconfig
2263         https://bugs.webkit.org/show_bug.cgi?id=183427
2264
2265         Reviewed by Dan Bernstein.
2266
2267         * Configurations/FeatureDefines.xcconfig:
2268         Sort and split FeatureDefines into paragraphs
2269         (to make it easier to sort later).
2270
2271 2018-03-07  Youenn Fablet  <youenn@apple.com>
2272
2273         Match unsupported plugins based on domains and not origin
2274         https://bugs.webkit.org/show_bug.cgi?id=183384
2275
2276         Reviewed by Chris Dumez.
2277
2278         * WebCoreSupport/WebPluginInfoProvider.h:
2279         * WebCoreSupport/WebPluginInfoProvider.mm:
2280         (WebPluginInfoProvider::getPluginInfo):
2281         (WebPluginInfoProvider::getWebVisiblePluginInfo):
2282
2283 2018-03-05  Andy Estes  <aestes@apple.com>
2284
2285         [Mac] Teach WebCore::Pasteboard about file promise drags
2286         https://bugs.webkit.org/show_bug.cgi?id=183314
2287         <rdar://problem/38105493>
2288
2289         Reviewed by Darin Adler.
2290
2291         Added a FIXME comment.
2292
2293         * WebView/WebView.mm:
2294         (-[WebView performDragOperation:]):
2295
2296 2018-03-04  Yusuke Suzuki  <utatane.tea@gmail.com>
2297
2298         [WTF] Move currentCPUTime and sleep(Seconds) to CPUTime.h and Seconds.h respectively
2299         https://bugs.webkit.org/show_bug.cgi?id=183312
2300
2301         Reviewed by Mark Lam.
2302
2303         Remove wtf/CurrentTime.h include pragma.
2304
2305         * WebView/WebFrame.mm:
2306         * WebView/WebPDFView.mm:
2307
2308 2018-03-04  Tim Horton  <timothy_horton@apple.com>
2309
2310         Make !ENABLE(DATA_DETECTION) iOS build actually succeed
2311         https://bugs.webkit.org/show_bug.cgi?id=183283
2312         <rdar://problem/38062148>
2313
2314         Reviewed by Sam Weinig.
2315
2316         * Configurations/FeatureDefines.xcconfig:
2317
2318 2018-02-28  Alex Christensen  <achristensen@webkit.org>
2319
2320         Reduce use of NetworkingContext in WebKit
2321         https://bugs.webkit.org/show_bug.cgi?id=183213
2322
2323         Reviewed by Brady Eidson.
2324
2325         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2326         (WebKit::NetscapePluginInstanceProxy::getProxy):
2327         * Plugins/WebNetscapePluginView.mm:
2328         (-[WebNetscapePluginView getVariable:forURL:value:length:]):
2329
2330 2018-02-17  Darin Adler  <darin@apple.com>
2331
2332         Prepare for ExtendedColor changes (first step)
2333         https://bugs.webkit.org/show_bug.cgi?id=182904
2334
2335         Reviewed by Sam Weinig.
2336
2337         * Misc/WebKitNSStringExtras.mm:
2338         (-[NSString _web_drawAtPoint:font:textColor:]): Use colorFromNSColor.
2339
2340 2018-02-22  Yusuke Suzuki  <utatane.tea@gmail.com>
2341
2342         Remove currentTime() / currentTimeMS()
2343         https://bugs.webkit.org/show_bug.cgi?id=183052
2344
2345         Reviewed by Mark Lam.
2346
2347         * WebCoreSupport/WebFrameLoaderClient.h:
2348         * WebCoreSupport/WebFrameLoaderClient.mm:
2349         (WebFrameLoaderClient::dispatchWillPerformClientRedirect):
2350
2351 2018-02-16  Youenn Fablet  <youenn@apple.com>
2352
2353         Allow specifying which plug-ins are supported
2354         https://bugs.webkit.org/show_bug.cgi?id=182748
2355
2356         Reviewed by Chris Dumez.
2357
2358         * WebCoreSupport/WebPluginInfoProvider.h:
2359         * WebCoreSupport/WebPluginInfoProvider.mm:
2360         (WebPluginInfoProvider::getPluginInfo):
2361         (WebPluginInfoProvider::getWebVisiblePluginInfo):
2362
2363 2018-02-16  Brent Fulgham  <bfulgham@apple.com>
2364
2365         [Cocoa][WebKitLegacy] REGRESSION(r221559): Coda 2 crashes when switching views
2366         https://bugs.webkit.org/show_bug.cgi?id=182882
2367         <rdar://problem/35672661>
2368
2369         Reviewed by Dan Bernstein.
2370
2371         Make sure the smart pointer hold the collection of subviews lives at least as
2372         long as the loop using it.
2373
2374         * WebView/WebHTMLView.mm:
2375         (-[WebHTMLView _web_makePluginSubviewsPerformSelector:withObject:]):
2376
2377 2018-02-14  Daniel Bates  <dabates@apple.com>
2378
2379         Disallow cross-origin subresources from asking for credentials
2380         https://bugs.webkit.org/show_bug.cgi?id=182579
2381         <rdar://problem/36162271>
2382
2383         Reviewed by Andy Estes.
2384
2385         Add a private preference to toggle allowing non-mixed content cross-origin subresources to load.
2386         DumpRenderTree toggles this preference when it sees the test option allowCrossOriginSubresourcesToAskForCredential.
2387
2388         * WebView/WebPreferenceKeysPrivate.h:
2389         * WebView/WebPreferences.mm:
2390         (+[WebPreferences initialize]):
2391         (-[WebPreferences allowCrossOriginSubresourcesToAskForCredentials]):
2392         (-[WebPreferences setAllowCrossOriginSubresourcesToAskForCredentials:]):
2393         * WebView/WebPreferencesPrivate.h:
2394         * WebView/WebView.mm:
2395         (-[WebView _preferencesChanged:]):
2396
2397 2018-02-14  Ross Kirsling  <ross.kirsling@sony.com>
2398
2399         Remove ForwardingHeaders directory from WebKitLegacy/mac.
2400         https://bugs.webkit.org/show_bug.cgi?id=182738
2401
2402         Reviewed by Darin Adler.
2403
2404         * ForwardingHeaders/collector/handles/Global.h: Removed.
2405         * ForwardingHeaders/debugger/DebuggerCallFrame.h: Removed.
2406         * ForwardingHeaders/runtime/Completion.h: Removed.
2407         * ForwardingHeaders/runtime/Error.h: Removed.
2408         * ForwardingHeaders/runtime/JSCJSValue.h: Removed.
2409         * ForwardingHeaders/runtime/JSFunction.h: Removed.
2410         * ForwardingHeaders/runtime/JSLock.h: Removed.
2411         * ForwardingHeaders/runtime/JSObject.h: Removed.
2412         * ForwardingHeaders/runtime/JSString.h: Removed.
2413         * ForwardingHeaders/runtime/Protect.h: Removed.
2414         * ForwardingHeaders/runtime/SymbolTable.h: Removed.
2415
2416 2018-02-09  Per Arne Vollan  <pvollan@apple.com>
2417
2418         Follow-up fixes after moving WebVideoFullscreenController from WebCore to WebKitLegacy.
2419         https://bugs.webkit.org/show_bug.cgi?id=182641
2420
2421         Reviewed by Dan Bernstein.
2422
2423         Remove incorrect use of WEBCORE_EXPORT and namespace WebCore after the files were moved in
2424         https://trac.webkit.org/changeset/228308.
2425
2426         * WebView/WebVideoFullscreenController.h:
2427         * WebView/WebVideoFullscreenHUDWindowController.mm:
2428         * WebView/WebWindowAnimation.h:
2429         * WebView/WebWindowAnimation.mm:
2430         (WebCore::WebWindowAnimationDurationFromDuration): Deleted.
2431         (WebCore::scaledRect): Deleted.
2432         (WebCore::squaredDistance): Deleted.
2433
2434 2018-02-09  Per Arne Vollan  <pvollan@apple.com>
2435
2436         Unreviewed 32-bit build fix after <https://trac.webkit.org/changeset/228308>.
2437
2438         * WebView/WebWindowAnimation.mm:
2439         (-[WebWindowScaleAnimation additionalDurationNeededToReachFinalFrame]):
2440
2441 2018-02-08  Per Arne Vollan  <pvollan@apple.com>
2442
2443         Move WebVideoFullscreenController from WebCore to WebKitLegacy.
2444         https://bugs.webkit.org/show_bug.cgi?id=182615
2445
2446         Reviewed by Eric Carlson.
2447
2448         It is only used by WK1. Also there are a few references to NSApp in WebVideoFullscreenController.mm.
2449         Ideally, we should not reference NSApp in WebCore.
2450
2451         * WebView/WebFullScreenController.mm:
2452         * WebView/WebVideoFullscreenController.h: Copied from Source/WebCore/platform/mac/WebVideoFullscreenController.h.
2453         * WebView/WebVideoFullscreenController.mm: Copied from Source/WebCore/platform/mac/WebVideoFullscreenController.mm.
2454         * WebView/WebVideoFullscreenHUDWindowController.h: Copied from Source/WebCore/platform/mac/WebVideoFullscreenHUDWindowController.h.
2455         * WebView/WebVideoFullscreenHUDWindowController.mm: Copied from Source/WebCore/platform/mac/WebVideoFullscreenHUDWindowController.mm.
2456         * WebView/WebView.mm:
2457         * WebView/WebWindowAnimation.h: Copied from Source/WebCore/platform/mac/WebWindowAnimation.h.
2458         * WebView/WebWindowAnimation.mm: Copied from Source/WebCore/platform/mac/WebWindowAnimation.mm.
2459
2460 2018-01-13  Darin Adler  <darin@apple.com>
2461
2462         Event improvements
2463         https://bugs.webkit.org/show_bug.cgi?id=179591
2464
2465         Reviewed by Chris Dumez.
2466
2467         * DOM/DOMWheelEvent.mm:
2468         (-[DOMWheelEvent initWheelEvent:wheelDeltaY:view:screenX:screenY:clientX:clientY:ctrlKey:altKey:shiftKey:metaKey:]):
2469         Call initWebKitWheelEvent.
2470
2471         * Plugins/Hosted/NetscapePluginInstanceProxy.mm: Removed include of ScriptValue.h.
2472         * WebCoreSupport/WebInspectorClient.mm: Ditto.
2473         * WebView/WebFrame.mm: Ditto.
2474
2475         * WebView/WebHTMLView.mm:
2476         (-[WebHTMLView _interpretKeyEvent:savingCommands:]): Updated for name change from keyEvent to
2477         underlyingPlatformEvent.
2478         (-[WebHTMLView _handleEditingKeyEvent:]): Ditto.
2479
2480         * WebView/WebScriptWorld.mm:
2481         (+[WebScriptWorld scriptWorldForGlobalContext:]): Pass reference to currentWorld function.
2482
2483         * WebView/WebView.mm: Removed include of ScriptValue.h.
2484
2485 2018-02-06  Don Olmstead  <don.olmstead@sony.com>
2486
2487         Remove WebCore/ForwardingHeaders directory
2488         https://bugs.webkit.org/show_bug.cgi?id=182347
2489
2490         Reviewed by Keith Miller.
2491
2492         * Carbon/CarbonWindowAdapter.mm:
2493         * DOM/WebDOMOperations.mm:
2494         * History/WebBackForwardList.mm:
2495         * History/WebHistoryItem.mm:
2496         * Misc/WebCache.mm:
2497         * Misc/WebElementDictionary.mm:
2498         * Misc/WebIconDatabase.mm:
2499         * Misc/WebStringTruncator.mm:
2500         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2501         * Plugins/Hosted/ProxyInstance.mm:
2502         * Plugins/Hosted/ProxyRuntimeObject.mm:
2503         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
2504         * Plugins/WebBaseNetscapePluginView.mm:
2505         * Plugins/WebBasePluginPackage.mm:
2506         * Plugins/WebNetscapePluginStream.mm:
2507         * Plugins/WebNetscapePluginView.mm:
2508         * Plugins/WebPluginController.mm:
2509         * WebCoreSupport/WebEditorClient.mm:
2510         * WebCoreSupport/WebFrameLoaderClient.mm:
2511         * WebCoreSupport/WebInspectorClient.h:
2512         * WebCoreSupport/WebInspectorClient.mm:
2513         * WebView/WebDataSource.mm:
2514         * WebView/WebFrame.mm:
2515         * WebView/WebHTMLRepresentation.mm:
2516         * WebView/WebHTMLView.mm:
2517         * WebView/WebPreferences.mm:
2518         * WebView/WebScriptDebugDelegate.mm:
2519         * WebView/WebScriptDebugger.h:
2520         * WebView/WebTextIterator.mm:
2521         * WebView/WebView.mm:
2522         * WebView/WebViewData.mm:
2523
2524 2018-01-30  Don Olmstead  <don.olmstead@sony.com>
2525
2526         JSExports.h should be included as <JavaScriptCore/JSExportMacros.h>
2527         https://bugs.webkit.org/show_bug.cgi?id=182312
2528
2529         Reviewed by Michael Catanzaro.
2530
2531         * WebKitPrefix.h:
2532
2533 2018-01-29  Jiewen Tan  <jiewen_tan@apple.com>
2534
2535         [WebAuthN] Add a compile-time feature flag
2536         https://bugs.webkit.org/show_bug.cgi?id=182211
2537         <rdar://problem/36936365>
2538
2539         Reviewed by Brent Fulgham.
2540
2541         * Configurations/FeatureDefines.xcconfig:
2542
2543 2018-01-27  Dan Bernstein  <mitz@apple.com>
2544
2545         HaveInternalSDK includes should be "#include?"
2546         https://bugs.webkit.org/show_bug.cgi?id=179670
2547
2548         * Configurations/Base.xcconfig:
2549
2550 2018-01-24  Alex Christensen  <achristensen@webkit.org>
2551
2552         Remove unused QTKit preference
2553         https://bugs.webkit.org/show_bug.cgi?id=181968
2554
2555         Reviewed by Alexey Proskuryakov.
2556
2557         * WebView/WebPreferenceKeysPrivate.h:
2558         * WebView/WebPreferences.mm:
2559         (+[WebPreferences initialize]):
2560         (-[WebPreferences setQTKitEnabled:]): Deleted.
2561         (-[WebPreferences isQTKitEnabled]): Deleted.
2562         * WebView/WebPreferencesPrivate.h:
2563         * WebView/WebView.mm:
2564         (-[WebView _preferencesChanged:]):
2565
2566 2018-01-23  Wenson Hsieh  <wenson_hsieh@apple.com>
2567
2568         Harden against layout passes triggered when iterating through HTMLFormElement::associatedElements
2569         https://bugs.webkit.org/show_bug.cgi?id=182037
2570         <rdar://problem/36747812>
2571
2572         Reviewed by Ryosuke Niwa.
2573
2574         Rename associatedElements() to unsafeAssociatedElements(), and add ScriptDisallowedScopes. See WebCore ChangeLog
2575         for more details.
2576
2577         * WebView/WebHTMLRepresentation.mm:
2578         (-[WebHTMLRepresentation elementWithName:inForm:]):
2579         (-[WebHTMLRepresentation controlsInForm:]):
2580
2581 2018-01-23  Alex Christensen  <achristensen@webkit.org>
2582
2583         Use CompletionHandlers for ResourceHandleClient::didReceiveResponseAsync
2584         https://bugs.webkit.org/show_bug.cgi?id=181961
2585
2586         Reviewed by Michael Catanzaro.
2587
2588         * WebView/WebPreferences.mm:
2589
2590 2018-01-23  Commit Queue  <commit-queue@webkit.org>
2591
2592         Unreviewed, rolling out r227437.
2593         https://bugs.webkit.org/show_bug.cgi?id=182011
2594
2595         broke build (Requested by alexchristensen on #webkit).
2596
2597         Reverted changeset:
2598
2599         "Remove unused QTKit preference"
2600         https://bugs.webkit.org/show_bug.cgi?id=181968
2601         https://trac.webkit.org/changeset/227437
2602
2603 2018-01-23  Alex Christensen  <achristensen@webkit.org>
2604
2605         Remove unused QTKit preference
2606         https://bugs.webkit.org/show_bug.cgi?id=181968
2607
2608         Reviewed by Alexey Proskuryakov.
2609
2610         * WebView/WebPreferenceKeysPrivate.h:
2611         * WebView/WebPreferences.mm:
2612         (+[WebPreferences initialize]):
2613         (-[WebPreferences setQTKitEnabled:]): Deleted.
2614         (-[WebPreferences isQTKitEnabled]): Deleted.
2615         * WebView/WebPreferencesPrivate.h:
2616         * WebView/WebView.mm:
2617         (-[WebView _preferencesChanged:]):
2618
2619 2018-01-22  Wenson Hsieh  <wenson_hsieh@apple.com>
2620
2621         WebViews created via -initSimpleHTMLDocumentWithStyle: don't propagate attachmentElementEnabled state
2622         https://bugs.webkit.org/show_bug.cgi?id=181960
2623         <rdar://problem/36431678>
2624
2625         Reviewed by Tim Horton.
2626
2627         Mail's compose view is initialized via the -initSimpleHTMLDocumentWithStyle: codepath. This is intended to be
2628         a fast path for initializing WebViews, which bypasses certain initialization steps present in the regular -init
2629         path, such as calling -_preferencesChanged: to sync RuntimeEnabledFeatures with WebPreferences.
2630
2631         This means that even though we set -[WebPreferences attachmentElementEnabled] to YES for Mail, the value of the
2632         RuntimeEnabledFeature isn't updated to match. To fix this, we explicitly invoke
2633         RuntimeEnabledFeatures::setAttachmentElementEnabled here to make sure the value is in sync with WebPreferences.
2634
2635         * WebView/WebView.mm:
2636         (-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):
2637
2638 2018-01-21  Ryosuke Niwa  <rniwa@webkit.org>
2639
2640         Turning off custom pasteboard data doesn't actually turn it off in WK2
2641         https://bugs.webkit.org/show_bug.cgi?id=181920
2642         <rdar://problem/36686429>
2643
2644         Reviewed by Wenson Hsieh.
2645
2646         Always disable custom pasteboard data in WebKit1. See r226156 for details.
2647
2648         * WebView/WebPreferences.mm:
2649         (+[WebPreferences initialize]):
2650         * WebView/WebView.mm:
2651         (-[WebView _preferencesChanged:]):
2652
2653 2018-01-21  Wenson Hsieh  <wenson_hsieh@apple.com>
2654
2655         Add a new feature flag for EXTRA_ZOOM_MODE and reintroduce AdditionalFeatureDefines.h
2656         https://bugs.webkit.org/show_bug.cgi?id=181918
2657
2658         Reviewed by Tim Horton.
2659
2660         Add EXTRA_ZOOM_MODE to FeatureDefines.xconfig (off by default).
2661
2662         * Configurations/FeatureDefines.xcconfig:
2663
2664 2018-01-20  Andy Estes  <aestes@apple.com>
2665
2666         [Apple Pay] Stop eagerly loading PassKit.framework
2667         https://bugs.webkit.org/show_bug.cgi?id=181911
2668         <rdar://problem/36555369>
2669
2670         Reviewed by Tim Horton.
2671
2672         * WebCoreSupport/WebPaymentCoordinatorClient.h:
2673         * WebCoreSupport/WebPaymentCoordinatorClient.mm:
2674         (WebPaymentCoordinatorClient::validatedPaymentNetwork):
2675
2676         Implemented PaymentCoordinatorClient::validatedPaymentNetwork().
2677
2678 2018-01-19  Dean Jackson  <dino@apple.com>
2679
2680         REGRESSION (r221092): Swipe actions are hard to perform in FastMail app
2681         https://bugs.webkit.org/show_bug.cgi?id=181817
2682         <rdar://problem/35274055>
2683
2684         Reviewed by Simon Fraser.
2685
2686         Add a linked-on-or-after check to set passive touch listeners on document in WebCore.
2687
2688         * Misc/WebKitVersionChecks.h:
2689         * WebView/WebView.mm:
2690         (-[WebView _commonInitializationWithFrameName:groupName:]):
2691
2692 2018-01-19  Alex Christensen  <achristensen@webkit.org>
2693
2694         Remove unused WebViewPrivate _allowCookies
2695         https://bugs.webkit.org/show_bug.cgi?id=181812
2696
2697         Reviewed by Tim Horton.
2698
2699         * WebView/WebView.mm:
2700         (+[WebView _setAllowCookies:]): Deleted.
2701         (+[WebView _allowCookies]): Deleted.
2702         * WebView/WebViewPrivate.h:
2703
2704 2018-01-18  Alexey Proskuryakov  <ap@apple.com>
2705
2706         Build fix, remove a call to -[NSWindow setOneShot:]
2707         https://bugs.webkit.org/show_bug.cgi?id=181809
2708
2709         Reviewed by Tim Horton.
2710
2711         * WebView/WebTextCompletionController.mm:
2712         (-[WebTextCompletionController _buildUI]):
2713
2714 2018-01-18  Ryan Haddad  <ryanhaddad@apple.com>
2715
2716         Unreviewed, suppress deprecation warnings to fix the build with a newer SDK.
2717
2718         * Carbon/HIWebView.mm:
2719         (overrideCGContext):
2720         (restoreCGContext):
2721
2722 2018-01-18  Dan Bernstein  <mitz@apple.com>
2723
2724         [Xcode] Streamline and future-proof target-macOS-version-dependent build setting definitions
2725         https://bugs.webkit.org/show_bug.cgi?id=181803
2726
2727         Reviewed by Tim Horton.
2728
2729         * Configurations/Base.xcconfig: Updated.
2730         * Configurations/DebugRelease.xcconfig: Ditto.
2731         * Configurations/FeatureDefines.xcconfig: Adopted macOSTargetConditionals helpers.
2732         * Configurations/Version.xcconfig: Updated.
2733         * Configurations/macOSTargetConditionals.xcconfig: Added. Defines helper build settings
2734           useful for defining settings that depend on the target macOS version.
2735
2736 2018-01-17  Youenn Fablet  <youenn@apple.com>
2737
2738         Put fetch Request.keepalive behind a runtime flag
2739         https://bugs.webkit.org/show_bug.cgi?id=181592
2740
2741         Reviewed by Chris Dumez.
2742
2743         * WebView/WebPreferenceKeysPrivate.h:
2744         * WebView/WebPreferences.mm:
2745         (+[WebPreferences initialize]):
2746         (-[WebPreferences fetchAPIKeepAliveEnabled]):
2747         (-[WebPreferences setFetchAPIKeepAliveEnabled:]):
2748         * WebView/WebPreferencesPrivate.h:
2749         * WebView/WebView.mm:
2750         (-[WebView _preferencesChanged:]):
2751
2752 2018-01-17  Wenson Hsieh  <wenson_hsieh@apple.com>
2753
2754         Add injected bundle SPI to replace subresource URLs when dropping or pasting rich content
2755         https://bugs.webkit.org/show_bug.cgi?id=181637
2756         <rdar://problem/36508471>
2757
2758         Reviewed by Tim Horton.
2759
2760         Add a stub implementation of replacementURLForResource. See WebCore and WebKit ChangeLogs for more detail.
2761
2762         * WebCoreSupport/WebEditorClient.h:
2763         * WebCoreSupport/WebEditorClient.mm:
2764         (WebEditorClient::replacementURLForResource):
2765
2766 2018-01-11  Keith Miller  <keith_miller@apple.com>
2767
2768         Rename ENABLE_ASYNC_ITERATION to ENABLE_JS_ASYNC_ITERATION
2769         https://bugs.webkit.org/show_bug.cgi?id=181573
2770
2771         Reviewed by Simon Fraser.
2772
2773         * Configurations/FeatureDefines.xcconfig:
2774
2775 2018-01-11  Wenson Hsieh  <wenson_hsieh@apple.com>
2776
2777         Send PromisedBlobInfo to the client through DragItem instead of DragClient::prepareToDragPromisedBlob
2778         https://bugs.webkit.org/show_bug.cgi?id=181497
2779
2780         Reviewed by Tim Horton.
2781
2782         See other ChangeLogs for more detail.
2783
2784         * WebCoreSupport/WebDragClient.h:
2785
2786 2018-01-11  Tim Horton  <timothy_horton@apple.com>
2787
2788         Null deref in WebImmediateActionController _dictionaryPopupInfoForRange
2789         https://bugs.webkit.org/show_bug.cgi?id=181523
2790         <rdar://problem/28959131>
2791
2792         Reviewed by Alex Christensen.
2793
2794         * WebView/WebImmediateActionController.mm:
2795         (+[WebImmediateActionController _dictionaryPopupInfoForRange:inFrame:withLookupOptions:indicatorOptions:transition:]):
2796         Apply the change made in r216652 to WebKit1's immediate action controller.
2797
2798         Speculative (but successful in WebKit2) fix for non-reproducible crash when
2799         the startContainer of the range is in an anonymous node.
2800
2801 2018-01-11  Youenn Fablet  <youenn@apple.com>
2802
2803         Replace WebRTCLegacyAPIDisabled by WebRTCLegacyAPIEnabled and switch off WebRTC legacy flag by default
2804         https://bugs.webkit.org/show_bug.cgi?id=181480
2805
2806         Reviewed by Eric Carlson.
2807
2808         * WebView/WebPreferences.mm:
2809         (+[WebPreferences initialize]):
2810
2811 2018-01-08  David Kilzer  <ddkilzer@apple.com>
2812
2813         Fix check-webkit-style issues with WebNSDataExtras.mm
2814         <https://webkit.org/b/181369>
2815
2816         Reviewed by Alex Christensen.
2817
2818         * Misc/WebNSDataExtras.mm:
2819         (-[NSString _web_capitalizeRFC822HeaderFieldName]):
2820         (-[NSData _webkit_guessedMIMETypeForXML]):
2821         (-[NSData _webkit_guessedMIMEType]):
2822         (-[NSData _web_isCaseInsensitiveEqualToCString:]):
2823         (_findEOL):
2824         (-[NSData _webkit_parseRFC822HeaderFields]):
2825         (-[NSData _web_locationAfterFirstBlankLine]):
2826         - Fix all the check-webkit-style warnings.
2827
2828 2018-01-08  David Kilzer  <ddkilzer@apple.com>
2829
2830         Build fix #2: Enable -Wcast-qual for WebInspectorUI, WebKitLegacy, WebKit projects
2831         <https://webkit.org/b/181256>
2832         <rdar://problem/36281730>
2833
2834         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
2835         (WebNetscapePluginEventHandlerCocoa::handleTSMEvent):
2836         - Use reinterpret_cast<NPNSString*>(const_cast<CFMutableStringRef>())
2837           to avoid warnings from casting CFStringRef to NPNSString*.
2838           Note that CFMutableStringRef is the same as CFStringRef
2839           without the const modifier, hence its use in the const_cast<>
2840           above.
2841
2842 2018-01-08  David Kilzer  <ddkilzer@apple.com>
2843
2844         Build fix: Enable -Wcast-qual for WebInspectorUI, WebKitLegacy, WebKit projects
2845         <https://webkit.org/b/181256>
2846         <rdar://problem/36281730>
2847
2848         * Carbon/HIWebView.mm:
2849         (StartUpdateObserver): Include TypeCastsCF.h from WTF, and use
2850         checked_cf_cast<CFRunLoopRef>() to fix warning.
2851
2852 2018-01-07  David Kilzer  <ddkilzer@apple.com>
2853
2854         Enable -Wcast-qual for WebInspectorUI, WebKitLegacy, WebKit projects
2855         <https://webkit.org/b/181256>
2856         <rdar://problem/36281730>
2857
2858         Reviewed by Darin Adler.
2859
2860         * Carbon/CarbonUtils.m:
2861         (PoolCleaner):
2862         - Use #pragmas to ignore -Wcast-qual warnings when using a
2863           C-style cast from CFTypeRef to CFRunloopRef.
2864         * Carbon/CarbonWindowFrame.m:
2865         (-[CarbonWindowFrame title]):
2866         - Use #pragmas to ignore -Wcast-qual warnings when using a
2867           C-style cast from CFStringRef to NSString *.
2868         * Carbon/HIViewAdapter.m:
2869         (+[HIViewAdapter getHIViewForNSView:]):
2870         - Use #pragmas to ignore -Wcast-qual warnings when using a
2871           C-style cast from CFTypeRef to HIViewRef.
2872         * Configurations/Base.xcconfig:
2873         (WARNING_CFLAGS): Add -Wcast-qual.
2874         * Misc/WebElementDictionary.mm:
2875         (-[WebElementDictionary objectForKey:]):
2876         - Use static_cast<SEL>(const_cast<void*>()) to fix
2877           warning.
2878         * Misc/WebNSDataExtras.mm: Renamed from Source/WebKitLegacy/mac/Misc/WebNSDataExtras.m.
2879         (-[NSString _web_capitalizeRFC822HeaderFieldName]):
2880         (-[NSData _webkit_guessedMIMETypeForXML]):
2881         (-[NSData _webkit_guessedMIMEType]):
2882         (-[NSData _web_isCaseInsensitiveEqualToCString:]):
2883         (_findEOL):
2884         (-[NSData _webkit_parseRFC822HeaderFields]):
2885         (-[NSData _web_startsWithBlankLine]):
2886         (-[NSData _web_locationAfterFirstBlankLine]):
2887         - Rename WebNSDataExtras.m to WebNSDataExtras.mm and change file
2888           type to Objective-C++.  This fixes the warnings about
2889           discarding the `const` modifier when casing from CFStringRef
2890           to NSString * because in older clang versions, -Wcast-qual was
2891           completely broken when compiling C++ and Objective-C++ source
2892           files.  In newer clang versions, discarding the `const`
2893           modifier for toll-free bridged types is ignored when compiling
2894           Objective-C++ source.
2895         - Update copyright and license header.
2896         - Use reinterpret_cast<> and static_cast<> to fix warnings
2897           unrelated to (NSString *) C-style casts.
2898         - Replace use of MIN() macro with std::min<> template functions.
2899         - Fix location of `*` for local variables modified above.
2900         * Plugins/Hosted/NetscapePluginHostManager.mm:
2901         (WebKit::NetscapePluginHostManager::spawnPluginHost):
2902         (WebKit::NetscapePluginHostManager::initializeVendorPort):
2903         (WebKit::NetscapePluginHostManager::instantiatePlugin):
2904         - Use static_cast<uint8_t*>(const_cast<void*>()) to fix
2905           warnings.
2906         * Plugins/Hosted/NetscapePluginHostProxy.mm:
2907         (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
2908         - Use reinterpret_cast<mig_subsystem_t>(const_cast<struct WKWebKitPluginClient_subsystem*>())
2909           to fix warning.
2910         * Plugins/Hosted/ProxyInstance.mm:
2911         (WebKit::ProxyInstance::invoke):
2912         - Use static_cast<char*>(const_cast<void*>()) to fix
2913           warning when using -[NSData bytes].
2914         (WebKit::ProxyInstance::fieldValue const):
2915         - Use reinterpret_cast<char*>(const_cast<unsigned char*>())
2916           to fix warning when using CFDataGetBytePtr().
2917         * Plugins/Hosted/WebTextInputWindowController.m:
2918         (-[WebTextInputPanel _interpretKeyEvent:string:]):
2919         - Use #pragma to ignore -Wcast-qual warning since there
2920           is not a good way to avoid this warning in Objective-C.
2921         * Plugins/WebNetscapePluginStream.mm:
2922         (WebNetscapePluginStream::deliverData):
2923         - Use const_cast<void*>() to fix warning when using
2924           -[NSData bytes].
2925         * Plugins/WebNetscapePluginView.mm:
2926         (-[WebNetscapePluginView _createPlugin]):
2927         - Change C-style cast to const_cast<char*>() to fix
2928           warning.
2929         * WebCoreSupport/WebChromeClient.mm:
2930         (WebChromeClient::wrapCryptoKey const):
2931         (WebChromeClient::unwrapCryptoKey const):
2932         - Change C-style cast to
2933           static_cast<uint8_t*>(const_cast<void*>() to fix
2934           warning.
2935         * WebView/WebPDFView.mm:
2936         (_applicationInfoForMIMEType):
2937         - Change local variable type from 'NSURL *' to
2938           'CFURLRef' to fix warning.  Cast back to 'NSURL *'
2939           when calling -[NSURL path].
2940
2941 2018-01-05  Dan Bernstein  <mitz@apple.com>
2942
2943         Fixed the build following AppKit API deprecations in a recent SDKs
2944
2945         * WebView/WebFullScreenController.mm:
2946         (-[WebFullScreenController enterFullScreen:]): Suppressed deprecation warnings.
2947         (-[WebFullScreenController exitFullScreen]): Ditto.
2948         (-[WebFullScreenController _startEnterFullScreenAnimationWithDuration:]): Ditto.
2949         (-[WebFullScreenController _startExitFullScreenAnimationWithDuration:]): Ditto.
2950         * WebView/WebHTMLView.mm:
2951         (-[WebHTMLView drawRect:]): Ditto.
2952         (-[WebHTMLView _endPrintModeAndRestoreWindowAutodisplay]): Ditto.
2953         (-[WebHTMLView knowsPageRange:]): Ditto.
2954         * WebView/WebView.mm:
2955         (LayerFlushController::flushLayers): Ditto.
2956
2957 2018-01-03  Wenson Hsieh  <wenson_hsieh@apple.com>
2958
2959         [Attachment Support] Create attachment elements when dropping files on iOS
2960         https://bugs.webkit.org/show_bug.cgi?id=181192
2961         <rdar://problem/36280945>
2962
2963         Reviewed by Tim Horton.
2964
2965         Make some minor adjustments for changes to the pasteboard in WebCore. See WebCore/ChangeLog for more detail.
2966
2967         * WebCoreSupport/WebPlatformStrategies.h:
2968         * WebCoreSupport/WebPlatformStrategies.mm:
2969         (WebPlatformStrategies::informationForItemAtIndex):
2970         (WebPlatformStrategies::getFilenamesForDataInteraction): Deleted.
2971
2972 2018-01-03  Wenson Hsieh  <wenson_hsieh@apple.com>
2973
2974         [Attachment Support] Add plumbing for starting a drag with promised blob data
2975         https://bugs.webkit.org/show_bug.cgi?id=181201
2976
2977         Reviewed by Tim Horton.
2978
2979         Minor adjustment to account for a DragClient interface change. See WebCore ChangeLog for more details.
2980
2981         * WebCoreSupport/WebDragClient.h:
2982
2983 2018-01-02  Jiewen Tan  <jiewen_tan@apple.com>
2984
2985         Add a WebAuthentication runtime feature flag
2986         https://bugs.webkit.org/show_bug.cgi?id=181220
2987         <rdar://problem/36055305>
2988
2989         Reviewed by Brent Fulgham.
2990
2991         Renames the CredentialManagement runtime feature flag into WebAuthentication.
2992
2993         * WebView/WebPreferenceKeysPrivate.h:
2994         * WebView/WebPreferences.mm:
2995         (+[WebPreferences initialize]):
2996         (-[WebPreferences webAuthenticationEnabled]):
2997         (-[WebPreferences setWebAuthenticationEnabled:]):
2998         (-[WebPreferences credentialManagementEnabled]): Deleted.
2999         (-[WebPreferences setCredentialManagementEnabled:]): Deleted.
3000         * WebView/WebPreferencesPrivate.h:
3001         * WebView/WebView.mm:
3002         (-[WebView _preferencesChanged:]):
3003
3004 2017-12-22  Jeff Miller  <jeffm@apple.com>
3005
3006         Update user-visible copyright strings to include 2018
3007         https://bugs.webkit.org/show_bug.cgi?id=181141
3008
3009         Reviewed by Dan Bernstein.
3010
3011         * Info.plist:
3012
3013 2017-12-30  Wenson Hsieh  <wenson_hsieh@apple.com>
3014
3015         [Attachment Support] Remove current macOS support for dragging file-backed attachments
3016         https://bugs.webkit.org/show_bug.cgi?id=181188
3017
3018         Reviewed by Dan Bernstein.
3019
3020         See WebCore/ChangeLog for more detail.
3021
3022         * WebCoreSupport/WebDragClient.h:
3023         * WebCoreSupport/WebDragClient.mm:
3024         (WebDragClient::declareAndWriteAttachment): Deleted.
3025         * WebView/WebHTMLView.mm:
3026         (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
3027
3028 2017-12-22  Wenson Hsieh  <wenson_hsieh@apple.com>
3029
3030         Unreviewed, continue to fix build failures due to AppKit API deprecation
3031
3032         Wraps more code in -Wdeprecated-declarations.
3033
3034         * Carbon/HIWebView.mm:
3035         (overrideCGContext):
3036
3037 2017-12-22  Wenson Hsieh  <wenson_hsieh@apple.com>
3038
3039         Unreviewed, fix build failures due to using deprecated AppKit symbols when building 32-bit
3040
3041         Wrap some more code in -Wdeprecated-declarations to try and fix the 32-bit build using the newest SDK.
3042
3043         * Carbon/CarbonWindowAdapter.mm:
3044         (-[CarbonWindowAdapter setViewsNeedDisplay:]):
3045         * Plugins/WebNetscapePluginView.mm:
3046         (-[WebNetscapePluginView saveAndSetNewPortStateForUpdate:]):
3047         (-[WebNetscapePluginView sendDrawRectEvent:]):
3048         (-[WebNetscapePluginView drawRect:]):
3049
3050 2017-12-22  Wenson Hsieh  <wenson_hsieh@apple.com>
3051
3052         Fix build failures due to using deprecated AppKit symbols
3053         https://bugs.webkit.org/show_bug.cgi?id=181110
3054         <rdar://problem/36162865>
3055
3056         Reviewed by Dan Bernstein and Tim Horton.
3057
3058         See WebCore ChangeLog for more details. Additionally makes a few minor adjustments to pass our style checker.
3059
3060         * Misc/WebKitNSStringExtras.mm:
3061         (-[NSString _web_drawAtPoint:font:textColor:]):
3062         * Misc/WebNSPasteboardExtras.h:
3063         * Misc/WebNSPasteboardExtras.mm:
3064         (+[NSPasteboard _web_writableTypesForURL]):
3065         (_createWritableTypesForImageWithoutArchive):
3066         (_createWritableTypesForImageWithArchive):
3067         (+[NSPasteboard _web_dragTypesForURL]):
3068         (-[NSPasteboard _web_bestURL]):
3069         (-[NSPasteboard _web_writeURL:andTitle:types:]):
3070         (+[NSPasteboard _web_setFindPasteboardString:withOwner:]):
3071         (-[NSPasteboard _web_writeFileWrapperAsRTFDAttachment:]):
3072         (-[NSPasteboard _web_writeImage:element:URL:title:archive:types:source:]):
3073         (-[NSPasteboard _web_declareAndWriteDragImageForElement:URL:title:archive:source:]):
3074         * Panels/WebAuthenticationPanel.m:
3075         (-[WebAuthenticationPanel runAsModalDialogWithChallenge:]):
3076         (-[WebAuthenticationPanel sheetDidEnd:returnCode:contextInfo:]):
3077         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
3078         (-[WebHostedNetscapePluginView drawRect:]):
3079         * WebInspector/WebNodeHighlightView.mm:
3080         (-[WebNodeHighlightView drawRect:]):
3081         * WebView/WebFrame.mm:
3082         (-[WebFrame _updateBackgroundAndUpdatesWhileOffscreen]):
3083         (-[WebFrame _drawRect:contentsOnly:]):
3084         * WebView/WebHTMLView.mm:
3085         (kit):
3086         (-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:]):
3087         (-[WebHTMLView _plainTextFromPasteboard:]):
3088         (-[WebHTMLView _writeSelectionWithPasteboardTypes:toPasteboard:cachedAttributedString:]):
3089         (+[WebHTMLView _insertablePasteboardTypes]):
3090         (+[WebHTMLView _selectionPasteboardTypes]):
3091         (-[WebHTMLView pasteboard:provideDataForType:]):
3092         (-[WebHTMLView _writeSelectionToPasteboard:]):
3093         (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
3094         (-[WebHTMLView validRequestorForSendType:returnType:]):
3095         (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]):
3096         (createMenuItem):
3097         (-[WebHTMLView _fontAttributesFromFontPasteboard]):
3098         (-[WebHTMLView _colorAsString:]):
3099         (-[WebHTMLView copyFont:]):
3100         * WebView/WebPDFView.mm:
3101         (-[WebPDFView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
3102         (-[WebPDFView _recursiveDisplayAllDirtyWithLockFocus:visRect:]):
3103         (-[WebPDFView _recursive:displayRectIgnoringOpacity:inContext:topView:]):
3104         (-[WebPDFView pasteboardTypesForSelection]):
3105         (-[WebPDFView writeSelectionWithPasteboardTypes:toPasteboard:]):
3106         * WebView/WebView.h:
3107         * WebView/WebView.mm:
3108         (-[WebView performDragOperation:]):
3109         (-[WebView validateUserInterfaceItemWithoutDelegate:]):
3110         (-[WebView _searchWithGoogleFromMenu:]):
3111
3112 2017-12-21  Youenn Fablet  <youenn@apple.com>
3113
3114         ServiceWorkerThreadProxy should set the correct cookie and cache partitioning options
3115         https://bugs.webkit.org/show_bug.cgi?id=181000
3116
3117         Reviewed by Chris Dumez.
3118
3119         * Misc/WebCache.mm:
3120         (+[WebCache addImageToCache:forURL:forFrame:]):
3121
3122 2017-12-21  Jeremy Jones  <jeremyj@apple.com>
3123
3124         Update FULLSCREEN_API feature defines.
3125         https://bugs.webkit.org/show_bug.cgi?id=181015
3126
3127         Reviewed by Tim Horton.
3128
3129         Change enabled iphone sdk for FULLSCREEN_API.
3130
3131         * Configurations/FeatureDefines.xcconfig:
3132
3133 2017-12-21  Jer Noble  <jer.noble@apple.com>
3134
3135         Add initial DOM support for Media Capabilities
3136         https://bugs.webkit.org/show_bug.cgi?id=181064
3137
3138         Reviewed by Eric Carlson.
3139
3140         Add a new preference to enable the (disabled-by-default) Media Capabilities API.
3141
3142         * WebView/WebPreferenceKeysPrivate.h:
3143         * WebView/WebPreferences.mm:
3144         (+[WebPreferences initialize]):
3145         (-[WebPreferences mediaCapabilitiesEnabled]):
3146         (-[WebPreferences setMediaCapabilitiesEnabled:]):
3147         * WebView/WebPreferencesPrivate.h:
3148         * WebView/WebView.mm:
3149         (-[WebView _preferencesChanged:]):
3150
3151 2017-12-21  Jeremy Jones  <jeremyj@apple.com>
3152
3153         Enable picture-in-picture from inline element on suspend.
3154         https://bugs.webkit.org/show_bug.cgi?id=180942
3155         rdar://problem/34745234
3156
3157         Reviewed by Jer Noble.
3158
3159         Update signature of enterVideoFullscreenForVideoElement().
3160
3161         * WebCoreSupport/WebChromeClient.h:
3162         * WebCoreSupport/WebChromeClient.mm:
3163         (WebChromeClient::enterVideoFullscreenForVideoElement):
3164
3165 2017-12-20  Daniel Bates  <dabates@apple.com>
3166
3167         Remove Alternative Presentation Button
3168         https://bugs.webkit.org/show_bug.cgi?id=180500
3169         <rdar://problem/35891047>
3170
3171         Reviewed by Simon Fraser.
3172
3173         We no longer need the alternative presentation button.
3174
3175         * Configurations/FeatureDefines.xcconfig:
3176
3177 2017-12-19  Jer Noble  <jer.noble@apple.com>
3178
3179         Playing media elements which call "pause(); play()" will have the play promise rejected.
3180         https://bugs.webkit.org/show_bug.cgi?id=180781
3181         <rdar://problem/33191377>
3182
3183         Reviewed by Eric Carlson.
3184
3185         shouldRequireUserGestureToLoadVideo() should default to false on Mac.
3186
3187         * WebView/WebView.mm:
3188         (shouldRequireUserGestureToLoadVideo):
3189
3190 2017-12-19  Wenson Hsieh  <wenson_hsieh@apple.com>
3191
3192         API test WKAttachmentTests.InsertPastedAttributedStringContainingMultipleAttachments is failing on El Capitan and Sierra
3193         https://bugs.webkit.org/show_bug.cgi?id=180977
3194
3195         Reviewed by Tim Horton.
3196
3197         Fixes a failing API test by updating markup deserialization codepaths in WebKitLegacy to behave like the modern
3198         WebCore counterpart. When determining element tags to exclude when generating markup from an attributed string,
3199         don't add "object" as an element to exclude if the attachment element runtime feature is enabled.
3200
3201         * WebCoreSupport/WebEditorClient.mm:
3202         (attributesForAttributedStringConversion):
3203         * WebView/WebHTMLView.mm:
3204         (+[WebHTMLView _excludedElementsForAttributedStringConversion]):
3205
3206 2017-12-18  David Kilzer  <ddkilzer@apple.com>
3207
3208         BUILD FIX: Ignore NSWindow deprecation warnings from the mysterious future
3209
3210         Attempt to fix the following warnings:
3211
3212             AppKit instance variables are private, and the ability to access them will be removed in a future release. [-Werror,-Wdeprecated-declarations]
3213
3214         For the following instance variables:
3215
3216             _borderView
3217             _contentView
3218             _frame
3219             _wFlags
3220
3221         * Carbon/CarbonWindowAdapter.mm:
3222         (-[CarbonWindowAdapter initWithCarbonWindowRef:takingOwnership:disableOrdering:carbon:]):
3223         (-[CarbonWindowAdapter reconcileToCarbonWindowBounds]):
3224         (-[CarbonWindowAdapter _termWindowIfOwner]):
3225         (-[CarbonWindowAdapter _windowMovedToRect:]):
3226         (-[CarbonWindowAdapter setContentView:]):
3227         (-[CarbonWindowAdapter _handleRootBoundsChanged]):
3228         (-[CarbonWindowAdapter _handleContentBoundsChanged]):
3229
3230 2017-12-16  Dan Bernstein  <mitz@apple.com>
3231
3232         WKWebView has no equivalent of -[WebView setAlwaysShowVerticalScroller:]
3233         https://bugs.webkit.org/show_bug.cgi?id=180613
3234         <rdar://problem/35946124>
3235
3236         Reviewed by Geoff Garen.
3237
3238         * WebKit.mac.exp: Removed WebCoreScrollbarAlwaysOn, which is no longer being used by any
3239           clients.
3240         * WebView/WebDynamicScrollBarsView.h: Ditto.
3241         * WebView/WebDynamicScrollBarsView.mm: Ditto.
3242
3243 2017-12-14  David Kilzer  <ddkilzer@apple.com>
3244
3245         Enable -Wstrict-prototypes for WebKit
3246         <https://webkit.org/b/180757>
3247         <rdar://problem/36024132>
3248
3249         Rubber-stamped by Joseph Pecoraro.
3250
3251         * Configurations/Base.xcconfig:
3252         (CLANG_WARN_STRICT_PROTOTYPES): Add. Set to YES.
3253
3254 2017-12-14  John Wilander  <wilander@apple.com>
3255
3256         Storage Access API: Implement frame-specific access in the document.cookie layer
3257         https://bugs.webkit.org/show_bug.cgi?id=180682
3258         <rdar://problem/35982257>
3259
3260         Reviewed by Alex Christensen.
3261
3262         CookiesStrategy::cookiesForDOM(), CookiesStrategy::setCookiesFromDOM(),
3263         CookiesStrategy::cookieRequestHeaderFieldValue(), and
3264         CookiesStrategy::getRawCookies() now take optional parameters for
3265         frameID and pageID to allow frame-specific scoping of cookies.
3266
3267         This change makes the return values of FrameLoaderClient::frameID()
3268         and FrameLoaderClient::pageID() std::optional<uint64_t> so that
3269         WebCore can call those getters and get the right return values in
3270         WebKit and std:nullopt in WebKitLegacy.
3271
3272         * WebCoreSupport/WebFrameLoaderClient.h:
3273         * WebCoreSupport/WebFrameLoaderClient.mm:
3274         (WebFrameLoaderClient::pageID const):
3275         (WebFrameLoaderClient::frameID const):
3276         * WebCoreSupport/WebPlatformStrategies.h:
3277         * WebCoreSupport/WebPlatformStrategies.mm:
3278         (WebPlatformStrategies::cookiesForDOM):
3279         (WebPlatformStrategies::setCookiesFromDOM):
3280         (WebPlatformStrategies::cookieRequestHeaderFieldValue):
3281         (WebPlatformStrategies::getRawCookies):
3282
3283 2017-12-12  Simon Fraser  <simon.fraser@apple.com>
3284
3285         Remove ColorSpaceDeviceRGB and most users of the obsolete deviceRGB colorspace
3286         https://bugs.webkit.org/show_bug.cgi?id=180689
3287
3288         Reviewed by Tim Horton.
3289
3290         Use sRGBColorSpaceRef() from WebCore.
3291
3292         * WebView/WebHTMLView.mm:
3293         (imageFromRect):
3294
3295 2017-12-11  Tim Horton  <timothy_horton@apple.com>
3296
3297         Stop using deprecated target conditional for simulator builds
3298         https://bugs.webkit.org/show_bug.cgi?id=180662
3299         <rdar://problem/35136156>
3300
3301         Reviewed by Simon Fraser.
3302
3303         * postprocess-headers.sh:
3304
3305 2017-12-11  David Quesada  <david_quesada@apple.com>
3306
3307         Turn on ENABLE_APPLICATION_MANIFEST
3308         https://bugs.webkit.org/show_bug.cgi?id=180562
3309         rdar://problem/35924737
3310
3311         Reviewed by Geoffrey Garen.
3312
3313         * Configurations/FeatureDefines.xcconfig:
3314
3315 2017-12-08  Yusuke Suzuki  <utatane.tea@gmail.com>
3316
3317         Remove pthread_once in favor of dispatch_once
3318         https://bugs.webkit.org/show_bug.cgi?id=180591
3319
3320         Reviewed by Saam Barati.
3321
3322         * Misc/WebKitErrors.m:
3323         (+[NSError _registerWebKitErrors]):
3324         (registerErrors): Deleted.
3325         * Storage/WebStorageManager.mm:
3326         (+[WebStorageManager _storageDirectoryPath]):
3327         (initializeLocalStoragePath): Deleted.
3328
3329 2017-12-07  Darin Adler  <darin@apple.com>
3330
3331         Remove some unused code from WebKitLegacy
3332         https://bugs.webkit.org/show_bug.cgi?id=180567
3333
3334         Reviewed by Anders Carlsson.
3335
3336         * Misc/WebKitNSStringExtras.h: Researched which of these functions are used in
3337         macOS (back a few versions) and iOS and removed unused
3338         _web_drawAtPoint:font:textColor:allowingFontSmoothing:,
3339         _web_drawDoubledAtPoint:withTopColor:bottomColor:font:,
3340         _web_stringByStrippingReturnCharacters, _webkit_hasCaseInsensitiveSubstring:,
3341         _webkit_stringByCollapsingNonPrintingCharacters,
3342         _webkit_stringByCollapsingWhitespaceCharacters,
3343         _web_stringWithData:textEncodingName:, and
3344         _webkit_localStorageDirectoryWithBundleIdentifier:.
3345
3346         * Misc/WebKitNSStringExtras.mm: Made WebKitLocalCacheDefaultsKey private to
3347         this source file.
3348         (canUseFastRenderer): Made this faster by not calling u_charDirection for
3349         Latin-1 characters, and also added special cases for U_DIR_NON_SPACING_MARK
3350         and U_BOUNDARY_NEUTRAL, which should not prevent use of the fast renderer.
3351         (-[NSString _web_drawAtPoint:font:textColor:allowingFontSmoothing:]): Deleted.
3352         (-[NSString _web_drawAtPoint:font:textColor:]): Removed unneeded code to
3353         handle font smoothing options.
3354         (-[NSString _web_drawDoubledAtPoint:withTopColor:bottomColor:font:]): Deleted.
3355         (-[NSString _web_stringByAbbreviatingWithTildeInPath]): Moved comment here
3356         from header and made it a little clearer.
3357         (-[NSString _web_stringByStrippingReturnCharacters]): Deleted.
3358         (-[NSString _webkit_hasCaseInsensitiveSubstring:]): Deleted.
3359         (-[NSString _webkit_stringByCollapsingNonPrintingCharacters]): Deleted.
3360         (-[NSString _webkit_stringByCollapsingWhitespaceCharacters]): Deleted.
3361         (+[NSString _web_stringWithData:textEncodingName:]): Deleted.
3362         (+[NSString _webkit_localCacheDirectoryWithBundleIdentifier:]): Streamlined
3363         implementation a bit and used whole words instead of abbreviations.
3364         (+[NSString _webkit_localStorageDirectoryWithBundleIdentifier:]): Deleted.
3365
3366         * Misc/WebNSFileManagerExtras.mm:
3367         (-[NSFileManager _webkit_pathWithUniqueFilenameForPath:]): Use the
3368         filenameByFixingIllegalCharacters function from WebCore directly instead of
3369         indirectly through the method _webkit_filenameByFixingIllegalCharacters.
3370
3371         * Plugins/WebBaseNetscapePluginView.mm:
3372         (-[WebBaseNetscapePluginView URLWithCString:]): Rewrote to use simple
3373         string replacements instead of _web_stringByStrippingReturnCharacters
3374         and to use NSString methods instead of CFString functions.
3375
3376 2017-12-07  Jessie Berlin  <jberlin@webkit.org>
3377
3378         Ignore deprecation warnings.
3379
3380         * WebView/WebHTMLView.mm:
3381         (-[NSWindow _web_borderView]):
3382         (-[WebHTMLView _setAsideSubviews]):
3383         * WebView/WebView.mm:
3384         (-[WebView encodeWithCoder:]):
3385
3386 2017-12-02  Darin Adler  <darin@apple.com>
3387
3388         Modernize some aspects of text codecs, eliminate WebKit use of strcasecmp
3389         https://bugs.webkit.org/show_bug.cgi?id=180009
3390
3391         Reviewed by Alex Christensen.
3392
3393         * History/HistoryPropertyList.mm: Removed include of StringExtras.h.
3394
3395         * Plugins/WebBaseNetscapePluginView.mm:
3396         (WebKit::getAuthenticationInfo): Use equalLettersIgnoringASCIICase instead
3397         of strcasecmp.
3398
3399         * WebView/WebPreferences.mm:
3400         (contains): Ditto. Also made this a template so it's easier to call on an array.
3401         (cacheModelForMainBundle): Take advantage of the above to make it cleaner.
3402
3403 2017-12-05  Brent Fulgham  <bfulgham@apple.com>
3404
3405         Limit user agent versioning to an upper bound
3406         https://bugs.webkit.org/show_bug.cgi?id=180365
3407         <rdar://problem/34550617>
3408
3409         Reviewed by Joseph Pecoraro.
3410
3411         * WebView/WebView.mm:
3412         (+[WebView _standardUserAgentWithApplicationName:]): Don't pass the WebKit bundle version when
3413         creating the User Agent string.
3414         (webKitBundleVersionString): Deleted.
3415
3416 2017-12-05  Andy Estes  <aestes@apple.com>
3417
3418         [Cocoa] Stop specifying TARGET_OS_EMBEDDED in postprocess-headers.sh's unifdef options
3419         https://bugs.webkit.org/show_bug.cgi?id=180457
3420         <rdar://problem/35143007>
3421
3422         Reviewed by Tim Horton.
3423
3424         None of WebKitLegacy's framework headers mention TARGET_OS_EMBEDDED, so there's no need to
3425         check for this macro during post-processing.
3426
3427         * postprocess-headers.sh:
3428
3429 2017-12-04  David Quesada  <david_quesada@apple.com>
3430
3431         Add a class for parsing application manifests
3432         https://bugs.webkit.org/show_bug.cgi?id=177973
3433         rdar://problem/34747949
3434
3435         Reviewed by Geoffrey Garen.
3436
3437         * Configurations/FeatureDefines.xcconfig: Add ENABLE_APPLICATION_MANIFEST feature flag.
3438
3439 2017-11-30  Stephan Szabo  <stephan.szabo@sony.com>
3440
3441         Make LegacyCustomProtocolManager optional for network process
3442         https://bugs.webkit.org/show_bug.cgi?id=176230
3443
3444         Reviewed by Alex Christensen.
3445
3446         * Configurations/FeatureDefines.xcconfig:
3447
3448 2017-11-30  Joseph Pecoraro  <pecoraro@apple.com>
3449
3450         Fix some NSOperationQueue leaks
3451         https://bugs.webkit.org/show_bug.cgi?id=180221
3452
3453         Reviewed by Wenson Hsieh.
3454
3455         * WebView/WebView.mm:
3456         (-[WebView performDragOperation:]):
3457
3458 2017-11-30  Darin Adler  <darin@apple.com>
3459
3460         [Mac] remove unneeded RetainPtr use introduced in r225142
3461         https://bugs.webkit.org/show_bug.cgi?id=180202
3462
3463         Reviewed by Tim Horton.
3464
3465         * WebView/WebImmediateActionController.mm:
3466         (-[WebImmediateActionController _animationControllerForText]): Got rid of unnecessary
3467         RetainPtr.
3468
3469 2017-11-29  Said Abou-Hallawa  <sabouhallawa@apple.com>
3470
3471         Remove the ImageSource from the class hierarchy that connects BitmapImage to ImageFrame
3472         https://bugs.webkit.org/show_bug.cgi?id=175595
3473
3474         Reviewed by Darin Adler.
3475
3476         * WebView/WebPreferences.mm:
3477
3478 2017-11-27  Tim Horton  <timothy_horton@apple.com>
3479
3480         One too many zeroes in macOS version number in FeatureDefines
3481         https://bugs.webkit.org/show_bug.cgi?id=180011
3482