[SOUP] Network process assertion in NetworkDataTask::continueHTTPRedirection
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2016-10-25  Carlos Garcia Campos  <cgarcia@igalia.com>
2
3         [SOUP] Network process assertion in NetworkDataTask::continueHTTPRedirection
4         https://bugs.webkit.org/show_bug.cgi?id=163941
5
6         Reviewed by Michael Catanzaro.
7
8         equalLettersIgnoringASCIICase() expects the second argument to be the letters to compare in lowercase, so use
9         "get" instead of "GET".
10
11         * NetworkProcess/soup/NetworkDataTaskSoup.cpp:
12         (WebKit::NetworkDataTaskSoup::continueHTTPRedirection):
13
14 2016-10-25  Eric Carlson  <eric.carlson@apple.com>
15
16         [MediaStream] Add "has capture device" bit to media state flags
17         https://bugs.webkit.org/show_bug.cgi?id=163952
18
19         Reviewed by Sam Weinig.
20
21         * UIProcess/API/C/WKPage.cpp:
22         (WKPageGetMediaState): Support MediaProducer::HasMediaCaptureDevice.
23         * UIProcess/API/C/WKPagePrivate.h: Define kWKMediaHasCaptureDevice.
24
25 2016-10-25  Commit Queue  <commit-queue@webkit.org>
26
27         Unreviewed, rolling out r207827 and r207828.
28         https://bugs.webkit.org/show_bug.cgi?id=163965
29
30         Caused LayoutTest webaudio/web-audio-is-playing.html to time
31         out on macOS. (Requested by ryanhaddad on #webkit).
32
33         Reverted changesets:
34
35         "[MediaStream] Add "has capture device" bit to media state
36         flags"
37         https://bugs.webkit.org/show_bug.cgi?id=163952
38         http://trac.webkit.org/changeset/207827
39
40         "[MediaStream] Add "has capture device" bit to media state
41         flags"
42         https://bugs.webkit.org/show_bug.cgi?id=163952
43         http://trac.webkit.org/changeset/207828
44
45 2016-10-25  Eric Carlson  <eric.carlson@apple.com>
46
47         [MediaStream] Add "has capture device" bit to media state flags
48         https://bugs.webkit.org/show_bug.cgi?id=163952
49
50         Reviewed by Sam Weinig.
51
52         * UIProcess/API/C/WKPage.cpp:
53         (WKPageGetMediaState): Support MediaProducer::HasMediaCaptureDevice.
54         * UIProcess/API/C/WKPagePrivate.h: Define kWKMediaHasCaptureDevice.
55
56 2016-10-25  Chris Dumez  <cdumez@apple.com>
57
58         Unreviewed, rolling out r207494.
59
60         iOS SDK has been updated on the bots now so rollout the
61         rollout
62
63         Reverted changeset:
64
65         "Unreviewed, rolling out r207413."
66         https://bugs.webkit.org/show_bug.cgi?id=163547
67         http://trac.webkit.org/changeset/207494
68
69 2016-10-25  Jonathan Bedard  <jbedard@apple.com>
70
71         Unreviewed build fix.
72
73         * UIProcess/API/Cocoa/WKWebView.mm:
74         (-[WKWebView _fullscreenDelegate]): Removed unneeded parenthesis.
75
76 2016-10-19  Jer Noble  <jer.noble@apple.com>
77
78         Add WKWebView fullscreen delegate SPI
79         https://bugs.webkit.org/show_bug.cgi?id=163674
80
81         Reviewed by Anders Carlsson.
82
83         Add a new SPI property to WKWebView allowing clients to be notified when fullscreen mode enters and exits.
84
85         * UIProcess/API/APIFullscreenClient.h: Added.
86         (API::FullscreenClient::~FullscreenClient):
87         (API::FullscreenClient::willEnterFullscreen):
88         (API::FullscreenClient::didEnterFullscreen):
89         (API::FullscreenClient::willExitFullscreen):
90         (API::FullscreenClient::didExitFullscreen):
91         * UIProcess/API/Cocoa/WKWebView.mm:
92         (-[WKWebView _initializeWithConfiguration:]):
93         (-[WKWebView _setFullscreenDelegate:]):
94         (-[WKWebView _fullscreenDelegate]):
95         (-[WKWebView _isInFullscreen]):
96         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
97         * UIProcess/API/Cocoa/_WKFullscreenDelegate.h: Added.
98         * UIProcess/Cocoa/FullscreenClient.h: Added.
99         (WebKit::FullscreenClient::~FullscreenClient):
100         * UIProcess/Cocoa/FullscreenClient.mm: Added.
101         (WebKit::FullscreenClient::FullscreenClient):
102         (WebKit::FullscreenClient::delegate):
103         (WebKit::FullscreenClient::setDelegate):
104         (WebKit::FullscreenClient::willEnterFullscreen):
105         (WebKit::FullscreenClient::didEnterFullscreen):
106         (WebKit::FullscreenClient::willExitFullscreen):
107         (WebKit::FullscreenClient::didExitFullscreen):
108         * UIProcess/WebFullScreenManagerProxy.cpp:
109         (WebKit::WebFullScreenManagerProxy::willEnterFullScreen):
110         (WebKit::WebFullScreenManagerProxy::didEnterFullScreen):
111         (WebKit::WebFullScreenManagerProxy::willExitFullScreen):
112         (WebKit::WebFullScreenManagerProxy::didExitFullScreen):
113         * UIProcess/WebPageProxy.cpp:
114         (WebKit::WebPageProxy::WebPageProxy):
115         (WebKit::WebPageProxy::setFullscreenClient):
116         (WebKit::WebPageProxy::fullScreenManager): Deleted.
117         * UIProcess/WebPageProxy.h:
118         (WebKit::WebPageProxy::fullscreenClient):
119         * WebKit2.xcodeproj/project.pbxproj:
120
121 2016-10-25  Carlos Garcia Campos  <cgarcia@igalia.com>
122
123         Unreviewed. Fix timeouts in 12 GTK+ unit tests after r207812.
124
125         * NetworkProcess/NetworkProcessCreationParameters.h: Initialize loadThrottleLatency.
126
127 2016-10-25  Carlos Garcia Campos  <cgarcia@igalia.com>
128
129         Unreviewed. Fix Soup based ports debug build after r207813.
130
131         * NetworkProcess/soup/NetworkDataTaskSoup.cpp:
132         (WebKit::NetworkDataTaskSoup::authenticateCallback):
133         (WebKit::NetworkDataTaskSoup::requestStartedCallback):
134
135 2016-10-25  Andreas Kling  <akling@apple.com>
136
137         More PassRefPtr purging in WebCore.
138         <https://webkit.org/b/163895>
139
140         Reviewed by Antti Koivisto.
141
142         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.h:
143         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.mm:
144         (WebKit::PDFPlugin::createScrollbar):
145
146 2016-10-25  Carlos Garcia Campos  <cgarcia@igalia.com>
147
148         NetworkSession: switch to use subclasses for NetworkSession and NetworkDataTask implementations
149         https://bugs.webkit.org/show_bug.cgi?id=163777
150
151         Reviewed by Alex Christensen.
152
153         The subclass model allows us to choose the implementation at run time, so we could add other implementations
154         like a mock network class to measure performance, and even one for blobs and finally get rid of ResourceHandle
155         in WebKit2.
156
157         * CMakeLists.txt: Add new files to compilation.
158         * NetworkProcess/NetworkDataTask.cpp: Added.
159         (WebKit::NetworkDataTask::create): Create a NetworkDataTaskCocoa or NetworkDataTaskSoup.
160         (WebKit::NetworkDataTask::NetworkDataTask): Move common code from NetworkDataTaskCocoa and NetworkDataTaskSoup
161         here to handle the early failures.
162         (WebKit::NetworkDataTask::~NetworkDataTask):
163         (WebKit::NetworkDataTask::scheduleFailure):
164         (WebKit::NetworkDataTask::failureTimerFired):
165         * NetworkProcess/NetworkDataTask.h: Remove platform specific members.
166         (WebKit::NetworkDataTask::setPendingDownloadLocation): Make it virtual and set the m_pendingDownloadLocation.
167         (WebKit::NetworkDataTask::suggestedFilename): Make it virtual and const with a default implementation.
168         (WebKit::NetworkDataTask::setSuggestedFilename): Ditto.
169         (WebKit::NetworkDataTask::allowsSpecificHTTPSCertificateForHost): Ditto.
170         * NetworkProcess/NetworkLoad.cpp: Include NetworkDataTaskCocoa.h.
171         * NetworkProcess/NetworkLoad.h: Include NetworkDataTask.h instead of NetworkSession.h.
172         * NetworkProcess/NetworkProcess.cpp:
173         (WebKit::NetworkProcess::NetworkProcess): Use NetworkSessionCocoa.
174         * NetworkProcess/NetworkSession.cpp:
175         (WebKit::NetworkSession::create): Create a NetworkSessionCocoa or NetworkSessionSoup.
176         (WebKit::NetworkSession::defaultSession): In case of cocoa use NetworkSessionCocoa::defaultSession() because of
177         the custom protocol manager, otherwise simply create a default session.
178         (WebKit::NetworkSession::networkStorageSession): Move common code from NetworkSessionCocoa and
179         NetworkSessionSoup here.
180         (WebKit::NetworkSession::NetworkSession):
181         (WebKit::NetworkSession::~NetworkSession):
182         * NetworkProcess/NetworkSession.h: Remove platform specific members.
183         (WebKit::NetworkSession::invalidateAndCancel): Make it virtual.
184         (WebKit::NetworkSession::clearCredentials): Ditto.
185         * NetworkProcess/cache/NetworkCacheSpeculativeLoad.cpp: Include NetworkSession.h.
186         * NetworkProcess/cocoa/NetworkDataTaskCocoa.h: Added.
187         * NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
188         (WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):
189         (WebKit::NetworkDataTaskCocoa::~NetworkDataTaskCocoa):
190         (WebKit::NetworkDataTaskCocoa::didSendData):
191         (WebKit::NetworkDataTaskCocoa::didReceiveChallenge):
192         (WebKit::NetworkDataTaskCocoa::didCompleteWithError):
193         (WebKit::NetworkDataTaskCocoa::didReceiveResponse):
194         (WebKit::NetworkDataTaskCocoa::didReceiveData):
195         (WebKit::NetworkDataTaskCocoa::didBecomeDownload):
196         (WebKit::NetworkDataTaskCocoa::willPerformHTTPRedirection):
197         (WebKit::NetworkDataTaskCocoa::setPendingDownloadLocation):
198         (WebKit::NetworkDataTaskCocoa::tryPasswordBasedAuthentication):
199         (WebKit::NetworkDataTaskCocoa::transferSandboxExtensionToDownload):
200         (WebKit::NetworkDataTaskCocoa::allowsSpecificHTTPSCertificateForHost):
201         (WebKit::NetworkDataTaskCocoa::suggestedFilename):
202         (WebKit::NetworkDataTaskCocoa::cancel):
203         (WebKit::NetworkDataTaskCocoa::resume):
204         (WebKit::NetworkDataTaskCocoa::suspend):
205         (WebKit::NetworkDataTaskCocoa::state):
206         * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
207         (WebKit::NetworkProcess::platformInitializeNetworkProcessCocoa):
208         * NetworkProcess/cocoa/NetworkSessionCocoa.h: Added.
209         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
210         (-[WKNetworkSessionDelegate initWithNetworkSession:withCredentials:]):
211         (-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]):
212         (WebKit::configurationForSessionID):
213         (WebKit::NetworkSessionCocoa::setCustomProtocolManager):
214         (WebKit::NetworkSessionCocoa::setSourceApplicationAuditTokenData):
215         (WebKit::NetworkSessionCocoa::setSourceApplicationBundleIdentifier):
216         (WebKit::NetworkSessionCocoa::setSourceApplicationSecondaryIdentifier):
217         (WebKit::NetworkSessionCocoa::setCTDataConnectionServiceType):
218         (WebKit::NetworkSessionCocoa::create):
219         (WebKit::NetworkSessionCocoa::defaultSession):
220         (WebKit::NetworkSessionCocoa::NetworkSessionCocoa):
221         (WebKit::NetworkSessionCocoa::~NetworkSessionCocoa):
222         (WebKit::NetworkSessionCocoa::invalidateAndCancel):
223         (WebKit::NetworkSessionCocoa::clearCredentials):
224         (WebKit::NetworkSessionCocoa::dataTaskForIdentifier):
225         (WebKit::NetworkSessionCocoa::addDownloadID):
226         (WebKit::NetworkSessionCocoa::downloadID):
227         (WebKit::NetworkSessionCocoa::takeDownloadID):
228         * NetworkProcess/mac/RemoteNetworkingContext.mm:
229         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
230         * NetworkProcess/soup/NetworkDataTaskSoup.cpp:
231         (WebKit::NetworkDataTaskSoup::NetworkDataTaskSoup):
232         (WebKit::NetworkDataTaskSoup::~NetworkDataTaskSoup):
233         (WebKit::NetworkDataTaskSoup::suggestedFilename):
234         (WebKit::NetworkDataTaskSoup::setPendingDownloadLocation):
235         (WebKit::NetworkDataTaskSoup::createRequest):
236         (WebKit::NetworkDataTaskSoup::clearRequest):
237         (WebKit::NetworkDataTaskSoup::resume):
238         (WebKit::NetworkDataTaskSoup::suspend):
239         (WebKit::NetworkDataTaskSoup::cancel):
240         (WebKit::NetworkDataTaskSoup::invalidateAndCancel):
241         (WebKit::NetworkDataTaskSoup::state):
242         (WebKit::NetworkDataTaskSoup::timeoutFired):
243         (WebKit::NetworkDataTaskSoup::startTimeout):
244         (WebKit::NetworkDataTaskSoup::stopTimeout):
245         (WebKit::NetworkDataTaskSoup::sendRequestCallback):
246         (WebKit::NetworkDataTaskSoup::didSendRequest):
247         (WebKit::NetworkDataTaskSoup::didReceiveResponse):
248         (WebKit::NetworkDataTaskSoup::tlsErrorsChangedCallback):
249         (WebKit::NetworkDataTaskSoup::tlsErrorsChanged):
250         (WebKit::NetworkDataTaskSoup::applyAuthenticationToRequest):
251         (WebKit::NetworkDataTaskSoup::authenticateCallback):
252         (WebKit::NetworkDataTaskSoup::authenticate):
253         (WebKit::NetworkDataTaskSoup::continueAuthenticate):
254         (WebKit::NetworkDataTaskSoup::skipInputStreamForRedirectionCallback):
255         (WebKit::NetworkDataTaskSoup::skipInputStreamForRedirection):
256         (WebKit::NetworkDataTaskSoup::didFinishSkipInputStreamForRedirection):
257         (WebKit::NetworkDataTaskSoup::shouldStartHTTPRedirection):
258         (WebKit::NetworkDataTaskSoup::continueHTTPRedirection):
259         (WebKit::NetworkDataTaskSoup::readCallback):
260         (WebKit::NetworkDataTaskSoup::read):
261         (WebKit::NetworkDataTaskSoup::didRead):
262         (WebKit::NetworkDataTaskSoup::didFinishRead):
263         (WebKit::NetworkDataTaskSoup::requestNextPartCallback):
264         (WebKit::NetworkDataTaskSoup::requestNextPart):
265         (WebKit::NetworkDataTaskSoup::didRequestNextPart):
266         (WebKit::NetworkDataTaskSoup::didFinishRequestNextPart):
267         (WebKit::NetworkDataTaskSoup::gotHeadersCallback):
268         (WebKit::NetworkDataTaskSoup::didGetHeaders):
269         (WebKit::NetworkDataTaskSoup::wroteBodyDataCallback):
270         (WebKit::NetworkDataTaskSoup::didWriteBodyData):
271         (WebKit::NetworkDataTaskSoup::download):
272         (WebKit::NetworkDataTaskSoup::writeDownloadCallback):
273         (WebKit::NetworkDataTaskSoup::writeDownload):
274         (WebKit::NetworkDataTaskSoup::didWriteDownload):
275         (WebKit::NetworkDataTaskSoup::didFinishDownload):
276         (WebKit::NetworkDataTaskSoup::didFailDownload):
277         (WebKit::NetworkDataTaskSoup::cleanDownloadFiles):
278         (WebKit::NetworkDataTaskSoup::didFail):
279         (WebKit::NetworkDataTaskSoup::networkEventCallback):
280         (WebKit::NetworkDataTaskSoup::networkEvent):
281         (WebKit::NetworkDataTaskSoup::startingCallback):
282         (WebKit::NetworkDataTaskSoup::requestStartedCallback):
283         (WebKit::NetworkDataTaskSoup::didStartRequest):
284         (WebKit::NetworkDataTaskSoup::restartedCallback):
285         (WebKit::NetworkDataTaskSoup::didRestart):
286         * NetworkProcess/soup/NetworkDataTaskSoup.h: Added.
287         * NetworkProcess/soup/NetworkSessionSoup.cpp:
288         (WebKit::NetworkSessionSoup::NetworkSessionSoup):
289         (WebKit::NetworkSessionSoup::~NetworkSessionSoup):
290         (WebKit::NetworkSessionSoup::soupSession):
291         (WebKit::NetworkSessionSoup::invalidateAndCancel):
292         * NetworkProcess/soup/NetworkSessionSoup.h: Added.
293         * NetworkProcess/soup/RemoteNetworkingContextSoup.cpp:
294         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession): Update to new NetworkSession::create() API.
295         * PlatformEfl.cmake: Add new files to compilation.
296         * PlatformGTK.cmake: Ditto.
297         * WebKit2.xcodeproj/project.pbxproj: Ditto.
298         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
299         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession): Update to new NetworkSession::create() API.
300         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
301         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession): Ditto.
302
303 2016-10-25  Antti Koivisto  <antti@apple.com>
304
305         Add support for introducing simulated latency in network process
306         https://bugs.webkit.org/show_bug.cgi?id=163902
307
308         Reviewed by Alex Christensen.
309
310         For testing purposes it is useful to have a mechanism for simulating high latency.
311         This patch adds a basic mechanism that introduces a delay to each response in network
312         process. In Safari it can be used with
313
314              defaults write com.apple.Safari WebKitNetworkLoadThrottleLatencyMilliseconds 200
315
316         Setting the delay to 0 disables the feature.
317
318         * NetworkProcess/NetworkLoad.cpp:
319         (WebKit::NetworkLoad::Throttle::Throttle):
320         (WebKit::NetworkLoad::didReceiveResponseNetworkSession):
321         (WebKit::NetworkLoad::notifyDidReceiveResponse):
322         (WebKit::NetworkLoad::didReceiveData):
323         (WebKit::NetworkLoad::didCompleteWithError):
324         (WebKit::NetworkLoad::throttleDelayCompleted):
325         * NetworkProcess/NetworkLoad.h:
326         * NetworkProcess/NetworkProcess.cpp:
327         (WebKit::NetworkProcess::initializeNetworkProcess):
328         * NetworkProcess/NetworkProcess.h:
329         (WebKit::NetworkProcess::loadThrottleLatency):
330         * NetworkProcess/NetworkProcessCreationParameters.cpp:
331         (WebKit::NetworkProcessCreationParameters::encode):
332         (WebKit::NetworkProcessCreationParameters::decode):
333         * NetworkProcess/NetworkProcessCreationParameters.h:
334         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
335         (WebKit::WebProcessPool::platformInitializeNetworkProcess):
336
337 2016-10-24  Dan Bernstein  <mitz@apple.com>
338
339         REGRESSION (r206410): Sandbox violations beneath WebProcessProxy::platformIsBeingDebugged
340         https://bugs.webkit.org/show_bug.cgi?id=163879
341         <rdar://problem/28728735>
342
343         Reviewed by Darin Adler.
344
345         * UIProcess/Cocoa/WebProcessProxyCocoa.mm:
346         (WebKit::WebProcessProxy::platformIsBeingDebugged): Check if the current process, which is
347           the UI process, is sandboxed before trying to find out if the Web process is being
348           debugged.
349
350 2016-10-21  Alex Christensen  <achristensen@webkit.org>
351
352         URL::port should return Optional<uint16_t>
353         https://bugs.webkit.org/show_bug.cgi?id=163806
354
355         Reviewed by Darin Adler.
356
357         * NetworkProcess/mac/NetworkProcessMac.mm:
358         (WebKit::overrideSystemProxies):
359         * Shared/API/APISecurityOrigin.h:
360         (API::SecurityOrigin::create):
361         * Shared/API/APIURL.h:
362         (API::URL::protocol):
363         * Shared/API/c/WKSecurityOriginRef.cpp:
364         (WKSecurityOriginGetPort):
365         * UIProcess/API/Cocoa/WKSecurityOrigin.mm:
366         (-[WKSecurityOrigin port]):
367         * WebProcess/WebPage/WebPage.cpp:
368         (WebKit::WebPage::canHandleRequest):
369         * WebProcess/cocoa/WebProcessCocoa.mm:
370         (WebKit::origin):
371
372 2016-10-24  Eric Carlson  <eric.carlson@apple.com>
373
374         [MediaStream] Separate media capture and audio playback muting
375         https://bugs.webkit.org/show_bug.cgi?id=163855
376         <rdar://problem/28827186>
377
378         Reviewed by Darin Adler.
379
380         * Shared/WebPageCreationParameters.h: Change 'muted' from bool to MutedStateFlags.
381
382         * UIProcess/API/C/WKPage.cpp: Change parameter from bool to WKMediaMutedState.
383         (WKPageSetMuted):
384         * UIProcess/API/C/WKPagePrivate.h: Define WKMediaMutedState.
385
386         * UIProcess/WebPageProxy.cpp:
387         (WebKit::WebPageProxy::WebPageProxy):
388         (WebKit::WebPageProxy::setMuted): m_muted -> m_mutedState.
389         (WebKit::WebPageProxy::creationParameters): Ditto.
390         * UIProcess/WebPageProxy.h:
391
392         * WebProcess/Plugins/PluginView.cpp:
393         (WebKit::PluginView::isMuted): page.isMuted -> page.mutedState.
394
395         * WebProcess/WebPage/WebPage.messages.in: Change SetMuted parameter.
396
397 2016-10-24  Youenn Fablet  <youenn@apple.com>
398
399         Activate WEB_RTC compilation flags for Mac bots
400         https://bugs.webkit.org/show_bug.cgi?id=163886
401
402         Reviewed by Eric Carlson.
403
404         * Configurations/FeatureDefines.xcconfig:
405
406 2016-10-24  Brady Eidson  <beidson@apple.com>
407
408         IndexedDB 2.0: Support IDBIndex name assignment.
409         <rdar://problem/28806932> and https://bugs.webkit.org/show_bug.cgi?id=163805
410
411         Reviewed by Alex Christensen.
412
413         * DatabaseProcess/IndexedDB/WebIDBConnectionToClient.cpp:
414         (WebKit::WebIDBConnectionToClient::didRenameIndex):
415         (WebKit::WebIDBConnectionToClient::renameIndex):
416         * DatabaseProcess/IndexedDB/WebIDBConnectionToClient.h:
417         * DatabaseProcess/IndexedDB/WebIDBConnectionToClient.messages.in:
418
419         * WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.cpp:
420         (WebKit::WebIDBConnectionToServer::renameIndex):
421         (WebKit::WebIDBConnectionToServer::didRenameIndex):
422         * WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.h:
423         * WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.messages.in:
424
425 2016-10-23  Michael Catanzaro  <mcatanzaro@igalia.com>
426
427         [GTK] Remove DO NOT MODIFY headers from files that are no longer autogenerated
428         https://bugs.webkit.org/show_bug.cgi?id=163867
429
430         Reviewed by Darin Adler.
431
432         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMAttr.cpp:
433         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMAttr.h:
434         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMAttrPrivate.h:
435         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMBlob.cpp:
436         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMBlob.h:
437         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMBlobPrivate.h:
438         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCDATASection.cpp:
439         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCDATASection.h:
440         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCDATASectionPrivate.h:
441         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRule.h:
442         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRuleList.cpp:
443         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRuleList.h:
444         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRuleListPrivate.h:
445         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRulePrivate.h:
446         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleDeclaration.h:
447         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleDeclarationPrivate.h:
448         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleSheet.h:
449         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleSheetPrivate.h:
450         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSValue.h:
451         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSValuePrivate.h:
452         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCharacterData.cpp:
453         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCharacterData.h:
454         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCharacterDataPrivate.h:
455         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMComment.cpp:
456         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMComment.h:
457         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCommentPrivate.h:
458         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMImplementation.h:
459         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMImplementationPrivate.h:
460         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMSelection.cpp:
461         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMSelection.h:
462         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMSelectionPrivate.h:
463         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMTokenList.cpp:
464         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMTokenList.h:
465         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMTokenListPrivate.h:
466         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindow.cpp:
467         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindow.h:
468         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindowPrivate.h:
469         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindowUnstable.h:
470         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocument.h:
471         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentFragment.cpp:
472         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentFragment.h:
473         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentFragmentPrivate.h:
474         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentFragmentUnstable.h:
475         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentPrivate.h:
476         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentType.cpp:
477         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentType.h:
478         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentTypePrivate.h:
479         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocumentUnstable.h:
480         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMElement.cpp:
481         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMElement.h:
482         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMElementPrivate.h:
483         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMElementUnstable.h:
484         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMEvent.cpp:
485         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMEvent.h:
486         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMEventPrivate.h:
487         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFile.cpp:
488         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFile.h:
489         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFileList.cpp:
490         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFileList.h:
491         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFileListPrivate.h:
492         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMFilePrivate.h:
493         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAnchorElement.cpp:
494         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAnchorElement.h:
495         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAnchorElementPrivate.h:
496         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAppletElement.cpp:
497         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAppletElement.h:
498         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAppletElementPrivate.h:
499         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAreaElement.cpp:
500         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAreaElement.h:
501         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLAreaElementPrivate.h:
502         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBRElement.cpp:
503         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBRElement.h:
504         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBRElementPrivate.h:
505         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBaseElement.cpp:
506         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBaseElement.h:
507         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBaseElementPrivate.h:
508         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBodyElement.cpp:
509         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBodyElement.h:
510         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLBodyElementPrivate.h:
511         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLButtonElement.cpp:
512         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLButtonElement.h:
513         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLButtonElementPrivate.h:
514         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCanvasElement.cpp:
515         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCanvasElement.h:
516         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCanvasElementPrivate.h:
517         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCollection.cpp:
518         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCollection.h:
519         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLCollectionPrivate.h:
520         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDListElement.cpp:
521         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDListElement.h:
522         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDListElementPrivate.h:
523         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDirectoryElement.cpp:
524         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDirectoryElement.h:
525         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDirectoryElementPrivate.h:
526         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDivElement.cpp:
527         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDivElement.h:
528         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDivElementPrivate.h:
529         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDocument.cpp:
530         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDocument.h:
531         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLDocumentPrivate.h:
532         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLElement.cpp:
533         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLElement.h:
534         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLElementPrivate.h:
535         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLElementUnstable.h:
536         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLEmbedElement.cpp:
537         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLEmbedElement.h:
538         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLEmbedElementPrivate.h:
539         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFieldSetElement.cpp:
540         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFieldSetElement.h:
541         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFieldSetElementPrivate.h:
542         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFontElement.cpp:
543         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFontElement.h:
544         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFontElementPrivate.h:
545         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFormElement.cpp:
546         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFormElement.h:
547         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFormElementPrivate.h:
548         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameElement.cpp:
549         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameElement.h:
550         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameElementPrivate.h:
551         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameSetElement.cpp:
552         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameSetElement.h:
553         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLFrameSetElementPrivate.h:
554         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHRElement.cpp:
555         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHRElement.h:
556         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHRElementPrivate.h:
557         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadElement.cpp:
558         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadElement.h:
559         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadElementPrivate.h:
560         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadingElement.cpp:
561         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadingElement.h:
562         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHeadingElementPrivate.h:
563         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHtmlElement.cpp:
564         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHtmlElement.h:
565         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLHtmlElementPrivate.h:
566         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLIFrameElement.cpp:
567         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLIFrameElement.h:
568         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLIFrameElementPrivate.h:
569         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLImageElement.cpp:
570         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLImageElement.h:
571         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLImageElementPrivate.h:
572         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLInputElement.cpp:
573         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLInputElement.h:
574         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLInputElementPrivate.h:
575         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLIElement.cpp:
576         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLIElement.h:
577         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLIElementPrivate.h:
578         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLabelElement.cpp:
579         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLabelElement.h:
580         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLabelElementPrivate.h:
581         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLegendElement.cpp:
582         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLegendElement.h:
583         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLegendElementPrivate.h:
584         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLinkElement.cpp:
585         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLinkElement.h:
586         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLLinkElementPrivate.h:
587         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMapElement.cpp:
588         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMapElement.h:
589         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMapElementPrivate.h:
590         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMarqueeElement.cpp:
591         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMarqueeElement.h:
592         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMarqueeElementPrivate.h:
593         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMenuElement.cpp:
594         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMenuElement.h:
595         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMenuElementPrivate.h:
596         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMetaElement.cpp:
597         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMetaElement.h:
598         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLMetaElementPrivate.h:
599         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLModElement.cpp:
600         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLModElement.h:
601         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLModElementPrivate.h:
602         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOListElement.cpp:
603         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOListElement.h:
604         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOListElementPrivate.h:
605         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLObjectElement.cpp:
606         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLObjectElement.h:
607         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLObjectElementPrivate.h:
608         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptGroupElement.cpp:
609         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptGroupElement.h:
610         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptGroupElementPrivate.h:
611         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionElement.cpp:
612         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionElement.h:
613         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionElementPrivate.h:
614         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionsCollection.cpp:
615         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionsCollection.h:
616         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLOptionsCollectionPrivate.h:
617         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParagraphElement.cpp:
618         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParagraphElement.h:
619         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParagraphElementPrivate.h:
620         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParamElement.cpp:
621         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParamElement.h:
622         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLParamElementPrivate.h:
623         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLPreElement.cpp:
624         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLPreElement.h:
625         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLPreElementPrivate.h:
626         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLPrivate.cpp:
627         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLQuoteElement.cpp:
628         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLQuoteElement.h:
629         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLQuoteElementPrivate.h:
630         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLScriptElement.cpp:
631         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLScriptElement.h:
632         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLScriptElementPrivate.h:
633         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLSelectElement.cpp:
634         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLSelectElement.h:
635         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLSelectElementPrivate.h:
636         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLStyleElement.cpp:
637         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLStyleElement.h:
638         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLStyleElementPrivate.h:
639         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCaptionElement.cpp:
640         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCaptionElement.h:
641         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCaptionElementPrivate.h:
642         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCellElement.cpp:
643         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCellElement.h:
644         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableCellElementPrivate.h:
645         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableColElement.cpp:
646         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableColElement.h:
647         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableColElementPrivate.h:
648         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableElement.cpp:
649         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableElement.h:
650         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableElementPrivate.h:
651         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableRowElement.cpp:
652         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableRowElement.h:
653         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableRowElementPrivate.h:
654         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableSectionElement.cpp:
655         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableSectionElement.h:
656         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTableSectionElementPrivate.h:
657         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTextAreaElement.cpp:
658         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTextAreaElement.h:
659         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTextAreaElementPrivate.h:
660         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTitleElement.cpp:
661         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTitleElement.h:
662         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLTitleElementPrivate.h:
663         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLUListElement.cpp:
664         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLUListElement.h:
665         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLUListElementPrivate.h:
666         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMKeyboardEvent.cpp:
667         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMKeyboardEvent.h:
668         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMKeyboardEventPrivate.h:
669         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMediaList.h:
670         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMediaListPrivate.h:
671         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMouseEvent.cpp:
672         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMouseEvent.h:
673         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMouseEventPrivate.h:
674         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNamedNodeMap.cpp:
675         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNamedNodeMap.h:
676         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNamedNodeMapPrivate.h:
677         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNode.h:
678         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeIterator.cpp:
679         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeIterator.h:
680         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeIteratorPrivate.h:
681         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeList.cpp:
682         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeList.h:
683         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodeListPrivate.h:
684         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMNodePrivate.h:
685         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMProcessingInstruction.cpp:
686         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMProcessingInstruction.h:
687         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMProcessingInstructionPrivate.h:
688         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMRange.cpp:
689         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMRange.h:
690         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMRangePrivate.h:
691         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMRangeUnstable.h:
692         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheet.cpp:
693         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheet.h:
694         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheetList.cpp:
695         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheetList.h:
696         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheetListPrivate.h:
697         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMStyleSheetPrivate.h:
698         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMText.cpp:
699         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMText.h:
700         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMTextPrivate.h:
701         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMTreeWalker.cpp:
702         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMTreeWalker.h:
703         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMTreeWalkerPrivate.h:
704         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMUIEvent.cpp:
705         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMUIEvent.h:
706         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMUIEventPrivate.h:
707         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMWheelEvent.cpp:
708         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMWheelEvent.h:
709         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMWheelEventPrivate.h:
710         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathExpression.cpp:
711         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathExpression.h:
712         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathExpressionPrivate.h:
713         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathNSResolverPrivate.h:
714         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathResult.cpp:
715         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathResult.h:
716         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathResultPrivate.h:
717         * WebProcess/InjectedBundle/API/gtk/DOM/webkitdom.h:
718         * WebProcess/InjectedBundle/API/gtk/DOM/webkitdomautocleanups.h:
719         * WebProcess/InjectedBundle/API/gtk/DOM/webkitdomdefines.h:
720
721 2016-10-23  Chris Dumez  <cdumez@apple.com>
722
723         Another unreviewed attempt to fix the WatchOS / TvOS build after r207585.
724         <rdar://problem/28902292>
725
726         Disable USE_CFURLCONNECTION on newer WatchOS / TvOS.
727
728         * config.h:
729
730 2016-10-23  Chris Dumez  <cdumez@apple.com>
731
732         Unreviewed attempt to fix WatchOS / TvOS build after r207585.
733         <rdar://problem/28902292>
734
735         Enable NETWORK_SESSION on those platforms.
736
737         * config.h:
738
739 2016-10-22  Dan Bernstein  <mitz@apple.com>
740
741         [iOS] _webViewWillEndNavigationGesture:withNavigationToBackForwardListItem: is never called
742         https://bugs.webkit.org/show_bug.cgi?id=163758
743
744         Reviewed by Darin Adler.
745
746         * UIProcess/ios/ViewGestureControllerIOS.mm:
747         (WebKit::ViewGestureController::beginSwipeGesture): Don’t reset the interactive update
748           handler.
749
750 2016-10-21  David Kilzer  <ddkilzer@apple.com>
751
752         Bug 163762: IntSize::area() should used checked arithmetic
753         <https://webkit.org/b/163762>
754
755         Reviewed by Darin Adler.
756
757         * Shared/ShareableBitmap.cpp:
758         (WebKit::ShareableBitmap::create): Add overflow check and return
759         nullptr on overflow.
760         (WebKit::ShareableBitmap::createShareable): Ditto.
761         (WebKit::ShareableBitmap::create): Change debug assert for
762         adequate buffer size check into release check.
763         * Shared/ShareableBitmap.h:
764         (WebKit::ShareableBitmap::numBytesForSize): Change to return a
765         Checked<unsigned, RecordOverflow> value.
766         (WebKit::ShareableBitmap::sizeInBytes):
767         * Shared/cairo/ShareableBitmapCairo.cpp:
768         (WebKit::ShareableBitmap::numBytesForSize): Ditto.
769         * UIProcess/API/Cocoa/WKWebView.mm:
770         (-[WKWebView _takeViewSnapshot]): Call unsafeGet().
771
772 2016-10-21  Eric Carlson  <eric.carlson@apple.com>
773
774         [MediaStream] Dynamically generate media capture sandbox extensions
775         https://bugs.webkit.org/show_bug.cgi?id=154861
776         <rdar://problem/24909411>
777
778         Reviewed by Tim Horton.
779
780         * Shared/SandboxExtension.h:
781         (WebKit::SandboxExtension::createHandleForGenericExtension):
782         * Shared/mac/SandboxExtensionMac.mm:
783         (WebKit::wkSandboxExtensionType): Add case for generic handle.
784         (WebKit::SandboxExtension::createHandleForGenericExtension): New.
785
786         * UIProcess/UserMediaPermissionRequestManagerProxy.cpp:
787         (WebKit::UserMediaPermissionRequestManagerProxy::invalidateRequests): Clear the list of extensions granted.
788         (WebKit::UserMediaPermissionRequestManagerProxy::userMediaAccessWasGranted): Extend the web 
789           process sandbox as necessary.
790         * UIProcess/UserMediaPermissionRequestManagerProxy.h:
791
792         * WebProcess/MediaStream/UserMediaPermissionRequestManager.cpp:
793         (WebKit::UserMediaPermissionRequestManager::~UserMediaPermissionRequestManager): Revoke all
794           sandbox extensions.
795         (WebKit::UserMediaPermissionRequestManager::grantUserMediaDevicesSandboxExtension): Consume
796           sandbox extensions.
797         * WebProcess/MediaStream/UserMediaPermissionRequestManager.h:
798
799         * WebProcess/WebPage/WebPage.cpp:
800         (WebKit::WebPage::grantUserMediaDevicesSandboxExtension): Pass-through to user media manager.
801         * WebProcess/WebPage/WebPage.h:
802
803         * WebProcess/WebPage/WebPage.messages.in: Add GrantUserMediaDevicesSandboxExtension.
804
805         * WebProcess/com.apple.WebProcess.sb.in: Add rules, defines, and a macro to allow dynamic extensions
806           for media capture devices.
807
808 2016-10-21  Gavin Barraclough  <barraclough@apple.com>
809
810         WebPageProxy should not need PageActivityState
811         https://bugs.webkit.org/show_bug.cgi?id=163821
812
813         Reviewed by Geoff Garen.
814
815         The PageActivityState is currently plumbed back from WebCore up to the UI process, to
816         determine whether to enabled process suppression. However the information it contains
817         (whether a page load is ongoing, whether audio is playing) is already available via
818         other means. Remove this use of PageActivityState.
819
820         * UIProcess/PageLoadState.cpp:
821         (WebKit::PageLoadState::commitChanges):
822             - PageLoadState notifies WebPageProxy when loading state changes.
823         * UIProcess/WebPageProxy.cpp:
824         (WebKit::WebPageProxy::updateThrottleState):
825             - Now relies on info from PageLoadState, setMuted, isPlayingMediaDidChange.
826         (WebKit::WebPageProxy::setMuted):
827         (WebKit::WebPageProxy::isPlayingMediaDidChange):
828             - If audio playback state changes we may need to update the throttle state.
829         (WebKit::WebPageProxy::setPageActivityState): Deleted.
830             - removed PageActivityState from WK2.
831         * UIProcess/WebPageProxy.h:
832         (WebKit::WebPageProxy::isLoadingChanged):
833             - PageLoadState notifies WebPageProxy when loading state changes.
834         * UIProcess/WebPageProxy.messages.in:
835             - removed PageActivityState from WK2.
836         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
837         (WebKit::WebChromeClient::setPageActivityState): Deleted.
838             - removed PageActivityState from WK2.
839         * WebProcess/WebCoreSupport/WebChromeClient.h:
840             - removed PageActivityState from WK2.
841         * WebProcess/WebPage/WebPage.cpp:
842         (WebKit::WebPage::setPageActivityState): Deleted.
843             - removed PageActivityState from WK2.
844         * WebProcess/WebPage/WebPage.h:
845             - removed PageActivityState from WK2.
846
847 2016-10-21  Gavin Barraclough  <barraclough@apple.com>
848
849         WebPage should take UserActivity directly for user input
850         https://bugs.webkit.org/show_bug.cgi?id=163813
851
852         Reviewed by Anders Carlsson.
853
854         When we receive mouse/keyboard events in a page, we want to prevent AppNap. We currently do so
855         via the PageThrottler. This patch is to just make the WebPage drive the UserActivity directly.
856
857         Two reasons to do so: (1) to cleanup & simplify for further refactoring. (2) The current code
858         isn't really achieving the desired effect. The page setting the flag in the throttler to get
859         the activity to be set is now a less effective way of achieving this goal, since the
860         PageActivityState bounces back across to the UI process & then messages back to the WebContent
861         process to take the UserActivity. These extra hops defeat the purpose of making sure the boost
862         from the initial message isn't lost.
863
864         * WebProcess/WebPage/WebPage.cpp:
865         (WebKit::m_userActivityHysteresis):
866             - m_userActivityHysteresis triggers updateUserActivity.
867         (WebKit::WebPage::setPageSuppressed):
868             - setPageSuppressed starts/stops m_userActivityHysteresis.
869         (WebKit::WebPage::updateUserActivity):
870             - update UserActivity based on state of m_userActivityHysteresis.
871         (WebKit::WebPage::mouseEvent):
872         (WebKit::WebPage::wheelEvent):
873         (WebKit::WebPage::keyEvent):
874             - input events impulse m_userActivityHysteresis.
875         * WebProcess/WebPage/WebPage.h:
876
877 2016-10-21  Wenson Hsieh  <wenson_hsieh@apple.com>
878
879         Support (insertFrom|deleteBy)Composition and (insert|delete)CompositionText inputTypes for InputEvents
880         https://bugs.webkit.org/show_bug.cgi?id=163460
881         <rdar://problem/28784142>
882
883         Reviewed by Darin Adler.
884
885         Handle new EditAction types for inserting/deleting pending/final compositions.
886
887         * UIProcess/WebEditCommandProxy.cpp:
888         (WebKit::WebEditCommandProxy::nameForEditAction):
889
890 2016-10-21  Jeremy Jones  <jeremyj@apple.com>
891
892         Implement basic pointer lock behavior for WebKit and WebKit2.
893         https://bugs.webkit.org/show_bug.cgi?id=162745
894
895         Reviewed by Simon Fraser.
896
897         Enable basic pointer lock functionality by plumbing requests through WebPage IPC.
898         Pass through mouse movement deltas.
899         Unlock pointer when view is no longer visible.
900
901         * Shared/WebEventConversion.cpp:
902         (WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent): Pass along mouse movement.
903         * UIProcess/WebPageProxy.cpp:
904         (WebKit::WebPageProxy::dispatchViewStateChange): Unlock pointer when page is not visible.
905         (WebKit::WebPageProxy::requestPointerLock): Hide and disassociate pointer.
906         (WebKit::WebPageProxy::requestPointerUnlock): Show and associate pointer.
907         * UIProcess/WebPageProxy.h:
908         * UIProcess/WebPageProxy.messages.in: Add methods.
909         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
910         (WebKit::WebChromeClient::requestPointerLock): Pass along to web page.
911         (WebKit::WebChromeClient::requestPointerUnlock): Ditto.
912         * WebProcess/WebCoreSupport/WebChromeClient.h:
913         * WebProcess/WebPage/WebPage.cpp:
914         (WebKit::WebPage::didAcquirePointerLock): Forward to PointerLockController.
915         (WebKit::WebPage::didNotAcquirePointerLock): Ditto.
916         (WebKit::WebPage::didLosePointerLock): Ditto.
917         * WebProcess/WebPage/WebPage.h:
918         * WebProcess/WebPage/WebPage.messages.in: Add methods.
919
920 2016-10-21  Wenson Hsieh  <wenson_hsieh@apple.com>
921
922         Implement InputEvent.getTargetRanges() for the input events spec
923         https://bugs.webkit.org/show_bug.cgi?id=162947
924         <rdar://problem/28853079>
925
926         Reviewed by Darin Adler.
927
928         Boilerplate change to add a runtime guard for InputEvents-related IDL interfaces. See WebCore ChangeLog entry
929         for more details.
930
931         * WebProcess/WebPage/WebPage.cpp:
932         (WebKit::WebPage::updatePreferences):
933
934 2016-10-20  Carlos Garcia Campos  <cgarcia@igalia.com>
935
936         [GTK] Configures but fails to link with ENABLE_OPENGL=OFF
937         https://bugs.webkit.org/show_bug.cgi?id=163449
938
939         Reviewed by Michael Catanzaro.
940
941         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
942         (webkitWebViewBaseRealize): Check TEXTURE_MAPPER_GL instead of TEXTURE_MAPPER and also ensure the current
943         display is X11.
944         (webkitWebViewBaseUnrealize): Ditto.
945         (webkitWebViewBaseDidRelaunchWebProcess): Check TEXTURE_MAPPER_GL instead of TEXTURE_MAPPER.
946         (webkitWebViewBasePageClosed): Ditto.
947         * UIProcess/AcceleratedDrawingAreaProxy.cpp:
948         (WebKit::AcceleratedDrawingAreaProxy::didUpdateBackingStoreState): Ditto.
949         (WebKit::AcceleratedDrawingAreaProxy::waitForAndDispatchDidUpdateBackingStoreState): Check EGL is enabled before
950         trying to use the WaylandCompositor.
951         * UIProcess/AcceleratedDrawingAreaProxy.h:
952         * UIProcess/WebProcessPool.cpp:
953         (WebKit::WebProcessPool::createNewWebProcess): Ditto.
954         * UIProcess/gtk/AcceleratedBackingStore.cpp:
955         (WebKit::AcceleratedBackingStore::create): Ditto.
956         * UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:
957         * UIProcess/gtk/WaylandCompositor.cpp:
958         * UIProcess/gtk/WaylandCompositor.h:
959         * WebProcess/WebPage/AcceleratedDrawingArea.cpp:
960         (WebKit::AcceleratedDrawingArea::enterAcceleratedCompositingMode): Check TEXTURE_MAPPER_GL instead of TEXTURE_MAPPER.
961         * WebProcess/WebPage/AcceleratedDrawingArea.h:
962         * WebProcess/WebPage/DrawingArea.h:
963         * WebProcess/WebPage/DrawingArea.messages.in:
964         * WebProcess/WebPage/LayerTreeHost.h:
965
966 2016-10-20  Chris Dumez  <cdumez@apple.com>
967
968         "Download Linked File" context menu action should use 'download' attribute as suggested filename
969         https://bugs.webkit.org/show_bug.cgi?id=163742
970         <rdar://problem/28840734>
971
972         Reviewed by Darin Adler.
973
974         Update "Download Linked File" context menu action to use the anchor
975         element's 'download' attribute as suggested filename for the download.
976
977         * NetworkProcess/NetworkProcess.cpp:
978         (WebKit::NetworkProcess::downloadRequest):
979         * NetworkProcess/NetworkProcess.h:
980         * NetworkProcess/NetworkProcess.messages.in:
981         * Shared/WebHitTestResultData.cpp:
982         (WebKit::WebHitTestResultData::WebHitTestResultData):
983         (WebKit::WebHitTestResultData::encode):
984         (WebKit::WebHitTestResultData::decode):
985         * Shared/WebHitTestResultData.h:
986         * UIProcess/WebPageProxy.cpp:
987         (WebKit::WebPageProxy::contextMenuItemSelected):
988         * UIProcess/WebProcessPool.cpp:
989         (WebKit::WebProcessPool::download):
990         * UIProcess/WebProcessPool.h:
991         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
992         (WebKit::InjectedBundleHitTestResult::linkSuggestedFilename):
993
994 2016-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
995
996         [macOS] [iOS] Disable variation fonts on macOS El Capitan and iOS 9
997         https://bugs.webkit.org/show_bug.cgi?id=163374
998
999         Reviewed by Darin Adler.
1000
1001         * Configurations/FeatureDefines.xcconfig:
1002
1003 2016-10-20  Brady Eidson  <beidson@apple.com>
1004
1005         IndexedDB 2.0: Support IDBObjectStore name assignment.
1006         <rdar://problem/28806931> and https://bugs.webkit.org/show_bug.cgi?id=163749
1007
1008         Reviewed by Alex Christensen.
1009
1010         * DatabaseProcess/IndexedDB/WebIDBConnectionToClient.cpp:
1011         (WebKit::WebIDBConnectionToClient::didRenameObjectStore):
1012         (WebKit::WebIDBConnectionToClient::renameObjectStore):
1013         * DatabaseProcess/IndexedDB/WebIDBConnectionToClient.h:
1014         * DatabaseProcess/IndexedDB/WebIDBConnectionToClient.messages.in:
1015
1016         * WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.cpp:
1017         (WebKit::WebIDBConnectionToServer::renameObjectStore):
1018         (WebKit::WebIDBConnectionToServer::didRenameObjectStore):
1019         * WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.h:
1020         * WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.messages.in:
1021
1022 2016-10-20  Carlos Garcia Campos  <cgarcia@igalia.com>
1023
1024         [GTK] Avoid strstr() when checking (E)GL extensions
1025         https://bugs.webkit.org/show_bug.cgi?id=161958
1026
1027         Reviewed by Žan Doberšek.
1028
1029         Use GLContext::isExtensionSupported() instead of strstr().
1030
1031         * UIProcess/gtk/WaylandCompositor.cpp:
1032         (WebKit::WaylandCompositor::initializeEGL):
1033
1034 2016-10-20  Carlos Garcia Campos  <cgarcia@igalia.com>
1035
1036         Wrong use of EGL_DEPTH_SIZE
1037         https://bugs.webkit.org/show_bug.cgi?id=155536
1038
1039         Reviewed by Michael Catanzaro.
1040
1041         Use XErrorTrapper class instead of the custom XErrorHandler.
1042
1043         * PluginProcess/unix/PluginProcessMainUnix.cpp:
1044         (WebKit::PluginProcessMainUnix):
1045
1046 2016-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1047
1048         [SOUP] Add NetworkSession implementation and switch to use it
1049         https://bugs.webkit.org/show_bug.cgi?id=163597
1050
1051         Reviewed by Alex Christensen.
1052
1053         Basically move the ResourceHandle implementation to the network process, but modernized, cleaned up, and adapted
1054         to the NetworkSession model.
1055
1056         * CMakeLists.txt: Add new files to compilation.
1057         * NetworkProcess/Downloads/Download.cpp:
1058         (WebKit::Download::Download): Use the same code for all ports using NetworkSession and add missing
1059         initialization of m_sessionID.
1060         * NetworkProcess/Downloads/Download.h:
1061         (WebKit::Download::Download): Define PlatformDownloadTaskRef on every platform to make the constructor common to
1062         all ports using NetworkSession.
1063         * NetworkProcess/Downloads/soup/DownloadSoup.cpp:
1064         (WebKit::Download::cancelNetworkLoad):
1065         (WebKit::Download::platformDidFinish):
1066         * NetworkProcess/NetworkDataTask.h:
1067         (WebKit::NetworkDataTask::pendingDownloadID): Make const.
1068         (WebKit::NetworkDataTask::pendingDownload): Ditto.
1069         (WebKit::NetworkDataTask::pendingDownloadLocation): Ditto.
1070         (WebKit::NetworkDataTask::isDownload): Helper to check if the task is a download.
1071         * NetworkProcess/NetworkLoad.cpp:
1072         (WebKit::NetworkLoad::didReceiveResponseNetworkSession): Use NetworkDataTask::isDownload().
1073         * NetworkProcess/NetworkProcess.cpp:
1074         (WebKit::NetworkProcess::NetworkProcess): NetworkSession::setCustomProtocolManager() is Cocoa only.
1075         * NetworkProcess/NetworkSession.h:
1076         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
1077         (WebKit::NetworkSession::networkStorageSession): Make const.
1078         * NetworkProcess/soup/NetworkDataTaskSoup.cpp: Added.
1079         (WebKit::NetworkDataTask::NetworkDataTask):
1080         (WebKit::NetworkDataTask::~NetworkDataTask):
1081         (WebKit::NetworkDataTask::scheduleFailure):
1082         (WebKit::NetworkDataTask::failureTimerFired):
1083         (WebKit::NetworkDataTask::suggestedFilename):
1084         (WebKit::NetworkDataTask::setSuggestedFilename):
1085         (WebKit::NetworkDataTask::setPendingDownloadLocation):
1086         (WebKit::NetworkDataTask::allowsSpecificHTTPSCertificateForHost):
1087         (WebKit::NetworkDataTask::createRequest):
1088         (WebKit::NetworkDataTask::clearRequest):
1089         (WebKit::NetworkDataTask::resume):
1090         (WebKit::NetworkDataTask::suspend):
1091         (WebKit::NetworkDataTask::cancel):
1092         (WebKit::NetworkDataTask::invalidateAndCancel):
1093         (WebKit::NetworkDataTask::state):
1094         (WebKit::NetworkDataTask::timeoutFired):
1095         (WebKit::NetworkDataTask::startTimeout):
1096         (WebKit::NetworkDataTask::stopTimeout):
1097         (WebKit::NetworkDataTask::sendRequestCallback):
1098         (WebKit::NetworkDataTask::didSendRequest):
1099         (WebKit::NetworkDataTask::didReceiveResponse):
1100         (WebKit::NetworkDataTask::tlsErrorsChangedCallback):
1101         (WebKit::NetworkDataTask::tlsErrorsChanged):
1102         (WebKit::NetworkDataTask::applyAuthenticationToRequest):
1103         (WebKit::NetworkDataTask::authenticateCallback):
1104         (WebKit::isAuthenticationFailureStatusCode):
1105         (WebKit::NetworkDataTask::authenticate):
1106         (WebKit::NetworkDataTask::continueAuthenticate):
1107         (WebKit::NetworkDataTask::skipInputStreamForRedirectionCallback):
1108         (WebKit::NetworkDataTask::skipInputStreamForRedirection):
1109         (WebKit::NetworkDataTask::didFinishSkipInputStreamForRedirection):
1110         (WebKit::shouldRedirectAsGET):
1111         (WebKit::NetworkDataTask::shouldStartHTTPRedirection):
1112         (WebKit::NetworkDataTask::continueHTTPRedirection):
1113         (WebKit::NetworkDataTask::readCallback):
1114         (WebKit::NetworkDataTask::read):
1115         (WebKit::NetworkDataTask::didRead):
1116         (WebKit::NetworkDataTask::didFinishRead):
1117         (WebKit::NetworkDataTask::requestNextPartCallback):
1118         (WebKit::NetworkDataTask::requestNextPart):
1119         (WebKit::NetworkDataTask::didRequestNextPart):
1120         (WebKit::NetworkDataTask::didFinishRequestNextPart):
1121         (WebKit::NetworkDataTask::gotHeadersCallback):
1122         (WebKit::NetworkDataTask::didGetHeaders):
1123         (WebKit::NetworkDataTask::wroteBodyDataCallback):
1124         (WebKit::NetworkDataTask::didWriteBodyData):
1125         (WebKit::NetworkDataTask::download):
1126         (WebKit::NetworkDataTask::writeDownloadCallback):
1127         (WebKit::NetworkDataTask::writeDownload):
1128         (WebKit::NetworkDataTask::didWriteDownload):
1129         (WebKit::NetworkDataTask::didFinishDownload):
1130         (WebKit::NetworkDataTask::didFailDownload):
1131         (WebKit::NetworkDataTask::cleanDownloadFiles):
1132         (WebKit::NetworkDataTask::didFail):
1133         (WebKit::NetworkDataTask::networkEventCallback):
1134         (WebKit::NetworkDataTask::networkEvent):
1135         (WebKit::NetworkDataTask::startingCallback):
1136         (WebKit::NetworkDataTask::requestStartedCallback):
1137         (WebKit::NetworkDataTask::didStartRequest):
1138         (WebKit::NetworkDataTask::restartedCallback):
1139         (WebKit::NetworkDataTask::didRestart):
1140         * NetworkProcess/soup/NetworkSessionSoup.cpp:
1141         (WebKit::NetworkSession::create):
1142         (WebKit::NetworkSession::defaultSession):
1143         (WebKit::NetworkSession::networkStorageSession):
1144         (WebKit::NetworkSession::NetworkSession):
1145         (WebKit::NetworkSession::~NetworkSession):
1146         (WebKit::NetworkSession::soupSession):
1147         (WebKit::NetworkSession::invalidateAndCancel):
1148         (WebKit::NetworkSession::clearCredentials):
1149         * NetworkProcess/soup/RemoteNetworkingContextSoup.cpp:
1150         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession): Add implementation matching
1151         WebFrameNetworkingContext::ensurePrivateBrowsingSession().
1152         (WebKit::RemoteNetworkingContext::storageSession): Do not always return the default session if the given one is
1153         in the global map.
1154         * PlatformEfl.cmake: Ad new files to compilation.
1155         * PlatformGTK.cmake: Ditto.
1156         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
1157         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession): Also create a NetworkSession.
1158         * config.h: Enable NetworkSession unconditionally for Soup based ports.
1159
1160 2016-10-19  Alex Christensen  <achristensen@webkit.org>
1161
1162         Revert r207151
1163         https://bugs.webkit.org/show_bug.cgi?id=163675
1164
1165         Reviewed by Brent Fulgham.
1166
1167         * NetworkProcess/Downloads/Download.h:
1168         * NetworkProcess/Downloads/mac/DownloadMac.mm:
1169         * NetworkProcess/NetworkLoad.h:
1170         * NetworkProcess/mac/NetworkLoadMac.mm:
1171         (WebKit::NetworkLoad::willCacheResponseAsync):
1172         * Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm:
1173         (WebKit::AuthenticationManager::receivedCredential):
1174         (WebKit::AuthenticationManager::receivedRequestToContinueWithoutCredential):
1175         (WebKit::AuthenticationManager::receivedCancellation):
1176         (WebKit::AuthenticationManager::receivedRequestToPerformDefaultHandling):
1177         (WebKit::AuthenticationManager::receivedChallengeRejection):
1178         * Shared/WebProcessCreationParameters.cpp:
1179         (WebKit::WebProcessCreationParameters::encode):
1180         (WebKit::WebProcessCreationParameters::decode):
1181         * Shared/WebProcessCreationParameters.h:
1182         * Shared/mac/WebCoreArgumentCodersMac.mm:
1183         (IPC::ArgumentCoder<ResourceRequest>::encodePlatformData):
1184         (IPC::ArgumentCoder<ResourceRequest>::decodePlatformData):
1185         * WebKit2.xcodeproj/project.pbxproj:
1186
1187 2016-10-19  Chris Dumez  <cdumez@apple.com>
1188
1189         [WK2] Expose suggested filename via WKBundleHitTestResult API
1190         https://bugs.webkit.org/show_bug.cgi?id=163693
1191         <rdar://problem/28840734>
1192
1193         Reviewed by Anders Carlsson.
1194
1195         Expose suggested filename via WKBundleHitTestResult API. The implementation
1196         currently relies on the 'download' attribute on anchor / area elements
1197         that we recently started supporting.
1198
1199         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
1200         (WKBundleHitTestResultCopyLinkSuggestedFilename):
1201         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.h:
1202         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
1203         (WebKit::InjectedBundleHitTestResult::create):
1204         (WebKit::InjectedBundleHitTestResult::mediaType):
1205         (WebKit::InjectedBundleHitTestResult::linkSuggestedFilename):
1206         (WebKit::InjectedBundleHitTestResult::imageRect):
1207         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
1208
1209 2016-10-19  Ryan Haddad  <ryanhaddad@apple.com>
1210
1211         Unreviewed, rolling out r207557.
1212
1213         This change caused animations/font-variations tests to time
1214         out on pre-Sierra Macs.
1215
1216         Reverted changeset:
1217
1218         "[macOS] [iOS] Disable variation fonts on macOS El Capitan and
1219         iOS 9"
1220         https://bugs.webkit.org/show_bug.cgi?id=163374
1221         http://trac.webkit.org/changeset/207557
1222
1223 2016-10-19  Andy Estes  <aestes@apple.com>
1224
1225         Crash in ASCIICaseInsensitiveHash::hash() when a response has a null MIME type
1226         https://bugs.webkit.org/show_bug.cgi?id=163476
1227         <rdar://problem/26941395>
1228
1229         Reviewed by Andreas Kling.
1230
1231         When custom content providers are registered and a response has a null MIME type, WebPage
1232         will pass a null String to HashSet::contains(). This results in a null pointer dereference,
1233         since the String hash functions do not support null Strings and unconditionally dereference
1234         their StringImpls. Fixed by checking that Strings are non-null before calling
1235         HashSet::contains() on m_mimeTypesWithCustomContentProviders.
1236
1237         New API test: WebKit2.LoadDataWithNilMIMEType.
1238
1239         * WebProcess/WebPage/WebPage.cpp:
1240         (WebKit::WebPage::shouldUseCustomContentProviderForResponse): Checked if mimeType is null
1241         before calling m_mimeTypesWithCustomContentProviders.contains().
1242         (WebKit::WebPage::canShowMIMEType): Ditto.
1243         * WebProcess/WebPage/WebPage.h: Made private the declaration of canPluginHandleResponse().
1244
1245 2016-10-19  Chris Dumez  <cdumez@apple.com>
1246
1247         Move HTML Interactive Form Validation behind an experimental flag
1248         https://bugs.webkit.org/show_bug.cgi?id=163673
1249
1250         Reviewed by Daniel Bates.
1251
1252         Move HTML Interactive Form Validation behind an experimental feature flag
1253         and disable by default until by have a better UI.
1254
1255         * Shared/WebPreferencesDefinitions.h:
1256         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1257         (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
1258
1259 2016-10-19  Damian Kaleta  <dkaleta@apple.com>
1260
1261         https://bugs.webkit.org/show_bug.cgi?id=163292
1262
1263         Reviewed by Brady Eidson.
1264         
1265         Added ability to display context menu asynchronously.
1266
1267         * Shared/API/APIObject.h: Added ContextMenuListener.
1268         * Shared/API/c/WKBase.h: Added WKContextMenuListenerRef struct.
1269         * UIProcess/API/APIContextMenuClient.h:
1270         (API::ContextMenuClient::getContextMenuFromProposedMenuAsync): New method that allows showing context menu asynchronously.
1271         * UIProcess/API/C/WKAPICast.h: Added a new mapping for WebContextMenuListenerProxy.
1272         * UIProcess/API/C/WKContextMenuListener.cpp: Added. New class that allow a client to return results asynchronously.
1273         (WKContextMenuListenerGetTypeID):
1274         (WKContextMenuListenerUseContextMenuItems):
1275         * UIProcess/API/C/WKContextMenuListener.h: Added.
1276         * UIProcess/API/C/WKPage.cpp: Added WKPageContextMenuClientV4.
1277         (WKPageSetPageContextMenuClient):
1278         * UIProcess/API/C/WKPageContextMenuClient.h:
1279         * UIProcess/WebContextMenuListenerProxy.cpp: Copied from Source/WebKit2/UIProcess/mac/WebContextMenuProxyMac.h.
1280         (WebKit::WebContextMenuListenerProxy::WebContextMenuListenerProxy):
1281         (WebKit::WebContextMenuListenerProxy::~WebContextMenuListenerProxy):
1282         (WebKit::WebContextMenuListenerProxy::useContextMenuItems): Passes items to m_contextMenuMac.
1283         (WebKit::WebContextMenuListenerProxy::invalidate):
1284         * UIProcess/WebContextMenuListenerProxy.h: Copied from Source/WebKit2/UIProcess/mac/WebContextMenuProxyMac.h.
1285         (WebKit::WebContextMenuListenerProxy::create):
1286         * UIProcess/mac/WebContextMenuProxyMac.h:
1287         * UIProcess/mac/WebContextMenuProxyMac.mm:
1288         (WebKit::WebContextMenuProxyMac::showContextMenuWithItems): Shows context menu.
1289         (WebKit::WebContextMenuProxyMac::showContextMenu): Extracted some logic to showContextMenuWithItems().
1290         * WebKit2.xcodeproj/project.pbxproj:
1291
1292 2016-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
1293
1294         [macOS] [iOS] Disable variation fonts on macOS El Capitan and iOS 9
1295         https://bugs.webkit.org/show_bug.cgi?id=163374
1296
1297         Reviewed by Darin Adler.
1298
1299         * Configurations/FeatureDefines.xcconfig:
1300
1301 2016-10-19  Darin Adler  <darin@apple.com>
1302
1303         Move XPath from ExceptionCode to Exception
1304         https://bugs.webkit.org/show_bug.cgi?id=163656
1305
1306         Reviewed by Chris Dumez.
1307
1308         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDocument.cpp:
1309         (webkit_dom_document_create_expression): Use ExceptionOr.
1310         (webkit_dom_document_evaluate): Ditto.
1311         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathExpression.cpp:
1312         (webkit_dom_xpath_expression_evaluate): Ditto.
1313         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMXPathResult.cpp:
1314         (webkit_dom_xpath_result_iterate_next): Ditto.
1315         (webkit_dom_xpath_result_snapshot_item): Ditto.
1316         (webkit_dom_xpath_result_get_number_value): Ditto.
1317         (webkit_dom_xpath_result_get_string_value): Ditto.
1318         (webkit_dom_xpath_result_get_boolean_value): Ditto.
1319         (webkit_dom_xpath_result_get_single_node_value): Ditto.
1320         (webkit_dom_xpath_result_get_snapshot_length): Ditto.
1321
1322 2016-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1323
1324         NetworkSession: updatedRequest parameter of NetworkProcess::findPendingDownloadLocation is unused since r206988
1325         https://bugs.webkit.org/show_bug.cgi?id=163588
1326
1327         Reviewed by Alex Christensen.
1328
1329         The parameter was used only for the DownloadProxy::DidStart message that is no longer sent from
1330         findPendingDownloadLocation since r206988.
1331
1332         * NetworkProcess/NetworkDataTask.h:
1333         (WebKit::NetworkDataTask::currentRequest): Removed since it's unused now.
1334         * NetworkProcess/NetworkLoad.cpp:
1335         (WebKit::NetworkLoad::convertTaskToDownload): Update the m_currentRequest and pass it to DidStart message.
1336         (WebKit::NetworkLoad::didReceiveResponseNetworkSession):
1337         * NetworkProcess/NetworkProcess.cpp:
1338         (WebKit::NetworkProcess::findPendingDownloadLocation):
1339         * NetworkProcess/NetworkProcess.h:
1340         * NetworkProcess/cocoa/NetworkDataTaskCocoa.mm: Remove currentRequest() implementation.
1341
1342 2016-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1343
1344         Unreviewed. Fix GTK+ build after r207522.
1345
1346         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMWindow.cpp:
1347         (webkit_dom_dom_window_webkit_message_handlers_post_message): Use new exceptions.
1348
1349 2016-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1350
1351         Unreviewed. Fix GTK+ build after r207497.
1352
1353         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLSelectElement.cpp:
1354         (webkit_dom_html_select_element_add): Update implementation since add() now takes a Variant.
1355
1356 2016-10-18  Simon Fraser  <simon.fraser@apple.com>
1357
1358         Add a MiniBrowser menu item to apply page scale in WK1 and WK2
1359         https://bugs.webkit.org/show_bug.cgi?id=163627
1360
1361         Reviewed by Dean Jackson.
1362
1363         New SPI to set and retrieve page scale.
1364
1365         * UIProcess/API/Cocoa/WKWebView.mm:
1366         (-[WKWebView _setPageScale:withOrigin:]):
1367         (-[WKWebView _pageScale]):
1368         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1369
1370 2016-10-18  Dean Jackson  <dino@apple.com>
1371
1372         Remove CSS_SHAPES feature definition. This should always be on.
1373         https://bugs.webkit.org/show_bug.cgi?id=163628
1374         <rdar://problem/28834613>
1375
1376         Reviewed by Tim Horton.
1377
1378         * Configurations/FeatureDefines.xcconfig:
1379
1380 2016-10-18  Ryan Haddad  <ryanhaddad@apple.com>
1381
1382         Unreviewed, rolling out r207413.
1383
1384         This change broke iOS builds.
1385
1386         Reverted changeset:
1387
1388         "[iOS] Hook up WebPlatformTouchPoint's radiusX / radiusY to
1389         _UIWebTouchPoint.majorRadiusInScreenCoordinates"
1390         https://bugs.webkit.org/show_bug.cgi?id=163547
1391         http://trac.webkit.org/changeset/207413
1392
1393 2016-10-18  Commit Queue  <commit-queue@webkit.org>
1394
1395         Unreviewed, rolling out r207443.
1396         https://bugs.webkit.org/show_bug.cgi?id=163616
1397
1398         "Caused 5% PLT regression" (Requested by krollin on #webkit).
1399
1400         Reverted changeset:
1401
1402         "Crash in ASCIICaseInsensitiveHash::hash() when a response has
1403         a null MIME type"
1404         https://bugs.webkit.org/show_bug.cgi?id=163476
1405         http://trac.webkit.org/changeset/207443
1406
1407 2016-10-18  Megan Gardner  <megan_gardner@apple.com>
1408
1409         Fix build for platforms where HAVE(LINK_PREVIEW) is false
1410         https://bugs.webkit.org/show_bug.cgi?id=163607
1411
1412         Reviewed by Tim Horton.
1413
1414         Added needed # for link preview
1415
1416         * UIProcess/ios/WKContentViewInteraction.mm:
1417         (-[WKContentView _contentsOfUserInterfaceItem:]):
1418
1419 2016-10-18  Joseph Pecoraro  <pecoraro@apple.com>
1420
1421         Remote Web Inspector: Timeline UI not updating while recording
1422         https://bugs.webkit.org/show_bug.cgi?id=163582
1423         <rdar://problem/28766837>
1424
1425         Reviewed by Timothy Hatcher.
1426
1427         * WebProcess/WebPage/RemoteWebInspectorUI.cpp:
1428         (WebKit::RemoteWebInspectorUI::frontendLoaded):
1429         Local inspector windows keep the web view alive and toggle the
1430         WebInspector.visible state depending on whether or not an inspector is
1431         open. Remote Inspector windows go away when closed, so they can always
1432         be marked as open. This matches earlier remote inspector behavior.
1433
1434 2016-10-18  Eric Carlson  <eric.carlson@apple.com>
1435
1436         [MediaStream] Resolve constraints and enumerate devices in the UI process
1437         https://bugs.webkit.org/show_bug.cgi?id=162147
1438         <rdar://problem/28803569>
1439
1440         Reviewed by Darin Adler.
1441         
1442         Restructure gUM constraint validation and MediaDevices.enumerateDevices so all media device
1443         access happens in the UI process.
1444
1445         * Scripts/webkit/messages.py:
1446         (headers_for_type): Special case MediaConstraintsData.
1447
1448         * Shared/WebCoreArgumentCoders.cpp:
1449         (IPC::encodeMediaTrackConstraintSetMap): MediaTrackConstraintSetMap encoder.
1450         (IPC::ArgumentCoder<MediaConstraintsData>::encode): MediaConstraintsData encoder.
1451         (IPC::decodeMediaTrackConstraintSetMap): MediaTrackConstraintSetMap decoder.
1452         (IPC::ArgumentCoder<MediaConstraintsData>::decode): MediaConstraintsData decoder.
1453         (IPC::ArgumentCoder<CaptureDevice>::encode): CaptureDevice enoder.
1454         (IPC::ArgumentCoder<CaptureDevice>::decode): CaptureDevice decoder.
1455         * Shared/WebCoreArgumentCoders.h:
1456
1457         * UIProcess/API/APIUIClient.h:  Remove UserMediaPermissionCheckProxy forward declaration.
1458
1459         * UIProcess/API/C/WKUserMediaPermissionRequest.cpp:
1460         (toWK): Translate UserMediaPermissionRequestDenialReason to UserMediaAccessDenialReason.
1461         (WKUserMediaPermissionRequestDeny): Add "reason" parameter.
1462         * UIProcess/API/C/WKUserMediaPermissionRequest.h:
1463
1464         * UIProcess/UserMediaPermissionRequestManagerProxy.cpp:
1465         (WebKit::UserMediaPermissionRequestManagerProxy::invalidateRequests): Invalidate pending device requests.
1466         (WebKit::UserMediaPermissionRequestManagerProxy::createRequest): Make private.
1467         (WebKit::toWebCore): Map from UserMediaAccessDenialReason to MediaAccessDenialReason, cast to
1468           uint64_t to pass to web process.
1469         (WebKit::UserMediaPermissionRequestManagerProxy::denyRequest): Send to web process.
1470         (WebKit::UserMediaPermissionRequestManagerProxy::userMediaAccessWasGranted): Ditto.
1471         (WebKit::UserMediaPermissionRequestManagerProxy::requestUserMediaPermissionForFrame): Validate
1472           constraints and make sure gUM is enabled before prompting user.
1473         (WebKit::UserMediaPermissionRequestManagerProxy::enumerateMediaDevicesForFrame): New.
1474         (WebKit::UserMediaPermissionRequestManagerProxy::didCompleteUserMediaPermissionCheck): Send 
1475           results of device enumeration to web process.
1476         (WebKit::UserMediaPermissionRequestManagerProxy::didReceiveUserMediaPermissionDecision): Deleted.
1477         (WebKit::UserMediaPermissionRequestManagerProxy::createUserMediaPermissionCheck): Deleted.
1478         * UIProcess/UserMediaPermissionRequestManagerProxy.h:
1479
1480         * UIProcess/UserMediaPermissionRequestProxy.cpp:
1481         (WebKit::UserMediaPermissionRequestProxy::allow):
1482         (WebKit::UserMediaPermissionRequestProxy::deny): Take "reason" parameter.
1483         * UIProcess/UserMediaPermissionRequestProxy.h:
1484
1485         * UIProcess/WebPageProxy.cpp:
1486         (WebKit::WebPageProxy::requestUserMediaPermissionForFrame):
1487         (WebKit::WebPageProxy::enumerateMediaDevicesForFrame):
1488         (WebKit::WebPageProxy::checkUserMediaPermissionForFrame): Deleted.
1489         * UIProcess/WebPageProxy.h:
1490         * UIProcess/WebPageProxy.messages.in:
1491
1492         * WebProcess/MediaStream/UserMediaPermissionRequestManager.cpp:
1493         (WebKit::UserMediaPermissionRequestManager::startUserMediaRequest): userMediaAccessDenied -> deny.
1494           Pass the audio and video constraints to the UI process.
1495         (WebKit::UserMediaPermissionRequestManager::userMediaAccessWasGranted): 
1496         (WebKit::UserMediaPermissionRequestManager::userMediaAccessWasDenied):
1497         (WebKit::UserMediaPermissionRequestManager::enumerateMediaDevices): Send the enumeration request
1498           to the UI process.
1499         (WebKit::UserMediaPermissionRequestManager::cancelMediaDevicesEnumeration):
1500         (WebKit::UserMediaPermissionRequestManager::didCompleteMediaDeviceEnumeration):
1501         (WebKit::UserMediaPermissionRequestManager::didReceiveUserMediaPermissionDecision): Deleted.
1502         (WebKit::UserMediaPermissionRequestManager::startUserMediaPermissionCheck): Deleted.
1503         (WebKit::UserMediaPermissionRequestManager::cancelUserMediaPermissionCheck): Deleted.
1504         (WebKit::UserMediaPermissionRequestManager::didCompleteUserMediaPermissionCheck): Deleted.
1505         * WebProcess/MediaStream/UserMediaPermissionRequestManager.h:
1506
1507         * WebProcess/WebCoreSupport/WebUserMediaClient.cpp:
1508         (WebKit::WebUserMediaClient::enumerateMediaDevices): New.
1509         (WebKit::WebUserMediaClient::cancelMediaDevicesEnumerationRequest): New.
1510         (WebKit::WebUserMediaClient::checkUserMediaPermission): Deleted.
1511         (WebKit::WebUserMediaClient::cancelUserMediaPermissionCheck): Deleted.
1512         * WebProcess/WebCoreSupport/WebUserMediaClient.h:
1513
1514         * WebProcess/WebPage/WebPage.cpp:
1515         (WebKit::WebPage::userMediaAccessWasGranted): New.
1516         (WebKit::WebPage::userMediaAccessWasDenied): Ditto.
1517         (WebKit::WebPage::didCompleteMediaDeviceEnumeration):
1518         (WebKit::WebPage::didReceiveUserMediaPermissionDecision): Deleted.
1519         (WebKit::WebPage::didCompleteUserMediaPermissionCheck): Deleted.
1520         * WebProcess/WebPage/WebPage.h:
1521         * WebProcess/WebPage/WebPage.messages.in:
1522
1523 2016-10-17  Antti Koivisto  <antti@apple.com>
1524
1525         Rename setNeedsStyleRecalc to invalidateStyle
1526         https://bugs.webkit.org/show_bug.cgi?id=163542
1527
1528         Reviewed by Darin Adler.
1529
1530         * WebProcess/Plugins/PluginView.cpp:
1531         (WebKit::PluginView::didInitializePlugin):
1532         (WebKit::PluginView::pluginProcessCrashed):
1533
1534 2016-10-17  Carlos Garcia Campos  <cgarcia@igalia.com>
1535
1536         NetworkSession: PendingDownload is leaked if canceled before willDecidePendingDownloadDestination
1537         https://bugs.webkit.org/show_bug.cgi?id=163545
1538
1539         Reviewed by Alex Christensen.
1540
1541         If a download started by DownloadManager::startDownload() is cancelled before
1542         DownloadManager::willDecidePendingDownloadDestination() is called, DownloadManager::cancelDownload() does
1543         nothing, because the Download hasn't been created yet and m_downloadsWaitingForDestination map doesn't contain
1544         the download ID, and the PendingDownload is never removed from the m_pendingDownloads map.
1545
1546         * NetworkProcess/Downloads/DownloadManager.cpp:
1547         (WebKit::DownloadManager::cancelDownload): Always take the PendingDownload from m_pendingDownloads map. Then, if
1548         the download was already in m_downloadsWaitingForDestination map, get the network data task to properly cancel
1549         it and then call the completion handler to ignore the request. Otherwise cancel the pending download if exists.
1550         * NetworkProcess/Downloads/PendingDownload.cpp:
1551         (WebKit::PendingDownload::cancel): Cancel the network load and notify the UI process that the download was canceled.
1552         * NetworkProcess/Downloads/PendingDownload.h:
1553
1554 2016-10-17  Megan Gardner  <megan_gardner@apple.com>
1555
1556         Add test and infrastructure for link popover
1557         https://bugs.webkit.org/show_bug.cgi?id=163406
1558
1559         Reviewed by Simon Fraser.
1560
1561         Add infrastructure to see when a link popover appears, and what URL it has loaded.
1562
1563         * UIProcess/API/Cocoa/WKWebView.mm:
1564         (-[WKWebView didShowForcePressPreview]):
1565         (-[WKWebView didDismissForcePressPreview]):
1566         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1567         * UIProcess/ios/WKContentViewInteraction.mm:
1568         (-[WKContentView _contentsOfUserInterfaceItem:]):
1569         (-[WKContentView _presentedViewControllerForPreviewItemController:]):
1570         (-[WKContentView _previewItemController:didDismissPreview:committing:]):
1571         (-[WKContentView _previewItemControllerDidCancelPreview:]):
1572
1573 2016-10-17  Tim Horton  <timothy_horton@apple.com>
1574
1575         REGRESSION (r169805): WKWebView canGoBack returning YES when nothing is in the back-forward list after restoring session state
1576         https://bugs.webkit.org/show_bug.cgi?id=163573
1577         <rdar://problem/28744549>
1578
1579         Reviewed by Dan Bernstein.
1580
1581         * UIProcess/WebPageProxy.cpp:
1582         (WebKit::WebPageProxy::restoreFromSessionState):
1583         Update PageLoadState's canGoBack/canGoForward bits when restoring from
1584         session state, because in the don't-navigate case, nothing else will make this happen,
1585         and it will remain stale.
1586
1587 2016-10-17  Andy Estes  <aestes@apple.com>
1588
1589         Crash in ASCIICaseInsensitiveHash::hash() when a response has a null MIME type
1590         https://bugs.webkit.org/show_bug.cgi?id=163476
1591         <rdar://problem/26941395>
1592
1593         Reviewed by Tim Horton.
1594
1595         When custom content providers are registered and a response has a null MIME type, WebPage
1596         will pass a null String to HashSet::contains(). This results in a null pointer dereference,
1597         since the String hash functions do not support null Strings and unconditionally dereference
1598         their StringImpls. Fixed by checking that Strings are non-null before calling
1599         HashSet::contains() on m_mimeTypesWithCustomContentProviders.
1600
1601         Rearranging WebPage::shouldUseCustomContentProviderForResponse() to call
1602         canPluginHandleResponse() before checking m_mimeTypesWithCustomContentProviders uncovered a
1603         crash in existing layout tests where WebPage::m_mainFrame can be NULL during WebPage
1604         construction (m_mainFrame isn't yet initialized). Fixed this by passing the main Frame to
1605         canPluginHandleResponseInFrame() instead of relying on m_mainFrame.
1606
1607         New API test: WebKit2.LoadDataWithNilMIMEType.
1608
1609         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1610         (WebKit::WebFrameLoaderClient::transitionToCommittedFromCachedFrame): Passed
1611         m_frame->coreFrame() to shouldUseCustomContentProviderForResponse().
1612         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage): Ditto.
1613         * WebProcess/WebPage/WebPage.cpp:
1614         (WebKit::WebPage::canPluginHandleResponse): Added a mainFrame parameter and used it instead
1615         of m_mainFrame->coreFrame().
1616         (WebKit::WebPage::shouldUseCustomContentProviderForResponse): Passed mainFrame to
1617         canPluginHandleResponse(), and checked if mimeType is null before calling
1618         m_mimeTypesWithCustomContentProviders.contains().
1619         (WebKit::WebPage::canShowMIMEType): Checked if MIMEType is null before calling
1620         m_mimeTypesWithCustomContentProviders.contains().
1621         * WebProcess/WebPage/WebPage.h: Made canPluginHandleResponse() a private declaration.
1622
1623 2016-10-17  Chris Dumez  <cdumez@apple.com>
1624
1625         [WK2][NetworkCache] PendingFrameLoad objects are sometimes leaked
1626         https://bugs.webkit.org/show_bug.cgi?id=163569
1627         <rdar://problem/28810836>
1628
1629         Reviewed by Antti Koivisto.
1630
1631         PendingFrameLoad objects are created to track frame loads and added to
1632         the m_pendingFrameLoads hash map. These objects are supposed to remove
1633         themselves from the hash map once they detect that the page load has
1634         finished by calling PendingFrameLoad::m_loadCompletionHandler().
1635
1636         PendingFrameLoad::m_loadCompletionHandler() is called from
1637         markLoadAsCompleted() when we detect that the page load has finished
1638         via the m_loadHysteresisActivity HysteresisActivity. We call impulse()
1639         on the HysteresisActivity every time a subresource is loaded in the
1640         frame. The issue is that if no subresource is ever loaded, then we
1641         never call impulse() on the HysteresisActivity, which is therefore
1642         never started. If it nevers starts, then it nevers stops and never
1643         calls markLoadAsCompleted(). To address the problem, we now call
1644         impulse() on the HysteresisActivity as soon as we construct it.
1645
1646         * NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp:
1647
1648 2016-10-17  Jeremy Jones  <jeremyj@apple.com>
1649
1650         Enable keyboard in fullscreen.
1651         https://bugs.webkit.org/show_bug.cgi?id=163146
1652
1653         Reviewed by Jer Noble.
1654
1655         Allow keyboard in fullscreen.
1656
1657         * UIProcess/WebFullScreenManagerProxy.cpp:
1658         (WebKit::WebFullScreenManagerProxy::supportsFullScreen):
1659
1660 2016-10-17  Chris Dumez  <cdumez@apple.com>
1661
1662         Move form.reportValidity() behind InteractiveFormValidation setting
1663         https://bugs.webkit.org/show_bug.cgi?id=163550
1664
1665         Reviewed by Darin Adler.
1666
1667         Enable InteractiveFormValidation setting by default and link it to
1668         RuntimeEnabledFeatures so we can use it in the IDL.
1669
1670         * UIProcess/API/C/WKPreferencesRefPrivate.h:
1671         * WebProcess/WebPage/WebPage.cpp:
1672         (WebKit::WebPage::updatePreferences):
1673
1674 2016-10-17  Gavin Barraclough  <barraclough@apple.com>
1675
1676         UIProcess should determine throttle state for WebContent process
1677         https://bugs.webkit.org/show_bug.cgi?id=163556
1678
1679         Reviewed by Anders Carlsson.
1680
1681         This is a step towards merging page/process throttling code for mac & iOS.
1682
1683         Previously WebPage determined whether to start a UserActivity based on page activity,
1684         visibility and the preference to disable. Now WebPage passes the activity state across
1685         to WebPageProxy, which makes the decision & explicitly instructs WebPage to start/stop
1686         the UserActivity.
1687
1688         * UIProcess/WebPageProxy.cpp:
1689         (WebKit::WebPageProxy::WebPageProxy):
1690             - updateActivityToken + updateProccessSuppressionState -> updateThrottleState
1691         (WebKit::WebPageProxy::reattachToWebProcess):
1692             - updateActivityToken -> updateThrottleState
1693         (WebKit::WebPageProxy::dispatchViewStateChange):
1694             - updateActivityToken -> updateThrottleState
1695         (WebKit::WebPageProxy::setPageActivityState):
1696             - Record activity state passed from WebPage, and update.
1697         (WebKit::WebPageProxy::preferencesDidChange):
1698             - updateProccessSuppressionState -> updateThrottleState
1699         (WebKit::WebPageProxy::updateActivityToken): Deleted.
1700         (WebKit::WebPageProxy::updateProccessSuppressionState): Deleted.
1701         (WebKit::WebPageProxy::updateThrottleState):
1702             - Merged existing updateActivityToken/updateProccessSuppressionState to unified updateThrottleState.
1703             - Compute whether page should be suppressed, and send SetPageSuppressed message accordingly.
1704         * UIProcess/WebPageProxy.h:
1705             - Merged existing updateActivityToken/updateProccessSuppressionState to unified updateThrottleState.
1706             - Added setPageActivityState/m_activityState to report/record page activity.
1707             - Added m_pageSuppressed to prevent redundant message sends.
1708         * UIProcess/WebPageProxy.messages.in:
1709             - Expose SetPageActivityState message (called by WebPage).
1710         * WebProcess/WebPage/WebPage.cpp:
1711         (WebKit::WebPage::WebPage):
1712             - removed m_processSuppressionEnabled
1713             - updateUserActivity -> setPageSuppressed - explicitly set the page to not be suppressed, until WebPageProxy tells us to do so.
1714         (WebKit::WebPage::setPageActivityState):
1715             - post activity state on to WebPageProxy.
1716         (WebKit::WebPage::setPageSuppressed):
1717             - Start/stop USerActivity accordingly.
1718         (WebKit::WebPage::setViewState):
1719             - No longer need to monitor ViewState changes on the WebProcess side.
1720         (WebKit::WebPage::updatePreferences):
1721             - No longer need to monitor preference changes on the WebProcess side.
1722         (WebKit::WebPage::updateUserActivity): Deleted.
1723             - Only updated on reciept of setPageSuppressed message.
1724         * WebProcess/WebPage/WebPage.h:
1725             - Removed m_activityState, m_processSuppressionEnabled, updateUserActivity.
1726             - Added setPageSuppressed message.
1727         * WebProcess/WebPage/WebPage.messages.in:
1728             - Added SetPageSuppressed message.
1729
1730 2016-10-17  Michael Catanzaro  <mcatanzaro@igalia.com>
1731
1732         REGRESSION(r206189): logs error statements when API::URLRequest is canceled
1733         https://bugs.webkit.org/show_bug.cgi?id=163393
1734
1735         Reviewed by Antti Koivisto.
1736
1737         Print this case at normal logging level, not as an error.
1738
1739         * WebProcess/Network/WebLoaderStrategy.cpp:
1740         (WebKit::WebLoaderStrategy::loadResource):
1741
1742 2016-10-17  Chris Dumez  <cdumez@apple.com>
1743
1744         [iOS] Hook up WebPlatformTouchPoint's radiusX / radiusY to _UIWebTouchPoint.majorRadiusInScreenCoordinates
1745         https://bugs.webkit.org/show_bug.cgi?id=163547
1746
1747         Reviewed by Darin Adler.
1748
1749         Hook up WebPlatformTouchPoint's radiusX / radiusY to _UIWebTouchPoint.majorRadiusInScreenCoordinates
1750         now that it is available in UIKit.
1751
1752         * Platform/spi/ios/UIKitSPI.h:
1753         * Shared/ios/NativeWebTouchEventIOS.mm:
1754         (WebKit::NativeWebTouchEvent::extractWebTouchPoint):
1755
1756 2016-10-17  Konstantin Tokarev  <annulen@yandex.ru>
1757
1758         Eleminate code duplication between ResourceRequest encoding/decoding implementations
1759         https://bugs.webkit.org/show_bug.cgi?id=163507
1760
1761         Reviewed by Carlos Garcia Campos.
1762
1763         ResourceRequestBase::encodeWithoutPlatformData() and Soup implementation of
1764         ArgumentCoder<ResourceRequest>::encodePlatformData() share most of the code,
1765         ditto for decoding implementations.
1766
1767         * Shared/soup/WebCoreArgumentCodersSoup.cpp:
1768         (IPC::ArgumentCoder<ResourceRequest>::encodePlatformData):
1769         (IPC::ArgumentCoder<ResourceRequest>::decodePlatformData):
1770
1771 2016-10-17  Michael Catanzaro  <mcatanzaro@igalia.com>
1772
1773         Move user agent quirks to cross-platform location
1774         https://bugs.webkit.org/show_bug.cgi?id=163508
1775
1776         Reviewed by Carlos Garcia Campos.
1777
1778         #include <WebCore/UserAgent.h> instead of <WebCore/UserAgentGtk.h>.
1779
1780         * UIProcess/API/gtk/WebKitSettings.cpp:
1781         * UIProcess/efl/WebPageProxyEfl.cpp:
1782         * UIProcess/gtk/WebPageProxyGtk.cpp:
1783         * WebProcess/WebPage/gtk/WebPageGtk.cpp:
1784
1785 2016-10-17  Carlos Garcia Campos  <cgarcia@igalia.com>
1786
1787         [SOUP] Downloads should always sniff contents
1788         https://bugs.webkit.org/show_bug.cgi?id=163538
1789
1790         Reviewed by Michael Catanzaro.
1791
1792         It's quite common that downloads have weird filenames with no extension, so it would be better if the loader
1793         sniff the contents to guess the mime type.
1794
1795         * NetworkProcess/Downloads/soup/DownloadSoup.cpp:
1796         (WebKit::Download::startNetworkLoad): Pass true for shouldContentSniff parameter of ResourceHandle::create().
1797
1798 2016-10-17  Carlos Garcia Campos  <cgarcia@igalia.com>
1799
1800         [GTK] Switch to use API::DownloadClient instead of the C API client
1801         https://bugs.webkit.org/show_bug.cgi?id=163537
1802
1803         Reviewed by Michael Catanzaro.
1804
1805         The code is simpler and we avoid all the toImpl/toAPI.
1806
1807         * UIProcess/API/gtk/WebKitDownloadClient.cpp:
1808         (attachDownloadClientToContext):
1809         (didStart):
1810         (didReceiveResponse):
1811         (didReceiveData):
1812         (decideDestinationWithSuggestedFilename):
1813         (didCreateDestination):
1814         (didFail):
1815         (didCancel):
1816         (didFinish):
1817
1818 2016-10-17  Manuel Rego Casasnovas  <rego@igalia.com>
1819
1820         [css-grid] Disable CSS Grid Layout runtime flag by default
1821         https://bugs.webkit.org/show_bug.cgi?id=163432
1822
1823         Reviewed by Darin Adler.
1824
1825         It was enabled in r201042, but now Safari Technology Preview
1826         has a UI to switch runtime flags so it doesn't need to be enabled
1827         by default anymore.
1828
1829         * Shared/WebPreferencesDefinitions.h: Disable grid layout runtime flag
1830         by default.
1831
1832 2016-10-16  Darin Adler  <darin@apple.com>
1833
1834         Move CSS classes from ExceptionCode to Exception
1835         https://bugs.webkit.org/show_bug.cgi?id=163494
1836
1837         Reviewed by Sam Weinig.
1838
1839         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSRule.cpp:
1840         (webkit_dom_css_rule_set_css_text): Updated for ExceptionOr.
1841         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleDeclaration.cpp:
1842         (webkit_dom_css_style_declaration_remove_property): Ditto.
1843         (webkit_dom_css_style_declaration_set_property): Ditto.
1844         (webkit_dom_css_style_declaration_set_css_text): Ditto.
1845         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSStyleSheet.cpp:
1846         (webkit_dom_css_style_sheet_insert_rule): Ditto.
1847         (webkit_dom_css_style_sheet_delete_rule): Ditto.
1848         (webkit_dom_css_style_sheet_add_rule): Ditto.
1849         (webkit_dom_css_style_sheet_remove_rule): Ditto.
1850         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMCSSValue.cpp:
1851         (webkit_dom_css_value_set_css_text): Ditto.
1852         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMMediaList.cpp:
1853         (webkit_dom_media_list_delete_medium): Ditto.
1854         (webkit_dom_media_list_append_medium): Ditto.
1855         (webkit_dom_media_list_set_media_text): Ditto.
1856
1857 2016-10-16  Carlos Garcia Campos  <cgarcia@igalia.com>
1858
1859         [GTK] Default WebKitWebsiteDataManager is always leaked in WebKitWebContext
1860         https://bugs.webkit.org/show_bug.cgi?id=163443
1861
1862         Reviewed by Michael Catanzaro.
1863
1864         Adopt the reference returned by webkitWebsiteDataManagerCreate().
1865
1866         * UIProcess/API/gtk/WebKitWebContext.cpp:
1867         (webkitWebContextConstructed):
1868
1869 2016-10-16  Carlos Garcia Campos  <cgarcia@igalia.com>
1870
1871         [GTK] WebKitWebPage URI not updated after URI is modified by InjectedBundlePageResourceLoadClient::willSendRequestForFrame
1872         https://bugs.webkit.org/show_bug.cgi?id=163389
1873
1874         Reviewed by Michael Catanzaro.
1875
1876         Update the page URI also when the load is committed.
1877
1878         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
1879         (getDocumentLoaderURL):
1880         (didStartProvisionalLoadForFrame):
1881         (didReceiveServerRedirectForProvisionalLoadForFrame):
1882         (didCommitLoadForFrame):
1883         (webkitWebPageCreate):
1884         (getProvisionalURLForFrame): Deleted.
1885
1886 2016-10-15  Simon Fraser  <simon.fraser@apple.com>
1887
1888         Sort the project file.
1889
1890         * WebKit2.xcodeproj/project.pbxproj:
1891
1892 2016-10-14  Anders Carlsson  <andersca@apple.com>
1893
1894         Fix Mac build.
1895
1896         * UIProcess/ApplePay/mac/WebPaymentCoordinatorProxyMac.mm:
1897         (WebKit::WebPaymentCoordinatorProxy::platformShowPaymentUI):
1898
1899 2016-10-14  Anders Carlsson  <andersca@apple.com>
1900
1901         Pass on networking settings to the PKPaymentRequest
1902         https://bugs.webkit.org/show_bug.cgi?id=163462
1903         rdar://problem/28567629
1904
1905         Reviewed by Dan Bernstein.
1906
1907         * UIProcess/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.h:
1908         * UIProcess/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.mm:
1909         (WebKit::toPKPaymentRequest):
1910         * UIProcess/ApplePay/ios/WebPaymentCoordinatorProxyIOS.mm:
1911         (WebKit::WebPaymentCoordinatorProxy::platformShowPaymentUI):
1912
1913 2016-10-14  Anders Carlsson  <andersca@apple.com>
1914
1915         Clean up BackForwardClient
1916         https://bugs.webkit.org/show_bug.cgi?id=163454
1917
1918         Reviewed by Sam Weinig.
1919
1920         Remove empty iOS only stubs.
1921
1922         * WebKit2.xcodeproj/project.pbxproj:
1923         * WebProcess/WebPage/WebBackForwardListProxy.h:
1924         * WebProcess/WebPage/ios/WebBackForwardListProxyIOS.mm: Removed.
1925
1926 2016-10-14  Brady Eidson  <beidson@apple.com>
1927
1928         Enable Gamepads by default in WK2.
1929         https://bugs.webkit.org/show_bug.cgi?id=163447
1930
1931         Rubberstamped by Sam Weinig.
1932
1933         * Shared/WebPreferencesDefinitions.h:
1934
1935 2016-10-14  Gavin Barraclough  <barraclough@apple.com>
1936
1937         Add API to restrict WebKit processes to background priority
1938         https://bugs.webkit.org/show_bug.cgi?id=163363
1939
1940         Reviewed by Anders Carlson.
1941
1942         Add API on _WKProcessPoolConfiguration to flag a process pool as 'alwaysRunsAtBackgroundPriority'.
1943         WebContent and Networking processes associated with that pool will only run a background priority,
1944         when they otherwise would have run at foreground priority.
1945
1946         * UIProcess/API/APIProcessPoolConfiguration.h:
1947             - Add m_alwaysRunsAtBackgroundPriority flag to pool configuration object.
1948         * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.h:
1949         * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm:
1950         (-[_WKProcessPoolConfiguration alwaysRunsAtBackgroundPriority]):
1951         (-[_WKProcessPoolConfiguration setAlwaysRunsAtBackgroundPriority:]):
1952             - Expose new configuration property through API.
1953         * UIProcess/Network/NetworkProcessProxy.cpp:
1954         (WebKit::NetworkProcessProxy::alwaysRunsAtBackgroundPriority):
1955         * UIProcess/Network/NetworkProcessProxy.h:
1956             - Support ProcessThrottlerClient interface to check if alwaysRunsAtBackgroundPriority is set.
1957         * UIProcess/ProcessThrottler.cpp:
1958         (WebKit::ProcessThrottler::assertionState):
1959             - When determining whether to take a foreground exception check alwaysRunsAtBackgroundPriority.
1960         * UIProcess/ProcessThrottlerClient.h:
1961             - Add interface to access alwaysRunsAtBackgroundPriority state of WebProcess of NetworkProcess.
1962         * UIProcess/WebProcessPool.cpp:
1963         (WebKit::WebProcessPool::WebProcessPool):
1964         * UIProcess/WebProcessPool.h:
1965             - Add m_alwaysRunsAtBackgroundPriority, set by configuration.
1966         * UIProcess/WebProcessProxy.cpp:
1967         (WebKit::WebProcessProxy::alwaysRunsAtBackgroundPriority):
1968         * UIProcess/WebProcessProxy.h:
1969             - Support ProcessThrottlerClient interface to check if alwaysRunsAtBackgroundPriority is set.
1970
1971 2016-10-14  Youenn Fablet  <youenn@apple.com>
1972
1973         Make NetworkCache aware of fetch cache mode
1974         https://bugs.webkit.org/show_bug.cgi?id=163332
1975
1976         Reviewed by Antti Koivisto.
1977
1978         Adding explicit serialization of ResourceRequest cachePolicy since it does no longer map to platform request cache policy.
1979
1980         Added support for:
1981         - Bypassing entirely the network cache in case cache mode is NoStore.
1982         - requiring revalidation in case of cache hit and cache mode is NoCache.
1983         - Not using any entry if cache mode is Reload (but cache can still be updated)
1984
1985         Also made sure that the ResourceRequest::cachePolicy remains the same throughout redirections.
1986
1987         * NetworkProcess/NetworkResourceLoader.cpp:
1988         (WebKit::NetworkResourceLoader::canUseCache):
1989         (WebKit::NetworkResourceLoader::retrieveCacheEntry):
1990         (WebKit::NetworkResourceLoader::continueWillSendRequest):
1991         * NetworkProcess/cache/NetworkCache.cpp:
1992         (WebKit::NetworkCache::cachePolicyAllowsExpired):
1993         (WebKit::NetworkCache::makeRetrieveDecision):
1994         * Shared/mac/WebCoreArgumentCodersMac.mm:
1995         (IPC::ArgumentCoder<ResourceRequest>::encodePlatformData):
1996         (IPC::ArgumentCoder<ResourceRequest>::decodePlatformData):
1997
1998 2016-10-13  Tim Horton  <timothy_horton@apple.com>
1999
2000         Rename the SPI added in r207292 due to post-landing review comments
2001         https://bugs.webkit.org/show_bug.cgi?id=163364
2002         <rdar://problem/28012494>
2003
2004         Reviewed by Simon Fraser.
2005
2006         * UIProcess/API/APIPageConfiguration.h:
2007         (API::PageConfiguration::waitsForPaintAfterViewDidMoveToWindow):
2008         (API::PageConfiguration::setWaitsForPaintAfterViewDidMoveToWindow):
2009         (API::PageConfiguration::shouldWaitForPaintAfterViewDidMoveToWindow): Deleted.
2010         (API::PageConfiguration::setShouldWaitForPaintAfterViewDidMoveToWindow): Deleted.
2011         * UIProcess/API/Cocoa/WKWebView.mm:
2012         (-[WKWebView _initializeWithConfiguration:]):
2013         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
2014         (-[WKWebViewConfiguration init]):
2015         (-[WKWebViewConfiguration copyWithZone:]):
2016         (-[WKWebViewConfiguration _waitsForPaintAfterViewDidMoveToWindow]):
2017         (-[WKWebViewConfiguration _setWaitsForPaintAfterViewDidMoveToWindow:]):
2018         (-[WKWebViewConfiguration _shouldWaitForPaintAfterViewDidMoveToWindow]): Deleted.
2019         (-[WKWebViewConfiguration _setShouldWaitForPaintAfterViewDidMoveToWindow:]): Deleted.
2020         * UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:
2021         * UIProcess/WebPageProxy.cpp:
2022         (WebKit::WebPageProxy::WebPageProxy):
2023         (WebKit::WebPageProxy::dispatchViewStateChange):
2024         * UIProcess/WebPageProxy.h:
2025
2026 2016-10-13  Jonathan Bedard  <jbedard@apple.com>
2027
2028         GTK and EFL on Mac fail to compile WebTextChecker due to missing definition of WKTextCheckerClientBase
2029         https://bugs.webkit.org/show_bug.cgi?id=163346
2030
2031         Reviewed by Daniel Bates.
2032
2033         * UIProcess/API/C/WKTextChecker.cpp: Fixed #ifdefs for GTK and EFL builds on Darwin machines.
2034         * UIProcess/API/C/WKTextChecker.h: Ditto.
2035
2036 2016-10-13  Tim Horton  <timothy_horton@apple.com>
2037
2038         Expose SPI to disable synchronously blocking on painting after parenting a WKWebView
2039         https://bugs.webkit.org/show_bug.cgi?id=163364
2040         <rdar://problem/28012494>
2041
2042         Reviewed by Geoff Garen.
2043
2044         Some clients may not want the default WKWebView behavior where we synchronously
2045         block on the Web process after the first time a WKWebView is re-added to the window,
2046         because they are e.g. parenting re-used WKWebViews while scrolling.
2047
2048         * UIProcess/API/APIPageConfiguration.h:
2049         (API::PageConfiguration::shouldSynchronizeInitialPaintAfterMovingToWindow):
2050         (API::PageConfiguration::setShouldSynchronizeInitialPaintAfterMovingToWindow):
2051         * UIProcess/API/Cocoa/WKWebView.mm:
2052         (-[WKWebView _initializeWithConfiguration:]):
2053         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
2054         (-[WKWebViewConfiguration init]):
2055         (-[WKWebViewConfiguration copyWithZone:]):
2056         (-[WKWebViewConfiguration _shouldSynchronizeInitialPaintAfterMovingToWindow]):
2057         (-[WKWebViewConfiguration _setShouldSynchronizeInitialPaintAfterMovingToWindow:]):
2058         * UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:
2059         * UIProcess/WebPageProxy.h:
2060         * UIProcess/WebPageProxy.cpp:
2061         (WebKit::WebPageProxy::WebPageProxy):
2062         Add and plumb a new WKWebView configuration parameter.
2063
2064         (WebKit::WebPageProxy::dispatchViewStateChange):
2065         If the new configuration parameter is set, don't block the main thread when
2066         a view is reparented.
2067
2068 2016-10-12  Chris Dumez  <cdumez@apple.com>
2069
2070         [Web IDL] Drop support for legacy [ConstructorConditional=*]
2071         https://bugs.webkit.org/show_bug.cgi?id=163368
2072
2073         Reviewed by Ryosuke Niwa.
2074
2075         Drop ENABLE_DOM4_EVENTS_CONSTRUCTOR compiler flag.
2076
2077         * Configurations/FeatureDefines.xcconfig:
2078
2079 2016-10-12  Alex Christensen  <achristensen@webkit.org>
2080
2081         Fix assertion after switching to URLParser
2082         https://bugs.webkit.org/show_bug.cgi?id=163350
2083         rdar://problem/28739938
2084
2085         Reviewed by Brady Eidson.
2086         
2087         Covered by a new API test.
2088
2089         * UIProcess/API/Cocoa/_WKUserStyleSheet.mm:
2090         (-[_WKUserStyleSheet initWithSource:forMainFrameOnly:legacyWhitelist:legacyBlacklist:baseURL:userContentWorld:]):
2091         The { } here is not understood by the compiler to mean WebCore::URL(), but rather the empty constructor for the enum ParsedURLStringTag.
2092         We used to be unsafely trusting that the URL was valid and canonicalized, but with URLParser we are canonicalizing it,
2093         and the assertion (url == m_string) in URL.cpp was failing.
2094
2095 2016-10-12  Anders Carlsson  <andersca@apple.com>
2096
2097         Remove an unused function
2098         https://bugs.webkit.org/show_bug.cgi?id=163341
2099
2100         Reviewed by Dan Bernstein.
2101
2102         * WebProcess/WebPage/WebBackForwardListProxy.cpp:
2103         (WebKit::WebBackForwardListProxy::isActive): Deleted.
2104         * WebProcess/WebPage/WebBackForwardListProxy.h:
2105
2106 2016-10-11  Gyuyoung Kim  <gyuyoung.kim@navercorp.com>
2107
2108         [EFL] Update API tests which are passed or failed
2109         https://bugs.webkit.org/show_bug.cgi?id=163322
2110
2111         Unreviewed, simple on/off API test.
2112
2113         *ewk_favicon_database_clear* has been crashed for a long time, however
2114         *ewk_cookie_manager_permanent_storage* is fine now. So the passing test
2115         is enabled again, and disable the failure tests.
2116
2117         * UIProcess/API/efl/tests/test_ewk2_cookie_manager.cpp:
2118         (TEST_F):
2119         * UIProcess/API/efl/tests/test_ewk2_favicon_database.cpp:
2120         (TEST_F):
2121
2122 2016-10-11  Daniel Bates  <dabates@apple.com>
2123
2124         Attempt to fix the Apple Internal Mac build following r207159
2125         (https://bugs.webkit.org/show_bug.cgi?id=163244)
2126
2127         * UIProcess/API/Cocoa/WKWebView.mm:
2128         (shouldRequireUserGestureToLoadVideo):
2129
2130 2016-10-11  Anders Carlsson  <andersca@apple.com>
2131
2132         Clean up WebPageGroup somewhat
2133         https://bugs.webkit.org/show_bug.cgi?id=163299
2134
2135         Reviewed by Tim Horton.
2136
2137         * Shared/API/c/WKDeprecatedFunctions.cpp:
2138         (WKPageGroupCopyIdentifier):
2139         Move this here from WKPageGroup.
2140
2141         (WKPageGroupAddUserContentFilter):
2142         (WKPageGroupRemoveUserContentFilter):
2143         (WKPageGroupRemoveAllUserContentFilters):
2144         Just call directly into the user content controller.
2145
2146         * UIProcess/API/C/WKPageGroup.cpp:
2147         (WKPageGroupAddUserStyleSheet):
2148         (WKPageGroupRemoveAllUserStyleSheets):
2149         (WKPageGroupAddUserScript):
2150         (WKPageGroupRemoveAllUserScripts):
2151         Just call directly into the user content controller.
2152
2153         * UIProcess/API/C/WKPageGroup.h:
2154         * UIProcess/WebPageGroup.cpp:
2155         (WebKit::WebPageGroup::addUserStyleSheet): Deleted.
2156         (WebKit::WebPageGroup::addUserScript): Deleted.
2157         (WebKit::WebPageGroup::removeAllUserStyleSheets): Deleted.
2158         (WebKit::WebPageGroup::removeAllUserScripts): Deleted.
2159         (WebKit::WebPageGroup::removeAllUserContent): Deleted.
2160         (WebKit::WebPageGroup::addUserContentExtension): Deleted.
2161         (WebKit::WebPageGroup::removeUserContentExtension): Deleted.
2162         (WebKit::WebPageGroup::removeAllUserContentExtensions): Deleted.
2163         Get rid of these, all their callers just call into the user content controller now.
2164
2165         * UIProcess/WebPageGroup.h:
2166         (WebKit::WebPageGroup::identifier): Deleted.
2167         (WebKit::WebPageGroup::sendToAllProcessesInGroup): Deleted.
2168         Remove unused code.
2169
2170 2016-10-11  Daniel Bates  <dabates@apple.com>
2171
2172         [iOS] REGRESSION (r197953): User gesture required to load video in iOS 9-built apps
2173         https://bugs.webkit.org/show_bug.cgi?id=163244
2174         <rdar://problem/27250015>
2175
2176         Reviewed by Jer Noble.
2177
2178         Enable or disable the Setting::requiresUserGestureToLoadVideo() in WebKit depending on the
2179         version of iOS SDK that the app was linked against. We require a user gesture to begin
2180         loading a video as of iOS 10.
2181
2182         * Shared/WebPreferencesDefinitions.h:
2183         * UIProcess/API/Cocoa/WKWebView.mm:
2184         (shouldRequireUserGestureToLoadVideo): Added.
2185         (-[WKWebView _initializeWithConfiguration:]): Set the requiresUserGestureToLoadVideo preference.
2186         * WebProcess/WebPage/WebPage.cpp:
2187         (WebKit::WebPage::updatePreferences): Modified to pass the WebKit requiresUserGestureToLoadVideo
2188         preference to WebCore.
2189
2190 2016-10-11  Alex Christensen  <achristensen@webkit.org>
2191
2192         Remove dead networking code
2193         https://bugs.webkit.org/show_bug.cgi?id=163263
2194
2195         Reviewed by Daniel Bates.
2196
2197         * NetworkProcess/Downloads/Download.h:
2198         * NetworkProcess/Downloads/ios/DownloadIOS.mm: Removed.
2199         * NetworkProcess/Downloads/mac/DownloadMac.mm:
2200         * NetworkProcess/NetworkLoad.h:
2201         * NetworkProcess/mac/NetworkLoadMac.mm:
2202         (WebKit::NetworkLoad::willCacheResponseAsync): Deleted.
2203         * Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm:
2204         (WebKit::AuthenticationManager::receivedCredential):
2205         (WebKit::AuthenticationManager::receivedRequestToContinueWithoutCredential):
2206         (WebKit::AuthenticationManager::receivedCancellation):
2207         (WebKit::AuthenticationManager::receivedRequestToPerformDefaultHandling):
2208         (WebKit::AuthenticationManager::receivedChallengeRejection):
2209         * Shared/WebProcessCreationParameters.cpp:
2210         (WebKit::WebProcessCreationParameters::encode):
2211         (WebKit::WebProcessCreationParameters::decode):
2212         * Shared/WebProcessCreationParameters.h:
2213         * Shared/mac/WebCoreArgumentCodersMac.mm:
2214         (IPC::ArgumentCoder<ResourceRequest>::encodePlatformData):
2215         (IPC::ArgumentCoder<ResourceRequest>::decodePlatformData):
2216         * WebKit2.xcodeproj/project.pbxproj:
2217
2218 2016-10-11  Anders Carlsson  <andersca@apple.com>
2219
2220         Move no longer used functions to WKDeprecatedFunctions.cpp
2221         https://bugs.webkit.org/show_bug.cgi?id=163290
2222
2223         Reviewed by Dan Bernstein.
2224
2225         * Shared/API/c/WKDeprecatedFunctions.cpp:
2226         (WKPageGroupAddUserContentFilter):
2227         (WKPageGroupRemoveUserContentFilter):
2228         (WKPageGroupRemoveAllUserContentFilters):
2229         (WKContextSetProcessModel): Deleted.
2230         * UIProcess/API/C/WKPageGroup.cpp:
2231         (WKPageGroupRemoveAllUserScripts):
2232         (WKPageGroupAddUserContentFilter): Deleted.
2233         (WKPageGroupRemoveUserContentFilter): Deleted.
2234         (WKPageGroupRemoveAllUserContentFilters): Deleted.
2235         * UIProcess/API/C/WKPageGroup.h:
2236
2237 2016-10-11  Konstantin Tokarev  <annulen@yandex.ru>
2238
2239         Use modern for loops for iterating supplement maps
2240         https://bugs.webkit.org/show_bug.cgi?id=163274
2241
2242         Reviewed by Alex Christensen.
2243
2244         * NetworkProcess/NetworkProcess.cpp:
2245         (WebKit::NetworkProcess::initializeNetworkProcess):
2246         (WebKit::NetworkProcess::initializeConnection):
2247         * UIProcess/WebProcessPool.cpp:
2248         (WebKit::WebProcessPool::~WebProcessPool):
2249         (WebKit::WebProcessPool::networkProcessCrashed):
2250         (WebKit::WebProcessPool::databaseProcessCrashed): Iterate by values()
2251         like in other places.
2252
2253 2016-10-11  Wenson Hsieh  <wenson_hsieh@apple.com>
2254
2255         The "Input Events" experimental feature runtime flag should not be on by default
2256         https://bugs.webkit.org/show_bug.cgi?id=163278
2257
2258         Reviewed by Zalan Bujtas.
2259
2260         This was intended to be off by default.
2261
2262         * Shared/WebPreferencesDefinitions.h:
2263
2264 2016-10-10  Zan Dobersek  <zdobersek@igalia.com>
2265
2266         Add ENABLE_ENCRYPTED_MEDIA configuration option
2267         https://bugs.webkit.org/show_bug.cgi?id=163219
2268
2269         Reviewed by Darin Adler.
2270
2271         * Configurations/FeatureDefines.xcconfig:
2272         Add the ENABLE_ENCRYPTED_MEDIA configuration option. It will be used
2273         to enable or disable the new EME implementation at build-time.
2274
2275 2016-10-10  Carlos Garcia Campos  <cgarcia@igalia.com>
2276
2277         NetworkSession: NetworkDataTask is leaked if download finishes in didReceiveResponse completion handler
2278         https://bugs.webkit.org/show_bug.cgi?id=163204
2279
2280         Reviewed by Alex Christensen.
2281
2282         After the completion handler a reference of the NetworkDataTask is saved in m_downloadsAfterDestinationDecided.
2283         If the download failed or was canceled DownloadManager::dataTaskBecameDownloadTask is never called and the data
2284         task is kept in the download manager forever. This patch exposes NSURLSessionTask state property in
2285         NetworkDataTask, so that the download manager can check the task state after the completion handler and return
2286         early if the download finished or was cancelled.
2287
2288         * NetworkProcess/Downloads/DownloadManager.cpp:
2289         (WebKit::DownloadManager::continueDecidePendingDownloadDestination):
2290         * NetworkProcess/NetworkDataTask.h:
2291         * NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
2292         (WebKit::NetworkDataTask::state):
2293
2294 2016-10-10  Konstantin Tokarev  <annulen@yandex.ru>
2295
2296         Added final specifier to WebInspectorServer and to its overridden methods
2297         https://bugs.webkit.org/show_bug.cgi?id=163228
2298
2299         Reviewed by Darin Adler.
2300
2301         * UIProcess/InspectorServer/WebInspectorServer.h:
2302
2303 2016-10-10  Carlos Garcia Campos  <cgarcia@igalia.com>
2304
2305         [GTK] 2.14.0 Compile Errors: GTK 3.22.1
2306         https://bugs.webkit.org/show_bug.cgi?id=163190
2307
2308         Reviewed by Alex Christensen.
2309
2310         * UIProcess/gtk/AcceleratedBackingStoreX11.cpp: Include gtk.h since we are using gtk_widget_queue_draw().
2311
2312 2016-10-10  Gyuyoung Kim  <gyuyoung.kim@navercorp.com>
2313
2314         [EFL] ewk_context_preferred_languages has been failed since r206949
2315         https://bugs.webkit.org/show_bug.cgi?id=163211
2316
2317         Reviewed by Chris Dumez.
2318
2319         r206949 changed to return value of navigator.language from en-us to en-US
2320         in order to match other browsers and w3c spec. So ewk_context_preferred_languages
2321         needs to change the expected result as well.
2322
2323         * UIProcess/API/efl/tests/test_ewk2_context.cpp:
2324         (TEST_F):
2325
2326 2016-10-10  Carlos Garcia Campos  <cgarcia@igalia.com>
2327
2328         NetworkSession: downloads started by startDownload() can fail before starting from the API point of view
2329         https://bugs.webkit.org/show_bug.cgi?id=163107
2330
2331         Reviewed by Alex Christensen.
2332
2333         In the network process we use a PendingDownload in this case, but in the UI process we always have a single
2334         download proxy. If an error happens before the pending download is converted inot a real download, the DidFail
2335         messages is received in the download proxy before the DidStart one. This is problematic at least for the GTK+
2336         API, because it's common to connect to the started signal and connect to all other signals from there, but in
2337         this case the started signal is never emitted, and then the failed one is not handled. This is not a problem for
2338         downloads started by convertTaskToDownload, because in that case those loads are not considered a download by
2339         the UI process when those early errors happen, and then the web page handles them.
2340
2341         * NetworkProcess/Downloads/PendingDownload.cpp:
2342         (WebKit::PendingDownload::PendingDownload): Send DidStart message right after the network load starts like the
2343         non network session code does.
2344         * NetworkProcess/NetworkLoad.cpp:
2345         (WebKit::NetworkLoad::convertTaskToDownload): Send DidStart message now that the normal load has been converted
2346         into a download.
2347         * NetworkProcess/NetworkProcess.cpp:
2348         (WebKit::NetworkProcess::findPendingDownloadLocation): Do not send DidStart message here.
2349
2350 2016-10-10  Carlos Garcia Campos  <cgarcia@igalia.com>
2351
2352         Network Session: PendingDownload is always nullptr in DownloadManager::dataTaskBecameDownloadTask
2353         https://bugs.webkit.org/show_bug.cgi?id=163006
2354
2355         Reviewed by Alex Christensen.
2356
2357         In DownloadManager::dataTaskBecameDownloadTask() we are supposed to have either a pending download, or a network
2358         data task depending on whether the download was started by startDownload() or convertTaskToDownload. However, in
2359         both cases we do have a data task and never a pending download. In the case of startDownload() the pending
2360         download is removed from m_pendingDownloads in willDecidePendingDownloadDestination(). The task is always
2361         added to m_downloadsWaitingForDestination in willDecidePendingDownloadDestination() and to
2362         m_downloadsAfterDestinationDecided in continueDecidePendingDownloadDestination() in both cases.
2363
2364         * NetworkProcess/Downloads/DownloadManager.cpp:
2365         (WebKit::DownloadManager::dataTaskBecameDownloadTask): Add an ASSERT to ensure we don't have a pending download
2366         at this point and that the download is not already in the map. Remove the download from the
2367         m_downloadsAfterDestinationDecided map, but don't check its result because it might not bein that map if
2368         dataTaskBecameDownloadTask is called synchronously from the didReceiveResponse completion handler.
2369         (WebKit::DownloadManager::willDecidePendingDownloadDestination): Do not take the pending download here, wait
2370         until didReceiveResponse completion handler is called.
2371         (WebKit::DownloadManager::continueDecidePendingDownloadDestination): Take the pending download here ensuring
2372         it's alive while the didReceiveResponse completion handler is called. Also remove invalid early return when
2373         either networkDataTask or completionHandler are nullptr because we are using both unconditionally, we should
2374         return early if both are nullptr to avoid crashes. However, we are checking that the download is in the
2375         m_downloadsWaitingForDestination and in that case we should always have both, so better add asserts there. If
2376         the download is already in the map after the completion handler it means that dataTaskBecameDownloadTask() has
2377         alrady been called, so we can just return in that case.
2378         * NetworkProcess/Downloads/DownloadManager.h:
2379         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
2380         (-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]): Protect the NetworkDataTask that can
2381         be deleted by dataTaskBecameDownloadTask().
2382
2383 2016-10-10  Tim Horton  <timothy_horton@apple.com>
2384
2385         Share more code between iOS and macOS ViewGestureController
2386         https://bugs.webkit.org/show_bug.cgi?id=163158
2387
2388         Reviewed by Simon Fraser.
2389
2390         Share canSwipeInDirection() and the (unused on Mac) alternate back-forward list mechanism.
2391         Make ViewGestureController operate in terms of WebPageProxy, not WKWebView,
2392         because it shouldn't know anything about WKWebView.
2393         Refactor scrollEventCanBecomeSwipe a bit to be less repetitive.
2394
2395         * UIProcess/API/Cocoa/WKWebView.mm:
2396         (-[WKWebView setAllowsBackForwardNavigationGestures:]):
2397         * UIProcess/Cocoa/ViewGestureController.cpp:
2398         (WebKit::ViewGestureController::ViewGestureController):
2399         (WebKit::ViewGestureController::setAlternateBackForwardListSourcePage):
2400         (WebKit::ViewGestureController::canSwipeInDirection):
2401         (WebKit::ViewGestureController::gestureControllerForPage): Deleted.
2402         * UIProcess/Cocoa/ViewGestureController.h:
2403         * UIProcess/WebPageProxy.cpp:
2404         (WebKit::WebPageProxy::WebPageProxy):
2405         * UIProcess/WebPageProxy.h:
2406         (WebKit::WebPageProxy::createWeakPtr):
2407         * UIProcess/ios/ViewGestureControllerIOS.mm:
2408         (WebKit::ViewGestureController::beginSwipeGesture):
2409         (WebKit::ViewGestureController::setAlternateBackForwardListSourceView): Deleted.
2410         (WebKit::ViewGestureController::canSwipeInDirection): Deleted.
2411         * UIProcess/mac/ViewGestureControllerMac.mm:
2412         (WebKit::ViewGestureController::PendingSwipeTracker::PendingSwipeTracker):
2413         (WebKit::ViewGestureController::PendingSwipeTracker::scrollEventCanBecomeSwipe):
2414         (WebKit::ViewGestureController::PendingSwipeTracker::tryToStartSwipe):
2415
2416 2016-10-10  Tomas Popela  <tpopela@redhat.com>
2417
2418         [GTK] UIProcess crashes when using Japanese IM
2419         https://bugs.webkit.org/show_bug.cgi?id=163011
2420
2421         We have to reference the current GdkEventKey before we try process it
2422         as later when the lambda body is reached the event could be already
2423         freed.
2424
2425         Reviewed by Carlos Garcia Campos.
2426
2427         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
2428         (webkitWebViewBaseKeyPressEvent):
2429         (webkitWebViewBaseKeyReleaseEvent):
2430         * UIProcess/gtk/InputMethodFilter.h:
2431         Use non-copyable Function so we can use WTFMove to pass the event to
2432         lambda.
2433
2434 2016-10-09  Wenson Hsieh  <wenson_hsieh@apple.com>
2435
2436         Support InputEvent.inputType for the new InputEvent spec
2437         https://bugs.webkit.org/show_bug.cgi?id=163025
2438         <rdar://problem/28658092>
2439
2440         Reviewed by Darin Adler.
2441
2442         Accounts for some changes to the EditAction enum in nameForEditAction. Some former edit
2443         actions, such as EditActionTyping, have been split out into its more specific subtypes,
2444         so we preserve shipping behavior by treating all of the new subtypes the same way as the
2445         original type.
2446
2447         * UIProcess/WebEditCommandProxy.cpp:
2448         (WebKit::WebEditCommandProxy::nameForEditAction):
2449
2450 2016-10-08  Emanuele Aina  <emanuele.aina@collabora.com>
2451
2452         [GTK] Drop redundant wl_display_flush_clients() call
2453         https://bugs.webkit.org/show_bug.cgi?id=161904
2454
2455         Reviewed by Michael Catanzaro.
2456
2457         The Wayland GSource::prepare() function already calls
2458         wl_display_flush_clients() at every mainloop iteration, so there's no
2459         need to further call it on Surface::commit().
2460
2461         * UIProcess/gtk/WaylandCompositor.cpp:
2462         (WebKit::WaylandCompositor::Surface::commit):
2463         * UIProcess/gtk/WaylandCompositor.h:
2464
2465 2016-10-06  Darin Adler  <darin@apple.com>
2466
2467         Next step on moving to modern way to return DOM exceptions
2468         https://bugs.webkit.org/show_bug.cgi?id=163016
2469
2470         Reviewed by Ryosuke Niwa.
2471
2472         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMImplementation.cpp:
2473         (webkit_dom_dom_implementation_create_document_type): Updated for name change
2474         from takeReturnValue to releaseReturnValue.
2475         (webkit_dom_dom_implementation_create_document): Ditto.
2476         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMDOMSelection.cpp:
2477         (webkit_dom_dom_selection_collapse_to_end): Use ExceptionOr instead of ExceptionCode.
2478         (webkit_dom_dom_selection_collapse_to_start): Ditto.
2479         (webkit_dom_dom_selection_extend): Ditto.
2480         (webkit_dom_dom_selection_get_range_at): Ditto.
2481
2482 2016-10-08  Commit Queue  <commit-queue@webkit.org>
2483
2484         Unreviewed, rolling out r206950.
2485         https://bugs.webkit.org/show_bug.cgi?id=163169
2486
2487         broke an API test (Requested by thorton on #webkit).
2488
2489         Reverted changeset:
2490
2491         "Share more code between iOS and macOS ViewGestureController"
2492         https://bugs.webkit.org/show_bug.cgi?id=163158
2493         http://trac.webkit.org/changeset/206950
2494
2495 2016-10-08  Tim Horton  <timothy_horton@apple.com>
2496
2497         Share more code between iOS and macOS ViewGestureController
2498         https://bugs.webkit.org/show_bug.cgi?id=163158
2499
2500         Reviewed by Simon Fraser.
2501
2502         Share canSwipeInDirection() and the (unused on Mac) alternate back-forward list mechanism.
2503         Make ViewGestureController operate in terms of WebPageProxy, not WKWebView,
2504         because it shouldn't know anything about WKWebView.
2505         Refactor scrollEventCanBecomeSwipe a bit to be less repetitive.
2506
2507         * UIProcess/API/Cocoa/WKWebView.mm:
2508         (-[WKWebView setAllowsBackForwardNavigationGestures:]):
2509         * UIProcess/Cocoa/ViewGestureController.cpp:
2510         (WebKit::ViewGestureController::ViewGestureController):
2511         (WebKit::ViewGestureController::setAlternateBackForwardListSourcePage):
2512         (WebKit::ViewGestureController::canSwipeInDirection):
2513         (WebKit::ViewGestureController::gestureControllerForPage): Deleted.
2514         * UIProcess/Cocoa/ViewGestureController.h:
2515         * UIProcess/WebPageProxy.cpp:
2516         (WebKit::WebPageProxy::WebPageProxy):
2517         * UIProcess/WebPageProxy.h:
2518         (WebKit::WebPageProxy::createWeakPtr):
2519         * UIProcess/ios/ViewGestureControllerIOS.mm:
2520         (WebKit::ViewGestureController::beginSwipeGesture):
2521         (WebKit::ViewGestureController::setAlternateBackForwardListSourceView): Deleted.
2522         (WebKit::ViewGestureController::canSwipeInDirection): Deleted.
2523         * UIProcess/mac/ViewGestureControllerMac.mm:
2524         (WebKit::ViewGestureController::PendingSwipeTracker::PendingSwipeTracker):
2525         (WebKit::ViewGestureController::PendingSwipeTracker::scrollEventCanBecomeSwipe):
2526         (WebKit::ViewGestureController::PendingSwipeTracker::tryToStartSwipe):
2527
2528 2016-10-07  Anders Carlsson  <andersca@apple.com>
2529
2530         Get rid of API::Session and WKSessionRef
2531         https://bugs.webkit.org/show_bug.cgi?id=163140
2532
2533         Reviewed by Tim Horton.
2534
2535         This API is no longer used.
2536
2537         * CMakeLists.txt:
2538         * Shared/API/APIObject.h:
2539         * Shared/API/c/WKSharedAPICast.h:
2540         * UIProcess/API/APISession.cpp: Removed.
2541         (API::generateID): Deleted.
2542         (API::Session::defaultSession): Deleted.
2543         (API::Session::Session): Deleted.
2544         (API::Session::createEphemeral): Deleted.
2545         (API::Session::isEphemeral): Deleted.
2546         (API::Session::getID): Deleted.
2547         (API::Session::~Session): Deleted.
2548         * UIProcess/API/APISession.h: Removed.
2549         * UIProcess/API/C/WKPage.h:
2550         * UIProcess/API/C/WKSessionRef.cpp: Removed.
2551         (WKSessionCreate): Deleted.
2552         (WKSessionGetTypeID): Deleted.
2553         (WKSessionIsEphemeral): Deleted.
2554         * UIProcess/API/C/WKSessionRef.h: Removed.
2555         * UIProcess/WebPageProxy.h:
2556         * UIProcess/WebProcessProxy.h:
2557         * WebKit2.xcodeproj/project.pbxproj:
2558
2559 2016-10-07  Tim Horton  <timothy_horton@apple.com>
2560
2561         Move ViewGestureController files to more accurate locations
2562         https://bugs.webkit.org/show_bug.cgi?id=163141
2563
2564         Reviewed by Anders Carlsson.
2565
2566         * PlatformMac.cmake:
2567         * UIProcess/Cocoa/ViewGestureController.cpp: Renamed from UIProcess/ViewGestureController.cpp.
2568         * UIProcess/Cocoa/ViewGestureController.h: Renamed from UIProcess/mac/ViewGestureController.h.
2569         * UIProcess/Cocoa/ViewGestureController.messages.in: Renamed from UIProcess/mac/ViewGestureController.messages.in.
2570         * WebKit2.xcodeproj/project.pbxproj:
2571
2572 2016-10-07  Tim Horton  <timothy_horton@apple.com>
2573
2574         Adopt BlockPtr in ViewGestureController
2575         https://bugs.webkit.org/show_bug.cgi?id=163132
2576
2577         Reviewed by Anders Carlsson.
2578
2579         * UIProcess/Cocoa/WebViewImpl.h:
2580         * UIProcess/Cocoa/WebViewImpl.mm:
2581         (WebKit::WebViewImpl::setDidMoveSwipeSnapshotCallback):
2582         * UIProcess/ViewGestureController.cpp:
2583         (WebKit::ViewGestureController::SnapshotRemovalTracker::stopWaitingForEvent):
2584         * UIProcess/mac/ViewGestureController.h:
2585         (WebKit::ViewGestureController::setDidMoveSwipeSnapshotCallback):
2586         (WebKit::ViewGestureController::m_didMoveSwipeSnapshotCallback): Deleted.
2587         * UIProcess/mac/ViewGestureControllerMac.mm:
2588         (WebKit::ViewGestureController::platformTeardown):
2589         (WebKit::ViewGestureController::setDidMoveSwipeSnapshotCallback): Deleted.
2590
2591 2016-10-07  Anders Carlsson  <andersca@apple.com>
2592
2593         Get rid of WKPageSetSession
2594         https://bugs.webkit.org/show_bug.cgi?id=163129
2595
2596         Reviewed by Tim Horton.
2597
2598         This function is no longer used.
2599
2600         * UIProcess/API/C/WKPage.cpp:
2601         (WKPageSetSession): Deleted.
2602         * UIProcess/API/C/WKPage.h:
2603         * UIProcess/WebPageProxy.cpp:
2604         (WebKit::WebPageProxy::setSessionID): Deleted.
2605         * UIProcess/WebPageProxy.h:
2606         (WebKit::WebPageProxy::sessionID):
2607         * WebProcess/WebPage/WebPage.messages.in:
2608
2609 2016-10-07  Commit Queue  <commit-queue@webkit.org>
2610
2611         Unreviewed, rolling out r206909.
2612         https://bugs.webkit.org/show_bug.cgi?id=163116
2613
2614         Caused most of  GTK layout tests to crash (Requested by KaL on
2615         #webkit).
2616
2617         Reverted changeset:
2618
2619         "[GTK] UIProcess crashes when using Japanese IM"
2620         https://bugs.webkit.org/show_bug.cgi?id=163011
2621         http://trac.webkit.org/changeset/206909
2622
2623 2016-10-07  Carlos Garcia Campos  <cgarcia@igalia.com>
2624
2625         Network Session: Allow NetworkDataTask decide what to do when override is allowed for a download
2626         https://bugs.webkit.org/show_bug.cgi?id=163010
2627
2628         Reviewed by Alex Christensen.
2629
2630         Current code always deletes the file before starting a download when allow override is True. In soup backend we
2631         use glib API that takes care of it and tries to ensure that the original file is not deleted if the new file
2632         creation fails for whatever reason.
2633
2634         * NetworkProcess/Downloads/DownloadManager.cpp:
2635         (WebKit::DownloadManager::continueDecidePendingDownloadDestination): Pass allowOverride to setPendingDownloadLocation().
2636         * NetworkProcess/NetworkDataTask.h:
2637         * NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
2638         (WebKit::NetworkDataTask::setPendingDownloadLocation): Delete the destination file if exists and allowOverride
2639         is True.
2640
2641 2016-10-07  Tomas Popela  <tpopela@redhat.com>
2642
2643         [GTK] UIProcess crashes when using Japanese IM
2644         https://bugs.webkit.org/show_bug.cgi?id=163011
2645
2646         We have to reference the current GdkEventKey before we try process it
2647         as later when the lambda body is reached the event could be already
2648         freed.
2649
2650         Reviewed by Carlos Garcia Campos.
2651
2652         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
2653         (webkitWebViewBaseKeyPressEvent):
2654         (webkitWebViewBaseKeyReleaseEvent):
2655         * UIProcess/gtk/InputMethodFilter.h:
2656         Use non-copyable Function so we can use WTFMove to pass the event to
2657         lambda.
2658
2659 2016-10-06  Michael Catanzaro  <mcatanzaro@igalia.com>
2660
2661         [GTK] Expose WebKitDOMHTMLInputElement APIs for form autofill
2662         https://bugs.webkit.org/show_bug.cgi?id=163082
2663
2664         Reviewed by Darin Adler.
2665
2666         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLInputElement.cpp:
2667         (webkit_dom_html_input_element_get_auto_filled): Added.
2668         (webkit_dom_html_input_element_set_auto_filled): Added.
2669         (webkit_dom_html_input_element_set_editing_value): Added.
2670         * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLInputElement.h:
2671         * WebProcess/InjectedBundle/API/gtk/DOM/docs/webkitdomgtk-4.0-sections.txt:
2672
2673 2016-10-06  John Wilander  <wilander@apple.com>
2674
2675         Update Resource Load Statistics
2676         https://bugs.webkit.org/show_bug.cgi?id=162811
2677
2678         Reviewed by Alex Christensen.
2679
2680         * UIProcess/WebResourceLoadStatisticsStore.cpp:
2681         (WebKit::WebResourceLoadStatisticsStore::hasPrevalentResourceCharacteristics):
2682             Switched to vector-based classification.
2683         (WebKit::WebResourceLoadStatisticsStore::classifyResource):
2684             Simplified logic and moved the split between has and has
2685             no user interaction into ResourceLoadStatisticsStore.
2686         (WebKit::WebResourceLoadStatisticsStore::clearDataRecords):
2687             Added.
2688         (WebKit::WebResourceLoadStatisticsStore::resourceLoadStatisticsUpdated):
2689             Updated to make use of the new functions.
2690         (WebKit::WebResourceLoadStatisticsStore::persistentStoragePath):
2691             Removed stray whitespace.
2692         (WebKit::WebResourceLoadStatisticsStore::writeEncoderToDisk):
2693             Removed stray whitespace.
2694         (WebKit::WebResourceLoadStatisticsStore::createDecoderFromDisk):
2695             Removed stray whitespace.
2696         (WebKit::hasPrevalentResourceCharacteristics): Deleted.
2697         (WebKit::classifyPrevalentResources): Deleted.
2698         * UIProcess/WebResourceLoadStatisticsStore.h:
2699             Added member variables for clearing of data records.
2700
2701 2016-10-06  Youenn Fablet  <youenn@apple.com>
2702
2703         [WK2] 304 revalidation on the network process does not update the validated response
2704         https://bugs.webkit.org/show_bug.cgi?id=162973
2705
2706         Reviewed by Darin Adler.
2707
2708         * NetworkProcess/NetworkResourceLoader.cpp: Updating cache entry with the revalidated one.
2709
2710 2016-10-05  Wenson Hsieh  <wenson_hsieh@apple.com>
2711
2712         Introduce InputEvent bindings in preparation for the input events spec
2713         https://bugs.webkit.org/show_bug.cgi?id=162954
2714
2715         Reviewed by Ryosuke Niwa.
2716
2717         Adds a new runtime switch for enabling InputEvents.
2718
2719         * Shared/WebPreferencesDefinitions.h:
2720         * WebProcess/WebPage/WebPage.cpp:
2721         (WebKit::WebPage::updatePreferences):
2722
2723 2016-10-05  Myles C. Maxfield  <mmaxfield@apple.com>
2724
2725         Put variation fonts work behind a compile-time flag
2726         https://bugs.webkit.org/show_bug.cgi?id=162949
2727
2728         Reviewed by Simon Fraser.
2729
2730         * Configurations/FeatureDefines.xcconfig:
2731
2732 2016-10-05  Tim Horton  <timothy_horton@apple.com>
2733
2734         Fix the build.
2735
2736         * UIProcess/Cocoa/WebViewImpl.mm:
2737
2738 2016-10-05  Tim Horton  <timothy_horton@apple.com>
2739
2740         Avoid automatically re-taking snapshots for back-forward items that were never loaded into the view
2741         https://bugs.webkit.org/show_bug.cgi?id=162955
2742         <rdar://problem/27659173>
2743
2744         Reviewed by Simon Fraser.
2745
2746         Make it possible for clients to control the snapshot for back-forward
2747         items that are restored from session state without navigating to them,
2748         by ensuring that we won't stomp on the snapshot that they explicitly take,
2749         until a load occurs.
2750
2751         * UIProcess/WebBackForwardList.cpp:
2752         (WebKit::WebBackForwardList::addItem):
2753         (WebKit::WebBackForwardList::goToItem):
2754         * UIProcess/ios/ViewGestureControllerIOS.mm:
2755         (WebKit::ViewGestureController::beginSwipeGesture):
2756         * UIProcess/mac/ViewGestureControllerMac.mm:
2757         (WebKit::ViewGestureController::trackSwipeGesture):
2758         Disambiguate explicit API-driven snapshot recording from automatic,
2759         navigation-driven snapshot recording.
2760
2761         * UIProcess/Cocoa/WebViewImpl.mm:
2762         (WebKit::WebViewImpl::saveBackForwardSnapshotForCurrentItem):
2763         Get rid of the version of recordNavigationSnapshot() that doesn't take a
2764         back-forward list item, and grab the current item at the one remaining caller.
2765         
2766         * UIProcess/WebPageProxy.cpp:
2767         (WebKit::WebPageProxy::recordAutomaticNavigationSnapshot):
2768         (WebKit::WebPageProxy::recordNavigationSnapshot):
2769         (WebKit::WebPageProxy::restoreFromSessionState):
2770         (WebKit::WebPageProxy::didCommitLoadForFrame):
2771         * UIProcess/WebPageProxy.h:
2772         Rename m_suppressNavigationSnapshotting to m_suppressAutomaticNavigationSnapshotting,
2773         and make it be only about automatic (navigation-driven) snapshots; it won't have
2774         any impact on explicit snapshots forced by clients.
2775         
2776         Set m_suppressAutomaticNavigationSnapshotting unconditionally when restoring
2777         from session state, so that we won't start automatically snapshotting until
2778         something has loaded in the view.
2779
2780 2016-10-05  Tim Horton  <timothy_horton@apple.com>
2781
2782         Make it possible to test ViewSnapshotStore behaviors
2783         https://bugs.webkit.org/show_bug.cgi?id=162983
2784
2785         Reviewed by Simon Fraser.
2786
2787         Add two pieces of SPI to make it easier to test ViewSnapshotStore:
2788
2789         - [WKWebView _disableBackForwardSnapshotVolatilityForTesting]
2790             This makes it so that we don't make snapshots volatile after we
2791             take them, so that they won't get purged while the test is running
2792             and cause the test to be flaky.
2793
2794         - [WKBackForwardListItem _copySnapshotForTesting]
2795             This returns a CGImage with the content of the given back-forward
2796             item's current snapshot, if there is one.
2797
2798         * UIProcess/API/Cocoa/WKBackForwardListItem.mm:
2799         (-[WKBackForwardListItem _copySnapshotForTesting]):
2800         * UIProcess/API/Cocoa/WKBackForwardListItemInternal.h:
2801         * UIProcess/API/Cocoa/WKBackForwardListItemPrivate.h: Added.
2802         Add WKBackForwardListItem SPI to retrieve the snapshot for a given back-forward list item.
2803
2804         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2805         * UIProcess/API/Cocoa/WKWebView.mm:
2806         (-[WKWebView _disableBackForwardSnapshotVolatilityForTesting]):
2807         Add WKWebView SPI to disable volatility of snapshots, for testing purposes.
2808         
2809         * UIProcess/Cocoa/WebViewImpl.h:
2810         * UIProcess/Cocoa/WebViewImpl.mm:
2811         (WebKit::WebViewImpl::takeViewSnapshot):
2812         Adopt ViewSnapshot::setVolatile instead of reaching into the surface.
2813
2814         * UIProcess/mac/ViewGestureControllerMac.mm:
2815         (WebKit::ViewGestureController::removeSwipeSnapshot):
2816         Adopt ViewSnapshot::setVolatile instead of reaching into the surface.
2817
2818         * UIProcess/mac/ViewSnapshotStore.h:
2819         (WebKit::ViewSnapshotStore::setDisableSnapshotVolatilityForTesting):
2820         (WebKit::ViewSnapshotStore::disableSnapshotVolatilityForTesting):
2821         * UIProcess/mac/ViewSnapshotStore.mm:
2822         (WebKit::ViewSnapshotStore::ViewSnapshotStore):
2823         (WebKit::ViewSnapshot::setVolatile):
2824         (WebKit::ViewSnapshot::asLayerContents):
2825         Move all touching of snapshot volatility into the new setVolatile,
2826         and short-circuit if the testing-only m_disableSnapshotVolatility bit is set
2827
2828         (WebKit::ViewSnapshot::asImageForTesting):
2829         Make a CGImageRef for the aforementioned WKBackForwardListItem SPI.
2830         This is currently not implemented for the iOS Simulator, because we
2831         don't have access to the bits of the image in that case.
2832
2833 2016-10-05  Chris Dumez  <cdumez@apple.com>
2834
2835         KeyboardEvent.getModifierState() should support "CapsLock" modifier
2836         https://bugs.webkit.org/show_bug.cgi?id=162861
2837
2838         Reviewed by Darin Adler.
2839
2840         Add support for CapsLock modifier on events.
2841
2842         * Shared/API/c/WKEvent.h:
2843         * Shared/API/c/WKSharedAPICast.h:
2844         (WebKit::toAPI):
2845         * Shared/WebEventConversion.cpp:
2846         (WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent):
2847         (WebKit::WebKit2PlatformWheelEvent::WebKit2PlatformWheelEvent):
2848         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
2849         (WebKit::WebKit2PlatformTouchEvent::WebKit2PlatformTouchEvent):
2850         (WebKit::WebKit2PlatformGestureEvent::WebKit2PlatformGestureEvent):
2851         * Shared/efl/WebEventFactory.cpp:
2852         (WebKit::toWebEventModifiers):
2853         * Shared/ios/WebIOSEventFactory.mm:
2854         (modifiersForEvent):
2855         * Shared/mac/WebEventFactory.mm:
2856         (WebKit::modifiersForEvent):
2857         * UIProcess/API/Cocoa/WKNavigationAction.mm:
2858         (toNSEventModifierFlags):
2859         * UIProcess/Cocoa/WebAutomationSessionCocoa.mm:
2860         (WebKit::WebAutomationSession::platformSimulateMouseInteraction):
2861
2862 2016-10-05  Zan Dobersek  <zdobersek@igalia.com>
2863
2864         Rename ENABLE_ENCRYPTED_MEDIA_V2 to ENABLE_LEGACY_ENCRYPTED_MEDIA
2865         https://bugs.webkit.org/show_bug.cgi?id=162903
2866
2867         Reviewed by Alex Christensen.
2868
2869         Rename build guards for the remaining implementation of the legacy EME API
2870         to ENABLE_LEGACY_ENCRYPTED_MEDIA. This will allow for the future implementation
2871         of the near-finished API to be guarded with the simple ENABLE_ENCRYPTED_MEDIA guards.
2872
2873         * Configurations/FeatureDefines.xcconfig:
2874         * WebProcess/WebPage/WebPage.cpp:
2875         (WebKit::m_userInterfaceLayoutDirection):
2876         * WebProcess/WebProcess.cpp:
2877         (WebKit::m_resourceLoadStatisticsStorage):
2878
2879 2016-10-05  Daniel Bates  <dabates@apple.com>
2880
2881         [WK2][NetworkSession] Ping requests should follow redirects if applicable
2882         https://bugs.webkit.org/show_bug.cgi?id=162580
2883         <rdar://problem/28631274>
2884
2885         Reviewed by Alex Christensen.
2886
2887         Implement support for following redirects, if applicable, of a ping request when using the
2888         Network Session (ENABLE(NETWORK_SESSION)) code path in WebKit2. For ping requests that are
2889         in response to hyperlink auditing (e.g. <a ping>) we should follow redirect responses.
2890         For Content Security Policy and XSS Auditor violation reports we should not follow redirect
2891         responses.
2892
2893         Currently we always ignore redirects for ping requests that are sent using the Network Session
2894         code path in WebKit2. This behavior disagrees with the behavior described in section
2895         "Hyperlink auditing" of the HTML standard, <https://html.spec.whatwg.org/multipage/semantics.html#hyperlink-auditing> (27 September 2016),
2896         as well as the behavior in Legacy WebKit and WebKit2 with Network Session disabled. We should
2897         follow redirects for ping requests initiated as part of hyperlink auditing to more closely
2898         conform to the HTML standard and match the behavior in Legacy WebKit and WebKit2 with Network
2899         Session disabled.
2900
2901         * NetworkProcess/PingLoad.h:
2902
2903 2016-10-05  Daniel Bates  <dabates@apple.com>
2904
2905         Do not follow redirects when sending violation report
2906         https://bugs.webkit.org/show_bug.cgi?id=162520
2907         <rdar://problem/27957639>
2908
2909         Reviewed by Alex Christensen.
2910
2911         Update the non-Network Session WebKit2 implementation to follow redirect responses for a ping
2912         request, if applicable. I did not update the Network Session implementation at this time. I
2913         will fix it in <https://bugs.webkit.org/show_bug.cgi?id=162580>.
2914
2915         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
2916         (WebKit::NetworkConnectionToWebProcess::loadPing): Tell PingHandle whether to follow redirects.
2917         * NetworkProcess/NetworkLoadParameters.h:
2918         * NetworkProcess/NetworkResourceLoadParameters.cpp:
2919         (WebKit::NetworkResourceLoadParameters::encode): Encode NetworkResourceLoadParameters::shouldFollowRedirects.
2920         (WebKit::NetworkResourceLoadParameters::decode): Decode NetworkResourceLoadParameters::shouldFollowRedirects.
2921         * NetworkProcess/PingLoad.h: Added FIXME comment to implement support for following redirects,
2922         if applicable (for hyperlink auditing). See <https://bugs.webkit.org/show_bug.cgi?id=162580>
2923         for more details.
2924         * WebProcess/Network/WebLoaderStrategy.cpp:
2925         (WebKit::WebLoaderStrategy::createPingHandle): Modified to take a boolean whether to follow
2926         redirects responses and set NetworkResourceLoadParameters::shouldFollowRedirects as appropriate.
2927         * WebProcess/Network/WebLoaderStrategy.h:
2928
2929 2016-10-05  Carlos Garcia Campos  <cgarcia@igalia.com>
2930
2931         [SOUP] Move global TLS errors handling from ResourceHandle to SoupNetworkSession
2932         https://bugs.webkit.org/show_bug.cgi?id=162910
2933
2934         Reviewed by Alex Christensen.
2935
2936         Use SoupNetworkSession instead of ResourceHandle.
2937
2938         * NetworkProcess/soup/NetworkProcessSoup.cpp:
2939         (WebKit::NetworkProcess::setIgnoreTLSErrors):
2940         (WebKit::NetworkProcess::allowSpecificHTTPSCertificateForHost):
2941
2942 2016-10-05  Carlos Garcia Campos  <cgarcia@igalia.com>
2943
2944         Unreviewed. Fix GTK+ build with USE_REDIRECTED_XCOMPOSITE_WINDOW disabled.
2945
2946         * UIProcess/AcceleratedDrawingAreaProxy.cpp:
2947         (WebKit::AcceleratedDrawingAreaProxy::setNativeSurfaceHandleForCompositing):
2948
2949 2016-10-04  Chris Dumez  <cdumez@apple.com>
2950
2951         Implement KeyboardEvent.code from the UI Event spec
2952         https://bugs.webkit.org/show_bug.cgi?id=149584
2953
2954         Reviewed by Darin Adler.
2955
2956         Add support for Keyboard.code attribute:
2957         - https://w3c.github.io/uievents/#dom-keyboardevent-code
2958         - https://w3c.github.io/uievents-code/
2959
2960         * Shared/WebEvent.h:
2961         (WebKit::WebKeyboardEvent::code):
2962         * Shared/WebEventConversion.cpp:
2963         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
2964         * Shared/WebKeyboardEvent.cpp:
2965         (WebKit::WebKeyboardEvent::WebKeyboardEvent):
2966         (WebKit::WebKeyboardEvent::encode):
2967         (WebKit::WebKeyboardEvent::decode):
2968         * Shared/mac/WebEventFactory.mm:
2969         (WebKit::WebEventFactory::createWebKeyboardEvent):
2970
2971 2016-10-04  Said Abou-Hallawa  <sabouhallawa@apple.com>
2972
2973         The dragged image should be the current frame only of the animated image
2974         https://bugs.webkit.org/show_bug.cgi?id=162109
2975
2976         Reviewed by Tim Horton.
2977
2978         * UIProcess/Cocoa/WebViewImpl.mm:
2979         (WebKit::WebViewImpl::provideDataForPasteboard): Call the Image function with its new name.
2980
2981 2016-10-04  Ryosuke Niwa  <rniwa@webkit.org>
2982
2983         Revert a change erroneously committed in r206795.
2984
2985         * WebProcess/WebPage/WebPage.cpp:
2986         (WebKit::WebPage::updatePreferences):
2987
2988 2016-10-04  Anders Carlsson  <andersca@apple.com>
2989
2990         Properly kill web processes in the launching state
2991         https://bugs.webkit.org/show_bug.cgi?id=162938
2992
2993         Reviewed by Tim Horton.
2994
2995         * UIProcess/Launcher/ProcessLauncher.h:
2996         Add m_xpcConnection member.
2997
2998         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
2999         (WebKit::ProcessLauncher::launchProcess):
3000         Store the XPC connection in the m_xpcConnection member variable.
3001         In the reply handler, handle m_xpcConnection being null.
3002
3003         (WebKit::ProcessLauncher::platformInvalidate):
3004         Cancel and kill the connection.
3005
3006         * UIProcess/WebPageProxy.cpp:
3007         (WebKit::WebPageProxy::terminateProcess):
3008         Get rid of an assertion.
3009
3010         * UIProcess/WebProcessProxy.cpp:
3011         (WebKit::WebProcessProxy::requestTermination):
3012         Handle the launching state.
3013
3014 2016-10-04  Tim Horton  <timothy_horton@apple.com>
3015
3016         Fix the build.
3017
3018         * Shared/WebBackForwardListItem.cpp:
3019         (WebKit::WebBackForwardListItem::WebBackForwardListItem):
3020         (WebKit::WebBackForwardListItem::highestUsedItemID):
3021
3022 2016-10-04  Tim Horton  <timothy_horton@apple.com>
3023
3024         Fix a typo in WebBackForwardListItem (highed->highest)
3025         https://bugs.webkit.org/show_bug.cgi?id=162935
3026
3027         Reviewed by Anders Carlsson.
3028
3029         * Shared/WebBackForwardListItem.cpp:
3030         (WebKit::WebBackForwardListItem::highestUsedItemID):
3031         (WebKit::WebBackForwardListItem::highedUsedItemID): Deleted.
3032         * Shared/WebBackForwardListItem.h:
3033         * UIProcess/WebPageProxy.cpp:
3034         (WebKit::WebPageProxy::creationParameters):
3035
3036 2016-10-04  Yusuke Suzuki  <utatane.tea@gmail.com>
3037
3038         [DOMJIT] Introduce DOMJIT::GetterSetter to tell JIT information
3039         https://bugs.webkit.org/show_bug.cgi?id=162916
3040
3041         Reviewed by Filip Pizlo.
3042
3043         * CMakeLists.txt:
3044
3045 2016-10-04  Carlos Garcia Campos  <cgarcia@igalia.com>
3046
3047         [SOUP] Remove SSLPolicyFlags from SoupNetworkSession
3048         https://bugs.webkit.org/show_bug.cgi?id=162906
3049
3050         Reviewed by Michael Catanzaro.
3051
3052         * NetworkProcess/soup/NetworkProcessMainSoup.cpp:
3053         (WebKit::NetworkProcessMainUnix):
3054
3055 2016-10-04  Wenson Hsieh  <wenson_hsieh@apple.com>
3056
3057         Media controls are displayed in the incorrect state momentarily after switching between tabs playing media
3058         https://bugs.webkit.org/show_bug.cgi?id=162766
3059         <rdar://problem/28533523>
3060
3061         Reviewed by Jer Noble.
3062
3063         Plumbs some more Now Playing information from the web process to the UI process for testing purposes. See
3064         WebCore ChangeLog for more details.
3065
3066         * UIProcess/API/Cocoa/WKWebView.mm:
3067         (-[WKWebView _handleActiveNowPlayingSessionInfoResponse:title:duration:elapsedTime:]):
3068         (-[WKWebView _handleActiveNowPlayingSessionInfoResponse:]): Deleted.
3069         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3070         * UIProcess/PageClient.h:
3071         * UIProcess/WebPageProxy.cpp:
3072         (WebKit::WebPageProxy::handleActiveNowPlayingSessionInfoResponse):
3073         * UIProcess/WebPageProxy.h:
3074         * UIProcess/WebPageProxy.messages.in:
3075         * UIProcess/mac/PageClientImpl.h:
3076         * UIProcess/mac/PageClientImpl.mm:
3077         (WebKit::PageClientImpl::handleActiveNowPlayingSessionInfoResponse):
3078         * WebProcess/WebPage/mac/WebPageMac.mm:
3079         (WebKit::WebPage::requestActiveNowPlayingSessionInfo):
3080
3081 2016-10-04  Zan Dobersek  <zdobersek@igalia.com>
3082
3083         Unreviewed GTK+ build fix.
3084
3085         * UIProcess/API/C/WKPage.cpp:
3086         (WKPageSetPageNavigationClient): Guard the call to getDefaultWebCryptoMasterKey()
3087         with ENABLE(SUBTLE_CRYPTO), since the same guard is used for the definition. Fixes
3088         GTK+ production builds where the feature is disabled.
3089
3090 2016-10-03  Keith Rollin  <krollin@apple.com>
3091
3092         More logging to diagnose "WebKit encountered an internal error" messages
3093         https://bugs.webkit.org/show_bug.cgi?id=162754
3094
3095         Reviewed by Antti Koivisto.
3096
3097         Add more logging around calls to internalError, as well as some
3098         low-level logging around SharedMemory, and mach_vm_map in particular.
3099
3100         * NetworkProcess/NetworkResourceLoader.cpp:
3101         (WebKit::NetworkResourceLoader::startNetworkLoad):
3102         * Platform/Logging.h:
3103         * Platform/mac/SharedMemoryMac.cpp:
3104         (WebKit::SharedMemory::allocate):
3105         (WebKit::makeMemoryEntry):
3106         (WebKit::SharedMemory::map):
3107         (WebKit::SharedMemory::~SharedMemory):
3108         * WebProcess/Network/WebLoaderStrategy.cpp:
3109         (WebKit::WebLoaderStrategy::networkProcessCrashed):
3110         (WebKit::WebLoaderStrategy::loadResourceSynchronously):
3111         * WebProcess/Network/WebResourceLoader.cpp:
3112         (WebKit::WebResourceLoader::didReceiveResource):
3113
3114 2016-10-03  Ryan Haddad  <ryanhaddad@apple.com>
3115
3116         Unreviewed, rolling out r206754.
3117
3118         This change broke the El Capitan and Yosemite debug builds.
3119
3120         Reverted changeset:
3121
3122         "More logging to diagnose "WebKit encountered an internal
3123         error" messages"
3124         https://bugs.webkit.org/show_bug.cgi?id=162754
3125         http://trac.webkit.org/changeset/206754
3126
3127 2016-10-03  Keith Rollin  <krollin@apple.com>
3128
3129         More logging to diagnose "WebKit encountered an internal error" messages
3130         https://bugs.webkit.org/show_bug.cgi?id=162754
3131
3132         Reviewed by Antti Koivisto.
3133
3134         Add more logging around calls to internalError, as well as some
3135         low-level logging around SharedMemory, and mach_vm_map in particular.
3136
3137         * NetworkProcess/NetworkResourceLoader.cpp:
3138         (WebKit::NetworkResourceLoader::startNetworkLoad):
3139         * Platform/Logging.h:
3140         * Platform/mac/SharedMemoryMac.cpp:
3141         (WebKit::SharedMemory::allocate):
3142         (WebKit::makeMemoryEntry):
3143         (WebKit::SharedMemory::map):
3144         (WebKit::SharedMemory::~SharedMemory):
3145         * WebProcess/Network/WebLoaderStrategy.cpp:
3146         (WebKit::WebLoaderStrategy::networkProcessCrashed):
3147         (WebKit::WebLoaderStrategy::loadResourceSynchronously):
3148         * WebProcess/Network/WebResourceLoader.cpp:
3149         (WebKit::WebResourceLoader::didReceiveResource):
3150
3151 2016-10-03  Chris Dumez  <cdumez@apple.com>
3152
3153         Add support for KeyboardEvent.key attribute
3154         https://bugs.webkit.org/show_bug.cgi?id=36267
3155
3156         Reviewed by Darin Adler.
3157
3158         Add support for KeyboardEvent.key attribute.
3159
3160         * Shared/WebEvent.h:
3161         (WebKit::WebKeyboardEvent::key):
3162         (WebKit::WebKeyboardEvent::unmodifiedText): Deleted.
3163         * Shared/WebEventConversion.cpp:
3164         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
3165         * Shared/WebKeyboardEvent.cpp:
3166         (WebKit::WebKeyboardEvent::WebKeyboardEvent):
3167         (WebKit::WebKeyboardEvent::encode):
3168         (WebKit::WebKeyboardEvent::decode):
3169         * Shared/mac/WebEventFactory.mm:
3170         (WebKit::WebEventFactory::createWebKeyboardEvent):
3171
3172 2016-10-03  Chris Dumez  <cdumez@apple.com>
3173
3174         Add support for KeyboardEvent.key attribute
3175         https://bugs.webkit.org/show_bug.cgi?id=36267
3176
3177         Reviewed by Darin Adler.
3178
3179         Add support for KeyboardEvent.key attribute.
3180
3181         * Shared/WebEvent.h:
3182         (WebKit::WebKeyboardEvent::key):
3183         (WebKit::WebKeyboardEvent::unmodifiedText): Deleted.
3184         * Shared/WebEventConversion.cpp:
3185         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
3186         * Shared/WebKeyboardEvent.cpp:
3187         (WebKit::WebKeyboardEvent::WebKeyboardEvent):
3188         (WebKit::WebKeyboardEvent::encode):
3189         (WebKit::WebKeyboardEvent::decode):
3190         * Shared/mac/WebEventFactory.mm:
3191         (WebKit::WebEventFactory::createWebKeyboardEvent):
3192
3193 2016-10-03  Carlos Garcia Campos  <cgarcia@igalia.com>
3194
3195         [SOUP] Cleanup persistent credential storage code
3196         https://bugs.webkit.org/show_bug.cgi?id=162777
3197
3198         Reviewed by Alex Christensen.
3199
3200         Use USE(LIBSECRET) instead of ENABLE(CREDENTIAL_STORAGE).
3201
3202         * UIProcess/API/gtk/WebKitAuthenticationRequest.cpp:
3203         (webkit_authentication_request_can_save_credentials):
3204
3205 2016-10-02  Ryan Haddad  <ryanhaddad@apple.com>
3206
3207         Unreviewed, rolling out r206683.
3208
3209         This change caused API test WebKit2.FindMatches to fail on
3210         Mac.
3211
3212         Reverted changeset:
3213
3214         "The dragged image should be the current frame only of the
3215         animated image"
3216         https://bugs.webkit.org/show_bug.cgi?id=162109
3217         http://trac.webkit.org/changeset/206683
3218
3219 2016-09-30  Myles C. Maxfield  <mmaxfield@apple.com>
3220
3221         Follow-up patch after r206701
3222         https://bugs.webkit.org/show_bug.cgi?id=162818
3223
3224         Unreviewed.
3225
3226         I missed one place required to enable an experimental feature by default.
3227
3228         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
3229         (WebKit::registerUserDefaultsIfNeeded):
3230
3231 2016-09-30  Dan Bernstein  <mitz@apple.com>
3232
3233         [iOS] Editing menu omits the Share command if the selected text is longer than 200 characters
3234         https://bugs.webkit.org/show_bug.cgi?id=162821
3235         <rdar://problem/28409828>
3236
3237         Reviewed by Tim Horton.
3238
3239         * UIProcess/ios/WKContentViewInteraction.mm:
3240         (-[WKContentView canPerformAction:withSender:]): Changed to return YES for the _share:
3241           action even if the selection is longer than 200 characters. While Define should not have
3242           been available for longer selections, Share does not have such a limitation.
3243
3244 2016-09-30  Myles C. Maxfield  <mmaxfield@apple.com>
3245
3246         Turn variation fonts on by default
3247         https://bugs.webkit.org/show_bug.cgi?id=162818
3248
3249         Reviewed by Simon Fraser.
3250
3251         * Shared/WebPreferencesDefinitions.h:
3252
3253 2016-09-30  Brady Eidson  <beidson@apple.com>
3254
3255         REGRESSION (Safari 10 combined with WK changes): Unable to store WebCrypto keys in IndexedDB database.
3256         <rdar://problem/28334440> and https://bugs.webkit.org/show_bug.cgi?id=162554
3257
3258         Reviewed by Alexey Proskuryakov.
3259
3260         Safari 10 has a WKPageNavigation client but does not implement the "copyWebCryptoMasterKey" callback.
3261
3262         WebKit just fails in this case, instead of falling back to "getDefaultWebCryptoMasterKey".
3263         It should fall back.
3264
3265         Additionally there's a WKContextClient callback to get the crypto key, also, but it is completely unused.
3266         So it should be pulled.
3267
3268         * UIProcess/API/APILoaderClient.h:
3269         (API::LoaderClient::webCryptoMasterKey): Deleted.
3270         * UIProcess/API/C/WKContext.h:
3271
3272         * UIProcess/API/C/WKPage.cpp:
3273         (WKPageSetPageLoaderClient):
3274         (WKPageSetPageNavigationClient): If the client doesn't implement this method, fallback to getDefaultWebCryptoMasterKey.
3275
3276         * UIProcess/Cocoa/NavigationState.mm:
3277         (WebKit::NavigationState::NavigationClient::webCryptoMasterKey): If the client doesn't implement this method,
3278           fallback to getDefaultWebCryptoMasterKey.
3279
3280         * UIProcess/WebContextClient.cpp:
3281         (WebKit::WebContextClient::copyWebCryptoMasterKey): Deleted.
3282         * UIProcess/WebContextClient.h:
3283
3284         * UIProcess/WebPageProxy.cpp:
3285         (WebKit::WebPageProxy::wrapCryptoKey): Only ask the NavigationClient before falling back. Don't ask the loader client.
3286         (WebKit::WebPageProxy::unwrapCryptoKey): Ditto.
3287
3288 2016-09-30  Said Abou-Hallawa  <sabouhallawa@apple.com>
3289
3290         The dragged image should be the current frame only of the animated image
3291         https://bugs.webkit.org/show_bug.cgi?id=162109
3292
3293         Reviewed by Tim Horton.
3294
3295         * UIProcess/Cocoa/WebViewImpl.mm:
3296         (WebKit::WebViewImpl::provideDataForPasteboard): Call the Image function with its new name.
3297
3298 2016-09-30  Anders Carlsson  <andersca@apple.com>
3299
3300         Second time going into fullscreen using silverlight, will hide the menu bar and dock for Safari
3301         https://bugs.webkit.org/show_bug.cgi?id=162805
3302         rdar://problem/28208495
3303
3304         Reviewed by Dan Bernstein.
3305
3306         Turns out that the WindowRef wrappers for full screen NSWindows can end up in the m_windows HashSet,
3307         and never go away. 
3308         
3309         Fix this by storing the canonical CGWindowIDs in the hash map instead.
3310
3311         * PluginProcess/mac/PluginProcessMac.mm:
3312         (WebKit::cgWindowID):
3313         (WebKit::windowCoversAnyScreen):
3314         (WebKit::FullscreenWindowTracker::windowShown):
3315         (WebKit::FullscreenWindowTracker::windowHidden):
3316
3317 2016-09-30  Myles C. Maxfield  <mmaxfield@apple.com>
3318
3319         Create runtime flag for variation font work
3320         https://bugs.webkit.org/show_bug.cgi?id=162780
3321
3322         Reviewed by Alex Christensen.
3323
3324         * Shared/WebPreferencesDefinitions.h:
3325         * WebProcess/WebPage/WebPage.cpp:
3326         (WebKit::WebPage::updatePreferences):
3327
3328 2016-09-30  Chris Dumez  <cdumez@apple.com>
3329
3330         [WK2][iOS] Add radiusX / radiusY / rotationAngle to WebPlatformTouchPoint
3331         https://bugs.webkit.org/show_bug.cgi?id=162787
3332         <rdar://problem/28554292>
3333
3334         Reviewed by Benjamin Poulain.
3335
3336         Add radiusX / radiusY / rotationAngle to WebPlatformTouchPoint.
3337
3338         * Platform/spi/ios/UIKitSPI.h:
3339         * Shared/WebEvent.h:
3340         (WebKit::WebPlatformTouchPoint::setRadiusX):
3341         (WebKit::WebPlatformTouchPoint::radiusX):
3342         (WebKit::WebPlatformTouchPoint::setRadiusY):
3343         (WebKit::WebPlatformTouchPoint::radiusY):
3344         (WebKit::WebPlatformTouchPoint::setRotationAngle):
3345         (WebKit::WebPlatformTouchPoint::rotationAngle):
3346         * Shared/WebEventConversion.cpp:
3347         (WebKit::WebKit2PlatformTouchPoint::WebKit2PlatformTouchPoint):
3348         * Shared/ios/NativeWebTouchEventIOS.mm:
3349         (WebKit::NativeWebTouchEvent::extractWebTouchPoint):
3350         * Shared/ios/WebPlatformTouchPointIOS.cpp:
3351         (WebKit::WebPlatformTouchPoint::encode):
3352         (WebKit::WebPlatformTouchPoint::decode):
3353
3354 2016-09-30  Megan Gardner  <megan_gardner@apple.com>
3355
3356         Make it possible to test web-related user-interface features
3357         https://bugs.webkit.org/show_bug.cgi?id=162657
3358
3359         Reviewed by Simon Fraser.
3360
3361         Added the ability to pull the strings from an Action Sheet and pass them to
3362         test scripts to make sure we are giving the correct available actions for
3363         the item we are interacting with.
3364         Added a test for long press on an image, and used the sheet scraping functionality
3365         to make sure that the correct actions were being displayed.
3366         Test for previous patch, Changeset 205915; Bug 161761
3367
3368         * UIProcess/API/Cocoa/WKWebView.mm:
3369         (-[WKWebView _contentsOfUserInterfaceItem:]):
3370         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3371         * UIProcess/ios/WKActionSheetAssistant.h:
3372         * UIProcess/ios/WKActionSheetAssistant.mm:
3373         (-[WKActionSheetAssistant currentAvailableActionStrings]):
3374         * UIProcess/ios/WKContentViewInteraction.h:
3375         * UIProcess/ios/WKContentViewInteraction.mm:
3376         (-[WKContentView _contentsOfUserInterfaceItem:]):
3377
3378 2016-09-27  Anders Carlsson  <andersca@apple.com>
3379
3380         Remove a couple of unused members from PlatformKeyboardEvent
3381         https://bugs.webkit.org/show_bug.cgi?id=162641
3382
3383         Reviewed by Tim Horton.
3384
3385         * Shared/WebEventConversion.cpp:
3386         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
3387
3388 2016-09-29  Nan Wang  <n_wang@apple.com>
3389
3390         AX: iOS: Tapping <input> in Safari zooms in a bit when page has max scale = 1
3391         https://bugs.webkit.org/show_bug.cgi?id=162471
3392
3393         Reviewed by Simon Fraser.
3394
3395         * Shared/AssistedNodeInformation.cpp:
3396         (WebKit::AssistedNodeInformation::encode):
3397         (WebKit::AssistedNodeInformation::decode):
3398         * Shared/AssistedNodeInformation.h:
3399         * UIProcess/ios/WKContentViewInteraction.mm:
3400         (-[WKContentView _displayFormNodeInputView]):
3401         * WebProcess/WebPage/WebPage.h:
3402         * WebProcess/WebPage/ios/WebPageIOS.mm:
3403         (WebKit::WebPage::maximumPageScaleFactorIgnoringAlwaysScalable):
3404         (WebKit::WebPage::getAssistedNodeInformation):
3405
3406 2016-09-29  Daniel Bates  <dabates@apple.com>
3407
3408         Mark NetworkLoad as final
3409         https://bugs.webkit.org/show_bug.cgi?id=162681
3410
3411         Reviewed by Alex Christensen.
3412
3413         Mark class NetworkLoad as final as we do not have any derived classes at the moment and it
3414         is unclear if it would make sense to subclass it. We can always unmark the class if it turns
3415         out that it makes sense to subclass it.
3416
3417         * NetworkProcess/NetworkLoad.h:
3418
3419 2016-09-29  Sam Weinig  <sam@webkit.org>
3420
3421         Allow overriding some NSURLSessionConfiguration properties on a per-NetworkProcess basis
3422         <rdar://problem/27648683>
3423         https://bugs.webkit.org/show_bug.cgi?id=162735
3424
3425         Reviewed by Dan Bernstein.
3426
3427         Add SPI for overriding the following NSURLSessionConfigurations properties:
3428             - _sourceApplicationBundleIdentifier
3429             - _sourceApplicationSecondaryIdentifier
3430             - _CTDataConnectionServiceType
3431