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