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