dd689dec7a23a69f857c4d70fdb2cc603b1ea8d9
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2016-01-27  Zhuo Li  <zachli@apple.com>
2
3         Need ability to specify alternate image for AutoFill button in input fields.
4         https://bugs.webkit.org/show_bug.cgi?id=153116.
5         rdar://problem/23384854.
6
7         Reviewed by Darin Adler.
8
9         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
10         (toAutoFillButtonType): Convert the WebKit AutoFill button type enum to WebCore AutoFill button
11         type enum.
12         (WKBundleNodeHandleSetHTMLInputElementAutoFillButtonEnabledWithButtonType): Added to be able to specify
13         what the AutoFill button type is. None means the AutoFill button is not shown.
14         (WKBundleNodeHandleSetHTMLInputElementAutoFillButtonEnabled): Deprecate this method.
15         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandlePrivate.h: Declare an AutoFill button type enum.
16         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
17         (WebKit::InjectedBundleNodeHandle::isHTMLInputElementAutoFillButtonEnabled): None means the AutoFill button is not enabled.
18         (WebKit::InjectedBundleNodeHandle::setHTMLInputElementAutoFillButtonEnabledWithButtonType): Use the new parameter to specify
19         what the AutoFill button type is.
20         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h: Ditto.
21
22 2016-01-27  Dan Bernstein  <mitz@apple.com>
23
24         More trying to fix the build.
25
26         * Configurations/WebKit.xcconfig:
27
28 2016-01-27  Alexey Proskuryakov  <ap@apple.com>
29
30         Remove ENABLE_CURRENTSRC
31         https://bugs.webkit.org/show_bug.cgi?id=153545
32
33         Reviewed by Simon Fraser.
34
35         * Configurations/FeatureDefines.xcconfig:
36
37 2016-01-27  Sam Weinig  <sam@webkit.org>
38
39         Try to fix the build.
40
41         * Configurations/WebKit.xcconfig:
42
43 2016-01-26  Sam Weinig  <sam@webkit.org>
44
45         Attempt to force a rebuild.
46
47         * DerivedSources.make:
48
49 2016-01-26  Tim Horton  <timothy_horton@apple.com>
50
51         REGRESSION (r194557): Keyboard shortcuts stop working after the WKWebView is unparented and reparented
52         https://bugs.webkit.org/show_bug.cgi?id=153492
53         <rdar://problem/24138989>
54
55         Reviewed by Dan Bernstein.
56
57         * UIProcess/ios/WKContentViewInteraction.h:
58         * UIProcess/ios/WKContentViewInteraction.mm:
59         (-[WKContentView canBecomeFirstResponder]):
60         (-[WKContentView becomeFirstResponder]):
61         (-[WKContentView resignFirstResponder]):
62         When WKWebView is unparented, WKContentView will attempt to resignFirstResponder upwards,
63         first asking WKWebView. After r194557, WKWebView will accept first responder and forward
64         it on to the WKContentView, which will happily accept it again, despite being the view
65         that's trying to resign. This will cause us to completely lose first responder,
66         where it was actually supposed to propagate up above WKWebView to the client.
67
68         Keep track of when WKContentView is resigning first responder, and don't
69         let it become first responder while it is doing so, breaking the cycle.
70
71         * UIProcess/ios/WKContentView.h:
72         * UIProcess/API/Cocoa/WKWebView.mm:
73         (-[WKWebView canBecomeFirstResponder]):
74         If the WKContentView is currently in the process of resigning first responder status,
75         we shouldn't accept it, because clients expect to receive it.
76
77 2016-01-26  I-Ting Liu  <iting_liu@apple.com>
78
79         Implement wildcard matching for plug-in policy host.
80         https://bugs.webkit.org/show_bug.cgi?id=153090
81
82         Reviewed by Darin Adler.
83
84         WebPlatformStrategies decides the plug-in load policy for a host by looking
85         for a matched hostname in the list of plug-in policies sent by Safari. This
86         patch adds support for wildcard matching -- if there's a policy with hostname
87         "*.example.com," the policy for "foo.example.com" would be replaced with that
88         of "*.example.com" if there's no policy for this hostname. If there is more
89         than one wildcard hostname, the host with the longest wildcard hostname will
90         be used.
91
92         This patch adds a helper function in StringUtilites that matches a string to
93         another string, which may contain wildcard ('*') characters.
94
95         * Platform/mac/StringUtilities.h:
96         - Add WebKit::stringMatchesWildcardString.
97         - Remove #if ENABLE(TELEPHONE_NUMBER_DETECTION) && PLATFORM(MAC) flag so that
98         the compiler allows exposing StringUtilities.h.
99         - Add #if __OBJC__ to allow the file to be included in WebPltformStrategies.cpp
100
101         * Platform/mac/StringUtilities.mm:
102         (WebKit::stringMatchesWildcardString):
103         Return true if the entire first given String matches the second. The second string 
104         may contain wildcard characters.
105         (WebKit::wildcardRegexPatternString):
106         Return the regex expression from a wildcard string by replacing the wildcard
107         character ('*') with (".*") and escaping regular expression metacharacters.
108         (WebKit::formattedPhoneNumberString):
109         To expose StringUtilities.h for tests, we removed #if ENABLE(TELEPHONE_NUMBER_DETECTION)
110         && PLATFORM(MAC) flag in the header. Add a function that returns nil for
111         #if !(ENABLE(TELEPHONE_NUMBER_DETECTION) && PLATFORM(MAC)) to fix the removal
112         of the flag in the header file.
113
114         * WebKit2.xcodeproj/project.pbxproj:
115         Change the file attribute of StringUtilities.h from Project to Private for
116         testing in TestWebKitAPI.
117
118         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
119         (WebKit::WebPlatformStrategies::longestMatchedWildcardHostForHost):
120         Return the wildcard hostname whose matched substring with the host is the longest.
121         (WebKit::WebPlatformStrategies::replaceHostWithMatchedWildcardHost):
122         Replace the look-up host with a matched wildcard host if there is a match and that
123         the matched wildcard host's plug-in identifier is the same as that of the host.
124         (WebKit::WebPlatformStrategies::pluginLoadClientPolicyForHost):
125         Try to replace the look-up host with the wildcard host if there's no policy for
126         the host. Restructure the function to reduce hashmap lookup.
127
128         * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
129         Declare the methods.
130
131 2016-01-26  Anders Carlsson  <andersca@apple.com>
132
133         Remove -d flag from make invocation.
134
135         * WebKit2.xcodeproj/project.pbxproj:
136
137 2016-01-26  Joseph Pecoraro  <pecoraro@apple.com>
138
139         Generalize ResourceUsageData gathering to be used outside of ResourceUsageOverlay
140         https://bugs.webkit.org/show_bug.cgi?id=153509
141         <rdar://problem/24354291>
142
143         Reviewed by Andreas Kling.
144
145         * WebProcess/WebPage/WebPage.cpp:
146         (WebKit::WebPage::updatePreferences):
147         Rename the ENABLE flag.
148
149 2016-01-26  Commit Queue  <commit-queue@webkit.org>
150
151         Unreviewed, rolling out r195602.
152         https://bugs.webkit.org/show_bug.cgi?id=153526
153
154         broke more than it fixed (Requested by thorton on #webkit).
155
156         Reverted changeset:
157
158         "REGRESSION (r194557): Keyboard shortcuts stop working after
159         the WKWebView is unparented and reparented"
160         https://bugs.webkit.org/show_bug.cgi?id=153492
161         http://trac.webkit.org/changeset/195602
162
163 2016-01-26  Anders Carlsson  <andersca@apple.com>
164
165         WebKitAdditions should be able to modify derived source rules
166         https://bugs.webkit.org/show_bug.cgi?id=153514
167
168         Reviewed by Tim Horton.
169
170         * Configurations/BaseTarget.xcconfig:
171         * Configurations/WebKit.xcconfig:
172         Set WEBKITADDITIONS_HEADER_SEARCH_PATHS.
173
174         * DerivedSources.make:
175         Move the path computation earlier and include WebKitDerivedSourcesAdditions.make.
176
177         * WebKit2.xcodeproj/project.pbxproj:
178         Pass our WebKitAdditions paths as include paths to make.
179
180 2016-01-26  Anders Carlsson  <andersca@apple.com>
181
182         Add a private WKUIDelegate method for getting a presenting view controller for a WKWebView on iOS
183         https://bugs.webkit.org/show_bug.cgi?id=153510
184
185         Reviewed by Dan Bernstein.
186
187         * UIProcess/API/APIUIClient.h:
188         (API::UIClient::presentingViewController):
189         * UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
190         * UIProcess/Cocoa/UIDelegate.h:
191         * UIProcess/Cocoa/UIDelegate.mm:
192         (WebKit::UIDelegate::setDelegate):
193         (WebKit::UIDelegate::UIClient::presentingViewController):
194
195 2016-01-26  Dean Jackson  <dino@apple.com>
196
197         [iOS] Documents without an explicit width should not get fast tapping
198         https://bugs.webkit.org/show_bug.cgi?id=153465
199         <rdar://problem/23962529>
200
201         Reviewed by Simon Fraser (and Wenson Hseih).
202
203         As the title says, documents that do not set a viewport should
204         not get the fast click behaviour. There were complaints that we broke
205         double-tap to scroll in ImageDocuments where the image was narrow and long.
206
207         The fix is to just keep a flag that tells the UI process if the
208         width was explicit. However, it turns out that those ImageDocuments
209         are given an explicit device-width, which is fine for scaling but
210         really should behave as auto for fast tapping. So we also need
211         to tell the UIProcess if the viewport arguments came from an
212         ImageDocument.
213
214         * Shared/mac/RemoteLayerTreeTransaction.h: Add two new flags into
215         the transaction.
216         (WebKit::RemoteLayerTreeTransaction::viewportMetaTagWidthWasExplicit):
217         (WebKit::RemoteLayerTreeTransaction::setViewportMetaTagWidthWasExplicit):
218         (WebKit::RemoteLayerTreeTransaction::viewportMetaTagCameFromImageDocument):
219         (WebKit::RemoteLayerTreeTransaction::setViewportMetaTagCameFromImageDocument):
220         * Shared/mac/RemoteLayerTreeTransaction.mm:
221         (WebKit::RemoteLayerTreeTransaction::encode):
222         (WebKit::RemoteLayerTreeTransaction::decode):
223         (WebKit::RemoteLayerTreeTransaction::description):
224
225         * UIProcess/API/Cocoa/WKWebView.mm:
226         (-[WKWebView _didCommitLayerTree:]): Notice whether or not the viewport
227         width was explicit.
228         (-[WKWebView _allowsDoubleTapGestures]): Return yes if the width
229         was not explicit, or if the viewport came from an ImageDocument.
230         * WebProcess/WebPage/WebPage.cpp:
231         (WebKit::WebPage::willCommitLayerTree):
232
233 2016-01-26  Tim Horton  <timothy_horton@apple.com>
234
235         REGRESSION (r194557): Keyboard shortcuts stop working after the WKWebView is unparented and reparented
236         https://bugs.webkit.org/show_bug.cgi?id=153492
237         <rdar://problem/24138989>
238
239         Reviewed by Dan Bernstein.
240
241         * UIProcess/ios/WKContentViewInteraction.h:
242         * UIProcess/ios/WKContentViewInteraction.mm:
243         (-[WKContentView canBecomeFirstResponder]):
244         (-[WKContentView becomeFirstResponder]):
245         (-[WKContentView resignFirstResponder]):
246         When WKWebView is unparented, WKContentView will attempt to resignFirstResponder upwards,
247         first asking WKWebView. After r194557, WKWebView will accept first responder and forward
248         it on to the WKContentView, which will happily accept it again, despite being the view
249         that's trying to resign. This will cause us to completely lose first responder,
250         where it was actually supposed to propagate up above WKWebView to the client.
251
252         Keep track of when WKContentView is resigning first responder, and don't
253         let it become first responder while it is doing so, breaking the cycle.
254
255 2016-01-25  Ada Chan  <adachan@apple.com>
256
257         Move WebVideoFullscreenManager and related classes from iOS specific folders to cocoa folders
258         https://bugs.webkit.org/show_bug.cgi?id=153473
259
260         Reviewed by Eric Carlson.
261
262         * DerivedSources.make:
263         Add new paths.
264         * UIProcess/Cocoa/WebVideoFullscreenManagerProxy.h: Renamed from Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.h.
265         * UIProcess/Cocoa/WebVideoFullscreenManagerProxy.messages.in: Renamed from Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in.
266         * UIProcess/Cocoa/WebVideoFullscreenManagerProxy.mm: Renamed from Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.mm.
267         (WebKit::WebVideoFullscreenManagerProxy::setSeekableRangesVector):
268         Fix a style error by moving the opening curly brace to the same line as the for statement.
269         * WebKit2.xcodeproj/project.pbxproj:
270         Update due to changes to the file locations.
271         * WebProcess/cocoa/WebVideoFullscreenManager.h: Renamed from Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.h.
272         * WebProcess/cocoa/WebVideoFullscreenManager.messages.in: Renamed from Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.messages.in.
273         * WebProcess/cocoa/WebVideoFullscreenManager.mm: Renamed from Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.mm.
274         (WebKit::WebVideoFullscreenInterfaceContext::setSeekableRanges):
275         Fix a style error by adding a missing space after a comma.
276
277 2016-01-26  Daniel Bates  <dabates@apple.com>
278
279         WebKitTestRunner: Credential cache is not cleared between tests
280         https://bugs.webkit.org/show_bug.cgi?id=153407
281         <rdar://problem/24280834>
282
283         Reviewed by Alexey Proskuryakov.
284
285         Expose SPI to call CredentialStorage::clearCredentials() on the default network storage
286         session to clear cached credentials.
287
288         * NetworkProcess/NetworkProcess.cpp:
289         (WebKit::NetworkProcess::clearCachedCredentials): Added.
290         * NetworkProcess/NetworkProcess.h:
291         * NetworkProcess/NetworkProcess.messages.in: Added message ClearCachedCredentials().
292         * UIProcess/API/C/WKContext.cpp:
293         (WKContextClearCachedCredentials): Added.
294         * UIProcess/API/C/WKContextPrivate.h:
295         * UIProcess/WebProcessPool.cpp:
296         (WebKit::WebProcessPool::clearCachedCredentials): Notify all web processes and the
297         network process to clear cached credentials.
298         * UIProcess/WebProcessPool.h:
299         * WebProcess/WebProcess.cpp:
300         (WebKit::WebProcess::clearCachedCredentials): Clear cached credentials in the default
301         network storage session.
302         * WebProcess/WebProcess.h:
303         * WebProcess/WebProcess.messages.in: Added message ClearCachedCredentials().
304
305 2016-01-26  Mario Sanchez Prada  <mario@endlessm.com>
306
307         [GTK] WebProcess crashes when quickly attempting many DnD operations
308         https://bugs.webkit.org/show_bug.cgi?id=138468
309
310         Reviewed by Michael Catanzaro.
311
312         Do not allow different DnD operations over the same element at the
313         same time, so that any new attempt to DnD an element happening before
314         a previous attempt has ended will take precedence, cancelling the older
315         operation before going ahead with the new one.
316
317         This is consistent with how WebCore::EventHandler handles DnD operations,
318         preventing the web process from crashing in scenarios where the user might
319         try to perform many DnD operations over the same element very quickly.
320
321         * UIProcess/gtk/DragAndDropHandler.cpp:
322         (WebKit::DragAndDropHandler::DragAndDropHandler): Initialized new member.
323         (WebKit::DragAndDropHandler::startDrag): Ensure a previous DnD operation
324         is cancelled before handling the new one that has just started.
325         (WebKit::DragAndDropHandler::fillDragData): Protect against calling this
326         function from webkitWebViewBaseDragDataGet for already cancelled operations.
327         (WebKit::DragAndDropHandler::finishDrag): Protect against calling this
328         function from webkitWebViewBaseDragEnd for already cancelled operations.
329         * UIProcess/gtk/DragAndDropHandler.h:
330
331 2016-01-25  Enrica Casucci  <enrica@apple.com>
332
333         Add support for DataDetectors in WK (iOS).
334         https://bugs.webkit.org/show_bug.cgi?id=152989
335         rdar://problem/22855960
336
337         Reviewed by Tim Horton.
338
339         Moving InteractionInformationAtPosition files to platform folder,
340         since this is only used on iOS and changing from .cpp to .mm.
341         The structure is extended to include data detection specific fields
342         and the relevant encode/decode functions have been updated to
343         handle the new fields.
344         The patch also adds a new WKUIDelegatePrivate method to allow
345         the client to provide additional context for data detection actions.
346
347         * Platform/spi/ios/UIKitSPI.h:
348         * Shared/InteractionInformationAtPosition.cpp: Removed.
349         * Shared/InteractionInformationAtPosition.h: Removed.
350         * Shared/ios/InteractionInformationAtPosition.h: Copied from Shared/InteractionInformationAtPosition.h.
351         * Shared/ios/InteractionInformationAtPosition.mm: Copied from Shared/InteractionInformationAtPosition.cpp.
352         (WebKit::InteractionInformationAtPosition::encode):
353         (WebKit::InteractionInformationAtPosition::decode):
354         * UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
355         * UIProcess/WebPageProxy.h:
356         * UIProcess/ios/WKActionSheetAssistant.h:
357         * UIProcess/ios/WKActionSheetAssistant.mm:
358         (-[WKActionSheetAssistant showDataDetectorsSheet]):
359         * UIProcess/ios/WKContentViewInteraction.mm:
360         (-[WKContentView actionSheetAssistantDidStopInteraction:]):
361         (-[WKContentView dataDetectionContextForActionSheetAssistant:]):
362         (-[WKContentView selectedTextForActionSheetAssistant:]):
363         (-[WKContentView _dataForPreviewItemController:atPosition:type:]):
364         * UIProcess/ios/WebPageProxyIOS.mm:
365         * WebKit2.xcodeproj/project.pbxproj:
366         * WebProcess/WebPage/ios/WebPageIOS.mm:
367         (WebKit::WebPage::getPositionInformation):
368
369 2016-01-25  Commit Queue  <commit-queue@webkit.org>
370
371         Unreviewed, rolling out r195543.
372         https://bugs.webkit.org/show_bug.cgi?id=153451
373
374         regressed performance of test bots by ~6% (Requested by dydz
375         on #webkit).
376
377         Reverted changeset:
378
379         "WebKitTestRunner: Credential cache is not cleared between
380         tests"
381         https://bugs.webkit.org/show_bug.cgi?id=153407
382         http://trac.webkit.org/changeset/195543
383
384 2016-01-25  Chris Dumez  <cdumez@apple.com>
385
386         [WK2][NetworkCache] Enable speculative revalidation
387         https://bugs.webkit.org/show_bug.cgi?id=153443
388         <rdar://problem/23092196>
389
390         Reviewed by Antti Koivisto.
391
392         Enable speculative revalidation to better evaluate performance and
393         robustness.
394
395         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
396         (WebKit::registerUserDefaultsIfNeeded):
397
398 2016-01-25  Beth Dakin  <bdakin@apple.com>
399
400         Handle soft spaces after accepted candidates
401         https://bugs.webkit.org/show_bug.cgi?id=153331
402         -and corresponding-
403         rdar://problem/23958418
404
405         Reviewed by Darin Adler.
406
407         New member variable m_softSpaceRange keeps track to the NSRange of a soft 
408         space if the last text that was inserted has a soft space at the end.
409         * UIProcess/Cocoa/WebViewImpl.h:
410         * UIProcess/Cocoa/WebViewImpl.mm:
411         (WebKit::WebViewImpl::WebViewImpl):
412
413         The space at the end of candidates is a soft space. If that space exists, 
414         cache the range of the space in m_softSpaceRange.
415         (WebKit::WebViewImpl::handleAcceptedCandidate):
416
417         When new text is inserted, find out if it is being inserted right after a 
418         soft space. If it is, then [NSSpellChecker deletesAutospaceBeforeString] will 
419         tell us if the space needs to be removed. If that is the case, then set the 
420         replacementString to the soft space.
421         (WebKit::WebViewImpl::insertText):
422
423 2016-01-25  Daniel Bates  <dabates@apple.com>
424
425         WebKitTestRunner: Credential cache is not cleared between tests
426         https://bugs.webkit.org/show_bug.cgi?id=153407
427         <rdar://problem/24280834>
428
429         Reviewed by Brady Eidson.
430
431         Add SPI to call NetworkStorageSession::switchToNewTestingSession() to create a new testing session.
432         The new testing session will have an empty credential cache.
433
434         * NetworkProcess/NetworkProcess.cpp:
435         (WebKit::NetworkProcess::switchToNewTestingSession): Added.
436         * NetworkProcess/NetworkProcess.h:
437         * NetworkProcess/NetworkProcess.messages.in: Added message SwitchToNewTestingSession().
438         * UIProcess/API/C/WKContext.cpp:
439         (WKContextResetTestingNetworkSession): Added.
440         * UIProcess/API/C/WKContextPrivate.h:
441         * UIProcess/WebProcessPool.cpp:
442         (WebKit::WebProcessPool::resetTestingNetworkSession): Added.
443         * UIProcess/WebProcessPool.h:
444         * WebProcess/WebProcess.cpp:
445         (WebKit::WebProcess::switchToNewTestingSession): Added.
446         * WebProcess/WebProcess.h:
447         * WebProcess/WebProcess.messages.in: Added message SwitchToNewTestingSession().
448
449 2016-01-22  Ryosuke Niwa  <rniwa@webkit.org>
450
451         document.createElement should be able to create a custom element
452         https://bugs.webkit.org/show_bug.cgi?id=153173
453
454         Reviewed by Darin Adler.
455
456         Use createElementForBindings here since this is for SPI.
457
458         * WebProcess/InjectedBundle/API/mac/WKDOMDocument.mm:
459         (-[WKDOMDocument createElement:]):
460         (-[WKDOMDocument createTextNode:]):
461
462 2016-01-24  Alex Christensen  <achristensen@webkit.org>
463
464         Report upload progress to NetworkLoadClient when using NetworkSession
465         https://bugs.webkit.org/show_bug.cgi?id=153388
466
467         Reviewed by Darin Adler.
468
469         This fixes http/tests/xmlhttprequest/upload-onload-event.html and a few other tests.
470
471         * NetworkProcess/NetworkLoad.cpp:
472         (WebKit::NetworkLoad::didBecomeDownload):
473         (WebKit::NetworkLoad::didSendData):
474         (WebKit::NetworkLoad::didReceiveResponseAsync):
475         * NetworkProcess/NetworkLoad.h:
476         * NetworkProcess/NetworkSession.h:
477         (WebKit::NetworkSessionTaskClient::~NetworkSessionTaskClient):
478         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
479         (-[WKNetworkSessionDelegate initWithNetworkSession:]):
480         (-[WKNetworkSessionDelegate URLSession:task:didSendBodyData:totalBytesSent:totalBytesExpectedToSend:]):
481         (-[WKNetworkSessionDelegate URLSession:task:willPerformHTTPRedirection:newRequest:completionHandler:]):
482
483 2016-01-24  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
484
485         Reduce PassRefPtr uses in dom - 4
486         https://bugs.webkit.org/show_bug.cgi?id=153270
487
488         Reviewed by Darin Adler.
489
490         As a step to remove PassRefPtr uses, this patch reduces the uses in WebCore/dom.
491
492         * WebProcess/Plugins/PluginView.cpp:
493         (WebKit::PluginView::focusPluginElement):
494
495 2016-01-23  Alex Christensen  <achristensen@webkit.org>
496
497         CMake build fix after r195494.
498
499         * PlatformMac.cmake:
500         WebKit2 needs to be able to find DataDetectors.h.
501
502 2016-01-23  Alex Christensen  <achristensen@webkit.org>
503
504         Use credentials from a URL with NetworkSession like we did with ResourceHandle
505         https://bugs.webkit.org/show_bug.cgi?id=153328
506
507         Reviewed by Alexey Proskuryakov.
508
509         * NetworkProcess/NetworkLoad.cpp:
510         (WebKit::NetworkLoad::NetworkLoad):
511         createDataTaskWithRequest is being removed, so use std::make_unique<NetworkDataTask> directly instead.
512         Also, create the task even if we are deferring loading.  Don't call resume if we are deferring loading.
513         * NetworkProcess/NetworkSession.h:
514         Callbacks are not just used in NetworkSessionTaskClient, so declare them outside.
515         The NetworkDataTask now takes a ResourceRequest so we can strip its credentials.
516         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
517         (-[WKNetworkSessionDelegate URLSession:task:didReceiveChallenge:completionHandler:]):
518         Try credentials stored with the NetworkDataTask before asking the client for credentials.
519         (WebKit::NetworkSession::~NetworkSession):
520         (WebKit::NetworkSession::dataTaskForIdentifier):
521         (WebKit::NetworkSession::takeDownloadID):
522         (WebKit::NetworkDataTask::NetworkDataTask):
523         Strip the credentials from the url before creating the task because we do not know the authentication type.
524         We will use these credentials when a challenge is received.
525         (WebKit::NetworkDataTask::~NetworkDataTask):
526         (WebKit::NetworkDataTask::tryPasswordBasedAuthentication):
527         If we have credentials from the initial URL, try using them if it is appropriate.
528         (WebKit::NetworkDataTask::cancel):
529         (WebKit::NetworkSession::createDataTaskWithRequest): Deleted.
530         * Shared/Authentication/AuthenticationManager.h:
531
532 2016-01-22  Dan Bernstein  <mitz@apple.com>
533
534         <rdar://problem/24304228> REGRESSION (r184215): Staged XPC services load non-staged shims
535         https://bugs.webkit.org/show_bug.cgi?id=153389
536
537         Reviewed by Alexey Proskuryakov.
538
539         * Configurations/Shim.xcconfig: Don’t override the install name when using a staged install path.
540
541 2016-01-22  Enrica Casucci  <enrica@apple.com>
542
543         Add support for DataDetectors in WK (iOS).
544         https://bugs.webkit.org/show_bug.cgi?id=152989
545         rdar://problem/22855960
546
547         Reviewed by Tim Horton.
548
549         * UIProcess/API/Cocoa/WKWebView.mm:
550         (fromWKDataDetectorTypes): Changed parameter to uint64_t to
551         successfully compare against WKDataDetectorTypeAll.
552
553 2016-01-17  Ada Chan  <adachan@apple.com>
554
555         Add a mode parameter to MediaControllerInterface::supportsFullscreen() and ChromeClient::supportsVideoFullscreen().
556         https://bugs.webkit.org/show_bug.cgi?id=153220
557
558         Reviewed by Eric Carlson.
559
560         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
561         (WebKit::WebChromeClient::supportsVideoFullscreen):
562         * WebProcess/WebCoreSupport/WebChromeClient.h:
563
564 2016-01-22  Tim Horton  <timothy_horton@apple.com>
565
566         Reproducible "Unhanded web process message 'WebUserContentController:AddUserScripts'" and friends
567         https://bugs.webkit.org/show_bug.cgi?id=153193
568         <rdar://problem/24222034>
569
570         Reviewed by Darin Adler.
571
572         The WebPageProxy constructor assumes that if its WebProcess is already running,
573         it can add itself to the existing WebUserContentController(Proxy) and all will be well.
574
575         However, if the API client constructs a different WKUserContentController for two views,
576         and forces them both into the same process, WebPageProxy's constructor sends a message
577         with a WebUserContentController ID that doesn't exist yet on the WebProcess side
578         (because createWebPage, which usually brings it up, hasn't happened yet), and we 
579         drop the message on the floor (and get the aforementioned logging).
580
581         * UIProcess/WebPageProxy.cpp:
582         (WebKit::WebPageProxy::WebPageProxy):
583         (WebKit::WebPageProxy::initializeWebPageAfterProcessLaunch):
584         Instead of connecting our WebUserContentControllerProxy and WebVisitedLinkStoreProxy
585         to our WebProcessProxy in the constructor, when doing so might send messages
586         to the WebProcess that arrive before their corresponding WebProcess objects have
587         been created, do this in initializeWebPageAfterProcessLaunch, which always runs
588         during-or-after inititalizeWebPage (and always after the CreateWebPage message goes out).
589
590         (WebKit::WebPageProxy::initializeWebPage):
591         Mark us as needing initializeWebPageAfterProcessLaunch run, and run it right now
592         if the WebProcess is already up.
593         (WebKit::WebPageProxy::processDidFinishLaunching):
594         If the WebProcess wasn't up at the end of initializeWebPage, we'll eventually end up here
595         after it is launched, and will initializeWebPageAfterProcessLaunch.
596
597         (WebKit::WebPageProxy::resetStateAfterProcessExited):
598         If the WebProcess dies, we don't want to initializeWebPageAfterProcessLaunch
599         until after initializeWebPage runs again, so make sure the flag isn't set.
600
601         * UIProcess/WebPageProxy.h:
602
603 2016-01-22  Darin Adler  <darin@apple.com>
604
605         Reduce use of equalIgnoringCase to just ignore ASCII case
606         https://bugs.webkit.org/show_bug.cgi?id=153266
607
608         Reviewed by Ryosuke Niwa.
609
610         * UIProcess/PageLoadState.cpp:
611         (WebKit::PageLoadState::hasOnlySecureContent): Use the protocolIs
612         function from WebCore instead of calling startsWith.
613         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
614         (WebKit::NetscapePlugin::initialize): Use equalLettersIgnoringASCIICase.
615
616 2016-01-21  Brent Fulgham  <bfulgham@apple.com>
617
618         [Mac] Tooltips do not honor some types of obscuring windows
619         https://bugs.webkit.org/show_bug.cgi?id=153263
620         <rdar://problem/21423972>
621
622         Reviewed by Simon Fraser.
623
624         Recognize that the current WebView is obscured by comparing the current event's Window Number against
625         the Window Number of the current WebView. If they don't match, something is in the way.
626
627         * UIProcess/Cocoa/WebViewImpl.h:
628         * UIProcess/Cocoa/WebViewImpl.mm:
629         (WebKit::WebViewImpl::windowIsFrontWindowUnderMouse): Added.
630         * UIProcess/PageClient.h:
631         (WebKit::PageClient::windowIsFrontWindowUnderMouse):
632         * UIProcess/WebPageProxy.cpp:
633         (WebKit::WebPageProxy::handleMouseEvent): Check if the current WebView is obscured. If it
634         is, clear the tooltip and return.
635         * UIProcess/mac/PageClientImpl.h:
636         * UIProcess/mac/PageClientImpl.mm:
637         (WebKit::PageClientImpl::windowIsFrontWindowUnderMouse): Added.
638
639 2016-01-22  Youenn Fablet  <youenn.fablet@crf.canon.fr>
640
641         Remove PassRefPtr from ResourceRequest and FormData
642         https://bugs.webkit.org/show_bug.cgi?id=153229
643
644         Reviewed by Chris Dumez.
645
646         * NetworkProcess/NetworkResourceLoadParameters.cpp:
647         (WebKit::NetworkResourceLoadParameters::decode):
648         * NetworkProcess/cache/NetworkCacheEntry.cpp:
649         (WebKit::NetworkCache::Entry::Entry):
650
651 2016-01-21  Simon Fraser  <simon.fraser@apple.com>
652
653         REGRESSION (r168244): Content in horizontal-bt page is offset such that only the end is viewable and there is a white gap at the top
654         https://bugs.webkit.org/show_bug.cgi?id=136019
655
656         Reviewed by Dan Bernstein.
657
658         Now call frameView.positionForRootContentLayer(), and add a FIXME questioning the
659         behavior in horizontal b-t documents. However, this code isn't hit now that we always
660         do extended backgrounds, so never have shadow layers.
661
662         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
663         (WebKit::shadowLayerPositionForFrame):
664
665 2016-01-21  Dean Jackson  <dino@apple.com>
666
667         Move _allowsDoubleTapGestures implementation out of category
668         https://bugs.webkit.org/show_bug.cgi?id=153329
669         <rdar://problem/24289768>
670
671         Reviewed by Simon Fraser.
672
673         We were generating a linker warning because the implementation
674         was located inside the WKPrivate category.
675
676         * UIProcess/API/Cocoa/WKWebView.mm:
677         (-[WKWebView _allowsDoubleTapGestures]): Move this out of
678         the category.
679
680 2016-01-21  Dean Jackson  <dino@apple.com>
681
682         [iOS] Crash in _endPotentialTapAndEnableDoubleTapGesturesIfNecessary
683         https://bugs.webkit.org/show_bug.cgi?id=153326
684         <rdar://problem/24264339>
685
686         Reviewed by Anders Carlsson.
687
688         UIKit's UIGestureRecognizer could call back into the WKContentView
689         after the associated WKWebView has disappeared. The fix is to
690         explicitly null the WKWebView reference as we deallocate.
691
692         * UIProcess/API/Cocoa/WKWebView.mm:
693         (-[WKWebView dealloc]): Tell the WKContentView we are going away.
694         * UIProcess/ios/WKContentView.h:
695         * UIProcess/ios/WKContentView.mm:
696         (-[WKContentView _webViewDestroyed]):
697         * UIProcess/ios/WKContentViewInteraction.mm:
698         (-[WKContentView _endPotentialTapAndEnableDoubleTapGesturesIfNecessary]):
699         Only do something if the WKWebView is still around.
700
701 2016-01-21  Beth Dakin  <bdakin@apple.com>
702
703         Add the ability to update WebKitAdditions to WK2
704         https://bugs.webkit.org/show_bug.cgi?id=153320
705         -and corresponding-
706         rdar://problem/23639629
707
708         Reviewed by Anders Carlsson.
709
710         * UIProcess/API/Cocoa/WKWebView.mm:
711         * UIProcess/API/mac/WKView.mm:
712         * UIProcess/Cocoa/WebViewImpl.h:
713         (WebKit::WebViewImpl::createWeakPtr):
714         * UIProcess/Cocoa/WebViewImpl.mm:
715         (WebKit::WebViewImpl::updateWebViewImplAdditions):
716         (WebKit::WebViewImpl::showCandidates):
717         (WebKit::WebViewImpl::webViewImplAdditionsWillDestroyView):
718         (WebKit::trackingAreaOptions):
719         (WebKit::WebViewImpl::~WebViewImpl):
720         (WebKit::WebViewImpl::becomeFirstResponder):
721         (WebKit::WebViewImpl::selectionDidChange):
722         (WebKit::WebViewImpl::handleRequestedCandidates):
723         (WebKit::textCheckingResultFromNSTextCheckingResult):
724
725 2016-01-19  Ada Chan  <adachan@apple.com>
726
727         Make it possible to enable VIDEO_PRESENTATION_MODE on other Cocoa platforms.
728         https://bugs.webkit.org/show_bug.cgi?id=153218
729
730         Reviewed by Eric Carlson.
731
732         * Configurations/FeatureDefines.xcconfig:
733
734 2016-01-20  Alex Christensen  <achristensen@webkit.org>
735
736         Fix CMake build after r195300.
737
738         * PlatformMac.cmake:
739         Include editing/mac to find DataDetection.h.
740
741 2016-01-20  Alex Christensen  <achristensen@webkit.org>
742
743         Ask UI Process before sending redirect requests when downloading
744         https://bugs.webkit.org/show_bug.cgi?id=153041
745
746         Reviewed by Darin Adler.
747
748         * NetworkProcess/Downloads/DownloadManager.cpp:
749         (WebKit::DownloadManager::continueCanAuthenticateAgainstProtectionSpace):
750         (WebKit::DownloadManager::continueWillSendRequest):
751         (WebKit::DownloadManager::convertHandleToDownload):
752         * NetworkProcess/Downloads/DownloadManager.h:
753         * NetworkProcess/Downloads/PendingDownload.cpp:
754         (WebKit::PendingDownload::willSendRedirectedRequest):
755         (WebKit::PendingDownload::continueWillSendRequest):
756         * NetworkProcess/NetworkProcess.cpp:
757         (WebKit::NetworkProcess::continueCanAuthenticateAgainstProtectionSpace):
758         (WebKit::NetworkProcess::continueWillSendRequest):
759         (WebKit::NetworkProcess::setCacheModel):
760         * NetworkProcess/NetworkProcess.h:
761         * NetworkProcess/NetworkProcess.messages.in:
762         * UIProcess/API/APIDownloadClient.h:
763         (API::DownloadClient::didCancel):
764         (API::DownloadClient::processDidCrash):
765         (API::DownloadClient::canAuthenticateAgainstProtectionSpace):
766         (API::DownloadClient::willSendRequest):
767         * UIProcess/Downloads/DownloadProxy.cpp:
768         (WebKit::DownloadProxy::didReceiveAuthenticationChallenge):
769         (WebKit::DownloadProxy::canAuthenticateAgainstProtectionSpace):
770         (WebKit::DownloadProxy::willSendRequest):
771         (WebKit::DownloadProxy::didReceiveResponse):
772         * UIProcess/Downloads/DownloadProxy.h:
773         * UIProcess/Downloads/DownloadProxy.messages.in:
774
775 2016-01-20  Carlos Garcia Campos  <cgarcia@igalia.com>
776
777         Unreviewed. Update OptionsGTK.cmake and NEWS for 2.11.4 release.
778
779         * gtk/NEWS: Add release notes for 2.11.4.
780
781 2016-01-19  Enrica Casucci  <enrica@apple.com>
782
783         Add support for DataDetectors in WK (iOS).
784         https://bugs.webkit.org/show_bug.cgi?id=152989
785         rdar://problem/22855960
786
787         Reviewed by Tim Horton.
788
789         This is the first step toward implementing Data Detectors support
790         in WK2. The patch adds a new property to the configuration
791         object to indicate the type of detection desired and propagates
792         to the WebProcess.
793
794         * Configurations/FeatureDefines.xcconfig:
795         * Shared/WebPreferencesDefinitions.h:
796         * UIProcess/API/Cocoa/WKWebView.mm:
797         (fromWKDataDetectorTypes):
798         (-[WKWebView initWithFrame:configuration:]):
799         * UIProcess/API/Cocoa/WKWebViewConfiguration.h:
800         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
801         (-[WKWebViewConfiguration copyWithZone:]):
802         * WebProcess/WebPage/WebPage.cpp:
803         (WebKit::WebPage::updatePreferences):
804
805 2016-01-19  Commit Queue  <commit-queue@webkit.org>
806
807         Unreviewed, rolling out r195300.
808         https://bugs.webkit.org/show_bug.cgi?id=153244
809
810         enrica wants more time to fix Windows (Requested by thorton on
811         #webkit).
812
813         Reverted changeset:
814
815         "Add support for DataDetectors in WK (iOS)."
816         https://bugs.webkit.org/show_bug.cgi?id=152989
817         http://trac.webkit.org/changeset/195300
818
819 2016-01-19  Enrica Casucci  <enrica@apple.com>
820
821         Add support for DataDetectors in WK (iOS).
822         https://bugs.webkit.org/show_bug.cgi?id=152989
823         rdar://problem/22855960
824
825         Reviewed by Tim Horton.
826
827         This is the first step toward implementing Data Detectors support
828         in WK2. The patch adds a new property to the configuration
829         object to indicate the type of detection desired and propagates
830         to the WebProcess.
831
832         * Configurations/FeatureDefines.xcconfig:
833         * Shared/WebPreferencesDefinitions.h:
834         * UIProcess/API/Cocoa/WKWebView.mm:
835         (-[WKWebView initWithFrame:configuration:]):
836         * UIProcess/API/Cocoa/WKWebViewConfiguration.h:
837         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
838         (-[WKWebViewConfiguration copyWithZone:]):
839         * WebKit2.xcodeproj/project.pbxproj:
840         * WebProcess/WebPage/Cocoa/WebPageCocoa.mm: Added.
841         (WebKit::WebPage::fromWKDataDetectorTypes):
842         * WebProcess/WebPage/WebPage.cpp:
843         (WebKit::WebPage::updatePreferences):
844         * WebProcess/WebPage/WebPage.h:
845
846 2016-01-19  Commit Queue  <commit-queue@webkit.org>
847
848         Unreviewed, rolling out r187471.
849         https://bugs.webkit.org/show_bug.cgi?id=153236
850
851         purportedly caused a significant memory regression and want to
852         see if that is true (Requested by thorton on #webkit).
853
854         Reverted changeset:
855
856         "First in-window viewStateChange synchronously blocks despite
857         not previously being in-window"
858         https://bugs.webkit.org/show_bug.cgi?id=147344
859         http://trac.webkit.org/changeset/187471
860
861 2016-01-19  Carlos Garcia Campos  <cgarcia@igalia.com>
862
863         [GTK] Runtime critical warnings when loading a URL after a session restore
864         https://bugs.webkit.org/show_bug.cgi?id=153233
865
866         Reviewed by Michael Catanzaro.
867
868         This happens when doing a normal load after restoring the back
869         forward list from session state and the list contained forward
870         items. In that case the forward items are removed from the list
871         and we try to reference a WebBackForwardListItem wrapper that
872         hasn't been created. We create the wrappers on demand, and when
873         the back forward list is populated from session state, items are
874         added to the list without creating their wrappers. That was not
875         possible before, and that's why we assumed that any item that is
876         removed from the list should have a wrapper already created.
877
878         * UIProcess/API/gtk/WebKitBackForwardList.cpp:
879         (webkitBackForwardListChanged): If we don't have a wrapper for the
880         removed item, create a new one to be passed to the signal, but
881         without adding it to the map.
882
883 2016-01-19  Ryosuke Niwa  <rniwa@webkit.org>
884
885         CharacterData::setData doesn't need ExceptionCode as an out argument
886         https://bugs.webkit.org/show_bug.cgi?id=153225
887
888         Reviewed by Antti Koivisto.
889
890         * WebProcess/InjectedBundle/API/mac/WKDOMText.mm:
891         (-[WKDOMText setData:]):
892
893 2016-01-18  Ryuan Choi  <ryuan.choi@navercorp.com>
894
895         [EFL] Remove wkView() from EwkView
896         https://bugs.webkit.org/show_bug.cgi?id=152604
897
898         Reviewed by Gyuyoung Kim.
899
900         * UIProcess/API/efl/EwkView.cpp:
901         (EwkViewEventHandler<EVAS_CALLBACK_SHOW>::handleEvent):
902         (EwkViewEventHandler<EVAS_CALLBACK_HIDE>::handleEvent):
903         (EwkView::EwkView):
904         (EwkView::create):
905         (EwkView::wkPage):
906         (EwkView::isVisible):
907         (EwkView::setVisible):
908         (EwkView::setDeviceScaleFactor):
909         (EwkView::deviceSize):
910         (EwkView::displayTimerFired):
911         (EwkView::setViewportPosition):
912         (EwkView::requestExitFullScreen):
913         (EwkView::contentsSize):
914         (EwkView::setThemePath):
915         (EwkView::feedTouchEvent):
916         (EwkView::createGLSurface):
917         (EwkView::showContextMenu):
918         (EwkView::requestPopupMenu):
919         (EwkView::webView):
920         (EwkView::handleEvasObjectCalculate):
921         (EwkView::handleEvasObjectColorSet):
922         (EwkView::handleEwkViewFocusIn):
923         (EwkView::handleEwkViewFocusOut):
924         (EwkView::feedTouchEvents):
925         (EwkView::takeSnapshot):
926         (EwkView::scrollBy):
927         (EwkView::setBackgroundColor):
928         (EwkView::backgroundColor):
929         * UIProcess/API/efl/EwkView.h:
930         (EwkView::wkView): Deleted.
931         * UIProcess/API/efl/GestureRecognizer.cpp:
932         (WebKit::GestureHandler::handleSingleTap):
933         * UIProcess/API/efl/ewk_view.cpp:
934         (EWKViewCreate):
935         (EWKViewGetWKView):
936         (ewk_view_fullscreen_exit):
937         (ewk_view_layout_fixed_set):
938         (ewk_view_layout_fixed_get):
939         (ewk_view_layout_fixed_size_set):
940         (ewk_view_layout_fixed_size_get):
941         (ewk_view_bg_color_get):
942         (ewk_view_contents_size_get):
943         * UIProcess/efl/PageViewportControllerClientEfl.cpp:
944         (WebKit::PageViewportControllerClientEfl::setPageScaleFactor):
945         * UIProcess/efl/ViewClientEfl.cpp:
946         (WebKit::ViewClientEfl::webProcessDidRelaunch):
947         (WebKit::ViewClientEfl::ViewClientEfl):
948         (WebKit::ViewClientEfl::~ViewClientEfl):
949
950 2016-01-18  Zan Dobersek  <zdobersek@igalia.com>
951
952         Sink the Vector<uint8_t> buffer into the SerializedScriptValue constructor
953         https://bugs.webkit.org/show_bug.cgi?id=142634
954
955         Reviewed by Darin Adler.
956
957         Update API::SerializedScriptValue::adopt() to take in a Vector<uint8_t>
958         rvalue, moving it into the WebCore::SerializedScriptValue::adopt() call.
959
960         Update other places that are affected by the SerializedScriptValue changes.
961
962         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
963         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createIndex):
964         * Shared/API/APISerializedScriptValue.h:
965         (API::SerializedScriptValue::adopt):
966         * Shared/UserData.cpp:
967         (WebKit::UserData::decode):
968         * UIProcess/UserContent/WebUserContentControllerProxy.cpp:
969         (WebKit::WebUserContentControllerProxy::didPostMessage):
970         * UIProcess/WebPageProxy.cpp:
971         (WebKit::WebPageProxy::scriptValueCallback):
972         * WebProcess/WebCoreSupport/SessionStateConversion.cpp:
973         (WebKit::applyFrameState):
974
975 2016-01-18  Olivier Blin  <olivier.blin@softathome.com>
976
977         [EFL][GTK][WK2] Fix UIProcess build with GStreamer and without VIDEO
978         https://bugs.webkit.org/show_bug.cgi?id=153135
979
980         Reviewed by Michael Catanzaro.
981
982         GStreamer builds fail when WebAudio is enabled but VIDEO disabled.
983
984         This change makes the flag more consistent around the
985         decicePolicyForInstallMissingMediaPluginsPermissionRequest() method:
986         ENABLE(VIDEO) && USE(GSTREAMER) everywhere, while the code used to
987         test either one or the other.
988
989         This does not enable InstallMissingMediaPlugins for WebAudio, since no
990         code makes use of this in WebKitWebAudioSourceGStreamer.
991
992         It also fixes a naming typo for the following method:
993         decidePolicyForInstallMissingMediaPluginsPermissionRequest()
994
995         * UIProcess/API/gtk/PageClientImpl.cpp:
996         (WebKit::PageClientImpl::decidePolicyForInstallMissingMediaPluginsPermissionRequest):
997         * UIProcess/API/gtk/PageClientImpl.h:
998         * UIProcess/PageClient.h:
999         * UIProcess/efl/WebViewEfl.h:
1000         * UIProcess/gstreamer/WebPageProxyGStreamer.cpp:
1001         (WebKit::WebPageProxy::requestInstallMissingMediaPlugins):
1002
1003 2016-01-17  Jeremy Huddleston Sequoia  <jeremyhu@apple.com>
1004
1005         Add quotes around ${CMAKE_SHARED_LINKER_FLAGS} in case it is unset
1006         https://bugs.webkit.org/show_bug.cgi?id=153175
1007
1008         Reviewed by Michael Catanzaro.
1009
1010         * PlatformGTK.cmake:
1011
1012 2016-01-16  Jeremy Huddleston Sequoia  <jeremyhu@apple.com>
1013
1014         Remove a now-irrelevant darwin build hack
1015         https://bugs.webkit.org/show_bug.cgi?id=153117
1016
1017         Reviewed by Michael Catanzaro.
1018
1019         * PlatformGTK.cmake:
1020
1021 2016-01-16  Jon Honeycutt  <jhoneycutt@apple.com>
1022
1023         [iOS] Replace deprecated -[UIDocumentMenuViewController
1024         _setIgnoreApplicationEntitlementForImport:]
1025
1026         <https://bugs.webkit.org/show_bug.cgi?id=145690>
1027         <rdar://problem/20636577>
1028
1029         Reviewed by Brent Fulgham.
1030
1031         * Platform/spi/ios/UIKitSPI.h:
1032         Replace deprecated SPI with newer SPI.
1033
1034         * UIProcess/ios/forms/WKFileUploadPanel.mm:
1035         (-[WKFileUploadPanel presentWithParameters:resultListener:]):
1036         (-[WKFileUploadPanel _showDocumentPickerMenu]):
1037         Ditto.
1038
1039 2016-01-16  Michael Catanzaro  <mcatanzaro@igalia.com>
1040
1041         [GTK] Unreviewed. Fix a typo in an API comment.
1042
1043         * UIProcess/API/gtk/WebKitWebViewSessionState.cpp:
1044
1045 2016-01-16  Carlos Garcia Campos  <cgarcia@igalia.com>
1046
1047         [GTK] GVariant runtime critical errors when encoding session data
1048         https://bugs.webkit.org/show_bug.cgi?id=153130
1049
1050         Reviewed by Michael Catanzaro.
1051
1052         It happens when the FrameState has children, because the recursive
1053         serialization is wrong. Also fix serialization of
1054         documentSequenceNumber and itemSequenceNumber that are gint64, not
1055         guint64.
1056
1057         * UIProcess/API/gtk/WebKitWebViewSessionState.cpp:
1058         (encodeFrameState): Let the caller open/init the given
1059         builder. Use a new builder to encode child states recursively.
1060         (encodePageState): Do the builder open/close for the FrameState encoding.
1061         (decodeFrameState): Get the variant of every child.
1062
1063 2016-01-15  Michael Catanzaro  <mcatanzaro@igalia.com>
1064
1065         Fix internal Windows build
1066         https://bugs.webkit.org/show_bug.cgi?id=153142
1067
1068         Unreviewed addition to Alex's JSC patch, which was reviewed by Brent Fulgham. Pass
1069         -I${JAVASCRIPTCORE_DIR} to g-ir-scanner.
1070
1071         * PlatformGTK.cmake:
1072
1073 2016-01-14  Simon Fraser  <simon.fraser@apple.com>
1074
1075         Remove workaround for rdar://problem/23623670
1076         https://bugs.webkit.org/show_bug.cgi?id=153107
1077         rdar://problem/23633319
1078
1079         Reviewed by Tim Horton.
1080
1081         Remove the code that uses IOSurfaceAcceleratorTransformSurface() when copying from
1082         back-to-front buffer, now that CGIOSurfaceContextCreate()-code path works correctly.
1083
1084         * Shared/mac/RemoteLayerBackingStore.mm:
1085         (WebKit::RemoteLayerBackingStore::display):
1086
1087 2016-01-14  Beth Dakin  <bdakin@apple.com>
1088
1089         WK1 and WK2 should share more candidate request code
1090         https://bugs.webkit.org/show_bug.cgi?id=153108
1091
1092         Reviewed by Simon Fraser.
1093
1094         requestCandidatesForSelection() does not need to be exposed as an 
1095         EditorClient function. WK1 can just call invoke this code from the existing 
1096         respondToChangedSelection EditorClient function, which is what WK2 does.
1097         * WebProcess/WebCoreSupport/WebEditorClient.h:
1098
1099 2016-01-14  Beth Dakin  <bdakin@apple.com>
1100
1101         WK2: Request completion candidates when needed
1102         https://bugs.webkit.org/show_bug.cgi?id=153040
1103         -and corresponding-
1104         rdar://problem/24155631
1105
1106         Reviewed by Enrica Casucci and Tim Horton.
1107
1108         Mac needs to support postLayoutData in order to have some layout-related 
1109         editing information to request candidates. This patch re-shuffles some items 
1110         in the struct so that they can be shared by Mac and iOS, and it adds 3 new 
1111         items for Mac only.
1112         * Shared/EditorState.cpp:
1113         (WebKit::EditorState::encode):
1114         (WebKit::EditorState::decode):
1115         (WebKit::EditorState::PostLayoutData::encode):
1116         (WebKit::EditorState::PostLayoutData::decode):
1117         * Shared/EditorState.h:
1118
1119         Request and handle candidates here in WebViewImpl, and cache the 
1120         m_lastStringForCandidateRequest so that we can ensure the results we receive 
1121         were received in a timely enough manner that they are still for the same 
1122         String.
1123         * UIProcess/Cocoa/WebViewImpl.h:
1124         * UIProcess/Cocoa/WebViewImpl.mm:
1125         (WebKit::WebViewImpl::selectionDidChange):
1126
1127         When selection changes, request new candidates.
1128         (WebKit::WebViewImpl::requestCandidatesForSelectionIfNeeded):
1129
1130         Once candidates have been received, we ask the sharedSpellChecker to show 
1131         them.
1132         (WebKit::WebViewImpl::handleRequestedCandidates):
1133
1134         If a candidate is accepted, we ask the WebProcess to accept it, so we start 
1135         by converting the NSTextCheckingResult to a WebCore::TextCheckingResult.
1136         (WebKit::textCheckingResultFromNSTextCheckingResult):
1137         (WebKit::WebViewImpl::handleAcceptedCandidate):
1138
1139         Ask the WebProcess to handle accepting the candidate.
1140         * UIProcess/WebPageProxy.cpp:
1141         (WebKit::WebPageProxy::handleAcceptedCandidate):
1142         * UIProcess/WebPageProxy.h:
1143         * WebProcess/WebPage/WebPage.h:
1144         (WebKit::WebPage:: handleAcceptedCandidate):
1145         * WebProcess/WebPage/WebPage.messages.in:
1146
1147         Now that Mac has some postLayoutData in the EditorState, fill that in in 
1148         platformEditorState().
1149         * WebProcess/WebPage/mac/WebPageMac.mm:
1150         (WebKit::WebPage::platformEditorState):
1151
1152         Ask WebCore::Editor to handle the accepted candidate.
1153         (WebKit::WebPage::handleAcceptedCandidate):
1154
1155 2016-01-14  Commit Queue  <commit-queue@webkit.org>
1156
1157         Unreviewed, rolling out r195002.
1158         https://bugs.webkit.org/show_bug.cgi?id=153098
1159
1160         Crashes many/most editing tests (Requested by ap on #webkit).
1161
1162         Reverted changeset:
1163
1164         "WK2: Request completion candidates when needed"
1165         https://bugs.webkit.org/show_bug.cgi?id=153040
1166         http://trac.webkit.org/changeset/195002
1167
1168 2016-01-14  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1169
1170         [EFL][GTK][SeccompFilter] Fix build break when enabling --seccomp-filters
1171         https://bugs.webkit.org/show_bug.cgi?id=153094
1172
1173         Reviewed by Csaba Osztrogonác.
1174
1175         diskCacheDirectory and cookiePersistentStoragePath were removed by r192796.
1176         But SyscallPolicy::addDefaultWebProcessPolicy has added directory permission
1177         to the removed paths.
1178
1179         It looks two paths needs to be handled by network process.
1180
1181         * Shared/linux/SeccompFilters/SyscallPolicy.cpp:
1182         (WebKit::SyscallPolicy::addDefaultWebProcessPolicy): Deleted.
1183
1184 2016-01-13  Alex Christensen  <achristensen@webkit.org>
1185
1186         Implement custom protocols when using NetworkSession
1187         https://bugs.webkit.org/show_bug.cgi?id=153078
1188
1189         Reviewed by Andy Estes.
1190
1191         * NetworkProcess/CustomProtocols/Cocoa/CustomProtocolManagerCocoa.mm:
1192         (WebKit::generateCustomProtocolID):
1193         (+[WKCustomProtocol canInitWithRequest:]):
1194         (+[WKCustomProtocol canonicalRequestForRequest:]):
1195         (-[WKCustomProtocol initWithRequest:cachedResponse:client:]):
1196         (-[WKCustomProtocol startLoading]):
1197         (-[WKCustomProtocol stopLoading]):
1198         There's no need to have a static pointer when we can use NetworkProcess::singleton to access 
1199         the process-global CustomProtocolManager, and add null checks because that's a good thing to do.
1200         (WebKit::CustomProtocolManager::CustomProtocolManager):
1201         Call UTF8Encoding when creating the CustomProtocolManager on the main thread to make sure it exists
1202         for when we decode URLS in ResourceResponses from IPC later, which is done on a different WorkQueue.
1203         (WebKit::CustomProtocolManager::initializeConnection):
1204         (WebKit::CustomProtocolManager::initialize):
1205         (WebKit::CustomProtocolManager::removeCustomProtocol):
1206         (WebKit::CustomProtocolManager::registerProtocolClass):
1207         (WebKit::CustomProtocolManager::registerScheme):
1208         * NetworkProcess/CustomProtocols/CustomProtocolManager.h:
1209         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
1210         (WebKit::NetworkSession::NetworkSession):
1211         Call registerProtocolClass to set configuration.protocolClasses if there is a CustomProtocolManager.
1212
1213 2016-01-13  Beth Dakin  <bdakin@apple.com>
1214
1215         WK2: Request completion candidates when needed
1216         https://bugs.webkit.org/show_bug.cgi?id=153040
1217         -and corresponding-
1218         rdar://problem/24155631
1219
1220         Reviewed by Enrica Casucci.
1221
1222         Mac needs to support postLayoutData in order to have some layout-related 
1223         editing information to request candidates. This patch re-shuffles some items 
1224         in the struct so that they can be shared by Mac and iOS, and it adds 3 new 
1225         items for Mac only.
1226         * Shared/EditorState.cpp:
1227         (WebKit::EditorState::encode):
1228         (WebKit::EditorState::decode):
1229         (WebKit::EditorState::PostLayoutData::encode):
1230         (WebKit::EditorState::PostLayoutData::decode):
1231         * Shared/EditorState.h:
1232
1233         Request and handle candidates here in WebViewImpl, and cache the 
1234         m_lastStringForCandidateRequest so that we can ensure the results we receive 
1235         were received in a timely enough manner that they are still for the same 
1236         String.
1237         * UIProcess/Cocoa/WebViewImpl.h:
1238         * UIProcess/Cocoa/WebViewImpl.mm:
1239         (WebKit::WebViewImpl::selectionDidChange):
1240
1241         When selection changes, request new candidates.
1242         (WebKit::WebViewImpl::requestCandidatesForSelectionIfNeeded):
1243
1244         Once candidates have been received, we ask the sharedSpellChecker to show 
1245         them.
1246         (WebKit::WebViewImpl::handleRequestedCandidates):
1247
1248         If a candidate is accepted, we ask the WebProcess to accept it, so we start 
1249         by converting the NSTextCheckingResult to a WebCore::TextCheckingResult.
1250         (WebKit::textCheckingResultFromNSTextCheckingResult):
1251         (WebKit::WebViewImpl::handleAcceptedCandidate):
1252
1253         Ask the WebProcess to handle accepting the candidate.
1254         * UIProcess/WebPageProxy.cpp:
1255         (WebKit::WebPageProxy::handleAcceptedCandidate):
1256         * UIProcess/WebPageProxy.h:
1257         * WebProcess/WebPage/WebPage.h:
1258         (WebKit::WebPage:: handleAcceptedCandidate):
1259         * WebProcess/WebPage/WebPage.messages.in:
1260
1261         Now that Mac has some postLayoutData in the EditorState, fill that in in 
1262         platformEditorState().
1263         * WebProcess/WebPage/mac/WebPageMac.mm:
1264         (WebKit::WebPage::platformEditorState):
1265
1266         Ask WebCore::Editor to handle the accepted candidate.
1267         (WebKit::WebPage::handleAcceptedCandidate):
1268
1269 2016-01-12  Geoffrey Garen  <ggaren@apple.com>
1270
1271         WebKit2 should have an API for eagerly querying whether the web process is responsive
1272         https://bugs.webkit.org/show_bug.cgi?id=153037
1273
1274         Reviewed by Tim Horton.
1275
1276         WebKit2 provides a delegate notification when the web process doesn't
1277         respond to a message after a while. But there's no way to send a message
1278         eagerly and check for reply.
1279
1280         We want this new mechanism so that navigation can terminate the web
1281         process eagerly if it is hung.
1282
1283         * UIProcess/API/C/WKPage.cpp:
1284         (WKPageGetWebProcessIsResponsive):
1285         * UIProcess/API/C/WKPagePrivate.h: This is the new API.
1286
1287         * UIProcess/WebPageProxy.cpp:
1288         (WebKit::WebPageProxy::sendWheelEvent): Updated for interface change.
1289
1290         (WebKit::WebPageProxy::getWebProcessIsResponsive): Calls through to the
1291         web process proxy. We claim that we are responsive when there is no
1292         web process because we assume that a fresh web process will not hang.
1293
1294         * UIProcess/WebPageProxy.h:
1295
1296         * UIProcess/WebProcessProxy.cpp:
1297         (WebKit::WebProcessProxy::WebProcessProxy):
1298         (WebKit::WebProcessProxy::didBecomeUnresponsive): Keep a flag indicating
1299         whether the process is unresponsive so that we can fire unresponsiveness
1300         callbacks immediately for a hung process instead of waiting another 3s.
1301
1302         (WebKit::WebProcessProxy::didBecomeResponsive): We don't fire responsiveness
1303         callbacks inside didBecomeResponsive because we assume that a responsive
1304         web process will invoke didReceiveMainThreadPing -- and we fire the
1305         callbacks there.
1306
1307         (WebKit::WebProcessProxy::getIsResponsive): If the web process is already
1308         known to be unresponsive, fire the callback right away. Otherwise, queue
1309         it up to fire once we have an answer from a main thread ping.
1310
1311         (WebKit::WebProcessProxy::didReceiveMainThreadPing): Fire any pending
1312         callbacks when we learn that the web process is responsive.
1313
1314         * UIProcess/WebProcessProxy.h:
1315
1316 2016-01-12  Carlos Garcia Campos  <cgarcia@igalia.com>
1317
1318         Unreviewed. Update OptionsGTK.cmake and NEWS for 2.11.3 release.
1319
1320         * gtk/NEWS: Add release notes for 2.11.3.
1321
1322 2016-01-12  Geoffrey Garen  <ggaren@apple.com>
1323
1324         WebPageProxy should reattach to the web process before navigating
1325         https://bugs.webkit.org/show_bug.cgi?id=153026
1326
1327         Reviewed by Anders Carlsson.
1328
1329         This fixes a crash (and lots of other corruption) when force-quitting
1330         the web process during navigation.
1331
1332         Some objects (like ViewGestureController) use one-time initialization
1333         to point to a ChildProcessProxy -- and, by design, we destroy them when
1334         the ChildProcessProxy becomes invalid (i.e., crashes or quits).
1335
1336         If we navigate *before* creating a new, valid ChildProcessProxy, then
1337         we accidentally re-create these objects pointing to the old, invalid
1338         ChildProcessProxy.
1339
1340         We need to wait until we have a valid ChildProcessProxy before we
1341         initialize these objects.
1342
1343         * UIProcess/WebPageProxy.cpp:
1344         (WebKit::WebPageProxy::reattachToWebProcessWithItem): Navigate after
1345         reattaching to the web process so that lazily allocated helper objects
1346         point to the right ChildProcessProxy.
1347
1348 2016-01-12  Ryosuke Niwa  <rniwa@webkit.org>
1349
1350         Add a build flag for custom element
1351         https://bugs.webkit.org/show_bug.cgi?id=153005
1352
1353         Reviewed by Alex Christensen.
1354
1355         * Configurations/FeatureDefines.xcconfig:
1356
1357 2016-01-12  Alex Christensen  <achristensen@webkit.org>
1358
1359         Ask for UI Process approval of ProtectionSpace when authenticating downloads with NetworkSession
1360         https://bugs.webkit.org/show_bug.cgi?id=152999
1361
1362         Reviewed by Brady Eidson.
1363
1364         * DerivedSources.make:
1365         I mistakenly added PendingDownload.messages.in in r194810, but this will not be needed because
1366         the PendingDownload is not a MessageReceiver.  Rather, the NetworkProcess receives the messages
1367         and forwards their contents to the PendingDownload through its DownloadManager.
1368         * NetworkProcess/Downloads/DownloadManager.cpp:
1369         (WebKit::DownloadManager::dataTaskBecameDownloadTask):
1370         (WebKit::DownloadManager::continueCanAuthenticateAgainstProtectionSpace):
1371         (WebKit::DownloadManager::convertHandleToDownload):
1372         * NetworkProcess/Downloads/DownloadManager.h:
1373         * NetworkProcess/Downloads/PendingDownload.cpp:
1374         (WebKit::PendingDownload::continueWillSendRequest):
1375         (WebKit::PendingDownload::canAuthenticateAgainstProtectionSpaceAsync):
1376         Instead of taking a shortcut I added in r194810, send a message to the UI process and wait for its
1377         asynchronous reply to determine if we can authenticate against this protection space.
1378         (WebKit::PendingDownload::continueCanAuthenticateAgainstProtectionSpace):
1379         (WebKit::PendingDownload::didConvertToDownload):
1380         * NetworkProcess/Downloads/PendingDownload.h:
1381         * NetworkProcess/Downloads/PendingDownload.messages.in: Removed.
1382         * NetworkProcess/NetworkProcess.cpp:
1383         (WebKit::NetworkProcess::cancelDownload):
1384         (WebKit::NetworkProcess::continueCanAuthenticateAgainstProtectionSpace):
1385         (WebKit::NetworkProcess::setCacheModel):
1386         * NetworkProcess/NetworkProcess.h:
1387         * NetworkProcess/NetworkProcess.messages.in:
1388         * Shared/Authentication/AuthenticationManager.h:
1389         * UIProcess/API/APIDownloadClient.h:
1390         (API::DownloadClient::didFail):
1391         (API::DownloadClient::didCancel):
1392         (API::DownloadClient::processDidCrash):
1393         (API::DownloadClient::canAuthenticateAgainstProtectionSpace):
1394         * UIProcess/Downloads/DownloadProxy.cpp:
1395         (WebKit::DownloadProxy::didReceiveAuthenticationChallenge):
1396         (WebKit::DownloadProxy::canAuthenticateAgainstProtectionSpace):
1397         (WebKit::DownloadProxy::didReceiveResponse):
1398         * UIProcess/Downloads/DownloadProxy.h:
1399         * UIProcess/Downloads/DownloadProxy.messages.in:
1400         * WebKit2.xcodeproj/project.pbxproj:
1401
1402 2016-01-12  Carlos Garcia Campos  <cgarcia@igalia.com>
1403
1404         Move ChildProcessProxy from Shared to UIProcess
1405         https://bugs.webkit.org/show_bug.cgi?id=125570
1406
1407         Reviewed by Darin Adler.
1408
1409         ChildProcessProxy is only used by the UI process.
1410
1411         * CMakeLists.txt:
1412         * PlatformGTK.cmake:
1413         * UIProcess/ChildProcessProxy.cpp: Renamed from Source/WebKit2/Shared/ChildProcessProxy.cpp.
1414         (WebKit::ChildProcessProxy::ChildProcessProxy):
1415         (WebKit::ChildProcessProxy::~ChildProcessProxy):
1416         (WebKit::ChildProcessProxy::fromConnection):
1417         (WebKit::ChildProcessProxy::getLaunchOptions):
1418         (WebKit::ChildProcessProxy::connect):
1419         (WebKit::ChildProcessProxy::terminate):
1420         (WebKit::ChildProcessProxy::state):
1421         (WebKit::ChildProcessProxy::sendMessage):
1422         (WebKit::ChildProcessProxy::addMessageReceiver):
1423         (WebKit::ChildProcessProxy::removeMessageReceiver):
1424         (WebKit::ChildProcessProxy::dispatchMessage):
1425         (WebKit::ChildProcessProxy::dispatchSyncMessage):
1426         (WebKit::ChildProcessProxy::didFinishLaunching):
1427         (WebKit::ChildProcessProxy::shutDownProcess):
1428         (WebKit::ChildProcessProxy::connectionWillOpen):
1429         * UIProcess/ChildProcessProxy.h: Renamed from Source/WebKit2/Shared/ChildProcessProxy.h.
1430         (WebKit::ChildProcessProxy::connection):
1431         (WebKit::ChildProcessProxy::processIdentifier):
1432         (WebKit::ChildProcessProxy::canSendMessage):
1433         (WebKit::ChildProcessProxy::send):
1434         (WebKit::ChildProcessProxy::sendSync):
1435         * WebKit2.xcodeproj/project.pbxproj:
1436
1437 2016-01-12  Carlos Garcia Campos  <cgarcia@igalia.com>
1438
1439         [GTK] UI process crashes if webkit_web_view_get_tls_info is called before internal load-committed event
1440         https://bugs.webkit.org/show_bug.cgi?id=142375
1441
1442         Reviewed by Michael Catanzaro.
1443
1444         Remove all the hacks to emit delayed load events now that the
1445         page cache resource load delegates are consistent with all other
1446         resource loads.
1447
1448         * UIProcess/API/gtk/WebKitWebView.cpp:
1449         (webkitWebViewLoadChanged):
1450         (webkitWebViewResourceLoadStarted):
1451         (webkit_web_view_get_tls_info): Add a g_return_val_if_fail to
1452         prevent this function from being misused.
1453         (webkitWebViewDisconnectMainResourceResponseChangedSignalHandler): Deleted.
1454         (webkitWebViewDispose): Deleted.
1455         (webkitWebViewEmitLoadChanged): Deleted.
1456         (webkitWebViewEmitDelayedLoadEvents): Deleted.
1457         (mainResourceResponseChangedCallback): Deleted.
1458         (waitForMainResourceResponseIfWaitingForResource): Deleted.
1459
1460 2016-01-11  Carlos Garcia Campos  <cgarcia@igalia.com>
1461
1462         REGRESSION(r190717): [GTK] Popup menus stop working after being dismissed without selecting an item
1463         https://bugs.webkit.org/show_bug.cgi?id=152977
1464
1465         Reviewed by Michael Catanzaro.
1466
1467         This happens since r190717 when you open a popup menu and without
1468         selecting any option it's dismissed (press ESC or click somewhere
1469         else). This is because I removed the code to track when the menu
1470         is unmapped, thinking that it was no longer necessary. But we need
1471         to send the DidChangeSelectedIndexForActivePopupMenu to the
1472         WebProcess with -1 as index to keep the web process in sync.
1473
1474         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
1475         (WebKit::WebPopupMenuProxyGtk::WebPopupMenuProxyGtk):
1476         (WebKit::WebPopupMenuProxyGtk::showPopupMenu):
1477         (WebKit::WebPopupMenuProxyGtk::cancelTracking):
1478         (WebKit::WebPopupMenuProxyGtk::menuItemActivated):
1479         (WebKit::WebPopupMenuProxyGtk::dismissMenuTimerFired):
1480         (WebKit::WebPopupMenuProxyGtk::menuUnmappedCallback):
1481         * UIProcess/gtk/WebPopupMenuProxyGtk.h:
1482
1483 2016-01-09  Andy Estes  <aestes@apple.com>
1484
1485         [Cocoa] Add SPI to opt out a URL scheme from the memory cache
1486         https://bugs.webkit.org/show_bug.cgi?id=152950
1487         rdar://problem/24066652
1488
1489         Reviewed by Tim Horton.
1490
1491         Added a alwaysRevalidatedURLSchemes property to _WKProcessPoolConfiguration. Taught WebProcess to add these
1492         schemes to SchemeRegistry when initializing a new web process.
1493
1494         * Shared/API/Cocoa/WKFoundation.h: Added a newline to force re-postprocessing.
1495         * Shared/WebProcessCreationParameters.cpp:
1496         (WebKit::WebProcessCreationParameters::encode):
1497         (WebKit::WebProcessCreationParameters::decode):
1498         * Shared/WebProcessCreationParameters.h:
1499         * UIProcess/API/APIProcessPoolConfiguration.cpp:
1500         (API::ProcessPoolConfiguration::copy):
1501         * UIProcess/API/APIProcessPoolConfiguration.h:
1502         * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.h:
1503         * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm:
1504         (-[_WKProcessPoolConfiguration alwaysRevalidatedURLSchemes]):
1505         (-[_WKProcessPoolConfiguration setAlwaysRevalidatedURLSchemes:]):
1506         * UIProcess/WebProcessPool.cpp:
1507         (WebKit::WebProcessPool::createNewWebProcess):
1508         * UIProcess/WebProcessPool.h:
1509         * WebProcess/WebProcess.cpp:
1510         (WebKit::WebProcess::initializeWebProcess):
1511         (WebKit::WebProcess::registerURLSchemeAsAlwaysRevalidated):
1512         * WebProcess/WebProcess.h:
1513
1514 2016-01-11  Anders Carlsson  <andersca@apple.com>
1515
1516         Get rid of CFMakeCollectable, it is a no-op
1517         https://bugs.webkit.org/show_bug.cgi?id=152988
1518
1519         Reviewed by Sam Weinig.
1520
1521         * Shared/Cocoa/WKNSString.mm:
1522         * Shared/Cocoa/WKNSURL.mm:
1523         (-[WKNSURL _web_createTarget]):
1524
1525 2016-01-11  Commit Queue  <commit-queue@webkit.org>
1526
1527         Unreviewed, rolling out r194866.
1528         https://bugs.webkit.org/show_bug.cgi?id=152986
1529
1530         This change broke the mac build (Requested by ryanhaddad on
1531         #webkit).
1532
1533         Reverted changeset:
1534
1535         "[Cocoa] Add SPI to opt out a URL scheme from the memory
1536         cache"
1537         https://bugs.webkit.org/show_bug.cgi?id=152950
1538         http://trac.webkit.org/changeset/194866
1539
1540 2016-01-11  Andy Estes  <aestes@apple.com>
1541
1542         [Cocoa] Add SPI to opt out a URL scheme from the memory cache
1543         https://bugs.webkit.org/show_bug.cgi?id=152950
1544         rdar://problem/24066652
1545
1546         Reviewed by Tim Horton.
1547
1548         Added a alwaysRevalidatedURLSchemes property to _WKProcessPoolConfiguration. Taught WebProcess to add these
1549         schemes to SchemeRegistry when initializing a new web process.
1550
1551         * Shared/WebProcessCreationParameters.cpp:
1552         (WebKit::WebProcessCreationParameters::encode):
1553         (WebKit::WebProcessCreationParameters::decode):
1554         * Shared/WebProcessCreationParameters.h:
1555         * UIProcess/API/APIProcessPoolConfiguration.cpp:
1556         (API::ProcessPoolConfiguration::copy):
1557         * UIProcess/API/APIProcessPoolConfiguration.h:
1558         * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.h:
1559         * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm:
1560         (-[_WKProcessPoolConfiguration alwaysRevalidatedURLSchemes]):
1561         (-[_WKProcessPoolConfiguration setAlwaysRevalidatedURLSchemes:]):
1562         * UIProcess/WebProcessPool.cpp:
1563         (WebKit::WebProcessPool::createNewWebProcess):
1564         * UIProcess/WebProcessPool.h:
1565         * WebProcess/WebProcess.cpp:
1566         (WebKit::WebProcess::initializeWebProcess):
1567         (WebKit::WebProcess::registerURLSchemeAsAlwaysRevalidated):
1568         * WebProcess/WebProcess.h:
1569
1570 2016-01-11  Alex Christensen  <achristensen@webkit.org>
1571
1572         Fix Mac CMake build after r194810.
1573
1574         * PlatformMac.cmake:
1575         PendingDownload isn't needed until NETWORK_SESSION is used by default.
1576         I'll figure this out when I make the switch.
1577
1578 2016-01-11  Mario Sanchez Prada  <mario@endlessm.com>
1579
1580         [WK2][GTK] Propagate motion-notify-event signals from the WebView
1581         https://bugs.webkit.org/show_bug.cgi?id=152974
1582
1583         Reviewed by Carlos Garcia Campos.
1584
1585         Always propagate motion-notify-event signals, regardless of what the
1586         web process does, so that we can listen for those events (which does
1587         not act on specific targets inside the webview) from the container
1588         widget too, and not just from the WebView itself.
1589
1590         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1591         (webkitWebViewBaseMotionNotifyEvent): Ensure the signal gets propagated.
1592
1593 2016-01-10  Dan Bernstein  <mitz@apple.com>
1594
1595         [Cocoa] Disable header postprocessing when building for El Capitan
1596         https://bugs.webkit.org/show_bug.cgi?id=152962
1597
1598         Reviewed by Anders Carlsson.
1599
1600         * Configurations/WebKit.xcconfig:
1601
1602 2016-01-09  Dan Bernstein  <mitz@apple.com>
1603
1604         [Cocoa] Allow overriding the frameworks directory independently of using a staging install path
1605         https://bugs.webkit.org/show_bug.cgi?id=152926
1606
1607         Reviewed by Tim Horton.
1608
1609         Introduce a new build setting, WK_OVERRIDE_FRAMEWORKS_DIR. When not empty, it determines
1610         where the frameworks are installed. Setting USE_STAGING_INSTALL_PATH to YES sets
1611         WK_OVERRIDE_FRAMEWORKS_DIR to $(SYSTEM_LIBRARY_DIR)/StagedFrameworks/Safari.
1612
1613         Account for the possibility of WK_OVERRIDE_FRAMEWORKS_DIR containing spaces.
1614
1615         * Configurations/BaseTarget.xcconfig:
1616         - Add quotes to account for spaces.
1617         - Define WEBKIT_FRAMEWORKS_DIR and UMBRELLA_FRAMEWORKS_DIR based on
1618           WK_OVERRIDE_FRAMEWORKS_DIR.
1619
1620         * WebKit2.xcodeproj/project.pbxproj:
1621         - In the Migrate WebKitLegacy Headers build phase, work around make’s inability to handle
1622           spaces in paths by creating a symlink to WEBKIT_LEGACY_PRIVATE_HEADERS_DIR under
1623           BUILT_PRODUCTS_DIR and using the symlink as the value of
1624           WEBKIT_LEGACY_PRIVATE_HEADERS_DIR.
1625         - In the Postprocess WKBase.h and Postprocess WKFoundation.h build phases, add quotes to
1626           account for spaces.
1627
1628         * mac/MigrateHeadersFromWebKitLegacy.make:
1629           Use a BUILT_PRODUCTS_DIR-based path to the framework instead of a TARGET_BUILD_DIR-based
1630           one in order to avoid spaces.
1631
1632         * mac/postprocess-framework-headers.sh:
1633           Add quotes to account for spaces.
1634
1635 2016-01-08  Alex Christensen  <achristensen@webkit.org>
1636
1637         Implement download authentication with NetworkSession
1638         https://bugs.webkit.org/show_bug.cgi?id=152878
1639
1640         Reviewed by Brady Eidson.
1641
1642         * DerivedSources.make:
1643         * NetworkProcess/Downloads/Download.h:
1644         * NetworkProcess/Downloads/DownloadManager.cpp:
1645         (WebKit::DownloadManager::startDownload):
1646         * NetworkProcess/Downloads/PendingDownload.cpp: Added.
1647         (WebKit::PendingDownload::PendingDownload):
1648         (WebKit::PendingDownload::willSendRedirectedRequest):
1649         (WebKit::PendingDownload::continueWillSendRequest):
1650         (WebKit::PendingDownload::canAuthenticateAgainstProtectionSpaceAsync):
1651         (WebKit::PendingDownload::continueCanAuthenticateAgainstProtectionSpace):
1652         (WebKit::PendingDownload::didConvertToDownload):
1653         (WebKit::PendingDownload::messageSenderConnection):
1654         (WebKit::PendingDownload::messageSenderDestinationID):
1655         * NetworkProcess/Downloads/PendingDownload.h:
1656         (WebKit::PendingDownload::PendingDownload): Deleted.
1657         * NetworkProcess/Downloads/PendingDownload.messages.in: Added.
1658         * NetworkProcess/NetworkLoad.cpp:
1659         (WebKit::NetworkLoad::continueWillSendRequest):
1660         The completion handler should always be called.  If m_currentRequest is null, then the request will not proceed, which is the same as canceling it.
1661         (WebKit::NetworkLoad::setPendingDownloadID):
1662         (WebKit::NetworkLoad::setPendingDownload):
1663         (WebKit::NetworkLoad::willPerformHTTPRedirection):
1664         (WebKit::NetworkLoad::continueCanAuthenticateAgainstProtectionSpace):
1665         If this load is going to become a download, then call the PendingDownload version of didReceiveAuthenticationChallenge to communicate with the 
1666         UI process directly because there wasn't necessarily a web process associated with this request that will become a download.
1667         * NetworkProcess/NetworkLoad.h:
1668         (WebKit::NetworkLoad::pendingDownloadID):
1669         * NetworkProcess/NetworkSession.h:
1670         (WebKit::NetworkDataTask::client):
1671         (WebKit::NetworkDataTask::pendingDownloadID):
1672         (WebKit::NetworkDataTask::pendingDownload):
1673         (WebKit::NetworkDataTask::setPendingDownloadID):
1674         (WebKit::NetworkDataTask::setPendingDownload):
1675         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
1676         * PlatformMac.cmake:
1677         * Shared/Authentication/AuthenticationManager.cpp:
1678         (WebKit::AuthenticationManager::didReceiveAuthenticationChallenge):
1679         * Shared/Authentication/AuthenticationManager.h:
1680         * WebKit2.xcodeproj/project.pbxproj:
1681         * WebProcess/Network/WebResourceLoader.cpp:
1682         (WebKit::WebResourceLoader::canAuthenticateAgainstProtectionSpace):
1683         Removed unnecessary protection and move null check to before using the pointer it checks.
1684
1685 2016-01-07  Simon Fraser  <simon.fraser@apple.com>
1686
1687         Use an appropriate buffer format for swipe snapshots
1688         https://bugs.webkit.org/show_bug.cgi?id=152880
1689         rdar://problem/23728299
1690
1691         Reviewed by Tim Horton.
1692         
1693         Choose an appropriate buffer format for swipe snapshots, and avoid converting
1694         them to YUV422.
1695
1696         * UIProcess/API/Cocoa/WKWebView.mm:
1697         (WebKit::bufferFormat):
1698         (-[WKWebView _takeViewSnapshot]):
1699
1700 2016-01-07  Alex Christensen  <achristensen@webkit.org>
1701
1702         Progress towards implementing downloads with NetworkSession
1703         https://bugs.webkit.org/show_bug.cgi?id=152760
1704
1705         Reviewed by Brady Eidson.
1706
1707         * NetworkProcess/Downloads/Download.cpp:
1708         (WebKit::Download::Download):
1709         There's no need to store the unused NetworkSession&.
1710         (WebKit::Download::didStart):
1711         (WebKit::Download::didReceiveAuthenticationChallenge):
1712         Downloads with NetworkSession are NetworkLoads until the response is received, which is after authentication
1713         challenges are handled by NetworkLoad's code.
1714         (WebKit::Download::didReceiveResponse):
1715         * NetworkProcess/Downloads/Download.h:
1716         * NetworkProcess/Downloads/DownloadManager.cpp:
1717         (WebKit::DownloadManager::startDownload):
1718         Create a PendingDownload, which is basically a NetworkLoad that knows that it will become a Download 
1719         when the response is received, regardless of whether or not there is a Content-Disposition header.
1720         (WebKit::DownloadManager::dataTaskBecameDownloadTask):
1721         * NetworkProcess/Downloads/DownloadManager.h:
1722         * NetworkProcess/Downloads/PendingDownload.h: Added.
1723         (WebKit::PendingDownload::PendingDownload):
1724         Added a new NetworkLoadClient for requests that will become downloads.
1725         A PendingDownload contains a NetworkLoad so we can always keep them together
1726         and so it can handle setting its pending download id.
1727         * WebKit2.xcodeproj/project.pbxproj:
1728         * NetworkProcess/NetworkLoad.cpp:
1729         (WebKit::NetworkLoad::NetworkLoad):
1730         Avoid dereferencing a pointer if the NetworkSession hadn't been created when a NetworkLoad starts.
1731         This shouldn't be possible, but it's good to not assume that all pointers are non-null.
1732         (WebKit::NetworkLoad::cancel):
1733         Add a null check in case the constructor doesn't make m_task.
1734         (WebKit::NetworkLoad::convertTaskToDownload):
1735         (WebKit::NetworkLoad::setPendingDownloadID):
1736         Added for downloads that start with startDownload.  The pending DownloadID is used to indicate that
1737         this request should always become a download, regardless of whether or not the response has a 
1738         Content-Disposition header.
1739         (WebKit::NetworkLoad::willPerformHTTPRedirection):
1740         (WebKit::NetworkLoad::didReceiveResponse):
1741         * NetworkProcess/NetworkLoad.h:
1742         There's no need to store a DownloadID here.  It's stored in the NetworkDataTask (m_task).
1743         * NetworkProcess/NetworkSession.h:
1744         (WebKit::NetworkDataTask::client):
1745         (WebKit::NetworkDataTask::pendingDownloadID):
1746         (WebKit::NetworkDataTask::setPendingDownloadID):
1747         (WebKit::NetworkDataTask::downloadID): Deleted.
1748         (WebKit::NetworkDataTask::setDownloadID): Deleted.
1749         Renamed downloadID and setDownloadID to pendingDownloadID and setPendingDownloadID, respectively,
1750         to indicate their use.  They are not the current downloadID, but they are the downloadID of the download
1751         that will happen once the response is received and PolicyDownload will be returned in the completion handler.
1752         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
1753         (-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]):
1754         Call dataTaskBecameDownloadTask after didBecomeDownload because the networkDataTask is deleted by removing it 
1755         from m_pendingDownloads in dataTaskBecameDownloadTask.
1756
1757 2016-01-06  Simon Fraser  <simon.fraser@apple.com>
1758
1759         Add a setting and preferences to enable display-list drawing. Does nothing yet.
1760         https://bugs.webkit.org/show_bug.cgi?id=152807
1761
1762         Reviewed by Zalan Bujtas.
1763         
1764         WK2 debug pref for display-list drawing, defaults to off.
1765
1766         * Shared/WebPreferencesDefinitions.h:
1767         * UIProcess/API/Cocoa/WKPreferences.mm:
1768         (-[WKPreferences _displayListDrawingEnabled]):
1769         (-[WKPreferences _setDisplayListDrawingEnabled:]):
1770         * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
1771         * WebProcess/WebPage/WebPage.cpp:
1772         (WebKit::WebPage::updatePreferences):
1773
1774 2016-01-06  Daniel Bates  <dabates@apple.com>
1775
1776         Use code signed identifier as part of user directory suffix
1777         https://bugs.webkit.org/show_bug.cgi?id=152310
1778         <rdar://problem/13352225>
1779
1780         As pointed out by Sam Weinig, the year is 2016! I inadvertently added the copyright year 2015 instead of 2016.
1781
1782         * Shared/mac/ChildProcessMac.mm:
1783
1784 2016-01-06  Simon Fraser  <simon.fraser@apple.com>
1785
1786         [iOS] Revert overflow:hidden on the body affecting viewport scale (r186786)
1787         https://bugs.webkit.org/show_bug.cgi?id=152803
1788         rdar://problem/22242515
1789
1790         Reviewed by Tim Horton.
1791
1792         You can't assume that if an author uses overflow:hidden on the body, they have no
1793         content outside the body that is important. Sites like Google Translate put
1794         abspos elements outside the body.
1795         
1796         So revert the change.
1797
1798         * WebProcess/WebPage/WebPage.cpp:
1799         (WebKit::WebPage::mainFrameDidLayout): Go back to using contents size.
1800
1801 2016-01-06  Anders Carlsson  <andersca@apple.com>
1802
1803         Add a smart block pointer
1804         https://bugs.webkit.org/show_bug.cgi?id=152799
1805
1806         Reviewed by Tim Horton.
1807
1808         Use WTF::BlockPtr.
1809
1810         * UIProcess/API/Cocoa/WKWebsiteDataStore.mm:
1811         (-[WKWebsiteDataStore fetchDataRecordsOfTypes:completionHandler:]):
1812         (-[WKWebsiteDataStore removeDataOfTypes:modifiedSince:completionHandler:]):
1813         (-[WKWebsiteDataStore removeDataOfTypes:forDataRecords:completionHandler:]):
1814
1815 2016-01-06  Daniel Bates  <dabates@apple.com>
1816
1817         Use code signed identifier as part of user directory suffix
1818         https://bugs.webkit.org/show_bug.cgi?id=152310
1819         <rdar://problem/13352225>
1820
1821         Reviewed by Brent Fulgham.
1822
1823         * Shared/mac/ChildProcessMac.mm:
1824         (WebKit::findSecCodeForProcess): Added.
1825         (WebKit::ChildProcess::initializeSandbox): Modified to use an identifier
1826         from the code signature of the app/tool as part of the user directory suffix.
1827
1828 2016-01-06  Brian Burg  <bburg@apple.com>
1829
1830         Add a WebKit SPI for registering an automation controller with RemoteInspector
1831         https://bugs.webkit.org/show_bug.cgi?id=151576
1832
1833         Reviewed by Dan Bernstein and Joseph Pecoraro.
1834
1835         _WKAutomationDelegate is a new SPI that allows WKProcessPool clients to decide
1836         policy and implement actions for remote automation.
1837
1838         The SPI's implementation connects the client's delegate to RemoteInspector::Client.
1839         This allows the delegate to handle some commands, such as requestAutomationSession,
1840         that come over XPC from an external test runner but are not associated with a specific
1841         automation target.
1842
1843         * PlatformMac.cmake:
1844         * UIProcess/API/APIAutomationClient.h: Added. Boilerplate for WebKit::AutomationClient.
1845         (API::AutomationClient::~AutomationClient):
1846         (API::AutomationClient::allowsRemoteAutomation):
1847         (API::AutomationClient::requestAutomationSession):
1848         * UIProcess/API/Cocoa/WKProcessPool.mm:
1849         (-[WKProcessPool _automationDelegate]): Added.
1850         (-[WKProcessPool _setAutomationDelegate:]): Added.
1851         (-[WKProcessPool _automationCapabilitiesDidChange]): Added.
1852         * UIProcess/API/Cocoa/WKProcessPoolPrivate.h: Add delegate.
1853         * UIProcess/API/Cocoa/_WKAutomationDelegate.h: Added.
1854
1855             This is a new delegate SPI of WKProcessPool; it corresponds to AutomationClient.
1856
1857         * UIProcess/Cocoa/AutomationClient.h: Added.
1858         * UIProcess/Cocoa/AutomationClient.mm: Added.
1859
1860             This implements a bridge between RemoteInspector::Client and _WKAutomationDelegate.
1861             Since the delegate can be called from JavaScriptCore, save the delegating
1862             WKProcessPool and pass it as the self parameter to delegate methods.
1863
1864         (WebKit::AutomationClient::AutomationClient):
1865         (WebKit::AutomationClient::~AutomationClient):
1866
1867             This client automatically registers and unregisters as a RemoteInspector::Client.
1868
1869         (WebKit::AutomationClient::remoteAutomationAllowed):
1870         (WebKit::AutomationClient::requestAutomationSession):
1871
1872             Forward requests from RemoteInspector to the automation delegate.
1873
1874         * UIProcess/WebProcessPool.cpp:
1875         (WebKit::WebProcessPool::WebProcessPool):
1876         (WebKit::WebProcessPool::setAutomationClient): Added.
1877         (WebKit::WebProcessPool::updateAutomationCapabilities): Added, it notifies RemoteInspector.
1878         * UIProcess/WebProcessPool.h:
1879         * WebKit2.xcodeproj/project.pbxproj:
1880
1881 2016-01-06  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1882
1883         [EFL] Set WebKit2 process output name
1884         https://bugs.webkit.org/show_bug.cgi?id=152773
1885
1886         Reviewed by Benjamin Poulain.
1887
1888         If we add *WebKit* prefix to each WK2 process, it is more clear when checking what process is running.
1889         So this patch sets wk2 process output name.
1890
1891         * PlatformEfl.cmake:
1892
1893 2016-01-05  Alex Christensen  <achristensen@webkit.org>
1894
1895         Implement defersLoading with NetworkSession
1896         https://bugs.webkit.org/show_bug.cgi?id=151818
1897
1898         Reviewed by Darin Adler.
1899
1900         * NetworkProcess/NetworkLoad.cpp:
1901         (WebKit::NetworkLoad::NetworkLoad):
1902         (WebKit::NetworkLoad::setDefersLoading):
1903         * NetworkProcess/NetworkSession.h:
1904         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
1905         (WebKit::NetworkDataTask::resume):
1906         (WebKit::NetworkDataTask::suspend):
1907
1908 2016-01-05  Tim Horton  <timothy_horton@apple.com>
1909
1910         REGRESSION (r192432): Keyboard repeat doesn't work anymore for arrow keys/spacebar
1911         https://bugs.webkit.org/show_bug.cgi?id=152767
1912         <rdar://problem/24017380>
1913
1914         Reviewed by Dan Bernstein.
1915
1916         * UIProcess/ios/WKContentViewInteraction.mm:
1917         (-[WKContentView _didHandleKeyEvent:eventWasHandled:]):
1918         Instead of always bailing, call [super _handleKeyUIEvent:] if we aren't
1919         in an editable area, because we won't have done so in _handleKeyUIEvent.
1920
1921         It's important that the event makes it to the root UIResponder (even if
1922         we handled it!) for key repeat to function.
1923
1924         The double-scrolling case is still fixed because we notice the resent
1925         event coming back in to us and bail if we've already seen it.
1926
1927 2016-01-05  Jer Noble  <jer.noble@apple.com>
1928
1929         [Mac] Exiting fullscreen via Mission Control leaves fullcreen window frontmost on desktop
1930         https://bugs.webkit.org/show_bug.cgi?id=152733
1931
1932         Reviewed by Eric Carlson.
1933
1934         Rather than ignore -windowDidExitFullScreen: notifications when fullscreen exit was
1935         not initiated by WebKit (and the -window:startCustomAnimationToEnterFullScreenWithDuration:
1936         method was not called), continue to exit fullscreen normally.
1937
1938         * UIProcess/mac/WKFullScreenWindowController.mm:
1939         (-[WKFullScreenWindowController finishedExitFullScreenAnimation:]):
1940
1941 2016-01-05  Alex Christensen  <achristensen@webkit.org>
1942
1943         Clean up download code
1944         https://bugs.webkit.org/show_bug.cgi?id=152739
1945
1946         Reviewed by Brady Eidson.
1947
1948         * NetworkProcess/Downloads/DownloadManager.cpp:
1949         (WebKit::DownloadManager::DownloadManager):
1950         (WebKit::DownloadManager::didCreateDownload):
1951         (WebKit::DownloadManager::didDestroyDownload):
1952         (WebKit::DownloadManager::downloadProxyConnection):
1953         (WebKit::DownloadManager::downloadsAuthenticationManager):
1954         * NetworkProcess/Downloads/DownloadManager.h:
1955         Keep a Client& instead of a Client*.
1956         * NetworkProcess/NetworkProcess.cpp:
1957         (WebKit::NetworkProcess::downloadManager):
1958         * NetworkProcess/NetworkSession.h:
1959         m_sessionID is not used. There is no need to store the sessionID if it is only used in the NetworkSession constructor.
1960         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
1961         (WebKit::NetworkSession::defaultSession):
1962         (WebKit::NetworkSession::NetworkSession):
1963
1964 2016-01-04  Carlos Garcia Campos  <cgarcia@igalia.com>
1965
1966         [GTK] Allow to save and restore session
1967         https://bugs.webkit.org/show_bug.cgi?id=115600
1968
1969         Reviewed by Michael Catanzaro.
1970
1971         Add new API to get and resore the web view session state.
1972
1973         * PlatformGTK.cmake: Add new files to compilation.
1974         * UIProcess/API/gtk/WebKitWebView.cpp:
1975         (webkit_web_view_get_session_state): Create a new
1976         WebKitWebViewSessionState representing the current session state.
1977         (webkit_web_view_restore_session_state): Restore the web view
1978         session state from the given WebKitWebViewSessionState.
1979         * UIProcess/API/gtk/WebKitWebView.h:
1980         * UIProcess/API/gtk/WebKitWebViewSessionState.cpp: Added.
1981         (_WebKitWebViewSessionState::_WebKitWebViewSessionState):
1982         (toExternalURLsPolicy):
1983         (toWebCoreExternalURLsPolicy):
1984         (toHTMLBodyElementType):
1985         (toHTTPBodyElementType):
1986         (encodeHTTPBody):
1987         (encodeFrameState):
1988         (encodePageState):
1989         (encodeBackForwardListItemState):
1990         (encodeBackForwardListState):
1991         (encodeSessionState):
1992         (decodeHTTPBody):
1993         (decodeFrameState):
1994         (decodeBackForwardListItemState):
1995         (decodeSessionState):
1996         (webkitWebViewSessionStateCreate):
1997         (webkitWebViewSessionStateGetSessionState):
1998         (webkit_web_view_session_state_new): Create a
1999         WebKitWebViewSessionState from serialized data.
2000         (webkit_web_view_session_state_ref):
2001         (webkit_web_view_session_state_unref):
2002         (webkit_web_view_session_state_serialize): Serialize the WebKitWebViewSessionState.
2003         * UIProcess/API/gtk/WebKitWebViewSessionState.h: Added.
2004         * UIProcess/API/gtk/WebKitWebViewSessionStatePrivate.h: Added.
2005         * UIProcess/API/gtk/docs/webkit2gtk-4.0-sections.txt: Add new symbols.
2006         * UIProcess/API/gtk/docs/webkit2gtk-4.0.types: Add webkit_web_view_session_state_get_type.
2007         * UIProcess/API/gtk/webkit2.h: Include WebKitWebViewSessionState.h.
2008
2009 2016-01-04  Alex Christensen  <achristensen@webkit.org>
2010
2011         Use unique_ptr for NetworkDataTasks and references for NetworkSessionTaskClients
2012         https://bugs.webkit.org/show_bug.cgi?id=152724
2013
2014         Reviewed by Andy Estes.
2015
2016         There is no reason to have a NetworkSessionTaskClient* instead of a 
2017         NetworkSessionTaskClient& just so we can clear it in the NetworkLoad destructor, 
2018         which immediately calls ~NetworkDataTask.
2019         Also, NetworkDataTasks are owned only by the NetworkLoad, so there's no reason to refcount them.
2020
2021         * NetworkProcess/Downloads/Download.h:
2022         * NetworkProcess/Downloads/DownloadManager.h:
2023         * NetworkProcess/NetworkLoad.cpp:
2024         (WebKit::NetworkLoad::~NetworkLoad):
2025         * NetworkProcess/NetworkLoad.h:
2026         * NetworkProcess/NetworkSession.h:
2027         (WebKit::NetworkSessionTaskClient::~NetworkSessionTaskClient):
2028         (WebKit::NetworkDataTask::client):
2029         (WebKit::NetworkDataTask::downloadID):
2030         (WebKit::NetworkDataTask::setDownloadID):
2031         (WebKit::NetworkDataTask::clearClient): Deleted.
2032         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
2033         (-[WKNetworkSessionDelegate URLSession:task:willPerformHTTPRedirection:newRequest:completionHandler:]):
2034         (-[WKNetworkSessionDelegate URLSession:task:didReceiveChallenge:completionHandler:]):
2035         (-[WKNetworkSessionDelegate URLSession:task:didCompleteWithError:]):
2036         (-[WKNetworkSessionDelegate URLSession:dataTask:didReceiveResponse:completionHandler:]):
2037         (-[WKNetworkSessionDelegate URLSession:dataTask:didReceiveData:]):
2038         (-[WKNetworkSessionDelegate URLSession:downloadTask:didFinishDownloadingToURL:]):
2039         (-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]):
2040         (WebKit::NetworkSession::~NetworkSession):
2041         (WebKit::NetworkSession::createDataTaskWithRequest):
2042         (WebKit::NetworkSession::dataTaskForIdentifier):
2043         (WebKit::NetworkDataTask::NetworkDataTask):
2044
2045 2016-01-04  Alex Christensen  <achristensen@webkit.org>
2046
2047         Progress towards implementing downloads with NetworkSession
2048         https://bugs.webkit.org/show_bug.cgi?id=152716
2049
2050         Reviewed by Brady Eidson.
2051
2052         * NetworkProcess/Downloads/Download.h:
2053         * NetworkProcess/Downloads/DownloadID.h:
2054         (WebKit::DownloadID::DownloadID):
2055         (WebKit::DownloadID::operator==):
2056         (WebKit::DownloadID::operator!=):
2057         (WebKit::DownloadID::downloadID):
2058         * NetworkProcess/Downloads/DownloadManager.cpp:
2059         (WebKit::DownloadManager::startDownload):
2060         * NetworkProcess/Downloads/DownloadManager.h:
2061         (WebKit::DownloadManager::download):
2062         (WebKit::DownloadManager::isDownloading):
2063         * NetworkProcess/Downloads/cocoa/DownloadCocoa.mm:
2064         (WebKit::Download::resume):
2065         (WebKit::Download::platformInvalidate):
2066         (WebKit::Download::platformDidFinish):
2067         (WebKit::Download::start): Deleted.
2068         * NetworkProcess/NetworkSession.h:
2069         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
2070         (-[WKNetworkSessionDelegate URLSession:task:willPerformHTTPRedirection:newRequest:completionHandler:]):
2071         (-[WKNetworkSessionDelegate URLSession:task:didReceiveChallenge:completionHandler:]):
2072         (-[WKNetworkSessionDelegate URLSession:task:didCompleteWithError:]):
2073         (-[WKNetworkSessionDelegate URLSession:dataTask:didReceiveResponse:completionHandler:]):
2074         (-[WKNetworkSessionDelegate URLSession:dataTask:didReceiveData:]):
2075         (-[WKNetworkSessionDelegate URLSession:downloadTask:didFinishDownloadingToURL:]):
2076         (-[WKNetworkSessionDelegate URLSession:downloadTask:didWriteData:totalBytesWritten:totalBytesExpectedToWrite:]):
2077         (-[WKNetworkSessionDelegate URLSession:downloadTask:didResumeAtOffset:expectedTotalBytes:]):
2078         (-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]):
2079
2080         When using NSURLSession, a data task is converted to a download task after the connection has already
2081         been established, the headers have been received, and WebCore looks at the response and decides that
2082         this connection should become a download.  We call the didReceiveResponse to match the behavior of 
2083         NSURLDownload, but this could be cleaned up later to match what is actually happening.  We also do not
2084         need to tell the download to start because it has already started.
2085
2086         (WebKit::NetworkSession::dataTaskForIdentifier):
2087         (WebKit::NetworkSession::addDownloadID):
2088         (WebKit::NetworkSession::downloadID):
2089         (WebKit::NetworkSession::takeDownloadID):
2090         (WebKit::NetworkDataTask::NetworkDataTask):
2091
2092         NSURLSessionDownloadTask taskIdentifiers are unique to that NSURLSession, but we have one global DownloadManager
2093         in the NetworkProcess.  We need to have each NetworkSession keep a map of taskIdentifiers to global DownloadID.
2094
2095 2016-01-04  Tim Horton  <timothy_horton@apple.com>
2096
2097         Turn on gesture events when building for Yosemite
2098         https://bugs.webkit.org/show_bug.cgi?id=152704
2099         rdar://problem/24042472
2100
2101         Reviewed by Anders Carlsson.
2102
2103         * Configurations/FeatureDefines.xcconfig:
2104
2105 2016-01-04  Tim Horton  <timothy_horton@apple.com>
2106
2107         Hardware keyboard key-commands stop responding when viewing PDFs
2108         https://bugs.webkit.org/show_bug.cgi?id=152712
2109         <rdar://problem/23014457>
2110
2111         Reviewed by Dan Bernstein.
2112
2113         Maintain first responder status through any content view swapping, by
2114         making WKWebView become first responder if needed, and pushing first
2115         responder status down to the swapped-in content view if possible.
2116
2117         * UIProcess/API/Cocoa/WKWebView.mm:
2118         (-[WKWebView becomeFirstResponder]):
2119         Make the current content view first responder instead of the WKContentView,
2120         in case we have a custom content view installed.
2121
2122         (-[WKWebView canBecomeFirstResponder]):
2123         WKWebView can always become first responder, even if none of its children can.
2124         This makes it so that if a custom content view can't become first responder,
2125         WKWebView will take the responsibility.
2126
2127         (-[WKWebView _setHasCustomContentView:loadedMIMEType:]):
2128         Return the responsibility of being first responder to the newly-installed
2129         content view if WKWebView is currently the first responder (either because
2130         of tab switching or because the previous content view did not support
2131         being first responder), if it supports being first responder.
2132
2133 2016-01-04  Commit Queue  <commit-queue@webkit.org>
2134
2135         Unreviewed, rolling out r194544.
2136         https://bugs.webkit.org/show_bug.cgi?id=152711
2137
2138         This change caused assertions in existing inspector tests
2139         (Requested by ryanhaddad on #webkit).
2140
2141         Reverted changeset:
2142
2143         "Web Inspector: reproducible debug ASSERT when inspecting the
2144         inspector (WK2)"
2145         https://bugs.webkit.org/show_bug.cgi?id=152080
2146         http://trac.webkit.org/changeset/194544
2147
2148 2016-01-04  Alex Christensen  <achristensen@webkit.org>
2149
2150         Fix Mac CMake build after r194378.
2151
2152         * CMakeLists.txt:
2153
2154 2016-01-04  Brian Burg  <bburg@apple.com>
2155
2156         Web Inspector: reproducible debug ASSERT when inspecting the inspector (WK2)
2157         https://bugs.webkit.org/show_bug.cgi?id=152080
2158
2159         Reviewed by Timothy Hatcher.
2160
2161         We hit an assert underneath ChildProcessProxy::addMessageReceiver when opening Inspector[2]
2162         because we try to add WebInpectorProxy as a message receiver twice for the same process.
2163
2164         On investigating, I found several interrelated issues that caused this state of affairs:
2165
2166          - WebInspectorProxy adds message receivers for inspector page's WebProcess and the
2167         inspected page's WebProcess. When inspecting the inspector, we mistakenly add a receiver
2168         again because the inspector is now the inspected page.
2169          - We mixed up process ids when adding message receivers.
2170          - invalidate() is re-entrant, causing us to try and double-remove the message receiver.
2171
2172         Fix this by removing add/remove of message recievers for the inspector page when then
2173         inspected page is itself an inspector page. In that case, the receivers are managed by
2174         the inspector page's WebInspectorProxy instance.
2175
2176         * UIProcess/WebInspectorProxy.cpp:
2177         (WebKit::WebInspectorProxy::invalidate): Re-arrange to guard against useless reentrancy.
2178         (WebKit::WebInspectorProxy::didRelaunchInspectorPageProcess):
2179         (WebKit::WebInspectorProxy::eagerlyCreateInspectorPage):
2180         (WebKit::WebInspectorProxy::didClose):
2181
2182 2016-01-04  Alex Christensen  <achristensen@webkit.org>
2183
2184         Build fix after r194536 when using NetworkSession.
2185
2186         * NetworkProcess/Downloads/DownloadManager.cpp:
2187         (WebKit::DownloadManager::dataTaskBecameDownloadTask):
2188         (WebKit::DownloadManager::convertHandleToDownload):
2189         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
2190         (-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]):
2191         WTFMove changed underneath me.
2192
2193 2016-01-04  Alex Christensen  <achristensen@webkit.org>
2194
2195         Progress towards implementing downloads with NetworkSession
2196         https://bugs.webkit.org/show_bug.cgi?id=152576
2197
2198         Reviewed by Brady Eidson.
2199
2200         * NetworkProcess/Downloads/Download.cpp:
2201         (WebKit::Download::Download):
2202         (WebKit::Download::~Download):
2203         (WebKit::Download::didStart):
2204         (WebKit::Download::didReceiveAuthenticationChallenge):
2205         * NetworkProcess/Downloads/Download.h:
2206         (WebKit::Download::downloadID):
2207         * NetworkProcess/Downloads/DownloadManager.cpp:
2208         (WebKit::DownloadManager::startDownload):
2209         (WebKit::DownloadManager::dataTaskBecameDownloadTask):
2210         (WebKit::DownloadManager::convertHandleToDownload):
2211         * NetworkProcess/Downloads/DownloadManager.h:
2212         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
2213         (WebKit::NetworkConnectionToWebProcess::convertMainResourceLoadToDownload):
2214         * NetworkProcess/NetworkLoad.cpp:
2215         (WebKit::NetworkLoad::convertTaskToDownload):
2216         * NetworkProcess/NetworkLoad.h:
2217         * NetworkProcess/NetworkSession.h:
2218         (WebKit::NetworkDataTask::client):
2219         (WebKit::NetworkDataTask::clearClient):
2220         (WebKit::NetworkDataTask::downloadID):
2221         (WebKit::NetworkDataTask::setDownloadID):
2222         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
2223         (-[WKNetworkSessionDelegate URLSession:downloadTask:didWriteData:totalBytesWritten:totalBytesExpectedToWrite:]):
2224         (-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]):
2225
2226 2016-01-04  Michael Catanzaro  <mcatanzaro@igalia.com>
2227
2228         [GTK] Rename _WebKitWebContextPrivate.context to _WebKitWebContextPrivate.processPool
2229         https://bugs.webkit.org/show_bug.cgi?id=152672
2230
2231         Reviewed by Carlos Garcia Campos.
2232
2233         * UIProcess/API/gtk/WebKitDownloadClient.cpp:
2234         (attachDownloadClientToContext):
2235         * UIProcess/API/gtk/WebKitInjectedBundleClient.cpp:
2236         (attachInjectedBundleClientToContext):
2237         * UIProcess/API/gtk/WebKitSecurityManager.cpp:
2238         (registerSecurityPolicyForURIScheme):
2239         * UIProcess/API/gtk/WebKitWebContext.cpp:
2240         (webkitWebContextConstructed):
2241         (webkitWebContextDispose):
2242         (webkit_web_context_set_cache_model):
2243         (webkit_web_context_get_cache_model):
2244         (webkit_web_context_clear_cache):
2245         (webkit_web_context_get_cookie_manager):
2246         (ensureFaviconDatabase):
2247         (webkit_web_context_set_favicon_database_directory):
2248         (webkit_web_context_set_additional_plugins_directory):
2249         (webkitWebContextGetPluginThread):
2250         (webkit_web_context_set_tls_errors_policy):
2251         (webkit_web_context_set_disk_cache_directory):
2252         (webkit_web_context_prefetch_dns):
2253         (webkit_web_context_allow_tls_certificate_for_host):
2254         (webkit_web_context_set_process_model):
2255         (webkit_web_context_set_web_process_count_limit):
2256         (webkitWebContextStartDownload):
2257         (webkitWebContextGetProcessPool):
2258         (webkitWebContextCreatePageForWebView):
2259         (webkitWebContextGetContext): Deleted.
2260         * UIProcess/API/gtk/WebKitWebContextPrivate.h:
2261
2262 2016-01-03  Simon Fraser  <simon.fraser@apple.com>
2263
2264         Rename scrollPosition(Scrollbar*) to scrollOffset(ScrollbarOrientation)
2265         https://bugs.webkit.org/show_bug.cgi?id=152666
2266
2267         Reviewed by Dan Bernstein.
2268
2269         Scrollbar values take offsets (zero-based), so rename the accessor used
2270         by scrollbars to set their value, and pass in an orientation, rather than
2271         a pointer to the scrollbar.
2272
2273         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.h:
2274         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.mm:
2275         (WebKit::PDFPlugin::scrollOffset):
2276         (WebKit::PDFPlugin::scrollPosition): Renamed.
2277
2278 2015-12-31  Andy Estes  <aestes@apple.com>
2279
2280         Replace WTF::move with WTFMove
2281         https://bugs.webkit.org/show_bug.cgi?id=152601
2282
2283         Reviewed by Brady Eidson.
2284
2285         * DatabaseProcess/DatabaseProcess.cpp:
2286         (WebKit::DatabaseProcess::postDatabaseTask):
2287         (WebKit::DatabaseProcess::fetchWebsiteData):
2288         (WebKit::DatabaseProcess::deleteWebsiteData):
2289         (WebKit::DatabaseProcess::deleteWebsiteDataForOrigins):
2290         (WebKit::DatabaseProcess::indexedDatabaseOrigins):
2291         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
2292         (WebKit::UniqueIDBDatabase::postTransactionOperation):
2293         (WebKit::UniqueIDBDatabase::postMainThreadTask):
2294         (WebKit::UniqueIDBDatabase::postDatabaseTask):
2295         * NetworkProcess/Downloads/DownloadManager.cpp:
2296         (WebKit::DownloadManager::startDownload):
2297         (WebKit::DownloadManager::convertHandleToDownload):
2298         (WebKit::DownloadManager::resumeDownload):
2299         * NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm:
2300         (WebKit::NetworkServiceInitializerDelegate::NetworkServiceInitializerDelegate):
2301         * NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
2302         (WebKit::NetworkBlobRegistry::registerBlobURL):
2303         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
2304         (WebKit::NetworkConnectionToWebProcess::performSynchronousLoad):
2305         (WebKit::NetworkConnectionToWebProcess::registerBlobURL):
2306         * NetworkProcess/NetworkLoad.cpp:
2307         (WebKit::NetworkLoad::didReceiveData):
2308         (WebKit::NetworkLoad::didReceiveBuffer):
2309         (WebKit::NetworkLoad::continueCanAuthenticateAgainstProtectionSpace):
2310         * NetworkProcess/NetworkProcess.cpp:
2311         (WebKit::fetchDiskCacheEntries):
2312         (WebKit::NetworkProcess::fetchWebsiteData):
2313         (WebKit::NetworkProcess::deleteWebsiteData):
2314         (WebKit::clearDiskCacheEntries):
2315         (WebKit::NetworkProcess::deleteWebsiteDataForOrigins):
2316         * NetworkProcess/NetworkResourceLoader.cpp:
2317         (WebKit::NetworkResourceLoader::SynchronousLoadData::SynchronousLoadData):
2318         (WebKit::NetworkResourceLoader::NetworkResourceLoader):
2319         (WebKit::NetworkResourceLoader::retrieveCacheEntry):
2320         (WebKit::NetworkResourceLoader::didFinishLoading):
2321         (WebKit::NetworkResourceLoader::tryStoreAsCacheEntry):
2322         (WebKit::NetworkResourceLoader::validateCacheEntry):
2323         * NetworkProcess/NetworkResourceLoader.h:
2324         * NetworkProcess/cache/NetworkCache.cpp:
2325         (WebKit::NetworkCache::Cache::retrieve):
2326         (WebKit::NetworkCache::Cache::store):
2327         (WebKit::NetworkCache::Cache::clear):
2328         * NetworkProcess/cache/NetworkCacheCoders.h:
2329         * NetworkProcess/cache/NetworkCacheDataSoup.cpp:
2330         (WebKit::NetworkCache::Data::empty):
2331         (WebKit::NetworkCache::Data::subrange):
2332         (WebKit::NetworkCache::concatenate):
2333         (WebKit::NetworkCache::Data::adoptMap):
2334         * NetworkProcess/cache/NetworkCacheEntry.cpp:
2335         (WebKit::NetworkCache::Entry::Entry):
2336         * NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp:
2337         (WebKit::NetworkCache::runTaskInQueue):
2338         (WebKit::NetworkCache::fillDataFromReadBuffer):
2339         (WebKit::NetworkCache::IOChannel::readSyncInThread):
2340         * NetworkProcess/cache/NetworkCacheSpeculativeLoad.cpp:
2341         (WebKit::NetworkCache::SpeculativeLoad::SpeculativeLoad):
2342         (WebKit::NetworkCache::SpeculativeLoad::didFinishLoading):
2343         (WebKit::NetworkCache::SpeculativeLoad::didComplete):
2344         * NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp:
2345         (WebKit::NetworkCache::SpeculativeLoadManager::ExpiringEntry::ExpiringEntry):
2346         (WebKit::NetworkCache::SpeculativeLoadManager::PreloadedEntry::PreloadedEntry):
2347         (WebKit::NetworkCache::SpeculativeLoadManager::PreloadedEntry::takeCacheEntry):
2348         (WebKit::NetworkCache::SpeculativeLoadManager::PendingFrameLoad::create):
2349         (WebKit::NetworkCache::SpeculativeLoadManager::PendingFrameLoad::setExistingSubresourcesEntry):
2350         (WebKit::NetworkCache::SpeculativeLoadManager::PendingFrameLoad::PendingFrameLoad):
2351         (WebKit::NetworkCache::SpeculativeLoadManager::registerLoad):
2352         (WebKit::NetworkCache::SpeculativeLoadManager::addPreloadedEntry):
2353         (WebKit::NetworkCache::SpeculativeLoadManager::retrieveEntryFromStorage):
2354         (WebKit::NetworkCache::SpeculativeLoadManager::revalidateEntry):
2355         (WebKit::NetworkCache::SpeculativeLoadManager::preloadEntry):
2356         (WebKit::NetworkCache::SpeculativeLoadManager::retrieveSubresourcesEntry):
2357         * NetworkProcess/cache/NetworkCacheStatistics.cpp:
2358         (WebKit::NetworkCache::Statistics::queryWasEverRequested):
2359         * NetworkProcess/cache/NetworkCacheStorage.cpp:
2360         (WebKit::NetworkCache::Storage::ReadOperation::finish):
2361         (WebKit::NetworkCache::Storage::synchronize):
2362         (WebKit::NetworkCache::Storage::dispatchReadOperation):
2363         (WebKit::NetworkCache::Storage::dispatchWriteOperation):
2364         (WebKit::NetworkCache::Storage::retrieve):
2365         (WebKit::NetworkCache::Storage::store):
2366         (WebKit::NetworkCache::Storage::traverse):
2367         (WebKit::NetworkCache::Storage::clear):
2368         * NetworkProcess/cache/NetworkCacheSubresourcesEntry.cpp:
2369         (WebKit::NetworkCache::SubresourcesEntry::SubresourcesEntry):
2370         (WebKit::NetworkCache::SubresourcesEntry::updateSubresourceKeys):
2371         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
2372         (WebKit::NetworkDataTask::NetworkDataTask):
2373         * NetworkProcess/soup/NetworkProcessSoup.cpp:
2374         (WebKit::NetworkProcess::clearDiskCache):
2375         * Platform/IPC/ArgumentCoders.h:
2376         (IPC::ArgumentCoder<WTF::Optional<T>>::decode):
2377         * Platform/IPC/ArgumentDecoder.cpp:
2378         (IPC::ArgumentDecoder::ArgumentDecoder):
2379         * Platform/IPC/ArgumentEncoder.cpp:
2380         (IPC::ArgumentEncoder::addAttachment):
2381         (IPC::ArgumentEncoder::releaseAttachments):
2382         * Platform/IPC/Attachment.cpp:
2383         (IPC::Attachment::encode):
2384         * Platform/IPC/Connection.cpp:
2385         (IPC::Connection::SyncMessageState::processIncomingMessage):
2386         (IPC::Connection::SyncMessageState::dispatchMessages):
2387         (IPC::Connection::dispatchWorkQueueMessageReceiverMessage):
2388         (IPC::Connection::sendMessage):
2389         (IPC::Connection::sendSyncReply):
2390         (IPC::Connection::waitForMessage):
2391         (IPC::Connection::sendSyncMessage):
2392         (IPC::Connection::sendSyncMessageFromSecondaryThread):
2393         (IPC::Connection::waitForSyncReply):
2394         (IPC::Connection::processIncomingSyncReply):
2395         (IPC::Connection::processIncomingMessage):
2396         (IPC::Connection::sendOutgoingMessages):
2397         (IPC::Connection::dispatchSyncMessage):
2398         (IPC::Connection::enqueueIncomingMessage):
2399         (IPC::Connection::dispatchOneMessage):
2400         * Platform/IPC/Connection.h:
2401         (IPC::Connection::Identifier::Identifier):
2402         (IPC::Connection::send):
2403         (IPC::Connection::sendSync):
2404         * Platform/IPC/HandleMessage.h:
2405         (IPC::handleMessage):
2406         (IPC::handleMessageDelayed):
2407         * Platform/IPC/MessageDecoder.cpp:
2408         (IPC::MessageDecoder::MessageDecoder):
2409         (IPC::MessageDecoder::setImportanceAssertion):
2410         (IPC::MessageDecoder::unwrapForTesting):
2411         * Platform/IPC/MessageDecoder.h:
2412         (IPC::MessageDecoder::setMessageProcessingToken):
2413         * Platform/IPC/MessageEncoder.cpp:
2414         (IPC::MessageEncoder::wrapForTesting):
2415         * Platform/IPC/MessageRecorder.cpp:
2416         (IPC::MessageRecorder::recordOutgoingMessage):
2417         (IPC::MessageRecorder::recordIncomingMessage):
2418         (IPC::MessageRecorder::MessageProcessingToken::MessageProcessingToken):
2419         * Platform/IPC/MessageSender.cpp:
2420         (IPC::MessageSender::sendMessage):
2421         * Platform/IPC/MessageSender.h:
2422         (IPC::MessageSender::send):
2423         (IPC::MessageSender::sendSync):
2424         * Platform/IPC/glib/GSocketMonitor.cpp:
2425         (IPC::GSocketMonitor::start):
2426         * Platform/IPC/mac/ConnectionMac.mm:
2427         (IPC::Connection::open):
2428         (IPC::createMessageDecoder):
2429         (IPC::Connection::receiveSourceEventHandler):
2430         * Platform/IPC/unix/ConnectionUnix.cpp:
2431         (IPC::Connection::processMessage):
2432         * Platform/unix/SharedMemoryUnix.cpp:
2433         (WebKit::SharedMemory::Handle::decode):
2434         (WebKit::SharedMemory::Handle::releaseAttachment):
2435         (WebKit::SharedMemory::Handle::adoptAttachment):
2436         * PluginProcess/EntryPoint/mac/XPCService/PluginServiceEntryPoint.mm:
2437         (WebKit::PluginServiceInitializerDelegate::PluginServiceInitializerDelegate):
2438         * PluginProcess/PluginProcess.cpp:
2439         (WebKit::PluginProcess::initializePluginProcess):
2440         * PluginProcess/WebProcessConnection.cpp:
2441         (WebKit::WebProcessConnection::addPluginControllerProxy):
2442         (WebKit::WebProcessConnection::createPluginInternal):
2443         * PluginProcess/mac/PluginProcessMac.mm:
2444         (WebKit::PluginProcess::platformInitializePluginProcess):
2445         * Scripts/webkit/LegacyMessageReceiver-expected.cpp:
2446         (Messages::WebPage::GetPluginProcessConnection::DelayedReply::DelayedReply):
2447         (Messages::WebPage::GetPluginProcessConnection::DelayedReply::send):
2448         (Messages::WebPage::TestMultipleAttributes::DelayedReply::DelayedReply):
2449         (Messages::WebPage::TestMultipleAttributes::DelayedReply::send):
2450         * Scripts/webkit/MessageReceiver-expected.cpp:
2451         (Messages::WebPage::GetPluginProcessConnection::DelayedReply::DelayedReply):
2452         (Messages::WebPage::GetPluginProcessConnection::DelayedReply::send):
2453         (Messages::WebPage::TestMultipleAttributes::DelayedReply::DelayedReply):
2454         (Messages::WebPage::TestMultipleAttributes::DelayedReply::send):
2455         * Scripts/webkit/messages.py:
2456         (generate_message_handler):
2457         * Shared/API/APIArray.cpp:
2458         (API::Array::create):
2459         (API::Array::createStringArray):
2460         (API::Array::copy):
2461         * Shared/API/APIArray.h:
2462         * Shared/API/APIDictionary.cpp:
2463         (API::Dictionary::create):
2464         (API::Dictionary::Dictionary):
2465         (API::Dictionary::keys):
2466         * Shared/API/APIPageGroupHandle.cpp:
2467         (API::PageGroupHandle::create):
2468         (API::PageGroupHandle::PageGroupHandle):
2469         (API::PageGroupHandle::decode):
2470         * Shared/API/APIString.h:
2471         * Shared/API/APIURL.h:
2472         (API::URL::create):
2473         (API::URL::URL):
2474         * Shared/API/Cocoa/RemoteObjectInvocation.h:
2475         (WebKit::RemoteObjectInvocation::ReplyInfo::ReplyInfo):
2476         * Shared/API/Cocoa/RemoteObjectInvocation.mm:
2477         (WebKit::RemoteObjectInvocation::RemoteObjectInvocation):
2478         (WebKit::RemoteObjectInvocation::decode):
2479         * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
2480         (ensureObjectStream):
2481         (createEncodedObject):
2482         * Shared/API/Cocoa/_WKRemoteObjectInterface.mm:
2483         (initializeMethod):
2484         (-[_WKRemoteObjectInterface setClasses:forSelector:argumentIndex:ofReply:]):
2485         * Shared/API/Cocoa/_WKRemoteObjectRegistry.mm:
2486         (-[_WKRemoteObjectRegistry _sendInvocation:interface:]):
2487         * Shared/API/c/WKArray.cpp:
2488         (WKArrayCreate):
2489         (WKArrayCreateAdoptingValues):
2490         * Shared/API/c/WKDictionary.cpp:
2491         (WKDictionaryCreate):
2492         * Shared/API/c/WKSharedAPICast.h:
2493         (WebKit::ProxyingRefPtr::ProxyingRefPtr):
2494         * Shared/APIWebArchive.mm:
2495         (API::WebArchive::WebArchive):
2496         (API::WebArchive::subresources):
2497         (API::WebArchive::subframeArchives):
2498         * Shared/AsyncRequest.cpp:
2499         (WebKit::AsyncRequest::AsyncRequest):
2500         (WebKit::AsyncRequest::setAbortHandler):
2501         * Shared/AsyncRequest.h:
2502         * Shared/BlockingResponseMap.h:
2503         (BlockingResponseMap::didReceiveResponse):
2504         * Shared/ChildProcessProxy.cpp:
2505         (WebKit::ChildProcessProxy::sendMessage):
2506         (WebKit::ChildProcessProxy::didFinishLaunching):
2507         * Shared/ChildProcessProxy.h:
2508         (WebKit::ChildProcessProxy::send):
2509         (WebKit::ChildProcessProxy::sendSync):
2510         * Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp:
2511         (WebKit::CoordinatedGraphicsScene::dispatchOnMainThread):
2512         (WebKit::CoordinatedGraphicsScene::dispatchOnClientRunLoop):
2513         (WebKit::CoordinatedGraphicsScene::createLayer):
2514         (WebKit::CoordinatedGraphicsScene::syncRemoteContent):
2515         (WebKit::CoordinatedGraphicsScene::appendUpdate):
2516         * Shared/CoordinatedGraphics/threadedcompositor/ThreadSafeCoordinatedSurface.cpp:
2517         (WebKit::ThreadSafeCoordinatedSurface::create):
2518         (WebKit::ThreadSafeCoordinatedSurface::ThreadSafeCoordinatedSurface):
2519         * Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.cpp:
2520         (WebKit::CompositingRunLoop::CompositingRunLoop):
2521         (WebKit::CompositingRunLoop::callOnCompositingRunLoop):
2522         (WebKit::ThreadedCompositor::callOnCompositingThread):
2523         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
2524         (WebKit::XPCServiceInitializerDelegate::XPCServiceInitializerDelegate):
2525         (WebKit::XPCServiceInitializer):
2526         * Shared/Plugins/Netscape/PluginInformation.cpp:
2527         (WebKit::createPluginInformationDictionary):
2528         * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.h:
2529         (WebKit::RemoteScrollingCoordinatorTransaction::setStateTreeToEncode):
2530         * Shared/SessionTracker.cpp:
2531         (WebKit::SessionTracker::setSession):
2532         * Shared/UserData.cpp:
2533         (WebKit::UserData::UserData):
2534         (WebKit::transformGraph):
2535         (WebKit::UserData::decode):
2536         * Shared/WebBackForwardListItem.cpp:
2537         (WebKit::WebBackForwardListItem::create):
2538         (WebKit::WebBackForwardListItem::WebBackForwardListItem):
2539         * Shared/WebBackForwardListItem.h:
2540         (WebKit::WebBackForwardListItem::setPageState):
2541         * Shared/WebCompiledContentExtension.cpp:
2542         (WebKit::WebCompiledContentExtension::create):
2543         (WebKit::WebCompiledContentExtension::WebCompiledContentExtension):
2544         * Shared/WebCompiledContentExtensionData.h:
2545         (WebKit::WebCompiledContentExtensionData::WebCompiledContentExtensionData):
2546         * Shared/WebContextMenuItem.cpp:
2547         (WebKit::WebContextMenuItem::submenuItemsAsAPIArray):
2548         * Shared/WebCoreArgumentCoders.cpp:
2549         (IPC::ArgumentCoder<UserStyleSheet>::decode):
2550         (IPC::ArgumentCoder<UserScript>::decode):
2551         (IPC::ArgumentCoder<FilterOperations>::decode):
2552         (IPC::ArgumentCoder<BlobPart>::decode):
2553         * Shared/WebKeyboardEvent.cpp:
2554         (WebKit::WebKeyboardEvent::WebKeyboardEvent):
2555         * Shared/WebPreferencesStore.h:
2556         (WebKit::WebPreferencesStore::Value::Value):
2557         * Shared/WebRenderLayer.cpp:
2558         (WebKit::WebRenderLayer::createArrayFromLayerList):
2559         * Shared/WebRenderObject.cpp:
2560         (WebKit::WebRenderObject::WebRenderObject):
2561         * Shared/WebTouchEvent.cpp:
2562         (WebKit::WebTouchEvent::WebTouchEvent):
2563         * Shared/efl/WebEventFactory.cpp:
2564         (WebKit::WebEventFactory::createWebTouchEvent):
2565         * Shared/gtk/NativeWebKeyboardEventGtk.cpp:
2566         (WebKit::NativeWebKeyboardEvent::NativeWebKeyboardEvent):
2567         * Shared/gtk/NativeWebTouchEventGtk.cpp:
2568         (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
2569         * Shared/gtk/WebContextMenuItemGtk.cpp:
2570         (WebKit::WebContextMenuItemGtk::WebContextMenuItemGtk):
2571         * Shared/gtk/WebEventFactory.cpp:
2572         (WebKit::WebEventFactory::createWebKeyboardEvent):
2573         (WebKit::WebEventFactory::createWebTouchEvent):
2574         * Shared/linux/SeccompFilters/OpenSyscall.cpp:
2575         (WebKit::OpenSyscall::createFromOpenatContext):
2576         (WebKit::OpenSyscall::createFromCreatContext):
2577         (WebKit::OpenSyscallResult::encode):
2578         * Shared/mac/ObjCObjectGraph.mm:
2579         (WebKit::ObjCObjectGraph::decode):
2580         * Shared/mac/RemoteLayerBackingStore.mm:
2581         (WebKit::RemoteLayerBackingStore::takeFrontContextPendingFlush):
2582         (WebKit::RemoteLayerBackingStore::Buffer::discard):
2583         * Shared/mac/RemoteLayerTreeTransaction.h:
2584         (WebKit::RemoteLayerTreeTransaction::setCallbackIDs):
2585         * Shared/mac/RemoteLayerTreeTransaction.mm:
2586         (WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
2587         (WebKit::RemoteLayerTreeTransaction::decode):
2588         (WebKit::RemoteLayerTreeTransaction::setCreatedLayers):
2589         (WebKit::RemoteLayerTreeTransaction::setDestroyedLayerIDs):
2590         (WebKit::RemoteLayerTreeTransaction::setLayerIDsWithNewlyUnreachableBackingStore):
2591         * Shared/soup/WebCoreArgumentCodersSoup.cpp:
2592         (IPC::ArgumentCoder<ResourceRequest>::decodePlatformData):
2593         * UIProcess/API/APIProcessPoolConfiguration.h:
2594         * UIProcess/API/APISessionState.cpp:
2595         (API::SessionState::create):
2596         (API::SessionState::SessionState):
2597         * UIProcess/API/APIUserContentExtension.cpp:
2598         (API::UserContentExtension::UserContentExtension):
2599         * UIProcess/API/APIUserContentExtension.h:
2600         * UIProcess/API/APIUserContentExtensionStore.cpp:
2601         (API::compiledToFile):
2602         (API::createExtension):
2603         (API::UserContentExtensionStore::compileContentExtension):
2604         * UIProcess/API/APIUserScript.h:
2605         * UIProcess/API/APIWebsiteDataRecord.cpp:
2606         (API::WebsiteDataRecord::create):
2607         (API::WebsiteDataRecord::WebsiteDataRecord):
2608         * UIProcess/API/APIWebsiteDataStore.cpp:
2609         (API::WebsiteDataStore::create):
2610         (API::WebsiteDataStore::WebsiteDataStore):
2611         * UIProcess/API/C/WKApplicationCacheManager.cpp:
2612         (WKApplicationCacheManagerGetApplicationCacheOrigins):
2613         * UIProcess/API/C/WKKeyValueStorageManager.cpp:
2614         (WKKeyValueStorageManagerGetKeyValueStorageOrigins):
2615         (WKKeyValueStorageManagerGetStorageDetailsByOrigin):
2616         * UIProcess/API/C/WKPage.cpp:
2617         (WKPageCopySessionState):
2618         (WKPageRestoreFromSessionState):
2619         (WKPageSetPageContextMenuClient):
2620         (WKPageSetPageFindMatchesClient):
2621         (WKPageSetPageLoaderClient):
2622         (WebKit::RunJavaScriptAlertResultListener::create):
2623         (WebKit::RunJavaScriptAlertResultListener::RunJavaScriptAlertResultListener):
2624         (WebKit::RunJavaScriptConfirmResultListener::create):
2625         (WebKit::RunJavaScriptConfirmResultListener::RunJavaScriptConfirmResultListener):
2626         (WebKit::RunJavaScriptPromptResultListener::create):
2627         (WebKit::RunJavaScriptPromptResultListener::RunJavaScriptPromptResultListener):
2628         (WKPageSetPageUIClient):
2629         (WKPageSetPageNavigationClient):
2630         (WKPageCopyRelatedPages):
2631         * UIProcess/API/C/WKResourceCacheManager.cpp:
2632         (WKResourceCacheManagerGetCacheOrigins):
2633         * UIProcess/API/C/WKSessionStateRef.cpp:
2634         (WKSessionStateCreateFromData):
2635         * UIProcess/API/C/mac/WKContextPrivateMac.mm:
2636         (WKContextGetInfoForInstalledPlugIns):
2637         * UIProcess/API/C/mac/WKPagePrivateMac.mm:
2638         (-[WKObservablePageState initWithPage:]):
2639         * UIProcess/API/Cocoa/WKBrowsingContextGroup.mm:
2640         (createWKArray):
2641         * UIProcess/API/Cocoa/WKWebView.mm:
2642         (-[WKWebView initWithFrame:configuration:]):
2643         (-[WKWebView _takeViewSnapshot]):
2644         (-[WKWebView _restoreFromSessionStateData:]):
2645         (-[WKWebView _setInputDelegate:]):
2646         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
2647         (LazyInitialized::set):
2648         * UIProcess/API/Cocoa/WKWebsiteDataStore.mm:
2649         (-[WKWebsiteDataStore fetchDataRecordsOfTypes:completionHandler:]):
2650         * UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm:
2651         (-[_WKProcessPoolConfiguration setCachePartitionedURLSchemes:]):
2652         * UIProcess/API/Cocoa/_WKSessionState.mm:
2653         (-[_WKSessionState _initWithSessionState:]):
2654         * UIProcess/API/Cocoa/_WKUserContentExtensionStore.mm:
2655         (-[_WKUserContentExtensionStore compileContentExtensionForIdentifier:encodedContentExtension:completionHandler:]):
2656         * UIProcess/API/efl/ewk_database_manager.cpp:
2657         (EwkDatabaseManager::getDatabaseOrigins):
2658         * UIProcess/API/gtk/WebKitContextMenuItem.cpp:
2659         (webkitContextMenuItemToWebContextMenuItemGtk):
2660         * UIProcess/API/gtk/WebKitFileChooserRequest.cpp:
2661         (webkit_file_chooser_request_select_files):
2662         * UIProcess/API/gtk/WebKitNotificationProvider.cpp:
2663         (WebKitNotificationProvider::notificationCloseCallback):
2664         * UIProcess/API/gtk/WebKitWebContext.cpp:
2665         (webkit_web_context_prefetch_dns):
2666         (webkitWebContextCreatePageForWebView):
2667         * UIProcess/API/gtk/WebKitWebView.cpp:
2668         (webkit_web_view_get_snapshot):
2669         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
2670         (webkitWebViewBaseTouchEvent):
2671         (webkitWebViewBaseCreateWebPage):
2672         * UIProcess/API/gtk/WebKitWebsiteDataManager.cpp:
2673         (webkitWebsiteDataManagerCreate):
2674         (webkitWebsiteDataManagerGetDataStore):
2675         * UIProcess/API/mac/WKView.mm:
2676         (-[WKView initWithFrame:processPool:configuration:webView:]):
2677         (-[WKView initWithFrame:contextRef:pageGroupRef:relatedToPage:]):
2678         (-[WKView initWithFrame:configurationRef:]):
2679         * UIProcess/Cocoa/NavigationState.mm:
2680         (WebKit::tryAppLink):
2681         (WebKit::NavigationState::NavigationClient::decidePolicyForNavigationAction):
2682         (WebKit::NavigationState::NavigationClient::decidePolicyForNavigationResponse):
2683         * UIProcess/Cocoa/WebViewImpl.mm:
2684         (WebKit::WebViewImpl::WebViewImpl):
2685         (WebKit::WebViewImpl::takeViewSnapshot):
2686         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.cpp:
2687         (WebKit::CoordinatedLayerTreeHostProxy::dispatchUpdate):
2688         * UIProcess/Databases/DatabaseProcessProxy.cpp:
2689         (WebKit::DatabaseProcessProxy::fetchWebsiteData):
2690         (WebKit::DatabaseProcessProxy::deleteWebsiteData):
2691         (WebKit::DatabaseProcessProxy::deleteWebsiteDataForOrigins):
2692         * UIProcess/GenericCallback.h:
2693         (WebKit::CallbackMap::put):
2694         * UIProcess/InspectorServer/WebSocketServer.cpp:
2695         (WebKit::WebSocketServer::didAcceptConnection):
2696         * UIProcess/InspectorServer/soup/WebSocketServerSoup.cpp:
2697         (WebKit::connectionCallback):
2698         * UIProcess/Network/NetworkProcessProxy.cpp:
2699         (WebKit::NetworkProcessProxy::fetchWebsiteData):
2700         * UIProcess/Notifications/WebNotificationManagerProxy.cpp:
2701         (WebKit::WebNotificationManagerProxy::providerDidCloseNotifications):
2702         * UIProcess/Notifications/WebNotificationProvider.cpp:
2703         (WebKit::WebNotificationProvider::clearNotifications):
2704         * UIProcess/PageLoadState.cpp:
2705         (WebKit::PageLoadState::Transaction::Transaction):
2706         * UIProcess/Plugins/PlugInAutoStartProvider.cpp:
2707         (WebKit::PlugInAutoStartProvider::autoStartOriginsTableCopy):
2708         * UIProcess/Plugins/PluginProcessManager.cpp:
2709         (WebKit::PluginProcessManager::pluginProcessToken):
2710         (WebKit::PluginProcessManager::fetchWebsiteData):
2711         (WebKit::PluginProcessManager::deleteWebsiteData):
2712         (WebKit::PluginProcessManager::deleteWebsiteDataForHostNames):
2713         * UIProcess/Plugins/PluginProcessProxy.cpp:
2714         (WebKit::PluginProcessProxy::fetchWebsiteData):
2715         (WebKit::PluginProcessProxy::deleteWebsiteData):
2716         (WebKit::PluginProcessProxy::deleteWebsiteDataForHostNames):
2717         * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp:
2718         (WebKit::RemoteScrollingCoordinatorProxy::updateScrollingTree):
2719         * UIProcess/StatisticsRequest.cpp:
2720         (WebKit::StatisticsRequest::completedRequest):
2721         * UIProcess/Storage/LocalStorageDatabase.cpp:
2722         (WebKit::LocalStorageDatabase::create):
2723         (WebKit::LocalStorageDatabase::LocalStorageDatabase):
2724         * UIProcess/Storage/StorageManager.cpp:
2725         (WebKit::StorageManager::TransientLocalStorageNamespace::getOrCreateStorageArea):
2726         (WebKit::StorageManager::StorageArea::create):
2727         (WebKit::StorageManager::StorageArea::StorageArea):
2728         (WebKit::StorageManager::LocalStorageNamespace::getOrCreateStorageArea):
2729         (WebKit::StorageManager::SessionStorageNamespace::getOrCreateStorageArea):
2730         (WebKit::StorageManager::getSessionStorageOrigins):
2731         (WebKit::StorageManager::getLocalStorageOrigins):
2732         (WebKit::StorageManager::getLocalStorageOriginDetails):
2733         (WebKit::StorageManager::createTransientLocalStorageMap):
2734         (WebKit::StorageManager::createSessionStorageMap):
2735         * UIProcess/UserContent/WebScriptMessageHandler.cpp:
2736         (WebKit::WebScriptMessageHandler::create):
2737         (WebKit::WebScriptMessageHandler::WebScriptMessageHandler):
2738         * UIProcess/UserContent/WebUserContentControllerProxy.cpp:
2739         (WebKit::WebUserContentControllerProxy::addUserStyleSheet):
2740         * UIProcess/ViewGestureController.cpp:
2741         (WebKit::ViewGestureController::SnapshotRemovalTracker::start):
2742         (WebKit::ViewGestureController::SnapshotRemovalTracker::fireRemovalCallbackImmediately):
2743         * UIProcess/WebBackForwardList.cpp:
2744         (WebKit::WebBackForwardList::addItem):
2745         (WebKit::WebBackForwardList::backListAsAPIArrayWithLimit):
2746         (WebKit::WebBackForwardList::forwardListAsAPIArrayWithLimit):
2747         (WebKit::WebBackForwardList::removeAllItems):
2748         (WebKit::WebBackForwardList::clear):
2749         (WebKit::WebBackForwardList::restoreFromState):
2750         * UIProcess/WebCookieManagerProxy.cpp:
2751         (WebKit::WebCookieManagerProxy::getHostnamesWithCookies):
2752         (WebKit::WebCookieManagerProxy::getHTTPCookieAcceptPolicy):
2753         * UIProcess/WebFormClient.cpp:
2754         (WebKit::WebFormClient::willSubmitForm):
2755         * UIProcess/WebFrameListenerProxy.h:
2756         (WebKit::WebFrameListenerProxy::setNavigation):
2757         * UIProcess/WebFrameProxy.h:
2758         (WebKit::WebFrameProxy::contentFilterDidBlockLoad):
2759         * UIProcess/WebGrammarDetail.cpp:
2760         (WebKit::WebGrammarDetail::guesses):
2761         * UIProcess/WebInspectorProxy.cpp:
2762         (WebKit::WebInspectorProxy::createInspectorPage):
2763         * UIProcess/WebMediaCacheManagerProxy.cpp:
2764         (WebKit::WebMediaCacheManagerProxy::getHostnamesWithMediaCache):
2765         * UIProcess/WebPageProxy.cpp:
2766         (WebKit::ExceededDatabaseQuotaRecords::add):
2767         (WebKit::WebPageProxy::create):
2768         (WebKit::WebPageProxy::WebPageProxy):
2769         (WebKit::WebPageProxy::setHistoryClient):
2770         (WebKit::WebPageProxy::setNavigationClient):
2771         (WebKit::WebPageProxy::setLoaderClient):
2772         (WebKit::WebPageProxy::setPolicyClient):
2773         (WebKit::WebPageProxy::setFormClient):
2774         (WebKit::WebPageProxy::setUIClient):
2775         (WebKit::WebPageProxy::setFindClient):
2776         (WebKit::WebPageProxy::setFindMatchesClient):
2777         (WebKit::WebPageProxy::setDiagnosticLoggingClient):
2778         (WebKit::WebPageProxy::setContextMenuClient):
2779         (WebKit::WebPageProxy::reattachToWebProcessForReload):
2780         (WebKit::WebPageProxy::reattachToWebProcessWithItem):
2781         (WebKit::WebPageProxy::loadRequest):
2782         (WebKit::WebPageProxy::loadFile):
2783         (WebKit::WebPageProxy::loadData):
2784         (WebKit::WebPageProxy::loadHTMLString):
2785         (WebKit::WebPageProxy::reload):
2786         (WebKit::WebPageProxy::didChangeBackForwardList):
2787         (WebKit::WebPageProxy::setInitialFocus):
2788         (WebKit::WebPageProxy::validateCommand):
2789         (WebKit::WebPageProxy::handleWheelEvent):
2790         (WebKit::WebPageProxy::processNextQueuedWheelEvent):
2791         (WebKit::WebPageProxy::restoreFromSessionState):
2792         (WebKit::WebPageProxy::runJavaScriptInMainFrame):
2793         (WebKit::WebPageProxy::getRenderTreeExternalRepresentation):
2794         (WebKit::WebPageProxy::getSourceForFrame):
2795         (WebKit::WebPageProxy::getContentsAsString):
2796         (WebKit::WebPageProxy::getBytecodeProfile):
2797         (WebKit::WebPageProxy::getContentsAsMHTMLData):
2798         (WebKit::WebPageProxy::getSelectionOrContentsAsString):
2799         (WebKit::WebPageProxy::getSelectionAsWebArchiveData):
2800         (WebKit::WebPageProxy::getMainResourceDataOfFrame):
2801         (WebKit::WebPageProxy::getResourceDataFromFrame):
2802         (WebKit::WebPageProxy::getWebArchiveOfFrame):
2803         (WebKit::WebPageProxy::decidePolicyForNavigationAction):
2804         (WebKit::WebPageProxy::decidePolicyForNewWindowAction):
2805         (WebKit::WebPageProxy::decidePolicyForResponse):
2806         (WebKit::WebPageProxy::sendMessage):
2807         (WebKit::WebPageProxy::exceededDatabaseQuota):
2808         (WebKit::WebPageProxy::getMarkedRangeAsync):
2809         (WebKit::WebPageProxy::getSelectedRangeAsync):
2810         (WebKit::WebPageProxy::characterIndexForPointAsync):
2811         (WebKit::WebPageProxy::firstRectForCharacterRangeAsync):
2812         (WebKit::WebPageProxy::takeSnapshot):
2813         * UIProcess/WebProcessPool.cpp:
2814         (WebKit::WebProcessPool::setHistoryClient):
2815         (WebKit::WebProcessPool::setDownloadClient):
2816         (WebKit::WebProcessPool::createWebPage):
2817         (WebKit::WebProcessPool::getStatistics):
2818         (WebKit::WebProcessPool::pluginInfoStoreDidLoadPlugins):
2819         * UIProcess/WebProcessProxy.cpp:
2820         (WebKit::WebProcessProxy::createWebPage):
2821         (WebKit::WebProcessProxy::addBackForwardItem):
2822         (WebKit::WebProcessProxy::fetchWebsiteData):
2823         * UIProcess/WebsiteData/WebsiteDataRecord.cpp:
2824         (WebKit::WebsiteDataRecord::add):
2825         * UIProcess/WebsiteData/WebsiteDataStore.cpp:
2826         (WebKit::WebsiteDataStore::create):
2827         (WebKit::WebsiteDataStore::WebsiteDataStore):
2828         (WebKit::WebsiteDataStore::fetchData):
2829         (WebKit::WebsiteDataStore::removeData):
2830         (WebKit::WebsiteDataStore::mediaKeyOrigins):
2831         * UIProcess/efl/InputMethodContextEfl.cpp:
2832         (WebKit::InputMethodContextEfl::InputMethodContextEfl):
2833         * UIProcess/efl/InputMethodContextEfl.h:
2834         (WebKit::InputMethodContextEfl::create):
2835         * UIProcess/efl/WebContextMenuProxyEfl.cpp:
2836         (WebKit::WebContextMenuProxyEfl::showContextMenu):
2837         * UIProcess/efl/WebUIPopupMenuClient.cpp:
2838         (WebUIPopupMenuClient::showPopupMenu):
2839         * UIProcess/gtk/InputMethodFilter.cpp:
2840         (WebKit::InputMethodFilter::filterKeyEvent):
2841         * UIProcess/gtk/KeyBindingTranslator.cpp:
2842         (WebKit::KeyBindingTranslator::commandsForKeyEvent):
2843         * UIProcess/gtk/RedirectedXCompositeWindow.cpp:
2844         (WebKit::XDamageNotifier::add):
2845         (WebKit::RedirectedXCompositeWindow::RedirectedXCompositeWindow):
2846         (WebKit::RedirectedXCompositeWindow::surface):
2847         * UIProcess/ios/WKActionSheetAssistant.mm:
2848         (-[WKActionSheetAssistant showImageSheet]):
2849         (-[WKActionSheetAssistant showLinkSheet]):
2850         * UIProcess/ios/WKContentView.mm:
2851         (-[WKContentView _commonInitializationWithProcessPool:configuration:]):
2852         (-[WKContentView initWithFrame:processPool:configuration:webView:]):
2853         * UIProcess/ios/WKContentViewInteraction.mm:
2854         (-[WKContentView actionSheetAssistant:decideActionsForElement:defaultActions:]):
2855         * UIProcess/ios/WKGeolocationProviderIOS.mm:
2856         (-[WKGeolocationProviderIOS geolocationAuthorizationGranted]):
2857         (-[WKGeolocationProviderIOS geolocationAuthorizationDenied]):
2858         * UIProcess/ios/WKPDFView.mm:
2859         (-[WKPDFView actionSheetAssistant:decideActionsForElement:defaultActions:]):
2860         * UIProcess/ios/WebPageProxyIOS.mm:
2861         (WebKit::WebPageProxy::selectWithGesture):
2862         (WebKit::WebPageProxy::updateSelectionWithTouches):
2863         (WebKit::WebPageProxy::requestAutocorrectionData):
2864         (WebKit::WebPageProxy::applyAutocorrection):
2865         (WebKit::WebPageProxy::executeEditCommand):
2866         (WebKit::WebPageProxy::selectTextWithGranularityAtPoint):
2867         (WebKit::WebPageProxy::selectPositionAtBoundaryWithDirection):
2868         (WebKit::WebPageProxy::moveSelectionAtBoundaryWithDirection):
2869         (WebKit::WebPageProxy::selectPositionAtPoint):
2870         (WebKit::WebPageProxy::beginSelectionInDirection):
2871         (WebKit::WebPageProxy::updateSelectionWithExtentPoint):
2872         (WebKit::WebPageProxy::updateSelectionWithExtentPointAndBoundary):
2873         (WebKit::WebPageProxy::requestDictationContext):
2874         (WebKit::WebPageProxy::requestAutocorrectionContext):
2875         (WebKit::WebPageProxy::getLookupContextAtPoint):
2876         (WebKit::WebPageProxy::selectWithTwoTouches):
2877         (WebKit::WebPageProxy::moveSelectionByOffset):
2878         (WebKit::WebPageProxy::focusNextAssistedNode):
2879         * UIProcess/ios/WebVideoFullscreenManagerProxy.h:
2880         * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
2881         (WebKit::WebVideoFullscreenManagerProxy::createModelAndInterface):
2882         * UIProcess/ios/forms/WKFileUploadPanel.mm:
2883         (-[WKFileUploadPanel _chooseFiles:displayString:iconImage:]):
2884         * UIProcess/mac/LegacySessionStateCoding.cpp:
2885         (WebKit::HistoryEntryDataEncoder::finishEncoding):
2886         (WebKit::decodeFormData):
2887         (WebKit::decodeBackForwardTreeNode):
2888         (WebKit::decodeSessionHistoryEntries):
2889         * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
2890         (WebKit::RemoteLayerTreeDrawingAreaProxy::dispatchAfterEnsuringDrawing):
2891         * UIProcess/mac/ViewGestureController.h:
2892         (WebKit::ViewGestureController::setCustomSwipeViews):
2893         * UIProcess/mac/ViewGestureControllerMac.mm:
2894         (WebKit::ViewGestureController::PendingSwipeTracker::PendingSwipeTracker):
2895         * UIProcess/mac/ViewSnapshotStore.mm:
2896         (WebKit::ViewSnapshot::create):
2897         (WebKit::ViewSnapshot::ViewSnapshot):
2898         (WebKit::ViewSnapshot::setSurface):
2899         * UIProcess/mac/WebPageProxyMac.mm:
2900         (WebKit::WebPageProxy::attributedSubstringForCharacterRangeAsync):
2901         (WebKit::WebPageProxy::fontAtSelection):
2902         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
2903         (contextMenuItems):
2904         (WKBundlePageCopyOriginsWithApplicationCache):
2905         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
2906         (WKBundlePageOverlayCreate):
2907         * WebProcess/InjectedBundle/API/efl/ewk_extension.cpp:
2908         (EwkExtension::didCreatePage):
2909         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
2910         (webkitFrameGetOrCreate):
2911         (didInitiateLoadForResource):
2912         (willSendRequestForFrame):
2913         (didReceiveResponseForResource):
2914         (didReceiveContentLengthForResource):
2915         (didFinishLoadForResource):
2916         (didFailLoadForResource):
2917         (webkitWebPageDidReceiveMessage):
2918         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
2919         (-[WKWebProcessPlugInBrowserContextController _setFormDelegate:]):
2920         * WebProcess/InjectedBundle/InjectedBundle.cpp:
2921         (WebKit::InjectedBundle::addUserScript):
2922         (WebKit::InjectedBundle::addUserStyleSheet):
2923         * WebProcess/InjectedBundle/InjectedBundleBackForwardListItem.cpp:
2924         (WebKit::InjectedBundleBackForwardListItem::children):
2925         * WebProcess/InjectedBundle/InjectedBundlePageContextMenuClient.cpp:
2926         (WebKit::InjectedBundlePageContextMenuClient::getCustomMenuFromDefaultItems):
2927         * WebProcess/InjectedBundle/InjectedBundlePageFormClient.cpp:
2928         (WebKit::InjectedBundlePageFormClient::willSendSubmitEvent):
2929         (WebKit::InjectedBundlePageFormClient::willSubmitForm):
2930         (WebKit::InjectedBundlePageFormClient::didAssociateFormControls):
2931         * WebProcess/InjectedBundle/InjectedBundlePageResourceLoadClient.cpp:
2932         (WebKit::InjectedBundlePageResourceLoadClient::willSendRequestForFrame):
2933         * WebProcess/Network/WebResourceLoader.cpp:
2934         (WebKit::WebResourceLoader::willSendRequest):
2935         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
2936         (WebKit::NPN_PostURL):
2937         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2938         (WebKit::NetscapePlugin::scheduleTimer):
2939         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2940         (WebKit::convertStringToKeyCodes):
2941         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.mm:
2942         (WebKit::PDFPlugin::PDFPlugin):
2943         * WebProcess/Plugins/PDF/PDFPlugin.mm:
2944         (-[WKPDFHUDAnimationDelegate initWithAnimationCompletionHandler:]):
2945         * WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.mm:
2946         (WebKit::PDFPluginChoiceAnnotation::createAnnotationElement):
2947         * WebProcess/Storage/StorageAreaMap.cpp:
2948         (WebKit::StorageAreaMap::create):
2949         (WebKit::StorageAreaMap::StorageAreaMap):
2950         * WebProcess/Storage/StorageNamespaceImpl.cpp:
2951         (WebKit::StorageNamespaceImpl::storageArea):
2952         * WebProcess/UserContent/WebUserContentController.cpp:
2953         (WebKit::WebUserContentController::addUserContentExtensions):
2954         * WebProcess/WebCoreSupport/SessionStateConversion.cpp:
2955         (WebKit::toHTTPBody):
2956         (WebKit::toFrameState):
2957         (WebKit::applyFrameState):
2958         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2959         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
2960         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
2961         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
2962         (WebKit::WebFrameLoaderClient::dispatchWillSubmitForm):
2963         (WebKit::WebFrameLoaderClient::contentFilterDidBlockLoad):
2964         * WebProcess/WebCoreSupport/WebPasteboardOverrides.cpp:
2965         (WebKit::WebPasteboardOverrides::addOverride):
2966         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp:
2967         (WebKit::WebEditorClient::executePendingEditorCommands):
2968         * WebProcess/WebPage/FindController.cpp:
2969         (WebKit::FindController::findStringMatches):
2970         * WebProcess/WebPage/ViewUpdateDispatcher.cpp:
2971         (WebKit::ViewUpdateDispatcher::dispatchVisibleContentRectUpdate):
2972         * WebProcess/WebPage/WebFrame.cpp:
2973         (WebKit::WebFrame::createSubframe):
2974         (WebKit::WebFrame::create):
2975         (WebKit::WebFrame::WebFrame):
2976         (WebKit::WebFrame::didReceivePolicyDecision):
2977         (WebKit::WebFrame::childFrames):
2978         (WebKit::WebFrame::createSelectionSnapshot):
2979         * WebProcess/WebPage/WebPage.cpp:
2980         (WebKit::WebPage::setInjectedBundleContextMenuClient):
2981         (WebKit::WebPage::setInjectedBundleFormClient):
2982         (WebKit::WebPage::setInjectedBundleUIClient):
2983         (WebKit::WebPage::trackedRepaintRects):
2984         (WebKit::WebPage::createDocumentLoader):
2985         * WebProcess/WebPage/WebPageGroupProxy.cpp:
2986         (WebKit::WebPageGroupProxy::addUserContentExtension):
2987         * WebProcess/WebPage/WebPageOverlay.cpp:
2988         (WebKit::WebPageOverlay::create):
2989         (WebKit::WebPageOverlay::WebPageOverlay):
2990         * WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
2991         (WebKit::LayerTreeHostGtk::RenderFrameScheduler::RenderFrameScheduler):
2992         * WebProcess/WebPage/ios/WebPageIOS.mm:
2993         (WebKit::WebPage::computePagesForPrintingAndStartDrawingToPDF):
2994         * WebProcess/WebPage/mac/PlatformCAAnimationRemote.mm:
2995         (WebKit::PlatformCAAnimationRemote::setTimingFunction):
2996         (WebKit::PlatformCAAnimationRemote::setValues):
2997         (WebKit::PlatformCAAnimationRemote::setTimingFunctions):
2998         * WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:
2999         (WebKit::RemoteLayerTreeContext::layerWasCreated):
3000         (WebKit::RemoteLayerTreeContext::buildTransaction):
3001         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
3002         (WebKit::RemoteLayerTreeDrawingArea::flushLayers):
3003         (WebKit::RemoteLayerTreeDrawingArea::BackingStoreFlusher::create):
3004         (WebKit::RemoteLayerTreeDrawingArea::BackingStoreFlusher::BackingStoreFlusher):
3005         (WebKit::RemoteLayerTreeDrawingArea::BackingStoreFlusher::flush):
3006         * WebProcess/WebProcess.cpp:
3007         (WebKit::WebProcess::initializeWebProcess):
3008         (WebKit::WebProcess::transformObjectsToHandles):
3009         * WebProcess/cocoa/WebProcessCocoa.mm:
3010         (WebKit::WebProcess::platformInitializeWebProcess):
3011         * WebProcess/ios/WebVideoFullscreenManager.mm:
3012         (WebKit::WebVideoFullscreenInterfaceContext::setLayerHostingContext):
3013         (WebKit::WebVideoFullscreenManager::createModelAndInterface):
3014         (WebKit::WebVideoFullscreenManager::setSeekableRanges):
3015         * WebProcess/soup/WebKitSoupRequestInputStream.cpp:
3016         (webkitSoupRequestInputStreamDidFailWithError):
3017
3018 2016-01-01  Simon Fraser  <simon.fraser@apple.com>
3019
3020         Fix the iOS and EFL builds, after an over-eager commit-queue commit.
3021
3022         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3023         (WebKit::WebFrameLoaderClient::restoreViewState):
3024         * WebProcess/WebPage/efl/WebPageEfl.cpp:
3025         (WebKit::WebPage::restorePageState):
3026
3027 2016-01-01  Simon Fraser  <simon.fraser@apple.com>
3028
3029         Fix naming in HistoryItem to refer to scrollPositions
3030         https://bugs.webkit.org/show_bug.cgi?id=152646
3031
3032         Reviewed by Zalan Bujtas.
3033         
3034         HistoryItem stores a scrollPosition, so call it that.
3035         
3036         No behavior change.
3037
3038         * Shared/SessionState.cpp:
3039         (WebKit::FrameState::encode):
3040         (WebKit::FrameState::decode):
3041         * Shared/SessionState.h:
3042         * UIProcess/mac/LegacySessionStateCoding.cpp:
3043         (WebKit::encodeFrameStateNode):
3044         (WebKit::decodeBackForwardTreeNode):
3045         * WebProcess/WebCoreSupport/SessionStateConversion.cpp:
3046         (WebKit::toFrameState):
3047         (WebKit::applyFrameState):
3048
3049 2016-01-01  Simon Fraser  <simon.fraser@apple.com>
3050
3051         Fix reload and programmatic scrolling in RTL documents
3052         https://bugs.webkit.org/show_bug.cgi?id=152639
3053
3054         Reviewed by Zalan Bujtas.
3055
3056         Reloading a left-scrolled RTL document would cause the content to appear
3057         at an odd offset, and programmatic sideways scrolls in RTL documents also
3058         jumped to the wrong location.
3059         
3060         Fix by resolving offset/position confusion in ScrollableArea::scrollPositionChanged()
3061         and the scrolling tree.
3062         
3063         ScrollableArea::scrollPositionChanged() was erroneously passing a scrollPosition
3064         to setScrollOffset(). 
3065         
3066         ScrollingTreeFrameScrollingNode* were confused about offsets and positions. It
3067         turns out that the layer position is just -scrollPosition, but minimumScrollPosition()
3068         and maximumScrollPosition() need fixing to return positions, not offsets.
3069         
3070         ScrollingTreeFrameScrollingNode::viewToContentsOffset() was also doing incorrect
3071         math with scrollOrigin, which was detected by a failing test.
3072         
3073         Add more logging to the Scrolling channel.
3074
3075         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.h:
3076         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.mm:
3077         (WebKit::PDFPlugin::setScrollOffset):
3078
3079 2016-01-01  Michael Catanzaro  <mcatanzaro@igalia.com>
3080
3081         [SOUP] REGRESSION(r192761): Broke resource URIs for applications that use g_resource_load in a web extension
3082         https://bugs.webkit.org/show_bug.cgi?id=152634
3083
3084         Reviewed by Carlos Garcia Campos.
3085
3086         Load GResource URIs locally, not in the network process. Applications expect calling
3087         g_resource_load in a web extension to make it possible to load resource URIs, but that
3088         doesn't work now that the network process is in use. Loading them locally solves this.
3089
3090         * WebProcess/Network/WebLoaderStrategy.cpp:
3091         (WebKit::WebLoaderStrategy::scheduleLoad):
3092
3093 2016-01-01  Jeff Miller  <jeffm@apple.com>
3094
3095         Update user-visible copyright strings to include 2016
3096         https://bugs.webkit.org/show_bug.cgi?id=152531
3097
3098         Reviewed by Alexey Proskuryakov.
3099
3100         * DatabaseProcess/EntryPoint/mac/LegacyProcess/Info.plist:
3101         * DatabaseProcess/EntryPoint/mac/XPCService/DatabaseService.Development/Info.plist:
3102         * DatabaseProcess/EntryPoint/mac/XPCService/DatabaseService/Info.plist:
3103         * Info.plist:
3104         * NetworkProcess/EntryPoint/mac/LegacyProcess/Info.plist:
3105         * NetworkProcess/EntryPoint/mac/XPCService/NetworkService.Development/Info-OSX.plist:
3106         * NetworkProcess/EntryPoint/mac/XPCService/NetworkService.Development/Info-iOS.plist:
3107         * NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info-OSX-10.9-10.10.plist:
3108         * NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info-OSX.plist:
3109         * NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info-iOS.plist:
3110         * PluginProcess/EntryPoint/mac/LegacyProcess/Info.plist:
3111         * PluginProcess/EntryPoint/mac/XPCService/PluginService.32-64-10.9-10.10.Info.plist:
3112         * PluginProcess/EntryPoint/mac/XPCService/PluginService.32-64.Info.plist:
3113         * PluginProcess/EntryPoint/mac/XPCService/PluginService.Development/Info.plist:
3114         * WebProcess/EntryPoint/mac/LegacyProcess/Info.plist:
3115         * WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/Info-OSX.plist:
3116         * WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/Info-iOS.plist:
3117         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX-10.9-10.10.plist:
3118         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX.plist:
3119         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-iOS.plist:
3120
3121 2015-12-31  Simon Fraser  <simon.fraser@apple.com>
3122
3123         Rename documentScrollOffsetRelativeTo* functions
3124         https://bugs.webkit.org/show_bug.cgi?id=152632
3125
3126         Reviewed by Zalan Bujtas.
3127
3128         ScrollView::documentScrollOffsetRelativeTo* functions return scroll positions,
3129         not offsets, so rename them and fix their return types, and fix callers. Make
3130         their code more similar.
3131
3132         * WebProcess/WebPage/WebPage.cpp:
3133         (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
3134         (WebKit::WebPage::plugInIntersectsSearchRect):
3135
3136 2015-12-31  Simon Fraser  <simon.fraser@apple.com>
3137
3138         [iOS WK2] Fix incorrect scrollPosition handling
3139         https://bugs.webkit.org/show_bug.cgi?id=152630
3140
3141         Reviewed by Zalan Bujtas.
3142         
3143         WebPage::updateVisibleContentRects() was setting the ScrollView's scroll position
3144         to a scrollOffset, which was counteracted by ScrollView::unobscuredContentRect()
3145         adding the scrollOrigin to the scrollPosition, which resulted in the correct
3146         rects, but an incorrect scrollPosition. Fix.
3147
3148         * WebProcess/WebPage/ios/WebPageIOS.mm:
3149         (WebKit::WebPage::updateVisibleContentRects):
3150
3151 2015-12-31  Michael Catanzaro  <mcatanzaro@igalia.com>
3152
3153         Unreviewed, fix a log message
3154
3155         * WebProcess/Network/WebResourceLoader.cpp:
3156         (WebKit::WebResourceLoader::didReceiveResponse):
3157
3158 2015-12-31  David Kilzer  <ddkilzer@apple.com>
3159
3160         Stop using USE(CFNETWORK) path on iOS
3161         https://bugs.webkit.org/show_bug.cgi?id=142540
3162
3163         Step 1/2: Do everything but turn off USE(CFNETWORK) internally.
3164
3165         Original patch by Antti Koivisto <antti@apple.com> on 2015-03-10
3166         Reviewed by Daniel Bates.
3167
3168         * NetworkProcess/Downloads/ios/DownloadIOS.mm: This is now the
3169         USE(CFNETWORK) && !USE(NETWORK_SESSION) code path.
3170         * NetworkProcess/Downloads/mac/DownloadMac.mm: This is now the
3171         !USE(CFNETWORK) && !USE(NETWORK_SESSION) code path.  Make use of
3172         NSURLDownloadSPI.h.  Ignore a deprecated delcaration warning now
3173         that we're using actual header declarations internally.
3174         * NetworkProcess/NetworkProcess.cpp:
3175         (WebKit::NetworkProcess::initializeNetworkProcess): Update for
3176         iOS to use NSURLConnection loader.
3177
3178 2015-12-31  Andy Estes  <aestes@apple.com>
3179
3180         Fix warnings uncovered by migrating to WTF_MOVE
3181         https://bugs.webkit.org/show_bug.cgi?id=152601
3182
3183         Reviewed by Daniel Bates.
3184
3185         * UIProcess/API/APIUIClient.h:
3186         (API::UIClient::actionsForElement): Moving a return value passed to the function by value is redundant, since it
3187         will be implicitly moved in this case.
3188         * UIProcess/Cocoa/UIDelegate.mm:
3189         (WebKit::UIDelegate::UIClient::actionsForElement): Ditto.
3190
3191 2015-12-30  Simon Fraser  <simon.fraser@apple.com>
3192
3193         Add explicit conversions between scrollOffset and scrollPostion, and use them in a few places
3194         https://bugs.webkit.org/show_bug.cgi?id=152594
3195
3196         Reviewed by Sam Weinig.
3197
3198         Add functions to ScrollableArea to convert between scrollPosition and scrollOffset,
3199         and use them in places where code did the math with scrollOrigin.
3200
3201         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
3202         (WebKit::RemoteLayerTreeDrawingArea::updateScrolledExposedRect):
3203         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
3204         (WebKit::TiledCoreAnimationDrawingArea::updateScrolledExposedRect):
3205
3206 2015-12-30  Zan Dobersek  <zdobersek@igalia.com>
3207
3208         [TexMap] Clean up TextureMapperAnimation, TextureMapperAnimations
3209         https://bugs.webkit.org/show_bug.cgi?id=152112
3210
3211         Reviewed by Darin Adler.
3212
3213         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
3214         (IPC::ArgumentCoder<TextureMapperAnimation>::decode):
3215
3216 2015-12-29  Simon Fraser  <simon.fraser@apple.com>
3217
3218         Remove ScrollView::scrollOffset() in preparation for scrollOffset vs. scrollPosition clarification
3219         https://bugs.webkit.org/show_bug.cgi?id=152589
3220
3221         Reviewed by Sam Weinig.
3222
3223         Current code uses scrollOffset vs. scrollPosition interchangeably, and confusingly.
3224         Longer term, I plan to make "scrollPosition" be the value that is relative to the 
3225         contents, i.e. affected by scrollOrigin, and "scrollOffset" be the zero-based value
3226         that's used to set scrollbar values.
3227         
3228         To prepare for this, remove ScrollView::scrollOffset(), which is just the
3229         scrollPosition as an IntSize.
3230         
3231         Add some typedefs in ScrollableArea, which will slowly propagate through the
3232         code as position vs. offset is clarified.
3233
3234         * WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.cpp:
3235         (WebKit::InjectedBundleRangeHandle::renderedImage):
3236         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.h:
3237         * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.mm:
3238         (WebKit::PDFPlugin::scrollPosition):
3239         (WebKit::PDFPlugin::minimumScrollPosition):
3240         (WebKit::PDFPlugin::maximumScrollPosition):
3241         * WebProcess/WebPage/WebFrame.cpp:
3242         (WebKit::WebFrame::scrollOffset):
3243         * WebProcess/WebPage/WebPage.cpp:
3244         (WebKit::WebPage::scrollMainFrameIfNotAtMaxScrollPosition):
3245         (WebKit::WebPage::updateMainFrameScrollOffsetPinning):
3246
3247 2015-12-25  Andy Estes  <aestes@apple.com>
3248
3249         Stop moving local objects in return statements
3250         https://bugs.webkit.org/show_bug.cgi?id=152557
3251
3252         Reviewed by Brady Eidson.
3253
3254         Calling std::move() on a local object in a return statement prevents the compiler from applying the return value optimization.
3255
3256         Clang can warn about these mistakes with -Wpessimizing-move, although only when std::move() is called directly.
3257         I found these issues by temporarily replacing WTF::move with std::move and recompiling.
3258
3259         * UIProcess/WebPageProxy.cpp:
3260         (WebKit::ExceededDatabaseQuotaRecords::createRecord):
3261
3262 2015-12-26  Joonghun Park  <jh718.park@samsung.com>
3263
3264         [WK2][EFL] Use eina_file_path_join at platformDefaultIconDatabasePath in WebProcessPoolEfl
3265         https://bugs.webkit.org/show_bug.cgi?id=152565
3266
3267         Reviewed by Gyuyoung Kim.
3268
3269         Use eina_file_path_join and EINA_PATH_SEP_S at platformDefaultIconDatabasePath
3270         instead of operator+ and separator "/" respectively
3271         to concatenate paths.
3272
3273         * UIProcess/API/efl/APIWebsiteDataStoreEfl.cpp:
3274         * UIProcess/efl/WebProcessPoolEfl.cpp:
3275         (WebKit::WebProcessPool::platformDefaultIconDatabasePath):
3276
3277 2015-12-25  David Kilzer  <ddkilzer@apple.com>
3278
3279         ResourceError should store failingURL as URL instead of String to avoid reparsing and to address FIXME comments in ResourceErrorCF.cpp and ResourceErrorMac.mm
3280         <http://webkit.org/b/146391>
3281
3282         Reviewed by Antti Koivisto.
3283
3284         * NetworkProcess/Downloads/efl/DownloadSoupErrorsEfl.cpp:
3285         (WebKit::platformDownloadNetworkError):
3286         * NetworkProcess/Downloads/gtk/DownloadSoupErrorsGtk.cpp:
3287         (WebKit::platformDownloadNetworkError):
3288         * NetworkProcess/Downloads/soup/DownloadSoup.cpp:
3289         (WebKit::DownloadClient::didReceiveResponse):
3290         * NetworkProcess/Downloads/soup/DownloadSoupErrors.h:
3291         * Shared/soup/WebCoreArgumentCodersSoup.cpp:
3292         (IPC::ArgumentCoder<ResourceError>::encodePlatformData):
3293         (IPC::ArgumentCoder<ResourceError>::decodePlatformData):
3294         * UIProcess/API/gtk/WebKitLoaderClient.cpp:
3295         (LoaderClient::didFailProvisionalLoadWithErrorForFrame):
3296         (LoaderClient::didFailLoadWithErrorForFrame):
3297         * UIProcess/API/gtk/WebKitURISchemeRequest.cpp:
3298         (webkit_uri_scheme_request_finish_error):
3299         * WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp:
3300         (WebKit::internalError):
3301         * WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp:
3302         (WebKit::internalError):
3303         - Update for type change of 'failingURL' argument to
3304           ResourceError().
3305
3306 2015-12-23  Simon Fraser  <simon.fraser@apple.com>
3307
3308         Use "constrainedBetween" in more places
3309         https://bugs.webkit.org/show_bug.cgi?id=152543
3310
3311         Reviewed by Zalan Bujtas.
3312
3313         Replace code that contrains points via shrunkTo/expandedTo() with calls
3314         to constrainedBetween(), and implement constrainedBetween() on IntPoint,
3315         FloatPoint and LayoutPoint.
3316
3317         Convert some functions that return points to more modern syntax.
3318
3319         * UIProcess/API/Cocoa/WKWebView.mm:
3320         (constrainContentOffset):
3321
3322 2015-12-22  Hunseop Jeong  <hs85.jeong@samsung.com>
3323
3324         [EFL] ewk_application_cache_manager test failed after r193812
3325         https://bugs.webkit.org/show_bug.cgi?id=152498
3326
3327         Reviewed by Gyuyoung Kim.
3328
3329         Need to enable the offline_web_application_cache for the ewk_application_cache_manager test.
3330
3331         * UIProcess/API/efl/tests/test_ewk2_application_cache_manager.cpp:
3332         (TEST_F):
3333
3334 2015-12-22  Andy Estes  <aestes@apple.com>
3335
3336         [CF] Replace CFNetwork-related WebKitSystemInterface calls with SPI
3337         https://bugs.webkit.org/show_bug.cgi?id=152463
3338
3339         Reviewed by Alexey Proskuryakov.
3340
3341         Replaced WebkitSystemInterface calls that wrapped CFNetwork SPI with direct calls to SPI that is now forward
3342         declared in CFNetworkSPI.h.
3343
3344         * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
3345         (WebKit::initializeNetworkSettings):
3346         * NetworkProcess/mac/NetworkProcessMac.mm:
3347         (WebKit::overrideSystemProxies):
3348         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
3349         (WebKit::WebFrameNetworkingContext::setCookieAcceptPolicyForAllContexts):
3350         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3351         (InitWebCoreSystemInterface):
3352
3353 2015-12-22  Brent Fulgham  <bfulgham@apple.com>
3354
3355         Allow JavaScript to iterate over plugins for local SecurityOrigins
3356         https://bugs.webkit.org/show_bug.cgi?id=152489
3357
3358         Reviewed by Alexey Proskuryakov.
3359
3360         The 'getWebVisiblePluginInfo' is filtering plugins, even when we want to list
3361         all plugins. To avoid this, we check the Document's SecurityOrigin. If no such
3362         origin exists, we construct a SecurityOrigin from the URL.
3363         
3364         If the relevant SecurityOrigin satsifies 'isLocal', we show all plugins.
3365
3366         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
3367         (WebKit::WebPlatformStrategies::getWebVisiblePluginInfo):
3368
3369 2015-12-21  Hunseop Jeong  <hs85.jeong@samsung.com>
3370
3371         [EFL] test_ewk2_context failed after r192808
3372         https://bugs.webkit.org/show_bug.cgi?id=151846
3373
3374         Reviewed by Gyuyoung Kim.
3375
3376         As we can make the single WebProcess behavior by setting the miximum number
3377         of WebProcess to 1 after r192808, I remove the ewk_context_process_model_{set|get}
3378         apis and add the ewk_context_web_process_count_limit_{set|get} apis and tests.
3379
3380         * UIProcess/API/efl/ewk_context.cpp:
3381         (EwkContext::EwkContext):
3382         (EwkContext::setProcessCountLimit):
3383         (EwkContext::processCountLimit):
3384         (ewk_context_web_process_count_limit_set):
3385         (ewk_context_web_process_count_limit_get):
3386         (EwkContext::setProcessModel): Deleted.
3387         (EwkContext::processModel): Deleted.
3388         (ewk_context_process_model_set): Deleted.
3389         (ewk_context_process_model_get): Deleted.
3390         * UIProcess/API/efl/ewk_context.h:
3391         * UIProcess/API/efl/ewk_context_private.h:
3392         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.cpp:
3393         (EWK2UnitTest::EWK2UnitTestBase::SetUp):
3394         * UIProcess/API/efl/tests/test_ewk2_context.cpp:
3395         (TEST_F): Changed the ewk_context_{web|network}_process_model tests to
3396         ewk_context_{web|network}_process_count_limit tests.
3397
3398 2015-12-21  Joonghun Park  <jh718.park@samsung.com>
3399
3400         [WK2][EFL] Use cacheDirectoryFileSystemRepresentation and websiteDataDirectoryFileSystemRepresentation
3401         to refactor APIWebsiteDataStoreEfl
3402         https://bugs.webkit.org/show_bug.cgi?id=152475
3403
3404         Reviewed by Gyuyoung Kim.
3405
3406         Use cacheDirectoryFileSystemRepresentation and websiteDataDirectoryFileSystemRepresentation
3407         instead of to use efreet_cache_home_get
3408         and efreet_data_home_get directly.
3409         And also use EINA_PATH_SEP_S instead of "/" as directory separator,
3410         and WebCore::pathByAppendingComponent instead of operator+.
3411
3412         * UIProcess/API/efl/APIWebsiteDataStoreEfl.cpp:
3413         (API::WebsiteDataStore::defaultApplicationCacheDirectory):
3414         (API::WebsiteDataStore::defaultNetworkCacheDirectory):
3415         (API::WebsiteDataStore::defaultIndexedDBDatabaseDirectory):
3416         (API::WebsiteDataStore::defaultLocalStorageDirectory):
3417         (API::WebsiteDataStore::defaultMediaKeysStorageDirectory):
3418         (API::WebsiteDataStore::defaultWebSQLDatabaseDirectory):
3419         (API::WebsiteDataStore::cacheDirectoryFileSystemRepresentation):
3420         (API::WebsiteDataStore::websiteDataDirectoryFileSystemRepresentation):
3421
3422 2015-12-21  Antti Koivisto  <antti@apple.com>
3423
3424         Factor NetworkResourceLoader code for storing a cache entry into a function
3425         https://bugs.webkit.org/show_bug.cgi?id=152467
3426
3427         Reviewed by Andreas Kling.
3428
3429         * NetworkProcess/NetworkResourceLoader.cpp:
3430         (WebKit::NetworkResourceLoader::didFinishLoading):
3431
3432             Having m_cacheEntryForValidation already implies canUseCache() so remove the test from this path.
3433             Move storing to the end of the function so we don't delay DidFinishResourceLoad message on it.
3434
3435         (WebKit::NetworkResourceLoader::sendBufferMaybeAborting):
3436         (WebKit::NetworkResourceLoader::tryStoreAsCacheEntry):
3437
3438             Factor to a function.
3439             Remove m_response.isHTTP() test as it is covered by NetworkCache::store().
3440             Remove !isPrivateSession test as it is covered by NetworkResourceLoader::canUseCache().
3441
3442         (WebKit::NetworkResourceLoader::didRetrieveCacheEntry):
3443         * NetworkProcess/NetworkResourceLoader.h:
3444
3445 2015-12-21  Antti Koivisto  <antti@apple.com>
3446
3447         Limit cached redirect chain length
3448         https://bugs.webkit.org/show_bug.cgi?id=152477
3449
3450         Reviewed by Andreas Kling.
3451
3452         Networking layer prevents cycles and limits the redirect chain length so creating cache cycles is difficult.
3453         For robustness the network cache should still limit the maximum redirect chain length.
3454
3455         This patch adds a limit of five redirects both when storing and retrieving cache entries.
3456
3457         * NetworkProcess/NetworkResourceLoader.cpp:
3458         (WebKit::NetworkResourceLoader::canUseCache):
3459         (WebKit::NetworkResourceLoader::canUseCachedRedirect):
3460         (WebKit::NetworkResourceLoader::willSendRedirectedRequest):
3461         (WebKit::NetworkResourceLoader::continueWillSendRequest):
3462         (WebKit::NetworkResourceLoader::dispatchWillSendRequestForCacheEntry):
3463         * NetworkProcess/NetworkResourceLoader.h:
3464
3465 2015-12-21  Dan Bernstein  <mitz@apple.com>
3466
3467         Different and incorrect flags are passed to sendSync when accessibility is enabled, SpinRunLoopWhileWaitingForReply
3468         https://bugs.webkit.org/show_bug.cgi?id=126021
3469
3470         Reviewed by Darin Adler.
3471
3472         Get rid of SpinRunLoopWhileWaitingForReply because it’s not used anymore.
3473
3474         * Platform/IPC/Connection.cpp:
3475         (IPC::Connection::waitForSyncReply): Removed the SpinRunLoopWhileWaitingForReply branch.
3476
3477         * Platform/IPC/Connection.h: Removed SpinRunLoopWhileWaitingForReply.
3478
3479         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3480         (WebKit::WebChromeClient::runBeforeUnloadConfirmPanel): Don’t check
3481           WebPage::synchronousMessagesShouldSpinRunLoop() and don’t specify
3482           SpinRunLoopWhileWaitingForReply.
3483         (WebKit::WebChromeClient::runJavaScriptAlert): Ditto.
3484         (WebKit::WebChromeClient::runJavaScriptConfirm): Ditto.
3485         (WebKit::WebChromeClient::runJavaScriptPrompt): Ditto.
3486         (WebKit::WebChromeClient::print): Ditto.
3487         (WebKit::WebChromeClient::exceededDatabaseQuota): Ditto.
3488         (WebKit::WebChromeClient::reachedApplicationCacheOriginQuota): Ditto.
3489
3490         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3491         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse): Ditto.
3492
3493         * WebProcess/WebPage/WebPage.cpp:
3494         (WebKit::WebPage::synchronousMessagesShouldSpinRunLoop): Deleted.
3495         * WebProcess/WebPage/WebPage.h:
3496
3497 2015-12-20  Joonghun Park  <jh718.park@samsung.com>
3498
3499         [WK2][EFL] Use WebsiteDataStore instead of WebDatabaseManager which has been deleted in r194295
3500         https://bugs.webkit.org/show_bug.cgi?id=152460
3501
3502         Reviewed by Gyuyoung Kim.
3503
3504         Use WebsiteDataStore to support EFL WebDatabase API and to fix build break.
3505
3506         * PlatformEfl.cmake:
3507         * UIProcess/API/APIWebsiteDataStore.cpp:
3508         * UIProcess/API/efl/APIWebsiteDataStoreEfl.cpp: Copied from Source/WebKit2/UIProcess/API/APIWebsiteDataStore.cpp.
3509         (API::WebsiteDataStore::defaultApplicationCacheDirectory):
3510         (API::WebsiteDataStore::defaultNetworkCacheDirectory):
3511         (API::WebsiteDataStore::defaultIndexedDBDatabaseDirectory):
3512         (API::WebsiteDataStore::defaultLocalStorageDirectory):
3513         (API::WebsiteDataStore::defaultMediaKeysStorageDirectory):
3514         (API::WebsiteDataStore::defaultWebSQLDatabaseDirectory):
3515         (API::WebsiteDataStore::cacheDirectoryFileSystemRepresentation):
3516         (API::WebsiteDataStore::websiteDataDirectoryFileSystemRepresentation):
3517         (API::WebsiteDataStore::defaultDataStoreConfiguration):
3518         * UIProcess/API/efl/ewk_context.cpp:
3519         (EwkContext::EwkContext):
3520         * UIProcess/API/efl/ewk_database_manager.cpp:
3521         (EwkDatabaseManager::EwkDatabaseManager):
3522         (EwkDatabaseManager::getDatabaseOrigins):
3523         * UIProcess/API/efl/ewk_database_manager_private.h:
3524         * UIProcess/efl/WebProcessPoolEfl.cpp:
3525         (WebKit::WebProcessPool::legacyPlatformDefaultApplicationCacheDirectory):
3526         (WebKit::WebProcessPool::legacyPlatformDefaultWebSQLDatabaseDirectory):
3527         (WebKit::WebProcessPool::legacyPlatformDefaultIndexedDBDatabaseDirectory):
3528         (WebKit::WebProcessPool::legacyPlatformDefaultLocalStorageDirectory):
3529         (WebKit::WebProcessPool::legacyPlatformDefaultMediaKeysStorageDirectory):
3530         (WebKit::WebProcessPool::legacyPlatformDefaultNetworkCacheDirectory):
3531
3532 2015-12-20  Dan Bernstein  <mitz@apple.com>
3533
3534         Remove unused setToolbarHeight
3535         https://bugs.webkit.org/show_bug.cgi?id=152466
3536
3537         Reviewed by Darin Adler.
3538
3539         * UIProcess/WebInspectorProxy.cpp:
3540         (WebKit::WebInspectorProxy::platformSetToolbarHeight): Deleted.
3541         * UIProcess/WebInspectorProxy.h:
3542         (WebKit::WebInspectorProxy::setToolbarHeight): Deleted.
3543         * UIProcess/WebInspectorProxy.messages.in:
3544         * UIProcess/efl/WebInspectorProxyEfl.cpp:
3545         (WebKit::WebInspectorProxy::platformSetToolbarHeight): Deleted.
3546         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
3547         (WebKit::WebInspectorProxy::platformSetToolbarHeight): Deleted.
3548         * UIProcess/mac/WebInspectorProxyMac.mm:
3549         (WebKit::WebInspectorProxy::platformSetToolbarHeight): Deleted.
3550         * WebProcess/WebPage/WebInspectorUI.cpp:
3551         (WebKit::WebInspectorUI::setToolbarHeight): Deleted.
3552         * WebProcess/WebPage/WebInspectorUI.h:
3553
3554 2015-12-19  Dan Bernstein  <mitz@apple.com>
3555
3556         [Mac] WebKit contains dead source code for OS X Mavericks and earlier
3557         https://bugs.webkit.org/show_bug.cgi?id=152462
3558
3559         Reviewed by Alexey Proskuryakov.
3560
3561         - Removed build setting definitions for OS X 10.9 and earlier, and simplified defintions
3562           that became uniform across all OS X versions as a result:
3563
3564         * Configurations/BaseTarget.xcconfig:
3565         * Configurations/BaseXPCService.xcconfig:
3566         * Configurations/DebugRelease.xcconfig:
3567         * Configurations/FeatureDefines.xcconfig:
3568         * Configurations/Version.xcconfig:
3569         * Configurations/WebKit.xcconfig:
3570
3571         - Removed the definition of BUNDLE_LOCALIZATION_KEY:
3572
3573         * Configurations/WebContentService.Development.xcconfig:
3574         * Configurations/WebContentService.xcconfig:
3575
3576         - Added CFBundleFollowParentLocalization set to true:
3577
3578         * WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/Info-OSX.plist:
3579         * WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/Info-iOS.plist:
3580         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX-10.9-10.10.plist:
3581         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX.plist:
3582         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-iOS.plist:
3583
3584         * WebKit2.xcodeproj/project.pbxproj: Removed the “Add CFBundle Localization Info.plist Key”
3585           script build phases from the Web Content Service targets.
3586
3587         - Simplified expressions involving __MAC_OS_X_VERSION_MIN_REQUIRED and removed code that was
3588           never getting compiled:
3589
3590         * DatabaseProcess/mac/com.apple.WebKit.Databases.sb.in:
3591         * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
3592         * NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in:
3593         * Platform/IPC/mac/ConnectionMac.mm:
3594         * Platform/IPC/mac/ImportanceAssertion.h:
3595         * Platform/mac/MenuUtilities.h:
3596         * Platform/mac/MenuUtilities.mm:
3597         * Platform/mac/StringUtilities.h:
3598         * Platform/mac/StringUtilities.mm:
3599         * Shared/API/Cocoa/WKFoundation.h:
3600         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.Development.mm:
3601         * UIProcess/API/Cocoa/WKViewPrivate.h:
3602         * UIProcess/API/Cocoa/WKWebView.mm:
3603         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3604         * UIProcess/API/mac/WKView.mm:
3605         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
3606         * UIProcess/Cocoa/WebViewImpl.h:
3607         * UIProcess/Cocoa/WebViewImpl.mm:
3608         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
3609         * UIProcess/mac/PageClientImpl.mm:
3610         * UIProcess/mac/WKImmediateActionController.h:
3611         * UIProcess/mac/WKImmediateActionController.mm:
3612         * UIProcess/mac/WebInspectorProxyMac.mm:
3613         * WebProcess/WebPage/FindController.cpp:
3614         * WebProcess/WebPage/WebPage.cpp:
3615         * WebProcess/com.apple.WebProcess.sb.in:
3616         * config.h:
3617
3618 2015-12-18  Antti Koivisto  <antti@apple.com>
3619
3620         Cache redirects as separate entries
3621         https://bugs.webkit.org/show_bug.cgi?id=152424
3622
3623         Reviewed by Alex Christensen.
3624
3625         We are currently caching redirect chains. This has correctness issues and can be inefficient in cases
3626         where multiple URLs redirect to the same destination.
3627
3628         After this patch we write a cache entry for each redirect individually.
3629
3630         * NetworkProcess/NetworkLoad.cpp:
3631         (WebKit::NetworkLoad::sharedWillSendRedirectedRequest):
3632         * NetworkProcess/NetworkLoad.h:
3633         (WebKit::NetworkLoad::currentRequest):
3634         (WebKit::NetworkLoad::clearCurrentRequest):
3635         * NetworkProcess/NetworkLoadClient.h:
3636
3637             Add original request as a parameter for willSendRedirectedRequest.
3638
3639         * NetworkProcess/NetworkResourceLoader.cpp:
3640         (WebKit::NetworkResourceLoader::~NetworkResourceLoader):
3641         (WebKit::NetworkResourceLoader::canUseCache):
3642
3643             Factor to a function.
3644
3645         (WebKit::NetworkResourceLoader::isSynchronous):
3646         (WebKit::NetworkResourceLoader::start):
3647         (WebKit::NetworkResourceLoader::retrieveCacheEntry):
3648
3649             Factor to a function.
3650             Call dispatchWillSendRequestForCacheEntry for cached redirects.
3651
3652         (WebKit::NetworkResourceLoader::startNetworkLoad):
3653
3654             Make this take request as argument instead of always loading originalRequest().
3655
3656         (WebKit::NetworkResourceLoader::abort):
3657         (WebKit::NetworkResourceLoader::didFinishLoading):
3658
3659             Remove redirect chain code.
3660             Store cache entry for current request instead of the original request.
3661
3662         (WebKit::NetworkResourceLoader::didFailLoading):
3663         (WebKit::NetworkResourceLoader::willSendRedirectedRequest):
3664
3665             Write cache entry for redirect.
3666
3667         (WebKit::NetworkResourceLoader::continueWillSendRequest):
3668
3669             If we are playing back cached redirect continue with another cache lookup.
3670
3671         (WebKit::NetworkResourceLoader::didRetrieveCacheEntry):
3672
3673             No need to synthesize fake willSendRequest anymore.
3674
3675         (WebKit::NetworkResourceLoader::validateCacheEntry):
3676         (WebKit::NetworkResourceLoader::dispatchWillSendRequestForCacheEntry):
3677
3678             Route via web process willSendRequest so cached redirects looks exactly like network ones.
3679
3680         (WebKit::NetworkResourceLoader::messageSenderConnection):
3681         * NetworkProcess/NetworkResourceLoader.h:
3682         * NetworkProcess/cache/NetworkCache.cpp:
3683         (WebKit::NetworkCache::makeUseDecision):
3684
3685             Ignore validation headers for cached redirects.
3686
3687         (WebKit::NetworkCache::makeRetrieveDecision):
3688         (WebKit::NetworkCache::makeStoreDecision):
3689         (WebKit::NetworkCache::Cache::retrieve):
3690         (WebKit::NetworkCache::Cache::store):
3691
3692             Rename originalRequest -> request since it is not really the original request anymore in all cases.
3693
3694         (WebKit::NetworkCache::Cache::storeRedirect):
3695
3696             Stored redirects include the network layer generated ResourceRequest instead of body data.
3697
3698         (WebKit::NetworkCache::Cache::update):
3699         * NetworkProcess/cache/NetworkCache.h:
3700         * NetworkProcess/cache/NetworkCacheEntry.cpp:
3701         (WebKit::NetworkCache::Entry::Entry):
3702
3703             New constructor for making redirect entries.
3704
3705         (WebKit::NetworkCache::Entry::encodeAsStorageRecord):
3706         (WebKit::NetworkCache::Entry::decodeStorageRecord):
3707
3708             Encoding support.
3709
3710         * NetworkProcess/cache/NetworkCacheEntry.h:
3711         (WebKit::NetworkCache::Entry::varyingRequestHeaders):
3712         (WebKit::NetworkCache::Entry::redirectRequest):
3713         * NetworkProcess/cache/NetworkCacheSpeculativeLoad.cpp:
3714         (WebKit::NetworkCache::SpeculativeLoad::~SpeculativeLoad):
3715         (WebKit::NetworkCache::SpeculativeLoad::willSendRedirectedRequest):
3716         * NetworkProcess/cache/NetworkCacheSpeculativeLoad.h:
3717         * NetworkProcess/cache/NetworkCacheStatistics.cpp:
3718         (WebKit::NetworkCache::cachedEntryReuseFailureToDiagnosticKey):
3719
3720 2015-12-18  Michael Catanzaro  <mcatanzaro@igalia.com>
3721
3722         Avoid triggering clang's -Wundefined-bool-conversion
3723         https://bugs.webkit.org/show_bug.cgi?id=152408
3724
3725         Reviewed by Mark Lam.
3726
3727         Use ASSERT_THIS_GC_OBJECT_INHERITS where needed.
3728
3729         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
3730         (WebKit::JSNPObject::callMethod):
3731         (WebKit::JSNPObject::callObject):
3732         (WebKit::JSNPObject::callConstructor):
3733         (WebKit::JSNPObject::deleteProperty):
3734
3735 2015-12-15  Anders Carlsson  <andersca@apple.com>
3736
3737         Get rid of WebDatabaseManager, it's been replaced by WebsiteDataStore
3738         https://bugs.webkit.org/show_bug.cgi?id=152318
3739
3740         Reviewed by Tim Horton.
3741
3742         Build fixes by Ossy.
3743
3744         * DerivedSources.make:
3745         * Shared/API/APIObject.h:
3746         * Shared/API/c/WKBase.h:
3747         * UIProcess/API/C/WKAPICast.h:
3748         * UIProcess/API/C/WKContext.cpp:
3749         (WKContextGetDatabaseManager): Deleted.
3750         * UIProcess/API/C/WKContext.h:
3751         * UIProcess/API/C/WKDatabaseManager.cpp: Removed.
3752         (WKDatabaseManagerGetTypeID): Deleted.
3753         (WKDatabaseManagerGetOriginKey): Deleted.
3754         (WKDatabaseManagerGetOriginQuotaKey): Deleted.
3755         (WKDatabaseManagerGetOriginUsageKey): Deleted.
3756         (WKDatabaseManagerGetDatabaseDetailsKey): Deleted.
3757         (WKDatabaseManagerGetDatabaseDetailsNameKey): Deleted.
3758         (WKDatabaseManagerGetDatabaseDetailsDisplayNameKey): Deleted.
3759         (WKDatabaseManagerGetDatabaseDetailsExpectedUsageKey): Deleted.
3760         (WKDatabaseManagerGetDatabaseDetailsCurrentUsageKey): Deleted.
3761         (WKDatabaseManagerGetDatabaseDetailsCreationTimeKey): Deleted.
3762         (WKDatabaseManagerGetDatabaseDetailsModificationTimeKey): Deleted.
3763         (WKDatabaseManagerSetClient): Deleted.
3764         (WKDatabaseManagerGetDatabasesByOrigin): Deleted.
3765         (WKDatabaseManagerGetDatabaseOrigins): Deleted.
3766         (WKDatabaseManagerDeleteDatabasesWithNameForOrigin): Deleted.
3767         (WKDatabaseManagerDeleteDatabasesForOrigin): Deleted.
3768         (WKDatabaseManagerDeleteAllDatabases): Deleted.
3769         (WKDatabaseManagerSetQuotaForOrigin): Deleted.
3770         * UIProcess/API/C/WKDatabaseManager.h: Removed.
3771         * UIProcess/WebDatabaseManagerProxy.cpp: Removed.
3772         (WebKit::WebDatabaseManagerProxy::supplementName): Deleted.
3773         (WebKit::WebDatabaseManagerProxy::originKey): Deleted.
3774         (WebKit::WebDatabaseManagerProxy::originQuotaKey): Deleted.
3775         (WebKit::WebDatabaseManagerProxy::originUsageKey): Deleted.
3776         (WebKit::WebDatabaseManagerProxy::databaseDetailsKey): Deleted.
3777         (WebKit::WebDatabaseManagerProxy::databaseDetailsNameKey): Deleted.
3778         (WebKit::WebDatabaseManagerProxy::databaseDetailsDisplayNameKey): Deleted.
3779         (WebKit::WebDatabaseManagerProxy::databaseDetailsExpectedUsageKey): Deleted.
3780         (WebKit::WebDatabaseManagerProxy::databaseDetailsCurrentUsageKey): Deleted.
3781         (WebKit::WebDatabaseManagerProxy::databaseDetailsCreationTimeKey): Deleted.
3782         (WebKit::WebDatabaseManagerProxy::databaseDetailsModificationTimeKey): Deleted.
3783         (WebKit::WebDatabaseManagerProxy::create): Deleted.
3784         (WebKit::WebDatabaseManagerProxy::WebDatabaseManagerProxy): Deleted.
3785         (WebKit::WebDatabaseManagerProxy::~WebDatabaseManagerProxy): Deleted.
3786         (WebKit::WebDatabaseManagerProxy::initializeClient): Deleted.
3787         (WebKit::WebDatabaseManagerProxy::processPoolDestroyed): Deleted.
3788         (WebKit::WebDatabaseManagerProxy::processDidClose): Deleted.
3789         (WebKit::WebDatabaseManagerProxy::shouldTerminate): Deleted.
3790         (WebKit::WebDatabaseManagerProxy::refWebContextSupplement): Deleted.
3791         (WebKit::WebDatabaseManagerProxy::derefWebContextSupplement): Deleted.
3792         (WebKit::WebDatabaseManagerProxy::getDatabasesByOrigin): Deleted.
3793         (WebKit::WebDatabaseManagerProxy::didGetDatabasesByOrigin): Deleted.
3794         (WebKit::WebDatabaseManagerProxy::getDatabaseOrigins): Deleted.
3795         (WebKit::WebDatabaseManagerProxy::didGetDatabaseOrigins): Deleted.
3796         (WebKit::WebDatabaseManagerProxy::deleteDatabaseWithNameForOrigin): Deleted.
3797         (WebKit::WebDatabaseManagerProxy::deleteDatabasesForOrigin): Deleted.
3798         (WebKit::WebDatabaseManagerProxy::deleteAllDatabases): Deleted.
3799         (WebKit::WebDatabaseManagerProxy::setQuotaForOrigin): Deleted.
3800         (WebKit::WebDatabaseManagerProxy::didModifyOrigin): Deleted.
3801         (WebKit::WebDatabaseManagerProxy::didModifyDatabase): Deleted.
3802         * UIProcess/WebDatabaseManagerProxy.h: Removed.
3803         * UIProcess/WebDatabaseManagerProxy.messages.in: Removed.
3804         * UIProcess/WebDatabaseManagerProxyClient.cpp: Removed.
3805         (WebKit::WebDatabaseManagerProxyClient::didModifyOrigin): Deleted.
3806         (WebKit::WebDatabaseManagerProxyClient::didModifyDatabase): Deleted.
3807         * UIProcess/WebDatabaseManagerProxyClient.h: Removed.
3808         * UIProcess/WebProcessPool.cpp:
3809         * WebKit2.xcodeproj/project.pbxproj:
3810         * WebProcess/InjectedBundle/InjectedBundle.cpp:
3811         * WebProcess/WebCoreSupport/WebDatabaseManager.cpp: Removed.
3812         (WebKit::WebDatabaseManager::supplementName): Deleted.
3813         (WebKit::WebDatabaseManager::WebDatabaseManager): Deleted.
3814         (WebKit::WebDatabaseManager::initialize): Deleted.
3815         (WebKit::WebDatabaseManager::getDatabasesByOrigin): Deleted.
3816         (WebKit::WebDatabaseManager::getDatabaseOrigins): Deleted.
3817         (WebKit::WebDatabaseManager::deleteDatabaseWithNameForOrigin): Deleted.
3818         (WebKit::WebDatabaseManager::deleteDatabasesForOrigin): Deleted.
3819         (WebKit::WebDatabaseManager::deleteAllDatabases): Deleted.
3820         (WebKit::WebDatabaseManager::closeAllDatabases): Deleted.
3821         (WebKit::WebDatabaseManager::setQuotaForOrigin): Deleted.
3822         (WebKit::WebDatabaseManager::dispatchDidModifyOrigin): Deleted.
3823         (WebKit::WebDatabaseManager::dispatchDidModifyDatabase): Deleted.
3824         * WebProcess/WebCoreSupport/WebDatabaseManager.h: Removed.
3825         * WebProcess/WebCoreSupport/WebDatabaseManager.messages.in: Removed.
3826         * WebProcess/WebCoreSupport/ios/WebDatabaseManagerIOS.mm: Removed.
3827         (WebKit::WebDatabaseManager::dispatchDidAddNewOrigin): Deleted.
3828         (WebKit::WebDatabaseManager::dispatchDidDeleteDatabase): Deleted.
3829         (WebKit::WebDatabaseManager::dispatchDidDeleteDatabaseOrigin): Deleted.
3830         * WebProcess/WebProcess.cpp:
3831         (WebKit::WebProcess::processWillSuspendImminently):
3832         (WebKit::m_webSQLiteDatabaseTracker): Deleted.
3833
3834 2015-12-18  Michael Catanzaro  <mcatanzaro@igalia.com>
3835
3836         [GTK] Unreviewed, fix GtkDoc after r193620
3837
3838         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml:
3839
3840 2015-12-18  Dan Bernstein  <mitz@apple.com>
3841
3842         WebPage::didCompleteUserMediaPermissionCheck and WebPage::didReceiveUserMediaPermissionDecision are exported
3843         https://bugs.webkit.org/show_bug.cgi?id=152429
3844
3845         Reviewed by Tim Horton.
3846
3847         * WebProcess/WebPage/WebPage.h: Removed WK_EXPORT specifiers from these two declarations.
3848
3849 2015-12-18  Alex Christensen  <achristensen@webkit.org>
3850
3851         Move networking code from Shared to NetworkProcess
3852         https://bugs.webkit.org/show_bug.cgi?id=152421
3853
3854         Reviewed by Antti Koivisto.
3855
3856         Since recently removing the non-NetworkProcess configurations, this code is no longer shared with the WebProcess.
3857
3858         * CMakeLists.txt:
3859         * DerivedSources.make:
3860         * NetworkProcess/CustomProtocols: Copied from Source/WebKit2/Shared/Network/CustomProtocols.
3861         * NetworkProcess/Downloads: Copied from Source/WebKit2/Shared/Downloads.
3862         * NetworkProcess/Downloads/Download.cpp: Copied from Source/WebKit2/Shared/Downloads/Download.cpp.
3863         * NetworkProcess/Downloads/Download.h: Copied from Source/WebKit2/Shared/Downloads/Download.h.
3864         * NetworkProcess/Downloads/DownloadID.h: Copied from Source/WebKit2/Shared/Downloads/DownloadID.h.
3865         * NetworkProcess/Downloads/DownloadManager.cpp: Copied from Source/WebKit2/Shared/Downloads/DownloadManager.cpp.
3866         * NetworkProcess/Downloads/DownloadManager.h: Copied from Source/WebKit2/Shared/Downloads/DownloadManager.h.
3867         * NetworkProcess/NetworkProcessCreationParameters.cpp: Copied from Source/WebKit2/Shared/Network/NetworkProcessCreationParameters.cpp.
3868         * NetworkProcess/NetworkProcessCreationParameters.h: Copied from Source/WebKit2/Shared/Network/NetworkProcessCreationParameters.h.
3869         * NetworkProcess/NetworkProcessSupplement.h: Copied from Source/WebKit2/Shared/Network/NetworkProcessSupplement.h.
3870         * NetworkProcess/NetworkResourceLoadParameters.cpp: Copied from Source/WebKit2/Shared/Network/NetworkResourceLoadParameters.cpp.
3871         * NetworkProcess/NetworkResourceLoadParameters.h: Copied from Source/WebKit2/Shared/Network/NetworkResourceLoadParameters.h.
3872         * PlatformEfl.cmake:
3873         * PlatformGTK.cmake:
3874         * PlatformMac.cmake:
3875         * Shared/Downloads: Removed.
3876         * Shared/Downloads/Download.cpp: Removed.
3877         * Shared/Downloads/Download.h: Removed.
3878         * Shared/Downloads/DownloadAuthenticationClient.cpp: Removed.
3879         * Shared/Downloads/DownloadAuthenticationClient.h: Removed.
3880         * Shared/Downloads/DownloadID.h: Removed.
3881         * Shared/Downloads/DownloadManager.cpp: Removed.
3882         * Shared/Downloads/DownloadManager.h: Removed.
3883         * Shared/Downloads/cocoa: Removed.
3884         * Shared/Downloads/cocoa/DownloadCocoa.mm: Removed.
3885         * Shared/Downloads/efl: Removed.
3886         * Shared/Downloads/efl/DownloadSoupErrorsEfl.cpp: Removed.
3887         * Shared/Downloads/gtk: Removed.
3888         * Shared/Downloads/gtk/DownloadSoupErrorsGtk.cpp: Removed.
3889         * Shared/Downloads/ios: Removed.
3890         * Shared/Downloads/ios/DownloadIOS.mm: Removed.
3891         * Shared/Downloads/mac: Removed.
3892         * Shared/Downloads/mac/DownloadMac.mm: Removed.
3893         * Shared/Downloads/soup: Removed.
3894         * Shared/Downloads/soup/DownloadSoup.cpp: Removed.
3895         * Shared/Downloads/soup/DownloadSoupErrors.h: Removed.
3896         * Shared/Network: Removed.
3897         * Shared/Network/CustomProtocols: Removed.
3898         * Shared/Network/CustomProtocols/Cocoa: Removed.
3899         * Shared/Network/CustomProtocols/Cocoa/CustomProtocolManagerCocoa.mm: Removed.
3900         * Shared/Network/CustomProtocols/CustomProtocolManager.h: Removed.
3901         * Shared/Network/CustomProtocols/CustomProtocolManager.messages.in: Removed.
3902         * Shared/Network/CustomProtocols/soup: Removed.
3903         * Shared/Network/CustomProtocols/soup/CustomProtocolManagerImpl.cpp: Removed.
3904         * Shared/Network/CustomProtocols/soup/CustomProtocolManagerImpl.h: Removed.
3905         * Shared/Network/CustomProtocols/soup/CustomProtocolManagerSoup.cpp: Removed.
3906         * Shared/Network/NetworkProcessCreationParameters.cpp: Removed.
3907         * Shared/Network/NetworkProcessCreationParameters.h: Removed.
3908         * Shared/Network/NetworkProcessSupplement.h: Removed.
3909         * Shared/Network/NetworkResourceLoadParameters.cpp: Removed.
3910         * Shared/Network/NetworkResourceLoadParameters.h: Removed.
3911         * WebKit2.xcodeproj/project.pbxproj:
3912
3913 2015-12-18  Michael Catanzaro  <mcatanzaro@igalia.com>
3914
3915         LayerTreeHostGtk triggers -Wunused-private-field
3916         https://bugs.webkit.org/show_bug.cgi?id=152410
3917
3918         Reviewed by Carlos Garcia Campos.
3919
3920         Remove the unused member variable.
3921
3922         * WebProcess/WebPage/gtk/LayerTreeHostGtk.h:
3923
3924 2015-12-18  Alex Christensen  <achristensen@webkit.org>
3925
3926         Add types for DownloadID and TaskIdentifier
3927         https://bugs.webkit.org/show_bug.cgi?id=152401
3928
3929         Reviewed by Brady Eidson.
3930
3931         DownloadID and TaskIdentifier used to both be just uint64_t's.
3932         It is confusing to distinguish between them, so now they both have names.
3933         We need a HashMap<TaskIdentifier, DownloadID> instead of a HashMap<uint64_t, uint64_t>.
3934
3935         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
3936         (WebKit::storageSession):
3937         (WebKit::NetworkConnectionToWebProcess::startDownload):
3938         (WebKit::NetworkConnectionToWebProcess::convertMainResourceLoadToDownload):
3939         * NetworkProcess/NetworkConnectionToWebProcess.h:
3940         * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
3941         * NetworkProcess/NetworkProcess.cpp:
3942         (WebKit::NetworkProcess::deleteWebsiteDataForOrigins):
3943         (WebKit::NetworkProcess::downloadRequest):
3944         (WebKit::NetworkProcess::resumeDownload):
3945         (WebKit::NetworkProcess::cancelDownload):
3946         (WebKit::NetworkProcess::getNetworkProcessStatistics):
3947         (WebKit::NetworkProcess::logDiagnosticMessage):
3948         (WebKit::NetworkProcess::logDiagnosticMessageWithResult):
3949         (WebKit::NetworkProcess::logDiagnosticMessageWithValue):
3950         * NetworkProcess/NetworkProcess.h:
3951         * NetworkProcess/NetworkProcess.messages.in:
3952         * NetworkProcess/NetworkSession.h:
3953         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
3954         (WebKit::NetworkSession::createDataTaskWithRequest):
3955         (WebKit::NetworkSession::dataTaskForIdentifier):
3956         (WebKit::NetworkDataTask::resume):
3957         (WebKit::NetworkDataTask::taskIdentifier): Deleted.
3958         * Shared/Downloads/Download.cpp:
3959         (WebKit::Download::Download):
3960         (WebKit::Download::messageSenderDestinationID):
3961         * Shared/Downloads/Download.h:
3962         (WebKit::Download::downloadID):
3963         * Shared/Downloads/DownloadID.h: Added.
3964         (WebKit::DownloadID::DownloadID):
3965         (WebKit::DownloadID::operator==):
3966         (WebKit::DownloadID::downloadID):
3967         (IPC::ArgumentCoder<WebKit::DownloadID>::encode):
3968         (IPC::ArgumentCoder<WebKit::DownloadID>::decode):
3969         (WTF::DownloadIDHash::hash):
3970         (WTF::DownloadIDHash::equal):
3971         (WTF::HashTraits<WebKit::DownloadID>::emptyValue):
3972         (WTF::HashTraits<WebKit::DownloadID>::constructDeletedValue):
3973         (WTF::HashTraits<WebKit::DownloadID>::isDeletedValue):
3974         * Shared/Downloads/DownloadManager.cpp:
3975         (WebKit::DownloadManager::DownloadManager):
3976         (WebKit::DownloadManager::startDownload):
3977         (WebKit::DownloadManager::convertHandleToDownload):
3978         (WebKit::DownloadManager::resumeDownload):
3979         (WebKit::DownloadManager::cancelDownload):
3980         * Shared/Downloads/DownloadManager.h:
3981         (WebKit::DownloadManager::isDownloading):
3982         * UIProcess/API/C/WKDownload.cpp:
3983         (WKDownloadGetID):
3984         (WKDownloadCopyRequest):
3985         * UIProcess/Downloads/DownloadProxy.h:
3986         (WebKit::DownloadProxy::downloadID):
3987         (WebKit::DownloadProxy::request):
3988         (WebKit::DownloadProxy::resumeData):
3989         * UIProcess/Downloads/DownloadProxyMap.cpp:
3990         (WebKit::DownloadProxyMap::createDownloadProxy):
3991         (WebKit::DownloadProxyMap::downloadFinished):
3992         (WebKit::DownloadProxyMap::processDidClose):
3993         * UIProcess/Downloads/DownloadProxyMap.h:
3994         * UIProcess/WebPageProxy.cpp:
3995         (WebKit::WebPageProxy::receivedPolicyDecision):
3996         (WebKit::WebPageProxy::frameDidBecomeFrameSet):
3997         (WebKit::WebPageProxy::decidePolicyForNavigationAction):
3998         (WebKit::WebPageProxy::decidePolicyForResponse):
3999         (WebKit::WebPageProxy::decidePolicyForResponseSync):
4000         * UIProcess/WebPageProxy.h:
4001         * UIProcess/WebPageProxy.messages.in:
4002         * WebKit2.xcodeproj/project.pbxproj:
4003         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
4004         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
4005         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
4006         * WebProcess/WebPage/WebFrame.cpp:
4007         (WebKit::WebFrame::invalidatePolicyListener):
4008         (WebKit::WebFrame::didReceivePolicyDecision):
4009         (WebKit::WebFrame::startDownload):
4010         (WebKit::WebFrame::convertMainResourceLoadToDownload):
4011         * WebProcess/WebPage/WebFrame.h: