-
Notifications
You must be signed in to change notification settings - Fork 1.2k
/
ChangeLog
14592 lines (11136 loc) · 673 KB
/
ChangeLog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
2018-04-02 Beth Dakin <bdakin@apple.com>
Fix the managed configurations build
https://bugs.webkit.org/show_bug.cgi?id=184253
-and corresponding-
rdar://problem/39078586
Reviewed by Dan Bernstein.
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView canPerformActionForWebView:withSender:]):
(-[WKContentView _defineForWebView:]):
2018-04-02 Carlos Garcia Campos <cgarcia@igalia.com>
[Enchant] Clean up TextCheckerEnchant
https://bugs.webkit.org/show_bug.cgi?id=184233
Reviewed by Michael Catanzaro.
Use TextCheckerEnchant as a singleton now, instead of implementing the singleton here.
* UIProcess/gtk/TextCheckerGtk.cpp:
(WebKit::TextChecker::checkSpellingOfString):
(WebKit::TextChecker::getGuessesForWord):
(WebKit::TextChecker::learnWord):
(WebKit::TextChecker::ignoreWord):
(WebKit::TextChecker::setSpellCheckingLanguages):
(WebKit::TextChecker::loadedSpellCheckingLanguages):
(WebKit::enchantTextChecker): Deleted.
2018-04-03 Carlos Garcia Campos <cgarcia@igalia.com>
[GTK] NetworkProcess from WebKitGtk+ 2.19.9x SIGSEVs in NetworkStorageSession (secret search callback)
https://bugs.webkit.org/show_bug.cgi?id=183346
Reviewed by Michael Catanzaro.
Pass the request cancellable to NetworkStorageSession::getCredentialFromPersistentStorage().
* NetworkProcess/soup/NetworkDataTaskSoup.cpp:
(WebKit::NetworkDataTaskSoup::authenticate):
2018-04-02 Brady Eidson <beidson@apple.com>
Process swapping on navigation needs to handle server redirects.
<rdar://problem/38690465> and https://bugs.webkit.org/show_bug.cgi?id=184142
Reviewed by Alex Christensen.
The same rules we apply to process swapping for basic navigations need to apply
to server redirects as well.
There's three interesting cases we need to support that are covered by new API tests:
1 - The initial load in a WKWebView redirects cross-origin.
2 - A WKWebView is showing content from a.com, we start a load to b.com, and that redirects to c.com
3 - A WKWebView is showing content from a.com, we start a load to a.com, that that redirects to b.com.
Supporting all 3 of these brought their own little challenges.
By teaching Navigation objects more about redirects I was able to support all 3 cases.
* UIProcess/API/APINavigation.cpp:
(API::Navigation::Navigation):
(API::Navigation::setCurrentRequest):
(API::Navigation::appendRedirectionURL):
(API::Navigation::loggingString const):
(API::Navigation::loggingURL const): Deleted.
* UIProcess/API/APINavigation.h:
(API::Navigation::originalRequest const):
(API::Navigation::currentRequest const):
(API::Navigation::currentRequestProcessIdentifier const):
(API::Navigation::setCurrentRequestIsRedirect):
(API::Navigation::currentRequestIsRedirect const):
(API::Navigation::request const): Deleted.
* UIProcess/API/Cocoa/WKNavigation.mm:
(-[WKNavigation _request]):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::receivedPolicyDecision):
(WebKit::WebPageProxy::continueNavigationInNewProcess): If this continued navigation is currently in a server
redirect, save off a lambda to synthesize a "did receive server redirect" callback once the new WebProcess is running.
(WebKit::WebPageProxy::didCreateMainFrame):
(WebKit::WebPageProxy::didStartProvisionalLoadForFrame): Possibly ignore this notification if it is really a
cross-origin redirect that is just starting back up in a new WebProcess.
(WebKit::WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame):
(WebKit::WebPageProxy::didCommitLoadForFrame):
(WebKit::WebPageProxy::decidePolicyForNavigationAction):
(WebKit::WebPageProxy::resetStateAfterProcessExited): Do not clear pageLoadState if the process is exitting for
a navigation swap, as we will need to pick up where we left off when the load continues in a new WebProcess.
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::processForNavigation): If a process has never committed any provisional load, it can always
be used to continue a navigation.
* UIProcess/WebProcessPool.h:
* UIProcess/WebProcessProxy.h:
(WebKit::WebProcessProxy::didCommitProvisionalLoad):
(WebKit::WebProcessProxy::hasCommittedAnyProvisionalLoads const):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
2018-04-02 Eric Carlson <eric.carlson@apple.com>
[Extra zoom mode] Replace video with a placeholder image during fullscreen transition
https://bugs.webkit.org/show_bug.cgi?id=184188
<rdar://problem/38940307>
Reviewed by Youenn Fablet.
* UIProcess/Cocoa/VideoFullscreenManagerProxy.h:
* UIProcess/Cocoa/VideoFullscreenManagerProxy.messages.in:
* UIProcess/Cocoa/VideoFullscreenManagerProxy.mm:
(WebKit::VideoFullscreenModelContext::willExitFullscreen):
(WebKit::VideoFullscreenManagerProxy::preparedToExitFullscreen):
(WebKit::VideoFullscreenManagerProxy::willExitFullscreen):
* WebProcess/cocoa/VideoFullscreenManager.h:
* WebProcess/cocoa/VideoFullscreenManager.messages.in:
* WebProcess/cocoa/VideoFullscreenManager.mm:
(WebKit::VideoFullscreenManager::willExitFullscreen):
2018-04-02 Brian Burg <bburg@apple.com>
[Cocoa] Fix some internal builds that consume WebDriver atoms
https://bugs.webkit.org/show_bug.cgi?id=184197
Reviewed by Dan Bernstein.
* WebKit.xcodeproj/project.pbxproj:
Use a Run Script phase to copy WebDriver atoms to WebKit.framework
private headers during the installhdrs phase.
2018-04-02 Ryan Haddad <ryanhaddad@apple.com>
Unreviewed, rolling out r230174.
Caused LayoutTests to exit early with assertion failures.
Reverted changeset:
"Process swapping on navigation needs to handle server
redirects."
https://bugs.webkit.org/show_bug.cgi?id=184142
https://trac.webkit.org/changeset/230174
2018-04-02 Wenson Hsieh <wenson_hsieh@apple.com>
[Extra zoom mode] Update date picker UI to latest specifications
https://bugs.webkit.org/show_bug.cgi?id=184234
<rdar://problem/38804760>
Reviewed by Timothy Hatcher.
Rename WKTextFormControlListViewControllerDelegate to WKTextInputListViewControllerDelegate and adjust for the
new initializer of WKDatePickerViewController.
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView presentViewControllerForCurrentAssistedNode]):
2018-04-02 Brady Eidson <beidson@apple.com>
Process swapping on navigation needs to handle server redirects.
<rdar://problem/38690465> and https://bugs.webkit.org/show_bug.cgi?id=184142
Reviewed by Alex Christensen.
The same rules we apply to process swapping for basic navigations need to apply
to server redirects as well.
There's three interesting cases we need to support that are covered by new API tests:
1 - The initial load in a WKWebView redirects cross-origin.
2 - A WKWebView is showing content from a.com, we start a load to b.com, and that redirects to c.com
3 - A WKWebView is showing content from a.com, we start a load to a.com, that that redirects to b.com.
Supporting all 3 of these brought their own little challenges.
By teaching Navigation objects more about redirects I was able to support all 3 cases.
* UIProcess/API/APINavigation.cpp:
(API::Navigation::Navigation):
(API::Navigation::setCurrentRequest):
(API::Navigation::appendRedirectionURL):
(API::Navigation::loggingString const):
(API::Navigation::loggingURL const): Deleted.
* UIProcess/API/APINavigation.h:
(API::Navigation::originalRequest const):
(API::Navigation::currentRequest const):
(API::Navigation::currentRequestProcessIdentifier const):
(API::Navigation::setCurrentRequestIsRedirect):
(API::Navigation::currentRequestIsRedirect const):
(API::Navigation::request const): Deleted.
* UIProcess/API/Cocoa/WKNavigation.mm:
(-[WKNavigation _request]):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::receivedPolicyDecision):
(WebKit::WebPageProxy::continueNavigationInNewProcess): If this continued navigation is currently in a server
redirect, save off a lambda to synthesize a "did receive server redirect" callback once the new WebProcess is running.
(WebKit::WebPageProxy::didCreateMainFrame):
(WebKit::WebPageProxy::didStartProvisionalLoadForFrame): Possibly ignore this notification if it is really a
cross-origin redirect that is just starting back up in a new WebProcess.
(WebKit::WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame):
(WebKit::WebPageProxy::didCommitLoadForFrame):
(WebKit::WebPageProxy::decidePolicyForNavigationAction):
(WebKit::WebPageProxy::resetStateAfterProcessExited): Do not clear pageLoadState if the process is exitting for
a navigation swap, as we will need to pick up where we left off when the load continues in a new WebProcess.
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::processForNavigation): If a process has never committed any provisional load, it can always
be used to continue a navigation.
* UIProcess/WebProcessPool.h:
* UIProcess/WebProcessProxy.h:
(WebKit::WebProcessProxy::didCommitProvisionalLoad):
(WebKit::WebProcessProxy::hasCommittedAnyProvisionalLoads const):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
2018-04-02 Wenson Hsieh <wenson_hsieh@apple.com>
[Extra zoom mode] Zoom level is sometimes excessive when zooming to focused form controls
https://bugs.webkit.org/show_bug.cgi?id=184222
<rdar://problem/39063886>
Reviewed by Timothy Hatcher.
Upon interactively focusing an element, we zoom and scroll to reveal that element. The heuristics introduced in
<https://trac.webkit.org/r168744> work by computing a target scale, and then a point to zoom to given that
scale. Currently, this scale is dependent on the computed font size of the form control, such that the form
control would be scaled to have an effective font size of 16.
However, in extra zoom mode, applying these same heuristics (ironically) results in excessive zoom levels, since
scaling the font up to 16 would cause most form controls to zoom so far in that we lose context of surrounding
elements such as labels and other form controls; the fact that the element is highlighted by the focused form
control overlay makes this even more confusing, since part of the focus overlay highlight rect often ends up
outside the viewport.
To fix this, we make a couple of tweaks to focus rect zooming in extra zoom mode. (1) Instead of computing
target zoom level based on font size, try to zoom such that the focused element rect fills up most of the
viewport (similar to double-tap zooming). This ensures that the focused form control overlay's highlight rect
makes sense in most cases, with few exceptions (e.g. the element frame is larger than the viewport). (2)
Introduce a minimum legible font size of 11, and compute the minimium scale needed such that the form control
font would appear to be at least this legible font size. Then, clamp the target scale chosen by (1) to this
minimum scale.
One additional consideration for (1) is that naively scaling to fit the element rect to the viewport (with some
fixed margins) would cause the viewport scale to always change when moving focus between form controls of
different dimensions, even if the current scale is more or less appropriate for all the focusable elements. To
address this, instead of computing a single target zoom scale for an element rect, compute a range of possible
target zoom scales (where the minimum and maximum values depend on the margin we add around the element rect).
If the current scale already falls within this target scale range, then we won't bother adjusting the scale at
all (unless the font size is too small — see (2)). If the current scale falls outside the target scale range, we
then make the minimal adjustment needed to ensure that the element rect fits well within the viewport without
being too small.
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _zoomToFocusRect:selectionRect:insideFixed:fontSize:minimumScale:maximumScale:allowScaling:forceScroll:]):
Move some logic around so that the target scale is computed after computing the visible size. Also renames some
constants local to this function (WKWebViewStandardFontSize, kMinimumHeightToShowContentAboveKeyboard,
UIWebFormAnimationDuration, CaretOffsetFromWindowEdge) such that they now share a consistent naming style.
2018-04-02 Jer Noble <jer.noble@apple.com>
Enable Legacy EME for all WebKit & WebKitLegacy clients
https://bugs.webkit.org/show_bug.cgi?id=184018
<rdar://problem/34887387>
Reviewed by Eric Carlson.
* Shared/WebPreferences.yaml:
* Shared/WebPreferencesDefaultValues.h:
2018-04-02 Jer Noble <jer.noble@apple.com>
REGRESSION (229680): Fullscreen video does not work (youtube, netflix)
https://bugs.webkit.org/show_bug.cgi?id=184235
Reviewed by Eric Carlson.
Enable the Fullscreen API by default.
* Shared/WebPreferences.yaml:
* Shared/WebPreferencesDefaultValues.h:
2018-04-02 Fujii Hironori <Hironori.Fujii@sony.com>
[Win] MSVC can't compile WebResourceLoadStatisticsStore::scheduleClearInMemoryAndPersistent
https://bugs.webkit.org/show_bug.cgi?id=184120
Reviewed by Alex Christensen.
It seems that MSVC can't compile the code using `this` in a
generalized lambda capture in another lambda.
In this case, there is no need to copy `protectedThis` for the
inner lambda. Move `protectedThis` of the outer lambda to the
inner as well as `callback`.
* UIProcess/WebResourceLoadStatisticsStore.cpp:
(WebKit::WebResourceLoadStatisticsStore::scheduleClearInMemoryAndPersistent):
Moved `protectedThis` from the outer lambda to the inner.
2018-04-02 Dan Bernstein <mitz@apple.com>
Build fix after r230121
* Configurations/WebKit.xcconfig: Disabled framework header postprocessing when building for
iOS 11.*
* UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h: Reverted r230159.
2018-04-02 Dan Bernstein <mitz@apple.com>
Fixed the build when BOOL is not bool.
<rdar://problem/39094484>
Reviewed by Jer Noble.
* UIProcess/ios/fullscreen/WKFullScreenViewController.mm:
(-[WKFullScreenViewController videoControlsManagerDidChange]): Removed the write-only ivar
_hasControlsManager, the assignment to which was causing the compiler error.
2018-04-02 Ryan Haddad <ryanhaddad@apple.com>
Unreviewed build fix.
* UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h: Update availability annotation.
2018-04-02 Michael Catanzaro <mcatanzaro@igalia.com>
[GTK] DragAndDropHandler.cpp should include GUniquePtrGtk.h
https://bugs.webkit.org/show_bug.cgi?id=184119
Reviewed by Daniel Bates.
* UIProcess/gtk/DragAndDropHandler.cpp:
2018-04-02 Frederic Wang <fwang@igalia.com>
Fix warnings for unused lambda captures in Source/WebKit
https://bugs.webkit.org/show_bug.cgi?id=173555
Reviewed by Konstantin Tokarev.
When release logs are disabled, several lambda captures are unused, causing compilation
failures with -Wunused-lambda-capture. This patch marks the corresponding variables as unused
in order to fix these warnings.
Based on initial patch by: Konstantin Tokarev <annulen@yandex.ru>
* NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::retrieveCacheEntry):
* UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::fetchWebsiteData):
(WebKit::NetworkProcessProxy::deleteWebsiteData):
(WebKit::NetworkProcessProxy::deleteWebsiteDataForOrigins):
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::fetchWebsiteData):
(WebKit::WebProcessProxy::deleteWebsiteData):
(WebKit::WebProcessProxy::deleteWebsiteDataForOrigins):
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView dragInteraction:willAnimateLiftWithAnimator:session:]):
2018-04-02 Alejandro G. Castro <alex@igalia.com>
[GTK] Make libwebrtc backend buildable for GTK port
https://bugs.webkit.org/show_bug.cgi?id=178860
Reviewed by Youenn Fablet.
* CMakeLists.txt: Add RTC network classes to the compilation and
the libwebrtc includes.
* PlatformGTK.cmake: Add the libwebrtc directory.
* SourcesGTK.txt: Add RTC files to the compilation.
2018-03-30 Chris Dumez <cdumez@apple.com>
REGRESSION (r229828): Facebook login popup is blank
https://bugs.webkit.org/show_bug.cgi?id=184206
<rdar://problem/39057006>
Reviewed by Wenson Hsieh.
Add assertion to make sure we never try to do a policy check to
a resource response while a policy check for a navigation is
pending. This assertion was being hit by several of our redirection
tests without my fix.
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
2018-03-30 Ryan Haddad <ryanhaddad@apple.com>
Unreviewed, rolling out r230125.
Build fix broke more builds.
Reverted changeset:
"Unreviewed build fix, remove unused lambda capture."
https://trac.webkit.org/changeset/230125
2018-03-30 Ryan Haddad <ryanhaddad@apple.com>
Unreviewed build fix, remove unused lambda capture.
* NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::retrieveCacheEntry):
2018-03-30 Wenson Hsieh <wenson_hsieh@apple.com>
[Extra zoom mode] Adopt list view controller UI for numeric input types
https://bugs.webkit.org/show_bug.cgi?id=184184
<rdar://problem/37238916>
Reviewed by Timothy Hatcher.
Remove existing logic for presenting a number pad view controller, since number pads will now be handled as a
special case of general text form controls in extra zoom mode.
* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView presentViewControllerForCurrentAssistedNode]):
(-[WKContentView dismissAllInputViewControllers]):
(-[WKContentView _wheelChangedWithEvent:]):
2018-03-30 Dan Bernstein <mitz@apple.com>
Update availability annotations to match the macOS 10.13.4 and iOS 11.3 GM SDKs
https://bugs.webkit.org/show_bug.cgi?id=184173
Reviewed by Alex Christensen.
Changed WK_MAC_TBA and WK_IOS_TBA to 10.13.4 and 11.3, respectively, in all declarations that
appear in the GM SDKs.
* Shared/API/Cocoa/_WKNSWindowExtras.h:
* UIProcess/API/Cocoa/WKNavigationDelegatePrivate.h:
* UIProcess/API/Cocoa/WKOpenPanelParameters.h:
* UIProcess/API/Cocoa/WKOpenPanelParametersPrivate.h:
* UIProcess/API/Cocoa/WKPreferencesPrivate.h:
* UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
* UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
* UIProcess/API/Cocoa/WKViewPrivate.h:
* UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:
* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/API/Cocoa/WKWebsiteDataRecord.h:
* UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h:
* UIProcess/API/Cocoa/_WKApplicationManifest.h:
* UIProcess/API/Cocoa/_WKAttachment.h:
* UIProcess/API/Cocoa/_WKAutomationSession.h:
* UIProcess/API/Cocoa/_WKAutomationSessionConfiguration.h:
* UIProcess/API/Cocoa/_WKDownload.h:
* UIProcess/API/Cocoa/_WKDownloadDelegate.h:
* UIProcess/API/Cocoa/_WKFocusedElementInfo.h:
* UIProcess/API/Cocoa/_WKFullscreenDelegate.h:
* UIProcess/API/Cocoa/_WKProcessPoolConfiguration.h:
* UIProcess/API/Cocoa/_WKRemoteWebInspectorViewController.h:
* UIProcess/API/Cocoa/_WKVisitedLinkStore.h:
* UIProcess/API/Cocoa/_WKWebsiteDataStoreConfiguration.h:
* UIProcess/API/Cocoa/_WKWebsitePolicies.h:
* WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandlePrivate.h:
* WebProcess/InjectedBundle/API/mac/WKDOMDocument.h:
2018-03-30 Youenn Fablet <youenn@apple.com>
NetworkLoadChecker should upgrade redirects if needed
https://bugs.webkit.org/show_bug.cgi?id=184098
Reviewed by Chris Dumez.
In case of redirections, upgrade URL according CSP.
* NetworkProcess/NetworkLoadChecker.cpp:
(WebKit::NetworkLoadChecker::checkRequest):
(WebKit::NetworkLoadChecker::contentSecurityPolicy const):
2018-03-30 JF Bastien <jfbastien@apple.com>
Update messages.py codegen for String, fix tests
https://bugs.webkit.org/show_bug.cgi?id=184179
<rdar://problem/39041352>
Reviewed by Mark Lam.
I updated some of the code in
https://trac.webkit.org/changeset/230097 and auto-magically used a
script to update copyright headers... and that broke the tests
which checked for a particular date. Update all of the headers.
Part of this change updates the code generated by messages.py
* Scripts/webkit/LegacyMessageReceiver-expected.cpp:
* Scripts/webkit/MessageReceiver-expected.cpp:
* Scripts/webkit/MessageReceiverSuperclass-expected.cpp:
* Scripts/webkit/MessagesSuperclass-expected.h:
* Scripts/webkit/messages.py:
* Scripts/webkit/messages_unittest.py:
(GeneratedFileContentsTest.assertGeneratedFileContentsEqual):
generate a better error message
2018-03-29 JF Bastien <jfbastien@apple.com>
Use Forward.h instead of forward-declaring WTF::String
https://bugs.webkit.org/show_bug.cgi?id=184172
<rdar://problem/39026146>
Reviewed by Yusuke Suzuki.
As part of #184164 I'm changing WTF::String, and the forward
declarations are just wrong because I'm making it templated. We
should use Forward.h anyways, so do that instead.
* Scripts/webkit/LegacyMessages-expected.h:
* Scripts/webkit/Messages-expected.h:
* Scripts/webkit/MessagesSuperclass-expected.h:
* UIProcess/WebOpenPanelResultListenerProxy.h:
2018-03-29 Brian Burg <bburg@apple.com>
Web Automation: clipToViewport is ignored for element screenshots
https://bugs.webkit.org/show_bug.cgi?id=184158
<rdar://problem/39014307>
Reviewed by Timothy Hatcher.
In §19.2 Take Element Screenshot, step 5.2 says that we should clip
the element screenshot rect with the visible viewport rect. We don't
do that right now even though we pass over clipToViewport.
* WebProcess/Automation/WebAutomationSessionProxy.cpp:
(WebKit::snapshotRectForScreenshot):
Clip the rect to viewport if needed.
(WebKit::WebAutomationSessionProxy::takeScreenshot):
This scrollIntoView is misplaced; by this point we have already done
the math to figure out the screenshot rect. Move it before computing the rect.
2018-03-29 Brent Fulgham <bfulgham@apple.com>
REGRESSION(r230035): ASSERT(MACH_PORT_VALID(m_sendPort)) hit in IPC::Connection::initializeSendSource()
https://bugs.webkit.org/show_bug.cgi?id=184122
<rdar://problem/39003606>
Reviewed by Chris Dumez.
One of the new assertions added in r230035 begin firing while running tests locally. This was happening
because the WebInspector was attempting to open a new connection to a web process that had already
terminated its mach port connection (a dead port).
We should avoid opening new connections when the port we were given is already dead.
* Platform/IPC/Connection.h:
(IPC::Connection::identifierIsValid): Added.
* Platform/IPC/mac/ConnectionMac.mm:
(IPC::Connection::platformInitialize): Do not perform initialization on a dead (or null) port.
(IPC::Connection::open): Add some assertions that ports are in a valid state.
(IPC::Connection::sendOutgoingMessage): Assert that the send port is not dead.
(IPC::Connection::receiveSourceEventHandler): Assert that the receive port is valid.
* UIProcess/ChildProcessProxy.cpp:
(WebKit::ChildProcessProxy::didFinishLaunching): Treat a dead port as a signal that the
child process failed to launch.
* UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::didFinishLaunching): Ditto.
* UIProcess/Plugins/PluginProcessProxy.cpp:
(WebKit::PluginProcessProxy::didFinishLaunching): Ditto.
* UIProcess/Storage/StorageProcessProxy.cpp:
(WebKit::StorageProcessProxy::didFinishLaunching): Ditto.
* WebProcess/Plugins/PluginProcessConnectionManager.cpp:
(WebKit::PluginProcessConnectionManager::getPluginProcessConnection): Ditto.
* WebProcess/WebPage/WebInspectorUI.cpp:
(WebKit::WebInspectorUI::establishConnection): Ditto.
* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::ensureNetworkProcessConnection): Ditto.
(WebKit::WebProcess::ensureWebToStorageProcessConnection): Ditto.
2018-03-29 Youenn Fablet <youenn@apple.com>
Synchronize SecurityOrigin related scheme registries with NetworkProcess
https://bugs.webkit.org/show_bug.cgi?id=184140
Reviewed by Chris Dumez.
Add syncing of scheme registries that are used by SecurityOrigin and ContentSecurityPolicy
so that we can properly use them in NetworkProcess as we do in WebProcess.
The registries that are not synced are:
- URLSchemeAsEmptyDocument
- URLSchemeDomainRelaxationForbidden
- URLSchemeAsCachePartitioned
- URLSchemeAsCanDisplayOnlyIfCanRequest
* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::initializeNetworkProcess):
(WebKit::NetworkProcess::registerURLSchemeAsSecure const):
(WebKit::NetworkProcess::registerURLSchemeAsBypassingContentSecurityPolicy const):
(WebKit::NetworkProcess::registerURLSchemeAsLocal const):
(WebKit::NetworkProcess::registerURLSchemeAsNoAccess const):
(WebKit::NetworkProcess::registerURLSchemeAsDisplayIsolated const):
(WebKit::NetworkProcess::registerURLSchemeAsCORSEnabled const):
(WebKit::NetworkProcess::registerURLSchemeAsCanDisplayOnlyIfCanRequest const):
* NetworkProcess/NetworkProcess.h:
* NetworkProcess/NetworkProcess.messages.in:
* NetworkProcess/NetworkProcessCreationParameters.cpp:
(WebKit::NetworkProcessCreationParameters::encode const):
(WebKit::NetworkProcessCreationParameters::decode):
* NetworkProcess/NetworkProcessCreationParameters.h:
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::ensureNetworkProcess):
(WebKit::WebProcessPool::registerURLSchemeAsSecure):
(WebKit::WebProcessPool::registerURLSchemeAsBypassingContentSecurityPolicy):
(WebKit::WebProcessPool::registerURLSchemeAsLocal):
(WebKit::WebProcessPool::registerURLSchemeAsNoAccess):
(WebKit::WebProcessPool::registerURLSchemeAsDisplayIsolated):
(WebKit::WebProcessPool::registerURLSchemeAsCORSEnabled):
(WebKit::WebProcessPool::registerURLSchemeAsCanDisplayOnlyIfCanRequest):
2018-03-29 Brent Fulgham <bfulgham@apple.com>
REGRESSION(r229480): ERROR: Unhandled web process message 'WebCookieManager:SetHTTPCookieAcceptPolicy'
https://bugs.webkit.org/show_bug.cgi?id=184124
<rdar://problem/38998971>
Reviewed by Chris Dumez.
Cookie accept policy messages were still being sent to the WebContent process after
I removed cookie access in r229480. The WebContent process no longer recognizes these
messages, and generates logging to that effect.
This patch stops sending these unnecessary messages to the WebContent process. Only the
Network process needs to receive this information.
* UIProcess/WebCookieManagerProxy.cpp:
(WebKit::WebCookieManagerProxy::setHTTPCookieAcceptPolicy):
2018-03-29 Carlos Eduardo Ramalho <cadubentzen@gmail.com>
[WPE] Floating point exception in WebEventFactory::createWebWheelEvent
https://bugs.webkit.org/show_bug.cgi?id=184037
Reviewed by Žan Doberšek.
* Shared/wpe/WebEventFactory.cpp:
(WebKit::WebEventFactory::createWebWheelEvent): Use std::copysign() to avoid division by 0.
2018-03-28 Zalan Bujtas <zalan@apple.com>
Make it possible to override the screen size
https://bugs.webkit.org/show_bug.cgi?id=184111
<rdar://problem/38972181>
Reviewed by Tim Horton.
* Shared/WebPageCreationParameters.cpp:
(WebKit::WebPageCreationParameters::encode const):
(WebKit::WebPageCreationParameters::decode):
* Shared/WebPageCreationParameters.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::creationParameters):
* UIProcess/WebPageProxy.h:
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::overrideScreenSize):
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::overrideScreenSize const):
* WebProcess/WebCoreSupport/WebChromeClient.h:
* WebProcess/WebPage/WebPage.cpp:
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::overrideScreenSize const):
2018-03-28 Chris Dumez <cdumez@apple.com>
Do process swap when opening a cross-origin URL via window.open(url, '_blank', 'noopener')
https://bugs.webkit.org/show_bug.cgi?id=183962
<rdar://problem/38817833>
Reviewed by Brady Eidson.
Swap WebProcess on for the initial navigation in a new Window that was opened
via window.open(), when the new URL is cross-origin compared to the opener's
origin. For now, we only swap process if 'noopener' property is set when calling
window.open(). This is because we do not support the remote DOMWindows yet.
* Shared/NavigationActionData.cpp:
(WebKit::NavigationActionData::encode const):
(WebKit::NavigationActionData::decode):
* Shared/NavigationActionData.h:
* UIProcess/API/APINavigation.h:
(API::Navigation::setIsCrossOriginWindowOpenNavigation):
(API::Navigation::isCrossOriginWindowOpenNavigation const):
(API::Navigation::setOpener):
(API::Navigation::opener const):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::receivedPolicyDecision):
(WebKit::WebPageProxy::decidePolicyForNavigationAction):
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::processForNavigation):
* UIProcess/WebProcessPool.h:
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
2018-03-28 Per Arne Vollan <pvollan@apple.com>
Adopt WEBPROCESS_WINDOWSERVER_BLOCKING compiler guard in WebProcess.
https://bugs.webkit.org/show_bug.cgi?id=183959
<rdar://problem/38965719>
Reviewed by Brent Fulgham.
Use the compile guard to guard the call to CGSSetDenyWindowServerConnections.
* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::initializeProcess):
2018-03-28 Brent Fulgham <bfulgham@apple.com>
Unreviewed build fix after r230045.
* UIProcess/Launcher/mac/ProcessLauncherMac.mm: Add missing include (breaks iOS).
2018-03-28 Brent Fulgham <bfulgham@apple.com>
Protect against invalid mach ports returned by mach_port_request_notification
https://bugs.webkit.org/show_bug.cgi?id=184106
<rdar://problem/37865316>
Reviewed by Chris Dumez.
* Platform/IPC/Connection.h:
(IPC::Connection::Identifier::Identifier): Use default initializer syntax.
* Platform/IPC/mac/ConnectionMac.mm:
(IPC::Connection::open): Drive-by-fix: Include formatted mach error message in logging.
(IPC::Connection::receiveSourceEventHandler): Check return value from 'mach_port_request_notification'
and clean up if it experienced an error.
* UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::ProcessLauncher::launchProcess): Ditto.
2018-03-28 Dean Jackson <dino@apple.com>
WKWebViewContentProvider shouldn't be a UIScrollViewDelegate
https://bugs.webkit.org/show_bug.cgi?id=184107
<rdar://problem/38967492>
Reviewed by Tim Horton.
There is no need for this class to be a UIScrollViewDelegate. Instead
the protocol should have an optional method that is effectively
scrollViewDidScroll.
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView scrollViewDidScroll:]): Call web_scrollViewDidScroll
if it exists.
* UIProcess/Cocoa/WKWebViewContentProvider.h: Remove UIScrollViewDelegate
and add an optional web_scrollViewDidScroll.
* UIProcess/ios/WKPDFView.mm:
(-[WKPDFView web_scrollViewDidScroll:]): Renamed from scrollViewDidScroll.
(-[WKPDFView scrollViewDidScroll:]): Deleted.
* UIProcess/ios/WKSystemPreviewView.mm:
(-[WKSystemPreviewView scrollViewDidScroll:]): Deleted.
2018-03-28 Wenson Hsieh <wenson_hsieh@apple.com>
[Extra zoom mode] Make boosted text autosizing values switchable at runtime
https://bugs.webkit.org/show_bug.cgi?id=184092
<rdar://problem/38939917>
Reviewed by Tim Horton.
Add a private web view preference to switch between normal and boosted text autosizing mode. By default, we use
normal text autosizing values.
* Shared/WebPreferences.yaml:
* UIProcess/API/Cocoa/WKPreferences.mm:
(-[WKPreferences _setShouldEnableTextAutosizingBoost:]):
(-[WKPreferences _shouldEnableTextAutosizingBoost]):
* UIProcess/API/Cocoa/WKPreferencesPrivate.h:
2018-03-28 Brent Fulgham <bfulgham@apple.com>
Avoid uninitialized mach ports
https://bugs.webkit.org/show_bug.cgi?id=184090
<rdar://problem/37261129>
Reviewed by Chris Dumez.
It is possible for mach_port_allocate to return an error, but we rarely check its return value. The value
of the argument passed to mach_port_allocate is not guaranteed to be valid when it returns an error, so
there is a potential for us to try to use invalid ports.
We should always check return values, and ensure that the mach port variables we seek to initialize are
kept in a valid state.
Reviewed by Chris Dumez.
* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::createNetworkConnectionToWebProcess): Initialize new port to a safe default and
check the return state of the allocation function.
* Platform/IPC/Connection.h:
* Platform/IPC/mac/ConnectionMac.mm:
(IPC::Connection::open): Ditto.
(IPC::Connection::initializeSendSource): Ditto.
(IPC::readFromMachPort): Ditto.
(IPC::Connection::receiveSourceEventHandler): Ditto.
* Platform/SharedMemory.h:
* Platform/cocoa/SharedMemoryCocoa.cpp:
(WebKit::makeMemoryEntry): Ditto.
* Platform/mac/MachUtilities.cpp:
(setMachPortQueueLength): Ditto.
(setMachExceptionPort): Ditto.
* PluginProcess/PluginProcess.cpp:
(WebKit::PluginProcess::createWebProcessConnection): Ditto.
* StorageProcess/StorageProcess.cpp:
(WebKit::StorageProcess::createStorageToWebProcessConnection): Ditto.
* UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::ProcessLauncher::launchProcess): Ditto.
* WebProcess/WebPage/WebInspector.cpp:
(WebKit::WebInspector::openFrontendConnection): Ditto.
2018-03-28 Michael Catanzaro <mcatanzaro@igalia.com>
Fails to build webkitgtk+ after git-svn-id: http://svn.webkit.org/repository/webkit/trunk@229877 268f45cc-cd09-0410-ab3c-d52691b4dbfc
https://bugs.webkit.org/show_bug.cgi?id=184081
Unreviewed, switch to use UNUSED_PARAM()
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::decidePolicyForNavigationAction):
2018-03-28 Tim Horton <timothy_horton@apple.com>
Make use of HAVE(CORE_ANIMATION_RENDER_SERVER) in more places
https://bugs.webkit.org/show_bug.cgi?id=184072
<rdar://problem/38946530>
Reviewed by Dan Bernstein.
* Platform/mac/LayerHostingContext.mm:
(WebKit::LayerHostingContext::createForExternalHostingProcess):
* UIProcess/mac/ViewSnapshotStore.h:
* UIProcess/mac/ViewSnapshotStore.mm:
(WebKit::ViewSnapshot::clearImage):
2018-03-28 Wenson Hsieh <wenson_hsieh@apple.com>
Revert an unnecessary workaround when zooming focused form controls
https://bugs.webkit.org/show_bug.cgi?id=184067
<rdar://problem/38805254>
Reviewed by Tim Horton.
Reverts an unintended change introduced in r227984.
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _displayFormNodeInputView]):
2018-03-28 Miguel Gomez <magomez@igalia.com>
[GTK][WPE] Remove UpdateAtlas
https://bugs.webkit.org/show_bug.cgi?id=184042
Reviewed by Žan Doberšek.
Remove all the code related to UpdateAtlas handling.
* Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp:
(WebKit::CoordinatedGraphicsScene::updateTilesIfNeeded):
(WebKit::CoordinatedGraphicsScene::commitSceneState):
(WebKit::CoordinatedGraphicsScene::purgeGLResources):
(WebKit::CoordinatedGraphicsScene::syncUpdateAtlases): Deleted.
(WebKit::CoordinatedGraphicsScene::createUpdateAtlas): Deleted.
(WebKit::CoordinatedGraphicsScene::removeUpdateAtlas): Deleted.
(WebKit::CoordinatedGraphicsScene::releaseUpdateAtlases): Deleted.
* Shared/CoordinatedGraphics/CoordinatedGraphicsScene.h:
* Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.cpp:
(WebKit::ThreadedCompositor::renderLayerTree):
(WebKit::ThreadedCompositor::releaseUpdateAtlases): Deleted.
* Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.h:
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::delegatedScrollRequested):
(WebKit::WebChromeClient::resetUpdateAtlasForTesting): Deleted.
* WebProcess/WebCoreSupport/WebChromeClient.h:
* WebProcess/WebPage/AcceleratedDrawingArea.cpp:
(WebKit::AcceleratedDrawingArea::resetUpdateAtlasForTesting): Deleted.
* WebProcess/WebPage/AcceleratedDrawingArea.h:
* WebProcess/WebPage/CoordinatedGraphics/CompositingCoordinator.cpp:
(WebKit::CompositingCoordinator::CompositingCoordinator):
(WebKit::CompositingCoordinator::flushPendingLayerChanges):
(WebKit::CompositingCoordinator::clearPendingStateChanges):
(WebKit::CompositingCoordinator::renderNextFrame):
(WebKit::CompositingCoordinator::purgeBackingStores):
(WebKit::CompositingCoordinator::createUpdateAtlas): Deleted.
(WebKit::CompositingCoordinator::removeUpdateAtlas): Deleted.
(WebKit::CompositingCoordinator::getCoordinatedBuffer): Deleted.
(): Deleted.
(WebKit::CompositingCoordinator::scheduleReleaseInactiveAtlases): Deleted.
(WebKit::CompositingCoordinator::releaseInactiveAtlasesTimerFired): Deleted.
(WebKit::CompositingCoordinator::releaseAtlases): Deleted.
(WebKit::CompositingCoordinator::clearUpdateAtlases): Deleted.
* WebProcess/WebPage/CoordinatedGraphics/CompositingCoordinator.h:
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
(WebKit::CoordinatedLayerTreeHost::clearUpdateAtlases): Deleted.
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
* WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.cpp:
(WebKit::ThreadedCoordinatedLayerTreeHost::releaseUpdateAtlases): Deleted.
* WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.h:
* WebProcess/WebPage/DrawingArea.h:
* WebProcess/WebPage/LayerTreeHost.h:
(WebKit::LayerTreeHost::setIsDiscardable):
2018-03-28 Carlos Garcia Campos <cgarcia@igalia.com>
REGRESSION(r229998): WebDriver: MiniBrowser is crashing in a lot of tests after r229998
https://bugs.webkit.org/show_bug.cgi?id=184075
Reviewed by Žan Doberšek.
This is because we are using a value after it has been moved.
* UIProcess/Automation/WebAutomationSession.cpp:
(WebKit::WebAutomationSession::setWindowFrameOfBrowsingContext): Save a reference to page in a local variable
before using it when it's also going to be moved in the lambda capture.
2018-03-27 Michael Catanzaro <mcatanzaro@igalia.com>
Unreviewed, fix typo in variable name
* UIProcess/API/gtk/WebKitWebViewBase.cpp:
(webkitWebViewBaseCrossingNotifyEvent):
2018-03-27 Per Arne Vollan <pvollan@apple.com>
The layout test fast/canvas/webgl/read-pixels-test.html is timing out.
https://bugs.webkit.org/show_bug.cgi?id=183923
<rdar://problem/38756869>
Reviewed by Brent Fulgham.
Send OpenGL display mask to the WebContent process when the display ID is changing.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::windowScreenDidChange):
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebPage/mac/WebPageMac.mm:
(WebKit::WebPage::openGLDisplayMaskChanged):
2018-03-27 Youenn Fablet <youenn@apple.com>
Move request checking out of PingLoad for future reuse in NetworkLoad
https://bugs.webkit.org/show_bug.cgi?id=183865
Reviewed by Chris Dumez.
Introduce NetworkLoadChecker as a way to validate requests before sending them in the network process.
Validation encompasses: CORS checks, CSP and Content Extensions on both main request and redirected requests if any.
Make PingLoad use NetworkLoadChecker. Future patch should make NetworkLoad to use it as well whenever needed.
Make NetworkCORSPreflightChecker takes a CompletionHandler instead of a Function.
Ensure this callback is called even if preflight is not completed by returning a Canceled error.
* NetworkProcess/NetworkCORSPreflightChecker.cpp:
(WebKit::NetworkCORSPreflightChecker::~NetworkCORSPreflightChecker):
(WebKit::NetworkCORSPreflightChecker::returnResult):
(WebKit::NetworkCORSPreflightChecker::willPerformHTTPRedirection):
(WebKit::NetworkCORSPreflightChecker::didReceiveChallenge):
(WebKit::NetworkCORSPreflightChecker::didCompleteWithError):
* NetworkProcess/NetworkCORSPreflightChecker.h:
* NetworkProcess/NetworkLoadChecker.cpp: Added.
(WebKit::NetworkLoadChecker::NetworkLoadChecker):
(WebKit::NetworkLoadChecker::check):
(WebKit::NetworkLoadChecker::checkRedirection):
(WebKit::NetworkLoadChecker::returnError):
(WebKit::NetworkLoadChecker::checkRequest):
(WebKit::NetworkLoadChecker::checkCORSRequest):
(WebKit::NetworkLoadChecker::checkCORSRedirectedRequest):
(WebKit::NetworkLoadChecker::checkCORSRequestWithPreflight):
(WebKit::NetworkLoadChecker::doesNotNeedCORSCheck const):
(WebKit::NetworkLoadChecker::contentSecurityPolicy const):
(WebKit::NetworkLoadChecker::contentExtensionsBackend):
(WebKit::NetworkLoadChecker::processContentExtensionRulesForLoad):
* NetworkProcess/NetworkLoadChecker.h: Added.
(WebKit::NetworkLoadChecker::setCSPResponseHeaders):
(WebKit::NetworkLoadChecker::setContentExtensionRuleLists):
(WebKit::NetworkLoadChecker::url const):
(WebKit::NetworkLoadChecker::storedCredentialsPolicy const):
(WebKit::NetworkLoadChecker::isChecking const):
(WebKit::NetworkLoadChecker::isRedirected const):
* NetworkProcess/PingLoad.cpp:
(WebKit::PingLoad::PingLoad):
(WebKit::PingLoad::~PingLoad):