58070667debe29935e6964102479fb48df8b79a5
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2014-01-24  Víctor Manuel Jáquez Leal  <vjaquez@igalia.com>
2
3         [GTK] youtube HTML5 videos in fullscreen, after <Esc>, can't go fullscreen again
4         https://bugs.webkit.org/show_bug.cgi?id=127064
5
6         When pressing <Esc> or <f> at full screen, the WebView shall emit the
7         event webkitfullscreenchange, but wk2gtk does not emit it. This is
8         because the WebView manages directly the exit of the full screen.
9
10         With this patch the WebView calls requestExitFullScreen to the full
11         screen manager, instead of managing directly the exit of the full
12         screen, and the event webkitfullscreenchange will be dispatched
13         correctly.
14
15         Reviewed by Martin Robinson.
16
17         No tests are included because there is a bug in WKTR that prevents the
18         execution of a test for this patch. See
19         https://bugs.webkit.org/show_bug.cgi?id=127348
20
21         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
22         (webkitWebViewBaseKeyPressEvent): Call
23         webkitWebViewBaseRequestExitFullScreen.
24         (webkitWebViewBaseRequestExitFullScreen): Added.
25         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h: Ditto.
26
27 2014-01-24  Tim Horton  <timothy_horton@apple.com>
28
29         iOS build fix after r162710.
30
31         This is why these sorts of comments are bad.
32
33         * UIProcess/WebPageProxy.cpp:
34
35 2014-01-24  Anders Carlsson  <andersca@apple.com>
36
37         Use a side table to map WebPageProxy objects to WKBrowsingContextController objects
38         https://bugs.webkit.org/show_bug.cgi?id=127577
39
40         Reviewed by Tim Horton.
41
42         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
43         (browsingContextControllerMap):
44         (-[WKBrowsingContextController dealloc]):
45         (-[WKBrowsingContextController _initWithPageRef:]):
46         (+[WKBrowsingContextController _browsingContextControllerForPageRef:]):
47         * UIProcess/API/Cocoa/WKBrowsingContextControllerInternal.h:
48         * UIProcess/WebPageProxy.h:
49
50 2014-01-24  Tim Horton  <timothy_horton@apple.com>
51
52         iOS build fix after r162710.
53
54         * UIProcess/API/ios/PageClientImplIOS.h:
55         * UIProcess/API/ios/PageClientImplIOS.mm:
56         (WebKit::PageClientImpl::takeViewSnapshot):
57
58 2014-01-24  Enrique Ocaña González  <eocanha@igalia.com>
59
60         [GTK] Put cache files in XDG_CACHE_HOME
61         https://bugs.webkit.org/show_bug.cgi?id=123458
62
63         Reviewed by Martin Robinson.
64
65         * UIProcess/gtk/WebContextGtk.cpp:
66         (WebKit::WebContext::platformDefaultIconDatabasePath):
67
68 2014-01-24  Tim Horton  <timothy_horton@apple.com>
69
70         WebKit2 View Gestures (Swipe): Add a simple cache of view snapshots
71         https://bugs.webkit.org/show_bug.cgi?id=127438
72
73         Reviewed by Sam Weinig.
74
75         Add a cache of bitmap snapshots of the WKView, taken via OS X's window server
76         snapshotting mechanism. For now, we store all snapshots; refinements to the
77         caching strategy (or really having one at all) will come in future patches.
78
79         Snapshots are stored in a side map, with a UUID that allows references
80         to be stored inside WebBackForwardListItem (and serialized along with
81         the back-forward list when it is copied).
82
83         * Shared/WebBackForwardListItem.h:
84         (WebKit::WebBackForwardListItem::setSnapshotUUID):
85         (WebKit::WebBackForwardListItem::snapshotUUID):
86         * UIProcess/cf/WebBackForwardListCF.cpp:
87         (WebKit::WebBackForwardList::createCFDictionaryRepresentation):
88         (WebKit::extractBackForwardListEntriesFromArray):
89         Store and serialize a UUID along with each back-forward list item which
90         identifies that item's view snapshot in the ViewSnapshotStore.
91
92         * UIProcess/cf/WebPageProxyCF.cpp:
93         Bump the session state data version, as we changed the WebBackForwardList format.
94
95         * UIProcess/API/Cocoa/WKViewPrivate.h:
96         * UIProcess/API/mac/PageClientImpl.h:
97         * UIProcess/API/mac/PageClientImpl.mm:
98         (WebKit::PageClientImpl::takeViewSnapshot):
99
100         * UIProcess/API/mac/WKView.mm:
101         (-[WKView _takeViewSnapshot]):
102         Add _takeViewSnapshot IPI, which is used by ViewSnapshotStore via the PageClient
103         to take a snapshot of the view.
104
105         (-[WKView saveBackForwardSnapshotForCurrentItem]):
106         Add saveBackForwardSnapshotForCurrentItem SPI, which clients could potentially
107         use when they know they're about to manipulate the view hierarchy in such a way
108         that they want the current back-forward item's snapshot to be up to date.
109
110         * UIProcess/API/mac/WKViewInternal.h:
111         * UIProcess/PageClient.h:
112         * UIProcess/WebPageProxy.cpp:
113         (WebKit::WebPageProxy::WebPageProxy):
114         (WebKit::WebPageProxy::recordNavigationSnapshot):
115         (WebKit::WebPageProxy::goForward):
116         (WebKit::WebPageProxy::goBack):
117         (WebKit::WebPageProxy::goToBackForwardItem):
118         (WebKit::WebPageProxy::didStartProvisionalLoadForFrame):
119         Update the current back-forward item's snapshot immediately before navigating.
120
121         * UIProcess/WebPageProxy.h:
122         (WebKit::WebPageProxy::shouldRecordNavigationSnapshots):
123         (WebKit::WebPageProxy::setShouldRecordNavigationSnapshots):
124         Expose the ability to enable taking view snapshots on every navigation.
125         This is off by default, so we won't be taking any snapshots yet.
126
127         * UIProcess/mac/ViewSnapshotStore.h: Added.
128         (WebKit::ViewSnapshotStore::disableSnapshotting):
129         (WebKit::ViewSnapshotStore::enableSnapshotting):
130         * UIProcess/mac/ViewSnapshotStore.mm: Added.
131         (WebKit::ViewSnapshotStore::ViewSnapshotStore):
132         (WebKit::ViewSnapshotStore::~ViewSnapshotStore):
133         (WebKit::ViewSnapshotStore::shared):
134         (WebKit::ViewSnapshotStore::recordSnapshot):
135         (WebKit::ViewSnapshotStore::snapshotAndRenderTreeSize):
136         * UIProcess/mac/WebPageProxyMac.mm:
137         (WebKit::WebPageProxy::takeViewSnapshot):
138         * WebKit2.xcodeproj/project.pbxproj:
139
140 2014-01-24  Brady Eidson  <beidson@apple.com>
141
142         IDB: support createIndex/deleteIndex messaging
143         https://bugs.webkit.org/show_bug.cgi?id=127546
144
145         Reviewed by Tim Horton.
146
147         Message create/delete requests over to the DatabaseProcess, and listen to its replies:
148         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
149         (WebKit::WebIDBServerConnection::createIndex):
150         (WebKit::WebIDBServerConnection::didCreateIndex):
151         (WebKit::WebIDBServerConnection::deleteIndex):
152         (WebKit::WebIDBServerConnection::didDeleteIndex):
153         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
154         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:
155
156         Pass create/delete requests to the appropriate unique IDB database:
157         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
158         (WebKit::DatabaseProcessIDBConnection::createIndex):
159         (WebKit::DatabaseProcessIDBConnection::deleteIndex):
160         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
161         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
162
163         Message the create/delete request to the database thread for the backing store to handle:
164         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
165         (WebKit::UniqueIDBDatabase::didCreateIndex):
166         (WebKit::UniqueIDBDatabase::didDeleteIndex):
167         (WebKit::UniqueIDBDatabase::createIndex):
168         (WebKit::UniqueIDBDatabase::deleteIndex):
169         (WebKit::UniqueIDBDatabase::createIndexInBackingStore):
170         (WebKit::UniqueIDBDatabase::deleteIndexInBackingStore):
171         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
172
173         * Scripts/webkit2/messages.py:
174         (struct_or_class):
175
176 2014-01-24  Csaba Osztrogonác  <ossy@webkit.org>
177
178         [EFL][WK2] Debug buildfix
179         https://bugs.webkit.org/show_bug.cgi?id=127496
180
181         Reviewed by Gyuyoung Kim.
182
183         * Shared/SessionTracker.cpp:
184
185 2014-01-23  Brady Eidson  <beidson@apple.com>
186
187         IDB: Support IDBObjectStore.clear()
188         https://bugs.webkit.org/show_bug.cgi?id=127541
189
190         Reviewed by Anders Carlsson.
191
192         Make the WebProcess call out to the DatabaseProcess with a clear request, and handle the
193         response from the DatabaseProcess:
194         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
195         (WebKit::WebIDBServerConnection::clearObjectStore):
196         (WebKit::WebIDBServerConnection::didClearObjectStore):
197         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
198         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:
199
200         Pass the clear request to the appropriate UniqueIDBDatabase:
201         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
202         (WebKit::DatabaseProcessIDBConnection::clearObjectStore):
203         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
204         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
205
206         Pass the clear request to the backing store:
207         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
208         (WebKit::UniqueIDBDatabase::didClearObjectStore):
209         (WebKit::UniqueIDBDatabase::clearObjectStore):
210         (WebKit::UniqueIDBDatabase::clearObjectStoreInBackingStore):
211         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
212
213         Actually drop the records in the database:
214         * DatabaseProcess/IndexedDB/UniqueIDBDatabaseBackingStore.h:
215         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
216         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::clearObjectStore):
217         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
218
219 2014-01-23  Anders Carlsson  <andersca@apple.com>
220
221         Fix crash when opening the inspector
222         https://bugs.webkit.org/show_bug.cgi?id=127542
223         <rdar://problem/15899544>
224
225         Reviewed by Joseph Pecoraro.
226
227         Create default clients so we won't crash if they're never set.
228
229         * UIProcess/WebPageProxy.cpp:
230         (WebKit::WebPageProxy::WebPageProxy):
231
232 2014-01-23  Ryuan Choi  <ryuan.choi@samsung.com>
233
234         Unreviewed build fix attemp on the EFL and GTK build after r162678
235
236         * CMakeLists.txt: Removed WebPolicyClient.cpp
237         * GNUmakefile.list.am: Removed WebPolicyClient.cpp and WebPolicyClient.h
238
239 2014-01-23  Yongjun Zhang  <yongjun_zhang@apple.com>
240
241         Support NSInteger argument type for encoding/decoding invocations.
242         https://bugs.webkit.org/show_bug.cgi?id=127522
243
244         Reviewed by Dan Bernstein.
245
246         Add support for NSInteger argument type ('q') for remote invocations.
247
248         * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
249         (encodeInvocation):
250         (decodeInvocationArguments):
251
252 2014-01-23  Brady Eidson  <beidson@apple.com>
253
254         IDB: Implement SQLite backing store 'get' support
255         https://bugs.webkit.org/show_bug.cgi?id=127502
256
257         Reviewed by Tim Horton.
258
259         This makes get of a single IDBKey work, and lays the groundwork for getting an IDBKeyRange.
260
261         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
262         (WebKit::UniqueIDBDatabase::getRecordFromBackingStore):
263         * DatabaseProcess/IndexedDB/UniqueIDBDatabaseBackingStore.h:
264
265         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
266         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createAndPopulateInitialMetadata): Add custom collation
267           to the Records table.
268         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::getOrEstablishMetadata): Install the custom collator.
269         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::getKeyRecordFromObjectStore):
270         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::getKeyRangeRecordFromObjectStore):
271         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::collate): Collation function to be filled in later.
272         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
273
274 2014-01-23  Jon Honeycutt  <jhoneycutt@apple.com>
275
276         Assertion failure in WebCore::PseudoElement::didRecalcStyle()
277         <https://bugs.webkit.org/show_bug.cgi?id=126761>
278         <rdar://problem/15793540>
279
280         Reviewed by Andy Estes.
281
282         * WebProcess/WebPage/ios/WebPageIOS.mm:
283         (WebKit::WebPage::getPositionInformation):
284         Check isRenderImage() rather than isImage() before casting to
285         RenderImage.
286
287 2014-01-23  Anders Carlsson  <andersca@apple.com>
288
289         Move policy client into WKPage.cpp and get rid of WebPolicyClient files
290         https://bugs.webkit.org/show_bug.cgi?id=127536
291
292         Reviewed by Tim Horton.
293
294         * UIProcess/API/C/WKPage.cpp:
295         (WKPageSetPagePolicyClient):
296         * UIProcess/WebPolicyClient.cpp: Removed.
297         * UIProcess/WebPolicyClient.h: Removed.
298         * WebKit2.xcodeproj/project.pbxproj:
299
300 2014-01-23  Joseph Pecoraro  <pecoraro@apple.com>
301
302         Web Inspector: Remove recompileAllJSFunctions timer in ScriptDebugServer
303         https://bugs.webkit.org/show_bug.cgi?id=127409
304
305         Reviewed by Geoffrey Garen.
306
307         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
308         (WebKit::WebInspectorFrontendClient::closeWindow):
309         * WebProcess/WebPage/WebInspector.cpp:
310         (WebKit::WebInspector::remoteFrontendDisconnected):
311         Include InspectorDisconnectReason.
312
313 2014-01-23  Anders Carlsson  <andersca@apple.com>
314
315         Only WKPage should know about WebPolicyClient
316         https://bugs.webkit.org/show_bug.cgi?id=127535
317
318         Reviewed by Andreas Kling.
319
320         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
321         (setUpPagePolicyClient):
322         (-[WKBrowsingContextController setPolicyDelegate:]):
323         * UIProcess/WebInspectorProxy.cpp:
324         (WebKit::WebInspectorProxy::createInspectorPage):
325
326 2014-01-23  Anders Carlsson  <andersca@apple.com>
327
328         Simplify API::LoaderClient management
329         https://bugs.webkit.org/show_bug.cgi?id=127531
330
331         Reviewed by Tim Horton.
332
333         Add default implementations to API::LoaderClient and change WebPageProxy::setLoaderClient to
334         always create a policy client, even if the loader client set is null. That way we don't have to null
335         check the loader client everywhere.
336
337         * UIProcess/API/APILoaderClient.h:
338         (API::LoaderClient::didStartProvisionalLoadForFrame):
339         (API::LoaderClient::didReceiveServerRedirectForProvisionalLoadForFrame):
340         (API::LoaderClient::didFailProvisionalLoadWithErrorForFrame):
341         (API::LoaderClient::didCommitLoadForFrame):
342         (API::LoaderClient::didFinishDocumentLoadForFrame):
343         (API::LoaderClient::didFinishLoadForFrame):
344         (API::LoaderClient::didFailLoadWithErrorForFrame):
345         (API::LoaderClient::didSameDocumentNavigationForFrame):
346         (API::LoaderClient::didReceiveTitleForFrame):
347         (API::LoaderClient::didFirstLayoutForFrame):
348         (API::LoaderClient::didFirstVisuallyNonEmptyLayoutForFrame):
349         (API::LoaderClient::didRemoveFrameFromHierarchy):
350         (API::LoaderClient::didDisplayInsecureContentForFrame):
351         (API::LoaderClient::didRunInsecureContentForFrame):
352         (API::LoaderClient::didDetectXSSForFrame):
353         (API::LoaderClient::didLayout):
354         (API::LoaderClient::canAuthenticateAgainstProtectionSpaceInFrame):
355         (API::LoaderClient::didReceiveAuthenticationChallengeInFrame):
356         (API::LoaderClient::didStartProgress):
357         (API::LoaderClient::didChangeProgress):
358         (API::LoaderClient::didFinishProgress):
359         (API::LoaderClient::processDidBecomeUnresponsive):
360         (API::LoaderClient::interactionOccurredWhileProcessUnresponsive):
361         (API::LoaderClient::processDidBecomeResponsive):
362         (API::LoaderClient::processDidCrash):
363         (API::LoaderClient::didChangeBackForwardList):
364         (API::LoaderClient::willGoToBackForwardListItem):
365         (API::LoaderClient::pluginLoadPolicy):
366         (API::LoaderClient::didFailToInitializePlugin):
367         (API::LoaderClient::didBlockInsecurePluginVersion):
368         (API::LoaderClient::webGLLoadPolicy):
369         * UIProcess/WebPageProxy.cpp:
370         (WebKit::WebPageProxy::setLoaderClient):
371         (WebKit::WebPageProxy::didChangeBackForwardList):
372         (WebKit::WebPageProxy::willGoToBackForwardListItem):
373         (WebKit::WebPageProxy::findPlugin):
374         (WebKit::WebPageProxy::didStartProgress):
375         (WebKit::WebPageProxy::didChangeProgress):
376         (WebKit::WebPageProxy::didFinishProgress):
377         (WebKit::WebPageProxy::didStartProvisionalLoadForFrame):
378         (WebKit::WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame):
379         (WebKit::WebPageProxy::didFailProvisionalLoadForFrame):
380         (WebKit::WebPageProxy::didCommitLoadForFrame):
381         (WebKit::WebPageProxy::didFinishDocumentLoadForFrame):
382         (WebKit::WebPageProxy::didFinishLoadForFrame):
383         (WebKit::WebPageProxy::didFailLoadForFrame):
384         (WebKit::WebPageProxy::didSameDocumentNavigationForFrame):
385         (WebKit::WebPageProxy::didReceiveTitleForFrame):
386         (WebKit::WebPageProxy::didFirstLayoutForFrame):
387         (WebKit::WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame):
388         (WebKit::WebPageProxy::didLayout):
389         (WebKit::WebPageProxy::didRemoveFrameFromHierarchy):
390         (WebKit::WebPageProxy::didDisplayInsecureContentForFrame):
391         (WebKit::WebPageProxy::didRunInsecureContentForFrame):
392         (WebKit::WebPageProxy::didDetectXSSForFrame):
393         (WebKit::WebPageProxy::webGLPolicyForURL):
394         (WebKit::WebPageProxy::processDidBecomeUnresponsive):
395         (WebKit::WebPageProxy::interactionOccurredWhileProcessUnresponsive):
396         (WebKit::WebPageProxy::processDidBecomeResponsive):
397         (WebKit::WebPageProxy::processDidCrash):
398         (WebKit::WebPageProxy::canAuthenticateAgainstProtectionSpaceInFrame):
399         (WebKit::WebPageProxy::didReceiveAuthenticationChallengeProxy):
400         (WebKit::WebPageProxy::didFailToInitializePlugin):
401         (WebKit::WebPageProxy::didBlockInsecurePluginVersion):
402
403 2014-01-23  Anders Carlsson  <andersca@apple.com>
404
405         Simplify API::PolicyClient management
406         https://bugs.webkit.org/show_bug.cgi?id=127529
407
408         Reviewed by Tim Horton.
409
410         Add default implementations to API::PolicyClient and change WebPageProxy::setPolicyClient to
411         always create a policy client, even if the policy object set is null. That way we don't have to null
412         check the policy client everywhere.
413
414         * UIProcess/API/APIPolicyClient.h:
415         (API::PolicyClient::decidePolicyForNavigationAction):
416         (API::PolicyClient::decidePolicyForNewWindowAction):
417         (API::PolicyClient::decidePolicyForResponse):
418         (API::PolicyClient::unableToImplementPolicy):
419         * UIProcess/WebPageProxy.cpp:
420         (WebKit::WebPageProxy::setPolicyClient):
421         (WebKit::WebPageProxy::decidePolicyForNavigationAction):
422         (WebKit::WebPageProxy::decidePolicyForNewWindowAction):
423         (WebKit::WebPageProxy::decidePolicyForResponse):
424         (WebKit::WebPageProxy::unableToImplementPolicy):
425
426 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
427
428         Fix GTK.
429
430         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
431         (webkitWebPageDidReceiveMessage):
432
433 2014-01-23  Anders Carlsson  <andersca@apple.com>
434
435         Add an APILoaderClient base class
436         https://bugs.webkit.org/show_bug.cgi?id=127527
437
438         Reviewed by Tim Horton.
439
440         * UIProcess/API/APILoaderClient.h: Added.
441         (API::LoaderClient::~LoaderClient):
442         * UIProcess/API/C/WKPage.cpp:
443         (WKPageSetPageLoaderClient):
444         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
445         (setUpPageLoaderClient):
446         (-[WKBrowsingContextController setLoadDelegate:]):
447         (+[WKBrowsingContextController _browsingContextControllerForPageRef:]):
448         * UIProcess/WebLoaderClient.cpp:
449         (WebKit::WebLoaderClient::WebLoaderClient):
450         * UIProcess/WebLoaderClient.h:
451         * UIProcess/WebPageProxy.cpp:
452         (WebKit::WebPageProxy::setLoaderClient):
453         (WebKit::WebPageProxy::close):
454         (WebKit::WebPageProxy::didChangeBackForwardList):
455         (WebKit::WebPageProxy::willGoToBackForwardListItem):
456         (WebKit::WebPageProxy::findPlugin):
457         (WebKit::WebPageProxy::didStartProgress):
458         (WebKit::WebPageProxy::didChangeProgress):
459         (WebKit::WebPageProxy::didFinishProgress):
460         (WebKit::WebPageProxy::didStartProvisionalLoadForFrame):
461         (WebKit::WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame):
462         (WebKit::WebPageProxy::didFailProvisionalLoadForFrame):
463         (WebKit::WebPageProxy::didCommitLoadForFrame):
464         (WebKit::WebPageProxy::didFinishDocumentLoadForFrame):
465         (WebKit::WebPageProxy::didFinishLoadForFrame):
466         (WebKit::WebPageProxy::didFailLoadForFrame):
467         (WebKit::WebPageProxy::didSameDocumentNavigationForFrame):
468         (WebKit::WebPageProxy::didReceiveTitleForFrame):
469         (WebKit::WebPageProxy::didFirstLayoutForFrame):
470         (WebKit::WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame):
471         (WebKit::WebPageProxy::didLayout):
472         (WebKit::WebPageProxy::didRemoveFrameFromHierarchy):
473         (WebKit::WebPageProxy::didDisplayInsecureContentForFrame):
474         (WebKit::WebPageProxy::didRunInsecureContentForFrame):
475         (WebKit::WebPageProxy::didDetectXSSForFrame):
476         (WebKit::WebPageProxy::webGLPolicyForURL):
477         (WebKit::WebPageProxy::processDidBecomeUnresponsive):
478         (WebKit::WebPageProxy::interactionOccurredWhileProcessUnresponsive):
479         (WebKit::WebPageProxy::processDidBecomeResponsive):
480         (WebKit::WebPageProxy::processDidCrash):
481         (WebKit::WebPageProxy::canAuthenticateAgainstProtectionSpaceInFrame):
482         (WebKit::WebPageProxy::didReceiveAuthenticationChallengeProxy):
483         (WebKit::WebPageProxy::didFailToInitializePlugin):
484         (WebKit::WebPageProxy::didBlockInsecurePluginVersion):
485         * UIProcess/WebPageProxy.h:
486         (WebKit::WebPageProxy::loaderClient):
487         * WebKit2.xcodeproj/project.pbxproj:
488
489 2014-01-23  Ryuan Choi  <ryuan.choi@samsung.com>
490
491         Build break after r162650
492         https://bugs.webkit.org/show_bug.cgi?id=127525
493
494         Reviewed by Anders Carlsson.
495
496         WKPreferences.h was renamed to WKPreferencesRef.
497
498         * UIProcess/API/C/WKPreferences.cpp:
499
500 2014-01-23  Anders Carlsson  <andersca@apple.com>
501
502         Fix a refactoring bug that crept in and is causing the inspector to crash.
503
504         * UIProcess/WebPolicyClient.cpp:
505         (WebKit::WebPolicyClient::decidePolicyForResponse):
506
507 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
508
509         Make visibleContentRect() return actualVisibleContentRect() on iOS most of the time
510         https://bugs.webkit.org/show_bug.cgi?id=127456
511         
512         Reviewed by Antti Koivisto.
513         
514         On iOS, visibleContentRect() returns the entire document rect for historical
515         reasons, and actualVisibleContentRect() returns what visibleContentRect()
516         returns on other platforms.
517         
518         In addition, actualVisibleContentRect() was returning an empty rect in WK2.
519         
520         Reduce the confusion of #ifdefs by making visibleContentRect() behave like
521         actualVisibleContentRect() by default on iOS. Where it needs the old behavior,
522         an optional parameter, LegacyIOSDocumentVisibleRect, provides this.
523         
524         Achieve this by having the virtual ScrollableArea::visibleContentRectInternal(),
525         which is called by non-virtual visibleContentRect() and visibleContentRectIncludingScrollbars().
526         
527         Similarly clean up visibleHeight/visibleWidth functions by having visibleSize() be virtual,
528         with non-virtual visibleHeight() and visibleWidth().
529         
530         ScrollableArea subclasses override visibleContentRectInternal() and visibleSize() where necessary.
531         
532         Mechanically change all the call sites of actualVisibleContentRect() to
533         use visibleContentRect(), and the call sites of visibleContentRect()
534         to visibleContentRect(..., LegacyIOSDocumentVisibleRect), adding comments
535         where this may not be appropriate.
536         
537         Change callers of visibleContentRect(IncludeScrollbars...) to visibleContentRectIncludingScrollbars().
538         
539         Also add actualScrollPosition(), and clean up some actualScroll* call sites.
540         
541         No behavior change.
542
543         * WebProcess/Plugins/PDF/PDFPlugin.h:
544         * WebProcess/WebPage/ViewGestureGeometryCollector.cpp:
545         (WebKit::ViewGestureGeometryCollector::collectGeometryForMagnificationGesture):
546         (WebKit::ViewGestureGeometryCollector::collectGeometryForSmartMagnificationGesture):
547         * WebProcess/WebPage/WebFrame.cpp:
548         (WebKit::WebFrame::visibleContentBounds):
549         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
550         (WebKit::TiledCoreAnimationDrawingArea::commitTransientZoom):
551         (WebKit::TiledCoreAnimationDrawingArea::applyTransientZoomToPage):
552
553 2014-01-23  Tim Horton  <timothy_horton@apple.com>
554
555         [wk2] Page Overlays: Add API to clear the page overlay (and get rid of its backing store)
556         https://bugs.webkit.org/show_bug.cgi?id=127518
557
558         Reviewed by Anders Carlsson.
559
560         Add WKBundlePageOverlayClear, to allow clients of the page overlay API to
561         manually clear the page overlay's backing store, for memory, power, and performance gains.
562
563         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
564         (WKBundlePageOverlayClear):
565         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.h:
566         * WebProcess/WebPage/DrawingArea.h:
567         (WebKit::DrawingArea::clearPageOverlay):
568         * WebProcess/WebPage/PageOverlay.cpp:
569         (WebKit::PageOverlay::clear):
570         * WebProcess/WebPage/PageOverlay.h:
571         Add WKBundlePageOverlayClear and plumb it through PageOverlay to the DrawingArea.
572
573         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
574         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
575         (WebKit::RemoteLayerTreeDrawingArea::clearPageOverlay):
576         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
577         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
578         (WebKit::TiledCoreAnimationDrawingArea::clearPageOverlay):
579         Set the layer to drawsContent=false and give it 0x0 size, effectively
580         removing its backing store.
581
582 2014-01-23  Anders Carlsson  <andersca@apple.com>
583
584         Explicitly link XPC services with AppKit
585         https://bugs.webkit.org/show_bug.cgi?id=127520
586         <rdar://problem/15759718>
587
588         Reviewed by Mark Rowe.
589
590         Explicitly link XPC services that use the _NSApplicationMain run loop type with AppKit.
591
592         * Configurations/PluginService.32.xcconfig:
593         * Configurations/PluginService.64.xcconfig:
594         * Configurations/PluginService.Development.xcconfig:
595         * Configurations/WebContentService.Development.xcconfig:
596         * Configurations/WebContentService.xcconfig:
597
598 2014-01-23  Anders Carlsson  <andersca@apple.com>
599
600         Fix build again.
601
602         * UIProcess/API/mac/WKView.mm:
603         (-[WKView _windowDidChangeBackingProperties:]):
604
605 2014-01-23  Anders Carlsson  <andersca@apple.com>
606
607         Another 32-bit build fix.
608
609         * UIProcess/API/mac/WKView.mm:
610         (-[WKView _windowDidChangeBackingProperties:]):
611
612 2014-01-23  Anders Carlsson  <andersca@apple.com>
613
614         Clean up WKView.mm a little
615         https://bugs.webkit.org/show_bug.cgi?id=127517
616
617         Reviewed by Tim Horton.
618
619         Remove an unused ivar and migrate to API constants that were added in Lion.
620
621         * UIProcess/API/mac/WKView.mm:
622         (-[WKView setFrameSize:]):
623         (-[WKView addWindowObserversForWindow:]):
624         (-[WKView removeWindowObservers]):
625         (-[WKView viewDidMoveToWindow]):
626         (-[WKView _windowDidMiniaturize:]):
627         (-[WKView _windowDidResize:]):
628         (-[WKView _windowDidChangeBackingProperties:]):
629
630 2014-01-23  Anders Carlsson  <andersca@apple.com>
631
632         Try to fix the 32-bit build.
633
634         * UIProcess/API/Cocoa/WKPreferences.mm:
635
636 2014-01-23  Anders Carlsson  <andersca@apple.com>
637
638         Remove an unneeded synchronous back/forward message
639         https://bugs.webkit.org/show_bug.cgi?id=127516
640
641         Reviewed by Tim Horton.
642
643         * UIProcess/WebLoaderClient.cpp:
644         * UIProcess/WebLoaderClient.h:
645         * UIProcess/WebPageProxy.cpp:
646         (WebKit::WebPageProxy::initializeLoaderClient):
647         * UIProcess/WebPageProxy.h:
648         * UIProcess/WebPageProxy.messages.in:
649         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
650         (WebKit::WebFrameLoaderClient::shouldGoToHistoryItem):
651         * WebProcess/WebPage/WebPage.cpp:
652         (WebKit::WebPage::WebPage):
653         * WebProcess/WebPage/WebPage.h:
654         * WebProcess/WebPage/WebPage.messages.in:
655
656 2014-01-23  Anders Carlsson  <andersca@apple.com>
657
658         Rename WKPreferences.h to WKPreferencesRef.h and add a stubbed out WKPreferences class
659         https://bugs.webkit.org/show_bug.cgi?id=127512
660
661         Reviewed by Dan Bernstein.
662
663         * UIProcess/API/C/WKAPICast.h:
664         * UIProcess/API/C/WKPreferencesRef.h: Renamed from Source/WebKit2/UIProcess/API/C/WKPreferences.h.
665         * UIProcess/API/C/WebKit2_C.h:
666         * UIProcess/API/Cocoa/WKPreferences.h: Added.
667         * UIProcess/API/Cocoa/WKPreferences.mm: Added.
668         * WebKit2.xcodeproj/project.pbxproj:
669
670 2014-01-23  Max Vujovic  <mvujovic@adobe.com>
671
672         Remove CSS Custom Filters code and tests
673         https://bugs.webkit.org/show_bug.cgi?id=127382
674
675         Reviewed by Simon Fraser.
676
677         * CMakeLists.txt:
678         * Configurations/FeatureDefines.xcconfig:
679         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
680         (IPC::ArgumentCoder<WebCore::FilterOperations>::encode):
681         (IPC::ArgumentCoder<WebCore::FilterOperations>::decode):
682         (IPC::ArgumentCoder<CoordinatedGraphicsState>::encode):
683         (IPC::ArgumentCoder<CoordinatedGraphicsState>::decode):
684         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.h:
685         * Shared/CoordinatedGraphics/WebCustomFilterProgramProxy.cpp: Removed.
686         * Shared/CoordinatedGraphics/WebCustomFilterProgramProxy.h: Removed.
687         * Shared/WebCoreArgumentCoders.cpp:
688         (IPC::encodeFilterOperation):
689         (IPC::decodeFilterOperation):
690         * Shared/WebPreferencesStore.h:
691         * Shared/mac/RemoteLayerTreeTransaction.mm:
692         (WebKit::RemoteLayerTreeTextStream::operator<<):
693         * UIProcess/API/C/WKPreferences.cpp:
694         * UIProcess/API/C/WKPreferencesPrivate.h:
695         * WebProcess/InjectedBundle/InjectedBundle.cpp:
696         (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
697         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
698         (WebKit::CoordinatedLayerTreeHost::~CoordinatedLayerTreeHost):
699         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
700         * WebProcess/WebPage/WebPage.cpp:
701         (WebKit::WebPage::updatePreferences):
702         * mac/WebKit2.order:
703
704 2014-01-23  Anders Carlsson  <andersca@apple.com>
705
706         Add API::PolicyClient base class
707         https://bugs.webkit.org/show_bug.cgi?id=127509
708
709         Reviewed by Tim Horton.
710
711         * UIProcess/API/APIPolicyClient.h: Copied from Source/WebKit2/UIProcess/WebPolicyClient.h.
712         (API::PolicyClient::~PolicyClient):
713         * UIProcess/API/C/WKPage.cpp:
714         (WKPageSetPagePolicyClient):
715         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
716         (setUpPagePolicyClient):
717         (-[WKBrowsingContextController setPolicyDelegate:]):
718         * UIProcess/WebInspectorProxy.cpp:
719         (WebKit::WebInspectorProxy::createInspectorPage):
720         * UIProcess/WebPageProxy.cpp:
721         (WebKit::WebPageProxy::setPolicyClient):
722         (WebKit::WebPageProxy::close):
723         (WebKit::WebPageProxy::decidePolicyForNavigationAction):
724         (WebKit::WebPageProxy::decidePolicyForNewWindowAction):
725         (WebKit::WebPageProxy::decidePolicyForResponse):
726         (WebKit::WebPageProxy::unableToImplementPolicy):
727         * UIProcess/WebPageProxy.h:
728         * UIProcess/WebPolicyClient.cpp:
729         (WebKit::WebPolicyClient::WebPolicyClient):
730         (WebKit::WebPolicyClient::decidePolicyForNavigationAction):
731         (WebKit::WebPolicyClient::decidePolicyForNewWindowAction):
732         (WebKit::WebPolicyClient::decidePolicyForResponse):
733         * UIProcess/WebPolicyClient.h:
734         * WebKit2.xcodeproj/project.pbxproj:
735
736 2014-01-23  Anders Carlsson  <andersca@apple.com>
737
738         Add init methods that create default configurations
739         https://bugs.webkit.org/show_bug.cgi?id=127503
740
741         Reviewed by Dan Bernstein.
742
743         * UIProcess/API/Cocoa/WKProcessClass.mm:
744         (-[WKProcessClass init]):
745         * UIProcess/API/Cocoa/WKWebView.mm:
746         (-[WKWebView initWithFrame:]):
747
748 2014-01-23  Brady Eidson  <beidson@apple.com>
749
750         IDB: Implement cross-thread and IPC plumbing for 'get' support
751         https://bugs.webkit.org/show_bug.cgi?id=127501
752
753         Reviewed by Anders Carlsson.
754
755         Make the WebProcess call out to the DatabaseProcess with a get request, and handle the
756         response from the DatabaseProcess:
757         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
758         (WebKit::WebIDBServerConnection::get):
759         (WebKit::WebIDBServerConnection::didGetRecord):
760         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
761         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:
762
763         Get the request from the WebProcess and forward it to the appropriate unique IDB database:
764         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
765         (WebKit::DatabaseProcessIDBConnection::getRecord):
766         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
767         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
768
769         Forward the request to the database thread, and response to the result from that thread:
770         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
771         (WebKit::UniqueIDBDatabase::getRecord):
772         (WebKit::UniqueIDBDatabase::getRecordFromBackingStore):
773         (WebKit::UniqueIDBDatabase::didGetRecordFromBackingStore):
774         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
775
776         IPC and asynchronous request infrastructure:
777         * Scripts/webkit2/messages.py:
778         (struct_or_class):
779
780         * Shared/AsyncTask.h:
781         (WebKit::createAsyncTask):
782
783         * Shared/WebCoreArgumentCoders.cpp:
784         (IPC::ArgumentCoder<IDBGetResult>::encode):
785         (IPC::ArgumentCoder<IDBGetResult>::decode):
786         (IPC::ArgumentCoder<IDBKeyRangeData>::encode):
787         (IPC::ArgumentCoder<IDBKeyRangeData>::decode):
788         * Shared/WebCoreArgumentCoders.h:
789
790 2014-01-23  Tim Horton  <timothy_horton@apple.com>
791
792         PDFPlugin: Use PDFPlugin even if there's an external plugin installed, if it's blocked
793         https://bugs.webkit.org/show_bug.cgi?id=127415
794         <rdar://problem/12482452>
795
796         Reviewed by Sam Weinig.
797
798         Allow use of PDFPlugin even if an external plugin is installed but blocked.
799         If an external plugin is installed and not blocked, we will continue to use that.
800
801         Inject a context menu item into the PDFPlugin context menu that allows the client
802         to unblock the plugin and reload the page (via the same mechanism that the
803         unavailable plugin button uses).
804
805         * UIProcess/API/C/WKPageLoaderClient.h:
806         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
807         (setUpPageLoaderClient):
808         * UIProcess/WebLoaderClient.cpp:
809         (WebKit::WebLoaderClient::pluginLoadPolicy):
810         * UIProcess/WebLoaderClient.h:
811         * UIProcess/WebPageProxy.cpp:
812         (WebKit::WebPageProxy::findPlugin):
813         * UIProcess/WebPageProxy.h:
814         * UIProcess/WebPageProxy.messages.in:
815         Add a new PluginLoadPolicy callback for the V4 client with
816         yet another string out-argument, to allow clients to customize the string
817         that will appear in the PDFPlugin context menu when it is used in place
818         of a blocked plugin.
819
820         * WebProcess/Plugins/PDF/PDFPlugin.h:
821         Add setUsedInPlaceOfBlockedPlugin(), which determines whether or not
822         we should include an item in the PDFPlugin context menu that acts identically
823         to the unavailable plugin button, allowing the client to potentially unblock
824         the plugin.
825
826         * WebProcess/Plugins/PDF/PDFPlugin.mm:
827         (-[WKPDFPluginContextMenuTarget initWithPDFPlugin:WebKit::]):
828         (-[WKPDFPluginContextMenuTarget useBlockedPlugin:]):
829         Added WKPDFPluginContextMenuTarget, which is the Objective-C object that the
830         aforementioned context menu item targets.
831
832         (WebKit::PDFPlugin::PDFPlugin):
833         By default, we won't show the extra context menu item.
834
835         (WebKit::PDFPlugin::handleContextMenuEvent):
836         If we were used in place of a blocked plugin, inject our additional context
837         menu item into the menu. If we were handed a custom string via setUsedInPlaceOfBlockedPlugin,
838         use that. Otherwise, use the generic string from WebCore's localized strings.
839
840         (WebKit::PDFPlugin::openWithPlugin):
841         Pretend that the user clicked the unavailable plugin button when they click
842         the injected context menu item.
843
844         (WebKit::PDFPlugin::setUsedInPlaceOfBlockedPlugin):
845
846         * WebProcess/WebPage/WebPage.cpp:
847         (WebKit::WebPage::createPlugin):
848         If we end up with a blocked plugin, but could have used PDFPlugin to display
849         the content, do so instead of showing the unavailable plugin indicator.
850
851         Pass PDFPlugin the custom context menu item title acquired from the client.
852
853         (WebKit::WebPage::canPluginHandleResponse):
854
855 2014-01-23  Tim Horton  <timothy_horton@apple.com>
856
857         [iOS] [WK2] WKContentView has a black background
858         https://bugs.webkit.org/show_bug.cgi?id=127471
859         <rdar://problem/12287363>
860
861         Reviewed by Sam Weinig.
862
863         * UIProcess/API/ios/WKContentView.mm:
864         (-[WKContentView _commonInitializationWithContextRef:pageGroupRef:relatedToPage:]):
865         Instead of giving it a (black!) background to make hit-testing work, use CALayer SPI
866         to tell CA that the whole layer should be treated as opaque when it comes to hit-testing.
867
868 2014-01-22  Carlos Garcia Campos  <cgarcia@igalia.com>
869
870         [GLIB] Use GUniquePtr instead of GOwnPtr
871         https://bugs.webkit.org/show_bug.cgi?id=127431
872
873         Reviewed by Martin Robinson.
874
875         GUniquePtr is a template alias of std::unique_ptr with a custom
876         deleter that replaces GOwnPtr. GOwnPtr is still used for the cases
877         where the output pointer is needed, but it will also be replaced soon.
878
879         * Shared/Downloads/soup/DownloadSoup.cpp:
880         (WebKit::DownloadClient::didReceiveResponse):
881         * Shared/NativeWebKeyboardEvent.h:
882         * Shared/NativeWebMouseEvent.h:
883         * Shared/NativeWebWheelEvent.h:
884         * Shared/gtk/ArgumentCodersGtk.cpp:
885         (IPC::encodeGKeyFile):
886         (IPC::decodeGKeyFile):
887         (IPC::encode):
888         (IPC::decode):
889         * UIProcess/API/gtk/WebKitContextMenuItem.cpp:
890         (webkitContextMenuItemSetSubMenuFromGtkMenu):
891         * UIProcess/API/gtk/WebKitDownload.cpp:
892         (webkitDownloadDecideDestination):
893         (webkitDownloadNotifyProgress):
894         (webkitDownloadFailed):
895         * UIProcess/API/gtk/WebKitFileChooserRequest.cpp:
896         (webkit_file_chooser_request_select_files):
897         * UIProcess/API/gtk/WebKitInjectedBundleClient.cpp:
898         (didReceiveWebViewMessageFromInjectedBundle):
899         (getInjectedBundleInitializationUserData):
900         * UIProcess/API/gtk/WebKitLoaderClient.cpp:
901         (didFailProvisionalLoadWithErrorForFrame):
902         (didFailLoadWithErrorForFrame):
903         * UIProcess/API/gtk/WebKitPrintOperation.cpp:
904         (drawPagesForPrintingCompleted):
905         * UIProcess/API/gtk/WebKitURIRequest.cpp:
906         (webkit_uri_request_get_http_headers):
907         * UIProcess/API/gtk/WebKitURISchemeRequest.cpp:
908         (webkit_uri_scheme_request_get_scheme):
909         (webkit_uri_scheme_request_get_path):
910         * UIProcess/API/gtk/WebKitWebContext.cpp:
911         (injectedBundleFilename):
912         (webkit_web_context_set_favicon_database_directory):
913         * UIProcess/API/gtk/WebKitWebView.cpp:
914         (webkitWebViewLoadFail):
915         (webkitWebViewCreateJavaScriptDialog):
916         (fileChooserDialogResponseCallback):
917         (webkitWebViewLoadChanged):
918         (webkitWebViewLoadFailedWithTLSErrors):
919         (webkitWebViewPopulateContextMenu):
920         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
921         (webkitWebViewBaseButtonPressEvent):
922         (webkitWebViewBaseStartDrag):
923         * UIProcess/InspectorServer/gtk/WebInspectorServerGtk.cpp:
924         (WebKit::WebInspectorServer::platformResourceForPath):
925         * UIProcess/InspectorServer/soup/WebSocketServerSoup.cpp:
926         (WebKit::connectionCallback):
927         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
928         (WebKit::ProcessLauncher::launchProcess):
929         * UIProcess/gtk/WebContextGtk.cpp:
930         (WebKit::WebContext::platformDefaultApplicationCacheDirectory):
931         (WebKit::WebContext::platformDefaultDatabaseDirectory):
932         (WebKit::WebContext::platformDefaultIconDatabasePath):
933         (WebKit::WebContext::platformDefaultLocalStorageDirectory):
934         (WebKit::WebContext::platformDefaultDiskCacheDirectory):
935         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
936         (WebKit::contextMenuItemVisibilityChanged):
937         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
938         (WebKit::WebInspectorProxy::platformInspectedURLChanged):
939         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
940         (WebKit::WebPopupMenuProxyGtk::createGtkActionForMenuItem):
941         * WebProcess/WebPage/gtk/WebInspectorGtk.cpp:
942         * WebProcess/WebPage/gtk/WebPageGtk.cpp:
943         (WebKit::WebPage::platformInitialize):
944         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp:
945         * WebProcess/gtk/WebProcessMainGtk.cpp:
946         * WebProcess/soup/WebSoupRequestManager.cpp:
947         (WebKit::WebSoupRequestManager::send):
948
949 2014-01-22  Simon Fraser  <simon.fraser@apple.com>
950
951         Surround fixedVisibleContentRect code with USE(TILED_BACKING_STORE)
952         https://bugs.webkit.org/show_bug.cgi?id=127461
953
954         Reviewed by Andreas Kling.
955         
956         The "fixedVisibleContentRect" code path is only used by platforms
957         which enabled TILED_BACKING_STORE, so to reduce confusion, surround
958         this code with #if USE(TILED_BACKING_STORE).
959
960         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
961         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
962
963 2014-01-22  Benjamin Poulain  <bpoulain@apple.com>
964
965         Add a minimalistic SPI to control the layout size outside of WKView
966         https://bugs.webkit.org/show_bug.cgi?id=127403
967
968         Reviewed by Sam Weinig.
969
970         The API lets a client of WKView force the layout size. Once the size
971         is set this way, default update is disabled and the client needs to
972         update the size systematically as needed. This is done to avoid double
973         layout or flickering.
974
975         * UIProcess/API/Cocoa/WKViewPrivate.h:
976         * UIProcess/API/ios/WKViewIOS.mm:
977         (-[WKView _frameOrBoundsChanged]):
978         (-[WKView overrideMinimumLayoutSize:]):
979
980 2014-01-22  Jinwoo Song  <jinwoo7.song@samsung.com>
981
982         [EFL][WK2] defaultTextEncodingName should be stored as a member variable of EwkSettings
983         https://bugs.webkit.org/show_bug.cgi?id=127420
984
985         Reviewed by Gyuyoung Kim.
986
987         As the defaultTextEncodingName is returned as a local WKEinaSharedString variable, 
988         the stringshared data is de-refed by eina_stringshare_del().
989         To maintain the reference counter, the defaultTextEncodingName should be stored 
990         as a member variable of EwkSettings class.
991
992         * UIProcess/API/efl/ewk_settings.cpp:
993         (ewk_settings_encoding_detector_enabled_get): Reordering.
994         (ewk_settings_default_text_encoding_name_set):
995         (ewk_settings_default_text_encoding_name_get):
996         (EwkSettings::setDefaultTextEncodingName):
997         (EwkSettings::defaultTextEncodingName):
998         * UIProcess/API/efl/ewk_settings_private.h:
999         (EwkSettings::EwkSettings): Add m_defaultTextEncodingName and setter/getter methods.
1000
1001 2014-01-22  Enrica Casucci  <enrica@apple.com>
1002
1003         Support WebSelections in WK2 on iOS.
1004         https://bugs.webkit.org/show_bug.cgi?id=127015
1005         <rdar://problem/15211964>
1006
1007         Reviewed by Benjamin Poulain.
1008
1009         This change adds support for text only (non block mode)
1010         selections in non editable content.
1011         The main changes consist in hooking up the new gesture type
1012         and touches to handle selection creation and interaction.
1013         It also includes changes to the way first responder is handled
1014         which includes the implementation of the isEditable method
1015         to allow iOS to know when to show the keyboard.
1016
1017         * Shared/ios/WKGestureTypes.h:
1018         * UIProcess/API/ios/WKInteractionView.mm:
1019         (-[WKInteractionView isEditable]):
1020         (-[WKInteractionView canBecomeFirstResponder]):
1021         (-[WKInteractionView webSelectionRects]):
1022         (-[WKInteractionView _highlightLongPressRecognized:]):
1023         (-[WKInteractionView _singleTapRecognized:]):
1024         (-[WKInteractionView inputAccessoryView]):
1025         (-[WKInteractionView canPerformAction:withSender:]):
1026         (-[WKInteractionView _showDictionary:]):
1027         (toWKGestureType):
1028         (toUIWKGestureType):
1029         (selectionChangedWithGesture):
1030         (selectionChangedWithTouch):
1031         (-[WKInteractionView selectedTextRange]):
1032         (-[WKInteractionView webSelectionAssistant]):
1033         (-[WKInteractionView _startAssistingNode]):
1034         (-[WKInteractionView _stopAssistingNode]):
1035         (-[WKInteractionView _selectionChanged]):
1036         * WebProcess/WebPage/ios/WebPageIOS.mm:
1037         (WebKit::WebPage::selectWithGesture):
1038         (WebKit::WebPage::updateSelectionWithTouches):
1039
1040 2014-01-22  Anders Carlsson  <andersca@apple.com>
1041
1042         WKBrowsingContextController should not be an API wrapper around WebPageProxy
1043         https://bugs.webkit.org/show_bug.cgi?id=127454
1044
1045         Reviewed by Dan Bernstein.
1046
1047         * Shared/Cocoa/APIObject.mm:
1048         (API::Object::newObject):
1049         * Shared/mac/ObjCObjectGraphCoders.mm:
1050         (WebKit::WebContextObjCObjectGraphDecoderImpl::decode):
1051         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
1052         (-[WKBrowsingContextController _initWithPageRef:]):
1053         (+[WKBrowsingContextController _browsingContextControllerForPageRef:]):
1054         * UIProcess/API/Cocoa/WKBrowsingContextControllerInternal.h:
1055         * UIProcess/API/Cocoa/WKProcessGroup.mm:
1056         (didNavigateWithNavigationData):
1057         (didPerformClientRedirect):
1058         (didPerformServerRedirect):
1059         (didUpdateHistoryTitle):
1060         * UIProcess/API/ios/WKContentView.mm:
1061         (-[WKContentView browsingContextController]):
1062         * UIProcess/API/mac/WKView.mm:
1063         (-[WKView browsingContextController]):
1064         * UIProcess/ios/WebPageProxyIOS.mm:
1065         (WebKit::WebPageProxy::platformInitialize):
1066         * UIProcess/mac/WebPageProxyMac.mm:
1067         (WebKit::WebPageProxy::platformInitialize):
1068
1069 2014-01-22  Myles C. Maxfield  <mmaxfield@apple.com>
1070
1071         Remove CSS3_TEXT_DECORATION define
1072         https://bugs.webkit.org/show_bug.cgi?id=127333
1073
1074         Reviewed by Simon Fraser.
1075
1076         This is required for unprefixing the text-decoration-* CSS properties.
1077
1078         * Configurations/FeatureDefines.xcconfig:
1079
1080 2014-01-22  Gavin Barraclough  <barraclough@apple.com>
1081
1082         Debug mechanism to override process QoS on Mac
1083         https://bugs.webkit.org/show_bug.cgi?id=127455
1084
1085         Reviewed by Anders Carlsson.
1086
1087         * NetworkProcess/NetworkProcess.messages.in:
1088             - added message.
1089         * PluginProcess/PluginProcess.messages.in:
1090             - added message.
1091         * Shared/ChildProcess.h:
1092         * Shared/mac/ChildProcessMac.mm:
1093         (WebKit::ChildProcess::setQOS):
1094             - Added implementation of new message.
1095         * UIProcess/Plugins/PluginProcessProxy.cpp:
1096         (WebKit::PluginProcessProxy::didFinishLaunching):
1097             - SetQOS for the PluginProcess.
1098         * UIProcess/Plugins/PluginProcessProxy.h:
1099         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
1100         (WebKit::pluginProcessLatencyQOS):
1101         (WebKit::pluginProcessThroughputQOS):
1102             - read NSUserDefaults.
1103         * UIProcess/WebContext.cpp:
1104         (WebKit::WebContext::ensureNetworkProcess):
1105             - SetQOS for the NetworkProcess.
1106         (WebKit::WebContext::createNewWebProcess):
1107             - SetQOS for the WebProcess.
1108         * UIProcess/WebContext.h:
1109         * UIProcess/mac/WebContextMac.mm:
1110         (WebKit::networkProcessLatencyQOS):
1111         (WebKit::networkProcessThroughputQOS):
1112         (WebKit::webProcessLatencyQOS):
1113         (WebKit::webProcessThroughputQOS):
1114             - read NSUserDefaults.
1115         * WebProcess/WebProcess.messages.in:
1116             - added message.
1117
1118 2014-01-22  David Farler  <dfarler@apple.com>
1119
1120         ASAN builds are broken - missing flags
1121         https://bugs.webkit.org/show_bug.cgi?id=127231
1122
1123         Reviewed by Andy Estes.
1124
1125         Add missing $(ASAN_OTHER_LDFLAGS).
1126         * Configurations/PluginProcessShim.xcconfig:
1127         * Configurations/SecItemShim.xcconfig:
1128         * Configurations/WebKit2.xcconfig:
1129         * Configurations/WebProcessShim.xcconfig:
1130
1131 2014-01-22  Brady Eidson  <beidson@apple.com>
1132
1133         The IDB backing store get() method shouldn't call IDB callbacks directly
1134         https://bugs.webkit.org/show_bug.cgi?id=127453
1135         
1136         Reviewed by Beth Dakin.
1137
1138         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
1139         (WebKit::WebIDBServerConnection::get):
1140         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
1141
1142 2014-01-22  Martin Hock  <mhock@apple.com>
1143
1144         Enable Session API.
1145         https://bugs.webkit.org/show_bug.cgi?id=127255
1146
1147         Reviewed by Alexey Proskuryakov.
1148
1149         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
1150         (WebKit::storageSession):
1151         * NetworkProcess/NetworkResourceLoader.cpp:
1152         (WebKit::NetworkResourceLoader::NetworkResourceLoader):
1153         (WebKit::NetworkResourceLoader::start):
1154         * NetworkProcess/NetworkResourceLoader.h:
1155         * NetworkProcess/RemoteNetworkingContext.h:
1156         * NetworkProcess/mac/RemoteNetworkingContext.mm:
1157         (WebKit::RemoteNetworkingContext::storageSession):
1158         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
1159         * Shared/Network/NetworkResourceLoadParameters.cpp:
1160         (WebKit::NetworkResourceLoadParameters::NetworkResourceLoadParameters):
1161         (WebKit::NetworkResourceLoadParameters::encode):
1162         (WebKit::NetworkResourceLoadParameters::decode):
1163         * Shared/Network/NetworkResourceLoadParameters.h:
1164         * Shared/SessionTracker.cpp:
1165         (WebKit::staticSessionMap):
1166         (WebKit::SessionTracker::sessionMap):
1167         (WebKit::SessionTracker::session):
1168         (WebKit::SessionTracker::setSession):
1169         (WebKit::SessionTracker::destroySession):
1170         * Shared/SessionTracker.h:
1171         * UIProcess/API/C/WKPage.cpp:
1172         (WKPageSetSession):
1173         * UIProcess/API/C/WKPage.h:
1174         * UIProcess/API/C/WKSessionRef.cpp:
1175         (WKSessionCreate):
1176         * UIProcess/API/C/WKSessionRef.h:
1177         * UIProcess/WebPageProxy.cpp:
1178         (WebKit::WebPageProxy::WebPageProxy):
1179         (WebKit::WebPageProxy::setSession):
1180         * UIProcess/WebPageProxy.h:
1181         * WebProcess/Network/WebResourceLoadScheduler.cpp:
1182         (WebKit::WebResourceLoadScheduler::scheduleLoad):
1183         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1184         (WebKit::WebPlatformStrategies::loadResourceSynchronously):
1185         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
1186         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
1187         (WebKit::WebFrameNetworkingContext::setCookieAcceptPolicyForAllContexts):
1188         (WebKit::WebFrameNetworkingContext::storageSession):
1189         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
1190         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
1191         * WebProcess/WebPage/WebFrame.cpp:
1192         (WebKit::WebFrame::startDownload):
1193         * WebProcess/WebPage/WebPage.cpp:
1194         (WebKit::WebPage::WebPage):
1195         (WebKit::WebPage::sessionID):
1196         (WebKit::WebPage::updatePreferences):
1197         * WebProcess/WebPage/WebPage.h:
1198         (WebKit::WebPage::setSessionID):
1199         * WebProcess/WebPage/WebPage.messages.in:
1200
1201 2014-01-21  Brady Eidson  <beidson@apple.com>
1202
1203         IDB: "Put" support
1204         <rdar://problem/15779643> and https://bugs.webkit.org/show_bug.cgi?id=127401
1205
1206         Reviewed by Alexey Proskuryakov.
1207
1208         Ship putRecord requests over to the DatabaseProcess, and listen for completion from the DatabaseProcess:
1209         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
1210         (WebKit::WebIDBServerConnection::put):
1211         (WebKit::WebIDBServerConnection::didPutRecord):
1212         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
1213         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:
1214
1215         Pass off the putRecord request to the Unique IDBDatabase:
1216         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
1217         (WebKit::DatabaseProcessIDBConnection::putRecord):
1218         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
1219         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
1220
1221         Pass off the putRecord request to the backing store:
1222         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
1223         (WebKit::UniqueIDBDatabase::putRecord):
1224         (WebKit::UniqueIDBDatabase::putRecordInBackingStore):
1225         (WebKit::UniqueIDBDatabase::didPutRecordInBackingStore):
1226         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
1227
1228         Add backing store methods related to putRecord, though only one is critical right now:
1229         * DatabaseProcess/IndexedDB/UniqueIDBDatabaseBackingStore.h:
1230         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
1231         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createAndPopulateInitialMetadata):
1232         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::generateKey):
1233         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::keyExistsInObjectStore):
1234         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::putRecord):
1235         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::updateKeyGenerator):
1236         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
1237
1238         Add the IDBKeyData type to IPC:
1239         * Scripts/webkit2/messages.py:
1240         (struct_or_class):
1241
1242         * Shared/WebCoreArgumentCoders.cpp:
1243         (IPC::ArgumentCoder<IDBKeyData>::encode):
1244         (IPC::ArgumentCoder<IDBKeyData>::decode):
1245         * Shared/WebCoreArgumentCoders.h:
1246
1247         * DatabaseProcess/IndexedDB/IDBSerialization.cpp:
1248         (WebKit::serializeIDBKey):
1249         * DatabaseProcess/IndexedDB/IDBSerialization.h:
1250
1251         Implement more cross-thread copying:
1252         * Shared/WebCrossThreadCopier.cpp:
1253         (WebCore::Vector<uint8_t>>::copy):
1254         (WebCore::Vector<Vector<IDBKeyData>>>::copy):
1255         (WebCore::ASCIILiteral>::copy):
1256         * Shared/WebCrossThreadCopier.h:
1257
1258         Implement more numbers of generic AsyncTask templates:
1259         * Shared/AsyncTask.h:
1260         (WebKit::createAsyncTask):
1261
1262 2014-01-22  Anders Carlsson  <andersca@apple.com>
1263
1264         WKProcessClass should create a WebContext
1265         https://bugs.webkit.org/show_bug.cgi?id=127449
1266         <rdar://problem/15885582>
1267
1268         Reviewed by Dan Bernstein.
1269
1270         * Shared/Cocoa/APIObject.mm:
1271         (API::Object::newObject):
1272         * UIProcess/API/Cocoa/WKBrowsingContextController.h:
1273         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
1274         * UIProcess/API/Cocoa/WKProcessClass.mm:
1275         (-[WKProcessClass initWithConfiguration:]):
1276         (-[WKProcessClass dealloc]):
1277         (-[WKProcessClass API::]):
1278         * UIProcess/API/Cocoa/WKProcessClassInternal.h: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKProcessGroupInternal.h.
1279         (WebKit::wrapper):
1280         * UIProcess/API/Cocoa/WKProcessGroup.mm:
1281         (-[WKProcessGroup initWithInjectedBundleURL:]):
1282         * UIProcess/API/ios/WKContentView.mm:
1283         (-[WKContentView _decidePolicyForGeolocationRequestFromOrigin:frame:request:]):
1284         * WebKit2.xcodeproj/project.pbxproj:
1285
1286 2014-01-22  Tim Horton  <timothy_horton@apple.com>
1287
1288         Crashes in DrawingAreaProxy::setExposedRect (null DrawingAreaProxy)
1289         https://bugs.webkit.org/show_bug.cgi?id=127445
1290
1291         Reviewed by Anders Carlsson.
1292
1293         * UIProcess/API/ios/WKContentView.mm:
1294         (-[WKContentView _updateViewExposedRect]):
1295         * UIProcess/API/mac/WKView.mm:
1296         (-[WKView _updateViewExposedRect]):
1297         Null-check.
1298
1299 2014-01-22  Anders Carlsson  <andersca@apple.com>
1300
1301         Add WKWebView class
1302         https://bugs.webkit.org/show_bug.cgi?id=127444
1303         <rdar://problem/15884418>
1304
1305         Reviewed by Dan Bernstein.
1306
1307         * UIProcess/API/Cocoa/WKWebView.h: Added.
1308         * UIProcess/API/Cocoa/WKWebView.mm: Added.
1309         (-[WKWebView initWithFrame:configuration:]):
1310         (-[WKWebView configuration]):
1311         * WebKit2.xcodeproj/project.pbxproj:
1312
1313 2014-01-22  Anders Carlsson  <andersca@apple.com>
1314
1315         Fix 32-bit build.
1316
1317         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
1318
1319 2014-01-22  Tim Horton  <timothy_horton@apple.com>
1320
1321         [wk2] Scroll pinning state is wrong until the first scroll event
1322         https://bugs.webkit.org/show_bug.cgi?id=127437
1323
1324         Reviewed by Simon Fraser.
1325
1326         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1327         (WebKit::WebFrameLoaderClient::didChangeScrollOffset):
1328         * WebProcess/WebPage/WebPage.cpp:
1329         (WebKit::WebPage::updateMainFrameScrollOffsetPinning):
1330         (WebKit::WebPage::didCommitLoad):
1331         * WebProcess/WebPage/WebPage.h:
1332         Rename WebPage::didChangeScrollOffsetForMainFrame to
1333         updateMainFrameScrollOffsetPinning, which better describes what it
1334         actually does. Call it when a load is committed, so that we have valid
1335         pinning state before the first scroll event comes in.
1336
1337 2014-01-22  Anders Carlsson  <andersca@apple.com>
1338
1339         Add WKWebViewConfiguration class
1340         https://bugs.webkit.org/show_bug.cgi?id=127436
1341         <rdar://problem/15882923>
1342
1343         Reviewed by Tim Horton.
1344
1345         * UIProcess/API/Cocoa/WKWebViewConfiguration.h: Added.
1346         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm: Added.
1347         (-[WKWebViewConfiguration copyWithZone:]):
1348         * WebKit2.xcodeproj/project.pbxproj:
1349
1350 2014-01-22  Alice Barraclough  <alice.liu@apple.com>
1351
1352         [WK2] add cocoa API for private browsing setting
1353         https://bugs.webkit.org/show_bug.cgi?id=127391
1354
1355         Reviewed by Sam Weinig.
1356
1357         * UIProcess/API/Cocoa/WKBrowsingContextGroup.h:
1358         * UIProcess/API/Cocoa/WKBrowsingContextGroup.mm:
1359         (-[WKBrowsingContextGroup privateBrowsingEnabled]):
1360         (-[WKBrowsingContextGroup setPrivateBrowsingEnabled:]):
1361         Adding some API for the private Browsing setting. Reaches through
1362         to the WKPageGroup's preferences.
1363
1364 2014-01-22  Anders Carlsson  <andersca@apple.com>
1365
1366         Add WKProcessClass class
1367         https://bugs.webkit.org/show_bug.cgi?id=127433
1368         <rdar://problem/15882582>
1369
1370         Reviewed by Dan Bernstein.
1371
1372         Add a stubbed out WKProcessClass class.
1373
1374         * Shared/API/Cocoa/WKFoundation.h:
1375         * UIProcess/API/Cocoa/WKProcessClass.h: Added.
1376         * UIProcess/API/Cocoa/WKProcessClass.mm: Added.
1377         (-[WKProcessClass initWithConfiguration:]):
1378         (-[WKProcessClass configuration]):
1379         * UIProcess/API/Cocoa/WKProcessClassConfiguration.mm:
1380         * WebKit2.xcodeproj/project.pbxproj:
1381
1382 2014-01-22  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1383
1384         [EFL][GTK] Get EFL and GTK compiling with ACCESSIBILITY disabled
1385         https://bugs.webkit.org/show_bug.cgi?id=127119
1386
1387         Reviewed by Mario Sanchez Prada.
1388
1389         Guarding ACCESSIBILITY code with HAVE(ACCESSIBILITY).
1390
1391         * WebProcess/WebPage/WebPage.cpp:
1392         (WebKit::WebPage::WebPage):
1393         * WebProcess/WebPage/WebPage.h:
1394         * WebProcess/WebPage/gtk/WebPageGtk.cpp:
1395         (WebKit::WebPage::platformInitialize):
1396
1397 2014-01-22  Martin Robinson  <mrobinson@igalia.com>
1398
1399         [GTK][CMake] Add support for building the NetworkProcess
1400         https://bugs.webkit.org/show_bug.cgi?id=127195
1401
1402         Reviewed by Daniel Bates.
1403
1404         * CMakeLists.txt: Add shared network process build instructions.
1405         * PlatformEfl.cmake: Move build instructions to the platform-independent file.
1406         * PlatformGTK.cmake: Add some files to the source lists.
1407
1408 2014-01-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1409
1410         REGRESSION(r162441): [GTK] ResourceLoader is broken when there aren't user extensions
1411         https://bugs.webkit.org/show_bug.cgi?id=127422
1412
1413         Reviewed by Anders Carlsson.
1414
1415         * WebProcess/gtk/WebGtkExtensionManager.cpp:
1416         (WebKit::WebGtkExtensionManager::initialize): Always create the
1417         WebKitWebExtension object since it's used internally to implement
1418         the ResourceLoader client.
1419
1420 2014-01-22  Jer Noble  <jer.noble@apple.com>
1421
1422         [Mac][WK2] Unable to play video protected by session cookies
1423         https://bugs.webkit.org/show_bug.cgi?id=127207
1424
1425         Reviewed by Sam Weinig.
1426
1427         Recent changes in our underlying media frameworks caused our shimmed methods
1428         in CookieStorageShim to stop being called. Insert an objective-c shim in addition
1429         to our original shim to intercept pulling cookies out of cookie storage.
1430
1431         * Shared/mac/CookieStorageShim.mm: Renamed from Source/WebKit2/Shared/mac/CookieStorageShim.cpp.
1432         (WebKit::CookieStorageShim::initialize): Insert the shim.
1433         (-[WKNSURLSessionLocal _copyCookiesForRequestUsingAllAppropriateStorageSemantics:]):
1434             Pass through to webKitCookieStorageCopyRequestHeaderFieldsForURL().
1435         * WebKit2.xcodeproj/project.pbxproj: Rename CookieStorageShim.cpp -> .mm.
1436
1437 2014-01-22  Yongjun Zhang  <yongjun_zhang@apple.com>
1438
1439         https://bugs.webkit.org/show_bug.cgi?id=127380
1440         Add more methods to WKWebProcessPlugInNodeHandle.
1441
1442         Reviewed by Sam Weinig.
1443
1444         Add a static method that creates a WKWebProcessPlugInNodeHandle from a JSValue* and a JSContext*.  Also
1445         add a method to return the iframe's content frame from a WKWebProcessPlugInNodeHandle.
1446  
1447         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandle.h:
1448         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandle.mm:
1449         (+[WKWebProcessPlugInNodeHandle nodeHandleWithJSValue:inContext:]):
1450         (-[WKWebProcessPlugInNodeHandle htmlIFrameElementContentFrame]):
1451
1452 2014-01-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1453
1454         Unreviewed. Fix GTK+ build with CUSTOM_PROTOCOL enabled after r162449.
1455
1456         * UIProcess/Network/CustomProtocols/soup/WebSoupCustomProtocolRequestManager.h:
1457         Use override instead of OVERRIDE.
1458
1459 2014-01-22  Koop Mast <kwm@FreeBSD.org>
1460
1461         Build fixes for FreeBSD.
1462         https://bugs.webkit.org/show_bug.cgi?id=126779
1463
1464         Reviewed by Csaba Osztrogonác.
1465
1466         * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
1467         (WebKit::PluginProcessProxy::scanPlugin):
1468
1469 2014-01-22  Jinwoo Song  <jinwoo7.song@samsung.com>
1470
1471         [EFL][WK2] Use std::function in the rest of EFL's WorkQueue implementation
1472         https://bugs.webkit.org/show_bug.cgi?id=127397
1473
1474         Reviewed by Anders Carlsson.
1475
1476         Move to using std::function and move semantics in WorkQueue::registerSocketEventHandler
1477         and DispatchQueue::setSocketEventHandler.
1478
1479         * Platform/IPC/unix/ConnectionUnix.cpp:
1480         (IPC::Connection::open):
1481         * Platform/WorkQueue.h:
1482         * Platform/efl/DispatchQueueEfl.cpp:
1483         (DispatchQueue::setSocketEventHandler):
1484         * Platform/efl/DispatchQueueEfl.h:
1485         * Platform/efl/WorkQueueEfl.cpp:
1486         (WorkQueue::registerSocketEventHandler):
1487
1488 2014-01-21  Tim Horton  <timothy_horton@apple.com>
1489
1490         [wk2] De-.get()ify receivers of Objective-C messages
1491         https://bugs.webkit.org/show_bug.cgi?id=127398
1492
1493         Reviewed by Sam Weinig.
1494
1495         RetainPtr does the right thing when you use it as the
1496         receiver of an Obj-C message, so we don't need .get().
1497
1498         Long and useless file list elided.
1499
1500 2014-01-21  Brady Eidson  <beidson@apple.com>
1501
1502         The IDB backing store put() method shouldn't call IDB callbacks directly
1503         https://bugs.webkit.org/show_bug.cgi?id=127399
1504
1505         Reviewed by Beth Dakin.
1506
1507         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
1508         (WebKit::WebIDBServerConnection::put):
1509         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
1510
1511 2014-01-21  Anders Carlsson  <andersca@apple.com>
1512
1513         Fix 32-bit build.
1514
1515         * UIProcess/API/Cocoa/WKProcessClassConfiguration.mm:
1516
1517 2014-01-21  Jinwoo Song  <jinwoo7.song@samsung.com>
1518
1519         [EFL][WK2] Use nanoseconds in TimerWorkItem class consistently
1520         https://bugs.webkit.org/show_bug.cgi?id=127263
1521
1522         Reviewed by Gyuyoung Kim.
1523
1524         After r162276 and r162300, TimerWorkItem is getting nanoseconds as parameter.
1525         So it would be better to use nanoseconds in TimerWorkItem for consistency.
1526
1527         * Platform/efl/DispatchQueueEfl.cpp:
1528         (DispatchQueue::performTimerWork):
1529         (DispatchQueue::insertTimerWorkItem):
1530         (DispatchQueue::getNextTimeOut):
1531         * Platform/efl/DispatchQueueWorkItemEfl.h:
1532         (TimerWorkItem::create):
1533         (TimerWorkItem::expirationTimeNanoSeconds):
1534         (TimerWorkItem::hasExpired):
1535         (TimerWorkItem::TimerWorkItem):
1536
1537 2014-01-21  Tim Horton  <timothy_horton@apple.com>
1538
1539         Don't copy ViewGestureGeometryCollector.messages.in into the WebProcess bundle.
1540
1541         Reviewed by Simon Fraser.
1542
1543         * WebKit2.xcodeproj/project.pbxproj:
1544
1545 2014-01-21  Anders Carlsson  <andersca@apple.com>
1546
1547         Add a WKProcessClassConfiguration class
1548         https://bugs.webkit.org/show_bug.cgi?id=127378
1549         <rdar://problem/15875413>
1550
1551         Reviewed by Dan Bernstein.
1552
1553         * UIProcess/API/Cocoa/WKProcessClassConfiguration.h: Added.
1554         * UIProcess/API/Cocoa/WKProcessClassConfiguration.mm: Added.
1555         (-[WKProcessClassConfiguration copyWithZone:]):
1556         * UIProcess/API/Cocoa/WKProcessClassConfigurationPrivate.h: Added.
1557         * WebKit2.xcodeproj/project.pbxproj:
1558
1559 2014-01-21  Tim Horton  <timothy_horton@apple.com>
1560
1561         Make ViewGestureController Obj-C++
1562         https://bugs.webkit.org/show_bug.cgi?id=127385
1563
1564         Reviewed by Dean Jackson.
1565
1566         * UIProcess/mac/ViewGestureController.mm: Renamed from Source/WebKit2/UIProcess/mac/ViewGestureController.cpp.
1567         * WebKit2.xcodeproj/project.pbxproj:
1568
1569 2014-01-21  Anders Carlsson  <andersca@apple.com>
1570
1571         Make all the WebKit2 headers private and move Cocoa UIProcess API headers to a Deprecated group
1572         https://bugs.webkit.org/show_bug.cgi?id=127374
1573
1574         Reviewed by Dan Bernstein.
1575
1576         * WebKit2.xcodeproj/project.pbxproj:
1577
1578 2014-01-21  Commit Queue  <commit-queue@webkit.org>
1579
1580         Unreviewed, rolling out r162452.
1581         http://trac.webkit.org/changeset/162452
1582         https://bugs.webkit.org/show_bug.cgi?id=127366
1583
1584         broke a few tests on all Mac WebKit1 bots (Requested by
1585         thorton on #webkit).
1586
1587         * WebProcess/WebPage/WebPage.cpp:
1588         (WebKit::WebPage::WebPage):
1589         (WebKit::WebPage::setActive):
1590         (WebKit::WebPage::setViewIsVisible):
1591         (WebKit::WebPage::setFocused):
1592         (WebKit::WebPage::setIsInWindow):
1593         (WebKit::WebPage::setViewStateInternal):
1594         (WebKit::WebPage::setIsVisuallyIdle):
1595         * WebProcess/WebPage/WebPage.h:
1596
1597 2014-01-21  Martin Hock  <mhock@apple.com>
1598
1599         Trivial Session API cleanup.
1600         https://bugs.webkit.org/show_bug.cgi?id=127356
1601
1602         Reviewed by Alexey Proskuryakov.
1603
1604         * UIProcess/API/C/WKSessionRef.cpp:
1605         (WKSessionIsEphemeral):
1606         * UIProcess/API/C/WKSessionRef.h:
1607
1608 2014-01-16  Simon Fraser  <simon.fraser@apple.com>
1609
1610         Log an error for a common cause of WebProcess early launch crashing in misconfigured development builds
1611         https://bugs.webkit.org/show_bug.cgi?id=127121
1612
1613         Reviewed by Anders Carlsson.
1614         
1615         A common cause of early WebProcess crashes during development is a null return
1616         from CFBundleGetValueForInfoDictionaryKey(), so log and return an error in
1617         this case rather than passing a null C string to dlsym().
1618
1619         * Shared/EntryPointUtilities/mac/LegacyProcess/ChildProcessMain.mm:
1620         (WebKit::BootstrapMain):
1621
1622 2014-01-21  Tim Horton  <timothy_horton@apple.com>
1623
1624         Sort headers after the rename that happened in r162454.
1625
1626         * UIProcess/mac/RemoteLayerTreeHost.mm:
1627         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm:
1628
1629 2014-01-21  Tim Horton  <timothy_horton@apple.com>
1630
1631         Address late review naming comments after r162453.
1632
1633         * UIProcess/API/mac/WKView.mm:
1634         And, fix the build by adding an include I accidentally missed.
1635
1636         * UIProcess/mac/RemoteLayerTreeHost.mm:
1637         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm:
1638
1639 2014-01-21  Tim Horton  <timothy_horton@apple.com>
1640
1641         Keep CALayer implicit animation disabling code in a single place
1642         https://bugs.webkit.org/show_bug.cgi?id=127355
1643
1644         Reviewed by Simon Fraser.
1645
1646         * Shared/mac/RemoteLayerTreePropertyApplier.h:
1647         * Shared/mac/RemoteLayerTreePropertyApplier.mm:
1648         Remove disableActionsForLayer.
1649
1650         * UIProcess/API/mac/WKView.mm:
1651         (-[WKView _rootLayer]):
1652         Disable actions on the root layer. It doesn't need them, and currently
1653         isn't affected by implicit animations, but future patches which animate
1654         the root layer will benefit from this.
1655
1656         * UIProcess/mac/RemoteLayerTreeHost.mm:
1657         (WebKit::RemoteLayerTreeHost::createLayer):
1658         Use web_disableAllActions instead of disableActionsForLayer.
1659
1660         * WebKit2.xcodeproj/project.pbxproj:
1661         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm: Renamed from Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.cpp.
1662         (PlatformCALayerRemoteCustom::PlatformCALayerRemoteCustom):
1663         (PlatformCALayerRemoteCustom::~PlatformCALayerRemoteCustom):
1664         (PlatformCALayerRemoteCustom::hostingContextID):
1665         Use web_disableAllActions instead of disableActionsForLayer.
1666         This requires making this file Obj-C++ but that's OK since it's Mac/iOS only.
1667
1668 2014-01-21  Gavin Barraclough  <barraclough@apple.com>
1669
1670         Change Page, FocusController to use ViewState
1671         https://bugs.webkit.org/show_bug.cgi?id=126533
1672
1673         Reviewed by Tim Horton.
1674
1675         These classes currently maintain a set of separate fields to represent the view state;
1676         combine these into a single field, and allow WebPage to send the combined update rather
1677         than individual changes.
1678
1679         Maintain existing interface for WebKit1 clients.
1680
1681         * WebProcess/WebPage/WebPage.cpp:
1682         (WebKit::WebPage::WebPage):
1683             - Combined separate calls to Page::setViewState.
1684         (WebKit::WebPage::updateIsInWindow):
1685             - Simplied from setIsInWindow.
1686         (WebKit::WebPage::setViewState):
1687             - Combined separate calls to Page::setViewState.
1688         * WebProcess/WebPage/WebPage.h:
1689             - Declare updateIsInWindow.
1690
1691 2014-01-21  Carlos Garcia Campos  <cgarcia@igalia.com>
1692
1693         [SOUP] Implement CUSTOM PROTOCOLS
1694         https://bugs.webkit.org/show_bug.cgi?id=125583
1695
1696         Reviewed by Anders Carlsson.
1697
1698         Add new classes to implement CustomProtocols for soup. The
1699         implementation is the same, but using the CustomProtocol API and
1700         messages. The current implementation can be removed once all ports
1701         using soup switch to using CustomProtocols.
1702
1703         * GNUmakefile.am: Add new include paths.
1704         * GNUmakefile.list.am: Add new files to compilation.
1705         * PlatformGTK.cmake: Add new files to compilation.
1706         * Shared/API/c/soup/WKBaseSoup.h:
1707         * Shared/APIObject.h:
1708         * Shared/Network/CustomProtocols/CustomProtocolManager.h:
1709         * Shared/Network/CustomProtocols/soup/CustomProtocolManagerImpl.cpp: Added.
1710         (WebKit::generateCustomProtocolID):
1711         (WebKit::WebSoupRequestAsyncData::WebSoupRequestAsyncData):
1712         (WebKit::WebSoupRequestAsyncData::~WebSoupRequestAsyncData):
1713         (WebKit::WebSoupRequestAsyncData::requestFailed):
1714         (WebKit::WebSoupRequestAsyncData::releaseTask):
1715         (WebKit::CustomProtocolManagerImpl::CustomProtocolManagerImpl):
1716         (WebKit::CustomProtocolManagerImpl::~CustomProtocolManagerImpl):
1717         (WebKit::CustomProtocolManagerImpl::registerScheme):
1718         (WebKit::CustomProtocolManagerImpl::supportsScheme):
1719         (WebKit::CustomProtocolManagerImpl::didFailWithError):
1720         (WebKit::CustomProtocolManagerImpl::didLoadData):
1721         (WebKit::CustomProtocolManagerImpl::didReceiveResponse):
1722         (WebKit::CustomProtocolManagerImpl::didFinishLoading):
1723         (WebKit::CustomProtocolManagerImpl::send):
1724         (WebKit::CustomProtocolManagerImpl::finish):
1725         * Shared/Network/CustomProtocols/soup/CustomProtocolManagerImpl.h: Added.
1726         * Shared/Network/CustomProtocols/soup/CustomProtocolManagerSoup.cpp:
1727         (WebKit::CustomProtocolManager::CustomProtocolManager):
1728         (WebKit::CustomProtocolManager::initialize):
1729         (WebKit::CustomProtocolManager::registerScheme):
1730         (WebKit::CustomProtocolManager::supportsScheme):
1731         (WebKit::CustomProtocolManager::didFailWithError):
1732         (WebKit::CustomProtocolManager::didLoadData):
1733         (WebKit::CustomProtocolManager::didReceiveResponse):
1734         (WebKit::CustomProtocolManager::didFinishLoading):
1735         * Shared/WebProcessCreationParameters.cpp:
1736         (WebKit::WebProcessCreationParameters::encode):
1737         (WebKit::WebProcessCreationParameters::decode):
1738         * Shared/WebProcessCreationParameters.h:
1739         * UIProcess/API/C/soup/WKAPICastSoup.h:
1740         * UIProcess/API/C/soup/WKSoupCustomProtocolRequestManager.cpp: Copied from Source/WebKit2/UIProcess/soup/WebContextSoup.cpp.
1741         (WKSoupCustomProtocolRequestManagerGetTypeID):
1742         (WKSoupCustomProtocolRequestManagerSetClient):
1743         * UIProcess/API/C/soup/WKSoupCustomProtocolRequestManager.h: Added.
1744         * UIProcess/Network/CustomProtocols/CustomProtocolManagerProxy.h:
1745         * UIProcess/Network/CustomProtocols/mac/CustomProtocolManagerProxyMac.mm:
1746         (WebKit::CustomProtocolManagerProxy::CustomProtocolManagerProxy):
1747         * UIProcess/Network/CustomProtocols/soup/CustomProtocolManagerProxySoup.cpp:
1748         (WebKit::CustomProtocolManagerProxy::CustomProtocolManagerProxy):
1749         (WebKit::CustomProtocolManagerProxy::startLoading):
1750         (WebKit::CustomProtocolManagerProxy::stopLoading):
1751         * UIProcess/Network/CustomProtocols/soup/WebSoupCustomProtocolRequestManager.cpp: Added.
1752         (WebKit::WebSoupCustomProtocolRequestManager::supplementName):
1753         (WebKit::WebSoupCustomProtocolRequestManager::create):
1754         (WebKit::WebSoupCustomProtocolRequestManager::WebSoupCustomProtocolRequestManager):
1755         (WebKit::WebSoupCustomProtocolRequestManager::~WebSoupCustomProtocolRequestManager):
1756         (WebKit::WebSoupCustomProtocolRequestManager::initializeClient):
1757         (WebKit::WebSoupCustomProtocolRequestManager::contextDestroyed):
1758         (WebKit::WebSoupCustomProtocolRequestManager::processDidClose):
1759         (WebKit::WebSoupCustomProtocolRequestManager::refWebContextSupplement):
1760         (WebKit::WebSoupCustomProtocolRequestManager::derefWebContextSupplement):
1761         (WebKit::WebSoupCustomProtocolRequestManager::registerSchemeForCustomProtocol):
1762         (WebKit::WebSoupCustomProtocolRequestManager::unregisterSchemeForCustomProtocol):
1763         (WebKit::WebSoupCustomProtocolRequestManager::startLoading):
1764         (WebKit::WebSoupCustomProtocolRequestManager::stopLoading):
1765         (WebKit::WebSoupCustomProtocolRequestManager::didReceiveResponse):
1766         (WebKit::WebSoupCustomProtocolRequestManager::didLoadData):
1767         (WebKit::WebSoupCustomProtocolRequestManager::didFailWithError):
1768         (WebKit::WebSoupCustomProtocolRequestManager::didFinishLoading):
1769         * UIProcess/Network/CustomProtocols/soup/WebSoupCustomProtocolRequestManager.h: Added.
1770         (WebKit::WebSoupCustomProtocolRequestManager::registeredSchemesForCustomProtocols):
1771         * UIProcess/Network/CustomProtocols/soup/WebSoupCustomProtocolRequestManagerClient.cpp: Added.
1772         (WebKit::WebSoupCustomProtocolRequestManagerClient::startLoading):
1773         (WebKit::WebSoupCustomProtocolRequestManagerClient::stopLoading):
1774         * UIProcess/Network/CustomProtocols/soup/WebSoupCustomProtocolRequestManagerClient.h: Added.
1775         * UIProcess/Network/NetworkProcessProxy.cpp:
1776         (WebKit::NetworkProcessProxy::NetworkProcessProxy):
1777         * UIProcess/WebContext.cpp:
1778         (WebKit::WebContext::WebContext):
1779         * UIProcess/WebPageProxy.cpp:
1780         * UIProcess/WebPageProxy.h:
1781         * UIProcess/WebPageProxy.messages.in:
1782         * UIProcess/WebProcessProxy.cpp:
1783         (WebKit::WebProcessProxy::WebProcessProxy):
1784         * UIProcess/gtk/WebContextGtk.cpp:
1785         (WebKit::WebContext::platformInitializeWebProcess):
1786         * UIProcess/soup/WebContextSoup.cpp:
1787         (WebKit::WebContext::platformInitializeNetworkProcess):
1788         * WebProcess/WebProcess.cpp:
1789         (WebKit::WebProcess::WebProcess):
1790         * WebProcess/soup/WebKitSoupRequestGeneric.cpp:
1791         (webkitSoupRequestGenericSendAsync):
1792         (webkitSoupRequestGenericSendFinish):
1793         * WebProcess/soup/WebKitSoupRequestGeneric.h:
1794         * WebProcess/soup/WebProcessSoup.cpp:
1795         (WebKit::WebProcess::platformInitializeWebProcess):
1796
1797 2014-01-21  Adrian Perez de Castro  <aperez@igalia.com>
1798
1799         [GTK] Allow passing extra data to web extensions
1800         https://bugs.webkit.org/show_bug.cgi?id=125990
1801
1802         Reviewed by Carlos Garcia Campos.
1803
1804         Allow passing additional information to the injected bundle. On top
1805         of the string containing the path to the web extensions directory,
1806         a GVariant can be set with additional data using
1807         webkit_web_context_set_web_extensions_initialization_user_data().
1808         Also, a new initialize-web-extensions signal is emitted before
1809         launching a new WebProcess to allow setting different user data
1810         for each process. The GVariant is serialized as a string, passed
1811         to the injected bundle, and the injected bundle deserializes back
1812         the data, which is passed to web extensions which define the
1813         webkit_web_extension_initialize_with_user_data() function (for
1814         backwards compatibility, webkit_web_extension_initialize() is
1815         used as a fallback.)
1816
1817         * UIProcess/API/gtk/WebKitInjectedBundleClient.cpp:
1818         (getInjectedBundleInitializationUserData): Define new callback
1819         function which causes emission of the initialize-web-extensions
1820         signal, and serializes the data to be passed to the web process.
1821         (attachInjectedBundleClientToContext): Set the
1822         getInjectedBundleInitializationUserData() callback.
1823         * UIProcess/API/gtk/WebKitWebContext.cpp:
1824         (webkit_web_context_class_init): Define the
1825         initialize-web-extensions signal.
1826         (webkit_web_context_set_web_extensions_directory):
1827         Web extensions directory as now member of WebKitWebContextPrivate,
1828         to be able to retrieve it later.
1829         (webkit_web_context_set_web_extensions_initialization_user_data):
1830         New API method to set the user data passed to the web extensions
1831         when initialized.
1832         (webkitWebContextInitializeWebExtensions): Private function used
1833         to trigger emission of the initialize-web-extensions signal.
1834         * UIProcess/API/gtk/WebKitWebContext.h:
1835         Added prototype for new API method
1836         webkit_web_context_set_web_extensions_initialization_user_data().
1837         * UIProcess/API/gtk/WebKitWebContextPrivate.h:
1838         Prototype of the new private function.
1839         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
1840         Add new public API bits to the documentation.
1841         * WebProcess/gtk/WebGtkExtensionManager.cpp:
1842         (WebKit::WebGtkExtensionManager::initialize):
1843         Deserialize the data received from the UI process and pass it to
1844         webkit_web_extension_initialize_with_user_data() if available,
1845         keeping webkit_web_extension_initialize() as fallback.
1846
1847 2014-01-20  Ryuan Choi  <ryuan.choi@samsung.com>
1848
1849         [EFL][WK2] Move isEwkViewEvasObject back to ewk_view.cpp
1850         https://bugs.webkit.org/show_bug.cgi?id=127261
1851
1852         Reviewed by Gyuyoung Kim.
1853
1854         isEwkViewEvasObject is general check routine of EFL and mainly used in
1855         ewk_view.cpp but it was in EwkView.cpp since separated EwkView.cpp from ewk_view.cpp
1856
1857         This patch moves it to EwkView.h as inline function with small refactoring.
1858         In addition, this patch added EINA_UNLIKELY keyword in cold paths.
1859
1860         * UIProcess/API/efl/EwkView.cpp:
1861         (defaultSmartClassInstance):
1862         (toSmartData):
1863         (toEwkView): Moved it from bottom not to expose it to header file.
1864         * UIProcess/API/efl/EwkView.h:
1865         * UIProcess/API/efl/ewk_view.cpp:
1866         (isEwkViewEvasObject):
1867         (toEwkViewChecked):
1868
1869 2014-01-20  Eunmi Lee  <eunmi15.lee@samsung.com>
1870
1871         [EFL][WK2] Amount of scrolling is different from movement of touch when device pixel ratio is not 1.
1872         https://bugs.webkit.org/show_bug.cgi?id=127268
1873
1874         Reviewed by Gyuyoung Kim.
1875
1876         Amount of scrolling should be same with movement of touch even though
1877         device pixel ratio is not 1, so apply device pixel ratio to the new
1878         position of scrollBy().
1879
1880         * UIProcess/API/efl/EwkView.cpp:
1881         (EwkView::scrollBy):
1882
1883 2014-01-20  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1884
1885         [WK2] Setting m_pageScaleFactor directly in WebPageProxy::scalePage
1886         https://bugs.webkit.org/show_bug.cgi?id=127090
1887
1888         Reviewed by Simon Fraser.
1889
1890         When the client side sets the scale factor, the UIProcess will send the message to WebProcess and only after
1891         WebPageProxy::pageScaleFactorDidChange is called the desired scale factor is returned correctly by
1892         WebPageProxy::pageScaleFactor.
1893         This will avoid the client side retrieve a wrong scale factor while UIProcess and WebProcess gets synchronized.
1894
1895         * UIProcess/WebPageProxy.cpp:
1896         (WebKit::WebPageProxy::scalePage):
1897
1898 2014-01-20  Zan Dobersek  <zdobersek@igalia.com>
1899
1900         [GTK][WK2] Move the rest of GTK's WorkQueue implementation to std::function
1901         https://bugs.webkit.org/show_bug.cgi?id=127273
1902
1903         Reviewed by Anders Carlsson.
1904
1905         Move to using std::function and move semantics in WorkQueue::registerSocketEventHandler
1906         and WorkQueue::SocketEventSource.
1907
1908         * Platform/IPC/unix/ConnectionUnix.cpp:
1909         (IPC::Connection::open):
1910         * Platform/WorkQueue.h:
1911         * Platform/gtk/WorkQueueGtk.cpp:
1912         (WorkQueue::SocketEventSource::SocketEventSource):
1913         (WorkQueue::registerSocketEventHandler):
1914         (WorkQueue::dispatchOnSource): Use std::move instead of std::forward<T>.
1915         (WorkQueue::dispatch): Ditto.
1916         (WorkQueue::dispatchAfter): Ditto.
1917
1918 2014-01-20  Zan Dobersek  <zdobersek@igalia.com>
1919
1920         Unreviewed. Additional build fixes after r162276 and r163304.
1921
1922         * Platform/WorkQueue.h:
1923         * Platform/gtk/WorkQueueGtk.cpp:
1924         (WorkQueue::EventSource::EventSource):
1925         (WorkQueue::dispatchOnSource):
1926         (WorkQueue::dispatch):
1927         (WorkQueue::dispatchAfter):
1928
1929 2014-01-19  Zan Dobersek  <zdobersek@igalia.com>
1930
1931         Unreviewed GTK build fix after r162276.
1932
1933         Updating the WorkQueue implementation to use std::function and std::chrono.
1934
1935         * Platform/WorkQueue.h:
1936         * Platform/gtk/WorkQueueGtk.cpp:
1937         (WorkQueue::dispatchOnSource):
1938         (WorkQueue::dispatch):
1939         (WorkQueue::dispatchAfter):
1940
1941 2014-01-19  Jinwoo Song  <jinwoo7.song@samsung.com>
1942
1943         Unreviewed debug build fix on EFL port after r162300.
1944
1945         * Platform/efl/DispatchQueueWorkItemEfl.h:
1946         (TimerWorkItem::create):
1947
1948 2014-01-19  Jinwoo Song  <jinwoo7.song@samsung.com>
1949
1950         [EFL][WK2] build fix after r162276
1951         https://bugs.webkit.org/show_bug.cgi?id=127259
1952
1953         Reviewed by Anders Carlsson.
1954
1955         * Platform/efl/DispatchQueueEfl.cpp:
1956         (DispatchQueue::performTimerWork):
1957         (DispatchQueue::getNextTimeOut):
1958         * Platform/efl/DispatchQueueWorkItemEfl.h:
1959         (WorkItem::create):
1960         (WorkItem::WorkItem):
1961         (TimerWorkItem::create):
1962         (TimerWorkItem::TimerWorkItem):
1963         * Platform/efl/WorkQueueEfl.cpp:
1964         (WorkQueue::dispatch):
1965         (WorkQueue::dispatchAfter):
1966
1967 2014-01-18  Anders Carlsson  <andersca@apple.com>
1968
1969         Replace a couple of uses of WTF::Function with std::function
1970         https://bugs.webkit.org/show_bug.cgi?id=127218
1971
1972         Reviewed by Andreas Kling.
1973
1974         * Platform/IPC/mac/ConnectionMac.cpp:
1975         (IPC::createDataAvailableSource):
1976         * Platform/WorkQueue.h:
1977         * Platform/mac/WorkQueueMac.cpp:
1978         (WorkQueue::dispatch):
1979         (WorkQueue::dispatchAfter):
1980         * Shared/ChildProcess.cpp:
1981         (WebKit::didCloseOnConnectionWorkQueue):
1982         * UIProcess/Storage/LocalStorageDatabase.cpp:
1983         (WebKit::LocalStorageDatabase::scheduleDatabaseUpdate):
1984         * WebProcess/WebPage/DrawingArea.cpp:
1985         (WebKit::DrawingArea::dispatchAfterEnsuringUpdatedScrollPosition):
1986         * WebProcess/WebPage/DrawingArea.h:
1987         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
1988         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1989         (WebKit::TiledCoreAnimationDrawingArea::dispatchAfterEnsuringUpdatedScrollPosition):
1990
1991 2014-01-18  Martin Hock  <mhock@apple.com>
1992
1993         Flesh out session APIs (still not enabled at API level).
1994         https://bugs.webkit.org/show_bug.cgi?id=126918
1995
1996         Reviewed by Alexey Proskuryakov.
1997
1998         * CMakeLists.txt:
1999         * GNUmakefile.list.am:
2000         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
2001         (WebKit::storageSession):
2002         (WebKit::NetworkConnectionToWebProcess::startDownload):
2003         (WebKit::NetworkConnectionToWebProcess::cookiesForDOM):
2004         (WebKit::NetworkConnectionToWebProcess::setCookiesFromDOM):
2005         (WebKit::NetworkConnectionToWebProcess::cookiesEnabled):
2006         (WebKit::NetworkConnectionToWebProcess::cookieRequestHeaderFieldValue):
2007         (WebKit::NetworkConnectionToWebProcess::getRawCookies):
2008         (WebKit::NetworkConnectionToWebProcess::deleteCookie):
2009         * NetworkProcess/NetworkConnectionToWebProcess.h:
2010         * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
2011         * NetworkProcess/NetworkProcess.cpp:
2012         (WebKit::NetworkProcess::initializeNetworkProcess):
2013         (WebKit::NetworkProcess::ensurePrivateBrowsingSession):
2014         (WebKit::NetworkProcess::destroyPrivateBrowsingSession):
2015         * NetworkProcess/NetworkProcess.h:
2016         * NetworkProcess/NetworkProcess.messages.in:
2017         * NetworkProcess/RemoteNetworkingContext.h:
2018         * NetworkProcess/mac/RemoteNetworkingContext.mm:
2019         (WebKit::RemoteNetworkingContext::storageSession):
2020         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
2021         * NetworkProcess/soup/RemoteNetworkingContextSoup.cpp:
2022         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
2023         * Shared/SessionTracker.cpp: Copied from Source/WebKit2/UIProcess/APISession.cpp.
2024         (WebKit::sessionMap):
2025         (WebKit::identifierBase):
2026         (WebKit::SessionTracker::getSessionMap):
2027         (WebKit::SessionTracker::getIdentifierBase):
2028         (WebKit::SessionTracker::session):
2029         (WebKit::SessionTracker::destroySession):
2030         (WebKit::SessionTracker::setIdentifierBase):
2031         * Shared/SessionTracker.h: Copied from Source/WebKit2/UIProcess/APISession.h.
2032         (WebKit::SessionTracker::isEphemeralID):
2033         * Shared/mac/CookieStorageShim.cpp:
2034         (WebKit::webKitCookieStorageCopyRequestHeaderFieldsForURL):
2035         * UIProcess/APISession.cpp:
2036         (API::generateID):
2037         (API::Session::defaultSession):
2038         (API::Session::legacyPrivateSession):
2039         (API::Session::Session):
2040         (API::Session::create):
2041         (API::Session::isEphemeral):
2042         (API::Session::getID):
2043         * UIProcess/APISession.h:
2044         * UIProcess/WebContext.cpp:
2045         (WebKit::WebContext::setAnyPageGroupMightHavePrivateBrowsingEnabled):
2046         (WebKit::WebContext::createNewWebProcess):
2047         (WebKit::WebContext::createWebPage):
2048         * UIProcess/WebContext.h:
2049         * UIProcess/WebPageProxy.cpp:
2050         (WebKit::WebPageProxy::create):
2051         (WebKit::WebPageProxy::WebPageProxy):
2052         * UIProcess/WebPageProxy.h:
2053         (WebKit::WebPageProxy::sessionID):
2054         * UIProcess/WebProcessProxy.cpp:
2055         (WebKit::WebProcessProxy::createWebPage):
2056         * UIProcess/WebProcessProxy.h:
2057         * WebKit2.xcodeproj/project.pbxproj:
2058         * WebProcess/InjectedBundle/InjectedBundle.cpp:
2059         (WebKit::InjectedBundle::setPrivateBrowsingEnabled):
2060         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
2061         (WebKit::legacySessionID):
2062         (WebKit::WebPlatformStrategies::cookiesForDOM):
2063         (WebKit::WebPlatformStrategies::setCookiesFromDOM):
2064         (WebKit::WebPlatformStrategies::cookiesEnabled):
2065         (WebKit::WebPlatformStrategies::cookieRequestHeaderFieldValue):
2066         (WebKit::WebPlatformStrategies::getRawCookies):
2067         (WebKit::WebPlatformStrategies::deleteCookie):
2068         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
2069         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
2070         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
2071         (WebKit::WebFrameNetworkingContext::setCookieAcceptPolicyForAllContexts):
2072         (WebKit::WebFrameNetworkingContext::storageSession):
2073         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
2074         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
2075         (WebKit::WebFrameNetworkingContext::storageSession):
2076         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h:
2077         * WebProcess/WebProcess.cpp:
2078         (WebKit::WebProcess::initializeWebProcess):
2079         (WebKit::WebProcess::ensurePrivateBrowsingSession):
2080         (WebKit::WebProcess::destroyPrivateBrowsingSession):
2081         * WebProcess/WebProcess.h:
2082         * WebProcess/WebProcess.messages.in:
2083
2084 2014-01-18  Brian Burg  <bburg@apple.com>
2085
2086         Web Inspector: Page should use std::unique_ptr for InspectorController
2087         https://bugs.webkit.org/show_bug.cgi?id=127068
2088
2089         Reviewed by Joseph Pecoraro.
2090
2091         Convert call sites to use a InspectorController reference.
2092
2093         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
2094         (WebKit::WebInspectorClient::drawRect):
2095         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
2096         (WebKit::WebInspectorFrontendClient::WebInspectorFrontendClient):
2097         (WebKit::WebInspectorFrontendClient::closeWindow):
2098         * WebProcess/WebPage/WebInspector.cpp:
2099         (WebKit::WebInspector::createInspectorPage):
2100         (WebKit::WebInspector::show):
2101         (WebKit::WebInspector::close):
2102         (WebKit::WebInspector::evaluateScriptForTest):
2103         (WebKit::WebInspector::showConsole):
2104         (WebKit::WebInspector::showResources):
2105         (WebKit::WebInspector::showMainResourceForFrame):
2106         (WebKit::WebInspector::startJavaScriptDebugging):
2107         (WebKit::WebInspector::stopJavaScriptDebugging):
2108         (WebKit::WebInspector::setJavaScriptProfilingEnabled):
2109         (WebKit::WebInspector::startJavaScriptProfiling):
2110         (WebKit::WebInspector::stopJavaScriptProfiling):
2111         (WebKit::WebInspector::startPageProfiling):
2112         (WebKit::WebInspector::stopPageProfiling):
2113         (WebKit::WebInspector::dispatchMessageFromRemoteFrontend):
2114         (WebKit::WebInspector::remoteFrontendConnected):
2115         (WebKit::WebInspector::remoteFrontendDisconnected):
2116
2117 2014-01-18  Anders Carlsson  <andersca@apple.com>
2118
2119         Remove ENABLE_THREADED_HTML_PARSER defines everywhere
2120         https://bugs.webkit.org/show_bug.cgi?id=127225
2121
2122         Reviewed by Andreas Kling.
2123
2124         This concludes the removal of over 8.8 million lines of threaded parser code.
2125
2126         * Configurations/FeatureDefines.xcconfig:
2127
2128 2014-01-18  Yongjun Zhang  <yongjun_zhang@apple.com>
2129
2130         Make WKRenderingProgressEvents a shareable API.
2131         https://bugs.webkit.org/show_bug.cgi?id=127213
2132
2133         Reviewed by Dan Bernstein.
2134
2135         Move WKRenderingProgressEvents from UIProcess to Shared, so that an inject bundle
2136         could also use this enum when listening to layout milestones.
2137
2138         * Shared/API/Cocoa/WKRenderingProgressEvents.h: Added.
2139         (NS_OPTIONS):
2140         * Shared/API/Cocoa/WKRenderingProgressEventsInternal.h: Added.
2141         (renderingProgressEvents):
2142         * UIProcess/API/Cocoa/WKBrowsingContextController.h: Move WKRenderingProgressEvents to Shared/API/Cocoa/WKRenderingProgressEvents.h.
2143         * UIProcess/API/Cocoa/WKBrowsingContextController.mm: Move renderingProgressEvents() to WKRenderingProgressEventsInternal.h.
2144         * WebKit2.xcodeproj/project.pbxproj:
2145         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInLoadDelegate.h: Add
2146             webProcessPlugInBrowserContextController:renderingProgressDidChange: to load delegate.
2147         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
2148         (didLayout):
2149         (setUpPageLoaderClient): Also listen to didLayout callback for layout milestones.
2150
2151 2014-01-17  Commit Queue  <commit-queue@webkit.org>
2152
2153         Unreviewed, rolling out r162237 and r162241.
2154         http://trac.webkit.org/changeset/162237
2155         http://trac.webkit.org/changeset/162241
2156         https://bugs.webkit.org/show_bug.cgi?id=127216
2157
2158         Broke lots of API tests (Requested by ap on #webkit).
2159
2160         * CMakeLists.txt:
2161         * GNUmakefile.list.am:
2162         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
2163         (WebKit::storageSession):
2164         (WebKit::NetworkConnectionToWebProcess::startDownload):
2165         (WebKit::NetworkConnectionToWebProcess::cookiesForDOM):
2166         (WebKit::NetworkConnectionToWebProcess::setCookiesFromDOM):
2167         (WebKit::NetworkConnectionToWebProcess::cookiesEnabled):
2168         (WebKit::NetworkConnectionToWebProcess::cookieRequestHeaderFieldValue):
2169         (WebKit::NetworkConnectionToWebProcess::getRawCookies):
2170         (WebKit::NetworkConnectionToWebProcess::deleteCookie):
2171         * NetworkProcess/NetworkConnectionToWebProcess.h:
2172         * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
2173         * NetworkProcess/NetworkProcess.cpp:
2174         (WebKit::NetworkProcess::initializeNetworkProcess):
2175         (WebKit::NetworkProcess::ensurePrivateBrowsingSession):
2176         (WebKit::NetworkProcess::destroyPrivateBrowsingSession):
2177         * NetworkProcess/NetworkProcess.h:
2178         * NetworkProcess/NetworkProcess.messages.in:
2179         * NetworkProcess/RemoteNetworkingContext.h:
2180         * NetworkProcess/mac/RemoteNetworkingContext.mm:
2181         (WebKit::privateBrowsingStorageSession):
2182         (WebKit::RemoteNetworkingContext::storageSession):
2183         (WebKit::RemoteNetworkingContext::privateBrowsingSession):
2184         (WebKit::privateBrowsingStorageSessionIdentifierBase):
2185         (WebKit::RemoteNetworkingContext::setPrivateBrowsingStorageSessionIdentifierBase):
2186         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
2187         (WebKit::RemoteNetworkingContext::destroyPrivateBrowsingSession):
2188         * NetworkProcess/soup/RemoteNetworkingContextSoup.cpp:
2189         (WebKit::RemoteNetworkingContext::setPrivateBrowsingStorageSessionIdentifierBase):
2190         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
2191         (WebKit::RemoteNetworkingContext::destroyPrivateBrowsingSession):
2192         (WebKit::RemoteNetworkingContext::privateBrowsingSession):
2193         * Shared/SessionTracker.cpp: Removed.
2194         * Shared/SessionTracker.h: Removed.
2195         * UIProcess/APISession.cpp:
2196         (API::Session::Session):
2197         (API::Session::create):
2198         (API::Session::isEphemeral):
2199         * UIProcess/APISession.h:
2200         * UIProcess/WebContext.cpp:
2201         (WebKit::WebContext::setAnyPageGroupMightHavePrivateBrowsingEnabled):
2202         (WebKit::WebContext::createNewWebProcess):
2203         (WebKit::WebContext::createWebPage):
2204         * UIProcess/WebContext.h:
2205         * UIProcess/WebPageProxy.cpp:
2206         (WebKit::WebPageProxy::create):
2207         (WebKit::WebPageProxy::WebPageProxy):
2208         * UIProcess/WebPageProxy.h:
2209         * UIProcess/WebProcessProxy.cpp:
2210         (WebKit::WebProcessProxy::createWebPage):
2211         * UIProcess/WebProcessProxy.h:
2212         * WebKit2.xcodeproj/project.pbxproj:
2213         * WebProcess/InjectedBundle/InjectedBundle.cpp:
2214         (WebKit::InjectedBundle::setPrivateBrowsingEnabled):
2215         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
2216         (WebKit::WebPlatformStrategies::cookiesForDOM):
2217         (WebKit::WebPlatformStrategies::setCookiesFromDOM):
2218         (WebKit::WebPlatformStrategies::cookiesEnabled):
2219         (WebKit::WebPlatformStrategies::cookieRequestHeaderFieldValue):
2220         (WebKit::WebPlatformStrategies::getRawCookies):
2221         (WebKit::WebPlatformStrategies::deleteCookie):
2222         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
2223         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
2224         (WebKit::privateSession):
2225         (WebKit::identifierBase):
2226         (WebKit::WebFrameNetworkingContext::setPrivateBrowsingStorageSessionIdentifierBase):
2227         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
2228         (WebKit::WebFrameNetworkingContext::destroyPrivateBrowsingSession):
2229         (WebKit::WebFrameNetworkingContext::setCookieAcceptPolicyForAllContexts):
2230         (WebKit::WebFrameNetworkingContext::storageSession):
2231         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
2232         (WebKit::privateSession):
2233         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
2234         (WebKit::WebFrameNetworkingContext::destroyPrivateBrowsingSession):
2235         (WebKit::WebFrameNetworkingContext::storageSession):
2236         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h:
2237         * WebProcess/WebProcess.cpp:
2238         (WebKit::WebProcess::initializeWebProcess):
2239         (WebKit::WebProcess::ensurePrivateBrowsingSession):
2240         (WebKit::WebProcess::destroyPrivateBrowsingSession):
2241         * WebProcess/WebProcess.h:
2242         * WebProcess/WebProcess.messages.in:
2243
2244 2014-01-17  Ryuan Choi  <ryuan.choi@samsung.com>
2245
2246         Unreviewed build fix on EFL port after r162237
2247
2248         The EFL port disabled NETWORK_PROCESS yet and use -Werror=unused-function.
2249
2250         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
2251         Guarded legacySessionID with ENABLE(NETWORK_PROCESS)
2252
2253 2014-01-17  Martin Hock  <mhock@apple.com>
2254
2255         Flesh out session APIs (still not enabled at API level).
2256         https://bugs.webkit.org/show_bug.cgi?id=126918
2257
2258         Reviewed by Alexey Proskuryakov.
2259
2260         * CMakeLists.txt:
2261         * GNUmakefile.list.am:
2262         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
2263         (WebKit::storageSession):
2264         (WebKit::NetworkConnectionToWebProcess::startDownload):
2265         (WebKit::NetworkConnectionToWebProcess::cookiesForDOM):
2266         (WebKit::NetworkConnectionToWebProcess::setCookiesFromDOM):
2267         (WebKit::NetworkConnectionToWebProcess::cookiesEnabled):
2268         (WebKit::NetworkConnectionToWebProcess::cookieRequestHeaderFieldValue):
2269         (WebKit::NetworkConnectionToWebProcess::getRawCookies):
2270         (WebKit::NetworkConnectionToWebProcess::deleteCookie):
2271         * NetworkProcess/NetworkConnectionToWebProcess.h:
2272         * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
2273         * NetworkProcess/NetworkProcess.cpp:
2274         (WebKit::NetworkProcess::initializeNetworkProcess):
2275         (WebKit::NetworkProcess::ensurePrivateBrowsingSession):
2276         (WebKit::NetworkProcess::destroyPrivateBrowsingSession):
2277         * NetworkProcess/NetworkProcess.h:
2278         * NetworkProcess/NetworkProcess.messages.in:
2279         * NetworkProcess/RemoteNetworkingContext.h:
2280         * NetworkProcess/mac/RemoteNetworkingContext.mm:
2281         (WebKit::RemoteNetworkingContext::storageSession):
2282         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
2283         * NetworkProcess/soup/RemoteNetworkingContextSoup.cpp:
2284         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
2285         * Shared/SessionTracker.cpp: Copied from Source/WebKit2/UIProcess/APISession.cpp.
2286         (WebKit::sessionMap):
2287         (WebKit::identifierBase):
2288         (WebKit::SessionTracker::getSessionMap):
2289         (WebKit::SessionTracker::getIdentifierBase):
2290         (WebKit::SessionTracker::session):
2291         (WebKit::SessionTracker::destroySession):
2292         (WebKit::SessionTracker::setIdentifierBase):
2293         * Shared/SessionTracker.h: Copied from Source/WebKit2/UIProcess/APISession.h.
2294         (WebKit::SessionTracker::isEphemeralID):
2295         * UIProcess/APISession.cpp:
2296         (API::generateID):
2297         (API::Session::defaultSession):
2298         (API::Session::legacyPrivateSession):
2299         (API::Session::Session):
2300         (API::Session::create):
2301         (API::Session::isEphemeral):
2302         (API::Session::getID):
2303         * UIProcess/APISession.h:
2304         * UIProcess/WebContext.cpp:
2305         (WebKit::WebContext::setAnyPageGroupMightHavePrivateBrowsingEnabled):
2306         (WebKit::WebContext::createNewWebProcess):
2307         (WebKit::WebContext::createWebPage):
2308         * UIProcess/WebContext.h:
2309         * UIProcess/WebPageProxy.cpp:
2310         (WebKit::WebPageProxy::create):
2311         (WebKit::WebPageProxy::WebPageProxy):
2312         * UIProcess/WebPageProxy.h:
2313         (WebKit::WebPageProxy::sessionID):
2314         * UIProcess/WebProcessProxy.cpp:
2315         (WebKit::WebProcessProxy::createWebPage):
2316         * UIProcess/WebProcessProxy.h:
2317         * WebKit2.xcodeproj/project.pbxproj:
2318         * WebProcess/InjectedBundle/InjectedBundle.cpp:
2319         (WebKit::InjectedBundle::setPrivateBrowsingEnabled):
2320         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
2321         (WebKit::legacySessionID):
2322         (WebKit::WebPlatformStrategies::cookiesForDOM):
2323         (WebKit::WebPlatformStrategies::setCookiesFromDOM):
2324         (WebKit::WebPlatformStrategies::cookiesEnabled):
2325         (WebKit::WebPlatformStrategies::cookieRequestHeaderFieldValue):
2326         (WebKit::WebPlatformStrategies::getRawCookies):
2327         (WebKit::WebPlatformStrategies::deleteCookie):
2328         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
2329         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
2330         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
2331         (WebKit::WebFrameNetworkingContext::setCookieAcceptPolicyForAllContexts):
2332         (WebKit::WebFrameNetworkingContext::storageSession):
2333         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
2334         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
2335         (WebKit::WebFrameNetworkingContext::storageSession):
2336         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h:
2337         * WebProcess/WebProcess.cpp:
2338         (WebKit::WebProcess::initializeWebProcess):
2339         (WebKit::WebProcess::ensurePrivateBrowsingSession):
2340         (WebKit::WebProcess::destroyPrivateBrowsingSession):
2341         * WebProcess/WebProcess.h:
2342         * WebProcess/WebProcess.messages.in:
2343
2344 2014-01-17  Andreas Kling  <akling@apple.com>
2345
2346         Remove unused TOUCH_ADJUSTMENT code.
2347         <https://webkit.org/b/127181>
2348
2349         Reviewed by Anders Carlsson.
2350
2351         * WebProcess/WebPage/CoordinatedGraphics/WebPageCoordinatedGraphics.cpp:
2352         (WebKit::WebPage::findZoomableAreaForPoint):
2353
2354 2014-01-17  Anders Carlsson  <andersca@apple.com>
2355
2356         Fix build.
2357
2358         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2359         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2360
2361 2014-01-17  Anders Carlsson  <andersca@apple.com>
2362
2363         Remove FrameLoaderClient::didPerformFirstNavigation()
2364         https://bugs.webkit.org/show_bug.cgi?id=127191
2365
2366         Reviewed by Dan Bernstein.
2367
2368         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2369         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2370
2371 2014-01-17  Manuel Rego Casasnovas  <rego@igalia.com>
2372
2373         [GTK] Add CSS Grid Layout as experimental feature
2374         https://bugs.webkit.org/show_bug.cgi?id=127089
2375
2376         Reviewed by Martin Robinson.
2377
2378         Allow CSS Grid Layout to be enabled through the environment variable WEBKITGTK_EXPERIMENTAL_FEATURES.
2379
2380         Example: WEBKITGTK_EXPERIMENTAL_FEATURES="CSS_GRID_LAYOUT=1"
2381
2382         * UIProcess/API/gtk/WebKitSettings.cpp:
2383         (webKitSettingsConstructed): Use new experimental feature to enable or disable CSS Grid Layout.
2384         * UIProcess/gtk/ExperimentalFeatures.cpp: Add new experimental feature.
2385         * UIProcess/gtk/ExperimentalFeatures.h: Ditto.
2386
2387 2014-01-17  Enrica Casucci  <enrica@apple.com>
2388
2389         Support WebSelections in WK2 on iOS.
2390         https://bugs.webkit.org/show_bug.cgi?id=127015
2391         <rdar://problem/15843090>
2392
2393         Reviewed by Dan Bernstein.
2394
2395         Removing unused variable in selectWithGesture that
2396         causes Release build to fail after r162103.
2397
2398         * WebProcess/WebPage/ios/WebPageIOS.mm:
2399         (WebKit::WebPage::selectWithGesture):
2400
2401 2014-01-17  Yongjun Zhang  <yongjun_zhang@apple.com>
2402
2403         https://bugs.webkit.org/show_bug.cgi?id=127138
2404         Add more delegate callback methods to WKWebProcessPlugInLoadDelegate.
2405
2406         Reviewed by Sam Weinig.
2407
2408         Add more WKWebProcessPlugInLoadDelegate callback methods so that a injected
2409         bundle can listen/react to more frame loading events.
2410
2411         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInLoadDelegate.h: Add more delegate callback methods for
2412             WKWebProcessPlugInLoadDelegate.
2413         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
2414         (didCommitLoadForFrame):
2415         (didFinishDocumentLoadForFrame):
2416         (didFailLoadWithErrorForFrame):
2417         (didSameDocumentNavigationForFrame): 
2418         (didLayoutForFrame):
2419         (setUpPageLoaderClient):
2420
2421 2014-01-16  Carlos Garcia Campos  <cgarcia@igalia.com>
2422
2423         [SOUP] Add stubs for CustomProtocol classes
2424         https://bugs.webkit.org/show_bug.cgi?id=126343
2425
2426         Reviewed by Gustavo Noronha Silva.
2427
2428         * CMakeLists.txt:
2429         * GNUmakefile.am:
2430         * GNUmakefile.list.am:
2431         * PlatformGTK.cmake:
2432         * Shared/Network/CustomProtocols/soup/CustomProtocolManagerSoup.cpp: Added.
2433         (WebKit::generateCustomProtocolID):
2434         (WebKit::WebSoupRequestAsyncData::WebSoupRequestAsyncData):
2435         (WebKit::WebSoupRequestAsyncData::~WebSoupRequestAsyncData):
2436         (WebKit::WebSoupRequestAsyncData::requestFailed):
2437         (WebKit::WebSoupRequestAsyncData::releaseTask):
2438         (WebKit::CustomProtocolManager::supplementName):
2439         (WebKit::CustomProtocolManager::CustomProtocolManager):
2440         (WebKit::CustomProtocolManager::initializeConnection):
2441         (WebKit::CustomProtocolManager::initialize):
2442         * Shared/Network/NetworkProcessCreationParameters.cpp:
2443         (WebKit::NetworkProcessCreationParameters::encode): Move
2444         urlSchemesRegisteredForCustomProtocols encoding out of platform
2445         ifdefs, since it's already guarded by ENABLE(CUSTOM_PROTOCOLS).
2446         (WebKit::NetworkProcessCreationParameters::decode): Ditto.
2447         * Shared/Network/NetworkProcessCreationParameters.h: Ditto.
2448         * UIProcess/Network/CustomProtocols/soup/CustomProtocolManagerProxySoup.cpp: Added.
2449         (WebKit::CustomProtocolManagerProxy::CustomProtocolManagerProxy):
2450         (WebKit::CustomProtocolManagerProxy::startLoading):
2451         (WebKit::CustomProtocolManagerProxy::stopLoading):
2452
2453 2014-01-16  Tim Horton  <timothy_horton@apple.com>
2454
2455         On iOS, zooming in with a TileController-backed main frame makes hundreds of tiles
2456         https://bugs.webkit.org/show_bug.cgi?id=126531
2457         <rdar://problem/15745862>
2458
2459         Reviewed by Anders Carlsson.
2460
2461         * UIProcess/API/ios/WKContentView.mm:
2462         (-[WKContentView _updateViewExposedRect]):
2463         (-[WKContentView setViewportSize:]):
2464         (-[WKContentView didFinishScrollTo:]):
2465         (-[WKContentView didScrollTo:]):
2466         (-[WKContentView didZoomToScale:]):
2467         Because zooming is performed by the UIScrollView, we need to transform
2468         the exposedRect's offset in order to get it in FrameView-relative coordinates.
2469
2470         * UIProcess/ios/WebPageProxyIOS.mm:
2471         (WebKit::WebPageProxy::didFinishZooming):
2472         Save the pageScaleFactor when it changes.
2473
2474 2014-01-16  Carlos Garcia Campos  <cgarcia@igalia.com>
2475
2476         [GTK] Remove the weak pointer added to the web view in WebKitPrintOperation
2477         https://bugs.webkit.org/show_bug.cgi?id=127098
2478
2479         Reviewed by Martin Robinson.
2480
2481         If the print operation finishes and the web view is still alive,
2482         the weak pointer added to the view should be removed.
2483
2484         * UIProcess/API/gtk/WebKitPrintOperation.cpp:
2485         (_WebKitPrintOperationPrivate::~_WebKitPrintOperationPrivate):
2486
2487 2014-01-15  Sam Weinig  <sam@webkit.org>
2488
2489         TextBreakIterator's should support Latin-1 for all iterator types (Part 3)
2490         https://bugs.webkit.org/show_bug.cgi?id=126856
2491
2492         Reviewed by Ryosuke Niwa.
2493
2494         Change all the TextBreakIterator creation functions to take StringViews. Remove a few
2495         now unnecessary up-conversions to UTF-16 in the process.
2496
2497         * UIProcess/efl/TextCheckerEfl.cpp:
2498         (WebKit::nextWordOffset):
2499         (WebKit::TextChecker::checkTextOfParagraph):
2500
2501 2014-01-16  Eunmi Lee  <eunmi15.lee@samsung.com>
2502
2503         [EFL][WK2] EwkView can not be shown without re-sizing once it is hidden.
2504         https://bugs.webkit.org/show_bug.cgi?id=127084
2505
2506         Reviewed by Gyuyoung Kim.
2507
2508         Visibility of EwkView can not be controlled by evas_object_show/hide
2509         because EwkView can be shown only if re-sizing is requested, so modify
2510         codes to show EwkView directly if we do not wait for re-sizing.
2511         Additionally, we have to set default value of m_pendingSurfaceResize
2512         to true for accelerated mode to prevent to show black empty view for
2513         the first request to show.
2514
2515         * UIProcess/API/efl/EwkView.cpp:
2516         (EwkView::EwkView):
2517         (EwkView::handleEvasObjectShow):
2518
2519 2014-01-16  Andy Estes  <aestes@apple.com>
2520
2521         Build Fix: Use standard architectures when building for iOS
2522
2523         Even though we don't use the plug-in services on iOS, we still need
2524         them to build (we won't install them). Be sure we specify valid iOS
2525         architectures when doing so.
2526
2527         * Configurations/PluginService.32.xcconfig:
2528         * Configurations/PluginService.64.xcconfig:
2529
2530 2014-01-16  Enrica Casucci  <enrica@apple.com>
2531
2532         Crash when destroying WKInteractionView.
2533         https://bugs.webkit.org/show_bug.cgi?id=127153
2534         <rdar://problem/15840761>
2535
2536         Reviewed by Anders Carlsson.
2537
2538         UIWKSelectionAssistant is a RetainPtr and it is being 
2539         deallocated after the view and its gesture recognizers
2540         have been destroyed.
2541         The parent class UIWebSelectionAssistant assumes to be
2542         deallocated before the view is gone.
2543         We deallocate the interaction assistants explicitly to
2544         fix the problem.
2545
2546         * UIProcess/API/ios/WKInteractionView.mm:
2547         (-[WKInteractionView dealloc]):
2548
2549 2014-01-16  Brady Eidson  <beidson@apple.com>
2550
2551         IDB: delete object store support
2552         <rdar://problem/15779641> and https://bugs.webkit.org/show_bug.cgi?id=127123
2553
2554         Reviewed by Alexey Proskuryakov.
2555
2556         Pipe through Web -> Database -> Web process messaging for delete object store.
2557         Perform dropping the object store in the backing store.
2558
2559         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
2560         (WebKit::DatabaseProcessIDBConnection::deleteObjectStore):
2561         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
2562         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
2563
2564         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
2565         (WebKit::UniqueIDBDatabase::didDeleteObjectStore):
2566         (WebKit::UniqueIDBDatabase::deleteObjectStore):
2567         (WebKit::UniqueIDBDatabase::deleteObjectStoreInBackingStore):
2568         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
2569
2570         * DatabaseProcess/IndexedDB/UniqueIDBDatabaseBackingStore.h:
2571         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
2572         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createObjectStore):
2573         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::deleteObjectStore):
2574         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
2575
2576         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
2577         (WebKit::WebIDBServerConnection::deleteObjectStore):
2578         (WebKit::WebIDBServerConnection::didDeleteObjectStore):
2579         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
2580         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:
2581
2582 2014-01-16  Alexey Proskuryakov  <ap@apple.com>
2583
2584         [Mac] [iOS] Add support for CFHTTPCookieStorageAcceptPolicyExclusivelyFromMainDocumentDomain
2585         https://bugs.webkit.org/show_bug.cgi?id=127139
2586
2587         Reviewed by Brady Eidson.
2588
2589         * Shared/HTTPCookieAcceptPolicy.h:
2590         * UIProcess/API/C/WKAPICast.h:
2591         (WebKit::toHTTPCookieAcceptPolicy):
2592         (WebKit::toAPI):
2593         * UIProcess/API/C/WKCookieManager.h:
2594         Added the policy to appropriate switches and enums.
2595
2596 2014-01-16  Jeffrey Pfau  <jpfau@apple.com>
2597
2598         Fix build after r162161. One FINAL was still present.
2599
2600         * Shared/cf/KeyedDecoder.h:
2601
2602 2014-01-16  Anders Carlsson  <andersca@apple.com>
2603
2604         Change all uses of FINAL to final now that all our compilers support it
2605         https://bugs.webkit.org/show_bug.cgi?id=127142
2606
2607         Reviewed by Benjamin Poulain.
2608
2609         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
2610         * NetworkProcess/RemoteNetworkingContext.h:
2611         * Shared/API/Cocoa/RemoteObjectRegistry.h:
2612         * Shared/APIArray.h:
2613         * Shared/APIString.h:
2614         * Shared/AsyncRequest.h:
2615         * Shared/AsyncTask.h:
2616         * Shared/cf/KeyedEncoder.h:
2617         * UIProcess/API/gtk/PageClientImpl.h:
2618         * UIProcess/API/mac/PageClientImpl.h:
2619         * UIProcess/efl/WebViewEfl.h:
2620         * WebProcess/Databases/IndexedDB/WebIDBFactoryBackend.h:
2621         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
2622         * WebProcess/Plugins/PDF/PDFPlugin.h:
2623         * WebProcess/Storage/StorageAreaImpl.h:
2624         * WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
2625         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.h:
2626         * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h:
2627
2628 2014-01-16  Brady Eidson  <beidson@apple.com>
2629
2630         Fix the build after r162148
2631
2632         * Shared/cf/KeyedEncoder.h: s/OVERRIDE/override/
2633
2634 2014-01-15  Brady Eidson  <beidson@apple.com>
2635
2636         Use KeyedCoding as a persistent storage mechanism for blobs
2637         https://bugs.webkit.org/show_bug.cgi?id=127012
2638
2639         Reviewed by Anders Carlsson.
2640
2641         Add a way to get the encoded buffer to save:
2642         * Shared/cf/KeyedEncoder.cpp:
2643         (WebKit::KeyedEncoder::finishEncoding):
2644         * Shared/cf/KeyedEncoder.h:
2645
2646         Add a WebKit KeyedDecoder for CF platforms that can decode the previously encoded buffer:
2647         * Shared/cf/KeyedDecoder.cpp: Added.
2648         (WebKit::KeyedDecoder::KeyedDecoder):
2649         (WebKit::KeyedDecoder::~KeyedDecoder):
2650         (WebKit::KeyedDecoder::decodeInt64):
2651         (WebKit::KeyedDecoder::decodeUInt32):
2652         (WebKit::KeyedDecoder::decodeString):
2653         (WebKit::KeyedDecoder::beginObject):
2654         (WebKit::KeyedDecoder::endObject):
2655         (WebKit::KeyedDecoder::beginArray):
2656         (WebKit::KeyedDecoder::beginArrayElement):
2657         (WebKit::KeyedDecoder::endArrayElement):
2658         (WebKit::KeyedDecoder::endArray):
2659         * Shared/cf/KeyedDecoder.h:
2660
2661         Create a WebKit KeyedEncoder/Decoder and use to encode/decode IDBKeyPaths:
2662         * DatabaseProcess/IndexedDB/IDBSerialization.cpp:
2663         (WebKit::serializeIDBKeyPath):
2664         (WebKit::deserializeIDBKeyPath):
2665         * DatabaseProcess/IndexedDB/IDBSerialization.h:
2666
2667         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
2668         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createObjectStore):
2669
2670         * WebKit2.xcodeproj/project.pbxproj:
2671
2672 2014-01-16  Andy Estes  <aestes@apple.com>
2673
2674         Stop copying WKOriginDataManager.cpp into WebKit2.framework
2675         https://bugs.webkit.org/show_bug.cgi?id=127100
2676
2677         Reviewed by Sam Weinig.
2678
2679         The file was mistakenly added to the 'All' target. Remove it.
2680
2681         * WebKit2.xcodeproj/project.pbxproj:
2682
2683 2014-01-16  Andy Estes  <aestes@apple.com>
2684
2685         [iOS] Install WebKit2 XPC services correctly
2686         https://bugs.webkit.org/show_bug.cgi?id=127097
2687
2688         Reviewed by Anders Carlsson.
2689
2690         * Configurations/PluginService.32.xcconfig: Set SKIP_INSTALL to YES on iOS.
2691         * Configurations/PluginService.64.xcconfig: Ditto.
2692         * Configurations/PluginService.Development.xcconfig: Ditto.
2693         * WebKit2.xcodeproj/project.pbxproj: Modified the "Add XPCServices symlink"
2694         build phase to only execute on OS X. Modified the
2695         "Copy XPC services for engineering builds" build phase to copy files
2696         directly to WebKit2.framework/XPCServices/ on iOS, and modified its
2697         output file paths to omit "Versions/A/" (since OS X will have a
2698         XPCServices symlink at the root of the framework bundle).
2699
2700 2014-01-16  Roger Fong  <roger_fong@apple.com>
2701
2702         Build fix for mac following r162141.
2703
2704         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h: Switch OVERRIDE to override.
2705
2706 2014-01-16  Roger Fong  <roger_fong@apple.com>
2707
2708         Add support for handling WebGL load policies.
2709         https://bugs.webkit.org/show_bug.cgi?id=126935
2710         <rdar://problem/15790448>.
2711
2712         Reviewed by Timothy Horton.
2713
2714         Boiler plate code for getting the load policy logic from WebProcess to the UIProcess.
2715
2716         * UIProcess/API/C/WKAPICast.h:
2717         (WebKit::toWebGLLoadPolicy):
2718         * UIProcess/API/C/WKPageLoaderClient.h: Define a new WKPageLoaderClientV4 struct.
2719         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
2720         (setUpPageLoaderClient):
2721         * UIProcess/WebLoaderClient.cpp:
2722         (WebKit::WebLoaderClient::webGLLoadPolicy):
2723         * UIProcess/WebLoaderClient.h:
2724         * UIProcess/WebPageProxy.cpp:
2725         (WebKit::WebPageProxy::webGLPolicyForURL):
2726         * UIProcess/WebPageProxy.h:
2727         * UIProcess/WebPageProxy.messages.in:
2728         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2729         (WebKit::WebFrameLoaderClient::webGLPolicyForURL): 
2730         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2731         * WebProcess/WebPage/WebPage.cpp:
2732         (WebKit::WebPage::webGLPolicyForURL): We use a sendSync to get the load policy value from the UIProcess.
2733         * WebProcess/WebPage/WebPage.h:
2734
2735 2014-01-16  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
2736
2737         Remove workaround for compilers not supporting explicit override control
2738         https://bugs.webkit.org/show_bug.cgi?id=127111
2739
2740         Reviewed by Anders Carlsson.
2741
2742         Now all compilers support explicit override control, this workaround can be removed.
2743
2744         * DatabaseProcess/DatabaseProcess.h:
2745         * DatabaseProcess/DatabaseToWebProcessConnection.h:
2746         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
2747         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
2748         * NetworkProcess/AsynchronousNetworkLoaderClient.h:
2749         * NetworkProcess/NetworkProcess.h:
2750         * NetworkProcess/NetworkProcessPlatformStrategies.h:
2751         * NetworkProcess/NetworkResourceLoader.h:
2752         * NetworkProcess/RemoteNetworkingContext.h:
2753         * NetworkProcess/SynchronousNetworkLoaderClient.h:
2754         * NetworkProcess/mac/DiskCacheMonitor.h:
2755         * PluginProcess/EntryPoint/mac/LegacyProcess/PluginProcessMain.mm:
2756         * PluginProcess/PluginControllerProxy.h:
2757         * PluginProcess/PluginProcess.h:
2758         * PluginProcess/WebProcessConnection.h:
2759         * Shared/API/Cocoa/RemoteObjectRegistry.h:
2760         * Shared/APIObject.h:
2761         * Shared/AsyncRequest.h:
2762         * Shared/AsyncTask.h:
2763         * Shared/Authentication/AuthenticationManager.h:
2764         * Shared/ChildProcess.h:
2765         * Shared/ChildProcessProxy.h:
2766         * Shared/CoordinatedGraphics/WebCoordinatedSurface.h:
2767         * Shared/Downloads/Download.h:
2768         * Shared/Network/CustomProtocols/CustomProtocolManager.h:
2769         * Shared/WebConnection.h:
2770         * Shared/WebResourceBuffer.h:
2771         * Shared/cf/KeyedEncoder.h:
2772         * Shared/mac/SecItemShim.h:
2773         * UIProcess/API/Cocoa/WKBrowsingContextController.mm:
2774         * UIProcess/API/gtk/PageClientImpl.h:
2775         * UIProcess/API/ios/PageClientImplIOS.h:
2776         * UIProcess/API/mac/PageClientImpl.h:
2777         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.h:
2778         * UIProcess/CoordinatedGraphics/WebView.h:
2779         * UIProcess/Databases/DatabaseProcessProxy.h:
2780         * UIProcess/Downloads/DownloadProxy.h:
2781         * UIProcess/DrawingAreaProxy.h:
2782         * UIProcess/Network/CustomProtocols/CustomProtocolManagerProxy.h:
2783         * UIProcess/Network/NetworkProcessProxy.h:
2784         * UIProcess/Notifications/WebNotificationManagerProxy.h:
2785         * UIProcess/Plugins/PluginProcessProxy.h:
2786         * UIProcess/Scrolling/RemoteScrollingTree.h:
2787         * UIProcess/Storage/StorageManager.h:
2788         * UIProcess/WebApplicationCacheManagerProxy.h:
2789         * UIProcess/WebBatteryManagerProxy.h:
2790         * UIProcess/WebConnectionToWebProcess.h:
2791         * UIProcess/WebContext.h:
2792         * UIProcess/WebCookieManagerProxy.h:
2793         * UIProcess/WebDatabaseManagerProxy.h:
2794         * UIProcess/WebFullScreenManagerProxy.h:
2795         * UIProcess/WebGeolocationManagerProxy.h:
2796         * UIProcess/WebIconDatabase.h:
2797         * UIProcess/WebInspectorProxy.h:
2798         * UIProcess/WebKeyValueStorageManager.h:
2799         * UIProcess/WebMediaCacheManagerProxy.h:
2800         * UIProcess/WebNetworkInfoManagerProxy.h:
2801         * UIProcess/WebOriginDataManagerProxy.h:
2802         * UIProcess/WebPageProxy.h:
2803         * UIProcess/WebProcessProxy.h:
2804         * UIProcess/WebResourceCacheManagerProxy.h:
2805         * UIProcess/WebVibrationProxy.h:
2806         * UIProcess/efl/PageViewportControllerClientEfl.h:
2807         * UIProcess/efl/WebViewEfl.h:
2808         * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h:
2809         * UIProcess/mac/SecItemShimProxy.h:
2810         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
2811         * UIProcess/mac/ViewGestureController.h:
2812         * UIProcess/mac/WebColorPickerMac.h:
2813         * UIProcess/soup/WebSoupRequestManagerProxy.h:
2814         * WebProcess/ApplicationCache/WebApplicationCacheManager.h:
2815         * WebProcess/Battery/WebBatteryManager.h:
2816         * WebProcess/Cookies/WebCookieManager.h:
2817         * WebProcess/Databases/IndexedDB/WebIDBFactoryBackend.h:
2818         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
2819         * WebProcess/Databases/WebToDatabaseProcessConnection.h:
2820         * WebProcess/EntryPoint/mac/LegacyProcess/WebContentProcessMain.mm:
2821         * WebProcess/FileAPI/BlobRegistryProxy.h:
2822         * WebProcess/Geolocation/WebGeolocationManager.h:
2823         * WebProcess/IconDatabase/WebIconDatabaseProxy.h:
2824         * WebProcess/InjectedBundle/API/c/mac/WKBundlePageBannerMac.mm:
2825         * WebProcess/MediaCache/WebMediaCacheManager.h:
2826         * WebProcess/Network/NetworkProcessConnection.h:
2827         * WebProcess/Network/WebResourceLoadScheduler.h:
2828         * WebProcess/Network/WebResourceLoader.h:
2829         * WebProcess/NetworkInfo/WebNetworkInfoManager.h:
2830         * WebProcess/Notifications/WebNotificationManager.h:
2831         * WebProcess/OriginData/WebOriginDataManager.h:
2832         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2833         * WebProcess/Plugins/PDF/PDFPlugin.h:
2834         * WebProcess/Plugins/PDF/PDFPluginAnnotation.h:
2835         * WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.h:
2836         * WebProcess/Plugins/PDF/PDFPluginPasswordField.h:
2837         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.h:
2838         * WebProcess/Plugins/PluginProcessConnection.h:
2839         * WebProcess/Plugins/PluginProcessConnectionManager.h:
2840         * WebProcess/Plugins/PluginProxy.h:
2841         * WebProcess/Plugins/PluginView.h:
2842         * WebProcess/ResourceCache/WebResourceCacheManager.h:
2843         * WebProcess/Scrolling/RemoteScrollingCoordinator.h:
2844         * WebProcess/Storage/StorageAreaImpl.h:
2845         * WebProcess/Storage/StorageAreaMap.h:
2846         * WebProcess/Storage/StorageNamespaceImpl.h:
2847         * WebProcess/WebConnectionToUIProcess.h:
2848         * WebProcess/WebCoreSupport/WebAlternativeTextClient.h:
2849         * WebProcess/WebCoreSupport/WebBatteryClient.h:
2850         * WebProcess/WebCoreSupport/WebChromeClient.h:
2851         * WebProcess/WebCoreSupport/WebColorChooser.h:
2852         * WebProcess/WebCoreSupport/WebContextMenuClient.h:
2853         * WebProcess/WebCoreSupport/WebDatabaseManager.h:
2854         * WebProcess/WebCoreSupport/WebDeviceProximityClient.h:
2855         * WebProcess/WebCoreSupport/WebDragClient.h:
2856         * WebProcess/WebCoreSupport/WebEditorClient.h:
2857         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2858         * WebProcess/WebCoreSupport/WebGeolocationClient.h:
2859         * WebProcess/WebCoreSupport/WebInspectorClient.h:
2860         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.h:
2861         * WebProcess/WebCoreSupport/WebNavigatorContentUtilsClient.h:
2862         * WebProcess/WebCoreSupport/WebNetworkInfoClient.h:
2863         * WebProcess/WebCoreSupport/WebNotificationClient.h:
2864         * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
2865         * WebProcess/WebCoreSupport/WebPopupMenu.h:
2866         * WebProcess/WebCoreSupport/WebProgressTrackerClient.h:
2867         * WebProcess/WebCoreSupport/WebSearchPopupMenu.h:
2868         * WebProcess/WebCoreSupport/WebVibrationClient.h:
2869         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
2870         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedDrawingArea.h:
2871         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
2872         * WebProcess/WebPage/DrawingAreaImpl.h:
2873         * WebProcess/WebPage/EventDispatcher.h:
2874         * WebProcess/WebPage/ViewGestureGeometryCollector.h:
2875         * WebProcess/WebPage/WebBackForwardListProxy.h:
2876         * WebProcess/WebPage/WebPage.h:
2877         * WebProcess/WebPage/gtk/LayerTreeHostGtk.h:
2878         * WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
2879         * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
2880         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.h:
2881         * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h:
2882         * WebProcess/WebPage/mac/RemoteLayerTreeContext.h:
2883         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
2884         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2885         * WebProcess/WebProcess.h:
2886         * WebProcess/soup/WebSoupRequestManager.h:
2887
2888 2014-01-16  Ian Henderson  <ianh@apple.com>
2889
2890         Expose scrollView on WKView
2891         https://bugs.webkit.org/show_bug.cgi?id=127085
2892
2893         Reviewed by Antti Koivisto.
2894
2895         Expose WKView's scroll view as a property.  In order to support
2896         clients calling setDelegate:, we create a forwarder object that sends
2897         delegate methods to both WKView (the "internal delegate") and the
2898         publicly-exposed delegate (the "external delegate").
2899
2900         * UIProcess/API/Cocoa/WKView.h:
2901         * UIProcess/API/ios/WKScrollView.h:
2902         * UIProcess/API/ios/WKScrollView.mm:
2903         (-[WKScrollViewDelegateForwarder initWithInternalDelegate:externalDelegate:]):
2904         (-[WKScrollViewDelegateForwarder methodSignatureForSelector:]):
2905         (-[WKScrollViewDelegateForwarder respondsToSelector:]):
2906         (-[WKScrollViewDelegateForwarder forwardInvocation:]):
2907         (-[WKScrollView setInternalDelegate:]):
2908         (-[WKScrollView setDelegate:]):
2909         (-[WKScrollView delegate]):
2910         Pretend like _externalDelegate is the real delegate to avoid exposing
2911         our internal delegate or forwarder object.
2912         (-[WKScrollView _updateDelegate]):
2913         (-[WKScrollView dealloc]):
2914         * UIProcess/API/ios/WKViewIOS.mm:
2915         (-[WKView scrollView]):
2916         (-[WKView _commonInitializationWithContextRef:pageGroupRef:relatedToPage:]):
2917
2918 2014-01-15  Carlos Garcia Campos  <cgarcia@igalia.com>
2919
2920         [GTK][EFL][NIX] Do not use PrintContext, Frame and DocumentLoader in Errors
2921         https://bugs.webkit.org/show_bug.cgi?id=127047
2922
2923         Reviewed by Martin Robinson.
2924
2925         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp:
2926         (WebKit::WebPrintOperationGtk::frameURL): Helper function to get
2927         the URL of the frame being printed.
2928         (WebKit::WebPrintOperationGtk::print): Use frameURL() as failing
2929         URL for printing errors.
2930         * WebProcess/WebPage/gtk/WebPrintOperationGtk.h:
2931
2932 2014-01-15  Benjamin Poulain  <bpoulain@apple.com>
2933
2934         Move user agent code to WebCore and unify some code between OS X and iOS
2935         https://bugs.webkit.org/show_bug.cgi?id=127080
2936
2937         Reviewed by Sam Weinig.
2938
2939         * UIProcess/ios/WebPageProxyIOS.mm:
2940         (WebKit::userVisibleWebKitVersionString):
2941         (WebKit::WebPageProxy::standardUserAgent):
2942         * UIProcess/mac/WebPageProxyMac.mm:
2943         (WebKit::WebPageProxy::standardUserAgent):
2944         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2945         (InitWebCoreSystemInterface):
2946
2947 2014-01-15  Eunmi Lee  <eunmi15.lee@samsung.com>
2948
2949         [EFL][WK2] Use timestamp when event occurs for touch events.
2950         https://bugs.webkit.org/show_bug.cgi?id=126424
2951
2952         Reviewed by Gyuyoung Kim.
2953
2954         Current time is used for touch event's timestamp instead of timestamp
2955         when event occurs. Timestamp of touch event is used to implement flick
2956         gesture, so it should be real value for accurate gesture processing.
2957
2958         * UIProcess/API/efl/EwkView.cpp:
2959         Function names for handling touch events are changed to distinguish
2960         mouse events and multi events.
2961         (EwkView::setTouchEventsEnabled):
2962         (EwkView::feedTouchEvents):
2963         (EwkView::handleMouseDownForTouch):
2964         (EwkView::handleMouseUpForTouch):
2965         (EwkView::handleMouseMoveForTouch):
2966         (EwkView::handleMultiDownForTouch):
2967         (EwkView::handleMultiUpForTouch):
2968         (EwkView::handleMultiMoveForTouch):
2969         * UIProcess/API/efl/EwkView.h:
2970         * UIProcess/API/efl/GestureRecognizer.cpp:
2971         (WebKit::GestureHandler::handlePan):
2972         (WebKit::GestureRecognizer::processTouchEvent):
2973         (WebKit::GestureRecognizer::noGesture):
2974         (WebKit::GestureRecognizer::singleTapGesture):
2975         (WebKit::GestureRecognizer::doubleTapGesture):
2976         (WebKit::GestureRecognizer::panGesture):
2977         (WebKit::GestureRecognizer::pinchGesture):
2978         * UIProcess/API/efl/GestureRecognizer.h:
2979
2980 2014-01-15  Gavin Barraclough  <barraclough@apple.com>
2981
2982         Change Page, FocusController to use ViewState
2983         https://bugs.webkit.org/show_bug.cgi?id=126533
2984
2985         Unreviewed rollout, this caused a regression.
2986
2987         * WebProcess/WebPage/WebPage.cpp:
2988         (WebKit::WebPage::WebPage):
2989         (WebKit::WebPage::setActive):
2990         (WebKit::WebPage::setViewIsVisible):
2991         (WebKit::WebPage::setFocused):
2992         (WebKit::WebPage::setIsInWindow):
2993         (WebKit::WebPage::setViewStateInternal):
2994         (WebKit::WebPage::setIsVisuallyIdle):
2995         * WebProcess/WebPage/WebPage.h:
2996
2997 2014-01-15  Yongjun Zhang  <yongjun_zhang@apple.com>
2998
2999         https://bugs.webkit.org/show_bug.cgi?id=127072
3000         Don't autorelease wrapper object (WebProcessPlugInScriptWorld) for InjectedBundleScriptWorld::normalWorld().
3001
3002         Reviewed by Geoffrey Garen.
3003
3004         In [WKWebProcessPlugInScriptWorld normalWorld], InjectedBundleScriptWorld::normalWorld() returns a static
3005         instance,  autoreleasing its wrapper object could cause a dangling pointer and crash later.
3006
3007         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInScriptWorld.mm:
3008         (+[WKWebProcessPlugInScriptWorld normalWorld]):
3009
3010 2014-01-15  Andy Estes  <aestes@apple.com>
3011
3012         [iOS] Properly exclude the shim dylibs this time
3013         https://bugs.webkit.org/show_bug.cgi?id=127075
3014
3015         Reviewed by Anders Carlsson.
3016
3017         BaseLegacyProcess.xcconfig was setting EXCLUDED_SOURCE_FILE_NAMES in
3018         conflict with what I added in r161918, and I misspelled the setting
3019         name in two instances. Fix these two bugs.
3020
3021         Also remove a vestigial OTHER_LDFLAGS from WebContentProcess.xcconfig
3022         while we're here.
3023
3024         * Configurations/BaseLegacyProcess.xcconfig:
3025         * Configurations/NetworkProcess.xcconfig:
3026         * Configurations/PluginProcess.xcconfig:
3027         * Configurations/WebContentProcess.xcconfig:
3028
3029 2014-01-15  Enrica Casucci  <enrica@apple.com>
3030
3031         Support WebSelections in WK2 on iOS.
3032         https://bugs.webkit.org/show_bug.cgi?id=127015
3033
3034         Reviewed by Benjamin Poulain.
3035
3036         This is the first step towards adding support for selections in
3037         non editable content on iOS for WK2.
3038         In particular, this patch adds the basic plumbing to decide which
3039         gesture recognizers are enabled and adds empty stubs for the gestures
3040         that we'll need to support.
3041         There are two separate assistants for selections, one to be used
3042         in editable text (UIWKTextInteractionAssistant) and one for non editable
3043         text (UIWKSelectionAssistant) and they are mutually exclusive.
3044         UIWKSelectionAssistant is created at the time the view is created, 
3045         and swapped with UIWKTextInteraction assistant
3046         only when an editable element is focused and the keyboard appears on screen.
3047
3048         gestureRecognizerShouldBegin is the delegate call used to decide which gestures
3049         should begin based on the position the gesture occurred at.
3050         We want to avoid as much as possible synchronous calls to the WebProcess to
3051         retrieve information about the content and in order to do so, we take advantage
3052         of the order in which the gesture recognizers will trigger, based on the delay
3053         configured at initialization.
3054         The first gesture to trigger is highlightLongPress, followed by longpress in the
3055         active assistant and longpress in the WKInteractionView.
3056         There are two different scenarios for highlighlongpress based on which assistant is
3057         currently active.
3058
3059         UIWKSelectionAssistant is active:
3060             We send a request to the WebProcess to get information on the position
3061             and we return YES, allowing the gesture to start.
3062             We delegate to the WebProcess the proper handling of highlight based on the element.
3063             When longPress gesture fires for the assistant, we assume we have received the reply to our
3064             previous request, if not we fetch the information synchronously.
3065             We are then able to make an informed decision about whether
3066             or not to start the gesture. If the reply is NO, the third and last long press
3067             gesture can be evaluated to decide whether to show the action sheet or simply generate
3068             a click event.
3069
3070         UIWKTextInteractionAssistant is active:
3071             In this case we must have information about the position immediately and we issue
3072             a synchronous request to the WebProcess.
3073             If we are not interacting with the same node, we return NO.
3074             Then the longpress gesture fires for the assistant which performs the same check.
3075             If the node is the same, the loupe gesture will start, otherwise the last longpress
3076             gesture will be evaluated to decide about showing the action sheet or generating a
3077             click event.
3078
3079         * Scripts/webkit2/messages.py:
3080         * Shared/InteractionInformationAtPosition.cpp: Added.
3081         (WebKit::InteractionInformationAtPosition::encode):
3082         (WebKit::InteractionInformationAtPosition::decode):
3083         * Shared/InteractionInformationAtPosition.h: Added.
3084         (WebKit::InteractionInformationAtPosition::InteractionInformationAtPosition):
3085         * UIProcess/API/ios/PageClientImplIOS.h:
3086         * UIProcess/API/ios/PageClientImplIOS.mm:
3087         (WebKit::PageClientImpl::positionInformationDidChange):
3088         * UIProcess/API/ios/WKContentView.mm:
3089         (-[WKContentView _positionInformationDidChange:]):
3090         * UIProcess/API/ios/WKContentViewInternal.h:
3091         * UIProcess/API/ios/WKInteractionView.h:
3092         * UIProcess/API/ios/WKInteractionView.mm:
3093         (-[WKInteractionView initWithFrame:]):
3094         (-[WKInteractionView dealloc]):
3095         (-[WKInteractionView gestureRecognizer:canPreventGestureRecognizer:]):
3096         (-[WKInteractionView gestureRecognizer:canBePreventedByGestureRecognizer:]):
3097         (isSamePair):
3098         (-[WKInteractionView gestureRecognizer:shouldRecognizeSimultaneouslyWithGestureRecognizer:]):
3099         (-[WKInteractionView _showImageSheet]):
3100         (-[WKInteractionView _showLinkSheet]):
3101         (-[WKInteractionView _actionForLongPress]):
3102         (-[WKInteractionView ensurePositionInformationIsUpToDate:]):
3103         (-[WKInteractionView gestureRecognizerShouldBegin:]):
3104         (-[WKInteractionView hasSelectablePositionAtPoint:]):
3105         (-[WKInteractionView pointIsInAssistedNode:]):
3106         (-[WKInteractionView _longPressRecognized:]):
3107         (-[WKInteractionView _doubleTapRecognized:]):
3108         (-[WKInteractionView _twoFingerDoubleTapRecognized:]):
3109         (-[WKInteractionView _twoFingerPanRecognized:]):
3110         (-[WKInteractionView useSelectionAssistantWithMode:]):
3111         (-[WKInteractionView _positionInformationDidChange:]):
3112         (-[WKInteractionView interactionAssistant]):
3113         (-[WKInteractionView _startAssistingKeyboard]):
3114         (-[WKInteractionView _stopAssistingKeyboard]):
3115         * UIProcess/PageClient.h:
3116         * UIProcess/WebPageProxy.h:
3117         * UIProcess/WebPageProxy.messages.in:
3118         * UIProcess/ios/WebPageProxyIOS.mm:
3119         (WebKit::WebPageProxy::didReceivePositionInformation):
3120         (WebKit::WebPageProxy::getPositionInformation):
3121         (WebKit::WebPageProxy::requestPositionInformation):
3122         * WebKit2.xcodeproj/project.pbxproj:
3123         * WebProcess/WebPage/WebPage.h:
3124         * WebProcess/WebPage/WebPage.messages.in:
3125         * WebProcess/WebPage/ios/WebPageIOS.mm:
3126         (WebKit::WebPage::selectWithGesture):
3127         (WebKit::WebPage::getPositionInformation):
3128         (WebKit::WebPage::requestPositionInformation):
3129
3130 2014-01-15  Yongjun Zhang  <yongjun_zhang@apple.com>
3131
3132         https://bugs.webkit.org/show_bug.cgi?id=127066
3133         Add WKBrowsingContextHandle.h to WebKit2 private headers.
3134
3135         Reviewed by Dan Bernstein.
3136
3137         Add WKBrowsingContextHandle.h to WebKit2 private headers so that WebKit2 client
3138         can use WKBrowsingContextHandle class.
3139
3140         * WebKit2.xcodeproj/project.pbxproj:
3141
3142 2014-01-15  Piotr Grad  <p.grad@samsung.com>
3143
3144         toStringVector static function definition should not be redundant.
3145         https://bugs.webkit.org/show_bug.cgi?id=126872.
3146
3147         Reviewed by Anders Carlsson.
3148
3149         toStringVector function was declared twice in InjectedBundle.cpp and WebPageGroup.cpp as static.
3150         In order to remove redundant definition this function was moved into API::Array.
3151
3152         * Shared/APIArray.cpp:
3153         (API::Array::toStringVector):
3154         * Shared/APIArray.h:
3155         * UIProcess/WebPageGroup.cpp:
3156         (WebKit::WebPageGroup::addUserStyleSheet):
3157         (WebKit::WebPageGroup::addUserScript):
3158         * WebProcess/InjectedBundle/InjectedBundle.cpp:
3159         (WebKit::InjectedBundle::addUserScript):
3160         (WebKit::InjectedBundle::addUserStyleSheet):
3161
3162 2014-01-10  Gavin Barraclough  <barraclough@apple.com>
3163
3164         REGRESSION (r158369): Some pop-up windows open at incorrect size (affects GMail, theblaze.com)
3165         https://bugs.webkit.org/show_bug.cgi?id=126289
3166
3167         Reviewed by Anders Carlson.
3168
3169         Partial revert of https://bugs.webkit.org/show_bug.cgi?id=123557.
3170         On window.open, update page when the UIProcess sends the create message
3171
3172         * UIProcess/WebPageProxy.cpp:
3173         (WebKit::WebPageProxy::initializeWebPage):
3174         (WebKit::WebPageProxy::creationParameters):
3175         * UIProcess/WebPageProxy.h:
3176             - creation paraments are not preserved at window.open.
3177         * WebProcess/WebPage/WebPage.cpp:
3178         (WebKit::WebPage::reinitializeWebPage):
3179         (WebKit::WebPage::setViewState):
3180         (WebKit::WebPage::setViewStateInternal):
3181         * WebProcess/WebPage/WebPage.h:
3182             - add interface to update page.
3183         * WebProcess/WebProcess.cpp:
3184         (WebKit::WebProcess::createWebPage):
3185             - if we try to create a page that already exists, update the current page's view state.
3186
3187 2014-01-15  Carlos Garcia Campos  <cgarcia@igalia.com>
3188
3189         [GTK] Web process sometimes crashes when printing in synchronous mode
3190         https://bugs.webkit.org/show_bug.cgi?id=126979
3191
3192         Reviewed by Gustavo Noronha Silva.
3193
3194         When printing synchronously in GTK+ we need to make sure that we
3195         have a list of Printers before starting the print operation. Getting
3196         the list of printers is done synchronously by GTK+, but using a
3197         nested main loop that might process IPC messages comming from the
3198         UI process like EndPrinting. When the EndPrinting message is
3199         received while the printer list is being populated, the print
3200         operation is finished unexpectely and the web process crashes. The
3201         PrinterListGtk class gets the list of printers in the constructor
3202         so we just need to ensure there's an instance alive during the
3203         synchronous print operation. In case of asynchronous printing the
3204         printer list will be created during the print operation without
3205         any risk, because the EndPrinting message is not sent until the
3206         printing callback has been received in the UI process.
3207
3208         * GNUmakefile.list.am: Add new files to compilation.
3209         * PlatformGTK.cmake: Ditto.
3210         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3211         (WebKit::WebChromeClient::print): Ensure PrinterListGtk is created
3212         before the synchronous printing and destroyed afterwards.
3213         * WebProcess/WebPage/gtk/PrinterListGtk.cpp: Added.
3214         (WebKit::PrinterListGtk::shared): Return the singleton.
3215         (WebKit::PrinterListGtk::enumeratePrintersFunction): Callback
3216         called by gtk_enumerate_printers() when a new printer is found.
3217         (WebKit::PrinterListGtk::PrinterListGtk): Call
3218         gtk_enumerate_printers() in syhchronous mode.
3219         (WebKit::PrinterListGtk::~PrinterListGtk):
3220         (WebKit::PrinterListGtk::addPrinter): Add the printer to the list
3221         and set the default printer if needed.
3222         (WebKit::PrinterListGtk::findPrinter): Find the printer for the
3223         given name.
3224         * WebProcess/WebPage/gtk/PrinterListGtk.h: Added.
3225         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp: Use
3226         PrinterListGtk class to find the printer instead of calling
3227         gtk_enumerate_printers().
3228
3229 2014-01-15  Tomas Popela  <tpopela@redhat.com>
3230
3231         [SOUP] [WK2] - Disable MemoryCache when the DOCUMENT_VIEWER cache model is set
3232         https://bugs.webkit.org/show_bug.cgi?id=126577
3233
3234         Reviewed by Carlos Garcia Campos.
3235
3236         As in http://trac.webkit.org/changeset/152483, but this time for
3237         WebKit2. When WEBKIT_CACHE_MODEL_DOCUMENT_VIEWER is set we need to
3238         disable the MemoryCache completely to prevent caching of the resources.
3239
3240         * WebProcess/soup/WebProcessSoup.cpp:
3241         (WebKit::WebProcess::platformSetCacheModel):
3242
3243 2014-01-14  Carlos Garcia Campos  <cgarcia@igalia.com>
3244
3245         [GTK] UI process crashes when closing the window right after printing with javascript
3246         https://bugs.webkit.org/show_bug.cgi?id=126981
3247
3248         Reviewed by Gustavo Noronha Silva.
3249
3250         The UI process crashes because when the page is closed, the web
3251         view is destroyed before the print operation has actually
3252         finished. Use a weak pointer to make sure the web view pointer is
3253         set to NULL when the it's destroyed and emit the finished callback
3254         always so that the user can clean up the operation even when the
3255         web view has been closed.
3256
3257         * UIProcess/API/gtk/WebKitPrintOperation.cpp:
3258         (drawPagesForPrintingCompleted):
3259
3260 2014-01-14  Carlos Garcia Campos  <cgarcia@igalia.com>
3261
3262         [GTK] UI process crashes when the web process crashes while printing
3263         https://bugs.webkit.org/show_bug.cgi?id=126977
3264
3265         Reviewed by Gustavo Noronha Silva.
3266
3267         When the web process crashes, the printing callback is
3268         invalidated, so the function is called with a NULL error.
3269
3270         * UIProcess/API/gtk/WebKitPrintOperation.cpp:
3271         (drawPagesForPrintingCompleted): Check wkError is not NULL before
3272         trying to use it.
3273         * UIProcess/API/gtk/WebKitWebView.cpp:
3274         (webkitWebViewPrintFrame): Set the print mode of the operation
3275         before emitting the print signal.
3276
3277 2014-01-14  Brady Eidson  <beidson@apple.com>
3278
3279         IDB: create object store support
3280         <rdar://problem/15779639> and https://bugs.webkit.org/show_bug.cgi?id=127011
3281
3282         Reviewed by Anders Carlsson.
3283
3284         Add messaging/callback infrastructure for creating object stores:
3285         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
3286         (WebKit::DatabaseProcessIDBConnection::createObjectStore):
3287         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
3288         * DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:
3289
3290         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
3291         (WebKit::WebIDBServerConnection::createObjectStore):
3292         (WebKit::WebIDBServerConnection::didCreateObjectStore):
3293         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
3294         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:
3295
3296         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
3297         (WebKit::UniqueIDBDatabase::didChangeDatabaseVersion):
3298         (WebKit::UniqueIDBDatabase::didCreateObjectStore):
3299         (WebKit::UniqueIDBDatabase::didCompleteBoolRequest):
3300         (WebKit::UniqueIDBDatabase::createObjectStore):
3301         (WebKit::UniqueIDBDatabase::createObjectStoreInBackingStore):
3302         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:
3303
3304         * DatabaseProcess/IndexedDB/UniqueIDBDatabaseBackingStore.h:
3305
3306         Add serialization helpers to save/restore an IDBKeyPath to/from disk:
3307         * DatabaseProcess/IndexedDB/IDBSerialization.cpp:
3308         (WebKit::serializeIDBKeyPath):
3309         (WebKit::deserializeIDBKeyPath):
3310         * DatabaseProcess/IndexedDB/IDBSerialization.h:
3311
3312         Add object store metadata to the schema, and save/restore the metadata:
3313         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
3314         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createAndPopulateInitialMetadata):
3315         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::extractExistingMetadata):
3316         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createObjectStore):
3317         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:
3318
3319         * Scripts/webkit2/messages.py:
3320         (struct_or_class):
3321         * WebKit2.xcodeproj/project.pbxproj:
3322
3323 2014-01-14  Jae Hyun Park  <jae.park@company100.net>
3324
3325         [GTK] Unreviewed build fix after r162034
3326
3327         * GNUmakefile.list.am:
3328
3329 2014-01-14  Ryuan Choi  <ryuan.choi@samsung.com>
3330
3331         Unreviewed build fix for CMake based ports after r162034.
3332
3333         * CMakeLists.txt:
3334
3335 2014-01-14  Jeffrey Pfau  <jpfau@apple.com>
3336
3337         Build fix after r162034
3338
3339         Rubber-stamped by Benjamin Poulain.
3340
3341         * WebProcess/WebCoreSupport/WebProgressTrackerClient.cpp:
3342
3343 2014-01-14  Anders Carlsson  <andersca@apple.com>
3344
3345         Create separate progress tracker clients
3346         https://bugs.webkit.org/show_bug.cgi?id=127025
3347
3348         Reviewed by Sam Weinig.
3349
3350         * WebKit2.xcodeproj/project.pbxproj:
3351         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3352         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
3353         * WebProcess/WebCoreSupport/WebProgressTrackerClient.cpp: Copied from Source/WebCore/loader/ProgressTrackerClient.h.
3354         (WebKit::WebProgressTrackerClient::WebProgressTrackerClient):
3355         (WebKit::WebProgressTrackerClient::progressTrackerDestroyed):
3356         (WebKit::WebProgressTrackerClient::progressStarted):
3357         (WebKit::WebProgressTrackerClient::progressEstimateChanged):
3358         (WebKit::WebProgressTrackerClient::progressFinished):
3359         * WebProcess/WebCoreSupport/WebProgressTrackerClient.h: Copied from Source/WebCore/loader/ProgressTrackerClient.h.
3360         * WebProcess/WebPage/WebPage.cpp:
3361         (WebKit::WebPage::WebPage):
3362
3363 2014-01-14  Benjamin Poulain  <bpoulain@apple.com>
3364
3365         [WK2] Make WebPageProxy's setUserAgent private
3366         https://bugs.webkit.org/show_bug.cgi?id=127013
3367
3368         Reviewed by Anders Carlsson.
3369
3370         * UIProcess/WebPageProxy.h:
3371         The API to modify the user agent already has 3 "setters":
3372         -standardUserAgent
3373         -setApplicationNameForUserAgent
3374         -setCustomUserAgent
3375
3376         The method WebPageProxy::setUserAgent() is supposed to be internal, not used directly.
3377         Using it directly would cause unexpected behaviors, for example:
3378         -Set the user agent with setUserAgent.
3379         -Set CustomUserAgent.
3380         -Reset CustomUserAgent.
3381         ->The user agent is now standardUserAgent instead of the user agent defined initially.
3382
3383 2014-01-14  Commit Queue  <commit-queue@webkit.org>
3384
3385         Unreviewed, rolling out r162000.
3386         http://trac.webkit.org/changeset/162000
3387         https://bugs.webkit.org/show_bug.cgi?id=127009
3388
3389         API versioning is wrong (Requested by rfong on #webkit).
3390
3391         * UIProcess/API/C/WKAPICast.h:
3392         * UIProcess/API/C/WKPageLoaderClient.h:
3393         * UIProcess/API/C/WKPageUIClient.h:
3394         * UIProcess/WebLoaderClient.cpp:
3395         * UIProcess/WebLoaderClient.h:
3396         * UIProcess/WebPageProxy.cpp:
3397         * UIProcess/WebPageProxy.h:
3398         * UIProcess/WebPageProxy.messages.in:
3399         * UIProcess/WebUIClient.cpp:
3400         * UIProcess/WebUIClient.h:
3401         * UIProcess/mac/WebInspectorProxyMac.mm:
3402         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
3403         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3404         * WebProcess/WebCoreSupport/WebChromeClient.h:
3405         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3406         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
3407         * WebProcess/WebPage/WebPage.cpp:
3408         * WebProcess/WebPage/WebPage.h:
3409
3410 2014-01-14  Csaba Osztrogonác  <ossy@webkit.org>
3411
3412         Speculative buildfix after r161999.
3413
3414         * Shared/APIObject.h:
3415
3416 2014-01-09  Roger Fong  <roger_fong@apple.com>
3417
3418         Add support for handling WebGL load policies.
3419         https://bugs.webkit.org/show_bug.cgi?id=126935
3420         <rdar://problem/15790448>.
3421
3422         Reviewed by Brent Fulgham.
3423
3424         Boiler plate code for sending messages to and from the UI and Web Process. 
3425
3426         * UIProcess/API/C/WKAPICast.h:
3427         (WebKit::toWebGLLoadPolicy):
3428         * UIProcess/API/C/WKPageLoaderClient.h:
3429         * UIProcess/API/C/WKPageUIClient.h:
3430         * UIProcess/WebLoaderClient.cpp:
3431         (WebKit::WebLoaderClient::webGLLoadPolicy):
3432         * UIProcess/WebLoaderClient.h:
3433         * UIProcess/WebPageProxy.cpp:
3434         (WebKit::WebPageProxy::webGLContextCreated):
3435         (WebKit::WebPageProxy::webGLPolicyForHost):
3436         * UIProcess/WebPageProxy.h:
3437         * UIProcess/WebPageProxy.messages.in:
3438         * UIProcess/WebUIClient.cpp:
3439         (WebKit::WebUIClient::webGLContextCreated):
3440         * UIProcess/WebUIClient.h:
3441         * UIProcess/mac/WebInspectorProxyMac.mm:
3442         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
3443         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3444         (WebKit::WebChromeClient::webGLContextCreated):
3445         * WebProcess/WebCoreSupport/WebChromeClient.h:
3446         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3447         (WebKit::WebFrameLoaderClient::webGLPolicyForHost):
3448         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
3449         * WebProcess/WebPage/WebPage.cpp: A sendSync is used here to get the webGLPolicyForHost message sent between the Web and UI process.
3450                                           In the future this will be replaced with a strategy is non-blocking.
3451         (WebKit::WebPage::getWebGLPolicyForHost):
3452         * WebProcess/WebPage/WebPage.h:
3453
3454 2014-01-14  Mark Rowe  <mrowe@apple.com>
3455
3456         WebKit2 leaks sudden termination assertions when a page with unload handlers is closed.
3457         <https://webkit.org/b/126974> / <rdar://problem/15812954>
3458
3459         When a page with an unload handler is loaded, the web process tells the UI process that it
3460         should disable sudden termination. However, when the page is closed the connection between
3461         the web and UI process is torn down before the web content has a chance to tell the UI
3462         process to reenable sudden termination.
3463
3464         Reviewed by Anders Carlsson.
3465
3466         * UIProcess/WebProcessProxy.cpp:
3467         (WebKit::WebProcessProxy::WebProcessProxy):
3468         (WebKit::WebProcessProxy::~WebProcessProxy): Balance any outstanding disableSuddenTermination calls.
3469         (WebKit::WebProcessProxy::enableSuddenTermination): Decrement the count.
3470         (WebKit::WebProcessProxy::disableSuddenTermination): Increment the count.
3471         * UIProcess/WebProcessProxy.h:
3472
3473 2014-01-14  Joseph Pecoraro  <pecoraro@apple.com>
3474
3475         Web Inspector: For Remote Inspection link WebProcess's to their parent UIProcess
3476         https://bugs.webkit.org/show_bug.cgi?id=126995
3477
3478         Reviewed by Timothy Hatcher.
3479
3480         * WebProcess/WebCoreSupport/WebInspectorClient.h:
3481         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3482         (WebKit::WebInspectorClient::parentProcessIdentifier):
3483         WebProcesses are proxies for a parent UIProcess.
3484
3485 2014-01-14  Tim Horton  <timothy_horton@apple.com>
3486
3487         iOS WebKit2 build fixes, part 3
3488
3489         * WebKit2.xcodeproj/project.pbxproj:
3490         Remove some files from the 'All' target that should never have been a part of it.
3491
3492 2014-01-14  Tim Horton  <timothy_horton@apple.com>
3493
3494         iOS WebKit2 build fixes, part 2
3495
3496         * WebKit2.xcodeproj/project.pbxproj:
3497         Add some missing files.
3498
3499 2014-01-14  Brian J. Burg  <burg@cs.washington.edu>
3500
3501         Add ENABLE(WEB_REPLAY) feature flag to the build system
3502         https://bugs.webkit.org/show_bug.cgi?id=126949
3503
3504         Reviewed by Joseph Pecoraro.
3505
3506         * Configurations/FeatureDefines.xcconfig:
3507
3508 2014-01-14  Tim Horton  <timothy_horton@apple.com>
3509
3510         Move WKView.mm to WKViewIOS.mm as 161950 was supposed to do.
3511
3512         * UIProcess/API/ios/WKView.mm: Removed.
3513         * UIProcess/API/ios/WKViewIOS.mm: Copied from UIProcess/API/ios/WKView.mm.
3514
3515 2014-01-14  Carlos Garcia Campos  <cgarcia@igalia.com>
3516
3517         [GTK] Test /webkit2/WebKitWebContext/languages crashes with network process enabled
3518         https://bugs.webkit.org/show_bug.cgi?id=126130
3519
3520         Reviewed by Anders Carlsson.
3521
3522         We need to notify the network process when the user preferred
3523         languages have changed to update the SoupSession accordingly.
3524
3525         * NetworkProcess/NetworkProcess.h: Add
3526         userPreferredLanguagesChanged when using soup network backend.
3527         * NetworkProcess/NetworkProcess.messages.in: Add
3528         UserPreferredLanguagesChanged message when using soup network
3529         backend.
3530         * NetworkProcess/soup/NetworkProcessSoup.cpp:
3531         (WebKit::NetworkProcess::userPreferredLanguagesChanged): Update
3532         the SoupSession to use the given languages.
3533         (WebKit::NetworkProcess::platformInitializeNetworkProcess): Call
3534         userPreferredLanguagesChanged() when initialization parameters
3535         contain languages.
3536         (WebKit::NetworkProcess::allowSpecificHTTPSCertificateForHost):
3537         Remove unnedded WebCore prefix.
3538         (WebKit::NetworkProcess::clearCacheForAllOrigins): Simplify using
3539         a single line.
3540         * Shared/Network/NetworkProcessCreationParameters.cpp:
3541         (WebKit::NetworkProcessCreationParameters::encode): Encode the
3542         languages vector.
3543         (WebKit::NetworkProcessCreationParameters::decode): Decode the
3544         languages vector.
3545         * Shared/Network/NetworkProcessCreationParameters.h:
3546         * UIProcess/WebContext.cpp:
3547         (WebKit::WebContext::languageChanged): Send a message also to the
3548         network process.
3549         * UIProcess/soup/WebContextSoup.cpp:
3550         (WebKit::WebContext::platformInitializeNetworkProcess): Set
3551         languages initial parameter.
3552
3553 2014-01-14  Carlos Garcia Campos  <cgarcia@igalia.com>
3554
3555         [SOUP] SoupNetworkSession::setAcceptLanguages should receive a const reference
3556         https://bugs.webkit.org/show_bug.cgi?id=126966
3557
3558         Reviewed by Gustavo Noronha Silva.
3559
3560         * WebProcess/soup/WebProcessSoup.cpp:
3561         (WebKit::setSoupSessionAcceptLanguage): Use const Vector<String>&.
3562
3563 2014-01-14  Andreas Kling  <akling@apple.com>
3564
3565         Remove deprecated DeferrableOneShotTimer constructor.
3566         <https://webkit.org/b/126984>
3567
3568         Reviewed by Anders Carlsson.
3569
3570         * WebProcess/Plugins/PluginView.h:
3571         * WebProcess/Plugins/PluginView.cpp:
3572         (WebKit::PluginView::pluginSnapshotTimerFired):
3573
3574             Take the timer by reference so we can use the new constructor.
3575
3576 2014-01-13  Tim Horton  <timothy_horton@apple.com>
3577
3578         iOS WebKit2 build fixes, part 1
3579
3580         * Configurations/WebKit2.xcconfig:
3581         * NetworkProcess/NetworkResourceLoader.cpp:
3582         * NetworkProcess/NetworkResourceLoader.h:
3583         * NetworkProcess/RemoteNetworkingContext.h:
3584         * Shared/WebEventConversion.h:
3585         * UIProcess/API/ios/WKGeolocationProviderIOS.mm:
3586         * UIProcess/API/ios/WKInteractionView.mm:
3587         (-[WKTextPosition isEqual:]):
3588         * UIProcess/API/ios/WKViewIOS.mm: Renamed from Source/WebKit2/UIProcess/API/ios/WKView.mm.
3589         * UIProcess/ios/WebPageProxyIOS.mm:
3590         * UIProcess/ios/WebProcessProxyIOS.mm:
3591         * WebKit2.xcodeproj/project.pbxproj:
3592         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
3593         * WebProcess/WebPage/WebPage.h:
3594         * WebProcess/WebPage/ios/WebPageIOS.mm:
3595         (WebKit::WebPage::elementDidFocus):
3596         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
3597
3598 2014-01-13  Jinwoo Song  <jinwoo7.song@samsung.com>
3599
3600         [EFL][WK2] Disable failing API tests
3601         https://bugs.webkit.org/show_bug.cgi?id=126960
3602
3603         Reviewed by Gyuyoung Kim.
3604
3605         Disable color picker test until bug 119120 is resolved.
3606
3607         * UIProcess/API/efl/tests/test_ewk2_color_picker.cpp:
3608         (TEST_F):
3609
3610 2014-01-13  Jinwoo Song  <jinwoo7.song@samsung.com>
3611
3612         [EFL][WK2] ewk_view_page_contents_get() API test is failing
3613         https://bugs.webkit.org/show_bug.cgi?id=126957
3614
3615         Reviewed by Gyuyoung Kim.
3616
3617         As the day in 'Date' field may be one digit or two digit,
3618         the data length may also be varied by one byte.
3619
3620         * UIProcess/API/efl/tests/test_ewk2_view.cpp:
3621         (EWK2ViewTest::PageContentsAsMHTMLCallback):
3622
3623 2014-01-13  Commit Queue  <commit-queue@webkit.org>
3624
3625         Unreviewed, rolling out r161939.
3626         http://trac.webkit.org/changeset/161939
3627         https://bugs.webkit.org/show_bug.cgi?id=126956
3628
3629         didn't work with mac, of course (Requested by thorton on
3630         #webkit).
3631
3632         * NetworkProcess/NetworkResourceLoader.cpp:
3633         * NetworkProcess/NetworkResourceLoader.h:
3634         * NetworkProcess/RemoteNetworkingContext.h:
3635         * Shared/WebEventConversion.h:
3636         * UIProcess/API/ios/WKGeolocationProviderIOS.mm:
3637         * UIProcess/API/ios/WKInteractionView.mm:
3638         (-[WKTextPosition isEqual:]):
3639         * WebKit2.xcodeproj/project.pbxproj:
3640         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
3641         * WebProcess/WebPage/WebPage.h:
3642         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
3643
3644 2014-01-13  Benjamin Poulain  <bpoulain@apple.com>
3645
3646         Update WebPageProxyIOS's user agent string
3647         https://bugs.webkit.org/show_bug.cgi?id=126933
3648
3649         Reviewed by Darin Adler.
3650
3651         * UIProcess/ios/WebPageProxyIOS.mm:
3652         (WebKit::WebPageProxy::standardUserAgent):
3653         Send a more reasonable user agent. The previous one was forcing
3654         iOS 5.1's iPad user-agent.
3655
3656 2014-01-13  Tim Horton  <timothy_horton@apple.com>
3657
3658         iOS WebKit2 build fixes
3659
3660         * NetworkProcess/NetworkResourceLoader.cpp:
3661         * NetworkProcess/NetworkResourceLoader.h:
3662         Introduce/clarify some confusion about CFNETWORK vs. PLATFORM(IOS).
3663
3664         * NetworkProcess/RemoteNetworkingContext.h:
3665         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
3666         Get rid of an override of something that doesn't exist anymore.
3667
3668         * WebKit2.xcodeproj/project.pbxproj:
3669         Add some files. It's likely there are more missing, but this is a start.
3670
3671         * Shared/WebEventConversion.h:
3672         * WebProcess/WebPage/WebPage.h:
3673         Use WebKitAdditions.
3674
3675         * UIProcess/API/ios/WKGeolocationProviderIOS.mm:
3676         Something bizarre is happening with internal deprecation warnings.
3677
3678         * UIProcess/API/ios/WKInteractionView.mm:
3679         (-[WKTextPosition isEqual:]):
3680         Fix a typo.
3681
3682         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
3683         Remove an override of something that doesn't exist anymore.
3684
3685 2014-01-13  Andy Estes  <aestes@apple.com>
3686
3687         [iOS] Build Fix: Don't build the 'All-iOS' target on iOS. Just use 'All'.
3688
3689         * Makefile:
3690
3691 2014-01-13  Martin Robinson  <mrobinson@igalia.com>
3692
3693         [CMake] Mark all dependency include paths and libraries as advanced variables
3694         https://bugs.webkit.org/show_bug.cgi?id=126504
3695
3696         Reviewed by Daniel Bates.
3697
3698         * CMakeLists.txt: Mark the LIBRT_LIBRARIES variable as advanced.
3699
3700 2014-01-13  Martin Robinson  <mrobinson@igalia.com>
3701
3702         [GTK][CMake] Circular dependency in generation of WebKitEnumTypes.h
3703         https://bugs.webkit.org/show_bug.cgi?id=126912
3704
3705         Reviewed by Daniel Bates.
3706
3707         * PlatformGTK.cmake: Remove the circular dependency by generating WebKitEnumTypes.h with
3708         all installed headers except for WebKitEnumTypes.h itself.
3709
3710 2014-01-13  Andy Estes  <aestes@apple.com>
3711
3712         [iOS] Exclude shims and PluginProcess.app from the WebKit2 build
3713         https://bugs.webkit.org/show_bug.cgi?id=126936
3714
3715         Reviewed by Daniel Bates.
3716
3717         * Configurations/All.xcconfig: Added. Excluded PluginProcess.app from
3718         being copied into WebKit2.framework on iOS.
3719         * Configurations/NetworkProcess.xcconfig: Excluded SecItemShim.dylib
3720         from being copied into NetworkProcess.app on iOS.
3721         * Configurations/PluginProcess.xcconfig: Excluded
3722         PluginProcessShim.dylib from being copied into PluginProcess.app and
3723         set SKIP_INSTALL to YES on iOS.
3724         * Configurations/PluginProcessShim.xcconfig: Added. Linked the shim
3725         against necessary frameworks on Mac.
3726         * Configurations/SecItemShim.xcconfig: Ditto.
3727         * Configurations/WebProcessShim.xcconfig: Ditto.
3728         * Configurations/WebContentProcess.xcconfig: Excluded
3729         WebProcessShim.dylib from being copied into WebProcess.app on iOS.
3730         * PluginProcess/mac/PluginProcessShim.mm: Added #if !PLATFORM(IOS) guards.
3731         * Shared/mac/CookieStorageShimLibrary.cpp: Ditto.
3732         * WebProcess/mac/SecItemShimLibrary.mm: Ditto.
3733         * WebKit2.xcodeproj/project.pbxproj: Removed Mac-only frameworks from
3734         the shims' 'Link Binary with Libraries' build phases. Added new xcconfigs.
3735
3736 2014-01-13  Jinwoo Song  <jinwoo7.song@samsung.com>
3737
3738         [EFL][WK2] Replace usage of DEFINE_STATIC_LOCAL with NeverDestroyed
3739         https://bugs.webkit.org/show_bug.cgi?id=126882
3740
3741         Reviewed by Gyuyoung Kim.
3742
3743         * Shared/efl/ProcessExecutablePathEfl.cpp:
3744         (WebKit::executablePathOfWebProcess):
3745         (WebKit::executablePathOfPluginProcess):
3746         (WebKit::executablePathOfNetworkProcess):
3747         * UIProcess/API/efl/EwkView.cpp:
3748         (wkPageToEvasObjectMap):
3749         * UIProcess/API/efl/ewk_context.cpp:
3750         (contextMap):
3751         * UIProcess/API/efl/ewk_page_group.cpp:
3752         (pageGroupMap):
3753         * UIProcess/efl/TextCheckerClientEfl.cpp:
3754         (TextCheckerClientEfl::instance):
3755         * UIProcess/efl/TextCheckerClientEfl.h:
3756
3757 2014-01-13  Carlos Garcia Campos  <cgarcia@igalia.com>
3758
3759         [SOUP] Add SoupNetworkSession class to wrap a SoupSession
3760         https://bugs.webkit.org/show_bug.cgi?id=126813
3761
3762         Reviewed by Gustavo Noronha Silva.
3763
3764         Use the new SoupNetworkSession API.
3765
3766         * NetworkProcess/soup/NetworkProcessSoup.cpp:
3767         (WebKit::NetworkProcess::platformInitializeNetworkProcess):
3768         (WebKit::NetworkProcess::platformSetCacheModel):
3769         (WebKit::NetworkProcess::clearCacheForAllOrigins):
3770         * NetworkProcess/unix/NetworkProcessMainUnix.cpp:
3771         (WebKit::NetworkProcessMain):
3772         * WebProcess/Cookies/soup/WebCookieManagerSoup.cpp:
3773         (WebKit::WebCookieManager::setCookiePersistentStorage):
3774         * WebProcess/efl/WebProcessMainEfl.cpp:
3775         (WebKit::WebProcessMainEfl):
3776         * WebProcess/gtk/WebProcessMainGtk.cpp:
3777         (WebKit::WebProcessMainGtk):
3778         * WebProcess/soup/WebProcessSoup.cpp:
3779         (WebKit::WebProcess::platformSetCacheModel):
3780         (WebKit::WebProcess::platformClearResourceCaches):
3781         (WebKit::setSoupSessionAcceptLanguage):
3782         (WebKit::WebProcess::platformInitializeWebProcess):
3783         * WebProcess/soup/WebSoupRequestManager.cpp:
3784         (WebKit::WebSoupRequestManager::registerURIScheme):
3785
3786 2014-01-13  Zalan Bujtas  <zalan@apple.com>
3787
3788         Enable SUBPIXEL_LAYOUT on Mac
3789         <https://webkit.org/b/126283>
3790
3791         Reviewed by Simon Fraser.
3792
3793         * Configurations/FeatureDefines.xcconfig:
3794
3795 2014-01-12  Sergio Correia  <sergio.correia@openbossa.org>
3796
3797         [EFL][WK2] Make API tests work again
3798         https://bugs.webkit.org/show_bug.cgi?id=126769
3799
3800         Reviewed by Gyuyoung Kim.
3801
3802         The EFL and WK2 test binaries are currently being generated at *TestWebKitAPI/
3803         [E]WebKit2, respectively, and this causes problems because the logic to find
3804         where WebProcess is to look in the same directory of the running process and
3805         then proceed to use LIBEXECDIR (typically /usr/loca/bin).
3806
3807         This patch introduces a WEBKIT_EXEC_PATH environment variable, inspired in the
3808         Gtk port, which allows us to look for WebProcess initially in this directory,
3809         if it's defined.
3810
3811         * Shared/efl/ProcessExecutablePathEfl.cpp:
3812         (WebKit::findProcessPath): Change the logic to look initially in
3813         WEBKIT_EXEC_PATH, then proceed with the existing checks.
3814         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestEnvironment.cpp:
3815         (EWK2UnitTest::EWK2UnitTestEnvironment::EWK2UnitTestEnvironment):
3816         Define WEBKIT_EXEC_PATH to be used by EWebKit2 tests.
3817
3818 2014-01-12  Darin Adler  <darin@apple.com>
3819
3820         Add deprecatedCharacters as a synonym for characters and convert most call sites
3821         https://bugs.webkit.org/show_bug.cgi?id=126858
3822
3823         Reviewed by Anders Carlsson.
3824
3825         * Shared/APIString.h:
3826         * UIProcess/WebPageProxy.cpp:
3827         (WebKit::WebPageProxy::checkTextOfParagraph):
3828         (WebKit::WebPageProxy::checkSpellingOfString):
3829         (WebKit::WebPageProxy::checkGrammarOfString):
3830         * WebProcess/WebPage/EncoderAdapter.cpp:
3831         (WebKit::EncoderAdapter::encodeString):
3832         Use deprecatedCharacters instead of characters.
3833
3834 2014-01-12  Darin Adler  <darin@apple.com>
3835
3836         Add type checking to isEqual methods
3837         https://bugs.webkit.org/show_bug.cgi?id=126862
3838
3839         Reviewed by Anders Carlsson.
3840
3841         * UIProcess/API/ios/WKInteractionView.mm:
3842         (-[WKTextRange isEqual:]): Added type checking for the argument. The old
3843         code asserted instead, and it's not clear what guarantees that assertion is
3844         true. Added a FIXME about the lack of a hash method. Added another FIXME
3845         about the fact that this method ignores much of the object state. Removed
3846         an unneeded extra fetch of the isRange property. Deleted some dead code.
3847         (-[WKTextPosition isEqual:]): Ditto.
3848
3849 2014-01-12  Anders Carlsson  <andersca@apple.com>
3850
3851         Remove the last remaining uses of AtomicallyInitializedStatic
3852         https://bugs.webkit.org/show_bug.cgi?id=126863
3853
3854         Reviewed by Darin Adler.
3855
3856         * Shared/mac/SecItemShim.cpp:
3857         (WebKit::responseMap):
3858
3859 2014-01-12  Dan Bernstein  <mitz@apple.com>
3860
3861         Added a reference to WebContentService/Info-OSX.plist to the project.
3862
3863         * WebKit2.xcodeproj/project.pbxproj:
3864
3865 2014-01-12  Dan Bernstein  <mitz@apple.com>
3866
3867         OS X build fix.
3868
3869         * WebKit2.xcodeproj/project.pbxproj:
3870         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX.plist: Copied from WebProcess/EntryPoint/mac/XPCService/WebContentService/Info.plist.
3871         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info.plist: Removed.
3872
3873 2014-01-12  Andy Estes  <aestes@apple.com>
3874
3875         Build Fix: Objective-C GC should be unsupported in iOS WebKit2
3876
3877         * Configurations/Base.xcconfig:
3878
3879 2014-01-12  Andy Estes  <aestes@apple.com>
3880
3881         [iOS] Upstream WebKit2 xcconfig changes to fix the build
3882
3883         * Configurations/All-iOS.xcconfig: Added.
3884         * Configurations/Base.xcconfig:
3885         * Configurations/BaseLegacyProcess.xcconfig:
3886         * Configurations/BaseTarget.xcconfig:
3887         * Configurations/BaseXPCService.xcconfig:
3888         * Configurations/DebugRelease.xcconfig:
3889         * Configurations/WebContentService.xcconfig:
3890         * Configurations/iOS.xcconfig: Added.
3891
3892 2014-01-12  Carlos Garcia Campos  <cgarcia@igalia.com>
3893
3894         Unreviewed. Fix make distcheck.
3895
3896         * GNUmakefile.am: Add WebKit2InspectorGResourceBundle.xml to
3897         EXTRA_DIST.
3898         * GNUmakefile.list.am: Removed deleted files and add missing ones.
3899         * NetworkProcess/unix/NetworkProcessMainUnix.cpp: Move
3900         ProxyResolverSoup.h to EFL platform ifdef, because GTK port doesn't
3901         build the proxy resolver.
3902
3903 2014-01-12  Carlos Garcia Campos  <cgarcia@igalia.com>
3904
3905         [GTK] Fix return value of WebKitDownload::created-destination
3906         https://bugs.webkit.org/show_bug.cgi?id=126741
3907
3908         Reviewed by Martin Robinson.
3909
3910         WebKitDownload::created-destination signal should be void instead
3911         of gboolean. This doesn't break the API/ABI.
3912
3913         * UIProcess/API/gtk/WebKitDownload.cpp:
3914         (webkit_download_class_init):
3915         (webkitDownloadDestinationCreated):
3916
3917 2014-01-11  Yongjun Zhang  <yongjun_zhang@apple.com>
3918
3919         Support bool argument for encoding/decoding invocations.
3920         https://bugs.webkit.org/show_bug.cgi?id=126823
3921
3922         Reviewed by Sam Weinig.
3923
3924         For remote invocation method argument, current we support int, double and ObjC
3925         object, this patch add support for bool type too.
3926
3927         * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
3928         (encodeInvocation):
3929         (decodeInvocationArguments):
3930
3931 2014-01-11  Alexey Proskuryakov  <ap@apple.com>
3932
3933         [Mac] [Windows] Stop scheduling network requests in WebCore
3934         https://bugs.webkit.org/show_bug.cgi?id=126789
3935         <rdar://problem/15114727>
3936
3937         Reviewed by Sam Weinig.
3938
3939         * NetworkProcess/mac/NetworkResourceLoadSchedulerMac.mm:
3940         (WebKit::NetworkResourceLoadScheduler::platformInitializeMaximumHTTPConnectionCountPerHost):
3941         We no longer need the trick with 7 connections, as synchronous requests always have
3942         the right of way.
3943
3944         * UIProcess/API/C/WKContext.cpp: Removed long obsolete functions.
3945
3946         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm: (InitWebCoreSystemInterface):
3947         Updated for new WKSI function names.
3948
3949 2014-01-11  Simon Fraser  <simon.fraser@apple.com>
3950
3951         Unfork GraphicsContext::drawNativeImage for iOS
3952         https://bugs.webkit.org/show_bug.cgi?id=126824
3953
3954         Reviewed by Dean Jackson.
3955
3956         GraphicsContext::drawNativeImage had a different signature for iOS,
3957         which required #ifdefs at all the call sites. Unfork by passing the "scale"
3958         parameter everywhere (it's only used on iOS).
3959
3960         * Shared/API/c/cg/WKImageCG.cpp:
3961         (WKImageCreateFromCGImage):
3962
3963 2014-01-11  Sam Weinig  <sam@webkit.org>
3964
3965         Clean up iterator filter / iterator range code
3966         https://bugs.webkit.org/show_bug.cgi?id=126817
3967
3968         Reviewed by Anders Carlsson.
3969
3970         * Shared/APIArray.h:
3971         Update elementsOfType() to use combination of FilterIterator and TransformIterator
3972         (now that FilterIterator no longer has a transform predicate) and make use of the 
3973         makeFoo() helpers.
3974
3975 2014-01-11  Anders Carlsson  <andersca@apple.com>
3976
3977         Simplify Timer and DeferrableOneShotTimer using std::function
3978         https://bugs.webkit.org/show_bug.cgi?id=126816
3979
3980         Reviewed by Sam Weinig.
3981
3982         Add another unexported symbol.
3983
3984         * Configurations/WebKit2.xcconfig:
3985
3986 2014-01-11  Jinwoo Song  <jinwoo7.song@samsung.com>
3987
3988         [EFL][WK2] Use nullptr instead of 0 in EFL API layer
3989         https://bugs.webkit.org/show_bug.cgi?id=126806
3990
3991         Reviewed by Anders Carlsson.
3992
3993         * UIProcess/API/efl/EwkView.cpp:
3994         (EwkView::create):
3995         * UIProcess/API/efl/ewk_auth_request.cpp:
3996         (ewk_auth_request_suggested_username_get):
3997         (ewk_auth_request_realm_get):
3998         (ewk_auth_request_host_get):
3999         * UIProcess/API/efl/ewk_back_forward_list.cpp:
4000         (ewk_back_forward_list_current_item_get):
4001         (ewk_back_forward_list_previous_item_get):
4002         (ewk_back_forward_list_next_item_get):
4003         (ewk_back_forward_list_item_at_index_get):
4004         (ewk_back_forward_list_n_back_items_copy):
4005         (ewk_back_forward_list_n_forward_items_copy):
4006         * UIProcess/API/efl/ewk_back_forward_list_item.cpp:
4007         (ewk_back_forward_list_item_url_get):
4008         (ewk_back_forward_list_item_title_get):
4009         (ewk_back_forward_list_item_original_url_get):
4010         * UIProcess/API/efl/ewk_context.cpp:
4011         (ewk_context_cookie_manager_get):
4012         (ewk_context_database_manager_get):
4013         (ewk_context_favicon_database_get):
4014         (ewk_context_storage_manager_get):
4015         (ewk_context_new_with_injected_bundle_path):
4016         * UIProcess/API/efl/ewk_context_menu.cpp:
4017         (ewk_context_menu_items_get):
4018         * UIProcess/API/efl/ewk_context_menu_item.cpp:
4019         (ewk_context_menu_item_new_with_submenu):
4020         (ewk_context_menu_item_title_get):
4021         (ewk_context_menu_item_parent_menu_get):
4022         (ewk_context_menu_item_submenu_get):
4023         * UIProcess/API/efl/ewk_download_job.cpp:
4024         (ewk_download_job_request_get):
4025         (ewk_download_job_response_get):
4026         (ewk_download_job_destination_get):
4027         (ewk_download_job_suggested_filename_get):
4028         * UIProcess/API/efl/ewk_error.cpp:
4029         (ewk_error_url_get):
4030         (ewk_error_description_get):
4031         * UIProcess/API/efl/ewk_file_chooser_request.cpp:
4032         (ewk_file_chooser_request_accepted_mimetypes_get):
4033         * UIProcess/API/efl/ewk_form_submission_request.cpp:
4034         (ewk_form_submission_request_field_names_get):
4035         (ewk_form_submission_request_field_value_get):
4036         * UIProcess/API/efl/ewk_navigation_data.cpp:
4037         (ewk_navigation_data_title_get):
4038         (ewk_navigation_data_original_request_get):
4039         (ewk_navigation_data_url_get):
4040         * UIProcess/API/efl/ewk_navigation_policy_decision.cpp:
4041         (ewk_navigation_policy_frame_name_get):
4042         (ewk_navigation_policy_request_get):
4043         * UIProcess/API/efl/ewk_object.cpp:
4044         (ewk_object_ref):
4045         * UIProcess/API/efl/ewk_popup_menu.cpp:
4046         (ewk_popup_menu_items_get):
4047         * UIProcess/API/efl/ewk_popup_menu_item.cpp:
4048         (ewk_popup_menu_item_text_get):
4049         (ewk_popup_menu_item_tooltip_get):
4050         (ewk_popup_menu_item_accessibility_text_get):
4051         * UIProcess/API/efl/ewk_security_origin.cpp:
4052         (ewk_security_origin_host_get):
4053         (ewk_security_origin_protocol_get):
4054         * UIProcess/API/efl/ewk_settings.cpp:
4055         (ewk_settings_default_text_encoding_name_get):
4056         * UIProcess/API/efl/ewk_url_request.cpp:
4057         (ewk_url_request_url_get):
4058         (ewk_request_cookies_first_party_get):
4059         (ewk_url_request_http_method_get):
4060         * UIProcess/API/efl/ewk_url_response.cpp:
4061         (ewk_url_response_url_get):
4062         (ewk_url_response_mime_type_get):
4063         * UIProcess/API/efl/ewk_url_scheme_request.cpp:
4064         (ewk_url_scheme_request_scheme_get):
4065         (ewk_url_scheme_request_url_get):
4066         (ewk_url_scheme_request_path_get):
4067         * UIProcess/API/efl/ewk_view.cpp:
4068         (toEwkViewChecked):
4069         (EWKViewGetWKView):
4070         (ewk_view_smart_add):
4071         (ewk_view_add_with_context):
4072         (ewk_view_context_get):
4073         (ewk_view_page_group_get):
4074         (ewk_view_url_get):
4075         (ewk_view_favicon_get):
4076         (ewk_view_settings_get):
4077         (ewk_view_title_get):
4078         (ewk_view_theme_get):
4079         (ewk_view_back_forward_list_get):
4080         (ewk_view_custom_encoding_get):
4081         (ewk_view_user_agent_get):
4082
4083 2014-01-10  Anders Carlsson  <andersca@apple.com>
4084
4085         Tweak ProgressTrackerClient functions
4086         https://bugs.webkit.org/show_bug.cgi?id=126808
4087
4088         Reviewed by Sam Weinig.
4089
4090         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
4091         (WebKit::WebFrameLoaderClient::progressStarted):
4092         (WebKit::WebFrameLoaderClient::progressEstimateChanged):
4093         (WebKit::WebFrameLoaderClient::progressFinished):
4094         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
4095