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