d0cadc5f500add2c5d329b593a6ced69ab9604aa
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2015-10-27  Anders Carlsson  <andersca@apple.com>
2
3         Stub out more of the context menu SPI
4         https://bugs.webkit.org/show_bug.cgi?id=150606
5
6         Reviewed by Dan Bernstein.
7
8         Add a delegate method that will allow the client to modify the menu. Also,
9         add an empty _WKContextMenuElementInfo class and its _WKElementInfo superclass.
10
11         * UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
12         * UIProcess/API/Cocoa/_WKContextMenuElementInfo.h: Added.
13         * UIProcess/API/Cocoa/_WKContextMenuElementInfo.mm: Added.
14         * UIProcess/API/Cocoa/_WKElementInfo.h: Added.
15         * UIProcess/API/Cocoa/_WKElementInfo.mm: Added.
16         * UIProcess/Cocoa/UIDelegate.h:
17         * UIProcess/Cocoa/UIDelegate.mm:
18         (WebKit::UIDelegate::setDelegate):
19         (WebKit::UIDelegate::ContextMenuClient::menuFromProposedMenu):
20         (WebKit::UIDelegate::UIClient::createNewPage):
21         * UIProcess/mac/WebContextMenuProxyMac.mm:
22         (WebKit::WebContextMenuProxyMac::showContextMenu):
23         * WebKit2.xcodeproj/project.pbxproj:
24
25 2015-10-28  Chris Dumez  <cdumez@apple.com>
26
27         Use RunLoopTimer in DataURLDecoder to avoid issues related to runloops
28         https://bugs.webkit.org/show_bug.cgi?id=150609
29         <rdar://problem/22702894>
30
31         Reviewed by Antti Koivisto.
32
33         Move addSchedulePair() call to Page::platformInitialize() so that
34         RunLoopTimer can be used by any Page, even those that don't have
35         a WebPage wrapper.
36
37         * WebProcess/WebPage/mac/WebPageMac.mm:
38         (WebKit::WebPage::platformInitialize): Deleted.
39
40 2015-10-27  Tim Horton  <timothy_horton@apple.com>
41
42         Fix the 32-bit build.
43
44         * UIProcess/Cocoa/WebViewImpl.mm:
45         (WebKit::WebViewImpl::dragImageForView):
46
47 2015-10-27  Tim Horton  <timothy_horton@apple.com>
48
49         Fix the build.
50
51         * UIProcess/Cocoa/WebViewImpl.mm:
52
53 2015-10-27  Tim Horton  <timothy_horton@apple.com>
54
55         WKView being inside WKWebView leads to weird API issues
56         https://bugs.webkit.org/show_bug.cgi?id=150174
57
58         Reviewed by Anders Carlsson.
59
60         * UIProcess/API/mac/WKView.mm:
61         (-[WKView mouseDown:]):
62         (-[WKView mouseUp:]):
63         (-[WKView acceptsFirstMouse:]):
64         (-[WKView shouldDelayWindowOrderingForEvent:]):
65         (-[WKView pasteboardChangedOwner:]):
66         (-[WKView pasteboard:provideDataForType:]):
67         (-[WKView namesOfPromisedFilesDroppedAtDestination:]):
68         (-[WKView _startWindowDrag]):
69         (-[WKView _setMouseDownEvent:]): Deleted.
70         (-[WKView _colorSpace]): Deleted.
71         (-[WKView _dragImageForView:withImage:at:linkDrag:]): Deleted.
72         (matchesExtensionOrEquivalent): Deleted.
73         (-[WKView _setFileAndURLTypes:withExtension:withTitle:withURL:withVisibleURL:forPasteboard:]): Deleted.
74         (-[WKView _setPromisedDataForImage:withFileName:withExtension:withTitle:withURL:withVisibleURL:withArchive:forPasteboard:]): Deleted.
75         (-[WKView _setPromisedDataForAttachment:withExtension:withTitle:withURL:withVisibleURL:forPasteboard:]): Deleted.
76         (fileExists): Deleted.
77         (pathWithUniqueFilenameForPath): Deleted.
78         (-[WKView spellCheckerDocumentTag]): Deleted.
79         (-[WKView handleAcceptedAlternativeText:]): Deleted.
80         (-[WKView initWithFrame:processPool:configuration:webView:]): Deleted.
81         * UIProcess/API/mac/WKViewInternal.h:
82         * UIProcess/Cocoa/WebViewImpl.h:
83         * UIProcess/Cocoa/WebViewImpl.mm:
84         (WebKit::WebViewImpl::handleAcceptedAlternativeText):
85         (WebKit::WebViewImpl::spellCheckerDocumentTag):
86         (WebKit::WebViewImpl::startWindowDrag):
87         (WebKit::WebViewImpl::dragImageForView):
88         (WebKit::matchesExtensionOrEquivalent):
89         (WebKit::WebViewImpl::setFileAndURLTypes):
90         (WebKit::WebViewImpl::setPromisedDataForImage):
91         (WebKit::WebViewImpl::setPromisedDataForAttachment):
92         (WebKit::WebViewImpl::pasteboardChangedOwner):
93         (WebKit::WebViewImpl::provideDataForPasteboard):
94         (WebKit::fileExists):
95         (WebKit::pathWithUniqueFilenameForPath):
96         (WebKit::WebViewImpl::namesOfPromisedFilesDroppedAtDestination):
97         (WebKit::WebViewImpl::setLastMouseDownEvent):
98         * UIProcess/mac/CorrectionPanel.h:
99         * UIProcess/mac/CorrectionPanel.mm:
100         (WebKit::CorrectionPanel::show):
101         (WebKit::CorrectionPanel::recordAutocorrectionResponse):
102         (WebKit::CorrectionPanel::handleAcceptedReplacement):
103         * UIProcess/mac/PageClientImpl.mm:
104         (WebKit::PageClientImpl::colorSpace):
105         (WebKit::PageClientImpl::setDragImage):
106         (WebKit::PageClientImpl::setPromisedDataForImage):
107         (WebKit::PageClientImpl::setPromisedDataForAttachment):
108         (WebKit::PageClientImpl::showCorrectionPanel):
109         (WebKit::PageClientImpl::recordAutocorrectionResponse):
110         (WebKit::PageClientImpl::showDictationAlternativeUI):
111         Move some pasteboard and spellcheck code.
112
113 2015-10-27  Wenson Hsieh  <wenson_hsieh@apple.com>
114
115         Implement viewport-width-based fast-click heuristic
116         https://bugs.webkit.org/show_bug.cgi?id=150604
117         <rdar://problem/23267308>
118
119         Reviewed by Simon Fraser.
120
121         Implement a new fast-click heuristic that applies to viewports with width = device-width. The basic rules are
122         as follows: when a page has viewport width = device-width and is at initial zoom scale, we disable double-tapping
123         in favor of fast-clicking. However, if the viewport scale is not the initial scale, we allow double tapping. For
124         fast-clicking to remain useful after the user pinch-zooms, we change our double-tap to zoom out behavior to zoom
125         to the initial scale rather than the minimum scale. For unscalable viewports, we default to fast-clicking behavior,
126         and for all other viewports not at device-width, we double-tap to zoom and scroll as normal.
127
128         This patch removes some logic previously used for our scroll- and zoom-based fast-clicking heuristic, and adds
129         information about the viewport width and initial scale to RemoteLayerTreeTransactions. This information is then
130         used by the UI process to determine whether double tapping should be disabled or enabled.
131
132         The fast-click heuristic can be turned off through user default preferences, and a tap highlight for debugging
133         fast-clicking can also be enabled through a user default preference. A red highlight indicates that a single-
134         tap was slow, whereas a green highlight indicates a fast single-tap.
135
136         * Shared/mac/RemoteLayerTreeTransaction.h:
137         (WebKit::RemoteLayerTreeTransaction::initialScaleFactor):
138         (WebKit::RemoteLayerTreeTransaction::setInitialScaleFactor):
139         (WebKit::RemoteLayerTreeTransaction::viewportMetaTagWidth):
140         (WebKit::RemoteLayerTreeTransaction::setViewportMetaTagWidth):
141         * Shared/mac/RemoteLayerTreeTransaction.mm:
142         (WebKit::RemoteLayerTreeTransaction::encode):
143         (WebKit::RemoteLayerTreeTransaction::decode):
144         * UIProcess/API/Cocoa/WKWebView.mm:
145         (-[WKWebView initWithFrame:configuration:]):
146         (-[WKWebView _processDidExit]):
147         (-[WKWebView _didCommitLayerTree:]):
148         (-[WKWebView _zoomToInitialScaleWithOrigin:animated:]):
149         (-[WKWebView _allowsDoubleTapGestures]):
150         (-[WKWebView _setViewportMetaTagWidth:]): Deleted.
151         (-[WKWebView _contentZoomScale]): Deleted.
152         (-[WKWebView _viewportMetaTagWidth]): Deleted.
153         (-[WKWebView _viewportIsUserScalable]): Deleted.
154         * UIProcess/API/Cocoa/WKWebViewInternal.h:
155         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
156         * UIProcess/PageClient.h:
157         * UIProcess/WebPageProxy.h:
158         * UIProcess/WebPageProxy.messages.in:
159         * UIProcess/ios/PageClientImplIOS.h:
160         * UIProcess/ios/PageClientImplIOS.mm:
161         (WebKit::PageClientImpl::disableDoubleTapGesturesDuringTapIfNecessary):
162         (WebKit::PageClientImpl::didChangeViewportMetaTagWidth): Deleted.
163         (WebKit::PageClientImpl::disableDoubleTapGesturesUntilTapIsFinishedIfNecessary): Deleted.
164         * UIProcess/ios/SmartMagnificationController.h:
165         * UIProcess/ios/SmartMagnificationController.mm:
166         (WebKit::SmartMagnificationController::didCollectGeometryForSmartMagnificationGesture):
167         * UIProcess/ios/WKContentView.h:
168         * UIProcess/ios/WKContentView.mm:
169         (-[WKContentView _zoomToInitialScaleWithOrigin:]):
170         * UIProcess/ios/WKContentViewInteraction.h:
171         * UIProcess/ios/WKContentViewInteraction.mm:
172         (-[WKContentView setupInteraction]):
173         (-[WKContentView _showTapHighlight]):
174         (-[WKContentView _didGetTapHighlightForRequest:color:quads:topLeftRadius:topRightRadius:bottomLeftRadius:bottomRightRadius:]):
175         (-[WKContentView _mayDisableDoubleTapGesturesDuringSingleTap]):
176         (-[WKContentView _disableDoubleTapGesturesDuringTapIfNecessary:]):
177         (-[WKContentView _finishInteraction]):
178         (-[WKContentView _endPotentialTapAndEnableDoubleTapGesturesIfNecessary]):
179         (-[WKContentView _tapHighlightColorForFastClick:]):
180         (-[WKContentView _setDoubleTapGesturesEnabled:]):
181         (-[WKContentView _fastClickZoomThreshold]): Deleted.
182         (-[WKContentView _allowDoubleTapToZoomForCurrentZoomScale:andTargetZoomScale:]): Deleted.
183         (-[WKContentView _disableDoubleTapGesturesUntilTapIsFinishedIfNecessary:allowsDoubleTapZoom:targetRect:isReplaced:minimumScale:maximumScale:]): Deleted.
184         * UIProcess/ios/WebPageProxyIOS.mm:
185         (WebKit::WebPageProxy::disableDoubleTapGesturesDuringTapIfNecessary):
186         (WebKit::WebPageProxy::viewportMetaTagWidthDidChange): Deleted.
187         (WebKit::WebPageProxy::disableDoubleTapGesturesUntilTapIsFinishedIfNecessary): Deleted.
188         * WebProcess/WebPage/ViewGestureGeometryCollector.h:
189         * WebProcess/WebPage/WebPage.cpp:
190         (WebKit::WebPage::willCommitLayerTree):
191         * WebProcess/WebPage/ios/WebPageIOS.mm:
192         (WebKit::WebPage::potentialTapAtPosition):
193         (WebKit::WebPage::viewportPropertiesDidChange): Deleted.
194
195 2015-10-27  Tim Horton  <timothy_horton@apple.com>
196
197         WKView being inside WKWebView leads to weird API issues
198         https://bugs.webkit.org/show_bug.cgi?id=150174
199
200         Reviewed by Anders Carlsson.
201
202         * UIProcess/API/mac/WKView.mm:
203         (-[WKView _superAccessibilityAttributeValue:]):
204         (-[WKView accessibilityFocusedUIElement]):
205         (-[WKView accessibilityIsIgnored]):
206         (-[WKView accessibilityHitTest:]):
207         (-[WKView accessibilityAttributeValue:]):
208         (-[WKView _processDidExit]):
209         (-[WKView _pageClosed]):
210         (-[WKView _updateRemoteAccessibilityRegistration:]): Deleted.
211         (-[WKView enableAccessibilityIfNecessary]): Deleted.
212         (-[WKView _toolTipChangedFrom:to:]): Deleted.
213         (-[WKView _setAccessibilityWebProcessToken:]): Deleted.
214         (-[WKView _hasFullScreenWindowController]): Deleted.
215         (-[WKView _fullScreenWindowController]): Deleted.
216         (-[WKView _closeFullScreenWindowController]): Deleted.
217         (-[WKView _setSuppressVisibilityUpdates:]): Deleted.
218         (-[WKView _suppressVisibilityUpdates]): Deleted.
219         (-[WKView _primaryTrackingArea]): Deleted.
220         (-[WKView _setPrimaryTrackingArea:]): Deleted.
221         (-[WKView initWithFrame:processPool:configuration:webView:]): Deleted.
222         * UIProcess/API/mac/WKViewInternal.h:
223         * UIProcess/Cocoa/WebViewImpl.h:
224         (WebKit::WebViewImpl::accessibilityIsIgnored):
225         (WebKit::WebViewImpl::primaryTrackingArea):
226         * UIProcess/Cocoa/WebViewImpl.mm:
227         (WebKit::trackingAreaOptions):
228         (WebKit::WebViewImpl::WebViewImpl):
229         (WebKit::WebViewImpl::setAccessibilityWebProcessToken):
230         (WebKit::WebViewImpl::updateRemoteAccessibilityRegistration):
231         (WebKit::WebViewImpl::accessibilityFocusedUIElement):
232         (WebKit::WebViewImpl::accessibilityHitTest):
233         (WebKit::WebViewImpl::enableAccessibilityIfNecessary):
234         (WebKit::WebViewImpl::accessibilityAttributeValue):
235         (WebKit::WebViewImpl::setPrimaryTrackingArea):
236         (WebKit::WebViewImpl::toolTipChanged):
237         * UIProcess/mac/PageClientImpl.mm:
238         (WebKit::PageClientImpl::toolTipChanged):
239         (WebKit::PageClientImpl::accessibilityWebProcessTokenReceived):
240         (WebKit::PageClientImpl::recommendedScrollbarStyleDidChange):
241         (WebKit::PageClientImpl::closeFullScreenManager):
242         (WebKit::PageClientImpl::isFullScreen):
243         (WebKit::PageClientImpl::enterFullScreen):
244         (WebKit::PageClientImpl::exitFullScreen):
245         (WebKit::PageClientImpl::beganEnterFullScreen):
246         (WebKit::PageClientImpl::beganExitFullScreen):
247         Move accessibility code, and fold in some internal-only methods.
248
249 2015-10-27  Tim Horton  <timothy_horton@apple.com>
250
251         WKView being inside WKWebView leads to weird API issues
252         https://bugs.webkit.org/show_bug.cgi?id=150174
253
254         Reviewed by Anders Carlsson.
255
256         * UIProcess/API/mac/WKView.mm:
257         (-[WKView scrollWheel:]):
258         (-[WKView swipeWithEvent:]):
259         (-[WKView _superSwipeWithEvent:]):
260         (-[WKView _superMagnifyWithEvent:]):
261         (-[WKView _superSmartMagnifyWithEvent:]):
262         (-[WKView _processDidExit]):
263         (-[WKView setAllowsBackForwardNavigationGestures:]):
264         (-[WKView allowsBackForwardNavigationGestures]):
265         (-[WKView setAllowsMagnification:]):
266         (-[WKView allowsMagnification]):
267         (-[WKView magnifyWithEvent:]):
268         (-[WKView rotateWithEvent:]):
269         (-[WKView _gestureEventWasNotHandledByWebCore:]):
270         (-[WKView smartMagnifyWithEvent:]):
271         (-[WKView setMagnification:centeredAtPoint:]):
272         (-[WKView setMagnification:]):
273         (-[WKView magnification]):
274         (-[WKView _setCustomSwipeViews:]):
275         (-[WKView _setCustomSwipeViewsTopContentInset:]):
276         (-[WKView _tryToSwipeWithEvent:ignoringPinnedState:]):
277         (-[WKView _setDidMoveSwipeSnapshotCallback:]):
278         (-[WKView _ensureGestureController]): Deleted.
279         (takeWindowSnapshot): Deleted.
280         (-[WKView _takeViewSnapshot]): Deleted.
281         (-[WKView _wheelEventWasNotHandledByWebCore:]): Deleted.
282         (-[WKView _didFirstVisuallyNonEmptyLayoutForMainFrame]): Deleted.
283         (-[WKView _didFinishLoadForMainFrame]): Deleted.
284         (-[WKView _didFailLoadForMainFrame]): Deleted.
285         (-[WKView _didSameDocumentNavigationForMainFrame:]): Deleted.
286         (-[WKView _removeNavigationGestureSnapshot]): Deleted.
287         * UIProcess/API/mac/WKViewInternal.h:
288         * UIProcess/Cocoa/WebViewImpl.h:
289         (WebKit::WebViewImpl::gestureController):
290         (WebKit::WebViewImpl::allowsBackForwardNavigationGestures):
291         (WebKit::WebViewImpl::allowsMagnification):
292         * UIProcess/Cocoa/WebViewImpl.mm:
293         (WebKit::takeWindowSnapshot):
294         (WebKit::WebViewImpl::takeViewSnapshot):
295         (WebKit::WebViewImpl::ensureGestureController):
296         (WebKit::WebViewImpl::resetGestureController):
297         (WebKit::WebViewImpl::setAllowsBackForwardNavigationGestures):
298         (WebKit::WebViewImpl::setAllowsMagnification):
299         (WebKit::WebViewImpl::setMagnification):
300         (WebKit::WebViewImpl::magnification):
301         (WebKit::WebViewImpl::setCustomSwipeViews):
302         (WebKit::WebViewImpl::setCustomSwipeViewsTopContentInset):
303         (WebKit::WebViewImpl::tryToSwipeWithEvent):
304         (WebKit::WebViewImpl::setDidMoveSwipeSnapshotCallback):
305         (WebKit::WebViewImpl::scrollWheel):
306         (WebKit::WebViewImpl::swipeWithEvent):
307         (WebKit::WebViewImpl::magnifyWithEvent):
308         (WebKit::WebViewImpl::smartMagnifyWithEvent):
309         (WebKit::WebViewImpl::rotateWithEvent):
310         (WebKit::WebViewImpl::gestureEventWasNotHandledByWebCore):
311         (WebKit::WebViewImpl::gestureEventWasNotHandledByWebCoreFromViewOnly):
312         * UIProcess/mac/PageClientImpl.mm:
313         (WebKit::PageClientImpl::takeViewSnapshot):
314         (WebKit::PageClientImpl::wheelEventWasNotHandledByWebCore):
315         (WebKit::PageClientImpl::didFirstVisuallyNonEmptyLayoutForMainFrame):
316         (WebKit::PageClientImpl::didFinishLoadForMainFrame):
317         (WebKit::PageClientImpl::didFailLoadForMainFrame):
318         (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
319         (WebKit::PageClientImpl::removeNavigationGestureSnapshot):
320         Move swipe, zoom, rotate, and snapshotting code.
321
322 2015-10-27  Zhuo Li  <zachli@apple.com>
323
324         Add WebKit API to clear data type Search Field Recent Searches.
325         https://bugs.webkit.org/show_bug.cgi?id=150019.
326
327         Reviewed by Anders Carlsson.
328
329         * Shared/WebsiteData/WebsiteDataTypes.h: Add data type Search Field Recent Searches.
330         * UIProcess/API/Cocoa/WKWebsiteDataRecord.mm:
331         (dataTypesToString): Ditto.
332         * UIProcess/API/Cocoa/WKWebsiteDataRecordInternal.h:
333         (WebKit::toWebsiteDataTypes): Ditto.
334         (WebKit::toWKWebsiteDataTypes): Ditto.
335         * UIProcess/API/Cocoa/WKWebsiteDataRecordPrivate.h: Ditto.
336         * UIProcess/WebsiteData/WebsiteDataStore.cpp:
337         (WebKit::WebsiteDataStore::removeData): Handle the case when data type is Search
338         Field Recent Searches.
339         * UIProcess/WebsiteData/WebsiteDataStore.h: Add a private function for removing
340         recent searches based on time.
341         * UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:
342         (WebKit::WebsiteDataStoreCocoa::platformRemoveRecentSearches): Call the removing
343         recent searches logic in WebCore.
344         * UIProcess/efl/WebPageProxyEfl.cpp:
345         (WebKit::WebsiteDataStore::platformRemoveRecentSearches): Not implemented.
346         * UIProcess/gtk/WebPageProxyGtk.cpp:
347         (WebKit::WebsiteDataStore::platformRemoveRecentSearches): Not implemented.
348
349 2015-10-26  Brady Eidson  <beidson@apple.com>
350
351         Make IDBKeyData from a struct to a class.
352         https://bugs.webkit.org/show_bug.cgi?id=150576
353
354         Reviewed by Alex Christensen.
355
356         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
357         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
358         * DatabaseProcess/IndexedDB/IDBSerialization.h:
359         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
360         (WebKit::UniqueIDBDatabase::putRecordInBackingStore):
361         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
362         * DatabaseProcess/IndexedDB/UniqueIDBDatabaseBackingStore.h:
363         * DatabaseProcess/IndexedDB/sqlite/SQLiteIDBCursor.cpp:
364         (WebKit::buildIndexStatement):
365         (WebKit::buildObjectStoreStatement):
366         (WebKit::SQLiteIDBCursor::establishStatement):
367         (WebKit::SQLiteIDBCursor::createSQLiteStatement):
368         (WebKit::SQLiteIDBCursor::resetAndRebindStatement):
369         (WebKit::SQLiteIDBCursor::iterate):
370         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
371         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createIndex):
372         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
373         (WebKit::WebIDBServerConnection::didPutRecord):
374         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
375         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:
376
377 2015-10-26  Philip Chimento  <philip.chimento@gmail.com>
378
379         [GTK] [Stable] InstallMissingMediaPluginsPermissionRequest not defined when building without GStreamer
380         https://bugs.webkit.org/show_bug.cgi?id=148607
381
382         Unreviewed, build fix.
383
384         * UIProcess/gstreamer/InstallMissingMediaPluginsPermissionRequest.h:
385         Add a stub for the InstallMissingMediaPluginsPermissionRequest class
386         for the case when video is disabled or not using GStreamer. It's OK
387         that this class does nothing, because the associated C API contains
388         an assert_not_reached if video is disabled. We just need to define
389         the symbol so that the function signature will compile.
390
391 2015-10-26  Anders Carlsson  <andersca@apple.com>
392
393         Pipe custom context menu handling through to the UIDelegate object
394         https://bugs.webkit.org/show_bug.cgi?id=150572
395
396         Reviewed by Tim Horton.
397
398         * UIProcess/API/APIContextMenuClient.h:
399         (API::ContextMenuClient::menuFromProposedMenu):
400         * UIProcess/API/Cocoa/WKWebView.mm:
401         (-[WKWebView setUIDelegate:]):
402         * UIProcess/Cocoa/UIDelegate.h:
403         * UIProcess/Cocoa/UIDelegate.mm:
404         (WebKit::UIDelegate::createContextMenuClient):
405         (WebKit::UIDelegate::ContextMenuClient::ContextMenuClient):
406         (WebKit::UIDelegate::ContextMenuClient::~ContextMenuClient):
407         (WebKit::UIDelegate::ContextMenuClient::menuFromProposedMenu):
408         * UIProcess/mac/WebContextMenuProxyMac.mm:
409         (WebKit::WebContextMenuProxyMac::showContextMenu):
410
411 2015-10-26  Tim Horton  <timothy_horton@apple.com>
412
413         WKView being inside WKWebView leads to weird API issues
414         https://bugs.webkit.org/show_bug.cgi?id=150174
415
416         Reviewed by Anders Carlsson.
417
418         * UIProcess/API/mac/WKView.mm:
419         (-[WKView mouseDown:]):
420         (-[WKView mouseDragged:]):
421         (-[WKView draggedImage:endedAt:operation:]):
422         (-[WKView draggingEntered:]):
423         (-[WKView draggingUpdated:]):
424         (-[WKView draggingExited:]):
425         (-[WKView prepareForDragOperation:]):
426         (-[WKView performDragOperation:]):
427         (-[WKView _hitTest:dragTypes:]):
428         (-[WKView initWithFrame:processPool:configuration:webView:]):
429         (-[WKView applicationFlags:]): Deleted.
430         (maybeCreateSandboxExtensionFromPasteboard): Deleted.
431         (createSandboxExtensionsForFileUpload): Deleted.
432         (-[WKView _registerDraggedTypes]): Deleted.
433         * UIProcess/Cocoa/WebViewImpl.h:
434         (WebKit::WebViewImpl::ignoresMouseDraggedEvents):
435         * UIProcess/Cocoa/WebViewImpl.mm:
436         (WebKit::WebViewImpl::setIgnoresMouseDraggedEvents):
437         (WebKit::WebViewImpl::draggedImage):
438         (WebKit::applicationFlagsForDrag):
439         (WebKit::WebViewImpl::draggingEntered):
440         (WebKit::WebViewImpl::draggingUpdated):
441         (WebKit::WebViewImpl::draggingExited):
442         (WebKit::WebViewImpl::prepareForDragOperation):
443         (WebKit::maybeCreateSandboxExtensionFromPasteboard):
444         (WebKit::createSandboxExtensionsForFileUpload):
445         (WebKit::WebViewImpl::performDragOperation):
446         (WebKit::WebViewImpl::hitTestForDragTypes):
447         (WebKit::WebViewImpl::registerDraggedTypes):
448         Move some drag-related things to WebViewImpl.
449
450 2015-10-26  Anders Carlsson  <andersca@apple.com>
451
452         Pipe custom context menu handling through to the UIDelegate object
453         https://bugs.webkit.org/show_bug.cgi?id=150572
454
455         Reviewed by Tim Horton.
456
457         * UIProcess/API/APIContextMenuClient.h:
458         (API::ContextMenuClient::menuFromProposedMenu):
459         * UIProcess/API/Cocoa/WKWebView.mm:
460         (-[WKWebView setUIDelegate:]):
461         * UIProcess/Cocoa/UIDelegate.h:
462         * UIProcess/Cocoa/UIDelegate.mm:
463         (WebKit::UIDelegate::createContextMenuClient):
464         (WebKit::UIDelegate::ContextMenuClient::ContextMenuClient):
465         (WebKit::UIDelegate::ContextMenuClient::~ContextMenuClient):
466         (WebKit::UIDelegate::ContextMenuClient::menuFromProposedMenu):
467         * UIProcess/mac/WebContextMenuProxyMac.mm:
468         (WebKit::WebContextMenuProxyMac::showContextMenu):
469
470 2015-10-26  Alex Christensen  <achristensen@webkit.org>
471
472         Build fix when using NETWORK_SESSION after r191457.
473
474         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
475         (-[NetworkSessionDelegate URLSession:dataTask:didReceiveResponse:completionHandler:]):
476         Use resourceResponse.
477
478 2015-10-26  Anders Carlsson  <andersca@apple.com>
479
480         Remove more dead context menu code
481         https://bugs.webkit.org/show_bug.cgi?id=150569
482
483         Reviewed by Tim Horton.
484
485         * UIProcess/API/APIContextMenuClient.h:
486         (API::ContextMenuClient::contextMenuDismissed): Deleted.
487         * UIProcess/API/C/WKPage.cpp:
488         (WKPageSetPageContextMenuClient): Deleted.
489
490 2015-10-26  Anders Carlsson  <andersca@apple.com>
491
492         Remove dead context menu code
493         https://bugs.webkit.org/show_bug.cgi?id=150567
494
495         Reviewed by Tim Horton.
496
497         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
498         (WebKit::WebContextMenuClient::getCustomMenuFromDefaultItems): Deleted.
499         * WebProcess/WebCoreSupport/WebContextMenuClient.h:
500
501 2015-10-26  Tim Horton  <timothy_horton@apple.com>
502
503         Don't expose the whitelist/blacklist in _WKUserStyleSheet
504         https://bugs.webkit.org/show_bug.cgi?id=150566
505
506         Reviewed by Anders Carlsson.
507
508         * UIProcess/API/Cocoa/_WKUserStyleSheet.h:
509         * UIProcess/API/Cocoa/_WKUserStyleSheet.mm:
510         (-[_WKUserStyleSheet initWithSource:forMainFrameOnly:]):
511         (toWTFStrings): Deleted.
512         (-[_WKUserStyleSheet initWithSource:whitelistedURLPatterns:blacklistedURLPatterns:forMainFrameOnly:]): Deleted.
513         (-[_WKUserStyleSheet whitelistedURLPatterns]): Deleted.
514         (-[_WKUserStyleSheet blacklistedURLPatterns]): Deleted.
515
516 2015-10-25  Carlos Garcia Campos  <cgarcia@igalia.com>
517
518         Unreviewed. Fix GTK+ build after r191543.
519
520         * UIProcess/API/gtk/WebKitWebView.cpp:
521         (webkit_web_view_run_javascript):
522         (resourcesStreamReadCallback):
523
524 2015-10-24  Tim Horton  <timothy_horton@apple.com>
525
526         Add a way to add user style sheets to WKUserContentController
527         https://bugs.webkit.org/show_bug.cgi?id=150531
528         <rdar://problem/23191691>
529
530         Reviewed by Darin Adler.
531
532         * Shared/API/APIObject.h:
533         * Shared/Cocoa/APIObject.mm:
534         (API::Object::newObject):
535         Boilerplate for a new API::UserStyleSheet.
536
537         * UIProcess/API/APIUserStyleSheet.cpp: Added.
538         (API::generateIdentifier):
539         (API::UserStyleSheet::generateUniqueURL):
540         * UIProcess/API/APIUserStyleSheet.h: Added.
541         Added API::UserStyleSheet, borrowing URL generation code from API::UserScript.
542
543         * UIProcess/API/Cocoa/WKUserContentController.mm:
544         (-[WKUserContentController _addUserStyleSheet:]):
545         (-[WKUserContentController _removeAllUserStyleSheets]):
546         Forward add and remove-all to WebUserContentControllerProxy.
547
548         * UIProcess/API/Cocoa/WKUserContentControllerPrivate.h:
549         * UIProcess/API/Cocoa/_WKUserStyleSheet.h: Added.
550         * UIProcess/API/Cocoa/_WKUserStyleSheet.mm: Added.
551         (toWTFStrings):
552         (-[_WKUserStyleSheet initWithSource:whitelistedURLPatterns:blacklistedURLPatterns:forMainFrameOnly:]):
553         (-[_WKUserStyleSheet source]):
554         (-[_WKUserStyleSheet isForMainFrameOnly]):
555         (-[_WKUserStyleSheet copyWithZone:]):
556         (-[_WKUserStyleSheet _apiObject]):
557         * UIProcess/API/Cocoa/_WKUserStyleSheetInternal.h: Added.
558         (API::wrapper):
559         * WebKit2.xcodeproj/project.pbxproj:
560         Add the new modern API object (as SPI for now).
561
562 2015-10-24  Tim Horton  <timothy_horton@apple.com>
563
564         Expose more information about the exception in WKErrorJavaScriptExceptionOccurred errors
565         https://bugs.webkit.org/show_bug.cgi?id=150525
566
567         Reviewed by Darin Adler.
568
569         * Scripts/webkit/messages.py:
570         (headers_for_type):
571         * Shared/WebCoreArgumentCoders.cpp:
572         (IPC::ArgumentCoder<ExceptionDetails>::encode):
573         (IPC::ArgumentCoder<ExceptionDetails>::decode):
574         * Shared/WebCoreArgumentCoders.h:
575         Learn how to en/decode ExceptionDetails.
576
577         * UIProcess/API/C/WKPage.cpp:
578         (WKPageRunJavaScriptInMainFrame):
579         * UIProcess/WebPageProxy.cpp:
580         (WebKit::WebPageProxy::runJavaScriptInMainFrame):
581         (WebKit::WebPageProxy::scriptValueCallback):
582         * UIProcess/WebPageProxy.h:
583         * UIProcess/WebPageProxy.messages.in:
584         * WebProcess/WebPage/WebPage.cpp:
585         (WebKit::WebPage::runJavaScriptInMainFrame):
586         Plumb ExceptionDetails back through runJavaScriptInMainFrame, across the
587         process boundary.
588
589         * UIProcess/API/Cocoa/WKError.mm:
590         (localizedDescriptionForErrorCode):
591         * UIProcess/API/Cocoa/WKErrorInternal.h:
592         * UIProcess/API/Cocoa/WKErrorPrivate.h:
593         Expose localizedDescriptionForErrorCode so that WKWebView can do special
594         things with its error.
595         Add new private userInfo keys for exception info.
596
597         * UIProcess/API/Cocoa/WKWebView.mm:
598         (-[WKWebView evaluateJavaScript:completionHandler:]):
599         Fill in the NSError userInfo with the exception info.
600
601 2015-10-24  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
602
603         [EFL] Fix a wrong enum variable use
604         https://bugs.webkit.org/show_bug.cgi?id=150522
605
606         Reviewed by Csaba Osztrogonác.
607
608         * UIProcess/API/efl/EwkView.cpp:
609         (EwkView::requestPopupMenu):
610         Use kWKPopupItemTextDirectionLTR instead of EWK_TEXT_DIRECTION_LEFT_TO_RIGHT.
611
612 2015-10-24  Dan Bernstein  <mitz@apple.com>
613
614         [Cocoa] _WKFormInputSession should provide access to the focused element info
615         https://bugs.webkit.org/show_bug.cgi?id=150512
616
617         Reviewed by Tim Horton.
618
619         * UIProcess/API/Cocoa/_WKFormInputSession.h: Added focusedElementInfo property to the
620           protocol.
621
622         * UIProcess/ios/WKContentViewInteraction.mm:
623         (-[WKFormInputSession initWithContentView:focusedElementInfo:userObject:]): Added the
624           focusedElementInfo argument, used to initialize a new ivar.
625         (-[WKFormInputSession focusedElementInfo]): Added this getter for the new
626           _WKFormInputSession property.
627         (-[WKContentView _startAssistingNode:userIsInteracting:blurPreviousNode:userObject:]):
628           Create the WKFocusedElementInfo unconditionally and pass it to the new WKFormInputSession
629           initializer.
630
631 2015-10-24  Dan Bernstein  <mitz@apple.com>
632
633         [iOS] Allow clients to specify a custom input view to be used for a form input session
634         https://bugs.webkit.org/show_bug.cgi?id=150395
635
636         Reviewed by Tim Horton.
637
638         * UIProcess/API/Cocoa/_WKFormInputSession.h: Added customInputView property to the protocol.
639
640         * UIProcess/ios/WKContentViewInteraction.mm:
641         (-[WKFormInputSession customInputView]): Added this getter.
642         (-[WKFormInputSession setCustomInputView:]): Added this setter, which reloads the input
643           views when the custom input view changes.
644         (-[WKContentView inputView]): Changed to return the custom view from the input session if
645           there is one.
646
647 2015-10-23  Alex Christensen  <achristensen@webkit.org>
648
649         Fix CMake compile error and add correct null check
650         https://bugs.webkit.org/show_bug.cgi?id=150520
651
652         Reviewed by Simon Fraser.
653
654         * UIProcess/API/Cocoa/WKWebView.mm:
655         (-[WKWebView _doAfterNextPresentationUpdate:]):
656
657 2015-10-23  Alex Christensen  <achristensen@webkit.org>
658
659         Progress towards CMake on Mac
660         https://bugs.webkit.org/show_bug.cgi?id=150517
661
662         Reviewed by Tim Horton.
663
664         * CMakeLists.txt:
665         * PlatformEfl.cmake:
666         * PlatformGTK.cmake:
667         * PlatformMac.cmake:
668         * WebProcess/Cookies/cf/WebCookieManagerCFNet.cpp: Removed.
669         * WebProcess/Cookies/curl/WebCookieManagerCurl.cpp: Removed.
670
671 2015-10-23  Tim Horton  <timothy_horton@apple.com>
672
673         WKView being inside WKWebView leads to weird API issues
674         https://bugs.webkit.org/show_bug.cgi?id=150174
675
676         * UIProcess/Cocoa/WebViewImpl.h:
677         Whoops.
678
679 2015-10-23  Tim Horton  <timothy_horton@apple.com>
680
681         WKView being inside WKWebView leads to weird API issues
682         https://bugs.webkit.org/show_bug.cgi?id=150174
683
684         Reviewed by Anders Carlsson.
685
686         * UIProcess/API/mac/WKView.mm:
687         (-[WKView hitTest:]):
688         (-[WKView _processDidExit]):
689         (-[WKView _setThumbnailView:]):
690         (-[WKView _thumbnailView]):
691         (-[WKFlippedView isFlipped]): Deleted.
692         (-[WKView dealloc]): Deleted.
693         (-[WKView _setAcceleratedCompositingModeRootLayer:]): Deleted.
694         (-[WKView _acceleratedCompositingModeRootLayer]): Deleted.
695         (-[WKView _updateThumbnailViewLayer]): Deleted.
696         (-[WKView _reparentLayerTreeInThumbnailView]): Deleted.
697         * UIProcess/API/mac/WKViewInternal.h:
698         * UIProcess/Cocoa/WebViewImpl.h:
699         (WebKit::WebViewImpl::acceleratedCompositingRootLayer):
700         (WebKit::WebViewImpl::layerHostingView):
701         (WebKit::WebViewImpl::thumbnailView):
702         * UIProcess/Cocoa/WebViewImpl.mm:
703         (-[WKFlippedView isFlipped]):
704         (WebKit::WebViewImpl::~WebViewImpl):
705         (WebKit::WebViewImpl::setAcceleratedCompositingRootLayer):
706         (WebKit::WebViewImpl::setThumbnailView):
707         (WebKit::WebViewImpl::reparentLayerTreeInThumbnailView):
708         (WebKit::WebViewImpl::updateThumbnailViewLayer):
709         * UIProcess/mac/PageClientImpl.mm:
710         (WebKit::PageClientImpl::enterAcceleratedCompositingMode):
711         (WebKit::PageClientImpl::exitAcceleratedCompositingMode):
712         (WebKit::PageClientImpl::updateAcceleratedCompositingMode):
713         (WebKit::PageClientImpl::setAcceleratedCompositingRootLayer):
714         (WebKit::PageClientImpl::acceleratedCompositingRootLayer):
715         Move accelerated compositing and thumbnail view code.
716
717 2015-10-23  Tim Horton  <timothy_horton@apple.com>
718
719         WKView being inside WKWebView leads to weird API issues
720         https://bugs.webkit.org/show_bug.cgi?id=150174
721
722         Reviewed by Anders Carlsson.
723
724         * UIProcess/API/mac/WKView.mm:
725         (-[WKView _superRemoveTrackingRect:]):
726         (-[WKView addTrackingRect:owner:userData:assumeInside:]):
727         (-[WKView _addTrackingRect:owner:userData:assumeInside:useTrackingNum:]):
728         (-[WKView _addTrackingRects:owner:userDataList:assumeInsideList:trackingNums:count:]):
729         (-[WKView removeTrackingRect:]):
730         (-[WKView _removeTrackingRects:count:]):
731         (-[WKView view:stringForToolTip:point:userData:]):
732         (-[WKView _toolTipChangedFrom:to:]):
733         (-[WKView _setAcceleratedCompositingModeRootLayer:]): Deleted.
734         (-[WKView _acceleratedCompositingModeRootLayer]): Deleted.
735         (takeWindowSnapshot): Deleted.
736         * UIProcess/Cocoa/WebViewImpl.h:
737         * UIProcess/Cocoa/WebViewImpl.mm:
738         (WebKit::WebViewImpl::addTrackingRect):
739         (WebKit::WebViewImpl::addTrackingRectWithTrackingNum):
740         (WebKit::WebViewImpl::addTrackingRectsWithTrackingNums):
741         (WebKit::WebViewImpl::removeTrackingRect):
742         (WebKit::WebViewImpl::removeTrackingRects):
743         (WebKit::WebViewImpl::sendToolTipMouseExited):
744         (WebKit::WebViewImpl::sendToolTipMouseEntered):
745         (WebKit::WebViewImpl::stringForToolTip):
746         (WebKit::WebViewImpl::toolTipChanged):
747         Move tooltip code.
748
749 2015-10-23  Tim Horton  <timothy_horton@apple.com>
750
751         WKView being inside WKWebView leads to weird API issues
752         https://bugs.webkit.org/show_bug.cgi?id=150174
753
754         Reviewed by Anders Carlsson.
755
756         * UIProcess/API/mac/WKView.mm:
757         (-[WKView _interpretKeyEvent:completionHandler:]):
758         (-[WKView inputContext]):
759         (-[WKView performKeyEquivalent:]):
760         (-[WKView keyDown:]):
761         (-[WKView _doneWithKeyEvent:eventWasHandled:]):
762         (-[WKView _setPluginComplexTextInputState:]): Deleted.
763         (-[WKView _disableComplexTextInputIfNecessary]): Deleted.
764         (-[WKView _handlePluginComplexTextInputKeyDown:]): Deleted.
765         (-[WKView _tryHandlePluginComplexTextInputKeyDown:]): Deleted.
766         (-[WKView _tryPostProcessPluginComplexTextInputKeyDown:]): Deleted.
767         (-[WKView _pluginFocusOrWindowFocusChanged:pluginComplexTextInputIdentifier:]): Deleted.
768         (-[WKView _setPluginComplexTextInputState:pluginComplexTextInputIdentifier:]): Deleted.
769         * UIProcess/API/mac/WKViewInternal.h:
770         * UIProcess/Cocoa/WebViewImpl.h:
771         (WebKit::WebViewImpl::pluginComplexTextInputState):
772         (WebKit::WebViewImpl::pluginComplexTextInputIdentifier):
773         * UIProcess/Cocoa/WebViewImpl.mm:
774         (WebKit::WebViewImpl::setPluginComplexTextInputState):
775         (WebKit::WebViewImpl::setPluginComplexTextInputStateAndIdentifier):
776         (WebKit::WebViewImpl::disableComplexTextInputIfNecessary):
777         (WebKit::WebViewImpl::handlePluginComplexTextInputKeyDown):
778         (WebKit::WebViewImpl::tryHandlePluginComplexTextInputKeyDown):
779         (WebKit::WebViewImpl::pluginFocusOrWindowFocusChanged):
780         (WebKit::WebViewImpl::tryPostProcessPluginComplexTextInputKeyDown):
781         * UIProcess/mac/PageClientImpl.mm:
782         (WebKit::PageClientImpl::pluginFocusOrWindowFocusChanged):
783         (WebKit::PageClientImpl::setPluginComplexTextInputState):
784         Move a few more methods.
785
786 2015-10-23  Eric Carlson  <eric.carlson@apple.com>
787
788         [MediaStream] Fix UserMediaPermissionRequestProxy::invalidate
789         https://bugs.webkit.org/show_bug.cgi?id=150503
790         <rdar://problem/23235386>
791
792         Reviewed by Dean Jackson.
793
794         * UIProcess/UserMediaPermissionRequestProxy.cpp:
795         (WebKit::UserMediaPermissionRequestProxy::UserMediaPermissionRequestProxy): m_manager is a pointer.
796         (WebKit::UserMediaPermissionRequestProxy::allow): Return early if m_manager is null, clear it after
797           calling the manager.
798         (WebKit::UserMediaPermissionRequestProxy::deny): Ditto.
799         (WebKit::UserMediaPermissionRequestProxy::invalidate): Clear m_manager.
800         * UIProcess/UserMediaPermissionRequestProxy.h: Change m_manager from a reference to a
801           pointer so it can be cleared.
802
803 2015-10-23  Claudio Saavedra  <csaavedra@igalia.com>
804
805         [GTK] Minor web editor fixes
806         https://bugs.webkit.org/show_bug.cgi?id=150501
807
808         Reviewed by Carlos Garcia Campos.
809
810         * UIProcess/gtk/KeyBindingTranslator.cpp: Remove
811         "MoveParagraphForward/Backward" as these commands do not exist in
812         WebKit (anymore?).
813         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp:
814         (WebKit::WebEditorClient::executePendingEditorCommands):
815         Editor::Command can take a String, no need to convert to a C char.
816
817 2015-10-23  Timothy Horton  <timothy_horton@apple.com>
818
819         Fix the build by unapplying review comments.
820
821         * UIProcess/Cocoa/WebViewImpl.h:
822
823 2015-10-23  Tim Horton  <timothy_horton@apple.com>
824
825         WKView being inside WKWebView leads to weird API issues
826         https://bugs.webkit.org/show_bug.cgi?id=150174
827
828         Reviewed by Anders Carlsson.
829
830         * UIProcess/API/mac/WKView.mm:
831         (-[WKView renewGState]):
832         (-[WKView writeSelectionToPasteboard:types:]):
833         (-[WKView centerSelectionInVisibleArea:]):
834         (-[WKView scrollWheel:]):
835         (-[WKView swipeWithEvent:]):
836         (-[WKView mouseMoved:]):
837         (-[WKView mouseDown:]):
838         (-[WKView mouseUp:]):
839         (-[WKView mouseDragged:]):
840         (-[WKView pressureChangeWithEvent:]):
841         (-[WKView acceptsFirstMouse:]):
842         (-[WKView shouldDelayWindowOrderingForEvent:]):
843         (-[WKView performKeyEquivalent:]):
844         (-[WKView keyUp:]):
845         (-[WKView keyDown:]):
846         (-[WKView flagsChanged:]):
847         (-[WKView _superQuickLookWithEvent:]):
848         (-[WKView _addFontPanelObserver]):
849         (-[WKView viewWillMoveToWindow:]):
850         (-[WKView viewDidMoveToWindow]):
851         (-[WKView viewDidChangeBackingProperties]):
852         (-[WKView enableAccessibilityIfNecessary]):
853         (-[WKView quickLookWithEvent:]):
854         (-[WKView _colorSpace]):
855         (-[WKView _didRelaunchProcess]):
856         (-[WKView _setTextIndicator:]):
857         (-[WKView _setTextIndicator:withLifetime:]):
858         (-[WKView _clearTextIndicatorWithAnimation:]):
859         (-[WKView _setTextIndicatorAnimationProgress:]):
860         (-[WKView initWithFrame:processPool:configuration:webView:]):
861         (-[WKView _didPerformImmediateActionHitTest:contentPreventsDefault:userData:]):
862         (-[WKView _internalImmediateActionAnimationControllerForHitTestResult:withType:userData:]):
863         (-[WKView _internalPrepareForImmediateActionAnimation]):
864         (-[WKView _internalCancelImmediateActionAnimation]):
865         (-[WKView _internalCompleteImmediateActionAnimation]):
866         (-[WKView _internalDismissContentRelativeChildWindowsWithAnimation:]):
867         (-[WKView beginDeferringViewInWindowChanges]):
868         (-[WKView endDeferringViewInWindowChanges]):
869         (-[WKView endDeferringViewInWindowChangesSync]):
870         (-[WKView _prepareForMoveToWindow:withCompletionHandler:]):
871         (-[WKView isDeferringViewInWindowChanges]):
872         (-[WKView allowsLinkPreview]):
873         (-[WKView setAllowsLinkPreview:]):
874         (-[WKView _setIgnoresAllEvents:]):
875         (-[WKView _setIgnoresNonWheelMouseEvents:]):
876         (-[WKView _setIgnoresNonWheelEvents:]):
877         (-[WKView _ignoresNonWheelEvents]):
878         (-[WKView _ignoresAllEvents]):
879         (-[WKView _setOverrideDeviceScaleFactor:]):
880         (-[WKView _overrideDeviceScaleFactor]):
881         (-[WKView _setTopContentInset:]):
882         (-[WKView _topContentInset]):
883         (-[WKView _dismissContentRelativeChildWindows]):
884         (-[WKView _dismissContentRelativeChildWindowsWithAnimation:]):
885         (-[WKView _setAutomaticallyAdjustsContentInsets:]):
886         (-[WKView _automaticallyAdjustsContentInsets]):
887         (-[WKWindowVisibilityObserver initWithView:]): Deleted.
888         (-[WKWindowVisibilityObserver startObserving:]): Deleted.
889         (-[WKWindowVisibilityObserver stopObserving:]): Deleted.
890         (-[WKWindowVisibilityObserver _windowDidOrderOnScreen:]): Deleted.
891         (-[WKWindowVisibilityObserver _windowDidOrderOffScreen:]): Deleted.
892         (-[WKView dealloc]): Deleted.
893         (-[WKView _updateWindowAndViewFrames]): Deleted.
894         (-[WKView updateFontPanelIfNeeded]): Deleted.
895         (-[WKView _selectionChanged]): Deleted.
896         (-[WKView addWindowObserversForWindow:]): Deleted.
897         (-[WKView removeWindowObservers]): Deleted.
898         (-[WKView doWindowDidChangeScreen]): Deleted.
899         (-[WKView _windowDidBecomeKey:]): Deleted.
900         (-[WKView _windowDidChangeScreen:]): Deleted.
901         (-[WKView _windowDidChangeLayerHosting:]): Deleted.
902         (-[WKView _windowDidResignKey:]): Deleted.
903         (-[WKView _windowDidMiniaturize:]): Deleted.
904         (-[WKView _windowDidDeminiaturize:]): Deleted.
905         (-[WKView _windowDidMove:]): Deleted.
906         (-[WKView _windowDidResize:]): Deleted.
907         (-[WKView _windowDidOrderOffScreen:]): Deleted.
908         (-[WKView _windowDidOrderOnScreen:]): Deleted.
909         (-[WKView _windowDidChangeBackingProperties:]): Deleted.
910         (-[WKView _windowDidChangeOcclusionState:]): Deleted.
911         (-[WKView _prepareForDictionaryLookup]): Deleted.
912         (-[WKView _dictionaryLookupPopoverWillClose:]): Deleted.
913         (-[WKView _accessibilityRegisterUIProcessTokens]): Deleted.
914         (-[WKView _postFakeMouseMovedEventForFlagsChangedEvent:]): Deleted.
915         (-[WKView _intrinsicDeviceScaleFactor]): Deleted.
916         (-[WKView _preferencesDidChange]): Deleted.
917         (-[WKView _targetWindowForMovePreparation]): Deleted.
918         (-[WKView _updateContentInsetsIfAutomatic]): Deleted.
919         (-[WKView observeValueForKeyPath:ofObject:change:context:]): Deleted.
920         (-[WKView _dispatchSetTopContentInset]): Deleted.
921         * UIProcess/API/mac/WKViewInternal.h:
922         * UIProcess/Cocoa/WebViewImpl.h:
923         (WebKit::WebViewImpl::automaticallyAdjustsContentInsets):
924         (WebKit::WebViewImpl::topContentInset):
925         (WebKit::WebViewImpl::overrideDeviceScaleFactor):
926         (WebKit::WebViewImpl::isDeferringViewInWindowChanges):
927         (WebKit::WebViewImpl::targetWindowForMovePreparation):
928         (WebKit::WebViewImpl::lastPressureEvent):
929         (WebKit::WebViewImpl::allowsLinkPreview):
930         (WebKit::WebViewImpl::ignoresNonWheelEvents):
931         (WebKit::WebViewImpl::ignoresAllEvents):
932         (WebKit::WebViewImpl::createWeakPtr):
933         * UIProcess/Cocoa/WebViewImpl.mm:
934         (SOFT_LINK_CONSTANT_MAY_FAIL):
935         (-[WKWindowVisibilityObserver initWithView:impl:]):
936         (-[WKWindowVisibilityObserver dealloc]):
937         (-[WKWindowVisibilityObserver startObserving:]):
938         (-[WKWindowVisibilityObserver stopObserving:]):
939         (-[WKWindowVisibilityObserver startObservingFontPanel]):
940         (-[WKWindowVisibilityObserver startObservingLookupDismissal]):
941         (-[WKWindowVisibilityObserver _windowDidOrderOnScreen:]):
942         (-[WKWindowVisibilityObserver _windowDidOrderOffScreen:]):
943         (-[WKWindowVisibilityObserver _windowDidBecomeKey:]):
944         (-[WKWindowVisibilityObserver _windowDidResignKey:]):
945         (-[WKWindowVisibilityObserver _windowDidMiniaturize:]):
946         (-[WKWindowVisibilityObserver _windowDidDeminiaturize:]):
947         (-[WKWindowVisibilityObserver _windowDidMove:]):
948         (-[WKWindowVisibilityObserver _windowDidResize:]):
949         (-[WKWindowVisibilityObserver _windowDidChangeBackingProperties:]):
950         (-[WKWindowVisibilityObserver _windowDidChangeScreen:]):
951         (-[WKWindowVisibilityObserver _windowDidChangeLayerHosting:]):
952         (-[WKWindowVisibilityObserver _windowDidChangeOcclusionState:]):
953         (-[WKWindowVisibilityObserver observeValueForKeyPath:ofObject:change:context:]):
954         (-[WKWindowVisibilityObserver _dictionaryLookupPopoverWillClose:]):
955         (-[WKEditCommandObjC initWithWebEditCommandProxy:]):
956         (-[WKEditCommandObjC command]):
957         (-[WKEditorUndoTargetObjC undoEditing:]):
958         (-[WKEditorUndoTargetObjC redoEditing:]):
959         (WebKit::WebViewImpl::WebViewImpl):
960         (WebKit::WebViewImpl::~WebViewImpl):
961         (WebKit::WebViewImpl::becomeFirstResponder):
962         (WebKit::WebViewImpl::resignFirstResponder):
963         (WebKit::WebViewImpl::renewGState):
964         (WebKit::WebViewImpl::updateWindowAndViewFrames):
965         (WebKit::WebViewImpl::setAutomaticallyAdjustsContentInsets):
966         (WebKit::WebViewImpl::updateContentInsetsIfAutomatic):
967         (WebKit::WebViewImpl::setTopContentInset):
968         (WebKit::WebViewImpl::dispatchSetTopContentInset):
969         (WebKit::WebViewImpl::setOverrideDeviceScaleFactor):
970         (WebKit::WebViewImpl::intrinsicDeviceScaleFactor):
971         (WebKit::WebViewImpl::windowDidOrderOffScreen):
972         (WebKit::WebViewImpl::windowDidOrderOnScreen):
973         (WebKit::WebViewImpl::windowDidBecomeKey):
974         (WebKit::WebViewImpl::windowDidResignKey):
975         (WebKit::WebViewImpl::windowDidMiniaturize):
976         (WebKit::WebViewImpl::windowDidDeminiaturize):
977         (WebKit::WebViewImpl::windowDidMove):
978         (WebKit::WebViewImpl::windowDidResize):
979         (WebKit::WebViewImpl::windowDidChangeBackingProperties):
980         (WebKit::WebViewImpl::windowDidChangeScreen):
981         (WebKit::WebViewImpl::windowDidChangeLayerHosting):
982         (WebKit::WebViewImpl::windowDidChangeOcclusionState):
983         (WebKit::WebViewImpl::viewWillMoveToWindow):
984         (WebKit::WebViewImpl::viewDidMoveToWindow):
985         (WebKit::WebViewImpl::viewDidChangeBackingProperties):
986         (WebKit::WebViewImpl::postFakeMouseMovedEventForFlagsChangedEvent):
987         (WebKit::WebViewImpl::colorSpace):
988         (WebKit::WebViewImpl::beginDeferringViewInWindowChanges):
989         (WebKit::WebViewImpl::endDeferringViewInWindowChanges):
990         (WebKit::WebViewImpl::endDeferringViewInWindowChangesSync):
991         (WebKit::WebViewImpl::prepareForMoveToWindow):
992         (WebKit::WebViewImpl::pressureChangeWithEvent):
993         (WebKit::WebViewImpl::isEditable):
994         (WebKit::WebViewImpl::executeEditCommand):
995         (WebKit::WebViewImpl::registerEditCommand):
996         (WebKit::WebViewImpl::clearAllEditCommands):
997         (WebKit::WebViewImpl::writeSelectionToPasteboard):
998         (WebKit::WebViewImpl::centerSelectionInVisibleArea):
999         (WebKit::WebViewImpl::selectionDidChange):
1000         (WebKit::WebViewImpl::startObservingFontPanel):
1001         (WebKit::WebViewImpl::updateFontPanelIfNeeded):
1002         (WebKit::WebViewImpl::preferencesDidChange):
1003         (WebKit::WebViewImpl::setTextIndicator):
1004         (WebKit::WebViewImpl::clearTextIndicatorWithAnimation):
1005         (WebKit::WebViewImpl::setTextIndicatorAnimationProgress):
1006         (WebKit::WebViewImpl::dismissContentRelativeChildWindows):
1007         (WebKit::WebViewImpl::quickLookWithEvent):
1008         (WebKit::WebViewImpl::prepareForDictionaryLookup):
1009         (WebKit::WebViewImpl::setAllowsLinkPreview):
1010         (WebKit::WebViewImpl::immediateActionAnimationControllerForHitTestResult):
1011         (WebKit::WebViewImpl::prepareForImmediateActionAnimation):
1012         (WebKit::WebViewImpl::cancelImmediateActionAnimation):
1013         (WebKit::WebViewImpl::completeImmediateActionAnimation):
1014         (WebKit::WebViewImpl::setIgnoresNonWheelEvents):
1015         (WebKit::WebViewImpl::setIgnoresAllEvents):
1016         (WebKit::WebViewImpl::accessibilityRegisterUIProcessTokens):
1017         * UIProcess/mac/PageClientImpl.h:
1018         * UIProcess/mac/PageClientImpl.mm:
1019         (WebKit::PageClientImpl::activeWindow):
1020         (WebKit::PageClientImpl::preferencesDidChange):
1021         (WebKit::PageClientImpl::registerEditCommand):
1022         (WebKit::PageClientImpl::clearAllEditCommands):
1023         (WebKit::PageClientImpl::selectionDidChange):
1024         (WebKit::PageClientImpl::didPerformDictionaryLookup):
1025         (-[WKEditCommandObjC initWithWebEditCommandProxy:]): Deleted.
1026         (-[WKEditCommandObjC command]): Deleted.
1027         (-[WKEditorUndoTargetObjC undoEditing:]): Deleted.
1028         (-[WKEditorUndoTargetObjC redoEditing:]): Deleted.
1029         (WebKit::PageClientImpl::PageClientImpl): Deleted.
1030         Move more things to WebViewImpl.
1031         This also introduces an unfortunate pattern that is required for things which
1032         clients override on WKView, where we have a flow like this:
1033                 - somebody (PageClient, etc.) calls WebViewImpl::x
1034                 - WebViewImpl::x does nothing except call [WKView _x]
1035                 - [WKView _x] calls WebViewImpl::xFromViewOnly, which does the real work
1036         As long as no clients call the -FromViewOnly variant, this will mean that
1037         all callers are bottlenecked through the overridable WKView method.
1038         How this works with WKWebView, I am not sure yet.
1039
1040         * UIProcess/mac/WKImmediateActionController.h:
1041         * UIProcess/mac/WKImmediateActionController.mm:
1042         (-[WKImmediateActionController initWithPage:view:viewImpl:recognizer:]):
1043         (-[WKImmediateActionController willDestroyView:]):
1044         (-[WKImmediateActionController immediateActionRecognizerWillPrepare:]):
1045         (-[WKImmediateActionController immediateActionRecognizerDidCancelAnimation:]):
1046         (-[WKImmediateActionController immediateActionRecognizerDidCompleteAnimation:]):
1047         (-[WKImmediateActionController menuItem:viewAtScreenPoint:]):
1048         (-[WKImmediateActionController menuItem:previewItemAtPoint:]):
1049         (-[WKImmediateActionController menuItem:itemFrameForPoint:]):
1050         (-[WKImmediateActionController menuItem:maxSizeForPoint:]):
1051         (-[WKImmediateActionController _animationControllerForDataDetectedText]):
1052         (-[WKImmediateActionController _animationControllerForDataDetectedLink]):
1053         (-[WKImmediateActionController _animationControllerForText]):
1054         (-[WKImmediateActionController initWithPage:view:recognizer:]): Deleted.
1055         Keep a generic NSView, use the WebViewImpl for WK*View related things.
1056
1057 2015-10-22  Joonghun Park  <jh718.park@samsung.com>
1058
1059         [GTK] Fix build break since r191471
1060         https://bugs.webkit.org/show_bug.cgi?id=150487
1061
1062         Reviewed by Žan Doberšek.
1063
1064         * UIProcess/API/gtk/WebKitContextMenuClient.cpp:
1065         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
1066         (WebKit::WebContextMenuProxyGtk::populate):
1067
1068 2015-10-22  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1069
1070         [EFL] Build break since r191472 and r191473
1071         https://bugs.webkit.org/show_bug.cgi?id=150485
1072
1073         Unreviewed build fix.
1074
1075         * CMakeLists.txt: Remove icu include path and move page include path.
1076
1077 2015-10-22  Sam Weinig  <sam@webkit.org>
1078
1079         Navigations on the same host (but with different schemes and ports) should not trigger universal links
1080         <rdar://problem/22811325>
1081         https://bugs.webkit.org/show_bug.cgi?id=150481
1082
1083         Reviewed by Dan Bernstein.
1084
1085         Update the policy for following universal links to only take host into consideration.
1086
1087         * UIProcess/API/C/WKPage.cpp:
1088         (WKPageSetPageUIClient):
1089         * UIProcess/Cocoa/UIDelegate.mm:
1090         (WebKit::UIDelegate::UIClient::createNewPage):
1091         * UIProcess/WebPageProxy.cpp:
1092         (WebKit::WebPageProxy::decidePolicyForNavigationAction):
1093         (WebKit::WebPageProxy::decidePolicyForNewWindowAction):
1094         (WebKit::WebPageProxy::createNewPage):
1095         (WebKit::WebPageProxy::showPage):
1096
1097 2015-10-22  Anders Carlsson  <andersca@apple.com>
1098
1099         Simplify menu creation
1100         https://bugs.webkit.org/show_bug.cgi?id=150476
1101
1102         Reviewed by Tim Horton.
1103
1104         Instead of creating vectors of NSMenuItem objects, just simply build the menu recursively.
1105
1106         * UIProcess/mac/WebContextMenuProxyMac.h:
1107         * UIProcess/mac/WebContextMenuProxyMac.mm:
1108         (WebKit::WebContextMenuProxyMac::createContextMenuFromItems):
1109         (WebKit::WebContextMenuProxyMac::createContextMenuItem):
1110         (WebKit::WebContextMenuProxyMac::showContextMenu):
1111         (WebKit::populateNSMenu): Deleted.
1112         (WebKit::nsMenuItem): Deleted.
1113         (WebKit::nsMenuItemVector): Deleted.
1114
1115 2015-10-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1116
1117         ERROR: Unhandled web process message 'StorageAreaMap:DispatchStorageEvent'
1118         https://bugs.webkit.org/show_bug.cgi?id=150315
1119
1120         Reviewed by Andreas Kling.
1121
1122         It was introduced in r184930, that keeps the session storage area
1123         maps alive in the UI process when they are destroyed by the web
1124         process. The problem is that we also keep the listeners, so that
1125         events are also dispatched to the listeners of destroyed areas,
1126         and the message handlers were removed in the web process.
1127
1128         * UIProcess/Storage/StorageManager.cpp:
1129         (WebKit::StorageManager::createTransientLocalStorageMap): Add a
1130         listener for the new storage map ID when the map is reused.
1131         (WebKit::StorageManager::destroyStorageMap): Always remove
1132         listeners of destroyed maps.
1133
1134 2015-10-22  Tim Horton  <timothy_horton@apple.com>
1135
1136         Add a SPI variant of loadData that accepts user data to WKWebView
1137         https://bugs.webkit.org/show_bug.cgi?id=150475
1138
1139         Reviewed by Anders Carlsson.
1140
1141         * UIProcess/API/Cocoa/WKWebView.mm:
1142         (-[WKWebView _loadData:MIMEType:characterEncodingName:baseURL:userData:]):
1143         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1144
1145 2015-10-22  Alex Christensen  <achristensen@webkit.org>
1146
1147         Progress towards CMake on Mac
1148         https://bugs.webkit.org/show_bug.cgi?id=150466
1149
1150         Reviewed by Chris Dumez.
1151
1152         * CMakeLists.txt:
1153         * PlatformMac.cmake:
1154         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
1155
1156 2015-10-22  Anders Carlsson  <andersca@apple.com>
1157
1158         NativeContextMenuItem isn't needed anymore, remove it
1159         https://bugs.webkit.org/show_bug.cgi?id=150473
1160
1161         Reviewed by Tim Horton.
1162
1163         * PlatformEfl.cmake:
1164         * PlatformGTK.cmake:
1165         * Shared/NativeContextMenuItem.h: Removed.
1166         (WebKit::NativeContextMenuItem::~NativeContextMenuItem): Deleted.
1167         (WebKit::NativeContextMenuItem::nsMenuItem): Deleted.
1168         * Shared/WebContextMenuItem.cpp:
1169         (WebKit::WebContextMenuItem::WebContextMenuItem): Deleted.
1170         * Shared/WebContextMenuItem.h:
1171         (WebKit::WebContextMenuItem::create): Deleted.
1172         (WebKit::WebContextMenuItem::nativeContextMenuItem): Deleted.
1173         * Shared/efl/NativeContextMenuItemEfl.cpp: Removed.
1174         (WebKit::NativeContextMenuItem::NativeContextMenuItem): Deleted.
1175         * Shared/gtk/NativeContextMenuItemGtk.cpp: Removed.
1176         (WebKit::NativeContextMenuItem::NativeContextMenuItem): Deleted.
1177         * Shared/mac/NativeContextMenuItem.mm: Removed.
1178         (WebKit::NativeContextMenuItem::NativeContextMenuItem): Deleted.
1179         * UIProcess/mac/WebContextMenuProxyMac.mm:
1180         (WebKit::nsMenuItem): Deleted.
1181         * WebKit2.xcodeproj/project.pbxproj:
1182
1183 2015-10-22  Anders Carlsson  <andersca@apple.com>
1184
1185         CTTE WebContextMenuItemData
1186         https://bugs.webkit.org/show_bug.cgi?id=150471
1187
1188         Reviewed by Tim Horton.
1189
1190         * Shared/API/c/WKContextMenuItem.cpp:
1191         (WKContextMenuItemGetTag):
1192         (WKContextMenuItemGetType):
1193         (WKContextMenuItemCopyTitle):
1194         (WKContextMenuItemGetEnabled):
1195         (WKContextMenuItemGetChecked):
1196         * Shared/WebContextMenuItem.cpp:
1197         (WebKit::WebContextMenuItem::create):
1198         * Shared/WebContextMenuItem.h:
1199         (WebKit::WebContextMenuItem::data):
1200         * UIProcess/API/C/WKPage.cpp:
1201         (WKPageSelectContextMenuItem):
1202         * UIProcess/mac/WebContextMenuProxyMac.mm:
1203         (WebKit::nsMenuItem):
1204         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
1205         (WKBundlePageClickMenuItem):
1206         * WebProcess/InjectedBundle/InjectedBundlePageContextMenuClient.cpp:
1207         (WebKit::InjectedBundlePageContextMenuClient::getCustomMenuFromDefaultItems):
1208
1209 2015-10-22  Anders Carlsson  <andersca@apple.com>
1210
1211         Handle nil menu items.
1212
1213         * UIProcess/mac/WebContextMenuProxyMac.mm:
1214         (WebKit::nsMenuItemVector):
1215
1216 2015-10-22  Anders Carlsson  <andersca@apple.com>
1217
1218         Wait to convert the share menu item to a real share menu until after calling out to the client
1219         https://bugs.webkit.org/show_bug.cgi?id=150465
1220
1221         Reviewed by Tim Horton.
1222
1223         This will let us simplify more code in upcoming patches.
1224
1225         * UIProcess/mac/WebContextMenuProxyMac.h:
1226         * UIProcess/mac/WebContextMenuProxyMac.mm:
1227         (WebKit::nsMenuItem):
1228         (WebKit::nsMenuItemVector):
1229         (WebKit::WebContextMenuProxyMac::showContextMenu):
1230
1231 2015-10-22  Myles C. Maxfield  <mmaxfield@apple.com>
1232
1233         [Cocoa] Migrate WKSetPatternPhaseInUserSpace() and WKGetUserToBaseCTM() from WKSI
1234         https://bugs.webkit.org/show_bug.cgi?id=150460
1235
1236         Reviewed by Tim Horton.
1237
1238         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
1239         (InitWebCoreSystemInterface): Deleted.
1240
1241 2015-10-22  Alex Christensen  <achristensen@webkit.org>
1242
1243         Initial NSURLSession WebResourceLoader implementation
1244         https://bugs.webkit.org/show_bug.cgi?id=150355
1245
1246         Reviewed by Antti Koivisto.
1247
1248         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
1249         (WebKit::NetworkConnectionToWebProcess::convertMainResourceLoadToDownload):
1250         (WebKit::NetworkConnectionToWebProcess::cookiesForDOM):
1251         * NetworkProcess/NetworkResourceLoader.cpp:
1252         (WebKit::NetworkResourceLoader::~NetworkResourceLoader):
1253         (WebKit::NetworkResourceLoader::startNetworkLoad):
1254         (WebKit::NetworkResourceLoader::setDefersLoading):
1255         (WebKit::NetworkResourceLoader::cleanup):
1256         (WebKit::NetworkResourceLoader::didConvertHandleToDownload):
1257         (WebKit::NetworkResourceLoader::abort):
1258         (WebKit::NetworkResourceLoader::willPerformHTTPRedirection):
1259         (WebKit::NetworkResourceLoader::didReceiveChallenge):
1260         (WebKit::NetworkResourceLoader::didReceiveResponse):
1261         (WebKit::NetworkResourceLoader::didReceiveData):
1262         (WebKit::NetworkResourceLoader::didCompleteWithError):
1263         (WebKit::NetworkResourceLoader::didReceiveResponseAsync):
1264         (WebKit::NetworkResourceLoader::willSendRequestAsync):
1265         (WebKit::NetworkResourceLoader::continueWillSendRequest):
1266         (WebKit::NetworkResourceLoader::continueDidReceiveResponse):
1267         (WebKit::NetworkResourceLoader::didSendData):
1268         (WebKit::NetworkResourceLoader::receivedCancellation):
1269         (WebKit::NetworkResourceLoader::startBufferingTimerIfNeeded):
1270         (WebKit::NetworkResourceLoader::bufferingTimerFired):
1271         (WebKit::NetworkResourceLoader::validateCacheEntry):
1272         (WebKit::NetworkResourceLoader::sendAbortingOnFailure):
1273         (WebKit::NetworkResourceLoader::canAuthenticateAgainstProtectionSpaceAsync):
1274         (WebKit::NetworkResourceLoader::continueCanAuthenticateAgainstProtectionSpace):
1275         (WebKit::NetworkResourceLoader::supportsDataArray):
1276         * NetworkProcess/NetworkResourceLoader.h:
1277         (WebKit::NetworkResourceLoader::create):
1278         (WebKit::NetworkResourceLoader::currentRequest):
1279         (WebKit::NetworkResourceLoader::handle):
1280         * NetworkProcess/NetworkSession.h: Added.
1281         (WebKit::NetworkSessionTaskClient::~NetworkSessionTaskClient):
1282         (WebKit::NetworkingDataTask::client):
1283         (WebKit::NetworkingDataTask::clearClient):
1284         (WebKit::NetworkSession::~NetworkSession):
1285         * NetworkProcess/cocoa/NetworkSessionCocoa.mm: Added.
1286         (toNSURLSessionResponseDisposition):
1287         (toNSURLSessionAuthChallengeDisposition):
1288         (-[NetworkSessionDelegate initWithNetworkSession:]):
1289         (-[NetworkSessionDelegate URLSession:task:willPerformHTTPRedirection:newRequest:completionHandler:]):
1290         (-[NetworkSessionDelegate URLSession:task:didReceiveChallenge:completionHandler:]):
1291         (-[NetworkSessionDelegate URLSession:task:didCompleteWithError:]):
1292         (-[NetworkSessionDelegate URLSession:dataTask:didReceiveResponse:completionHandler:]):
1293         (-[NetworkSessionDelegate URLSession:dataTask:didReceiveData:]):
1294         (WebKit::NetworkSession::create):
1295         (WebKit::NetworkSession::singleton):
1296         (WebKit::configurationForType):
1297         (WebKit::NetworkSession::NetworkSession):
1298         (WebKit::NetworkSession::createDataTaskWithRequest):
1299         (WebKit::NetworkSession::dataTaskForIdentifier):
1300         (WebKit::NetworkingDataTask::NetworkingDataTask):
1301         (WebKit::NetworkingDataTask::~NetworkingDataTask):
1302         (WebKit::NetworkingDataTask::suspend):
1303         (WebKit::NetworkingDataTask::resume):
1304         (WebKit::NetworkingDataTask::taskIdentifier):
1305         * NetworkProcess/mac/NetworkResourceLoaderMac.mm:
1306         (WebKit::NetworkResourceLoader::willCacheResponseAsync):
1307         * WebKit2.xcodeproj/project.pbxproj:
1308         * config.h:
1309
1310 2015-10-22  Philippe Normand  <pnormand@igalia.com>
1311
1312         Unreviewed, GTK build fix for disabled redirected XComposite window support.
1313
1314         * UIProcess/API/gtk/WebKitWebViewBase.cpp: Add USE(REDIRECTED_XCOMPOSITE_WINDOW) guards.
1315         * UIProcess/DrawingAreaProxyImpl.h: Mark virtual methods as override to avoid compilation warnings.
1316
1317 2015-10-22  Wenson Hsieh  <wenson_hsieh@apple.com>
1318
1319         Implement touch-action: manipulation; for iOS
1320         https://bugs.webkit.org/show_bug.cgi?id=149854
1321         <rdar://problem/23017145>
1322
1323         Reviewed by Benjamin Poulain.
1324
1325         Implements the manipulation value for the CSS property touch-action. Performs hit-testing upon receiving a potential
1326         tap to determine whether to disable double-tap gesture recognition over the duration of the tap. If so, sends a message
1327         from the web process to the UI process indicating that double-tapping should be disabled, allowing single taps to
1328         avoid the delay.
1329
1330         * WebProcess/WebPage/ios/WebPageIOS.mm:
1331         (WebKit::WebPage::potentialTapAtPosition):
1332
1333 2015-10-22  Ryosuke Niwa  <rniwa@webkit.org>
1334
1335         REGRESSION (r181972): Scroll position changes to top of youtube page when switching tabs
1336         https://bugs.webkit.org/show_bug.cgi?id=150428
1337
1338         Reviewed by Antti Koivisto.
1339
1340         Call updateFocusAppearance with RevealMode::DoNotReveal to avoid revealing the focused element.
1341
1342         * WebProcess/WebPage/WebPage.cpp:
1343         (WebKit::WebPage::restoreSelectionInFocusedEditableElement):
1344
1345 2015-10-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1346
1347         Unreviewed. Fix a crash in GTk+ after r191402.
1348
1349         Since r191402 WebContextMenuProxy is no longer refcounted, and
1350         std::unique_ptr is used instead. This means that when we show the
1351         context menu for the second time in a web view, a new
1352         WebContextMenuProxy is created and the previous one is
1353         destroyed. We were setting the active context menu of the WebView
1354         in the constructor of WebContextMenuProxy, and unsetting it in the
1355         destructor. Now the constructor of the new WebContextMenuProxy
1356         happens before the destructor of the current one that unsets the
1357         WebView active context menu. This patch simply makes the web view
1358         unset its active context menu when it's unmapped and a new one
1359         hasn't been set.
1360
1361         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1362         (activeContextMenuUnmapped):
1363         (webkitWebViewBaseSetActiveContextMenuProxy):
1364         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
1365         (WebKit::WebContextMenuProxyGtk::~WebContextMenuProxyGtk):
1366
1367 2015-10-22  Hunseop Jeong  <hs85.jeong@samsung.com>
1368
1369         [GTK] Try to fix the build after r191402.
1370         https://bugs.webkit.org/show_bug.cgi?id=150435
1371
1372         Reviewed by Carlos Garcia Campos.
1373
1374         * UIProcess/API/gtk/PageClientImpl.cpp:
1375         (WebKit::PageClientImpl::createPopupMenuProxy):
1376         (WebKit::PageClientImpl::createContextMenuProxy):
1377         (WebKit::PageClientImpl::createColorPicker):
1378         * UIProcess/API/gtk/PageClientImpl.h:
1379         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
1380         (WebKit::WebContextMenuProxyGtk::populate):
1381         (WebKit::WebContextMenuProxyGtk::show):
1382         (WebKit::WebContextMenuProxyGtk::WebContextMenuProxyGtk):
1383         (WebKit::WebContextMenuProxyGtk::~WebContextMenuProxyGtk):
1384         (WebKit::WebContextMenuProxyGtk::menuPositionFunction):
1385         (WebKit::WebContextMenuProxyGtk::showContextMenu): Deleted.
1386         (WebKit::WebContextMenuProxyGtk::hideContextMenu): Deleted.
1387         (WebKit::WebContextMenuProxyGtk::cancelTracking): Deleted.
1388         * UIProcess/gtk/WebContextMenuProxyGtk.h:
1389         (WebKit::WebContextMenuProxyGtk::gtkMenu):
1390         (WebKit::WebContextMenuProxyGtk::create): Deleted.
1391
1392 2015-10-21  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1393
1394        Unreviewed EFL build fix. Remove customizeMenu implementation.
1395
1396         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
1397         (WebKit::WebContextMenuClient::customizeMenu): Deleted.
1398
1399 2015-10-21  Alex Christensen  <achristensen@webkit.org>
1400
1401         Speculative EFL build fix.
1402
1403         * WebProcess/WebCoreSupport/WebContextMenuClient.h:
1404         Remove another customizeMenu call.
1405
1406 2015-10-21  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1407
1408         [EFL][GTK][WK2] Fix build break since r191402, r191401
1409         https://bugs.webkit.org/show_bug.cgi?id=150432
1410
1411         Unreviewed EFL and GTK build fix.
1412
1413         * CMakeLists.txt:
1414         * UIProcess/CoordinatedGraphics/WebView.cpp:
1415         (WebKit::WebView::createContextMenuProxy):
1416         * UIProcess/CoordinatedGraphics/WebView.h:
1417         * UIProcess/efl/WebContextMenuProxyEfl.cpp:
1418         (WebKit::WebContextMenuProxyEfl::show):
1419         * UIProcess/efl/WebContextMenuProxyEfl.h:
1420         (WebKit::WebContextMenuProxyEfl::create): Deleted.
1421         * UIProcess/efl/WebViewEfl.cpp:
1422         (WebKit::WebViewEfl::createContextMenuProxy):
1423         * UIProcess/efl/WebViewEfl.h:
1424         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
1425         (WebKit::WebContextMenuClient::customizeMenu):
1426         * WebProcess/WebCoreSupport/WebContextMenuClient.h:
1427
1428 2015-10-21  Anders Carlsson  <andersca@apple.com>
1429
1430         Get rid of WebContextMenuClient::customizeMenu, it's no longer used
1431         https://bugs.webkit.org/show_bug.cgi?id=150427
1432
1433         Reviewed by Tim Horton.
1434
1435         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
1436         (WebKit::WebContextMenuClient::customizeMenu): Deleted.
1437         * WebProcess/WebCoreSupport/WebContextMenuClient.h:
1438
1439 2015-10-21  Tim Horton  <timothy_horton@apple.com>
1440
1441         API-ify the FindMatches client
1442         https://bugs.webkit.org/show_bug.cgi?id=150422
1443
1444         Reviewed by Anders Carlsson.
1445
1446         * UIProcess/API/APIFindMatchesClient.h: Renamed from Source/WebKit2/UIProcess/WebFindClient.h.
1447         (API::FindMatchesClient::~FindMatchesClient):
1448         (API::FindMatchesClient::didFindStringMatches):
1449         (API::FindMatchesClient::didGetImageForMatchResult):
1450         * UIProcess/API/C/WKPage.cpp:
1451         (WKPageSetPageFindMatchesClient):
1452         * UIProcess/WebFindClient.cpp: Removed.
1453         * UIProcess/WebPageProxy.cpp:
1454         (WebKit::WebPageProxy::WebPageProxy):
1455         (WebKit::WebPageProxy::setFindMatchesClient):
1456         (WebKit::WebPageProxy::close):
1457         (WebKit::WebPageProxy::didGetImageForFindMatch):
1458         (WebKit::WebPageProxy::didFindStringMatches):
1459         (WebKit::WebPageProxy::initializeFindMatchesClient): Deleted.
1460         * UIProcess/WebPageProxy.h:
1461         (WebKit::WebPageProxy::findMatchesClient):
1462         * WebKit2.xcodeproj/project.pbxproj:
1463
1464 2015-10-21  Enrica Casucci  <enrica@apple.com>
1465
1466         WebProcess crashes when accessibility bundle is not found.
1467         https://bugs.webkit.org/show_bug.cgi?id=150414
1468
1469         Reviewed by Dan Bernstein.
1470
1471         The uninitialized pointer to NSError causes the print function to crash.
1472
1473         * WebProcess/cocoa/WebProcessCocoa.mm:
1474         (WebKit::registerWithAccessibility):
1475
1476 2015-10-21  Anders Carlsson  <andersca@apple.com>
1477
1478         Move services menu handling out into a separate function
1479         https://bugs.webkit.org/show_bug.cgi?id=150420
1480
1481         Reviewed by Tim Horton.
1482
1483         * UIProcess/mac/WebContextMenuProxyMac.h:
1484         * UIProcess/mac/WebContextMenuProxyMac.mm:
1485         (WebKit::WebContextMenuProxyMac::showServicesMenu):
1486         (WebKit::WebContextMenuProxyMac::show):
1487         (WebKit::WebContextMenuProxyMac::showContextMenu):
1488         (WebKit::WebContextMenuProxyMac::populate): Deleted.
1489
1490 2015-10-21  Wenson Hsieh  <wenson_hsieh@apple.com>
1491
1492         Single tapping clickable elements in unscalable pages should show a tap highlight
1493         https://bugs.webkit.org/show_bug.cgi?id=150382
1494
1495         Reviewed by Simon Fraser.
1496
1497         When the double tap gesture recognizer is disabled ahead of time (as in the case of unscalable pages) the tap is
1498         committed before the geometries come in. To fix this, we introduce a flag that allows the single tap to be
1499         committed before the tap highlight arrives. This allows the tap highlight to be immediately animated when receiving
1500         the tap highlight geometries only in the case where double tapping is disabled when recognizing the single tap.
1501
1502         * UIProcess/ios/WKContentViewInteraction.h:
1503         * UIProcess/ios/WKContentViewInteraction.mm:
1504         (-[WKContentView setupInteraction]):
1505         (-[WKContentView cleanupInteraction]):
1506         (-[WKContentView _didGetTapHighlightForRequest:color:quads:topLeftRadius:topRightRadius:bottomLeftRadius:bottomRightRadius:]):
1507         (-[WKContentView _singleTapRecognized:]):
1508         (-[WKContentView _singleTapCommited:]):
1509
1510 2015-10-21  Anders Carlsson  <andersca@apple.com>
1511
1512         Get rid of useBinaryEncoding from WKPageGetContentsAsMHTMLData
1513         https://bugs.webkit.org/show_bug.cgi?id=150417
1514
1515         Reviewed by Tim Horton.
1516
1517         The useBinaryEncoding parameter is always false, so just get rid of it.
1518
1519         * UIProcess/API/C/WKPage.cpp:
1520         (WKPageGetContentsAsMHTMLData):
1521         * UIProcess/API/C/WKPage.h:
1522         * UIProcess/API/efl/ewk_view.cpp:
1523         (ewk_view_page_contents_get):
1524         * UIProcess/API/gtk/WebKitWebView.cpp:
1525         (webkit_web_view_save):
1526         (webkit_web_view_save_to_file):
1527         * UIProcess/WebPageProxy.cpp:
1528         (WebKit::WebPageProxy::getContentsAsMHTMLData):
1529         * UIProcess/WebPageProxy.h:
1530         * WebProcess/WebPage/WebPage.cpp:
1531         (WebKit::WebPage::getContentsAsMHTMLData):
1532         * WebProcess/WebPage/WebPage.h:
1533         * WebProcess/WebPage/WebPage.messages.in:
1534
1535 2015-10-21  Anders Carlsson  <andersca@apple.com>
1536
1537         WebContextMenuProxyMac::setupServicesMenu doesn't need to take a context parameter
1538         https://bugs.webkit.org/show_bug.cgi?id=150418
1539
1540         Reviewed by Tim Horton.
1541
1542         * UIProcess/mac/WebContextMenuProxyMac.h:
1543         * UIProcess/mac/WebContextMenuProxyMac.mm:
1544         (WebKit::WebContextMenuProxyMac::setupServicesMenu):
1545         (WebKit::WebContextMenuProxyMac::populate):
1546
1547 2015-10-21  Anders Carlsson  <andersca@apple.com>
1548
1549         WebContextMenuProxy doesn't have to be ref-counted
1550         https://bugs.webkit.org/show_bug.cgi?id=150415
1551
1552         Reviewed by Tim Horton.
1553
1554         Change WebContextMenuProxy to not inherit from RefCounted. Instead of using RefPtr, use std::unique_ptr.
1555         Get rid of cancelTracking and hideContextMenu and dismiss the menu whenever the menu proxy is destroyed.
1556         Also, rename showContextMenu to show.
1557
1558         * UIProcess/PageClient.h:
1559         * UIProcess/WebContextMenuProxy.h:
1560         (WebKit::WebContextMenuProxy::cancelTracking): Deleted.
1561         * UIProcess/WebPageProxy.cpp:
1562         (WebKit::WebPageProxy::close):
1563         (WebKit::WebPageProxy::internalShowContextMenu):
1564         * UIProcess/WebPageProxy.h:
1565         * UIProcess/ios/PageClientImplIOS.h:
1566         * UIProcess/ios/PageClientImplIOS.mm:
1567         (WebKit::PageClientImpl::createContextMenuProxy):
1568         * UIProcess/mac/PageClientImpl.h:
1569         * UIProcess/mac/PageClientImpl.mm:
1570         (WebKit::PageClientImpl::createContextMenuProxy):
1571         * UIProcess/mac/WebContextMenuProxyMac.h:
1572         (WebKit::WebContextMenuProxyMac::create): Deleted.
1573         * UIProcess/mac/WebContextMenuProxyMac.mm:
1574         (WebKit::WebContextMenuProxyMac::~WebContextMenuProxyMac):
1575         (WebKit::WebContextMenuProxyMac::show):
1576         (WebKit::WebContextMenuProxyMac::showContextMenu): Deleted.
1577         (WebKit::WebContextMenuProxyMac::hideContextMenu): Deleted.
1578         (WebKit::WebContextMenuProxyMac::cancelTracking): Deleted.
1579
1580 2015-10-21  Anders Carlsson  <andersca@apple.com>
1581
1582         Stop using a popup menu button cell(!) for context menus
1583         https://bugs.webkit.org/show_bug.cgi?id=150413
1584
1585         Reviewed by Tim Horton.
1586
1587         Just use a regular NSMenu. Also, have the service menu code path store the service menu
1588         in the same member variable.
1589
1590         * UIProcess/mac/WebContextMenuProxyMac.h:
1591         * UIProcess/mac/WebContextMenuProxyMac.mm:
1592         (WebKit::WebContextMenuProxyMac::setupServicesMenu):
1593         (WebKit::WebContextMenuProxyMac::clearServicesMenu):
1594         (WebKit::WebContextMenuProxyMac::populate):
1595         (WebKit::WebContextMenuProxyMac::showContextMenu):
1596         (WebKit::WebContextMenuProxyMac::hideContextMenu):
1597         (WebKit::WebContextMenuProxyMac::cancelTracking):
1598         (WebKit::WebContextMenuProxyMac::~WebContextMenuProxyMac): Deleted.
1599
1600 2015-10-21  Chris Dumez  <cdumez@apple.com>
1601
1602         Add assertions to NetworkCache::Entry constructor to make sure a key's type is "resource"
1603         https://bugs.webkit.org/show_bug.cgi?id=150369
1604
1605         Reviewed by Antti Koivisto.
1606
1607         Add assertions to NetworkCache::Entry constructor to make sure a key's
1608         type is "resource" now that the NetworkCache storage supports other
1609         types of entries.
1610
1611         * NetworkProcess/cache/NetworkCacheEntry.cpp:
1612         (WebKit::NetworkCache::Entry::Entry):
1613
1614 2015-10-21  Carlos Garcia Campos  <cgarcia@igalia.com>
1615
1616         NetworkProcess: DNS prefetch happens in the Web Process
1617         https://bugs.webkit.org/show_bug.cgi?id=147824
1618
1619         Reviewed by Chris Dumez.
1620
1621         DNS prefetch requests started in the WebProcess should be sent to
1622         the network process when it's enabled.
1623
1624         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
1625         (WebKit::NetworkConnectionToWebProcess::prefetchDNS): Use NetworkProcess::prefetchDNS().
1626         * NetworkProcess/NetworkConnectionToWebProcess.h:
1627         * NetworkProcess/NetworkConnectionToWebProcess.messages.in: Add
1628         PrefetchDNS message.
1629         * NetworkProcess/NetworkProcess.cpp:
1630         (WebKit::NetworkProcess::prefetchDNS): Do the actual DNS prefetch.
1631         * NetworkProcess/NetworkProcess.h:
1632         * WebProcess/InjectedBundle/API/gtk/WebKitWebExtension.cpp:
1633         (webkitWebExtensionDidReceiveMessage): Use WebProcess::prefetchDNS().
1634         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1635         (WebKit::WebFrameLoaderClient::prefetchDNS): Use WebProcess::prefetchDNS().
1636         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
1637         * WebProcess/WebPage/ios/WebPageIOS.mm:
1638         (WebKit::WebPage::sendTapHighlightForNodeIfNecessary): Use
1639         FrameLoaderClient to do the DNS prefetch.
1640         * WebProcess/WebProcess.cpp:
1641         (WebKit::WebProcess::WebProcess): Initialize the DNS prefetched
1642         hosts cleanup hysteresis activity. Clear the cache of DNS
1643         prefetched when hysteresis activity stopped.
1644         (WebKit::WebProcess::prefetchDNS): Send the request to the network
1645         process if it's enabled, otherwise do the actual DNS prefetch.
1646         * WebProcess/WebProcess.h:
1647
1648 2015-10-20  Chris Dumez  <cdumez@apple.com>
1649
1650         [WK2] Generalize NetworkCacheStorage API so it can store different types of metadata
1651         https://bugs.webkit.org/show_bug.cgi?id=150221
1652         <rdar://problem/23149771>
1653
1654         Reviewed by Darin Adler and Antti Koivisto.
1655
1656         Generalize NetworkCacheStorage API so it can store different types of
1657         metadata alongside the network resources. This is a pre-requirement to
1658         making our NetworkCache smarter by storing information about the
1659         resources.
1660
1661         To keep the code simple, the entry type is now part of the entry key and
1662         we store records of a specific type in a 'type' subfolder. The cache
1663         structure looks like so:
1664         - WebKitCache/Version 5/[Partition]/[Type]/[Hash]
1665         - WebKitCache/Version 5/[Partition]/[Type]/[Hash]-blob (Optional)
1666
1667         Existing cache entries now that the 'resource' type as these are network
1668         resources.
1669
1670         * NetworkProcess/cache/NetworkCache.cpp:
1671         * NetworkProcess/cache/NetworkCacheKey.cpp:
1672         * NetworkProcess/cache/NetworkCacheKey.h:
1673         * NetworkProcess/cache/NetworkCacheStatistics.cpp:
1674         * NetworkProcess/cache/NetworkCacheStorage.cpp:
1675         * NetworkProcess/cache/NetworkCacheStorage.h:
1676
1677 2015-10-20  Hunseop Jeong  <hs85.jeong@samsung.com>
1678
1679         [EFL] ContextMenu doesn't work correctly on MiniBrowser after r191194.
1680         https://bugs.webkit.org/show_bug.cgi?id=150311
1681
1682         Reviewed by Gyuyoung Kim.
1683
1684         Restore the test_ewk2_context_menu API test to check the context menu whether it works correctly.
1685
1686         * PlatformEfl.cmake:
1687
1688 2015-10-13  Conrad Shultz  <conrad_shultz@apple.com>
1689
1690         _WKThumbnailView should support a snapshot-only mode
1691         https://bugs.webkit.org/show_bug.cgi?id=150106
1692
1693         Reviewed by Tim Horton.
1694
1695         Add a new property to _WKThumbnailView, exclusivelyUsesSnapshot, which causes _WKThumbnailView
1696         to bypass both layer tree reparenting and event suppression on the associated WKView.
1697
1698         Add a new method, -requestSnapshot, which clients can use to force _WKThumbnailView to refresh
1699         on demand.
1700
1701         * UIProcess/API/Cocoa/_WKThumbnailView.h:
1702         * UIProcess/API/Cocoa/_WKThumbnailView.mm:
1703         (-[_WKThumbnailView requestSnapshot]):
1704         Extracted from -_requestSnapshotIfNeeded:.
1705         (-[_WKThumbnailView _viewWasUnparented]):
1706         (-[_WKThumbnailView _viewWasParented]):
1707         (-[_WKThumbnailView _requestSnapshotIfNeeded]):
1708
1709 2015-10-20  Alexey Proskuryakov  <ap@apple.com>
1710
1711         Build fix.
1712
1713         * UIProcess/ios/forms/WKAirPlayRoutePicker.mm:
1714         * UIProcess/ios/forms/WKFileUploadPanel.mm:
1715
1716 2015-10-20  Joseph Pecoraro  <pecoraro@apple.com>
1717
1718         ASSERT when right clicking on SVG Image generating Share menu - can break Web Inspector
1719         https://bugs.webkit.org/show_bug.cgi?id=150374
1720
1721         Reviewed by Brian Burg.
1722
1723         When there is no absolute URL or downloadable media URL no system share
1724         menu is created, but we were still appending the null context menu to
1725         the list of context menu items.
1726
1727         * UIProcess/mac/WebContextMenuProxyMac.mm:
1728         (WebKit::WebContextMenuProxyMac::shareMenuItem):
1729         Bail early if the context menu is null.
1730
1731         (WebKit::WebContextMenuProxyMac::showContextMenu):
1732         Only append the share context menu item if it is non-null.
1733         This matches ContextMenuController.cpp in WebCore.
1734
1735 2015-10-20  Commit Queue  <commit-queue@webkit.org>
1736
1737         Unreviewed, rolling out r191306.
1738         https://bugs.webkit.org/show_bug.cgi?id=150371
1739
1740         "May have caused a significant warm PLT regression" (Requested
1741         by cdumez_ on #webkit).
1742
1743         Reverted changeset:
1744
1745         "[WK2] Generalize NetworkCacheStorage API so it can store
1746         different types of metadata"
1747         https://bugs.webkit.org/show_bug.cgi?id=150221
1748         http://trac.webkit.org/changeset/191306
1749
1750 2015-10-20  Tim Horton  <timothy_horton@apple.com>
1751
1752         Try to fix the build by disabling MAC_GESTURE_EVENTS on 10.9 and 10.10
1753
1754         * Configurations/FeatureDefines.xcconfig:
1755
1756 2015-10-20  Commit Queue  <commit-queue@webkit.org>
1757
1758         Unreviewed, rolling out r191333.
1759         https://bugs.webkit.org/show_bug.cgi?id=150362
1760
1761         Caused assertions on regression tests (Requested by ap on
1762         #webkit).
1763
1764         Reverted changeset:
1765
1766         "ERROR: Unhandled web process message
1767         'StorageAreaMap:DispatchStorageEvent'"
1768         https://bugs.webkit.org/show_bug.cgi?id=150315
1769         http://trac.webkit.org/changeset/191333
1770
1771 2015-10-20  Carlos Garcia Campos  <cgarcia@igalia.com>
1772
1773         [UNIX] ASSERTION FAILED: m_shouldWaitForSyncReplies in Connection::connectionDidClose()
1774         https://bugs.webkit.org/show_bug.cgi?id=150361
1775
1776         Reviewed by Martin Robinson.
1777
1778         It doesn't always happen because it depends on how sockets are
1779         closed, and the state of the threads. The problem is that we are
1780         not handling the case when the read fails because we closed the
1781         connection. In that case we log the error and call
1782         Connection::connectionDidClose(). But it was connectionDidClose()
1783         the one closing the socket. So, in this particular case it's not an
1784         error but a normal termination, and we shouldn't try to close the
1785         connection again. Something similar can happen while sending a
1786         message, and we get a broken pipe error, but in that case we are
1787         only printing the error, so it's harmless.
1788
1789         * Platform/IPC/unix/ConnectionUnix.cpp:
1790         (IPC::Connection::readyReadHandler): Only print error and call
1791         connectionDidClose() if we are still connected when read fails.
1792         (IPC::Connection::sendOutgoingMessage): Only print error if we are
1793         still connected when send fails.
1794
1795 2015-10-20  Carlos Garcia Campos  <cgarcia@igalia.com>
1796
1797         [GTK] Graphics corruption when entering/leaving AC mode quickly
1798         https://bugs.webkit.org/show_bug.cgi?id=150323
1799
1800         Reviewed by Mario Sanchez Prada.
1801
1802         The UI process is notified when entering accelerated compositing
1803         mode after the layers have been flushed and rendered to avoid
1804         flickering. However, this is producing flickering in the GTK+
1805         port, because we use an offscreen redirected window that is
1806         resized to a minimium size to save memory when not in AC mode. The
1807         web process always uses the current size of the redirected window,
1808         so when entering AC mode, contents are rendered into the 1x1
1809         window, then the UI process is notified, the redirected window is
1810         resized to its actual size, and we force a resize to ask the web
1811         process to render again, now at the correct size. Rendering at 1x1
1812         and then resizing the window is what produces the flickering when
1813         entering AC mode, but it's also inefficient, since we need to
1814         render again after the redirected window is resized. So, this
1815         patch adds a WillEnterAcceleratedCompositing message that is sent
1816         to the UI process when the layer tree host is created but before
1817         the contents have been composited and rendered. This is
1818         implemented by the GTK+ port to prepare for entering AC mode, by
1819         resizing the redirected window. When we actually enter AC mode,
1820         the contents have already been rendered in the web process at the
1821         correct size, so we can just use the redirected window surface
1822         instead of the drawing area one, and paint in the web view without
1823         any flickering. We no longer need the forceResize either.
1824         When leaving accelerated compositing mode, we now clear the redirected
1825         window resources after a short delay. This ensures that we have
1826         already rendered the update sent in the ExitAcceleratedCompositingMode
1827         message, but also that entering/leaving AC mode quickly doesn't
1828         produce any redirected window resize.
1829
1830         * UIProcess/API/gtk/PageClientImpl.cpp:
1831         (WebKit::PageClientImpl::willEnterAcceleratedCompositingMode):
1832         * UIProcess/API/gtk/PageClientImpl.h:
1833         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1834         (webkitWebViewBaseClearRedirectedWindowSoon):
1835         (webkitWebViewBaseWillEnterAcceleratedCompositingMode):
1836         (webkitWebViewBaseEnterAcceleratedCompositingMode):
1837         (webkitWebViewBaseExitAcceleratedCompositingMode):
1838         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h:
1839         * UIProcess/CoordinatedGraphics/WebView.h:
1840         * UIProcess/DrawingAreaProxy.h:
1841         (WebKit::DrawingAreaProxy::willEnterAcceleratedCompositingMode):
1842         * UIProcess/DrawingAreaProxy.messages.in:
1843         * UIProcess/DrawingAreaProxyImpl.cpp:
1844         (WebKit::DrawingAreaProxyImpl::willEnterAcceleratedCompositingMode):
1845         * UIProcess/DrawingAreaProxyImpl.h:
1846         (WebKit::DrawingAreaProxyImpl::forceResize): Deleted.
1847         * UIProcess/PageClient.h:
1848         * UIProcess/WebPageProxy.cpp:
1849         (WebKit::WebPageProxy::willEnterAcceleratedCompositingMode):
1850         * UIProcess/WebPageProxy.h:
1851         * UIProcess/ios/PageClientImplIOS.h:
1852         * UIProcess/ios/PageClientImplIOS.mm:
1853         (WebKit::PageClientImpl::willEnterAcceleratedCompositingMode):
1854         * UIProcess/mac/PageClientImpl.h:
1855         * UIProcess/mac/PageClientImpl.mm:
1856         (WebKit::PageClientImpl::willEnterAcceleratedCompositingMode):
1857         * WebProcess/WebPage/DrawingAreaImpl.cpp:
1858         (WebKit::DrawingAreaImpl::enterAcceleratedCompositingMode):
1859
1860 2015-10-20  Sergio Villar Senin  <svillar@igalia.com>
1861
1862         [GTK] Fix build for ENABLE_PLUGIN_PROCESS_GTK2=OFF
1863         https://bugs.webkit.org/show_bug.cgi?id=150086
1864
1865         Reviewed by Darin Adler.
1866
1867         * UIProcess/cairo/BackingStoreCairo.cpp:
1868         (WebKit::BackingStore::createBackend):
1869
1870 2015-10-20  Yoav Weiss  <yoav@yoav.ws>
1871
1872         Rename the PICTURE_SIZES flag to CURRENTSRC
1873         https://bugs.webkit.org/show_bug.cgi?id=150275
1874
1875         Reviewed by Dean Jackson.
1876
1877         * Configurations/FeatureDefines.xcconfig:
1878
1879 2015-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1880
1881         ERROR: Unhandled web process message 'StorageAreaMap:DispatchStorageEvent'
1882         https://bugs.webkit.org/show_bug.cgi?id=150315
1883
1884         Reviewed by Andreas Kling.
1885
1886         It was introduced in r184930, that keeps the session storage area
1887         maps alive in the UI process when they are destroyed by the web
1888         process. The problem is that we also keep the listeners, so that
1889         events are also dispatched to the listeners of destroyed areas,
1890         and the message handlers were removed in the web process.
1891
1892         * UIProcess/Storage/StorageManager.cpp:
1893         (WebKit::StorageManager::createTransientLocalStorageMap): Add a
1894         listener for the new storage map ID when the map is reused.
1895         (WebKit::StorageManager::destroyStorageMap): Always remove
1896         listeners of destroyed maps.
1897
1898 2015-10-19  Tim Horton  <timothy_horton@apple.com>
1899
1900         Remove unused support for long presses from WebKit
1901         https://bugs.webkit.org/show_bug.cgi?id=150345
1902
1903         Reviewed by Beth Dakin.
1904
1905         * Shared/WebPreferencesDefinitions.h:
1906         * UIProcess/API/APIUIClient.h:
1907         (API::UIClient::didBeginTrackingPotentialLongMousePress): Deleted.
1908         (API::UIClient::didRecognizeLongMousePress): Deleted.
1909         (API::UIClient::didCancelTrackingPotentialLongMousePress): Deleted.
1910         * UIProcess/API/C/WKPage.cpp:
1911         (WKPageSetPageUIClient): Deleted.
1912         * UIProcess/API/C/WKPageUIClient.h:
1913         * UIProcess/API/C/WKPreferences.cpp:
1914         (WKPreferencesGetLongMousePressEnabled):
1915         (WKPreferencesSetLongMousePressEnabled): Deleted.
1916         * UIProcess/API/C/WKPreferencesRefPrivate.h:
1917         * UIProcess/WebPageProxy.cpp:
1918         (WebKit::WebPageProxy::didBeginTrackingPotentialLongMousePress): Deleted.
1919         (WebKit::WebPageProxy::didRecognizeLongMousePress): Deleted.
1920         (WebKit::WebPageProxy::didCancelTrackingPotentialLongMousePress): Deleted.
1921         * UIProcess/WebPageProxy.h:
1922         * UIProcess/WebPageProxy.messages.in:
1923         * WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h:
1924         (API::InjectedBundle::PageUIClient::didBeginTrackingPotentialLongMousePress): Deleted.
1925         (API::InjectedBundle::PageUIClient::didRecognizeLongMousePress): Deleted.
1926         (API::InjectedBundle::PageUIClient::didCancelTrackingPotentialLongMousePress): Deleted.
1927         * WebProcess/InjectedBundle/API/c/WKBundlePageUIClient.h:
1928         * WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp:
1929         (WebKit::InjectedBundlePageUIClient::didBeginTrackingPotentialLongMousePress): Deleted.
1930         (WebKit::InjectedBundlePageUIClient::didRecognizeLongMousePress): Deleted.
1931         (WebKit::InjectedBundlePageUIClient::didCancelTrackingPotentialLongMousePress): Deleted.
1932         * WebProcess/InjectedBundle/InjectedBundlePageUIClient.h:
1933         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1934         (WebKit::WebChromeClient::didBeginTrackingPotentialLongMousePress): Deleted.
1935         (WebKit::WebChromeClient::didRecognizeLongMousePress): Deleted.
1936         (WebKit::WebChromeClient::didCancelTrackingPotentialLongMousePress): Deleted.
1937         * WebProcess/WebCoreSupport/WebChromeClient.h:
1938         * WebProcess/WebPage/WebPage.cpp:
1939         (WebKit::WebPage::updatePreferences): Deleted.
1940
1941 2015-10-19  Chris Dumez  <cdumez@apple.com>
1942
1943         Make sure development Safari does not delete the stable Safari cache storage.
1944         https://bugs.webkit.org/show_bug.cgi?id=150343
1945
1946         Reviewed by Antti Koivisto.
1947
1948         Make sure development Safari does not delete the stable Safari disk cache
1949         storage. Development Safari now uses Version 5, while the last stable
1950         Safari uses Version 4. Since the 2 versions can co-exist, it is best not
1951         to drop the old cache version (4) at this point.
1952
1953         * NetworkProcess/cache/NetworkCacheStorage.cpp:
1954         (WebKit::NetworkCache::Storage::deleteOldVersions):
1955
1956 2015-10-19  Tim Horton  <timothy_horton@apple.com>
1957
1958         WKView being inside WKWebView leads to weird API issues
1959         https://bugs.webkit.org/show_bug.cgi?id=150174
1960
1961         Reviewed by Darin Adler.
1962
1963         * UIProcess/API/mac/WKView.mm:
1964         * UIProcess/API/mac/WKViewInternal.h:
1965         * UIProcess/Cocoa/WebViewImpl.h: Added.
1966         * UIProcess/Cocoa/WebViewImpl.mm: Added.
1967         (WebKit::WebViewImpl::WebViewImpl):
1968         (WebKit::WebViewImpl::~WebViewImpl):
1969         (WebKit::WebViewImpl::setDrawsBackground):
1970         (WebKit::WebViewImpl::drawsBackground):
1971         (WebKit::WebViewImpl::setDrawsTransparentBackground):
1972         (WebKit::WebViewImpl::drawsTransparentBackground):
1973         (WebKit::WebViewImpl::acceptsFirstResponder):
1974         (WebKit::WebViewImpl::becomeFirstResponder):
1975         (WebKit::WebViewImpl::resignFirstResponder):
1976         (WebKit::WebViewImpl::isFocused):
1977         (WebKit::WebViewImpl::viewWillStartLiveResize):
1978         (WebKit::WebViewImpl::viewDidEndLiveResize):
1979         (WebKit::WebViewImpl::setFrameSize):
1980         (WebKit::WebViewImpl::disableFrameSizeUpdates):
1981         (WebKit::WebViewImpl::enableFrameSizeUpdates):
1982         (WebKit::WebViewImpl::frameSizeUpdatesDisabled):
1983         (WebKit::WebViewImpl::setFrameAndScrollBy):
1984         (WebKit::WebViewImpl::setFixedLayoutSize):
1985         (WebKit::WebViewImpl::fixedLayoutSize):
1986         (WebKit::WebViewImpl::setDrawingAreaSize):
1987         (WebKit::WebViewImpl::setContentPreparationRect):
1988         (WebKit::WebViewImpl::updateViewExposedRect):
1989         (WebKit::WebViewImpl::setClipsToVisibleRect):
1990         (WebKit::WebViewImpl::setIntrinsicContentSize):
1991         (WebKit::WebViewImpl::intrinsicContentSize):
1992         (WebKit::WebViewImpl::setViewScale):
1993         (WebKit::WebViewImpl::viewScale):
1994         (WebKit::WebViewImpl::layoutMode):
1995         (WebKit::WebViewImpl::setLayoutMode):
1996         (WebKit::WebViewImpl::supportsArbitraryLayoutModes):
1997         (WebKit::WebViewImpl::updateSupportsArbitraryLayoutModes):
1998         (WebKit::WebViewImpl::updateSecureInputState):
1999         (WebKit::WebViewImpl::resetSecureInputState):
2000         (WebKit::WebViewImpl::notifyInputContextAboutDiscardedComposition):
2001         (WebKit::WebViewImpl::hasFullScreenWindowController):
2002         (WebKit::WebViewImpl::fullScreenWindowController):
2003         (WebKit::WebViewImpl::closeFullScreenWindowController):
2004         (WebKit::WebViewImpl::fullScreenPlaceholderView):
2005         (WebKit::WebViewImpl::createFullScreenWindow):
2006         Move the actual implementation of a number of WKView methods into a
2007         C++ class, WebViewImpl, which WKView calls directly into.
2008         Eventually, we will move all of the logic of WKView into WebViewImpl,
2009         and then duplicate the necessary forwarding in WKWebView and remove
2010         WKWebView's inner WKView.
2011
2012         * UIProcess/mac/PageClientImpl.h:
2013         * UIProcess/mac/PageClientImpl.mm:
2014         (WebKit::PageClientImpl::isViewFocused):
2015         (WebKit::PageClientImpl::didCommitLoadForMainFrame):
2016         (WebKit::PageClientImpl::updateSecureInputState):
2017         (WebKit::PageClientImpl::resetSecureInputState):
2018         (WebKit::PageClientImpl::notifyInputContextAboutDiscardedComposition):
2019         (WebKit::PageClientImpl::beganEnterFullScreen):
2020         (WebKit::PageClientImpl::beganExitFullScreen):
2021         For now, forward PageClient requests that can be answered by WebViewImpl
2022         to WebViewImpl. Eventually, we'll probably fold PageClientImpl and WebViewImpl
2023         together into one class, and these things will collapse down.
2024
2025         * UIProcess/mac/WKFullScreenWindowController.h:
2026         * UIProcess/mac/WKFullScreenWindowController.mm:
2027         (-[WKFullScreenWindowController initWithWindow:webView:page:]):
2028         (-[WKFullScreenWindowController enterFullScreen:]):
2029         (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
2030         (-[WKFullScreenWindowController exitFullScreen]):
2031         (-[WKFullScreenWindowController finishedExitFullScreenAnimation:]):
2032         (-[WKFullScreenWindowController completeFinishExitFullScreenAnimationAfterRepaint]):
2033         (-[WKFullScreenWindowController _manager]):
2034         (-[WKFullScreenWindowController _startEnterFullScreenAnimationWithDuration:]):
2035         (-[WKFullScreenWindowController _startExitFullScreenAnimationWithDuration:]):
2036         (-[WKFullScreenWindowController initWithWindow:webView:]): Deleted.
2037         (-[WKFullScreenWindowController _page]): Deleted.
2038         * UIProcess/mac/WKViewLayoutStrategy.h:
2039         * UIProcess/mac/WKViewLayoutStrategy.mm:
2040         (+[WKViewLayoutStrategy layoutStrategyWithPage:view:viewImpl:mode:]):
2041         (-[WKViewLayoutStrategy initWithPage:view:viewImpl:mode:]):
2042         (-[WKViewLayoutStrategy invalidate]):
2043         (-[WKViewLayoutStrategy didChangeFrameSize]):
2044         (-[WKViewViewSizeLayoutStrategy initWithPage:view:viewImpl:mode:]):
2045         (-[WKViewFixedSizeLayoutStrategy initWithPage:view:viewImpl:mode:]):
2046         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy initWithPage:view:viewImpl:mode:]):
2047         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy updateLayout]):
2048         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy didChangeFrameSize]):
2049         (-[WKViewDynamicSizeComputedFromMinimumDocumentSizeLayoutStrategy initWithPage:view:viewImpl:mode:]):
2050         (+[WKViewLayoutStrategy layoutStrategyWithPage:view:mode:]): Deleted.
2051         (-[WKViewLayoutStrategy initWithPage:view:mode:]): Deleted.
2052         (-[WKViewLayoutStrategy willDestroyView:]): Deleted.
2053         (-[WKViewViewSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
2054         (-[WKViewFixedSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
2055         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy initWithPage:view:mode:]): Deleted.
2056         (-[WKViewDynamicSizeComputedFromMinimumDocumentSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
2057         Make WKViewLayoutStrategy and WKFullScreenWindowController operate in terms of generic
2058         NSViews instead of WKView, so that eventually they will be able to work for either
2059         WKView or WKWebView, and so that they can sit underneath WebViewImpl.
2060
2061         * WebKit2.xcodeproj/project.pbxproj:
2062
2063 2015-10-19  Commit Queue  <commit-queue@webkit.org>
2064
2065         Unreviewed, rolling out r191307.
2066         https://bugs.webkit.org/show_bug.cgi?id=150338
2067
2068         broke lots of API tests, need time to figure out whats up
2069         (Requested by thorton on #webkit).
2070
2071         Reverted changeset:
2072
2073         "WKView being inside WKWebView leads to weird API issues"
2074         https://bugs.webkit.org/show_bug.cgi?id=150174
2075         http://trac.webkit.org/changeset/191307
2076
2077 2015-10-19  Tim Horton  <timothy_horton@apple.com>
2078
2079         Try again to fix the 32-bit build.
2080
2081         * UIProcess/mac/WebContextMenuProxyMac.mm:
2082         (WebKit::WebContextMenuProxyMac::setupServicesMenu):
2083
2084 2015-10-17  Wenson Hsieh  <wenson_hsieh@apple.com>
2085
2086         Extend fast-clicking behavior to trigger on elements that have negligible zoom
2087         https://bugs.webkit.org/show_bug.cgi?id=150248
2088         <rdar://problem/23140069>
2089
2090         Reviewed by Simon Fraser.
2091
2092         Currently, fast-clicking only triggers on pages that have unscalable viewports. To allow more websites to benefit from fast-clicking
2093         behavior, we generalize fast-clicking to also occur when tapping on elements for which double-tap-to-zoom would zoom the element in
2094         or out by an insignificant amount. We define an insignificant amount of zoom to mean that zooming would increase the viewport scale
2095         by less than a configurable threshold, or decrease the viewport scale by more than a configurable threshold. We accomplish this by
2096         temporarily disabling the double tap gesture recognizer for the duration of the tap. This patch refactors some logic used to compute
2097         zoomed viewports to make it possible to predict the change in viewport scale when double tapping to zoom. See the changes in
2098         SmartMagnificationController and ViewGestureGeometryCollector for more details.
2099
2100         There are no new tests, since this patch does not change existing behavior. Instead, this patch adds the machinery needed for zoom-
2101         dependent fast-clicking: by setting the preferences WebKitFastClickingEnabled and WebKitFastClickZoomThreshold, we will be able to tweak
2102         the behavior dynamically.
2103
2104         * UIProcess/API/Cocoa/WKWebView.mm:
2105         (-[WKWebView _didCommitLayerTree:]):
2106         (-[WKWebView _contentZoomScale]):
2107         (-[WKWebView _targetContentZoomScaleForRect:currentScale:fitEntireRect:minimumScale:maximumScale:]):
2108         (-[WKWebView _zoomToRect:withOrigin:fitEntireRect:minimumScale:maximumScale:minimumScrollDistance:]):
2109         (-[WKWebView _viewportIsUserScalable]):
2110         * UIProcess/API/Cocoa/WKWebViewInternal.h:
2111         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2112         * UIProcess/PageClient.h:
2113         * UIProcess/WebPageProxy.h:
2114         * UIProcess/WebPageProxy.messages.in:
2115         * UIProcess/ios/PageClientImplIOS.h:
2116         * UIProcess/ios/PageClientImplIOS.mm:
2117         (WebKit::PageClientImpl::disableDoubleTapGesturesUntilTapIsFinishedIfNecessary):
2118         * UIProcess/ios/SmartMagnificationController.h:
2119         * UIProcess/ios/SmartMagnificationController.mm:
2120         (WebKit::SmartMagnificationController::adjustSmartMagnificationTargetRectAndZoomScales):
2121         (WebKit::SmartMagnificationController::didCollectGeometryForSmartMagnificationGesture):
2122         (WebKit::SmartMagnificationController::magnify):
2123         * UIProcess/ios/WKContentViewInteraction.h:
2124         * UIProcess/ios/WKContentViewInteraction.mm:
2125         (-[WKContentView _didGetTapHighlightForRequest:color:quads:topLeftRadius:topRightRadius:bottomLeftRadius:bottomRightRadius:]):
2126         (-[WKContentView _fastClickZoomThreshold]):
2127         (-[WKContentView _allowDoubleTapToZoomForCurrentZoomScale:andTargetZoomScale:]):
2128         (-[WKContentView _disableDoubleTapGesturesUntilTapIsFinishedIfNecessary:allowsDoubleTapZoom:targetRect:isReplaced:minimumScale:maximumScale:]):
2129         (-[WKContentView _highlightLongPressRecognized:]):
2130         (-[WKContentView _endPotentialTapAndEnableDoubleTapGesturesIfNecessary]):
2131         (-[WKContentView _singleTapRecognized:]):
2132         (cancelPotentialTapIfNecessary):
2133         (-[WKContentView _singleTapCommited:]):
2134         (-[WKContentView webSelectionRects]): Deleted.
2135         * UIProcess/ios/WebPageProxyIOS.mm:
2136         (WebKit::WebPageProxy::disableDoubleTapGesturesUntilTapIsFinishedIfNecessary):
2137         * WebProcess/WebPage/ViewGestureGeometryCollector.cpp:
2138         (WebKit::ViewGestureGeometryCollector::collectGeometryForSmartMagnificationGesture):
2139         (WebKit::ViewGestureGeometryCollector::computeZoomInformationForNode):
2140         * WebProcess/WebPage/ViewGestureGeometryCollector.h:
2141         * WebProcess/WebPage/ios/WebPageIOS.mm:
2142         (WebKit::WebPage::potentialTapAtPosition):
2143
2144 2015-10-19  Tim Horton  <timothy_horton@apple.com>
2145
2146         WKView being inside WKWebView leads to weird API issues
2147         https://bugs.webkit.org/show_bug.cgi?id=150174
2148
2149         Reviewed by Darin Adler.
2150
2151         * UIProcess/API/mac/WKView.mm:
2152         * UIProcess/API/mac/WKViewInternal.h:
2153         * UIProcess/Cocoa/WebViewImpl.h: Added.
2154         * UIProcess/Cocoa/WebViewImpl.mm: Added.
2155         (WebKit::WebViewImpl::WebViewImpl):
2156         (WebKit::WebViewImpl::~WebViewImpl):
2157         (WebKit::WebViewImpl::setDrawsBackground):
2158         (WebKit::WebViewImpl::drawsBackground):
2159         (WebKit::WebViewImpl::setDrawsTransparentBackground):
2160         (WebKit::WebViewImpl::drawsTransparentBackground):
2161         (WebKit::WebViewImpl::acceptsFirstResponder):
2162         (WebKit::WebViewImpl::becomeFirstResponder):
2163         (WebKit::WebViewImpl::resignFirstResponder):
2164         (WebKit::WebViewImpl::isFocused):
2165         (WebKit::WebViewImpl::viewWillStartLiveResize):
2166         (WebKit::WebViewImpl::viewDidEndLiveResize):
2167         (WebKit::WebViewImpl::setFrameSize):
2168         (WebKit::WebViewImpl::disableFrameSizeUpdates):
2169         (WebKit::WebViewImpl::enableFrameSizeUpdates):
2170         (WebKit::WebViewImpl::frameSizeUpdatesDisabled):
2171         (WebKit::WebViewImpl::setFrameAndScrollBy):
2172         (WebKit::WebViewImpl::setFixedLayoutSize):
2173         (WebKit::WebViewImpl::fixedLayoutSize):
2174         (WebKit::WebViewImpl::setDrawingAreaSize):
2175         (WebKit::WebViewImpl::setContentPreparationRect):
2176         (WebKit::WebViewImpl::updateViewExposedRect):
2177         (WebKit::WebViewImpl::setClipsToVisibleRect):
2178         (WebKit::WebViewImpl::setIntrinsicContentSize):
2179         (WebKit::WebViewImpl::intrinsicContentSize):
2180         (WebKit::WebViewImpl::setViewScale):
2181         (WebKit::WebViewImpl::viewScale):
2182         (WebKit::WebViewImpl::layoutMode):
2183         (WebKit::WebViewImpl::setLayoutMode):
2184         (WebKit::WebViewImpl::supportsArbitraryLayoutModes):
2185         (WebKit::WebViewImpl::updateSupportsArbitraryLayoutModes):
2186         (WebKit::WebViewImpl::updateSecureInputState):
2187         (WebKit::WebViewImpl::resetSecureInputState):
2188         (WebKit::WebViewImpl::notifyInputContextAboutDiscardedComposition):
2189         (WebKit::WebViewImpl::hasFullScreenWindowController):
2190         (WebKit::WebViewImpl::fullScreenWindowController):
2191         (WebKit::WebViewImpl::closeFullScreenWindowController):
2192         (WebKit::WebViewImpl::fullScreenPlaceholderView):
2193         (WebKit::WebViewImpl::createFullScreenWindow):
2194         Move the actual implementation of a number of WKView methods into a
2195         C++ class, WebViewImpl, which WKView calls directly into.
2196         Eventually, we will move all of the logic of WKView into WebViewImpl,
2197         and then duplicate the necessary forwarding in WKWebView and remove
2198         WKWebView's inner WKView.
2199
2200         * UIProcess/mac/PageClientImpl.h:
2201         * UIProcess/mac/PageClientImpl.mm:
2202         (WebKit::PageClientImpl::isViewFocused):
2203         (WebKit::PageClientImpl::didCommitLoadForMainFrame):
2204         (WebKit::PageClientImpl::updateSecureInputState):
2205         (WebKit::PageClientImpl::resetSecureInputState):
2206         (WebKit::PageClientImpl::notifyInputContextAboutDiscardedComposition):
2207         (WebKit::PageClientImpl::beganEnterFullScreen):
2208         (WebKit::PageClientImpl::beganExitFullScreen):
2209         For now, forward PageClient requests that can be answered by WebViewImpl
2210         to WebViewImpl. Eventually, we'll probably fold PageClientImpl and WebViewImpl
2211         together into one class, and these things will collapse down.
2212
2213         * UIProcess/mac/WKFullScreenWindowController.h:
2214         * UIProcess/mac/WKFullScreenWindowController.mm:
2215         (-[WKFullScreenWindowController initWithWindow:webView:page:]):
2216         (-[WKFullScreenWindowController enterFullScreen:]):
2217         (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
2218         (-[WKFullScreenWindowController exitFullScreen]):
2219         (-[WKFullScreenWindowController finishedExitFullScreenAnimation:]):
2220         (-[WKFullScreenWindowController completeFinishExitFullScreenAnimationAfterRepaint]):
2221         (-[WKFullScreenWindowController _manager]):
2222         (-[WKFullScreenWindowController _startEnterFullScreenAnimationWithDuration:]):
2223         (-[WKFullScreenWindowController _startExitFullScreenAnimationWithDuration:]):
2224         (-[WKFullScreenWindowController initWithWindow:webView:]): Deleted.
2225         (-[WKFullScreenWindowController _page]): Deleted.
2226         * UIProcess/mac/WKViewLayoutStrategy.h:
2227         * UIProcess/mac/WKViewLayoutStrategy.mm:
2228         (+[WKViewLayoutStrategy layoutStrategyWithPage:view:viewImpl:mode:]):
2229         (-[WKViewLayoutStrategy initWithPage:view:viewImpl:mode:]):
2230         (-[WKViewLayoutStrategy invalidate]):
2231         (-[WKViewLayoutStrategy didChangeFrameSize]):
2232         (-[WKViewViewSizeLayoutStrategy initWithPage:view:viewImpl:mode:]):
2233         (-[WKViewFixedSizeLayoutStrategy initWithPage:view:viewImpl:mode:]):
2234         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy initWithPage:view:viewImpl:mode:]):
2235         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy updateLayout]):
2236         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy didChangeFrameSize]):
2237         (-[WKViewDynamicSizeComputedFromMinimumDocumentSizeLayoutStrategy initWithPage:view:viewImpl:mode:]):
2238         (+[WKViewLayoutStrategy layoutStrategyWithPage:view:mode:]): Deleted.
2239         (-[WKViewLayoutStrategy initWithPage:view:mode:]): Deleted.
2240         (-[WKViewLayoutStrategy willDestroyView:]): Deleted.
2241         (-[WKViewViewSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
2242         (-[WKViewFixedSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
2243         (-[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy initWithPage:view:mode:]): Deleted.
2244         (-[WKViewDynamicSizeComputedFromMinimumDocumentSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
2245         Make WKViewLayoutStrategy and WKFullScreenWindowController operate in terms of generic
2246         NSViews instead of WKView, so that eventually they will be able to work for either
2247         WKView or WKWebView, and so that they can sit underneath WebViewImpl.
2248
2249         * WebKit2.xcodeproj/project.pbxproj:
2250
2251 2015-10-19  Chris Dumez  <cdumez@apple.com>
2252
2253         [WK2] Generalize NetworkCacheStorage API so it can store different types of metadata
2254         https://bugs.webkit.org/show_bug.cgi?id=150221
2255         <rdar://problem/23149771>
2256
2257         Reviewed by Darin Adler and Antti Koivisto.
2258
2259         Generalize NetworkCacheStorage API so it can store different types of
2260         metadata alongside the network resources. This is a pre-requirement to
2261         making our NetworkCache smarter by storing information about the
2262         resources.
2263
2264         To keep the code simple, the entry type is now part of the entry key and
2265         we store records of a specific type in a 'type' subfolder. The cache
2266         structure looks like so:
2267         - WebKitCache/Version 5/[Partition]/[Type]/[Hash]
2268         - WebKitCache/Version 5/[Partition]/[Type]/[Hash]-blob (Optional)
2269
2270         Existing cache entries now that the 'resource' type as these are network
2271         resources.
2272
2273         * NetworkProcess/cache/NetworkCache.cpp:
2274         * NetworkProcess/cache/NetworkCacheKey.cpp:
2275         * NetworkProcess/cache/NetworkCacheKey.h:
2276         * NetworkProcess/cache/NetworkCacheStatistics.cpp:
2277         * NetworkProcess/cache/NetworkCacheStorage.cpp:
2278         * NetworkProcess/cache/NetworkCacheStorage.h:
2279
2280 2015-10-19  Tim Horton  <timothy_horton@apple.com>
2281
2282         Try to fix the iOS build
2283
2284         * Configurations/FeatureDefines.xcconfig:
2285
2286 2015-10-19  Tim Horton  <timothy_horton@apple.com>
2287
2288         Try to fix the 32-bit build.
2289
2290         * UIProcess/mac/WebContextMenuProxyMac.mm:
2291         (WebKit::WebContextMenuProxyMac::setupServicesMenu):
2292
2293 2015-10-16  Anders Carlsson  <andersca@apple.com>
2294
2295         Fix image service menus somewhat
2296         https://bugs.webkit.org/show_bug.cgi?id=150265
2297
2298         Reviewed by Tim Horton.
2299
2300         * Shared/ContextMenuContextData.cpp:
2301         (WebKit::ContextMenuContextData::ContextMenuContextData):
2302         It's a service menu if we have a controlled image.
2303
2304         * UIProcess/mac/WebContextMenuProxyMac.mm:
2305         (WebKit::WebContextMenuProxyMac::setupServicesMenu):
2306         Use an item provider.
2307
2308 2015-10-19  Tim Horton  <timothy_horton@apple.com>
2309
2310         Add magnify and rotate gesture event support for Mac
2311         https://bugs.webkit.org/show_bug.cgi?id=150179
2312         <rdar://problem/8036240>
2313
2314         Reviewed by Darin Adler.
2315
2316         * Configurations/FeatureDefines.xcconfig:
2317         New feature flag.
2318
2319         * Shared/NativeWebGestureEvent.h: Added.
2320         (WebKit::NativeWebGestureEvent::nativeEvent):
2321         * Shared/WebEvent.h:
2322         * Shared/WebEventConversion.cpp:
2323         (WebKit::WebKit2PlatformGestureEvent::WebKit2PlatformGestureEvent):
2324         (WebKit::platform):
2325         * Shared/WebEventConversion.h:
2326         * Shared/mac/NativeWebGestureEventMac.mm: Added.
2327         (WebKit::webEventTypeForNSEvent):
2328         (WebKit::pointForEvent):
2329         (WebKit::NativeWebGestureEvent::NativeWebGestureEvent):
2330         Add and plumb a new native event that wraps a NSEvent of type
2331         NSEventTypeMagnify or NSEventTypeRotate (gesture events).
2332
2333         * Shared/mac/WebGestureEvent.cpp: Added.
2334         (WebKit::WebGestureEvent::encode):
2335         (WebKit::WebGestureEvent::decode):
2336         (WebKit::WebGestureEvent::isGestureEventType):
2337         * Shared/mac/WebGestureEvent.h: Added.
2338         (WebKit::WebGestureEvent::WebGestureEvent):
2339         (WebKit::WebGestureEvent::position):
2340         (WebKit::WebGestureEvent::gestureScale):
2341         (WebKit::WebGestureEvent::gestureRotation):
2342         Add IPC plumbing for WebGestureEvent, which becomes a WebCore::PlatformGestureEvent.
2343
2344         * UIProcess/API/Cocoa/WKViewPrivate.h:
2345         Remove unnecessary iPhone-only WKView code.
2346         Add _gestureEventWasNotHandledByWebCore, SPI which can be overridden
2347         to react when WebCore decides not to handle a gesture event.
2348
2349         * UIProcess/API/mac/WKView.mm:
2350         (-[WKView magnifyWithEvent:]):
2351         Route magnification gesture events to the page, unless we're already
2352         in an active view zoom gesture, in which case we'll bypass the page
2353         and send the event straight to ViewGestureController.
2354
2355         (-[WKView rotateWithEvent:]):
2356         Route rotation gesture events to the page.
2357
2358         (-[WKView _gestureEventWasNotHandledByWebCore:]):
2359         Let ViewGestureController know that WebCore didn't handle a gesture event.
2360         We always give WebCore the first crack at the event if we're not in a zoom,
2361         because it could preventDefault() on the Begin phase event, and that should
2362         prevent pinch-zoom from starting.
2363
2364         * UIProcess/PageClient.h:
2365         * UIProcess/mac/PageClientImpl.h:
2366         * UIProcess/mac/PageClientImpl.mm:
2367         (WebKit::PageClientImpl::gestureEventWasNotHandledByWebCore):
2368         Plumb gestureEventWasNotHandledByWebCore back from WebPageProxy to WKView.
2369
2370         * UIProcess/WebPageProxy.cpp:
2371         (WebKit::WebPageProxy::handleGestureEvent):
2372         (WebKit::WebPageProxy::didReceiveEvent):
2373         * UIProcess/WebPageProxy.h:
2374         Forward gesture events to EventDispatcher, and let WKView know when WebCore
2375         passes on handling them.
2376         
2377         * UIProcess/mac/ViewGestureController.h:
2378         (WebKit::ViewGestureController::hasActiveMagnificationGesture):
2379         * UIProcess/mac/ViewGestureControllerMac.mm:
2380         (WebKit::ViewGestureController::gestureEventWasNotHandledByWebCore):
2381         (WebKit::ViewGestureController::handleMagnificationGestureEvent):
2382         Don't try to start a zoom with anything other than a Begin phase event.
2383         Try to start a zoom with any events that WebCore doesn't handle.
2384         Move dispatch of endMagnificationGesture into ViewGestureController;
2385         there is no reason for that to be in WKView anymore.
2386
2387         * WebKit2.xcodeproj/project.pbxproj:
2388         * WebProcess/WebPage/EventDispatcher.cpp:
2389         (WebKit::EventDispatcher::gestureEvent):
2390         (WebKit::EventDispatcher::dispatchGestureEvent):
2391         * WebProcess/WebPage/EventDispatcher.h:
2392         * WebProcess/WebPage/EventDispatcher.messages.in:
2393         * WebProcess/WebPage/WebPage.cpp:
2394         (WebKit::handleGestureEvent):
2395         (WebKit::WebPage::gestureEvent):
2396         * WebProcess/WebPage/WebPage.h:
2397         Dispatch to the main thread and hand off the gesture event to WebCore,
2398         asynchronously informing the UI process of whether the event was handled or not.
2399
2400 2015-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
2401
2402         [GTK] ASSERTION FAILED: parent in WebInspectorProxy::platformDetach()
2403         https://bugs.webkit.org/show_bug.cgi?id=150319
2404
2405         Reviewed by Žan Doberšek.
2406
2407         This happens when the inspector is shown/closed very
2408         quickly. Since we start the inspector attached by default, when
2409         the web inspector is created m_isAttached is set to true, so that
2410         when opened, it's attached to the view. If the inspector is closed
2411         before it has been actually attached, the inspector view doesn't
2412         have a parent, even if the m_isAttached is true. So, we should
2413         handle this case instead of asserting. This is what happens in
2414         test http/tests/xmlhttprequest/access-control-repeated-failed-preflight-crash.html.
2415
2416         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
2417         (WebKit::WebInspectorProxy::platformDetach): Remove the view from
2418         its parent container if it was actually attached.
2419
2420 2015-10-19  Hunseop Jeong  <hs85.jeong@samsung.com>
2421
2422         [EFL] Implement WebContextMenuProxyEfl::showContextMenu after r191194
2423         https://bugs.webkit.org/show_bug.cgi?id=150310
2424
2425         Reviewed by Gyuyoung Kim.
2426
2427         showContextMenu() doesn't work correctly after r191194 in EFL port.
2428         This patch implements WebContextMenuProxyEfl::showContextMenu.
2429
2430         * UIProcess/efl/WebContextMenuProxyEfl.cpp:
2431         (WebKit::WebContextMenuProxyEfl::WebContextMenuProxyEfl):
2432         (WebKit::WebContextMenuProxyEfl::showContextMenu):
2433         (WebKit::WebContextMenuProxyEfl::hideContextMenu):
2434         * UIProcess/efl/WebContextMenuProxyEfl.h:
2435
2436 2015-10-18  Csaba Osztrogonác  <ossy@webkit.org>
2437
2438         [WK2] Simplify unused return warning in WKRetainPtr.h
2439         https://bugs.webkit.org/show_bug.cgi?id=150173
2440
2441         Reviewed by Darin Adler.
2442
2443         * UIProcess/API/cpp/WKRetainPtr.h:
2444         (WebKit::__attribute__):
2445         (WebKit::adoptWK): Deleted.
2446
2447 2015-10-18  Csaba Osztrogonác  <ossy@webkit.org>
2448
2449         Fix the ENABLE(SECCOMP_FILTERS) build after r187030
2450         https://bugs.webkit.org/show_bug.cgi?id=150172
2451
2452         Reviewed by Alexey Proskuryakov.
2453
2454         * Shared/linux/SeccompFilters/Syscall.cpp:
2455         (WebKit::reportUnexpectedSyscall):
2456
2457 2015-10-18  Joonghun Park  <jh718.park@samsung.com>
2458
2459         [GTK] Remove WebKitContextMenu related missing annotation warnings
2460         https://bugs.webkit.org/show_bug.cgi?id=150299
2461
2462         Reviewed by Darin Adler.
2463
2464         The warnings occur currently because when executing g-ir-scanner,
2465         it doesn't consider WebKitContextMenu related .cpp files,
2466         but only .h files.
2467
2468         * PlatformGTK.cmake: Add WebKitContextMenu related cpp files.
2469
2470 2015-10-18  Myles C. Maxfield  <mmaxfield@apple.com>
2471
2472         Stop honoring the user default "WebKitKerningAndLigaturesEnabledByDefault"
2473         https://bugs.webkit.org/show_bug.cgi?id=150287
2474
2475         Reviewed by Simon Fraser.
2476
2477         * Shared/WebProcessCreationParameters.cpp:
2478         (WebKit::WebProcessCreationParameters::WebProcessCreationParameters): Deleted.
2479         (WebKit::WebProcessCreationParameters::encode): Deleted.
2480         (WebKit::WebProcessCreationParameters::decode): Deleted.
2481         * Shared/WebProcessCreationParameters.h:
2482         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
2483         (WebKit::registerUserDefaultsIfNeeded): Deleted.
2484         (WebKit::WebProcessPool::platformInitializeWebProcess): Deleted.
2485         * WebProcess/cocoa/WebProcessCocoa.mm:
2486         (WebKit::WebProcess::platformInitializeWebProcess): Deleted.
2487
2488 2015-10-18  Yusuke Suzuki  <utatane.tea@gmail.com>
2489
2490         [GTK] Implement WebContextMenuProxyGtk::showContextMenu after r191194
2491         https://bugs.webkit.org/show_bug.cgi?id=150276
2492
2493         Reviewed by Carlos Garcia Campos.
2494
2495         After r191194, showContextMenu signature becomes changed, and the implementation
2496         is moved from the generic file to the Mac port. It poses the compile error in GTK port.
2497         This patch implements WebContextMenuProxyGtk::showContextMenu. The logic is the same
2498         to the old one except for dropping SERVICE_CONTROLS support. This is because
2499         SERVICE_CONTROLS is not related to GTK.
2500
2501         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
2502         (WebKit::WebContextMenuProxyGtk::showContextMenu):
2503         * UIProcess/gtk/WebContextMenuProxyGtk.h:
2504
2505 2015-10-18  Commit Queue  <commit-queue@webkit.org>
2506
2507         Unreviewed, rolling out r191250 and r191253.
2508         https://bugs.webkit.org/show_bug.cgi?id=150296
2509
2510         Broke all the tests on Windows (Requested by ap on #webkit).
2511
2512         Reverted changesets:
2513
2514         "Stop honoring the user default
2515         "WebKitKerningAndLigaturesEnabledByDefault""
2516         https://bugs.webkit.org/show_bug.cgi?id=150287
2517         http://trac.webkit.org/changeset/191250
2518
2519         "Build fix after r191250"
2520         http://trac.webkit.org/changeset/191253
2521
2522 2015-10-17  Myles C. Maxfield  <mmaxfield@apple.com>
2523
2524         Stop honoring the user default "WebKitKerningAndLigaturesEnabledByDefault"
2525         https://bugs.webkit.org/show_bug.cgi?id=150287
2526
2527         Reviewed by Simon Fraser.
2528
2529         * Shared/WebProcessCreationParameters.cpp:
2530         (WebKit::WebProcessCreationParameters::WebProcessCreationParameters): Deleted.
2531         (WebKit::WebProcessCreationParameters::encode): Deleted.
2532         (WebKit::WebProcessCreationParameters::decode): Deleted.
2533         * Shared/WebProcessCreationParameters.h:
2534         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
2535         (WebKit::registerUserDefaultsIfNeeded): Deleted.
2536         (WebKit::WebProcessPool::platformInitializeWebProcess): Deleted.
2537         * WebProcess/cocoa/WebProcessCocoa.mm:
2538         (WebKit::WebProcess::platformInitializeWebProcess): Deleted.
2539
2540 2015-10-17  Dan Bernstein  <mitz@apple.com>
2541
2542         [Cocoa] Stop using WKAXRegisterRemoteApp
2543         https://bugs.webkit.org/show_bug.cgi?id=150283
2544
2545         Reviewed by Alexey Proskuryakov.
2546
2547         * Platform/spi/mac: Added.
2548         * Platform/spi/mac/AppKitSPI.h: Added. Includes declaration of
2549           +[NSAccessibilityRemoteUIElement setRemoteUIApp:].
2550
2551         * WebKit2.xcodeproj/project.pbxproj: Added reference to new header. Also changed the path of
2552           the Platform/spi/Cocoa group to the corresponding path in the source tree.
2553
2554         * WebProcess/cocoa/WebProcessCocoa.mm:
2555         (WebKit::registerWithAccessibility): Added.
2556         (WebKit::WebProcess::platformInitializeProcess): Use new registerWithAccessibility instead
2557           of WKAXRegisterRemoteApp.
2558
2559 2015-10-16  Simon Fraser  <simon.fraser@apple.com>
2560
2561         Enhance TextStream for logging, remove subclasses, log more things
2562         https://bugs.webkit.org/show_bug.cgi?id=150269
2563
2564         Reviewed by Zalan Bujtas.
2565
2566         Remove the various TextStream subclasses that only existed to support indenting,
2567         and output additional types. Add output for more WebCore and WebKit2 types, and
2568         just use TextStream everywhere.
2569         
2570         TextStream is enhance to support grouping (open paren and intent), with a 
2571         stack-based class to open/end a group.
2572         
2573         Remove some SVG-specific duplicate output functions.
2574         
2575         Outdent namespace contents of GraphicsTypes.h.
2576
2577         * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
2578         (WebKit::dump):
2579         (WebKit::recursiveDumpNodes):
2580         (WebKit::RemoteScrollingCoordinatorTransaction::description):
2581         (WebKit::RemoteScrollingTreeTextStream::RemoteScrollingTreeTextStream): Deleted.
2582         (WebKit::RemoteScrollingTreeTextStream::increaseIndent): Deleted.
2583         (WebKit::RemoteScrollingTreeTextStream::decreaseIndent): Deleted.
2584         (WebKit::RemoteScrollingTreeTextStream::writeIndent): Deleted.
2585         (WebKit::dumpProperty): Deleted.
2586         (WebKit::RemoteScrollingTreeTextStream::operator<<): Deleted.
2587         (WebKit::RemoteScrollingTreeTextStream::dump): Deleted.
2588         (WebKit::RemoteScrollingTreeTextStream::recursiveDumpNodes): Deleted.
2589         * Shared/mac/RemoteLayerTreeTransaction.mm:
2590         (WebKit::operator<<):
2591         (WebKit::dumpChangedLayers):
2592         (WebKit::RemoteLayerTreeTransaction::description):
2593         (WebKit::RemoteLayerTreeTextStream::RemoteLayerTreeTextStream): Deleted.
2594         (WebKit::RemoteLayerTreeTextStream::increaseIndent): Deleted.
2595         (WebKit::RemoteLayerTreeTextStream::decreaseIndent): Deleted.
2596         (WebKit::dumpProperty): Deleted.
2597         (WebKit::RemoteLayerTreeTextStream::operator<<): Deleted.
2598         (WebKit::RemoteLayerTreeTextStream::writeIndent): Deleted.
2599         * WebProcess/WebPage/mac/PlatformCAAnimationRemote.h:
2600         * WebProcess/WebPage/mac/PlatformCAAnimationRemote.mm:
2601         (WebKit::operator<<):
2602
2603 2015-10-17  Hunseop Jeong  <hs85.jeong@samsung.com>
2604
2605         URTBF after r191194 to fix EFL build.
2606         https://bugs.webkit.org/show_bug.cgi?id=150272
2607
2608         Reviewed by Csaba Osztrogonác.
2609
2610         * UIProcess/efl/WebContextMenuProxyEfl.cpp:
2611         (WebKit::WebContextMenuProxyEfl::showContextMenu):
2612         * UIProcess/efl/WebContextMenuProxyEfl.h:
2613
2614 2015-10-16  Wenson Hsieh  <wenson_hsieh@apple.com>
2615
2616         Add a WKWebView input delegate SPI
2617         https://bugs.webkit.org/show_bug.cgi?id=149646
2618
2619         Reviewed by Dan Bernstein.
2620
2621         Renames the existing _WKFormDelegate to _WKInputDelegate and adds a new delegate SPI method
2622         -[_WKInputDelegate _webView:focusShouldStartInputSession:] that allows clients to allow or
2623         disallow showing up the keyboard. To make this decision, clients are given a
2624         _WKFocusedElementInfo, which contains information about the focused element prior to the
2625         keyboard showing up so the client will be able to override default assistance behavior.
2626
2627         While the information contained in a _WKFocusedElementInfo currently seems like overkill for
2628         _webView:focusShouldStartInputSession, our intentions are to give WebKit clients control over more
2629         details of how node assistance works, such as being able to use a custom editor for certain
2630         types of nodes.
2631
2632         * Shared/API/Cocoa/WebKitPrivate.h: Added new header _WKFocusedElementInfo.h.
2633         * UIProcess/API/Cocoa/WKWebView.h:
2634         * UIProcess/API/Cocoa/WKWebView.mm:
2635         (-[WKWebView _inputDelegate]):
2636         (-[WKWebView _formDelegate]):
2637         (-[WKWebView _setInputDelegate:]):
2638         (-[WKWebView _setFormDelegate:]):
2639         (-[WKWebView initWithFrame:configuration:]): Deleted canAssistOnProgrammaticFocus flag.
2640         (-[WKWebView canAssistOnProgrammaticFocus]): Ditto.
2641         (-[WKWebView setCanAssistOnProgrammaticFocus:]): Ditto.
2642         * UIProcess/API/Cocoa/WKWebViewConfiguration.h:
2643         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
2644         (-[WKWebViewConfiguration init]): Deleted.
2645         (-[WKWebViewConfiguration _canAssistOnProgrammaticFocus]): Deleted canAssistOnProgrammaticFocus flag.
2646         (-[WKWebViewConfiguration _setCanAssistOnProgrammaticFocus:]): Ditto.
2647         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2648         * UIProcess/API/Cocoa/_WKFocusedElementInfo.h: Added.
2649         * UIProcess/API/Cocoa/_WKFormDelegate.h:
2650         * UIProcess/API/Cocoa/_WKInputDelegate.h: Copied from Source/WebKit2/UIProcess/API/Cocoa/_WKFormDelegate.h.
2651         * UIProcess/ios/WKContentViewInteraction.mm:
2652         (-[WKFocusedElementInfo initWithAssistedNodeInformation:isInteracting:]):
2653         (-[WKFocusedElementInfo type]):
2654         (-[WKFocusedElementInfo value]):
2655         (-[WKFocusedElementInfo isUserInitiated]):
2656         (-[WKContentView accessoryAutoFill]):
2657         (-[WKContentView _startAssistingNode:userIsInteracting:blurPreviousNode:userObject:]): If the input delegate responds to
2658             shouldStartInputSession, consult it to see if we should bring up the keyboard; otherwise, use our default behavior.
2659         * WebKit2.xcodeproj/project.pbxproj:
2660
2661 2015-10-16  Simon Fraser  <simon.fraser@apple.com>
2662
2663         Make TextStream the canonical way to log classes in WebCore
2664         https://bugs.webkit.org/show_bug.cgi?id=150256
2665
2666         Reviewed by Sam Weinig.
2667
2668         We vacillated between PrintStream and TextStream as being the canonical way
2669         to stringify WebCore data structures. This patch solidifies TextStream
2670         as the solution, since it has convenient stream syntax, and is what we
2671         use for render tree dumps.
2672
2673         Remove TextStream member functions that output non-simple structs
2674         (sizes, points and rects), replacing them with free operator<< functions
2675         in the .cpp file for the relevant class. Formatting is currently consistent
2676         with RenderTreeAsText output, to avoid breaking tests.
2677
2678         Remove custom FloatRect outputting in SVG and RemoteLayerTreeTransaction.
2679
2680         * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
2681         (WebKit::RemoteScrollingTreeTextStream::operator<<): Deleted.
2682         * Shared/mac/RemoteLayerTreeTransaction.mm:
2683         (WebKit::RemoteLayerTreeTextStream::operator<<): Deleted.
2684
2685 2015-10-16  Anders Carlsson  <andersca@apple.com>
2686
2687         Remove some dead menu code
2688         https://bugs.webkit.org/show_bug.cgi?id=150247
2689
2690         Reviewed by Andreas Kling.
2691
2692         * Shared/WebContextMenuItemData.cpp:
2693         (WebKit::WebContextMenuItemData::WebContextMenuItemData):
2694         (WebKit::WebContextMenuItemData::encode): Deleted.
2695         * Shared/WebContextMenuItemData.h:
2696         (WebKit::WebContextMenuItemData::selectionHandler): Deleted.
2697         * UIProcess/mac/WebContextMenuProxyMac.mm:
2698         (WebKit::nsMenuItem):
2699
2700 2015-10-16  Anders Carlsson  <andersca@apple.com>
2701
2702         Move more code to WebContextMenuProxyMac
2703         https://bugs.webkit.org/show_bug.cgi?id=150240
2704
2705         Reviewed by Tim Horton.
2706
2707         * UIProcess/WebContextMenuProxy.h:
2708         * UIProcess/WebPageProxy.cpp:
2709         (WebKit::WebPageProxy::internalShowContextMenu):
2710         * UIProcess/WebPageProxy.h:
2711         (WebKit::WebPageProxy::contextMenuClient):
2712         * UIProcess/mac/WebContextMenuProxyMac.h:
2713         * UIProcess/mac/WebContextMenuProxyMac.mm:
2714         (WebKit::WebContextMenuProxyMac::initializeShareMenuItem):
2715         (WebKit::WebContextMenuProxyMac::showContextMenu):
2716         * UIProcess/mac/WebPageProxyMac.mm:
2717         (WebKit::WebPageProxy::platformInitializeShareMenuItem): Deleted.
2718
2719 2015-10-16  Tim Horton  <timothy_horton@apple.com>
2720
2721         Hook up autolayout intrinsic sizing for WKWebView
2722         https://bugs.webkit.org/show_bug.cgi?id=150219
2723         <rdar://problem/20016905>
2724
2725         Reviewed by Simon Fraser.
2726
2727         * UIProcess/API/Cocoa/WKWebView.mm:
2728         (-[WKWebView initWithFrame:configuration:]):
2729         (-[WKWebView intrinsicContentSize]):
2730         (-[WKWebView _setIntrinsicContentSize:]):
2731         (-[WKWebView _minimumLayoutWidth]):
2732         (-[WKWebView _setMinimumLayoutWidth:]):
2733         * UIProcess/API/Cocoa/WKWebViewInternal.h:
2734         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2735         Add a simple SPI to specify the minimum width that a WKWebView will attempt
2736         to lay out to, similar to WKView except just a width, not a size, and
2737         with no option to force the height to the view size. Similar behavior can
2738         be achieved by clients by setting custom autolayout constraints on the view.
2739
2740         * UIProcess/mac/PageClientImpl.mm:
2741         (WebKit::PageClientImpl::intrinsicContentSizeDidChange):
2742         Forward intrinsic content size changes to the WKWebView, not its inner WKView,
2743         if we have one.
2744
2745         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2746         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
2747         Only set the autosizing fixed minimum height if we're using that behavior;
2748         otherwise, setting it to the view's height will end up accidentally
2749         turning on that behavior (which involves an extra layout per resize!).
2750
2751 2015-10-15  Anders Carlsson  <andersca@apple.com>
2752
2753         Use the ShowContextMenu message for service menus as well
2754         https://bugs.webkit.org/show_bug.cgi?id=150206
2755
2756         Reviewed by Tim Horton.
2757
2758         * Shared/ContextMenuContextData.cpp:
2759         (WebKit::ContextMenuContextData::ContextMenuContextData):
2760         (WebKit::ContextMenuContextData::encode):
2761         (WebKit::ContextMenuContextData::decode):
2762         * Shared/ContextMenuContextData.h:
2763         (WebKit::ContextMenuContextData::type):
2764         (WebKit::ContextMenuContextData::ContextMenuContextData):
2765         (WebKit::ContextMenuContextData::isServicesMenu):
2766         (WebKit::ContextMenuContextData::needsServicesMenu): Deleted.
2767         * UIProcess/WebPageProxy.cpp:
2768         (WebKit::WebPageProxy::showContextMenu):
2769         (WebKit::WebPageProxy::internalShowContextMenu):
2770         * UIProcess/WebPageProxy.h:
2771         * UIProcess/WebPageProxy.messages.in:
2772         * UIProcess/mac/WebContextMenuProxyMac.mm:
2773         (WebKit::WebContextMenuProxyMac::populate):
2774         (WebKit::WebContextMenuProxyMac::showContextMenu):
2775         * UIProcess/mac/WebPageProxyMac.mm:
2776         (WebKit::WebPageProxy::showSelectionServiceMenu): Deleted.
2777         * WebProcess/WebPage/mac/WebPageMac.mm:
2778         (WebKit::WebPage::handleSelectionServiceClick):
2779
2780 2015-10-16  Hunseop Jeong  <hs85.jeong@samsung.com>
2781
2782         [GTK] Try to fix the build after r191137
2783         https://bugs.webkit.org/show_bug.cgi?id=150222
2784
2785         Reviewed by Carlos Garcia Campos.
2786
2787         * UIProcess/API/gtk/PageClientImpl.cpp:
2788         (WebKit::PageClientImpl::doneWithKeyEvent):
2789         (WebKit::PageClientImpl::createPopupMenuProxy):
2790         (WebKit::PageClientImpl::createContextMenuProxy):
2791         (WebKit::PageClientImpl::createColorPicker):
2792         * UIProcess/API/gtk/PageClientImpl.h:
2793         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
2794         (WebKit::WebContextMenuProxyGtk::populate):
2795         (WebKit::WebContextMenuProxyGtk::showContextMenu):
2796         (WebKit::WebContextMenuProxyGtk::hideContextMenu):
2797         (WebKit::WebContextMenuProxyGtk::WebContextMenuProxyGtk):
2798         * UIProcess/gtk/WebContextMenuProxyGtk.h:
2799         (WebKit::WebContextMenuProxyGtk::create):
2800         (WebKit::WebContextMenuProxyGtk::gtkMenu):
2801         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
2802         (WebKit::WebPopupMenuProxyGtk::WebPopupMenuProxyGtk):
2803         * UIProcess/gtk/WebPopupMenuProxyGtk.h:
2804         (WebKit::WebPopupMenuProxyGtk::create):
2805         (WebKit::WebPopupMenuProxyGtk::setCurrentlySelectedMenuItem):
2806
2807 2015-10-15  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
2808
2809          EFL build fix since r191137
2810
2811          Unreviewed EFL build fix.
2812
2813         * UIProcess/CoordinatedGraphics/WebView.cpp: Removed.
2814
2815 2015-10-15  Myles C. Maxfield  <mmaxfield@apple.com>
2816
2817         Migrate to CGContextSetBaseCTM() and CGContextResetClip() from WKSI
2818         https://bugs.webkit.org/show_bug.cgi?id=150155
2819
2820         Reviewed by Tim Horton.
2821
2822         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2823         (InitWebCoreSystemInterface): Deleted.
2824
2825 2015-10-15  Dean Jackson  <dino@apple.com>
2826
2827         Fix the iOS build. And hopefully not breaking the other builds
2828         at the same time.
2829
2830         * UIProcess/PageClient.h:
2831         * UIProcess/WebContextMenuProxy.cpp:
2832         * UIProcess/WebContextMenuProxy.h:
2833         * UIProcess/ios/PageClientImplIOS.h:
2834         * UIProcess/ios/PageClientImplIOS.mm:
2835         * UIProcess/mac/PageClientImpl.h:
2836         * UIProcess/mac/PageClientImpl.mm:
2837
2838 2015-10-15  Anders Carlsson  <andersca@apple.com>
2839
2840         Use the context inside WebContextMenuProxyMac
2841         https://bugs.webkit.org/show_bug.cgi?id=150196
2842
2843         Reviewed by Tim Horton.
2844
2845         * UIProcess/WebContextMenuProxy.h:
2846         * UIProcess/WebPageProxy.cpp:
2847         (WebKit::WebPageProxy::internalShowContextMenu):
2848         * UIProcess/mac/WebContextMenuProxyMac.h:
2849         * UIProcess/mac/WebContextMenuProxyMac.mm:
2850         (WebKit::WebContextMenuProxyMac::populate):
2851         (WebKit::WebContextMenuProxyMac::showContextMenu):
2852
2853 2015-10-15  Anders Carlsson  <andersca@apple.com>
2854
2855         Use the context menu location that's stored in the context data
2856         https://bugs.webkit.org/show_bug.cgi?id=150194
2857
2858         Reviewed by Tim Horton.
2859
2860         * UIProcess/WebContextMenuProxy.h:
2861         * UIProcess/WebPageProxy.cpp:
2862         (WebKit::WebPageProxy::internalShowContextMenu):
2863         * UIProcess/mac/WebContextMenuProxyMac.h:
2864         * UIProcess/mac/WebContextMenuProxyMac.mm:
2865         (WebKit::WebContextMenuProxyMac::showContextMenu):
2866
2867 2015-10-15  Anders Carlsson  <andersca@apple.com>
2868
2869         Store the context menu data and user data in the WebContextMenuProxy object
2870         https://bugs.webkit.org/show_bug.cgi?id=150191
2871
2872         Reviewed by Tim Horton.
2873
2874         * UIProcess/PageClient.h:
2875         * UIProcess/WebContextMenuProxy.cpp:
2876         (WebKit::WebContextMenuProxy::WebContextMenuProxy):
2877         * UIProcess/WebContextMenuProxy.h:
2878         * UIProcess/WebPageProxy.cpp:
2879         (WebKit::WebPageProxy::internalShowContextMenu):
2880         * UIProcess/ios/PageClientImplIOS.h:
2881         * UIProcess/ios/PageClientImplIOS.mm:
2882         (WebKit::PageClientImpl::createContextMenuProxy):
2883         * UIProcess/mac/PageClientImpl.h:
2884         * UIProcess/mac/PageClientImpl.mm:
2885         (WebKit::PageClientImpl::createContextMenuProxy):
2886         * UIProcess/mac/WebContextMenuProxyMac.h:
2887         (WebKit::WebContextMenuProxyMac::create):
2888         * UIProcess/mac/WebContextMenuProxyMac.mm:
2889         (WebKit::WebContextMenuProxyMac::WebContextMenuProxyMac):
2890
2891 2015-10-15  Dan Bernstein  <mitz@apple.com>
2892
2893         [Cocoa] Stop using WKSetNSURLConnectionDefersCallbacks
2894         https://bugs.webkit.org/show_bug.cgi?id=150189
2895
2896         Reviewed by Anders Carlsson.
2897
2898         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2899         (InitWebCoreSystemInterface): Removed initialization.
2900
2901 2015-10-15  Anders Carlsson  <andersca@apple.com>
2902
2903         Fix build.
2904
2905         * UIProcess/API/APIFrameInfo.cpp:
2906         (API::FrameInfo::~FrameInfo):
2907         * UIProcess/API/APIFrameInfo.h:
2908         * UIProcess/API/Cocoa/WKUserContentController.mm:
2909
2910 2015-10-15  Anders Carlsson  <andersca@apple.com>
2911
2912         CTTE menu proxies
2913         https://bugs.webkit.org/show_bug.cgi?id=150187
2914
2915         Reviewed by Tim Horton.
2916
2917         * UIProcess/PageClient.h:
2918         * UIProcess/WebPageProxy.cpp:
2919         (WebKit::WebPageProxy::showPopupMenu):
2920         (WebKit::WebPageProxy::internalShowContextMenu):
2921         * UIProcess/WebPopupMenuProxy.h:
2922         (WebKit::WebPopupMenuProxy::WebPopupMenuProxy):
2923         * UIProcess/ios/PageClientImplIOS.h:
2924         * UIProcess/ios/PageClientImplIOS.mm:
2925         (WebKit::PageClientImpl::createPopupMenuProxy):
2926         (WebKit::PageClientImpl::createContextMenuProxy): Deleted.
2927         * UIProcess/mac/PageClientImpl.h:
2928         * UIProcess/mac/PageClientImpl.mm:
2929         (WebKit::PageClientImpl::createPopupMenuProxy):
2930         (WebKit::PageClientImpl::createContextMenuProxy):
2931         * UIProcess/mac/WebContextMenuProxyMac.h:
2932         (WebKit::WebContextMenuProxyMac::create):
2933         (WebKit::WebContextMenuProxyMac::page):
2934         * UIProcess/mac/WebContextMenuProxyMac.mm:
2935         (WebKit::WebContextMenuProxyMac::WebContextMenuProxyMac):
2936         (WebKit::WebContextMenuProxyMac::~WebContextMenuProxyMac):
2937         (WebKit::WebContextMenuProxyMac::contextMenuItemSelected):
2938         * UIProcess/mac/WebPopupMenuProxyMac.h:
2939         (WebKit::WebPopupMenuProxyMac::create):
2940         * UIProcess/mac/WebPopupMenuProxyMac.mm:
2941         (WebKit::WebPopupMenuProxyMac::WebPopupMenuProxyMac):
2942
2943 2015-10-15  Anders Carlsson  <andersca@apple.com>
2944
2945         Add -[WKFrameInfo _handle]
2946         https://bugs.webkit.org/show_bug.cgi?id=150185
2947         rdar://problem/23132371
2948
2949         Reviewed by Tim Horton.
2950
2951         * UIProcess/API/APIFrameInfo.cpp:
2952         (API::FrameInfo::FrameInfo):
2953         * UIProcess/API/APIFrameInfo.h:
2954         * UIProcess/API/Cocoa/WKFrameInfo.mm:
2955         (-[WKFrameInfo _handle]):
2956         * UIProcess/API/Cocoa/WKFrameInfoInternal.h:
2957         * UIProcess/API/Cocoa/WKFrameInfoPrivate.h: Copied from Source/WebKit2/UIProcess/API/Cocoa/WKFrameInfoInternal.h.
2958         * UIProcess/WebPageProxy.cpp:
2959         (WebKit::WebPageProxy::showPopupMenu):
2960         (WebKit::WebPageProxy::internalShowContextMenu):
2961         * UIProcess/WebPopupMenuProxy.h:
2962         (WebKit::WebPopupMenuProxy::WebPopupMenuProxy):
2963         * WebKit2.xcodeproj/project.pbxproj:
2964
2965 2015-10-15  Anders Carlsson  <andersca@apple.com>
2966
2967         The menu location and menu items should be part of ContextMenuContextData
2968         https://bugs.webkit.org/show_bug.cgi?id=150182
2969
2970         Reviewed by Andreas Kling.
2971
2972         * Shared/ContextMenuContextData.cpp:
2973         (WebKit::ContextMenuContextData::ContextMenuContextData):
2974         (WebKit::ContextMenuContextData::encode):
2975         (WebKit::ContextMenuContextData::decode):
2976         * Shared/ContextMenuContextData.h:
2977         (WebKit::ContextMenuContextData::menuLocation):
2978         (WebKit::ContextMenuContextData::menuItems):
2979         (WebKit::ContextMenuContextData::ContextMenuContextData):
2980         * UIProcess/WebPageProxy.cpp:
2981         (WebKit::WebPageProxy::showContextMenu):
2982         (WebKit::WebPageProxy::internalShowContextMenu):
2983         * UIProcess/WebPageProxy.h:
2984         * UIProcess/WebPageProxy.messages.in:
2985         * UIProcess/mac/WebPageProxyMac.mm:
2986         (WebKit::WebPageProxy::showSelectionServiceMenu):
2987         * WebProcess/WebPage/WebContextMenu.cpp:
2988         (WebKit::WebContextMenu::show):
2989
2990 2015-10-15  Carlos Garcia Campos  <cgarcia@igalia.com>
2991
2992         [GTK] Test WebKit2.RestoreSessionStateContainingFormData fails
2993         https://bugs.webkit.org/show_bug.cgi?id=84960
2994
2995         Reviewed by Žan Doberšek.
2996
2997         Add a cross-platform implementation to LegacySessionStateCodingNone
2998         using the new SessionState, so that non mac ports can make unit
2999         tests that use the legacy session state coding pass.
3000
3001         * UIProcess/LegacySessionStateCodingNone.cpp:
3002         (WebKit::encodeLegacySessionState):
3003         (WebKit::decodeLegacySessionState):
3004         (WebKit::encodeLegacySessionHistoryEntryData): Deleted.
3005         (WebKit::decodeLegacySessionHistoryEntryData): Deleted.
3006
3007 2015-10-15  Carlos Garcia Campos  <cgarcia@igalia.com>
3008
3009         Unreviewed. Fix wrong #ifdef added in r190615.
3010
3011         This disabled accelerated compositing unconditionally.
3012
3013         * UIProcess/gtk/WebPreferencesGtk.cpp:
3014         (WebKit::WebPreferences::platformInitializeStore):
3015
3016 2015-10-14  Zhuo Li  <zachli@apple.com>
3017
3018         Augment <input type=search>’s recent search history with the time each entry was added,
3019         in order to allow time-based clearing of search history.
3020         https://bugs.webkit.org/show_bug.cgi?id=148388.
3021
3022         Reviewed by Darin Adler.
3023
3024         Replace Vector<String> with Vector<RecentSearch>, where RecentSearch is a struct
3025         that consists search string and time, for recent searches in order to store additional time
3026         information.
3027
3028         All these new RecentSearches are stored in a plist in which the structure looks like:
3029         Root {
3030             "items": {
3031                 autosave name: {
3032                     "searches": [
3033                         { "searchString": searchString, "date": date },
3034                         ...
3035                     ]
3036                 }
3037             }
3038         }
3039
3040         * Scripts/webkit/messages.py:
3041         (headers_for_type):
3042         * Shared/WebCoreArgumentCoders.cpp:
3043         (IPC::ArgumentCoder<RecentSearch>::encode): Encode the new struct RecentSearch
3044         (IPC::ArgumentCoder<RecentSearch>::decode): Decode the new struct RecentSearch
3045         * Shared/WebCoreArgumentCoders.h:
3046         * UIProcess/Cocoa/WebPageProxyCocoa.mm:
3047         (WebKit::WebPageProxy::saveRecentSearches): Call saveRecentSearches in WebCore::SearchPopupMenuCocoa.
3048         (WebKit::WebPageProxy::loadRecentSearches): Call loadRecentSearches in WebCore::SearchPopupMenuCocoa.
3049         * UIProcess/WebPageProxy.h:
3050         * UIProcess/WebPageProxy.messages.in:
3051         * UIProcess/efl/WebPageProxyEfl.cpp:
3052         (WebKit::WebPageProxy::saveRecentSearches):
3053         (WebKit::WebPageProxy::loadRecentSearches):
3054         * UIProcess/gtk/WebPageProxyGtk.cpp:
3055         (WebKit::WebPageProxy::saveRecentSearches):
3056         (WebKit::WebPageProxy::loadRecentSearches):
3057         * WebProcess/WebCoreSupport/WebSearchPopupMenu.cpp:
3058         (WebKit::WebSearchPopupMenu::saveRecentSearches):
3059         (WebKit::WebSearchPopupMenu::loadRecentSearches):
3060         * WebProcess/WebCoreSupport/WebSearchPopupMenu.h:
3061
3062 2015-10-14  Wenson Hsieh  <wenson_hsieh@apple.com>
3063
3064         Web pages with unscalable viewports shouldn't have a single tap delay
3065         https://bugs.webkit.org/show_bug.cgi?id=149968
3066         <rdar://problem/23054453>
3067
3068         Reviewed by Simon Fraser.
3069
3070         When a viewport is unscalable (specified through the meta viewport tag) we
3071         do not add a delay to our single tap gesture recognizer. We do this by
3072         disabling or reinitializing the WKContentView's double tap gesture recognizer
3073         when the viewport becomes unscalable or scalable, respectively. A viewport is
3074         deemed unscalable when it has user-scalable = no, or when the minimum scale is
3075         greater than or equal to the maximum scale.
3076
3077         * UIProcess/API/Cocoa/WKWebView.mm:
3078         (-[WKWebView _didCommitLayerTree:]):
3079         * UIProcess/ios/WKContentViewInteraction.h:
3080         * UIProcess/ios/WKContentViewInteraction.mm:
3081         (-[WKContentView _createAndConfigureDoubleTapGestureRecognizer]): Pulled logic
3082                 for initializing a double tap gesture recognizer out into a helper function.
3083         (-[WKContentView setupInteraction]):
3084         (-[WKContentView _setDoubleTapGesturesEnabled:]): Turns gesture recognition for double
3085                 taps on or off.
3086
3087 2015-10-14  Anders Carlsson  <andersca@apple.com>
3088
3089         Remove a message that isn't used by anyone
3090         https://bugs.webkit.org/show_bug.cgi?id=150136
3091
3092         Reviewed by Andreas Kling.
3093
3094         * UIProcess/API/APILoaderClient.h:
3095         (API::LoaderClient::didRemoveFrameFromHierarchy): Deleted.
3096         * UIProcess/API/C/WKPage.cpp:
3097         (WKPageSetPageLoaderClient): Deleted.
3098         * UIProcess/WebPageProxy.cpp:
3099         (WebKit::WebPageProxy::didRemoveFrameFromHierarchy): Deleted.
3100         * UIProcess/WebPageProxy.h:
3101         * UIProcess/WebPageProxy.messages.in:
3102         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3103         (WebKit::WebFrameLoaderClient::detachedFromParent2): Deleted.
3104
3105 2015-10-14  Alex Christensen  <achristensen@webkit.org>
3106
3107         Add SPI for reloading without content blockers
3108         https://bugs.webkit.org/show_bug.cgi?id=150058
3109         rdar://problem/22742222
3110
3111         Reviewed by Sam Weinig.
3112
3113         * Shared/WebPageCreationParameters.cpp:
3114         (WebKit::WebPageCreationParameters::encode):
3115         (WebKit::WebPageCreationParameters::decode):
3116         * Shared/WebPageCreationParameters.h:
3117         * UIProcess/API/C/WKPage.cpp:
3118         (WKPageReload):
3119         (WKPageReloadWithoutContentBlockers):
3120         (WKPageReloadFromOrigin):
3121         (WKPageTryClose):
3122         (WKPageSetUserContentExtensionsEnabled):
3123         (WKPageSupportsTextEncoding):
3124         * UIProcess/API/C/WKPage.h:
3125         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
3126         (-[WKBrowsingContextController reload]):
3127         (-[WKBrowsingContextController reloadFromOrigin]):
3128         (-[WKBrowsingContextController applicationNameForUserAgent]):
3129         * UIProcess/API/Cocoa/WKWebView.mm:
3130         (-[WKWebView reload]):
3131         (-[WKWebView reloadFromOrigin]):
3132         (-[WKWebView _setUserContentExtensionsEnabled:]):
3133         (-[WKWebView _userContentExtensionsEnabled]):
3134         (-[WKWebView _webProcessIdentifier]):
3135         (-[WKWebView _killWebContentProcess]):
3136         (-[WKWebView _reloadWithoutContentBlockers]):
3137         (-[WKWebView _killWebContentProcessAndResetState]):
3138         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3139         * UIProcess/API/gtk/WebKitWebView.cpp:
3140         (webkit_web_view_reload):
3141         (webkit_web_view_reload_bypass_cache):
3142         * UIProcess/WebFrameProxy.cpp:
3143         (WebKit::WebFrameProxy::didHandleContentFilterUnblockNavigation):
3144         * UIProcess/WebPageProxy.cpp:
3145         (WebKit::WebPageProxy::stopLoading):
3146         (WebKit::WebPageProxy::reload):
3147         (WebKit::WebPageProxy::creationParameters):
3148         (WebKit::WebPageProxy::setShouldScaleViewToFitDocument):
3149         (WebKit::WebPageProxy::setUserContentExtensionsEnabled): Deleted.
3150         * UIProcess/WebPageProxy.h:
3151         (WebKit::WebPageProxy::userContentExtensionsEnabled): Deleted.
3152         * WebProcess/WebPage/WebPage.cpp:
3153         (WebKit::m_shouldDispatchFakeMouseMoveEvents):
3154         (WebKit::WebPage::setDefersLoading):
3155         (WebKit::WebPage::reload):
3156         (WebKit::WebPage::goForward):
3157         (WebKit::WebPage::createDocumentLoader):
3158         (WebKit::WebPage::setShouldScaleViewToFitDocument):
3159         (WebKit::WebPage::imageOrMediaDocumentSizeChanged):
3160         (WebKit::WebPage::setUserContentExtensionsEnabled): Deleted.
3161         * WebProcess/WebPage/WebPage.h:
3162         * WebProcess/WebPage/WebPage.messages.in:
3163
3164 2015-10-14  Simon Fraser  <simon.fraser@apple.com>
3165
3166         Change GraphicsContext image-drawing functions to take references
3167         https://bugs.webkit.org/show_bug.cgi?id=150108
3168
3169         Reviewed by Tim Horton and Sam Weinig.
3170
3171         Change GraphicsContext::drawImage(), drawTiledImage(), drawImageBuffer(), clipToImageBuffer()
3172         and isCompatibleWithBuffer() to take references, and adjust calling code, adding
3173         null-checks where necessary.
3174
3175         * Shared/ContextMenuContextData.cpp:
3176         (WebKit::ContextMenuContextData::ContextMenuContextData):
3177         * Shared/WebCoreArgumentCoders.cpp:
3178         (IPC::encodeImage):
3179         (IPC::encodeOptionalImage):
3180         (IPC::ArgumentCoder<Cursor>::encode):
3181         * WebProcess/WebPage/WebFrame.cpp:
3182         (WebKit::WebFrame::createSelectionSnapshot):
3183
3184 2015-10-14  Anders Carlsson  <andersca@apple.com>
3185
3186         Change the bundle app cache APIs to take a page
3187         https://bugs.webkit.org/show_bug.cgi?id=150123
3188
3189         Reviewed by Sam Weinig.
3190
3191         This is another step towards getting rid of ApplicationCacheStorage::singleton().
3192         Ideally the WKTR tests that use this should be converted to API tests.
3193
3194         * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
3195         (WKBundleClearApplicationCache): Deleted.
3196         (WKBundleClearApplicationCacheForOrigin): Deleted.
3197         (WKBundleSetAppCacheMaximumSize): Deleted.
3198         (WKBundleGetAppCacheUsageForOrigin): Deleted.
3199         (WKBundleSetApplicationCacheOriginQuota): Deleted.
3200         (WKBundleResetApplicationCacheOriginQuota): Deleted.
3201         (WKBundleCopyOriginsWithApplicationCache): Deleted.
3202         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
3203         (WKBundlePageClearApplicationCache):
3204         (WKBundlePageClearApplicationCacheForOrigin):
3205         (WKBundlePageSetAppCacheMaximumSize):
3206         (WKBundlePageGetAppCacheUsageForOrigin):
3207         (WKBundlePageSetApplicationCacheOriginQuota):
3208         (WKBundlePageResetApplicationCacheOriginQuota):
3209         (WKBundlePageCopyOriginsWithApplicationCache):
3210         * WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
3211         * WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
3212         * WebProcess/InjectedBundle/InjectedBundle.cpp:
3213         (WebKit::InjectedBundle::clearApplicationCache): Deleted.
3214         (WebKit::InjectedBundle::clearApplicationCacheForOrigin): Deleted.
3215         (WebKit::InjectedBundle::setAppCacheMaximumSize): Deleted.
3216         (WebKit::InjectedBundle::appCacheUsageForOrigin): Deleted.
3217         (WebKit::InjectedBundle::setApplicationCacheOriginQuota): Deleted.
3218         (WebKit::InjectedBundle::resetApplicationCacheOriginQuota): Deleted.
3219         (WebKit::InjectedBundle::originsWithApplicationCache): Deleted.
3220         * WebProcess/InjectedBundle/InjectedBundle.h:
3221
3222 2015-10-14  Joonghun Park  <jh718.park@samsung.com>
3223
3224         [EFL] Fix the problem in which environment variable included in webprocess-cmd-prefix can't be parsed
3225         https://bugs.webkit.org/show_bug.cgi?id=148616
3226
3227         Reviewed by Gyuyoung Kim.
3228
3229         This patch fixes the problem in which environment variable in web process-cmd-prefix can't be parsed.
3230         process-cmd-prefix option doesn't work in two cases.
3231         1. When executing run-layout-tests,
3232         2. When executing MiniBrowser with web process-cmd-prefix environment variable.
3233
3234         * UIProcess/Launcher/efl/ProcessLauncherEfl.cpp:
3235         (WebKit::parseAndRemoveEnvironments):
3236         (WebKit::ProcessLauncher::launchProcess):
3237
3238 2015-10-13  Yongjun Zhang  <yongjun_zhang@apple.com>
3239
3240         Use the correct notification strings for view service applications state change.
3241         https://bugs.webkit.org/show_bug.cgi?id=150107
3242
3243         Use the correct notification names "_UIViewServiceHostDidEnterBackgroundNotification" and
3244         "_UIViewServiceHostWillEnterForegroundNotification" to listen to view service application state changes.
3245
3246         Reviewed by Gavin Barraclough.
3247
3248         * UIProcess/ApplicationStateTracker.mm:
3249         (WebKit::ApplicationStateTracker::ApplicationStateTracker):
3250
3251 2015-10-13  Myles C. Maxfield  <mmaxfield@apple.com>
3252
3253         Split TypesettingFeatures into kerning and ligatures bools
3254         https://bugs.webkit.org/show_bug.cgi?id=150074
3255
3256         Reviewed by Simon Fraser.
3257
3258         * Shared/WebProcessCreationParameters.cpp:
3259         (WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
3260         (WebKit::WebProcessCreationParameters::encode):
3261         (WebKit::WebProcessCreationParameters::decode):
3262         * Shared/WebProcessCreationParameters.h:
3263         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
3264         (WebKit::WebProcessPool::platformInitializeWebProcess):
3265         * WebProcess/cocoa/WebProcessCocoa.mm:
3266         (WebKit::WebProcess::platformInitializeWebProcess):
3267
3268 2015-10-13  Dean Jackson  <dino@apple.com>
3269
3270         Fix iOS-family builds.
3271
3272         * UIProcess/API/C/mac/WKPagePrivateMac.mm:
3273         (WKPageGetObjectRegistry):
3274         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
3275         (-[WKBrowsingContextController _remoteObjectRegistry]):
3276         * UIProcess/API/mac/WKViewInternal.h:
3277
3278 2015-10-13  Anders Carlsson  <andersca@apple.com>
3279
3280         Fix 32-bit build.
3281
3282         * UIProcess/API/C/mac/WKPagePrivateMac.mm:
3283         (WKPageGetObjectRegistry):
3284
3285 2015-10-13  Anders Carlsson  <andersca@apple.com>
3286
3287         Add and implement WKPageGetObjectRegistry
3288         https://bugs.webkit.org/show_bug.cgi?id=150102
3289
3290         Reviewed by Tim Horton.
3291
3292         Put the _WKObjectRegistry used by WKPageRef and WKBrowsingContextController on the WKView for now.
3293         If we decide to share more code between WKView and WKWebView, the object registry could live in an object that would be shared
3294         between WKView and WKWebView.
3295
3296         * UIProcess/API/C/mac/WKPagePrivateMac.h:
3297         * UIProcess/API/C/mac/WKPagePrivateMac.mm:
3298         (WKPageGetObjectRegistry):
3299         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
3300         (-[WKBrowsingContextController _remoteObjectRegistry]):
3301         (-[WKBrowsingContextController dealloc]): Deleted.
3302         * UIProcess/API/mac/WKView.mm:
3303         (-[WKView dealloc]):
3304         (-[WKView _remoteObjectRegistry]):
3305         * UIProcess/API/mac/WKViewInternal.h:
3306
3307 2015-10-13  Chris Dumez  <cdumez@apple.com>
3308
3309         Avoid useless copies in range-loops that are using 'auto'
3310         https://bugs.webkit.org/show_bug.cgi?id=150091
3311
3312         Reviewed by Sam Weinig.
3313
3314         Avoid useless copies in range-loops that are using 'auto'. Also use
3315         'auto*' instead of 'auto' when range values are pointers for clarity.
3316
3317         * UIProcess/VisitedLinkStore.cpp:
3318         (WebKit::VisitedLinkStore::pendingVisitedLinksTimerFired):
3319         (WebKit::VisitedLinkStore::resizeTable):
3320         * UIProcess/WebProcessProxy.cpp:
3321         (WebKit::WebProcessProxy::releaseRemainingIconsForPageURLs):
3322         * UIProcess/WebsiteData/WebsiteDataStore.cpp:
3323         (WebKit::WebsiteDataStore::fetchData):
3324         (WebKit::WebsiteDataStore::removeData):
3325         (WebKit::WebsiteDataStore::plugins):
3326
3327 2015-10-13  Said Abou-Hallawa  <sabouhallawa@apple.com>
3328
3329         Add debug settings for using giant tiles (4096x4096)
3330         https://bugs.webkit.org/show_bug.cgi?id=149977
3331         <rdar://problem/23017093>
3332
3333         Reviewed by Tim Horton.
3334
3335         * Shared/WebPreferencesDefinitions.h:
3336         * UIProcess/API/C/WKPreferences.cpp:
3337         (WKPreferencesSetUseGiantTiles):
3338         (WKPreferencesGetUseGiantTiles):
3339         * UIProcess/API/C/WKPreferencesRefPrivate.h:
3340         * WebProcess/WebPage/WebPage.cpp:
3341         (WebKit::WebPage::updatePreferences):
3342
3343 2015-10-13  Brent Fulgham  <bfulgham@apple.com>
3344
3345         [iOS] Avoid crash due to invalid screen bounds
3346         https://bugs.webkit.org/show_bug.cgi?id=150048
3347         <rdar://problem/22112664>
3348
3349         Reviewed by Jer Noble.
3350
3351         Check for an invalid bounds, and reset it to a known state before
3352         attempting to use it.
3353
3354         * WebProcess/ios/WebVideoFullscreenManager.mm:
3355         (WebKit::WebVideoFullscreenManager::setVideoLayerFrameFenced):
3356
3357 2015-10-13  Sergio Villar Senin  <svillar@igalia.com>
3358
3359         [GTK] Fix build for ENABLE_TOUCH_EVENTS=OFF
3360         https://bugs.webkit.org/show_bug.cgi?id=150085
3361
3362         Reviewed by Carlos Garcia Campos.
3363
3364         * Shared/gtk/NativeWebTouchEventGtk.cpp:
3365         * Shared/gtk/WebEventFactory.cpp:
3366         * Shared/gtk/WebEventFactory.h:
3367         * UIProcess/API/gtk/PageClientImpl.cpp:
3368         * UIProcess/API/gtk/PageClientImpl.h:
3369         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
3370         (webkit_web_view_base_class_init):
3371
3372 2015-10-13  Chris Dumez  <cdumez@apple.com>
3373
3374         Avoid useless copying of Key::HashType in loops in NetworkCache::Storage::synchronize()
3375         https://bugs.webkit.org/show_bug.cgi?id=150061
3376
3377         Reviewed by Carlos Garcia Campos.
3378
3379         Avoid useless copying of Key::HashType in loops in NetworkCache::Storage::synchronize().
3380         Key::HashType is currently a SHA1::Digest, which is a std::array<uint8_t, 20>.
3381
3382         * NetworkProcess/cache/NetworkCacheStorage.cpp:
3383         (WebKit::NetworkCache::Storage::synchronize):
3384
3385 2015-10-12  Philip Chimento  <philip.chimento@gmail.com>
3386
3387         [GTK] OSX linker doesn't understand --whole-archive
3388         https://bugs.webkit.org/show_bug.cgi?id=144557
3389
3390         Reviewed by Martin Robinson.
3391
3392         * PlatformGTK.cmake: Link with extra libraries on Darwin, since
3393         we don't have the --whole-archive linker option.
3394
3395 2015-10-09  Anders Carlsson  <andersca@apple.com>
3396
3397         Don't allow plug-ins to override image types for <embed> elements
3398         https://bugs.webkit.org/show_bug.cgi?id=149979
3399
3400         Reviewed by Tim Horton.
3401
3402         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3403         (WebKit::WebFrameLoaderClient::objectContentType):
3404         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
3405
3406 2015-10-12  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
3407
3408         [EFL] Bump Version/X in user agent
3409         https://bugs.webkit.org/show_bug.cgi?id=150013
3410
3411         Reviewed by Csaba Osztrogonác.
3412
3413         EFL port needs to ensure maximum compatibility with existing web sites.
3414         Thus version number needs to be bumped from 5.0 to 8.0 as GTK port.
3415
3416         * UIProcess/efl/WebPageProxyEfl.cpp:
3417         (WebKit::WebPageProxy::standardUserAgent):
3418
3419 2015-10-10  Dan Bernstein  <mitz@apple.com>
3420
3421         [iOS] Remove unnecessary iOS version checks
3422         https://bugs.webkit.org/show_bug.cgi?id=150002
3423
3424         Reviewed by Alexey Proskuryakov.
3425
3426         * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
3427         (WebKit::NetworkProcess::platformInitializeNetworkProcessCocoa):
3428         * Platform/IPC/mac/ConnectionMac.mm:
3429         (IPC::AccessibilityProcessSuspendedNotification):
3430         * Platform/spi/ios/SafariServicesSPI.h:
3431         * Platform/spi/ios/UIKitSPI.h:
3432         * Shared/Network/NetworkProcessCreationParameters.cpp:
3433         (WebKit::NetworkProcessCreationParameters::encode):
3434         (WebKit::NetworkProcessCreationParameters::decode):
3435         * Shared/Network/NetworkProcessCreationParameters.h:
3436         * Shared/Plugins/PluginProcessCreationParameters.cpp:
3437         (WebKit::PluginProcessCreationParameters::encode):
3438         (WebKit::PluginProcessCreationParameters::decode):
3439         * Shared/Plugins/PluginProcessCreationParameters.h:
3440         * Shared/WebEventConversion.cpp:
3441         (WebKit::WebKit2PlatformTouchPoint::WebKit2PlatformTouchPoint):
3442         * Shared/WebProcessCreationParameters.cpp:
3443         (WebKit::WebProcessCreationParameters::encode):
3444         (WebKit::WebProcessCreationParameters::decode):
3445         * Shared/WebProcessCreationParameters.h:
3446         * Shared/ios/NativeWebTouchEventIOS.mm:
3447         (WebKit::NativeWebTouchEvent::extractWebTouchPoint):
3448         (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
3449         * Shared/ios/WebPlatformTouchPointIOS.cpp:
3450         (WebKit::WebPlatformTouchPoint::encode):
3451         (WebKit::WebPlatformTouchPoint::decode):
3452         * UIProcess/API/Cocoa/WKWebView.mm:
3453         (-[WKWebView _mayAutomaticallyShowVideoPictureInPicture]):
3454         (shouldAllowPictureInPictureMediaPlayback):
3455         (-[WKWebView _snapshotRect:intoImageOfWidth:completionHandler:]):
3456         * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
3457         (WebKit::WebProcessPool::platformInitializeWebProcess):
3458         (WebKit::WebProcessPool::platformInitializeNetworkProcess):
3459         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
3460         (WebKit::PluginProcessProxy::platformInitializePluginProcess):
3461         * UIProcess/ios/ViewGestureControllerIOS.mm:
3462         (-[WKSwipeTransitionController gestureRecognizerForInteractiveTransition:WithTarget:action:]):
3463         * UIProcess/ios/WKContentViewInteraction.mm:
3464         (-[WKContentView setupInteraction]):
3465         (-[WKContentView _ensureFormAccessoryView]):
3466         (-[WKContentView webSelectionAssistant]):
3467         (-[WKContentView selectionInteractionAssistant]):
3468         * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
3469         (WebKit::WebVideoFullscreenManagerProxy::create):
3470         * UIProcess/ios/forms/WKFileUploadPanel.mm:
3471         (photoLibraryIcon):
3472         (cameraIcon):
3473         (fallbackIconForFile):
3474         (iconForImageFile):
3475         * WebKit2.xcodeproj/project.pbxproj:
3476         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
3477         (WebKit::RemoteLayerTreeDrawingArea::flushLayers):
3478         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
3479         (WebKit::TiledCoreAnimationDrawingArea::flushLayers):
3480         * WebProcess/cocoa/WebProcessCocoa.mm:
3481         (WebKit::WebProcess::platformInitializeWebProcess):
3482
3483 2015-10-10  Dan Bernstein  <mitz@apple.com>
3484
3485         [iOS] Remove project support for iOS 8
3486         https://bugs.webkit.org/show_bug.cgi?id=149993
3487
3488         Reviewed by Alexey Proskuryakov.
3489
3490         * Configurations/Base.xcconfig:
3491         * Configurations/BaseLegacyProcess.xcconfig:
3492         * Configurations/BaseXPCService.xcconfig:
3493         * Configurations/PluginProcessShim.xcconfig:
3494         * Configurations/SecItemShim.xcconfig:
3495         * Configurations/WebKit.xcconfig:
3496         * Configurations/WebKit2.xcconfig:
3497         * Configurations/WebProcessShim.xcconfig:
3498
3499 2015-10-09  Myles C. Maxfield  <mmaxfield@apple.com>
3500
3501         Unreviewed, rolling out r190689
3502         https://bugs.webkit.org/show_bug.cgi?id=149992
3503
3504         Fixed in other repository.
3505
3506         Reverted changesets:
3507
3508         "Unreviewed, rolling out r190572, r190593, r190594, and r190639."
3509         https://bugs.webkit.org/show_bug.cgi?id=149897
3510
3511 2015-10-09  Beth Dakin  <bdakin@apple.com>
3512
3513         Rubber-stamped by Anders Carlsson.
3514
3515         Remove unnecessary includes.
3516         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3517         * WebProcess/Plugins/Plugin.h:
3518         * WebProcess/Plugins/PluginProxy.h:
3519         * WebProcess/Plugins/PluginView.h:
3520         * WebProcess/WebPage/mac/WebPageMac.mm:
3521
3522 2015-10-09  Beth Dakin  <bdakin@apple.com>
3523
3524         Build fix.
3525
3526         * CMakeLists.txt:
3527         * Shared/API/APIHitTestResult.cpp: Removed.
3528         * Shared/API/APIHitTestResult.h: Removed.
3529         * WebKit2.xcodeproj/project.pbxproj:
3530
3531 2015-10-09  Beth Dakin  <bdakin@apple.com>
3532
3533         Build fix.
3534
3535         * UIProcess/API/APIHitTestResult.cpp: Copied from Shared/API/APIHitTestResult.cpp.
3536         * UIProcess/API/APIHitTestResult.h: Copied from Shared/API/APIHitTestResult.h.
3537         * UIProcess/mac/PageClientImpl.mm:
3538
3539 2015-10-09  Beth Dakin  <bdakin@apple.com>
3540
3541         WKWebView needs SPI to customize immediate actions
3542         https://bugs.webkit.org/show_bug.cgi?id=149939
3543         -and corresponding-
3544         rdar://problem/20016849
3545
3546         Reviewed by Anders Carlsson.
3547
3548         This patch breaks WebHitTestResult into two files. WebHiTestResultData 
3549         continues to live in the WebKit namespace and contains the old 
3550         WebHitTestResult::Data struct. The rest of WebHitTestResult is now 
3551         API::HitTestResult. The patch also adds _WKHitTestResult as Obj-C API to wrap 
3552         API::HitTestResult.
3553
3554         Attempt to keep other ports happy with new files.
3555         * CMakeLists.txt:
3556
3557         WebKit::WebHitTestResult no longer contains the Data struct and is now called 
3558         API::HitTestResult.
3559         * Shared/API/APIHitTestResult.cpp: Copied from Shared/WebHitTestResult.cpp.
3560         (API::HitTestResult::create):
3561         (WebKit::WebHitTestResult::create): Deleted.
3562         (WebKit::WebHitTestResult::Data::Data): Deleted.
3563         (WebKit::WebHitTestResult::Data::~Data): Deleted.
3564         (WebKit::WebHitTestResult::Data::encode): Deleted.
3565         (WebKit::WebHitTestResult::Data::decode): Deleted.
3566         (WebKit::WebHitTestResult::Data::platformEncode): Deleted.
3567         (WebKit::WebHitTestResult::Data::platformDecode): Deleted.
3568         (WebKit::WebHitTestResult::Data::elementBoundingBoxInWindowCoordinates): Deleted.
3569         * Shared/API/APIHitTestResult.h: Copied from Shared/WebHitTestResult.h.
3570         (API::HitTestResult::absoluteImageURL):
3571         (API::HitTestResult::absolutePDFURL):
3572         (API::HitTestResult::absoluteLinkURL):
3573         (API::HitTestResult::absoluteMediaURL):
3574         (API::HitTestResult::linkLabel):
3575         (API::HitTestResult::linkTitle):
3576         (API::HitTestResult::lookupText):
3577         (API::HitTestResult::isContentEditable):
3578         (API::HitTestResult::isDownloadableMedia):
3579         (API::HitTestResult::HitTestResult):
3580         (WebKit::WebHitTestResult::absoluteImageURL): Deleted.
3581         (WebKit::WebHitTestResult::absolutePDFURL): Deleted.
3582         (WebKit::WebHitTestResult::absoluteLinkURL): Deleted.
3583         (WebKit::WebHitTestResult::absoluteMediaURL): Deleted.
3584         (WebKit::WebHitTestResult::linkLabel): Deleted.
3585         (WebKit::WebHitTestResult::linkTitle): Deleted.
3586         (WebKit::WebHitTestResult::lookupText): Deleted.
3587         (WebKit::WebHitTestResult::isContentEditable): Deleted.
3588         (WebKit::WebHitTestResult::isDownloadableMedia): Deleted.
3589         (WebKit::WebHitTestResult::WebHitTestResult): Deleted.
3590
3591         This is a new obj-c object that we can use for the modern immediate action 
3592         API.
3593         * Shared/API/Cocoa/_WKHitTestResult.h: Added.
3594         * Shared/API/Cocoa/_WKHitTestResult.mm: Added.
3595         (-[_WKHitTestResult dealloc]):
3596         (-[_WKHitTestResult absoluteImageURL]):
3597         (-[_WKHitTestResult absolutePDFURL]):
3598         (-[_WKHitTestResult absoluteLinkURL]):
3599         (-[_WKHitTestResult absoluteMediaURL]):
3600         (-[_WKHitTestResult linkLabel]):
3601         (-[_WKHitTestResult linkTitle]):
3602         (-[_WKHitTestResult lookupText]):
3603         (-[_WKHitTestResult isContentEditable]):
3604         (-[_WKHitTestResult elementBoundingBox]):
3605         (-[_WKHitTestResult copyWithZone:]):
3606         (-[_WKHitTestResult _apiObject]):
3607
3608         _WKHitTestResult wraps API::HitTestResult.
3609         * Shared/API/Cocoa/_WKHitTestResultInternal.h: Added.
3610         (API::wrapper):
3611         * Shared/Cocoa/APIObject.mm:
3612         (API::Object::newObject):
3613
3614         Since we want to use the same enum name for the new enum, use a #define instead of a typedef in the old C SPI. This should keep old clients working in the meantime.
3615         * Shared/API/c/WKImmediateActionTypes.h:
3616
3617         WebHitTestResult::Data is now WebHitTestResultData.
3618         * Shared/ContextMenuContextData.h:
3619         (WebKit::ContextMenuContextData::webHitTestResultData):
3620         (WebKit::ContextMenuContextData::selectedText):
3621
3622         Remove WebHitTestResult, and add WebHitTestResultData for the Data struct.
3623         * Shared/WebHitTestResult.cpp: Removed.
3624         * Shared/WebHitTestResult.h: Removed.
3625         * Shared/WebHitTestResultData.cpp: Added.
3626         (WebKit::WebHitTestResultData::WebHitTestResultData):
3627         (WebKit::WebHitTestResultData::~WebHitTestResultData):
3628         (WebKit::WebHitTestResultData::encode):
3629         (WebKit::WebHitTestResultData::decode):
3630         (WebKit::WebHitTestResultData::platformEncode):
3631         (WebKit::WebHitTestResultData::platformDecode):
3632         (WebKit::WebHitTestResultData::elementBoundingBoxInWindowCoordinates):
3633         * Shared/WebHitTestResultData.h: Added.
3634         * Shared/mac/WebHitTestResult.mm: Removed.
3635         * Shared/mac/WebHitTestResultData.mm: Copied from Shared/mac/WebHitTestResult.mm.
3636         (WebKit::WebHitTestResultData::platformEncode):
3637         (WebKit::WebHitTestResultData::platformDecode):
3638         (WebKit::WebHitTestResult::Data::platformEncode): Deleted.
3639         (WebKit::WebHitTestResult::Data::platformDecode): Deleted.
3640
3641         WebHitTestResult::Data is now WebHitTestResultData.
3642         * UIProcess/API/APIContextMenuClient.h:
3643         (API::ContextMenuClient::~ContextMenuClient):
3644         (API::ContextMenuClient::getContextMenuFromProposedMenu):
3645         (API::ContextMenuClient::customContextMenuItemSelected):
3646         (API::ContextMenuClient::contextMenuDismissed):
3647         (API::ContextMenuClient::showContextMenu):
3648
3649         WebHitTestResult is now WebHitTestResult
3650         * UIProcess/API/APIUIClient.h:
3651         (API::UIClient::runJavaScriptPrompt):
3652         (API::UIClient::setStatusText):
3653         (API::UIClient::mouseDidMoveOverElement):
3654         (API::UIClient::unavailablePluginButtonClicked):
3655         (API::UIClient::pinnedStateDidChange):
3656         (API::UIClient::didBeginTrackingPotentialLongMousePress):
3657         (API::UIClient::didRecognizeLongMousePress):
3658         (API::UIClient::didCancelTrackingPotentialLongMousePress):
3659         * UIProcess/API/C/WKAPICast.h:
3660         * UIProcess/API/C/WKHitTestResult.cpp:
3661         (WKHitTestResultGetTypeID):
3662         (WKHitTestResultCopyAbsoluteImageURL):
3663         * UIProcess/API/C/WKPage.cpp:
3664         (WKPageSetPageContextMenuClient):
3665         (WKPageSetPageUIClient):
3666
3667         New WKWebView SPI _immediateActionAnimationControllerForHitTestResult
3668         * UIProcess/API/Cocoa/WKViewPrivate.h:
3669         * UIProcess/API/Cocoa/WKWebView.mm:
3670         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3671
3672         Attempts to keep other ports happy with the re-name.
3673         * UIProcess/API/efl/WebAccessibility.cpp:
3674         * UIProcess/API/gtk/WebKitContextMenuClient.cpp:
3675         * UIProcess/API/gtk/WebKitHitTestResult.cpp:
3676         (webkit_hit_test_result_class_init):
3677         (webkitHitTestResultCreate):
3678         (stringIsEqualToCString):
3679         (webkitHitTestResultCompare):
3680         * UIProcess/API/gtk/WebKitHitTestResultPrivate.h:
3681         * UIProcess/API/gtk/WebKitUIClient.cpp:
3682         * UIProcess/API/gtk/WebKitWebView.cpp:
3683         (webkitWebViewMakePermissionRequest):
3684         (webkitWebViewMouseTargetChanged):
3685         (contextMenuDismissed):
3686         (webkitWebViewPopulateContextMenu):
3687         * UIProcess/API/gtk/WebKitWebViewPrivate.h:
3688
3689         Re-name, and just use uint32_t for the old SPI.
3690         * UIProcess/API/mac/WKView.mm:
3691         (-[WKView _didPerformImmediateActionHitTest:contentPreventsDefault:userData:]):
3692         (-[WKView _setDidMoveSwipeSnapshotCallback:]):
3693         (-[WKView _immediateActionAnimationControllerForHitTestResult:withType:userData:]):
3694         * UIProcess/API/mac/WKViewInternal.h:
3695
3696         PageClient will figure out whether to call into WKWebView or WKView for this 
3697         SPI.
3698         * UIProcess/PageClient.h:
3699         * UIProcess/WebPageProxy.cpp:
3700         (WebKit::WebPageProxy::immediateActionAnimationControllerForHitTestResult):
3701         * UIProcess/WebPageProxy.h:
3702         * UIProcess/mac/PageClientImpl.h:
3703         * UIProcess/mac/PageClientImpl.mm:
3704         (WebKit::PageClientImpl::immediateActionAnimationControllerForHitTestResult):
3705
3706         WebKit::WebHitTestResult::Data is now WebKit::WebHitTestResultData.
3707         * UIProcess/WebPageProxy.messages.in:
3708
3709         WKImmediateActionController calls through to WebPageProxy which calls to 
3710         PageClient, which figures out which API to call. Also cache the type as a 
3711         uint32_t
3712         * UIProcess/mac/WKImmediateActionController.h:
3713         * UIProcess/mac/WKImmediateActionController.mm:
3714         (-[WKImmediateActionController _updateImmediateActionItem]):
3715
3716         WebHitTestResult::Data is now WebHitTestResultData.
3717         * UIProcess/mac/WebPageProxyMac.mm:
3718         (WebKit::WebPageProxy::platformInitializeShareMenuItem):
3719
3720         New files!
3721         * WebKit2.xcodeproj/project.pbxproj:
3722
3723         Deal with the #define situation for the enum.
3724         * WebKit2Prefix.h:
3725
3726         New names for things. WebHitTestResult::Data -> WebHitTestResultData
3727         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3728         * WebProcess/Plugins/PDF/PDFPlugin.h:
3729         * WebProcess/Plugins/PDF/PDFPlugin.mm:
3730         (WebKit::pointInLayoutSpaceForPointInWindowSpace):
3731         (WebKit::PDFPlugin::lookupTextAtLocation):
3732         * WebProcess/Plugins/Plugin.h:
3733         * WebProcess/Plugins/PluginProxy.h:
3734         * WebProcess/Plugins/PluginView.h:
3735         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3736         (WebKit::WebChromeClient::mouseDidMoveOverElement):
3737         (WebKit::WebChromeClient::didBeginTrackingPotentialLongMousePress):
3738         * WebProcess/WebPage/mac/WebPageMac.mm:
3739         (WebKit::WebPage::performImmediateActionHitTestAtLocation):
3740
3741 2015-10-09  Anders Carlsson  <andersca@apple.com>
3742
3743         Remove two unused WKFrame functions
3744         https://bugs.webkit.org/show_bug.cgi?id=149958
3745
3746         Reviewed by Dan Bernstein.
3747
3748         * UIProcess/API/C/WKFrame.cpp:
3749         (WKFrameCopyChildFrames): Deleted.
3750         (WKFrameGetParentFrame): Deleted.
3751         * UIProcess/API/C/WKFrame.h:
3752
3753 2015-10-08  Michael Catanzaro  <mcatanzaro@igalia.com>
3754
3755         Format string issues in NetworkCache.cpp
3756         https://bugs.webkit.org/show_bug.cgi?id=149867
3757
3758         Reviewed by Csaba Osztrogonác.
3759
3760         Cast enums to ints before printing them to placate GCC's -Wformat.
3761
3762         * NetworkProcess/cache/NetworkCache.cpp:
3763         (WebKit::NetworkCache::Cache::retrieve):
3764         (WebKit::NetworkCache::Cache::store):
3765
3766 2015-10-08  Michael Catanzaro  <mcatanzaro@igalia.com>
3767
3768         Format string issue in WebResourceLoadScheduler.cpp
3769         https://bugs.webkit.org/show_bug.cgi?id=149868
3770
3771         Reviewed by Csaba Osztrogonác.
3772
3773         Cast enums to ints before printing them to placate GCC's -Wformat.
3774
3775         * WebProcess/Network/WebResourceLoadScheduler.cpp:
3776         (WebKit::WebResourceLoadScheduler::scheduleLoad):
3777
3778 2015-10-08  Carlos Garcia Campos  <cgarcia@igalia.com>
3779
3780         [GTK] Stop using a nested main loop for popup menus
3781         https://bugs.webkit.org/show_bug.cgi?id=149920
3782
3783         Reviewed by Sergio Villar Senin.
3784
3785         WebPageProxy used to expect the popup menus to run in a nested
3786         main loop and invalidated the menu right after showing it. But
3787         this is no longer the case, so there's no reason to keep using
3788         the nested main loop.
3789
3790         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
3791         (WebKit::WebPopupMenuProxyGtk::~WebPopupMenuProxyGtk):
3792         (WebKit::WebPopupMenuProxyGtk::cancelTracking):
3793         (WebKit::WebPopupMenuProxyGtk::menuItemActivated):
3794         (WebKit::WebPopupMenuProxyGtk::WebPopupMenuProxyGtk): Deleted.
3795         (WebKit::WebPopupMenuProxyGtk::showPopupMenu): Deleted.
3796         (WebKit::WebPopupMenuProxyGtk::shutdownRunLoop): Deleted.
3797         (WebKit::WebPopupMenuProxyGtk::menuUnmapped): Deleted.
3798         * UIProcess/gtk/WebPopupMenuProxyGtk.h:
3799         (WebKit::WebPopupMenuProxyGtk::setActiveItem): Deleted.
3800
3801 2015-10-07  Anders Carlsson  <andersca@apple.com>
3802
3803         Add API for getting a group identifier from a bundle page
3804         https://bugs.webkit.org/show_bug.cgi?id=149902
3805
3806         Reviewed by Tim Horton.
3807
3808         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
3809         (WKBundlePageCopyGroupIdentifier):
3810         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
3811
3812 2015-10-07  Csaba Osztrogonác  <ossy@webkit.org>
3813
3814         URTBF after r190678 to fix GTK and EFL builds.
3815
3816         * WebProcess/InjectedBundle/efl/InjectedBundleEfl.cpp:
3817         (WebKit::InjectedBundle::setBundleParameters):
3818         * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
3819         (WebKit::InjectedBundle::setBundleParameters):
3820
3821 2015-10-07  Commit Queue  <commit-queue@webkit.org>
3822
3823         Unreviewed, rolling out r190572, r190593, r190594, and
3824         r190639.
3825         https://bugs.webkit.org/show_bug.cgi?id=149897
3826
3827         Breaks Mavericks build (Requested by litherum on #webkit).
3828
3829         Reverted changesets:
3830
3831         "Allow WKRetainPtrs to be used as keys in hashing data
3832         structures"
3833         https://bugs.webkit.org/show_bug.cgi?id=149762
3834         http://trac.webkit.org/changeset/190572
3835
3836         "REGRESSION(189668?): http/tests/notifications/events.html
3837         flakily asserts or times out"
3838         https://bugs.webkit.org/show_bug.cgi?id=149218
3839         http://trac.webkit.org/changeset/190593
3840
3841         "Prospective Mavericks build fix."
3842         http://trac.webkit.org/changeset/190594
3843
3844         "Post-review cleanup after r190572."
3845         http://trac.webkit.org/changeset/190639
3846
3847 2015-10-07  Anders Carlsson  <andersca@apple.com>
3848
3849         Provide a way to get a WKFrameInfoRef from a WKFrameRef
3850         https://bugs.webkit.org/show_bug.cgi?id=149896
3851         rdar://problem/23016081
3852
3853         Reviewed by Dan Bernstein.
3854
3855         * UIProcess/API/C/WKFrame.cpp:
3856         (WKFrameCreateFrameInfo):
3857         * UIProcess/API/C/WKFrame.h:
3858
3859 2015-10-07  Anders Carlsson  <andersca@apple.com>
3860
3861         Add unreachable URL to _WKObservablePageState
3862         https://bugs.webkit.org/show_bug.cgi?id=149893
3863         <rdar://problem/23017235>
3864  
3865         Reviewed by Dan Bernstein.
3866
3867         * UIProcess/API/C/mac/WKPagePrivateMac.h:
3868         * UIProcess/API/C/mac/WKPagePrivateMac.mm:
3869         (-[WKObservablePageState unreachableURL]):
3870
3871 2015-10-07  Anders Carlsson  <andersca@apple.com>
3872
3873         Add -[WKProcessPool _setObjectsForBundleParametersWithDictionary:]
3874         https://bugs.webkit.org/show_bug.cgi?id=149887
3875
3876         Reviewed by Tim Horton.
3877
3878         * UIProcess/API/Cocoa/WKProcessPool.mm:
3879         (-[WKProcessPool _setObjectsForBundleParametersWithDictionary:]):
3880         Copy the dictionary, archive it, and set the values on the UI side bundle parameter data struct.
3881
3882         * UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
3883         Add new SPI.
3884
3885         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h:
3886         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm:
3887         (-[WKWebProcessBundleParameters setParameter:forKey:]):
3888         We can just call setValue:forKey: on the dictionary; it will do the right thing if value is nil.
3889
3890         (-[WKWebProcessBundleParameters setParametersForKeyWithDictionary:]):
3891         Enumerate the dictionary and call setValue:forKey: on each key/value pair.
3892
3893         * WebProcess/InjectedBundle/InjectedBundle.h:
3894         * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
3895         (WebKit::InjectedBundle::setBundleParameter):
3896         If we fail to unarchive a parameter, don't set it to null.
3897
3898         (WebKit::InjectedBundle::setBundleParameters):
3899         Unarchive the dictionary and update the bundle parameters.
3900
3901         * WebProcess/WebProcess.cpp:
3902         (WebKit::WebProcess::setInjectedBundleParameters):
3903         Call the injected bundle.
3904
3905         * WebProcess/WebProcess.h:
3906         * WebProcess/WebProcess.messages.in:
3907         Add new message.
3908
3909 2015-10-06  Anders Carlsson  <andersca@apple.com>
3910
3911         Expose the bundle parameter object on WKBundleRef
3912         https://bugs.webkit.org/show_bug.cgi?id=149860
3913
3914         Reviewed by Tim Horton.
3915
3916         * WebKit2.xcodeproj/project.pbxproj:
3917         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm:
3918         (-[WKWebProcessBundleParameters description]):
3919         Add a description that includes the parameters.
3920
3921         * WebProcess/InjectedBundle/API/c/mac/WKBundleMac.h:
3922         * WebProcess/InjectedBundle/API/c/mac/WKBundleMac.mm:
3923         (WKBundleGetParameters):
3924         Add getter.
3925
3926         * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
3927         (WebKit::InjectedBundle::initialize):
3928         Make sure to decode the bundle parameters before calling out to the bundle.
3929
3930 2015-10-06  Michael Catanzaro  <mcatanzaro@igalia.com>
3931
3932         [GTK] Add autocleanups
3933         https://bugs.webkit.org/show_bug.cgi?id=149588
3934
3935         Reviewed by Darin Adler.
3936
3937         * PlatformGTK.cmake:
3938         * UIProcess/API/gtk/WebKitAutocleanups.h: Added.
3939         * UIProcess/API/gtk/webkit2.h:
3940         * WebProcess/InjectedBundle/API/gtk/WebKitWebExtensionAutocleanups.h: Added.
3941         * WebProcess/InjectedBundle/API/gtk/webkit-web-extension.h:
3942
3943 2015-10-06  Anders Carlsson  <andersca@apple.com>
3944
3945         Try to fix the 32-bit build.
3946
3947         * UIProcess/API/C/mac/WKPagePrivateMac.mm:
3948
3949 2015-10-06  Anders Carlsson  <andersca@apple.com>
3950
3951         WKPage needs to expose a KVO-compliant object, similar to WKWebView
3952         https://bugs.webkit.org/show_bug.cgi?id=149851
3953         rdar://problem/22382022
3954
3955         Reviewed by Dan Bernstein.
3956
3957         Move the PageLoadStateObserver object from WKBrowsingContextController out into a separate file and make it
3958         work with any Objective-C object. Use it in WKObservablePageState and add a WKPageCreateObservableState function.
3959
3960         * UIProcess/API/C/mac/WKPagePrivateMac.h:
3961         * UIProcess/API/C/mac/WKPagePrivateMac.mm: Renamed from Source/WebKit2/UIProcess/API/C/mac/WKPagePrivateMac.cpp.
3962         (-[WKObservablePageState initWithPage:]):
3963         (-[WKObservablePageState dealloc]):
3964         (-[WKObservablePageState isLoading]):
3965         (-[WKObservablePageState title]):
3966         (-[WKObservablePageState URL]):
3967         (-[WKObservablePageState hasOnlySecureContent]):
3968         (-[WKObservablePageState estimatedProgress]):
3969         (WKPageCreateObservableState):
3970         (WKPageGetProcessIdentifier):
3971         (WKPageIsURLKnownHSTSHost):
3972         * UIProcess/API/Cocoa/PageLoadStateObserver.h: Added.
3973         (WebKit::PageLoadStateObserver::PageLoadStateObserver):
3974         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
3975         (PageLoadStateObserver::PageLoadStateObserver): Deleted.
3976         * WebKit2.xcodeproj/project.pbxproj:
3977
3978 2015-10-06  Daniel Bates  <dbates@webkit.org>
3979
3980         Enable XSLT when building WebKit for iOS using the public iOS SDK
3981         https://bugs.webkit.org/show_bug.cgi?id=149827
3982
3983         Reviewed by Alexey Proskuryakov.
3984
3985         * Configurations/FeatureDefines.xcconfig:
3986
3987 2015-10-06  Emanuele Aina  <emanuele.aina@collabora.com>
3988
3989         Fix ENABLE_OPENGL=OFF builds
3990         https://bugs.webkit.org/show_bug.cgi?id=146511
3991
3992         Reviewed by Darin Adler.
3993
3994         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
3995         (webkitWebViewBaseRealize):
3996         (webkitWebViewBaseDraw):
3997         (webkitWebViewBaseDidRelaunchWebProcess):
3998         Replace USE(TEXTURE_MAPPER_GL) with USE(TEXTURE_MAPPER) around
3999         webkitWebViewRenderAcceleratedCompositingResults()
4000         * UIProcess/DrawingAreaProxyImpl.cpp:
4001         * UIProcess/DrawingAreaProxyImpl.h:
4002         * WebProcess/WebPage/DrawingArea.cpp:
4003         (WebKit::DrawingArea::DrawingArea):
4004         * WebProcess/WebPage/DrawingArea.h:
4005         * WebProcess/WebPage/LayerTreeHost.h:
4006         Replace USE(TEXTURE_MAPPER_GL) with USE(TEXTURE_MAPPER) around
4007         setNativeSurfaceHandleForCompositing().
4008         * UIProcess/gtk/WebPreferencesGtk.cpp:
4009         (WebKit::WebPreferences::platformInitializeStore):
4010         Default to no AC if no GL support has been built.
4011         * WebProcess/WebPage/DrawingArea.messages.in:
4012         Replace USE(TEXTURE_MAPPER_GL) with USE(TEXTURE_MAPPER) around
4013         SetNativeSurfaceHandleForCompositing.
4014         * WebProcess/WebPage/DrawingAreaImpl.h:
4015         * WebProcess/WebPage/DrawingAreaImpl.cpp:
4016         (WebKit::DrawingAreaImpl::enterAcceleratedCompositingMode):
4017         Replace USE(TEXTURE_MAPPER_GL) with USE(TEXTURE_MAPPER) around
4018         setNativeSurfaceHandleForCompositing().
4019         (WebKit::DrawingAreaImpl::setNativeSurfaceHandleForCompositing):
4020         Force setAcceleratedCompositingEnabled() only if a LayerTreeHost
4021         implementation is available, to avoid crashing when building without
4022         any GL support.
4023
4024 2015-10-06  Csaba Osztrogonác  <ossy@webkit.org>
4025
4026         URTBF after r190611.
4027
4028         * CMakeLists.txt:
4029
4030 2015-10-06  Alex Christensen  <achristensen@webkit.org>
4031
4032         Report error when main resource is blocked by content blocker
4033         https://bugs.webkit.org/show_bug.cgi?id=149719
4034         rdar://problem/21970595
4035
4036         Reviewed by Brady Eidson.
4037
4038         * Shared/API/c/WKErrorRef.h:
4039         * WebProcess/WebCoreSupport/WebErrors.h:
4040         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
4041         (WebKit::WebFrameLoaderClient::blockedError):
4042         (WebKit::WebFrameLoaderClient::blockedByContentBlockerError):
4043         (WebKit::WebFrameLoaderClient::cannotShowURLError):
4044         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
4045         * WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp:
4046         (WebKit::blockedError):
4047         (WebKit::blockedByContentBlockerError):
4048         (WebKit::cannotShowURLError):
4049         * WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp:
4050         (WebKit::blockedError):
4051         (WebKit::blockedByContentBlockerError):
4052         (WebKit::cannotShowURLError):
4053         * WebProcess/WebCoreSupport/mac/WebErrorsMac.mm: