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