[EFL][WK2] Rename async APIs for better consistency with EFL
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2014-03-18  Ryuan Choi  <ryuan.choi@samsung.com>
2
3         [EFL][WK2] Rename async APIs for better consistency with EFL
4         https://bugs.webkit.org/show_bug.cgi?id=130319
5
6         Reviewed by Gyuyoung Kim.
7
8         There are inconsistency with async keyword in several ewebkit2 APIs.
9         This patch rename them to {module/feature}_async_{verb} for better consistency with EFL.
10         In addition, added Async keyword into their callback name.
11
12         * UIProcess/API/efl/ewk_application_cache_manager.cpp:
13         (EwkApplicationCacheOriginsAsyncData::EwkApplicationCacheOriginsAsyncData):
14         (getApplicationCacheOriginsCallback):
15         (ewk_application_cache_manager_origins_async_get):
16         * UIProcess/API/efl/ewk_application_cache_manager.h:
17         * UIProcess/API/efl/ewk_cookie_manager.cpp:
18         (EwkCookiePolicyAsyncData::EwkCookiePolicyAsyncData):
19         (getAcceptPolicyCallback):
20         (ewk_cookie_manager_accept_policy_async_get):
21         (EwkCookieHostnamesAsyncData::EwkCookieHostnamesAsyncData):
22         (getHostnamesWithCookiesCallback):
23         (ewk_cookie_manager_hostnames_with_cookies_async_get):
24         * UIProcess/API/efl/ewk_cookie_manager.h:
25         * UIProcess/API/efl/ewk_database_manager.cpp:
26         (EwkDatabaseOriginsAsyncData::EwkDatabaseOriginsAsyncData):
27         (getDatabaseOriginsCallback):
28         (ewk_database_manager_origins_async_get):
29         * UIProcess/API/efl/ewk_database_manager.h:
30         * UIProcess/API/efl/ewk_storage_manager.cpp:
31         (EwkStorageOriginsAsyncData::EwkStorageOriginsAsyncData):
32         (getStorageOriginsCallback):
33         (ewk_storage_manager_origins_async_get):
34         * UIProcess/API/efl/ewk_storage_manager.h:
35         * UIProcess/API/efl/tests/test_ewk2_application_cache_manager.cpp:
36         (timerCallback):
37         * UIProcess/API/efl/tests/test_ewk2_cookie_manager.cpp:
38         (EWK2CookieManagerTest::getAcceptPolicy):
39         (EWK2CookieManagerTest::getHostnamesWithCookies):
40         * UIProcess/API/efl/tests/test_ewk2_database_manager.cpp:
41         (EWK2DatabaseManagerTest::timerCallback):
42         (TEST_F):
43         * UIProcess/API/efl/tests/test_ewk2_storage_manager.cpp:
44         (EWK2StorageManagerTest::timerCallback):
45         (TEST_F):
46
47 2014-03-18  Tim Horton  <timothy_horton@apple.com>
48
49         [iOS][WebKit2] Mark layer contents as being opaque if they are
50         https://bugs.webkit.org/show_bug.cgi?id=130427
51         <rdar://problem/15540434>
52
53         Reviewed by Simon Fraser.
54
55         * Shared/mac/RemoteLayerBackingStore.h:
56         (WebKit::RemoteLayerBackingStore::isOpaque):
57         * Shared/mac/RemoteLayerBackingStore.mm:
58         (RemoteLayerBackingStore::RemoteLayerBackingStore):
59         (RemoteLayerBackingStore::ensureBackingStore):
60         (RemoteLayerBackingStore::encode):
61         (RemoteLayerBackingStore::decode):
62         (RemoteLayerBackingStore::display):
63         (RemoteLayerBackingStore::applyBackingStoreToLayer):
64         Move the code to set a RemoteLayerBackingStore as a CALayer's contents
65         from RemoteLayerTreePropertyApplier to RemoteLayerBackingStore (mostly
66         as a way to keep the USE(IOSURFACE) #ifs in one place).
67         Remove the surface() getter, because it's no longer needed, and make
68         image() private as it can be now (and rename it to createImageForFrontBuffer
69         for clarity's sake).
70
71         Add an isOpaque argument to ensureBackingStore, encode/decode it, and
72         add a getter. If isOpaque is true when applying backing store to the
73         CALayer on the UI process side, set CALayer.contentsOpaque to let CA know.
74
75         Make opaque bitmaps if not using accelerated drawing. For the IOSurface
76         case, we can't make opaque IOSurfaces, but telling CA that we have filled
77         the whole bitmap still enables similar optimizations.
78
79         * Shared/mac/RemoteLayerTreePropertyApplier.mm:
80         (WebKit::applyPropertiesToLayer):
81         Reset contentsOpaque if the layer loses its backing store.
82
83         * Shared/mac/RemoteLayerTreeTransaction.mm:
84         (WebKit::RemoteLayerTreeTextStream::operator<<):
85         (WebKit::dumpChangedLayers):
86         Add a bit more logging about RemoteLayerBackingStore's opaqueness
87         and acceleratedness.
88
89         * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
90         (PlatformCALayerRemote::updateBackingStore):
91         (PlatformCALayerRemote::setOpaque):
92         Invalidate the RemoteLayerBackingStore if layer opaqueness changes.
93
94 2014-03-18  Brady Eidson  <beidson@apple.com>
95
96         Make image controls menu work in WK2
97         <rdar://problem/16294412> and https://bugs.webkit.org/show_bug.cgi?id=130424
98
99         Reviewed by Tim Horton.
100
101         * Platform/SharedMemory.h:
102         * Platform/mac/SharedMemoryMac.cpp:
103         (WebKit::SharedMemory::Handle::~Handle):
104         (WebKit::SharedMemory::Handle::clear):
105
106         * Platform/unix/SharedMemoryUnix.cpp:
107         (WebKit::SharedMemory::Handle::~Handle):
108         (WebKit::SharedMemory::Handle::clear):
109
110         * Shared/ContextMenuContextData.cpp:
111         (WebKit::ContextMenuContextData::ContextMenuContextData):
112         (WebKit::ContextMenuContextData::operator=):
113         (WebKit::ContextMenuContextData::encode):
114         (WebKit::ContextMenuContextData::decode):
115         * Shared/ContextMenuContextData.h:
116         (WebKit::ContextMenuContextData::controlledImageHandle):
117
118         * Shared/ShareableBitmap.cpp:
119         (WebKit::ShareableBitmap::Handle::clear):
120         * Shared/ShareableBitmap.h:
121         * UIProcess/WebContextMenuProxy.h:
122
123         * UIProcess/WebPageProxy.cpp:
124         (WebKit::WebPageProxy::internalShowContextMenu):
125         (WebKit::WebPageProxy::replaceControlledImage):
126         * UIProcess/WebPageProxy.h:
127
128         * UIProcess/efl/WebContextMenuProxyEfl.cpp:
129         (WebKit::WebContextMenuProxyEfl::showContextMenu):
130         * UIProcess/efl/WebContextMenuProxyEfl.h:
131
132         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
133         (WebKit::WebContextMenuProxyGtk::showContextMenu):
134         * UIProcess/gtk/WebContextMenuProxyGtk.h:
135
136         Add a sharing service context menu that lives side-by-side with the normal one:
137         * UIProcess/mac/WebContextMenuProxyMac.h:
138         * UIProcess/mac/WebContextMenuProxyMac.mm:
139         (+[WKSharingServicePickerDelegate sharedSharingServicePickerDelegate]):
140         (-[WKSharingServicePickerDelegate setMenuProxy:WebKit::]):
141         (-[WKSharingServicePickerDelegate setPicker:]):
142         (-[WKSharingServicePickerDelegate sharingServicePicker:delegateForSharingService:]):
143         (-[WKSharingServicePickerDelegate sharingService:willShareItems:]):
144         (-[WKSharingServicePickerDelegate sharingService:didShareItems:]):
145         (-[WKSharingServicePickerDelegate sharingService:sourceFrameOnScreenForShareItem:]):
146         (-[WKSharingServicePickerDelegate sharingService:transitionImageForShareItem:contentRect:]):
147         (-[WKSharingServicePickerDelegate sharingService:sourceWindowForShareItems:sharingContentScope:]):
148         (WebKit::WebContextMenuProxyMac::contextMenuItemSelected):
149         (WebKit::WebContextMenuProxyMac::setupImageServicesMenu):
150         (WebKit::WebContextMenuProxyMac::clearImageServicesMenu):
151         (WebKit::WebContextMenuProxyMac::populate):
152         (WebKit::WebContextMenuProxyMac::showContextMenu):
153         (WebKit::WebContextMenuProxyMac::window):
154         (WebKit::WebContextMenuProxyMac::replaceControlledImage):
155
156         * WebProcess/WebPage/WebContextMenu.cpp:
157         (WebKit::WebContextMenu::show):
158         (WebKit::WebContextMenu::replaceControlledImage):
159         * WebProcess/WebPage/WebContextMenu.h:
160
161         Teach the WebProcess how to accept the replaced image.
162         * WebProcess/WebPage/WebPage.cpp:
163         (WebKit::WebPage::replaceControlledImage):
164         * WebProcess/WebPage/WebPage.h:
165         * WebProcess/WebPage/WebPage.messages.in:
166
167 2014-03-18  Anders Carlsson  <andersca@apple.com>
168
169         Begin cleaning up KeyedDecoder and KeyedEncoder
170         https://bugs.webkit.org/show_bug.cgi?id=130431
171
172         Reviewed by Tim Horton.
173
174         * Shared/cf/KeyedDecoder.cpp:
175         (WebKit::KeyedDecoder::KeyedDecoder):
176         If we can't parse the property list data, just add an empty dictionary to the stack.
177
178         (WebKit::KeyedDecoder::decodeBool):
179         Remove unneeded m_dictionaryStack.last() null check. m_dictionaryStack would either be empty
180         or at least have a root element; it would never have a null element.
181         
182         (WebKit::KeyedDecoder::decodeDouble):
183         Remove the same check as above and remove the CFNumberGetType checks since CFNumberGetValue will
184         do the type conversion for us and return false if it's lossy.
185
186         (WebKit::KeyedDecoder::decodeInt64):
187         Remove the m_dictionaryStack.last() check.
188
189         (WebKit::KeyedDecoder::decodeUInt32):
190         Ditto.
191
192         (WebKit::KeyedDecoder::decodeString):
193         Ditto.
194
195         (WebKit::KeyedDecoder::beginObject):
196         Ditto.
197
198         (WebKit::KeyedDecoder::beginArray):
199         Ditto.
200
201         (WebKit::KeyedDecoder::beginArrayElement):
202         Ditto.
203
204         * Shared/cf/KeyedDecoder.h:
205         Sort functions to be in the same logical order as the base class.
206
207         * Shared/cf/KeyedEncoder.cpp:
208         (WebKit::KeyedEncoder::finishEncoding):
209         Don't check for a non-null CFErrorRef here (which we incidentally never released on error). Instead,
210         just null check the returned CFDataRef object.
211
212 2014-03-18  Joseph Pecoraro  <pecoraro@apple.com>
213
214         Unreviewed typo build fix for r165846.
215
216         * Shared/WebPageCreationParameters.cpp:
217         (WebKit::WebPageCreationParameters::decode):
218
219 2014-03-18  Joseph Pecoraro  <pecoraro@apple.com>
220
221         WebKit2 SPI to disable remote inspection on a WKWebView / WKPage
222         https://bugs.webkit.org/show_bug.cgi?id=130371
223
224         Reviewed by Dan Bernstein.
225
226         * Shared/WebPageCreationParameters.h:
227         * Shared/WebPageCreationParameters.cpp:
228         (WebKit::WebPageCreationParameters::encode):
229         (WebKit::WebPageCreationParameters::decode):
230         Add allowsRemoteInspection bool.
231
232         * UIProcess/API/C/WKPagePrivate.h:
233         * UIProcess/API/C/WKPage.cpp:
234         (WKPageGetAllowsRemoteInspection):
235         (WKPageSetAllowsRemoteInspection):
236         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
237         * UIProcess/API/Cocoa/WKWebView.mm:
238         (-[WKWebView _allowsRemoteInspection]):
239         (-[WKWebView _setAllowsRemoteInspection:]):
240         Getter and setter for allowing remote inspection state.
241
242         * UIProcess/WebPageProxy.h:
243         (WebKit::WebPageProxy::allowsRemoteInspection):
244         * UIProcess/WebPageProxy.cpp:
245         (WebKit::WebPageProxy::WebPageProxy):
246         (WebKit::WebPageProxy::setAllowsRemoteInspection):
247         (WebKit::WebPageProxy::creationParameters):
248         Cached allows remote inspection state, with getter and setter.
249
250         * WebProcess/WebPage/WebPage.h:
251         * WebProcess/WebPage/WebPage.messages.in:
252         * WebProcess/WebPage/WebPage.cpp:
253         (WebKit::WebPage::setAllowsRemoteInspection):
254         When setting, call into WebCore to adjust the Page's setting.
255
256 2014-03-18  Anders Carlsson  <andersca@apple.com>
257
258         REGRESSION: Visited link coloring seems to be completely broken in tip of tree
259         https://bugs.webkit.org/show_bug.cgi?id=130419
260         <rdar://problem/16337850>
261
262         Reviewed by Dan Bernstein.
263
264         Make sure to send any queued up messages before calling connectionWillOpen so we'll ensure
265         FIFO ordering if any messages are sent from within connectionWillOpen.
266
267         * Shared/ChildProcessProxy.cpp:
268         (WebKit::ChildProcessProxy::didFinishLaunching):
269
270 2014-03-18  Joseph Pecoraro  <pecoraro@apple.com>
271
272         WebPageCreationParameters colorSpace should be MAC not COCOA
273         https://bugs.webkit.org/show_bug.cgi?id=130414
274
275         Reviewed by Dan Bernstein.
276
277         The colorSpace param was only set and used on Mac, not iOS.
278
279         * Shared/WebPageCreationParameters.h:
280         * Shared/WebPageCreationParameters.cpp:
281         (WebKit::WebPageCreationParameters::encode):
282         (WebKit::WebPageCreationParameters::decode):
283
284 2014-03-18  Simon Fraser  <simon.fraser@apple.com>
285
286         Dan says that options should be unsigned, and enums should be signed.
287         
288         Reviewed by Dan Bernstein.
289
290         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
291         (NS_ENUM):
292
293 2014-03-17  Alexey Proskuryakov  <ap@apple.com>
294
295         [WK2] Pass ranges over IPC in a cross-platform manner
296         https://bugs.webkit.org/show_bug.cgi?id=130376
297
298         Reviewed by Anders Carlsson.
299
300         Added an EditingRange class for IPC, which automatically converts to and from
301         NSRanges, knowing the difference between notFound and NSNotFound.
302
303         Manually applied the same fix to characterIndexForPoint.
304
305         * Scripts/webkit2/messages.py:
306         (struct_or_class):
307         * Shared/EditingRange.h: Added.
308         (WebKit::EditingRange::EditingRange):
309         (WebKit::EditingRange::isValid):
310         (WebKit::EditingRange::operator NSRange):
311         * UIProcess/API/mac/WKView.mm:
312         (-[WKView insertText:replacementRange:]):
313         (-[WKView selectedRange]):
314         (-[WKView hasMarkedText]):
315         (-[WKView setMarkedText:selectedRange:replacementRange:]):
316         (-[WKView markedRange]):
317         (-[WKView attributedSubstringForProposedRange:actualRange:]):
318         (-[WKView characterIndexForPoint:]):
319         (-[WKView firstRectForCharacterRange:actualRange:]):
320         * UIProcess/WebPageProxy.h:
321         * UIProcess/ios/WKContentViewInteraction.mm:
322         (-[WKContentView setMarkedText:selectedRange:]):
323         (-[WKContentView insertText:]):
324         * UIProcess/ios/WebPageProxyIOS.mm:
325         (WebKit::WebPageProxy::setComposition):
326         (WebKit::WebPageProxy::insertText):
327         (WebKit::WebPageProxy::insertDictatedText):
328         (WebKit::WebPageProxy::getMarkedRange):
329         (WebKit::WebPageProxy::getSelectedRange):
330         (WebKit::WebPageProxy::getAttributedSubstringFromRange):
331         (WebKit::WebPageProxy::firstRectForCharacterRange):
332         * UIProcess/mac/WebPageProxyMac.mm:
333         (WebKit::WebPageProxy::setComposition):
334         (WebKit::WebPageProxy::insertText):
335         (WebKit::WebPageProxy::insertDictatedText):
336         (WebKit::WebPageProxy::getMarkedRange):
337         (WebKit::WebPageProxy::getSelectedRange):
338         (WebKit::WebPageProxy::getAttributedSubstringFromRange):
339         (WebKit::WebPageProxy::firstRectForCharacterRange):
340         * WebKit2.xcodeproj/project.pbxproj:
341         * WebProcess/WebPage/WebPage.cpp:
342         (WebKit::WebPage::rangeFromEditingRange):
343         * WebProcess/WebPage/WebPage.h:
344         * WebProcess/WebPage/WebPage.messages.in:
345         * WebProcess/WebPage/ios/WebPageIOS.mm:
346         (WebKit::WebPage::setComposition):
347         (WebKit::WebPage::insertText):
348         (WebKit::WebPage::insertDictatedText):
349         (WebKit::WebPage::getMarkedRange):
350         (WebKit::WebPage::getSelectedRange):
351         (WebKit::WebPage::getAttributedSubstringFromRange):
352         (WebKit::WebPage::firstRectForCharacterRange):
353         * WebProcess/WebPage/mac/WebPageMac.mm:
354         (WebKit::WebPage::setComposition):
355         (WebKit::WebPage::insertText):
356         (WebKit::WebPage::insertDictatedText):
357         (WebKit::WebPage::getMarkedRange):
358         (WebKit::WebPage::getSelectedRange):
359         (WebKit::WebPage::getAttributedSubstringFromRange):
360         (WebKit::WebPage::characterIndexForPoint):
361         (WebKit::WebPage::firstRectForCharacterRange):
362
363 2014-03-17  Filip Pizlo  <fpizlo@apple.com>
364
365         More FTL enabling.
366
367         Rubber stamped by Dan Bernstein.
368
369         * Configurations/FeatureDefines.xcconfig:
370
371 2014-03-17  Simon Fraser  <simon.fraser@apple.com>
372
373         Renable pagination mode in WK2 MiniBrowser
374         https://bugs.webkit.org/show_bug.cgi?id=130374
375
376         Reviewed by Anders Carlsson.
377         
378         Add SPI for pagination mode.
379
380         * UIProcess/API/Cocoa/WKWebView.mm:
381         (-[WKWebView _paginationMode]):
382         (-[WKWebView _setPaginationMode:]):
383         (-[WKWebView _paginationBehavesLikeColumns]):
384         (-[WKWebView _setPaginationBehavesLikeColumns:]):
385         (-[WKWebView _pageLength]):
386         (-[WKWebView _setPageLength:]):
387         (-[WKWebView _gapBetweenPages]):
388         (-[WKWebView _setGapBetweenPages:]):
389         (-[WKWebView _pageCount]):
390         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
391         (NS_ENUM):
392
393 2014-03-18  Ryuan Choi  <ryuan.choi@samsung.com>
394
395         [CMAKE][WK2]Move CoordinatedGraphics related files out of WebKit2/CMakeLists.txt
396         https://bugs.webkit.org/show_bug.cgi?id=130390
397
398         Reviewed by Martin Robinson.
399
400         Now, only EFL port use CoordinatedGraphics among CMake based ports.
401
402         * CMakeLists.txt:
403         * PlatformEfl.cmake:
404         * PlatformGTK.cmake: Removed CoordinatedGraphics related files.
405
406 2014-03-18  Carlos Garcia Campos  <cgarcia@igalia.com>
407
408         [GTK] Race condition when the socket event source is cancelled
409         https://bugs.webkit.org/show_bug.cgi?id=130395
410
411         Reviewed by Martin Robinson.
412
413         In some cases when the socket event source is cancelled the socket
414         event source callback is called with the condition of the previous
415         poll instead of 0. This can happen sometimes when the source is
416         cancelled from the socket event source callback. Once the socket
417         event source is cancelled, it's dispatched by glib without
418         polling, so the condition is never reset again and the callback is
419         called again and again with the previous condition. When the
420         condition is G_IO_IN, the source is re-scheduled entering into an
421         infinite loop. We should always check if the source has been
422         cancelled at the beginning of the callback to destroy the source
423         instead of relying on the condition being 0.
424
425         * Platform/gtk/WorkQueueGtk.cpp:
426         (WorkQueue::SocketEventSource::isCancelled):
427         (WorkQueue::SocketEventSource::eventCallback):
428
429 2014-03-18  Csaba Osztrogonác  <ossy@webkit.org>
430
431         [GTK] URTFB after r165789. Stub function added.
432
433         * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
434         (WebKit::InjectedBundle::setBundleParameter):
435
436 2014-03-17  Jaehun Lim  <ljaehun.lim@samsung.com>
437
438         Unreviewed, EFL build fix after r165789
439
440         * WebProcess/InjectedBundle/efl/InjectedBundleEfl.cpp:
441         (WebKit::InjectedBundle::setBundleParameter): Implemented.
442
443 2014-03-17  Jae Hyun Park  <jaepark@webkit.org>
444
445         [GTK] Build fix for debug build
446
447         Unreviewed.
448
449         finalizedListItem was actually used in ASSERT.  So, use ASSERT_UNUSED
450         instead of ASSERT.
451
452         * UIProcess/API/gtk/WebKitBackForwardListItem.cpp:
453         (webkitBackForwardListItemFinalized):
454
455 2014-03-17  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
456
457         [WK2] Getting rid of compilation warnings
458         https://bugs.webkit.org/show_bug.cgi?id=130348
459
460         Reviewed by Benjamin Poulain.
461
462         * UIProcess/API/APIHistoryClient.h:
463         (API::HistoryClient::didPerformClientRedirect):
464         (API::HistoryClient::didPerformServerRedirect):
465         (API::HistoryClient::didUpdateHistoryTitle):
466         * UIProcess/API/APILoaderClient.h:
467         (API::LoaderClient::didStartProvisionalLoadForFrame):
468         (API::LoaderClient::didReceiveServerRedirectForProvisionalLoadForFrame):
469         (API::LoaderClient::didFailProvisionalLoadWithErrorForFrame):
470         (API::LoaderClient::didCommitLoadForFrame):
471         (API::LoaderClient::didFinishLoadForFrame):
472         (API::LoaderClient::didFailLoadWithErrorForFrame):
473         (API::LoaderClient::didChangeBackForwardList):
474         * UIProcess/API/APIPolicyClient.h:
475         (API::PolicyClient::decidePolicyForNavigationAction):
476         (API::PolicyClient::decidePolicyForNewWindowAction):
477         (API::PolicyClient::decidePolicyForResponse):
478         (API::PolicyClient::unableToImplementPolicy):
479         * UIProcess/API/APIUIClient.h:
480         (API::UIClient::exceededDatabaseQuota):
481         (API::UIClient::saveDataToFileInDownloadsFolder):
482         * UIProcess/API/C/WKPage.cpp:
483         (WKPageSetPageLoaderClient):
484         * UIProcess/APISession.cpp:
485         (API::generateID):
486         * WebProcess/Plugins/PluginView.cpp:
487         (WebKit::PluginView::viewStateDidChange):
488
489 2014-03-17  Anders Carlsson  <andersca@apple.com>
490
491         Update the bundle parameters dictionary and send out KVO notifications
492         https://bugs.webkit.org/show_bug.cgi?id=130379
493         <rdar://problem/16213914>
494
495         Reviewed by Dan Bernstein.
496
497         * UIProcess/API/Cocoa/WKProcessPool.mm:
498         (-[WKProcessPool _setObject:forBundleParameter:]):
499         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h:
500         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm:
501         (-[WKWebProcessBundleParameters setParameter:forKey:]):
502         * WebProcess/InjectedBundle/InjectedBundle.h:
503         * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
504         (WebKit::InjectedBundle::setBundleParameter):
505         * WebProcess/WebProcess.cpp:
506         (WebKit::WebProcess::setInjectedBundleParameter):
507         * WebProcess/WebProcess.h:
508         * WebProcess/WebProcess.messages.in:
509
510 2014-03-17  Tim Horton  <timothy_horton@apple.com>
511
512         Address some style nits.
513
514         * UIProcess/API/Cocoa/_WKThumbnailViewInternal.h:
515
516 2014-03-17  Simon Fraser  <simon.fraser@apple.com>
517
518         Address some style nits.
519
520         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
521
522 2014-03-17  Simon Fraser  <simon.fraser@apple.com>
523
524         Add transparent window support back into MiniBrowser
525         https://bugs.webkit.org/show_bug.cgi?id=130363
526
527         Reviewed by Anders Carlsson.
528         
529         Expose SPI for transparent window support.
530
531         * UIProcess/API/Cocoa/WKWebView.mm:
532         (-[WKWebView _drawsTransparentBackground]):
533         (-[WKWebView _setDrawsTransparentBackground:]):
534         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
535
536 2014-03-17  Alexey Proskuryakov  <ap@apple.com>
537
538         Undo some accidental Gtk changes from http://trac.webkit.org/changeset/165759
539
540         * UIProcess/WebPageProxy.cpp:
541         * WebProcess/WebPage/WebPage.messages.in:
542
543 2014-03-17  Csaba Osztrogonác  <ossy@webkit.org>
544
545         [WK2] URTBF after r165755 for non Apple platforms, stub functions added.
546
547         * WebProcess/InjectedBundle/efl/InjectedBundleEfl.cpp:
548         (WebKit::InjectedBundle::platformInitialize):
549         * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
550         (WebKit::InjectedBundle::platformInitialize):
551
552 2014-03-17  Alexey Proskuryakov  <ap@apple.com>
553
554         Move convertToRange() helper to cross-platform WebPage.cpp
555         https://bugs.webkit.org/show_bug.cgi?id=130365
556
557         Reviewed by Tim Horton.
558
559         Also renamed it to rangeFromEditingLocationAndLength().
560
561         * WebProcess/WebPage/WebPage.cpp:
562         (WebKit::WebPage::rangeFromEditingLocationAndLength):
563         * WebProcess/WebPage/WebPage.h:
564         * WebProcess/WebPage/ios/WebPageIOS.mm:
565         (WebKit::WebPage::insertText):
566         * WebProcess/WebPage/mac/WebPageMac.mm:
567         (WebKit::WebPage::setComposition):
568         (WebKit::WebPage::insertText):
569         (WebKit::WebPage::insertDictatedText):
570         (WebKit::WebPage::getAttributedSubstringFromRange):
571         (WebKit::WebPage::characterIndexForPoint):
572         (WebKit::WebPage::firstRectForCharacterRange):
573
574 2014-03-17  Anders Carlsson  <andersca@apple.com>
575
576         Follow-up fix.
577
578         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h:
579
580 2014-03-17  Enrica Casucci  <enrica@apple.com>
581
582         WK2: support data detectors driven action sheet..
583         https://bugs.webkit.org/show_bug.cgi?id=130362
584         <rdar://problem/16319711>
585
586         Reviewed by Benjamin Poulain.
587
588         * UIProcess/ios/WKActionSheetAssistant.mm:
589         (-[WKActionSheetAssistant showDataDetectorsSheet]):
590
591 2014-03-17  Anders Carlsson  <andersca@apple.com>
592
593         Fix 32-bit OS X build.
594
595         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h:
596         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm:
597         * WebProcess/InjectedBundle/InjectedBundle.h:
598         * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
599         (WebKit::InjectedBundle::platformInitialize):
600
601 2014-03-17  Jae Hyun Park  <jaepark@webkit.org>
602
603         [GTK][CMake] Fix WebKit2 unused parameter warnings
604         https://bugs.webkit.org/show_bug.cgi?id=130316
605
606         Reviewed by Martin Robinson.
607
608         * Platform/gtk/WorkQueueGtk.cpp: Fix unused parameter warnings.
609         * UIProcess/API/gtk/PageClientImpl.cpp: Ditto.
610         * UIProcess/API/gtk/WebKitBackForwardListItem.cpp: Ditto.
611         * UIProcess/API/gtk/WebKitContextMenuClient.cpp: Ditto.
612         * UIProcess/API/gtk/WebKitContextMenuItem.cpp: Ditto.
613         * UIProcess/API/gtk/WebKitDownloadClient.cpp: Ditto.
614         * UIProcess/API/gtk/WebKitFaviconDatabase.cpp: Ditto.
615         * UIProcess/API/gtk/WebKitFindController.cpp: Ditto.
616         * UIProcess/API/gtk/WebKitFormClient.cpp: Ditto.
617         * UIProcess/API/gtk/WebKitGeolocationProvider.cpp: Ditto.
618         * UIProcess/API/gtk/WebKitLoaderClient.cpp: Ditto.
619         * UIProcess/API/gtk/WebKitPlugin.cpp: Ditto.
620         * UIProcess/API/gtk/WebKitPolicyClient.cpp: Ditto.
621         * UIProcess/API/gtk/WebKitRequestManagerClient.cpp: Ditto.
622         * UIProcess/API/gtk/WebKitTextChecker.cpp: Ditto.
623         * UIProcess/API/gtk/WebKitUIClient.cpp: Ditto.
624         * UIProcess/API/gtk/WebKitURISchemeRequest.cpp: Ditto.
625         * UIProcess/API/gtk/WebKitWebContext.cpp: Ditto.
626         * UIProcess/API/gtk/WebKitWebInspector.cpp: Ditto.
627         * UIProcess/API/gtk/WebKitWebView.cpp: Ditto.
628         * UIProcess/API/gtk/WebKitWebViewBase.cpp: Ditto.
629         * UIProcess/API/gtk/WebKitWebViewBaseAccessible.cpp: Ditto.
630         * UIProcess/API/gtk/WebViewBaseInputMethodFilter.cpp: Ditto.
631         * UIProcess/gtk/TextCheckerGtk.cpp: Ditto.
632         * UIProcess/gtk/WebContextMenuProxyGtk.cpp: Ditto.
633         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp: Ditto.
634         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.cpp: Ditto.
635         * WebProcess/InjectedBundle/API/gtk/WebKitWebExtension.cpp: Ditto.
636         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp: Ditto.
637         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp: Ditto.
638         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp: Ditto.
639
640 2014-03-17  Alexey Proskuryakov  <ap@apple.com>
641
642         [Mac] Standardize on start/length in text input IPC methods
643         https://bugs.webkit.org/show_bug.cgi?id=130359
644
645         Reviewed by Anders Carlsson.
646
647         Some IPC methods used start/length, and others use start/end. This was confusing.
648
649         While here, changed WebPageMac.mm to not use NSMakeRange where we don't need it
650         (I want to move this code to WebPage.cpp, where it could be shared with iOS and
651         other platforms, as it doesn't depend on Foundation much).
652
653         * UIProcess/API/mac/WKView.mm:
654         (-[WKView insertText:replacementRange:]):
655         (-[WKView setMarkedText:selectedRange:replacementRange:]):
656         (-[WKView attributedSubstringForProposedRange:actualRange:]):
657         * UIProcess/WebPageProxy.cpp:
658         (WebKit::WebPageProxy::internalShowContextMenu):
659         * UIProcess/WebPageProxy.h:
660         * UIProcess/ios/WebPageProxyIOS.mm:
661         (WebKit::WebPageProxy::setComposition):
662         (WebKit::WebPageProxy::insertText):
663         * UIProcess/mac/WebPageProxyMac.mm:
664         (WebKit::WebPageProxy::setComposition):
665         (WebKit::WebPageProxy::insertText):
666         (WebKit::WebPageProxy::insertDictatedText):
667         (WebKit::WebPageProxy::getAttributedSubstringFromRange):
668         * WebProcess/WebPage/WebPage.cpp:
669         (WebKit::WebPage::setComposition):
670         * WebProcess/WebPage/WebPage.h:
671         * WebProcess/WebPage/WebPage.messages.in:
672         * WebProcess/WebPage/ios/WebPageIOS.mm:
673         (WebKit::WebPage::setComposition):
674         (WebKit::WebPage::insertText):
675         * WebProcess/WebPage/mac/WebPageMac.mm:
676         (WebKit::WebPage::setComposition):
677         (WebKit::WebPage::insertText):
678         (WebKit::WebPage::insertDictatedText):
679         (WebKit::WebPage::getAttributedSubstringFromRange):
680         (WebKit::convertToRange):
681         (WebKit::WebPage::firstRectForCharacterRange):
682
683 2014-03-17  Tim Horton  <timothy_horton@apple.com>
684
685         Rename WKThumbnailView to _WKThumbnailView
686         https://bugs.webkit.org/show_bug.cgi?id=130361
687
688         Reviewed by Anders Carlsson.
689
690         * UIProcess/API/Cocoa/_WKThumbnailView.h: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.h.
691         * UIProcess/API/Cocoa/_WKThumbnailView.mm: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.mm.
692         (-[_WKThumbnailView initWithFrame:fromWKView:]):
693         (-[_WKThumbnailView _viewWasUnparented]):
694         (-[_WKThumbnailView _viewWasParented]):
695         (-[_WKThumbnailView _requestSnapshotIfNeeded]):
696         (-[_WKThumbnailView _didTakeSnapshot:]):
697         (-[_WKThumbnailView viewDidMoveToWindow]):
698         (-[_WKThumbnailView setScale:]):
699         (-[_WKThumbnailView setUsesSnapshot:]):
700         (-[_WKThumbnailView _setThumbnailLayer:]):
701         (-[_WKThumbnailView _thumbnailLayer]):
702         * UIProcess/API/Cocoa/_WKThumbnailViewInternal.h: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailViewInternal.h.
703         * UIProcess/API/mac/WKView.mm:
704         (-[WKView _setThumbnailView:]):
705         (-[WKView _thumbnailView]):
706         (-[WKView _updateThumbnailViewLayer]):
707         * UIProcess/API/mac/WKViewInternal.h:
708         * UIProcess/mac/PageClientImpl.mm:
709         * WebKit2.xcodeproj/project.pbxproj:
710
711 2014-03-17  Anders Carlsson  <andersca@apple.com>
712
713         Add SPI for getting bundle parameters from the injected bundle
714         https://bugs.webkit.org/show_bug.cgi?id=130355
715
716         Reviewed by Dan Bernstein.
717
718         * UIProcess/mac/WebContextMac.mm:
719         (WebKit::WebContext::platformInitializeWebProcess):
720         * WebKit2.xcodeproj/project.pbxproj:
721         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.h: Copied from Source/WebKit2/WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.h.
722         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessBundleParameters.mm: Copied from Source/WebKit2/WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.h.
723         (-[WKWebProcessBundleParameters initWithDictionary:]):
724         (-[WKWebProcessBundleParameters valueForKey:]):
725         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.h:
726         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.mm:
727         (-[WKWebProcessPlugInController parameters]):
728         * WebProcess/InjectedBundle/InjectedBundle.cpp:
729         (WebKit::InjectedBundle::InjectedBundle):
730         * WebProcess/InjectedBundle/InjectedBundle.h:
731         (WebKit::InjectedBundle::create):
732         * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
733         (WebKit::InjectedBundle::bundleParameters):
734         (WebKit::InjectedBundle::platformInitialize):
735         * WebProcess/WebProcess.cpp:
736         (WebKit::WebProcess::initializeWebProcess):
737
738 2014-03-17  Brent Fulgham  <bfulgham@apple.com>
739
740         Provide preference to enable additional AVFoundation options
741         https://bugs.webkit.org/show_bug.cgi?id=130275
742
743         Reviewed by Eric Carlson.
744
745         * Shared/WebPreferencesStore.h: Added new preference.
746         * UIProcess/API/C/WKPreferences.cpp:
747         (WKPreferencesSetEnableInheritURIQueryComponent): Added.
748         (WKPreferencesGetEnableInheritURIQueryComponent): Added.
749         * UIProcess/API/C/WKPreferencesPrivate.h:
750         * WebProcess/WebPage/WebPage.cpp:
751         (WebKit::WebPage::updatePreferences): Handle new preference.
752
753 2014-03-17  Alexey Proskuryakov  <ap@apple.com>
754
755         [Mac] getAttributedSubstringFromRange arguments are incorrectly named
756         https://bugs.webkit.org/show_bug.cgi?id=130349
757
758         Reviewed by Tim Horton.
759
760         There is a mess of start/end and start/length pairs in IPC. One day we'll fix them
761         all, but now, let's at least name them correctly.
762
763         No behavior change.
764
765         * UIProcess/WebPageProxy.h:
766         * UIProcess/mac/WebPageProxyMac.mm:
767         (WebKit::WebPageProxy::getAttributedSubstringFromRange):
768         * WebProcess/WebPage/WebPage.h:
769         * WebProcess/WebPage/WebPage.messages.in:
770         * WebProcess/WebPage/mac/WebPageMac.mm:
771         (WebKit::WebPage::getAttributedSubstringFromRange):
772
773 2014-03-17  Tim Horton  <timothy_horton@apple.com>
774
775         WKThumbnailView should support snapshots
776         https://bugs.webkit.org/show_bug.cgi?id=130335
777         <rdar://problem/16255139>
778
779         Reviewed by Simon Fraser.
780
781         Add a mode where WKThumbnailView takes a software snapshot of the web content,
782         replacing the live layer tree with said snapshot once it returns from the
783         web process. This may improve animation performance in cases where the
784         layer tree would otherwise be very complex.
785
786         * UIProcess/API/Cocoa/WKThumbnailView.h:
787         Add a property, usesSnapshot, which determines whether the thumbnail view
788         should use the live layer tree or a snapshot of the content.
789
790         * UIProcess/API/Cocoa/WKThumbnailView.mm:
791         (-[WKThumbnailView initWithFrame:fromWKView:]):
792         (-[WKThumbnailView _viewWasUnparented]):
793         Clear the snapshot when unparented.
794
795         (-[WKThumbnailView _viewWasParented]):
796         Take a snapshot of the web content when parented, if needed.
797
798         (-[WKThumbnailView _requestSnapshotIfNeeded]):
799         If we're using snapshots, and haven't already dispatched an async snapshot request,
800         and don't already have a snapshot, request a snapshot from the web process.
801
802         When it returns, use it as the contents of the WKThumbnailView layer, and
803         unparent the live layer tree.
804
805         (-[WKThumbnailView setScale:]):
806         (-[WKThumbnailView setUsesSnapshot:]):
807         (-[WKThumbnailView _setThumbnailLayer:]):
808         (-[WKThumbnailView _thumbnailLayer]):
809         * UIProcess/API/Cocoa/WKThumbnailViewInternal.h:
810
811         * UIProcess/API/mac/WKView.mm:
812         (-[WKView _setAcceleratedCompositingModeRootLayer:]):
813         (-[WKView _acceleratedCompositingModeRootLayer]):
814         WKView should always keep track of the current root layer, instead of totally
815         handing control over to WKThumbnailView when it is used.
816
817         (-[WKView _setThumbnailView:]):
818         (-[WKView _updateThumbnailViewLayer]):
819         (-[WKView _reparentLayerTreeInThumbnailView]):
820         If needed (either we're not using snapshots, or still waiting for the snapshot to be painted),
821         push the WKView's live layer tree into the thumbnail view.
822
823         * UIProcess/API/mac/WKViewInternal.h:
824         * UIProcess/WebPageProxy.cpp:
825         (WebKit::WebPageProxy::internalShowContextMenu):
826         * UIProcess/WebPageProxy.h:
827         * WebProcess/WebPage/WebPage.h:
828         * WebProcess/WebPage/WebPage.messages.in:
829         * WebProcess/WebPage/WebPage.cpp:
830         (WebKit::WebPage::takeThumbnailSnapshot):
831         Add a message that asynchronously returns a snapshot that respects the
832         current thumbnail scale and position.
833
834         (WebKit::WebPage::scaledSnapshotWithOptions):
835         Use some nullptr.
836
837         * WebProcess/WebPage/DrawingArea.cpp:
838         (WebKit::DrawingArea::transform):
839         * WebProcess/WebPage/DrawingArea.h:
840         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
841         Add a getter for the DrawingArea's transform.
842         Rename it to rootLayerTransform.
843
844 2014-03-17  Zan Dobersek  <zdobersek@igalia.com>
845
846         Use RunLoop objects through references instead of pointers
847         https://bugs.webkit.org/show_bug.cgi?id=130313
848
849         Reviewed by Andreas Kling.
850
851         Adjust the code accordingly now that RunLoop::current() and RunLoop::main()
852         return RunLoop reference instead of a pointer.
853
854         * DatabaseProcess/DatabaseProcess.cpp:
855         (WebKit::DatabaseProcess::didClose):
856         (WebKit::DatabaseProcess::didReceiveInvalidMessage):
857         * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
858         (WebKit::UniqueIDBDatabase::postMainThreadTask):
859         * NetworkProcess/NetworkProcess.cpp:
860         (WebKit::NetworkProcess::didClose):
861         (WebKit::NetworkProcess::didReceiveInvalidMessage):
862         * NetworkProcess/NetworkResourceLoader.cpp:
863         (WebKit::NetworkResourceLoader::continueWillSendRequest):
864         * Platform/IPC/Connection.cpp:
865         (IPC::Connection::SyncMessageState::getOrCreate):
866         (IPC::Connection::SyncMessageState::SyncMessageState):
867         (IPC::Connection::SyncMessageState::~SyncMessageState):
868         (IPC::Connection::SyncMessageState::processIncomingMessage):
869         (IPC::Connection::SyncMessageState::dispatchMessages):
870         (IPC::Connection::createServerConnection):
871         (IPC::Connection::createClientConnection):
872         (IPC::Connection::Connection):
873         (IPC::Connection::addWorkQueueMessageReceiver):
874         (IPC::Connection::removeWorkQueueMessageReceiver):
875         (IPC::Connection::sendSyncMessage):
876         (IPC::Connection::sendSyncMessageFromSecondaryThread):
877         (IPC::Connection::waitForSyncReply):
878         (IPC::Connection::processIncomingMessage):
879         (IPC::Connection::connectionDidClose):
880         (IPC::Connection::dispatchDidReceiveInvalidMessage):
881         (IPC::Connection::enqueueIncomingMessage):
882         (IPC::Connection::wakeUpRunLoop):
883         * Platform/IPC/Connection.h:
884         * Platform/IPC/mac/ConnectionMac.cpp:
885         (IPC::Connection::receiveSourceEventHandler):
886         * Shared/ChildProcess.cpp:
887         (WebKit::ChildProcess::stopRunLoop):
888         * Shared/Plugins/NPObjectProxy.cpp:
889         (WebKit::NPObjectProxy::NP_Deallocate):
890         * UIProcess/Launcher/efl/ProcessLauncherEfl.cpp:
891         (WebKit::ProcessLauncher::launchProcess):
892         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
893         (WebKit::ProcessLauncher::launchProcess):
894         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
895         (WebKit::connectToService):
896         (WebKit::tryPreexistingProcess):
897         (WebKit::createProcess):
898         * UIProcess/Storage/StorageManager.cpp:
899         (WebKit::StorageManager::getOrigins):
900         (WebKit::StorageManager::getStorageDetailsByOrigin):
901         * UIProcess/Storage/StorageManager.h:
902         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
903         (WebKit::NetscapePlugin::pluginThreadAsyncCall):
904         * WebProcess/Plugins/PluginView.cpp:
905         (WebKit::PluginView::unprotectPluginFromDestruction):
906         * WebProcess/WebPage/EventDispatcher.cpp:
907         (WebKit::EventDispatcher::wheelEvent):
908         * WebProcess/WebPage/ViewUpdateDispatcher.cpp:
909         (WebKit::ViewUpdateDispatcher::visibleContentRectUpdate):
910         * WebProcess/WebPage/WebPage.cpp:
911         (WebKit::WebPage::close):
912
913 2014-03-17  Giovanni Campagna  <gcampagna@src.gnome.org>
914
915         [GTK] Don't busy loop when the socket is full
916         https://bugs.webkit.org/show_bug.cgi?id=129802
917
918         Reviewed by Carlos Garcia Campos.
919
920         When the socket is full and we see EAGAIN or EWOULDBLOCK
921         (because the socket is non blocking), don't busy loop by
922         tring to write again, instead poll() until the socket
923         becomes writable.
924
925         * Platform/IPC/unix/ConnectionUnix.cpp:
926         (IPC::Connection::sendOutgoingMessage):
927
928 2014-03-17  Martin Robinson  <mrobinson@igalia.com>
929
930         [GTK][CMake] Ensure that HAVE_GTK_UNIX_PRINTING is defined when appropriate
931         https://bugs.webkit.org/show_bug.cgi?id=130155
932
933         Reviewed by Philippe Normand.
934
935         * PlatformGTK.cmake: Add GTK_UNIX_PRINT flags to the build.
936
937 2014-03-17  Ryuan Choi  <ryuan.choi@samsung.com>
938
939         [EFL][WK2] Restore cursor when moving mouse into webview
940         https://bugs.webkit.org/show_bug.cgi?id=130182
941
942         Reviewed by Gyuyoung Kim.
943
944         We changed mouse cursor when the type of cursor is changed.
945         But once mouse is moved out of webview, ewebkit will not know whether cursor
946         is changed or not.
947
948         So, this patch added a logic to restore the last applied type of cursor when
949         mouse is moved into webview again.
950
951         * UIProcess/API/efl/EwkView.cpp:
952         (EwkViewEventHandler<EVAS_CALLBACK_MOUSE_IN>::handleEvent):
953         Call updateCursor to restore the last applied type of cursor.
954         (EwkView::EwkView):
955         (EwkView::updateCursor): Extracted from setCursor.
956         (EwkView::setCursor):
957         (EwkView::handleEvasObjectAdd):
958         * UIProcess/API/efl/EwkView.h:
959
960 2014-03-16  Ryuan Choi  <ryuan.choi@samsung.com>
961
962         [EFL][WK2] Add ewk_application_cache_manager APIs
963         https://bugs.webkit.org/show_bug.cgi?id=102853
964
965         Reviewed by Gyuyoung Kim.
966
967         Implemented application cache manager to get list of origins which stores
968         application cache and remove specified origin or all.
969
970         * PlatformEfl.cmake: Added newly added files.
971         * UIProcess/API/efl/ewk_application_cache_manager.cpp: Added.
972         (EwkApplicationCacheManager::EwkApplicationCacheManager):
973         (EwkApplicationCacheManager::~EwkApplicationCacheManager):
974         (Get_Origins_Data::Get_Origins_Data):
975         (getApplicationCacheOriginsCallback):
976         (ewk_application_cache_manager_origins_get):
977         (ewk_application_cache_origins_free):
978         (ewk_application_cache_manager_delete_all):
979         (ewk_application_cache_manager_delete):
980         * UIProcess/API/efl/ewk_application_cache_manager.h: Added.
981         * UIProcess/API/efl/ewk_application_cache_manager_private.h: Added.
982         (EwkApplicationCacheManager::impl):
983         * UIProcess/API/efl/ewk_context.cpp:
984         (EwkContext::applicationCacheManager):
985         (ewk_context_application_cache_manager_get):
986         * UIProcess/API/efl/ewk_context.h:
987         * UIProcess/API/efl/ewk_context_private.h:
988         * UIProcess/API/efl/ewk_security_origin_private.h:
989         (EwkSecurityOrigin::wkSecurityOrigin):
990         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestServer.cpp:
991         (EWK2UnitTestServer::port):
992         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestServer.h:
993         * UIProcess/API/efl/tests/test_ewk2_application_cache_manager.cpp:
994         Added to test application_cache_manager.
995         (serverCallback):
996         (getOriginsCallback):
997         (timerCallback):
998         (TEST_F):
999         * UIProcess/API/efl/tests/test_ewk2_context.cpp:
1000         Added test case to test getter of application_cache_manager.
1001         (TEST_F):
1002
1003 2014-03-16  Zan Dobersek  <zdobersek@igalia.com>
1004
1005         Move GTK WebKit2 code to std::unique_ptr
1006         https://bugs.webkit.org/show_bug.cgi?id=129672
1007
1008         Reviewed by Anders Carlsson.
1009
1010         Repace uses of OwnPtr and PassOwnPtr in GTK-specific WebKit2 code with std::unique_ptr.
1011
1012         * Shared/Downloads/Download.h:
1013         * Shared/Downloads/soup/DownloadSoup.cpp:
1014         (WebKit::Download::start):
1015         (WebKit::Download::startWithHandle):
1016         (WebKit::Download::platformInvalidate):
1017         * UIProcess/API/gtk/PageClientImpl.cpp:
1018         * UIProcess/API/gtk/PageClientImpl.h:
1019         * UIProcess/API/gtk/WebKitContextMenuItem.cpp:
1020         (webkitContextMenuItemCreate):
1021         (webkitContextMenuItemCreateForGtkItem):
1022         (webkit_context_menu_item_new):
1023         (webkit_context_menu_item_new_from_stock_action):
1024         (webkit_context_menu_item_new_from_stock_action_with_label):
1025         (webkit_context_menu_item_new_with_submenu):
1026         (webkit_context_menu_item_new_separator):
1027         * UIProcess/API/gtk/WebKitTextChecker.h:
1028         * UIProcess/API/gtk/WebKitWebContext.cpp:
1029         (createDefaultWebContext):
1030         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1031         (webkitWebViewBaseConstructed):
1032         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp:
1033         (WebKit::WebPrintOperationGtk::print):
1034         * WebProcess/gtk/WebGtkExtensionManager.cpp:
1035         (WebKit::WebGtkExtensionManager::initialize):
1036         * WebProcess/soup/WebKitSoupRequestInputStream.cpp:
1037         (webkitSoupRequestInputStreamPendingReadAsyncComplete):
1038         (webkitSoupRequestInputStreamReadAsync):
1039         * WebProcess/soup/WebSoupRequestManager.cpp:
1040         (WebKit::WebSoupRequestManager::send):
1041         * WebProcess/soup/WebSoupRequestManager.h:
1042
1043 2014-03-16  Brian Burg  <bburg@apple.com>
1044
1045         Web Inspector: vended backend commands file should be generated as part of the build
1046         https://bugs.webkit.org/show_bug.cgi?id=130110
1047
1048         Reviewed by Timothy Hatcher.
1049
1050         * PlatformGTK.cmake: Copy over generated inspector backend commands files.
1051
1052 2014-03-16  Darin Adler  <darin@apple.com>
1053
1054         Try to fix 32-bit Mac build.
1055
1056         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm: Add missing include.
1057
1058 2014-03-16  Philippe Normand  <pnormand@igalia.com>
1059
1060         Unreviewed, GTK build fix after r165692.
1061
1062         * UIProcess/gtk/TextCheckerGtk.cpp:
1063         (WebKit::TextChecker::checkSpellingOfString):
1064         (WebKit::TextChecker::checkGrammarOfString):
1065
1066 2014-03-15  Darin Adler  <darin@apple.com>
1067
1068         Remove all uses of deprecatedCharacters from WebKit2
1069         https://bugs.webkit.org/show_bug.cgi?id=130197
1070
1071         Reviewed by Andreas Kling.
1072
1073         * Shared/APIString.h: Rewrote getCharacters to use StringView,
1074         substring, and getCharactersWithUpconvert. Added an 8-bit case
1075         to getUTF8CString.
1076
1077         * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
1078         (WebKit::writeByte): Added.
1079         (WebKit::writeCharacter): Added.
1080         (WebKit::writeLine): Added. Uses operator[] instead of characters16 to get
1081         the UTF-16 characters out of the string.
1082         (WebKit::NetscapePluginModule::scanPlugin): Replaced code that writes out
1083         text to stdout with much simpler version using the functions above.
1084
1085         * UIProcess/TextChecker.h: Changed text arguments to use StringView instead
1086         of UChar/int pairs.
1087
1088         * UIProcess/WebPageProxy.cpp:
1089         (WebKit::WebPageProxy::internalShowContextMenu): Updated to pass StringView.
1090
1091         * UIProcess/efl/TextCheckerEfl.cpp:
1092         (WebKit::nextWordOffset): Changed function to use StringView and unsigned.
1093         (WebKit::TextChecker::checkTextOfParagraph): Changed to use StringView and
1094         substring.
1095         (WebKit::TextChecker::checkSpellingOfString): Ditto.
1096         (WebKit::TextChecker::checkGrammarOfString): Ditto.
1097         (WebKit::TextChecker::requestCheckingOfString): Pass in a StringView, so no
1098         need to call deprecatedCharacters.
1099
1100         * UIProcess/ios/TextCheckerIOS.mm:
1101         (WebKit::TextChecker::checkTextOfParagraph): Changed to take StringView.
1102         (WebKit::TextChecker::checkSpellingOfString): Ditto.
1103         (WebKit::TextChecker::checkGrammarOfString): Ditto.
1104
1105         * UIProcess/mac/TextCheckerMac.mm:
1106         (WebKit::TextChecker::checkTextOfParagraph): Changed to take StringView and
1107         use StringView::createNSStringWithoutCopying.
1108         (WebKit::TextChecker::checkSpellingOfString): CHanged to take StringView.
1109         (WebKit::TextChecker::checkGrammarOfString): Ditto.
1110
1111         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1112         (WebKit::convertStringToKeyCodes): Changed to take StringView and use
1113         upconvertedCharacters instead of deprecatedCharacters. Also use move instead
1114         of swap.
1115         (WebKit::NetscapePlugin::sendComplexTextInput): Updated to new style for loop.
1116
1117         * WebProcess/WebPage/EncoderAdapter.cpp:
1118         (WebKit::EncoderAdapter::encodeString): Use StringView::upconvertedCharacters
1119         instead of String::deprecatedCharacters.
1120
1121 2014-03-15  David Kilzer  <ddkilzer@apple.com>
1122
1123         [iOS] Define SYSTEM_VERSION_PREFIX consistently
1124         <http://webkit.org/b/130293>
1125         <rdar://problem/15926359>
1126
1127         Reviewed by Dan Bernstein.
1128
1129         * Configurations/Version.xcconfig:
1130         (SYSTEM_VERSION_PREFIX): Sync with
1131         Source/WebKit/mac/Version.xcconfig.
1132
1133 2014-03-14  Alexey Proskuryakov  <ap@apple.com>
1134
1135         [Mac] Sync extended attribute related rules with AppSandbox profile
1136         https://bugs.webkit.org/show_bug.cgi?id=130263
1137         <rdar://problem/16318965>
1138
1139         Reviewed by Sam Weinig.
1140
1141         Update the fix to use a different syntax in some OS versions.
1142
1143         * NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in:
1144         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
1145         * WebProcess/com.apple.WebProcess.sb.in:
1146
1147 2014-03-14  Ryosuke Niwa  <rniwa@webkit.org>
1148
1149         Revert erroneous changes made to UIProcess/API/Cocoa in r165676.
1150
1151         * UIProcess/API/Cocoa/WKBackForwardList.h:
1152         * UIProcess/API/Cocoa/WKBackForwardListItem.h: Copied from Source/WebKit2/UIProcess/API/Cocoa/WKBackForwardListItem.h.
1153         * UIProcess/API/Cocoa/WKNavigation.h:
1154         * UIProcess/API/Cocoa/WKNavigationAction.h: Copied from Source/WebKit2/UIProcess/API/Cocoa/WKNavigationAction.h.
1155         * UIProcess/API/Cocoa/WKNavigationDelegate.h:
1156         (NS_ENUM):
1157         * UIProcess/API/Cocoa/WKNavigationResponse.h: Copied from Source/WebKit2/UIProcess/API/Cocoa/WKNavigationResponse.h.
1158         * UIProcess/API/Cocoa/WKNavigationTrigger.h: Removed.
1159         * UIProcess/API/Cocoa/WKWebView.h:
1160
1161 2014-03-14  Mark Rowe  <mrowe@apple.com>
1162
1163         Fix the production build.
1164
1165         Don't rely on USE_INTERNAL_SDK being set for the Production configuration since UseInternalSDK.xcconfig won't
1166         be at the expected relative path when working from installed source.
1167
1168         * Configurations/Base.xcconfig:
1169
1170 2014-03-14  Maciej Stachowiak  <mjs@apple.com>
1171
1172         Replace "Apple Computer, Inc." with "Apple Inc." in copyright headers
1173         https://bugs.webkit.org/show_bug.cgi?id=130276
1174         <rdar://problem/16266927>
1175         
1176         Reviewed by Simon Fraser.
1177
1178         * Shared/AsyncRequest.cpp:
1179         * Shared/AsyncRequest.h:
1180         * Shared/ContextMenuContextData.cpp:
1181         * Shared/ContextMenuContextData.h:
1182         * Shared/Databases/DatabaseProcessCreationParameters.h:
1183         * Shared/Databases/IndexedDB/IDBUtilities.cpp:
1184         * Shared/Databases/IndexedDB/IDBUtilities.h:
1185         * Shared/mac/RemoteLayerBackingStore.h:
1186         * Shared/mac/RemoteLayerBackingStore.mm:
1187         * UIProcess/API/Cocoa/WKBackForwardList.h:
1188         * UIProcess/API/Cocoa/WKBackForwardListItem.h: Removed.
1189         * UIProcess/API/Cocoa/WKNavigation.h:
1190         * UIProcess/API/Cocoa/WKNavigationAction.h: Removed.
1191         * UIProcess/API/Cocoa/WKNavigationDelegate.h:
1192         * UIProcess/API/Cocoa/WKNavigationResponse.h: Removed.
1193         * UIProcess/API/Cocoa/WKNavigationTrigger.h: Added.
1194         (NS_ENUM):
1195         * UIProcess/API/Cocoa/WKWebView.h:
1196         * UIProcess/API/CoordinatedGraphics/WKCoordinatedScene.cpp:
1197         * UIProcess/API/CoordinatedGraphics/WKCoordinatedScene.h:
1198         * UIProcess/CoordinatedGraphics/WKCoordinatedSceneAPICast.h:
1199         * WebProcess/Databases/IndexedDB/WebIDBFactoryBackend.cpp:
1200         * WebProcess/Databases/IndexedDB/WebIDBFactoryBackend.h:
1201         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
1202         * WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
1203         * WebProcess/Databases/WebToDatabaseProcessConnection.cpp:
1204         * WebProcess/Databases/WebToDatabaseProcessConnection.h:
1205         * WebProcess/WebCoreSupport/WebAlternativeTextClient.h:
1206         * WebProcess/WebCoreSupport/mac/WebAlternativeTextClient.cpp:
1207         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
1208         * WebProcess/WebPage/mac/GraphicsLayerCARemote.cpp:
1209         * WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
1210         * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
1211         * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
1212         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.h:
1213         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm:
1214         * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.cpp:
1215         * WebProcess/WebPage/mac/PlatformCALayerRemoteTiledBacking.h:
1216
1217 2014-03-14  Simon Fraser  <simon.fraser@apple.com>
1218
1219         [iOS WK2] background-attachment: fixed renders oddly, moves around
1220         https://bugs.webkit.org/show_bug.cgi?id=130277
1221         <rdar://problem/16332883>
1222
1223         Reviewed by Tim Horton.
1224         
1225         Actually send scrolling and counter-scrolling layers to the UI process!
1226
1227         * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
1228         (ArgumentCoder<ScrollingStateScrollingNode>::encode):
1229         (ArgumentCoder<ScrollingStateScrollingNode>::decode):
1230
1231 2014-03-14  Anders Carlsson  <andersca@apple.com>
1232
1233         Try to fix the iOS build.
1234
1235         * UIProcess/mac/WebContextMac.mm:
1236
1237 2014-03-14  Anders Carlsson  <andersca@apple.com>
1238
1239         Begin work on the bundle parameter API
1240         https://bugs.webkit.org/show_bug.cgi?id=130267
1241
1242         Reviewed by Dan Bernstein.
1243
1244         * Shared/WebProcessCreationParameters.cpp:
1245         (WebKit::WebProcessCreationParameters::encode):
1246         (WebKit::WebProcessCreationParameters::decode):
1247         * Shared/WebProcessCreationParameters.h:
1248         * UIProcess/API/Cocoa/WKProcessPool.mm:
1249         (-[WKProcessPool _objectForBundleParameter:]):
1250         (-[WKProcessPool _setObject:forBundleParameter:]):
1251         * UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
1252         * UIProcess/WebContext.h:
1253         (WebKit::WebContext::bundleParameters):
1254         * UIProcess/mac/WebContextMac.mm:
1255         (WebKit::WebContext::ensureBundleParameters):
1256         (WebKit::WebContext::platformInitializeWebProcess):
1257
1258 2014-03-14  Alexey Proskuryakov  <ap@apple.com>
1259
1260         [Mac] Sync extended attribute related rules with AppSandbox profile
1261         https://bugs.webkit.org/show_bug.cgi?id=130263
1262         <rdar://problem/16318965>
1263
1264         Reviewed by Sam Weinig.
1265
1266         * NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in:
1267         * Resources/PlugInSandboxProfiles/com.apple.QuickTime Plugin.plugin.sb:
1268         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
1269         * Resources/PlugInSandboxProfiles/com.apple.ist.ds.appleconnect.webplugin.sb:
1270         * Resources/PlugInSandboxProfiles/com.macromedia.Flash Player.plugin.sb:
1271         * Resources/PlugInSandboxProfiles/com.microsoft.SilverlightPlugin.sb:
1272         * Resources/PlugInSandboxProfiles/com.oracle.java.JavaAppletPlugin.sb:
1273         * WebProcess/com.apple.WebProcess.sb.in:
1274
1275 2014-03-14  Simon Fraser  <simon.fraser@apple.com>
1276
1277         [iOS WK2] Improve behavior of fixed elments on zooming
1278         https://bugs.webkit.org/show_bug.cgi?id=130253
1279
1280         Reviewed by Beth Dakin.
1281
1282         Correctly reposition right- and bottom-relative position:fixed
1283         elements on zooming in WK2 iOS by telling the scrolling tree
1284         about zoom-related viewport changes.
1285
1286         * Shared/mac/RemoteLayerTreeTransaction.h:
1287         (WebKit::RemoteLayerTreeTransaction::LayerProperties::notePropertiesChanged):
1288         Drive-by cleanup; typedef the flags field to an unsigned, to avoid ugly casting.
1289         * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp:
1290         (WebKit::RemoteScrollingCoordinatorProxy::updateScrollingTree): Pass out a flag to say
1291         if the update contained a new fixed or sticky layer.
1292         (WebKit::RemoteScrollingCoordinatorProxy::connectStateNodeLayers):
1293         (WebKit::RemoteScrollingCoordinatorProxy::viewportChangedViaDelegatedScrolling):
1294         Call into the new ScrolingTree::viewportChangedViaDelegatedScrolling().
1295         * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.h:
1296         * UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm: If we got a new fixed
1297         or sticky layer, set fixedOrStickyLayerChanged to true.
1298         (WebKit::RemoteScrollingCoordinatorProxy::connectStateNodeLayers): Ditto.
1299         * UIProcess/ios/WKContentView.mm:
1300         (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
1301         Remember both the old zoomScale and the filteredScale, since the fixed position rect
1302         should be computed using the unfiltered scale.
1303         Some FloatRect -> CGRect changes.
1304         Now call viewportChangedViaDelegatedScrolling() on the scrolling coordinator.
1305         (-[WKContentView fixedPositionRectFromExposedRect:scale:]): Call the
1306         FrameView function to compute the iOS fixed position rect.
1307         * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
1308         (WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree): If the update
1309         got a new fixed or sticky layer, run the scrolling tree logic to make sure
1310         it gets into the right place.
1311         * UIProcess/mac/RemoteLayerTreeHost.mm:
1312         (WebKit::RemoteLayerTreeHost::updateLayerTree): If we logged here,
1313         we'd log twice if the tiled scrolling indicator was enabled, so 
1314         hoisted the logging out into the caller.
1315
1316 2014-03-14  Landry Breuil  <landry@openbsd.org>
1317
1318         Use the correct type in webkitSoupRequestInputStreamNew()'s declaration.
1319         Nhttps://bugs.webkit.org/show_bug.cgi?id=129974
1320
1321         Reviewed by Andreas Kling.
1322
1323         * WebProcess/soup/WebKitSoupRequestInputStream.h:
1324
1325 2014-03-14  Anders Carlsson  <andersca@apple.com>
1326
1327         Fix crash when resizing the visited link table
1328         https://bugs.webkit.org/show_bug.cgi?id=130257
1329         <rdar://problem/16328177>
1330
1331         Reviewed by Dan Bernstein.
1332
1333         We're iterating over the old table, so use currentTableSize in the loop termination condition.
1334
1335         * UIProcess/VisitedLinkProvider.cpp:
1336         (WebKit::VisitedLinkProvider::resizeTable):
1337
1338 2014-03-14  Dan Bernstein  <mitz@apple.com>
1339
1340         [Cocoa] Expose a way to set the cookie accept policy
1341         https://bugs.webkit.org/show_bug.cgi?id=130251
1342
1343         Reviewed by Anders Carlsson.
1344
1345         * UIProcess/API/Cocoa/WKProcessPool.mm:
1346         (toHTTPCookieAcceptPolicy): Added a helper function that maps from NSHTTPCookieAcceptPolicy
1347         values to WebKit::HTTPCookieAcceptPolicy values.
1348         (-[WKProcessPool _setCookieAcceptPolicy:]): Added. Calls
1349         WebCookieManagerProxy::setHTTPCookieAcceptPolicy. 
1350         * UIProcess/API/Cocoa/WKProcessPoolPrivate.h: Declared new method.
1351
1352 2014-03-14  Carlos Garcia Campos  <cgarcia@igalia.com>
1353
1354         [GTK] WebKit2WebExtension GIR can't be used in vala
1355         https://bugs.webkit.org/show_bug.cgi?id=127179
1356
1357         Reviewed by Martin Robinson.
1358
1359         Do not include all WebKit2 gir symbols from WebKit2WebExtension gir
1360         file.
1361
1362         * GNUmakefile.am:
1363         * PlatformGTK.cmake:
1364
1365 2014-03-14  Csaba Osztrogonác  <ossy@webkit.org>
1366
1367         [CMake] URTBF after r165619.
1368
1369         * CMakeLists.txt: Add new files.
1370
1371 2014-03-14  Anders Carlsson  <andersca@apple.com>
1372
1373         Remove WebContext::addVisitedLink
1374         https://bugs.webkit.org/show_bug.cgi?id=130242
1375
1376         Reviewed by Dan Bernstein.
1377
1378         Fold the function into WKContextAddVisitedLink instead.
1379
1380         * UIProcess/API/C/WKContext.cpp:
1381         (WKContextAddVisitedLink):
1382         * UIProcess/WebContext.cpp:
1383         * UIProcess/WebContext.h:
1384         (WebKit::WebContext::visitedLinkProvider):
1385
1386 2014-03-13  Anders Carlsson  <andersca@apple.com>
1387
1388         Move visited link handling to VisitedLinkTableController and VisitedLinkProvider
1389         https://bugs.webkit.org/show_bug.cgi?id=130223
1390         <rdar://problem/16315792>
1391
1392         Reviewed by Dan Bernstein.
1393
1394         * DerivedSources.make:
1395         Generate messages for VisitedLinkProvider and VisitedLinkTableController.
1396         
1397         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
1398         (-[WKWebViewConfiguration copyWithZone:]):
1399         Set the visited link provider.
1400
1401         * UIProcess/API/Cocoa/_WKVisitedLinkProvider.h:
1402         Add addVisitedLinkWithURL: method.
1403
1404         * UIProcess/API/Cocoa/_WKVisitedLinkProvider.mm:
1405         (-[_WKVisitedLinkProvider addVisitedLinkWithURL:]):
1406         Compute a link hash from the absolute URL string and pass it to the underlying VisitedLinkProvider object.
1407
1408         * UIProcess/VisitedLinkProvider.cpp:
1409         (WebKit::VisitedLinkProvider::addProcess):
1410         Add the process to the m_processes HashCountedSet. If it's the first time we're adding the process, 
1411         add the VisitedLinkProvider object as a message receiver and send the visited link table to the process.
1412
1413         (WebKit::VisitedLinkProvider::removeProcess):
1414         Remove the process from the m_processes HashCountedSet. If we're removing the last reference to the process,
1415         remove ourselves as a  message receiver.
1416
1417         (WebKit::VisitedLinkProvider::addVisitedLinkHash):
1418         Rename this from addVisitedLink to better indicate what it's doing.
1419
1420         (WebKit::tableSizeForKeyCount):
1421         Update for constant rename.
1422
1423         (WebKit::VisitedLinkProvider::pendingVisitedLinksTimerFired):
1424         Compute the new pending visited links table size. If it's bigger than our current table, resize the table
1425         by calling resizeTable. Otherwise, simply try to add the pending hashes to our shared hash table. If successful,
1426         add the link hash to the addedVisitedLinks table and eventually send it to all processes associated with the visited link provider.
1427
1428         (WebKit::VisitedLinkProvider::resizeTable):
1429         Create a new shared memory segment, Set it as the table backing store and add all visited links from the old table. Finally,
1430         add our pending visited link hashes and send the new table memory to all processes associated with the visited link provider.
1431
1432         (WebKit::VisitedLinkProvider::sendTable):
1433         Helper function that creates a shared memory handle and sends it to a given web process.
1434
1435         * UIProcess/VisitedLinkProvider.h:
1436         Add new members.
1437
1438         * UIProcess/VisitedLinkProvider.messages.in:
1439         Add messages.
1440
1441         * UIProcess/WebContext.cpp:
1442         (WebKit::WebContext::processDidFinishLaunching):
1443         (WebKit::WebContext::disconnectProcess):
1444         The WebContext no longer needs to inform the visited link provider about the processes coming and going, that's already handled
1445         by the WebPageProxy objects.
1446
1447         (WebKit::WebContext::addVisitedLink):
1448         Call addVisitedLinkHash on the visited link provider.
1449
1450         * UIProcess/WebContext.h:
1451         * UIProcess/WebContext.messages.in:
1452         Remove a message that is now implemented by the visited link provider.
1453
1454         * WebKit2.xcodeproj/project.pbxproj:
1455         Add new files.
1456
1457         * WebProcess/WebPage/VisitedLinkTableController.cpp:
1458         (WebKit::VisitedLinkTableController::VisitedLinkTableController):
1459         Add the table controller as a message receiver.
1460
1461         (WebKit::VisitedLinkTableController::~VisitedLinkTableController):
1462         Remove the table controller as a message receiver.
1463
1464         (WebKit::VisitedLinkTableController::isLinkVisited):
1465         Check if the link is visited according to the visited link table.
1466
1467         (WebKit::VisitedLinkTableController::addVisitedLink):
1468         Send the link hash to the UI process if it's not already visited.
1469
1470         (WebKit::VisitedLinkTableController::setVisitedLinkTable):
1471         Set the backing store memory and invalidate all styles.
1472
1473         (WebKit::VisitedLinkTableController::visitedLinkStateChanged):
1474         Invalidate the styles for the given links.
1475
1476         (WebKit::VisitedLinkTableController::allVisitedLinkStateChanged):
1477         Invalidate the styles for all links.
1478
1479         * WebProcess/WebPage/VisitedLinkTableController.h:
1480         Add new members.
1481
1482         * WebProcess/WebPage/VisitedLinkTableController.messages.in:
1483         Add new messages.
1484
1485         * WebProcess/WebProcess.cpp:
1486         Remove unused functions; these are handled by VisitedLinkTableController now.
1487
1488         * WebProcess/WebProcess.h:
1489         (WebKit::WebProcess::shouldTrackVisitedLinks):
1490         Add getter.
1491
1492         * WebProcess/WebProcess.messages.in:
1493         Remove messages.
1494
1495 2014-03-12  Sergio Villar Senin  <svillar@igalia.com>
1496
1497         Rename DEFINE_STATIC_LOCAL to DEPRECATED_DEFINE_STATIC_LOCAL
1498         https://bugs.webkit.org/show_bug.cgi?id=129612
1499
1500         Reviewed by Darin Adler.
1501
1502         For new code use static NeverDestroyed<T> instead.
1503
1504         * DatabaseProcess/IndexedDB/sqlite/SQLiteIDBCursor.cpp:
1505         (WebKit::getIndexStatement):
1506         (WebKit::getObjectStoreStatement):
1507         * Shared/linux/SeccompFilters/SeccompBroker.cpp:
1508         (WebKit::SeccompBrokerClient::shared):
1509         * UIProcess/InspectorServer/WebInspectorServer.cpp:
1510         (WebKit::WebInspectorServer::didReceiveWebSocketUpgradeHTTPRequest):
1511
1512 2014-03-14  Dan Bernstein  <mitz@apple.com>
1513
1514         <rdar://problem/16319722> [Cocoa] WKHistoryDelegate is being called for subframes
1515         https://bugs.webkit.org/show_bug.cgi?id=130228
1516
1517         Reviewed by Mark Rowe.
1518
1519         * UIProcess/Cocoa/HistoryClient.mm:
1520         (WebKit::HistoryClient::didNavigateWithNavigationData): Bail out if the frame is not the
1521         main frame.
1522         (WebKit::HistoryClient::didPerformClientRedirect): Ditto.
1523         (WebKit::HistoryClient::didPerformServerRedirect): Ditto.
1524         (WebKit::HistoryClient::didUpdateHistoryTitle): Ditto.
1525
1526 2014-03-13  Jinwoo Jeong  <jw00.jeong@samsung.com>
1527
1528         Refactor Vibration algorithm to use only one timer.
1529         https://bugs.webkit.org/show_bug.cgi?id=130059
1530
1531         Reviewed by Darin Adler.
1532
1533         This patch adds a vibration unit test regression after r161257.
1534         It consists of two short term requests to check
1535         that Vibration could work properly by sequential requests.
1536
1537         Indeed this patch tightens condition of existing tests.
1538
1539         * UIProcess/API/efl/tests/test_ewk2_view.cpp:
1540         (TEST_F):
1541
1542 2014-03-13  Paul Hankes Drielsma  <phd@apple.com>
1543
1544         Add SPI to set a custom user agent on WKWebView
1545         https://bugs.webkit.org/show_bug.cgi?id=130164
1546
1547         Reviewed by Dan Bernstein.
1548
1549         * UIProcess/API/Cocoa/WKWebView.mm:
1550         (-[WKWebView _customUserAgent]):
1551         (-[WKWebView _setCustomUserAgent:]):
1552         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1553
1554 2014-03-13  Paul Hankes Drielsma  <phd@apple.com>
1555
1556         Add SPI to run javascript in main frame on WKWebView
1557         https://bugs.webkit.org/show_bug.cgi?id=130047
1558
1559         Reviewed by Anders Carlsson.
1560
1561         * UIProcess/API/Cocoa/WKWebView.mm:
1562         (-[WKWebView _runJavaScriptInMainFrame:]):
1563
1564 2014-03-13  Benjamin Poulain  <bpoulain@apple.com>
1565
1566         The viewport code should not depend on WebKitSystemInterface
1567         https://bugs.webkit.org/show_bug.cgi?id=130218
1568
1569         Reviewed by Tim Horton.
1570
1571         Get the viewport size from the UIProcess when creating a new WebProcess.
1572         From there, the value is stored in WebPage and used whenever we need to update
1573         the viewport parameters.
1574
1575         * Shared/WebPageCreationParameters.cpp:
1576         (WebKit::WebPageCreationParameters::encode):
1577         (WebKit::WebPageCreationParameters::decode):
1578         * Shared/WebPageCreationParameters.h:
1579         * UIProcess/WebPageProxy.cpp:
1580         (WebKit::WebPageProxy::internalShowContextMenu):
1581         * UIProcess/WebPageProxy.h:
1582         * UIProcess/ios/WebPageProxyIOS.mm:
1583         (WebKit::WebPageProxy::viewportScreenSize):
1584         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1585         (WebKit::WebChromeClient::viewportScreenSize):
1586         * WebProcess/WebCoreSupport/WebChromeClient.h:
1587         * WebProcess/WebPage/WebPage.cpp:
1588         (WebKit::WebPage::WebPage):
1589         * WebProcess/WebPage/WebPage.h:
1590         * WebProcess/WebPage/ios/WebPageIOS.mm:
1591         (WebKit::WebPage::viewportScreenSize):
1592
1593 2014-03-13  Beth Dakin  <bdakin@apple.com>
1594
1595         Do not show extended background during a pinch gesture on iOS
1596         https://bugs.webkit.org/show_bug.cgi?id=130152
1597         -and corresponding-
1598         <rdar://problem/16303819>
1599
1600         Reviewed by Simon Fraser.
1601
1602         This patch refactors the backgroundColor-setting logic into its own method so that 
1603         it can be called from both _didCommitLayerTree and scrollViewDidZoom.
1604
1605         Only set the UIScrollView’s background color when the zoomScale is greater than or 
1606         equal to the minimumZoomScale. Also do not set it during the zoom bounce 
1607         animation. Otherwise, clear the background color by setting it to nil.
1608         * UIProcess/API/Cocoa/WKWebView.mm:
1609         (-[WKWebView updateScrollViewBackground]):
1610         (-[WKWebView _didCommitLayerTree:WebKit::]):
1611         (-[WKWebView scrollViewDidZoom:]):
1612
1613 2014-03-13  Enrica Casucci  <enrica@apple.com>
1614
1615         [iOS WebKit2] block selection should avoid large blocks.
1616         https://bugs.webkit.org/show_bug.cgi?id=130208
1617         <rdar://problem/16251785>
1618
1619         Reviewed by Benjamin Poulain.
1620
1621         When creating a block selection, we should discard blocks that
1622         are larger than most of the visible portion of the document.
1623         This prevents the accidental selection the entire document, which
1624         is fairly common when tapping over empty areas.
1625
1626         * Shared/InteractionInformationAtPosition.cpp:
1627         (WebKit::InteractionInformationAtPosition::encode):
1628         (WebKit::InteractionInformationAtPosition::decode):
1629         * Shared/InteractionInformationAtPosition.h: Removed selectionRects that was not really needed and
1630         added isSelectable to indicate whether the selection can start.
1631         (WebKit::InteractionInformationAtPosition::InteractionInformationAtPosition):
1632         * UIProcess/ios/WKContentViewInteraction.mm:
1633         (-[WKContentView hasSelectablePositionAtPoint:]): Now uses isSelectable.
1634         * WebProcess/WebPage/ios/WebPageIOS.mm:
1635         (WebKit::WebPage::getPositionInformation): Takes into account the userSelect property
1636         to figure out if the element can be selected and discards blocks that are
1637         larger than 97% of the visible area of the document.
1638
1639 2014-03-13  Anders Carlsson  <andersca@apple.com>
1640
1641         Rename WKVisitedLinkProvider to _WKVisitedLinkProvider and make it private
1642         https://bugs.webkit.org/show_bug.cgi?id=130207
1643
1644         Reviewed by Dan Bernstein.
1645
1646         * UIProcess/API/Cocoa/WKVisitedLinkProviderPrivate.h: Removed.
1647         * UIProcess/API/Cocoa/WKWebView.mm:
1648         (-[WKWebView initWithFrame:configuration:]):
1649         * UIProcess/API/Cocoa/WKWebViewConfiguration.h:
1650         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
1651         (-[WKWebViewConfiguration _visitedLinkProvider]):
1652         (-[WKWebViewConfiguration _setVisitedLinkProvider:]):
1653         * UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:
1654         * UIProcess/API/Cocoa/_WKVisitedLinkProvider.h: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKVisitedLinkProvider.h.
1655         * UIProcess/API/Cocoa/_WKVisitedLinkProvider.mm: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKVisitedLinkProvider.mm.
1656         (-[_WKVisitedLinkProvider init]):
1657         * UIProcess/API/Cocoa/_WKVisitedLinkProviderInternal.h: Renamed from Source/WebKit2/UIProcess/API/Cocoa/WKVisitedLinkProviderInternal.h.
1658         * WebKit2.xcodeproj/project.pbxproj:
1659
1660 2014-03-13  Anders Carlsson  <andersca@apple.com>
1661
1662         Remove a commented out member function
1663         https://bugs.webkit.org/show_bug.cgi?id=130204
1664
1665         Reviewed by Tim Horton.
1666
1667         * Shared/ChildProcessProxy.h:
1668         (WebKit::ChildProcessProxy::canSendMessage):
1669
1670 2014-03-13  Enrica Casucci  <enrica@apple.com>
1671
1672         [iOS WebKit2] Crash on iPad when displaying a select element with options.
1673         https://bugs.webkit.org/show_bug.cgi?id=130200
1674         <rdar://problem/16316187>
1675
1676         Reviewed by Simon Fraser.
1677
1678         _singleSelectionIndex should be initialized to NSNotFound for multiSelect elements.
1679
1680         * UIProcess/ios/forms/WKFormSelectPopover.mm:
1681         (-[WKSelectTableViewController initWithView:hasGroups:]):
1682
1683 2014-03-13  Carlos Garcia Campos  <cgarcia@igalia.com>
1684
1685         [GTK] Close the connection when we fail to read from the socket for any unhandled error
1686         https://bugs.webkit.org/show_bug.cgi?id=130191
1687
1688         Reviewed by Martin Robinson.
1689
1690         We currently show an error message, but we should close the
1691         connection avoid entering an infinite loop. Also provide more
1692         information in the error message to help when debugging the issue.
1693
1694         * Platform/IPC/unix/ConnectionUnix.cpp:
1695         (IPC::Connection::readyReadHandler):
1696
1697 2014-03-13  Radu Stavila  <stavila@adobe.com>
1698
1699         Webkit not building on XCode 5.1 due to garbage collection no longer being supported
1700         https://bugs.webkit.org/show_bug.cgi?id=130087
1701
1702         Reviewed by Mark Rowe.
1703
1704         Disable garbage collection on macosx when not using internal SDK.
1705
1706         * Configurations/Base.xcconfig:
1707
1708 2014-03-10  Darin Adler  <darin@apple.com>
1709
1710         Avoid copy-prone idiom "for (auto item : collection)"
1711         https://bugs.webkit.org/show_bug.cgi?id=129990
1712
1713         Reviewed by Geoffrey Garen.
1714
1715         * Shared/mac/RemoteLayerTreePropertyApplier.mm:
1716         (WebKit::RemoteLayerTreePropertyApplier::applyProperties): Use auto&.
1717
1718         * Shared/mac/RemoteLayerTreeTransaction.mm:
1719         (WebKit::RemoteLayerTreeTransaction::LayerProperties::decode): Use auto&
1720         even though the type is a scalar. This does no harm and makes it easier
1721         to spot uses that trigger unnecessary copying with grep.
1722         (WebKit::RemoteLayerTreeTransaction::decode): Ditto.
1723         (WebKit::dumpChangedLayers): Ditto.
1724         * UIProcess/mac/RemoteLayerTreeHost.mm:
1725         (WebKit::RemoteLayerTreeHost::updateLayerTree): Ditto.
1726         * WebProcess/WebProcess.cpp:
1727         (WebKit::WebProcess::visitedLinkStateChanged): Ditto.
1728
1729 2014-03-12  Brian Burg  <bburg@apple.com>
1730
1731         Web Inspector: Remove unused callId parameter from evaluateInWebInspector
1732         https://bugs.webkit.org/show_bug.cgi?id=129744
1733
1734         Reviewed by Timothy Hatcher.
1735
1736         * WebProcess/InjectedBundle/API/c/WKBundleInspector.cpp:
1737         (WKBundleInspectorEvaluateScriptForTest):
1738         * WebProcess/InjectedBundle/API/c/WKBundleInspector.h:
1739         * WebProcess/WebPage/WebInspector.cpp:
1740         (WebKit::WebInspector::evaluateScriptForTest):
1741         * WebProcess/WebPage/WebInspector.h:
1742
1743 2014-03-13  Laszlo Vidacs  <lvidacs.u-szeged@partner.samsung.com>
1744
1745         Fix the !ENABLE(SQL_DATABASE) build
1746         https://bugs.webkit.org/show_bug.cgi?id=130130
1747
1748         Reviewed by Csaba Osztrogonác.
1749
1750         Add missing #ifdef guard to typedef.
1751
1752         * UIProcess/API/C/WKDatabaseManager.cpp:
1753
1754 2014-03-12  Dean Jackson  <dino@apple.com>
1755
1756         [WebGL] WebKit1 + WebKit2 iOS clients should check load policy
1757         https://bugs.webkit.org/show_bug.cgi?id=130162
1758
1759         Reviewed by Simon Fraser.
1760
1761         Implement webGLPolicyForURL() methods for iOS.
1762
1763         * Configurations/WebContent-iOS.entitlements: Add the MobileAsset asset type.
1764         * Configurations/WebKit2.xcconfig: Add MobileAsset to iOS link list.
1765         * WebProcess/WebPage/WebPage.cpp: Exclude iOS.
1766         * WebProcess/WebPage/ios/WebPageIOS.mm:
1767         (WebKit::WebPage::webGLPolicyForURL): Call into WKSI.
1768         (WebKit::WebPage::resolveWebGLPolicyForURL):
1769
1770 2014-03-12  Joseph Pecoraro  <pecoraro@apple.com>
1771
1772         Web Inspector: Disable REMOTE_INSPECTOR in earlier OS X releases
1773         https://bugs.webkit.org/show_bug.cgi?id=130118
1774
1775         Reviewed by Timothy Hatcher.
1776
1777         * Configurations/FeatureDefines.xcconfig:
1778
1779 2014-03-12  Enrica Casucci  <enrica@apple.com>
1780
1781         [iOS WebKit2] Crash when trying to select inside a video element with longpress..
1782         https://bugs.webkit.org/show_bug.cgi?id=130095
1783         <rdar://problem/16294534>
1784
1785         Reviewed by Benjamin Poulain.
1786
1787         We only need to set the assisted node for nodes that will receive an
1788         input peripheral (keyboard, picker, popover, etc.).
1789
1790         * WebProcess/WebPage/ios/WebPageIOS.mm:
1791         (WebKit::WebPage::rangeForWebSelectionAtPosition):
1792         (WebKit::WebPage::elementDidFocus):
1793
1794 2014-03-12  Simon Fraser  <simon.fraser@apple.com>
1795
1796         Have the scrolling tree track the viewport size, not the viewport rect
1797         https://bugs.webkit.org/show_bug.cgi?id=130141
1798
1799         Reviewed by Beth Dakin.
1800
1801         The scrolling tree only needs to know the size of the viewport, not its
1802         origin, since the origin is deduced from the updated scroll position.
1803
1804         * Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
1805         (ArgumentCoder<ScrollingStateScrollingNode>::encode):
1806         (ArgumentCoder<ScrollingStateScrollingNode>::decode):
1807
1808 2014-03-12  Commit Queue  <commit-queue@webkit.org>
1809
1810         Unreviewed, rolling out r165481.
1811         https://bugs.webkit.org/show_bug.cgi?id=130151
1812
1813         That didn't go well. (Requested by kling on #webkit).
1814
1815         Reverted changeset:
1816
1817         https://bugs.webkit.org/show_bug.cgi?id=130140
1818         http://trac.webkit.org/changeset/165481
1819
1820 2014-03-12  Carlos Garcia Campos  <cgarcia@igalia.com>
1821
1822         [GTK] Runtime error when page is closed while print operation is in progress
1823         https://bugs.webkit.org/show_bug.cgi?id=129869
1824
1825         Reviewed by Anders Carlsson.
1826
1827         Sometimes when the page is closed right after printing the web
1828         process aborts with the runtime message "pure virtual method
1829         called terminate called without an active exception".
1830         This happens because the page is closed when the pages have been
1831         printed, but print job is still ongoing sending the data to the
1832         printer. When print job finishes, we try to notify the UI process
1833         sending the print callback message using WebPage::send(), but the
1834         web page object has been destroyed. The virtual method it complains
1835         about is probably MessageSender::messageSenderDestinationID() used
1836         by send(). Since our print operation is always asynchronous, we
1837         need a way to notify the web page when the print operation has
1838         actually finished to clean it up, but also notify the print
1839         operation when the page has been closed to not try to notify the
1840         UI process in that case.
1841
1842         * WebProcess/WebPage/WebPage.cpp:
1843         (WebKit::WebPage::close): Call disconnectFromPage to notify the
1844         print operation in case there's an ongoing print job.
1845         (WebKit::WebPage::endPrinting): Do not cleanup the print operation
1846         here, since the print opertation might not have finished yet.
1847         (WebKit::WebPage::didFinishPrintOperation): Send
1848         PrintFinishedCallback message to the Ui process and cleanup the
1849         print operation.
1850         * WebProcess/WebPage/WebPage.h:
1851         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp:
1852         (WebKit::WebPrintOperationGtk::disconnectFromPage): Set m_webPage
1853         to nullptr.
1854         (WebKit::WebPrintOperationGtk::printDone): Call
1855         didFinishPrintOperation() is the web page hasn't been closed.
1856         * WebProcess/WebPage/gtk/WebPrintOperationGtk.h:
1857
1858 2014-03-12  Andreas Kling  <akling@apple.com>
1859
1860         BundlePageDiagnosticLoggingClient leaks every string passing through it.
1861         <https://webkit.org/b/130140>
1862         <rdar://problem/15416838>
1863
1864         Use toAPI() instead of toCopiedAPI() so the receiving end doesn't need
1865         to worry about adopting the WKStringRef.
1866
1867         Reviewed by Anders Carlsson.
1868
1869         * WebProcess/InjectedBundle/InjectedBundlePageDiagnosticLoggingClient.cpp:
1870         (WebKit::InjectedBundlePageDiagnosticLoggingClient::logDiagnosticMessage):
1871
1872 2014-03-12  Tim Horton  <timothy_horton@apple.com>
1873
1874         Hook up image controls for WebKit1
1875         https://bugs.webkit.org/show_bug.cgi?id=130062
1876         <rdar://problem/15964809>
1877
1878         Reviewed by Brady Eidson.
1879
1880         * Shared/ContextMenuContextData.cpp:
1881         (WebKit::ContextMenuContextData::ContextMenuContextData):
1882
1883 2014-03-11  Alexey Proskuryakov  <ap@apple.com>
1884
1885         REGRESSION (r165356): [Mac] Multi-part key bindings don't work
1886         https://bugs.webkit.org/show_bug.cgi?id=130100
1887
1888         Reviewed by Darin Adler.
1889
1890         Restore the previous behavior, where we only interpreted keydowns (including those
1891         coming through performKeyEquivalent).
1892
1893         In the future, we might send all events to input methods, but not to key bindings.
1894
1895         * UIProcess/API/mac/WKView.mm:
1896         (-[WKView keyUp:]):
1897         (-[WKView flagsChanged:]):
1898
1899 2014-03-11  Beth Dakin  <bdakin@apple.com>
1900
1901         _pageExtendedBackgroundColor should not be exposed on WKWebView
1902         https://bugs.webkit.org/show_bug.cgi?id=130093
1903
1904         Reviewed by Simon Fraser.
1905
1906         Added comment indicating that _pageExtendedBackgroundColor is deprecated.
1907         * UIProcess/API/Cocoa/WKViewPrivate.h:
1908
1909         _pageExtendedBackgroundColor now returns nil, but the conversation functionality 
1910         is maintained with a convenience method pageExtendedBackgroundColor.
1911         * UIProcess/API/Cocoa/WKWebView.mm:
1912         (-[WKWebView pageExtendedBackgroundColor]):
1913         (-[WKWebView _didCommitLayerTree:WebKit::]):
1914         (-[WKWebView _pageExtendedBackgroundColor]):
1915
1916         Added comment indicating that _pageExtendedBackgroundColor is deprecated.
1917         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1918
1919         Return nil.
1920         * UIProcess/API/ios/WKViewIOS.mm:
1921         (-[WKView _pageExtendedBackgroundColor]):
1922
1923 2014-03-11  Jae Hyun Park  <jaepark@webkit.org>
1924
1925         [GTK][CMake] Add HARFBUZZ_INCLUDE_DIRS to WebKit and WebKit2
1926         https://bugs.webkit.org/show_bug.cgi?id=130070
1927
1928         Reviewed by Martin Robinson.
1929
1930         * PlatformGTK.cmake:
1931
1932 2014-03-10  Dan Bernstein  <mitz@apple.com>
1933
1934         [Cocoa] Expose WebPageProxy::close
1935         https://bugs.webkit.org/show_bug.cgi?id=130068
1936
1937         Reviewed by Adele Peterson.
1938
1939         * UIProcess/API/Cocoa/WKWebView.mm:
1940         (-[WKWebView _close]):
1941         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
1942
1943 2014-03-10  Benjamin Poulain  <bpoulain@apple.com>
1944
1945         [iOS][WebKit 2] Wire the unobscured rect in the WebProcess
1946         https://bugs.webkit.org/show_bug.cgi?id=130058
1947
1948         Reviewed by Simon Fraser.
1949
1950         * WebProcess/WebPage/ios/WebPageIOS.mm:
1951         (WebKit::WebPage::updateVisibleContentRects):
1952
1953 2014-03-10  Simon Fraser  <simon.fraser@apple.com>
1954
1955         Fix three leaks
1956         https://bugs.webkit.org/show_bug.cgi?id=130048
1957
1958         Reviewed by Anders Carlsson.
1959
1960         * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
1961         (decodeObject): Code is simpler and less leaky without the RetainPtr.
1962         * UIProcess/API/Cocoa/WKNavigationAction.mm: Fix _originalURL leak
1963         by making it a RetainPtr and implementing the getter and setter.
1964         (-[WKNavigationAction _setOriginalURL:]):
1965         (-[WKNavigationAction _originalURL]):
1966
1967 2014-03-10  Beth Dakin  <bdakin@apple.com>
1968
1969         Set background color of WK2's UIScrollView to the pageExtendedBackgroundColor
1970         https://bugs.webkit.org/show_bug.cgi?id=129919
1971
1972         Reviewed by Benjamin Poulain.
1973
1974         Make the pageExtendedBackgroundColor part of a RemoteLayerTreeTransaction.
1975         * Shared/mac/RemoteLayerTreeTransaction.h:
1976         (WebKit::RemoteLayerTreeTransaction::pageExtendedBackgroundColor):
1977         (WebKit::RemoteLayerTreeTransaction::setPageExtendedBackgroundColor):
1978         * Shared/mac/RemoteLayerTreeTransaction.mm:
1979         (WebKit::RemoteLayerTreeTransaction::encode):
1980         (WebKit::RemoteLayerTreeTransaction::decode):
1981
1982         Set the background color of the UIScrollView based on the 
1983         pageExtendedBackgroundColor.
1984         * UIProcess/API/Cocoa/WKWebView.mm:
1985         (-[WKWebView _didCommitLayerTree:WebKit::]):
1986
1987         For the sake of PLATFORM(MAC), continue to support the fact that this color can be 
1988         set via a message from the WebProcess or the new RemoteLayerTreeTransaction.
1989         * UIProcess/WebPageProxy.h:
1990
1991         Cache the pageExtendedBackgroundColor as provided by the 
1992         RemoteLayerTreeTransaction.
1993         * UIProcess/ios/WebPageProxyIOS.mm:
1994         (WebKit::WebPageProxy::didCommitLayerTree):
1995
1996         It’s not necessary to do anything here in non-Mac platforms anymore.
1997         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1998         (WebKit::WebChromeClient::pageExtendedBackgroundColorDidChange):
1999
2000         Include the pageExtendedBackgroundColor in the RemoteLayerTreeTransaction.
2001         * WebProcess/WebPage/WebPage.cpp:
2002         (WebKit::WebPage::willCommitLayerTree):
2003
2004 2014-03-10  Benjamin Poulain  <bpoulain@apple.com>
2005
2006         Generalize unobscured rect to all ports
2007         https://bugs.webkit.org/show_bug.cgi?id=130036
2008
2009         Reviewed by Simon Fraser.
2010
2011         * WebProcess/WebPage/ViewGestureGeometryCollector.cpp:
2012         (WebKit::ViewGestureGeometryCollector::collectGeometryForSmartMagnificationGesture):
2013         (WebKit::ViewGestureGeometryCollector::collectGeometryForMagnificationGesture):
2014         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2015         (WebKit::TiledCoreAnimationDrawingArea::applyTransientZoomToPage):
2016
2017 2014-03-10  Dan Bernstein  <mitz@apple.com>
2018
2019         <rdar://problem/16278716> [Cocoa] Allow setting a custom group identifier on a WKWebView
2020         https://bugs.webkit.org/show_bug.cgi?id=130033
2021
2022         Reviewed by Tim Horton.
2023
2024         * UIProcess/API/Cocoa/WKWebView.mm:
2025         (-[WKWebView initWithFrame:configuration:]): Create a page group with the group identifier
2026         from the configuration, if it’s non-empty.
2027         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
2028         (-[WKWebViewConfiguration _groupIdentifier]): Added this accessor.
2029         (-[WKWebViewConfiguration _setGroupIdentifier:]): Ditto.
2030         * UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h: Declared _groupIdentifier property.
2031
2032 2014-03-10  Enrica Casucci  <enrica@apple.com>
2033
2034         WebKit2: Crash in WebPage::getPositionInformation.
2035         https://bugs.webkit.org/show_bug.cgi?id=129936
2036         <rdar://problem/16264550>
2037  
2038         Reviewed by Eric Carlson.
2039  
2040         Missing null check on the node renderer in one code path.
2041         If the page body is smaller than the document, hit testing
2042         will return HTMLHtmlElement that has no renderer.
2043
2044         * WebProcess/WebPage/ios/WebPageIOS.mm:
2045         (WebKit::WebPage::getPositionInformation):
2046
2047 2014-03-10  Martin Robinson  <mrobinson@igalia.com>
2048
2049         [GTK] [CMake] Clean up library linking
2050         https://bugs.webkit.org/show_bug.cgi?id=129782
2051
2052         Reviewed by Philippe Normand.
2053
2054         * PlatformGTK.cmake: Use the new macro.
2055
2056 2014-03-10  Carlos Garcia Campos  <cgarcia@igalia.com>
2057
2058         [GTK] The web process can finish while a print operation is still ongoing
2059         https://bugs.webkit.org/show_bug.cgi?id=129871
2060
2061         Reviewed by Martin Robinson.
2062
2063         This can happen when the last page is closed while the print job
2064         is sending data to the printer.
2065
2066         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp: Disable web
2067         process termination when the print job is sending data to the
2068         printer and enable it again when job finishes.
2069
2070 2014-03-09  Jeong Yong-uk  <yong@company100.com>
2071
2072         Update comment in NetworkResourceLoader
2073         https://bugs.webkit.org/show_bug.cgi?id=129997
2074
2075         Reviewed by Andreas Kling.
2076
2077         NetworkResourceLoader::resourceHandleStopped() has been renamed to
2078         NetworkResourceLoader::cleanup() but the comment is not updated.
2079
2080         * NetworkProcess/NetworkResourceLoader.cpp:
2081         (WebKit::NetworkResourceLoader::start):
2082
2083 2014-03-09  Alexey Proskuryakov  <ap@apple.com>
2084
2085         iOS build fix.
2086
2087         * WebProcess/WebPage/ios/WebPageIOS.mm: Include WebCore/KeyboardEvent.h.
2088
2089 2014-03-06  Alexey Proskuryakov  <ap@apple.com>
2090
2091         [Mac] Don't perform a round-trip through WebProcess before interpreting key events
2092         https://bugs.webkit.org/show_bug.cgi?id=129812
2093
2094         Reviewed by Darin Adler.
2095
2096         * Shared/NativeWebKeyboardEvent.h:
2097         * Shared/WebEvent.h:
2098         (WebKit::WebKeyboardEvent::handledByInputMethod):
2099         (WebKit::WebKeyboardEvent::commands):
2100         * Shared/WebEventConversion.cpp:
2101         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
2102         * Shared/WebKeyboardEvent.cpp:
2103         (WebKit::WebKeyboardEvent::WebKeyboardEvent):
2104         (WebKit::WebKeyboardEvent::~WebKeyboardEvent):
2105         (WebKit::WebKeyboardEvent::encode):
2106         (WebKit::WebKeyboardEvent::decode):
2107         * Shared/mac/NativeWebKeyboardEventMac.mm:
2108         (WebKit::NativeWebKeyboardEvent::NativeWebKeyboardEvent):
2109         * Shared/mac/WebEventFactory.h:
2110         * Shared/mac/WebEventFactory.mm:
2111         (WebKit::WebEventFactory::createWebKeyboardEvent):
2112         Keyboard events now carry results of interpretation with them.
2113         Ideally, mouse events should also have a handledByInputMethod member, because IMs
2114         can handle events, but that can wait until we have actual bugs caused by not diabling
2115         default processing for these.
2116
2117         * UIProcess/API/mac/WKView.mm:
2118         (-[WKView becomeFirstResponder]): Updated for new NativeWebKeyboardEvent contructor
2119         signature. We don't interpret the event in this code path.
2120         (-[WKView doCommandBySelector:]): Added logging.
2121         (-[WKView performKeyEquivalent:]): Reimplemented Esc and Cmd+period handling to avoid
2122         infinite loops and re-entrancy. These two work in a unique way in AppKit.
2123         Interpret key event before sending it down to WebProcess.
2124         (-[WKView keyUp:]): Interpret key event before sending it down to WebProcess.
2125         We need to tell IMs about the event, but key binding processing is moot, all commands
2126         are executed on keydown.
2127         (-[WKView keyDown:]): Interpret the event.
2128         (-[WKView flagsChanged:]): Ditto.
2129         (-[WKView _interpretKeyEvent:savingCommandsTo:WebCore::]): Added an assertion in
2130         consumedByIM code path.
2131         (-[WKView _executeSavedCommandBySelector:]): Added logging.
2132
2133         * UIProcess/PageClient.h:
2134         * UIProcess/ios/PageClientImplIOS.h:
2135         * UIProcess/ios/PageClientImplIOS.mm:
2136         * UIProcess/mac/PageClientImpl.h:
2137         * UIProcess/mac/PageClientImpl.mm:
2138         * UIProcess/WebPageProxy.h:
2139         * UIProcess/WebPageProxy.messages.in:
2140         * UIProcess/ios/WebPageProxyIOS.mm:
2141         * UIProcess/mac/WebPageProxyMac.mm:
2142         Removed interpretQueuedKeyEvent/interpretKeyEvent, WebProcess no longer asks UIProcess to do this.
2143
2144         * WebProcess/WebCoreSupport/ios/WebEditorClientIOS.mm:
2145         (WebKit::WebEditorClient::handleKeyboardEvent):
2146         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
2147         (WebKit::WebEditorClient::handleKeyboardEvent):
2148         (WebKit::WebEditorClient::handleInputMethodKeydown):
2149         WebPage::handleEditingKeyboardEvent is now one function instead of two with a boolean
2150         switch between two behaviors.
2151
2152         * WebProcess/WebPage/WebPage.cpp:(WebKit::WebPage::WebPage):
2153         * WebProcess/WebPage/WebPage.h:
2154         Removed m_keyboardEventBeingInterpreted, as we no longer send the event for interpretation.
2155         This means that we sometimes have to pass a null event down to WebCore, but I wasn't
2156         able to find any behavior differences from us doing so.
2157
2158         * WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::handleEditingKeyboardEvent):
2159         Added a FIXME.
2160
2161         * WebProcess/WebPage/mac/WebPageMac.mm:
2162         (WebKit::WebPage::executeKeypressCommandsInternal): When we don't have an event,
2163         use current frame as a target, just like input method messages do.
2164         (WebKit::WebPage::handleEditingKeyboardEvent): This function no longer saves commands,
2165         it only interprets them.
2166         Added a check for Esc, as we don't want to handle it in keydown event handler.
2167         (WebKit::WebPage::insertText): Pass 0 instead of m_keyboardEventBeingInterpreted.
2168         (WebKit::WebPage::insertDictatedText): Ditto.
2169         (WebKit::WebPage::executeKeypressCommands): Ditto.
2170
2171 2014-03-09  Zalan Bujtas  <zalan@apple.com>
2172
2173         Subpixel rendering: Pass FloatSize boxsize to transform animations to support device pixel sizing.
2174         https://bugs.webkit.org/show_bug.cgi?id=129985
2175
2176         Reviewed by Simon Fraser.
2177
2178         This is in preparation to stop passing integral positioned boxes to transform animations.
2179
2180         No change in behavior.
2181
2182         * WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
2183
2184 2014-03-08  Simon Fraser  <simon.fraser@apple.com>
2185
2186         [iOS Wk2] Can't scroll after going back to page in page cache
2187         https://bugs.webkit.org/show_bug.cgi?id=129989
2188         <rdar://problem/16217588>
2189
2190         Reviewed by Dan Bernstein.
2191
2192         iOS has a special FrameLoader::forceLayoutWithoutRecalculatingStyle()
2193         function that is called instead of FrameView::forceLayout(). This was unimplemented
2194         for the WK2 FrameLoaderClient, so no layout was forced, with the result
2195         that the contentSize was never updated and scrolling was broken.
2196         
2197         Fix by renaming the client function to forceLayoutOnRestoreFromPageCache()
2198         and having it return a bool to say whether the default forceLayout()
2199         should be done. WK1 can then continue to have its custom behavior,
2200         and Wk2 will simply do a forceLayout().
2201         
2202         Also remove FrameLaoderClient::forceLayout(), which was never called.
2203
2204         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2205         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2206         * WebProcess/WebCoreSupport/ios/WebFrameLoaderClientIOS.mm:
2207         (WebKit::WebFrameLoaderClient::forceLayoutOnRestoreFromPageCache):
2208
2209 2014-03-08  Simon Fraser  <simon.fraser@apple.com>
2210
2211         [iOS WK2] Get position:fixed working slighlty better
2212         https://bugs.webkit.org/show_bug.cgi?id=129988
2213
2214         Reviewed by Dan Bernstein.
2215         
2216         iOS uses fixed layout, but does not want fixed elements laid
2217         out relative to the frame.
2218
2219         * WebProcess/WebPage/WebPage.cpp:
2220         (WebKit::WebPage::setUseFixedLayout):
2221
2222 2014-03-08  Jon Lee  <jonlee@apple.com>
2223
2224         iOS broken after r165342
2225         https://bugs.webkit.org/show_bug.cgi?id=129987
2226
2227         Reviewed by Simon Fraser.
2228
2229         * NetworkProcess/ios/NetworkProcessIOS.mm:
2230         (WebKit::NetworkProcess::platformLowMemoryHandler): Add missing stub implementation for
2231         platformLowMemoryHandler().
2232
2233 2014-03-08  Eric Carlson  <eric.carlson@apple.com>
2234
2235         [iOS] media preferences not initialized correctly in WebKit2
2236         https://bugs.webkit.org/show_bug.cgi?id=129983
2237
2238         Reviewed by Dan Bernstein.
2239
2240         * Shared/WebPreferencesStore.h: Initialize mediaPlaybackAllowsInline and 
2241         mediaPlaybackRequiresUserGesture correctly for iOS.
2242
2243 2014-03-08  Jeremy Jones  <jeremyj@apple.com>
2244
2245         Allow media element to supply the video layer after fullscreen transition has already begun.
2246         https://bugs.webkit.org/show_bug.cgi?id=129870
2247
2248         Reviewed by Eric Carlson.
2249
2250         WebVideoFullscreenManager and WebVideoFullscreenManagerProxy do their own remote hosting of the video layer instead of needing the video layer to have already been hosted elsewhere. This allows the removal of the coordination with WebPageProxy via a RemoteLayerTreeTransaction.
2251
2252         * Shared/mac/RemoteLayerTreeTransaction.h:
2253         Remove m_videoLayerIDsPendingFullscreen and accessors.
2254
2255         * Shared/mac/RemoteLayerTreeTransaction.mm:
2256         (WebKit::RemoteLayerTreeTransaction::encode):
2257         Don't encode m_videoLayerIDsPendingFullscreen
2258
2259         (WebKit::RemoteLayerTreeTransaction::decode):
2260         Don't decode m_videoLayerIDsPendingFullscreen
2261
2262         * UIProcess/ios/WebPageProxyIOS.mm:
2263         (WebKit::WebPageProxy::didCommitLayerTree):
2264         Don't forward didCommitLayerTree to m_videoFullscreenManager.
2265
2266         * UIProcess/ios/WebVideoFullscreenManagerProxy.h:
2267         Remove code for synchronizing with the RenderTree.
2268         Add a hosting layer and methods to keep video layer frame and video gravity synchronized.
2269
2270         * UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in:
2271         Change IPC interface to fascilitate rehosting video layer with a instead of coordinating with the RenderTree by PlatformLayerID.
2272
2273         * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
2274         (WebKit::WebVideoFullscreenManagerProxy::WebVideoFullscreenManagerProxy):
2275         Remove initialization for removed members.
2276
2277         (WebKit::WebVideoFullscreenManagerProxy::enterFullscreenWithID):
2278         Rehost the video layer by id and pass on the layer.
2279         This replaces didCommitLayerTree() and  willLendVideoLayerWithID(). 
2280
2281         (WebKit::WebVideoFullscreenManagerProxy::didExitFullscreen):
2282         Cleanup the hosting layer.
2283
2284         (WebKit::WebVideoFullscreenManagerProxy::setVideoLayerFrame):
2285         Forward on the video layer's frame to keep the hosted layer in sync with the interface.
2286
2287         (WebKit::WebVideoFullscreenManagerProxy::setVideoLayerGravity):
2288         Forward the videolayer gravity.
2289
2290         * WebKit2.xcodeproj/project.pbxproj:
2291         Rename WebVideoFullscreenManager.cpp to WebVideoFullscreenManager.mm
2292
2293         * WebProcess/WebPage/WebPage.cpp:
2294         (WebKit::WebPage::willCommitLayerTree):
2295         Don't invovle the m_videoFullscreenManager in layer tree transactions.
2296
2297         * WebProcess/ios/WebVideoFullscreenManager.h:
2298         Remove code that synchronizes with the render tree via RemoteLayerTreeTransaction.
2299         Instead rehost the video layer directly.
2300         Instead of hoping the WebVideoFullscreenModel has a videoLayer, supply one into which
2301         it can add whatever it likes as needed.
2302
2303         * WebProcess/ios/WebVideoFullscreenManager.messages.in:
2304         No more explicit borrowing and returning video layers.
2305         Add functions to keep video layer bounds and gravity in sync with the UI. 
2306
2307         * WebProcess/ios/WebVideoFullscreenManager.mm: Renamed from Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.cpp.
2308         Removed code for synchronizing via RemoteLAyerTreeTransaction.
2309
2310         (WebKit::WebVideoFullscreenManager::WebVideoFullscreenManager):
2311         Remove initialization for removed memeber m_sendUnparentVideoLayerTransaction.
2312
2313         (WebKit::WebVideoFullscreenManager::enterFullscreenForNode):
2314         Creates a fullscreen layer, gives it to the WebVideoFullscreenModel to fill in,
2315         and hosts it in a context to send to the UIProcess.
2316
2317         (WebKit::WebVideoFullscreenManager::exitFullscreenForNode):
2318         remove enterFullscreen() and just directly send the IPC message. 
2319
2320         (WebKit::WebVideoFullscreenManager::didExitFullscreen):
2321         Clean up the hosting context.
2322
2323         (WebKit::WebVideoFullscreenManager::setVideoLayerGravityEnum):
2324         Forward on the video gravity. Type convert from unsigned to MediaPlayer::VideoGravity.
2325
2326 2014-03-08  Andreas Kling  <akling@apple.com>
2327
2328         [WK2] Improve the network process low memory handler.
2329         <https://webkit.org/b/129977>
2330
2331         Split the network process low memory handler into platform-specific
2332         and shared parts. The shared part tells FastMalloc to release freed
2333         pages back to the OS.
2334
2335         For Mac, added a call to purge the in-memory part of CFURLCache.
2336         Remove the malloc_zone_pressure_relief() since that is now taken care
2337         of by the shared MemoryPressureHandler code.
2338
2339         Reviewed by Darin Adler.
2340
2341         * NetworkProcess/NetworkProcess.cpp:
2342         (WebKit::NetworkProcess::initializeNetworkProcess):
2343         (WebKit::NetworkProcess::lowMemoryHandler):
2344         (WebKit::NetworkProcess::platformLowMemoryHandler):
2345         * NetworkProcess/NetworkProcess.h:
2346         * NetworkProcess/mac/NetworkProcessMac.mm:
2347         (WebKit::NetworkProcess::platformLowMemoryHandler):
2348         (WebKit::NetworkProcess::platformInitializeNetworkProcess):
2349
2350 2014-03-08  Jae Hyun Park  <jaepark@webkit.org>
2351
2352         Remove unnecessary casting in NetworkProcessMainUnix.cpp
2353         https://bugs.webkit.org/show_bug.cgi?id=129968
2354
2355         Reviewed by Andreas Kling.
2356
2357         * NetworkProcess/unix/NetworkProcessMainUnix.cpp:
2358         Since socket is an int, int casting is not necessary.
2359
2360         (WebKit::NetworkProcessMain):
2361
2362 2014-03-08  Aaron Golden  <golden@inkling.com>
2363
2364         Prevent processes spawned by WebProcess from trying to insert the SecItem shim.
2365         https://bugs.webkit.org/show_bug.cgi?id=129864
2366
2367         Reviewed by Anders Carlsson.
2368
2369         * WebProcess/EntryPoint/mac/LegacyProcess/WebContentProcessMain.mm:
2370         (WebKit::WebContentProcessMainDelegate::doPreInitializationWork):
2371
2372 2014-03-07  Tim Horton  <timothy_horton@apple.com>
2373
2374         [WebKit2][iOS] PDF
2375         https://bugs.webkit.org/show_bug.cgi?id=129600
2376         <rdar://problem/15260216>
2377
2378         Reviewed by Anders Carlsson.
2379
2380         Add a single custom content provider which installs a very primitive PDF view
2381         in place of the WKContentView if a PDF is loaded in the main frame.
2382
2383         * Configurations/WebKit2.xcconfig:
2384         Link against CorePDF, for UIPDFPageView.
2385
2386         * UIProcess/Cocoa/WKWebViewContentProviderRegistry.mm:
2387         (-[WKWebViewContentProviderRegistry init]):
2388         Initialize the registry, using WKPDFView for all PDF MIME types.
2389
2390         * WebKit2.xcodeproj/project.pbxproj:
2391         * UIProcess/ios/WKPDFView.h: Added.
2392         * UIProcess/ios/WKPDFView.mm: Added.
2393         Add a very simple PDF view based on UIPDFPageView. Additional functionality
2394         can come in the future; right now, we just create one view for each page, and
2395         depend on CATiledLayer to only paint the pages that are being displayed.
2396
2397 2014-03-07  Andreas Kling  <akling@apple.com>
2398
2399         ArgumentEncoder and ArgumentDecoder should be fastmalloced.
2400         <https://webkit.org/b/129960>
2401
2402         Reviewed by Ryosuke Niwa.
2403
2404         * Platform/IPC/ArgumentDecoder.h:
2405         * Platform/IPC/ArgumentEncoder.h:
2406
2407 2014-03-07  Martin Robinson  <mrobinson@igalia.com>
2408
2409         Fix the GTK+ build after the recent iOS merge.
2410
2411         * UIProcess/API/gtk/PageClientImpl.cpp: Make some methods available to non-Cocoa ports and fix some signatures.
2412         * UIProcess/WebPageProxy.h: Ditto.
2413
2414 2014-03-07  Ryuan Choi  <ryuan.choi@samsung.com>
2415
2416         Unreviewed. Fix build on the EFL port after r165303
2417
2418         * UIProcess/CoordinatedGraphics/WebView.cpp:
2419         (WebKit::WebView::didCommitLoadForMainFrame): Added new parameters.
2420         * UIProcess/CoordinatedGraphics/WebView.h: Ditto.
2421         * UIProcess/WebPageProxy.h:
2422         * UIProcess/efl/WebViewEfl.cpp: Added dummy didFinishLoadingDataForCustomContentProvider()
2423         (WebKit::WebViewEfl::exitFullScreen):
2424         (WebKit::WebViewEfl::didFinishLoadingDataForCustomContentProvider):
2425         * UIProcess/efl/WebViewEfl.h: Ditto.
2426
2427 2014-03-07  Enrica Casucci  <enrica@apple.com>
2428
2429         [iOS WebKit2] Keyboard accessory comes up when I click a link.
2430         https://bugs.webkit.org/show_bug.cgi?id=129949
2431         <rdar://problem/16265305>
2432
2433         Reviewed by Simon Fraser.
2434
2435         We need to create the accessory view only when needed.
2436
2437         * UIProcess/ios/WKContentViewInteraction.mm:
2438         (-[WKContentView requiresAccessoryView]):
2439         (-[WKContentView inputAccessoryView]):
2440
2441 2014-03-07  Enrica Casucci  <enrica@apple.com>
2442
2443         [iOS WebKit2] Long-press on a link shows just "Copy".
2444         https://bugs.webkit.org/show_bug.cgi?id=129938
2445         <rdar://problem/16266054>
2446
2447         Reviewed by Benjamin Poulain.
2448
2449         When adding a FIXME comment, I accidentally removed the ! on
2450         the if (!element) condition.
2451
2452         * WebProcess/WebPage/ios/WebPageIOS.mm:
2453         (WebKit::WebPage::getPositionInformation):
2454
2455 2014-03-07  Tim Horton  <timothy_horton@apple.com>
2456
2457         [WebKit2][iOS] Main-frame custom content providers
2458         https://bugs.webkit.org/show_bug.cgi?id=129809
2459
2460         Reviewed by Dan Bernstein.
2461
2462         Re-introduce custom content providers to WebKit2 (removed in r152841), but
2463         for iOS this time.
2464
2465         * UIProcess/API/Cocoa/WKWebView.mm:
2466         (-[WKWebView initWithFrame:configuration:]):
2467         Send the initial MIME types that have custom content providers to the WebProcess.
2468
2469         (-[WKWebView dealloc]):
2470         Unregister our page from the content provider registry.
2471         
2472         (-[WKWebView _setHasCustomContentView:loadedMIMEType:]):
2473         Install/uninstall the custom content provider. Create a view, if needed,
2474         based on the class that the registry has associated with the given MIME type.
2475         We unparent the WKContentView while the custom content provider is active,
2476         and re-use the existing WKScrollView to contain the custom content provider.
2477
2478         (-[WKWebView _didFinishLoadingDataForCustomContentProviderWithSuggestedFilename:dataReference:]):
2479         Forward loaded data on to the custom content provider for display.
2480
2481         (-[WKWebView _didCommitLayerTree:WebKit::]):
2482         Assert that we aren't getting layer tree commits while using a custom content provider.
2483
2484         (-[WKWebView viewForZoomingInScrollView:]):
2485         If we're using a custom content provider, its view should be used for zooming
2486         instead of the (unparented) web content view.
2487
2488         (-[WKWebView hasContentView]):
2489         (-[WKWebView scrollViewWillBeginZooming:withView:]):
2490         (-[WKWebView scrollViewWillBeginDragging:]):
2491         (-[WKWebView _didFinishScrolling]):
2492         (-[WKWebView _updateVisibleContentRects]):
2493         If we do not have a parented WKContentView because we are using a custom
2494         content provider, we should not forward scroll view related changes to it.
2495
2496         (-[WKWebView _frameOrBoundsChanged]):
2497         Update the minimum size of the custom content provider if the web view size changes.
2498
2499         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
2500         (-[WKWebViewConfiguration copyWithZone:]):
2501         (-[WKWebViewConfiguration _contentProviderRegistry]):
2502         (-[WKWebViewConfiguration _setContentProviderRegistry:]):
2503         * UIProcess/API/Cocoa/WKWebViewConfigurationInternal.h: Added.
2504         Add an internal WKWebViewConfiguration property, the WKWebViewContentProviderRegistry.
2505
2506         * UIProcess/API/Cocoa/WKWebViewInternal.h:
2507
2508         * UIProcess/Cocoa/WKWebViewContentProvider.h: Added.
2509         A minimal protocol for informing custom content providers of changes to
2510         the size of the view, the represented data, and the owning scroll view.
2511
2512         * UIProcess/Cocoa/WKWebViewContentProviderRegistry.h: Added.
2513         * UIProcess/Cocoa/WKWebViewContentProviderRegistry.mm: Added.
2514         (-[WKWebViewContentProviderRegistry addPage:]):
2515         (-[WKWebViewContentProviderRegistry removePage:]):
2516         (-[WKWebViewContentProviderRegistry registerProvider:forMIMEType:]):
2517         (-[WKWebViewContentProviderRegistry providerForMIMEType:]):
2518         (-[WKWebViewContentProviderRegistry mimeTypesWithContentProviders]):
2519         New class, keeps track of a mapping from MIME types to UIViews that
2520         conform to the WKWebViewContentProvider protocol.
2521
2522         * UIProcess/WebPageProxy.cpp:
2523         (WebKit::WebPageProxy::WebPageProxy):
2524         (WebKit::WebPageProxy::didCommitLoadForFrame):
2525         * UIProcess/WebPageProxy.h:
2526         * UIProcess/WebPageProxy.messages.in:
2527
2528         * UIProcess/PageClient.h:
2529         * UIProcess/ios/PageClientImplIOS.h:
2530         * UIProcess/ios/PageClientImplIOS.mm:
2531         (WebKit::PageClientImpl::PageClientImpl):
2532         (WebKit::PageClientImpl::didCommitLoadForMainFrame):
2533         (WebKit::PageClientImpl::didFinishLoadingDataForCustomContentProvider):
2534         * UIProcess/mac/PageClientImpl.h:
2535         * UIProcess/mac/PageClientImpl.mm:
2536         (WebKit::PageClientImpl::didCommitLoadForMainFrame):
2537         (WebKit::PageClientImpl::didFinishLoadingDataForCustomContentProvider):
2538         Add parameters to didCommitLoadForMainFrame, indicating if we should use
2539         a custom content provider to display the main frame, and what MIME type
2540         was loaded in said frame, and add didFinishLoadingDataForCustomContentProvider.
2541         On iOS, forward these to the WKWebView.
2542         Also, give PageClientImplIOS a reference to the WKWebView.
2543         
2544         * UIProcess/ios/WKContentView.mm:
2545         (-[WKContentView initWithFrame:context:WebKit::configuration:WebKit::webView:]):
2546         
2547         * WebKit2.xcodeproj/project.pbxproj:
2548         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.mm:
2549         (-[WKWebProcessPlugInFrame _hasCustomContentProvider]):
2550         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFramePrivate.h:
2551         Expose whether or not a given frame has a custom content provider to the plug-in.
2552
2553         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2554         (WebKit::WebFrameLoaderClient::WebFrameLoaderClient):
2555         (WebKit::WebFrameLoaderClient::hasHTMLView):
2556         (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
2557         (WebKit::WebFrameLoaderClient::committedLoad):
2558         (WebKit::WebFrameLoaderClient::finishedLoading):
2559         (WebKit::WebFrameLoaderClient::transitionToCommittedFromCachedFrame):
2560         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
2561         (WebKit::WebFrameLoaderClient::canCachePage):
2562         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2563         (WebKit::WebFrameLoaderClient::frameHasCustomContentProvider):
2564         Restore WebFrameLoaderClient custom representation code, which ensures
2565         that data is routed correctly (to the UI process, and not to WebCore) and
2566         that we don't try to use the page cache for frames with content providers.
2567
2568         * WebProcess/WebPage/WebPage.cpp:
2569         (WebKit::WebPage::mainFrameHasCustomContentProvider):
2570         (WebKit::WebPage::addMIMETypeWithCustomContentProvider):
2571         (WebKit::WebPage::shouldUseCustomContentProviderForResponse):
2572         (WebKit::WebPage::canShowMIMEType):
2573         * WebProcess/WebPage/WebPage.h:
2574         * WebProcess/WebPage/WebPage.messages.in:
2575         Keep a list of MIME types which can be displayed via custom content providers
2576         in WebPage, which will be pushed down from the registry as new providers
2577         are added. Plug-ins still take precendence over custom content providers.
2578
2579 2014-03-07  Anders Carlsson  <andersca@apple.com>
2580
2581         MigrateHeaders.make should remove C SPI includes from WebKit2 headers
2582         https://bugs.webkit.org/show_bug.cgi?id=129937
2583         <rdar://problem/15920020>
2584
2585         Reviewed by Tim Horton.
2586
2587         * WebKit2.xcodeproj/project.pbxproj:
2588         Make WKPreferences.h and all headers it includes public. Update the post processing of WKBase.h
2589         to account for WKBase.h now being a public header again.
2590
2591 2014-03-07  Alexey Proskuryakov  <ap@apple.com>
2592
2593         REGRESSION (r164847): Pressing the command key while hovering an element causes it to un-hover
2594         https://bugs.webkit.org/show_bug.cgi?id=129872
2595
2596         Reviewed by Tim Horton.
2597
2598         * UIProcess/API/Cocoa/WKViewPrivate.h: Changes in performDictionaryLookupAtCurrentMouseLocation
2599         were also not correct, because the current event could be a keyboard one (Cmd+Ctrl+D).
2600         But this SPI is unused, and can be simply removed.
2601
2602         * UIProcess/API/mac/WKView.mm: (-[WKView _postFakeMouseMovedEventForFlagsChangedEvent:]):
2603         locationInWindow is undefined for keyboard events, so we have to use current location.
2604         Thankfully, there is a method that returns the location in appropriate coordinate
2605         space, unlike +[NSEvent mouseLocation] that we used before.
2606
2607 2014-03-07  Andy Estes  <aestes@apple.com>
2608
2609         [iOS] Install WebKit2 XPC services to the correct place during iOS Simulator builds
2610         https://bugs.webkit.org/show_bug.cgi?id=129914
2611
2612         Reviewed by Dan Bernstein.
2613
2614         We weren't specifying INSTALL_PATH for iOS Simulator builds in
2615         BaseXPCService.xcconfig, and r164576 changed INSTALL_PATH to
2616         INSTALL_PATH_ACTUAL. This caused XPC services to start being installed
2617         to the root of the iOS Simulator SDK. Fix this by setting
2618         INSTALL_PATH_ACTUAL for iphonesimulator.
2619
2620         * Configurations/BaseXPCService.xcconfig:
2621
2622 2014-03-07  Andreas Kling  <akling@apple.com>
2623
2624         [Mac] Notify system malloc of fake memory pressure.
2625         <https://webkit.org/b/129908>
2626
2627         Reviewed by Anders Carlsson.
2628
2629         * NetworkProcess/mac/NetworkProcessMac.mm:
2630         (WebKit::NetworkProcess::platformInitializeNetworkProcess):
2631
2632             Listen for the fake memory pressure notification and respond by
2633             just forwarding to system malloc. We don't do the full WebCore
2634             memory pressure handling here, since that will cause stuff that
2635             the network process doesn't need to get instantiated.
2636
2637 2014-03-07  Dean Jackson  <dino@apple.com>
2638
2639         Attempt to fix the iOS build.
2640
2641         * Configurations/WebKit2.xcconfig: Add -framework OpenGLES to linking.
2642
2643 2014-03-07  Simon Fraser  <simon.fraser@apple.com>
2644
2645         [iOS] Add an updateID to visibleContentRect updates which is passed back in layer transactions, so we know whether transactions are stale
2646         https://bugs.webkit.org/show_bug.cgi?id=129897
2647
2648         Reviewed by Benjamin Poulain.
2649
2650         In WebKit2 on iOS we need to know when layer updates from the web process
2651         are stale with respect to visible rect updates from the UI process. Do so
2652         by adding an updateID to VisibleContentRectUpdateInfo, and storing it
2653         on each side, returning it in RemoteLayerTreeTransaction.
2654         
2655         Did some re-ordering of members and encoding order in RemoteLayerTreeTransaction
2656         to group like data members together.
2657         
2658         * Shared/VisibleContentRectUpdateInfo.cpp:
2659         (WebKit::VisibleContentRectUpdateInfo::encode):
2660         (WebKit::VisibleContentRectUpdateInfo::decode):
2661         * Shared/VisibleContentRectUpdateInfo.h:
2662         (WebKit::VisibleContentRectUpdateInfo::VisibleContentRectUpdateInfo):
2663         (WebKit::VisibleContentRectUpdateInfo::updateID):
2664         (WebKit::operator==):
2665         * Shared/mac/RemoteLayerTreeTransaction.h:
2666         (WebKit::RemoteLayerTreeTransaction::setLastVisibleContentRectUpdateID):
2667         (WebKit::RemoteLayerTreeTransaction::lastVisibleContentRectUpdateID):
2668         * Shared/mac/RemoteLayerTreeTransaction.mm:
2669         (WebKit::RemoteLayerTreeTransaction::encode):
2670         (WebKit::RemoteLayerTreeTransaction::decode):
2671         * UIProcess/WebPageProxy.h:
2672         (WebKit::WebPageProxy::nextVisibleContentRectUpdateID):
2673         (WebKit::WebPageProxy::lastVisibleContentRectUpdateID):
2674         * UIProcess/ios/WKContentView.mm:
2675         (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
2676         * WebProcess/WebPage/WebPage.cpp:
2677         (WebKit::WebPage::WebPage):
2678         (WebKit::WebPage::willCommitLayerTree):
2679         * WebProcess/WebPage/WebPage.h:
2680         * WebProcess/WebPage/ios/WebPageIOS.mm:
2681         (WebKit::WebPage::updateVisibleContentRects):
2682
2683 2014-03-07  Roger Fong  <roger_fong@apple.com>
2684
2685         Replace setSystemWebGLLoadPolicy API with methods to query for WebGL blocking policy.
2686         https://bugs.webkit.org/show_bug.cgi?id=129873.
2687
2688         Reviewed by Dean Jackson.
2689
2690         Remove setSystemWebGLLoadPolicy API.
2691         * UIProcess/API/APILoaderClient.h:
2692         (API::LoaderClient::resolveWebGLLoadPolicy):
2693         * UIProcess/API/C/WKPage.cpp:
2694         (WKPageSetPageLoaderClient):
2695         * UIProcess/API/C/WKPageLoaderClient.h:
2696         * UIProcess/WebPageProxy.cpp:
2697         (WebKit::WebPageProxy::resolveWebGLPolicyForURL):
2698         * UIProcess/WebPageProxy.h:
2699         * UIProcess/WebPageProxy.messages.in:
2700         * WebProcess/WebPage/mac/WebPageMac.mm:
2701         (WebKit::WebPage::webGLPolicyForURL):
2702
2703         Add API to directly query the WebGL blocking policies from WKSI.
2704         * UIProcess/API/C/mac/WKContextPrivateMac.h:
2705         * UIProcess/API/C/mac/WKContextPrivateMac.mm:
2706         (WKContextShouldBlockWebGL):
2707         (WKContextShouldSuggestBlockWebGL):
2708
2709 2014-03-07  Eric Carlson  <eric.carlson@apple.com>
2710
2711         Initialize new WKSI functions for WebKit2
2712         https://bugs.webkit.org/show_bug.cgi?id=129889
2713
2714         Reviewed by Simon Fraser.
2715
2716         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2717         (InitWebCoreSystemInterface):
2718
2719 2014-03-07  Carlos Garcia Campos  <cgarcia@igalia.com>
2720
2721         [GTK] Use final and override in WebPrintOperationGtk
2722         https://bugs.webkit.org/show_bug.cgi?id=129868
2723
2724         Reviewed by Sergio Villar Senin.
2725
2726         * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp:
2727
2728 2014-03-06  Alexey Proskuryakov  <ap@apple.com>
2729
2730         [Mac] Allow com.apple.GSSCred in WebKit sandbox profiles
2731         https://bugs.webkit.org/show_bug.cgi?id=129777
2732         <rdar://problem/16050832>
2733
2734         Reviewed by Anders Carlsson.
2735
2736         * NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in:
2737         * Resources/PlugInSandboxProfiles/com.apple.ist.ds.appleconnect.webplugin.sb:
2738         * WebProcess/com.apple.WebProcess.sb.in:
2739
2740 2014-03-06  Filip Pizlo  <fpizlo@apple.com>
2741
2742         If the FTL is build-time enabled then it should be run-time enabled.
2743
2744         Rubber stamped by Geoffrey Garen.
2745
2746         * Shared/WebProcessCreationParameters.cpp:
2747         (WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
2748         (WebKit::WebProcessCreationParameters::encode):
2749         (WebKit::WebProcessCreationParameters::decode):
2750         * Shared/WebProcessCreationParameters.h:
2751         * UIProcess/mac/WebContextMac.mm:
2752         (WebKit::registerUserDefaultsIfNeeded):
2753         (WebKit::WebContext::platformInitializeWebProcess):
2754         * WebProcess/cocoa/WebProcessCocoa.mm:
2755         (WebKit::WebProcess::platformInitializeWebProcess):
2756
2757 2014-03-06  Hyowon Kim  <hw1008.kim@samsung.com>
2758
2759         [EFL] Move EvasGL classes from WebKit to WebCore namespace.
2760         https://bugs.webkit.org/show_bug.cgi?id=129797
2761
2762         Reviewed by Gyuyoung Kim.
2763
2764         * UIProcess/API/efl/EwkView.h: namespace changes for EvasGLContext/Surface.
2765
2766 2014-03-06  Simon Fraser  <simon.fraser@apple.com>
2767
2768         Remove one more setCustomFixedPositionRect() that I missed.
2769
2770         * UIProcess/DrawingAreaProxy.h:
2771
2772 2014-03-06  Simon Fraser  <simon.fraser@apple.com>
2773
2774         Send the fixed position rect to the WebProcess along with the other rects
2775         https://bugs.webkit.org/show_bug.cgi?id=129856
2776
2777         Reviewed by Benjamin Poulain.
2778         
2779         Remove the functions that pass the custom fixed position rect through
2780         the DrawingArea, and replace them by adding this rect to the
2781         VisibleContentRectUpdateInfo, along with the "is stable" flag. We
2782         then set the custom fixed position rect in the web process for
2783         stable updates.
2784
2785         * Shared/VisibleContentRectUpdateInfo.cpp:
2786         (WebKit::VisibleContentRectUpdateInfo::encode):
2787         (WebKit::VisibleContentRectUpdateInfo::decode):
2788         * Shared/VisibleContentRectUpdateInfo.h:
2789         (WebKit::VisibleContentRectUpdateInfo::VisibleContentRectUpdateInfo):
2790         (WebKit::VisibleContentRectUpdateInfo::customFixedPositionRect):
2791         (WebKit::VisibleContentRectUpdateInfo::inStableState):
2792         (WebKit::operator==):
2793         * UIProcess/DrawingAreaProxy.cpp:
2794         * UIProcess/ios/WKContentView.mm:
2795         (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
2796         * WebProcess/WebPage/DrawingArea.h:
2797         * WebProcess/WebPage/DrawingArea.messages.in:
2798         * WebProcess/WebPage/ios/WebPageIOS.mm:
2799         (WebKit::WebPage::updateVisibleContentRects):
2800         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
2801         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
2802         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2803
2804 2014-03-06  Simon Fraser  <simon.fraser@apple.com>
2805
2806         Remove empty class extension in WKContentViewInteraction
2807         https://bugs.webkit.org/show_bug.cgi?id=129849
2808
2809         Reviewed by Enrica Casucci.
2810         
2811         This empty class extension is cruft left over from refactoring.
2812         It can be removed.
2813
2814         * UIProcess/ios/WKContentViewInteraction.mm:
2815
2816 2014-03-06  Simon Fraser  <simon.fraser@apple.com>
2817
2818         [iOS] didUpdateVisibleRect: should use fabs, not abs
2819         https://bugs.webkit.org/show_bug.cgi?id=129843
2820
2821         Reviewed by Benjamin Poulain.
2822         
2823         When zooming we sent messages to the web process with an unchanging
2824         zoom scale because of use of abs() rather than fabs().
2825
2826         * UIProcess/ios/WKContentView.mm:
2827         (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
2828
2829 2014-03-06  Anders Carlsson  <andersca@apple.com>
2830
2831         Remove WebKit1 header includes from WebKit2
2832         https://bugs.webkit.org/show_bug.cgi?id=129824
2833
2834         Reviewed by Dan Bernstein.
2835
2836         * UIProcess/mac/WKFullScreenWindowController.mm:
2837         (makeResponderFirstResponderIfDescendantOfView):
2838         Add a new function instead of calling an NSWindow category method that's defined in WebKit1.
2839
2840         (-[WKFullScreenWindowController enterFullScreen:]):
2841         (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
2842         (-[WKFullScreenWindowController finishedExitFullScreenAnimation:]):
2843         Call makeResponderFirstResponderIfDescendantOfView.
2844
2845         * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
2846         Remove unused WebKit1 header import.
2847
2848         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
2849         (WebKit::WebEditorClient::documentFragmentFromAttributedString):
2850         Change a category to be on NSObject instead of WebResource.
2851
2852 2014-03-06  Jon Lee  <jonlee@apple.com>
2853
2854         iOS build fix.
2855
2856         Reviewed by Simon Fraser.
2857
2858         * UIProcess/ios/SmartMagnificationController.mm:
2859
2860 2014-03-06  Joseph Pecoraro  <pecoraro@apple.com>
2861
2862         Web Inspector: Expose the console object in JSContexts to interact with Web Inspector
2863         https://bugs.webkit.org/show_bug.cgi?id=127944
2864
2865         Reviewed by Geoffrey Garen.
2866
2867         * WebProcess/WebCoreSupport/WebChromeClient.h:
2868         Update namespaces.
2869
2870 2014-03-06  Carlos Garcia Campos  <cgarcia@igalia.com>
2871
2872         [GTK] Close the page when the view is disposed instead of when finalized
2873         https://bugs.webkit.org/show_bug.cgi?id=129783
2874
2875         Reviewed by Sergio Villar Senin.
2876
2877         When a GtkWidget is destroyed, the GObject is disposed, but not
2878         finalized if it has additional references. When the destroyed
2879         widget is leaked by the application, we leak the page proxy and
2880         what is more important the web process in multi-process mode.
2881
2882         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
2883         (webkitWebViewBaseDispose): Close the WebPageProxy.
2884
2885 2014-03-05  Chris Fleizach  <cfleizach@apple.com>
2886
2887         AX: Support IOS Accessibility in WK2
2888         https://bugs.webkit.org/show_bug.cgi?id=129527
2889
2890         Build fix.
2891
2892         * WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.mm:
2893         (-[WKAccessibilityWebPageObject accessibilityHitTest:]):
2894
2895 2014-03-05  Chris Fleizach  <cfleizach@apple.com>
2896
2897         AX: Support IOS Accessibility in WK2
2898         https://bugs.webkit.org/show_bug.cgi?id=129527
2899
2900         Address review comments from Simon noted in bug.
2901
2902         * UIProcess/ios/WKContentView.mm:
2903         (-[WKContentView _accessibilityRegisterUIProcessTokens]):
2904         * WebProcess/WebPage/WKAccessibilityWebPageObjectIOS.mm:
2905         (-[WKAccessibilityWebPageObject init]):
2906         (-[WKAccessibilityWebPageObject dealloc]):
2907         * WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.h:
2908         * WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.mm:
2909         (-[WKAccessibilityWebPageObject accessibilityAttributeNames]):
2910         (-[WKAccessibilityWebPageObject accessibilitySetValue:forAttribute:]):
2911         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:]):
2912         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:forParameter:]):
2913         (-[WKAccessibilityWebPageObject accessibilityHitTest:]):
2914
2915 2014-03-05  Dean Jackson  <dino@apple.com>
2916
2917         [WebGL] Use WKSI to see what the system policy for WebGL is
2918         https://bugs.webkit.org/show_bug.cgi?id=129722
2919         <rdar://problem/15790542>
2920
2921         Reviewed by Tim Horton.
2922
2923         Use the WebKitSystemInterface methods WKShouldBlockWebGL
2924         and WKShouldSuggestBlockingWebGL to query what the host
2925         system thinks about the hardware. Tell the client about
2926         the result in a new WebPage method setSystemWebGLPolicy.
2927
2928         * UIProcess/API/APILoaderClient.h:
2929         (API::LoaderClient::setSystemWebGLLoadPolicy): New empty definition.
2930         * UIProcess/API/C/WKAPICast.h:
2931         (WebKit::toAPI): Convert a WebGLLoadPolicy into a WKWebGLLoadPolicy.
2932         * UIProcess/API/C/WKPage.cpp: Call setSystemWebGLLoadPolicy.
2933         (WKPageSetPageLoaderClient):
2934         * UIProcess/API/C/WKPageLoaderClient.h: New typedef and entry in client structure.
2935         * UIProcess/WebPageProxy.cpp:
2936         (WebKit::WebPageProxy::setSystemWebGLPolicy):
2937         * UIProcess/WebPageProxy.h:
2938         * UIProcess/WebPageProxy.messages.in: Add SetSystemWebGLPolicy.
2939         * Source/WebKit2/Configurations/WebKit2.xcconfig: We have to link against OpenGL now, because WKSI
2940         uses it for hardware detection.
2941         * WebProcess/WebPage/WebPage.cpp: Remove the implementation here, but leave
2942         empty methods for non-Apple platforms.
2943         (WebKit::WebPage::WebPage):
2944         (WebKit::WebPage::webGLPolicyForURL):
2945         (WebKit::WebPage::resolveWebGLPolicyForURL):
2946         * WebProcess/WebPage/WebPage.h: Add m_systemWebGLPolicy.
2947         * WebProcess/WebPage/mac/WebPageMac.mm:
2948         (WebKit::WebPage::webGLPolicyForURL): Moved in from WebPage, but now they call
2949         into WKSI and send the result to the client if necessary.
2950         (WebKit::WebPage::resolveWebGLPolicyForURL):
2951
2952 2014-03-05  Simon Fraser  <simon.fraser@apple.com>
2953
2954         Fix a stupid error in r165118 that caused userVisibleString()
2955         to call itself recursively.
2956
2957         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
2958         (WebKit::WebEditorClient::userVisibleString):
2959
2960 2014-03-05  Benjamin Poulain  <bpoulain@apple.com>
2961
2962         [iOS] Rename the various VisibleExtent variations to exposedContentRect
2963         https://bugs.webkit.org/show_bug.cgi?id=129728
2964
2965         Reviewed by Simon Fraser.
2966
2967         * WebProcess/WebPage/DrawingArea.h:
2968         * WebProcess/WebPage/ios/WebPageIOS.mm:
2969         (WebKit::WebPage::updateVisibleContentRects):
2970         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
2971         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
2972         (WebKit::RemoteLayerTreeDrawingArea::setExposedContentRect):
2973
2974 2014-03-05  Dean Jackson  <dino@apple.com>
2975
2976         Unreviewed. Fix the Apple-internal builds.
2977
2978         * Configurations/WebKit2.xcconfig: Add -framework OpenGL.
2979
2980 2014-03-05  Simon Fraser  <simon.fraser@apple.com>
2981
2982         ObjC exception when dropping files into a WKView: drag and drop uses code from WebKit.framework
2983         https://bugs.webkit.org/show_bug.cgi?id=129752
2984
2985         Reviewed by Enrica Casucci.
2986         
2987         Get WebDragClientMac off of all WebKit headers, and WebEditorClientMac off
2988         all but one by using C functions from WebCoreNSURLExtras.h rather than
2989         the NSURL category.
2990
2991         * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
2992         (WebKit::WebDragClient::declareAndWriteDragImage):
2993         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
2994         (WebKit::WebEditorClient::userVisibleString):
2995         (WebKit::WebEditorClient::canonicalizeURL):
2996         (WebKit::WebEditorClient::canonicalizeURLString):
2997
2998 2014-03-05  Martin Hock  <mhock@apple.com>
2999
3000         Add support for sessions to MemoryCache.
3001         https://bugs.webkit.org/show_bug.cgi?id=127794
3002
3003         Reviewed by Sam Weinig.
3004
3005         * NetworkProcess/NetworkResourceLoader.h: Add sessionID() method.
3006         (WebKit::NetworkResourceLoader::sessionID):
3007         * NetworkProcess/mac/DiskCacheMonitor.h: Add sessionID member.
3008         * NetworkProcess/mac/DiskCacheMonitor.mm:
3009         (WebKit::DiskCacheMonitor::DiskCacheMonitor): Send sessionID to NetworkProcessConnection::DidCacheResource.
3010         * WebProcess/Network/NetworkProcessConnection.cpp: Add sessionID parameter to didCacheResource and pass to MemoryCache.
3011         (WebKit::NetworkProcessConnection::didCacheResource):
3012         * WebProcess/Network/NetworkProcessConnection.h: Ditto.
3013         * WebProcess/Network/NetworkProcessConnection.messages.in: Ditto.
3014
3015 2014-03-05  Enrica Casucci  <enrica@apple.com>
3016
3017         [iOS WebKit2] support multi-select and select with groups for iPhone.
3018         https://bugs.webkit.org/show_bug.cgi?id=129344
3019         <rdar://problem/16206928>
3020
3021         Reviewed by Simon Fraser.
3022
3023         This is the remaining work on select element support on iOS.
3024         This adds multi-select and select with group support with UI
3025         for iPhone that uses UIPickerView.
3026
3027         * UIProcess/ios/WKContentViewInteraction.mm:
3028         (-[WKContentView resignFirstResponder]):
3029         (-[WKContentView inputAccessoryView]): Removed incorrect early return.
3030         (-[WKContentView _stopAssistingNode]):
3031         * UIProcess/ios/forms/WKFormSelectControl.h:
3032         * UIProcess/ios/forms/WKFormSelectControl.mm:
3033         (adjustedFontSize): Moved here to make it available to both picker and
3034         popover based implementations.
3035         (-[WKFormSelectControl initWithView:]):
3036         * UIProcess/ios/forms/WKFormSelectPicker.mm:
3037         (-[WKOptionPickerCell _isSelectable]):
3038         (-[WKOptionPickerCell initCommon]):
3039         (-[WKOptionPickerCell initWithOptionItem:]):
3040         (-[WKOptionGroupPickerCell initWithOptionItem:]):
3041         (-[WKOptionGroupPickerCell labelWidthForBounds:]):
3042         (-[WKOptionGroupPickerCell layoutSubviews]):
3043         (-[WKMultipleSelectPicker initWithView:]):
3044         (-[WKMultipleSelectPicker dealloc]):
3045         (-[WKMultipleSelectPicker controlView]):
3046         (-[WKMultipleSelectPicker controlBeginEditing]):
3047         (-[WKMultipleSelectPicker controlEndEditing]):
3048         (-[WKMultipleSelectPicker layoutSubviews]):
3049         (-[WKMultipleSelectPicker pickerView:viewForRow:forComponent:reusingView:]):
3050         (-[WKMultipleSelectPicker numberOfComponentsInPickerView:]):
3051         (-[WKMultipleSelectPicker pickerView:numberOfRowsInComponent:]):
3052         (-[WKMultipleSelectPicker findItemIndexAt:]):
3053         (-[WKMultipleSelectPicker pickerView:row:column:checked:]):
3054         (-[WKSelectSinglePicker initWithView:]):
3055         (-[WKSelectSinglePicker controlEndEditing]):
3056         * UIProcess/ios/forms/WKFormSelectPopover.mm:
3057
3058 2014-03-03  Martin Robinson  <mrobinson@igalia.com>
3059
3060         [GTK][CMake] Generate documentation for the DOM bindings
3061         https://bugs.webkit.org/show_bug.cgi?id=126211
3062
3063         Reviewed by Carlos Garcia Campos.
3064
3065         * PlatformGTK.cmake: The list of headers for GIR generation has a better name now.
3066
3067 2014-03-04  Benjamin Poulain  <bpoulain@apple.com>
3068
3069         Fix the build after r165095
3070
3071         * UIProcess/API/Cocoa/WKWebView.mm:
3072         (-[WKWebView _keyboardChangedWithInfo:adjustScrollView:]):
3073
3074 2014-03-04  Benjamin Poulain  <bpoulain@apple.com>
3075
3076         [iOS][WK2] Account for the keyboard when computing the unobscuredRect
3077         https://bugs.webkit.org/show_bug.cgi?id=129660
3078
3079         Reviewed by Enrica Casucci.
3080
3081         Adjust the unobscuredRect when a docked keyboard is on screen.
3082
3083         * UIProcess/API/Cocoa/WKWebView.mm:
3084         (-[WKWebView _updateVisibleContentRectsWithStableState:]):
3085         (-[WKWebView _keyboardChangedWithInfo:adjustScrollView:]):
3086
3087 2014-03-04  Andy Estes  <aestes@apple.com>
3088
3089         [iOS][WebKit2] Exclude plug-in sandbox profiles from the build
3090         https://bugs.webkit.org/show_bug.cgi?id=129719
3091
3092         Reviewed by Simon Fraser.
3093
3094         * Configurations/WebKit2.xcconfig:
3095
3096 2014-03-04  Benjamin Poulain  <bpoulain@apple.com>
3097
3098         [iOS][WK2] WKScrollView should be able to cancel touches in content view
3099         https://bugs.webkit.org/show_bug.cgi?id=129711
3100
3101         Reviewed by Simon Fraser.
3102
3103         * UIProcess/ios/WKScrollView.mm:
3104         We should not override UIWebScrollView behavior regarding touch cancellation otherwise we force
3105         other gesture recognizers to fail if delayed touches have been dispatched.
3106
3107 2014-03-04  Benjamin Poulain  <bpoulain@apple.com>
3108
3109         [iOS][WK2] Consider the entire view state on update to find if a change is stable or not
3110         https://bugs.webkit.org/show_bug.cgi?id=129721
3111
3112         Reviewed by Simon Fraser.
3113
3114         Changes in scroll, zoom and obscuredRect can happen simultaneously. To compute if the current state
3115         is stable or not, we should consider the complete picture from all the type of updates.
3116
3117         * UIProcess/API/Cocoa/WKWebView.mm:
3118         (-[WKWebView _didFinishScrolling]):
3119         (-[WKWebView scrollViewDidScroll:]):
3120         (-[WKWebView scrollViewDidZoom:]):
3121         (-[WKWebView scrollViewDidEndZooming:withView:atScale:]):
3122         (-[WKWebView _frameOrBoundsChanged]):
3123         (-[WKWebView _updateVisibleContentRects]):
3124         (-[WKWebView _setObscuredInsets:]):
3125         (-[WKWebView _endInteractiveObscuredInsetsChange]):
3126
3127 2014-03-04  Jeremy Jones  <jeremyj@apple.com>
3128
3129         WebVideoFullscreen, should make the hand off of the video layer explicit.
3130         https://bugs.webkit.org/show_bug.cgi?id=128844
3131
3132         Reviewed by Simon Fraser.
3133
3134         This change introduces a more explicit hand-off of the video layer and fullscreen transition.
3135         This describes the interactions between WebVideoFullscreenInterface and WebVideoFullscreenModel
3136         WebVideoFullscreenModel <-> WebVideoFullscreenInterface
3137               enterFullScreen(*) ->
3138                                 <- borrowVideoLayer
3139               willLendVideoLayer ->
3140                didLendVideoLayer ->
3141                                 <- didEnterFullscreen
3142                                 ...
3143                                 <- requestExitFullscreen
3144                   exitFullscreen ->
3145                                 <- returnVideoLayer
3146                                 <- didExitFullscreen
3147         (*) enterFullScreen actually comes from WebVideoFullscreenControllerAVKit.
3148
3149         * UIProcess/ios/WebVideoFullscreenManagerProxy.h:
3150         Implement WebVideoFullscreenChangeObserver.
3151         Add support for explicit video layer hand-off.
3152         Add m_videoView to retain the videoLayer's UIView.
3153
3154         * UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in:
3155         WillLendVideoLayerWithID replaces SetVideoLayerID
3156
3157         * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
3158         Adopt new methods for explicit video layer hand-off.
3159
3160         (WebKit::WebVideoFullscreenManagerProxy::WebVideoFullscreenManagerProxy):
3161         Observe fullscreen changes.
3162
3163         (WebKit::WebVideoFullscreenManagerProxy::didCommitLayerTree):
3164         Pending fullscreen transition now does didLendVideoLayer instead of calling enter fullscreen.
3165         It also removes the videoView from it's super view now that it is safe to do so.
3166
3167         (WebKit::WebVideoFullscreenManagerProxy::willLendVideoLayerWithID):
3168         This replaces setVideoLayerID. It retains the UIView for the layer to keep it alive before it is unparented.
3169
3170         (WebKit::WebVideoFullscreenManagerProxy::requestExitFullscreen):
3171         Adopt more explicit fullscreen transition.
3172
3173         (WebKit::WebVideoFullscreenManagerProxy::didExitFullscreen):
3174         Adopt more explicit fullscreen transition.
3175
3176         (WebKit::WebVideoFullscreenManagerProxy::didEnterFullscreen):
3177         Adopt more explicit fullscreen transition.
3178
3179         (WebKit::WebVideoFullscreenManagerProxy::borrowVideoLayer):
3180         Adopt more explicit video layer hand-off.
3181
3182         (WebKit::WebVideoFullscreenManagerProxy::returnVideoLayer):
3183         Adopt more explicit video layer hand-off.
3184
3185         * WebProcess/ios/WebVideoFullscreenManager.cpp:
3186         Manage state of fullscreen transition more competently. Wait till an animation is complete to begin the next one.
3187
3188         (WebKit::WebVideoFullscreenManager::WebVideoFullscreenManager):
3189         Init three new state members.
3190
3191         (WebKit::WebVideoFullscreenManager::enterFullscreenForNode):
3192         Update animation state. Don't procede if animation is in progress.
3193
3194         (WebKit::WebVideoFullscreenManager::exitFullscreenForNode):
3195         Update animation state. Don't procede if animation is in progress.
3196
3197         (WebKit::WebVideoFullscreenManager::willLendVideoLayer):
3198         Adopt more explicit video layer hand-off.
3199         This replaces SetVideoLayer.
3200
3201         (WebKit::WebVideoFullscreenManager::didLendVideoLayer):
3202         This is a no-op as this will be sent through a RemoteLayerTreeTransaction.
3203
3204         (WebKit::WebVideoFullscreenManager::didEnterFullscreen):
3205         Adopt more explicit fullscreen transition.
3206
3207         (WebKit::WebVideoFullscreenManager::didExitFullscreen):
3208         Adopt more explicit fullscreen transition.
3209
3210         * WebProcess/ios/WebVideoFullscreenManager.h:
3211         Adopt more explicit fullscreen transition.
3212
3213         * WebProcess/ios/WebVideoFullscreenManager.messages.in:
3214         Adopt more explicit fullscreen/video layer transition.
3215
3216 2014-03-04  Simon Fraser  <simon.fraser@apple.com>
3217
3218         Get position:fixed working slightly better on iOS WK2
3219         https://bugs.webkit.org/show_bug.cgi?id=129714
3220
3221         Reviewed by Benjamin Poulain.
3222         
3223         Start telling the RemoteScrollingCoordinatorProxy about scroll position changes
3224         again, so it can update fixed and sticky layers.
3225         
3226         Send the scroll position as a FloatPoint, rather than an IntPoint.
3227
3228         * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp:
3229         (WebKit::RemoteScrollingCoordinatorProxy::scrollPositionChangedViaDelegatedScrolling):
3230         (WebKit::RemoteScrollingCoordinatorProxy::scrollPositionChanged):
3231         * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.h:
3232         * UIProcess/WebPageProxy.h:
3233         * UIProcess/ios/WKContentView.mm:
3234         (-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):
3235         Tell the RemoteScrollingCoordinatorProxy about the scroll update.
3236         Only update the customFixedPositionRect if we've finished scrolling or zooming.
3237         * UIProcess/ios/WebPageProxyIOS.mm:
3238         (WebKit::WebPageProxy::updateVisibleContentRects): Return a bool indicating
3239         whether the visible rects changed.
3240
3241 2014-03-04  Conrad Shultz  <conrad_shultz@apple.com>
3242
3243         WKPage's pageExtendedBackgroundColor API exposed through WKView/WKWebView should support NSColor
3244         https://bugs.webkit.org/show_bug.cgi?id=129704
3245
3246         Reviewed by Beth Dakin.
3247
3248         Add NSColor-returning methods to complement the existing UIColor-returning methods.
3249
3250         * UIProcess/API/Cocoa/WKViewPrivate.h:
3251         Declare _pageExtendedBackgroundColor for non-TARGET_OS_IPHONE.
3252
3253         * UIProcess/API/Cocoa/WKWebView.mm:
3254         (-[WKWebView _pageExtendedBackgroundColor]):
3255         Return an NSColor created from the pageExtendedBackgroundColor.
3256
3257         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
3258         Declare _pageExtendedBackgroundColor for non-TARGET_OS_IPHONE.
3259
3260         * UIProcess/API/mac/WKView.mm:
3261         (-[WKView _pageExtendedBackgroundColor]):
3262         Return an NSColor created from the pageExtendedBackgroundColor.
3263
3264 2014-03-04  Joseph Pecoraro  <pecoraro@apple.com>
3265
3266         Web Inspector: Give WebProcess private RWI entitlement
3267         https://bugs.webkit.org/show_bug.cgi?id=129710
3268
3269         Reviewed by Timothy Hatcher.
3270
3271         * Configurations/WebContent-iOS.entitlements:
3272         Add entitlements to "WebProcess" when code signing.
3273
3274         * Configurations/WebContentProcess.xcconfig:
3275         Add the private RWI entitlement.
3276
3277 2014-03-04  Enrica Casucci  <enrica@apple.com>
3278
3279         [iOS WebKit2]: Next/Prev button in the accessory bar do not work.
3280         https://bugs.webkit.org/show_bug.cgi?id=129690
3281         <rdar://problem/16073569>
3282
3283         Reviewed by Simon Fraser.
3284
3285         Adding support for Next and Previous buttons in the accessory bar.
3286         When the request is processed by the WebProcess, we identify the next
3287         focusable node that needs to be assisted and we call focus() on the element
3288         letting the focus changing machinery take care of updating the assisted node.
3289         This change also add support for the Clear button, when appropriate and hooks up
3290         the call to the WebProcess.
3291
3292         * UIProcess/WebPageProxy.h:
3293         * UIProcess/ios/WKContentViewInteraction.mm:
3294         (-[WKContentView accessoryTab:]):
3295         (-[WKContentView accessoryClear]):
3296         (-[WKContentView _updateAccessory]):
3297         * UIProcess/ios/WebPageProxyIOS.mm:
3298         (WebKit::WebPageProxy::focusNextAssistedNode):
3299         * WebProcess/WebPage/WebPage.h:
3300         * WebProcess/WebPage/WebPage.messages.in:
3301         * WebProcess/WebPage/ios/WebPageIOS.mm:
3302         (WebKit::nextFocusableElement):
3303         (WebKit::hasFocusableElement):
3304         (WebKit::WebPage::focusNextAssistedNode):
3305         (WebKit::WebPage::getAssistedNodeInformation):
3306
3307 2014-03-04  Simon Fraser  <simon.fraser@apple.com>
3308
3309         Allow iOS DumpRenderTree crashes to show application-specific information
3310         https://bugs.webkit.org/show_bug.cgi?id=129705
3311
3312         Reviewed by David Kilzer.
3313         
3314         Make the WKSI function SetCrashReportApplicationSpecificInformation available
3315         in iOS simulator builds.
3316
3317         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3318         (InitWebCoreSystemInterface):
3319
3320 2014-03-04  Mark Hahnenberg  <mhahnenberg@apple.com>
3321
3322         Merge API shims and JSLock
3323         https://bugs.webkit.org/show_bug.cgi?id=129650
3324
3325         Reviewed by Mark Lam.
3326
3327         JSLock is now taking on all of APIEntryShim's responsibilities since there is never a reason 
3328         to take just the JSLock. Ditto for DropAllLocks and APICallbackShim.
3329
3330         * DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
3331         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::~UniqueIDBDatabaseBackingStoreSQLite):
3332         (WebKit::UniqueIDBDatabaseBackingStoreSQLite::createIndex):
3333
3334 2014-03-03  Enrica Casucci  <enrica@apple.com>
3335
3336         [WK2] Selection remains after reload.
3337         https://bugs.webkit.org/show_bug.cgi?id=129648
3338         <rdar://problem/16207547>
3339
3340         Reviewed by Sam Weinig.
3341
3342         We normally clear the selection when resigninig first responder but
3343         that doesn't get called when reloading the page or when navigating with
3344         back/forward buttons. The correct place to do this is when we get
3345         _didCommitLoadForMainFrame where we already stop assisting the node.
3346         The method we call into webselectionassistant is resignedFirstResponder
3347         which takes care of clearing the selection and removing the selection view.
3348
3349         * UIProcess/ios/WKContentViewInteraction.mm:
3350         (-[WKContentView _stopAssistingNode]):
3351
3352 2014-03-04  Hyowon Kim  <hw1008.kim@samsung.com>
3353
3354         Move EvasGLContext and EvasGLSurface files into the efl common directory.
3355         https://bugs.webkit.org/show_bug.cgi?id=129603
3356
3357         Reviewed by Gyuyoung Kim.
3358
3359         * PlatformEfl.cmake: Update for removed files.
3360
3361 2014-03-03  Benjamin Poulain  <bpoulain@apple.com>
3362
3363         [iOS][WK2] WebPage::updateVisibleContentRects can set the position directly instead of using programmatic scrolling
3364         https://bugs.webkit.org/show_bug.cgi?id=129649
3365
3366         Reviewed by Sam Weinig.
3367
3368         * WebProcess/WebPage/ios/WebPageIOS.mm:
3369         (WebKit::WebPage::updateVisibleContentRects):
3370         Update my workaround from r165003. We should not use programmatic scrolling when the scroll position is changed
3371         from the UI.
3372
3373 2014-03-03  Benjamin Poulain  <bpoulain@apple.com>
3374
3375         [iOS][WK2] Update UIScrollView's contentSize when a new layer tree is committed
3376         https://bugs.webkit.org/show_bug.cgi?id=129641
3377
3378         Reviewed by Sam Weinig.
3379
3380         * UIProcess/API/Cocoa/WKWebView.mm:
3381         (-[WKWebView _didCommitLayerTree:WebKit::]):
3382         Previously, we relied on [UIScrollView setZoomScale:] to reset the contentSize for us.
3383         In the cases where we would not go through [UIScrollView setZoomScale:], the UIScrollView's contentSize
3384         did not match the actual WKContentView's area on screen.
3385
3386 2014-03-03  Jeremy Jones  <jeremyj@apple.com>
3387
3388         Forward application suspend resume notifications to the web process.
3389         https://bugs.webkit.org/show_bug.cgi?id=129356
3390
3391         Reviewed by Eric Carlson.
3392
3393         Repost UIApplicationWillEnterForegroundNotification,
3394         UIApplicationDidBecomeActiveNotification and 
3395         UIApplicationWillResignActiveNotification from UIProcess to WebProcess.
3396         As WebUIApplicationWillEnterForegroundNotification,
3397         WebUIApplicationDidBecomeActiveNotification, and
3398         WebUIApplicationWillResignActiveNotification
3399
3400         * UIProcess/WebPageProxy.h:
3401         Add applicationWillEnterForeground()
3402         applicationWillResignActive()
3403         applicationDidBecomeActive()
3404
3405         * UIProcess/ios/WKContentView.mm:
3406         (-[WKContentView initWithFrame:context:WebKit::configuration:WebKit::]):
3407         Observe notifications.
3408
3409         (-[WKContentView dealloc]):
3410         Stop observing notifications.
3411
3412         (-[WKContentView _applicationWillResignActive:]):
3413         Notify WebPageProxy of the event.
3414
3415         (-[WKContentView _applicationWillEnterForeground:]):
3416         Notify WebPageProxy of the event.
3417
3418         (-[WKContentView _applicationDidBecomeActive:]):
3419         Notify WebPageProxy of the event.
3420
3421         * UIProcess/ios/WebPageProxyIOS.mm:
3422         (WebKit::WebPageProxy::applicationWillEnterForeground):
3423         Send corresponding Message to WebPage.
3424
3425         (WebKit::WebPageProxy::applicationWillResignActive):
3426         Send corresponding Message to WebPage.
3427
3428         (WebKit::WebPageProxy::applicationDidBecomeActive):
3429         Send corresponding Message to WebPage.
3430
3431         * WebProcess/WebPage/WebPage.h:
3432         Add applicationWillEnterForeground()
3433         applicationWillResignActive()
3434         applicationDidBecomeActive()
3435
3436         * WebProcess/WebPage/WebPage.messages.in:
3437         Add applicationWillEnterForeground()
3438         applicationWillResignActive()
3439         applicationDidBecomeActive()
3440
3441         * WebProcess/WebPage/ios/WebPageIOS.mm:
3442         (WebKit::WebPage::applicationWillResignActive):
3443         Post corresponding NSNotification.
3444
3445         (WebKit::WebPage::applicationWillEnterForeground):
3446         Post corresponding NSNotification.
3447
3448         (WebKit::WebPage::applicationDidBecomeActive):
3449         Post corresponding NSNotification.
3450
3451 2014-03-03  Commit Queue  <commit-queue@webkit.org>
3452
3453         Unreviewed, rolling out r165013.
3454         http://trac.webkit.org/changeset/165013
3455         https://bugs.webkit.org/show_bug.cgi?id=129646
3456
3457         New code is not thread safe, asserting on a worker test
3458         (Requested by ap on #webkit).
3459
3460         * NetworkProcess/NetworkResourceLoader.h:
3461         * NetworkProcess/mac/DiskCacheMonitor.h:
3462         * NetworkProcess/mac/DiskCacheMonitor.mm:
3463         (WebKit::DiskCacheMonitor::DiskCacheMonitor):
3464         * WebProcess/Network/NetworkProcessConnection.cpp:
3465         (WebKit::NetworkProcessConnection::didCacheResource):
3466         * WebProcess/Network/NetworkProcessConnection.h:
3467         * WebProcess/Network/NetworkProcessConnection.messages.in:
3468
3469 2014-03-03  Enrica Casucci  <enrica@apple.com>
3470
3471         [iOS WebKit2]: Text fields don't zoom in when focused
3472         https://bugs.webkit.org/show_bug.cgi?id=129632
3473         <rdar://problem/16185230>
3474
3475         Reviewed by Benjamin Poulain.
3476
3477         When focusing the node we need to zoom and center it and possibly
3478         scroll to make it visible.
3479         On iPad we only scroll, without zooming.
3480
3481         * Shared/AssistedNodeInformation.cpp:
3482         (WebKit::AssistedNodeInformation::encode):
3483         (WebKit::AssistedNodeInformation::decode):
3484         * Shared/AssistedNodeInformation.h:
3485         (WebKit::AssistedNodeInformation::AssistedNodeInformation):
3486         * UIProcess/API/Cocoa/WKWebViewInternal.h:
3487         * UIProcess/ios/WKContentView.h:
3488         * UIProcess/ios/WKContentView.mm:
3489         (-[WKContentView _scrollToRect:withOrigin:minimumScrollDistance:]):
3490         * UIProcess/ios/WKContentViewInteraction.mm:
3491         (-[WKContentView _displayFormNodeInputView]):
3492         (-[WKContentView _startAssistingNode:]):
3493         * WebProcess/WebPage/ios/WebPageIOS.mm:
3494         (WebKit::WebPage::getAssistedNodeInformation):
3495
3496 2014-03-03  Sam Weinig  <sam@webkit.org>
3497
3498         Fix ASSERT and leaks introduced in recent "Support IOS Accessibility in WK2" patch
3499
3500         Reviewed by Simon Fraser.
3501
3502         * UIProcess/ios/WKContentView.mm:<